summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohannes Schauer Marin Rodrigues <josch@mister-muffin.de>2023-08-25 23:44:45 +0200
committerJohannes Schauer Marin Rodrigues <josch@mister-muffin.de>2023-08-25 23:44:45 +0200
commitd66ecf0cbcc1d5734bb882746a2c45a712b4b9b3 (patch)
treef317943c92a4aae3e299e17f95c96b493e5e146a
parent112e597de859d204e528766b9b2c8d0f096ea86e (diff)
New upstream version 0.2.4+dfsg
-rw-r--r--.github/FUNDING.yml12
-rw-r--r--.github/workflows/manual.yml95
-rw-r--r--.github/workflows/release.yml104
-rw-r--r--.gitignore67
-rwxr-xr-x.travis.yml24
-rw-r--r--[-rwxr-xr-x]CMakeLists.txt200
-rw-r--r--LLVMprivateGenerator/Makefile12
-rw-r--r--LLVMprivateGenerator/main.cpp458
-rw-r--r--LLVMprivateGenerator/registered_structs.cpp267
-rw-r--r--README.md (renamed from docs/README.md)27
-rw-r--r--README_CN.md113
-rw-r--r--README_UK.md119
-rw-r--r--debian/changelog98
-rw-r--r--debian/compat1
-rw-r--r--debian/control14
-rw-r--r--debian/copyright26
-rw-r--r--debian/lintian-override1
-rw-r--r--debian/rules12
-rw-r--r--debian/source/format1
-rw-r--r--debian/upstream/metadata5
-rw-r--r--debian/watch1
-rw-r--r--docs/CHANGELOG.md41
-rw-r--r--[-rwxr-xr-x]docs/COMPILE.md173
-rw-r--r--docs/README_CN.md119
-rw-r--r--[-rwxr-xr-x]docs/USAGE.md31
-rw-r--r--docs/box64.pod465
-rw-r--r--[-rwxr-xr-x]docs/img/Box64Icon.pngbin63691 -> 63691 bytes
-rw-r--r--[-rwxr-xr-x]docs/img/Box64Logo.pngbin184304 -> 184304 bytes
-rw-r--r--pkgbuilds/PKGBUILD-arm6438
-rw-r--r--pkgbuilds/PKGBUILD-arm64-DEBUG38
-rw-r--r--pkgbuilds/PKGBUILD-lx2160a38
-rw-r--r--pkgbuilds/PKGBUILD-lx2160a-DEBUG38
-rw-r--r--pkgbuilds/PKGBUILD-rk339938
-rw-r--r--pkgbuilds/PKGBUILD-rk3399-DEBUG38
-rw-r--r--pkgbuilds/PKGBUILD-rpi438
-rw-r--r--pkgbuilds/PKGBUILD-rpi4-DEBUG38
-rw-r--r--pkgbuilds/PKGBUILD-tegra38
-rw-r--r--pkgbuilds/PKGBUILD-tegra-DEBUG38
-rw-r--r--pkgbuilds/PKGBUILD-x86_6437
-rw-r--r--pkgbuilds/PKGBUILD-x86_64-DEBUG37
-rw-r--r--pkgbuilds/README.md24
-rwxr-xr-xrebuild_wrappers.py91
-rw-r--r--[-rwxr-xr-x]runTest.cmake0
-rw-r--r--[-rwxr-xr-x]src/box64context.c92
-rw-r--r--[-rwxr-xr-x]src/box64version.h2
-rw-r--r--[-rwxr-xr-x]src/build_info.c0
-rw-r--r--[-rwxr-xr-x]src/build_info.h2
-rw-r--r--src/custommem.c238
-rw-r--r--[-rwxr-xr-x]src/dynarec/arm64/arm64_emitter.h158
-rw-r--r--[-rwxr-xr-x]src/dynarec/arm64/arm64_epilog.S0
-rw-r--r--[-rwxr-xr-x]src/dynarec/arm64/arm64_lock.S30
-rw-r--r--[-rwxr-xr-x]src/dynarec/arm64/arm64_lock.h30
-rw-r--r--[-rwxr-xr-x]src/dynarec/arm64/arm64_next.S0
-rw-r--r--[-rwxr-xr-x]src/dynarec/arm64/arm64_printer.c214
-rw-r--r--[-rwxr-xr-x]src/dynarec/arm64/arm64_prolog.S0
-rw-r--r--[-rwxr-xr-x]src/dynarec/arm64/dynarec_arm64_00.c676
-rw-r--r--[-rwxr-xr-x]src/dynarec/arm64/dynarec_arm64_0f.c375
-rw-r--r--src/dynarec/arm64/dynarec_arm64_64.c179
-rw-r--r--[-rwxr-xr-x]src/dynarec/arm64/dynarec_arm64_66.c311
-rw-r--r--[-rwxr-xr-x]src/dynarec/arm64/dynarec_arm64_660f.c702
-rw-r--r--src/dynarec/arm64/dynarec_arm64_6664.c21
-rw-r--r--src/dynarec/arm64/dynarec_arm64_66f0.c63
-rw-r--r--[-rwxr-xr-x]src/dynarec/arm64/dynarec_arm64_67.c215
-rw-r--r--src/dynarec/arm64/dynarec_arm64_d8.c34
-rw-r--r--src/dynarec/arm64/dynarec_arm64_d9.c46
-rw-r--r--src/dynarec/arm64/dynarec_arm64_db.c41
-rw-r--r--src/dynarec/arm64/dynarec_arm64_dc.c34
-rw-r--r--src/dynarec/arm64/dynarec_arm64_dd.c32
-rw-r--r--src/dynarec/arm64/dynarec_arm64_de.c37
-rw-r--r--src/dynarec/arm64/dynarec_arm64_df.c166
-rw-r--r--[-rwxr-xr-x]src/dynarec/arm64/dynarec_arm64_emit_logic.c2
-rw-r--r--[-rwxr-xr-x]src/dynarec/arm64/dynarec_arm64_emit_math.c4
-rw-r--r--[-rwxr-xr-x]src/dynarec/arm64/dynarec_arm64_emit_shift.c4
-rw-r--r--[-rwxr-xr-x]src/dynarec/arm64/dynarec_arm64_emit_tests.c19
-rw-r--r--src/dynarec/arm64/dynarec_arm64_f0.c184
-rw-r--r--[-rwxr-xr-x]src/dynarec/arm64/dynarec_arm64_f20f.c102
-rw-r--r--[-rwxr-xr-x]src/dynarec/arm64/dynarec_arm64_f30f.c96
-rw-r--r--[-rwxr-xr-x]src/dynarec/arm64/dynarec_arm64_functions.c579
-rw-r--r--[-rwxr-xr-x]src/dynarec/arm64/dynarec_arm64_functions.h71
-rw-r--r--[-rwxr-xr-x]src/dynarec/arm64/dynarec_arm64_helper.c504
-rw-r--r--[-rwxr-xr-x]src/dynarec/arm64/dynarec_arm64_helper.h239
-rw-r--r--[-rwxr-xr-x]src/dynarec/arm64/dynarec_arm64_pass0.h9
-rw-r--r--[-rwxr-xr-x]src/dynarec/arm64/dynarec_arm64_pass1.h0
-rw-r--r--[-rwxr-xr-x]src/dynarec/arm64/dynarec_arm64_pass2.h12
-rw-r--r--[-rwxr-xr-x]src/dynarec/arm64/dynarec_arm64_pass3.h70
-rw-r--r--[-rwxr-xr-x]src/dynarec/arm64/dynarec_arm64_private.h51
-rw-r--r--[-rwxr-xr-x]src/dynarec/dynablock.c157
-rw-r--r--[-rwxr-xr-x]src/dynarec/dynablock_private.h5
-rw-r--r--[-rwxr-xr-x]src/dynarec/dynarec.c215
-rw-r--r--[-rwxr-xr-x]src/dynarec/dynarec_arch.h33
-rw-r--r--[-rwxr-xr-x]src/dynarec/dynarec_helper.h2
-rw-r--r--[-rwxr-xr-x]src/dynarec/dynarec_native.c193
-rw-r--r--src/dynarec/dynarec_native_functions.c481
-rw-r--r--src/dynarec/dynarec_native_functions.h66
-rw-r--r--[-rwxr-xr-x]src/dynarec/dynarec_native_pass.c173
-rw-r--r--src/dynarec/dynarec_next.h11
-rw-r--r--[-rwxr-xr-x]src/dynarec/dynarec_private.h0
-rw-r--r--[-rwxr-xr-x]src/dynarec/native_lock.h44
-rw-r--r--src/dynarec/rv64/dynarec_rv64_00.c41
-rw-r--r--src/dynarec/rv64/dynarec_rv64_00_0.c497
-rw-r--r--src/dynarec/rv64/dynarec_rv64_00_1.c297
-rw-r--r--src/dynarec/rv64/dynarec_rv64_00_2.c845
-rw-r--r--src/dynarec/rv64/dynarec_rv64_00_3.c1198
-rw-r--r--src/dynarec/rv64/dynarec_rv64_0f.c1742
-rw-r--r--src/dynarec/rv64/dynarec_rv64_64.c496
-rw-r--r--src/dynarec/rv64/dynarec_rv64_66.c1020
-rw-r--r--src/dynarec/rv64/dynarec_rv64_660f.c2644
-rw-r--r--src/dynarec/rv64/dynarec_rv64_6664.c105
-rw-r--r--src/dynarec/rv64/dynarec_rv64_66f0.c195
-rw-r--r--src/dynarec/rv64/dynarec_rv64_67.c631
-rw-r--r--src/dynarec/rv64/dynarec_rv64_d8.c182
-rw-r--r--src/dynarec/rv64/dynarec_rv64_d9.c426
-rw-r--r--src/dynarec/rv64/dynarec_rv64_db.c303
-rw-r--r--src/dynarec/rv64/dynarec_rv64_dc.c119
-rw-r--r--src/dynarec/rv64/dynarec_rv64_dd.c179
-rw-r--r--src/dynarec/rv64/dynarec_rv64_de.c177
-rw-r--r--src/dynarec/rv64/dynarec_rv64_df.c244
-rw-r--r--src/dynarec/rv64/dynarec_rv64_emit_logic.c478
-rw-r--r--src/dynarec/rv64/dynarec_rv64_emit_math.c1441
-rw-r--r--src/dynarec/rv64/dynarec_rv64_emit_shift.c618
-rw-r--r--src/dynarec/rv64/dynarec_rv64_emit_tests.c349
-rw-r--r--src/dynarec/rv64/dynarec_rv64_f0.c691
-rw-r--r--src/dynarec/rv64/dynarec_rv64_f20f.c377
-rw-r--r--src/dynarec/rv64/dynarec_rv64_f30f.c522
-rw-r--r--src/dynarec/rv64/dynarec_rv64_functions.c564
-rw-r--r--src/dynarec/rv64/dynarec_rv64_functions.h52
-rw-r--r--src/dynarec/rv64/dynarec_rv64_helper.c2174
-rw-r--r--src/dynarec/rv64/dynarec_rv64_helper.h1348
-rw-r--r--src/dynarec/rv64/dynarec_rv64_jmpnext.c19
-rw-r--r--src/dynarec/rv64/dynarec_rv64_pass0.h55
-rw-r--r--src/dynarec/rv64/dynarec_rv64_pass1.h15
-rw-r--r--src/dynarec/rv64/dynarec_rv64_pass2.h18
-rw-r--r--src/dynarec/rv64/dynarec_rv64_pass3.h23
-rw-r--r--src/dynarec/rv64/dynarec_rv64_private.h150
-rw-r--r--src/dynarec/rv64/rv64_emitter.h654
-rw-r--r--src/dynarec/rv64/rv64_epilog.S65
-rw-r--r--src/dynarec/rv64/rv64_lock.S232
-rw-r--r--src/dynarec/rv64/rv64_lock.h60
-rw-r--r--src/dynarec/rv64/rv64_next.S51
-rw-r--r--src/dynarec/rv64/rv64_printer.c1450
-rw-r--r--src/dynarec/rv64/rv64_printer.h8
-rw-r--r--src/dynarec/rv64/rv64_prolog.S66
-rw-r--r--src/elfs/elfdwarf_private.c10
-rw-r--r--[-rwxr-xr-x]src/elfs/elfload_dump.c0
-rw-r--r--[-rwxr-xr-x]src/elfs/elfloader.c332
-rw-r--r--[-rwxr-xr-x]src/elfs/elfloader_private.h6
-rw-r--r--[-rwxr-xr-x]src/elfs/elfparser.c56
-rw-r--r--src/emu/modrm.h37
-rw-r--r--[-rwxr-xr-x]src/emu/x64emu.c182
-rw-r--r--[-rwxr-xr-x]src/emu/x64emu_private.h43
-rw-r--r--[-rwxr-xr-x]src/emu/x64int3.c29
-rw-r--r--[-rwxr-xr-x]src/emu/x64primop.c0
-rw-r--r--[-rwxr-xr-x]src/emu/x64primop.h0
-rw-r--r--[-rwxr-xr-x]src/emu/x64run.c707
-rw-r--r--src/emu/x64run0f.c181
-rw-r--r--src/emu/x64run64.c177
-rw-r--r--src/emu/x64run66.c236
-rw-r--r--src/emu/x64run660f.c351
-rw-r--r--src/emu/x64run6664.c32
-rw-r--r--src/emu/x64run66d9.c9
-rw-r--r--src/emu/x64run66dd.c9
-rw-r--r--src/emu/x64run66f0.c279
-rw-r--r--src/emu/x64run67.c34
-rw-r--r--src/emu/x64run670f.c44
-rw-r--r--src/emu/x64run6764_32.c67
-rw-r--r--src/emu/x64run6766.c31
-rw-r--r--src/emu/x64run67660f.c8
-rw-r--r--src/emu/x64run67_32.c100
-rw-r--r--[-rwxr-xr-x]src/emu/x64run_private.c428
-rw-r--r--[-rwxr-xr-x]src/emu/x64run_private.h117
-rw-r--r--src/emu/x64rund8.c23
-rw-r--r--src/emu/x64rund9.c19
-rw-r--r--src/emu/x64runda.c23
-rw-r--r--src/emu/x64rundb.c25
-rw-r--r--src/emu/x64rundc.c9
-rw-r--r--src/emu/x64rundd.c32
-rw-r--r--src/emu/x64runde.c7
-rw-r--r--src/emu/x64rundf.c22
-rw-r--r--src/emu/x64runf0.c189
-rw-r--r--src/emu/x64runf20f.c41
-rw-r--r--src/emu/x64runf30f.c47
-rw-r--r--[-rwxr-xr-x]src/emu/x64syscall.c46
-rw-r--r--src/emu/x64test.c160
-rw-r--r--[-rwxr-xr-x]src/emu/x64tls.c185
-rw-r--r--[-rwxr-xr-x]src/emu/x64trace.c19
-rwxr-xr-xsrc/emu/x86syscall.c284
-rw-r--r--[-rwxr-xr-x]src/emu/x86zydis.h0
-rw-r--r--[-rwxr-xr-x]src/emu/x87emu_private.c4
-rw-r--r--[-rwxr-xr-x]src/emu/x87emu_private.h6
-rw-r--r--[-rwxr-xr-x]src/include/auxval.h0
-rw-r--r--src/include/bitutils.h10
-rw-r--r--[-rwxr-xr-x]src/include/box64context.h51
-rw-r--r--[-rwxr-xr-x]src/include/box64stack.h9
-rw-r--r--[-rwxr-xr-x]src/include/bridge.h10
-rw-r--r--[-rwxr-xr-x]src/include/callback.h7
-rw-r--r--src/include/complext.h33
-rw-r--r--[-rwxr-xr-x]src/include/cpu_info.h0
-rw-r--r--src/include/custommem.h14
-rw-r--r--[-rwxr-xr-x]src/include/debug.h10
-rw-r--r--[-rwxr-xr-x]src/include/dictionnary.h2
-rw-r--r--[-rwxr-xr-x]src/include/dynablock.h8
-rw-r--r--[-rwxr-xr-x]src/include/dynarec.h3
-rw-r--r--[-rwxr-xr-x]src/include/dynarec_native.h15
-rw-r--r--src/include/dynarec_rv64.h10
-rw-r--r--[-rwxr-xr-x]src/include/elfload_dump.h0
-rw-r--r--[-rwxr-xr-x]src/include/elfloader.h14
-rw-r--r--[-rwxr-xr-x]src/include/fileutils.h4
-rw-r--r--[-rwxr-xr-x]src/include/globalsymbols.h16
-rw-r--r--[-rwxr-xr-x]src/include/gtkclass.h217
-rw-r--r--[-rwxr-xr-x]src/include/khash.h0
-rw-r--r--[-rwxr-xr-x]src/include/librarian.h22
-rw-r--r--[-rwxr-xr-x]src/include/library.h15
-rw-r--r--[-rwxr-xr-x]src/include/myalign.h15
-rw-r--r--[-rwxr-xr-x]src/include/pathcoll.h0
-rw-r--r--src/include/rcfile.h2
-rw-r--r--[-rwxr-xr-x]src/include/regs.h6
-rw-r--r--[-rwxr-xr-x]src/include/sdl1rwops.h2
-rw-r--r--[-rwxr-xr-x]src/include/sdl2rwops.h2
-rw-r--r--[-rwxr-xr-x]src/include/signals.h3
-rw-r--r--src/include/symbols.h7
-rw-r--r--[-rwxr-xr-x]src/include/threads.h12
-rw-r--r--[-rwxr-xr-x]src/include/wine_tools.h4
-rw-r--r--[-rwxr-xr-x]src/include/wrappedlibs.h2
-rw-r--r--[-rwxr-xr-x]src/include/x64emu.h19
-rw-r--r--[-rwxr-xr-x]src/include/x64run.h6
-rw-r--r--[-rwxr-xr-x]src/include/x64tls.h6
-rw-r--r--[-rwxr-xr-x]src/include/x64trace.h5
-rw-r--r--[-rwxr-xr-x]src/librarian/dictionnary.c0
-rw-r--r--[-rwxr-xr-x]src/librarian/globalsymbols.c92
-rw-r--r--[-rwxr-xr-x]src/librarian/librarian.c315
-rw-r--r--[-rwxr-xr-x]src/librarian/librarian_private.h0
-rw-r--r--[-rwxr-xr-x]src/librarian/library.c331
-rw-r--r--[-rwxr-xr-x]src/librarian/library_private.h8
-rw-r--r--src/librarian/symbols.c15
-rw-r--r--[-rwxr-xr-x]src/library_list.h16
-rw-r--r--[-rwxr-xr-x]src/libtools/auxval.c0
-rw-r--r--[-rwxr-xr-x]src/libtools/myalign.c6
-rw-r--r--[-rwxr-xr-x]src/libtools/obstack.c6
-rw-r--r--[-rwxr-xr-x]src/libtools/sdl1rwops.c10
-rw-r--r--[-rwxr-xr-x]src/libtools/sdl2rwops.c41
-rw-r--r--[-rwxr-xr-x]src/libtools/signals.c403
-rw-r--r--[-rwxr-xr-x]src/libtools/threads.c103
-rw-r--r--[-rwxr-xr-x]src/main.c126
-rw-r--r--src/mallochook.c208
-rw-r--r--src/rv64detect.c70
-rw-r--r--src/tools/bitutils.c22
-rw-r--r--[-rwxr-xr-x]src/tools/box64stack.c101
-rw-r--r--[-rwxr-xr-x]src/tools/bridge.c63
-rw-r--r--[-rwxr-xr-x]src/tools/bridge_private.h0
-rw-r--r--[-rwxr-xr-x]src/tools/callback.c110
-rw-r--r--[-rwxr-xr-x]src/tools/fileutils.c0
-rw-r--r--[-rwxr-xr-x]src/tools/gtkclass.c1621
-rw-r--r--src/tools/my_cpuid.c8
-rw-r--r--[-rwxr-xr-x]src/tools/pathcoll.c0
-rw-r--r--src/tools/rcfile.c17
-rw-r--r--[-rwxr-xr-x]src/tools/wine_tools.c4
-rw-r--r--src/wrapped/generated/functions_list.txt4517
-rw-r--r--src/wrapped/generated/wrappedaluredefs.h8
-rw-r--r--src/wrapped/generated/wrappedaluretypes.h17
-rw-r--r--src/wrapped/generated/wrappedalureundefs.h8
-rw-r--r--src/wrapped/generated/wrappedalutdefs.h8
-rw-r--r--src/wrapped/generated/wrappedaluttypes.h17
-rw-r--r--src/wrapped/generated/wrappedalutundefs.h8
-rw-r--r--src/wrapped/generated/wrappedatkbridgedefs.h8
-rw-r--r--src/wrapped/generated/wrappedatkbridgetypes.h17
-rw-r--r--src/wrapped/generated/wrappedatkbridgeundefs.h8
-rw-r--r--src/wrapped/generated/wrappedatkdefs.h8
-rw-r--r--src/wrapped/generated/wrappedatktypes.h23
-rw-r--r--src/wrapped/generated/wrappedatkundefs.h8
-rw-r--r--src/wrapped/generated/wrappedatomicdefs.h8
-rw-r--r--src/wrapped/generated/wrappedatomictypes.h17
-rw-r--r--src/wrapped/generated/wrappedatomicundefs.h8
-rw-r--r--src/wrapped/generated/wrappedatspidefs.h8
-rw-r--r--src/wrapped/generated/wrappedatspitypes.h17
-rw-r--r--src/wrapped/generated/wrappedatspiundefs.h8
-rw-r--r--src/wrapped/generated/wrappedbz2defs.h8
-rw-r--r--src/wrapped/generated/wrappedbz2types.h27
-rw-r--r--src/wrapped/generated/wrappedbz2undefs.h8
-rw-r--r--src/wrapped/generated/wrappedcairodefs.h8
-rw-r--r--src/wrapped/generated/wrappedcairogobjectdefs.h8
-rw-r--r--src/wrapped/generated/wrappedcairogobjecttypes.h17
-rw-r--r--src/wrapped/generated/wrappedcairogobjectundefs.h8
-rw-r--r--src/wrapped/generated/wrappedcairotypes.h17
-rw-r--r--src/wrapped/generated/wrappedcairoundefs.h8
-rw-r--r--src/wrapped/generated/wrappedcrashhandlerdefs.h8
-rw-r--r--src/wrapped/generated/wrappedcrashhandlertypes.h17
-rw-r--r--src/wrapped/generated/wrappedcrashhandlerundefs.h8
-rw-r--r--src/wrapped/generated/wrappedcryptodefs.h8
-rw-r--r--src/wrapped/generated/wrappedcryptotypes.h51
-rw-r--r--src/wrapped/generated/wrappedcryptoundefs.h8
-rw-r--r--src/wrapped/generated/wrappedcurldefs.h8
-rw-r--r--src/wrapped/generated/wrappedcurltypes.h21
-rw-r--r--src/wrapped/generated/wrappedcurlundefs.h8
-rw-r--r--src/wrapped/generated/wrappedd3dadapter9defs.h8
-rw-r--r--src/wrapped/generated/wrappedd3dadapter9types.h21
-rw-r--r--src/wrapped/generated/wrappedd3dadapter9undefs.h8
-rw-r--r--src/wrapped/generated/wrappeddbusdefs.h8
-rw-r--r--src/wrapped/generated/wrappeddbusglib1defs.h8
-rw-r--r--src/wrapped/generated/wrappeddbusglib1types.h28
-rw-r--r--src/wrapped/generated/wrappeddbusglib1undefs.h8
-rw-r--r--src/wrapped/generated/wrappeddbustypes.h45
-rw-r--r--src/wrapped/generated/wrappeddbusundefs.h8
-rw-r--r--src/wrapped/generated/wrappedexpatdefs.h8
-rw-r--r--src/wrapped/generated/wrappedexpattypes.h44
-rw-r--r--src/wrapped/generated/wrappedexpatundefs.h8
-rw-r--r--src/wrapped/generated/wrappedfaudiodefs.h8
-rw-r--r--src/wrapped/generated/wrappedfaudiotypes.h35
-rw-r--r--src/wrapped/generated/wrappedfaudioundefs.h8
-rw-r--r--src/wrapped/generated/wrappedflacdefs.h8
-rw-r--r--src/wrapped/generated/wrappedflactypes.h21
-rw-r--r--src/wrapped/generated/wrappedflacundefs.h8
-rw-r--r--src/wrapped/generated/wrappedfontconfigdefs.h8
-rw-r--r--src/wrapped/generated/wrappedfontconfigtypes.h21
-rw-r--r--src/wrapped/generated/wrappedfontconfigundefs.h8
-rw-r--r--src/wrapped/generated/wrappedfreebl3defs.h8
-rw-r--r--src/wrapped/generated/wrappedfreebl3types.h17
-rw-r--r--src/wrapped/generated/wrappedfreebl3undefs.h8
-rw-r--r--src/wrapped/generated/wrappedfreetypedefs.h8
-rw-r--r--src/wrapped/generated/wrappedfreetypetypes.h25
-rw-r--r--src/wrapped/generated/wrappedfreetypeundefs.h8
-rw-r--r--src/wrapped/generated/wrappedgbmdefs.h8
-rw-r--r--src/wrapped/generated/wrappedgbmtypes.h17
-rw-r--r--src/wrapped/generated/wrappedgbmundefs.h8
-rw-r--r--src/wrapped/generated/wrappedgconf2defs.h8
-rw-r--r--src/wrapped/generated/wrappedgconf2types.h17
-rw-r--r--src/wrapped/generated/wrappedgconf2undefs.h8
-rw-r--r--src/wrapped/generated/wrappedgcryptdefs.h8
-rw-r--r--src/wrapped/generated/wrappedgcrypttypes.h19
-rw-r--r--src/wrapped/generated/wrappedgcryptundefs.h8
-rw-r--r--src/wrapped/generated/wrappedgdk3defs.h8
-rw-r--r--src/wrapped/generated/wrappedgdk3types.h29
-rw-r--r--src/wrapped/generated/wrappedgdk3undefs.h8
-rw-r--r--src/wrapped/generated/wrappedgdkpixbuf2defs.h8
-rw-r--r--src/wrapped/generated/wrappedgdkpixbuf2types.h19
-rw-r--r--src/wrapped/generated/wrappedgdkpixbuf2undefs.h8
-rw-r--r--src/wrapped/generated/wrappedgdkx112defs.h8
-rw-r--r--src/wrapped/generated/wrappedgdkx112types.h29
-rw-r--r--src/wrapped/generated/wrappedgdkx112undefs.h8
-rw-r--r--src/wrapped/generated/wrappedgio2defs.h8
-rw-r--r--src/wrapped/generated/wrappedgio2types.h85
-rw-r--r--src/wrapped/generated/wrappedgio2undefs.h8
-rw-r--r--src/wrapped/generated/wrappedglib2defs.h8
-rw-r--r--src/wrapped/generated/wrappedglib2types.h174
-rw-r--r--src/wrapped/generated/wrappedglib2undefs.h8
-rw-r--r--src/wrapped/generated/wrappedgmodule2defs.h8
-rw-r--r--src/wrapped/generated/wrappedgmodule2types.h17
-rw-r--r--src/wrapped/generated/wrappedgmodule2undefs.h8
-rw-r--r--src/wrapped/generated/wrappedgmpdefs.h8
-rw-r--r--src/wrapped/generated/wrappedgmptypes.h17
-rw-r--r--src/wrapped/generated/wrappedgmpundefs.h8
-rw-r--r--src/wrapped/generated/wrappedgnutlsdefs.h8
-rw-r--r--src/wrapped/generated/wrappedgnutlstypes.h23
-rw-r--r--src/wrapped/generated/wrappedgnutlsundefs.h8
-rw-r--r--src/wrapped/generated/wrappedgobject2defs.h8
-rw-r--r--src/wrapped/generated/wrappedgobject2types.h86
-rw-r--r--src/wrapped/generated/wrappedgobject2undefs.h8
-rw-r--r--src/wrapped/generated/wrappedgssapidefs.h8
-rw-r--r--src/wrapped/generated/wrappedgssapikrb5defs.h8
-rw-r--r--src/wrapped/generated/wrappedgssapikrb5types.h17
-rw-r--r--src/wrapped/generated/wrappedgssapikrb5undefs.h8
-rw-r--r--src/wrapped/generated/wrappedgssapitypes.h17
-rw-r--r--src/wrapped/generated/wrappedgssapiundefs.h8
-rw-r--r--src/wrapped/generated/wrappedgstappdefs.h8
-rw-r--r--src/wrapped/generated/wrappedgstapptypes.h17
-rw-r--r--src/wrapped/generated/wrappedgstappundefs.h8
-rw-r--r--src/wrapped/generated/wrappedgstaudiodefs.h8
-rw-r--r--src/wrapped/generated/wrappedgstaudiotypes.h17
-rw-r--r--src/wrapped/generated/wrappedgstaudioundefs.h8
-rw-r--r--src/wrapped/generated/wrappedgstbasedefs.h8
-rw-r--r--src/wrapped/generated/wrappedgstbasetypes.h17
-rw-r--r--src/wrapped/generated/wrappedgstbaseundefs.h8
-rw-r--r--src/wrapped/generated/wrappedgstgldefs.h8
-rw-r--r--src/wrapped/generated/wrappedgstgltypes.h17
-rw-r--r--src/wrapped/generated/wrappedgstglundefs.h8
-rw-r--r--src/wrapped/generated/wrappedgstreamerdefs.h8
-rw-r--r--src/wrapped/generated/wrappedgstreamertypes.h42
-rw-r--r--src/wrapped/generated/wrappedgstreamerundefs.h8
-rw-r--r--src/wrapped/generated/wrappedgsttagdefs.h8
-rw-r--r--src/wrapped/generated/wrappedgsttagtypes.h17
-rw-r--r--src/wrapped/generated/wrappedgsttagundefs.h8
-rw-r--r--src/wrapped/generated/wrappedgstvideodefs.h8
-rw-r--r--src/wrapped/generated/wrappedgstvideotypes.h17
-rw-r--r--src/wrapped/generated/wrappedgstvideoundefs.h8
-rw-r--r--src/wrapped/generated/wrappedgthread2defs.h8
-rw-r--r--src/wrapped/generated/wrappedgthread2types.h20
-rw-r--r--src/wrapped/generated/wrappedgthread2undefs.h8
-rw-r--r--src/wrapped/generated/wrappedgtk3defs.h8
-rw-r--r--src/wrapped/generated/wrappedgtk3types.h79
-rw-r--r--src/wrapped/generated/wrappedgtk3undefs.h8
-rw-r--r--src/wrapped/generated/wrappedgtkx112defs.h8
-rw-r--r--src/wrapped/generated/wrappedgtkx112types.h102
-rw-r--r--src/wrapped/generated/wrappedgtkx112undefs.h8
-rw-r--r--src/wrapped/generated/wrappedkrb5defs.h8
-rw-r--r--src/wrapped/generated/wrappedkrb5types.h19
-rw-r--r--src/wrapped/generated/wrappedkrb5undefs.h8
-rw-r--r--src/wrapped/generated/wrappedlberdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlbertypes.h17
-rw-r--r--src/wrapped/generated/wrappedlberundefs.h8
-rw-r--r--src/wrapped/generated/wrappedldaprdefs.h8
-rw-r--r--src/wrapped/generated/wrappedldaprtypes.h19
-rw-r--r--src/wrapped/generated/wrappedldaprundefs.h8
-rw-r--r--src/wrapped/generated/wrappedldlinuxdefs.h8
-rw-r--r--src/wrapped/generated/wrappedldlinuxtypes.h19
-rw-r--r--src/wrapped/generated/wrappedldlinuxundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibasounddefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibasoundtypes.h28
-rw-r--r--src/wrapped/generated/wrappedlibasoundundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibcdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibcryptdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibcrypttypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibcryptundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibctypes.h268
-rw-r--r--src/wrapped/generated/wrappedlibcundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibcupsdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibcupstypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibcupsundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibdldefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibdltypes.h36
-rw-r--r--src/wrapped/generated/wrappedlibdlundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibdrmdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibdrmtypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibdrmundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibegldefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibegltypes.h19
-rw-r--r--src/wrapped/generated/wrappedlibeglundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibformdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibformtypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibformundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibformwdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibformwtypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibformwundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibfusedefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibfusetypes.h31
-rw-r--r--src/wrapped/generated/wrappedlibfuseundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibgldefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibgltypes.h30
-rw-r--r--src/wrapped/generated/wrappedlibgludefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibglundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibglutypes.h21
-rw-r--r--src/wrapped/generated/wrappedlibgluundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibglxdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibglxtypes.h20
-rw-r--r--src/wrapped/generated/wrappedlibglxundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibibusdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibibustypes.h33
-rw-r--r--src/wrapped/generated/wrappedlibibusundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibicedefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibicetypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibiceundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibmdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibmtypes.h58
-rw-r--r--src/wrapped/generated/wrappedlibmundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibncurses6defs.h8
-rw-r--r--src/wrapped/generated/wrappedlibncurses6types.h29
-rw-r--r--src/wrapped/generated/wrappedlibncurses6undefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibncursesdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibncursestypes.h27
-rw-r--r--src/wrapped/generated/wrappedlibncursesundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibncursesw6defs.h8
-rw-r--r--src/wrapped/generated/wrappedlibncursesw6types.h27
-rw-r--r--src/wrapped/generated/wrappedlibncursesw6undefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibncurseswdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibncurseswtypes.h29
-rw-r--r--src/wrapped/generated/wrappedlibncurseswundefs.h8
-rw-r--r--src/wrapped/generated/wrappedliboggdefs.h8
-rw-r--r--src/wrapped/generated/wrappedliboggtypes.h17
-rw-r--r--src/wrapped/generated/wrappedliboggundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibpaneldefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibpaneltypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibpanelundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibpcidefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibpcitypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibpciundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibpcredefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibpcretypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibpcreundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibpthreaddefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibpthreadtypes.h113
-rw-r--r--src/wrapped/generated/wrappedlibpthreadundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibresolvdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibresolvtypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibresolvundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibrtdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibrttypes.h19
-rw-r--r--src/wrapped/generated/wrappedlibrtundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibsmdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibsmtypes.h23
-rw-r--r--src/wrapped/generated/wrappedlibsmundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibsndfiledefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibsndfiletypes.h21
-rw-r--r--src/wrapped/generated/wrappedlibsndfileundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibssldefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibssltypes.h34
-rw-r--r--src/wrapped/generated/wrappedlibsslundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibtinfo6defs.h8
-rw-r--r--src/wrapped/generated/wrappedlibtinfo6types.h19
-rw-r--r--src/wrapped/generated/wrappedlibtinfo6undefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibtinfodefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibtinfotypes.h19
-rw-r--r--src/wrapped/generated/wrappedlibtinfoundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibusb1defs.h8
-rw-r--r--src/wrapped/generated/wrappedlibusb1types.h24
-rw-r--r--src/wrapped/generated/wrappedlibusb1undefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibuuiddefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibuuidtypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibuuidundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibvadefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibvadrmdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibvadrmtypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibvadrmundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibvatypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibvaundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibvawaylanddefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibvawaylandtypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibvawaylandundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibvax11defs.h8
-rw-r--r--src/wrapped/generated/wrappedlibvax11types.h17
-rw-r--r--src/wrapped/generated/wrappedlibvax11undefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibvdpaudefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibvdpautypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibvdpauundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibvorbisdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibvorbistypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibvorbisundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibx11defs.h8
-rw-r--r--src/wrapped/generated/wrappedlibx11types.h61
-rw-r--r--src/wrapped/generated/wrappedlibx11undefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibx11xcbdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibx11xcbtypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibx11xcbundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxaudefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxautypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxauundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbdri2defs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbdri2types.h17
-rw-r--r--src/wrapped/generated/wrappedlibxcbdri2undefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbdri3defs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbdri3types.h17
-rw-r--r--src/wrapped/generated/wrappedlibxcbdri3undefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbglxdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbglxtypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxcbglxundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbicccmdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbicccmtypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxcbicccmundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbimagedefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbimagetypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxcbimageundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbkeysymsdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbkeysymstypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxcbkeysymsundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbpresentdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbpresenttypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxcbpresentundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbrandrdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbrandrtypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxcbrandrundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbrenderdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbrendertypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxcbrenderundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbrenderutildefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbrenderutiltypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxcbrenderutilundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbshapedefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbshapetypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxcbshapeundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbshmdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbshmtypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxcbshmundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbsyncdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbsynctypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxcbsyncundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbtypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxcbundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbutildefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbutiltypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxcbutilundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbxfixesdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbxfixestypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxcbxfixesundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbxineramadefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbxineramatypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxcbxineramaundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbxkbdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbxkbtypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxcbxkbundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbxtestdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcbxtesttypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxcbxtestundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcompositedefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcompositetypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxcompositeundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcursordefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxcursortypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxcursorundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxdamagedefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxdamagetypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxdamageundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxdmcpdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxdmcptypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxdmcpundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxextdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxexttypes.h27
-rw-r--r--src/wrapped/generated/wrappedlibxextundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxfixesdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxfixestypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxfixesundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxftdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxfttypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxftundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxidefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxitypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxiundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxmudefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxmutypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxmuundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxpmdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxpmtypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxpmundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxpresentdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxpresenttypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxpresentundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxrandrdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxrandrtypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxrandrundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxrenderdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxrendertypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxrenderundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxssdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxsstypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxssundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxtdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxtstdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxtsttypes.h20
-rw-r--r--src/wrapped/generated/wrappedlibxtstundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxttypes.h23
-rw-r--r--src/wrapped/generated/wrappedlibxtundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxxf86vmdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibxxf86vmtypes.h17
-rw-r--r--src/wrapped/generated/wrappedlibxxf86vmundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibzdefs.h8
-rw-r--r--src/wrapped/generated/wrappedlibztypes.h31
-rw-r--r--src/wrapped/generated/wrappedlibzundefs.h8
-rw-r--r--src/wrapped/generated/wrappedlzmadefs.h8
-rw-r--r--src/wrapped/generated/wrappedlzmatypes.h37
-rw-r--r--src/wrapped/generated/wrappedlzmaundefs.h8
-rw-r--r--src/wrapped/generated/wrappedmpg123defs.h8
-rw-r--r--src/wrapped/generated/wrappedmpg123types.h21
-rw-r--r--src/wrapped/generated/wrappedmpg123undefs.h8
-rw-r--r--src/wrapped/generated/wrappednotifydefs.h8
-rw-r--r--src/wrapped/generated/wrappednotifytypes.h17
-rw-r--r--src/wrapped/generated/wrappednotifyundefs.h8
-rw-r--r--src/wrapped/generated/wrappednsldefs.h8
-rw-r--r--src/wrapped/generated/wrappednsltypes.h17
-rw-r--r--src/wrapped/generated/wrappednslundefs.h8
-rw-r--r--src/wrapped/generated/wrappednspr4defs.h8
-rw-r--r--src/wrapped/generated/wrappednspr4types.h17
-rw-r--r--src/wrapped/generated/wrappednspr4undefs.h8
-rw-r--r--src/wrapped/generated/wrappednss3defs.h8
-rw-r--r--src/wrapped/generated/wrappednss3types.h23
-rw-r--r--src/wrapped/generated/wrappednss3undefs.h8
-rw-r--r--src/wrapped/generated/wrappednssutil3defs.h8
-rw-r--r--src/wrapped/generated/wrappednssutil3types.h17
-rw-r--r--src/wrapped/generated/wrappednssutil3undefs.h8
-rw-r--r--src/wrapped/generated/wrappedopenaldefs.h8
-rw-r--r--src/wrapped/generated/wrappedopenaltypes.h25
-rw-r--r--src/wrapped/generated/wrappedopenalundefs.h8
-rw-r--r--src/wrapped/generated/wrappedpangocairodefs.h8
-rw-r--r--src/wrapped/generated/wrappedpangocairotypes.h17
-rw-r--r--src/wrapped/generated/wrappedpangocairoundefs.h8
-rw-r--r--src/wrapped/generated/wrappedpangodefs.h8
-rw-r--r--src/wrapped/generated/wrappedpangoft2defs.h8
-rw-r--r--src/wrapped/generated/wrappedpangoft2types.h17
-rw-r--r--src/wrapped/generated/wrappedpangoft2undefs.h8
-rw-r--r--src/wrapped/generated/wrappedpangotypes.h19
-rw-r--r--src/wrapped/generated/wrappedpangoundefs.h8
-rw-r--r--src/wrapped/generated/wrappedplc4defs.h8
-rw-r--r--src/wrapped/generated/wrappedplc4types.h17
-rw-r--r--src/wrapped/generated/wrappedplc4undefs.h8
-rw-r--r--src/wrapped/generated/wrappedplds4defs.h8
-rw-r--r--src/wrapped/generated/wrappedplds4types.h17
-rw-r--r--src/wrapped/generated/wrappedplds4undefs.h8
-rw-r--r--src/wrapped/generated/wrappedpng16defs.h8
-rw-r--r--src/wrapped/generated/wrappedpng16types.h31
-rw-r--r--src/wrapped/generated/wrappedpng16undefs.h8
-rw-r--r--src/wrapped/generated/wrappedpulsedefs.h8
-rw-r--r--src/wrapped/generated/wrappedpulsesimpledefs.h8
-rw-r--r--src/wrapped/generated/wrappedpulsesimpletypes.h17
-rw-r--r--src/wrapped/generated/wrappedpulsesimpleundefs.h8
-rw-r--r--src/wrapped/generated/wrappedpulsetypes.h120
-rw-r--r--src/wrapped/generated/wrappedpulseundefs.h8
-rw-r--r--src/wrapped/generated/wrappedsdl1defs.h8
-rw-r--r--src/wrapped/generated/wrappedsdl1imagedefs.h8
-rw-r--r--src/wrapped/generated/wrappedsdl1imagetypes.h37
-rw-r--r--src/wrapped/generated/wrappedsdl1imageundefs.h8
-rw-r--r--src/wrapped/generated/wrappedsdl1mixerdefs.h8
-rw-r--r--src/wrapped/generated/wrappedsdl1mixertypes.h33
-rw-r--r--src/wrapped/generated/wrappedsdl1mixerundefs.h8
-rw-r--r--src/wrapped/generated/wrappedsdl1netdefs.h8
-rw-r--r--src/wrapped/generated/wrappedsdl1nettypes.h17
-rw-r--r--src/wrapped/generated/wrappedsdl1netundefs.h8
-rw-r--r--src/wrapped/generated/wrappedsdl1sounddefs.h8
-rw-r--r--src/wrapped/generated/wrappedsdl1soundtypes.h19
-rw-r--r--src/wrapped/generated/wrappedsdl1soundundefs.h8
-rw-r--r--src/wrapped/generated/wrappedsdl1ttfdefs.h8
-rw-r--r--src/wrapped/generated/wrappedsdl1ttftypes.h21
-rw-r--r--src/wrapped/generated/wrappedsdl1ttfundefs.h8
-rw-r--r--src/wrapped/generated/wrappedsdl1types.h74
-rw-r--r--src/wrapped/generated/wrappedsdl1undefs.h8
-rw-r--r--src/wrapped/generated/wrappedsdl2defs.h9
-rw-r--r--src/wrapped/generated/wrappedsdl2imagedefs.h8
-rw-r--r--src/wrapped/generated/wrappedsdl2imagetypes.h43
-rw-r--r--src/wrapped/generated/wrappedsdl2imageundefs.h8
-rw-r--r--src/wrapped/generated/wrappedsdl2mixerdefs.h8
-rw-r--r--src/wrapped/generated/wrappedsdl2mixertypes.h34
-rw-r--r--src/wrapped/generated/wrappedsdl2mixerundefs.h8
-rw-r--r--src/wrapped/generated/wrappedsdl2netdefs.h8
-rw-r--r--src/wrapped/generated/wrappedsdl2nettypes.h17
-rw-r--r--src/wrapped/generated/wrappedsdl2netundefs.h8
-rw-r--r--src/wrapped/generated/wrappedsdl2ttfdefs.h8
-rw-r--r--src/wrapped/generated/wrappedsdl2ttftypes.h21
-rw-r--r--src/wrapped/generated/wrappedsdl2ttfundefs.h8
-rw-r--r--src/wrapped/generated/wrappedsdl2types.h134
-rw-r--r--src/wrapped/generated/wrappedsdl2undefs.h9
-rw-r--r--src/wrapped/generated/wrappedsecret1defs.h8
-rw-r--r--src/wrapped/generated/wrappedsecret1types.h17
-rw-r--r--src/wrapped/generated/wrappedsecret1undefs.h8
-rw-r--r--src/wrapped/generated/wrappedselinuxdefs.h8
-rw-r--r--src/wrapped/generated/wrappedselinuxtypes.h17
-rw-r--r--src/wrapped/generated/wrappedselinuxundefs.h8
-rw-r--r--src/wrapped/generated/wrappedsmime3defs.h8
-rw-r--r--src/wrapped/generated/wrappedsmime3types.h27
-rw-r--r--src/wrapped/generated/wrappedsmime3undefs.h8
-rw-r--r--src/wrapped/generated/wrappedsmpeg2defs.h8
-rw-r--r--src/wrapped/generated/wrappedsmpeg2types.h21
-rw-r--r--src/wrapped/generated/wrappedsmpeg2undefs.h8
-rw-r--r--src/wrapped/generated/wrappedsmpegdefs.h8
-rw-r--r--src/wrapped/generated/wrappedsmpegtypes.h21
-rw-r--r--src/wrapped/generated/wrappedsmpegundefs.h8
-rw-r--r--src/wrapped/generated/wrappedsoftokn3defs.h8
-rw-r--r--src/wrapped/generated/wrappedsoftokn3types.h17
-rw-r--r--src/wrapped/generated/wrappedsoftokn3undefs.h8
-rw-r--r--src/wrapped/generated/wrappedssl3defs.h8
-rw-r--r--src/wrapped/generated/wrappedssl3types.h17
-rw-r--r--src/wrapped/generated/wrappedssl3undefs.h8
-rw-r--r--src/wrapped/generated/wrappedtbbmallocdefs.h8
-rw-r--r--src/wrapped/generated/wrappedtbbmallocproxydefs.h8
-rw-r--r--src/wrapped/generated/wrappedtbbmallocproxytypes.h37
-rw-r--r--src/wrapped/generated/wrappedtbbmallocproxyundefs.h8
-rw-r--r--src/wrapped/generated/wrappedtbbmalloctypes.h34
-rw-r--r--src/wrapped/generated/wrappedtbbmallocundefs.h8
-rw-r--r--src/wrapped/generated/wrappedtcmallocminimaldefs.h8
-rw-r--r--src/wrapped/generated/wrappedtcmallocminimaltypes.h25
-rw-r--r--src/wrapped/generated/wrappedtcmallocminimalundefs.h8
-rw-r--r--src/wrapped/generated/wrappedudev0defs.h8
-rw-r--r--src/wrapped/generated/wrappedudev0types.h19
-rw-r--r--src/wrapped/generated/wrappedudev0undefs.h8
-rw-r--r--src/wrapped/generated/wrappedudev1defs.h8
-rw-r--r--src/wrapped/generated/wrappedudev1types.h19
-rw-r--r--src/wrapped/generated/wrappedudev1undefs.h8
-rw-r--r--src/wrapped/generated/wrappedunwinddefs.h8
-rw-r--r--src/wrapped/generated/wrappedunwindtypes.h24
-rw-r--r--src/wrapped/generated/wrappedunwindundefs.h8
-rw-r--r--src/wrapped/generated/wrappedutildefs.h8
-rw-r--r--src/wrapped/generated/wrappedutiltypes.h19
-rw-r--r--src/wrapped/generated/wrappedutilundefs.h8
-rw-r--r--src/wrapped/generated/wrappedvorbisfiledefs.h8
-rw-r--r--src/wrapped/generated/wrappedvorbisfiletypes.h20
-rw-r--r--src/wrapped/generated/wrappedvorbisfileundefs.h8
-rw-r--r--src/wrapped/generated/wrappedvulkandefs.h8
-rw-r--r--src/wrapped/generated/wrappedvulkantypes.h135
-rw-r--r--src/wrapped/generated/wrappedvulkanundefs.h8
-rw-r--r--src/wrapped/generated/wrappedwaylandclientdefs.h8
-rw-r--r--src/wrapped/generated/wrappedwaylandclienttypes.h17
-rw-r--r--src/wrapped/generated/wrappedwaylandclientundefs.h8
-rw-r--r--src/wrapped/generated/wrappedwaylandcursordefs.h8
-rw-r--r--src/wrapped/generated/wrappedwaylandcursortypes.h17
-rw-r--r--src/wrapped/generated/wrappedwaylandcursorundefs.h8
-rw-r--r--src/wrapped/generated/wrappedwaylandegldefs.h8
-rw-r--r--src/wrapped/generated/wrappedwaylandegltypes.h17
-rw-r--r--src/wrapped/generated/wrappedwaylandeglundefs.h8
-rw-r--r--src/wrapped/generated/wrappedxineramadefs.h8
-rw-r--r--src/wrapped/generated/wrappedxineramatypes.h17
-rw-r--r--src/wrapped/generated/wrappedxineramaundefs.h8
-rw-r--r--src/wrapped/generated/wrappedxkbcommondefs.h8
-rw-r--r--src/wrapped/generated/wrappedxkbcommontypes.h17
-rw-r--r--src/wrapped/generated/wrappedxkbcommonundefs.h8
-rw-r--r--src/wrapped/generated/wrappedxkbcommonx11defs.h8
-rw-r--r--src/wrapped/generated/wrappedxkbcommonx11types.h17
-rw-r--r--src/wrapped/generated/wrappedxkbcommonx11undefs.h8
-rw-r--r--src/wrapped/generated/wrappedxml2defs.h8
-rw-r--r--src/wrapped/generated/wrappedxml2types.h60
-rw-r--r--src/wrapped/generated/wrappedxml2undefs.h8
-rw-r--r--src/wrapped/generated/wrappedxshmfencedefs.h8
-rw-r--r--src/wrapped/generated/wrappedxshmfencetypes.h17
-rw-r--r--src/wrapped/generated/wrappedxshmfenceundefs.h8
-rw-r--r--src/wrapped/generated/wrappedxsltdefs.h8
-rw-r--r--src/wrapped/generated/wrappedxslttypes.h21
-rw-r--r--src/wrapped/generated/wrappedxsltundefs.h8
-rw-r--r--src/wrapped/generated/wrapper.c6224
-rw-r--r--src/wrapped/generated/wrapper.h2421
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedalure.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedalure_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedalut.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedalut_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedatk.c33
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedatk_private.h260
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedatkbridge.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedatkbridge_private.h0
-rw-r--r--src/wrapped/wrappedatomic_private.h8
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedatspi.c78
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedatspi_private.h46
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedbz2.c4
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedbz2_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedcairo.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedcairo_private.h250
-rw-r--r--src/wrapped/wrappedcairogobject_private.h66
-rw-r--r--src/wrapped/wrappedcap.c18
-rw-r--r--src/wrapped/wrappedcap_private.h62
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedcrashhandler.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedcrashhandler_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedcrypto.c292
-rw-r--r--src/wrapped/wrappedcrypto3.c466
-rw-r--r--src/wrapped/wrappedcrypto3_private.h3893
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedcrypto_private.h128
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedcurl.c22
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedcurl_private.h0
-rw-r--r--src/wrapped/wrappedd3dadapter9.c10
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappeddbus.c144
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappeddbus_private.h24
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappeddbusglib1.c48
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappeddbusglib1_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedexpat.c188
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedexpat_private.h2
-rw-r--r--src/wrapped/wrappedfaudio.c120
-rw-r--r--src/wrapped/wrappedfaudio_private.h14
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedflac.c118
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedflac_private.h164
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedfontconfig.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedfontconfig_private.h144
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedfreetype.c86
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedfreetype_private.h55
-rw-r--r--src/wrapped/wrappedgconf2.c67
-rw-r--r--src/wrapped/wrappedgconf2_private.h208
-rw-r--r--src/wrapped/wrappedgcrypt_private.h2
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedgdk3.c67
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedgdk3_private.h105
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedgdkpixbuf2.c8
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedgdkpixbuf2_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedgdkx112.c14
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedgdkx112_private.h164
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedgio2.c163
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedgio2_private.h1562
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedglib2.c253
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedglib2_private.h558
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedgmodule2.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedgmodule2_private.h2
-rw-r--r--src/wrapped/wrappedgmp.c138
-rw-r--r--src/wrapped/wrappedgmp_private.h100
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedgnutls.c24
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedgnutls_private.h7
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedgobject2.c164
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedgobject2_private.h122
-rw-r--r--src/wrapped/wrappedgomp.c18
-rw-r--r--src/wrapped/wrappedgomp_private.h477
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedgssapi.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedgssapi_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedgssapikrb5.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedgssapikrb5_private.h0
-rw-r--r--src/wrapped/wrappedgstapp_private.h2
-rw-r--r--src/wrapped/wrappedgstaudio_private.h112
-rw-r--r--src/wrapped/wrappedgstbase_private.h144
-rw-r--r--src/wrapped/wrappedgstgl_private.h106
-rw-r--r--src/wrapped/wrappedgstreamer.c142
-rw-r--r--src/wrapped/wrappedgstreamer_private.h930
-rw-r--r--src/wrapped/wrappedgstvideo_private.h242
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedgthread2.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedgthread2_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedgtk3.c180
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedgtk3_private.h1323
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedgtkx112.c256
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedgtkx112_private.h1222
-rw-r--r--src/wrapped/wrappedicui18n67.c29
-rw-r--r--src/wrapped/wrappedicui18n67_private.h100
-rw-r--r--src/wrapped/wrappedicui18n72.c29
-rw-r--r--src/wrapped/wrappedicui18n72_private.h103
-rw-r--r--src/wrapped/wrappedicuuc67.c28
-rw-r--r--src/wrapped/wrappedicuuc67_private.h86
-rw-r--r--src/wrapped/wrappedicuuc72.c28
-rw-r--r--src/wrapped/wrappedicuuc72_private.h86
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedkrb5.c8
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedkrb5_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlber.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlber_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedldapr.c8
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedldapr_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedldlinux.c14
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedldlinux_private.h2
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlib_init.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibasound.c35
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibasound_private.h9
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibc.c377
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibc_private.h271
-rw-r--r--src/wrapped/wrappedlibcmusl.c35
-rw-r--r--src/wrapped/wrappedlibcmusl_private.h4
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibcrypt.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibcrypt_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibcups.c49
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibcups_private.h34
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibdl.c207
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibdl_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibdrm.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibdrm_private.h18
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibegl.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibegl_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibfuse.c294
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibfuse_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibgl.c12
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibgl_private.h5656
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibglu.c6
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibglu_private.h0
-rw-r--r--src/wrapped/wrappedlibharfbuzz.c1217
-rw-r--r--src/wrapped/wrappedlibharfbuzz_private.h443
-rw-r--r--src/wrapped/wrappedlibibus.c2
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibice.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibice_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibm.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibm_private.h83
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibncurses.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibncurses6.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibncurses6_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibncurses_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibncursesw.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibncursesw6.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibncursesw6_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibncursesw_private.h0
-rw-r--r--src/wrapped/wrappedlibnuma.c25
-rw-r--r--src/wrapped/wrappedlibnuma_private.h107
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibogg.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibogg_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibpanel.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibpanel_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibpcre.c2
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibpcre_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibpthread.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibpthread_private.h119
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibresolv_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibrt.c2
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibrt_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibsm.c10
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibsm_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibsndfile.c10
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibsndfile_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibssl.c203
-rw-r--r--src/wrapped/wrappedlibssl3.c367
-rw-r--r--src/wrapped/wrappedlibssl3_private.h605
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibssl_private.h57
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibtinfo.c2
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibtinfo6.c2
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibtinfo6_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibtinfo_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibusb1.c6
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibusb1_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibuuid.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibuuid_private.h0
-rw-r--r--src/wrapped/wrappedlibva.c69
-rw-r--r--src/wrapped/wrappedlibva_private.h4
-rw-r--r--src/wrapped/wrappedlibvdpau.c24
-rw-r--r--src/wrapped/wrappedlibvdpau_private.h2
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibvorbis.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibvorbis_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibx11.c62
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibx11_private.h992
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxau.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxau_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxcb.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxcb_private.h8
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxcbdri2.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxcbdri2_private.h2
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxcbdri3.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxcbdri3_private.h2
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxcbimage.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxcbimage_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxcbkeysyms.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxcbkeysyms_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxcbrandr.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxcbrandr_private.h26
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxcbshape.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxcbshape_private.h10
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxcbshm.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxcbshm_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxcbxfixes.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxcbxfixes_private.h12
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxcbxtest.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxcbxtest_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxcomposite.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxcomposite_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxcursor.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxcursor_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxdamage.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxdamage_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxdmcp.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxdmcp_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxext.c317
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxext_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxfixes.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxfixes_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxft.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxft_private.h16
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxi.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxi_private.h4
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxmu.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxmu_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxpm.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxpm_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxrandr.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxrandr_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxrender.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxrender_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxss.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxss_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxt.c6
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxt_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxtst.c2
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxtst_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxxf86vm.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibxxf86vm_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlibz.c71
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlzma.c148
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedlzma_private.h94
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedmpg123.c11
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedmpg123_private.h114
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappednsl.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappednsl_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappednspr4.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappednspr4_private.h318
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappednss3.c33
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappednss3_private.h1054
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappednssutil3.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappednssutil3_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedopenal.c12
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedopenal_private.h26
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedpango.c6
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedpango_private.h170
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedpangocairo.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedpangocairo_private.h6
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedpangoft2.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedpangoft2_private.h2
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedplc4.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedplc4_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedplds4.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedplds4_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedpng16.c22
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedpng16_private.h1
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedpulse.c96
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedpulse_private.h48
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedpulsesimple.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedpulsesimple_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsdl1.c8
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsdl1_private.h56
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsdl1image.c2
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsdl1image_private.h6
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsdl1mixer.c10
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsdl1mixer_private.h20
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsdl1net.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsdl1net_private.h2
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsdl1sound.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsdl1sound_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsdl1ttf.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsdl1ttf_private.h10
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsdl2.c22
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsdl2_private.h174
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsdl2image.c2
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsdl2image_private.h8
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsdl2mixer.c10
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsdl2mixer_private.h14
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsdl2net.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsdl2net_private.h2
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsdl2ttf.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsdl2ttf_private.h12
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsecret1.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsecret1_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedselinux.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedselinux_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsmime3.c54
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsmime3_private.h2
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsmpeg.c2
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsmpeg2.c2
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsmpeg2_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedsmpeg_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedssl3.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedssl3_private.h0
-rw-r--r--src/wrapped/wrappedtbbbind.c54
-rw-r--r--src/wrapped/wrappedtbbbind_private.h14
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedtcmallocminimal.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedtcmallocminimal_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedudev0.c4
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedudev0_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedudev1.c4
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedudev1_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedutil.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedvorbisfile.c10
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedvorbisfile_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedvulkan.c65
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedvulkan_private.h28
-rw-r--r--src/wrapped/wrappedwaylandclient_private.h26
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedxinerama.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedxinerama_private.h0
-rw-r--r--src/wrapped/wrappedxkbcommon_private.h4
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedxkbcommonx11.c0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedxkbcommonx11_private.h0
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedxml2.c561
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedxml2_private.h80
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedxslt.c76
-rw-r--r--[-rwxr-xr-x]src/wrapped/wrappedxslt_private.h8
-rw-r--r--system/box64.box64rc30
-rw-r--r--[-rwxr-xr-x]system/box64.conf.cmake0
-rw-r--r--[-rwxr-xr-x]tests/benchfloat.c0
-rw-r--r--tests/ref17.txt14
-rw-r--r--tests/ref22.txt1354
-rw-r--r--[-rwxr-xr-x]tests/test05.c0
-rw-r--r--[-rwxr-xr-x]tests/test08.c0
-rw-r--r--[-rwxr-xr-x]tests/test09.c7
-rw-r--r--[-rwxr-xr-x]tests/test12.c0
-rw-r--r--[-rwxr-xr-x]tests/test14.c0
-rw-r--r--tests/test17.c50
-rw-r--r--tests/test18.c1
-rw-r--r--tests/test22.c101
-rw-r--r--wrapperhelper/CMakeLists.txt7
-rw-r--r--wrapperhelper/README.md99
-rw-r--r--wrapperhelper/ast.h189
-rw-r--r--wrapperhelper/gen.cpp1059
-rw-r--r--wrapperhelper/gen.h144
-rw-r--r--wrapperhelper/main.cpp69
-rw-r--r--wrapperhelper/utils.h33
1136 files changed, 59497 insertions, 38119 deletions
diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml
deleted file mode 100644
index 314a011..0000000
--- a/.github/FUNDING.yml
+++ /dev/null
@@ -1,12 +0,0 @@
-# These are supported funding model platforms
-
-github: ptitSeb
-patreon: # Replace with a single Patreon username
-open_collective: # Replace with a single Open Collective username
-ko_fi: # Replace with a single Ko-fi username
-tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
-community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
-liberapay: # Replace with a single Liberapay username
-issuehunt: # Replace with a single IssueHunt username
-otechie: # Replace with a single Otechie username
-custom: paypal.me/0ptitSeb
diff --git a/.github/workflows/manual.yml b/.github/workflows/manual.yml
deleted file mode 100644
index 839f33b..0000000
--- a/.github/workflows/manual.yml
+++ /dev/null
@@ -1,95 +0,0 @@
-### Manual build Box64 with Github Action
-name: Custom build Box64
-
-on:
- workflow_dispatch:
- inputs:
- platform:
- description: 'Target platform name'
- required: true
- default: 'GENERIC_ARM'
- type: choice
- options:
- - X64
- - GENERIC_ARM
- - PHYTIUM
- - RK3326
- - RK3399
- - RK3588
- - RPI4ARM64
- - SD845
- - TEGRAX1
- build_type:
- description: 'Build type'
- required: true
- default: 'RelWithDebInfo'
- type: choice
- options:
- - RelWithDebInfo
- - Release
- - Debug
- - MinSizeRel
- dynarec:
- description: 'Enable dynarec'
- required: false
- default: 'true'
- type: boolean
- trace:
- description: 'Enable trace'
- required: false
- default: 'false'
- type: boolean
-
-jobs:
- build:
- runs-on: ubuntu-latest
- steps:
- - name: "Checkout Box64 Repository"
- uses: actions/checkout@v2
-
- - name: "Environment preparation"
- run: |
- sudo apt-get update
- if [[ ${{ github.event.inputs.platform }} != 'X64' && ${{ github.event.inputs.platform }} != 'GENERIC_ARM' ]]; then
- echo "BOX64_PLATFORM_MARCRO=-D${{ github.event.inputs.platform }}=1" >> $GITHUB_ENV
- echo "BOX64_COMPILER=aarch64-linux-gnu-gcc" >> $GITHUB_ENV
- sudo apt-get -y install git gcc-aarch64-linux-gnu cmake make python3
- else
- if [[ ${{ github.event.inputs.platform }} == 'X64' ]]; then
- echo "BOX64_PLATFORM_MARCRO=-DLD80BITS=1 -DNOALIGN=1" >> $GITHUB_ENV
- echo "BOX64_COMPILER=gcc" >> $GITHUB_ENV
- sudo apt-get -y install git cmake make python3
- else
- echo BOX64_PLATFORM_MARCRO="-DARM_DYNAREC=ON" >> $GITHUB_ENV
- echo "BOX64_COMPILER=aarch64-linux-gnu-gcc" >> $GITHUB_ENV
- sudo apt-get -y install git gcc-aarch64-linux-gnu cmake make python3
- fi
- fi
-
- - name: "Display Build info"
- run: |
- echo "CMake Platform Macro: ${{ env.BOX64_PLATFORM_MARCRO }}"
- echo "CMake C Compiler: ${{ env.BOX64_COMPILER }}"
- echo "Build type: ${{ github.event.inputs.build_type }}"
- echo "Dynarec Enabled: ${{ github.event.inputs.dynarec }}"
- echo "Trace Enabled: ${{ github.event.inputs.trace }}"
-
- - name: "Build Box64"
- run: |
- mkdir build
- cd build
- cmake .. -DCMAKE_C_COMPILER=${{ env.BOX64_COMPILER }} ${{ env.BOX64_PLATFORM_MARCRO }}\
- -DCMAKE_BUILD_TYPE=${{ github.event.inputs.build_type }}\
- -DARM_DYNAREC:BOOL=${{ github.event.inputs.dynarec }}\
- -DHAVE_TRACE:BOOL=${{ github.event.inputs.trace }}\
- -DCMAKE_VERBOSE_MAKEFILE:BOOL=ON
- make -j$(nproc) VERBOSE=1
-
- - name: "Upload Artifact"
- uses: actions/upload-artifact@v2
- with:
- name: box64-${{ github.event.inputs.platform }}-${{ github.event.inputs.build_type }}
- path: build/box64
-
-
-
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml
deleted file mode 100644
index 7fe9584..0000000
--- a/.github/workflows/release.yml
+++ /dev/null
@@ -1,104 +0,0 @@
-### Auto build Box64 and release its binary with Github Action
-name: Build and Release Box64
-
-on:
- workflow_dispatch:
- release:
- push:
- paths:
- - "**/*.c"
- - "**/*.h"
- - "**/*.S"
- - "**/*.py"
- - "CMakeLists.txt"
- - "**/*.yml"
- pull_request:
- types: [assigned, opened, synchronize, reopened]
- paths:
- - "**/*.c"
- - "**/*.h"
- - "**/*.S"
- - "**/*.py"
- - "CMakeLists.txt"
- - "**/*.yml"
-
-jobs:
- build:
- strategy:
- fail-fast: false
- matrix:
- platform: [X64, OTHER_ARM, RISCV, RPI4ARM64, RK3326, RK3399, RK3588, PHYTIUM, SD845]
- type: [Release, Trace]
- os: [ubuntu-latest]
- include:
- - platform: TEGRAX1
- type: Release
- os: ubuntu-20.04
- - platform: TEGRAX1
- type: Trace
- os: ubuntu-20.04
-
- runs-on: ${{ matrix.os }}
- steps:
- - name: "Checkout Box64 Repository"
- uses: actions/checkout@v3
-
- - name: "Environment preparation"
- run: |
- sudo apt-get update
- if [[ ${{ matrix.platform }} != 'X64' && ${{ matrix.platform }} != 'OTHER_ARM' && ${{ matrix.platform }} != 'RISCV' ]]; then
- echo "BOX64_PLATFORM_MARCRO=-D${{ matrix.platform }}=1" >> $GITHUB_ENV
- echo "BOX64_COMPILER=aarch64-linux-gnu-gcc" >> $GITHUB_ENV
- sudo apt-get -y install git gcc-aarch64-linux-gnu cmake make python3
- else
- if [[ ${{ matrix.platform }} == 'X64' ]]; then
- echo "BOX64_PLATFORM_MARCRO=-DLD80BITS=1 -DNOALIGN=1" >> $GITHUB_ENV
- echo "BOX64_COMPILER=gcc" >> $GITHUB_ENV
- sudo apt-get -y install git cmake make python3
- elif [[ ${{ matrix.platform }} == 'RISCV' ]]; then
- echo BOX64_PLATFORM_MARCRO="-DRV64=ON" >> $GITHUB_ENV
- echo "BOX64_COMPILER=riscv64-linux-gnu-gcc" >> $GITHUB_ENV
- sudo apt-get -y install git gcc-riscv64-linux-gnu cmake make python3
- else
- echo BOX64_PLATFORM_MARCRO="-DARM_DYNAREC=ON" >> $GITHUB_ENV
- echo "BOX64_COMPILER=aarch64-linux-gnu-gcc" >> $GITHUB_ENV
- sudo apt-get -y install git gcc-aarch64-linux-gnu cmake make python3
- fi
- fi
- if [[ ${{ matrix.type }} == 'Release' ]]; then
- echo BOX64_BUILD_TYPE=Release >> $GITHUB_ENV
- echo BOX64_HAVE_TRACE=0 >> $GITHUB_ENV
- else
- echo BOX64_BUILD_TYPE=RelWithDebInfo >> $GITHUB_ENV
- echo BOX64_HAVE_TRACE=1 >> $GITHUB_ENV
- fi
-
- - name: "Display Build info"
- run: |
- echo "CMake Platform Macro: ${{ env.BOX64_PLATFORM_MARCRO }}"
- echo "CMake C Compiler: ${{ env.BOX64_COMPILER }}"
- echo "Build type: ${{ env.BOX64_BUILD_TYPE }}"
- echo "Trace Enabled: ${{ env.BOX64_HAVE_TRACE }}"
-
- - name: "Build Box64"
- run: |
- mkdir build
- cd build
- cmake .. -DCMAKE_C_COMPILER=${{ env.BOX64_COMPILER }}\
- ${{ env.BOX64_PLATFORM_MARCRO }}\
- -DCMAKE_BUILD_TYPE=${{ env.BOX64_BUILD_TYPE }}\
- -DHAVE_TRACE=${{ env.BOX64_HAVE_TRACE }}\
- -DCMAKE_VERBOSE_MAKEFILE:BOOL=ON
- make -j$(nproc) VERBOSE=1
-
- - name: "Test Box64"
- if: ${{ matrix.platform == 'X64' }}
- run: |
- cd build
- ctest -j$(nproc)
-
- - name: "Upload Artifact"
- uses: actions/upload-artifact@v3
- with:
- name: box64-${{ matrix.platform }}-${{ matrix.type }}
- path: build/box64
diff --git a/.gitignore b/.gitignore
deleted file mode 100644
index 3ad793b..0000000
--- a/.gitignore
+++ /dev/null
@@ -1,67 +0,0 @@
-# Prerequisites
-*.d
-
-# Object files
-*.o
-*.ko
-*.obj
-*.elf
-
-# Linker output
-*.ilk
-*.map
-*.exp
-
-# Precompiled Headers
-*.gch
-*.pch
-
-# Libraries
-*.lib
-*.a
-*.la
-*.lo
-
-# Shared objects (inc. Windows DLLs)
-*.dll
-*.so
-*.so.*
-*.dylib
-
-# Executables
-*.exe
-*.out
-*.app
-*.i*86
-*.x86_64
-*.hex
-
-# Debug files
-*.dSYM/
-*.su
-*.idb
-*.pdb
-
-# Kernel Module Compile Results
-*.mod*
-*.cmd
-.tmp_versions/
-modules.order
-Module.symvers
-Mkfile.old
-dkms.conf
-
-# from box86
-build/
-build*/
-.vscode
-.cache
-.gdb_history
-src/git_head.h
-backup/
-
-# LLVMprivateGenerator
-/LLVMprivateGenerator/*
-!/LLVMprivateGenerator/Makefile
-!/LLVMprivateGenerator/main.cpp
-!/LLVMprivateGenerator/registered_structs.cpp
diff --git a/.travis.yml b/.travis.yml
deleted file mode 100755
index 1d190e0..0000000
--- a/.travis.yml
+++ /dev/null
@@ -1,24 +0,0 @@
-language: c
-arch:
- - amd64
- - arm64-graviton2
-os: linux
-dist: focal
-
-compiler:
- - gcc
-
-addons:
- apt:
- packages:
- - python3
-
- #Build steps
-before_script:
- - mkdir build
- - cd build
- - if [ "$TRAVIS_CPU_ARCH" = "arm64" ]; then cmake .. -DRK3399=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo ; else cmake .. -DLD80BITS=1 -DNOALIGN=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo ; fi
-
-script:
- - make
- - ctest --output-on-failure
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 7e48c60..88c8eac 100755..100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -14,11 +14,13 @@ option(ODROIDN2 "Set to ON if targeting an Odroid-N2 device" ${ODROIDN2})
option(TEGRAX1 "Set to ON if targeting an Tegra X1 based device" ${TEGRAX1})
option(PHYTIUM "Set to ON if targeting an Phytium (D2000 or FT2000/4) based device" ${PHYTIUM})
option(SD845 "Set to ON if targeting a Snapragon 845 based device" ${SD845})
+option(SD888 "Set to ON if targeting a Snapragon 888 based device" ${SD888})
option(M1 "Set to ON if targeting a AppleM1 running on Asahi computer" ${M1})
option(LARCH64 "Set to ON if targeting an Loongarch64 based device" ${LARCH64})
option(RV64 "Set to ON if targeting an RISC-V RV64GC based device" ${RV64})
option(PPC64LE "Set to ON if targeting an PowerPC 64 LE based device" ${PPC64LE})
option(LX2160A "Set to ON if targeting an LX2160A based device" ${LX2160A})
+option(ARM64 "Set to ON if targeting a generic ARM64 based device" ${ARM64})
option(USE_CCACHE "Set to ON to use ccache if present in the system" ${USE_CCACHE})
option(HAVE_TRACE "Set to ON to have Trace ability (needs ZydisInfo library)" ${HAVE_TRACE})
option(NOLOADADDR "Set to ON to avoid fixing the load address of Box64" OFF)
@@ -30,25 +32,29 @@ if(LARCH64)
set(LD80BITS OFF CACHE BOOL "")
set(NOALIGN OFF CACHE BOOL "")
set(ARM_DYNAREC OFF CACHE BOOL "")
+ set(RV64_DYNAREC OFF CACHE BOOL "")
endif()
if(RV64)
set(LD80BITS OFF CACHE BOOL "")
set(NOALIGN OFF CACHE BOOL "")
- set(ARM_DYNAREC OFF CACHE BOOL "")
+ set(ARM_DYNAREC OFF CACHE BOOL "")
+ set(RV64_DYNAREC ON CACHE BOOL "")
set(PAGE16K OFF CACHE BOOL "")
endif()
if(PPC64LE)
set(LD80BITS OFF CACHE BOOL "")
set(NOALIGN OFF CACHE BOOL "")
set(ARM_DYNAREC OFF CACHE BOOL "")
+ set(RV64_DYNAREC OFF CACHE BOOL "")
set(PAGE16K OFF CACHE BOOL "")
endif()
-if(RK3399 OR RK3588 OR ODROIDN2 OR RPI3ARM64 OR RPI4ARM64 OR RK3326 OR TEGRAX1 OR PHYTIUM OR SD845 OR LX2160A OR M1)
+if(RK3399 OR RK3588 OR ODROIDN2 OR RPI3ARM64 OR RPI4ARM64 OR RK3326 OR TEGRAX1 OR PHYTIUM OR SD845 OR SD888 OR LX2160A OR M1 OR ARM64)
set(LD80BITS OFF CACHE BOOL "")
set(NOALIGN OFF CACHE BOOL "")
set(ARM_DYNAREC ON CACHE BOOL "")
+ set(RV64_DYNAREC OFF CACHE BOOL "")
endif()
-if(RK3399 OR RK3588 OR ODROIDN2 OR RPI3ARM64 OR RPI4ARM64 OR RK3326 OR TEGRAX1 OR PHYTIUM OR SD845 OR LX2160A)
+if(RK3399 OR RK3588 OR ODROIDN2 OR RPI3ARM64 OR RPI4ARM64 OR RK3326 OR TEGRAX1 OR PHYTIUM OR SD845 OR SD888 OR LX2160A)
set(PAGE16K OFF CACHE BOOL "")
endif()
if(RK3588)
@@ -66,23 +72,26 @@ endif()
option(LD80BITS "Set to ON if host device have 80bits long double (i.e. i386)" ${LD80BITS})
option(NOALIGN "Set to ON if host device doesn't need re-align (i.e. i386)" ${NOALIGN})
option(ARM_DYNAREC "Set to ON to use ARM Dynamic Recompilation" ${ARM_DYNAREC})
+option(RV64_DYNAREC "Set to ON to use RISC-V Dynamic Recompilation" ${RV64_DYNAREC})
option(PAGE8K "Set to ON if host device have PageSize of 8K (instead of 4K)" ${PAGE8K})
option(PAGE16K "Set to ON if host device have PageSize of 16K (instead of 4K)" ${PAGE16K})
option(PAGE64K "Set to ON if host device have PageSize of 64K (instead of 4K)" ${PAGE64K})
option(STATICBUILD "Set to ON to have a static build (Warning, not working)" ${STATICBUILD})
+option(NO_LIB_INSTALL "Set ON to not install a few x86_64 libs that are used by many program" ${NO_LIB_INSTALL})
+option(NO_CONF_INSTALL "Set ON to not install config files" ${NO_CONF_INSTALL})
if(${CMAKE_VERSION} VERSION_LESS "3.12.2")
find_package(PythonInterp 3)
if(NOT PYTHONINTERP_FOUND)
- message( FATAL_ERROR "You need a Python interpretor, CMake will exit." )
+ message( FATAL_ERROR "You need a Python interpreter, CMake will exit." )
endif()
if(${PYTHON_VERSION_MAJOR} LESS 3)
- message( FATAL_ERROR "You need a Python 3 interpretor, CMake will exit." )
+ message( FATAL_ERROR "You need a Python 3 interpreter, CMake will exit." )
endif()
else()
find_package(Python3)
if(NOT Python3_Interpreter_FOUND)
- message( FATAL_ERROR "You need a Python interpretor, CMake will exit." )
+ message( FATAL_ERROR "You need a Python interpreter, CMake will exit." )
endif()
set(PYTHON_EXECUTABLE ${Python3_EXECUTABLE} CACHE INTERNAL "The Python3 executable" FORCE)
endif()
@@ -130,13 +139,17 @@ elseif(TEGRAX1)
add_definitions(-pipe -march=armv8-a+crc+simd+crypto -mcpu=cortex-a57+crypto)
set(CMAKE_ASM_FLAGS "-pipe -march=armv8-a+crc+simd+crypto -mcpu=cortex-a57+crypto")
elseif(PHYTIUM)
- add_definitions(-DPHYSIUM)
+ add_definitions(-DPHYTIUM)
add_definitions(-pipe -march=armv8.1-a+crc+simd+crypto)
set(CMAKE_ASM_FLAGS "-pipe -march=armv8.1-a+crc+simd+crypto+aes")
elseif(SD845)
add_definitions(-DSD845)
add_definitions(-pipe -march=armv8.2-a+simd+crypto -mtune=cortex-a75.cortex-a55)
set(CMAKE_ASM_FLAGS "-pipe -march=armv8.2-a+simd+crypto -mtune=cortex-a75.cortex-a55")
+elseif(SD888)
+ add_definitions(-DSD888)
+ add_definitions(-pipe -march=armv8.4-a+crypto)
+ set(CMAKE_ASM_FLAGS "-pipe -march=armv8.4-a+crypto")
elseif(M1)
add_definitions(-DM1)
add_definitions(-pipe -march=armv8.5-a+simd+crypto)
@@ -157,6 +170,9 @@ elseif(LX2160A)
set(CMAKE_ASM_FLAGS "-pipe -march=armv8-a+crypto+crc -mcpu=cortex-a72+crypto")
elseif(SW64)
add_definitions(-DSW64)
+elseif(ARM64)
+ #add_definitions(-pipe -march=native)
+ set(CMAKE_ASM_FLAGS "-pipe -march=armv8-a+simd")
elseif(ARM_DYNAREC)
set(CMAKE_ASM_FLAGS "-pipe -march=armv8-a+crc+simd+crypto")
endif()
@@ -208,6 +224,12 @@ if(ARM_DYNAREC)
enable_language(ASM)
include_directories("${BOX64_ROOT}/src/dynarec/arm64")
set(DYNAREC ON)
+elseif(RV64_DYNAREC)
+ add_definitions(-DDYNAREC)
+ add_definitions(-DRV64)
+ enable_language(ASM)
+ include_directories("${BOX64_ROOT}/src/dynarec/rv64")
+ set(DYNAREC ON)
else()
set(DYNAREC OFF)
endif()
@@ -254,32 +276,9 @@ set(ELFLOADER_SRC
"${BOX64_ROOT}/src/emu/x64int3.c"
"${BOX64_ROOT}/src/emu/x87emu_private.c"
"${BOX64_ROOT}/src/emu/x64primop.c"
- "${BOX64_ROOT}/src/emu/x64run.c"
- "${BOX64_ROOT}/src/emu/x64run0f.c"
- "${BOX64_ROOT}/src/emu/x64run64.c"
- "${BOX64_ROOT}/src/emu/x64run66.c"
- "${BOX64_ROOT}/src/emu/x64run660f.c"
- "${BOX64_ROOT}/src/emu/x64run6664.c"
- "${BOX64_ROOT}/src/emu/x64run66d9.c"
- "${BOX64_ROOT}/src/emu/x64run66dd.c"
- "${BOX64_ROOT}/src/emu/x64run66f0.c"
- "${BOX64_ROOT}/src/emu/x64run67.c"
- "${BOX64_ROOT}/src/emu/x64run670f.c"
- "${BOX64_ROOT}/src/emu/x64run6766.c"
- "${BOX64_ROOT}/src/emu/x64run67660f.c"
- "${BOX64_ROOT}/src/emu/x64rund8.c"
- "${BOX64_ROOT}/src/emu/x64rund9.c"
- "${BOX64_ROOT}/src/emu/x64runda.c"
- "${BOX64_ROOT}/src/emu/x64rundb.c"
- "${BOX64_ROOT}/src/emu/x64rundc.c"
- "${BOX64_ROOT}/src/emu/x64rundd.c"
- "${BOX64_ROOT}/src/emu/x64runde.c"
- "${BOX64_ROOT}/src/emu/x64rundf.c"
- "${BOX64_ROOT}/src/emu/x64runf0.c"
- "${BOX64_ROOT}/src/emu/x64runf20f.c"
- "${BOX64_ROOT}/src/emu/x64runf30f.c"
"${BOX64_ROOT}/src/emu/x64run_private.c"
"${BOX64_ROOT}/src/emu/x64syscall.c"
+ "${BOX64_ROOT}/src/emu/x86syscall.c"
"${BOX64_ROOT}/src/emu/x64tls.c"
"${BOX64_ROOT}/src/emu/x64trace.c"
"${BOX64_ROOT}/src/librarian/librarian.c"
@@ -294,6 +293,7 @@ set(ELFLOADER_SRC
"${BOX64_ROOT}/src/libtools/sdl2rwops.c"
"${BOX64_ROOT}/src/libtools/signals.c"
"${BOX64_ROOT}/src/libtools/threads.c"
+ "${BOX64_ROOT}/src/tools/bitutils.c"
"${BOX64_ROOT}/src/tools/box64stack.c"
"${BOX64_ROOT}/src/tools/bridge.c"
"${BOX64_ROOT}/src/tools/callback.c"
@@ -306,6 +306,35 @@ set(ELFLOADER_SRC
"${BOX64_ROOT}/src/wrapped/generated/wrapper.c"
)
+set(INTERPRETER
+ "${BOX64_ROOT}/src/emu/x64run.c"
+ "${BOX64_ROOT}/src/emu/x64run0f.c"
+ "${BOX64_ROOT}/src/emu/x64run64.c"
+ "${BOX64_ROOT}/src/emu/x64run66.c"
+ "${BOX64_ROOT}/src/emu/x64run660f.c"
+ "${BOX64_ROOT}/src/emu/x64run6664.c"
+ "${BOX64_ROOT}/src/emu/x64run66d9.c"
+ "${BOX64_ROOT}/src/emu/x64run66dd.c"
+ "${BOX64_ROOT}/src/emu/x64run66f0.c"
+ "${BOX64_ROOT}/src/emu/x64run67.c"
+ "${BOX64_ROOT}/src/emu/x64run67_32.c"
+ "${BOX64_ROOT}/src/emu/x64run6764_32.c"
+ "${BOX64_ROOT}/src/emu/x64run670f.c"
+ "${BOX64_ROOT}/src/emu/x64run6766.c"
+ "${BOX64_ROOT}/src/emu/x64run67660f.c"
+ "${BOX64_ROOT}/src/emu/x64rund8.c"
+ "${BOX64_ROOT}/src/emu/x64rund9.c"
+ "${BOX64_ROOT}/src/emu/x64runda.c"
+ "${BOX64_ROOT}/src/emu/x64rundb.c"
+ "${BOX64_ROOT}/src/emu/x64rundc.c"
+ "${BOX64_ROOT}/src/emu/x64rundd.c"
+ "${BOX64_ROOT}/src/emu/x64runde.c"
+ "${BOX64_ROOT}/src/emu/x64rundf.c"
+ "${BOX64_ROOT}/src/emu/x64runf0.c"
+ "${BOX64_ROOT}/src/emu/x64runf20f.c"
+ "${BOX64_ROOT}/src/emu/x64runf30f.c"
+)
+
set(WRAPPEDS
"${BOX64_ROOT}/src/wrapped/wrappedalure.c"
"${BOX64_ROOT}/src/wrapped/wrappedalut.c"
@@ -314,10 +343,12 @@ set(WRAPPEDS
"${BOX64_ROOT}/src/wrapped/wrappedatomic.c"
"${BOX64_ROOT}/src/wrapped/wrappedatspi.c"
"${BOX64_ROOT}/src/wrapped/wrappedbz2.c"
+ "${BOX64_ROOT}/src/wrapped/wrappedcap.c"
"${BOX64_ROOT}/src/wrapped/wrappedcairo.c"
"${BOX64_ROOT}/src/wrapped/wrappedcairogobject.c"
"${BOX64_ROOT}/src/wrapped/wrappedcrashhandler.c"
"${BOX64_ROOT}/src/wrapped/wrappedcrypto.c"
+ "${BOX64_ROOT}/src/wrapped/wrappedcrypto3.c"
"${BOX64_ROOT}/src/wrapped/wrappedcurl.c"
"${BOX64_ROOT}/src/wrapped/wrappeddbus.c"
"${BOX64_ROOT}/src/wrapped/wrappeddbusglib1.c"
@@ -339,6 +370,7 @@ set(WRAPPEDS
"${BOX64_ROOT}/src/wrapped/wrappedgmp.c"
"${BOX64_ROOT}/src/wrapped/wrappedgnutls.c"
"${BOX64_ROOT}/src/wrapped/wrappedgobject2.c"
+ "${BOX64_ROOT}/src/wrapped/wrappedgomp.c"
"${BOX64_ROOT}/src/wrapped/wrappedgssapi.c"
"${BOX64_ROOT}/src/wrapped/wrappedgssapikrb5.c"
"${BOX64_ROOT}/src/wrapped/wrappedgstapp.c"
@@ -355,6 +387,7 @@ set(WRAPPEDS
"${BOX64_ROOT}/src/wrapped/wrappedldlinux.c"
"${BOX64_ROOT}/src/wrapped/wrappedlibasound.c"
"${BOX64_ROOT}/src/wrapped/wrappedlibc.c"
+ "${BOX64_ROOT}/src/wrapped/wrappedlibcmusl.c"
"${BOX64_ROOT}/src/wrapped/wrappedlibcrypt.c"
"${BOX64_ROOT}/src/wrapped/wrappedlibcups.c"
"${BOX64_ROOT}/src/wrapped/wrappedlibdl.c"
@@ -366,6 +399,7 @@ set(WRAPPEDS
"${BOX64_ROOT}/src/wrapped/wrappedlibgl.c"
"${BOX64_ROOT}/src/wrapped/wrappedlibglu.c"
"${BOX64_ROOT}/src/wrapped/wrappedlibglx.c"
+ "${BOX64_ROOT}/src/wrapped/wrappedlibharfbuzz.c"
"${BOX64_ROOT}/src/wrapped/wrappedlibibus.c"
"${BOX64_ROOT}/src/wrapped/wrappedlibice.c"
"${BOX64_ROOT}/src/wrapped/wrappedlibm.c"
@@ -373,6 +407,7 @@ set(WRAPPEDS
"${BOX64_ROOT}/src/wrapped/wrappedlibncurses6.c"
"${BOX64_ROOT}/src/wrapped/wrappedlibncursesw.c"
"${BOX64_ROOT}/src/wrapped/wrappedlibncursesw6.c"
+ "${BOX64_ROOT}/src/wrapped/wrappedlibnuma.c"
"${BOX64_ROOT}/src/wrapped/wrappedlibogg.c"
"${BOX64_ROOT}/src/wrapped/wrappedlibpanel.c"
"${BOX64_ROOT}/src/wrapped/wrappedlibpci.c"
@@ -383,6 +418,7 @@ set(WRAPPEDS
"${BOX64_ROOT}/src/wrapped/wrappedlibsm.c"
"${BOX64_ROOT}/src/wrapped/wrappedlibsndfile.c"
"${BOX64_ROOT}/src/wrapped/wrappedlibssl.c"
+ "${BOX64_ROOT}/src/wrapped/wrappedlibssl3.c"
"${BOX64_ROOT}/src/wrapped/wrappedlibtinfo.c"
"${BOX64_ROOT}/src/wrapped/wrappedlibtinfo6.c"
"${BOX64_ROOT}/src/wrapped/wrappedlibusb1.c"
@@ -467,6 +503,7 @@ set(WRAPPEDS
"${BOX64_ROOT}/src/wrapped/wrappedsmime3.c"
"${BOX64_ROOT}/src/wrapped/wrappedsmpeg2.c"
"${BOX64_ROOT}/src/wrapped/wrappedssl3.c"
+ "${BOX64_ROOT}/src/wrapped/wrappedtbbbind.c"
"${BOX64_ROOT}/src/wrapped/wrappedtbbmalloc.c"
"${BOX64_ROOT}/src/wrapped/wrappedtbbmallocproxy.c"
"${BOX64_ROOT}/src/wrapped/wrappedtcmallocminimal.c"
@@ -488,6 +525,10 @@ set(WRAPPEDS
"${BOX64_ROOT}/src/wrapped/wrappedvulkan.c"
"${BOX64_ROOT}/src/wrapped/wrappedxshmfence.c"
"${BOX64_ROOT}/src/wrapped/wrappedd3dadapter9.c"
+ "${BOX64_ROOT}/src/wrapped/wrappedicuuc67.c"
+ "${BOX64_ROOT}/src/wrapped/wrappedicui18n67.c"
+ "${BOX64_ROOT}/src/wrapped/wrappedicuuc72.c"
+ "${BOX64_ROOT}/src/wrapped/wrappedicui18n72.c"
)
# If BOX64_ROOT contains a ".c", the build breaks...
@@ -529,6 +570,8 @@ if(DYNAREC)
set(DYNAREC_SRC
"${BOX64_ROOT}/src/dynarec/dynablock.c"
"${BOX64_ROOT}/src/dynarec/dynarec_native.c"
+ "${BOX64_ROOT}/src/dynarec/dynarec_native_functions.c"
+ "${BOX64_ROOT}/src/emu/x64test.c"
)
endif()
@@ -575,9 +618,57 @@ if(ARM_DYNAREC)
)
endif()
+if(RV64_DYNAREC)
+ set(DYNAREC_SRC
+ ${DYNAREC_SRC}
+
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_functions.c"
+ "${BOX64_ROOT}/src/dynarec/rv64/rv64_printer.c"
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_jmpnext.c"
+ "${BOX64_ROOT}/src/rv64detect.c"
+
+ "${BOX64_ROOT}/src/dynarec/rv64/rv64_prolog.S"
+ "${BOX64_ROOT}/src/dynarec/rv64/rv64_epilog.S"
+ "${BOX64_ROOT}/src/dynarec/rv64/rv64_next.S"
+ "${BOX64_ROOT}/src/dynarec/rv64/rv64_lock.S"
+ )
+
+ set(DYNAREC_PASS
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_helper.c"
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_emit_tests.c"
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_emit_math.c"
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_emit_logic.c"
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_emit_shift.c"
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_00.c"
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_00_0.c"
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_00_1.c"
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_00_2.c"
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_00_3.c"
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_0f.c"
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_64.c"
+ #"${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_65.c"
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_66.c"
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_67.c"
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_d8.c"
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_d9.c"
+ #"${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_da.c"
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_db.c"
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_dc.c"
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_dd.c"
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_de.c"
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_df.c"
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_f0.c"
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_660f.c"
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_6664.c"
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_66f0.c"
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_f20f.c"
+ "${BOX64_ROOT}/src/dynarec/rv64/dynarec_rv64_f30f.c"
+ )
+endif()
+
if(DYNAREC)
- set(DYNAREC_PASS
- "${BOX64_ROOT}/src/wrapped/generated/wrapper.h"
+ set(DYNAREC_PASS
+ "${BOX64_ROOT}/src/wrapped/generated/wrapper.h"
${DYNAREC_PASS}
"${BOX64_ROOT}/src/dynarec/dynarec_native_pass.c"
)
@@ -592,6 +683,8 @@ if(DYNAREC)
set_target_properties(native_pass2 PROPERTIES COMPILE_FLAGS "-DSTEP=2")
add_library(native_pass3 OBJECT ${DYNAREC_PASS})
set_target_properties(native_pass3 PROPERTIES COMPILE_FLAGS "-DSTEP=3")
+ add_library(test_interpreter OBJECT ${INTERPRETER})
+ set_target_properties(test_interpreter PROPERTIES COMPILE_FLAGS "-DTEST_INTERPRETER")
add_dependencies(native_pass0 WRAPPERS)
add_dependencies(native_pass1 WRAPPERS)
add_dependencies(native_pass2 WRAPPERS)
@@ -603,6 +696,7 @@ if(DYNAREC)
$<TARGET_OBJECTS:native_pass1>
$<TARGET_OBJECTS:native_pass2>
$<TARGET_OBJECTS:native_pass3>
+ $<TARGET_OBJECTS:test_interpreter>
)
endif()
@@ -611,16 +705,18 @@ if(DYNAREC)
add_custom_command(
OUTPUT "${BOX64_ROOT}/src/git_head.h"
COMMAND sh -c "echo \\\#define GITREV \\\"$(git rev-parse --short HEAD)\\\">\"${BOX64_ROOT}/src/git_head.h\""
- DEPENDS dynarec ${ELFLOADER_SRC} ${WRAPPEDS}
+ DEPENDS dynarec ${ELFLOADER_SRC} ${INTERPRETER} ${WRAPPEDS}
VERBATIM)
else()
add_custom_command(
OUTPUT "${BOX64_ROOT}/src/git_head.h"
COMMAND sh -c "echo \\\#define GITREV \\\"$(git rev-parse --short HEAD)\\\">\"${BOX64_ROOT}/src/git_head.h\""
- DEPENDS ${ELFLOADER_SRC} ${WRAPPEDS}
+ DEPENDS ${ELFLOADER_SRC} ${INTERPRETER} ${WRAPPEDS}
VERBATIM)
endif()
+add_library(interpreter OBJECT ${INTERPRETER})
+
add_executable(${BOX64} ${ELFLOADER_SRC} ${WRAPPEDS} "${BOX64_ROOT}/src/git_head.h")
set_target_properties(${BOX64} PROPERTIES ENABLE_EXPORTS ON)
add_dependencies(${BOX64} WRAPPERS)
@@ -634,6 +730,7 @@ endif()
if(DYNAREC)
target_link_libraries(${BOX64} dynarec)
endif()
+target_link_libraries(${BOX64} interpreter)
if(${CMAKE_VERSION} VERSION_LESS "3.13")
if(NOT NOLOADADDR)
@@ -654,9 +751,10 @@ else()
endif()
endif()
-string(COMPARE EQUAL "${CMAKE_HOST_SYSTEM_PROCESSOR}" "i686" _x86)
-string(COMPARE EQUAL "${CMAKE_HOST_SYSTEM_PROCESSOR}" "x86_64" _x86_64)
-string(COMPARE EQUAL "${CMAKE_HOST_SYSTEM_PROCESSOR}" "aarch64" _aarch64)
+string(COMPARE EQUAL "${CMAKE_SYSTEM_PROCESSOR}" "i686" _x86)
+string(COMPARE EQUAL "${CMAKE_SYSTEM_PROCESSOR}" "x86_64" _x86_64)
+string(COMPARE EQUAL "${CMAKE_SYSTEM_PROCESSOR}" "aarch64" _aarch64)
+string(COMPARE EQUAL "${CMAKE_SYSTEM_PROCESSOR}" "riscv64" _riscv64)
if(_x86_64 OR _aarch64)
add_definitions(-DCONFIG_64BIT)
@@ -665,13 +763,17 @@ endif()
if(NOT _x86 AND NOT _x86_64)
install(TARGETS ${BOX64}
RUNTIME DESTINATION bin)
- configure_file(system/box64.conf.cmake system/box64.conf)
- install(FILES ${CMAKE_BINARY_DIR}/system/box64.conf DESTINATION /etc/binfmt.d/)
- install(FILES ${CMAKE_SOURCE_DIR}/x64lib/libstdc++.so.5 DESTINATION /usr/lib/x86_64-linux-gnu/)
- install(FILES ${CMAKE_SOURCE_DIR}/x64lib/libstdc++.so.6 DESTINATION /usr/lib/x86_64-linux-gnu/)
- install(FILES ${CMAKE_SOURCE_DIR}/x64lib/libgcc_s.so.1 DESTINATION /usr/lib/x86_64-linux-gnu/)
- install(FILES ${CMAKE_SOURCE_DIR}/x64lib/libpng12.so.0 DESTINATION /usr/lib/x86_64-linux-gnu/)
- install(FILES ${CMAKE_SOURCE_DIR}/system/box64.box64rc DESTINATION /etc/)
+ if(NOT NO_CONF_INSTALL)
+ configure_file(system/box64.conf.cmake system/box64.conf)
+ install(FILES ${CMAKE_BINARY_DIR}/system/box64.conf DESTINATION /etc/binfmt.d/)
+ install(FILES ${CMAKE_SOURCE_DIR}/system/box64.box64rc DESTINATION /etc/)
+ endif()
+ if(NOT NO_LIB_INSTALL)
+ install(FILES ${CMAKE_SOURCE_DIR}/x64lib/libstdc++.so.5 DESTINATION /usr/lib/x86_64-linux-gnu/)
+ install(FILES ${CMAKE_SOURCE_DIR}/x64lib/libstdc++.so.6 DESTINATION /usr/lib/x86_64-linux-gnu/)
+ install(FILES ${CMAKE_SOURCE_DIR}/x64lib/libgcc_s.so.1 DESTINATION /usr/lib/x86_64-linux-gnu/)
+ install(FILES ${CMAKE_SOURCE_DIR}/x64lib/libpng12.so.0 DESTINATION /usr/lib/x86_64-linux-gnu/)
+ endif()
endif()
if(NOT TARGET uninstall)
@@ -705,6 +807,8 @@ set(CPACK_PACKAGE_VERSION_PATCH ${BOX64_REVISION})
set(CPACK_DEBIAN_PACKAGE_CONTROL_EXTRA "${CMAKE_CURRENT_SOURCE_DIR}/postinst")
if(_aarch64)
set(CPACK_DEBIAN_PACKAGE_ARCHITECTURE "arm64")
+elseif(__riscv64)
+ set(CPACK_DEBIAN_PACKAGE_ARCHITECTURE "riscv64")
elseif(_x86_64)
set(CPACK_DEBIAN_PACKAGE_ARCHITECTURE "x86_64")
else()
@@ -795,14 +899,14 @@ add_test(sse_asm ${CMAKE_COMMAND} -D TEST_PROGRAM=${CMAKE_BINARY_DIR}/${BOX64}
-P ${CMAKE_SOURCE_DIR}/runTest.cmake )
set_tests_properties(sse_asm PROPERTIES ENVIRONMENT "BOX64_DYNAREC_FASTROUND=0")
-
+
add_test(sse_intrinsics ${CMAKE_COMMAND} -D TEST_PROGRAM=${CMAKE_BINARY_DIR}/${BOX64}
-D TEST_ARGS=${CMAKE_SOURCE_DIR}/tests/test17 -D TEST_OUTPUT=tmpfile17.txt
-D TEST_REFERENCE=${CMAKE_SOURCE_DIR}/tests/ref17.txt
-P ${CMAKE_SOURCE_DIR}/runTest.cmake )
set_tests_properties(sse_intrinsics PROPERTIES ENVIRONMENT "BOX64_DYNAREC_FASTNAN=0;BOX64_DYNAREC_FASTROUND=0")
-
+
add_test(aes ${CMAKE_COMMAND} -D TEST_PROGRAM=${CMAKE_BINARY_DIR}/${BOX64}
-D TEST_ARGS=${CMAKE_SOURCE_DIR}/tests/test18 -D TEST_OUTPUT=tmpfile18.txt
-D TEST_REFERENCE=${CMAKE_SOURCE_DIR}/tests/ref18.txt
@@ -828,6 +932,8 @@ add_test(irelative_reloc ${CMAKE_COMMAND} -D TEST_PROGRAM=${CMAKE_BINARY_DIR}/${
-D TEST_REFERENCE=${CMAKE_SOURCE_DIR}/tests/ref22.txt
-P ${CMAKE_SOURCE_DIR}/runTest.cmake )
+ set_tests_properties(x87 PROPERTIES ENVIRONMENT "BOX64_DYNAREC_FASTROUND=0")
+
file(GLOB extension_tests "${CMAKE_SOURCE_DIR}/tests/extensions/*.c")
foreach(file ${extension_tests})
get_filename_component(testname "${file}" NAME_WE)
diff --git a/LLVMprivateGenerator/Makefile b/LLVMprivateGenerator/Makefile
deleted file mode 100644
index 6186426..0000000
--- a/LLVMprivateGenerator/Makefile
+++ /dev/null
@@ -1,12 +0,0 @@
-all: dumpSigs
-
-dumpSigs: main.o registered_structs.o
- g++ -g3 -std=gnu++17 -fno-rtti main.o registered_structs.o -o dumpSigs "-L$(LLVM_install_dir)/lib" -lclang-cpp -lclangTooling -Wl,-rpath "-Wl,$(LLVM_install_dir)/lib"
-
-main.o: main.cpp
- g++ -g3 -std=gnu++17 -fno-rtti -c main.cpp -Wfatal-errors "-I$(LLVM_install_dir)/include" -o main.o
-registered_structs.o: registered_structs.cpp
- g++ -g3 -std=gnu++17 -fno-rtti -c registered_structs.cpp -Wfatal-errors -o registered_structs.o
-
-clean:
- $(RM) dumpSigs main.o registered_structs.o
diff --git a/LLVMprivateGenerator/main.cpp b/LLVMprivateGenerator/main.cpp
deleted file mode 100644
index fe070cb..0000000
--- a/LLVMprivateGenerator/main.cpp
+++ /dev/null
@@ -1,458 +0,0 @@
-#include <algorithm>
-#include <fstream>
-#include <iostream>
-#include <numeric>
-#include <unordered_map>
-#include <utility>
-#include <vector>
-
-#include <llvm/Support/raw_ostream.h>
-#include <clang/AST/ASTConsumer.h>
-#include <clang/AST/Decl.h>
-#include <clang/AST/Mangle.h>
-#include <clang/AST/PrettyPrinter.h>
-#include <clang/AST/RecursiveASTVisitor.h>
-#include <clang/Frontend/CompilerInstance.h>
-#include <clang/Frontend/FrontendActions.h>
-#include <clang/Tooling/CommonOptionsParser.h>
-#include <clang/Tooling/Tooling.h>
-
-clang::MangleContext *mangler = nullptr;
-
-std::unordered_map<std::string, std::pair<std::string, bool>> funMap;
-std::vector<std::string> funList;
-
-bool isTypeTrivial(const clang::QualType &q, const clang::QualType *qorig);
-clang::QualType getPointedType(const clang::QualType q) {
- if (const clang::PointerType *p = q->getAs<clang::PointerType>())
- return getPointedType(p->getPointeeType());
- else if (const clang::ReferenceType *r = q->getAs<clang::ReferenceType>())
- return getPointedType(r->getPointeeType());
- else
- return q;
-}
-
-std::string record2name(const clang::RecordDecl &q, const clang::QualType *qorig) {
- std::string s = q.getNameAsString();
- if (s == "") {
- if (!qorig) return "????.!";
- if (const clang::TypedefType *tt = (*qorig)->getAs<clang::TypedefType>()) {
- // Typedef
- if (clang::TypedefNameDecl *td = tt->getDecl()) {
- return td->getNameAsString();
- } else {
- return "<typedef with no declaration>";
- }
- } else {
- return std::string("<unknown type ") + (*qorig)->getTypeClassName() + ">";
- }
- } else {
- return s;
- }
-}
-
-char ptr2char(const std::string &str) __attribute__((const));
-const char *ptr2str(const std::string &str) __attribute__((const));
-char type2char(const clang::QualType &qual /* Canonical */, const clang::QualType *qorig) {
- if (qual->isBuiltinType()) {
- switch (static_cast<const clang::BuiltinType&>(*qual).getKind()) {
- case clang::BuiltinType::Kind::Void:
- return 'v';
- case clang::BuiltinType::Kind::Bool:
- return 'i';
- case clang::BuiltinType::Kind::Char_U:
- return 'C';
- case clang::BuiltinType::Kind::Char_S:
- return 'c';
- case clang::BuiltinType::Kind::Char8:
- return 'c';
- case clang::BuiltinType::Kind::UChar:
- return 'C';
- case clang::BuiltinType::Kind::SChar:
- return 'c';
- case clang::BuiltinType::Kind::WChar_U:
- return 'W';
- case clang::BuiltinType::Kind::UShort:
- return 'W';
- case clang::BuiltinType::Kind::WChar_S:
- return 'w';
- case clang::BuiltinType::Kind::Char16:
- return 'w';
- case clang::BuiltinType::Kind::Short:
- return 'w';
- case clang::BuiltinType::Kind::UInt:
- return 'u';
- case clang::BuiltinType::Kind::Char32:
- return 'i';
- case clang::BuiltinType::Kind::Int:
- return 'i';
- case clang::BuiltinType::Kind::ULong:
- return 'L';
- case clang::BuiltinType::Kind::Long:
- return 'l';
- case clang::BuiltinType::Kind::ULongLong:
- return 'U';
- case clang::BuiltinType::Kind::LongLong:
- return 'I';
- case clang::BuiltinType::Kind::UInt128:
- return 'H';
- case clang::BuiltinType::Kind::Int128:
- return 'H';
- case clang::BuiltinType::Kind::Float:
- return 'f';
- case clang::BuiltinType::Kind::Double:
- return 'd';
- case clang::BuiltinType::Kind::LongDouble:
- return 'D';
- case clang::BuiltinType::Kind::NullPtr:
- return 'p'; // nullptr_t
-
- case clang::BuiltinType::Kind::Half:
- case clang::BuiltinType::Kind::BFloat16:
- case clang::BuiltinType::Kind::ShortAccum:
- case clang::BuiltinType::Kind::Accum:
- case clang::BuiltinType::Kind::LongAccum:
- case clang::BuiltinType::Kind::UShortAccum:
- case clang::BuiltinType::Kind::UAccum:
- case clang::BuiltinType::Kind::ULongAccum:
- case clang::BuiltinType::Kind::ShortFract:
- case clang::BuiltinType::Kind::Fract:
- case clang::BuiltinType::Kind::LongFract:
- case clang::BuiltinType::Kind::UShortFract:
- case clang::BuiltinType::Kind::UFract:
- case clang::BuiltinType::Kind::ULongFract:
- case clang::BuiltinType::Kind::SatShortAccum:
- case clang::BuiltinType::Kind::SatAccum:
- case clang::BuiltinType::Kind::SatLongAccum:
- case clang::BuiltinType::Kind::SatUShortAccum:
- case clang::BuiltinType::Kind::SatUAccum:
- case clang::BuiltinType::Kind::SatULongAccum:
- case clang::BuiltinType::Kind::SatShortFract:
- case clang::BuiltinType::Kind::SatFract:
- case clang::BuiltinType::Kind::SatLongFract:
- case clang::BuiltinType::Kind::SatUShortFract:
- case clang::BuiltinType::Kind::SatUFract:
- case clang::BuiltinType::Kind::SatULongFract:
- case clang::BuiltinType::Kind::Float16:
- case clang::BuiltinType::Kind::Float128:
- case clang::BuiltinType::Kind::Overload:
- case clang::BuiltinType::Kind::BoundMember:
- case clang::BuiltinType::Kind::PseudoObject:
- case clang::BuiltinType::Kind::Dependent:
- case clang::BuiltinType::Kind::UnknownAny:
- case clang::BuiltinType::Kind::ARCUnbridgedCast:
- case clang::BuiltinType::Kind::BuiltinFn:
- case clang::BuiltinType::Kind::ObjCId:
- case clang::BuiltinType::Kind::ObjCClass:
- case clang::BuiltinType::Kind::ObjCSel:
-#define IMAGE_TYPE(it, id, si, a, s) case clang::BuiltinType::Kind::id:
-#include <clang/Basic/OpenCLImageTypes.def>
-#undef IMAGE_TYPE
- case clang::BuiltinType::Kind::OCLSampler:
- case clang::BuiltinType::Kind::OCLEvent:
- case clang::BuiltinType::Kind::OCLClkEvent:
- case clang::BuiltinType::Kind::OCLQueue:
- case clang::BuiltinType::Kind::OCLReserveID:
- case clang::BuiltinType::Kind::IncompleteMatrixIdx:
- case clang::BuiltinType::Kind::OMPArraySection:
- case clang::BuiltinType::Kind::OMPArrayShaping:
- case clang::BuiltinType::Kind::OMPIterator:
-#define EXT_OPAQUE_TYPE(et, id, e) case clang::BuiltinType::Kind::id:
-#include <clang/Basic/OpenCLExtensionTypes.def>
-#define SVE_TYPE(n, id, si) case clang::BuiltinType::Kind::id:
-#include <clang/Basic/AArch64SVEACLETypes.def>
-#define PPC_VECTOR_TYPE(n, id, s) case clang::BuiltinType::Kind::id:
-#include <clang/Basic/PPCTypes.def>
-#undef EXT_OPAQUE_TYPE
-#undef SVE_TYPE
-#undef PPC_VECTOR_TYPE
- return '!';
- default:
- return ':';
- }
- } else if (qual->isEnumeralType()) {
- const clang::EnumDecl *ed = qual->getAs<clang::EnumType>()->getDecl();
- if (!ed) {
- return 'i';
- } else {
- return type2char(ed->getIntegerType().getCanonicalType(), qorig);
- }
- } else if (qual->isFunctionPointerType()) {
- return '@';
- } else if (qual->isAnyPointerType() || qual->isReferenceType()) {
- const clang::QualType &pointed = getPointedType(qual);
- if (isTypeTrivial(pointed, qorig)) {
- return 'p';
- } else if (const clang::RecordType *rct = pointed->getAs<clang::RecordType>()) {
- clang::RecordDecl *rc = rct->getDecl();
- if (!rc) {
- return '!';
- } else if (!rc->isCompleteDefinition()) {
- return 'p';
- } else {
- std::string str;
- if (qorig) {
- const clang::QualType qpted = getPointedType(*qorig);
- str = record2name(*rc, &qpted);
- } else {
- str = record2name(*rc, nullptr);
- }
- char ret = ptr2char(str);
- if (ret) return ret;
- else {
- return '!';
- }
- }
- } else {
- return '!';
- }
- } else if (const clang::RecordType *rct = qual->getAs<clang::RecordType>()) {
- clang::RecordDecl *rc = rct->getDecl();
- if (!rc) {
- return '?';
- } else if (rc->getNameAsString() == "__builtin_va_list") {
- // va_list
- return 'A';
- } else {
- return '?';
- }
- } else {
- return '?';
- }
-}
-bool isTypeTrivial(const clang::QualType &q, const clang::QualType *qorig) {
- const char c = type2char(q, qorig);
-#define GO(chr) || (c == chr)
- return (c == 'v')
- GO('i') GO('u')
- GO('I') GO('U')
- GO('l') GO('L')
- GO('f') GO('d')
- GO('D') GO('K')
- GO('0') GO('1')
- GO('C') GO('c')
- GO('W') GO('w')
- GO('H')
- GO('p');
-#undef GO
-}
-bool isTypeValid(const clang::QualType &q, const clang::QualType *qorig) {
- const char c = type2char(q, qorig);
- if (c == 'A') return false;
- if (c == 'V') return false;
- return ((c >= '0') && (c <= '9')) || ((c >= 'A') && (c <= 'Z')) || ((c >= 'a') && (c <= 'z'));
-}
-
-const std::string type2string(const clang::QualType &qual, const clang::QualType *qorig) {
- if (qual->isBuiltinType()) {
- return std::string("(builtin) ") + static_cast<const clang::BuiltinType&>(*qual).getName(clang::PrintingPolicy{{}}).data();
- } else if (qual->isFunctionPointerType()) {
- return "Callback (function pointer)";
- } else if (qual->isAnyPointerType() || qual->isReferenceType()) {
- std::string prefix = qual->isAnyPointerType() ? "Pointer to " : "Reference to ";
- const clang::QualType &pointed = getPointedType(qual);
- if (isTypeTrivial(pointed, qorig)) {
- return prefix + "trivial object " + type2string(pointed, qorig) + " (" + type2char(pointed, qorig) + ")";
- } else if (const clang::RecordType *rct = pointed->getAs<clang::RecordType>()) {
- clang::RecordDecl *rc = rct->getDecl();
- if (!rc) {
- return prefix + "unknown record";
- } else if (!rc->isCompleteDefinition()) {
- return prefix + "incomplete record " + rc->getNameAsString();
- } else {
- std::string str;
- if (qorig) {
- const clang::QualType qpted = getPointedType(*qorig);
- str = record2name(*rc, &qpted);
- } else {
- str = record2name(*rc, nullptr);
- }
- const char *ret = ptr2str(str);
- if (ret[0] != '\0') {
- return prefix + ret;
- } else {
- if (mangler && mangler->shouldMangleDeclName(rc)) {
- std::string mangled;
- {
- llvm::raw_string_ostream strstr{mangled};
- mangler->mangleName(rc, strstr);
- }
- return prefix + "unknown record " + str + " (=== " + mangled + ")";
- } else {
- return prefix + "unknown record " + str;
- }
- }
- }
- } else {
- return prefix + "non-trivial or typedef'ed object " + type2string(pointed, qorig) + " (" + type2char(pointed, qorig) + ")";
- //return "Pointer (maybe to callback)";
- }
- } else if (qual->isEnumeralType()) {
- const clang::EnumDecl *ed = qual->getAs<clang::EnumType>()->getDecl();
- if (!ed) {
- return "Enumeration with unknown underlying integer type (assuming int)";
- } else {
- return "Enumeration with underlying type " + type2string(ed->getIntegerType().getCanonicalType(), nullptr);
- }
- } else if (const clang::RecordType *rct = qual->getAs<clang::RecordType>()) {
- clang::RecordDecl *rc = rct->getDecl();
- if (!rc) {
- return "Unknown record";
- } else if (rc->getNameAsString() == "__builtin_va_list") {
- return "va_list";
- } else {
- return "Unknown record " + std::string(rc->getName().data());
- }
- } else {
- return std::string("??? ") + qual->getTypeClassName();
- }
-}
-
-class Visitor : public clang::RecursiveASTVisitor<Visitor> {
-public:
- clang::ASTContext &context;
-
- bool shouldVisitTemplateInstantiations() const /* override */ { return true; }
-
- Visitor(clang::CompilerInstance &ci) : context(ci.getASTContext()) {
- if (!mangler) {
- mangler = clang::ItaniumMangleContext::create(context, ci.getDiagnostics());
- }
- }
-
- ~Visitor() {
- if (mangler) {
- delete mangler;
- mangler = nullptr;
- }
- }
-
- bool VisitDecl(clang::Decl *decl) /* override */ {
- std::cerr << std::flush;
- if (!decl) return true;
-
- if ((decl->getKind() >= clang::Decl::Kind::firstFunction) && (decl->getKind() <= clang::Decl::Kind::lastFunction)) {
- clang::DeclaratorDecl *ddecl = static_cast<clang::DeclaratorDecl*>(decl);
- std::cout << "Function detected!\n";
-
- std::string funName{ddecl->getName()};
-
- auto niceprint = [](const std::string &infotype, const auto &dat){ std::cout << " " << infotype << ": " << dat << "\n"; };
- niceprint("Function name", funName);
- if (mangler && mangler->shouldMangleDeclName(ddecl)) {
- std::string mangled;
- {
- llvm::raw_string_ostream strstr{mangled};
- mangler->mangleName(ddecl, strstr);
- }
- niceprint("Function mangled name", mangled);
- funName = std::move(mangled);
- }
-
- bool valid;
- std::string funTypeStr{""};
- if (ddecl->getFunctionType()->isFunctionNoProtoType()) {
- const clang::FunctionNoProtoType *funType = static_cast<const clang::FunctionNoProtoType*>(ddecl->getFunctionType());
- const auto &retType = funType->getReturnType();
-
- niceprint("Function return type", type2string(retType, &retType));
- niceprint("Canonical function return type",
- type2string(retType.getCanonicalType(), &retType) +
- " (" + type2char(retType.getCanonicalType(), &retType) + ")");
- niceprint("Is sugared", funType->isSugared());
- if (funType->isSugared()) {
- clang::QualType qft{funType, 0};
- niceprint("Desugared", type2string(funType->desugar(), &qft));
- }
-
- funTypeStr = type2char(retType.getCanonicalType(), &retType) + std::string("Fv");
- valid = isTypeValid(retType.getCanonicalType(), &retType);
- } else {
- const clang::FunctionProtoType *funType = static_cast<const clang::FunctionProtoType*>(ddecl->getFunctionType());
- const auto &retType = funType->getReturnType();
-
- niceprint("Function return type", type2string(retType, &retType));
- niceprint("Canonical function return type",
- type2string(retType.getCanonicalType(), &retType)
- + " (" + type2char(retType.getCanonicalType(), &retType) + ")");
- niceprint("Parameter count", funType->getNumParams());
- for (const clang::QualType &type : funType->getParamTypes()) {
- niceprint(" " + type2string(type, &type),
- type2string(type.getCanonicalType(), &type) + " (" + type2char(type.getCanonicalType(), &type) + ")");
- }
- niceprint("Variadic function", funType->isVariadic() ? "yes" : "no");
-
- funTypeStr =
- type2char(retType.getCanonicalType(), &retType) +
- ((funType->getNumParams() == 0)
- ? std::string("Fv") : std::accumulate(funType->getParamTypes().begin(), funType->getParamTypes().end(), std::string("F"),
- [](const std::string &acc, const clang::QualType &qual){ return acc + type2char(qual.getCanonicalType(), &qual); }));
- if (funType->isVariadic()) funTypeStr += "V";
- valid = !funType->isVariadic() &&
- std::accumulate(funType->getParamTypes().begin(), funType->getParamTypes().end(), isTypeValid(retType.getCanonicalType(), &retType),
- [](bool acc, const clang::QualType &qual){ return acc && isTypeValid(qual.getCanonicalType(), &qual); });
- }
-
- niceprint("Conclusion", "");
- niceprint("Function final name", funName);
- niceprint("Function type", funTypeStr);
- niceprint("Valid function type", valid ? "yes" : "no");
- std::cout << "\n";
-
- funMap[funName] = std::make_pair(funTypeStr, valid);
- funList.push_back(funName);
- }
-
- return true;
- }
-};
-
-class Consumer : public clang::ASTConsumer {
-public:
- Visitor visitor;
-
- Consumer(clang::CompilerInstance &ci) : visitor(ci) {
- }
-
- void HandleTranslationUnit(clang::ASTContext &context) override {
- visitor.TraverseDecl(context.getTranslationUnitDecl());
- }
-};
-
-class Action : public clang::ASTFrontendAction {
-public:
- virtual std::unique_ptr<clang::ASTConsumer> CreateASTConsumer(clang::CompilerInstance &ci, llvm::StringRef inFile) override {
- return std::make_unique<Consumer>(ci);
- }
-};
-
-int main(int argc, const char **argv) {
- if (argc < 2) {
- std::cerr << "Usage: " << argv[0] << " (filenames) -- [-I...]" << std::endl;
- return 2;
- }
-
- /*int fakeargc = argc + 1;
- const char **fakeargv = new const char*[fakeargc];
- memcpy(fakeargv, argv, argc * sizeof(char*));
- fakeargv[fakeargc - 1] = "--";*/
- llvm::cl::OptionCategory opcat{""};
- clang::tooling::CommonOptionsParser op{argc, argv, opcat};
- std::vector<std::string> paths; for (int i = 1; i < argc; ++i) paths.push_back(argv[i]);
-
- clang::tooling::ClangTool tool{op.getCompilations(), paths};
-
- tool.run(clang::tooling::newFrontendActionFactory<Action>().get());
-
- std::cout << "Done, outputing output.h" << std::endl;
- std::sort(funList.begin(), funList.end());
- std::fstream file{"output.h", std::ios_base::out};
- for (const std::string &funName : funList) {
- if (!funMap[funName].second) {
- file << "//";
- }
- file << "GO(" << funName << ", " << funMap[funName].first << ")\n";
- }
-
- return 0;
-}
diff --git a/LLVMprivateGenerator/registered_structs.cpp b/LLVMprivateGenerator/registered_structs.cpp
deleted file mode 100644
index 0473deb..0000000
--- a/LLVMprivateGenerator/registered_structs.cpp
+++ /dev/null
@@ -1,267 +0,0 @@
-#include <string>
-
-#define ALL START() \
- /* libc */ \
- STRUCT("_IO_FILE", "a FILE") \
- STRUCT("_G_fpos_t", "a file position") \
- STRUCT("sockaddr", "a socket address") \
- STRUCT("itimerspec", "an itimerspec") \
- STRUCT("timespec", "a timespec") \
- STRUCT("itimerval", "an itimerval") \
- STRUCT("timeval", "a timeval") \
- STRUCT("timex", "a timex") \
- STRUCT("timezone", "a timezone") \
- STRUCT("dirent", "a dirent") \
- STRUCT("dirent64", "a dirent64") \
- STRUCT("__dirstream", "a dir stream") \
- STRUCT("tm", "a time structure (tm)") \
- STRUCT("cmsghdr", "a cmsghdr") \
- STRUCT("msghdr", "a msghdr") \
- STRUCT("rpcent", "an rpcent") \
- STRUCT("random_data", "a random_data structure") \
- STRUCT("drand48_data", "a drand48_data structure") \
- STRUCT("termios", "a termios") \
- STRUCT("iovec", "an iovec") \
- STRUCT("file_handle", "a file handle") \
- STRUCT("lconv", "an lconv") \
- STRUCT("__locale_struct", "a locale structure") \
- STRUCT("aliasent", "an alias") \
- STRUCT("fstab", "an fstab") \
- STRUCT("group", "a group") \
- STRUCT("hostent", "a hostent") \
- STRUCT("protoent", "a protoent") \
- STRUCT("passwd", "a password") \
- STRUCT("spwd", "an spwd") \
- STRUCT("ttyent", "a ttyent") \
- STRUCT("utmp", "an utmp structure") \
- STRUCT("utmpx", "an utmpx structure") \
- STRUCT("ifaddrs", "an ifaddrs structure") \
- STRUCT("statfs", "a statfs structure") \
- STRUCT("statfs64", "a statfs64 structure") \
- STRUCT("statvfs", "a statvfs structure") \
- STRUCT("statvfs64", "a statvfs64 structure") \
- STRUCT("timeb", "a timeb structure") \
- STRUCT("_ftsent", "an _ftsent structure") \
- STRUCT("sysinfo", "a sysinfo structure") \
- STRUCT("rlimit", "an rlimit structure") \
- STRUCT("rlimit64", "an rlimit64 structure") \
- STRUCT("rusage", "an rusage structure") \
- STRUCT("entry", "an entry structure") \
- STRUCT("pollfd", "a pollfd structure") \
- STRUCT("re_pattern_buffer", "a re_pattern_buffer structure") \
- STRUCT("sembuf", "a sembuf structure") \
- STRUCT("tms", "a tms structure") \
- STRUCT("utsname", "an utsname structure") \
- STRUCT("utimbuf", "an utimbuf structure") \
- STRUCT2("__va_list_tag", "__va_list_tag (aka, a va_list)", 'A') \
- /* ncurses */ \
- STRUCT("_win_st", "a _win_st structure") \
- STRUCT("MEVENT", "an MEVENT structure") \
- TYPEDEF("cchar_t", "a cchar_t") \
- /* zlib */ \
- STRUCT("gz_header_s", "a gz_header_s structure") \
- STRUCT("gzFile_s", "a gzFile_s structure") \
- STRUCT("z_stream_s", "a z_stream_s structure") \
- \
- END()
-
-#define START()
-#define STRUCT(s, ret) if (str == s) { return 'p'; } else
-#define STRUCT2(s, ret, c) if (str == s) { return c; } else
-#define TYPEDEF(s, ret) if (str == s) { return 'p'; } else
-#define END() { return 0; }
-char ptr2char(const std::string &str) {
- /*if ((str == "_IO_FILE")
- || (str == "_G_fpos_t")
- || (str == "sockaddr")
- || (str == "itimerspec")
- || (str == "timespec")
- || (str == "itimerval")
- || (str == "timeval")
- || (str == "timex")
- || (str == "timezone")
- || (str == "dirent")
- || (str == "dirent64")
- || (str == "__dirstream")
- || (str == "tm")
- || (str == "cmsghdr")
- || (str == "msghdr")
- || (str == "rpcent")
- || (str == "random_data")
- || (str == "drand48_data")
- || (str == "termios")
- || (str == "iovec")
- || (str == "file_handle")
- || (str == "lconv")
- || (str == "__locale_struct")
- || (str == "aliasent")
- || (str == "fstab")
- || (str == "group")
- || (str == "hostent")
- || (str == "protoent")
- || (str == "passwd")
- || (str == "spwd")
- || (str == "ttyent")
- || (str == "utmp")
- || (str == "utmpx")
- || (str == "ifaddrs")
- || (str == "statfs")
- || (str == "statfs64")
- || (str == "statvfs")
- || (str == "timeb")
- || (str == "_ftsent")
- || (str == "sysinfo")
- || (str == "rlimit")
- || (str == "rlimit64")
- || (str == "rusage")
- || (str == "entry")
- || (str == "pollfd")
- || (str == "re_pattern_buffer")
- || (str == "sembuf")
- || (str == "tms")
- || (str == "utsname")
- || (str == "utimbuf")
- // ncurses
- || (str == "_win_st")
-
- || (str == "cchar_t")
- ) {
- // FILE*, fpos_t*, ...
- return 'p';
- } else if (str == "__va_list_tag") {
- return 'A';
- } else {
- return 0;
- }*/
- ALL
-}
-#undef END
-#undef TYPEDEF
-#undef STRUCT2
-#undef STRUCT
-#undef START
-
-#define START()
-#define STRUCT(s, ret) if (str == s) { return ret; } else
-#define STRUCT2(s, ret, c) if (str == s) { return ret; } else
-#define TYPEDEF(s, ret) if (str == s) { return ret; } else
-#define END() return "";
-const char *ptr2str(const std::string &str) {
- /*if (str == "_IO_FILE") {
- return "a FILE";
- } else if (str == "_G_fpos_t") {
- return "a file position";
- } else if (str == "sockaddr") {
- return "a socket address";
- } else if (str == "itimerspec") {
- return "an itimerspec";
- } else if (str == "timespec") {
- return "a timespec";
- } else if (str == "itimerval") {
- return "an itimerval";
- } else if (str == "timeval") {
- return "a timeval";
- } else if (str == "timex") {
- return "a timex";
- } else if (str == "timezone") {
- return "a timezone";
- } else if (str == "dirent") {
- return "a dirent";
- } else if (str == "dirent64") {
- return "a dirent64";
- } else if (str == "__dirstream") {
- return "a dir stream";
- } else if (str == "tm") {
- return "a time structure (tm)";
- } else if (str == "cmsghdr") {
- return "a cmsghdr";
- } else if (str == "msghdr") {
- return "a msghdr";
- } else if (str == "rpcent") {
- return "an rpcent";
- } else if (str == "random_data") {
- return "a random_data structure";
- } else if (str == "drand48_data") {
- return "a drand48_data structure";
- } else if (str == "termios") {
- return "a termios";
- } else if (str == "iovec") {
- return "an iovec";
- } else if (str == "file_handle") {
- return "a file handle";
- } else if (str == "lconv") {
- return "an lconv";
- } else if (str == "__locale_struct") {
- return "a locale structure";
- } else if (str == "aliasent") {
- return "an alias";
- } else if (str == "fstab") {
- return "an fstab";
- } else if (str == "group") {
- return "a group";
- } else if (str == "hostent") {
- return "a hostent";
- } else if (str == "protoent") {
- return "a protoent";
- } else if (str == "passwd") {
- return "a password";
- } else if (str == "spwd") {
- return "an spwd";
- } else if (str == "ttyent") {
- return "a ttyent";
- } else if (str == "utmp") {
- return "an utmp structure";
- } else if (str == "utmpx") {
- return "an utmpx structure";
- } else if (str == "ifaddrs") {
- return "an ifaddrs structure";
- } else if (str == "statfs") {
- return "a statfs structure";
- } else if (str == "statfs64") {
- return "a statfs64 structure";
- } else if (str == "statvfs") {
- return "a statvfs structure";
- } else if (str == "statvfs64") {
- return "a statvfs64 structure";
- } else if (str == "timeb") {
- return "a timeb structure";
- } else if (str == "_ftsent") {
- return "an _ftsent structure";
- } else if (str == "sysinfo") {
- return "a sysinfo structure";
- } else if (str == "rlimit") {
- return "an rlimit structure";
- } else if (str == "rlimit64") {
- return "an rlimit64 structure";
- } else if (str == "rusage") {
- return "an rusage structure";
- } else if (str == "entry") {
- return "an entry structure";
- } else if (str == "pollfd") {
- return "a pollfd structure";
- } else if (str == "re_pattern_buffer") {
- return "a re_pattern_buffer structure";
- } else if (str == "sembuf") {
- return "a sembuf structure";
- } else if (str == "tms") {
- return "a tms structure";
- } else if (str == "utsname") {
- return "an utsname structure";
- } else if (str == "utimbuf") {
- return "an utimbuf structure";
- } else if (str == "__va_list_tag") {
- return "__va_list_tag (aka, a va_list)";
- // ncurses
- } else if (str == "_win_st") {
- return "a _win_st structure";
-
- } else if (str == "cchar_t") {
- return "a cchar_t";
- } else return "";*/
- ALL
-}
-#undef END
-#undef TYPEDEF
-#undef STRUCT2
-#undef STRUCT
-#undef START
diff --git a/docs/README.md b/README.md
index ea1c5b4..a604c05 100644
--- a/docs/README.md
+++ b/README.md
@@ -1,8 +1,8 @@
-![Official logo](img/Box64Logo.png "Official Logo")
+![Official logo](docs/img/Box64Logo.png "Official Logo")
Linux Userspace x86_64 Emulator with a twist
-[View changelog](https://github.com/ptitSeb/box64/blob/main/docs/CHANGELOG.md) | [中文](https://github.com/ptitSeb/box64/blob/main/docs/README_CN.md) | [Report an error](https://github.com/ptitSeb/box64/issues/new)
+[View changelog](https://github.com/ptitSeb/box64/blob/main/docs/CHANGELOG.md) | [中文](https://github.com/ptitSeb/box64/blob/main/README_CN.md) | [Українська](https://github.com/ptitSeb/box64/blob/main/README_UK.md) | [Report an error](https://github.com/ptitSeb/box64/issues/new)
![build](https://app.travis-ci.com/ptitSeb/box64.svg?branch=main) ![stars](https://img.shields.io/github/stars/ptitSeb/box64) ![forks](https://img.shields.io/github/forks/ptitSeb/box64) ![contributors](https://img.shields.io/github/contributors/ptitSeb/box64) ![prs](https://img.shields.io/github/issues-pr/ptitSeb/box64) ![issues](https://img.shields.io/github/issues/ptitSeb/box64)
@@ -14,11 +14,11 @@ You can find many Box64 videos on the [MicroLinux](https://www.youtube.com/chann
Since Box64 uses the native versions of some "system" libraries, like libc, libm, SDL, and OpenGL, it's easy to integrate and use with most applications, and performance can be surprisingly high in many cases. Take a look at thoses bench analysis for an example [here](https://box86.org/index.php/2021/06/game-performances/).
-Box64 integrates with DynaRec (dynamic recompiler) for the ARM64 platform, providing a speed boost between 5 to 10 times faster than using only the interpreter. Some high level information on how DynaRec works can be found [here](https://box86.org/2021/07/inner-workings-a-high%e2%80%91level-view-of-box86-and-a-low%e2%80%91level-view-of-the-dynarec/).
+Box64 integrates with DynaRec (dynamic recompiler) for the ARM64 and RV64 platform, providing a speed boost between 5 to 10 times faster than using only the interpreter. Some high level information on how DynaRec works can be found [here](https://box86.org/2021/07/inner-workings-a-high%e2%80%91level-view-of-box86-and-a-low%e2%80%91level-view-of-the-dynarec/).
-Some x64 internal opcodes use parts of "Realmode X86 Emulator Library", see [x64primop.c](../src/emu/x64primop.c) for copyright details
+Some x64 internal opcodes use parts of "Realmode X86 Emulator Library", see [x64primop.c](src/emu/x64primop.c) for copyright details
-<img src="img/Box64Icon.png" width="96" height="96">
+<img src="docs/img/Box64Icon.png" width="96" height="96">
Logo and Icon made by @grayduck, thanks!
@@ -29,7 +29,7 @@ Usage
There are a few environment variables to control the behaviour of Box64.
-See [here](USAGE.md) for all the environment variables and what they do.
+See [here](docs/USAGE.md) for all the environment variables and what they do.
Note: Box64's Dynarec uses a mechanism with Memory Protection and a SegFault signal handler to handle JIT code. In simpler terms, if you want to use GDB to debug a running program that use JIT'd code (like mono/Unity3D), you will still have many "normal" segfaults triggering. It is suggested to use something like `handle SIGSEGV nostop` in GDB to not stop at each segfault, and maybe put a breakpoint inside `my_memprotectionhandler` in `signals.c` if you want to trap SegFaults.
@@ -37,14 +37,15 @@ Note: Box64's Dynarec uses a mechanism with Memory Protection and a SegFault sig
Compiling/Installation
----
-> Compilation instructions can be found [here](COMPILE.md).
+> Compilation instructions can be found [here](docs/COMPILE.md)\
+> Instructions for installing Wine for Box64 can be found [here](docs/X64WINE.md)
----
Version history/Change log
----
-The change log is available [here](CHANGELOG.md).
+The change log is available [here](docs/CHANGELOG.md).
----
@@ -85,23 +86,22 @@ GTK libraries are now wrapped on box64, both gtk2 and gtk3.
Notes about Steam
----
-Note that Steam is a hybrid 32-bit / 64-bit. You NEED box86 to run Steam, as the client app is a 32-bit binary. It also uses a 64-bit local server binaries, but like most stuff using libcef/chromium, it's not working correctly on box64 for now.
-So, no Steam for now on box64.
+Note that Steam is a hybrid 32-bit / 64-bit. You NEED box86 to run Steam, as the client app is a 32-bit binary. It also uses a 64-bit local server binaries, and that steamwebhelper process is now mendatory, even on the "small mode". And that process will eat lots of memory. So machine with less the 6Gb of RAM will need a swapfile tp use Steam.
----
Notes about Wine
----
-Wine64 is supported on box64. Proton should also work. Be aware that 64-bit Wine also includes 32-bit components, to be able to run 32-bit Windows programs. The 32-bit apps will need box86 and will not run without it. On a system where both box64 and box86 are present and working, a wine 64-bit setup can run both 32-bit and 64-bit Windows programs (just use `wine` and `wine64` respectively).
-Note that the new 32bits PE in 64bits process that the Wine time in currently implementing in Wine 7.+ is not yet supported. I tested Wine 7.5 64bits and it worked, but more recent version will probably just not work yet.
+Wine64 is supported on box64. Proton too. Be aware that 64-bit Wine also includes 32-bit components, to be able to run 32-bit Windows programs. The 32-bit apps will need box86 and will not run without it. On a system where both box64 and box86 are present and working, a wine 64-bit setup can run both 32-bit and 64-bit Windows programs (just use `wine` and `wine64` respectively).
+Note that the new 32bits PE in 64bits process that the Wine time in currently implementing in Wine 7.+ is now supported, but the support is quite young so there might be some residual issues.
----
Notes about Vulkan
----
-Box64 wraps Vulkan libraries, but note that it as only been tested with a RX550 card, so some extensions may be missing depending on your graphics card.
+Box64 wraps Vulkan libraries, but note that it as mostly been tested with a AMD RX550 card and on the Freedreno driver, so some extensions may be missing depending on your graphics card.
----
@@ -114,6 +114,7 @@ So, in no particular order, I want to thank:
* For their major code contribution: rajdakin, mogery
* For their major financial contribution: FlyingFathead, stormchaser3000, dennis1248, sll00, [libre-computer-project](https://libre.computer/)
* For hardware contribution and LoongArch migration: [xiaoji](https://www.linuxgame.cn/), Deepin Beijing Develop Team
+ * For their major code contribution on the RV64 Dynarec: ksco, xctan
* For their hardware contribution: [Radxa](https://rockpi.org/), [Pine64](https://www.pine64.org/), [StarFive](https://rvspace.org/)
* For their continous advertisement of box64 project: salva ([microLinux](https://www.youtube.com/channel/UCwFQAEj1lp3out4n7BeBatQ)), [PILab](https://www.youtube.com/channel/UCgfQjdc5RceRlTGfuthBs7g)/[TwisterOS](https://twisteros.com/) team, [The Byteman](https://www.youtube.com/channel/UCEr8lpIJ3B5Ctc5BvcOHSnA), [NicoD](https://www.youtube.com/channel/UCpv7NFr0-9AB5xoklh3Snhg), ekianjo ([Boilingsteam](https://boilingsteam.com/))
diff --git a/README_CN.md b/README_CN.md
new file mode 100644
index 0000000..caeb24e
--- /dev/null
+++ b/README_CN.md
@@ -0,0 +1,113 @@
+# box64
+
+![Official logo](docs/img/Box64Logo.png "Official Logo")
+Linux 上用户空间的 x86_64 应用模拟器(支持运行原生库)
+
+----
+![box64 build status](https://app.travis-ci.com/ptitSeb/box64.svg?branch=main)
+
+[English](docs/README.md) | [Українська](https://github.com/ptitSeb/box64/blob/main/README_UK.md)
+
+Box64 可以在非 x86_64 Linux 系统(比如 ARM64)上运行 x86_64 Linux 程序(比如游戏),注意主机系统需要是 64 位小端。
+
+您可以在 [MicroLinux](https://www.youtube.com/channel/UCwFQAEj1lp3out4n7BeBatQ)、[Pi Labs](https://www.youtube.com/channel/UCgfQjdc5RceRlTGfuthBs7g) 和 [The Byteman](https://www.youtube.com/channel/UCEr8lpIJ3B5Ctc5BvcOHSnA) YouTube 频道上找到许多 Box64 视频。
+
+由于 Box64 使用一些“系统”库的原生版本,如 libc、libm、SDL 和 OpenGL 等,因此很容易与大多数应用程序集成和使用,并且在许多情况下性能会相当不错。可以在[这里](https://box86.org/index.php/2021/06/game-performances/)查看一些性能测试的样例。
+
+Box64 集成了适用于 ARM64 平台的 DynaRec(动态重编译器),速度可以比纯解释模式快 5 到 10 倍。可以在[这里](https://box86.org/2021/07/inner-workings-a-high%E2%80%91level-view-of-box86-and-a-low%E2%80%91level-view-of-the-dynarec/)找到有关 DynaRec 工作原理的一些信息。
+
+一些 x64 内部操作码使用 “Realmode X86 Emulator Library” 的部分内容,有关版权详细信息,请参见 [x64primop.c](../src/emu/x64primop.c)。
+
+<img src="docs/img/Box64Icon.png" width="96" height="96">
+
+LOGO 由 @grayduck 制作,感谢!
+
+----
+
+使用方法
+----
+
+有若干环境变量可以控制 Box64 的行为。
+
+可在[这里](docs/USAGE.md)查看所有环境变量及其作用。
+
+注意:Box64 的 Dynarec 使用具有内存保护和段错误信号处理的机制来执行 JIT 代码。所以,如果想使用 GDB 调试使用 JIT 代码的程序(如 Mono/Unity3D),这会触发许多“正常”的段错误。建议在 GDB 中使用类似 `handle SIGSEGV nostop` 来防止它每个段错误处停止。如果你想捕获段错误,可以在 `signals.c` 的 `my_memprotectionhandler` 中设置断点。
+
+----
+
+编译/安装
+----
+
+编译说明可以在[这里](docs/COMPILE.md)查看。
+
+----
+
+版本历史
+----
+
+版本日志在[这里](docs/CHANGELOG.md)。
+
+----
+
+32位平台的注意事项
+----
+
+因为 Box64 的工作原理是直接将函数调用从 x86_64 转换为主机系统,所以主机系统(运行 Box64 的系统)需要有 64 位库。Box64 不包含任何 64 位 <-> 32 位的转换。
+
+所以 box64 只能运行 64 位的 Linux 二进制。对于 32 位二进制则需要使用 box86 来运行(它在 64 位操作系统上使用了 multiarch 和 proot 等技巧来实现运行)。请注意,许多(基于 mojo 的)安装程序在检测到 ARM64 操作系统时将回退到 “x86”,因此即使存在 x86_64 版本,也会尝试使用 box86。这时你可以使用一个假的 `uname`,当它的参数为 `-m` 时返回 `x86_64`。
+
+----
+
+关于 Unity 游戏模拟的注意事项
+----
+
+运行 Unity 游戏应该没什么问题,但还应该注意,许多 Unity3D 游戏需要 OpenGL 3+,这在 ARM SBC 上可能会比较棘手。同时许多较新的 Unity3D游戏(如 KSP)也使用 BC7 压缩纹理,很多 ARM 的集成显卡并不支持。
+
+> 提示:如果游戏开始后没有显示任何东西就退出了,在 Pi4 上可以使用 `MESA_GL_VERSION_OVERRIDE=3.2`,在 Panfrost 上则可以使用 `PAN_MESA_DEBUG=gl3` 来使用更高的配置。
+
+----
+
+关于GTK程序的注意事项
+----
+
+box64 封装了 GTK,包括 gtk2 和 gtk3。
+
+----
+
+关于 Steam 的注意事项
+----
+
+请注意,Steam 是 32/64 位的混合体,所以还需要 box86 才能运行,因为客户端应用程序是 32 位的。它还使用 64 位本地服务器,但与大多数使用 libcef/chromium 的东西一样,它目前无法在 box64 上正常工作。所以,现在 box64 上暂时不能运行 Steam。
+
+----
+
+关于 Wine 的注意事项
+----
+
+box64 支持 Wine64,Proton 应该也能运行。请注意,64 位 Wine 包含有 32 位组件,以便能够运行 32 位 Windows 程序。32 位应用程序需要 box86,否则无法运行。在 box64 和 box86 都存在并工作的系统上,64 位的 Wine 可以同时运行 32 位和 64 位 Windows 程序(分别使用 `wine` 和 `wine64`)。请注意,目前在 Wine 7.+ 中实现的 Wine 时间在 64 位进程中的新 32bit PE 尚不支持。我测试了 Wine 7.5 64 位可以正常工作,但是更新的版本可能还不行。
+
+----
+
+关于 Vulkan 注意事项
+----
+
+Box64 封装了 Vulkan 库,但请注意,它仅在 RX550 显卡上进行过测试,因此根据您的显卡,某些扩展可能会丢失。
+
+----
+
+结语
+----
+
+我要感谢所有为 box64 开发做出贡献的人。
+贡献方式有很多种:代码贡献、财务帮助、捐赠捐赠和广告合作!
+以下感谢不分先后:
+
+ * 代码贡献:rajdakin, mogery
+ * 财务帮助:FlyingFathead, stormchaser3000, dennis1248, sll00, [libre-computer-project](https://libre.computer/)
+ * 硬件捐赠和 LoongArch 迁移:[xiaoji](https://www.linuxgame.cn/), Deepin Beijing Develop Team
+ * 硬件捐赠:[Radxa](https://rockpi.org/), [Pine64](https://www.pine64.org/), [StarFive](https://rvspace.org/)
+ * 为本项目持续的宣传:salva ([microLinux](https://www.youtube.com/channel/UCwFQAEj1lp3out4n7BeBatQ)), [PILab](https://www.youtube.com/channel/UCgfQjdc5RceRlTGfuthBs7g)/[TwisterOS](https://twisteros.com/) team, [The Byteman](https://www.youtube.com/channel/UCEr8lpIJ3B5Ctc5BvcOHSnA), [NicoD](https://www.youtube.com/channel/UCpv7NFr0-9AB5xoklh3Snhg), ekianjo ([Boilingsteam](https://boilingsteam.com/))
+
+我还要感谢很多人,即使他们只参与了一次本项目。
+
+(如果你的项目中使用了Box64,请不要忘记提及!)
diff --git a/README_UK.md b/README_UK.md
new file mode 100644
index 0000000..a56624e
--- /dev/null
+++ b/README_UK.md
@@ -0,0 +1,119 @@
+![Official logo](docs/img/Box64Logo.png "Official Logo")
+
+Емулятор простіра користувача x86_64 із родзинкою
+
+[Дивитись журнал змін](https://github.com/ptitSeb/box64/blob/main/docs/CHANGELOG.md) | [中文](https://github.com/ptitSeb/box64/blob/main/README_CN.md) | [Українська](https://github.com/ptitSeb/box64/blob/main/README_UK.md) | [Повідомити про помилку](https://github.com/ptitSeb/box64/issues/new)
+
+![build](https://app.travis-ci.com/ptitSeb/box64.svg?branch=main) ![stars](https://img.shields.io/github/stars/ptitSeb/box64) ![forks](https://img.shields.io/github/forks/ptitSeb/box64) ![contributors](https://img.shields.io/github/contributors/ptitSeb/box64) ![prs](https://img.shields.io/github/issues-pr/ptitSeb/box64) ![issues](https://img.shields.io/github/issues/ptitSeb/box64)
+
+----
+
+Box64 дозволяє запускати x86_64 Linux програми (наприклад, ігри) на системах Linux відмінних від x86_64, наприклад ARM (хост-система має мати 64-розрядний порядок редагування).
+
+Ви можете знайти багато відео про Box64 в YouTube каналах [MicroLinux](https://www.youtube.com/channel/UCwFQAEj1lp3out4n7BeBatQ), [Pi Labs](https://www.youtube.com/channel/UCgfQjdc5RceRlTGfuthBs7g) або [The Byteman](https://www.youtube.com/channel/UCEr8lpIJ3B5Ctc5BvcOHSnA)
+
+Оскільки Box64 використовує рідні версії деяких «системних» бібліотек, таких як libc, libm, SDL і OpenGL, його легко інтегрувати та використовувати з більшістю програм, а продуктивність у багатьох випадках може бути напрочуд високою. Подивіться на цей стендовий аналіз для прикладу [тут](https://box86.org/index.php/2021/06/game-performances/).
+
+Box64 інтегрується з DynaRec (динамічний рекомпілятор) для платформ ARM64 і RV64 забезпечуючи підвищення швидкості в 5-10 разів, ніж використання лише інтерпретатора. Деякі високорівневі відомості про те, як працює DynaRec, можна знайти [тут](https://box86.org/2021/07/inner-workings-a-high%e2%80%91level-view-of-box86-and-a-low%e2%80%91level-view-of-the-dynarec/).
+
+Деякі внутрішні коди операцій x64 використовують частини «Бібліотеки емулятора Realmode X86», дивіться [x64primop.c](src/emu/x64primop.c) для детальної інформації про авторські права.
+
+<img src="docs/img/Box64Icon.png" width="96" height="96">
+
+Логотип і піктограма зроблені @grayduck, дякую!
+
+----
+
+Використання
+----
+
+Є кілька змінних середовища для керування поведінкою Box64.
+
+Дивіться [тут](docs/USAGE.md) для перегляду всіх змінних середовища та того, що вони роблять.
+
+Примітка: Dynarec від Box64 використовує механізм із захистом пам’яті та обробником сигналу помилки сегментів для обробки JIT коду. Простіше кажучи, якщо ви хочете використовувати GDB для налагодження запущеної програми, яка використовує JIT-код (наприклад, mono/Unity3D), ви все одно матимете багато «звичайних» помилок сегментів. Пропонується використовувати щось на зразок `handle SIGSEGV nostop` в GDB, щоб не зупинятися на кожній помилці сегмента, і, можливо, поставити точку зупину всередині `my_memprotectionhandler` в `signals.c`, якщо ви хочете перехопити помилки сегментів.
+
+----
+Компіляція/Встановлення
+----
+> Інструкцію зі складання Box64 можна знайти [тут](docs/COMPILE.md).\
+> Інструкцію з встановлення Wine для Box64 можна знайти [тут](docs/X64WINE.md).
+
+----
+
+Історія версій/Журнал змін
+----
+
+Історія версій доступна [тут](docs/CHANGELOG.md).
+
+----
+
+Примітки щодо 32 бітних платформ
+----
+Оскільки Box64 працює шляхом прямого перекладу викликів функцій з x86_64 на хост-систему, хост-система (та, на якій працює Box64) повинна мати 64-розрядні бібліотеки. Box64 не містить 64-біт <-> 32-біт перекладу.
+
+Також розумійте що Box64 запускатиме лише 64-розрядні двійкові Linux файли. Для 32-розрядних двійкових файлів вам потрібен Box86 (з усіма хитрощами з мультиархітектурною системою або корінними правами). Зауважте, що багато інсталяторів (на основі mojo) повертаються до "x86" при виявленні ОС ARM64, і тому намагатимуться використовувати Box86 для налаштування, навіть якщо існує версія x86_64. Ви можете зламати свій шлях за допомогою фальшивого "uname", який повертає "x86_64", коли аргумент "-m"
+
+----
+
+Примітки щодо конфігурації Box64
+----
+
+Обидва файли мають однаковий синтаксис і в основному є файлами ini. Розділ у квадратних дужках визначає назву процесу, а решта — встановлють змінну середовища. Подивіться [використання](USAGE.md), щоб дізнатися, які параметри можна завдати. Box64 поставляється з файлом за замовчуванням, який слід встановити для кращої стабільності. Файл знаходиться в `system/box64.box64rc` і має бути встановлен в `/etc/box64.box64rc`. Якщо з певних причин ви не хочете встановлювати цей файл у `/etc`, принаймні скопіюйте його в `~/.box64rc` або гра може не працювати належним чином. Зауважте, що пріоритетом є: `~/.bashrc` > `/etc/box64.box64rc` > командний рядок
+Таким чином, ваші налаштування в `~/.bashrc` можуть замінити налаштування з вашого командного рядка...
+
+----
+
+Примітки щодо емуляції ігор Unity
+----
+
+Запуск ігор Unity має працювати, але ви також повинні зауважити, що для багатьох ігор Unity3D потрібен OpenGL 3+, який може бути складно забезпечити на ARM SBC (одноплатних комп’ютерах). Крім того, багато нових ігор Unity3D (наприклад, KSP) використовують стиснуті текстури BC7, які не підтримуються багатьма інтегрованими GPU ARM.
+Підказка: в Pi4 використовуйте `MESA_GL_VERSION_OVERRIDE=3.2`, а в Panfrost — `PAN_MESA_DEBUG=gl3`, щоб використовувати вищий профіль, якщо гра запускається, а потім завершується, перш ніж щось показує.
+
+----
+
+Примітки щодо програм GTK
+----
+
+Бібліотеки GTK2 і GTK3 тепер використовуються в Box64.
+
+----
+
+Примітки щодо Steam
+----
+
+Зауважте, що Steam є гібридом 32-біт / 64-біт. Вам ПОТРІБЕН box86, щоб запустити Steam, оскільки клієнта є 32-розрядною двійковою програмою. Він також використовує 64-розрядні двійкові файли локального сервера, і цей процес steamwebhelper тепер є обов’язковим навіть у «малому режимі». І цей процес з’їсть багато оперативної пам’яті, таким чином машині з 6 Гб оперативної пам’яті знадобиться файл підкачки для використання Steam.
+
+----
+
+Примітки щодо Wine
+----
+
+Wine64 підтримується Box64, Proton теж. Майте на увазі, що 64-розрядний Wine також містить 32-розрядні компоненти щоб мати можливість запускати 32-розрядні програми Windows. Для 32-розрядних програм потрібен Box86, і вони не працюватимуть без нього. У системі, де присутні і працюють Box64, і Box86, 64-розрядне встановлення Wine може запускати як 32-розрядні, так і 64-розрядні програми Windows (просто використовуйте `wine` і `wine64` відповідно).
+Зауважте, що новий 32-бітний PE в 64-бітному процесі, який Wine зараз реалізує у Wine 7+ тепер підтримується, але підтримка є досить молодою тому можуть виникнути деякі проблеми.
+
+----
+
+Примітки щодо Vulkan
+----
+
+Box64 використовує бібліотеки Vulkan, але зауважте що він тестувався з картою AMD Radeon RX550 і драйвером Freedreno, тому деякі розширення можуть бути відсутні залежно від вашої відеокарти.
+
+----
+
+Останнє слово
+----
+
+Я хочу подякувати всім, хто зробив внесок у розвиток box64.
+Є багато способів зробити внесок: внесок коду, фінансовий внесок, апаратне забезпечення та реклама!
+Отже, без особливого порядку, я хочу подякувати:
+* За основний внесок у код: rajdakin, mogery
+* За великий фінансовий внесок: FlyingFathead, stormchaser3000, dennis1248, sll00, [libre-computer-project](https://libre.computer/)
+* За апаратне забезпечення та міграцію LoongArch: [xiaoji](https://www.linuxgame.cn/), команда розробників Deepin Beijing
+* За основний внесок у код RV64 Dynarec: ksco, xctan
+* За внесок у апаратне забезпечення: [Radxa](https://rockpi.org/), [Pine64](https://www.pine64.org/), [StarFive](https://rvspace.org/)
+* За безперервну рекламу Box64: salva ([microLinux](https://www.youtube.com/channel/UCwFQAEj1lp3out4n7BeBatQ)), [PILab](https://www.youtube.com/channel/UCgfQjdc5RceRlTGfuthBs7g)/Команда [TwisterOS](https://twisteros.com/), [The Byteman](https://www.youtube.com/channel/UCEr8lpIJ3B5Ctc5BvcOHSnA), [NicoD](https://www.youtube.com/channel/UCpv7NFr0-9AB5xoklh3Snhg), ekianjo ([Boilingsteam](https://boilingsteam.com/))
+
+І я також дякую багатьом іншим людям, які хоч раз брали участь у цьому проекті.
+
+(Якщо ви використовуєте Box64 у своєму проекті, будь ласка, не забудьте згадати про це!)
diff --git a/debian/changelog b/debian/changelog
deleted file mode 100644
index 34603d6..0000000
--- a/debian/changelog
+++ /dev/null
@@ -1,98 +0,0 @@
-box64 (0.2.2) unstable; urgency=low
-
- * Added a hacked version for overriden malloc/free functions, enabling libcef (and derivative) to work.
- * Added rcfile handling: box64 now read "/etc/box64.box64rc" and "~/.box64rc" and apply per process parameters
- * Added BOX64_DYNAREC_CALLRET to optimized CALL/RET opcode using semi-direct native CALL/RET (get more than 10% speedup)
- * Added BOX64_DYNAREC_FORWARD to allow bigger Dynarec block to be build (can get more then 30% of Speedup!)
- * Improved memory protection tracking and signal handling, again
- * Simplified mutex handling (faster, cleaner)
- * Reduce memory used by the memory tracking (memory almost divide by 4 is some critical use case)
- * Added d3dadaptor9 wrapping
- * More wrapped libs (especially on the gtk familly)
- * Improved/fixed some Syscall handling
- * Refactored Strong Memory Model emulation (faster and more accurate)
- * Added some more opcode to ARM64 Dynarec, and fixed some other
- * Some fixes to flags handling in the Dynarec on some special cases
- * Refactor library loading/unloading, with refcount.
- * Some special cases fixes for dlopen (fixes deadcells, maybe others too)
- * Improved mmap mapping, espcially with MAP_32BITS flag
- * More wrapped functions and syscalls
- * Lots of improvment in the Rounding of float & double (Dynarec and Interpretor), and proper handling of denormals when converting to/from 80 bits long double
- * Added specific suppport for RK3588 board (needed some hack in signal handling, probably due to the use of a non mainlined kernel)
- * More support on the RV64 port
- * More support to build under musl environment
-
--- Sebastien Chevalier <ptitseb@box86.org> Thu, 10 Mar 2023 10:20:33 -0500
-
-box64 (0.2.0) unstable; urgency=low
-
- * Wrapped more vulkan function, dxvk 2.0 now works
- * Added support for overriden malloc/free functions
- * Refactor Dynarec memory management, reducing memory footprint (from 20% to 40% of Dynarec size)
- * Improved elf loader
- * Improved dlsym handling with RTLD_NEXT
- * Added BOX64_DYNAREC_SAFEFLAGS to allow finetuning Dynarec generated code handling of flags accross function calls and returns.
- * Added BOX64_BASH to setup x86_64 bash binary, so shell script can be run in x86_64 world
- * Added BOX64_ROLLING_LOG to have details log only on crash
- * Work on alignment for some of pthread structures
- * More wrapped libraries in the gtk family
- * Some fixes on the Dynarec x87 code (fixing a bunch of games like ut2004 or Piczle Puzzle)
- * Improved TLS Size handling (Unity3D games now works)
- * More PageSize Compile options
- * Improved execv family of function to have better box64 integration
- * Added support for wrapped libfuse so AppImage works
- * Adjusted the binfmt integration so AppImage are automaticaly picked
- * Improved FAudio, SDL2, GL (and more) wrapping
- * More wrapped libs, like libEGL.so, to helps emulated Qt4/5 libs to load
- * Improved Signal Handling and memory protection traking
- * Some signature fixes to some wrapped functions (in libc)
- * Added more syscalls
- * Added a lot of new opcodes to the ARM64 Dynarec
- * docs: add instructions for Debian-based Linux by @ryanfortner in #306
- * Fix typos and arch type string by @archanox in #321
- * Fix grammar by @Jai-JAP in #326
- * Enable 64k page size by @martinmanyhats in #334
- * Align address when call mprotect by @wannacu in #336
- * Add wrapped functions needed for 'ls -l'. by @stiltr in #294
- * add 18.04 tegra X1 github actions by @theofficialgman in #345
- * change order of matrix (to preview better under checkmark dropdown by @theofficialgman in #346
- * Backport SDL_DYNAPI_entry wrapper from box86. by @JohnnyonFlame in #374
- * Add SW64 base support by @wannacu in #382
- * fix overzealous replace in wrappers pathnames by @NobodyNada in #415
- * Create X64WINE.md by @WheezyE in #423
- * src: asm: Rename lr & fp registers to their x-equivalents by @fredldotme in #426
- * Malloc override by @ptitSeb in #437
- * Remove dynablocklist by @ptitSeb in #438
- * Fix Pkgbuilds by @Jai-JAP in #452
-
- -- Sebastien Chevalier <ptitseb@box86.org> Thu, 17 Nov 2022 11:20:33 -0500
-
-box64 (0.1.8) unstable; urgency=low
-
- * Added an option to get generated -NAN on SSE2 operation
- * Many small fixes and improvement to get SteamPlay (i.e. proton) working (along with box86)
- * Added some workaround for program calling uname to mimic x86_64 system
- * Added some granularity to mmap, and generic memory protection tracking improvment, to mimic x86 system (for wine stagging and proton)
- * Better clone syscall and libc implementation
- * Improved wrapping of GTK libs
- * More wrapped libs (more gtk libs, like gstreamer-1.0 among other non-gtk libs too)
- * More wrapped functions(with some tricky one, like dladdr1)
- * Some fixes and improvment to some wrapped functions
- * Refactor Dynarec:
- * - better handling of SSE/x87 registers
- * - optimisation to limit float/double conversion
- * - better handling of "internal" jump inside a dynablock
- * - make adding new architecture easier, by sharing as much infrastructure as possible
- * Improved elfloader
- * Improved some tests
- * Improved a bit the "Hotpage" handling and messages
- * Added more dynarec opcodes
- * A few fixes in some Dynarec opcodes
- * A bit more optimisation in some Dynarec opcodes
- * Don't quit on unsupported syscall, return -1 / ENOSYS error
- * Added some more Syscall
- * Wrapped Vulkan library. Vulkan and dxvk now supported!
- * Support building on PPC64LE (interpretor only)
- * Added support for Risc-V (interpretor only)
-
- -- Sebastien Chevalier <ptitseb@box86.org> Tue, 18 Jan 2022 11:20:33 -0500
diff --git a/debian/compat b/debian/compat
deleted file mode 100644
index b4de394..0000000
--- a/debian/compat
+++ /dev/null
@@ -1 +0,0 @@
-11
diff --git a/debian/control b/debian/control
deleted file mode 100644
index 2c442ff..0000000
--- a/debian/control
+++ /dev/null
@@ -1,14 +0,0 @@
-Source: box64
-Section: utils
-Priority: optional
-Maintainer: Ryan Fortner <ryankfortner@gmail.com>
-Build-Depends: cmake, debhelper (>=11~), python3
-Standards-Version: 4.1.4
-Homepage: https://github.com/ptitSeb/box64
-
-Package: box64
-Architecture: any
-Multi-Arch: foreign
-Depends: ${misc:Depends}, ${shlibs:Depends}
-Description: Linux Userspace x86_64 Emulator with a twist, targeted at ARM Linux devices
- Box86 lets you run x86_64 Linux programs (such as games) on non-x86 Linux systems, like ARM (host system needs to be 64bit little-endian).
diff --git a/debian/copyright b/debian/copyright
deleted file mode 100644
index 17840aa..0000000
--- a/debian/copyright
+++ /dev/null
@@ -1,26 +0,0 @@
-Format-Specification: http://dep.debian.net/deps/dep5/
-
-Files: *
-Copyright: © 2022 Sebastien Chevalier
-License: MIT
-
-License: MIT
- Copyright (c) 2018-2021 Sebastien Chevalier ("ptitSeb")
- .
- Permission is hereby granted, free of charge, to any person obtaining a copy
- of this software and associated documentation files (the "Software"), to deal
- in the Software without restriction, including without limitation the rights
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
- copies of the Software, and to permit persons to whom the Software is
- furnished to do so, subject to the following conditions:
- .
- The above copyright notice and this permission notice shall be included in
- all copies or substantial portions of the Software.
- .
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
- THE SOFTWARE.
diff --git a/debian/lintian-override b/debian/lintian-override
deleted file mode 100644
index c670d8f..0000000
--- a/debian/lintian-override
+++ /dev/null
@@ -1 +0,0 @@
-box64: no-manual-page
diff --git a/debian/rules b/debian/rules
deleted file mode 100644
index c9954ee..0000000
--- a/debian/rules
+++ /dev/null
@@ -1,12 +0,0 @@
-#!/usr/bin/make -f
-
-%:
- dh $@
-
-override_dh_auto_configure:
- dh_auto_configure -- \
- -DCMAKE_BUILD_TYPE=RelWithDebInfo \
- -DARM_DYNAREC=1
-
-override_dh_shlibdeps:
- dh_shlibdeps --exclude=libgcc_s.so.1 --exclude=libpng12.so.0 --exclude=libstdc++.so.6
diff --git a/debian/source/format b/debian/source/format
deleted file mode 100644
index 163aaf8..0000000
--- a/debian/source/format
+++ /dev/null
@@ -1 +0,0 @@
-3.0 (quilt)
diff --git a/debian/upstream/metadata b/debian/upstream/metadata
deleted file mode 100644
index c0ed912..0000000
--- a/debian/upstream/metadata
+++ /dev/null
@@ -1,5 +0,0 @@
-Bug-Database: https://github.com/ptitSeb/box64/issues
-Bug-Submit: https://github.com/ptitSeb/box64/issues/new
-Repository: https://github.com/ptitSeb/box64.git
-Repository-Browse: https://github.com/ptitSeb/box64
-Security-Contact: ptitseb@box86.org
diff --git a/debian/watch b/debian/watch
deleted file mode 100644
index 9e7c0da..0000000
--- a/debian/watch
+++ /dev/null
@@ -1 +0,0 @@
-version=3
diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md
index 5ba0203..65bbb35 100644
--- a/docs/CHANGELOG.md
+++ b/docs/CHANGELOG.md
@@ -1,6 +1,31 @@
+v0.2.4
+======
+* Added Dynarec for RISC-V
+* Added partial 32 bits support (WoW64 works)
+* Changed cpuid to display box64
+* Fixed steam, again
+* Improved hacked version for overridden malloc/free functions
+* More wrapped libs
+* More wrapped functions and syscalls
+* Reduced memory footprint
+* Added support for the BIND_NOW flags in ELF files
+* Added RTLD_NOLOAD support
+* Fixed some typos and general cleanup, again
+* Added a cosimulation mode (to compare the behaviour of the dynarec with the interpreter)
+* Added FASTNAN/FASTROUND handling for more opcodes
+* Better float/double/long double handling
+* Better dlopen/dlclose handling
+* More games in the rc file
+* Added BOX64_DYNAREC_MISSING to show only missing opcode, independantly of the log level
+* Added BOX64_RESERVE_HIGH to reserve addresses above 47bits
+* Improved multitreading support
+* Ukrainian translation of the README
+=> Dynarec now support RISC-V, large speedup on RISC-V 64, were games are now playable (like Stardew Valley on a Vision Five 2)
+=> Improved compatibility with more fixes in elf handling, more wrapped libs and functiond, more fixed opcodes and refined profile
+
v0.2.2
======
-* Added a hacked version for overriden malloc/free functions, enabling libcef (and derivative) to work.
+* Added a hacked version for overridden malloc/free functions, enabling libcef (and derivative) to work.
=> Steam Large mode and new BigPicture are working
=> Heroic Launcher is working
* Added rcfile handling: box64 now read `/etc/box64.box64rc` and `~/.box64rc` and apply per process parameters
@@ -22,7 +47,7 @@ v0.2.2
* Some special cases fixes for dlopen (fixes deadcells, maybe others too)
* Improved mmap mapping, espcially with MAP_32BITS flag
* More wrapped functions and syscalls
-* Lots of improvment in the Rounding of float & double (Dynarec and Interpretor), and proper handling of denormals when converting to/from 80 bits long double
+* Lots of improvment in the Rounding of float & double (Dynarec and Interpreter), and proper handling of denormals when converting to/from 80 bits long double
* Added specific suppport for RK3588 board (needed some hack in signal handling, probably due to the use of a non mainlined kernel)
* More support on the RV64 port
* More support to build under musl environment
@@ -30,7 +55,7 @@ v0.2.2
v0.2.0
======
* Wrapped more vulkan function, dxvk 2.0 now works
-* Added support for overriden malloc/free functions
+* Added support for overridden malloc/free functions
* Refactor Dynarec memory management, reducing memory footprint (from 20% to 40% of Dynarec size)
* Improved elf loader
* Improved dlsym handling with RTLD_NEXT
@@ -80,8 +105,8 @@ v0.1.8
* Don't quit on unsupported syscall, return -1 / ENOSYS error
* Added some more Syscall
* Wrapped Vulkan library. Vulkan and dxvk now supported!
-* Support building on PPC64LE (interpretor only)
-* Added support for Risc-V (interpretor only)
+* Support building on PPC64LE (interpreter only)
+* Added support for Risc-V (interpreter only)
v0.1.6
======
@@ -97,7 +122,7 @@ v0.1.6
* Some residual fixes on thread attribute handling
* Better handling of app that want 32bits jumps, like unity3d/mono (thanks mogery)
* More ARM hardware option in CMake (Phytium, NX...)
-* Added loongarch64 support (interpretor only)
+* Added loongarch64 support (interpreter only)
* Some fixes to elfloader
* Added a mecanism to cancel a Dynarec block construction if it triggers a segfault (instead of a crash)
@@ -120,7 +145,7 @@ v0.1.4
v0.1.2
======
* OpenSource!
-* A few more opcode added to the Interpretor and the Dynarec
+* A few more opcode added to the Interpreter and the Dynarec
* Improved Native Function calling
* Added some function to limit allocated memory to 47bits space (for Wine)
* Improved and Fixed the functions to limit allocated memory to 32bits space
@@ -134,7 +159,7 @@ v0.1.0
* Some fixes to a few function signature
* Improvement to Signal handling, and internal mutex handling
* A few fixes to some dynarec opcodes
-* A few fixes to some interpretor opcodes
+* A few fixes to some interpreter opcodes
v0.0.8
======
diff --git a/docs/COMPILE.md b/docs/COMPILE.md
index f0dd088..a14292c 100755..100644
--- a/docs/COMPILE.md
+++ b/docs/COMPILE.md
@@ -1,45 +1,57 @@
Compiling/Installing
----
-#### Debian-based Linux
+### Debian-based Linux
You can use [@ryanfortner](https://github.com/ryanfortner)'s apt repository to install precompiled box64 debs, updated every 24 hours.
```
sudo wget https://ryanfortner.github.io/box64-debs/box64.list -O /etc/apt/sources.list.d/box64.list
-wget -O- https://ryanfortner.github.io/box64-debs/KEY.gpg | sudo gpg --dearmor -o /usr/share/keyrings/box64-debs-archive-keyring.gpg
-sudo apt update && sudo apt install box64 -y
+wget -qO- https://ryanfortner.github.io/box64-debs/KEY.gpg | sudo gpg --dearmor -o /etc/apt/trusted.gpg.d/box64-debs-archive-keyring.gpg
+sudo apt update && sudo apt install box64-arm64 -y
```
Alternatively, you can generate your own package using the [instructions below](https://github.com/ptitSeb/box64/blob/main/docs/COMPILE.md#debian-packaging).
-#### for RK3399
+----
-Using a 64bit OS:
+### The general approach is:
```
git clone https://github.com/ptitSeb/box64
cd box64
-mkdir build; cd build; cmake .. -DRK3399=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo
-make -j4
+mkdir build; cd build; cmake .. ${OPTIONS}
+make -j4
sudo make install
```
If it's the first install, you also need:
```
sudo systemctl restart systemd-binfmt
```
+- You can use `make -j1`, `make -j2` to prevent running out of memory
+- You can also add `-DBAD_SIGNAL=ON` to the cmake command if you are on Linux Kernel mixed with Android, like on RK3588 or maybe Termux
-#### for RK3588 / RK3588S
-
-Using a 64bit OS:
+#### For instance, if you want to build box64 for Generic ARM64 Linux platforms, it would look like this:
```
git clone https://github.com/ptitSeb/box64
cd box64
-mkdir build; cd build; cmake .. -DRK3588=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo
+mkdir build; cd build; cmake .. -D ARM_DYNAREC=ON -D CMAKE_BUILD_TYPE=RelWithDebInfo
make -j4
sudo make install
+sudo systemctl restart systemd-binfmt
```
-If it's the first install, you also need:
+----
+
+#### for RK3399
+
+Using a 64bit OS:
```
-sudo systemctl restart systemd-binfmt
+-D RK3399=1 -D CMAKE_BUILD_TYPE=RelWithDebInfo
+```
+
+#### for RK3588 / RK3588S
+
+Using a 64bit OS:
+```
+-D RK3588=1 -D CMAKE_BUILD_TYPE=RelWithDebInfo
```
#### for Raspberry Pi 3
@@ -55,16 +67,8 @@ run out of memory at some point and need to run the build again.
Still, this can be faster if your build is attended.
```
-git clone https://github.com/ptitSeb/box64
-cd box64
-mkdir build; cd build; cmake .. -DRPI3ARM64=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo
+-D RPI3ARM64=1 -D CMAKE_BUILD_TYPE=RelWithDebInfo
make
-# or e.g. make -j4
-sudo make install
-```
-If it's the first install, you also need:
-```
-sudo systemctl restart systemd-binfmt
```
#### for Raspberry Pi 4
@@ -72,15 +76,7 @@ sudo systemctl restart systemd-binfmt
Warning, you need a 64bit OS:
```
-git clone https://github.com/ptitSeb/box64
-cd box64
-mkdir build; cd build; cmake .. -DRPI4ARM64=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo
-make -j4
-sudo make install
-```
-If it's the first install, you also need:
-```
-sudo systemctl restart systemd-binfmt
+-D RPI4ARM64=1 -D CMAKE_BUILD_TYPE=RelWithDebInfo
```
#### for TEGRA X1
@@ -88,31 +84,16 @@ sudo systemctl restart systemd-binfmt
Using a 64bit OS:
```
-git clone https://github.com/ptitSeb/box64
-cd box64
-mkdir build; cd build; cmake .. -DTEGRAX1=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo
-make -j4
-sudo make install
-```
-If it's the first install, you also need:
-```
-sudo systemctl restart systemd-binfmt
+-D TEGRAX1=1 -D CMAKE_BUILD_TYPE=RelWithDebInfo
```
+
#### for ODROID N2/N2+
Using a 64bit OS:
```
-git clone https://github.com/ptitSeb/box64
-cd box64
-mkdir build; cd build; cmake .. -DODROIDN2=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo
-make -j4
-sudo make install
-```
-If it's the first install, you also need:
-```
-sudo systemctl restart systemd-binfmt
+-D ODROIDN2=1 -D CMAKE_BUILD_TYPE=RelWithDebInfo
```
#### for Snapdragon 845
@@ -120,32 +101,21 @@ sudo systemctl restart systemd-binfmt
Using a 64bit OS:
```
-git clone https://github.com/ptitSeb/box64
-cd box64
-mkdir build; cd build; cmake .. -DSD845=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo
-make -j4
-sudo make install
-```
-If it's the first install, you also need:
-```
-sudo systemctl restart systemd-binfmt
+-D SD845=1 -D CMAKE_BUILD_TYPE=RelWithDebInfo
```
-
-----
#### for Phytium
Using a 64bit OS:
```
-git clone https://github.com/ptitSeb/box64
-cd box64
-mkdir build; cd build; cmake .. -DPHYTIUM=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo
-make -j4
-sudo make install
+-D PHYTIUM=1 -D CMAKE_BUILD_TYPE=RelWithDebInfo
```
-If it's the first install, you also need:
+
+#### for a generic ARM64 machine
+
+Using a 64bit OS:
```
-sudo systemctl restart systemd-binfmt
+-D ARM64=1 -D CMAKE_BUILD_TYPE=RelWithDebInfo
```
#### for M1
@@ -153,38 +123,15 @@ sudo systemctl restart systemd-binfmt
Only test on Asahi for now, using the default "16K page" kernel
```
-git clone https://github.com/ptitSeb/box64
-cd box64
-mkdir build; cd build; cmake .. -DM1=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo
-make -j4
-sudo make install
-```
-If it's the first install, you also need:
-```
-sudo systemctl restart systemd-binfmt
+-D M1=1 -D CMAKE_BUILD_TYPE=RelWithDebInfo
```
-
-#### for Other ARM64 Linux platforms
-
- `mkdir build; cd build; cmake .. -DARM_DYNAREC=ON -DCMAKE_BUILD_TYPE=RelWithDebInfo; make -j$(nproc)`
-
-You can also add `-DBAD_SIGNAL=ON` to the cmake command if you are on Linux Kernel mixed with Android, like on RK3588 or maybe Termux
-
#### for LoongArch
Using a 64bit OS:
```
-git clone https://github.com/ptitSeb/box64
-cd box64
-mkdir build; cd build; cmake .. -DLARCH64=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo
-make -j4
-sudo make install
-```
-If it's the first install, you also need:
-```
-sudo systemctl restart systemd-binfmt
+-D LARCH64=1 -D CMAKE_BUILD_TYPE=RelWithDebInfo
```
#### for RISC-V
@@ -192,15 +139,7 @@ sudo systemctl restart systemd-binfmt
Using a 64bit OS:
```
-git clone https://github.com/ptitSeb/box64
-cd box64
-mkdir build; cd build; cmake .. -DRV64=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo
-make -j`nproc`
-sudo make install
-```
-If it's the first install, you also need:
-```
-sudo systemctl restart systemd-binfmt
+-D RV64=1 -D CMAKE_BUILD_TYPE=RelWithDebInfo
```
#### for PowerPC 64 LE
@@ -208,15 +147,7 @@ sudo systemctl restart systemd-binfmt
Using a 64bit OS:
```
-git clone https://github.com/ptitSeb/box64
-cd box64
-mkdir build; cd build; cmake .. -DPPC64LE=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo
-make -j4
-sudo make install
-```
-If it's the first install, you also need:
-```
-sudo systemctl restart systemd-binfmt
+-D PPC64LE=1 -D CMAKE_BUILD_TYPE=RelWithDebInfo
```
#### for LX2160A
@@ -224,22 +155,16 @@ sudo systemctl restart systemd-binfmt
Using a 64bit OS:
```
-git clone https://github.com/ptitSeb/box64
-cd box64
-mkdir build; cd build; cmake .. -DLX2160A=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo
-make -j$(nproc)
-sudo make install
-```
-If it's the first install, you also need:
-```
-sudo systemctl restart systemd-binfmt
+-D LX2160A=1 -D CMAKE_BUILD_TYPE=RelWithDebInfo
```
#### for x86_64 Linux
+```
+-D LD80BITS=1 -D NOALIGN=1 -D CMAKE_BUILD_TYPE=RelWithDebInfo
+```
+If you encounter some linking errors, try using `NOLOADADDR=ON` (`cmake -D NOLOADADDR=ON; make -j$(nproc)`).
- `mkdir build; cd build; cmake .. -DLD80BITS=1 -DNOALIGN=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo; make -j$(nproc)`
-
-If you encounter some linking errors, try using `NOLOADADDR=ON` (`cmake -DNOLOADADDR=ON; make -j$(nproc)`).
+----
### use ccmake
@@ -257,7 +182,7 @@ The `-DCMAKE_BUILD_TYPE=RelWithDebInfo` argument makes a build that is both opti
#### To have a Trace Enabled build
-To have a trace enabled build (***the interpreter will be slightly slower***), add `-DHAVE_TRACE=1`. But you will need to have the [Zydis library](https://github.com/zyantific/zydis) in your `LD_LIBRARY_PATH` or in the system library folders at runtime.
+To have a trace enabled build (***the interpreter will be slightly slower***), add `-DHAVE_TRACE=1`. But you will need to have the [Zydis library](https://github.com/zyantific/zydis) in your `LD_LIBRARY_PATH` or in the system library folders at runtime. Use version v3.2.1, as later version changed the API and will no longer work with box64
#### To have ARM Dynarec
@@ -282,4 +207,4 @@ The tests are very basic and only tests some functionality for now.
Debian Packaging
----
-Box64 can also be packaged into a .deb file with `DEB_BUILD_OPTIONS=nostrip dpkg-buildpackage -us -uc -nc`.
+Box64 can also be packaged into a .deb file ***using the source code zip from the releases page*** with `DEB_BUILD_OPTIONS=nostrip dpkg-buildpackage -us -uc -nc`. Configure any additional cmake options you might want in `debian/rules`.
diff --git a/docs/README_CN.md b/docs/README_CN.md
deleted file mode 100644
index 1d10853..0000000
--- a/docs/README_CN.md
+++ /dev/null
@@ -1,119 +0,0 @@
-# box64
-
-![Official logo](img/Box64Logo.png "Official Logo")
-Linux上用户空间的x86_64应用模拟器
-
-----
-![box64 build status](https://app.travis-ci.com/ptitSeb/box64.svg?branch=main)
-
-[English](README.md)
-
-在ARM或其他非X86_64架构的Linux操作系统上,使用Box64可以运行x86_64 Linux程序(例如游戏),请注意,主机系统需要**64位小端**。
-
-您可以在Youtube的[MicroLinux](https://www.youtube.com/channel/UCwFQAEj1lp3out4n7BeBatQ)、[Pi Labs](https://www.youtube.com/channel/UCgfQjdc5RceRlTGfuthBs7g)或[The Byteman](https://www.youtube.com/channel/UCEr8lpIJ3B5Ctc5BvcOHSnA)频道找到更多Box64视频。
-
-Box64使用了一些“系统”库的原生版本,例如libc、libm、SDL和OpenGL,所以它很容易与大多数应用程序集成和使用,并且在很多情况下性能会出奇的高。点击[此处](https://box86.org/index.php/2021/06/game-performances/)查看示例的基准测试分析。
-
-Box64为ARM64平台集成了DynaRec(动态重编译器),比仅使用解释器提升5到10倍性能。关于Dynarec如何工作的更多信息,可以在[这里](https://box86.org/2021/07/inner-workings-a-high%e2%80%91level-view-of-box86-and-a-low%e2%80%91level-view-of-the-dynarec/)找到。
-
-注:DynaRec需要针对不同平台编写一部分汇编代码,目前仅支持ARM64。
-
-一些x64内部操作码使用“Realmode X86 Emulator Library”的部分内容,请参阅[x64primop.c](../src/emu/x64primop.c)了解版权详情
-
-<img src="img/Box64Icon.png" width="96" height="96">
-
-Logo和图标由grayduck制作,感谢!
-
-----
-
-使用方法
-----
-
-若干环境变量可以设置Box64的行为。
-
-点击[这里](USAGE.md)了解所有的环境变量和它们的作用。
-
-请注意:Box64的Dynarec提供了一种机制来处理JIT代码,包含内存保护和段错误信号处理程序。简单地说,如果您想用GDB来调试一个使用JIT代码的运行程序(比如mono/Unity3D),您仍然会触发很多“正常”的段错误。建议在GDB中使用类似于`handle SIGSEGV nostop`的东西,不要在每个段错误时都停止,如果您想捕获段错误,可以在`signals.c`中的`my_memprotectionhandler`中放置一个断点。
-
-----
-
-编译/安装
-----
-> 编译说明可以在[这里](COMPILE.md)查看。
-
-----
-
-版本历史
-----
-
-版本日志在[这里](CHANGELOG.md)。
-
-----
-
-32位平台的注意事项
-----
-
-Box64的工作原理是直接将函数调用从x86_64转换到主机系统,主机系统(Box64运行的系统)需要有64位的库。Box64并不包括任何64位<->32位的转换。
-
-所以请理解,Box64只能运行64位的Linux二进制文件。对于32位的二进制文件,需要Box86(在64位的操作系统上需要所有的multiarch库或一些proot技巧)。
-
-请注意,许多(基于mojo的)安装程序,即使存在x86_64版本,但在检测到架构为ARM64时会退回到"x86",这时会尝试使用(如果有)box86进行安装。这时你可以使用一个假的"uname",当它的参数为"-m"时返回"x86_64"。
-
-----
-
-关于Unity游戏模拟的注意事项
-----
-
-当前Unity游戏模拟是一件碰运气的事情。Unity使用Mono(它的信号表示,并不总能100%成功模拟)。
-
-您还应该注意,一些Unity3D游戏需要OpenGL 3+,目前在ARM SBC(单板计算机)上提供OpenGL 3+是很棘手的。
-
-所以,并不是所有的Unity游戏都能工作,而且可能需要很高的OpenGL配置,但现在很多游戏都能工作。
-
-提示:如果游戏开始后在显示任何东西之前退出,在Pi4上使用`MESA_GL_VERSION_OVERRIDE=3.2`,在Panfrost上使用`PAN_MESA_DEBUG=gl3`来使用更高的配置文件。
-
-----
-
-关于GTK程序的注意事项
-----
-
-GTK 庫現在包裝在 box64 上,但只有 gtk2,而不是 gtk3(與 box86 相反)。
-
-----
-
-关于Steam的注意事项
-----
-
-Steam并不是32位/64位混合的,而是32位的,因此您需要Box86才能运行Steam。Steam也使用64位的本地服务器程序,但像大多数使用libcef/chromium的程序一样,在box64上暂时无法正常工作。
-所以:目前在box64上无法运行Steam。
-----
-
-关于Wine的注意事项
-----
-
-box64支持64位Wine,但请注意,64位的Wine还包含32位的组件,以便能够运行32位的Windws程序。32位程序需要Box86,没有它就不能运行。在Box64和Box86共存的系统上,设置64位Wine可以同时运行32位和64位windows程序(只需分别使用 `wine` 和 `wine64`)。
-
-----
-
-关于Vulkan注意事项
-----
-
-Box64 包裝 Vulkan 庫。但請注意,它僅使用 RX550 卡進行了測試,根據您的圖形卡,可能會缺少某些擴展。
-
-----
-
-结语
-----
-
-我要感谢所有为 box64 开发做出贡献的人。
-贡献方式有很多种:代码贡献、财务帮助、捐赠捐赠和广告合作!
-以下感谢不分先后:
- * 代码贡献:rajdakin, mogery
- * 财务帮助:FlyingFathead, stormchaser3000, dennis1248, sll00, [libre-computer-project](https://libre.computer/)
- * 硬件捐赠:[Radxa](https://rockpi.org/), [Pine64](https://www.pine64.org/), [StarFive](https://rvspace.org/)
- * 硬件捐赠和LoongArch迁移:[xiaoji](https://www.linuxgame.cn)
- * 为本项目持续的宣传:salva ([microLinux](https://www.youtube.com/channel/UCwFQAEj1lp3out4n7BeBatQ)), [PILab](https://www.youtube.com/channel/UCgfQjdc5RceRlTGfuthBs7g)/[TwisterOS](https://twisteros.com/) team, [The Byteman](https://www.youtube.com/channel/UCEr8lpIJ3B5Ctc5BvcOHSnA), [NicoD](https://www.youtube.com/channel/UCpv7NFr0-9AB5xoklh3Snhg), ekianjo ([Boilingsteam](https://boilingsteam.com/))
-
-我还要感谢很多人,即使他们只参与了一次本项目。
-
-(如果你的项目中使用了Box64,请不要忘记提及!)
diff --git a/docs/USAGE.md b/docs/USAGE.md
index 67a43f0..5c67f0f 100755..100644
--- a/docs/USAGE.md
+++ b/docs/USAGE.md
@@ -38,7 +38,7 @@ Enables/Disables the logging of `dlsym` errors.
#### BOX64_TRACE_FILE *
Send all log and trace to a file instead of `stdout`
Also, if name contains `%pid` then this is replaced by the actual PID of box64 instance
-End the filename with `+` to have thetrace appended instead of overwriten
+End the filename with `+` to have thetrace appended instead of overwritten
Use `stderr` to use this instead of default `stdout`
#### BOX64_TRACE *
@@ -130,9 +130,14 @@ Enables/Disables trace for generated code.
* 1 : Enable trace for generated code (like regular Trace, this will slow down the program a lot and generate huge logs).
#### BOX64_NODYNAREC *
-Forbid dynablock creation in the interval specified (helpfull for debugging behaviour difference between Dynarec and Interpretor)
+Forbid dynablock creation in the interval specified (helpfull for debugging behaviour difference between Dynarec and Interpreter)
* 0xXXXXXXXX-0xYYYYYYYY : define the interval where dynablock cannot start (inclusive-exclusive)
+#### BOX64_DYNAREC_TEST *
+Dynarec will compare it's execution with the interpreter (super slow, only for testing)
+ * 0 : No comparison
+ * 1 : Each opcode runs on interepter and on Dynarec, and regs and memory are compared and print if different
+
#### BOX64_DYNAREC_BIGBLOCK *
Enables/Disables Box64's Dynarec building BigBlock.
* 0 : Don't try to build block as big as possible (can help program using lots of thread and a JIT, like C#/Unity) (Default when libmonobdwgc-2.0.so is loaded)
@@ -178,12 +183,12 @@ Optimisation of CALL/RET opcodes (not compatible with jit/dynarec/smc)
* 1 : Try to optimized CALL/RET, skipping the use of the JumpTable when possible (will crash if blacks are invalidate, so probably incompatible with JIT/Dynarec)
#### BOX64_DYNAREC_HOTPAGE *
-Handling of HotPage (Page beeing both executed and writen)
-* 0 : Don't track hotpage
-* 1-255 : Track HotPage, and disable execution of a page beeing writen for N attempts (default is 4)
+Handling of HotPage (Page being both executed and written)
+* 0 : Don't track hotpage (Default)
+* 1-255 : Track HotPage, and disable execution of a page being written for N attempts
#### BOX64_DYNAREC_FASTPAGE *
-Will use a faster handling of HotPage (Page beeing both executed and writen)
+Will use a faster handling of HotPage (Page being both executed and written)
* 0 : use regular hotpage (Default)
* 1 : Use faster hotpage, taking the risk of running obsolete JIT code (might be faster, but more prone to crash)
@@ -192,11 +197,21 @@ Detect MonoBleedingEdge and apply conservative settings
* 0 : Don't detect MonoBleedingEdge
* 1 : Detect MonoBleedingEdge, and apply BIGBLOCK=0 STRONGMEM=1 if detected (Default)
+#### BOX64_DYNAREC_JVM *
+Detect libjvm and apply conservative settings
+* 0 : Don't detect libjvm
+* 1 : Detect libjvm, and apply BIGBLOCK=0 STRONGMEM=1 if detected (Default)
+
#### BOX64_DYNAREC_WAIT *
Behavior with FillBlock is not availble (FillBlock build Dynarec blocks and is not multithreaded)
* 0 : Dynarec will not wait for FillBlock to ready and use Interpreter instead (might speedup a bit massive multithread or JIT programs)
* 1 : Dynarec will wait for FillBlock to be ready (Default)
+#### BOX64_DYNAREC_MISSING *
+Dynarec print the missing opcodes
+* 0 : not print the missing opcode (Default, unless DYNAREC_LOG>=1 or DYNAREC_DUMP>=1 is used)
+* 1 : Will print the missing opcodes
+
#### BOX64_SSE_FLUSHTO0 *
Handling of SSE Flush to 0 flags
* 0 : Just track the flag (Default)
@@ -306,3 +321,7 @@ Those variables are only valid inside a rcfile:
#### BOX64_EXIT
* 0 : Nothing special
* 1 : Just exit, don't try to run the program
+
+#### BOX64_RESERVE_HIGH
+* 0 : Don't try to pe-reserve high memory (beyond 47bits) (Default)
+* 1 : Try to reserve (without allocating it) memory beyond 47bits (seems unstable)
diff --git a/docs/box64.pod b/docs/box64.pod
new file mode 100644
index 0000000..b5c89f5
--- /dev/null
+++ b/docs/box64.pod
@@ -0,0 +1,465 @@
+=head1 NAME
+
+box64 - Linux Userspace x86_64 Emulator with a twist
+
+=head1 SYNOPSIS
+
+B<box64> [B<--help>] [B<--version>] I<executable>
+
+=head1 DESCRIPTION
+
+B<Box64> lets you run x86_64 Linux programs (such as games) on non-x86_64 Linux
+systems, like ARM (host system needs to be 64-bit little-endian). Since B<Box64>
+uses the native versions of some "system" libraries, like libc, libm, SDL, and
+OpenGL, it's easy to integrate and use with most applications, and performance
+can be surprisingly high in many cases. B<Box64> integrates with DynaRec (dynamic
+recompiler) for the ARM64 platform, providing a speed boost between 5 to 10
+times faster than using only the interpreter.
+
+=head1 OPTIONS
+
+=over 8
+
+=item B<-h,--help>
+
+Print box64 help and quit.
+
+=item B<-v,--version>
+
+Print box64 version and quit.
+
+=back
+
+=head1 CONFIGURATION FILE
+
+B<Box64> now have configurations files. There are 2 files loaded.
+F</etc/box4.box64rc> and F<~/.box64rc>. Both files have the same syntax, and is
+basically an ini files. Section in square brackets define the process name, and
+the rest is the environment variable. B<Box64> comes with a default file that
+should be installed for better stability. Note that the priority is:
+F<~/.bashrc> > F</etc/box64.box64rc> > command line So, your settings in
+F<~/.bashrc> may override the setting from your command line. Example:
+
+ [factorio]
+ BOX64_DYNAREC_SAFEFLAGS=0
+ BOX64_DYNAREC_BIGBLOCK=2
+ BOX64_DYNAREC_FORWARD=1024
+ BOX64_DYNAREC_CALLRET=1
+
+=head1 VARIABLES FOR RCFILE ONLY
+
+=over 8
+
+=item B<BOX64_NOSANDBOX=0|1>
+
+When set to 1, add C<--no-sandbox> to command line arguments (useful for chrome
+based programs).
+
+=item B<BOX64_EXIT>=I<0|1>
+
+When set to 1, just exit, don't try to run the program.
+
+=back
+
+=head1 VARIABLES ONLY FOR ENVIRONMENT AND NOT RCFILE
+
+=over 8
+
+=item B<BOX64_NOBANNER>=I<0|1>
+
+When set to 1, don't prints the banner including version and build.
+
+=item B<BOX64_LD_PRELOAD>=I<lib1>[:I<lib2>:...]
+
+Force loading libraries with the binary. PreLoaded libs can be emulated or
+native, and are treated the same way as if they were comming from the binary.
+
+=item B<BOX64_ENV>=I<env=val>
+
+Add an variable with value to the environment.
+
+=item B<BOX64_ENV1>=I<env=val> B<BOX64_ENV2>=I<env=val> ...
+
+Add arbitrary many variables using B<BOX64_ENV1>, B<BOX64_ENV2>, ...
+
+=item B<BOX64_NORCFILES>
+
+No rc files (like F</etc/box64.box64rc> and F<~/.box64rc>) will be loaded.
+
+=back
+
+=head1 VARIABLES FOR BOTH ENVIRONMENT AND RCFILE
+
+=over 8
+
+=item B<BOX64_LOG>=I<0|NONE|1|INFO|2|DEBUG|3|DUMP>
+
+Controls the Verbosity level of the logs
+
+ * 0 or NONE : No message (except some fatal error). (Default.)
+ * 1 or INFO : Show some minimum log (Example: libraries not found)
+ * 2 or DEBUG : Details a lot of stuff (Example: relocations or functions called).
+ * 3 or DUMP : All DEBUG plus DUMP of all ELF Info.
+
+=item B<BOX64_ROLLING_LOG>=I<0|1|N>
+
+Show last few wrapped function call when a Signal is caught. Incompatible with
+B<BOX64_LOG> > 1 (may need B<BOX64_SHOWSEGV=1> also)
+
+ * 0: No last function call printed (Default.)
+ * 1: Last 16 wrapped functions calls printed when a signal is printed.
+ * N: Last N wrapped functions calls printed when a signal is printed.
+
+=item B<BOX64_LD_LIBRARY_PATH>=I</path/to/libs>
+
+Path to look for x86_64 libraries. Default is current folder and C<lib> in
+current folder. Also, F</usr/lib/x86_64-linux-gnu> and
+F</lib/x86_64-linux-gnu> are added if they exist.
+
+=item B<BOX64_PATH>=I</path/to/bins>
+
+Path to look for x86_64 executable. Default is current folder and C<bin> in
+current folder.
+
+=item B<BOX64_DLSYM_ERROR>=I<0|1>
+
+Enables/Disables the logging of `dlsym` errors.
+
+ * 0 : Don't log `dlsym` errors. (Default.)
+ * 1 : Log dlsym errors.
+
+=item B<BOX64_TRACE_FILE>=I</path/to/file>
+
+Send all log and trace to a file instead of C<stdout>. Also, if name contains
+C<%pid> then this is replaced by the actual C<PID> of B<box64> instance. End
+the filename with `+` to have thetrace appended instead of overwritten Use
+C<stderr> to use this instead of default C<stdout>.
+
+=item B<BOX64_TRACE>=I<0|1|symbolname|0xXXXXXXX-0xYYYYYYY>
+
+Only on build with trace enabled. Trace allow the logging of all instruction executed, along with register dump
+
+ * 0 : No trace. (Default.)
+ * 1 : Trace enabled. Trace start after the initialisation of all depending libraries is done.
+ * symbolname : Trace only `symbolname` (trace is disable if the symbol is not found).
+ * 0xXXXXXXX-0xYYYYYYY : Trace only between the 2 addresses.
+
+=item B<BOX64_TRACE_INIT>=I<0|1>
+
+Use B<BOX64_TRACE_INIT> instead of B<BOX_TRACE> to start trace before the
+initialization of libraries and the running program
+
+ * 0 : No trace. (Default.)
+ * 1 : Trace enabled. The trace start with the initialisation of all depending libraries is done.
+
+=item B<BOX64_TRACE_START>=I<NNNNNNN>
+
+Only on builds with trace enabled. Start trace only after I<NNNNNNNN> opcode
+execute (number is an `uint64_t`).
+
+=item B<BOX64_TRACE_XMM>=I<0|1>
+
+Only on builds with trace enabled.
+
+ * 0 : The XMM (i.e. SSE/SSE2) register will not be logged with the general and x86 registers. (Default.)
+ * 1 : Dump the XMM registers.
+
+=item B<BOX64_TRACE_EMM>=I<0|1>
+
+Only on builds with trace enabled.
+
+ * 0 : The EMM (i.e. MMX) register will not be logged with the general and x86 registers. (Default.)
+ * 1 : Dump the EMM registers.
+
+=item B<BOX64_TRACE_COLOR>=I<0|1>
+
+Only on builds with trace enabled.
+
+ * 0 : The general registers will always be the default white color. (Default.)
+ * 1 : The general registers will change color in the dumps when they changed value.
+
+=item B<BOX64_LOAD_ADDR>=I<0xXXXXXXXX>
+
+Try to load at C<0xXXXXXX> main binary (if binary is a PIE).
+
+=item B<BOX64_NOSIGSEGV>=I<0|1>
+
+Disable handling of SigSEGV. (Very useful for debugging.)
+
+ * 0 : Let the x86 program set sighandler for SEGV (Default.)
+ * 1 : Disable the handling of SigSEGV.
+
+=item B<BOX64_NOSIGILL>=I<0|1>
+
+Disable handling of SigILL (to ease debugging mainly).
+
+ * 0 : Let x86 program set sighandler for Illegal Instruction
+ * 1 : Disables the handling of SigILL
+
+=item B<BOX64_SHOWSEGV>=I<0|1>
+
+Show Segfault signal even if a signal handler is present
+
+ * 0 : Don"t force show the SIGSEGV analysis (Default.)
+ * 1 : Show SIGSEGV detail, even if a signal handler is present
+
+=item B<BOX64_SHOWBT>=I<0|1>
+
+Show some Backtrace (Nativ e and Emulated) whgen a signal (SEGV, ILL or BUS) is caught
+
+ * 0 : Don"t show backtraces (Default.)
+ * 1 : Show Backtrace detail (for native, box64 is rename as the x86_64 binary run)
+
+=item B<BOX64_X11THREADS>=I<0|1>
+
+Call XInitThreads when loading X11. (This is mostly for old Loki games with the Loki_Compat library.)
+
+ * 0 : Don't force call XInitThreads. (Default.)
+ * 1 : Call XInitThreads as soon as libX11 is loaded.
+
+=item B<BOX64_X11GLX>=I<0|1>
+
+Force libX11's GLX extension to be present.
+
+ * 0 : Do not force libX11's GLX extension to be present.
+ * 1 : GLX will always be present when using XQueryExtension. (Default.)
+
+=item B<BOX64_DYNAREC_DUMP>=I<0|1|2>
+
+Enables/disables Box64's Dynarec's dump.
+
+ * 0 : Disable Dynarec's blocks dump. (Default.)
+ * 1 : Enable Dynarec's blocks dump.
+ * 2 : Enable Dynarec's blocks dump with some colors.
+
+=item B<BOX64_DYNAREC_LOG>=I<0|1|2|3>
+
+Set the level of DynaRec's logs.
+
+ * 0 : NONE : No Logs for DynaRec. (Default.)
+ * 1 :INFO : Minimum Dynarec Logs (only unimplemented OpCode).
+ * 2 : DEBUG : Debug Logs for Dynarec (with details on block created / executed).
+ * 3 : VERBOSE : All of the above plus more.
+
+=item B<BOX64_DYNAREC>=I<0|1>
+
+Enables/Disables Box64's Dynarec.
+
+ * 0 : Disables Dynarec.
+ * 1 : Enable Dynarec. (Default.)
+
+=item B<BOX64_DYNAREC_TRACE>=I<0|1>
+
+Enables/Disables trace for generated code. Like regular Trace, this will slow
+down the program a lot and generate huge logs.
+
+ * 0 : Disable trace for generated code. (Default.)
+ * 1 : Enable trace for generated code
+
+=item B<BOX64_NODYNAREC>=I<0xXXXXXXXX-0xYYYYYYYY>
+
+Forbid dynablock creation in the interval specified (helpfull for debugging
+behaviour difference between Dynarec and Interpretor)
+
+=item B<BOX64_DYNAREC_TEST>=I<0|1>
+
+Enables/Disables test for generated code. This will run interpreter along the Dynacrec, so this will slow
+down the program a lot.
+
+ * 0 : No test for generated code. (Default.)
+ * 1 : Enable Tests for generated code
+
+=item B<BOX64_DYNAREC_BIGBLOCK>=I<0|1|2|3>
+
+Enables/Disables Box64's Dynarec building BigBlock.
+
+ * 0 : Don't try to build block as big as possible (can help program using lots of thread and a JIT, like C#/Unity) (Default when libmonobdwgc-2.0.so is loaded)
+ * 1 : Build Dynarec block as big as possible (Default.)
+ * 2 : Build Dynarec block bigger (don't stop when block overlaps, but only for blocks in elf memory)
+ * 3 : Build Dynarec block bigger (don't stop when block overlaps, for all type of memory)
+
+=item B<BOX64_DYNAREC_FORWARD>=I<0|XXX>
+
+Define Box64's Dynarec max allowed forward value when building Block.
+
+ * 0 : No forward value. When current block end, don't try to go further even if there are previous forward jumps
+ * XXX : Allow up to XXXX bytes of gap when building a Block after the block end to next forward jump (Default: 128)
+
+=item B<BOX64_DYNAREC_STRONGMEM>=I<0|1|2>
+
+Enable/Disable simulation of Strong Memory model
+
+ * 0 : Don't try anything special (Default.)
+ * 1 : Enable some Memory Barrier when reading from memory (on some MOV opcode) to simulate Strong Memory Model while trying to limit performance impact (Default when libmonobdwgc-2.0.so is loaded)
+ * 2 : Enable some Memory Barrier when reading from memory (on some MOV opcode) to simulate Strong Memory Model
+
+=item B<BOX64_DYNAREC_X87DOUBLE>=I<0|1>
+
+Force the use of Double for x87 emulation
+
+ * 0 : Try to use float when possible for x87 emulation (default, faster)
+ * 1 : Only use Double for x87 emulation (slower, may be needed for some specific games, like Crysis)
+
+=item B<BOX64_DYNAREC_FASTNAN>=I<0|1>
+
+Enable/Disable generation of -NAN
+
+ * 0 : Generate -NAN like on x86
+ * 1 : Don't do anything special with NAN, to go as fast as possible (default, faster)
+
+=item B<BOX64_DYNAREC_FASTROUND>=I<0|1>
+
+Enable/Disable generation of precise x86 rounding
+
+ * 0 : Generate float/double -> int rounding like on x86
+ * 1 : Don't do anything special with edge case Rounding, to go as fast as possible (no INF/NAN/Overflow -> MIN_INT conversion) (default, faster)
+
+=item B<BOX64_DYNAREC_SAFEFLAGS>=I<0|1|2>
+
+Handling of flags on CALL/RET opcodes
+
+ * 0 : Treat CALL/RET as if it never needs any flags (faster but not advised)
+ * 1 : most of RET will need flags, most of CALLS will not (Default)
+ * 2 : All CALL/RET will need flags (slower, but might be needed. Automatically enabled for Vara.exe)
+
+=item B<BOX64_DYNAREC_CALLRET>=I<0|1>
+
+Optimisation of CALL/RET opcodes (not compatible with jit/dynarec/smc)
+
+ * 0 : Don't optimize CALL/RET, use Jump Table for boths (Default)
+ * 1 : Try to optimized CALL/RET, skipping the use of the JumpTable when possible (will crash if blacks are invalidate, so probably incompatible with JIT/Dynarec)
+
+=item B<BOX64_DYNAREC_HOTPAGE>=I<0|1-255>
+
+Handling of HotPage (Page beeing both executed and writen)
+
+ * 0 : Don't track hotpage
+ * 1-255 : Track HotPage, and disable execution of a page beeing writen for N attempts (default is 4)
+
+=item B<BOX64_DYNAREC_FASTPAGE>=I<0|1>
+
+Will use a faster handling of HotPage (Page beeing both executed and writen)
+
+ * 0 : use regular hotpage (Default)
+ * 1 : Use faster hotpage, taking the risk of running obsolete JIT code (might be faster, but more prone to crash)
+
+=item B<BOX64_DYNAREC_BLEEDING_EDGE>=I<0|1>
+
+Detect MonoBleedingEdge and apply conservative settings
+
+ * 0 : Don't detect MonoBleedingEdge
+ * 1 : Detect MonoBleedingEdge, and apply BIGBLOCK=0 STRONGMEM=1 if detected (Default)
+
+=item B<BOX64_DYNAREC_WAIT>=I<0|1>
+
+Behavior with FillBlock is not availble (FillBlock build Dynarec blocks and is not multithreaded)
+
+ * 0 : Dynarec will not wait for FillBlock to ready and use Interpreter instead (might speedup a bit massive multithread or JIT programs)
+ * 1 : Dynarec will wait for FillBlock to be ready (Default)
+
+=item B<BOX64_SSE_FLUSHTO0>=I<0|1>
+
+Handling of SSE Flush to 0 flags
+
+ * 0 : Just track the flag (Default)
+ * 1 : Direct apply of SSE Flush to 0 flag
+
+=item B<BOX64_X87_NO80BITS>=I<0|1>
+
+Handling of x87 80bits long double
+
+ * 0 : Try to handle 80bits long double as precise as possible (Default)
+ * 1 : Handle them as double
+
+=item B<BOX64_LIBCEF>=I<0|1>
+
+Detect libcef and apply malloc_hack settings
+
+ * 0 : Don't detect libcef
+ * 1 : Detect libcef, and apply MALLOC_HACK=2 if detected (Default)
+
+=item B<BOX64_LIBGL>=I<libXXXX|/PATH/TO/libGLXXX>
+
+You can also use B<SDL_VIDEO_GL_DRIVER>
+
+ * libXXXX set the name for libGL (defaults to libGL.so.1).
+ * /PATH/TO/libGLXXX : Sets the name and path for libGL
+
+=item B<BOX64_EMULATED_LIBS>=I<XXXX[:YYYY:...]>
+
+Force lib XXXX (and YYYY...) to be emulated (and not wrapped) Some games uses
+an old version of some libraries, with an ABI incompatible with native version.
+Note that LittleInferno for example is auto detected, and libvorbis.so.0 is
+automatical added to emulated libs, and same for Don't Starve (and Together /
+Server variant) that use an old SDL2 too
+
+=item B<BOX64_ALLOWMISSINGLIBS>=I<0|1>
+
+Allow Box64 to continue even if a library is missing.
+
+ * 0 : Box64 will stop if a library cannot be loaded. (Default.)
+ * 1 : Continue even if a needed library cannot be loaded. Unadvised, this will, in most cases, crash later on.
+
+=item B<BOX64_PREFER_WRAPPED>=I<0|1>
+
+Box64 will use wrapped libs even if the lib is specified with absolute path
+
+ * 0 : Try to use emulated libs when they are defined with absolute path (Default.)
+ * 1 : Use Wrapped native libs even if path is absolute
+
+=item B<BOX64_PREFER_EMULATED>=I<0|1>
+
+Box64 will prefer emulated libs first (execpt for glibc, alsa, pulse, GL,
+vulkan and X11
+
+ * 0 : Native libs are prefered (Default.)
+ * 1 : Emulated libs are prefered (Default for program running inside pressure-vessel)
+
+=item B<BOX64_CRASHHANDLER>=I<0|1>
+
+Box64 will use a dummy crashhandler.so library
+
+ * 0 : Use Emulated crashhandler.so library if needed
+ * 1 : Use an internal dummy (completly empty) crashhandler.so library (defaut)
+
+=item B<BOX64_MALLOC_HACK>=I<0|1|2>
+
+How Box64 will handle hooking of malloc operators
+
+ * 0 : Don't allow malloc operator to be redirected, rewriting code to use regular function (Default)
+ * 1 : Allow malloc operator to be redirected (not advised)
+ * 2 : Like 0, but track special mmap / free (some redirected functions were inlined and cannot be redirected)
+
+=item B<BOX64_NOPULSE>=I<0|1>
+
+Disables the load of pulseaudio libraries.
+
+ * 0 : Load pulseaudio libraries if found. (Default.)
+ * 1 : Disables the load of pulse audio libraries (libpulse and libpulse-simple), both the native library and the x86 library
+
+=item B<BOX64_NOGTK>=I<0|1>
+
+Disables the loading of wrapped GTK libraries.
+
+ * 0 : Load wrapped GTK libraries if found. (Default.)
+ * 1 : Disables loading wrapped GTK libraries.
+
+=item B<BOX64_NOVULKAN>=I<0|1>
+
+Disables the load of vulkan libraries.
+
+ * 0 : Load vulkan libraries if found.
+ * 1 : Disables the load of vulkan libraries, both the native and the i386 version (can be useful on Pi4, where the vulkan driver is not quite there yet.)
+
+=item B<BOX64_BASH>=I<yyyy>
+
+Define x86_64 bash to launch script. Will use yyyy as x86_64 bash to launch
+script. yyyy needs to be a full path to a valid x86_64 version of bash
+
+=item B<BOX64_JITGDB>=I<0|1|2>
+
+ * 0 : Just print the Segfault message on segfault (default)
+ * 1 : Launch `gdb` when a segfault, bus error or illegal instruction signal is trapped, attached to the offending process and go in an endless loop, waiting. When in gdb, you need to find the correct thread yourself (the one with `my_box64signalhandler` in is stack) then probably need to `finish` 1 or 2 functions (inside `usleep(..)`) and then you'll be in `my_box64signalhandler`, just before the printf of the Segfault message. Then simply `set waiting=0` to exit the infinite loop.
+ * 2 : Launch `gdbserver` when a segfault, bus error or illegal instruction signal is trapped, attached to the offending process, and go in an endless loop, waiting. Use `gdb /PATH/TO/box64` and then `target remote 127.0.0.1:1234` to connect to the gdbserver (or use actual IP if not on the machine). After that, the procedure is the same as with ` BOX64_JITGDB=1`. This mode can be usefullwhen programs redirect all console output to a file (like Unity3D Games)
+
+=cut
diff --git a/docs/img/Box64Icon.png b/docs/img/Box64Icon.png
index 8b3c7a9..8b3c7a9 100755..100644
--- a/docs/img/Box64Icon.png
+++ b/docs/img/Box64Icon.png
Binary files differ
diff --git a/docs/img/Box64Logo.png b/docs/img/Box64Logo.png
index bac2f54..bac2f54 100755..100644
--- a/docs/img/Box64Logo.png
+++ b/docs/img/Box64Logo.png
Binary files differ
diff --git a/pkgbuilds/PKGBUILD-arm64 b/pkgbuilds/PKGBUILD-arm64
deleted file mode 100644
index ad1c02e..0000000
--- a/pkgbuilds/PKGBUILD-arm64
+++ /dev/null
@@ -1,38 +0,0 @@
-# Maintainer: Jai-JAP <jai.jap.318@gmail.com>
-# Author: Sebastien Chevalier <ptitseb@box86.org>
-pkgname=box64-arm64-git
-pkgver=r1495.e6e9fae
-pkgrel=1
-pkgdesc="Linux Userspace x86_64 Emulator with a twist, targeted at ARM64 Linux devices."
-arch=('aarch64')
-url="https://github.com/ptitSeb/box64"
-license=('MIT')
-optdepends=('gl4es: OpenGL 2 for GLES 2 devices')
-makedepends=('git' 'cmake' 'make')
-provides=("${pkgname%-git}" "${pkgname%-arm64-git}-git" "${pkgname%-arm64-git}")
-conflicts=("${pkgname%-git}" "${pkgname%-arm64-git}-git" "${pkgname%-arm64-git}")
-source=('git+https://github.com/ptitSeb/box64')
-md5sums=('SKIP')
-
-pkgver() {
- cd "$srcdir/${pkgname%-arm64-git}"
- printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
-}
-
-prepare() {
- cd "${srcdir}/${pkgname%-arm64-git}"
- if [[ ! -d ./build ]]; then
- mkdir build && cd build
- cmake .. -DARM_DYNAREC=ON -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_INSTALL_PREFIX=/usr
- fi
-}
-
-build() {
- cd "$srcdir/${pkgname%-arm64-git}/build"
- make -j$(nproc)
-}
-
-package() {
- cd "$srcdir/${pkgname%-arm64-git}/build"
- make DESTDIR="${pkgdir}/" install
-}
diff --git a/pkgbuilds/PKGBUILD-arm64-DEBUG b/pkgbuilds/PKGBUILD-arm64-DEBUG
deleted file mode 100644
index 1b5f70f..0000000
--- a/pkgbuilds/PKGBUILD-arm64-DEBUG
+++ /dev/null
@@ -1,38 +0,0 @@
-# Maintainer: Jai-JAP <jai.jap.318@gmail.com>
-# Author: Sebastien Chevalier <ptitseb@box86.org>
-pkgname=box64-arm64-git
-pkgver=r1495.e6e9fae
-pkgrel=1
-pkgdesc="Linux Userspace x86_64 Emulator with a twist, targeted at ARM64 Linux devices."
-arch=('aarch64')
-url="https://github.com/ptitSeb/box64"
-license=('MIT')
-optdepends=('gl4es: OpenGL 2 for GLES 2 devices')
-makedepends=('git' 'cmake' 'make')
-provides=("${pkgname%-git}" "${pkgname%-arm64-git}-git" "${pkgname%-arm64-git}")
-conflicts=("${pkgname%-git}" "${pkgname%-arm64-git}-git" "${pkgname%-arm64-git}")
-source=('git+https://github.com/ptitSeb/box64')
-md5sums=('SKIP')
-
-pkgver() {
- cd "$srcdir/${pkgname%-arm64-git}"
- printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
-}
-
-prepare() {
- cd "${srcdir}/${pkgname%-arm64-git}"
- if [[ ! -d ./build ]]; then
- mkdir build && cd build
- cmake .. -DARM_DYNAREC=ON -DCMAKE_BUILD_TYPE=Debug -DCMAKE_INSTALL_PREFIX=/usr
- fi
-}
-
-build() {
- cd "$srcdir/${pkgname%-arm64-git}/build"
- make -j$(nproc)
-}
-
-package() {
- cd "$srcdir/${pkgname%-arm64-git}/build"
- make DESTDIR="${pkgdir}/" install
-}
diff --git a/pkgbuilds/PKGBUILD-lx2160a b/pkgbuilds/PKGBUILD-lx2160a
deleted file mode 100644
index f9b1485..0000000
--- a/pkgbuilds/PKGBUILD-lx2160a
+++ /dev/null
@@ -1,38 +0,0 @@
-# Maintainer: Jai-JAP <jai.jap.318@gmail.com>
-# Author: Sebastien Chevalier <ptitseb@box86.org>
-pkgname=box64-lx2160a-git
-pkgver=r1495.e6e9fae
-pkgrel=1
-pkgdesc="Linux Userspace x86_64 Emulator with a twist, targeted at ARM64 Linux devices."
-arch=('aarch64')
-url="https://github.com/ptitSeb/box64"
-license=('MIT')
-optdepends=('gl4es: OpenGL 2 for GLES 2 devices')
-makedepends=('git' 'cmake' 'make')
-provides=("${pkgname%-git}" "${pkgname%-lx2160a-git}-git" "${pkgname%-lx2160a-git}")
-conflicts=("${pkgname%-git}" "${pkgname%-lx2160a-git}-git" "${pkgname%-lx2160a-git}")
-source=('git+https://github.com/ptitSeb/box64')
-md5sums=('SKIP')
-
-pkgver() {
- cd "$srcdir/${pkgname%-lx2160a-git}"
- printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
-}
-
-prepare() {
- cd "${srcdir}/${pkgname%-lx2160a-git}"
- if [[ ! -d ./build ]]; then
- mkdir build && cd build
- cmake .. -DLX2160A=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_INSTALL_PREFIX=/usr
- fi
-}
-
-build() {
- cd "$srcdir/${pkgname%-lx2160a-git}/build"
- make -j$(nproc)
-}
-
-package() {
- cd "$srcdir/${pkgname%-lx2160a-git}/build"
- make DESTDIR="${pkgdir}/" install
-}
diff --git a/pkgbuilds/PKGBUILD-lx2160a-DEBUG b/pkgbuilds/PKGBUILD-lx2160a-DEBUG
deleted file mode 100644
index 082fd74..0000000
--- a/pkgbuilds/PKGBUILD-lx2160a-DEBUG
+++ /dev/null
@@ -1,38 +0,0 @@
-# Maintainer: Jai-JAP <jai.jap.318@gmail.com>
-# Author: Sebastien Chevalier <ptitseb@box86.org>
-pkgname=box64-lx2160a-git
-pkgver=r1495.e6e9fae
-pkgrel=1
-pkgdesc="Linux Userspace x86_64 Emulator with a twist, targeted at ARM64 Linux devices."
-arch=('aarch64')
-url="https://github.com/ptitSeb/box64"
-license=('MIT')
-optdepends=('gl4es: OpenGL 2 for GLES 2 devices')
-makedepends=('git' 'cmake' 'make')
-provides=("${pkgname%-git}" "${pkgname%-lx2160a-git}-git" "${pkgname%-lx2160a-git}")
-conflicts=("${pkgname%-git}" "${pkgname%-lx2160a-git}-git" "${pkgname%-lx2160a-git}")
-source=('git+https://github.com/ptitSeb/box64')
-md5sums=('SKIP')
-
-pkgver() {
- cd "$srcdir/${pkgname%-lx2160a-git}"
- printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
-}
-
-prepare() {
- cd "${srcdir}/${pkgname%-lx2160a-git}"
- if [[ ! -d ./build ]]; then
- mkdir build && cd build
- cmake .. -DLX2160A=1 -DCMAKE_BUILD_TYPE=Debug -DCMAKE_INSTALL_PREFIX=/usr
- fi
-}
-
-build() {
- cd "$srcdir/${pkgname%-lx2160a-git}/build"
- make -j$(nproc)
-}
-
-package() {
- cd "$srcdir/${pkgname%-lx2160a-git}/build"
- make DESTDIR="${pkgdir}/" install
-}
diff --git a/pkgbuilds/PKGBUILD-rk3399 b/pkgbuilds/PKGBUILD-rk3399
deleted file mode 100644
index 0c3db91..0000000
--- a/pkgbuilds/PKGBUILD-rk3399
+++ /dev/null
@@ -1,38 +0,0 @@
-# Maintainer: Jai-JAP <jai.jap.318@gmail.com>
-# Author: Sebastien Chevalier <ptitseb@box86.org>
-pkgname=box86-rk3399-git
-pkgver=r1495.e6e9fae
-pkgrel=1
-pkgdesc="Linux Userspace x86_64 Emulator with a twist, targeted at ARM64 Linux devices."
-arch=('aarch64')
-url="https://github.com/ptitSeb/box64"
-license=('MIT')
-optdepends=('gl4es: OpenGL 2 for GLES 2 devices')
-makedepends=('git' 'cmake' 'make')
-provides=("${pkgname%-git}" "${pkgname%-rk3399-git}-git" "${pkgname%-rk3399-git}")
-conflicts=("${pkgname%-git}" "${pkgname%-rk3399-git}-git" "${pkgname%-rk3399-git}")
-source=('git+https://github.com/ptitSeb/box64')
-md5sums=('SKIP')
-
-pkgver() {
- cd "$srcdir/${pkgname%-rk3399-git}"
- printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
-}
-
-prepare() {
- cd "${srcdir}/${pkgname%-rk3399-git}"
- if [[ ! -d ./build ]]; then
- mkdir build && cd build
- cmake .. -DRK3399=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_INSTALL_PREFIX=/usr
- fi
-}
-
-build() {
- cd "$srcdir/${pkgname%-rk3399-git}/build"
- make -j$(nproc)
-}
-
-package() {
- cd "$srcdir/${pkgname%-rk3399-git}/build"
- make DESTDIR="${pkgdir}/" install
-}
diff --git a/pkgbuilds/PKGBUILD-rk3399-DEBUG b/pkgbuilds/PKGBUILD-rk3399-DEBUG
deleted file mode 100644
index e39da09..0000000
--- a/pkgbuilds/PKGBUILD-rk3399-DEBUG
+++ /dev/null
@@ -1,38 +0,0 @@
-# Maintainer: Jai-JAP <jai.jap.318@gmail.com>
-# Author: Sebastien Chevalier <ptitseb@box86.org>
-pkgname=box86-rk3399-git
-pkgver=r1495.e6e9fae
-pkgrel=1
-pkgdesc="Linux Userspace x86_64 Emulator with a twist, targeted at ARM64 Linux devices."
-arch=('aarch64')
-url="https://github.com/ptitSeb/box64"
-license=('MIT')
-optdepends=('gl4es: OpenGL 2 for GLES 2 devices')
-makedepends=('git' 'cmake' 'make')
-provides=("${pkgname%-git}" "${pkgname%-rk3399-git}-git" "${pkgname%-rk3399-git}")
-conflicts=("${pkgname%-git}" "${pkgname%-rk3399-git}-git" "${pkgname%-rk3399-git}")
-source=('git+https://github.com/ptitSeb/box64')
-md5sums=('SKIP')
-
-pkgver() {
- cd "$srcdir/${pkgname%-rk3399-git}"
- printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
-}
-
-prepare() {
- cd "${srcdir}/${pkgname%-rk3399-git}"
- if [[ ! -d ./build ]]; then
- mkdir build && cd build
- cmake .. -DRK3399=1 -DCMAKE_BUILD_TYPE=Debug -DCMAKE_INSTALL_PREFIX=/usr
- fi
-}
-
-build() {
- cd "$srcdir/${pkgname%-rk3399-git}/build"
- make -j$(nproc)
-}
-
-package() {
- cd "$srcdir/${pkgname%-rk3399-git}/build"
- make DESTDIR="${pkgdir}/" install
-}
diff --git a/pkgbuilds/PKGBUILD-rpi4 b/pkgbuilds/PKGBUILD-rpi4
deleted file mode 100644
index 32a030d..0000000
--- a/pkgbuilds/PKGBUILD-rpi4
+++ /dev/null
@@ -1,38 +0,0 @@
-# Maintainer: Jai-JAP <jai.jap.318@gmail.com>
-# Author: Sebastien Chevalier <ptitseb@box86.org>
-pkgname=box64-rpi-git
-pkgver=r1495.e6e9fae
-pkgrel=1
-pkgdesc="Linux Userspace x86_64 Emulator with a twist, targeted at ARM64 Linux devices."
-arch=('aarch64')
-url="https://github.com/ptitSeb/box64"
-license=('MIT')
-optdepends=('gl4es: OpenGL 2 for GLES 2 devices')
-makedepends=('git' 'cmake' 'make')
-provides=("${pkgname%-git}" "${pkgname%-rpi-git}-git" "${pkgname%-rpi-git}")
-conflicts=("${pkgname%-git}" "${pkgname%-rpi-git}-git" "${pkgname%-rpi-git}")
-source=('git+https://github.com/ptitSeb/box64')
-md5sums=('SKIP')
-
-pkgver() {
- cd "$srcdir/${pkgname%-rpi-git}"
- printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
-}
-
-prepare() {
- cd "${srcdir}/${pkgname%-rpi-git}"
- if [[ ! -d ./build ]]; then
- mkdir build && cd build
- cmake .. -DRPI4ARM64=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_INSTALL_PREFIX=/usr
- fi
-}
-
-build() {
- cd "$srcdir/${pkgname%-rpi-git}/build"
- make -j$(nproc)
-}
-
-package() {
- cd "$srcdir/${pkgname%-rpi-git}/build"
- make DESTDIR="${pkgdir}/" install
-}
diff --git a/pkgbuilds/PKGBUILD-rpi4-DEBUG b/pkgbuilds/PKGBUILD-rpi4-DEBUG
deleted file mode 100644
index ac192b1..0000000
--- a/pkgbuilds/PKGBUILD-rpi4-DEBUG
+++ /dev/null
@@ -1,38 +0,0 @@
-# Maintainer: Jai-JAP <jai.jap.318@gmail.com>
-# Author: Sebastien Chevalier <ptitseb@box86.org>
-pkgname=box64-rpi-git
-pkgver=r1495.e6e9fae
-pkgrel=1
-pkgdesc="Linux Userspace x86_64 Emulator with a twist, targeted at ARM64 Linux devices."
-arch=('aarch64')
-url="https://github.com/ptitSeb/box64"
-license=('MIT')
-optdepends=('gl4es: OpenGL 2 for GLES 2 devices')
-makedepends=('git' 'cmake' 'make')
-provides=("${pkgname%-git}" "${pkgname%-rpi-git}-git" "${pkgname%-rpi-git}")
-conflicts=("${pkgname%-git}" "${pkgname%-rpi-git}-git" "${pkgname%-rpi-git}")
-source=('git+https://github.com/ptitSeb/box64')
-md5sums=('SKIP')
-
-pkgver() {
- cd "$srcdir/${pkgname%-rpi-git}"
- printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
-}
-
-prepare() {
- cd "${srcdir}/${pkgname%-rpi-git}"
- if [[ ! -d ./build ]]; then
- mkdir build && cd build
- cmake .. -DRPI4ARM64=1 -DCMAKE_BUILD_TYPE=Debug -DCMAKE_INSTALL_PREFIX=/usr
- fi
-}
-
-build() {
- cd "$srcdir/${pkgname%-rpi-git}/build"
- make -j$(nproc)
-}
-
-package() {
- cd "$srcdir/${pkgname%-rpi-git}/build"
- make DESTDIR="${pkgdir}/" install
-}
diff --git a/pkgbuilds/PKGBUILD-tegra b/pkgbuilds/PKGBUILD-tegra
deleted file mode 100644
index cf4a000..0000000
--- a/pkgbuilds/PKGBUILD-tegra
+++ /dev/null
@@ -1,38 +0,0 @@
-# Maintainer: Jai-JAP <jai.jap.318@gmail.com>
-# Author: Sebastien Chevalier <ptitseb@box86.org>
-pkgname=box64-tegra-git
-pkgver=r1495.e6e9fae
-pkgrel=1
-pkgdesc="Linux Userspace x86_64 Emulator with a twist, targeted at ARM64 Linux devices."
-arch=('aarch64')
-url="https://github.com/ptitSeb/box64"
-license=('MIT')
-optdepends=('gl4es: OpenGL 2 for GLES 2 devices')
-makedepends=('git' 'cmake' 'make')
-provides=("${pkgname%-git}" "${pkgname%-tegra-git}-git" "${pkgname%-tegra-git}")
-conflicts=("${pkgname%-git}" "${pkgname%-tegra-git}-git" "${pkgname%-tegra-git}")
-source=('git+https://github.com/ptitSeb/box64')
-md5sums=('SKIP')
-
-pkgver() {
- cd "$srcdir/${pkgname%-tegra-git}"
- printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
-}
-
-prepare() {
- cd "${srcdir}/${pkgname%-tegra-git}"
- if [[ ! -d ./build ]]; then
- mkdir build && cd build
- cmake .. -DTEGRAX1=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_INSTALL_PREFIX=/usr
- fi
-}
-
-build() {
- cd "$srcdir/${pkgname%-tegra-git}/build"
- make -j$(nproc)
-}
-
-package() {
- cd "$srcdir/${pkgname%-tegra-git}/build"
- make DESTDIR="${pkgdir}/" install
-}
diff --git a/pkgbuilds/PKGBUILD-tegra-DEBUG b/pkgbuilds/PKGBUILD-tegra-DEBUG
deleted file mode 100644
index f27b968..0000000
--- a/pkgbuilds/PKGBUILD-tegra-DEBUG
+++ /dev/null
@@ -1,38 +0,0 @@
-# Maintainer: Jai-JAP <jai.jap.318@gmail.com>
-# Author: Sebastien Chevalier <ptitseb@box86.org>
-pkgname=box64-tegra-git
-pkgver=r1495.e6e9fae
-pkgrel=1
-pkgdesc="Linux Userspace x86_64 Emulator with a twist, targeted at ARM64 Linux devices."
-arch=('aarch64')
-url="https://github.com/ptitSeb/box64"
-license=('MIT')
-optdepends=('gl4es: OpenGL 2 for GLES 2 devices')
-makedepends=('git' 'cmake' 'make')
-provides=("${pkgname%-git}" "${pkgname%-tegra-git}-git" "${pkgname%-tegra-git}")
-conflicts=("${pkgname%-git}" "${pkgname%-tegra-git}-git" "${pkgname%-tegra-git}")
-source=('git+https://github.com/ptitSeb/box64')
-md5sums=('SKIP')
-
-pkgver() {
- cd "$srcdir/${pkgname%-tegra-git}"
- printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
-}
-
-prepare() {
- cd "${srcdir}/${pkgname%-tegra-git}"
- if [[ ! -d ./build ]]; then
- mkdir build && cd build
- cmake .. -DTEGRAX1=1 -DCMAKE_BUILD_TYPE=Debug -DCMAKE_INSTALL_PREFIX=/usr
- fi
-}
-
-build() {
- cd "$srcdir/${pkgname%-tegra-git}/build"
- make -j$(nproc)
-}
-
-package() {
- cd "$srcdir/${pkgname%-tegra-git}/build"
- make DESTDIR="${pkgdir}/" install
-}
diff --git a/pkgbuilds/PKGBUILD-x86_64 b/pkgbuilds/PKGBUILD-x86_64
deleted file mode 100644
index 17240e0..0000000
--- a/pkgbuilds/PKGBUILD-x86_64
+++ /dev/null
@@ -1,37 +0,0 @@
-# Maintainer: Jai-JAP <jai.jap.318@gmail.com>
-# Author: Sebastien Chevalier <ptitseb@box86.org>
-pkgname=box64-x64-git
-pkgver=r1495.e6e9fae
-pkgrel=1
-pkgdesc="Linux Userspace x86_64 Emulator with a twist, targeted at ARM64 Linux devices."
-arch=('aarch64')
-url="https://github.com/ptitSeb/box64"
-license=('MIT')
-makedepends=('git' 'cmake' 'make')
-provides=("${pkgname%-git}" "${pkgname%-x64-git}-git" "${pkgname%-x64-git}")
-conflicts=("${pkgname%-git}" "${pkgname%-x64-git}-git" "${pkgname%-x64-git}")
-source=('git+https://github.com/ptitSeb/box64')
-md5sums=('SKIP')
-
-pkgver() {
- cd "$srcdir/${pkgname%-x64-git}"
- printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
-}
-
-prepare() {
- cd "${srcdir}/${pkgname%-x64-git}"
- if [[ ! -d ./build ]]; then
- mkdir build && cd build
- cmake .. -DLD80BITS=1 -DNOALIGN=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_INSTALL_PREFIX=/usr
- fi
-}
-
-build() {
- cd "$srcdir/${pkgname%-x64-git}/build"
- make -j$(nproc)
-}
-
-package() {
- cd "$srcdir/${pkgname%-x64-git}/build"
- make DESTDIR="${pkgdir}/" install
-}
diff --git a/pkgbuilds/PKGBUILD-x86_64-DEBUG b/pkgbuilds/PKGBUILD-x86_64-DEBUG
deleted file mode 100644
index 770b7d2..0000000
--- a/pkgbuilds/PKGBUILD-x86_64-DEBUG
+++ /dev/null
@@ -1,37 +0,0 @@
-# Maintainer: Jai-JAP <jai.jap.318@gmail.com>
-# Author: Sebastien Chevalier <ptitseb@box86.org>
-pkgname=box64-x64-git
-pkgver=r1495.e6e9fae
-pkgrel=1
-pkgdesc="Linux Userspace x86_64 Emulator with a twist, targeted at ARM64 Linux devices."
-arch=('aarch64')
-url="https://github.com/ptitSeb/box64"
-license=('MIT')
-makedepends=('git' 'cmake' 'make')
-provides=("${pkgname%-git}" "${pkgname%-x64-git}-git" "${pkgname%-x64-git}")
-conflicts=("${pkgname%-git}" "${pkgname%-x64-git}-git" "${pkgname%-x64-git}")
-source=('git+https://github.com/ptitSeb/box64')
-md5sums=('SKIP')
-
-pkgver() {
- cd "$srcdir/${pkgname%-x64-git}"
- printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
-}
-
-prepare() {
- cd "${srcdir}/${pkgname%-x64-git}"
- if [[ ! -d ./build ]]; then
- mkdir build && cd build
- cmake .. -DLD80BITS=1 -DNOALIGN=1 -DCMAKE_BUILD_TYPE=Debug -DCMAKE_INSTALL_PREFIX=/usr
- fi
-}
-
-build() {
- cd "$srcdir/${pkgname%-x64-git}/build"
- make -j$(nproc)
-}
-
-package() {
- cd "$srcdir/${pkgname%-x64-git}/build"
- make DESTDIR="${pkgdir}/" install
-}
diff --git a/pkgbuilds/README.md b/pkgbuilds/README.md
deleted file mode 100644
index 6618d4f..0000000
--- a/pkgbuilds/README.md
+++ /dev/null
@@ -1,24 +0,0 @@
-# The directory containing all PKGBUILDs for BOX64
-## FAQ
-### 1. How to use it?
-Just download the `PKGBUILD-<your-platform>` (no need to download the whole repository), go to directory where you downloaded and type:
-```sh
-mv ./PKGBUILD-<your-platform> ./PKGBUILD
-cd ..
-makepkg -si
-```
-This will copy the PKGBUILD for your platform (where you type your platform name instead of `<your-platform>`), build it and install the PKGBUILD on 64-bit Archlinux ARM.
-
-In the future, I might try to do an unified PKGBUILD for all platforms that will recognize your platform automatically.
-
-### 2. What platforms are currently supported.
-All specified in [COMPILE.md](../docs/COMPILE.md).
-
-### 3. Any advantages with this solution?
-This might give you some advantages like:
-- automatic updates (with some AUR frontends like [`pamac-aur`](https://aur.archlinux.org/packages/pamac-aur/) or [`yay`](https://aur.archlinux.org/packages/yay));
-- easily uninstall with `pacman -R` when no needed (no need other scripts nor Makefile to do this);
-- your `box64` installation is recognized as a package (where it wasn't when installing with `make install`).
-
-
-### Note: You can use [makedeb](https://github.com/makedeb/makedeb) (or) [pkgbuild2spec](https://github.com/prozum/pkgbuild2spec) to compile box64 to .deb or .rpm installer files.
diff --git a/rebuild_wrappers.py b/rebuild_wrappers.py
index edd40ec..0bd25f0 100755
--- a/rebuild_wrappers.py
+++ b/rebuild_wrappers.py
@@ -152,10 +152,10 @@ class FunctionConvention(object):
self.values = valid_chars
# Free letters: B FG J QR T XYZab e gh jk mno qrst xyz
conventions = {
- 'F': FunctionConvention('F', "System V", ['E', 'v', 'c', 'w', 'i', 'I', 'C', 'W', 'u', 'U', 'f', 'd', 'D', 'K', 'l', 'L', 'p', 'V', 'O', 'S', 'N', 'M', 'H', 'P', 'A']),
+ 'F': FunctionConvention('F', "System V", ['E', 'v', 'c', 'w', 'i', 'I', 'C', 'W', 'u', 'U', 'f', 'd', 'D', 'K', 'l', 'L', 'p', 'V', 'O', 'S', 'N', 'M', 'H', 'P', 'A', 'x', 'X']),
'W': FunctionConvention('W', "Windows", ['E', 'v', 'c', 'w', 'i', 'I', 'C', 'W', 'u', 'U', 'f', 'd', 'K', 'l', 'L', 'p', 'V', 'O', 'S', 'N', 'M', 'P', 'A'])
}
-sortedvalues = ['E', 'v', 'c', 'w', 'i', 'I', 'C', 'W', 'u', 'U', 'f', 'd', 'D', 'K', 'l', 'L', 'p', 'V', 'O', 'S', 'N', 'M', 'H', 'P', 'A', '0', '1']
+sortedvalues = ['E', 'v', 'c', 'w', 'i', 'I', 'C', 'W', 'u', 'U', 'f', 'd', 'D', 'K', 'l', 'L', 'p', 'V', 'O', 'S', 'N', 'M', 'H', 'P', 'A', 'x', 'X', '0', '1']
assert(all(all(c not in conv.values[:i] and c in sortedvalues for i, c in enumerate(conv.values)) for conv in conventions.values()))
class FunctionType(str):
@@ -384,7 +384,7 @@ def readFiles(files: Iterable[Filename]) -> Tuple[JumbledGlobals, JumbledRedirec
# If you find no problem, comment the error below, add a "pass" line (so python is happy)
# and open a ticket so I can fix this.
raise NotImplementedError("Some functions are only implemented under one condition (probably) ({0}:{1})"
- .format(k, filename) + " [extra note in the script]")
+ .format(k, filename) + " [extra note in the script]\nProblematic function{}: {}".format(("" if len(funsname[k]) == 1 else "s"), funsname[k]))
for f in funsname[k]:
if f in ['_fini', '_init', '__bss_start', '__data_start', '_edata', '_end']:
continue # Always allow those symbols [TODO: check if OK]
@@ -824,13 +824,18 @@ def main(root: str, files: Iterable[Filename], ver: str):
allowed_regs : str = "cCwWiuIUlLp"
allowed_fpr : str = "fd"
+ # Detect functions which return in an x87 register
+ retx87_wraps: Dict[ClausesStr, List[FunctionType]] = {}
+ return_x87: str = "DK"
+
# Sanity checks
- forbidden_simple: str = "EDKVOSNMHPA"
+ forbidden_simple: str = "EDKVOSNMHPAxX"
assert(len(allowed_simply) + len(allowed_regs) + len(allowed_fpr) + len(forbidden_simple) == len(allowed_conv.values))
assert(all(c not in allowed_regs for c in allowed_simply))
assert(all(c not in allowed_simply + allowed_regs for c in allowed_fpr))
assert(all(c not in allowed_simply + allowed_regs + allowed_fpr for c in forbidden_simple))
assert(all(c in allowed_simply + allowed_regs + allowed_fpr + forbidden_simple for c in allowed_conv.values))
+ assert(all(c in allowed_conv.values for c in return_x87))
def check_simple(v: FunctionType) -> Optional[int]:
regs_count: int = 0
@@ -867,6 +872,15 @@ def main(root: str, files: Iterable[Filename], ver: str):
simple_wraps[k] = tmp
simple_idxs = sorted(simple_wraps.keys(), key=lambda x: Clauses(x).splitdef())
+ def check_return_x87(v: FunctionType) -> bool:
+ return v[0] in return_x87
+
+ for k in gbls:
+ tmp = [v for v in gbls[k] if check_return_x87(v)]
+ if tmp:
+ retx87_wraps[k] = tmp
+ retx87_idxs = sorted(retx87_wraps.keys(), key=lambda x: Clauses(x).splitdef())
+
# Now the files rebuilding part
# File headers and guards
files_header = {
@@ -880,6 +894,8 @@ def main(root: str, files: Iterable[Filename], ver: str):
#include "emu/x87emu_private.h"
#include "regs.h"
#include "x64emu.h"
+ #define COMPLEX_IMPL
+ #include "complext.h"
extern void* my__IO_2_1_stdin_ ;
extern void* my__IO_2_1_stdout_;
@@ -908,12 +924,14 @@ def main(root: str, files: Iterable[Filename], ver: str):
#define __WRAPPER_H_
#include <stdint.h>
#include <string.h>
+ #include "complext.h"
typedef struct x64emu_s x64emu_t;
// the generic wrapper pointer functions
typedef void (*wrapper_t)(x64emu_t* emu, uintptr_t fnc);
-
+
+
// list of defined wrapper
// E = current x86emu struct
// v = void
@@ -933,6 +951,8 @@ def main(root: str, files: Iterable[Filename], ver: str):
// M = ... automatically sending 2 args
// A = va_list
// 0 = constant 0, 1 = constant 1
+ // x = float complex
+ // X = double complex
""",
"fntypes.h": """
@@ -994,10 +1014,10 @@ def main(root: str, files: Iterable[Filename], ver: str):
# Rewrite the wrapper.c file:
# i and u should only be 32 bits
td_types = {
- # E v c w i I C W u U f d D K l L p V O S N M H P A
- 'F': ["x64emu_t*", "void", "int8_t", "int16_t", "int64_t", "int64_t", "uint8_t", "uint16_t", "uint64_t", "uint64_t", "float", "double", "long double", "double", "intptr_t", "uintptr_t", "void*", "void*", "int32_t", "void*", "...", "...", "unsigned __int128", "void*", "void*"],
+ # E v c w i I C W u U f d D K l L p V O S N M H P A x X
+ 'F': ["x64emu_t*", "void", "int8_t", "int16_t", "int32_t", "int64_t", "uint8_t", "uint16_t", "uint32_t", "uint64_t", "float", "double", "long double", "double", "intptr_t", "uintptr_t", "void*", "void*", "int32_t", "void*", "...", "...", "unsigned __int128", "void*", "void*", "complexf_t", "complex_t"],
# E v c w i I C W u U f d K l L p V O S N M P A
- 'W': ["x64emu_t*", "void", "int8_t", "int16_t", "int64_t", "int64_t", "uint8_t", "uint16_t", "uint64_t", "uint64_t", "float", "double", "double", "intptr_t", "uintptr_t", "void*", "void*", "int32_t", "void*", "...", "...", "void*", "void*"]
+ 'W': ["x64emu_t*", "void", "int8_t", "int16_t", "int32_t", "int64_t", "uint8_t", "uint16_t", "uint32_t", "uint64_t", "float", "double", "double", "intptr_t", "uintptr_t", "void*", "void*", "int32_t", "void*", "...", "...", "void*", "void*"]
}
assert(all(k in conventions for k in td_types))
for k in conventions:
@@ -1032,11 +1052,11 @@ def main(root: str, files: Iterable[Filename], ver: str):
"fn({0});", # v
"R_RAX=fn({0});", # c
"R_RAX=fn({0});", # w
- "R_RAX=(int64_t)fn({0});", # i should be int32_t
+ "R_RAX=(int32_t)fn({0});", # i
"R_RAX=(int64_t)fn({0});", # I
"R_RAX=(unsigned char)fn({0});", # C
"R_RAX=(unsigned short)fn({0});", # W
- "R_RAX=(uint64_t)fn({0});", # u should be uint32_t
+ "R_RAX=(uint32_t)fn({0});", # u
"R_RAX=fn({0});", # U
"emu->xmm[0].f[0]=fn({0});", # f
"emu->xmm[0].d[0]=fn({0});", # d
@@ -1053,17 +1073,19 @@ def main(root: str, files: Iterable[Filename], ver: str):
"unsigned __int128 u128 = fn({0}); R_RAX=(u128&0xFFFFFFFFFFFFFFFFL); R_RDX=(u128>>64)&0xFFFFFFFFFFFFFFFFL;", # H
"\n#error Invalid return type: pointer in the stack\n", # P
"\n#error Invalid return type: va_list\n", # A
+ 'from_complexf(emu, fn({0})));', # x
+ 'from_complex(emu, fn({0})));' # X
],
conventions['W']: [
"\n#error Invalid return type: emulator\n", # E
"fn({0});", # v
"R_RAX=fn({0});", # c
"R_RAX=fn({0});", # w
- "R_RAX=(int64_t)fn({0});", # i should be int32_t
+ "R_RAX=(int32_t)fn({0});", # i
"R_RAX=(int64_t)fn({0});", # I
"R_RAX=(unsigned char)fn({0});", # C
"R_RAX=(unsigned short)fn({0});", # W
- "R_RAX=(uint64_t)fn({0});", # u should be uint32_t
+ "R_RAX=(uint32_t)fn({0});", # u
"R_RAX=fn({0});", # U
"emu->xmm[0].f[0]=fn({0});", # f
"emu->xmm[0].d[0]=fn({0});", # d
@@ -1082,27 +1104,27 @@ def main(root: str, files: Iterable[Filename], ver: str):
}
# vreg: value is in a general register
- # E v c w i I C W u U f d D K l L p V O S N M H P A
- vreg = [0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 0, 1, 1, 1, 2, 2, 0, 1]
+ # E v c w i I C W u U f d D K l L p V O S N M H P A x X
+ vreg = [0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 0, 1, 1, 1, 2, 2, 0, 1, 0, 0]
# vxmm: value is in a XMM register
- # E v c w i I C W u U f d D K l L p V O S N M H P A
- vxmm = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
+ # E v c w i I C W u U f d D K l L p V O S N M H P A x X
+ vxmm = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2]
# vother: value is elsewere
- # E v c w i I C W u U f d D K l L p V O S N M H P A
- vother = [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0]
+ # E v c w i I C W u U f d D K l L p V O S N M H P A x X
+ vother = [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0]
# vstack: value is on the stack (or out of register)
- # E v c w i I C W u U f d D K l L p V O S N M H P A
- vstack = [0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 1, 1, 1, 0, 1, 1, 1, 2, 2, 1, 1]
+ # E v c w i I C W u U f d D K l L p V O S N M H P A x X
+ vstack = [0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 1, 1, 1, 0, 1, 1, 1, 2, 2, 1, 1, 1, 2]
arg_r = [
"", # E
"", # v
"(int8_t){p}, ", # c
"(int16_t){p}, ", # w
- "(int64_t){p}, ", # i should int32_t
+ "(int32_t){p}, ", # i
"(int64_t){p}, ", # I
"(uint8_t){p}, ", # C
"(uint16_t){p}, ", # W
- "(uint64_t){p}, ", # u should uint32_t
+ "(uint32_t){p}, ", # u
"(uint64_t){p}, ", # U
"", # f
"", # d
@@ -1119,6 +1141,8 @@ def main(root: str, files: Iterable[Filename], ver: str):
"\n#error Use pp instead\n", # H
"", # P
"(void*){p}, ", # A
+ "", # x
+ "", # X
]
arg_x = [
"", # E
@@ -1146,6 +1170,8 @@ def main(root: str, files: Iterable[Filename], ver: str):
"", # H
"", # P
"", # A
+ "to_complexf(emu, {p}),",# x
+ "to_complex(emu, {p})," # X
]
arg_o = [
"emu, ", # E
@@ -1173,17 +1199,19 @@ def main(root: str, files: Iterable[Filename], ver: str):
"", # H
"", # P
"", # A
+ "", # x
+ "", # X
]
arg_s = [
"", # E
"", # v
"*(int8_t*)(R_RSP + {p}), ", # c
"*(int16_t*)(R_RSP + {p}), ", # w
- "*(int64_t*)(R_RSP + {p}), ", # i should be int32_t
+ "*(int32_t*)(R_RSP + {p}), ", # i
"*(int64_t*)(R_RSP + {p}), ", # I
"*(uint8_t*)(R_RSP + {p}), ", # C
"*(uint16_t*)(R_RSP + {p}), ", # W
- "*(uint64_t*)(R_RSP + {p}), ", # u should be uint32_t
+ "*(uint32_t*)(R_RSP + {p}), ", # u
"*(uint64_t*)(R_RSP + {p}), ", # U
"*(float*)(R_RSP + {p}), ", # f
"*(double*)(R_RSP + {p}), ", # d
@@ -1200,6 +1228,8 @@ def main(root: str, files: Iterable[Filename], ver: str):
"*(unsigned __int128)(R_RSP + {p}), ", # H
"*(void**)(R_RSP + {p}), ", # P
"*(void**)(R_RSP + {p}), ", # A
+ "*(complexf_t*)(R_RSP + {p}), ", # x
+ "*(complex_t*)(R_RSP + {p}), ", # X
]
# Asserts
@@ -1365,6 +1395,17 @@ def main(root: str, files: Iterable[Filename], ver: str):
file.write("#endif\n")
file.write("\treturn 0;\n}\n")
+ # Write the isRetX87Wrapper function
+ file.write("\nint isRetX87Wrapper(wrapper_t fun) {\n")
+ for k in retx87_idxs:
+ if k != str(Clauses()):
+ file.write("#if " + k + "\n")
+ for vf in retx87_wraps[k]:
+ file.write("\tif (fun == &" + vf + ") return 1;\n")
+ if k != str(Clauses()):
+ file.write("#endif\n")
+ file.write("\treturn 0;\n}\n")
+
file.write(files_guard["wrapper.c"].format(lbr="{", rbr="}", version=ver))
# Rewrite the wrapper.h file:
@@ -1438,6 +1479,6 @@ if __name__ == '__main__':
if v == "--":
limit.append(i)
Define.defines = list(map(DefineType, sys.argv[2:limit[0]]))
- if main(sys.argv[1], sys.argv[limit[0]+1:], "2.2.0.16") != 0:
+ if main(sys.argv[1], sys.argv[limit[0]+1:], "2.2.0.18") != 0:
exit(2)
exit(0)
diff --git a/runTest.cmake b/runTest.cmake
index 11ab75f..11ab75f 100755..100644
--- a/runTest.cmake
+++ b/runTest.cmake
diff --git a/src/box64context.c b/src/box64context.c
index 95b4a5b..234657c 100755..100644
--- a/src/box64context.c
+++ b/src/box64context.c
@@ -76,7 +76,7 @@ int unlockMutex()
{
int ret = unlockCustommemMutex();
int i;
- #ifdef DYNAREC
+ #ifdef USE_CUSTOM_MUTEX
uint32_t tid = (uint32_t)GetTID();
#define GO(A, B) \
i = (native_lock_storeifref2_d(&A, 0, tid)==tid); \
@@ -138,11 +138,24 @@ static void init_mutexes(box64context_t* context)
pthread_mutexattr_destroy(&attr);
#else
+ #ifdef USE_CUSTOM_MUTEX
native_lock_store(&context->mutex_trace, 0);
native_lock_store(&context->mutex_tls, 0);
native_lock_store(&context->mutex_thread, 0);
native_lock_store(&context->mutex_bridge, 0);
native_lock_store(&context->mutex_dyndump, 0);
+ #else
+ pthread_mutexattr_t attr;
+ pthread_mutexattr_init(&attr);
+ pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_ERRORCHECK);
+ pthread_mutex_init(&context->mutex_trace, &attr);
+ pthread_mutex_init(&context->mutex_tls, &attr);
+ pthread_mutex_init(&context->mutex_thread, &attr);
+ pthread_mutex_init(&context->mutex_bridge, &attr);
+ pthread_mutex_init(&context->mutex_dyndump, &attr);
+ pthread_mutexattr_destroy(&attr);
+ #endif
+ pthread_mutex_init(&context->mutex_lock, NULL);
#endif
}
@@ -191,7 +204,7 @@ box64context_t *NewBox64Context(int argc)
initCycleLog(context);
- context->deferedInit = 1;
+ context->deferredInit = 1;
context->sel_serial = 1;
init_custommem_helper(context);
@@ -200,8 +213,7 @@ box64context_t *NewBox64Context(int argc)
context->local_maplib = NewLibrarian(context, 1);
context->versym = NewDictionnary();
context->system = NewBridge();
- context->globaldefver = NewDefaultVersion();
- context->weakdefver = NewDefaultVersion();
+ // Cannot use Bridge name as the map is not initialized yet
// create vsyscall
context->vsyscall = AddBridge(context->system, vFEv, x64Syscall, 0, NULL);
// create the vsyscalls
@@ -212,6 +224,8 @@ box64context_t *NewBox64Context(int argc)
addAlternate((void*)0xffffffffff600000, (void*)context->vsyscalls[0]);
addAlternate((void*)0xffffffffff600400, (void*)context->vsyscalls[1]);
addAlternate((void*)0xffffffffff600800, (void*)context->vsyscalls[2]);
+ // create exit bridge
+ context->exit_bridge = AddBridge(context->system, NULL, NULL, 0, NULL);
// get handle to box64 itself
context->box64lib = dlopen(NULL, RTLD_NOW|RTLD_GLOBAL);
context->dlprivate = NewDLPrivate();
@@ -229,6 +243,24 @@ box64context_t *NewBox64Context(int argc)
context->canary[getrand(4)] = 0;
printf_log(LOG_DEBUG, "Setting up canary (for Stack protector) at FS:0x28, value:%08X\n", *(uint32_t*)context->canary);
+ // init segments
+ for(int i=0; i<16; i++) {
+ context->segtls[i].limit = (uintptr_t)-1LL;
+ }
+ context->segtls[10].key_init = 0; // 0x53 selector
+ context->segtls[10].present = 1;
+ context->segtls[8].key_init = 0; // 0x43 selector
+ context->segtls[8].present = 1;
+ context->segtls[6].key_init = 0; // 0x33 selector
+ context->segtls[6].present = 1;
+ context->segtls[5].key_init = 0; // 0x2b selector
+ context->segtls[5].present = 1;
+ context->segtls[4].key_init = 0; // 0x23 selector
+ context->segtls[4].present = 1;
+ context->segtls[4].is32bits = 1;
+
+ context->globdata = NewMapSymbols();
+
initAllHelpers(context);
return context;
@@ -251,8 +283,6 @@ void FreeBox64Context(box64context_t** context)
if(ctx->maplib)
FreeLibrarian(&ctx->maplib, NULL);
FreeDictionnary(&ctx->versym);
- FreeDefaultVersion(&ctx->globaldefver);
- FreeDefaultVersion(&ctx->weakdefver);
for(int i=0; i<ctx->elfsize; ++i) {
FreeElfHeader(&ctx->elfs[i]);
@@ -265,11 +295,13 @@ void FreeBox64Context(box64context_t** context)
// stop trace now
if(ctx->dec)
DeleteX64TraceDecoder(&ctx->dec);
+ if(ctx->dec32)
+ DeleteX86TraceDecoder(&ctx->dec32);
if(ctx->zydis)
DeleteX64Trace(ctx);
- if(ctx->deferedInitList)
- box_free(ctx->deferedInitList);
+ if(ctx->deferredInitList)
+ box_free(ctx->deferredInitList);
/*box_free(ctx->argv);*/
@@ -323,9 +355,13 @@ void FreeBox64Context(box64context_t** context)
if(ctx->emu_sig)
FreeX64Emu(&ctx->emu_sig);
+ FreeMapSymbols(&ctx->globdata);
+
finiAllHelpers(ctx);
-#ifndef DYNAREC
+#ifdef DYNAREC
+ pthread_mutex_destroy(&ctx->mutex_lock);
+#else
pthread_mutex_destroy(&ctx->mutex_trace);
pthread_mutex_destroy(&ctx->mutex_lock);
pthread_mutex_destroy(&ctx->mutex_tls);
@@ -339,20 +375,44 @@ void FreeBox64Context(box64context_t** context)
}
int AddElfHeader(box64context_t* ctx, elfheader_t* head) {
- int idx = ctx->elfsize;
- if(idx==ctx->elfcap) {
- // resize...
- ctx->elfcap += 16;
- ctx->elfs = (elfheader_t**)box_realloc(ctx->elfs, sizeof(elfheader_t*) * ctx->elfcap);
+ int idx = 0;
+ while(idx<ctx->elfsize && ctx->elfs[idx]) idx++;
+ if(idx == ctx->elfsize) {
+ if(idx==ctx->elfcap) {
+ // resize...
+ ctx->elfcap += 16;
+ ctx->elfs = (elfheader_t**)box_realloc(ctx->elfs, sizeof(elfheader_t*) * ctx->elfcap);
+ }
+ ctx->elfs[idx] = head;
+ ctx->elfsize++;
+ } else {
+ ctx->elfs[idx] = head;
}
- ctx->elfs[idx] = head;
- ctx->elfsize++;
printf_log(LOG_DEBUG, "Adding \"%s\" as #%d in elf collection\n", ElfName(head), idx);
return idx;
}
+void RemoveElfHeader(box64context_t* ctx, elfheader_t* head) {
+ if(GetTLSBase(head)) {
+ // should remove the tls info
+ int tlsbase = GetTLSBase(head);
+ /*if(tlsbase == -ctx->tlssize) {
+ // not really correct, but will do for now
+ ctx->tlssize -= GetTLSSize(head);
+ if(!(++ctx->sel_serial))
+ ++ctx->sel_serial;
+ }*/
+ }
+ for(int i=0; i<ctx->elfsize; ++i)
+ if(ctx->elfs[i] == head) {
+ ctx->elfs[i] = NULL;
+ return;
+ }
+}
+
int AddTLSPartition(box64context_t* context, int tlssize) {
int oldsize = context->tlssize;
+ // should in fact first try to map a hole, but rewinding all elfs and checking filled space, like with the mapmem utilities
context->tlssize += tlssize;
context->tlsdata = box_realloc(context->tlsdata, context->tlssize);
memmove(context->tlsdata+tlssize, context->tlsdata, oldsize); // move to the top, using memmove as regions will probably overlap
diff --git a/src/box64version.h b/src/box64version.h
index c6defd1..ea108de 100755..100644
--- a/src/box64version.h
+++ b/src/box64version.h
@@ -3,6 +3,6 @@
#define BOX64_MAJOR 0
#define BOX64_MINOR 2
-#define BOX64_REVISION 2
+#define BOX64_REVISION 4
#endif //__BOX64_VERSION_H_
diff --git a/src/build_info.c b/src/build_info.c
index 02c19b4..02c19b4 100755..100644
--- a/src/build_info.c
+++ b/src/build_info.c
diff --git a/src/build_info.h b/src/build_info.h
index 45182a0..18456a4 100755..100644
--- a/src/build_info.h
+++ b/src/build_info.h
@@ -1,6 +1,6 @@
#ifndef __BUILD_INFO_H__
#define __BUILD_INFO_H__
-void PrintBox64Version();
+void PrintBox64Version(void);
#endif //__BUILD_INFO_H__ \ No newline at end of file
diff --git a/src/custommem.c b/src/custommem.c
index 633e15f..a92f983 100644
--- a/src/custommem.c
+++ b/src/custommem.c
@@ -26,6 +26,7 @@
#include "threads.h"
#ifdef DYNAREC
#include "dynablock.h"
+#include "dynarec/dynablock_private.h"
#include "dynarec/native_lock.h"
#include "dynarec/dynarec_next.h"
@@ -41,12 +42,17 @@ static uintptr_t box64_jmptbldefault0[1<<JMPTABL_SHIFT0];
// lock addresses
KHASH_SET_INIT_INT64(lockaddress)
static kh_lockaddress_t *lockaddress = NULL;
+#ifdef USE_CUSTOM_MUTEX
static uint32_t mutex_prot;
static uint32_t mutex_blocks;
#else
static pthread_mutex_t mutex_prot;
static pthread_mutex_t mutex_blocks;
#endif
+#else
+static pthread_mutex_t mutex_prot;
+static pthread_mutex_t mutex_blocks;
+#endif
#if defined(PAGE64K)
#define MEMPROT_SHIFT 16
#define MEMPROT_SHIFT2 (16+16)
@@ -110,14 +116,14 @@ typedef struct blockmark_s {
#define PREV_BLOCK(b) (blockmark_t*)(((uintptr_t)(b) - (b)->prev.size) - sizeof(blockmark_t))
#define LAST_BLOCK(b, s) (blockmark_t*)(((uintptr_t)(b)+(s))-sizeof(blockmark_t))
-static void printBlock(blockmark_t* b, void* start)
+void printBlock(blockmark_t* b, void* start)
{
- printf_log(LOG_INFO, "========== Block is:\n");
+ printf_log(LOG_NONE, "========== Block is:\n");
do {
- printf_log(LOG_INFO, "%c%p, fill=%d, size=0x%x (prev=%d/0x%x)\n", b==start?'*':' ', b, b->next.fill, b->next.size, b->prev.fill, b->prev.size);
+ printf_log(LOG_NONE, "%c%p, fill=%d, size=0x%x (prev=%d/0x%x)\n", b==start?'*':' ', b, b->next.fill, b->next.size, b->prev.fill, b->prev.size);
b = NEXT_BLOCK(b);
} while(b->next.x32);
- printf_log(LOG_INFO, "===================\n");
+ printf_log(LOG_NONE, "===================\n");
}
// get first subblock free in block. Return NULL if no block, else first subblock free (mark included), filling size
@@ -181,6 +187,8 @@ static size_t getMaxFreeBlock(void* block, size_t block_size, void* start)
}
}
+#define THRESHOLD (128-2*sizeof(blockmark_t))
+
static void* allocBlock(void* block, void *sub, size_t size, void** pstart)
{
(void)block;
@@ -190,25 +198,26 @@ static void* allocBlock(void* block, void *sub, size_t size, void** pstart)
s->next.fill = 1;
// check if a new mark is worth it
- if(s->next.size>size+2*sizeof(blockmark_t))
+ if(s->next.size>size+2*sizeof(blockmark_t)+THRESHOLD) {
+ size_t old_size = s->next.size;
s->next.size = size;
- blockmark_t *m = NEXT_BLOCK(s); // this is new n
- m->prev.fill = 1;
- if(n!=m) {
- // new mark
+ blockmark_t *m = NEXT_BLOCK(s);
+ m->prev.fill = 1;
m->prev.size = s->next.size;
m->next.fill = 0;
- m->next.size = ((uintptr_t)n - (uintptr_t)m) - sizeof(blockmark_t);
+ m->next.size = old_size - (size + sizeof(blockmark_t));
n->prev.fill = 0;
n->prev.size = m->next.size;
+ n = m;
+ } else {
+ n->prev.fill = 1;
}
if(pstart && sub==*pstart) {
// get the next free block
- m = (blockmark_t*)*pstart;
- while(m->next.fill)
- m = NEXT_BLOCK(m);
- *pstart = (void*)m;
+ while(n->next.fill)
+ n = NEXT_BLOCK(n);
+ *pstart = (void*)n;
}
return (void*)((uintptr_t)sub + sizeof(blockmark_t));
}
@@ -222,7 +231,7 @@ static size_t freeBlock(void *block, void* sub, void** pstart)
s->next.fill = 0;
n->prev.fill = 0;
// check if merge with previous
- if (s->prev.x32 && !s->prev.fill) {
+ if (m!=s && s->prev.x32 && !s->prev.fill) {
// remove s...
m->next.size += s->next.size + sizeof(blockmark_t);
n->prev.size = m->next.size;
@@ -235,7 +244,7 @@ static size_t freeBlock(void *block, void* sub, void** pstart)
s->next.size += n->next.size + sizeof(blockmark_t);
n2->prev.size = s->next.size;
}
- if(pstart && (uintptr_t)*pstart>(uintptr_t)sub) {
+ if(pstart && (uintptr_t)*pstart>(uintptr_t)s) {
*pstart = (void*)s;
}
// return free size at current block (might be bigger)
@@ -258,7 +267,7 @@ static int expandBlock(void* block, void* sub, size_t newsize)
if((size_t)(s->next.size + n->next.size + sizeof(blockmark_t)) < newsize)
return 0; // free space too short
// ok, doing the alloc!
- if((s->next.size+n->next.size+sizeof(blockmark_t))-newsize<2*sizeof(blockmark_t))
+ if((s->next.size+n->next.size+sizeof(blockmark_t))-newsize<THRESHOLD+2*sizeof(blockmark_t))
s->next.size += n->next.size+sizeof(blockmark_t);
else
s->next.size = newsize+sizeof(blockmark_t);
@@ -283,7 +292,61 @@ static size_t sizeBlock(void* sub)
return s->next.size;
}
-#define THRESHOLD (128-2*sizeof(blockmark_t))
+// return 1 if block is coherent, 0 if not (and printf the issues)
+int printBlockCoherent(int i)
+{
+ if(i<0 || i>=n_blocks) {
+ printf_log(LOG_NONE, "Error, %d should be between 0 and %d\n", i, n_blocks);
+ return 0;
+ }
+ int ret = 1;
+ blockmark_t* m = (blockmark_t*)p_blocks[i].block;
+ // check if first is correct
+ blockmark_t* first = getNextFreeBlock(m);
+ if(p_blocks[i].first && p_blocks[i].first!=first) {printf_log(LOG_NONE, "First %p and stored first %p differs for block %d\n", first, p_blocks[i].first, i); ret = 0;}
+ // check if maxfree is correct, with no hint
+ size_t maxfree = getMaxFreeBlock(m, p_blocks[i].size, NULL);
+ if(maxfree != p_blocks[i].maxfree) {printf_log(LOG_NONE, "Maxfree without hint %zd and stored maxfree %zd differs for block %d\n", maxfree, p_blocks[i].maxfree, i); ret = 0;}
+ // check if maxfree from first is correct
+ maxfree = getMaxFreeBlock(m, p_blocks[i].size, p_blocks[i].first);
+ if(maxfree != p_blocks[i].maxfree) {printf_log(LOG_NONE, "Maxfree with hint %zd and stored maxfree %zd differs for block %d\n", maxfree, p_blocks[i].maxfree, i); ret = 0;}
+ // check chain
+ blockmark_t* last = (blockmark_t*)(((uintptr_t)m)+p_blocks[i].size-sizeof(blockmark_t));
+ while(m<last) {
+ blockmark_t* n = NEXT_BLOCK(m);
+ if(!m->next.fill && !n->next.fill && n!=last) {
+ printf_log(LOG_NONE, "Chain contains 2 subsequent free blocks %p (%d) and %p (%d) for block %d\n", m, m->next.size, n, n->next.size, i);
+ ret = 0;
+ }
+ m = n;
+ }
+ if(m!=last) {
+ printf_log(LOG_NONE, "Last block %p is behond expexted block %p for block %d\n", m, last, i);
+ ret = 0;
+ }
+
+ return ret;
+}
+
+void testAllBlocks()
+{
+ size_t total = 0;
+ size_t fragmented_free = 0;
+ size_t max_free = 0;
+ for(int i=0; i<n_blocks; ++i) {
+ printBlockCoherent(i);
+ total += p_blocks[i].size;
+ if(max_free<p_blocks[i].maxfree)
+ max_free = p_blocks[i].maxfree;
+ blockmark_t* m = (blockmark_t*)p_blocks[i].block;
+ while(m->next.x32) {
+ if(!m->next.fill)
+ fragmented_free += m->next.size;
+ m = NEXT_BLOCK(m);
+ }
+ }
+ printf_log(LOG_NONE, "Total %d blocks, for %zd allocated memory, max_free %zd, toatal fragmented free %zd\n", n_blocks, total, max_free, fragmented_free);
+}
static size_t roundSize(size_t size)
{
@@ -314,9 +377,7 @@ void* customMalloc(size_t size)
if(sub) {
if(rsize-size<THRESHOLD)
size = rsize;
- void* ret = allocBlock(p_blocks[i].block, sub, size, NULL);
- if(sub==p_blocks[i].first)
- p_blocks[i].first = getNextFreeBlock(sub);
+ void* ret = allocBlock(p_blocks[i].block, sub, size, &p_blocks[i].first);
if(rsize==p_blocks[i].maxfree)
p_blocks[i].maxfree = getMaxFreeBlock(p_blocks[i].block, p_blocks[i].size, p_blocks[i].first);
mutex_unlock(&mutex_blocks);
@@ -353,8 +414,8 @@ void* customMalloc(size_t size)
n->prev.fill = 0;
n->prev.size = m->next.size;
// alloc 1st block
- void* ret = allocBlock(p_blocks[i].block, p, size, NULL);
- p_blocks[i].maxfree = getMaxFreeBlock(p_blocks[i].block, p_blocks[i].size, NULL);
+ void* ret = allocBlock(p_blocks[i].block, p, size, &p_blocks[i].first);
+ p_blocks[i].maxfree = getMaxFreeBlock(p_blocks[i].block, p_blocks[i].size, p_blocks[i].first);
mutex_unlock(&mutex_blocks);
return ret;
}
@@ -377,7 +438,7 @@ void* customRealloc(void* p, size_t size)
&& (addr<((uintptr_t)p_blocks[i].block+p_blocks[i].size))) {
void* sub = (void*)(addr-sizeof(blockmark_t));
if(expandBlock(p_blocks[i].block, sub, size)) {
- if(sub<p_blocks[i].first && p+size<p_blocks[i].first)
+ if(sub<p_blocks[i].first && p+size>=p_blocks[i].first)
p_blocks[i].first = getNextFreeBlock(sub);
p_blocks[i].maxfree = getMaxFreeBlock(p_blocks[i].block, p_blocks[i].size, p_blocks[i].first);
mutex_unlock(&mutex_blocks);
@@ -405,10 +466,7 @@ void customFree(void* p)
if ((addr>(uintptr_t)p_blocks[i].block)
&& (addr<((uintptr_t)p_blocks[i].block+p_blocks[i].size))) {
void* sub = (void*)(addr-sizeof(blockmark_t));
- void* n = NEXT_BLOCK((blockmark_t*)sub);
- size_t newfree = freeBlock(p_blocks[i].block, sub, NULL);
- if(sub<=p_blocks[i].first)
- p_blocks[i].first = getPrevFreeBlock(n);
+ size_t newfree = freeBlock(p_blocks[i].block, sub, &p_blocks[i].first);
if(p_blocks[i].maxfree < newfree) p_blocks[i].maxfree = newfree;
mutex_unlock(&mutex_blocks);
return;
@@ -557,10 +615,7 @@ void FreeDynarecMap(uintptr_t addr)
if ((addr>(uintptr_t)list->chunks[i].block)
&& (addr<((uintptr_t)list->chunks[i].block+list->chunks[i].size))) {
void* sub = (void*)(addr-sizeof(blockmark_t));
- void* n = NEXT_BLOCK((blockmark_t*)sub);
- size_t newfree = freeBlock(list->chunks[i].block, sub, NULL);
- if(sub<=list->chunks[i].first)
- list->chunks[i].first = getPrevFreeBlock(n);
+ size_t newfree = freeBlock(list->chunks[i].block, sub, &list->chunks[i].first);
if(list->chunks[i].maxfree < newfree)
list->chunks[i].maxfree = newfree;
return;
@@ -589,6 +644,7 @@ static uintptr_t getDBSize(uintptr_t addr, size_t maxsize, dynablock_t** db)
uintptr_t* block = box64_jmptbl3[idx3][idx2][idx1];
if(block == box64_jmptbldefault0)
return (((addr>>JMPTABL_START1)+1)<<JMPTABL_START1);
+ maxsize+=idx0; // need to adjust maxsize to "end in current block"
if (maxsize>JMPTABLE_MASK0)
maxsize = JMPTABLE_MASK0;
while(block[idx0]==(uintptr_t)native_next) {
@@ -770,6 +826,28 @@ dynablock_t* getDB(uintptr_t addr)
return *(dynablock_t**)(ret - sizeof(void*));
}
+int getNeedTest(uintptr_t addr)
+{
+ uintptr_t idx3, idx2, idx1, idx0;
+ idx3 = ((addr)>>JMPTABL_START3)&JMPTABLE_MASK3;
+ idx2 = ((addr)>>JMPTABL_START2)&JMPTABLE_MASK2;
+ idx1 = ((addr)>>JMPTABL_START1)&JMPTABLE_MASK1;
+ idx0 = ((addr) )&JMPTABLE_MASK0;
+ uintptr_t ret = (uintptr_t)box64_jmptbl3[idx3][idx2][idx1][idx0];
+ dynablock_t* db = *(dynablock_t**)(ret - sizeof(void*));
+ return db?((ret!=(uintptr_t)db->block)?1:0):0;
+}
+
+uintptr_t getJumpAddress64(uintptr_t addr)
+{
+ uintptr_t idx3, idx2, idx1, idx0;
+ idx3 = ((addr)>>JMPTABL_START3)&JMPTABLE_MASK3;
+ idx2 = ((addr)>>JMPTABL_START2)&JMPTABLE_MASK2;
+ idx1 = ((addr)>>JMPTABL_START1)&JMPTABLE_MASK1;
+ idx0 = ((addr) )&JMPTABLE_MASK0;
+ return (uintptr_t)box64_jmptbl3[idx3][idx2][idx1][idx0];
+}
+
// Remove the Write flag from an adress range, so DB can be executed safely
void protectDB(uintptr_t addr, uintptr_t size)
{
@@ -795,14 +873,16 @@ void protectDB(uintptr_t addr, uintptr_t size)
uint32_t prot = memprot[i>>16].prot[i&0xffff];
uint32_t dyn = prot&PROT_DYN;
uint32_t mapped = prot&PROT_MMAP;
- prot&=~PROT_CUSTOM;
if(!prot)
prot = PROT_READ | PROT_WRITE | PROT_EXEC; // comes from malloc & co, so should not be able to execute
- if((prot&PROT_WRITE)) {
- if(!dyn) mprotect((void*)(i<<MEMPROT_SHIFT), 1<<MEMPROT_SHIFT, prot&~PROT_WRITE);
- memprot[i>>16].prot[i&0xffff] = prot|mapped|PROT_DYNAREC; // need to use atomic exchange?
- } else
- memprot[i>>16].prot[i&0xffff] = prot|mapped|PROT_DYNAREC_R;
+ prot&=~PROT_CUSTOM;
+ if(!(dyn&PROT_NOPROT)) {
+ if(prot&PROT_WRITE) {
+ if(!dyn) mprotect((void*)(i<<MEMPROT_SHIFT), 1<<MEMPROT_SHIFT, prot&~PROT_WRITE);
+ memprot[i>>16].prot[i&0xffff] = prot|mapped|PROT_DYNAREC; // need to use atomic exchange?
+ } else
+ memprot[i>>16].prot[i&0xffff] = prot|mapped|PROT_DYNAREC_R;
+ }
}
mutex_unlock(&mutex_prot);
}
@@ -824,14 +904,16 @@ void unprotectDB(uintptr_t addr, size_t size, int mark)
i=(((i>>16)+1)<<16)-1; // next block
} else {
uint32_t prot = memprot[i>>16].prot[i&0xffff];
- if(prot&PROT_DYNAREC) {
- prot&=~PROT_DYN;
- if(mark)
- cleanDBFromAddressRange((i<<MEMPROT_SHIFT), 1<<MEMPROT_SHIFT, 0);
- mprotect((void*)(i<<MEMPROT_SHIFT), 1<<MEMPROT_SHIFT, prot&~PROT_MMAP);
- memprot[i>>16].prot[i&0xffff] = prot; // need to use atomic exchange?
- } else if(prot&PROT_DYNAREC_R)
- memprot[i>>16].prot[i&0xffff] = prot&~PROT_CUSTOM;
+ if(!(prot&PROT_NOPROT)) {
+ if(prot&PROT_DYNAREC) {
+ prot&=~PROT_DYN;
+ if(mark)
+ cleanDBFromAddressRange((i<<MEMPROT_SHIFT), 1<<MEMPROT_SHIFT, 0);
+ mprotect((void*)(i<<MEMPROT_SHIFT), 1<<MEMPROT_SHIFT, prot&~PROT_MMAP);
+ memprot[i>>16].prot[i&0xffff] = prot; // need to use atomic exchange?
+ } else if(prot&PROT_DYNAREC_R)
+ memprot[i>>16].prot[i&0xffff] = prot&~PROT_CUSTOM;
+ }
}
}
mutex_unlock(&mutex_prot);
@@ -977,11 +1059,13 @@ void updateProtection(uintptr_t addr, size_t size, uint32_t prot)
uint32_t old_prot = memprot[i>>16].prot[i&0xffff];
uint32_t dyn=(old_prot&PROT_DYN);
uint32_t mapped=(old_prot&PROT_MMAP);
- if(dyn && (prot&PROT_WRITE)) { // need to remove the write protection from this block
- dyn = PROT_DYNAREC;
- mprotect((void*)(i<<MEMPROT_SHIFT), 1<<MEMPROT_SHIFT, prot&~PROT_WRITE);
- } else if(dyn && !(prot&PROT_WRITE)) {
- dyn = PROT_DYNAREC_R;
+ if(!(dyn&PROT_NOPROT)) {
+ if(dyn && (prot&PROT_WRITE)) { // need to remove the write protection from this block
+ dyn = PROT_DYNAREC;
+ mprotect((void*)(i<<MEMPROT_SHIFT), 1<<MEMPROT_SHIFT, prot&~PROT_WRITE);
+ } else if(dyn && !(prot&PROT_WRITE)) {
+ dyn = PROT_DYNAREC_R;
+ }
}
memprot[i>>16].prot[i&0xffff] = prot|dyn|mapped;
}
@@ -1017,7 +1101,13 @@ void setProtection(uintptr_t addr, size_t size, uint32_t prot)
void setProtection_mmap(uintptr_t addr, size_t size, uint32_t prot)
{
- setProtection(addr, size, prot|PROT_MMAP);
+ if(prot)
+ setProtection(addr, size, prot|PROT_MMAP);
+ else {
+ mutex_lock(&mutex_prot);
+ addMapMem(addr, addr+size-1);
+ mutex_unlock(&mutex_prot);
+ }
}
void refreshProtection(uintptr_t addr)
@@ -1026,8 +1116,10 @@ void refreshProtection(uintptr_t addr)
uintptr_t idx = (addr>>MEMPROT_SHIFT);
if(memprot[idx>>16].prot!=memprot_default) {
int prot = memprot[idx>>16].prot[idx&0xffff];
- int ret = mprotect((void*)(idx<<MEMPROT_SHIFT), box64_pagesize, prot&~PROT_CUSTOM);
+ if(!(prot&PROT_DYNAREC)) {
+ int ret = mprotect((void*)(idx<<MEMPROT_SHIFT), box64_pagesize, prot&~PROT_CUSTOM);
printf_log(LOG_INFO, "refreshProtection(%p): %p/0x%x (ret=%d/%s)\n", (void*)addr, (void*)(idx<<MEMPROT_SHIFT), prot, ret, ret?strerror(errno):"ok");
+ }
}
mutex_unlock(&mutex_prot);
}
@@ -1279,7 +1371,7 @@ int unlockCustommemMutex()
{
int ret = 0;
int i = 0;
- #ifdef DYNAREC
+ #ifdef USE_CUSTOM_MUTEX
uint32_t tid = (uint32_t)GetTID();
#define GO(A, B) \
i = (native_lock_storeifref2_d(&A, 0, tid)==tid); \
@@ -1312,7 +1404,7 @@ void relockCustommemMutex(int locks)
static void init_mutexes(void)
{
- #ifdef DYNAREC
+ #ifdef USE_CUSTOM_MUTEX
native_lock_store(&mutex_blocks, 0);
native_lock_store(&mutex_prot, 0);
#else
@@ -1332,6 +1424,34 @@ static void atfork_child_custommem(void)
init_mutexes();
}
+void reserveHighMem()
+{
+ char* p = getenv("BOX64_RESERVE_HIGH");
+ if(!p || p[0]=='0')
+ return; // don't reserve by default
+ intptr_t cur = 1LL<<47;
+ mapmem_t* m = mapmem;
+ while(m && (m->end<cur)) {
+ m = m->next;
+ }
+ while (m) {
+ uintptr_t addr = 0, end = 0;
+ if(m->begin>cur) {
+ void* ret = mmap64((void*)cur, m->begin-cur, 0, MAP_ANONYMOUS|MAP_FIXED|MAP_PRIVATE|MAP_NORESERVE, -1, 0);
+ printf_log(LOG_DEBUG, "Reserve %p-%p => %p (%s)\n", (void*)cur, m->begin, ret, strerror(errno));
+ printf_log(LOG_DEBUG, "mmap %p-%p\n", m->begin, m->end);
+ if(ret!=(void*)-1) {
+ addr = cur;
+ end = m->begin;
+ }
+ }
+ cur = m->end + 1;
+ m = m->next;
+ if(addr)
+ addMapMem(addr, end);
+ }
+}
+
void init_custommem_helper(box64context_t* ctx)
{
(void)ctx;
@@ -1343,7 +1463,7 @@ void init_custommem_helper(box64context_t* ctx)
memprot[i].prot = memprot_default;
init_mutexes();
#ifdef DYNAREC
- if(box64_dynarec)
+ if(box64_dynarec) {
for(int i=0; i<(1<<JMPTABL_SHIFT3); ++i)
box64_jmptbl3[i] = box64_jmptbldefault2;
for(int i=0; i<(1<<JMPTABL_SHIFT2); ++i)
@@ -1352,6 +1472,7 @@ void init_custommem_helper(box64context_t* ctx)
box64_jmptbldefault1[i] = box64_jmptbldefault0;
for(int i=0; i<(1<<JMPTABL_SHIFT0); ++i)
box64_jmptbldefault0[i] = (uintptr_t)native_next;
+ }
lockaddress = kh_init(lockaddress);
#endif
pthread_atfork(NULL, NULL, atfork_child_custommem);
@@ -1360,9 +1481,10 @@ void init_custommem_helper(box64context_t* ctx)
mapmem->begin = 0x0;
mapmem->end = (uintptr_t)LOWEST - 1;
loadProtectionFromMap();
+ reserveHighMem();
// check if PageSize is correctly defined
if(box64_pagesize != (1<<MEMPROT_SHIFT)) {
- printf_log(LOG_NONE, "Error: PageSize configuation is wrong: configured with %d, but got %zd\n", 1<<MEMPROT_SHIFT, box64_pagesize);
+ printf_log(LOG_NONE, "Error: PageSize configuration is wrong: configured with %d, but got %zd\n", 1<<MEMPROT_SHIFT, box64_pagesize);
exit(-1); // abort or let it continue?
}
}
@@ -1446,7 +1568,7 @@ void fini_custommem_helper(box64context_t *ctx)
box_free(p_blocks[i].block);
#endif
box_free(p_blocks);
- #ifndef DYNAREC
+ #ifndef USE_CUSTOM_MUTEX
pthread_mutex_destroy(&mutex_prot);
pthread_mutex_destroy(&mutex_blocks);
#endif
diff --git a/src/dynarec/arm64/arm64_emitter.h b/src/dynarec/arm64/arm64_emitter.h
index 5a44052..02ba209 100755..100644
--- a/src/dynarec/arm64/arm64_emitter.h
+++ b/src/dynarec/arm64/arm64_emitter.h
@@ -130,6 +130,7 @@
}
#define MOV64xw(Rd, imm64) if(rex.w) {MOV64x(Rd, imm64);} else {MOV32w(Rd, imm64);}
+#define MOV64z(Rd, imm64) if(rex.is32bits) {MOV32w(Rd, imm64);} else {MOV64x(Rd, imm64);}
// ADD / SUB
@@ -141,6 +142,7 @@
#define ADDSw_REG(Rd, Rn, Rm) EMIT(ADDSUB_REG_gen(0, 0, 1, 0b00, Rm, 0, Rn, Rd))
#define ADDw_REG_LSL(Rd, Rn, Rm, lsl) EMIT(ADDSUB_REG_gen(0, 0, 0, 0b00, Rm, lsl, Rn, Rd))
#define ADDxw_REG(Rd, Rn, Rm) EMIT(ADDSUB_REG_gen(rex.w, 0, 0, 0b00, Rm, 0, Rn, Rd))
+#define ADDz_REG(Rd, Rn, Rm) EMIT(ADDSUB_REG_gen(rex.is32bits?0:1, 0, 0, 0b00, Rm, 0, Rn, Rd))
#define ADDSxw_REG(Rd, Rn, Rm) EMIT(ADDSUB_REG_gen(rex.w, 0, 1, 0b00, Rm, 0, Rn, Rd))
#define ADDxw_REG_LSR(Rd, Rn, Rm, lsr) EMIT(ADDSUB_REG_gen(rex.w, 0, 0, 0b01, Rm, lsr, Rn, Rd))
@@ -151,6 +153,7 @@
#define ADDSw_U12(Rd, Rn, imm12) EMIT(ADDSUB_IMM_gen(0, 0, 1, 0b00, (imm12)&0xfff, Rn, Rd))
#define ADDxw_U12(Rd, Rn, imm12) EMIT(ADDSUB_IMM_gen(rex.w, 0, 0, 0b00, (imm12)&0xfff, Rn, Rd))
#define ADDSxw_U12(Rd, Rn, imm12) EMIT(ADDSUB_IMM_gen(rex.w, 0, 1, 0b00, (imm12)&0xfff, Rn, Rd))
+#define ADDz_U12(Rd, Rn, imm12) EMIT(ADDSUB_IMM_gen(rex.is32bits?0:1, 0, 0, 0b00, (imm12)&0xfff, Rn, Rd))
#define SUBx_REG(Rd, Rn, Rm) EMIT(ADDSUB_REG_gen(1, 1, 0, 0b00, Rm, 0, Rn, Rd))
#define SUBSx_REG(Rd, Rn, Rm) EMIT(ADDSUB_REG_gen(1, 1, 1, 0b00, Rm, 0, Rn, Rd))
@@ -160,6 +163,7 @@
#define SUBSw_REG(Rd, Rn, Rm) EMIT(ADDSUB_REG_gen(0, 1, 1, 0b00, Rm, 0, Rn, Rd))
#define SUBSw_REG_LSL(Rd, Rn, Rm, lsl) EMIT(ADDSUB_REG_gen(0, 1, 1, 0b00, Rm, lsl, Rn, Rd))
#define SUBxw_REG(Rd, Rn, Rm) EMIT(ADDSUB_REG_gen(rex.w, 1, 0, 0b00, Rm, 0, Rn, Rd))
+#define SUBz_REG(Rd, Rn, Rm) EMIT(ADDSUB_REG_gen(rex.is32bits?0:1, 1, 0, 0b00, Rm, 0, Rn, Rd))
#define SUBSxw_REG(Rd, Rn, Rm) EMIT(ADDSUB_REG_gen(rex.w, 1, 1, 0b00, Rm, 0, Rn, Rd))
#define CMPSx_REG(Rn, Rm) SUBSx_REG(xZR, Rn, Rm)
#define CMPSw_REG(Rn, Rm) SUBSw_REG(wZR, Rn, Rm)
@@ -176,6 +180,7 @@
#define SUBw_U12(Rd, Rn, imm12) EMIT(ADDSUB_IMM_gen(0, 1, 0, 0b00, (imm12)&0xfff, Rn, Rd))
#define SUBSw_U12(Rd, Rn, imm12) EMIT(ADDSUB_IMM_gen(0, 1, 1, 0b00, (imm12)&0xfff, Rn, Rd))
#define SUBxw_U12(Rd, Rn, imm12) EMIT(ADDSUB_IMM_gen(rex.w, 1, 0, 0b00, (imm12)&0xfff, Rn, Rd))
+#define SUBz_U12(Rd, Rn, imm12) EMIT(ADDSUB_IMM_gen(rex.is32bits?0:1, 1, 0, 0b00, (imm12)&0xfff, Rn, Rd))
#define SUBSxw_U12(Rd, Rn, imm12) EMIT(ADDSUB_IMM_gen(rex.w, 1, 1, 0b00, (imm12)&0xfff, Rn, Rd))
#define CMPSx_U12(Rn, imm12) SUBSx_U12(xZR, Rn, imm12)
#define CMPSw_U12(Rn, imm12) SUBSw_U12(wZR, Rn, imm12)
@@ -221,6 +226,7 @@
#define LDRB_U12(Rt, Rn, imm12) EMIT(LD_gen(0b00, 0b01, ((uint32_t)((imm12)))&0xfff, Rn, Rt))
#define LDRH_U12(Rt, Rn, imm12) EMIT(LD_gen(0b01, 0b01, ((uint32_t)((imm12)>>1))&0xfff, Rn, Rt))
#define LDRxw_U12(Rt, Rn, imm12) EMIT(LD_gen((rex.w)?0b11:0b10, 0b01, ((uint32_t)((imm12)>>(2+rex.w)))&0xfff, Rn, Rt))
+#define LDRz_U12(Rt, Rn, imm12) EMIT(LD_gen((rex.is32bits)?0b10:0b11, 0b01, ((uint32_t)((imm12)>>(rex.is32bits?2:3)))&0xfff, Rn, Rt))
#define LDS_gen(size, op1, imm12, Rn, Rt) ((size)<<30 | 0b111<<27 | (op1)<<24 | 0b10<<22 | (imm12)<<10 | (Rn)<<5 | (Rt))
#define LDRSW_U12(Rt, Rn, imm12) EMIT(LDS_gen(0b10, 0b01, ((uint32_t)((imm12)>>2))&0xfff, Rn, Rt))
@@ -232,6 +238,7 @@
#define LDRw_REG(Rt, Rn, Rm) EMIT(LDR_REG_gen(0b10, Rm, 0b011, 0, Rn, Rt))
#define LDRw_REG_LSL2(Rt, Rn, Rm) EMIT(LDR_REG_gen(0b10, Rm, 0b011, 1, Rn, Rt))
#define LDRxw_REG(Rt, Rn, Rm) EMIT(LDR_REG_gen(0b10+rex.w, Rm, 0b011, 0, Rn, Rt))
+#define LDRz_REG(Rt, Rn, Rm) EMIT(LDR_REG_gen(rex.is32bits?0b10:0b11, Rm, 0b011, 0, Rn, Rt))
#define LDRB_REG(Rt, Rn, Rm) EMIT(LDR_REG_gen(0b00, Rm, 0b011, 0, Rn, Rt))
#define LDRH_REG(Rt, Rn, Rm) EMIT(LDR_REG_gen(0b01, Rm, 0b011, 0, Rn, Rt))
@@ -249,6 +256,41 @@
#define LDR_PC_gen(opc, imm19, Rt) ((opc)<<30 | 0b011<<27 | (imm19)<<5 | (Rt))
#define LDRx_literal(Rt, imm19) EMIT(LDR_PC_gen(0b01, ((imm19)>>2)&0x7FFFF, Rt))
+#define LDU_gen(size, opc, imm9, Rn, Rt) ((size)<<30 | 0b111<<27 | (opc)<<22 | ((imm9)&0x1ff)<<12 | (Rn)<<5 | (Rt))
+#define LDURx_I9(Rt, Rn, imm9) EMIT(LDU_gen(0b11, 0b01, imm9, Rn, Rt))
+#define LDURw_I9(Rt, Rn, imm9) EMIT(LDU_gen(0b10, 0b01, imm9, Rn, Rt))
+#define LDURxw_I9(Rt, Rn, imm9) EMIT(LDU_gen((rex.w)?0b11:0b10, 0b01, imm9, Rn, Rt))
+#define LDURz_I9(Rt, Rn, imm9) EMIT(LDU_gen((rex.is32bits)?0b10:0b11, 0b01, imm9, Rn, Rt))
+#define LDURH_I9(Rt, Rn, imm9) EMIT(LDU_gen(0b01, 0b01, imm9, Rn, Rt))
+#define LDURB_I9(Rt, Rn, imm9) EMIT(LDU_gen(0b00, 0b01, imm9, Rn, Rt))
+#define LDURSW_I9(Rt, Rn, imm9) EMIT(LDU_gen(0b10, 0b10, imm9, Rn, Rt))
+#define LDURSHw_I9(Rt, Rn, imm9) EMIT(LDU_gen(0b01, 0b11, imm9, Rn, Rt))
+#define LDURSHx_I9(Rt, Rn, imm9) EMIT(LDU_gen(0b01, 0b10, imm9, Rn, Rt))
+#define LDURSHxw_I9(Rt, Rn, imm9) EMIT(LDU_gen(0b01, (rex.w)?0b10:0b11, imm9, Rn, Rt))
+#define LDURSBw_I9(Rt, Rn, imm9) EMIT(LDU_gen(0b00, 0b11, imm9, Rn, Rt))
+#define LDURSBx_I9(Rt, Rn, imm9) EMIT(LDU_gen(0b00, 0b10, imm9, Rn, Rt))
+#define LDURSBxw_I9(Rt, Rn, imm9) EMIT(LDU_gen(0b00, (rex.w)?0b10:0b11, imm9, Rn, Rt))
+
+#define LDxw(A, B, C) if(unscaled) {LDURxw_I9(A, B, C);} else {LDRxw_U12(A, B, C);}
+#define LDz(A, B, C) if(unscaled) {LDURz_I9(A, B, C);} else {LDRz_U12(A, B, C);}
+#define LDx(A, B, C) if(unscaled) {LDURx_I9(A, B, C);} else {LDRx_U12(A, B, C);}
+#define LDW(A, B, C) if(unscaled) {LDURw_I9(A, B, C);} else {LDRw_U12(A, B, C);}
+#define LDH(A, B, C) if(unscaled) {LDURH_I9(A, B, C);} else {LDRH_U12(A, B, C);}
+#define LDB(A, B, C) if(unscaled) {LDURB_I9(A, B, C);} else {LDRB_U12(A, B, C);}
+#define LDSW(A, B, C) if(unscaled) {LDURSW_I9(A, B, C);} else {LDRSW_U12(A, B, C);}
+#define LDSHxw(A, B, C) if(unscaled) {LDURSHxw_I9(A, B, C);} else {LDRSHxw_U12(A, B, C);}
+#define LDSHx(A, B, C) if(unscaled) {LDURSHx_I9(A, B, C);} else {LDRSHx_U12(A, B, C);}
+#define LDSHw(A, B, C) if(unscaled) {LDURSHw_I9(A, B, C);} else {LDRSHw_U12(A, B, C);}
+#define LDSBxw(A, B, C) if(unscaled) {LDURSBxw_I9(A, B, C);} else {LDRSBxw_U12(A, B, C);}
+#define LDSBx(A, B, C) if(unscaled) {LDURSBx_I9(A, B, C);} else {LDRSBx_U12(A, B, C);}
+#define LDSBw(A, B, C) if(unscaled) {LDURSBw_I9(A, B, C);} else {LDRSBw_U12(A, B, C);}
+#define STxw(A, B, C) if(unscaled) {STURxw_I9(A, B, C);} else {STRxw_U12(A, B, C);}
+#define STz(A, B, C) if(unscaled) {STURz_I9(A, B, C);} else {STRz_U12(A, B, C);}
+#define STx(A, B, C) if(unscaled) {STURx_I9(A, B, C);} else {STRx_U12(A, B, C);}
+#define STW(A, B, C) if(unscaled) {STURw_I9(A, B, C);} else {STRw_U12(A, B, C);}
+#define STH(A, B, C) if(unscaled) {STURH_I9(A, B, C);} else {STRH_U12(A, B, C);}
+#define STB(A, B, C) if(unscaled) {STURB_I9(A, B, C);} else {STRB_U12(A, B, C);}
+
// STR
#define STR_gen(size, op1, imm9, op2, Rn, Rt) ((size)<<30 | 0b111<<27 | (op1)<<24 | 0b00<<22 | (imm9)<<12 | (op2)<<10 | (Rn)<<5 | (Rt))
#define STRx_S9_postindex(Rt, Rn, imm9) EMIT(STR_gen(0b11, 0b00, (imm9)&0x1ff, 0b01, Rn, Rt))
@@ -257,6 +299,7 @@
#define STRw_S9_preindex(Rt, Rn, imm9) EMIT(STR_gen(0b10, 0b00, (imm9)&0x1ff, 0b11, Rn, Rt))
#define STRxw_S9_postindex(Rt, Rn, imm9) EMIT(STR_gen(rex.w?0b11:0b10, 0b00, (imm9)&0x1ff, 0b01, Rn, Rt))
#define STRB_S9_postindex(Rt, Rn, imm9) EMIT(STR_gen(0b00, 0b00, (imm9)&0x1ff, 0b01, Rn, Rt))
+#define STRH_S9_preindex(Rt, Rn, imm9) EMIT(STR_gen(0b01, 0b00, (imm9)&0x1ff, 0b11, Rn, Rt))
#define STRH_S9_postindex(Rt, Rn, imm9) EMIT(STR_gen(0b01, 0b00, (imm9)&0x1ff, 0b01, Rn, Rt))
#define ST_gen(size, op1, imm12, Rn, Rt) ((size)<<30 | 0b111<<27 | (op1)<<24 | 0b00<<22 | (imm12)<<10 | (Rn)<<5 | (Rt))
@@ -265,11 +308,13 @@
#define STRB_U12(Rt, Rn, imm12) EMIT(ST_gen(0b00, 0b01, ((uint32_t)((imm12)))&0xfff, Rn, Rt))
#define STRH_U12(Rt, Rn, imm12) EMIT(ST_gen(0b01, 0b01, ((uint32_t)((imm12)>>1))&0xfff, Rn, Rt))
#define STRxw_U12(Rt, Rn, imm12) EMIT(ST_gen((rex.w)?0b11:0b10, 0b01, ((uint32_t)((imm12)>>(2+rex.w)))&0xfff, Rn, Rt))
+#define STRz_U12(Rt, Rn, imm12) EMIT(ST_gen((rex.is32bits)?0b10:0b11, 0b01, ((uint32_t)((imm12)>>(rex.is32bits?2:3)))&0xfff, Rn, Rt))
#define STU_gen(size, opc, imm9, Rn, Rt) ((size)<<30 | 0b111<<27 | (opc)<<22 | ((imm9)&0x1ff)<<12 | (Rn)<<5 | (Rt))
#define STURx_I9(Rt, Rn, imm9) EMIT(STU_gen(0b11, 0b00, imm9, Rn, Rt))
#define STURw_I9(Rt, Rn, imm9) EMIT(STU_gen(0b10, 0b00, imm9, Rn, Rt))
#define STURxw_I9(Rt, Rn, imm9) EMIT(STU_gen((rex.w)?0b11:0b10, 0b00, imm9, Rn, Rt))
+#define STURz_I9(Rt, Rn, imm9) EMIT(STU_gen((rex.is32bits)?0b10:0b11, 0b00, imm9, Rn, Rt))
#define STURH_I9(Rt, Rn, imm9) EMIT(STU_gen(0b01, 0b00, imm9, Rn, Rt))
#define STURB_I9(Rt, Rn, imm9) EMIT(STU_gen(0b00, 0b00, imm9, Rn, Rt))
@@ -282,6 +327,7 @@
#define STRB_REG(Rt, Rn, Rm) EMIT(STR_REG_gen(0b00, Rm, 0b011, 0, Rn, Rt))
#define STRH_REG(Rt, Rn, Rm) EMIT(STR_REG_gen(0b01, Rm, 0b011, 0, Rn, Rt))
#define STRxw_REG(Rt, Rn, Rm) EMIT(STR_REG_gen(rex.w?0b11:0b10, Rm, 0b011, 0, Rn, Rt))
+#define STRz_REG(Rt, Rn, Rm) EMIT(STR_REG_gen(rex.is32bits?0b10:0b11, Rm, 0b011, 0, Rn, Rt))
// LOAD/STORE PAIR
#define MEMPAIR_gen(size, L, op2, imm7, Rt2, Rn, Rt) ((size)<<31 | 0b101<<27 | (op2)<<23 | (L)<<22 | (imm7)<<15 | (Rt2)<<10 | (Rn)<<5 | (Rt))
@@ -309,6 +355,21 @@
// PUSH / POP helper
#define POP1(reg) LDRx_S9_postindex(reg, xRSP, 8)
#define PUSH1(reg) STRx_S9_preindex(reg, xRSP, -8)
+#define POP2(reg1, reg2) LDPx_S7_postindex(reg1, reg2, xRSP, 16)
+#define PUSH2(reg1, reg2) STPx_S7_preindex(reg2, reg1, xRSP, -16)
+
+#define POP1_32(reg) LDRw_S9_postindex(reg, xRSP, 4)
+#define PUSH1_32(reg) STRw_S9_preindex(reg, xRSP, -4)
+#define POP2_32(reg1, reg2) LDPw_S7_postindex(reg1, reg2, xRSP, 8)
+#define PUSH2_32(reg1, reg2) STPw_S7_preindex(reg2, reg1, xRSP, -8)
+
+#define POP1_16(reg) LDRH_S9_postindex(reg, xRSP, 2)
+#define PUSH1_16(reg) STRH_S9_preindex(reg, xRSP, -2)
+
+#define POP1z(reg) if(rex.is32bits) {POP1_32(reg);} else {POP1(reg);}
+#define PUSH1z(reg) if(rex.is32bits) {PUSH1_32(reg);} else {PUSH1(reg);}
+#define POP2z(reg1, reg2) if(rex.is32bits) {POP2_32(reg1, reg2);} else {POP2(reg1, reg2);}
+#define PUSH2z(reg1, reg2) if(rex.is32bits) {PUSH2_32(reg1, reg2);} else {PUSH2(reg1, reg2);}
// LOAD/STORE Acquire Exclusive
#define MEMAX_gen(size, L, Rs, Rn, Rt) ((size)<<30 | 0b001000<<24 | (L)<<22 | (Rs)<<16 | 1<<15 | 0b11111<<10 | (Rn)<<5 | (Rt))
@@ -380,9 +441,11 @@
#define CBNZx(Rt, imm19) EMIT(CB_gen(1, 1, ((imm19)>>2)&0x7FFFF, Rt))
#define CBNZw(Rt, imm19) EMIT(CB_gen(0, 1, ((imm19)>>2)&0x7FFFF, Rt))
#define CBNZxw(Rt, imm19) EMIT(CB_gen(rex.w, 1, ((imm19)>>2)&0x7FFFF, Rt))
+#define CBNZz(Rt, imm19) EMIT(CB_gen(rex.is32bits?0:1, 1, ((imm19)>>2)&0x7FFFF, Rt))
#define CBZx(Rt, imm19) EMIT(CB_gen(1, 0, ((imm19)>>2)&0x7FFFF, Rt))
#define CBZw(Rt, imm19) EMIT(CB_gen(0, 0, ((imm19)>>2)&0x7FFFF, Rt))
#define CBZxw(Rt, imm19) EMIT(CB_gen(rex.w, 0, ((imm19)>>2)&0x7FFFF, Rt))
+#define CBZz(Rt, imm19) EMIT(CB_gen(rex.is32bits?0:1, 0, ((imm19)>>2)&0x7FFFF, Rt))
#define TB_gen(b5, op, b40, imm14, Rt) ((b5)<<31 | 0b011011<<25 | (op)<<24 | (b40)<<19 | (imm14)<<5 | (Rt))
#define TBZ(Rt, bit, imm16) EMIT(TB_gen(((bit)>>5)&1, 0, (bit)&0x1f, ((imm16)>>2)&0x3FFF, Rt))
@@ -427,9 +490,9 @@
#define CSNEGx(Rd, Rn, Rm, cond) EMIT(CSNEG_gen(1, Rm, cond, Rn, Rd))
#define CSNEGw(Rd, Rn, Rm, cond) EMIT(CSNEG_gen(0, Rm, cond, Rn, Rd))
#define CSNEGxw(Rd, Rn, Rm, cond) EMIT(CSNEG_gen(rex.w, Rm, cond, Rn, Rd))
-#define CNEGx(Rd, Rn, cond) CSNEGx(Rn, Rn, Rn, invCond(cond))
-#define CNEGw(Rd, Rn, cond) CSNEGw(Rn, Rn, Rn, invCond(cond))
-#define CNEGxw(Rd, Rn, cond) CSNEGxw(Rn, Rn, Rn, invCond(cond))
+#define CNEGx(Rd, Rn, cond) CSNEGx(Rn, Rn, Rd, invCond(cond))
+#define CNEGw(Rd, Rn, cond) CSNEGw(Rn, Rn, Rd, invCond(cond))
+#define CNEGxw(Rd, Rn, cond) CSNEGxw(Rn, Rn, Rd, invCond(cond))
// AND / ORR
#define LOGIC_gen(sf, opc, N, immr, imms, Rn, Rd) ((sf)<<31 | (opc)<<29 | 0b100100<<23 | (N)<<22 | (immr)<<16 | (imms)<<10 | (Rn)<<5 | Rd)
@@ -474,9 +537,19 @@
#define EORx_REG_LSR(Rd, Rn, Rm, lsr) EMIT(LOGIC_REG_gen(1, 0b10, 0b01, 0, Rm, lsr, Rn, Rd))
#define EORw_REG_LSR(Rd, Rn, Rm, lsr) EMIT(LOGIC_REG_gen(0, 0b10, 0b01, 0, Rm, lsr, Rn, Rd))
#define EORxw_REG_LSR(Rd, Rn, Rm, lsr) EMIT(LOGIC_REG_gen(rex.w, 0b10, 0b01, 0, Rm, lsr, Rn, Rd))
+#define EONx_REG(Rd, Rn, Rm) EMIT(LOGIC_REG_gen(1, 0b10, 0b00, 1, Rm, 0, Rn, Rd))
+#define EONw_REG(Rd, Rn, Rm) EMIT(LOGIC_REG_gen(0, 0b10, 0b00, 1, Rm, 0, Rn, Rd))
+#define EONxw_REG(Rd, Rn, Rm) EMIT(LOGIC_REG_gen(rex.w, 0b10, 0b00, 1, Rm, 0, Rn, Rd))
+#define EONx_REG_LSL(Rd, Rn, Rm, lsl) EMIT(LOGIC_REG_gen(1, 0b10, 0b00, 1, Rm, lsl, Rn, Rd))
+#define EONw_REG_LSL(Rd, Rn, Rm, lsl) EMIT(LOGIC_REG_gen(0, 0b10, 0b00, 1, Rm, lsl, Rn, Rd))
+#define EONxw_REG_LSL(Rd, Rn, Rm, lsl) EMIT(LOGIC_REG_gen(rex.w, 0b10, 0b00, 1, Rm, lsl, Rn, Rd))
+#define EONx_REG_LSR(Rd, Rn, Rm, lsr) EMIT(LOGIC_REG_gen(1, 0b10, 0b01, 1, Rm, lsr, Rn, Rd))
+#define EONw_REG_LSR(Rd, Rn, Rm, lsr) EMIT(LOGIC_REG_gen(0, 0b10, 0b01, 1, Rm, lsr, Rn, Rd))
+#define EONxw_REG_LSR(Rd, Rn, Rm, lsr) EMIT(LOGIC_REG_gen(rex.w, 0b10, 0b01, 1, Rm, lsr, Rn, Rd))
#define MOVx_REG(Rd, Rm) ORRx_REG(Rd, xZR, Rm)
#define MOVw_REG(Rd, Rm) ORRw_REG(Rd, xZR, Rm)
#define MOVxw_REG(Rd, Rm) ORRxw_REG(Rd, xZR, Rm)
+#define MOVz_REG(Rd, Rm) if(rex.is32bits) {MOVw_REG(Rd, Rm);} else {MOVx_REG(Rd, Rm);}
#define LSLw_IMM(Rd, Rm, lsl) ORRw_REG_LSL(Rd, xZR, Rm, lsl)
#define LSLx_IMM(Rd, Rm, lsl) ORRx_REG_LSL(Rd, xZR, Rm, lsl)
#define LSLxw_IMM(Rd, Rm, lsl) ORRxw_REG_LSL(Rd, xZR, Rm, lsl)
@@ -499,6 +572,12 @@
#define BICx_REG BICx
#define BICw_REG BICw
#define BICxw_REG BICxw
+#define BICx_REG_LSL(Rd, Rn, Rm, lsl) EMIT(LOGIC_REG_gen(1, 0b00, 0b00, 1, Rm, lsl, Rn, Rd))
+#define BICw_REG_LSL(Rd, Rn, Rm, lsl) EMIT(LOGIC_REG_gen(0, 0b00, 0b00, 1, Rm, lsl, Rn, Rd))
+#define BICxw_REG_LSL(Rd, Rn, Rm, lsl) EMIT(LOGIC_REG_gen(rex.w, 0b00, 0b00, 1, Rm, lsl, Rn, Rd))
+#define BICx_REG_LSR(Rd, Rn, Rm, lsl) EMIT(LOGIC_REG_gen(1, 0b00, 0b01, 1, Rm, lsl, Rn, Rd))
+#define BICw_REG_LSR(Rd, Rn, Rm, lsl) EMIT(LOGIC_REG_gen(0, 0b00, 0b01, 1, Rm, lsl, Rn, Rd))
+#define BICxw_REG_LSR(Rd, Rn, Rm, lsl) EMIT(LOGIC_REG_gen(rex.w, 0b00, 0b01, 1, Rm, lsl, Rn, Rd))
#define TSTx_REG(Rn, Rm) ANDSx_REG(xZR, Rn, Rm)
#define TSTw_REG(Rn, Rm) ANDSw_REG(wZR, Rn, Rm)
#define TSTxw_REG(Rn, Rm) ANDSxw_REG(xZR, Rn, Rm)
@@ -726,6 +805,15 @@
#define VSTR64_I9(Vt, Rn, imm9) EMIT(VMEMUR_vector(0b11, 0b00, (imm9)&0b111111111, Rn, Vt))
#define VSTR128_I9(Vt, Rn, imm9) EMIT(VMEMUR_vector(0b00, 0b10, (imm9)&0b111111111, Rn, Vt))
+#define VLD128(A, B, C) if(unscaled) {VLDR128_I9(A, B, C);} else {VLDR128_U12(A, B, C);}
+#define VLD64(A, B, C) if(unscaled) {VLDR64_I9(A, B, C);} else {VLDR64_U12(A, B, C);}
+#define VLD32(A, B, C) if(unscaled) {VLDR32_I9(A, B, C);} else {VLDR32_U12(A, B, C);}
+#define VLD16(A, B, C) if(unscaled) {VLDR16_I9(A, B, C);} else {VLDR16_U12(A, B, C);}
+#define VST128(A, B, C) if(unscaled) {VSTR128_I9(A, B, C);} else {VSTR128_U12(A, B, C);}
+#define VST64(A, B, C) if(unscaled) {VSTR64_I9(A, B, C);} else {VSTR64_U12(A, B, C);}
+#define VST32(A, B, C) if(unscaled) {VSTR32_I9(A, B, C);} else {VSTR32_U12(A, B, C);}
+#define VST16(A, B, C) if(unscaled) {VSTR16_I9(A, B, C);} else {VSTR16_U12(A, B, C);}
+
#define VMEMW_gen(size, opc, imm9, op2, Rn, Rt) ((size)<<30 | 0b111<<27 | 1<<26 | (opc)<<22 | (imm9)<<12 | (op2)<<10 | 0b01<<10 | (Rn)<<5 | (Rt))
#define VLDR64_S9_postindex(Rt, Rn, imm9) EMIT(VMEMW_gen(0b11, 0b01, (imm9)&0x1ff, 0b01, Rn, Rt))
#define VLDR64_S9_preindex(Rt, Rn, imm9) EMIT(VMEMW_gen(0b11, 0b01, (imm9)&0x1ff, 0b11, Rn, Rt))
@@ -880,6 +968,10 @@
#define VSUB_16(Vd, Vn, Vm) EMIT(ADDSUB_vector(0, 1, 0b01, Vm, Vn, Vd))
#define VSUB_32(Vd, Vn, Vm) EMIT(ADDSUB_vector(0, 1, 0b10, Vm, Vn, Vd))
+#define ADDSUB_scalar(U, size, Rm, Rn, Rd) (01<<30 | (U)<<29 | 0b11110<<24 | (size)<<22 | 1<<21 | (Rm)<<16 | 0b10000<<11 | 1<<10 | (Rn)<<5 | (Rd))
+#define ADD_64(Vd, Vn, Vm) EMIT(ADDSUB_scalar(0, 0b11, Vm, Vn, Vd))
+#define SUB_64(Vd, Vn, Vm) EMIT(ADDSUB_scalar(1, 0b11, Vm, Vn, Vd))
+
#define NEGABS_vector(Q, U, size, Rn, Rd) ((Q)<<30 | (U)<<29 | 0b01110<<24 | (size)<<22 | 0b10000<<17 | 0b01011<<12 | 0b10<<10 | (Rn)<<5 | (Rd))
#define NEG_8(Vd, Vn) EMIT(NEGABS_vector(0, 1, 0b00, Vn, Vd))
#define NEG_16(Vd, Vn) EMIT(NEGABS_vector(0, 1, 0b01, Vn, Vd))
@@ -1025,7 +1117,7 @@
#define FMLA_vector(Q, op, sz, Rm, Rn, Rd) ((Q)<<30 | 0b01110<<24 | (op)<<23 | (sz)<<22 | 1<<21 | (Rm)<<16 | 0b11001<<11 | 1<<10 | (Rn)<<5 | (Rd))
#define VFMLAS(Sd, Sn, Sm) EMIT(FMLA_vector(0, 0, 0, Sm, Sn, Sd))
#define VFMLAQS(Sd, Sn, Sm) EMIT(FMLA_vector(1, 0, 0, Sm, Sn, Sd))
-#define CFMLAQD(Dd, Dn, Dm) EMIT(FMLA_vector(1, 0, 1, Dm, Dn, Dd))
+#define VFMLAQD(Dd, Dn, Dm) EMIT(FMLA_vector(1, 0, 1, Dm, Dn, Dd))
// DIV
#define FDIV_vector(Q, sz, Rm, Rn, Rd) ((Q)<<30 | 1<<29 | 0b01110<<24 | (sz)<<22 | 1<<21 | (Rm)<<16 | 0b11111<<11 | 1<<10 | (Rn)<<5 | (Rd))
@@ -1223,6 +1315,12 @@
#define FCVT_D_S(Dd, Sn) EMIT(FCVT_precision(0b00, 0b01, Sn, Dd))
#define FCVT_S_D(Sd, Dn) EMIT(FCVT_precision(0b01, 0b00, Dn, Sd))
+#define FCVTN_vector(Q, sz, Rn, Rd) ((Q)<<30 | 0<<29 | 0b01110<<24 | (sz)<<22 | 0b10000<<17 | 0b10110<<12 | 0b10<<10 | (Rn)<<5 | (Rd))
+// Convert Vn from 2*Double to lower Vd as 2*float and clears the upper half, use FPCR rounding
+#define FCVTN(Vd, Vn) EMIT(FCVTN_vector(0, 1, Vn, Vd))
+// Convert Vn from 2*Double to higher Vd as 2*float, use FPCR rounding
+#define FCVTN2(Vd, Vn) EMIT(FCVTN_vector(1, 1, Vn, Vd))
+
#define FCVTXN_vector(Q, sz, Rn, Rd) ((Q)<<30 | 1<<29 | 0b01110<<24 | (sz)<<22 | 0b10000<<17 | 0b10110<<12 | 0b10<<10 | (Rn)<<5 | (Rd))
// Convert Vn from 2*Double to lower Vd as 2*float and clears the upper half
#define FCVTXN(Vd, Vn) EMIT(FCVTXN_vector(0, 1, Vn, Vd))
@@ -1258,6 +1356,10 @@
#define VFRINTIS(Vd,Vn) EMIT(FRINT_vector(0, 1, 1, 0, 1, Vn, Vd))
#define VFRINTISQ(Vd,Vn) EMIT(FRINT_vector(1, 1, 1, 0, 1, Vn, Vd))
#define VFRINTIDQ(Vd,Vn) EMIT(FRINT_vector(1, 1, 1, 1, 1, Vn, Vd))
+// round with mode, mode is 0 = TieEven, 1=+inf, 2=-inf, 3=zero
+#define VFRINTRDQ(Vd,Vn, mode) EMIT(FRINT_vector(1, 0, (mode)&1, 1, ((mode)>>1)&1, Vn, Vd))
+// round with mode, mode is 0 = TieEven, 1=+inf, 2=-inf, 3=zero
+#define VFRINTRSQ(Vd,Vn, mode) EMIT(FRINT_vector(1, 0, (mode)&1, 0, ((mode)>>1)&1, Vn, Vd))
#define FRINTI_scalar(type, Rn, Rd) (0b11110<<24 | (type)<<22 | 1<<21 | 0b001<<18 | 0b111<<15 | 0b10000<<10 | (Rn)<<5 | (Rd))
#define FRINTIS(Sd, Sn) EMIT(FRINTI_scalar(0b00, Sn, Sd))
@@ -1344,14 +1446,23 @@
#define VUZP1Q_64(Rt, Rn, Rm) EMIT(UZP_gen(1, 0b11, Rm, 0, Rn, Rt))
#define VUZP2Q_64(Rt, Rn, Rm) EMIT(UZP_gen(1, 0b11, Rm, 1, Rn, Rt))
-#define DUP_gen(Q, imm5, Rn, Rd) ((Q)<<30 | 0b01110000<<21 | (imm5)<<16 | 1<<10 | (Rn)<<5 | (Rd))
-#define VDUP_8(Vd, Vn, idx) EMIT(DUP_gen(0, ((idx)<<1|1), Vn, Vd))
-#define VDUPQ_8(Vd, Vn, idx) EMIT(DUP_gen(1, ((idx)<<1|1), Vn, Vd))
-#define VDUP_16(Vd, Vn, idx) EMIT(DUP_gen(0, ((idx)<<2|0b10), Vn, Vd))
-#define VDUPQ_16(Vd, Vn, idx) EMIT(DUP_gen(1, ((idx)<<2|0b10), Vn, Vd))
-#define VDUP_32(Vd, Vn, idx) EMIT(DUP_gen(0, ((idx)<<3|0b100), Vn, Vd))
-#define VDUPQ_32(Vd, Vn, idx) EMIT(DUP_gen(1, ((idx)<<3|0b100), Vn, Vd))
-#define VDUPQ_64(Vd, Vn, idx) EMIT(DUP_gen(1, ((idx)<<4|0b1000), Vn, Vd))
+#define DUP_element(Q, imm5, Rn, Rd) ((Q)<<30 | 0b01110000<<21 | (imm5)<<16 | 1<<10 | (Rn)<<5 | (Rd))
+#define VDUP_8(Vd, Vn, idx) EMIT(DUP_element(0, ((idx)<<1|1), Vn, Vd))
+#define VDUPQ_8(Vd, Vn, idx) EMIT(DUP_element(1, ((idx)<<1|1), Vn, Vd))
+#define VDUP_16(Vd, Vn, idx) EMIT(DUP_element(0, ((idx)<<2|0b10), Vn, Vd))
+#define VDUPQ_16(Vd, Vn, idx) EMIT(DUP_element(1, ((idx)<<2|0b10), Vn, Vd))
+#define VDUP_32(Vd, Vn, idx) EMIT(DUP_element(0, ((idx)<<3|0b100), Vn, Vd))
+#define VDUPQ_32(Vd, Vn, idx) EMIT(DUP_element(1, ((idx)<<3|0b100), Vn, Vd))
+#define VDUPQ_64(Vd, Vn, idx) EMIT(DUP_element(1, ((idx)<<4|0b1000), Vn, Vd))
+
+#define DUP_general(Q, imm5, Rn, Rd) ((Q)<<30 | 0b01110000<<21 | (imm5)<<16 | 0b11<<10 | (Rn)<<5 | (Rd))
+#define VDUPB(Vd, Wn) EMIT(DUP_general(0, 0b1, Wn, Vd))
+#define VDUPQB(Vd, Wn) EMIT(DUP_general(1, 0b1, Wn, Vd))
+#define VDUPH(Vd, Wn) EMIT(DUP_general(0, 0b10, Wn, Vd))
+#define VDUPQH(Vd, Wn) EMIT(DUP_general(1, 0b10, Wn, Vd))
+#define VDUPS(Vd, Wn) EMIT(DUP_general(0, 0b100, Wn, Vd))
+#define VDUPQS(Vd, Wn) EMIT(DUP_general(1, 0b100, Wn, Vd))
+#define VDUPQD(Vd, Xn) EMIT(DUP_general(1, 0b1000, Xn, Vd))
// TBL
#define TBL_gen(Q, Rm, len, op, Rn, Rd) ((Q)<<30 | 0b001110<<24 | (Rm)<<16 | (len)<<13 | (op)<<12 | (Rn)<<5 | (Rd))
@@ -1638,10 +1749,17 @@
#define UADDLV_16(Rd, Rn) EMIT(ADDLV_vector(0, 1, 0b01, Rn, Rd))
#define UADDLV_32(Rd, Rn) EMIT(ADDLV_vector(0, 1, 0b10, Rn, Rd))
+// Population Count per byte
+#define CNT_vector(Q, size, Rn, Rd) ((Q)<<30 | 0b01110<<24 | (size)<<22 | 0b10000<<17 | 0b00101<<12 | 0b10<<10 | (Rn)<<5 | (Rd))
+#define CNT_8(Rd, Rn) EMIT(CNT_vector(0, 0b00, Rn, Rd))
+#define CNTQ_8(Rd, Rn) EMIT(CNT_vector(1, 0b00, Rn, Rd))
+
// MOV Immediate
#define MOVI_vector(Q, op, abc, cmode, defgh, Rd) ((Q)<<30 | (op)<<29 | 0b0111100000<<19 | (abc)<<16 | (cmode)<<12 | 1<<10 | (defgh)<<5 | (Rd))
#define MOVIQ_8(Rd, imm8) EMIT(MOVI_vector(1, 0, (((imm8)>>5)&0b111), 0b1110, ((imm8)&0b11111), Rd))
#define MOVI_8(Rd, imm8) EMIT(MOVI_vector(0, 0, (((imm8)>>5)&0b111), 0b1110, ((imm8)&0b11111), Rd))
+#define MOVI_16(Rd, imm8) EMIT(MOVI_vector(0, 0, (((imm8)>>5)&0b111), 0b1000, ((imm8)&0b11111), Rd))
+#define MOVI_32(Rd, imm8) EMIT(MOVI_vector(0, 0, (((imm8)>>5)&0b111), 0b0000, ((imm8)&0b11111), Rd))
// SHLL and eXtend Long
#define SHLL_vector(Q, U, immh, immb, Rn, Rd) ((Q)<<30 | (U)<<29 | 0b011110<<23 | (immh)<<19 | (immb)<<16 | 0b10100<<11 | 1<<10 | (Rn)<<5 | (Rd))
@@ -1711,35 +1829,35 @@
#define SMAX_8(Vd, Vn, Vm) EMIT(MINMAX_vector(0, 0, 0b00, Vm, 0, Vn, Vd))
#define SMAX_16(Vd, Vn, Vm) EMIT(MINMAX_vector(0, 0, 0b01, Vm, 0, Vn, Vd))
#define SMAX_32(Vd, Vn, Vm) EMIT(MINMAX_vector(0, 0, 0b10, Vm, 0, Vn, Vd))
-#define SMAX_64(Vd, Vn, Vm) EMIT(MINMAX_vector(0, 0, 0b11, Vm, 0, Vn, Vd))
+//#define SMAX_64(Vd, Vn, Vm) EMIT(MINMAX_vector(0, 0, 0b11, Vm, 0, Vn, Vd))
#define UMAX_8(Vd, Vn, Vm) EMIT(MINMAX_vector(0, 1, 0b00, Vm, 0, Vn, Vd))
#define UMAX_16(Vd, Vn, Vm) EMIT(MINMAX_vector(0, 1, 0b01, Vm, 0, Vn, Vd))
#define UMAX_32(Vd, Vn, Vm) EMIT(MINMAX_vector(0, 1, 0b10, Vm, 0, Vn, Vd))
-#define UMAX_64(Vd, Vn, Vm) EMIT(MINMAX_vector(0, 1, 0b11, Vm, 0, Vn, Vd))
+//#define UMAX_64(Vd, Vn, Vm) EMIT(MINMAX_vector(0, 1, 0b11, Vm, 0, Vn, Vd))
#define SMIN_8(Vd, Vn, Vm) EMIT(MINMAX_vector(0, 0, 0b00, Vm, 1, Vn, Vd))
#define SMIN_16(Vd, Vn, Vm) EMIT(MINMAX_vector(0, 0, 0b01, Vm, 1, Vn, Vd))
#define SMIN_32(Vd, Vn, Vm) EMIT(MINMAX_vector(0, 0, 0b10, Vm, 1, Vn, Vd))
-#define SMIN_64(Vd, Vn, Vm) EMIT(MINMAX_vector(0, 0, 0b11, Vm, 1, Vn, Vd))
+//#define SMIN_64(Vd, Vn, Vm) EMIT(MINMAX_vector(0, 0, 0b11, Vm, 1, Vn, Vd))
#define UMIN_8(Vd, Vn, Vm) EMIT(MINMAX_vector(0, 1, 0b00, Vm, 1, Vn, Vd))
#define UMIN_16(Vd, Vn, Vm) EMIT(MINMAX_vector(0, 1, 0b01, Vm, 1, Vn, Vd))
#define UMIN_32(Vd, Vn, Vm) EMIT(MINMAX_vector(0, 1, 0b10, Vm, 1, Vn, Vd))
-#define UMIN_64(Vd, Vn, Vm) EMIT(MINMAX_vector(0, 1, 0b11, Vm, 1, Vn, Vd))
+//#define UMIN_64(Vd, Vn, Vm) EMIT(MINMAX_vector(0, 1, 0b11, Vm, 1, Vn, Vd))
#define SMAXQ_8(Vd, Vn, Vm) EMIT(MINMAX_vector(1, 0, 0b00, Vm, 0, Vn, Vd))
#define SMAXQ_16(Vd, Vn, Vm) EMIT(MINMAX_vector(1, 0, 0b01, Vm, 0, Vn, Vd))
#define SMAXQ_32(Vd, Vn, Vm) EMIT(MINMAX_vector(1, 0, 0b10, Vm, 0, Vn, Vd))
-#define SMAXQ_64(Vd, Vn, Vm) EMIT(MINMAX_vector(1, 0, 0b11, Vm, 0, Vn, Vd))
+//#define SMAXQ_64(Vd, Vn, Vm) EMIT(MINMAX_vector(1, 0, 0b11, Vm, 0, Vn, Vd))
#define UMAXQ_8(Vd, Vn, Vm) EMIT(MINMAX_vector(1, 1, 0b00, Vm, 0, Vn, Vd))
#define UMAXQ_16(Vd, Vn, Vm) EMIT(MINMAX_vector(1, 1, 0b01, Vm, 0, Vn, Vd))
#define UMAXQ_32(Vd, Vn, Vm) EMIT(MINMAX_vector(1, 1, 0b10, Vm, 0, Vn, Vd))
-#define UMAXQ_64(Vd, Vn, Vm) EMIT(MINMAX_vector(1, 1, 0b11, Vm, 0, Vn, Vd))
+//#define UMAXQ_64(Vd, Vn, Vm) EMIT(MINMAX_vector(1, 1, 0b11, Vm, 0, Vn, Vd))
#define SMINQ_8(Vd, Vn, Vm) EMIT(MINMAX_vector(1, 0, 0b00, Vm, 1, Vn, Vd))
#define SMINQ_16(Vd, Vn, Vm) EMIT(MINMAX_vector(1, 0, 0b01, Vm, 1, Vn, Vd))
#define SMINQ_32(Vd, Vn, Vm) EMIT(MINMAX_vector(1, 0, 0b10, Vm, 1, Vn, Vd))
-#define SMINQ_64(Vd, Vn, Vm) EMIT(MINMAX_vector(1, 0, 0b11, Vm, 1, Vn, Vd))
+//#define SMINQ_64(Vd, Vn, Vm) EMIT(MINMAX_vector(1, 0, 0b11, Vm, 1, Vn, Vd))
#define UMINQ_8(Vd, Vn, Vm) EMIT(MINMAX_vector(1, 1, 0b00, Vm, 1, Vn, Vd))
#define UMINQ_16(Vd, Vn, Vm) EMIT(MINMAX_vector(1, 1, 0b01, Vm, 1, Vn, Vd))
#define UMINQ_32(Vd, Vn, Vm) EMIT(MINMAX_vector(1, 1, 0b10, Vm, 1, Vn, Vd))
-#define UMINQ_64(Vd, Vn, Vm) EMIT(MINMAX_vector(1, 1, 0b11, Vm, 1, Vn, Vd))
+//#define UMINQ_64(Vd, Vn, Vm) EMIT(MINMAX_vector(1, 1, 0b11, Vm, 1, Vn, Vd))
// HADD vector
#define HADD_vector(Q, U, size, Rm, Rn, Rd) ((Q)<<30 | (U)<<29 | 0b01110<<24 | (size)<<22 | 1<<21 | (Rm)<<16 | 1<<10 | (Rn)<<5 | (Rd))
diff --git a/src/dynarec/arm64/arm64_epilog.S b/src/dynarec/arm64/arm64_epilog.S
index 2e18626..2e18626 100755..100644
--- a/src/dynarec/arm64/arm64_epilog.S
+++ b/src/dynarec/arm64/arm64_epilog.S
diff --git a/src/dynarec/arm64/arm64_lock.S b/src/dynarec/arm64/arm64_lock.S
index 8c3c871..b091101 100755..100644
--- a/src/dynarec/arm64/arm64_lock.S
+++ b/src/dynarec/arm64/arm64_lock.S
@@ -15,8 +15,10 @@
.global arm64_lock_write_dd
.global arm64_lock_read_dq
.global arm64_lock_write_dq
-.global arm64_lock_xchg
+.global arm64_lock_xchg_dd
.global arm64_lock_xchg_d
+.global arm64_lock_xchg_h
+.global arm64_lock_xchg_b
.global arm64_lock_storeifnull
.global arm64_lock_storeifnull_d
.global arm64_lock_storeifref
@@ -97,13 +99,13 @@ arm64_lock_write_dq:
ret
-arm64_lock_xchg:
+arm64_lock_xchg_dd:
dmb ish
-arm64_lock_xchg_0:
+arm64_lock_xchg_dd_0:
// address is x0, value is x1, return old value in x0
ldaxr x2, [x0]
stlxr w3, x1, [x0]
- cbnz w3, arm64_lock_xchg_0
+ cbnz w3, arm64_lock_xchg_dd_0
mov x0, x2
ret
@@ -117,6 +119,26 @@ arm64_lock_xchg_d_0:
mov w0, w2
ret
+arm64_lock_xchg_h:
+ dmb ish
+arm64_lock_xchg_h_0:
+ // address is x0, value is x1, return old value in x0
+ ldaxrh w2, [x0]
+ stlxrh w3, w1, [x0]
+ cbnz w3, arm64_lock_xchg_h_0
+ mov w0, w2
+ ret
+
+arm64_lock_xchg_b:
+ dmb ish
+arm64_lock_xchg_b_0:
+ // address is x0, value is x1, return old value in x0
+ ldaxrb w2, [x0]
+ stlxrb w3, w1, [x0]
+ cbnz w3, arm64_lock_xchg_b_0
+ mov w0, w2
+ ret
+
arm64_lock_storeifnull:
dmb ish
1:
diff --git a/src/dynarec/arm64/arm64_lock.h b/src/dynarec/arm64/arm64_lock.h
index 7e303da..118c807 100755..100644
--- a/src/dynarec/arm64/arm64_lock.h
+++ b/src/dynarec/arm64/arm64_lock.h
@@ -27,40 +27,46 @@ extern void arm64_lock_read_dq(uint64_t * a, uint64_t* b, void* addr);
// STLXRD of ADDR, return 0 if ok, 1 if not
extern int arm64_lock_write_dq(uint64_t a, uint64_t b, void* addr);
-// Atomicaly exchange value at [p] with val, return old p
-extern uintptr_t arm64_lock_xchg(void* p, uintptr_t val);
+// Atomically exchange value at [p] with val, return old p
+extern uintptr_t arm64_lock_xchg_dd(void* p, uintptr_t val);
-// Atomicaly exchange value at [p] with val, return old p
+// Atomically exchange value at [p] with val, return old p
extern uint32_t arm64_lock_xchg_d(void* p, uint32_t val);
-// Atomicaly store value to [p] only if [p] is NULL. Return old [p] value
+// Atomically exchange value at [p] with val, return old p
+extern uint32_t arm64_lock_xchg_h(void* p, uint32_t val);
+
+// Atomically exchange value at [p] with val, return old p
+extern uint32_t arm64_lock_xchg_b(void* p, uint32_t val);
+
+// Atomically store value to [p] only if [p] is NULL. Return old [p] value
extern uint32_t arm64_lock_storeifnull_d(void*p, uint32_t val);
-// Atomicaly store value to [p] only if [p] is NULL. Return old [p] value
+// Atomically store value to [p] only if [p] is NULL. Return old [p] value
extern void* arm64_lock_storeifnull(void*p, void* val);
-// Atomicaly store value to [p] only if [p] is ref. Return new [p] value (so val or old)
+// Atomically store value to [p] only if [p] is ref. Return new [p] value (so val or old)
extern void* arm64_lock_storeifref(void*p, void* val, void* ref);
-// Atomicaly store value to [p] only if [p] is ref. Return new [p] value (so val or old)
+// Atomically store value to [p] only if [p] is ref. Return new [p] value (so val or old)
extern uint32_t arm64_lock_storeifref_d(void*p, uint32_t val, uint32_t ref);
-// Atomicaly store value to [p] only if [p] is ref. Return new [p] value (so val or old)
+// Atomically store value to [p] only if [p] is ref. Return new [p] value (so val or old)
extern uint32_t arm64_lock_storeifref2_d(void*p, uint32_t val, uint32_t ref);
-// decrement atomicaly the byte at [p] (but only if p not 0)
+// decrement atomically the byte at [p] (but only if p not 0)
extern void arm64_lock_decifnot0b(void*p);
// atomic store (with memory barrier)
extern void arm64_lock_storeb(void*p, uint8_t b);
-// increment atomicaly the int at [p] only if it was 0. Return the old value of [p]
+// increment atomically the int at [p] only if it was 0. Return the old value of [p]
extern int arm64_lock_incif0(void*p);
-// decrement atomicaly the int at [p] (but only if p not 0)
+// decrement atomically the int at [p] (but only if p not 0)
extern int arm64_lock_decifnot0(void*p);
// atomic store (with memory barrier)
extern void arm64_lock_store(void*p, uint32_t v);
-#endif //__ARM64_LOCK__H__ \ No newline at end of file
+#endif //__ARM64_LOCK__H__
diff --git a/src/dynarec/arm64/arm64_next.S b/src/dynarec/arm64/arm64_next.S
index e900fbe..e900fbe 100755..100644
--- a/src/dynarec/arm64/arm64_next.S
+++ b/src/dynarec/arm64/arm64_next.S
diff --git a/src/dynarec/arm64/arm64_printer.c b/src/dynarec/arm64/arm64_printer.c
index e935677..2806497 100755..100644
--- a/src/dynarec/arm64/arm64_printer.c
+++ b/src/dynarec/arm64/arm64_printer.c
@@ -160,13 +160,60 @@ const char* arm64_print(uint32_t opcode, uintptr_t addr)
if(isMask(opcode, "1x111000010iiiiiiiii01nnnnnttttt", &a)) {
int size = (opcode>>30)&3;
int offset = signExtend(imm, 9);
- snprintf(buff, sizeof(buff), "LDR %s, [%s], %s0x%x", (size==0b10)?Wt[Rt]:Xt[Rt], XtSp[Rn], (offset<0)?"-":"", abs(offset));
+ snprintf(buff, sizeof(buff), "LDUR %s, [%s], %s0x%x", (size==0b10)?Wt[Rt]:Xt[Rt], XtSp[Rn], (offset<0)?"-":"", abs(offset));
return buff;
}
if(isMask(opcode, "1x111000010iiiiiiiii11nnnnnttttt", &a)) {
int size = (opcode>>30)&3;
int offset = signExtend(imm, 9);
- snprintf(buff, sizeof(buff), "LDR %s, [%s, %s0x%x]!", (size==0b10)?Wt[Rt]:Xt[Rt], XtSp[Rn], (offset<0)?"-":"", abs(offset));
+ snprintf(buff, sizeof(buff), "LDUR %s, [%s, %s0x%x]!", (size==0b10)?Wt[Rt]:Xt[Rt], XtSp[Rn], (offset<0)?"-":"", abs(offset));
+ return buff;
+ }
+ if(isMask(opcode, "1x111000010iiiiiiiii00nnnnnttttt", &a)) {
+ int size = (opcode>>30)&3;
+ int offset = signExtend(imm, 9);
+ snprintf(buff, sizeof(buff), "LDUR %s, [%s, %s0x%x]", (size==0b10)?Wt[Rt]:Xt[Rt], XtSp[Rn], (offset<0)?"-":"", abs(offset));
+ return buff;
+ }
+ if(isMask(opcode, "00111000010iiiiiiiii00nnnnnttttt", &a)) {
+ int offset = signExtend(imm, 9);
+ snprintf(buff, sizeof(buff), "LDURB %s, [%s, %s0x%x]", Wt[Rt], XtSp[Rn], (offset<0)?"-":"", abs(offset));
+ return buff;
+ }
+ if(isMask(opcode, "01111000010iiiiiiiii00nnnnnttttt", &a)) {
+ int offset = signExtend(imm, 9);
+ snprintf(buff, sizeof(buff), "LDRUH %s, [%s, %s0x%x]", Wt[Rt], XtSp[Rn], (offset<0)?"-":"", abs(offset));
+ return buff;
+ }
+ if(isMask(opcode, "001110001x0iiiiiiiii00nnnnnttttt", &a)) {
+ int offset = signExtend(imm, 9);
+ snprintf(buff, sizeof(buff), "LDRUSB %s, [%s, %s0x%x]", a.x?Xt[Rt]:Wt[Rt], XtSp[Rn], (offset<0)?"-":"", abs(offset));
+ return buff;
+ }
+ if(isMask(opcode, "011110001x0iiiiiiiii00nnnnnttttt", &a)) {
+ int offset = signExtend(imm, 9);
+ snprintf(buff, sizeof(buff), "LDRUSH %s, [%s, %s0x%x]", a.x?Xt[Rt]:Wt[Rt], XtSp[Rn], (offset<0)?"-":"", abs(offset));
+ return buff;
+ }
+ if(isMask(opcode, "10111000100iiiiiiiii00nnnnnttttt", &a)) {
+ int offset = signExtend(imm, 9);
+ snprintf(buff, sizeof(buff), "LDRUSW %s, [%s, %s0x%x]", Xt[Rt], XtSp[Rn], (offset<0)?"-":"", abs(offset));
+ return buff;
+ }
+ if(isMask(opcode, "1x111000000iiiiiiiii00nnnnnttttt", &a)) {
+ int size = (opcode>>30)&3;
+ int offset = signExtend(imm, 9);
+ snprintf(buff, sizeof(buff), "STUR %s, [%s, %s0x%x]", (size==0b10)?Wt[Rt]:Xt[Rt], XtSp[Rn], (offset<0)?"-":"", abs(offset));
+ return buff;
+ }
+ if(isMask(opcode, "00111000000iiiiiiiii00nnnnnttttt", &a)) {
+ int offset = signExtend(imm, 9);
+ snprintf(buff, sizeof(buff), "STURB %s, [%s, %s0x%x]", Wt[Rt], XtSp[Rn], (offset<0)?"-":"", abs(offset));
+ return buff;
+ }
+ if(isMask(opcode, "01111000000iiiiiiiii00nnnnnttttt", &a)) {
+ int offset = signExtend(imm, 9);
+ snprintf(buff, sizeof(buff), "STRUH %s, [%s, %s0x%x]", Wt[Rt], XtSp[Rn], (offset<0)?"-":"", abs(offset));
return buff;
}
if(isMask(opcode, "1x11100101iiiiiiiiiiiinnnnnttttt", &a)) {
@@ -903,6 +950,28 @@ const char* arm64_print(uint32_t opcode, uintptr_t addr)
snprintf(buff, sizeof(buff), "VCMEQ V%d.%s, V%d.%s, V%d.%s", Rd, Vd, Rn, Vd, Rm, Vd);
return buff;
}
+ // MIN/MAX
+ if(isMask(opcode, "0QU01110ff1mmmmm0110o1nnnnnddddd", &a)) {
+ const char* Y[] = {"8B", "16B", "4H", "8H", "2S", "4S", "??", "2D"};
+ const char* Vd = Y[((sf)<<1) | a.Q];
+ snprintf(buff, sizeof(buff), "%c%s V%d.%s, V%d.%s, V%d.%s", a.U?'U':'S', a.o?"MIN":"MAX", Rd, Vd, Rn, Vd, Rm, Vd);
+ return buff;
+ }
+
+ // MOV immediate (not)shifted 8bits
+ if(isMask(opcode, "0Q00111100000iii111001iiiiiddddd", &a)) {
+ const char* Y[] = {"8B", "16B"};
+ const char* Vd = Y[a.Q];
+ snprintf(buff, sizeof(buff), "MOVI V%d.%s, #0x%x", Rd, Vd, imm);
+ return buff;
+ }
+ // MOV immediate (not)shifted 16bits & 32bits
+ if(isMask(opcode, "0Q00111100000iiif00001iiiiiddddd", &a)) {
+ const char* Y[] = {"2S", "4S", "4H", "8H"};
+ const char* Vd = Y[(sf<<1)| a.Q];
+ snprintf(buff, sizeof(buff), "MOVI V%d.%s, #0x%x", Rd, Vd, imm);
+ return buff;
+ }
// Shift
if(isMask(opcode, "0QU011110hhhhrrr000001nnnnnddddd", &a)) {
@@ -1038,6 +1107,84 @@ const char* arm64_print(uint32_t opcode, uintptr_t addr)
snprintf(buff, sizeof(buff), "FSQRT %c%d, %c%d", s, Rd, s, Rn);
return buff;
}
+ // FPRINTX
+ if(isMask(opcode, "0Q1011100f100001100110nnnnnddddd", &a)) {
+ char s = a.Q?'V':'D';
+ char d = sf?'D':'S';
+ int n = (a.Q && !sf)?4:2;
+ snprintf(buff, sizeof(buff), "VFRINTX %c%d.%d%c, %c%d.%d%c", s, Rd, n, d, s, Rn, n, d);
+ return buff;
+ }
+ if (isMask(opcode, "00011110ff100111010000nnnnnddddd", &a)) {
+ char s = (sf==0)?'S':((sf==1)?'D':'?');
+ snprintf(buff, sizeof(buff), "FRINTX %c%d, %c%d", s, Rd, s, Rn);
+ return buff;
+ }
+ // FRINTI
+ if(isMask(opcode, "0Q1011101f100001100110nnnnnddddd", &a)) {
+ char s = a.Q?'V':'D';
+ char d = sf?'D':'S';
+ int n = (a.Q && !sf)?4:2;
+ snprintf(buff, sizeof(buff), "VFRINTI %c%d.%d%c, %c%d.%d%c", s, Rd, n, d, s, Rn, n, d);
+ return buff;
+ }
+ if(isMask(opcode, "00011110ff100111110000nnnnnddddd", &a)) {
+ char s = (sf==0)?'S':((sf==1)?'D':'?');
+ snprintf(buff, sizeof(buff), "FRINTI %c%d, %c%d", s, Rd, s, Rn);
+ return buff;
+ }
+ // FRINTN
+ if(isMask(opcode, "0Q0011100f100001100010nnnnnddddd", &a)) {
+ char s = a.Q?'V':'D';
+ char d = sf?'D':'S';
+ int n = (a.Q && !sf)?4:2;
+ snprintf(buff, sizeof(buff), "VFRINTN %c%d.%d%c, %c%d.%d%c", s, Rd, n, d, s, Rn, n, d);
+ return buff;
+ }
+ if(isMask(opcode, "000111100f100100010000nnnnnddddd", &a)) {
+ char s = (sf==0)?'S':((sf==1)?'D':'?');
+ snprintf(buff, sizeof(buff), "FRINTN %c%d, %c%d", s, Rd, s, Rn);
+ return buff;
+ }
+ // FRINTM
+ if(isMask(opcode, "0Q0011100f100001100110nnnnnddddd", &a)) {
+ char s = a.Q?'V':'D';
+ char d = sf?'D':'S';
+ int n = (a.Q && !sf)?4:2;
+ snprintf(buff, sizeof(buff), "VFRINTM %c%d.%d%c, %c%d.%d%c", s, Rd, n, d, s, Rn, n, d);
+ return buff;
+ }
+ if(isMask(opcode, "000111100f100101010000nnnnnddddd", &a)) {
+ char s = (sf==0)?'S':((sf==1)?'D':'?');
+ snprintf(buff, sizeof(buff), "FRINTM %c%d, %c%d", s, Rd, s, Rn);
+ return buff;
+ }
+ // FRINTP
+ if(isMask(opcode, "0Q0011101f100001100010nnnnnddddd", &a)) {
+ char s = a.Q?'V':'D';
+ char d = sf?'D':'S';
+ int n = (a.Q && !sf)?4:2;
+ snprintf(buff, sizeof(buff), "VFRINTP %c%d.%d%c, %c%d.%d%c", s, Rd, n, d, s, Rn, n, d);
+ return buff;
+ }
+ if(isMask(opcode, "000111100f100100110000nnnnnddddd", &a)) {
+ char s = (sf==0)?'S':((sf==1)?'D':'?');
+ snprintf(buff, sizeof(buff), "FRINTP %c%d, %c%d", s, Rd, s, Rn);
+ return buff;
+ }
+ // FRINTZ
+ if(isMask(opcode, "0Q0011101f100001100110nnnnnddddd", &a)) {
+ char s = a.Q?'V':'D';
+ char d = sf?'D':'S';
+ int n = (a.Q && !sf)?4:2;
+ snprintf(buff, sizeof(buff), "VFRINTZ %c%d.%d%c, %c%d.%d%c", s, Rd, n, d, s, Rn, n, d);
+ return buff;
+ }
+ if(isMask(opcode, "000111100f100101110000nnnnnddddd", &a)) {
+ char s = (sf==0)?'S':((sf==1)?'D':'?');
+ snprintf(buff, sizeof(buff), "FRINTZ %c%d, %c%d", s, Rd, s, Rn);
+ return buff;
+ }
//CMP
if(isMask(opcode, "00011110ff1mmmmm001000nnnnn0c000", &a)) {
@@ -1048,6 +1195,16 @@ const char* arm64_print(uint32_t opcode, uintptr_t addr)
snprintf(buff, sizeof(buff), "FCMP %c%d, %c%d", s, Rn, s, Rm);
return buff;
}
+ //FCMP vector
+ if(isMask(opcode, "0QU01110cf1mmmmm111001nnnnnddddd", &a)) {
+ char s = (sf==0)?'S':((sf==1)?'D':'?');
+ int n = (sf==0)?2:1;
+ n *= a.Q?2:1;
+ int op = (a.c<<1) | (a.U);
+ const char* OP[] = {"EQ", "GE", "??", "GT"};
+ snprintf(buff, sizeof(buff), "FCMP%s%s V%d.%d%c, V%d.%d%c, V%d.%d%c", OP[op], a.Q?"Q":"", Rd, n, s, Rn, n, s, Rm, n, s);
+ return buff;
+ }
//FMIN/FMAX
if(isMask(opcode, "00011110ff1mmmmm01oo10nnnnnddddd", &a)) {
char s = (sf==0)?'S':((sf==1)?'D':'?');
@@ -1061,6 +1218,27 @@ const char* arm64_print(uint32_t opcode, uintptr_t addr)
snprintf(buff, sizeof(buff), "F%sNM%s V%d.%d%c, V%d.%d%c, V%d.%d%c", option?"MIN":"MAX", a.Q?"Q":"", Rd, n, s, Rn, n, s, Rm, n, s);
return buff;
}
+ if(isMask(opcode, "0Q001110of1mmmmm111101nnnnnddddd", &a)) {
+ char s = (sf==0)?'S':((sf==1)?'D':'?');
+ int n = (sf==0)?2:1;
+ n *= a.Q?2:1;
+ snprintf(buff, sizeof(buff), "F%s%s V%d.%d%c, V%d.%d%c, V%d.%d%c", option?"MIN":"MAX", a.Q?"Q":"", Rd, n, s, Rn, n, s, Rm, n, s);
+ return buff;
+ }
+ // NEG
+ if(isMask(opcode, "0Q101110ff100000101110nnnnnddddd", &a)) {
+ const char* Y[] = {"8B", "16B", "4H", "8H", "2S", "4S", "??", "2D"};
+ const char* Vd = Y[(sf<<1) | a.Q];
+ snprintf(buff, sizeof(buff), "NEG%s V%d.%s, V%d.%s", a.Q?"Q":"", Rd, Vd, Rn, Vd);
+ return buff;
+ }
+ // SSHL vector
+ if(isMask(opcode, "0QU01110ff1mmmmm010rS1nnnnnddddd", &a)) {
+ const char* Y[] = {"8B", "16B", "4H", "8H", "2S", "4S", "??", "2D"};
+ const char* Vd = Y[(sf<<1) | a.Q];
+ snprintf(buff, sizeof(buff), "%c%s%sSHL%s V%d.%s, V%d.%s, V%d.%s", a.U?'U':'S', a.r?"R":"", a.S?"Q":"", a.Q?"Q":"", Rd, Vd, Rn, Vd, Rm, Vd);
+ return buff;
+ }
// FCVT
if(isMask(opcode, "f0011110pp10010U000000nnnnnddddd", &a)) {
@@ -1236,14 +1414,6 @@ const char* arm64_print(uint32_t opcode, uintptr_t addr)
return buff;
}
- // MOV immediate
- if(isMask(opcode, "0Q00111100000iii111001iiiiiddddd", &a)) {
- const char* Y[] = {"8B", "16B"};
- const char* Vd = Y[a.Q];
- snprintf(buff, sizeof(buff), "MOVI V%d.%s, #0x%x", Rd, Vd, imm);
- return buff;
- }
-
// LD1/ST1 single structure
if(isMask(opcode, "0Q0011010L000000cc0Sffnnnnnttttt", &a)) {
int scale = a.c;
@@ -1272,9 +1442,9 @@ const char* arm64_print(uint32_t opcode, uintptr_t addr)
sz = 4;
int offset = signExtend(imm, 9);
if(!offset)
- snprintf(buff, sizeof(buff), "%sUR %s%d, [%s]", a.L?"LD":"ST", Y[sz], Rd, XtSp[Rn]);
+ snprintf(buff, sizeof(buff), "%sUR %s%d, [%s]", a.L?"LD":"ST", Y[sz], Rt, XtSp[Rn]);
else
- snprintf(buff, sizeof(buff), "%sUR %s%d, [%s, %+d]", a.L?"LD":"ST", Y[sz], Rd, XtSp[Rn], imm);
+ snprintf(buff, sizeof(buff), "%sUR %s%d, [%s, %s0x%x]", a.L?"LD":"ST", Y[sz], Rt, XtSp[Rn], (offset<0)?"-":"", abs(offset));
return buff;
}
// LDR/STR vector immediate
@@ -1285,9 +1455,9 @@ const char* arm64_print(uint32_t opcode, uintptr_t addr)
sz = 4;
int offset = imm<<sz;
if(!offset)
- snprintf(buff, sizeof(buff), "%sR %s%d, [%s]", a.L?"LD":"ST", Y[sz], Rd, XtSp[Rn]);
+ snprintf(buff, sizeof(buff), "%sR %s%d, [%s]", a.L?"LD":"ST", Y[sz], Rt, XtSp[Rn]);
else
- snprintf(buff, sizeof(buff), "%sR %s%d, [%s, %+d]", a.L?"LD":"ST", Y[sz], Rd, XtSp[Rn], imm);
+ snprintf(buff, sizeof(buff), "%sR %s%d, [%s, %+d]", a.L?"LD":"ST", Y[sz], Rt, XtSp[Rn], imm);
return buff;
}
@@ -1329,7 +1499,7 @@ const char* arm64_print(uint32_t opcode, uintptr_t addr)
// DUP
if(isMask(opcode, "0Q001110000iiiii000001nnnnnddddd", &a)) {
- const char* Y[] = {"8B", "16B", "4H", "8H", "2S", "4S", "2D", "??"};
+ const char* Y[] = {"8B", "16B", "4H", "8H", "2S", "4S", "??", "2D"};
const char* Z[] = {"B", "H", "S", "D"};
int sz = 3;
if((imm&0b0001)==0b0001) sz=0;
@@ -1341,7 +1511,18 @@ const char* arm64_print(uint32_t opcode, uintptr_t addr)
snprintf(buff, sizeof(buff), "DUP V%d.%s, V%d.%s[%d]", Rd, Vd, Rn, Vn, sh);
return buff;
}
-
+
+ if(isMask(opcode, "0Q001110000iiiii000011nnnnnddddd", &a)) {
+ const char* Y[] = {"8B", "16B", "4H", "8H", "2S", "4S", "??", "2D"};
+ int sz = 3;
+ if((imm&0b0001)==0b0001) sz=0;
+ else if((imm&0b0011)==0b0010) sz=1;
+ else if((imm&0b0111)==0b0100) sz=2;
+ const char* Vd = Y[(sz<<1)|a.Q];
+ snprintf(buff, sizeof(buff), "DUP V%d.%s, X%d", Rd, Vd, Rn);
+ return buff;
+ }
+
// AES
if(isMask(opcode, "0100111000101000010f10nnnnnddddd", &a)) {
snprintf(buff, sizeof(buff), "AES%c V%d.16B, V%d.16B", sf?'D':'E', Rd, Rn);
@@ -1365,6 +1546,7 @@ const char* arm64_print(uint32_t opcode, uintptr_t addr)
// DMB ISH
if(isMask(opcode, "11010101000000110011nnnn10111111", &a)) {
snprintf(buff, sizeof(buff), "DMB %s", (Rn==0b1011)?"ISH":"???");
+ return buff;
}
diff --git a/src/dynarec/arm64/arm64_prolog.S b/src/dynarec/arm64/arm64_prolog.S
index 5635fde..5635fde 100755..100644
--- a/src/dynarec/arm64/arm64_prolog.S
+++ b/src/dynarec/arm64/arm64_prolog.S
diff --git a/src/dynarec/arm64/dynarec_arm64_00.c b/src/dynarec/arm64/dynarec_arm64_00.c
index 4f327f5..c434dbd 100755..100644
--- a/src/dynarec/arm64/dynarec_arm64_00.c
+++ b/src/dynarec/arm64/dynarec_arm64_00.c
@@ -1,7 +1,6 @@
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
-#include <pthread.h>
#include <errno.h>
#include <signal.h>
@@ -26,6 +25,7 @@
#include "dynarec_arm64_helper.h"
int isSimpleWrapper(wrapper_t fun);
+int isRetX87Wrapper(wrapper_t fun);
uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog)
{
@@ -40,6 +40,7 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
uint64_t u64;
uint8_t wback, wb1, wb2, wb;
int64_t fixedaddress;
+ int unscaled;
int lock;
int cacheupd = 0;
@@ -101,7 +102,25 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
i64 = F32S;
emit_add32c(dyn, ninst, rex, xRAX, i64, x3, x4, x5);
break;
-
+ case 0x06:
+ if(rex.is32bits) {
+ INST_NAME("PUSH ES");
+ LDRH_U12(x1, xEmu, offsetof(x64emu_t, segs[_ES]));
+ PUSH1_32(x1);
+ } else {
+ DEFAULT;
+ }
+ break;
+ case 0x07:
+ if(rex.is32bits) {
+ INST_NAME("POP ES");
+ POP1_32(x1);
+ STRH_U12(x1, xEmu, offsetof(x64emu_t, segs[_ES]));
+ STRw_U12(xZR, xEmu, offsetof(x64emu_t, segs_serial[_ES]));
+ } else {
+ DEFAULT;
+ }
+ break;
case 0x08:
INST_NAME("OR Eb, Gb");
SETFLAGS(X_ALL, SF_SET_PENDING);
@@ -277,7 +296,25 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MOV64xw(x2, i64);
emit_sbb32(dyn, ninst, rex, xRAX, x2, x3, x4);
break;
-
+ case 0x1E:
+ if(rex.is32bits) {
+ INST_NAME("PUSH DS");
+ LDRH_U12(x1, xEmu, offsetof(x64emu_t, segs[_DS]));
+ PUSH1_32(x1);
+ } else {
+ DEFAULT;
+ }
+ break;
+ case 0x1F:
+ if(rex.is32bits) {
+ INST_NAME("POP DS");
+ POP1_32(x1);
+ STRH_U12(x1, xEmu, offsetof(x64emu_t, segs[_DS]));
+ STRw_U12(xZR, xEmu, offsetof(x64emu_t, segs_serial[_DS]));
+ } else {
+ DEFAULT;
+ }
+ break;
case 0x20:
INST_NAME("AND Eb, Gb");
SETFLAGS(X_ALL, SF_SET_PENDING);
@@ -489,6 +526,45 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
emit_cmp32_0(dyn, ninst, rex, xRAX, x3, x4);
break;
+ case 0x3F:
+ if(rex.is32bits) {
+ INST_NAME("AAS");
+ MESSAGE(LOG_DUMP, "Need Optimization AAS\n");
+ READFLAGS(X_AF);
+ SETFLAGS(X_AF|X_CF|X_PF|X_SF|X_ZF, SF_SET);
+ UXTHw(x1, xRAX);
+ CALL_(aas16, x1, 0);
+ BFIx(xRAX, x1, 0, 16);
+ } else {
+ DEFAULT;
+ }
+ break;
+ case 0x40:
+ case 0x41:
+ case 0x42:
+ case 0x43:
+ case 0x44:
+ case 0x45:
+ case 0x46:
+ case 0x47:
+ INST_NAME("INC Reg (32bits)");
+ SETFLAGS(X_ALL&~X_CF, SF_SUBSET_PENDING);
+ gd = xRAX + (opcode&7);
+ emit_inc32(dyn, ninst, rex, gd, x1, x2);
+ break;
+ case 0x48:
+ case 0x49:
+ case 0x4A:
+ case 0x4B:
+ case 0x4C:
+ case 0x4D:
+ case 0x4E:
+ case 0x4F:
+ INST_NAME("DEC Reg (32bits)");
+ SETFLAGS(X_ALL&~X_CF, SF_SUBSET_PENDING);
+ gd = xRAX + (opcode&7);
+ emit_dec32(dyn, ninst, rex, gd, x1, x2);
+ break;
case 0x50:
case 0x51:
case 0x52:
@@ -498,12 +574,39 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
case 0x56:
case 0x57:
INST_NAME("PUSH reg");
- gd = xRAX+(opcode&0x07)+(rex.b<<3);
- if(gd==xRSP) {
- MOVx_REG(x1, gd);
- gd = x1;
+ if(dyn->doublepush) {
+ SKIPTEST(x1);
+ dyn->doublepush = 0;
+ } else {
+ gd = xRAX+(opcode&0x07)+(rex.b<<3);
+ u32 = PK(0);
+ i32 = 1;
+ rex.rex = 0;
+ if(!rex.is32bits)
+ while(u32>=0x40 && u32<=0x4f) {
+ rex.rex = u32;
+ u32 = PK(i32);
+ i32++;
+ }
+ if(!box64_dynarec_test && u32>=0x50 && u32<=0x57 && (dyn->size>(ninst+1) && dyn->insts[ninst+1].pred_sz==1) && gd != xRSP) {
+ u32= xRAX+(u32&0x07)+(rex.b<<3);
+ if(u32==xRSP) {
+ PUSH1z(gd);
+ } else {
+ // double push!
+ MESSAGE(LOG_DUMP, "DOUBLE PUSH\n");
+ PUSH2z(gd, u32);
+ dyn->doublepush = 1;
+ }
+ } else {
+ if (gd == xRSP) {
+ MOVz_REG(x1, xRSP);
+ PUSH1z(x1);
+ } else {
+ PUSH1z(gd);
+ }
+ }
}
- PUSH1(gd);
break;
case 0x58:
case 0x59:
@@ -514,34 +617,102 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
case 0x5E:
case 0x5F:
INST_NAME("POP reg");
- gd = xRAX+(opcode&0x07)+(rex.b<<3);
- if(gd == xRSP) {
- POP1(x1);
- MOVx_REG(gd, x1);
+ if(dyn->doublepop) {
+ SKIPTEST(x1);
+ dyn->doublepop = 0;
} else {
- POP1(gd);
+ gd = xRAX+(opcode&0x07)+(rex.b<<3);
+ u32 = PK(0);
+ i32 = 1;
+ rex.rex = 0;
+ if(!rex.is32bits)
+ while(u32>=0x40 && u32<=0x4f) {
+ rex.rex = u32;
+ u32 = PK(i32);
+ i32++;
+ }
+ if(!box64_dynarec_test && (gd!=xRSP) && u32>=0x58 && u32<=0x5f && (dyn->size>(ninst+1) && dyn->insts[ninst+1].pred_sz==1)) {
+ // double pop!
+ u32= xRAX+(u32&0x07)+(rex.b<<3);
+ MESSAGE(LOG_DUMP, "DOUBLE POP\n");
+ if(gd==u32) {
+ ADDz_U12(xRSP, xRSP, rex.is32bits?0x4:0x8);
+ POP1z(gd);
+ } else {
+ POP2z(gd, (u32==xRSP)?x1:u32);
+ if(u32==xRSP) {
+ MOVz_REG(u32, x1);
+ }
+ }
+ dyn->doublepop = 1;
+ SKIPTEST(x1); // disable test for this OP
+ } else {
+ if(gd == xRSP) {
+ POP1z(x1);
+ MOVz_REG(gd, x1);
+ } else {
+ POP1z(gd);
+ }
+ }
+ }
+ break;
+ case 0x60:
+ if(rex.is32bits) {
+ INST_NAME("PUSHAD");
+ MOVw_REG(x1, xRSP);
+ PUSH2_32(xRAX, xRCX);
+ PUSH2_32(xRDX, xRBX);
+ PUSH2_32(x1, xRBP);
+ PUSH2_32(xRSI, xRDI);
+ } else {
+ DEFAULT;
+ }
+ break;
+ case 0x61:
+ if(rex.is32bits) {
+ INST_NAME("POPAD");
+ POP2_32(xRDI, xRSI);
+ POP2_32(xRBP, x1);
+ POP2_32(xRBX, xRDX);
+ POP2_32(xRCX, xRAX);
+ } else {
+ DEFAULT;
+ }
+ break;
+ case 0x62:
+ if(rex.is32bits) {
+ // BOUND here
+ DEFAULT;
+ } else {
+ INST_NAME("BOUND Gd, Ed");
+ nextop = F8;
+ FAKEED(0);
}
break;
-
case 0x63:
- INST_NAME("MOVSXD Gd, Ed");
- nextop = F8;
- GETGD;
- if(rex.w) {
- if(MODREG) { // reg <= reg
- SXTWx(gd, xRAX+(nextop&7)+(rex.b<<3));
- } else { // mem <= reg
- SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<2, 3, rex, NULL, 0, 0);
- LDRSW_U12(gd, ed, fixedaddress);
- }
+ if(rex.is32bits) {
+ // ARPL here
+ DEFAULT;
} else {
- if(MODREG) { // reg <= reg
- MOVw_REG(gd, xRAX+(nextop&7)+(rex.b<<3));
- } else { // mem <= reg
- SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<2, 3, rex, NULL, 0, 0);
- LDRw_U12(gd, ed, fixedaddress);
+ INST_NAME("MOVSXD Gd, Ed");
+ nextop = F8;
+ GETGD;
+ if(rex.w) {
+ if(MODREG) { // reg <= reg
+ SXTWx(gd, xRAX+(nextop&7)+(rex.b<<3));
+ } else { // mem <= reg
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, 0);
+ LDSW(gd, ed, fixedaddress);
+ }
+ } else {
+ if(MODREG) { // reg <= reg
+ MOVw_REG(gd, xRAX+(nextop&7)+(rex.b<<3));
+ } else { // mem <= reg
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, 0);
+ LDW(gd, ed, fixedaddress);
+ }
}
}
break;
@@ -564,10 +735,10 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MESSAGE(LOG_DUMP, "PUSH then RET, using indirect\n");
TABLE64(x3, addr-4);
LDRSW_U12(x1, x3, 0);
- PUSH1(x1);
+ PUSH1z(x1);
} else {
- MOV64x(x3, i64);
- PUSH1(x3);
+ MOV64z(x3, i64);
+ PUSH1z(x3);
}
break;
case 0x69:
@@ -606,8 +777,8 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
case 0x6A:
INST_NAME("PUSH Ib");
i64 = F8S;
- MOV64x(x3, i64);
- PUSH1(x3);
+ MOV64z(x3, i64);
+ PUSH1z(x3);
break;
case 0x6B:
INST_NAME("IMUL Gd, Ed, Ib");
@@ -643,6 +814,18 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
}
break;
+ case 0x6D:
+ INST_NAME("INSD");
+ SETFLAGS(X_ALL, SF_SET); // Hack to set flags in "don't care" state
+ GETIP(ip);
+ STORE_XEMU_CALL(xRIP);
+ CALL(native_priv, -1);
+ LOAD_XEMU_CALL(xRIP);
+ jump_to_epilog(dyn, 0, xRIP, ninst);
+ *need_epilog = 0;
+ *ok = 0;
+ break;
+
#define GO(GETFLAGS, NO, YES, F) \
READFLAGS(F); \
i8 = F8S; \
@@ -672,7 +855,13 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
GOCOND(0x70, "J", "ib");
#undef GO
-
+
+ case 0x82:
+ if(!rex.is32bits) {
+ DEFAULT;
+ return ip;
+ }
+ // fallthru
case 0x80:
nextop = F8;
switch((nextop>>3)&7) {
@@ -841,7 +1030,7 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
nextop=F8;
GETGD;
GETED(0);
- emit_test32(dyn, ninst, rex, ed, gd, x3, x5);
+ emit_test32(dyn, ninst, rex, ed, gd, x3, x5, x6);
break;
case 0x86:
INST_NAME("(LOCK)XCHG Eb, Gb");
@@ -865,7 +1054,7 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
} else {
SMDMB();
GETGB(x4);
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
MARKLOCK;
// do the swap with exclusive locking
LDAXRB(x1, ed);
@@ -887,7 +1076,7 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MOVxw_REG(ed, x1);
} else {
GETGD;
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
SMDMB();
TSTx_mask(ed, 1, 0, 1+rex.w); // mask=3 or 7
B_MARK(cNE);
@@ -932,8 +1121,8 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
}
BFIx(eb1, gd, eb2*8, 8);
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff, 0, rex, &lock, 0, 0);
- STRB_U12(gd, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff, 0, rex, &lock, 0, 0);
+ STB(gd, ed, fixedaddress);
SMWRITELOCK(lock);
}
break;
@@ -944,8 +1133,8 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
if(MODREG) { // reg <= reg
MOVxw_REG(xRAX+(nextop&7)+(rex.b<<3), gd);
} else { // mem <= reg
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, &lock, 0, 0);
- STRxw_U12(gd, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, &lock, 0, 0);
+ STxw(gd, ed, fixedaddress);
SMWRITELOCK(lock);
}
break;
@@ -976,9 +1165,9 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
ed = wback;
}
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff, 0, rex, &lock, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff, 0, rex, &lock, 0, 0);
SMREADLOCK(lock);
- LDRB_U12(x4, wback, fixedaddress);
+ LDB(x4, wback, fixedaddress);
ed = x4;
}
BFIx(gb1, ed, gb2*8, 8);
@@ -990,20 +1179,21 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
if(MODREG) {
MOVxw_REG(gd, xRAX+(nextop&7)+(rex.b<<3));
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, &lock, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, &lock, 0, 0);
SMREADLOCK(lock);
- LDRxw_U12(gd, ed, fixedaddress);
+ LDxw(gd, ed, fixedaddress);
}
break;
case 0x8C:
INST_NAME("MOV Ed, Seg");
nextop=F8;
+ u8 = (nextop&0x38)>>3;
if((nextop&0xC0)==0xC0) { // reg <= seg
- LDRH_U12(xRAX+(nextop&7)+(rex.b<<3), xEmu, offsetof(x64emu_t, segs[(nextop&0x38)>>3]));
+ LDRw_U12(xRAX+(nextop&7)+(rex.b<<3), xEmu, offsetof(x64emu_t, segs[u8]));
} else { // mem <= seg
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0, 0, rex, NULL, 0, 0);
- LDRH_U12(x3, xEmu, offsetof(x64emu_t, segs[(nextop&0x38)>>3]));
- STRH_U12(x3, ed, fixedaddress);
+ LDRw_U12(x3, xEmu, offsetof(x64emu_t, segs[u8]));
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, &unscaled, 0xfff<<1, 1, rex, NULL, 0, 0);
+ STH(x3, wback, fixedaddress);
SMWRITE2();
}
break;
@@ -1014,11 +1204,11 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
if(MODREG) { // reg <= reg? that's an invalid operation
DEFAULT;
} else { // mem <= reg
- addr = geted(dyn, addr, ninst, nextop, &ed, gd, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, gd, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
if(gd!=ed) { // it's sometimes used as a 3 bytes NOP
MOVxw_REG(gd, ed);
}
- else if(!rex.w) {
+ else if(!rex.w && !rex.is32bits) {
MOVw_REG(gd, gd); //truncate the higher 32bits as asked
}
}
@@ -1026,32 +1216,33 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
case 0x8E:
INST_NAME("MOV Seg,Ew");
nextop = F8;
+ u8 = (nextop&0x38)>>3;
if((nextop&0xC0)==0xC0) {
ed = xRAX+(nextop&7)+(rex.b<<3);
} else {
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<2, 0, rex, NULL, 0, 0);
- LDRH_U12(x1, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, &unscaled, 0xfff<<1, 1, rex, NULL, 0, 0);
+ LDH(x1, wback, fixedaddress);
ed = x1;
}
- STRw_U12(ed, xEmu, offsetof(x64emu_t, segs[(nextop&0x38)>>3]));
- STRw_U12(wZR, xEmu, offsetof(x64emu_t, segs_serial[(nextop&0x38)>>3]));
+ STRw_U12(ed, xEmu, offsetof(x64emu_t, segs[u8]));
+ STRw_U12(wZR, xEmu, offsetof(x64emu_t, segs_serial[u8]));
break;
case 0x8F:
INST_NAME("POP Ed");
nextop = F8;
if(MODREG) {
- POP1(xRAX+(nextop&7)+(rex.b<<3));
+ POP1z(xRAX+(nextop&7)+(rex.b<<3));
} else {
- POP1(x2); // so this can handle POP [ESP] and maybe some variant too
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
+ POP1z(x2); // so this can handle POP [ESP] and maybe some variant too
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
if(ed==xRSP) {
- STRx_U12(x2, ed, fixedaddress);
+ STz(x2, ed, fixedaddress);
} else {
// complicated to just allow a segfault that can be recovered correctly
- SUBx_U12(xRSP, xRSP, 8);
- STRx_U12(x2, ed, fixedaddress);
- ADDx_U12(xRSP, xRSP, 8);
+ SUBz_U12(xRSP, xRSP, rex.is32bits?4:8);
+ STz(x2, ed, fixedaddress);
+ ADDz_U12(xRSP, xRSP, rex.is32bits?4:8);
}
}
break;
@@ -1093,26 +1284,33 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
case 0x9C:
INST_NAME("PUSHF");
READFLAGS(X_ALL);
- PUSH1(xFlags);
+ PUSH1z(xFlags);
break;
case 0x9D:
INST_NAME("POPF");
SETFLAGS(X_ALL, SF_SET);
- POP1(xFlags);
+ POP1z(xFlags);
MOV32w(x1, 0x3F7FD7);
ANDw_REG(xFlags, xFlags, x1);
ORRw_mask(xFlags, xFlags, 0b011111, 0); //mask=0x00000002
SET_DFNONE(x1);
+ if(box64_wine) { // should this be done all the time?
+ TBZ_NEXT(xFlags, F_TF);
+ MOV64x(x1, addr);
+ STORE_XEMU_CALL(x1);
+ CALL(native_singlestep, -1);
+ BFCw(xFlags, F_TF, 1);
+ }
break;
case 0x9E:
INST_NAME("SAHF");
SETFLAGS(X_CF|X_PF|X_AF|X_ZF|X_SF, SF_SUBSET);
MOV32w(x2, 0b11010101);
BICw_REG(xFlags, xFlags, x2);
- UBFXx(x1, xRAX, 8, 8);
+ UBFXw(x1, xRAX, 8, 8);
ANDw_REG(x1, x1, x2);
ORRw_REG(xFlags, xFlags, x1);
- SET_DFNONE(x1);
+ SET_DFNONE(x1);
break;
case 0x9F:
INST_NAME("LAHF");
@@ -1121,28 +1319,42 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
break;
case 0xA0:
INST_NAME("MOV AL,Ob");
- u64 = F64;
- MOV64x(x1, u64);
+ if(rex.is32bits)
+ u64 = F32;
+ else
+ u64 = F64;
+ MOV64z(x1, u64);
+ SMREAD();
LDRB_U12(x2, x1, 0);
BFIx(xRAX, x2, 0, 8);
break;
case 0xA1:
INST_NAME("MOV EAX,Od");
- u64 = F64;
- MOV64x(x1, u64);
+ if(rex.is32bits)
+ u64 = F32;
+ else
+ u64 = F64;
+ MOV64z(x1, u64);
+ SMREAD();
LDRxw_U12(xRAX, x1, 0);
break;
case 0xA2:
INST_NAME("MOV Ob,AL");
- u64 = F64;
- MOV64x(x1, u64);
+ if(rex.is32bits)
+ u64 = F32;
+ else
+ u64 = F64;
+ MOV64z(x1, u64);
STRB_U12(xRAX, x1, 0);
SMWRITE();
break;
case 0xA3:
INST_NAME("MOV Od,EAX");
- u64 = F64;
- MOV64x(x1, u64);
+ if(rex.is32bits)
+ u64 = F32;
+ else
+ u64 = F64;
+ MOV64z(x1, u64);
STRxw_U12(xRAX, x1, 0);
SMWRITE();
break;
@@ -1237,7 +1449,45 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
break;
}
break;
-
+ case 0xA7:
+ switch(rep) {
+ case 1:
+ case 2:
+ if(rep==1) {INST_NAME("REPNZ CMPSD");} else {INST_NAME("REPZ CMPSD");}
+ MAYSETFLAGS();
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ CBZx_NEXT(xRCX);
+ TBNZ_MARK2(xFlags, F_DF);
+ MARK; // Part with DF==0
+ LDRxw_S9_postindex(x1, xRSI, rex.w?8:4);
+ LDRxw_S9_postindex(x2, xRDI, rex.w?8:4);
+ SUBx_U12(xRCX, xRCX, 1);
+ CMPSxw_REG(x1, x2);
+ B_MARK3((rep==1)?cEQ:cNE);
+ CBNZx_MARK(xRCX);
+ B_MARK3_nocond;
+ MARK2; // Part with DF==1
+ LDRxw_S9_postindex(x1, xRSI, rex.w?-8:-4);
+ LDRxw_S9_postindex(x2, xRDI, rex.w?-8:-4);
+ SUBx_U12(xRCX, xRCX, 1);
+ CMPSxw_REG(x1, x2);
+ B_MARK3((rep==1)?cEQ:cNE);
+ CBNZx_MARK2(xRCX);
+ MARK3; // end
+ emit_cmp32(dyn, ninst, rex, x1, x2, x3, x4, x5);
+ break;
+ default:
+ INST_NAME("CMPSD");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETDIR(x3, rex.w?8:4);
+ LDRxw_U12(x1, xRSI, 0);
+ LDRxw_U12(x2, xRDI, 0);
+ ADDx_REG(xRSI, xRSI, x3);
+ ADDx_REG(xRDI, xRDI, x3);
+ emit_cmp32(dyn, ninst, rex, x1, x2, x3, x4, x5);
+ break;
+ }
+ break;
case 0xA8:
INST_NAME("TEST AL, Ib");
SETFLAGS(X_ALL, SF_SET_PENDING);
@@ -1251,7 +1501,7 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
SETFLAGS(X_ALL, SF_SET_PENDING);
i64 = F32S;
MOV64xw(x2, i64);
- emit_test32(dyn, ninst, rex, xRAX, x2, x3, x4);
+ emit_test32(dyn, ninst, rex, xRAX, x2, x3, x4, x5);
break;
case 0xAA:
if(rep) {
@@ -1297,26 +1547,42 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
ADDx_REG(xRDI, xRDI, x3);
}
break;
-
+ case 0xAC:
+ if(rep) {
+ INST_NAME("REP LODSB");
+ } else {
+ INST_NAME("LODSB");
+ }
+ GETDIR(x1, 1);
+ if(rep) {
+ CBZx_NEXT(xRCX);
+ MARK;
+ }
+ LDRB_U12(x2, xRSI, 0);
+ ADDx_REG(xRSI, xRSI, x1);
+ if(rep) {
+ SUBx_U12(xRCX, xRCX, 1);
+ CBNZx_MARK(xRCX);
+ }
+ BFIx(xRAX, x2, 0, 8);
+ break;
case 0xAD:
if(rep) {
INST_NAME("REP LODSD");
} else {
INST_NAME("LODSD");
}
- LDRxw_U12(xRAX, xRSI, 0);
- BFIw(x2, xFlags, F_DF, 1);
- if(rex.w) {
- MOV32w(x1, 8);
- } else {
- MOV32w(x1, 4);
- }
- EORxw_REG_LSL(x1, x1, x2, rex.w?63:31);
+ GETDIR(x1, rex.w?8:4);
if(rep) {
- MULxw(x1, x1, xRCX);
- EORw_REG(xRCX, xRCX, xRCX);
+ CBZx_NEXT(xRCX);
+ MARK;
}
+ LDRxw_U12(xRAX, xRSI, 0);
ADDx_REG(xRSI, xRSI, x1);
+ if(rep) {
+ SUBx_U12(xRCX, xRCX, 1);
+ CBNZx_MARK(xRCX);
+ }
break;
case 0xAE:
switch(rep) {
@@ -1355,7 +1621,7 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
break;
}
break;
-
+
case 0xB0:
case 0xB1:
@@ -1585,7 +1851,7 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
}
BARRIER(BARRIER_FLOAT);
i32 = F16;
- retn_to_epilog(dyn, ninst, i32);
+ retn_to_epilog(dyn, ninst, rex, i32);
*need_epilog = 0;
*ok = 0;
break;
@@ -1593,10 +1859,10 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("RET");
// SETFLAGS(X_ALL, SF_SET); // Hack, set all flags (to an unknown state...)
if(box64_dynarec_safeflags) {
- READFLAGS(X_PEND); // so instead, force the defered flags, so it's not too slow, and flags are not lost
+ READFLAGS(X_PEND); // so instead, force the deferred flags, so it's not too slow, and flags are not lost
}
BARRIER(BARRIER_FLOAT);
- ret_to_epilog(dyn, ninst);
+ ret_to_epilog(dyn, ninst, rex);
*need_epilog = 0;
*ok = 0;
break;
@@ -1612,15 +1878,19 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
eb2 = (ed&4)>>2; // L or H
} else {
eb1 = xRAX+(nextop&7)+(rex.b<<3);
- eb2 = 0;
+ eb2 = 0;
}
MOV32w(x3, u8);
BFIx(eb1, x3, eb2*8, 8);
} else { // mem <= u8
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff, 0, rex, &lock, 0, 1);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x1, &fixedaddress, &unscaled, 0xfff, 0, rex, &lock, 0, 1);
u8 = F8;
- MOV32w(x3, u8);
- STRB_U12(x3, ed, fixedaddress);
+ if(u8) {
+ MOV32w(x3, u8);
+ ed = x3;
+ } else
+ ed = xZR;
+ STB(ed, wback, fixedaddress);
SMWRITELOCK(lock);
}
break;
@@ -1632,25 +1902,30 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
ed = xRAX+(nextop&7)+(rex.b<<3);
MOV64xw(ed, i64);
} else { // mem <= i32
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, &lock, 0, 4);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, &unscaled, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, &lock, 0, 4);
i64 = F32S;
- MOV64xw(x3, i64);
- STRxw_U12(x3, ed, fixedaddress);
+ if(i64) {
+ MOV64xw(x3, i64);
+ ed = x3;
+ } else
+ ed = xZR;
+ STxw(ed, wback, fixedaddress);
SMWRITELOCK(lock);
}
break;
case 0xC9:
INST_NAME("LEAVE");
- MOVx_REG(xRSP, xRBP);
- POP1(xRBP);
+ MOVz_REG(xRSP, xRBP);
+ POP1z(xRBP);
break;
case 0xCC:
SETFLAGS(X_ALL, SF_SET); // Hack, set all flags (to an unknown state...)
+ SKIPTEST(x1);
if(PK(0)=='S' && PK(1)=='C') {
addr+=2;
- BARRIER(BARRIER_FLOAT);
+ //BARRIER(BARRIER_FLOAT);
INST_NAME("Special Box64 instruction");
if((PK64(0)==0))
{
@@ -1667,6 +1942,9 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
x87_forget(dyn, ninst, x3, x4, 0);
sse_purge07cache(dyn, ninst, x3);
tmp = isSimpleWrapper(*(wrapper_t*)(addr));
+ if(isRetX87Wrapper(*(wrapper_t*)(addr)))
+ // return value will be on the stack, so the stack depth needs to be updated
+ x87_purgecache(dyn, ninst, 0, x3, x1, x4);
if((box64_log<2 && !cycle_log) && tmp) {
//GETIP(ip+3+8+8); // read the 0xCC
call_n(dyn, ninst, *(void**)(addr+8), tmp);
@@ -1705,6 +1983,45 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
#endif
}
break;
+ case 0xCD:
+ u8 = F8;
+ if(box64_wine && (u8==0x2D || u8==0x2C || u8==0x29)) {
+ INST_NAME("INT 29/2c/2d");
+ // lets do nothing
+ MESSAGE(LOG_INFO, "INT 29/2c/2d Windows interruption\n");
+ GETIP(ip);
+ STORE_XEMU_CALL(xRIP);
+ MOV32w(x1, u8);
+ CALL(native_int, -1);
+ LOAD_XEMU_CALL(xRIP);
+ } else if (u8==0x80) {
+ INST_NAME("32bits SYSCALL");
+ NOTEST(x1);
+ SMEND();
+ GETIP(addr);
+ STORE_XEMU_CALL(xRIP);
+ CALL_S(x86Syscall, -1);
+ LOAD_XEMU_CALL(xRIP);
+ TABLE64(x3, addr); // expected return address
+ CMPSx_REG(xRIP, x3);
+ B_MARK(cNE);
+ LDRw_U12(w1, xEmu, offsetof(x64emu_t, quit));
+ CBZw_NEXT(w1);
+ MARK;
+ LOAD_XEMU_REM();
+ jump_to_epilog(dyn, 0, xRIP, ninst);
+ } else {
+ INST_NAME("INT n");
+ SETFLAGS(X_ALL, SF_SET); // Hack to set flags in "don't care" state
+ GETIP(ip);
+ STORE_XEMU_CALL(xRIP);
+ CALL(native_priv, -1);
+ LOAD_XEMU_CALL(xRIP);
+ jump_to_epilog(dyn, 0, xRIP, ninst);
+ *need_epilog = 0;
+ *ok = 0;
+ }
+ break;
case 0xCF:
INST_NAME("IRET");
@@ -1892,7 +2209,7 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MOV64xw(x4, (rex.w?64:32));
SUBx_REG(x3, x4, x3);
GETED(0);
- if(!rex.w && MODREG) {MOVw_REG(ed, ed);}
+ if(!rex.w && !rex.is32bits && MODREG) {MOVw_REG(ed, ed);}
B_NEXT(cEQ);
RORxw_REG(ed, ed, x3);
WBACK;
@@ -1916,7 +2233,7 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
ANDSw_mask(x3, xRCX, 0, 0b00100); //mask=0x00000001f
}
GETED(0);
- if(!rex.w && MODREG) {MOVw_REG(ed, ed);}
+ if(!rex.w && !rex.is32bits && MODREG) {MOVw_REG(ed, ed);}
B_NEXT(cEQ);
RORxw_REG(ed, ed, x3);
WBACK;
@@ -1943,7 +2260,7 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
ANDSw_mask(x2, xRCX, 0, 0b00100); //mask=0x00000001f
}
GETEDW(x4, x1, 0);
- if(!rex.w && MODREG) {MOVw_REG(ed, ed);}
+ if(!rex.w && !rex.is32bits && MODREG) {MOVw_REG(ed, ed);}
B_NEXT(cEQ);
CALL_(rex.w?((void*)rcl64):((void*)rcl32), ed, x4);
WBACK;
@@ -1959,7 +2276,7 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
ANDSw_mask(x2, xRCX, 0, 0b00100); //mask=0x00000001f
}
GETEDW(x4, x1, 0);
- if(!rex.w && MODREG) {MOVw_REG(ed, ed);}
+ if(!rex.w && !rex.is32bits && MODREG) {MOVw_REG(ed, ed);}
B_NEXT(cEQ);
CALL_(rex.w?((void*)rcr64):((void*)rcr32), ed, x4);
WBACK;
@@ -1974,7 +2291,7 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
ANDSw_mask(x3, xRCX, 0, 0b00100); //mask=0x00000001f
}
GETED(0);
- if(!rex.w && MODREG) {MOVw_REG(ed, ed);}
+ if(!rex.w && !rex.is32bits && MODREG) {MOVw_REG(ed, ed);}
B_NEXT(cEQ);
emit_shl32(dyn, ninst, rex, ed, x3, x5, x4);
WBACK;
@@ -1988,7 +2305,7 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
ANDSw_mask(x3, xRCX, 0, 0b00100); //mask=0x00000001f
}
GETED(0);
- if(!rex.w && MODREG) {MOVw_REG(ed, ed);}
+ if(!rex.w && !rex.is32bits && MODREG) {MOVw_REG(ed, ed);}
B_NEXT(cEQ);
emit_shr32(dyn, ninst, rex, ed, x3, x5, x4);
WBACK;
@@ -2002,7 +2319,7 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
ANDSw_mask(x3, xRCX, 0, 0b00100); //mask=0x00000001f
}
GETED(0);
- if(!rex.w && MODREG) {MOVw_REG(ed, ed);}
+ if(!rex.w && !rex.is32bits && MODREG) {MOVw_REG(ed, ed);}
B_NEXT(cEQ);
UFLAG_OP12(ed, x3);
ASRxw_REG(ed, ed, x3);
@@ -2042,7 +2359,7 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
CHECK_CACHE()) { \
/* out of the block */ \
i32 = dyn->insts[ninst].epilog-(dyn->native_size); \
- if(Z) {CBNZx(xRCX, i32);} else {CBZx(xRCX, i32);}; \
+ if(Z) {CBNZz(xRCX, i32);} else {CBZz(xRCX, i32);}; \
if(dyn->insts[ninst].x64.jmp_insts==-1) { \
if(!(dyn->insts[ninst].x64.barrier&BARRIER_FLOAT)) \
fpu_purgecache(dyn, ninst, 1, x1, x2, x3); \
@@ -2055,28 +2372,28 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
} else { \
/* inside the block */ \
i32 = dyn->insts[dyn->insts[ninst].x64.jmp_insts].address-(dyn->native_size); \
- if(Z) {CBZx(xRCX, i32);} else {CBNZx(xRCX, i32);}; \
+ if(Z) {CBZz(xRCX, i32);} else {CBNZz(xRCX, i32);}; \
}
case 0xE0:
INST_NAME("LOOPNZ");
READFLAGS(X_ZF);
i8 = F8S;
- SUBx_U12(xRCX, xRCX, 1);
- TBNZ_NEXT(xFlags, 1<<F_ZF);
+ SUBz_U12(xRCX, xRCX, 1);
+ TBNZ_NEXT(xFlags, F_ZF);
GO(0);
break;
case 0xE1:
INST_NAME("LOOPZ");
READFLAGS(X_ZF);
i8 = F8S;
- SUBx_U12(xRCX, xRCX, 1);
- TBZ_NEXT(xFlags, 1<<F_ZF);
+ SUBz_U12(xRCX, xRCX, 1);
+ TBZ_NEXT(xFlags, F_ZF);
GO(0);
break;
case 0xE2:
INST_NAME("LOOP");
i8 = F8S;
- SUBx_U12(xRCX, xRCX, 1);
+ SUBz_U12(xRCX, xRCX, 1);
GO(0);
break;
case 0xE3:
@@ -2095,9 +2412,9 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
#endif
}
#if STEP < 2
- if(isNativeCall(dyn, addr+i32, &dyn->insts[ninst].natcall, &dyn->insts[ninst].retn))
+ if(!rex.is32bits && isNativeCall(dyn, addr+i32, &dyn->insts[ninst].natcall, &dyn->insts[ninst].retn))
tmp = dyn->insts[ninst].pass2choice = 3;
- else
+ else
tmp = dyn->insts[ninst].pass2choice = 0;
#else
tmp = dyn->insts[ninst].pass2choice;
@@ -2105,7 +2422,6 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
switch(tmp) {
case 3:
SETFLAGS(X_ALL, SF_SET); // Hack to set flags to "dont'care" state
- BARRIER(BARRIER_FULL);
//BARRIER_NEXT(BARRIER_FULL);
if(dyn->last_ip && (addr-dyn->last_ip<0x1000)) {
ADDx_U12(x2, xRIP, addr-dyn->last_ip);
@@ -2114,12 +2430,16 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
}
PUSH1(x2);
MESSAGE(LOG_DUMP, "Native Call to %s (retn=%d)\n", GetNativeName(GetNativeFnc(dyn->insts[ninst].natcall-1)), dyn->insts[ninst].retn);
+ SKIPTEST(x1); // disable test as this hack dos 2 instructions for 1
// calling a native function
sse_purge07cache(dyn, ninst, x3);
- if((box64_log<2 && !cycle_log) && dyn->insts[ninst].natcall)
+ if((box64_log<2 && !cycle_log) && dyn->insts[ninst].natcall) {
tmp=isSimpleWrapper(*(wrapper_t*)(dyn->insts[ninst].natcall+2));
- else
+ } else
tmp=0;
+ if(dyn->insts[ninst].natcall && isRetX87Wrapper(*(wrapper_t*)(dyn->insts[ninst].natcall+2)))
+ // return value will be on the stack, so the stack depth needs to be updated
+ x87_purgecache(dyn, ninst, 0, x3, x1, x4);
if((box64_log<2 && !cycle_log) && dyn->insts[ninst].natcall && tmp) {
//GETIP(ip+3+8+8); // read the 0xCC
call_n(dyn, ninst, *(void**)(dyn->insts[ninst].natcall+2+8), tmp);
@@ -2165,8 +2485,12 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
*need_epilog = 0;
*ok = 0;
}
- TABLE64(x2, addr);
- PUSH1(x2);
+ if(rex.is32bits) {
+ MOV32w(x2, addr);
+ } else {
+ TABLE64(x2, addr);
+ }
+ PUSH1z(x2);
if(box64_dynarec_callret) {
// Push actual return address
if(addr < (dyn->start+dyn->isize)) {
@@ -2179,13 +2503,11 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
LDRx_U12(x4, x4, 0);
}
STPx_S7_preindex(x4, x2, xSP, -16);
+ } else {
+ *ok = 0;
+ *need_epilog = 0;
}
- if(addr+i32==0) { // self modifying code maybe? so use indirect address fetching
- TABLE64(x4, addr-4);
- LDRx_U12(x4, x4, 0);
- jump_to_next(dyn, 0, x4, ninst);
- } else
- jump_to_next(dyn, addr+i32, 0, ninst);
+ jump_to_next(dyn, addr+i32, 0, ninst);
break;
}
break;
@@ -2199,11 +2521,11 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("JMP Ib");
i32 = F8S;
}
- JUMP(addr+i32, 0);
+ JUMP((uintptr_t)getAlternate((void*)(addr+i32)), 0);
if(dyn->insts[ninst].x64.jmp_insts==-1) {
// out of the block
fpu_purgecache(dyn, ninst, 1, x1, x2, x3);
- jump_to_next(dyn, addr+i32, 0, ninst);
+ jump_to_next(dyn, (uintptr_t)getAlternate((void*)(addr+i32)), 0, ninst);
} else {
// inside the block
CacheTransform(dyn, ninst, CHECK_CACHE(), x1, x2, x3);
@@ -2218,10 +2540,36 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
*ok = 0;
break;
+ case 0xEC: /* IN AL, DX */
+ case 0xED: /* IN EAX, DX */
+ case 0xEE: /* OUT DX, AL */
+ case 0xEF: /* OUT DX, EAX */
+ INST_NAME(opcode==0xEC?"IN AL, DX":(opcode==0xED?"IN EAX, DX":(opcode==0xEE?"OUT DX? AL":"OUT DX, EAX")));
+ SETFLAGS(X_ALL, SF_SET); // Hack to set flags in "don't care" state
+ GETIP(ip);
+ STORE_XEMU_CALL(xRIP);
+ CALL(native_priv, -1);
+ LOAD_XEMU_CALL(xRIP);
+ jump_to_epilog(dyn, 0, xRIP, ninst);
+ *need_epilog = 0;
+ *ok = 0;
+ break;
+
case 0xF0:
addr = dynarec64_F0(dyn, addr, ip, ninst, rex, rep, ok, need_epilog);
break;
+ case 0xF4:
+ INST_NAME("HLT");
+ SETFLAGS(X_ALL, SF_SET); // Hack to set flags in "don't care" state
+ GETIP(ip);
+ STORE_XEMU_CALL(xRIP);
+ CALL(native_priv, -1);
+ LOAD_XEMU_CALL(xRIP);
+ jump_to_epilog(dyn, 0, xRIP, ninst);
+ *need_epilog = 0;
+ *ok = 0;
+ break;
case 0xF5:
INST_NAME("CMC");
READFLAGS(X_CF);
@@ -2282,6 +2630,7 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
break;
case 7:
INST_NAME("IDIV Eb");
+ SKIPTEST(x1);
MESSAGE(LOG_DUMP, "Need Optimization\n");
SETFLAGS(X_ALL, SF_SET);
GETEB(x1, 0);
@@ -2299,7 +2648,7 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
GETEDH(x1, 4);
i64 = F32S;
MOV64xw(x2, i64);
- emit_test32(dyn, ninst, rex, ed, x2, x3, x4);
+ emit_test32(dyn, ninst, rex, ed, x2, x3, x4, x5);
break;
case 2:
INST_NAME("NOT Ed");
@@ -2367,9 +2716,9 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MOVw_REG(xRAX, x2);
MOVw_REG(xRDX, x4);
} else {
- if(ninst
- && dyn->insts[ninst-1].x64.addr
- && *(uint8_t*)(dyn->insts[ninst-1].x64.addr)==0x31
+ if(ninst
+ && dyn->insts[ninst-1].x64.addr
+ && *(uint8_t*)(dyn->insts[ninst-1].x64.addr)==0x31
&& *(uint8_t*)(dyn->insts[ninst-1].x64.addr+1)==0xD2) {
SET_DFNONE(x2);
GETED(0);
@@ -2392,6 +2741,7 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
break;
case 7:
INST_NAME("IDIV Ed");
+ SKIPTEST(x1);
SETFLAGS(X_ALL, SF_SET);
if(!rex.w) {
SET_DFNONE(x2)
@@ -2404,7 +2754,7 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MOVw_REG(xRDX, x4);
} else {
if(ninst && dyn->insts
- && dyn->insts[ninst-1].x64.addr
+ && dyn->insts[ninst-1].x64.addr
&& *(uint8_t*)(dyn->insts[ninst-1].x64.addr)==0x48
&& *(uint8_t*)(dyn->insts[ninst-1].x64.addr+1)==0x99) {
SET_DFNONE(x2)
@@ -2417,11 +2767,11 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
//Need to see if RDX==0 and RAX not signed
// or RDX==-1 and RAX signed
CBNZx_MARK2(xRDX);
- TBZ_MARK(xRAX, 31);
+ TBZ_MARK(xRAX, 63);
MARK2;
MVNx_REG(x2, xRDX);
CBNZx_MARK3(x2);
- TBNZ_MARK(xRAX, 31);
+ TBNZ_MARK(xRAX, 63);
MARK3;
if(ed!=x1) {MOVx_REG(x1, ed);}
CALL((void*)idiv64, -1);
@@ -2448,7 +2798,18 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
SET_DFNONE(x1);
ORRx_mask(xFlags, xFlags, 1, 0, 0); // xFlags | 1
break;
-
+ case 0xFA: /* STI */
+ case 0xFB: /* CLI */
+ INST_NAME(opcode==0xFA?"CLI":"STI");
+ SETFLAGS(X_ALL, SF_SET); // Hack to set flags in "don't care" state
+ GETIP(ip);
+ STORE_XEMU_CALL(xRIP);
+ CALL(native_priv, -1);
+ LOAD_XEMU_CALL(xRIP);
+ jump_to_epilog(dyn, 0, xRIP, ninst);
+ *need_epilog = 0;
+ *ok = 0;
+ break;
case 0xFC:
INST_NAME("CLD");
BFCw(xFlags, F_DF, 1);
@@ -2498,7 +2859,7 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
break;
case 2: // CALL Ed
INST_NAME("CALL Ed");
- PASS2IF((box64_dynarec_safeflags>1) ||
+ PASS2IF((box64_dynarec_safeflags>1) ||
((ninst && dyn->insts[ninst-1].x64.set_flags)
|| ((ninst>1) && dyn->insts[ninst-2].x64.set_flags)), 1)
{
@@ -2506,7 +2867,7 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
} else {
SETFLAGS(X_ALL, SF_SET); //Hack to put flag in "don't care" state
}
- GETEDx(0);
+ GETEDz(0);
if(box64_dynarec_callret && box64_dynarec_bigblock>1) {
BARRIER(BARRIER_FULL);
} else {
@@ -2528,22 +2889,41 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
}
STPx_S7_preindex(x4, xRIP, xSP, -16);
}
- PUSH1(xRIP);
+ PUSH1z(xRIP);
jump_to_next(dyn, 0, ed, ninst);
break;
case 4: // JMP Ed
INST_NAME("JMP Ed");
READFLAGS(X_PEND);
BARRIER(BARRIER_FLOAT);
- GETEDx(0);
+ GETEDz(0);
jump_to_next(dyn, 0, ed, ninst);
*need_epilog = 0;
*ok = 0;
break;
+ case 5: // JMP FAR Ed
+ if(MODREG) {
+ DEFAULT;
+ } else {
+ INST_NAME("JMP FAR Ed");
+ READFLAGS(X_PEND);
+ BARRIER(BARRIER_FLOAT);
+ SMREAD()
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, &unscaled, 0, 0, rex, NULL, 0, 0);
+ LDxw(x1, wback, 0);
+ ed = x1;
+ LDH(x3, wback, rex.w?8:4);
+ STW(x3, xEmu, offsetof(x64emu_t, segs[_CS]));
+ STW(xZR, xEmu, offsetof(x64emu_t, segs_serial[_CS]));
+ jump_to_epilog(dyn, 0, ed, ninst);
+ *need_epilog = 0;
+ *ok = 0;
+ }
+ break;
case 6: // Push Ed
INST_NAME("PUSH Ed");
- GETEDx(0);
- PUSH1(ed);
+ GETEDz(0);
+ PUSH1z(ed);
break;
default:
@@ -2554,6 +2934,6 @@ uintptr_t dynarec64_00(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
default:
DEFAULT;
}
-
+
return addr;
}
diff --git a/src/dynarec/arm64/dynarec_arm64_0f.c b/src/dynarec/arm64/dynarec_arm64_0f.c
index 8a51ab7..e4aa365 100755..100644
--- a/src/dynarec/arm64/dynarec_arm64_0f.c
+++ b/src/dynarec/arm64/dynarec_arm64_0f.c
@@ -1,7 +1,6 @@
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
-#include <pthread.h>
#include <errno.h>
#include "debug.h"
@@ -31,8 +30,8 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
uint8_t opcode = F8;
uint8_t nextop, u8;
uint8_t gd, ed;
- uint8_t wback, wb2;
- uint8_t eb1, eb2;
+ uint8_t wback, wb1, wb2;
+ uint8_t eb1, eb2, gb1, gb2;
int32_t i32, i32_;
int cacheupd = 0;
int v0, v1;
@@ -42,9 +41,13 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
uint64_t tmp64u;
int64_t j64;
int64_t fixedaddress;
+ int unscaled;
+ MAYUSE(wb1);
MAYUSE(wb2);
MAYUSE(eb1);
MAYUSE(eb2);
+ MAYUSE(gb1);
+ MAYUSE(gb2);
MAYUSE(q0);
MAYUSE(q1);
MAYUSE(d0);
@@ -65,7 +68,7 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
SETFLAGS(X_ALL, SF_SET); // Hack to set flags in "don't care" state
GETIP(ip);
STORE_XEMU_CALL(xRIP);
- CALL(arm_ud, -1);
+ CALL(native_ud, -1);
LOAD_XEMU_CALL(xRIP);
jump_to_epilog(dyn, 0, xRIP, ninst);
*need_epilog = 0;
@@ -74,6 +77,7 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
case 0x05:
INST_NAME("SYSCALL");
+ NOTEST(x1);
SMEND();
GETIP(addr);
STORE_XEMU_CALL(xRIP);
@@ -94,7 +98,7 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
SETFLAGS(X_ALL, SF_SET); // Hack to set flags in "don't care" state
GETIP(ip);
STORE_XEMU_CALL(xRIP);
- CALL(arm_ud, -1);
+ CALL(native_ud, -1);
LOAD_XEMU_CALL(xRIP);
jump_to_epilog(dyn, 0, xRIP, ninst);
*need_epilog = 0;
@@ -106,7 +110,7 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
SETFLAGS(X_ALL, SF_SET); // Hack to set flags in "don't care" state
GETIP(ip);
STORE_XEMU_CALL(xRIP);
- CALL(arm_ud, -1);
+ CALL(native_ud, -1);
LOAD_XEMU_CALL(xRIP);
jump_to_epilog(dyn, 0, xRIP, ninst);
*need_epilog = 0;
@@ -118,7 +122,7 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
switch((nextop>>3)&7) {
case 1:
INST_NAME("PREFETCHW");
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff, 7, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0xfff, 7, rex, NULL, 0, 0);
PST_L1_STREAM_U12(ed, fixedaddress);
break;
default: //???
@@ -138,8 +142,8 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
} else {
v0 = sse_get_reg_empty(dyn, ninst, x1, gd);
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<4, 15, rex, NULL, 0, 0);
- VLDR128_U12(v0, ed, fixedaddress); // no alignment issue with ARMv8 NEON :)
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<4, 15, rex, NULL, 0, 0);
+ VLD128(v0, ed, fixedaddress); // no alignment issue with ARMv8 NEON :)
}
break;
case 0x11:
@@ -152,8 +156,8 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
v1 = sse_get_reg_empty(dyn, ninst, x1, ed);
VMOVQ(v1, v0);
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<4, 15, rex, NULL, 0, 0);
- VSTR128_U12(v0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<4, 15, rex, NULL, 0, 0);
+ VST128(v0, ed, fixedaddress);
SMWRITE2();
}
break;
@@ -168,7 +172,7 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("MOVLPS Gx,Ex");
GETGX(v0, 1);
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
VLD1_64(v0, 0, ed);
}
break;
@@ -180,7 +184,7 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
v1 = sse_get_reg(dyn, ninst, x1, (nextop&7)+(rex.b<<3), 1);
VMOVeD(v1, 0, v0, 0);
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
VST1_64(v0, 0, ed); // better to use VST1 than VSTR_64, to avoid NEON->VFPU transfert I assume
SMWRITE2();
}
@@ -212,7 +216,7 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("MOVHPS Gx,Ex");
SMREAD();
GETGX(v0, 1);
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
VLD1_64(v0, 1, ed);
}
break;
@@ -224,7 +228,7 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
v1 = sse_get_reg(dyn, ninst, x1, (nextop&7)+(rex.b<<3), 1);
VMOVeD(v1, 0, v0, 1);
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
VST1_64(v0, 1, ed);
SMWRITE2();
}
@@ -237,22 +241,22 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
switch((nextop>>3)&7) {
case 0:
INST_NAME("PREFETCHh Ed");
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff, 7, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0xfff, 7, rex, NULL, 0, 0);
PLD_L1_STREAM_U12(ed, fixedaddress);
break;
case 1:
INST_NAME("PREFETCHh Ed");
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff, 7, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0xfff, 7, rex, NULL, 0, 0);
PLD_L1_KEEP_U12(ed, fixedaddress);
break;
case 2:
INST_NAME("PREFETCHh Ed");
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff, 7, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0xfff, 7, rex, NULL, 0, 0);
PLD_L2_KEEP_U12(ed, fixedaddress);
break;
case 3:
INST_NAME("PREFETCHh Ed");
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff, 7, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0xfff, 7, rex, NULL, 0, 0);
PLD_L3_KEEP_U12(ed, fixedaddress);
break;
default:
@@ -279,8 +283,8 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
} else {
v0 = sse_get_reg_empty(dyn, ninst, x1, gd);
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<4, 15, rex, NULL, 0, 0);
- VLDR128_U12(v0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<4, 15, rex, NULL, 0, 0);
+ VLD128(v0, ed, fixedaddress);
}
break;
case 0x29:
@@ -293,8 +297,8 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
v1 = sse_get_reg_empty(dyn, ninst, x1, ed);
VMOVQ(v1, v0);
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<4, 15, rex, NULL, 0, 0);
- VSTR128_U12(v0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<4, 15, rex, NULL, 0, 0);
+ VST128(v0, ed, fixedaddress);
SMWRITE2();
}
break;
@@ -309,8 +313,8 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
v1 = sse_get_reg_empty(dyn, ninst, x1, ed);
VMOVQ(v1, v0);
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<4, 15, rex, NULL, 0, 0);
- VSTR128_U12(v0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<4, 15, rex, NULL, 0, 0);
+ VST128(v0, ed, fixedaddress);
}
break;
@@ -321,24 +325,18 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
SETFLAGS(X_ALL, SF_SET);
nextop = F8;
GETGX(v0, 0);
- if(MODREG) {
- s0 = sse_get_reg(dyn, ninst, x1, (nextop&7) + (rex.b<<3), 0);
- } else {
- s0 = fpu_get_scratch(dyn);
- SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<2, 3, rex, NULL, 0, 0);
- VLDR32_U12(s0, ed, fixedaddress);
- }
+ GETEXSS(s0, 0, 0);
FCMPS(v0, s0);
FCOMI(x1, x2);
break;
case 0x31:
INST_NAME("RDTSC");
+ NOTEST(x1);
MESSAGE(LOG_DUMP, "Need Optimization\n");
- CALL(ReadTSC, xRAX); // will return the u64 in xEAX
- LSRx(xRDX, xRAX, 32);
- MOVw_REG(xRAX, xRAX); // wipe upper part
+ CALL(ReadTSC, x3); // will return the u64 in x3
+ LSRx(xRDX, x3, 32);
+ MOVw_REG(xRAX, x3); // wipe upper part
break;
case 0x38:
@@ -386,8 +384,8 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
REVxw(gd, xRAX+(nextop&7)+(rex.b<<3));
} else {
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, 0);
- LDRxw_U12(gd, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, 0);
+ LDxw(gd, ed, fixedaddress);
REVxw(gd, gd);
}
break;
@@ -398,9 +396,9 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
if(MODREG) { // reg <= reg
REVxw(xRAX+(nextop&7)+(rex.b<<3), gd);
} else { // mem <= reg
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, 0);
REVxw(x1, gd);
- STRxw_U12(x1, ed, fixedaddress);
+ STxw(x1, ed, fixedaddress);
SMWRITE2();
}
break;
@@ -420,7 +418,7 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
GETEM(q1, 1);
u8 = F8;
if(u8>15) {
- VEOR(q0, q0, q0);
+ VEOR(q0, q0, q0);
} else if(u8>7) {
d0 = fpu_get_scratch(dyn);
VEOR(d0, d0, d0);
@@ -443,9 +441,9 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
ed = xRAX+(nextop&7)+(rex.b<<3); \
CSELxw(gd, ed, gd, YES); \
} else { \
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, 0); \
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, 0); \
Bcond(NO, +8); \
- LDRxw_U12(gd, ed, fixedaddress); \
+ LDxw(gd, ed, fixedaddress); \
if(!rex.w) {MOVw_REG(gd, gd);} \
}
@@ -472,7 +470,7 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
} else {
// EX is memory
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, (0xfff<<3)-8, 7, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, NULL, (0xfff<<3)-8, 7, rex, NULL, 0, 0);
LDRx_U12(x1, ed, fixedaddress+0);
LSRx(x1, x1, 31);
BFIx(gd, x1, 0, 1);
@@ -495,13 +493,14 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
case 0x52:
INST_NAME("RSQRTPS Gx, Ex");
nextop = F8;
+ SKIPTEST(x1);
GETEX(q0, 0, 0);
GETGX_empty(q1);
v0 = fpu_get_scratch(dyn);
// more precise
if(q1==q0)
v1 = fpu_get_scratch(dyn);
- else
+ else
v1 = q1;
VFRSQRTEQS(v0, q0);
VFMULQS(v1, v0, q0);
@@ -511,6 +510,7 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
case 0x53:
INST_NAME("RCPPS Gx, Ex");
nextop = F8;
+ SKIPTEST(x1);
GETEX(q0, 0, 0);
GETGX_empty(q1);
if(q0 == q1)
@@ -597,6 +597,15 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
nextop = F8;
GETGX(v0, 1);
GETEX(v1, 0, 0);
+ // FMIN/FMAX wll not copy the value if v0[x] is NaN
+ // but x86 will copy if either v0[x] or v1[x] is NaN, so lets force a copy if source is NaN
+ if(!box64_dynarec_fastnan && v0!=v1) {
+ q0 = fpu_get_scratch(dyn);
+ VFCMEQQS(q0, v0, v0); // 0 is NaN, 1 is not NaN, so MASK for NaN
+ VANDQ(v0, v0, q0);
+ VBICQ(q0, v1, q0);
+ VORRQ(v0, v0, q0);
+ }
VFMINQS(v0, v0, v1);
break;
case 0x5E:
@@ -611,6 +620,15 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
nextop = F8;
GETGX(v0, 1);
GETEX(v1, 0, 0);
+ // FMIN/FMAX wll not copy the value if v0[x] is NaN
+ // but x86 will copy if either v0[x] or v1[x] is NaN, so lets force a copy if source is NaN
+ if(!box64_dynarec_fastnan && v0!=v1) {
+ q0 = fpu_get_scratch(dyn);
+ VFCMEQQS(q0, v0, v0); // 0 is NaN, 1 is not NaN, so MASK for NaN
+ VANDQ(v0, v0, q0);
+ VBICQ(q0, v1, q0);
+ VORRQ(v0, v0, q0);
+ }
VFMAXQS(v0, v0, v1);
break;
case 0x60:
@@ -675,7 +693,7 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
v1 = mmx_get_reg(dyn, ninst, x1, x2, x3, (nextop&7));
VMOVeD(q0, 1, v1, 0);
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
VLD1_64(q0, 1, ed);
}
SQXTUN_8(v0, q0);
@@ -711,7 +729,7 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
GETEM(v1, 0);
VMOVeD(q0, 1, v1, 0);
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
VLD1_64(q0, 1, ed);
}
SQXTN_16(v0, q0);
@@ -731,12 +749,11 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
FMOVSw(v0, ed);
}
} else {
- v0 = mmx_get_reg_empty(dyn, ninst, x1, x2, x3, gd);
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, 0);
if(rex.w) {
- VLDR64_U12(v0, ed, fixedaddress);
+ VLD64(v0, ed, fixedaddress);
} else {
- VLDR32_U12(v0, ed, fixedaddress);
+ VLD32(v0, ed, fixedaddress);
}
}
break;
@@ -750,8 +767,8 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
VMOVeD(v0, 0, v1, 0);
} else {
v0 = mmx_get_reg_empty(dyn, ninst, x1, x2, x3, gd);
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
- VLDR64_U12(v0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
+ VLD64(v0, ed, fixedaddress);
}
break;
case 0x70:
@@ -818,7 +835,7 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
}
} else {
v0 = mmx_get_reg_empty(dyn, ninst, x1, x2, x3, gd);
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 1);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 1);
u8 = F8;
if (u8) {
i32 = -1;
@@ -997,11 +1014,11 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MOVxw_REG(ed, ed);
}
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, 0);
if(rex.w) {
- VSTR64_U12(v0, ed, fixedaddress);
+ VST64(v0, ed, fixedaddress);
} else {
- VSTR32_U12(v0, ed, fixedaddress);
+ VST32(v0, ed, fixedaddress);
}
SMWRITE2();
}
@@ -1014,8 +1031,8 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
v1 = mmx_get_reg_empty(dyn, ninst, x1, x2, x3, nextop&7);
VMOV(v1, v0);
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
- VSTR64_U12(v0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
+ VST64(v0, ed, fixedaddress);
SMWRITE2();
}
break;
@@ -1065,16 +1082,17 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
} \
BFIx(eb1, x3, eb2, 8); \
} else { \
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff, 0, rex, NULL, 0, 0); \
- STRB_U12(x3, ed, fixedaddress); \
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff, 0, rex, NULL, 0, 0); \
+ STB(x3, ed, fixedaddress); \
SMWRITE(); \
}
GOCOND(0x90, "SET", "Eb");
#undef GO
-
+
case 0xA2:
INST_NAME("CPUID");
+ NOTEST(x1);
MOVx_REG(x1, xRAX);
CALL_(my_cpuid, -1, 0);
break;
@@ -1088,10 +1106,10 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
ed = xRAX+(nextop&7)+(rex.b<<3);
} else {
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, 0);
- ASRxw(x1, gd, 5+rex.w); // r1 = (gd>>5)
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, 0);
+ ASRx(x1, gd, 5+rex.w); // r1 = (gd>>5)
ADDx_REG_LSL(x3, wback, x1, 2+rex.w); //(&ed)+=r1*4;
- LDRxw_U12(x1, x3, fixedaddress);
+ LDxw(x1, x3, fixedaddress);
ed = x1;
}
if(rex.w) {
@@ -1136,10 +1154,10 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
wback = 0;
} else {
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, 0);
- ASRxw(x1, gd, 5+rex.w); // r1 = (gd>>5)
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, 0);
+ ASRx(x1, gd, 5+rex.w); // r1 = (gd>>5)
ADDx_REG_LSL(x3, wback, x1, 2+rex.w); //(&ed)+=r1*4;
- LDRxw_U12(x1, x3, fixedaddress);
+ LDxw(x1, x3, fixedaddress);
ed = x1;
wback = x3;
}
@@ -1209,7 +1227,7 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
if(MODREG) {
DEFAULT;
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
if(ed!=x1) {MOVx_REG(x1, ed);}
CALL(rex.w?((void*)fpu_fxsave64):((void*)fpu_fxsave32), -1);
}
@@ -1221,12 +1239,12 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
if(MODREG) {
DEFAULT;
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
if(ed!=x1) {MOVx_REG(x1, ed);}
CALL(rex.w?((void*)fpu_fxrstor64):((void*)fpu_fxrstor32), -1);
}
break;
- case 2:
+ case 2:
INST_NAME("LDMXCSR Md");
GETED(0);
STRw_U12(ed, xEmu, offsetof(x64emu_t, mxcsr));
@@ -1241,18 +1259,18 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
break;
case 3:
INST_NAME("STMXCSR Md");
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<2, 3, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, 0);
LDRw_U12(x4, xEmu, offsetof(x64emu_t, mxcsr));
- STRw_U12(x4, ed, fixedaddress);
+ STW(x4, ed, fixedaddress);
break;
case 7:
INST_NAME("CLFLUSH Ed");
MESSAGE(LOG_DUMP, "Need Optimization?\n");
- GETED(0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
if(ed!=x1) {
MOVx_REG(x1, ed);
}
- CALL_(arm_clflush, -1, 0);
+ CALL_(native_clflush, -1, 0);
break;
default:
DEFAULT;
@@ -1302,10 +1320,10 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
wback = 0;
} else {
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, 0);
- ASRxw(x1, gd, 5+rex.w); // r1 = (gd>>5)
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, 0);
+ ASRx(x1, gd, 5+rex.w); // r1 = (gd>>5)
ADDx_REG_LSL(x3, wback, x1, 2+rex.w); //(&ed)+=r1*4;
- LDRxw_U12(x1, x3, fixedaddress);
+ LDxw(x1, x3, fixedaddress);
ed = x1;
wback = x3;
}
@@ -1316,15 +1334,14 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
}
LSRxw_REG(x4, ed, x2);
if(rex.w) {
- ANDSx_mask(x4, x4, 1, 0, 0); //mask=1
+ ANDx_mask(x4, x4, 1, 0, 0); //mask=1
} else {
- ANDSw_mask(x4, x4, 0, 0); //mask=1
+ ANDw_mask(x4, x4, 0, 0); //mask=1
}
BFIw(xFlags, x4, F_CF, 1);
MOV32w(x4, 1);
LSLxw_REG(x4, x4, x2);
- EORxw_REG(x4, ed, x4);
- CSELxw(ed, ed, x4, cEQ);
+ BICxw_REG(ed, ed, x4);
if(wback) {
STRxw_U12(ed, wback, fixedaddress);
SMWRITE();
@@ -1347,8 +1364,8 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
UBFXxw(gd, eb1, eb2*8, 8);
} else {
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff, 0, rex, NULL, 0, 0);
- LDRB_U12(gd, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff, 0, rex, NULL, 0, 0);
+ LDB(gd, ed, fixedaddress);
}
break;
case 0xB7:
@@ -1360,8 +1377,8 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
UBFXxw(gd, ed, 0, 16);
} else {
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<1, 1, rex, NULL, 0, 0);
- LDRH_U12(gd, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<1, 1, rex, NULL, 0, 0);
+ LDH(gd, ed, fixedaddress);
}
break;
@@ -1377,8 +1394,8 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
ed = xRAX+(nextop&7)+(rex.b<<3);
} else {
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, 1);
- LDRxw_U12(x1, wback, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, 1);
+ LDxw(x1, wback, fixedaddress);
ed = x1;
}
u8 = F8;
@@ -1394,8 +1411,8 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
wback = 0;
} else {
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, 1);
- LDRxw_U12(x1, wback, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, 1);
+ LDxw(x1, wback, fixedaddress);
ed = x1;
}
u8 = F8;
@@ -1403,9 +1420,9 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
BFXILxw(xFlags, ed, u8, 1); // inject 1 bit from u8 to F_CF (i.e. pos 0)
TBNZ_MARK3(xFlags, 0); // bit already set, jump to next instruction
MOV32w(x4, 1);
- EORxw_REG_LSL(ed, ed, x4, u8);
+ ORRxw_REG_LSL(ed, ed, x4, u8);
if(wback) {
- STRxw_U12(ed, wback, fixedaddress);
+ STxw(ed, wback, fixedaddress);
SMWRITE();
}
MARK3;
@@ -1419,8 +1436,8 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
wback = 0;
} else {
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, 1);
- LDRxw_U12(x1, wback, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, 1);
+ LDxw(x1, wback, fixedaddress);
ed = x1;
}
u8 = F8;
@@ -1428,9 +1445,9 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
BFXILxw(xFlags, ed, u8, 1); // inject 1 bit from u8 to F_CF (i.e. pos 0)
TBZ_MARK3(xFlags, 0); // bit already clear, jump to next instruction
MOV32w(x4, 1);
- EORxw_REG_LSL(ed, ed, x4, u8);
+ BICxw_REG_LSL(ed, ed, x4, u8);
if(wback) {
- STRxw_U12(ed, wback, fixedaddress);
+ STxw(ed, wback, fixedaddress);
SMWRITE();
}
MARK3;
@@ -1444,8 +1461,8 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
wback = 0;
} else {
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, 1);
- LDRxw_U12(x1, wback, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, 1);
+ LDxw(x1, wback, fixedaddress);
ed = x1;
}
u8 = F8;
@@ -1454,7 +1471,7 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MOV32w(x4, 1);
EORxw_REG_LSL(ed, ed, x4, u8);
if(wback) {
- STRxw_U12(ed, wback, fixedaddress);
+ STxw(ed, wback, fixedaddress);
SMWRITE();
}
MARK3;
@@ -1474,10 +1491,10 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
wback = 0;
} else {
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, 0);
- ASRxw(x1, gd, 5+rex.w); // r1 = (gd>>5)
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, 0);
+ ASRx(x1, gd, 5+rex.w); // r1 = (gd>>5)
ADDx_REG_LSL(x3, wback, x1, 2+rex.w); //(&ed)+=r1*4;
- LDRxw_U12(x1, x3, fixedaddress);
+ LDxw(x1, x3, fixedaddress);
ed = x1;
wback = x3;
}
@@ -1497,7 +1514,7 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
LSLxw_REG(x4, x4, x2);
EORxw_REG(ed, ed, x4);
if(wback) {
- STRxw_U12(ed, wback, fixedaddress);
+ STxw(ed, wback, fixedaddress);
SMWRITE();
}
break;
@@ -1548,8 +1565,8 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
SBFXxw(gd, wback, wb2, 8);
} else {
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x3, &fixedaddress, 0xfff, 0, rex, NULL, 0, 0);
- LDRSBxw_U12(gd, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x3, &fixedaddress, &unscaled, 0xfff, 0, rex, NULL, 0, 0);
+ LDSBxw(gd, ed, fixedaddress);
}
break;
case 0xBF:
@@ -1561,11 +1578,33 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
SXTHxw(gd, ed);
} else {
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x3, &fixedaddress, 0xfff<<1, 1, rex, NULL, 0, 0);
- LDRSHxw_U12(gd, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x3, &fixedaddress, &unscaled, 0xfff<<1, 1, rex, NULL, 0, 0);
+ LDSHxw(gd, ed, fixedaddress);
}
break;
-
+ case 0xC0:
+ INST_NAME("XADD Gb, Eb");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGB(x1);
+ GETEB(x2, 0);
+ gd = x2; ed = x1; // swap gd/ed
+ emit_add8(dyn, ninst, x1, x2, x4, x5);
+ GBBACK; // gb gets x2 (old ed)
+ EBBACK; // eb gets x1 (sum)
+ break;
+ case 0xC1:
+ INST_NAME("XADD Gd, Ed");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED(0);
+ MOVxw_REG(x3, ed);
+ MOVxw_REG(ed, gd);
+ MOVxw_REG(gd, x3);
+ emit_add32(dyn, ninst, rex, ed, gd, x4, x5);
+ WBACK;
+ break;
case 0xC2:
INST_NAME("CMPPS Gx, Ex, Ib");
nextop = F8;
@@ -1577,21 +1616,21 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
case 0: VFCMEQQS(v0, v0, v1); break; // Equal
case 1: VFCMGTQS(v0, v1, v0); break; // Less than
case 2: VFCMGEQS(v0, v1, v0); break; // Less or equal
- case 3: VFCMEQQS(v0, v0, v0);
+ case 3: VFCMEQQS(v0, v0, v0);
if(v0!=v1) {
- q0 = fpu_get_scratch(dyn);
- VFCMEQQS(q0, v1, v1);
+ q0 = fpu_get_scratch(dyn);
+ VFCMEQQS(q0, v1, v1);
VANDQ(v0, v0, q0);
}
- VMVNQ(v0, v0);
+ VMVNQ(v0, v0);
break; // NaN (NaN is not equal to himself)
case 4: VFCMEQQS(v0, v0, v1); VMVNQ(v0, v0); break; // Not Equal (or unordered on ARM, not on X86...)
case 5: VFCMGTQS(v0, v1, v0); VMVNQ(v0, v0); break; // Greater or equal or unordered
case 6: VFCMGEQS(v0, v1, v0); VMVNQ(v0, v0); break; // Greater or unordered
- case 7: VFCMEQQS(v0, v0, v0);
+ case 7: VFCMEQQS(v0, v0, v0);
if(v0!=v1) {
- q0 = fpu_get_scratch(dyn);
- VFCMEQQS(q0, v1, v1);
+ q0 = fpu_get_scratch(dyn);
+ VFCMEQQS(q0, v1, v1);
VANDQ(v0, v0, q0);
}
break; // not NaN
@@ -1604,8 +1643,8 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
if(MODREG) { // reg <= reg
MOVxw_REG(xRAX+(nextop&7)+(rex.b<<3), gd);
} else { // mem <= reg
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, 0);
- STRxw_U12(gd, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, 0);
+ STxw(gd, ed, fixedaddress);
}
break;
case 0xC4:
@@ -1617,7 +1656,7 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
ed = xRAX+(nextop&7)+(rex.b<<3);
VMOVQHfrom(v0, u8, ed);
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0, 0, rex, NULL, 0, 1);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 1);
u8 = (F8)&3;
VLD1_16(v0, u8, wback);
}
@@ -1631,7 +1670,7 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
u8 = (F8)&3;
VMOVHto(gd, v0, u8);
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0, 0, rex, NULL, 0, 1);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 1);
u8 = (F8)&3;
LDRH_U12(gd, wback, u8*2);
}
@@ -1641,7 +1680,7 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
nextop = F8;
GETGX(v0, 1);
if(!MODREG) {
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 1);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 1);
v1 = -1; // to avoid a warning
} else
v1 = sse_get_reg(dyn, ninst, x1, (nextop&7)+(rex.b<<3), 0);
@@ -1686,7 +1725,56 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
gd = xRAX+(opcode&7)+(rex.b<<3);
REVxw(gd, gd);
break;
-
+ case 0xD1:
+ INST_NAME("PSRLW Gm, Em");
+ nextop = F8;
+ GETGM(d0);
+ GETEM(d1, 0);
+ if(MODREG) {
+ q0 = fpu_get_scratch(dyn);
+ }
+ else {
+ q0 = d1;
+ }
+ q1 = fpu_get_scratch(dyn);
+ VMOVBto(x1, d1, 0);
+ MOVZw(x2, 16);
+ SUBSw_REG(x2, x2, x1);
+ B_MARK(cGT);
+ VMOVQDfrom(d0, 0, xZR);
+ B_NEXT_nocond;
+ MARK;
+ VDUPQS(q1, x2);
+ UXTL_16(q0, d0);
+ USHLQ_32(q0, q0, q1);
+ VUZP2Q_16(q0, q0, q0);
+ VMOVeD(d0, 0, q0, 0);
+ break;
+ case 0xD2:
+ INST_NAME("PSRLD Gm, Em");
+ nextop = F8;
+ GETGM(d0);
+ GETEM(d1, 0);
+ if(MODREG) {
+ q0 = fpu_get_scratch(dyn);
+ }
+ else {
+ q0 = d1;
+ }
+ q1 = fpu_get_scratch(dyn);
+ VMOVBto(x1, d1, 0);
+ MOVZw(x2, 32);
+ SUBSw_REG(x2, x2, x1);
+ B_MARK(cGT);
+ VMOVQDfrom(d0, 0, xZR);
+ B_NEXT_nocond;
+ MARK;
+ VDUPQD(q1, x2);
+ UXTL_32(q0, d0);
+ USHLQ_64(q0, q0, q1);
+ VUZP2Q_32(q0, q0, q0);
+ VMOVeD(d0, 0, q0, 0);
+ break;
case 0xD3:
INST_NAME("PSRLQ Gm,Em");
nextop = F8;
@@ -1699,7 +1787,13 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
NEG_64(q0, d1);
USHL_R_64(d0, d0, q0);
break;
-
+ case 0xD4:
+ INST_NAME("PADDQ Gm,Em");
+ nextop = F8;
+ GETGM(v0);
+ GETEM(q0, 0);
+ ADD_64(v0, v0, q0);
+ break;
case 0xD5:
INST_NAME("PMULLW Gm, Em");
nextop = F8;
@@ -1723,7 +1817,7 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
USHL_8(q1, q1, v0); // shift
UADDLV_8(q1, q1); // accumalte
VMOVBto(gd, q1, 0);
- break;
+ break;
case 0xD8:
INST_NAME("PSUBUSB Gm, Em");
nextop = F8;
@@ -1814,8 +1908,8 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
DEFAULT;
} else {
v0 = mmx_get_reg(dyn, ninst, x1, x2, x3, gd);
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
- VSTR64_U12(v0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
+ VST64(v0, ed, fixedaddress);
}
break;
case 0xE8:
@@ -1832,7 +1926,13 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
GETEM(q0, 0);
SQSUB_16(v0, v0, q0);
break;
-
+ case 0xEA:
+ INST_NAME("PMINSW Gx,Ex");
+ nextop = F8;
+ GETGM(v0);
+ GETEM(q0, 0);
+ SMIN_16(v0, v0, q0);
+ break;
case 0xEB:
INST_NAME("POR Gm, Em");
nextop = F8;
@@ -1854,7 +1954,13 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
GETEM(d1, 0);
SQADD_16(d0, d0, d1);
break;
-
+ case 0xEE:
+ INST_NAME("PMAXSW Gx,Ex");
+ nextop = F8;
+ GETGM(v0);
+ GETEM(q0, 0);
+ SMAX_16(v0, v0, q0);
+ break;
case 0xEF:
INST_NAME("PXOR Gm,Em");
nextop = F8;
@@ -1881,7 +1987,13 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
SQXTN_32(v0, v0); // 2*q1 in 32bits now
SSHL_32(d0, d0, v0);
break;
-
+ case 0xF4:
+ INST_NAME("PMULUDQ Gx,Ex");
+ nextop = F8;
+ GETGX(v0, 1);
+ GETEX(v1, 0, 0);
+ VUMULL_32(v0, v0, v1);
+ break;
case 0xF5:
INST_NAME("PMADDWD Gm, Em");
nextop = F8;
@@ -1934,6 +2046,13 @@ uintptr_t dynarec64_0F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
GETEM(v1, 0);
VADD_8(v0, v0, v1);
break;
+ case 0xFB:
+ INST_NAME("PSUBQ Gm, Em");
+ nextop = F8;
+ GETGM(v0);
+ GETEM(v1, 0);
+ SUB_64(v0, v0, v1);
+ break;
case 0xFD:
INST_NAME("PADDW Gm, Em");
nextop = F8;
diff --git a/src/dynarec/arm64/dynarec_arm64_64.c b/src/dynarec/arm64/dynarec_arm64_64.c
index c6dfb44..d88f3b6 100644
--- a/src/dynarec/arm64/dynarec_arm64_64.c
+++ b/src/dynarec/arm64/dynarec_arm64_64.c
@@ -1,7 +1,6 @@
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
-#include <pthread.h>
#include <errno.h>
#include "debug.h"
@@ -23,8 +22,6 @@
#include "dynarec_arm64_helper.h"
#include "dynarec_arm64_functions.h"
-#define GETG gd = ((nextop&0x38)>>3)+(rex.r<<3)
-
uintptr_t dynarec64_64(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int seg, int* ok, int* need_epilog)
{
(void)ip; (void)rep; (void)need_epilog;
@@ -35,10 +32,12 @@ uintptr_t dynarec64_64(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
uint8_t gd, ed, eb1, eb2, gb1, gb2;
uint8_t wback, wb1, wb2, wb;
int64_t i64, j64;
+ uint64_t u64;
int v0, v1;
int q0;
int d0;
int64_t fixedaddress;
+ int unscaled;
MAYUSE(eb1);
MAYUSE(eb2);
MAYUSE(wb1);
@@ -55,12 +54,7 @@ uintptr_t dynarec64_64(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
rep = opcode-0xF1;
opcode = F8;
}
- // REX prefix before the F0 are ignored
- rex.rex = 0;
- while(opcode>=0x40 && opcode<=0x4f) {
- rex.rex = opcode;
- opcode = F8;
- }
+ GETREX();
switch(opcode) {
@@ -93,9 +87,9 @@ uintptr_t dynarec64_64(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
grab_segdata(dyn, addr, ninst, x4, seg);
v0 = sse_get_reg_empty(dyn, ninst, x1, gd);
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
ADDx_REG(x4, x4, ed);
- VLDR64_U12(v0, x4, fixedaddress); // upper part reseted
+ VLD64(v0, x4, fixedaddress); // upper part reseted
}
break;
case 2:
@@ -111,9 +105,9 @@ uintptr_t dynarec64_64(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
grab_segdata(dyn, addr, ninst, x4, seg);
v0 = sse_get_reg_empty(dyn, ninst, x1, gd);
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<2, 3, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, 0);
ADDx_REG(x4, x4, ed);
- VLDR32_U12(v0, x4, fixedaddress);
+ VLD32(v0, x4, fixedaddress);
}
break;
default:
@@ -133,9 +127,9 @@ uintptr_t dynarec64_64(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
VMOVQ(v1, v0);
} else {
grab_segdata(dyn, addr, ninst, x4, seg);
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<4, 15, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<4, 15, rex, NULL, 0, 0);
ADDx_REG(x4, x4, ed);
- VSTR128_U12(v0, x4, fixedaddress);
+ VST128(v0, x4, fixedaddress);
SMWRITE2();
}
break;
@@ -150,9 +144,9 @@ uintptr_t dynarec64_64(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
VMOVeD(d0, 0, v0, 0);
} else {
grab_segdata(dyn, addr, ninst, x4, seg);
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
ADDx_REG(x4, x4, ed);
- VSTR64_U12(v0, x4, fixedaddress);
+ VST64(v0, x4, fixedaddress);
SMWRITE2();
}
break;
@@ -167,9 +161,9 @@ uintptr_t dynarec64_64(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
VMOVeS(q0, 0, v0, 0);
} else {
grab_segdata(dyn, addr, ninst, x4, seg);
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<2, 3, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, 0);
ADDx_REG(x4, x4, ed);
- VSTR32_U12(v0, x4, fixedaddress);
+ VST32(v0, x4, fixedaddress);
SMWRITE2();
}
break;
@@ -191,9 +185,9 @@ uintptr_t dynarec64_64(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
} else {
grab_segdata(dyn, addr, ninst, x4, seg);
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<4, 15, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<4, 15, rex, NULL, 0, 0);
ADDx_REG(x4, x4, ed);
- VLDR128_U12(v0, ed, fixedaddress);
+ VLD128(v0, ed, fixedaddress);
}
break;
default:
@@ -260,7 +254,7 @@ uintptr_t dynarec64_64(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
UBFXxw(gd, eb1, eb2*8, 8);
} else {
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
LDRB_REG(gd, ed, x4);
}
break;
@@ -293,7 +287,7 @@ uintptr_t dynarec64_64(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
GETEDO(x4, 0);
emit_xor32(dyn, ninst, rex, gd, ed, x3, x4);
break;
-
+
case 0x39:
INST_NAME("CMP Seg:Ed, Gd");
SETFLAGS(X_ALL, SF_SET_PENDING);
@@ -315,26 +309,31 @@ uintptr_t dynarec64_64(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
break;
case 0x63:
- INST_NAME("MOVSXD Gd, Ed");
- nextop = F8;
- GETGD;
- if(rex.w) {
- if(MODREG) { // reg <= reg
- SXTWx(gd, xRAX+(nextop&7)+(rex.b<<3));
- } else { // mem <= reg
- grab_segdata(dyn, addr, ninst, x4, seg);
- SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0, 0, rex, NULL, 0, 0);
- LDRSW_REG(gd, ed, x4);
- }
+ if(rex.is32bits) {
+ // ARPL here
+ DEFAULT;
} else {
- if(MODREG) { // reg <= reg
- MOVw_REG(gd, xRAX+(nextop&7)+(rex.b<<3));
- } else { // mem <= reg
- grab_segdata(dyn, addr, ninst, x4, seg);
- SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0, 0, rex, NULL, 0, 0);
- LDRw_REG(gd, ed, x4);
+ INST_NAME("MOVSXD Gd, Ed");
+ nextop = F8;
+ GETGD;
+ if(rex.w) {
+ if(MODREG) { // reg <= reg
+ SXTWx(gd, xRAX+(nextop&7)+(rex.b<<3));
+ } else { // mem <= reg
+ grab_segdata(dyn, addr, ninst, x4, seg);
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
+ LDRSW_REG(gd, ed, x4);
+ }
+ } else {
+ if(MODREG) { // reg <= reg
+ MOVw_REG(gd, xRAX+(nextop&7)+(rex.b<<3));
+ } else { // mem <= reg
+ grab_segdata(dyn, addr, ninst, x4, seg);
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
+ LDRw_REG(gd, ed, x4);
+ }
}
}
break;
@@ -535,7 +534,7 @@ uintptr_t dynarec64_64(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
} else {
grab_segdata(dyn, addr, ninst, x4, seg);
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
LDRB_REG(x4, wback, x4);
ed = x4;
}
@@ -549,7 +548,7 @@ uintptr_t dynarec64_64(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
if(MODREG) { // reg <= reg
MOVxw_REG(xRAX+(nextop&7)+(rex.b<<3), gd);
} else { // mem <= reg
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
STRxw_REG(gd, ed, x4);
SMWRITE2();
}
@@ -564,11 +563,71 @@ uintptr_t dynarec64_64(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MOVxw_REG(gd, xRAX+(nextop&7)+(rex.b<<3));
} else { // mem <= reg
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
LDRxw_REG(gd, ed, x4);
}
break;
+ case 0x8D:
+ INST_NAME("LEA Gd, Ed");
+ nextop=F8;
+ GETGD;
+ if(MODREG) { // reg <= reg? that's an invalid operation
+ DEFAULT;
+ } else { // mem <= reg
+ addr = geted(dyn, addr, ninst, nextop, &ed, gd, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
+ if(gd!=ed) { // it's sometimes used as a 3 bytes NOP
+ MOVxw_REG(gd, ed);
+ }
+ else if(!rex.w && !rex.is32bits) {
+ MOVw_REG(gd, gd); //truncate the higher 32bits as asked
+ }
+ }
+ break;
+
+ case 0x8F:
+ INST_NAME("POP FS:Ed");
+ grab_segdata(dyn, addr, ninst, x4, seg);
+ nextop = F8;
+ if(MODREG) {
+ POP1z(xRAX+(nextop&7)+(rex.b<<3));
+ } else {
+ POP1z(x2); // so this can handle POP [ESP] and maybe some variant too
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0, 0, rex, NULL, 0, 0);
+ if(ed==xRSP) {
+ STRz_REG(x2, ed, x4);
+ } else {
+ // complicated to just allow a segfault that can be recovered correctly
+ SUBz_U12(xRSP, xRSP, rex.is32bits?4:8);
+ STRz_REG(x2, ed, x4);
+ ADDz_U12(xRSP, xRSP, rex.is32bits?4:8);
+ }
+ }
+ break;
+
+ case 0xA1:
+ INST_NAME("MOV EAX,FS:Od");
+ grab_segdata(dyn, addr, ninst, x4, seg);
+ if(rex.is32bits)
+ u64 = F32;
+ else
+ u64 = F64;
+ MOV64z(x1, u64);
+ LDRxw_REG(xRAX, x1, x4);
+ break;
+
+ case 0xA3:
+ INST_NAME("MOV FS:Od,EAX");
+ grab_segdata(dyn, addr, ninst, x4, seg);
+ if(rex.is32bits)
+ u64 = F32;
+ else
+ u64 = F64;
+ MOV64z(x1, u64);
+ STRxw_REG(xRAX, x1, x4);
+ SMWRITE2();
+ break;
+
case 0xC6:
INST_NAME("MOV Seg:Eb, Ib");
grab_segdata(dyn, addr, ninst, x4, seg);
@@ -581,12 +640,12 @@ uintptr_t dynarec64_64(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
eb2 = (ed&4)>>2; // L or H
} else {
eb1 = xRAX+(nextop&7)+(rex.b<<3);
- eb2 = 0;
+ eb2 = 0;
}
MOV32w(x3, u8);
BFIx(eb1, x3, eb2*8, 8);
} else { // mem <= u8
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 1);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 1);
u8 = F8;
MOV32w(x3, u8);
STRB_REG(x3, ed, x4);
@@ -602,7 +661,7 @@ uintptr_t dynarec64_64(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
ed = xRAX+(nextop&7)+(rex.b<<3);
MOV64xw(ed, i64);
} else { // mem <= i32
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0, 0, rex, NULL, 0, 4);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 4);
i64 = F32S;
MOV64xw(x3, i64);
STRxw_REG(x3, ed, x4);
@@ -813,9 +872,10 @@ uintptr_t dynarec64_64(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
break;
}
break;
-
+
case 0xF7:
nextop = F8;
+ grab_segdata(dyn, addr, ninst, x6, seg);
switch((nextop>>3)&7) {
case 0:
case 1:
@@ -824,7 +884,7 @@ uintptr_t dynarec64_64(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
GETEDO(x6, 4);
i64 = F32S;
MOV64xw(x2, i64);
- emit_test32(dyn, ninst, rex, ed, x2, x3, x4);
+ emit_test32(dyn, ninst, rex, ed, x2, x3, x4, x5);
break;
case 2:
INST_NAME("NOT Ed");
@@ -893,8 +953,8 @@ uintptr_t dynarec64_64(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MOVw_REG(xRDX, x4);
} else {
if(ninst
- && dyn->insts[ninst-1].x64.addr
- && *(uint8_t*)(dyn->insts[ninst-1].x64.addr)==0x31
+ && dyn->insts[ninst-1].x64.addr
+ && *(uint8_t*)(dyn->insts[ninst-1].x64.addr)==0x31
&& *(uint8_t*)(dyn->insts[ninst-1].x64.addr+1)==0xD2) {
SET_DFNONE(x2);
GETEDO(x6, 0);
@@ -917,6 +977,7 @@ uintptr_t dynarec64_64(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
break;
case 7:
INST_NAME("IDIV Ed");
+ NOTEST(x1);
SETFLAGS(X_ALL, SF_SET);
if(!rex.w) {
SET_DFNONE(x2)
@@ -929,7 +990,7 @@ uintptr_t dynarec64_64(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MOVw_REG(xRDX, x4);
} else {
if(ninst && dyn->insts
- && dyn->insts[ninst-1].x64.addr
+ && dyn->insts[ninst-1].x64.addr
&& *(uint8_t*)(dyn->insts[ninst-1].x64.addr)==0x48
&& *(uint8_t*)(dyn->insts[ninst-1].x64.addr+1)==0x99) {
SET_DFNONE(x2)
@@ -955,7 +1016,7 @@ uintptr_t dynarec64_64(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
break;
}
break;
-
+
case 0xFF:
nextop = F8;
grab_segdata(dyn, addr, ninst, x6, seg);
@@ -984,7 +1045,7 @@ uintptr_t dynarec64_64(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
} else {
SETFLAGS(X_ALL, SF_SET); //Hack to put flag in "don't care" state
}
- GETEDOx(x6, 0);
+ GETEDOz(x6, 0);
if(box64_dynarec_callret && box64_dynarec_bigblock>1) {
BARRIER(BARRIER_FULL);
} else {
@@ -1006,22 +1067,22 @@ uintptr_t dynarec64_64(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
}
STPx_S7_preindex(x4, xRIP, xSP, -16);
}
- PUSH1(xRIP);
+ PUSH1z(xRIP);
jump_to_next(dyn, 0, ed, ninst);
break;
case 4: // JMP Ed
INST_NAME("JMP Ed");
READFLAGS(X_PEND);
BARRIER(BARRIER_FLOAT);
- GETEDOx(x6, 0);
+ GETEDOz(x6, 0);
jump_to_next(dyn, 0, ed, ninst);
*need_epilog = 0;
*ok = 0;
break;
case 6: // Push Ed
INST_NAME("PUSH Ed");
- GETEDOx(x6, 0);
- PUSH1(ed);
+ GETEDOz(x6, 0);
+ PUSH1z(ed);
break;
default:
diff --git a/src/dynarec/arm64/dynarec_arm64_66.c b/src/dynarec/arm64/dynarec_arm64_66.c
index 951518b..f646a28 100755..100644
--- a/src/dynarec/arm64/dynarec_arm64_66.c
+++ b/src/dynarec/arm64/dynarec_arm64_66.c
@@ -1,7 +1,6 @@
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
-#include <pthread.h>
#include <errno.h>
#include "debug.h"
@@ -35,6 +34,7 @@ uintptr_t dynarec64_66(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
uint8_t gd, ed;
uint8_t wback, wb1;
int64_t fixedaddress;
+ int unscaled;
int lock;
MAYUSE(u8);
MAYUSE(u16);
@@ -49,14 +49,9 @@ uintptr_t dynarec64_66(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
rep = opcode-0xF1;
opcode = F8;
}
- // REX prefix before the 66 are ignored
- rex.rex = 0;
- while(opcode>=0x40 && opcode<=0x4f) {
- rex.rex = opcode;
- opcode = F8;
- }
+ GETREX();
- if(rex.w && opcode!=0x0f) // rex.w cancels "66", but not for 66 0f type of prefix
+ if(rex.w && !(opcode==0x0f || opcode==0xf0 || opcode==0x64 || opcode==0x65)) // rex.w cancels "66", but not for 66 0f type of prefix
return dynarec64_00(dyn, addr-1, ip, ninst, rex, rep, ok, need_epilog); // addr-1, to "put back" opcode
switch(opcode) {
@@ -87,7 +82,7 @@ uintptr_t dynarec64_66(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
emit_add16(dyn, ninst, x1, x2, x3, x4);
BFIx(xRAX, x1, 0, 16);
break;
-
+
case 0x09:
INST_NAME("OR Ew, Gw");
SETFLAGS(X_ALL, SF_SET_PENDING);
@@ -294,6 +289,113 @@ uintptr_t dynarec64_66(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
}
break;
+ case 0x40:
+ case 0x41:
+ case 0x42:
+ case 0x43:
+ case 0x44:
+ case 0x45:
+ case 0x46:
+ case 0x47:
+ INST_NAME("INC Reg16 (32bits)");
+ SETFLAGS(X_ALL&~X_CF, SF_SUBSET_PENDING);
+ gd = xRAX + (opcode&7);
+ UXTHw(x1, gd);
+ emit_inc16(dyn, ninst, x1, x2, x3);
+ BFIw(gd, x1, 0, 16);
+ break;
+ case 0x48:
+ case 0x49:
+ case 0x4A:
+ case 0x4B:
+ case 0x4C:
+ case 0x4D:
+ case 0x4E:
+ case 0x4F:
+ INST_NAME("DEC Reg16 (32bits)");
+ SETFLAGS(X_ALL&~X_CF, SF_SUBSET_PENDING);
+ gd = xRAX + (opcode&7);
+ UXTHw(x1, gd);
+ emit_dec16(dyn, ninst, x1, x2, x3);
+ BFIw(gd, x1, 0, 16);
+ break;
+ case 0x50:
+ case 0x51:
+ case 0x52:
+ case 0x53:
+ case 0x54:
+ case 0x55:
+ case 0x56:
+ case 0x57:
+ if(rex.is32bits) {
+ INST_NAME("PUSH reg");
+ gd = xRAX+(opcode&0x07);
+ if (gd == xRSP) {
+ MOVw_REG(x1, xRSP);
+ PUSH1_16(x1);
+ } else {
+ PUSH1_16(gd);
+ }
+ } else {
+ DEFAULT;
+ }
+ break;
+ case 0x58:
+ case 0x59:
+ case 0x5A:
+ case 0x5B:
+ case 0x5C:
+ case 0x5D:
+ case 0x5E:
+ case 0x5F:
+ if(rex.is32bits) {
+ INST_NAME("POP reg");
+ gd = xRAX+(opcode&0x07);
+ POP1_16(x1);
+ BFIw(gd, x1, 0, 16);
+ } else {
+ DEFAULT;
+ }
+ break;
+ case 0x60:
+ if(rex.is32bits) {
+ INST_NAME("PUSHA 16bits (32bits)");
+ MOVw_REG(x1, xRSP);
+ PUSH1_16(xRAX);
+ PUSH1_16(xRCX);
+ PUSH1_16(xRDX);
+ PUSH1_16(xRBX);
+ PUSH1_16(x1);
+ PUSH1_16(xRBP);
+ PUSH1_16(xRSI);
+ PUSH1_16(xRDI);
+ } else {
+ DEFAULT;
+ }
+ break;
+ case 0x61:
+ if(rex.is32bits) {
+ INST_NAME("POPA 16bits (32bits)");
+ POP1_16(x1);
+ BFIw(xRDI, x1, 0, 16);
+ POP1_16(x1);
+ BFIw(xRSI, x1, 0, 16);
+ POP1_16(x1);
+ BFIw(xRBP, x1, 0, 16);
+ POP1_16(x1); // RSP ignored
+ POP1_16(x1);
+ BFIw(xRBX, x1, 0, 16);
+ POP1_16(x1);
+ BFIw(xRDX, x1, 0, 16);
+ POP1_16(x1);
+ BFIw(xRCX, x1, 0, 16);
+ POP1_16(x1);
+ BFIw(xRAX, x1, 0, 16);
+ } else {
+ DEFAULT;
+ }
+ break;
+
case 0x64:
addr = dynarec64_6664(dyn, addr, ip, ninst, rex, _FS, ok, need_epilog);
break;
@@ -424,7 +526,7 @@ uintptr_t dynarec64_66(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
break;
}
break;
-
+
case 0x85:
INST_NAME("TEST Ew, Gw");
SETFLAGS(X_ALL, SF_SET_PENDING);
@@ -445,7 +547,7 @@ uintptr_t dynarec64_66(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
BFIx(ed, x1, 0, 16);
} else {
GETGD;
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
SMDMB();
TSTx_mask(ed, 1, 0, 0); // mask=1
B_MARK(cNE);
@@ -462,7 +564,7 @@ uintptr_t dynarec64_66(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
BFIx(gd, x1, 0, 16);
}
break;
-
+
case 0x89:
INST_NAME("MOV Ew, Gw");
nextop = F8;
@@ -473,8 +575,8 @@ uintptr_t dynarec64_66(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
BFIx(ed, gd, 0, 16);
}
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<1, 1, rex, &lock, 0, 0);
- STRH_U12(gd, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<1, 1, rex, &lock, 0, 0);
+ STH(gd, ed, fixedaddress);
SMWRITELOCK(lock);
}
break;
@@ -488,12 +590,25 @@ uintptr_t dynarec64_66(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
BFIx(gd, ed, 0, 16);
}
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<1, 1, rex, &lock, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<1, 1, rex, &lock, 0, 0);
SMREADLOCK(lock);
- LDRH_U12(x1, ed, fixedaddress);
+ LDH(x1, ed, fixedaddress);
BFIx(gd, x1, 0, 16);
}
break;
+ case 0x8C:
+ INST_NAME("MOV EW, Seg");
+ nextop=F8;
+ u8 = (nextop&0x38)>>3;
+ LDRw_U12(x3, xEmu, offsetof(x64emu_t, segs[u8]));
+ if((nextop&0xC0)==0xC0) { // reg <= seg
+ UXTHw(xRAX+(nextop&7)+(rex.b<<3), x3);
+ } else { // mem <= seg
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, &unscaled, 0xfff<<1, 1, rex, NULL, 0, 0);
+ STH(x3, wback, fixedaddress);
+ SMWRITE2();
+ }
+ break;
case 0x90:
case 0x91:
@@ -517,21 +632,51 @@ uintptr_t dynarec64_66(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
case 0x98:
INST_NAME("CBW");
SXTBw(x1, xRAX);
- BFIw(xRAX, x1, 0, 16);
+ BFIx(xRAX, x1, 0, 16);
+ break;
+
+ case 0x9C:
+ INST_NAME("PUSHF");
+ READFLAGS(X_ALL);
+ PUSH1_16(xFlags);
+ break;
+ case 0x9D:
+ INST_NAME("POPF");
+ SETFLAGS(X_ALL, SF_SET);
+ POP1_16(x1); // probably not usefull...
+ BFIw(xFlags, x1, 0, 16);
+ MOV32w(x1, 0x3F7FD7);
+ ANDw_REG(xFlags, xFlags, x1);
+ ORRw_mask(xFlags, xFlags, 0b011111, 0); //mask=0x00000002
+ SET_DFNONE(x1);
+ if(box64_wine) { // should this be done all the time?
+ TBZ_NEXT(xFlags, F_TF);
+ MOV64x(x1, addr);
+ STORE_XEMU_CALL(x1);
+ CALL(native_singlestep, -1);
+ BFCw(xFlags, F_TF, 1);
+ }
break;
case 0xA1:
INST_NAME("MOV EAX,Od");
- u64 = F64;
- MOV64x(x1, u64);
+ if(rex.is32bits)
+ u64 = F32;
+ else
+ u64 = F64;
+ MOV64z(x1, u64);
+ SMREAD();
LDRH_U12(x2, x1, 0);
BFIx(xRAX, x2, 0, 16);
break;
case 0xA3:
INST_NAME("MOV Od,EAX");
- u64 = F64;
- MOV64x(x1, u64);
+ if(rex.is32bits)
+ u64 = F32;
+ else
+ u64 = F64;
+ MOV64z(x1, u64);
STRH_U12(xRAX, x1, 0);
SMWRITE();
break;
@@ -563,6 +708,46 @@ uintptr_t dynarec64_66(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
}
break;
+ case 0xA7:
+ switch(rep) {
+ case 1:
+ case 2:
+ if(rep==1) {INST_NAME("REPNZ CMPSW");} else {INST_NAME("REPZ CMPSW");}
+ MAYSETFLAGS();
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ CBZx_NEXT(xRCX);
+ TBNZ_MARK2(xFlags, F_DF);
+ MARK; // Part with DF==0
+ LDRH_S9_postindex(x1, xRSI, 2);
+ LDRH_S9_postindex(x2, xRDI, 2);
+ SUBx_U12(xRCX, xRCX, 1);
+ CMPSw_REG(x1, x2);
+ B_MARK3((rep==1)?cEQ:cNE);
+ CBNZx_MARK(xRCX);
+ B_MARK3_nocond;
+ MARK2; // Part with DF==1
+ LDRH_S9_postindex(x1, xRSI, -2);
+ LDRH_S9_postindex(x2, xRDI, -2);
+ SUBx_U12(xRCX, xRCX, 1);
+ CMPSw_REG(x1, x2);
+ B_MARK3((rep==1)?cEQ:cNE);
+ CBNZx_MARK2(xRCX);
+ MARK3; // end
+ emit_cmp16(dyn, ninst, x1, x2, x3, x4, x5);
+ break;
+ default:
+ INST_NAME("CMPSW");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETDIR(x3, 2);
+ LDRH_U12(x1, xRSI, 0);
+ LDRH_U12(x2, xRDI, 0);
+ ADDx_REG(xRSI, xRSI, x3);
+ ADDx_REG(xRDI, xRDI, x3);
+ emit_cmp16(dyn, ninst, x1, x2, x3, x4, x5);
+ break;
+ }
+ break;
+
case 0xA9:
INST_NAME("TEST AX,Iw");
SETFLAGS(X_ALL, SF_SET_PENDING);
@@ -595,6 +780,70 @@ uintptr_t dynarec64_66(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
}
break;
+ case 0xAD:
+ if(rep) {
+ INST_NAME("REP LODSW");
+ CBZx_NEXT(xRCX);
+ TBNZ_MARK2(xFlags, F_DF);
+ MARK; // Part with DF==0
+ LDRH_S9_postindex(x2, xRSI, 2);
+ SUBx_U12(xRCX, xRCX, 1);
+ CBNZx_MARK(xRCX);
+ B_MARK3_nocond;
+ MARK2; // Part with DF==1
+ LDRH_S9_postindex(x2, xRSI, -2);
+ SUBx_U12(xRCX, xRCX, 1);
+ CBNZx_MARK2(xRCX);
+ MARK3;
+ BFIx(xRAX, x2, 0, 16);
+ // done
+ } else {
+ INST_NAME("LODSW");
+ GETDIR(x3, 2);
+ LDRH_U12(x2, xRSI, 0);
+ ADDx_REG(xRSI, xRSI, x3);
+ BFIx(xRAX, x2, 0, 16);
+ }
+ break;
+
+ case 0xAF:
+ switch(rep) {
+ case 1:
+ case 2:
+ if(rep==1) {INST_NAME("REPNZ SCASW");} else {INST_NAME("REPZ SCASW");}
+ MAYSETFLAGS();
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ CBZx_NEXT(xRCX);
+ UXTHw(x1, xRAX);
+ TBNZ_MARK2(xFlags, F_DF);
+ MARK; // Part with DF==0
+ LDRH_S9_postindex(x2, xRDI, 2);
+ SUBx_U12(xRCX, xRCX, 1);
+ CMPSw_REG(x1, x2);
+ B_MARK3((rep==1)?cEQ:cNE);
+ CBNZx_MARK(xRCX);
+ B_MARK3_nocond;
+ MARK2; // Part with DF==1
+ LDRH_S9_postindex(x2, xRDI, -2);
+ SUBx_U12(xRCX, xRCX, 1);
+ CMPSw_REG(x1, x2);
+ B_MARK3((rep==1)?cEQ:cNE);
+ CBNZx_MARK2(xRCX);
+ MARK3; // end
+ emit_cmp16(dyn, ninst, x1, x2, x3, x4, x5);
+ break;
+ default:
+ INST_NAME("SCASW");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETDIR(x3, 2);
+ UXTHw(x1, xRAX);
+ LDRH_U12(x2, xRDI, 0);
+ ADDx_REG(xRDI, xRDI, x3);
+ emit_cmp16(dyn, ninst, x1, x2, x3, x4, x5);
+ break;
+ }
+ break;
+
case 0xB8:
case 0xB9:
case 0xBA:
@@ -707,10 +956,10 @@ uintptr_t dynarec64_66(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MOV32w(x1, u16);
BFIx(ed, x1, 0, 16);
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<1, 1, rex, &lock, 0, 2);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<1, 1, rex, &lock, 0, 2);
u16 = F16;
MOV32w(x1, u16);
- STRH_U12(x1, ed, fixedaddress);
+ STH(x1, ed, fixedaddress);
SMWRITELOCK(lock);
}
break;
@@ -821,7 +1070,7 @@ uintptr_t dynarec64_66(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
break;
}
break;
-
+
case 0xF0:
return dynarec64_66F0(dyn, addr, ip, ninst, rex, rep, ok, need_epilog);
@@ -885,6 +1134,7 @@ uintptr_t dynarec64_66(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
break;
case 7:
INST_NAME("IDIV Ew");
+ NOTEST(x1);
SETFLAGS(X_ALL, SF_SET);
GETSEW(x1, 0);
UXTHw(x2, xRAX);
@@ -896,7 +1146,7 @@ uintptr_t dynarec64_66(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
break;
}
break;
-
+
case 0xFF:
nextop = F8;
switch((nextop>>3)&7) {
@@ -914,10 +1164,21 @@ uintptr_t dynarec64_66(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
emit_dec16(dyn, ninst, x1, x2, x4);
EWBACK;
break;
+ case 6: // Push Ew
+ if(rex.is32bits) {
+ INST_NAME("PUSH Ew");
+ GETEW(x1, 0);
+ PUSH1_16(ed);
+ } else {
+ DEFAULT;
+ }
+ break;
+
default:
DEFAULT;
}
break;
+
default:
DEFAULT;
}
diff --git a/src/dynarec/arm64/dynarec_arm64_660f.c b/src/dynarec/arm64/dynarec_arm64_660f.c
index 01cd736..9f30df5 100755..100644
--- a/src/dynarec/arm64/dynarec_arm64_660f.c
+++ b/src/dynarec/arm64/dynarec_arm64_660f.c
@@ -1,7 +1,6 @@
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
-#include <pthread.h>
#include <errno.h>
#include "debug.h"
@@ -38,6 +37,7 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
int q0, q1;
int d0, d1;
int64_t fixedaddress;
+ int unscaled;
MAYUSE(d0);
MAYUSE(d1);
@@ -48,6 +48,7 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
MAYUSE(j64);
#if STEP > 1
static const int8_t mask_shift8[] = { -7, -6, -5, -4, -3, -2, -1, 0 };
+ static const int8_t round_round[] = { 0, 2, 1, 3};
#endif
switch(opcode) {
@@ -63,8 +64,8 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
} else {
SMREAD();
v0 = sse_get_reg_empty(dyn, ninst, x1, gd);
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<4, 15, rex, NULL, 0, 0);
- VLDR128_U12(v0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<4, 15, rex, NULL, 0, 0);
+ VLD128(v0, ed, fixedaddress);
}
break;
case 0x11:
@@ -76,8 +77,8 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
v1 = sse_get_reg_empty(dyn, ninst, x1, (nextop&7)+(rex.b<<3));
VMOVQ(v1, v0);
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<4, 15, rex, NULL, 0, 0);
- VSTR128_U12(v0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<4, 15, rex, NULL, 0, 0);
+ VST128(v0, ed, fixedaddress);
SMWRITE2();
}
break;
@@ -91,7 +92,7 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
return addr;
}
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
VLD1_64(v0, 0, ed);
break;
case 0x13:
@@ -103,7 +104,7 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
DEFAULT;
return addr;
}
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
VST1_64(v0, 0, ed);
SMWRITE2();
break;
@@ -116,7 +117,7 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
VMOVeD(v0, 1, v1, 0);
} else {
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
VLD1_64(v0, 1, ed);
}
break;
@@ -130,7 +131,7 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
VMOVeD(v0, 1, v1, 1);
} else {
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
v1 = fpu_get_scratch(dyn);
ADDx_U12(ed, ed, 8);
VLD1_64(v0, 1, ed);
@@ -146,7 +147,7 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
return addr;
}
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
VLD1_64(v0, 1, ed);
break;
case 0x17:
@@ -158,7 +159,7 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
DEFAULT;
return addr;
}
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
VST1_64(v0, 1, ed);
SMWRITE2();
break;
@@ -181,8 +182,8 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
} else {
SMREAD();
v0 = sse_get_reg_empty(dyn, ninst, x1, gd);
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<4, 15, rex, NULL, 0, 0);
- VLDR128_U12(v0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<4, 15, rex, NULL, 0, 0);
+ VLD128(v0, ed, fixedaddress);
}
break;
case 0x29:
@@ -195,8 +196,8 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
v1 = sse_get_reg_empty(dyn, ninst, x1, ed);
VMOVQ(v1, v0);
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<4, 15, rex, NULL, 0, 0);
- VSTR128_U12(v0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<4, 15, rex, NULL, 0, 0);
+ VST128(v0, ed, fixedaddress);
SMWRITE2();
}
break;
@@ -208,7 +209,7 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
SETFLAGS(X_ALL, SF_SET);
nextop = F8;
GETGX(v0, 0);
- GETEX(q0, 0, 0);
+ GETEXSD(q0, 0, 0);
FCMPD(v0, q0);
FCOMI(x1, x2);
break;
@@ -260,6 +261,36 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
SQXTN2_16(q0, v0);
break;
+ case 0x05:
+ INST_NAME("PHSUBW Gx, Ex");
+ nextop = F8;
+ GETGX(q0, 1);
+ GETEX(q1, 0, 0);
+ v0 = fpu_get_scratch(dyn);
+ VUZP2Q_16(v0, q0, q1);
+ VUZP1Q_16(q0, q0, q1);
+ VSUBQ_16(q0, q0, v0);
+ break;
+ case 0x06:
+ INST_NAME("PHSUBD Gx, Ex");
+ nextop = F8;
+ GETGX(q0, 1);
+ GETEX(q1, 0, 0);
+ v0 = fpu_get_scratch(dyn);
+ VUZP2Q_32(v0, q0, q1);
+ VUZP1Q_32(q0, q0, q1);
+ VSUBQ_32(q0, q0, v0);
+ break;
+ case 0x07:
+ INST_NAME("PHSUBSW Gx, Ex");
+ nextop = F8;
+ GETGX(q0, 1);
+ GETEX(q1, 0, 0);
+ v0 = fpu_get_scratch(dyn);
+ VUZP2Q_16(v0, q0, q1);
+ VUZP1Q_16(q0, q0, q1);
+ SQSUBQ_16(q0, q0, v0);
+ break;
case 0x08:
INST_NAME("PSIGNB Gx, Ex");
nextop = F8;
@@ -328,6 +359,65 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
}
break;
+ case 0x14:
+ INST_NAME("PBLENDVPS Gx,Ex");
+ nextop = F8;
+ GETGX(q0, 1);
+ GETEX(q1, 0, 0);
+ v0 = sse_get_reg(dyn, ninst, x1, 0, 0);
+ v1 = fpu_get_scratch(dyn);
+ if(q0!=q1) {
+ VSSHRQ_32(v1, v0, 31); // bit[31]-> bit[31..0]
+ VBICQ(q0, q0, v1);
+ VANDQ(v1, q1, v1);
+ VORRQ(q0, q0, v1);
+ }
+ break;
+ case 0x15:
+ INST_NAME("PBLENDVPD Gx,Ex");
+ nextop = F8;
+ GETGX(q0, 1);
+ GETEX(q1, 0, 0);
+ v0 = sse_get_reg(dyn, ninst, x1, 0, 0);
+ v1 = fpu_get_scratch(dyn);
+ if(q0!=q1) {
+ VSSHRQ_64(v1, v0, 63); // bit[63]-> bit[63..0]
+ VBICQ(q0, q0, v1);
+ VANDQ(v1, q1, v1);
+ VORRQ(q0, q0, v1);
+ }
+ break;
+
+ case 0x17:
+ INST_NAME("PTEST Gx, Ex");
+ nextop = F8;
+ SETFLAGS(X_ALL, SF_SET);
+ GETGX(q0, 0);
+ GETEX(q1, 0, 0);
+ v1 = fpu_get_scratch(dyn);
+ IFX(X_ZF) {
+ VANDQ(v1, q1, q0);
+ CMEQQ_0_64(v1, v1);
+ UADDLVQ_32(v1, v1);
+ VMOVQDto(x1, v1, 0);
+ UBFXx(x1, x1, 33, 1); // bit33 will only be set if all bits are 1
+ BFIw(xFlags, x1, F_ZF, 1);
+ }
+ IFX(X_CF) {
+ VBICQ(v1, q1, q0);
+ CMEQQ_0_64(v1, v1);
+ UADDLVQ_32(v1, v1);
+ VMOVQDto(x1, v1, 0);
+ UBFXx(x1, x1, 33, 1);
+ BFIw(xFlags, x1, F_CF, 1);
+ }
+ IFX(X_PF|X_AF|X_OF|X_SF) {
+ MOV32w(x1, (1<<F_PF)|(1<<F_AF)|(1<<F_OF)|(1<<F_SF));
+ BICw_REG(xFlags, xFlags, x1);
+ }
+ SET_DFNONE(x1);
+ break;
+
case 0x1C:
INST_NAME("PABSB Gx,Ex");
nextop = F8;
@@ -397,6 +487,55 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
SXTL_32(q0, q1); // 32bits->64bits
break;
+ case 0x28:
+ INST_NAME("PMULDQ Gx, Ex");
+ nextop = F8;
+ GETEX(q1, 0, 0);
+ GETGX(q0, 1);
+ VUZP1Q_32(q0, q0, q0); // needs elem 0 and 2 in lower part
+ if(q0==q1) {
+ v0 = q0;
+ } else {
+ if(MODREG)
+ v0 = fpu_get_scratch(dyn);
+ else
+ v0 = q1;
+ VUZP1Q_32(v0, q1, q1);
+ }
+ VSMULL_32(q0, q0, v0);
+ break;
+ case 0x29:
+ INST_NAME("PCMPEQQ Gx, Ex"); // SSE4 opcode!
+ nextop = F8;
+ GETEX(q1, 0, 0);
+ GETGX_empty(q0);
+ VCMEQQ_64(q0, q0, q1);
+ break;
+ case 0x2A:
+ INST_NAME("MOVNTDQA Gx, Ex");
+ nextop = F8;
+ GETEX(q1, 0, 0);
+ GETGX(q0, 1);
+ VMOVQ(q0, q1);
+ break;
+ case 0x2B:
+ INST_NAME("PACKUSDW Gx, Ex"); // SSE4 opcode!
+ nextop = F8;
+ GETEX(q1, 0, 0);
+ GETGX(q0, 1);
+ v0 = fpu_get_scratch(dyn);
+ v1 = fpu_get_scratch(dyn);
+ VEORQ(v0, v0, v0);
+ SMAXQ_32(v1, v0, q0); // values < 0 => 0
+ UQXTN_16(q0, v1);
+ if(q0==q1) {
+ VMOVeD(q0, 1, q0, 0);
+ } else {
+ SMAXQ_32(v0, v0, q1);
+ UQXTN2_16(q0, v0);
+ }
+ break;
+
case 0x30:
INST_NAME("PMOVZXBW Gx, Ex"); // SSE4 opcode!
nextop = F8;
@@ -500,6 +639,13 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
GETGX(q0, 1);
UMAXQ_32(q0, q0, q1);
break;
+ case 0x40:
+ INST_NAME("PMULLD Gx, Ex"); // SSE4 opcode!
+ nextop = F8;
+ GETEX(q1, 0, 0);
+ GETGX(q0, 1);
+ VMULQ_32(q0, q0, q1);
+ break;
case 0xDB:
INST_NAME("AESIMC Gx, Ex"); // AES-NI
@@ -516,7 +662,7 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
}
sse_forget_reg(dyn, ninst, gd);
MOV32w(x1, gd);
- CALL(arm_aesimc, -1);
+ CALL(native_aesimc, -1);
}
break;
case 0xDC:
@@ -534,7 +680,7 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
GETG;
sse_forget_reg(dyn, ninst, gd);
MOV32w(x1, gd);
- CALL(arm_aese, -1);
+ CALL(native_aese, -1);
GETGX(q0, 1);
GETEX(q1, 0, 0);
VEORQ(q0, q0, q1);
@@ -554,7 +700,7 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
GETG;
sse_forget_reg(dyn, ninst, gd);
MOV32w(x1, gd);
- CALL(arm_aeselast, -1);
+ CALL(native_aeselast, -1);
GETGX(q0, 1);
GETEX(q1, 0, 0);
VEORQ(q0, q0, q1);
@@ -575,7 +721,7 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
GETG;
sse_forget_reg(dyn, ninst, gd);
MOV32w(x1, gd);
- CALL(arm_aesd, -1);
+ CALL(native_aesd, -1);
GETGX(q0, 1);
GETEX(q1, 0, 0);
VEORQ(q0, q0, q1);
@@ -595,26 +741,102 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
GETG;
sse_forget_reg(dyn, ninst, gd);
MOV32w(x1, gd);
- CALL(arm_aesdlast, -1);
+ CALL(native_aesdlast, -1);
GETGX(q0, 1);
GETEX(q1, 0, 0);
VEORQ(q0, q0, q1);
}
break;
-
+ case 0xF0:
+ INST_NAME("MOVBE Gw, Ew");
+ nextop=F8;
+ gd = xRAX+((nextop&0x38)>>3)+(rex.r<<3);
+ if(MODREG) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ REV16x(x1, ed);
+ BFIx(gd, x1, 0, 16);
+ } else {
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<2, (1<<2)-1, rex, NULL, 0, 0);
+ LDH(x1, ed, fixedaddress);
+ REV16x(x1, x1);
+ BFIx(gd, x1, 0, 16);
+ }
+ break;
+ case 0xF1:
+ INST_NAME("MOVBE Ew, Gw");
+ nextop=F8;
+ gd = xRAX+((nextop&0x38)>>3)+(rex.r<<3);
+ if(MODREG) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ REV16x(x1, gd);
+ BFIx(ed, x1, 0, 16);
+ } else {
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<2, (1<<2)-1, rex, NULL, 0, 0);
+ REV16x(x1, gd);
+ STH(x1, ed, fixedaddress);
+ }
+ break;
default:
DEFAULT;
}
break;
- case 0x3A: // these are some more SSSE3 opcodes
+ case 0x3A: // these are some more SSSE3+ opcodes
opcode = F8;
switch(opcode) {
+ case 0x08:
+ INST_NAME("ROUNDPS Gx, Ex, Ib");
+ nextop = F8;
+ GETEX(q1, 0, 1);
+ GETGX_empty(q0);
+ u8 = F8;
+ v1 = fpu_get_scratch(dyn);
+ if(u8&4) {
+ u8 = sse_setround(dyn, ninst, x1, x2, x3);
+ VFRINTISQ(q0, q1);
+ x87_restoreround(dyn, ninst, u8);
+ } else {
+ VFRINTRSQ(q0, q1, round_round[u8&3]);
+ }
+ break;
+ case 0x09:
+ INST_NAME("ROUNDPD Gx, Ex, Ib");
+ nextop = F8;
+ GETEX(q1, 0, 1);
+ GETGX_empty(q0);
+ u8 = F8;
+ v1 = fpu_get_scratch(dyn);
+ if(u8&4) {
+ u8 = sse_setround(dyn, ninst, x1, x2, x3);
+ VFRINTIDQ(q0, q1);
+ x87_restoreround(dyn, ninst, u8);
+ } else {
+ VFRINTRDQ(q0, q1, round_round[u8&3]);
+ }
+ break;
+ case 0x0A:
+ INST_NAME("ROUNDSS Gx, Ex, Ib");
+ nextop = F8;
+ GETGX(q0, 1);
+ GETEXSS(q1, 0, 1);
+ u8 = F8;
+ v1 = fpu_get_scratch(dyn);
+ if(u8&4) {
+ u8 = sse_setround(dyn, ninst, x1, x2, x3);
+ FRINTXS(v1, q1);
+ x87_restoreround(dyn, ninst, u8);
+ } else {
+ FRINTRRS(v1, q1, round_round[u8&3]);
+ }
+ VMOVeS(q0, 0, v1, 0);
+ break;
case 0x0B:
INST_NAME("ROUNDSD Gx, Ex, Ib");
nextop = F8;
GETGX(q0, 1);
- GETEX(q1, 0, 1);
+ GETEXSD(q1, 0, 1);
u8 = F8;
v1 = fpu_get_scratch(dyn);
if(u8&4) {
@@ -622,13 +844,62 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
FRINTXD(v1, q1);
x87_restoreround(dyn, ninst, u8);
} else {
- const uint8_t rounds[] = {0, 2, 1, 3};
- MAYUSE(rounds);
- FRINTRRD(v1, q1, rounds[u8&3]);
+ FRINTRRD(v1, q1, round_round[u8&3]);
}
VMOVeD(q0, 0, v1, 0);
break;
+ case 0x0C:
+ INST_NAME("PBLENDPS Gx, Ex, Ib");
+ nextop = F8;
+ GETGX(q0, 1);
+ GETEX(q1, 0, 1);
+ u8 = F8&0b1111;
+ if(u8==0b0011) {
+ VMOVeD(q0, 0, q1, 0);
+ } else if(u8==0b1100) {
+ VMOVeD(q0, 1, q1, 1);
+ } else for(int i=0; i<4; ++i)
+ if(u8&(1<<i)) {
+ VMOVeS(q0, i, q1, i);
+ }
+ break;
+ case 0x0E:
+ INST_NAME("PBLENDW Gx, Ex, Ib");
+ nextop = F8;
+ GETGX(q0, 1);
+ GETEX(q1, 0, 1);
+ u8 = F8;
+ i32 = 0;
+ if(q0!=q1)
+ while(u8) {
+ if(u8&1) {
+ if(!(i32&1) && u8&2) {
+ if(!(i32&3) && (u8&0xf)==0xf) {
+ // whole 64bits
+ VMOVeD(q0, i32>>2, q1, i32>>2);
+ i32+=4;
+ u8>>=4;
+ } else {
+ // 32bits
+ VMOVeS(q0, i32>>1, q1, i32>>1);
+ i32+=2;
+ u8>>=2;
+ }
+ } else {
+ // 16 bits
+ VMOVeH(q0, i32, q1, i32);
+ i32++;
+ u8>>=1;
+ }
+ } else {
+ // nope
+ i32++;
+ u8>>=1;
+ }
+
+ }
+ break;
case 0x0F:
INST_NAME("PALIGNR Gx, Ex, Ib");
nextop = F8;
@@ -646,16 +917,57 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
}
break;
+ case 0x14:
+ INST_NAME("PEXTRB Ed, Gx, Ib");
+ nextop = F8;
+ GETGX(q0, 0);
+ if(MODREG) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ u8 = F8;
+ VMOVBto(ed, q0, (u8&15));
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 1);
+ u8 = F8;
+ VST1_8(q0, (u8&15), wback);
+ SMWRITE2();
+ }
+ break;
+ case 0x15:
+ INST_NAME("PEXTRW Ed, Gx, Ib");
+ nextop = F8;
+ GETGX(q0, 0);
+ if(MODREG) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ u8 = F8;
+ VMOVHto(ed, q0, (u8&7));
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 1);
+ u8 = F8;
+ VST1_16(q0, (u8&7), wback);
+ SMWRITE2();
+ }
+ break;
case 0x16:
if(rex.w) {INST_NAME("PEXTRQ Ed, Gx, Ib");} else {INST_NAME("PEXTRD Ed, Gx, Ib");}
nextop = F8;
GETGX(q0, 0);
- GETED(1);
- u8 = F8;
- if(rex.w) {
- VMOVQDto(ed, q0, (u8&1));
+ if(MODREG) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ u8 = F8;
+ if(rex.w) {
+ VMOVQDto(ed, q0, (u8&1));
+ } else {
+ VMOVSto(ed, q0, (u8&3));
+ }
} else {
- VMOVSto(ed, q0, (u8&3));
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 1);
+ u8 = F8;
+ if(rex.w) {
+ VST1_64(q0, (u8&1), wback);
+ } else {
+ VST1_32(q0, (u8&3), wback);
+ }
+ SMWRITE2();
}
break;
@@ -715,14 +1027,14 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
MOV32w(x3, 0); //p = NULL
} else {
MOV32w(x2, 0);
- addr = geted(dyn, addr, ninst, nextop, &ed, x3, &fixedaddress, 0, 0, rex, NULL, 0, 1);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x3, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 1);
if(ed!=x3) {
MOVx_REG(x3, ed);
}
}
u8 = F8;
MOV32w(x4, u8);
- CALL(arm_pclmul, -1);
+ CALL(native_pclmul, -1);
}
break;
@@ -739,14 +1051,14 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
MOV32w(x3, 0); //p = NULL
} else {
MOV32w(x2, 0);
- addr = geted(dyn, addr, ninst, nextop, &ed, x3, &fixedaddress, 0, 0, rex, NULL, 0, 1);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x3, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 1);
if(ed!=x3) {
MOVx_REG(x3, ed);
}
}
u8 = F8;
MOV32w(x4, u8);
- CALL(arm_aeskeygenassist, -1);
+ CALL(native_aeskeygenassist, -1);
break;
default:
@@ -763,8 +1075,8 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
ed = xRAX+(nextop&7)+(rex.b<<3); \
} else { \
SMREAD(); \
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<1, 1, rex, NULL, 0, 0); \
- LDRH_U12(x1, ed, fixedaddress); \
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<1, 1, rex, NULL, 0, 0); \
+ LDH(x1, ed, fixedaddress); \
ed = x1; \
} \
Bcond(NO, +8); \
@@ -877,17 +1189,44 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
nextop = F8;
GETEX(v1, 0, 0);
GETGX_empty(v0);
- FCVTXN(v0, v1);
+ if(box64_dynarec_fastround) {
+ FCVTXN(v0, v1);
+ } else {
+ u8 = sse_setround(dyn, ninst, x1, x2, x3);
+ FCVTN(v0, v1);
+ x87_restoreround(dyn, ninst, u8);
+ }
break;
case 0x5B:
INST_NAME("CVTPS2DQ Gx, Ex");
nextop = F8;
GETEX(v1, 0, 0);
GETGX_empty(v0);
- u8 = sse_setround(dyn, ninst, x1, x2, x3);
- VFRINTISQ(v0, v1);
- x87_restoreround(dyn, ninst, u8);
- VFCVTZSQS(v0, v0);
+ if(box64_dynarec_fastround) {
+ u8 = sse_setround(dyn, ninst, x1, x2, x3);
+ VFRINTISQ(v0, v1);
+ x87_restoreround(dyn, ninst, u8);
+ VFCVTZSQS(v0, v0);
+ } else {
+ MRS_fpsr(x5);
+ BFCw(x5, FPSR_IOC, 1); // reset IOC bit
+ MSR_fpsr(x5);
+ u8 = sse_setround(dyn, ninst, x1, x2, x3);
+ MOV32w(x4, 0x80000000);
+ d0 = fpu_get_scratch(dyn);
+ for(int i=0; i<4; ++i) {
+ BFCw(x5, FPSR_IOC, 1); // reset IOC bit
+ MSR_fpsr(x5);
+ VMOVeS(d0, 0, v1, i);
+ FRINTIS(d0, d0);
+ VFCVTZSs(d0, d0);
+ MRS_fpsr(x5); // get back FPSR to check the IOC bit
+ TBZ(x5, FPSR_IOC, 4+4);
+ VMOVQSfrom(d0, 0, x4);
+ VMOVeS(v0, i, d0, 0);
+ }
+ x87_restoreround(dyn, ninst, u8);
+ }
break;
case 0x5C:
INST_NAME("SUBPD Gx, Ex");
@@ -912,9 +1251,18 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
case 0x5D:
INST_NAME("MINPD Gx, Ex");
nextop = F8;
- GETEX(q0, 0, 0);
GETGX(v0, 1);
- VFMINQD(v0, v0, q0);
+ GETEX(v1, 0, 0);
+ // FMIN/FMAX wll not copy the value if v0[x] is NaN
+ // but x86 will copy if either v0[x] or v1[x] is NaN, so lets force a copy if source is NaN
+ if(!box64_dynarec_fastnan && v0!=v1) {
+ q0 = fpu_get_scratch(dyn);
+ VFCMEQQD(q0, v0, v0); // 0 is NaN, 1 is not NaN, so MASK for NaN
+ VANDQ(v0, v0, q0);
+ VBICQ(q0, v1, q0);
+ VORRQ(v0, v0, q0);
+ }
+ VFMINQD(v0, v0, v1);
break;
case 0x5E:
INST_NAME("DIVPD Gx, Ex");
@@ -939,9 +1287,18 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
case 0x5F:
INST_NAME("MAXPD Gx, Ex");
nextop = F8;
- GETEX(q0, 0, 0);
GETGX(v0, 1);
- VFMAXQD(v0, v0, q0);
+ GETEX(v1, 0, 0);
+ // FMIN/FMAX wll not copy the value if v0[x] is NaN
+ // but x86 will copy if either v0[x] or v1[x] is NaN, so lets force a copy if source is NaN
+ if(!box64_dynarec_fastnan && v0!=v1) {
+ q0 = fpu_get_scratch(dyn);
+ VFCMEQQD(q0, v0, v0); // 0 is NaN, 1 is not NaN, so MASK for NaN
+ VANDQ(v0, v0, q0);
+ VBICQ(q0, v1, q0);
+ VORRQ(v0, v0, q0);
+ }
+ VFMAXQD(v0, v0, v1);
break;
case 0x60:
INST_NAME("PUNPCKLBW Gx,Ex");
@@ -1050,7 +1407,7 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
v1 = sse_get_reg(dyn, ninst, x1, (nextop&7)+(rex.b<<3), 0);
VMOVeD(v0, 1, v1, 0);
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
VLD1_64(v0, 1, ed);
}
break;
@@ -1061,9 +1418,11 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
VMOVeD(v0, 0, v0, 1);
if(MODREG) {
v1 = sse_get_reg(dyn, ninst, x1, (nextop&7)+(rex.b<<3), 0);
- VMOVeD(v0, 1, v1, 1);
+ if(v0!=v1) {
+ VMOVeD(v0, 1, v1, 1);
+ }
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
ADDSx_U12(x1, ed, 8);
VLD1_64(v0, 1, x1);
}
@@ -1090,8 +1449,8 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
} else {
GETGX_empty(v0);
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<4, 15, rex, NULL, 0, 0);
- VLDR128_U12(v0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<4, 15, rex, NULL, 0, 0);
+ VLD128(v0, ed, fixedaddress);
}
break;
case 0x70:
@@ -1165,7 +1524,7 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
} else {
GETGX_empty(v0);
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 1);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 1);
u8 = F8;
if (u8) {
for (int i=0; i<4; ++i) {
@@ -1387,8 +1746,8 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
ed = xRAX + (nextop&7) + (rex.b<<3);
VMOVQDto(ed, v0, 0);
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
- VSTR64_U12(v0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
+ VST64(v0, ed, fixedaddress);
SMWRITE2();
}
} else {
@@ -1396,8 +1755,8 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
ed = xRAX + (nextop&7) + (rex.b<<3);
VMOVSto(ed, v0, 0);
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<2, 3, rex, NULL, 0, 0);
- VSTR32_U12(v0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, 0);
+ VST32(v0, ed, fixedaddress);
SMWRITE2();
}
}
@@ -1410,8 +1769,8 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
v1 = sse_get_reg(dyn, ninst, x1, (nextop&7)+(rex.b<<3), 1);
VMOVQ(v1, v0);
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<4, 15, rex, NULL, 0, 0);
- VSTR128_U12(v0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<4, 15, rex, NULL, 0, 0);
+ VST128(v0, ed, fixedaddress);
SMWRITE2();
}
break;
@@ -1426,10 +1785,10 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
ed = xRAX+(nextop&7)+(rex.b<<3);
} else {
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<2, (1<<2)-1, rex, NULL, 0, 0);
- SBFXw(x1, gd, 4, 12); // r1 = (gw>>4)
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<2, (1<<2)-1, rex, NULL, 0, 0);
+ SBFXx(x1, gd, 4, 12); // r1 = (gw>>4)
ADDx_REG_LSL(x3, wback, x1, 1); //(&ed)+=r1*2;
- LDRH_U12(x1, x3, fixedaddress);
+ LDH(x1, x3, fixedaddress);
ed = x1;
}
ANDw_mask(x2, gd, 0, 0b000011); // mask=0x0f
@@ -1467,10 +1826,11 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
ed = xRAX+(nextop&7)+(rex.b<<3);
wback = 0;
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<2, (1<<2)-1, rex, NULL, 0, 0);
- SBFXw(x4, gd, 4, 12); // r1 = (gw>>4)
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<2, (1<<2)-1, rex, NULL, 0, 0);
+ SBFXx(x4, gd, 4, 12); // r1 = (gw>>4)
ADDx_REG_LSL(x3, wback, x4, 1); //(&ed)+=r1*2;
- LDRH_U12(x4, x3, fixedaddress);
+ LDH(x4, x3, fixedaddress);
+ wback = x3;
ed = x4;
}
ANDw_mask(x2, gd, 0, 0b000011); // mask=0x0f
@@ -1480,7 +1840,7 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
B_NEXT(cNE);
MOV32w(x1, 1);
LSLxw_REG(x1, x1, x2);
- EORx_REG(ed, ed, x1);
+ ORRx_REG(ed, ed, x1);
if(wback) {
STRH_U12(ed, wback, fixedaddress);
}
@@ -1529,10 +1889,10 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
wback = 0;
} else {
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<2, (1<<2)-1, rex, NULL, 0, 0);
- SBFXw(x4, gd, 4, 12); // r1 = (gw>>4)
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<2, (1<<2)-1, rex, NULL, 0, 0);
+ SBFXx(x4, gd, 4, 12); // r1 = (gw>>4)
ADDx_REG_LSL(x3, wback, x4, 1); //(&ed)+=r1*2;
- LDRH_U12(x4, x3, fixedaddress);
+ LDH(x4, x3, fixedaddress);
wback = x3;
ed = x4;
}
@@ -1543,9 +1903,9 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
B_NEXT(cEQ);
MOV32w(x1, 1);
LSLxw_REG(x1, x1, x2);
- EORx_REG(ed, ed, x1);
+ BICx_REG(ed, ed, x1);
if(wback) {
- STRH_U12(ed, wback, fixedaddress);
+ STH(ed, wback, fixedaddress);
SMWRITE();
}
break;
@@ -1565,8 +1925,8 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
UBFXxw(x1, eb1, eb2*8, 8);
} else {
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff, 0, rex, NULL, 0, 0);
- LDRB_U12(x1, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff, 0, rex, NULL, 0, 0);
+ LDB(x1, ed, fixedaddress);
}
gd = xRAX+((nextop&0x38)>>3)+(rex.r<<3); // GETGW
BFIx(gd, x1, 0, 16); // insert in Gw
@@ -1579,14 +1939,71 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
UBFXxw(x1, eb1, 0, 16);
} else {
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff>>1, 1, rex, NULL, 0, 0);
- LDRH_U12(x1, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff>>1, 1, rex, NULL, 0, 0);
+ LDH(x1, ed, fixedaddress);
}
gd = xRAX+((nextop&0x38)>>3)+(rex.r<<3); // GETGW
BFIx(gd, x1, 0, 16); // insert in Gw
break;
+ case 0xBA:
+ nextop = F8;
+ switch((nextop>>3)&7) {
+ case 4:
+ INST_NAME("BT Ew, Ib");
+ SETFLAGS(X_CF, SF_SUBSET);
+ SET_DFNONE(x1);
+ gd = x2;
+ GETEW(x1, 1);
+ u8 = F8;
+ u8&=rex.w?0x3f:0x0f;
+ BFXILxw(xFlags, ed, u8, 1); // inject 1 bit from u8 to F_CF (i.e. pos 0)
+ break;
+ case 5:
+ INST_NAME("BTS Ew, Ib");
+ SETFLAGS(X_CF, SF_SUBSET);
+ SET_DFNONE(x1);
+ GETEW(x1, 1);
+ u8 = F8;
+ u8&=(rex.w?0x3f:0x0f);
+ BFXILxw(xFlags, ed, u8, 1); // inject 1 bit from u8 to F_CF (i.e. pos 0)
+ TBNZ_MARK3(xFlags, 0); // bit already set, jump to next instruction
+ MOV32w(x4, 1);
+ ORRxw_REG_LSL(ed, ed, x4, u8);
+ EWBACK(x1);
+ MARK3;
+ break;
+ case 6:
+ INST_NAME("BTR Ew, Ib");
+ SETFLAGS(X_CF, SF_SUBSET);
+ SET_DFNONE(x1);
+ GETEW(x1, 1);
+ u8 = F8;
+ u8&=(rex.w?0x3f:0x0f);
+ BFXILxw(xFlags, ed, u8, 1); // inject 1 bit from u8 to F_CF (i.e. pos 0)
+ TBZ_MARK3(xFlags, 0); // bit already clear, jump to next instruction
+ MOV32w(x4, 1);
+ BICxw_REG_LSL(ed, ed, x4, u8);
+ EWBACK(x1);
+ MARK3;
+ break;
+ case 7:
+ INST_NAME("BTC Ew, Ib");
+ SETFLAGS(X_CF, SF_SUBSET);
+ SET_DFNONE(x1);
+ GETEW(x1, 1);
+ u8 = F8;
+ u8&=(rex.w?0x3f:0x0f);
+ BFXILxw(xFlags, ed, u8, 1); // inject 1 bit from u8 to F_CF (i.e. pos 0)
+ MOV32w(x4, 1);
+ EORxw_REG_LSL(ed, ed, x4, u8);
+ EWBACK(x1);
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
case 0xBB:
INST_NAME("BTC Ew, Gw");
SETFLAGS(X_CF, SF_SUBSET);
@@ -1598,10 +2015,10 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
wback = 0;
} else {
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<2, (1<<2)-1, rex, NULL, 0, 0);
- SBFXw(x4, gd, 4, 12); // r1 = (gw>>4)
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<2, (1<<2)-1, rex, NULL, 0, 0);
+ SBFXx(x4, gd, 4, 12); // r1 = (gw>>4)
ADDx_REG_LSL(x3, wback, x4, 1); //(&ed)+=r1*2;
- LDRH_U12(x4, x3, fixedaddress);
+ LDH(x4, x3, fixedaddress);
wback = x3;
ed = x4;
}
@@ -1628,7 +2045,7 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
B_MARK(cEQ);
RBITw(x1, x1); // reverse
CLZw(x2, x1); // x2 gets leading 0 == BSF
- BFIw(gd, x2, 0, 16);
+ BFIx(gd, x2, 0, 16);
MARK;
CSETw(x1, cEQ); //ZF not set
BFIw(xFlags, x1, F_ZF, 1);
@@ -1665,11 +2082,11 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
eb1 = xRAX+(ed&3); // Ax, Cx, Dx or Bx
eb2 = (ed&4)>>2; // L or H
}
- SBFXw(x1, eb1, eb2, 8);
+ SBFXw(x1, eb1, eb2*8, 8);
} else {
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff, 0, rex, NULL, 0, 0);
- LDRSBw_U12(x1, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff, 0, rex, NULL, 0, 0);
+ LDSBw(x1, ed, fixedaddress);
}
BFIx(gd, x1, 0, 16);
break;
@@ -1716,7 +2133,7 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
VMOVQHfrom(v0, u8, ed);
} else {
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0, 0, rex, NULL, 0, 1);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 1);
u8 = (F8)&7;
VLD1_16(v0, u8, wback);
}
@@ -1731,7 +2148,7 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
VMOVHto(gd, v0, u8);
} else {
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0, 0, rex, NULL, 0, 1);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 1);
u8 = (F8)&7;
LDRH_U12(gd, wback, u8*2);
}
@@ -1781,8 +2198,12 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
GETGX(q0, 1);
GETEX(q1, 0, 0);
v0 = fpu_get_scratch(dyn);
- VDUPQ_16(v0, q1, 0);
- NEGQ_16(v0, v0); // neg, because SHR
+ v1 = fpu_get_scratch(dyn);
+ UQXTN_32(v0, q1);
+ MOVI_32(v1, 16);
+ UMIN_32(v0, v0, v1); // limit to 0 .. +16 values
+ NEG_32(v0, v0); // neg to do shr
+ VDUPQ_16(v0, v0, 0); // only the low 8bits will be used anyway
USHLQ_16(q0, q0, v0); // SHR x8
break;
case 0xD2:
@@ -1791,8 +2212,12 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
GETGX(q0, 1);
GETEX(q1, 0, 0);
v0 = fpu_get_scratch(dyn);
- VDUPQ_32(v0, q1, 0);
- NEGQ_32(v0, v0); // neg, because SHR
+ v1 = fpu_get_scratch(dyn);
+ UQXTN_32(v0, q1);
+ MOVI_32(v1, 32);
+ UMIN_32(v0, v0, v1); // limit to 0 .. +32 values
+ NEG_32(v0, v0); // neg to do shr
+ VDUPQ_16(v0, v0, 0); // only the low 8bits will be used anyway
USHLQ_32(q0, q0, v0); // SHR x4
break;
case 0xD3:
@@ -1801,8 +2226,12 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
GETGX(q0, 1);
GETEX(q1, 0, 0);
v0 = fpu_get_scratch(dyn);
- NEG_64(v0, q1);
- VMOVeD(v0, 1, v0, 0);
+ v1 = fpu_get_scratch(dyn);
+ UQXTN_32(v0, q1);
+ MOVI_32(v1, 64);
+ UMIN_32(v0, v0, v1); // limit to 0 .. +64 values
+ NEG_32(v0, v0); // neg to do shr
+ VDUPQ_16(v0, v0, 0); // only the low 8bits will be used anyway
USHLQ_64(q0, q0, v0);
break;
case 0xD4:
@@ -1827,8 +2256,8 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
v1 = sse_get_reg_empty(dyn, ninst, x1, (nextop&7) + (rex.b<<3));
FMOVD(v1, v0);
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
- VSTR64_U12(v0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
+ VST64(v0, ed, fixedaddress);
SMWRITE2();
}
break;
@@ -1926,13 +2355,12 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
GETGX(q0, 1);
GETEX(q1, 0, 0);
v0 = fpu_get_scratch(dyn);
- VMOVeD(v0, 0, q1, 0);
- VMOVeD(v0, 1, q1, 0);
- SQXTN_32(v0, v0); // 2*q1 in 32bits now
- NEG_32(v0, v0); // because we want SHR and not SHL
- VMOVeD(v0, 1, v0, 0);
- SQXTN_16(v0, v0); // 4*q1 in 32bits now
- VMOVeD(v0, 1, v0, 0);
+ v1 = fpu_get_scratch(dyn);
+ UQXTN_32(v0, q1);
+ MOVI_32(v1, 15);
+ UMIN_32(v0, v0, v1); // limit to -15 .. +15 values
+ NEG_32(v0, v0);
+ VDUPQ_16(v0, v0, 0); // only the low 8bits will be used anyway
SSHLQ_16(q0, q0, v0);
break;
case 0xE2:
@@ -1941,11 +2369,12 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
GETGX(q0, 1);
GETEX(q1, 0, 0);
v0 = fpu_get_scratch(dyn);
- VMOVeD(v0, 0, q1, 0);
- VMOVeD(v0, 1, q1, 0);
- SQXTN_32(v0, v0); // 2*q1 in 32bits now
- NEG_32(v0, v0); // because we want SHR and not SHL
- VMOVeD(v0, 1, v0, 0);
+ v1 = fpu_get_scratch(dyn);
+ UQXTN_32(v0, q1);
+ MOVI_32(v1, 31);
+ UMIN_32(v0, v0, v1); // limit to 0 .. +31 values
+ NEG_32(v0, v0);
+ VDUPQ_32(v0, v0, 0); // only the low 8bits will be used anyway
SSHLQ_32(q0, q0, v0);
break;
case 0xE3:
@@ -1984,8 +2413,31 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
nextop = F8;
GETEX(v1, 0, 0);
GETGX_empty(v0);
- VFCVTZSQD(v0, v1); // convert double -> int64
- SQXTN_32(v0, v0); // convert int64 -> int32 with saturation in lower part, RaZ high part
+ if(box64_dynarec_fastround) {
+ VFCVTZSQD(v0, v1); // convert double -> int64
+ SQXTN_32(v0, v0); // convert int64 -> int32 with saturation in lower part, RaZ high part
+ } else {
+ MRS_fpsr(x5);
+ BFCw(x5, FPSR_IOC, 1); // reset IOC bit
+ MSR_fpsr(x5);
+ ORRw_mask(x4, xZR, 1, 0); //0x80000000
+ d0 = fpu_get_scratch(dyn);
+ for(int i=0; i<2; ++i) {
+ BFCw(x5, FPSR_IOC, 1); // reset IOC bit
+ MSR_fpsr(x5);
+ if(i) {
+ VMOVeD(d0, 0, v1, i);
+ FCVTZSwD(x1, d0);
+ } else {
+ FCVTZSwD(x1, v1);
+ }
+ MRS_fpsr(x5); // get back FPSR to check the IOC bit
+ TBZ(x5, FPSR_IOC, 4+4);
+ MOVw_REG(x1, x4);
+ VMOVQSfrom(v0, i, x1);
+ }
+ VMOVQDfrom(v0, 1, xZR);
+ }
break;
case 0xE7:
INST_NAME("MOVNTDQ Ex, Gx");
@@ -1995,8 +2447,8 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
v1 = sse_get_reg_empty(dyn, ninst, x1, (nextop&7)+(rex.b<<3));
VMOVQ(v1, v0);
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<4, 15, rex, NULL, 0, 0);
- VSTR128_U12(v0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<4, 15, rex, NULL, 0, 0);
+ VST128(v0, ed, fixedaddress);
}
break;
case 0xE8:
@@ -2063,17 +2515,31 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
}
break;
+ case 0xF1:
+ INST_NAME("PSLLW Gx,Ex");
+ nextop = F8;
+ GETGX(q0, 1);
+ GETEX(q1, 0, 0);
+ v0 = fpu_get_scratch(dyn);
+ v1 = fpu_get_scratch(dyn);
+ UQXTN_32(v0, q1);
+ MOVI_32(v1, 16);
+ UMIN_32(v0, v0, v1); // limit to 0 .. +16 values
+ VDUPQ_16(v0, v0, 0); // only the low 8bits will be used anyway
+ USHLQ_16(q0, q0, v0);
+ break;
case 0xF2:
INST_NAME("PSLLD Gx,Ex");
nextop = F8;
GETGX(q0, 1);
GETEX(q1, 0, 0);
v0 = fpu_get_scratch(dyn);
- VMOVeD(v0, 0, q1, 0);
- VMOVeD(v0, 1, q1, 0);
- SQXTN_32(v0, v0); // 2*q1 in 32bits now
- VMOVeD(v0, 1, v0, 0);
- SSHLQ_32(q0, q0, v0);
+ v1 = fpu_get_scratch(dyn);
+ UQXTN_32(v0, q1);
+ MOVI_32(v1, 32);
+ UMIN_32(v0, v0, v1); // limit to 0 .. +32 values
+ VDUPQ_32(v0, v0, 0); // only the low 8bits will be used anyway
+ USHLQ_32(q0, q0, v0);
break;
case 0xF3:
INST_NAME("PSLLQ Gx,Ex");
@@ -2081,8 +2547,12 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
GETGX(q0, 1);
GETEX(q1, 0, 0);
v0 = fpu_get_scratch(dyn);
- VMOVQ(v0, q1);
- VMOVeD(v0, 1, v0, 0);
+ v0 = fpu_get_scratch(dyn);
+ v1 = fpu_get_scratch(dyn);
+ UQXTN_32(v0, q1);
+ MOVI_32(v1, 64);
+ UMIN_32(v0, v0, v1); // limit to 0 .. +64 values
+ VDUPQ_64(v0, v0, 0); // only the low 8bits will be used anyway
USHLQ_64(q0, q0, v0);
break;
case 0xF4:
@@ -2127,7 +2597,7 @@ uintptr_t dynarec64_660F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
VMOVeD(q0, 1, d1, 0);
break;
case 0xF7:
- INST_NAME("MASKMOVDQU Gx, Ex")
+ INST_NAME("MASKMOVDQU Gx, Ex");
nextop = F8;
GETGX(q0, 1);
GETEX(q1, 0, 0);
diff --git a/src/dynarec/arm64/dynarec_arm64_6664.c b/src/dynarec/arm64/dynarec_arm64_6664.c
index 92abeac..0fe5947 100644
--- a/src/dynarec/arm64/dynarec_arm64_6664.c
+++ b/src/dynarec/arm64/dynarec_arm64_6664.c
@@ -1,7 +1,6 @@
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
-#include <pthread.h>
#include <errno.h>
#include "debug.h"
@@ -22,8 +21,6 @@
#include "dynarec_arm64_helper.h"
#include "dynarec_arm64_functions.h"
-#define GETG gd = ((nextop&0x38)>>3)+(rex.r<<3)
-
uintptr_t dynarec64_6664(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int seg, int* ok, int* need_epilog)
{
(void)ip; (void)need_epilog;
@@ -34,14 +31,10 @@ uintptr_t dynarec64_6664(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
int64_t j64;
int v0, v1;
int64_t fixedaddress;
+ int unscaled;
MAYUSE(j64);
- // REX prefix before the 66 are ignored
- rex.rex = 0;
- while(opcode>=0x40 && opcode<=0x4f) {
- rex.rex = opcode;
- opcode = F8;
- }
+ GETREX();
/*if(rex.w && opcode!=0x0f) { // rex.w cancels "66", but not for 66 0f type of prefix
MESSAGE(LOG_DUMP, "Here!\n");
@@ -66,8 +59,8 @@ uintptr_t dynarec64_6664(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
} else {
grab_segdata(dyn, addr, ninst, x4, seg);
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 0);
- v1 = fpu_get_scratch(dyn); \
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
+ v1 = fpu_get_scratch(dyn);
VLDR64_REG(v1, ed, x4);
}
FCMPD(v0, v1);
@@ -83,7 +76,7 @@ uintptr_t dynarec64_6664(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
FMOVD(v1, v0);
} else {
grab_segdata(dyn, addr, ninst, x4, seg);
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
VSTR64_REG(v0, ed, x4);
SMWRITE();
}
@@ -109,7 +102,7 @@ uintptr_t dynarec64_6664(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
}
} else {
grab_segdata(dyn, addr, ninst, x4, seg);
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
if(rex.w) {
STRx_REG(gd, ed, x4);
} else {
@@ -135,7 +128,7 @@ uintptr_t dynarec64_6664(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
} else { // mem <= reg
grab_segdata(dyn, addr, ninst, x4, seg);
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
if(rex.w) {
LDRx_REG(gd, ed, x4);
} else {
diff --git a/src/dynarec/arm64/dynarec_arm64_66f0.c b/src/dynarec/arm64/dynarec_arm64_66f0.c
index 2a436ea..fe32cf9 100644
--- a/src/dynarec/arm64/dynarec_arm64_66f0.c
+++ b/src/dynarec/arm64/dynarec_arm64_66f0.c
@@ -1,7 +1,6 @@
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
-#include <pthread.h>
#include <errno.h>
#include "debug.h"
@@ -34,6 +33,7 @@ uintptr_t dynarec64_66F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
int32_t i32;
int64_t i64, j64;
int64_t fixedaddress;
+ int unscaled;
MAYUSE(gb1);
MAYUSE(gb2);
MAYUSE(wb1);
@@ -44,12 +44,8 @@ uintptr_t dynarec64_66F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
rep = opcode-0xF1;
opcode = F8;
}
- // REX prefix before the F0/66 are ignored
- rex.rex = 0;
- while(opcode>=0x40 && opcode<=0x4f) {
- rex.rex = opcode;
- opcode = F8;
- }
+
+ GETREX();
switch(opcode) {
case 0x09:
@@ -64,7 +60,7 @@ uintptr_t dynarec64_66F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
emit_or16(dyn, ninst, x6, x5, x3, x4);
BFIx(ed, x6, 0, 16);
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
MARKLOCK;
LDAXRH(x1, wback);
emit_or16(dyn, ninst, x1, x5, x3, x4);
@@ -93,7 +89,7 @@ uintptr_t dynarec64_66F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
B_MARK(cNE);
BFIx(ed, gd, 0, 16);
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
TSTx_mask(wback, 1, 0, 0); // mask=1
B_MARK3(cNE);
// Aligned version
@@ -123,7 +119,7 @@ uintptr_t dynarec64_66F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
BFIx(xRAX, x1, 0, 16);
SMDMB();
break;
-
+
case 0xC1:
INST_NAME("LOCK XADD Gw, Ew");
SETFLAGS(X_ALL, SF_SET_PENDING);
@@ -137,7 +133,7 @@ uintptr_t dynarec64_66F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
emit_add16(dyn, ninst, x5, gd, x3, x4);
BFIx(ed, x5, 0, 16);
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
MARKLOCK;
LDAXRH(x1, wback);
ADDxw_REG(x4, x1, x5);
@@ -156,7 +152,28 @@ uintptr_t dynarec64_66F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
DEFAULT;
}
break;
-
+ case 0x11:
+ INST_NAME("LOCK ADC Ew, Gw");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGW(x5);
+ SMDMB();
+ if(MODREG) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ UXTHw(x6, ed);
+ emit_adc16(dyn, ninst, x6, x5, x3, x4);
+ BFIx(ed, x6, 0, 16);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
+ MARKLOCK;
+ LDAXRH(x1, wback);
+ emit_adc16(dyn, ninst, x1, x5, x3, x4);
+ STLXRH(x3, x1, wback);
+ CBNZx_MARKLOCK(x3);
+ }
+ SMDMB();
+ break;
case 0x81:
case 0x83:
nextop = F8;
@@ -177,7 +194,7 @@ uintptr_t dynarec64_66F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
emit_add16(dyn, ninst, x6, x5, x3, x4);
BFIx(ed, x6, 0, 16);
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, (opcode==0x81)?2:1);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, (opcode==0x81)?2:1);
if(opcode==0x81) i32 = F16S; else i32 = F8S;
MOV32w(x5, i32);
TSTx_mask(wback, 1, 0, 0); // mask=1
@@ -188,7 +205,7 @@ uintptr_t dynarec64_66F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
STLXRH(x3, x1, wback);
CBNZx_MARKLOCK(x3);
B_NEXT_nocond;
- MARK; // unaligned! also, not enough
+ MARK; // unaligned! also, not enough
LDRH_U12(x1, wback, 0);
LDAXRB(x4, wback);
BFIw(x1, x4, 0, 8); // re-inject
@@ -209,7 +226,7 @@ uintptr_t dynarec64_66F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
emit_or16(dyn, ninst, x6, x5, x3, x4);
BFIx(ed, x6, 0, 16);
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, (opcode==0x81)?2:1);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, (opcode==0x81)?2:1);
if(opcode==0x81) i32 = F16S; else i32 = F8S;
MOV32w(x5, i32);
MARKLOCK;
@@ -231,7 +248,7 @@ uintptr_t dynarec64_66F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
emit_adc16(dyn, ninst, x6, x5, x3, x4);
BFIx(ed, x6, 0, 16);
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, (opcode==0x81)?2:1);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, (opcode==0x81)?2:1);
if(opcode==0x81) i32 = F16S; else i32 = F8S;
MOV32w(x5, i32);
MARKLOCK;
@@ -253,7 +270,7 @@ uintptr_t dynarec64_66F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
emit_sbb16(dyn, ninst, x6, x5, x3, x4);
BFIx(ed, x6, 0, 16);
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, (opcode==0x81)?2:1);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, (opcode==0x81)?2:1);
if(opcode==0x81) i32 = F16S; else i32 = F8S;
MOV32w(x5, i32);
MARKLOCK;
@@ -274,7 +291,7 @@ uintptr_t dynarec64_66F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
emit_and16(dyn, ninst, x6, x5, x3, x4);
BFIx(ed, x6, 0, 16);
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, (opcode==0x81)?2:1);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, (opcode==0x81)?2:1);
if(opcode==0x81) i32 = F16S; else i32 = F8S;
MOV32w(x5, i32);
MARKLOCK;
@@ -295,7 +312,7 @@ uintptr_t dynarec64_66F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
emit_sub16(dyn, ninst, x6, x5, x3, x4);
BFIx(ed, x6, 0, 16);
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, (opcode==0x81)?2:1);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, (opcode==0x81)?2:1);
if(opcode==0x81) i32 = F16S; else i32 = F8S;
MOV32w(x5, i32);
TSTx_mask(wback, 1, 0, 0); // mask=1
@@ -306,7 +323,7 @@ uintptr_t dynarec64_66F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
STLXRH(x3, x1, wback);
CBNZx_MARKLOCK(x3);
B_NEXT_nocond;
- MARK; // unaligned! also, not enough
+ MARK; // unaligned! also, not enough
LDRH_U12(x1, wback, 0);
LDAXRB(x4, wback);
BFIw(x1, x4, 0, 8); // re-inject
@@ -327,7 +344,7 @@ uintptr_t dynarec64_66F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
emit_xor16(dyn, ninst, x6, x5, x3, x4);
BFIx(ed, x6, 0, 16);
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, (opcode==0x81)?2:1);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, (opcode==0x81)?2:1);
if(opcode==0x81) i32 = F16S; else i32 = F8S;
MOV32w(x5, i32);
MARKLOCK;
@@ -369,7 +386,7 @@ uintptr_t dynarec64_66F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
emit_inc16(dyn, ninst, x6, x5, x3);
BFIx(ed, x6, 0, 16);
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
MARKLOCK;
LDAXRH(x1, wback);
emit_inc16(dyn, ninst, x1, x3, x4);
@@ -388,7 +405,7 @@ uintptr_t dynarec64_66F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
emit_dec16(dyn, ninst, x6, x5, x3);
BFIx(ed, x6, 0, 16);
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
MARKLOCK;
LDAXRH(x1, wback);
emit_dec16(dyn, ninst, x1, x3, x4);
diff --git a/src/dynarec/arm64/dynarec_arm64_67.c b/src/dynarec/arm64/dynarec_arm64_67.c
index a68cc36..06e1e93 100755..100644
--- a/src/dynarec/arm64/dynarec_arm64_67.c
+++ b/src/dynarec/arm64/dynarec_arm64_67.c
@@ -1,7 +1,6 @@
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
-#include <pthread.h>
#include <errno.h>
#include "debug.h"
@@ -22,14 +21,6 @@
#include "dynarec_arm64_helper.h"
#include "dynarec_arm64_functions.h"
-#define GETGX(a, w) \
- gd = ((nextop&0x38)>>3)+(rex.r<<3); \
- a = sse_get_reg(dyn, ninst, x1, gd, w)
-
-#define GETGM(a) \
- gd = ((nextop&0x38)>>3); \
- a = mmx_get_reg(dyn, ninst, x1, x2, x3, gd)
-
#define GETGm gd = ((nextop&0x38)>>3)
uintptr_t dynarec64_67(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog)
@@ -38,8 +29,9 @@ uintptr_t dynarec64_67(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
uint8_t opcode = F8;
uint8_t nextop;
- uint8_t gd, ed, wback, wb, wb1, wb2, gb1, gb2;
+ uint8_t gd, ed, wback, wb, wb1, wb2, gb1, gb2, eb1, eb2;
int64_t fixedaddress;
+ int unscaled;
int8_t i8;
uint8_t u8;
int32_t i32;
@@ -55,12 +47,14 @@ uintptr_t dynarec64_67(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MAYUSE(lock);
MAYUSE(cacheupd);
- // REX prefix before the 67 are ignored
- rex.rex = 0;
- while(opcode>=0x40 && opcode<=0x4f) {
- rex.rex = opcode;
- opcode = F8;
+ if(rex.is32bits) {
+ // should do a different file
+ DEFAULT;
+ return addr;
}
+
+ GETREX();
+
rep = 0;
while((opcode==0xF2) || (opcode==0xF3)) {
rep = opcode-0xF1;
@@ -172,6 +166,28 @@ uintptr_t dynarec64_67(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
opcode=F8;
switch(opcode) {
+ case 0x11:
+ switch(rep) {
+ case 0:
+ INST_NAME("MOVUPS Ex,Gx");
+ nextop = F8;
+ GETG;
+ v0 = sse_get_reg(dyn, ninst, x1, gd, 0);
+ if(MODREG) {
+ ed = (nextop&7)+(rex.b<<3);
+ v1 = sse_get_reg_empty(dyn, ninst, x1, ed);
+ VMOVQ(v1, v0);
+ } else {
+ addr = geted32(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<4, 15, rex, NULL, 0, 0);
+ VST128(v0, ed, fixedaddress);
+ SMWRITE2();
+ }
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+
case 0x2E:
// no special check...
case 0x2F:
@@ -186,8 +202,8 @@ uintptr_t dynarec64_67(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
} else {
s0 = fpu_get_scratch(dyn);
SMREAD();
- addr = geted32(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<2, 3, rex, NULL, 0, 0);
- VLDR32_U12(s0, ed, fixedaddress);
+ addr = geted32(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, 0);
+ VLD32(s0, ed, fixedaddress);
}
FCMPS(v0, s0);
FCOMI(x1, x2);
@@ -210,8 +226,22 @@ uintptr_t dynarec64_67(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
} else {
v0 = mmx_get_reg_empty(dyn, ninst, x1, x2, x3, gd);
SMREAD();
- addr = geted32(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
- VLDR64_U12(v0, ed, fixedaddress);
+ addr = geted32(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
+ VLD64(v0, ed, fixedaddress);
+ }
+ break;
+ case 2:
+ INST_NAME("MOVDQU Gx,Ex");
+ nextop = F8;
+ if(MODREG) {
+ v1 = sse_get_reg(dyn, ninst, x1, (nextop&7)+(rex.b<<3), 0);
+ GETGX_empty(v0);
+ VMOVQ(v0, v1);
+ } else {
+ GETGX_empty(v0);
+ SMREAD();
+ addr = geted32(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<4, 15, rex, NULL, 0, 0);
+ VLD128(v0, ed, fixedaddress);
}
break;
default:
@@ -229,8 +259,8 @@ uintptr_t dynarec64_67(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
v1 = mmx_get_reg_empty(dyn, ninst, x1, x2, x3, nextop&7);
VMOV(v1, v0);
} else {
- addr = geted32(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
- VSTR64_U12(v0, ed, fixedaddress);
+ addr = geted32(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
+ VST64(v0, ed, fixedaddress);
SMWRITE();
}
break;
@@ -239,6 +269,40 @@ uintptr_t dynarec64_67(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
}
break;
+ case 0xB6:
+ INST_NAME("MOVZX Gd, Eb");
+ nextop = F8;
+ GETGD;
+ if(MODREG) {
+ if(rex.rex) {
+ eb1 = xRAX+(nextop&7)+(rex.b<<3);
+ eb2 = 0; \
+ } else {
+ ed = (nextop&7);
+ eb1 = xRAX+(ed&3); // Ax, Cx, Dx or Bx
+ eb2 = (ed&4)>>2; // L or H
+ }
+ UBFXxw(gd, eb1, eb2*8, 8);
+ } else {
+ SMREAD();
+ addr = geted32(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff, 0, rex, NULL, 0, 0);
+ LDB(gd, ed, fixedaddress);
+ }
+ break;
+ case 0xB7:
+ INST_NAME("MOVZX Gd, Ew");
+ nextop = F8;
+ GETGD;
+ if(MODREG) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ UBFXxw(gd, ed, 0, 16);
+ } else {
+ SMREAD();
+ addr = geted32(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<1, 1, rex, NULL, 0, 0);
+ LDH(gd, ed, fixedaddress);
+ }
+ break;
+
default:
DEFAULT;
}
@@ -563,6 +627,54 @@ uintptr_t dynarec64_67(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
emit_cmp32_0(dyn, ninst, rex, xRAX, x3, x4);
break;
+ case 0x63:
+ INST_NAME("MOVSXD Gd, Ed");
+ nextop = F8;
+ GETGD;
+ if(rex.w) {
+ if(MODREG) { // reg <= reg
+ SXTWx(gd, xRAX+(nextop&7)+(rex.b<<3));
+ } else { // mem <= reg
+ SMREAD();
+ addr = geted32(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, 0);
+ LDSW(gd, ed, fixedaddress);
+ }
+ } else {
+ if(MODREG) { // reg <= reg
+ MOVw_REG(gd, xRAX+(nextop&7)+(rex.b<<3));
+ } else { // mem <= reg
+ SMREAD();
+ addr = geted32(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, 0);
+ LDW(gd, ed, fixedaddress);
+ }
+ }
+ break;
+
+ case 0x66:
+ opcode=F8;
+ switch(opcode) {
+
+ case 0x89:
+ INST_NAME("MOV Ew, Gw");
+ nextop = F8;
+ GETGD; // don't need GETGW here
+ if(MODREG) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ if(ed!=gd) {
+ BFIx(ed, gd, 0, 16);
+ }
+ } else {
+ addr = geted32(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<1, 1, rex, &lock, 0, 0);
+ STH(gd, ed, fixedaddress);
+ SMWRITELOCK(lock);
+ }
+ break;
+
+ default:
+ DEFAULT;
+ }
+ break;
+
case 0x81:
case 0x83:
nextop = F8;
@@ -640,7 +752,40 @@ uintptr_t dynarec64_67(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
break;
}
break;
-
+
+ case 0x88:
+ INST_NAME("MOV Eb, Gb");
+ nextop = F8;
+ gd = ((nextop&0x38)>>3)+(rex.r<<3);
+ if(rex.rex) {
+ gb2 = 0;
+ gb1 = xRAX + gd;
+ } else {
+ gb2 = ((gd&4)>>2);
+ gb1 = xRAX+(gd&3);
+ }
+ if(gb2) {
+ gd = x4;
+ UBFXw(gd, gb1, gb2*8, 8);
+ } else {
+ gd = gb1; // no need to extract
+ }
+ if(MODREG) {
+ ed = (nextop&7) + (rex.b<<3);
+ if(rex.rex) {
+ eb1 = xRAX+ed;
+ eb2 = 0;
+ } else {
+ eb1 = xRAX+(ed&3); // Ax, Cx, Dx or Bx
+ eb2 = ((ed&4)>>2); // L or H
+ }
+ BFIx(eb1, gd, eb2*8, 8);
+ } else {
+ addr = geted32(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff, 0, rex, &lock, 0, 0);
+ STB(gd, ed, fixedaddress);
+ SMWRITELOCK(lock);
+ }
+ break;
case 0x89:
INST_NAME("MOV Ed, Gd");
nextop=F8;
@@ -648,8 +793,8 @@ uintptr_t dynarec64_67(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
if(MODREG) { // reg <= reg
MOVxw_REG(xRAX+(nextop&7)+(rex.b<<3), gd);
} else { // mem <= reg
- addr = geted32(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, &lock, 0, 0);
- STRxw_U12(gd, ed, fixedaddress);
+ addr = geted32(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, &lock, 0, 0);
+ STxw(gd, ed, fixedaddress);
SMWRITELOCK(lock);
}
break;
@@ -661,9 +806,9 @@ uintptr_t dynarec64_67(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
if(MODREG) {
MOVxw_REG(gd, xRAX+(nextop&7)+(rex.b<<3));
} else {
- addr = geted32(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, &lock, 0, 0);
+ addr = geted32(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, &lock, 0, 0);
SMREADLOCK(lock);
- LDRxw_U12(gd, ed, fixedaddress);
+ LDxw(gd, ed, fixedaddress);
}
break;
@@ -674,8 +819,7 @@ uintptr_t dynarec64_67(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
if(MODREG) { // reg <= reg? that's an invalid operation
DEFAULT;
} else { // mem <= reg
- // should a geted32 be created, to use 32bits regs instead of 64bits?
- addr = geted32(dyn, addr, ninst, nextop, &ed, gd, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted32(dyn, addr, ninst, nextop, &ed, gd, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
if(ed!=gd) {
MOVw_REG(gd, ed);
}
@@ -763,10 +907,10 @@ uintptr_t dynarec64_67(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
ed = xRAX+(nextop&7)+(rex.b<<3);
MOV64xw(ed, i64);
} else { // mem <= i32
- addr = geted32(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, &lock, 0, 4);
+ addr = geted32(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, &lock, 0, 4);
i64 = F32S;
MOV64xw(x3, i64);
- STRxw_U12(x3, ed, fixedaddress);
+ STxw(x3, ed, fixedaddress);
SMWRITELOCK(lock);
}
break;
@@ -846,7 +990,7 @@ uintptr_t dynarec64_67(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
GETED32H(x1, 4);
i64 = F32S;
MOV64xw(x2, i64);
- emit_test32(dyn, ninst, rex, ed, x2, x3, x4);
+ emit_test32(dyn, ninst, rex, ed, x2, x3, x4, x5);
break;
case 2:
INST_NAME("NOT Ed");
@@ -914,9 +1058,9 @@ uintptr_t dynarec64_67(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MOVw_REG(xRAX, x2);
MOVw_REG(xRDX, x4);
} else {
- if(ninst && dyn->insts
- && dyn->insts[ninst-1].x64.addr
- && *(uint8_t*)(dyn->insts[ninst-1].x64.addr)==0x31
+ if(ninst && dyn->insts
+ && dyn->insts[ninst-1].x64.addr
+ && *(uint8_t*)(dyn->insts[ninst-1].x64.addr)==0x31
&& *(uint8_t*)(dyn->insts[ninst-1].x64.addr+1)==0xD2) {
SET_DFNONE(x2);
GETED32(0);
@@ -939,6 +1083,7 @@ uintptr_t dynarec64_67(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
break;
case 7:
INST_NAME("IDIV Ed");
+ NOTEST(x1);
SETFLAGS(X_ALL, SF_SET);
if(!rex.w) {
SET_DFNONE(x2)
@@ -951,7 +1096,7 @@ uintptr_t dynarec64_67(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MOVw_REG(xRDX, x4);
} else {
if(ninst && dyn->insts
- && dyn->insts[ninst-1].x64.addr
+ && dyn->insts[ninst-1].x64.addr
&& *(uint8_t*)(dyn->insts[ninst-1].x64.addr)==0x48
&& *(uint8_t*)(dyn->insts[ninst-1].x64.addr+1)==0x99) {
SET_DFNONE(x2)
diff --git a/src/dynarec/arm64/dynarec_arm64_d8.c b/src/dynarec/arm64/dynarec_arm64_d8.c
index 6aef5a9..a363945 100644
--- a/src/dynarec/arm64/dynarec_arm64_d8.c
+++ b/src/dynarec/arm64/dynarec_arm64_d8.c
@@ -1,7 +1,6 @@
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
-#include <pthread.h>
#include <errno.h>
#include "debug.h"
@@ -31,6 +30,7 @@ uintptr_t dynarec64_D8(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
uint8_t nextop = F8;
uint8_t ed;
int64_t fixedaddress;
+ int unscaled;
int v1, v2;
int s0;
@@ -185,8 +185,8 @@ uintptr_t dynarec64_D8(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("FADD ST0, float[ED]");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, X87_ST0);
s0 = fpu_get_scratch(dyn);
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<2, 3, rex, NULL, 0, 0);
- VLDR32_U12(s0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, 0);
+ VLD32(s0, ed, fixedaddress);
if(ST_IS_F(0)) {
FADDS(v1, v1, s0);
} else {
@@ -198,8 +198,8 @@ uintptr_t dynarec64_D8(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("FMUL ST0, float[ED]");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, X87_ST0);
s0 = fpu_get_scratch(dyn);
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<2, 3, rex, NULL, 0, 0);
- VLDR32_U12(s0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, 0);
+ VLD32(s0, ed, fixedaddress);
if(ST_IS_F(0)) {
FMULS(v1, v1, s0);
} else {
@@ -211,8 +211,8 @@ uintptr_t dynarec64_D8(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("FCOM ST0, float[ED]");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, X87_ST0);
s0 = fpu_get_scratch(dyn);
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<2, 3, rex, NULL, 0, 0);
- VLDR32_U12(s0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, 0);
+ VLD32(s0, ed, fixedaddress);
if(ST_IS_F(0)) {
FCMPS(v1, s0);
} else {
@@ -225,8 +225,8 @@ uintptr_t dynarec64_D8(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("FCOMP ST0, float[ED]");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, X87_ST0);
s0 = fpu_get_scratch(dyn);
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<2, 3, rex, NULL, 0, 0);
- VLDR32_U12(s0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, 0);
+ VLD32(s0, ed, fixedaddress);
if(ST_IS_F(0)) {
FCMPS(v1, s0);
} else {
@@ -240,8 +240,8 @@ uintptr_t dynarec64_D8(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("FSUB ST0, float[ED]");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, X87_ST0);
s0 = fpu_get_scratch(dyn);
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<2, 3, rex, NULL, 0, 0);
- VLDR32_U12(s0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, 0);
+ VLD32(s0, ed, fixedaddress);
if(ST_IS_F(0)) {
FSUBS(v1, v1, s0);
} else {
@@ -253,8 +253,8 @@ uintptr_t dynarec64_D8(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("FSUBR ST0, float[ED]");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, X87_ST0);
s0 = fpu_get_scratch(dyn);
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<2, 3, rex, NULL, 0, 0);
- VLDR32_U12(s0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, 0);
+ VLD32(s0, ed, fixedaddress);
if(ST_IS_F(0)) {
FSUBS(v1, s0, v1);
} else {
@@ -266,8 +266,8 @@ uintptr_t dynarec64_D8(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("FDIV ST0, float[ED]");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, X87_ST0);
s0 = fpu_get_scratch(dyn);
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<2, 3, rex, NULL, 0, 0);
- VLDR32_U12(s0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, 0);
+ VLD32(s0, ed, fixedaddress);
if(ST_IS_F(0)) {
FDIVS(v1, v1, s0);
} else {
@@ -279,8 +279,8 @@ uintptr_t dynarec64_D8(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("FDIVR ST0, float[ED]");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, X87_ST0);
s0 = fpu_get_scratch(dyn);
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<2, 3, rex, NULL, 0, 0);
- VLDR32_U12(s0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, 0);
+ VLD32(s0, ed, fixedaddress);
if(ST_IS_F(0)) {
FDIVS(v1, s0, v1);
} else {
diff --git a/src/dynarec/arm64/dynarec_arm64_d9.c b/src/dynarec/arm64/dynarec_arm64_d9.c
index 25587a9..fcb44d1 100644
--- a/src/dynarec/arm64/dynarec_arm64_d9.c
+++ b/src/dynarec/arm64/dynarec_arm64_d9.c
@@ -1,7 +1,6 @@
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
-#include <pthread.h>
#include <errno.h>
#include "debug.h"
@@ -33,6 +32,7 @@ uintptr_t dynarec64_D9(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
uint8_t wback, wb1;
uint8_t u8;
int64_t fixedaddress;
+ int unscaled;
int v1, v2;
int s0;
int i1, i2, i3;
@@ -180,21 +180,21 @@ uintptr_t dynarec64_D9(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("F2XM1");
MESSAGE(LOG_DUMP, "Need Optimization\n");
x87_forget(dyn, ninst, x1, x2, 0);
- CALL(arm_f2xm1, -1);
+ CALL(native_f2xm1, -1);
break;
case 0xF1:
INST_NAME("FYL2X");
MESSAGE(LOG_DUMP, "Need Optimization\n");
x87_forget(dyn, ninst, x1, x2, 0);
x87_forget(dyn, ninst, x1, x2, 1);
- CALL(arm_fyl2x, -1);
+ CALL(native_fyl2x, -1);
x87_do_pop(dyn, ninst, x3);
break;
case 0xF2:
INST_NAME("FPTAN");
MESSAGE(LOG_DUMP, "Need Optimization\n");
x87_forget(dyn, ninst, x1, x2, 0);
- CALL(arm_ftan, -1);
+ CALL(native_ftan, -1);
v1 = x87_do_push(dyn, ninst, x1, NEON_CACHE_ST_F);
if(ST_IS_F(0)) {
FMOVS_8(v1, 0b01110000);
@@ -207,7 +207,7 @@ uintptr_t dynarec64_D9(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MESSAGE(LOG_DUMP, "Need Optimization\n");
x87_forget(dyn, ninst, x1, x2, 0);
x87_forget(dyn, ninst, x1, x2, 1);
- CALL(arm_fpatan, -1);
+ CALL(native_fpatan, -1);
x87_do_pop(dyn, ninst, x3);
break;
case 0xF4:
@@ -215,14 +215,14 @@ uintptr_t dynarec64_D9(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MESSAGE(LOG_DUMP, "Need Optimization\n");
x87_do_push_empty(dyn, ninst, 0);
x87_forget(dyn, ninst, x1, x2, 1);
- CALL(arm_fxtract, -1);
+ CALL(native_fxtract, -1);
break;
case 0xF5:
INST_NAME("FPREM1");
MESSAGE(LOG_DUMP, "Need Optimization\n");
x87_forget(dyn, ninst, x1, x2, 0);
x87_forget(dyn, ninst, x1, x2, 1);
- CALL(arm_fprem1, -1);
+ CALL(native_fprem1, -1);
break;
case 0xF6:
INST_NAME("FDECSTP");
@@ -245,14 +245,14 @@ uintptr_t dynarec64_D9(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MESSAGE(LOG_DUMP, "Need Optimization\n");
x87_forget(dyn, ninst, x1, x2, 0);
x87_forget(dyn, ninst, x1, x2, 1);
- CALL(arm_fprem, -1);
+ CALL(native_fprem, -1);
break;
case 0xF9:
INST_NAME("FYL2XP1");
MESSAGE(LOG_DUMP, "Need Optimization\n");
x87_forget(dyn, ninst, x1, x2, 0);
x87_forget(dyn, ninst, x1, x2, 1);
- CALL(arm_fyl2xp1, -1);
+ CALL(native_fyl2xp1, -1);
x87_do_pop(dyn, ninst, x3);
break;
case 0xFA:
@@ -269,7 +269,7 @@ uintptr_t dynarec64_D9(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MESSAGE(LOG_DUMP, "Need Optimization\n");
x87_do_push_empty(dyn, ninst, 0);
x87_forget(dyn, ninst, x1, x2, 1);
- CALL(arm_fsincos, -1);
+ CALL(native_fsincos, -1);
break;
case 0xFC:
INST_NAME("FRNDINT");
@@ -277,7 +277,7 @@ uintptr_t dynarec64_D9(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MESSAGE(LOG_DUMP, "Need Optimization\n");
// use C helper for now, nothing staightforward is available
x87_forget(dyn, ninst, x1, x2, 0);
- CALL(arm_frndint, -1);
+ CALL(native_frndint, -1);
#else
v1 = x87_get_st(dyn, ninst, x1, x2, 0, X87_ST0);
u8 = x87_setround(dyn, ninst, x1, x2, x3);
@@ -294,19 +294,19 @@ uintptr_t dynarec64_D9(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MESSAGE(LOG_DUMP, "Need Optimization\n");
x87_forget(dyn, ninst, x1, x2, 0);
x87_forget(dyn, ninst, x1, x2, 1);
- CALL(arm_fscale, -1);
+ CALL(native_fscale, -1);
break;
case 0xFE:
INST_NAME("FSIN");
MESSAGE(LOG_DUMP, "Need Optimization\n");
x87_forget(dyn, ninst, x1, x2, 0);
- CALL(arm_fsin, -1);
+ CALL(native_fsin, -1);
break;
case 0xFF:
INST_NAME("FCOS");
MESSAGE(LOG_DUMP, "Need Optimization\n");
x87_forget(dyn, ninst, x1, x2, 0);
- CALL(arm_fcos, -1);
+ CALL(native_fcos, -1);
break;
@@ -328,8 +328,8 @@ uintptr_t dynarec64_D9(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
case 0:
INST_NAME("FLD ST0, float[ED]");
v1 = x87_do_push(dyn, ninst, x1, box64_dynarec_x87double?NEON_CACHE_ST_D:NEON_CACHE_ST_F);
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<2, 3, rex, NULL, 0, 0);
- VLDR32_U12(v1, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, 0);
+ VLD32(v1, ed, fixedaddress);
if(!ST_IS_F(0)) {
FCVT_D_S(v1, v1);
}
@@ -343,24 +343,24 @@ uintptr_t dynarec64_D9(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
s0 = fpu_get_scratch(dyn);
FCVT_S_D(s0, v1);
}
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<2, 3, rex, NULL, 0, 0);
- VSTR32_U12(s0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, 0);
+ VST32(s0, ed, fixedaddress);
break;
case 3:
INST_NAME("FSTP float[ED], ST0");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_F);
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<2, 3, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, 0);
if(!ST_IS_F(0)) {
FCVT_S_D(v1, v1);
}
- VSTR32_U12(v1, ed, fixedaddress);
+ VST32(v1, ed, fixedaddress);
x87_do_pop(dyn, ninst, x3);
break;
case 4:
INST_NAME("FLDENV Ed");
MESSAGE(LOG_DUMP, "Need Optimization\n");
fpu_purgecache(dyn, ninst, 0, x1, x2, x3); // maybe only x87, not SSE?
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
if(ed!=x1) {
MOVx_REG(x1, ed);
}
@@ -376,7 +376,7 @@ uintptr_t dynarec64_D9(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("FNSTENV Ed");
MESSAGE(LOG_DUMP, "Need Optimization\n");
fpu_purgecache(dyn, ninst, 0, x1, x2, x3); // maybe only x87, not SSE?
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
if(ed!=x1) {
MOVx_REG(x1, ed);
}
@@ -385,7 +385,7 @@ uintptr_t dynarec64_D9(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
break;
case 7:
INST_NAME("FNSTCW Ew");
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<1, 1, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<1, 1, rex, NULL, 0, 0);
ed = x1;
wb1 = 1;
LDRH_U12(x1, xEmu, offsetof(x64emu_t, cw));
diff --git a/src/dynarec/arm64/dynarec_arm64_db.c b/src/dynarec/arm64/dynarec_arm64_db.c
index 4533c83..8974351 100644
--- a/src/dynarec/arm64/dynarec_arm64_db.c
+++ b/src/dynarec/arm64/dynarec_arm64_db.c
@@ -1,7 +1,6 @@
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
-#include <pthread.h>
#include <errno.h>
#include "debug.h"
@@ -33,6 +32,7 @@ uintptr_t dynarec64_DB(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
uint8_t wback;
uint8_t u8;
int64_t fixedaddress;
+ int unscaled;
int v1, v2;
int s0;
int64_t j64;
@@ -189,15 +189,15 @@ uintptr_t dynarec64_DB(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
case 0:
INST_NAME("FILD ST0, Ed");
v1 = x87_do_push(dyn, ninst, x1, NEON_CACHE_ST_D);
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<2, 3, rex, NULL, 0, 0);
- VLDR32_U12(v1, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, 0);
+ VLD32(v1, ed, fixedaddress);
SXTL_32(v1, v1); // i32 -> i64
SCVTFDD(v1, v1); // i64 -> double
break;
case 1:
INST_NAME("FISTTP Ed, ST0");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_D);
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0xfff<<2, 3, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, 0);
s0 = fpu_get_scratch(dyn);
#if 0
ed = x1;
@@ -211,11 +211,11 @@ uintptr_t dynarec64_DB(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
FRINTZD(s0, v1);
VFCVTZSd(s0, s0);
SQXTN_S_D(s0, s0);
- VSTR32_U12(s0, wback, fixedaddress);
+ VST32(s0, wback, fixedaddress);
MRS_fpsr(x5); // get back FPSR to check the IOC bit
TBZ_MARK3(x5, FPSR_IOC);
MOV32w(x5, 0x80000000);
- STRw_U12(x5, wback, fixedaddress);
+ STW(x5, wback, fixedaddress);
MARK3;
#endif
x87_do_pop(dyn, ninst, x3);
@@ -224,7 +224,7 @@ uintptr_t dynarec64_DB(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("FIST Ed, ST0");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_D);
u8 = x87_setround(dyn, ninst, x1, x2, x4); // x1 have the modified RPSCR reg
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0xfff<<2, 3, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, 0);
s0 = fpu_get_scratch(dyn);
#if 0
ed = x1;
@@ -238,11 +238,11 @@ uintptr_t dynarec64_DB(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
FRINTXD(s0, v1);
VFCVTZSd(s0, s0);
SQXTN_S_D(s0, s0);
- VSTR32_U12(s0, wback, fixedaddress);
+ VST32(s0, wback, fixedaddress);
MRS_fpsr(x5); // get back FPSR to check the IOC bit
TBZ_MARK3(x5, FPSR_IOC);
MOV32w(x5, 0x80000000);
- STRw_U12(x5, wback, fixedaddress);
+ STW(x5, wback, fixedaddress);
MARK3;
#endif
x87_restoreround(dyn, ninst, u8);
@@ -251,7 +251,7 @@ uintptr_t dynarec64_DB(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("FISTP Ed, ST0");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_D);
u8 = x87_setround(dyn, ninst, x1, x2, x4); // x1 have the modified RPSCR reg
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0xfff<<2, 3, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, 0);
s0 = fpu_get_scratch(dyn);
#if 0
ed = x1;
@@ -265,11 +265,11 @@ uintptr_t dynarec64_DB(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
FRINTXD(s0, v1);
VFCVTZSd(s0, s0);
SQXTN_S_D(s0, s0);
- VSTR32_U12(s0, wback, fixedaddress);
+ VST32(s0, wback, fixedaddress);
MRS_fpsr(x5); // get back FPSR to check the IOC bit
TBZ_MARK3(x5, FPSR_IOC);
MOV32w(x5, 0x80000000);
- STRw_U12(x5, wback, fixedaddress);
+ STW(x5, wback, fixedaddress);
MARK3;
#endif
x87_restoreround(dyn, ninst, u8);
@@ -277,7 +277,7 @@ uintptr_t dynarec64_DB(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
break;
case 5:
INST_NAME("FLD tbyte");
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
if((PK(0)==0xDB && ((PK(1)>>3)&7)==7) || (PK(0)>=0x40 && PK(0)<=0x4f && PK(1)==0xDB && ((PK(2)>>3)&7)==7)) {
// the FLD is immediatly followed by an FSTP
LDRx_U12(x5, ed, 0);
@@ -291,20 +291,19 @@ uintptr_t dynarec64_DB(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
} else
rex.rex = 0;
nextop = F8; //modrm
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
STRx_U12(x5, ed, 0);
STRH_U12(x6, ed, 8);
} else {
if(box64_x87_no80bits) {
v1 = x87_do_push(dyn, ninst, x1, NEON_CACHE_ST_D);
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
VLDR64_U12(v1, ed, fixedaddress);
} else {
if(ed!=x1) {
MOVx_REG(x1, ed);
}
x87_do_push_empty(dyn, ninst, x3);
- CALL(arm_fld, -1);
+ CALL(native_fld, -1);
}
}
break;
@@ -312,20 +311,20 @@ uintptr_t dynarec64_DB(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("FSTP tbyte");
if(box64_x87_no80bits) {
v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_D);
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
- VSTR64_U12(v1, wback, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
+ VST64(v1, wback, fixedaddress);
} else {
#if 0
x87_forget(dyn, ninst, x1, x3, 0);
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
if(ed!=x1) {
MOVx_REG(x1, ed);
}
- CALL(arm_fstp, -1);
+ CALL(native_fstp, -1);
#else
// Painfully long, straight conversion from the C code, shoud be optimized
v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_D);
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
FMOVxD(x1, v1);
// do special value first
TSTx_mask(x1, 1, 0b00000, 0b111110); //0x7fffffffffffffffL
diff --git a/src/dynarec/arm64/dynarec_arm64_dc.c b/src/dynarec/arm64/dynarec_arm64_dc.c
index c729ed0..bd6c98d 100644
--- a/src/dynarec/arm64/dynarec_arm64_dc.c
+++ b/src/dynarec/arm64/dynarec_arm64_dc.c
@@ -1,7 +1,6 @@
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
-#include <pthread.h>
#include <errno.h>
#include "debug.h"
@@ -31,6 +30,7 @@ uintptr_t dynarec64_DC(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
uint8_t nextop = F8;
uint8_t wback;
int64_t fixedaddress;
+ int unscaled;
int v1, v2;
MAYUSE(v2);
@@ -182,24 +182,24 @@ uintptr_t dynarec64_DC(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("FADD ST0, double[ED]");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_D);
v2 = fpu_get_scratch(dyn);
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
- VLDR64_U12(v2, wback, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
+ VLD64(v2, wback, fixedaddress);
FADDD(v1, v1, v2);
break;
case 1:
INST_NAME("FMUL ST0, double[ED]");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_D);
v2 = fpu_get_scratch(dyn);
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
- VLDR64_U12(v2, wback, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
+ VLD64(v2, wback, fixedaddress);
FMULD(v1, v1, v2);
break;
case 2:
INST_NAME("FCOM ST0, double[ED]");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_D);
v2 = fpu_get_scratch(dyn);
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
- VLDR64_U12(v2, wback, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
+ VLD64(v2, wback, fixedaddress);
FCMPD(v1, v2);
FCOM(x1, x2, x3);
break;
@@ -207,8 +207,8 @@ uintptr_t dynarec64_DC(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("FCOMP ST0, double[ED]");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_D);
v2 = fpu_get_scratch(dyn);
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
- VLDR64_U12(v2, wback, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
+ VLD64(v2, wback, fixedaddress);
FCMPD(v1, v2);
FCOM(x1, x2, x3);
x87_do_pop(dyn, ninst, x3);
@@ -217,32 +217,32 @@ uintptr_t dynarec64_DC(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("FSUB ST0, double[ED]");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_D);
v2 = fpu_get_scratch(dyn);
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
- VLDR64_U12(v2, wback, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
+ VLD64(v2, wback, fixedaddress);
FSUBD(v1, v1, v2);
break;
case 5:
INST_NAME("FSUBR ST0, double[ED]");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_D);
v2 = fpu_get_scratch(dyn);
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
- VLDR64_U12(v2, wback, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
+ VLD64(v2, wback, fixedaddress);
FSUBD(v1, v2, v1);
break;
case 6:
INST_NAME("FDIV ST0, double[ED]");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_D);
v2 = fpu_get_scratch(dyn);
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
- VLDR64_U12(v2, wback, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
+ VLD64(v2, wback, fixedaddress);
FDIVD(v1, v1, v2);
break;
case 7:
INST_NAME("FDIVR ST0, double[ED]");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_D);
v2 = fpu_get_scratch(dyn);
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
- VLDR64_U12(v2, wback, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
+ VLD64(v2, wback, fixedaddress);
FDIVD(v1, v2, v1);
break;
}
diff --git a/src/dynarec/arm64/dynarec_arm64_dd.c b/src/dynarec/arm64/dynarec_arm64_dd.c
index dfb1750..b269791 100644
--- a/src/dynarec/arm64/dynarec_arm64_dd.c
+++ b/src/dynarec/arm64/dynarec_arm64_dd.c
@@ -1,7 +1,6 @@
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
-#include <pthread.h>
#include <errno.h>
#include "debug.h"
@@ -31,6 +30,7 @@ uintptr_t dynarec64_DD(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
uint8_t nextop = F8;
uint8_t ed;
int64_t fixedaddress;
+ int unscaled;
int v1, v2;
int s0;
int64_t j64;
@@ -161,13 +161,13 @@ uintptr_t dynarec64_DD(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
case 0:
INST_NAME("FLD double");
v1 = x87_do_push(dyn, ninst, x3, NEON_CACHE_ST_D);
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
- VLDR64_U12(v1, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
+ VLD64(v1, ed, fixedaddress);
break;
case 1:
INST_NAME("FISTTP i64, ST0");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_D);
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
s0 = fpu_get_scratch(dyn);
#if 0
// those are ARM 8.5 opcode!
@@ -180,11 +180,11 @@ uintptr_t dynarec64_DD(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MSR_fpsr(x5);
FRINTRRD(s0, v1, 3);
FCVTZSxD(x2, s0);
- STRx_U12(x2, ed, fixedaddress);
+ STx(x2, ed, fixedaddress);
MRS_fpsr(x5); // get back FPSR to check the IOC bit
TBZ_MARK3(x5, FPSR_IOC);
ORRx_mask(x5, xZR, 1, 1, 0); //0x8000000000000000
- STRw_U12(x5, ed, fixedaddress);
+ STx(x5, ed, fixedaddress);
MARK3;
#endif
x87_do_pop(dyn, ninst, x3);
@@ -192,36 +192,36 @@ uintptr_t dynarec64_DD(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
case 2:
INST_NAME("FST double");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_D);
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
- VSTR64_U12(v1, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
+ VST64(v1, ed, fixedaddress);
break;
case 3:
INST_NAME("FSTP double");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_D);
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
- VSTR64_U12(v1, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
+ VST64(v1, ed, fixedaddress);
x87_do_pop(dyn, ninst, x3);
break;
case 4:
INST_NAME("FRSTOR m108byte");
MESSAGE(LOG_DUMP, "Need Optimization\n");
fpu_purgecache(dyn, ninst, 0, x1, x2, x3);
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
if(ed!=x1) {MOVx_REG(x1, ed);}
- CALL(arm_frstor, -1);
+ CALL(native_frstor, -1);
break;
case 6:
INST_NAME("FSAVE m108byte");
MESSAGE(LOG_DUMP, "Need Optimization\n");
fpu_purgecache(dyn, ninst, 0, x1, x2, x3);
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
if(ed!=x1) {MOVx_REG(x1, ed);}
- CALL(arm_fsave, -1);
+ CALL(native_fsave, -1);
break;
case 7:
INST_NAME("FNSTSW m2byte");
fpu_purgecache(dyn, ninst, 0, x1, x2, x3);
- addr = geted(dyn, addr, ninst, nextop, &ed, x4, &fixedaddress, 0xfff<<1, 1, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x4, &fixedaddress, &unscaled, 0xfff<<1, 1, rex, NULL, 0, 0);
LDRw_U12(x2, xEmu, offsetof(x64emu_t, top));
LDRH_U12(x3, xEmu, offsetof(x64emu_t, sw));
if(dyn->n.x87stack) {
@@ -234,7 +234,7 @@ uintptr_t dynarec64_DD(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
ANDw_mask(x2, x2, 0, 2);
}
BFIw(x3, x2, 11, 3); // inject TOP at bit 11 (3 bits)
- STRH_U12(x3, ed, fixedaddress); // store whole sw flags
+ STH(x3, ed, fixedaddress); // store whole sw flags
break;
default:
DEFAULT;
diff --git a/src/dynarec/arm64/dynarec_arm64_de.c b/src/dynarec/arm64/dynarec_arm64_de.c
index ae7fccb..c045d23 100644
--- a/src/dynarec/arm64/dynarec_arm64_de.c
+++ b/src/dynarec/arm64/dynarec_arm64_de.c
@@ -1,7 +1,6 @@
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
-#include <pthread.h>
#include <errno.h>
#include "debug.h"
@@ -31,6 +30,7 @@ uintptr_t dynarec64_DE(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
uint8_t nextop = F8;
uint8_t wback;
int64_t fixedaddress;
+ int unscaled;
int v1, v2;
MAYUSE(v2);
@@ -184,15 +184,16 @@ uintptr_t dynarec64_DE(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
case 0xDD:
case 0xDE:
case 0xDF:
- return 0;
+ DEFAULT;
+ break;
default:
switch((nextop>>3)&7) {
case 0:
INST_NAME("FIADD ST0, word[ED]");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_D);
v2 = fpu_get_scratch(dyn);
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<1, 1, rex, NULL, 0, 0);
- VLDR16_U12(v2, wback, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<1, 1, rex, NULL, 0, 0);
+ VLD16(v2, wback, fixedaddress);
SXTL_16(v2, v2);
SXTL_32(v2, v2);
SCVTFDD(v2, v2);
@@ -202,8 +203,8 @@ uintptr_t dynarec64_DE(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("FIMUL ST0, word[ED]");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_D);
v2 = fpu_get_scratch(dyn);
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<1, 1, rex, NULL, 0, 0);
- VLDR16_U12(v2, wback, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<1, 1, rex, NULL, 0, 0);
+ VLD16(v2, wback, fixedaddress);
SXTL_16(v2, v2);
SXTL_32(v2, v2);
SCVTFDD(v2, v2);
@@ -213,8 +214,8 @@ uintptr_t dynarec64_DE(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("FICOM ST0, word[ED]");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_D);
v2 = fpu_get_scratch(dyn);
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<1, 1, rex, NULL, 0, 0);
- VLDR16_U12(v2, wback, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<1, 1, rex, NULL, 0, 0);
+ VLD16(v2, wback, fixedaddress);
SXTL_16(v2, v2);
SXTL_32(v2, v2);
SCVTFDD(v2, v2);
@@ -225,8 +226,8 @@ uintptr_t dynarec64_DE(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("FICOMP ST0, word[ED]");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_D);
v2 = fpu_get_scratch(dyn);
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<1, 1, rex, NULL, 0, 0);
- VLDR16_U12(v2, wback, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<1, 1, rex, NULL, 0, 0);
+ VLD16(v2, wback, fixedaddress);
SXTL_16(v2, v2);
SXTL_32(v2, v2);
SCVTFDD(v2, v2);
@@ -238,8 +239,8 @@ uintptr_t dynarec64_DE(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("FISUB ST0, word[ED]");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_D);
v2 = fpu_get_scratch(dyn);
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<1, 1, rex, NULL, 0, 0);
- VLDR16_U12(v2, wback, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<1, 1, rex, NULL, 0, 0);
+ VLD16(v2, wback, fixedaddress);
SXTL_16(v2, v2);
SXTL_32(v2, v2);
SCVTFDD(v2, v2);
@@ -249,8 +250,8 @@ uintptr_t dynarec64_DE(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("FISUBR ST0, word[ED]");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_D);
v2 = fpu_get_scratch(dyn);
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<1, 1, rex, NULL, 0, 0);
- VLDR16_U12(v2, wback, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<1, 1, rex, NULL, 0, 0);
+ VLD16(v2, wback, fixedaddress);
SXTL_16(v2, v2);
SXTL_32(v2, v2);
SCVTFDD(v2, v2);
@@ -260,8 +261,8 @@ uintptr_t dynarec64_DE(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("FIDIV ST0, word[ED]");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_D);
v2 = fpu_get_scratch(dyn);
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<1, 1, rex, NULL, 0, 0);
- VLDR16_U12(v2, wback, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<1, 1, rex, NULL, 0, 0);
+ VLD16(v2, wback, fixedaddress);
SXTL_16(v2, v2);
SXTL_32(v2, v2);
SCVTFDD(v2, v2);
@@ -271,8 +272,8 @@ uintptr_t dynarec64_DE(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("FIDIVR ST0, word[ED]");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_D);
v2 = fpu_get_scratch(dyn);
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<1, 1, rex, NULL, 0, 0);
- VLDR16_U12(v2, wback, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<1, 1, rex, NULL, 0, 0);
+ VLD16(v2, wback, fixedaddress);
SXTL_16(v2, v2);
SXTL_32(v2, v2);
SCVTFDD(v2, v2);
diff --git a/src/dynarec/arm64/dynarec_arm64_df.c b/src/dynarec/arm64/dynarec_arm64_df.c
index 2cbcfe4..c1ae66a 100644
--- a/src/dynarec/arm64/dynarec_arm64_df.c
+++ b/src/dynarec/arm64/dynarec_arm64_df.c
@@ -1,7 +1,6 @@
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
-#include <pthread.h>
#include <errno.h>
#include "debug.h"
@@ -34,6 +33,7 @@ uintptr_t dynarec64_DF(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
int s0;
int64_t j64;
int64_t fixedaddress;
+ int unscaled;
MAYUSE(s0);
MAYUSE(v2);
@@ -59,7 +59,8 @@ uintptr_t dynarec64_DF(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
LDRw_U12(x2, xEmu, offsetof(x64emu_t, top));
LDRH_U12(x1, xEmu, offsetof(x64emu_t, sw));
BFIw(x1, x2, 11, 3); // inject top
- BFIw(xRAX, x1, 0, 16);
+ STRH_U12(x1, xEmu, offsetof(x64emu_t, sw));
+ BFIx(xRAX, x1, 0, 16);
break;
case 0xE8:
case 0xE9:
@@ -151,8 +152,8 @@ uintptr_t dynarec64_DF(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
case 0:
INST_NAME("FILD ST0, Ew");
v1 = x87_do_push(dyn, ninst, x1, NEON_CACHE_ST_F);
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<1, 1, rex, NULL, 0, 0);
- LDRSHw_U12(x1, wback, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<1, 1, rex, NULL, 0, 0);
+ LDSHw(x1, wback, fixedaddress);
if(ST_IS_F(0)) {
SCVTFSw(v1, x1);
} else {
@@ -162,7 +163,7 @@ uintptr_t dynarec64_DF(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
case 1:
INST_NAME("FISTTP Ew, ST0");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_F);
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0xfff<<1, 1, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, &unscaled, 0xfff<<1, 1, rex, NULL, 0, 0);
ed = x1;
s0 = fpu_get_scratch(dyn);
#if 0
@@ -172,10 +173,11 @@ uintptr_t dynarec64_DF(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
VFCVTZSd(s0, s0);
SQXTN_S_D(s0, s0);
SQXTN_H_S(s0, s0);
- VSTR16_U12(s0, wback, fixedaddress);
+ VST16(s0, wback, fixedaddress);
#else
MRS_fpsr(x5);
BFCw(x5, FPSR_IOC, 1); // reset IOC bit
+ BFCw(x5, FPSR_QC, 1); // reset QC bit
MSR_fpsr(x5);
if(ST_IS_F(0)) {
VFCVTZSs(s0, v1);
@@ -183,13 +185,16 @@ uintptr_t dynarec64_DF(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
VFCVTZSd(s0, v1);
SQXTN_S_D(s0, s0);
}
- SQXTN_H_S(s0, s0);
- VSTR16_U12(s0, wback, fixedaddress);
+ VMOVSto(x3, s0, 0);
MRS_fpsr(x5); // get back FPSR to check the IOC bit
- TBZ_MARK3(x5, FPSR_IOC);
- MOV32w(x5, 0x8000);
- STRH_U12(x5, wback, fixedaddress);
+ TBNZ_MARK2(x5, FPSR_IOC);
+ SXTHw(x5, x3); // check if 16bits value is fine
+ SUBw_REG(x5, x5, x3);
+ CBZw_MARK3(x5);
+ MARK2;
+ MOV32w(x3, 0x8000);
MARK3;
+ STH(x3, wback, fixedaddress);
#endif
x87_do_pop(dyn, ninst, x3);
break;
@@ -197,7 +202,7 @@ uintptr_t dynarec64_DF(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("FIST Ew, ST0");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_F);
u8 = x87_setround(dyn, ninst, x1, x2, x4);
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0xfff<<1, 1, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, &unscaled, 0xfff<<1, 1, rex, NULL, 0, 0);
ed = x1;
s0 = fpu_get_scratch(dyn);
#if 0
@@ -206,10 +211,11 @@ uintptr_t dynarec64_DF(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
VFCVTZSd(s0, s0);
SQXTN_S_D(s0, s0);
SQXTN_H_S(s0, s0);
- VSTR16_U12(s0, wback, fixedaddress);
+ VST16(s0, wback, fixedaddress);
#else
MRS_fpsr(x5);
BFCw(x5, FPSR_IOC, 1); // reset IOC bit
+ BFCw(x5, FPSR_QC, 1); // reset QC bit
MSR_fpsr(x5);
if(ST_IS_F(0)) {
FRINTXS(s0, v1);
@@ -219,13 +225,16 @@ uintptr_t dynarec64_DF(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
VFCVTZSd(s0, s0);
SQXTN_S_D(s0, s0);
}
- SQXTN_H_S(s0, s0);
- VSTR16_U12(s0, wback, fixedaddress);
+ VMOVSto(x3, s0, 0);
MRS_fpsr(x5); // get back FPSR to check the IOC bit
- TBZ_MARK3(x5, FPSR_IOC);
- MOV32w(x5, 0x8000);
- STRH_U12(x5, wback, fixedaddress);
+ TBNZ_MARK2(x5, FPSR_IOC);
+ SXTHw(x5, x3); // check if 16bits value is fine
+ SUBw_REG(x5, x5, x3);
+ CBZw_MARK3(x5);
+ MARK2;
+ MOV32w(x3, 0x8000);
MARK3;
+ STH(x3, wback, fixedaddress);
#endif
x87_restoreround(dyn, ninst, u8);
break;
@@ -233,7 +242,7 @@ uintptr_t dynarec64_DF(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("FISTP Ew, ST0");
v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_F);
u8 = x87_setround(dyn, ninst, x1, x2, x4);
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0xfff<<1, 1, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, &unscaled, 0xfff<<1, 1, rex, NULL, 0, 0);
ed = x1;
s0 = fpu_get_scratch(dyn);
#if 0
@@ -242,7 +251,7 @@ uintptr_t dynarec64_DF(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
VFCVTZSd(s0, s0);
SQXTN_S_D(s0, s0);
SQXTN_H_S(s0, s0);
- VSTR16_U12(s0, wback, fixedaddress);
+ VST16(s0, wback, fixedaddress);
#else
MRS_fpsr(x5);
BFCw(x5, FPSR_IOC, 1); // reset IOC bit
@@ -255,13 +264,16 @@ uintptr_t dynarec64_DF(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
VFCVTZSd(s0, s0);
SQXTN_S_D(s0, s0);
}
- SQXTN_H_S(s0, s0);
- VSTR16_U12(s0, wback, fixedaddress);
+ VMOVSto(x3, s0, 0);
MRS_fpsr(x5); // get back FPSR to check the IOC bit
- TBZ_MARK3(x5, FPSR_IOC);
- MOV32w(x5, 0x8000);
- STRH_U12(x5, wback, fixedaddress);
+ TBNZ_MARK2(x5, FPSR_IOC);
+ SXTHw(x5, x3); // check if 16bits value is fine
+ SUBw_REG(x5, x5, x3);
+ CBZw_MARK3(x5);
+ MARK2;
+ MOV32w(x3, 0x8000);
MARK3;
+ STH(x3, wback, fixedaddress);
#endif
x87_do_pop(dyn, ninst, x3);
x87_restoreround(dyn, ninst, u8);
@@ -269,50 +281,100 @@ uintptr_t dynarec64_DF(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
case 4:
INST_NAME("FBLD ST0, tbytes");
x87_do_push_empty(dyn, ninst, x1);
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
if(ed!=x1) {MOVx_REG(x1, ed);}
CALL(fpu_fbld, -1);
break;
case 5:
INST_NAME("FILD ST0, i64");
- v1 = x87_do_push(dyn, ninst, x1, NEON_CACHE_ST_D);
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
- LDRx_U12(x1, wback, fixedaddress);
- SCVTFDx(v1, x1);
+ v1 = x87_do_push(dyn, ninst, x1, NEON_CACHE_ST_I64);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
+ VLD64(v1, wback, fixedaddress);
+ if(!ST_IS_I64(0)) {
+ if(rex.is32bits) {
+ // need to also feed the STll stuff...
+ ADDx_U12(x4, xEmu, offsetof(x64emu_t, fpu_ll));
+ LDRw_U12(x1, xEmu, offsetof(x64emu_t, top));
+ int a = 0 - dyn->n.x87stack;
+ if(a) {
+ if(a<0) {
+ SUBw_U12(x1, x1, -a);
+ } else {
+ ADDw_U12(x1, x1, a);
+ }
+ ANDw_mask(x1, x1, 0, 2); //mask=7
+ }
+ ADDx_REG_LSL(x1, x4, x1, 4); // fpu_ll is 2 i64
+ VSTR64_U12(v1, x1, 8); // ll
+ }
+ SCVTFDD(v1, v1);
+ if(rex.is32bits) {
+ VSTR64_U12(v1, x1, 0); // ref
+ }
+ }
break;
case 6:
INST_NAME("FBSTP tbytes, ST0");
x87_forget(dyn, ninst, x1, x2, 0);
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0, 0, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, NULL, 0, 0, rex, NULL, 0, 0);
if(ed!=x1) {MOVx_REG(x1, ed);}
CALL(fpu_fbst, -1);
x87_do_pop(dyn, ninst, x3);
break;
case 7:
INST_NAME("FISTP i64, ST0");
- v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_D);
- u8 = x87_setround(dyn, ninst, x1, x2, x4);
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
+ v1 = x87_get_st(dyn, ninst, x1, x2, 0, NEON_CACHE_ST_I64);
+ if(!ST_IS_I64(0)) {
+ u8 = x87_setround(dyn, ninst, x1, x2, x4);
+ }
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
ed = x1;
s0 = fpu_get_scratch(dyn);
- #if 0
- FRINT64XD(s0, v1);
- VFCVTZSd(s0, s0);
- VSTR64_U12(s0, wback, fixedaddress);
- #else
- MRS_fpsr(x5);
- BFCw(x5, FPSR_IOC, 1); // reset IOC bit
- MSR_fpsr(x5);
- FRINTXD(s0, v1);
- VFCVTZSd(s0, s0);
- VSTR64_U12(s0, wback, fixedaddress);
- MRS_fpsr(x5); // get back FPSR to check the IOC bit
- TBZ_MARK3(x5, FPSR_IOC);
- ORRx_mask(x5, xZR, 1, 1, 0); //0x8000000000000000
- STRx_U12(x5, wback, fixedaddress);
- MARK3;
- #endif
- x87_restoreround(dyn, ninst, u8);
+ if(ST_IS_I64(0)) {
+ VST64(v1, wback, fixedaddress);
+ } else {
+ #if 0
+ FRINT64XD(s0, v1);
+ VFCVTZSd(s0, s0);
+ VSTR64_U12(s0, wback, fixedaddress);
+ #else
+ if(rex.is32bits) {
+ // need to check STll first...
+ ADDx_U12(x5, xEmu, offsetof(x64emu_t, fpu_ll));
+ LDRw_U12(x1, xEmu, offsetof(x64emu_t, top));
+ VMOVQDto(x3, v1, 0);
+ int a = 0 - dyn->n.x87stack;
+ if(a) {
+ if(a<0) {
+ SUBw_U12(x1, x1, -a);
+ } else {
+ ADDw_U12(x1, x1, a);
+ }
+ ANDw_mask(x1, x1, 0, 2); //mask=7
+ }
+ ADDx_REG_LSL(x1, x5, x1, 4); // fpu_ll is 2 i64
+ LDRx_U12(x5, x1, 0); // ref
+ SUBx_REG(x5, x5, x3);
+ CBNZx_MARK2(x5);
+ LDRx_U12(x5, x1, 8); // ll
+ STx(x5, wback, fixedaddress);
+ B_MARK3(c__);
+ MARK2;
+ }
+ MRS_fpsr(x5);
+ BFCw(x5, FPSR_IOC, 1); // reset IOC bit
+ MSR_fpsr(x5);
+ FRINTXD(s0, v1);
+ VFCVTZSd(s0, s0);
+ VST64(s0, wback, fixedaddress);
+ MRS_fpsr(x5); // get back FPSR to check the IOC bit
+ TBZ_MARK3(x5, FPSR_IOC);
+ ORRx_mask(x5, xZR, 1, 1, 0); //0x8000000000000000
+ STx(x5, wback, fixedaddress);
+ MARK3;
+ #endif
+ x87_restoreround(dyn, ninst, u8);
+ }
x87_do_pop(dyn, ninst, x3);
break;
default:
diff --git a/src/dynarec/arm64/dynarec_arm64_emit_logic.c b/src/dynarec/arm64/dynarec_arm64_emit_logic.c
index 668713a..e8af51f 100755..100644
--- a/src/dynarec/arm64/dynarec_arm64_emit_logic.c
+++ b/src/dynarec/arm64/dynarec_arm64_emit_logic.c
@@ -1,7 +1,6 @@
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
-#include <pthread.h>
#include <errno.h>
#include "debug.h"
@@ -16,7 +15,6 @@
#include "emu/x64run_private.h"
#include "x64trace.h"
#include "dynarec_native.h"
-#include "../tools/bridge_private.h"
#include "arm64_printer.h"
#include "dynarec_arm64_private.h"
diff --git a/src/dynarec/arm64/dynarec_arm64_emit_math.c b/src/dynarec/arm64/dynarec_arm64_emit_math.c
index 8d952d5..f391f3a 100755..100644
--- a/src/dynarec/arm64/dynarec_arm64_emit_math.c
+++ b/src/dynarec/arm64/dynarec_arm64_emit_math.c
@@ -1,7 +1,6 @@
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
-#include <pthread.h>
#include <errno.h>
#include "debug.h"
@@ -16,7 +15,6 @@
#include "emu/x64run_private.h"
#include "x64trace.h"
#include "dynarec_native.h"
-#include "../tools/bridge_private.h"
#include "arm64_printer.h"
#include "dynarec_arm64_private.h"
@@ -432,7 +430,7 @@ void emit_sub8c(dynarec_arm_t* dyn, int ninst, int s1, int c, int s3, int s4, in
}
IFX(X_PEND) {
STRB_U12(s1, xEmu, offsetof(x64emu_t, op1));
- STRB_U12(s3, xEmu, offsetof(x64emu_t, op2));
+ STRB_U12(s5, xEmu, offsetof(x64emu_t, op2));
SET_DF(s3, d_sub8);
} else IFX(X_ALL) {
SET_DFNONE(s3);
diff --git a/src/dynarec/arm64/dynarec_arm64_emit_shift.c b/src/dynarec/arm64/dynarec_arm64_emit_shift.c
index 45add1f..007002f 100755..100644
--- a/src/dynarec/arm64/dynarec_arm64_emit_shift.c
+++ b/src/dynarec/arm64/dynarec_arm64_emit_shift.c
@@ -1,7 +1,6 @@
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
-#include <pthread.h>
#include <errno.h>
#include "debug.h"
@@ -16,7 +15,6 @@
#include "emu/x64run_private.h"
#include "x64trace.h"
#include "dynarec_native.h"
-#include "../tools/bridge_private.h"
#include "arm64_printer.h"
#include "dynarec_arm64_private.h"
@@ -327,7 +325,7 @@ void emit_ror32c(dynarec_arm_t* dyn, int ninst, rex_t rex, int s1, uint32_t c, i
if(c==1) {
LSRxw(s3, s1, rex.w?62:30);
EORxw_REG_LSR(s3, s3, s3, 1);
- BFIw(xFlags, s4, F_OF, 1);
+ BFIw(xFlags, s3, F_OF, 1);
}
}
}
diff --git a/src/dynarec/arm64/dynarec_arm64_emit_tests.c b/src/dynarec/arm64/dynarec_arm64_emit_tests.c
index 4d032e0..bf19058 100755..100644
--- a/src/dynarec/arm64/dynarec_arm64_emit_tests.c
+++ b/src/dynarec/arm64/dynarec_arm64_emit_tests.c
@@ -1,7 +1,6 @@
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
-#include <pthread.h>
#include <errno.h>
#include "debug.h"
@@ -16,7 +15,6 @@
#include "emu/x64run_private.h"
#include "x64trace.h"
#include "dynarec_native.h"
-#include "../tools/bridge_private.h"
#include "arm64_printer.h"
#include "dynarec_arm64_private.h"
@@ -267,8 +265,8 @@ void emit_cmp8_0(dynarec_arm_t* dyn, int ninst, int s1, int s3, int s4)
}
}
-// emit TEST32 instruction, from test s1, s2, using s3 and s4 as scratch
-void emit_test32(dynarec_arm_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4)
+// emit TEST32 instruction, from test s1, s2, using s3, s4 and s5 as scratch
+void emit_test32(dynarec_arm_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4, int s5)
{
MAYUSE(s1); MAYUSE(s2); MAYUSE(s3); MAYUSE(s4);
IFX_PENDOR0 {
@@ -294,18 +292,11 @@ void emit_test32(dynarec_arm_t* dyn, int ninst, rex_t rex, int s1, int s2, int s
}
// PF: (((emu->x64emu_parity_tab[(res) / 32] >> ((res) % 32)) & 1) == 0)
IFX(X_PF) {
- ANDw_mask(s3, s3, 0b011011, 0b000010); // 0xE0
- LSRw(s3, s3, 5);
- MOV64x(s4, (uintptr_t)GetParityTab());
- LDRw_REG_LSL2(s4, s4, s3);
- ANDw_mask(s3, s1, 0, 0b000100); // 0x1f
- LSRw_REG(s4, s4, s3);
- MVNx_REG(s4, s4);
- BFIw(xFlags, s4, F_PF, 1);
+ emit_pf(dyn, ninst, s3, s4, s5);
}
}
-// emit TEST16 instruction, from test s1, s2, using s3 and s4 as scratch
+// emit TEST16 instruction, from test s1, s2, using s3, s4 and s5 as scratch
void emit_test16(dynarec_arm_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5)
{
MAYUSE(s1); MAYUSE(s2);
@@ -336,7 +327,7 @@ void emit_test16(dynarec_arm_t* dyn, int ninst, int s1, int s2, int s3, int s4,
}
}
-// emit TEST8 instruction, from test s1, s2, using s3 and s4 as scratch
+// emit TEST8 instruction, from test s1, s2, using s3, s4 and s5 as scratch
void emit_test8(dynarec_arm_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5)
{
MAYUSE(s1); MAYUSE(s2);
diff --git a/src/dynarec/arm64/dynarec_arm64_f0.c b/src/dynarec/arm64/dynarec_arm64_f0.c
index dbfc4cc..07e4b76 100644
--- a/src/dynarec/arm64/dynarec_arm64_f0.c
+++ b/src/dynarec/arm64/dynarec_arm64_f0.c
@@ -1,7 +1,6 @@
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
-#include <pthread.h>
#include <errno.h>
#include "debug.h"
@@ -34,6 +33,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
int32_t i32;
int64_t i64, j64;
int64_t fixedaddress;
+ int unscaled;
MAYUSE(eb1);
MAYUSE(eb2);
MAYUSE(gb1);
@@ -46,12 +46,8 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
rep = opcode-0xF1;
opcode = F8;
}
- // REX prefix before the F0 are ignored
- rex.rex = 0;
- while(opcode>=0x40 && opcode<=0x4f) {
- rex.rex = opcode;
- opcode = F8;
- }
+
+ GETREX();
switch(opcode) {
case 0x00:
@@ -65,15 +61,15 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
wback = xRAX + (nextop&7) + (rex.b<<3);
wb2 = 0;
} else {
- wback = (nextop&7);
- wb2 = (wback>>2);
+ wback = (nextop&7);
+ wb2 = (wback>>2);
wback = xRAX+(wback&3);
}
- UBFXw(x1, wback, wb2*8, 8);
+ UBFXw(x1, wback, wb2*8, 8);
emit_add8(dyn, ninst, x1, x2, x4, x3);
BFIx(wback, x1, wb2*8, 8);
- } else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 0);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
MARKLOCK;
LDAXRB(x1, wback);
emit_add8(dyn, ninst, x1, x2, x4, x5);
@@ -92,7 +88,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
ed = xRAX+(nextop&7)+(rex.b<<3);
emit_add32(dyn, ninst, rex, ed, gd, x3, x4);
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
MARKLOCK;
LDAXRxw(x1, wback);
emit_add32(dyn, ninst, rex, x1, gd, x3, x4);
@@ -113,15 +109,15 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
wback = xRAX + (nextop&7) + (rex.b<<3);
wb2 = 0;
} else {
- wback = (nextop&7);
- wb2 = (wback>>2);
+ wback = (nextop&7);
+ wb2 = (wback>>2);
wback = xRAX+(wback&3);
}
- UBFXw(x1, wback, wb2*8, 8);
+ UBFXw(x1, wback, wb2*8, 8);
emit_or8(dyn, ninst, x1, x2, x4, x3);
BFIx(wback, x1, wb2*8, 8);
- } else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 0);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
MARKLOCK;
LDAXRB(x1, wback);
emit_or8(dyn, ninst, x1, x2, x4, x5);
@@ -140,7 +136,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
ed = xRAX+(nextop&7)+(rex.b<<3);
emit_or32(dyn, ninst, rex, ed, gd, x3, x4);
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
MARKLOCK;
LDAXRxw(x1, wback);
emit_or32(dyn, ninst, rex, x1, gd, x3, x4);
@@ -177,8 +173,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
BFIw(xFlags, x4, F_CF, 1);
MOV32w(x4, 1);
LSLxw_REG(x4, x4, x2);
- EORxw_REG(x4, ed, x4);
- CSELxw(ed, ed, x4, cNE);
+ ORRxw_REG(ed, ed, x4);
} else {
// Will fetch only 1 byte, to avoid alignment issue
if(rex.w) {
@@ -187,7 +182,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
ANDw_mask(x2, gd, 0, 0b00010); //mask=0x000000007
}
SMDMB();
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
ASRxw(x1, gd, 3); // r1 = (gd>>3)
ADDx_REG_LSL(x3, wback, x1, 0); //(&ed)+=r1;
MARKLOCK;
@@ -195,12 +190,11 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
ed = x1;
wback = x3;
LSRw_REG(x4, ed, x2);
- ANDSw_mask(x4, x4, 0, 0); //mask=1
+ ANDw_mask(x4, x4, 0, 0); //mask=1
BFIw(xFlags, x4, F_CF, 1);
MOV32w(x4, 1);
LSLw_REG(x4, x4, x2);
- EORw_REG(x4, ed, x4);
- CSELw(ed, ed, x4, cNE);
+ ORRw_REG(ed, ed, x4);
STLXRB(x4, ed, wback);
CBNZw_MARKLOCK(x4);
SMDMB();
@@ -219,11 +213,11 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
if(rex.rex) {
wback = xRAX+(nextop&7)+(rex.b<<3);
wb2 = 0;
- } else {
+ } else {
wback = (nextop&7);
wb2 = (wback>>2)*8;
wback = xRAX+(wback&3);
- }
+ }
UBFXx(x2, wback, wb2, 8);
wb1 = 0;
ed = x2;
@@ -236,7 +230,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
BFIx(xRAX, x2, 0, 8);
B_NEXT_nocond;
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
MARKLOCK;
LDAXRB(x2, wback);
CMPSxw_REG(x6, x2);
@@ -246,7 +240,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
CBNZx_MARKLOCK(x4);
// done
MARK;
- UFLAG_IF {emit_cmp32(dyn, ninst, rex, x6, x2, x3, x4, x5);}
+ UFLAG_IF {emit_cmp8(dyn, ninst, x6, x2, x3, x4, x5);}
BFIx(xRAX, x2, 0, 8);
}
SMDMB();
@@ -275,7 +269,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MOVxw_REG(xRAX, x1);
B_NEXT_nocond;
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
TSTx_mask(wback, 1, 0, 1+rex.w); // mask=3 or 7
B_MARK3(cNE);
// Aligned version
@@ -326,15 +320,14 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
}
LSRxw_REG(x4, ed, x2);
if(rex.w) {
- ANDSx_mask(x4, x4, 1, 0, 0); //mask=1
+ ANDx_mask(x4, x4, 1, 0, 0); //mask=1
} else {
- ANDSw_mask(x4, x4, 0, 0); //mask=1
+ ANDw_mask(x4, x4, 0, 0); //mask=1
}
BFIw(xFlags, x4, F_CF, 1);
MOV32w(x4, 1);
LSLxw_REG(x4, x4, x2);
- EORxw_REG(x4, ed, x4);
- CSELxw(ed, ed, x4, cEQ);
+ BICxw_REG(ed, ed, x4);
} else {
// Will fetch only 1 byte, to avoid alignment issue
if(rex.w) {
@@ -343,20 +336,19 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
ANDw_mask(x2, gd, 0, 0b00010); //mask=0x000000007
}
SMDMB();
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 0);
- ASRxw(x1, gd, 3); // r1 = (gd>>3)
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
+ ASRx(x1, gd, 3); // r1 = (gd>>3)
ADDx_REG_LSL(x3, wback, x1, 0); //(&ed)+=r1;
MARKLOCK;
LDAXRB(x1, wback);
ed = x1;
wback = x3;
LSRw_REG(x4, ed, x2);
- ANDSw_mask(x4, x4, 0, 0); //mask=1
+ ANDw_mask(x4, x4, 0, 0); //mask=1
BFIw(xFlags, x4, F_CF, 1);
MOV32w(x4, 1);
LSLw_REG(x4, x4, x2);
- EORw_REG(x4, ed, x4);
- CSELw(ed, ed, x4, cEQ);
+ ORRw_REG(ed, ed, x4);
STLXRB(x4, ed, wback);
CBNZw_MARKLOCK(x4);
SMDMB();
@@ -378,7 +370,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MOVxw_REG(gd, x1);
emit_add32(dyn, ninst, rex, ed, gd, x3, x4);
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
TSTx_mask(wback, 1, 0, 1+rex.w); // mask=3 or 7
B_MARK(cNE); // unaligned
MARKLOCK;
@@ -415,7 +407,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
INST_NAME("LOCK CMPXCHG8B Gq, Eq");
SETFLAGS(X_ZF, SF_SUBSET);
nextop = F8;
- addr = geted(dyn, addr, ninst, nextop, &wback, x1, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x1, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
SMDMB();
MARKLOCK;
LDAXPxw(x2, x3, wback);
@@ -444,7 +436,55 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
DEFAULT;
}
break;
-
+ case 0x10:
+ INST_NAME("LOCK ADC Eb, Gb");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ SMDMB();
+ GETGB(x2);
+ if((nextop&0xC0)==0xC0) {
+ if(rex.rex) {
+ wback = xRAX + (nextop&7) + (rex.b<<3);
+ wb2 = 0;
+ } else {
+ wback = (nextop&7);
+ wb2 = (wback>>2);
+ wback = xRAX+(wback&3);
+ }
+ UBFXw(x1, wback, wb2*8, 8);
+ emit_adc8(dyn, ninst, x1, x2, x4, x5);
+ BFIx(wback, x1, wb2*8, 8);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
+ MARKLOCK;
+ LDAXRB(x1, wback);
+ emit_adc8(dyn, ninst, x1, x2, x4, x5);
+ STLXRB(x4, x1, wback);
+ CBNZx_MARKLOCK(x4);
+ }
+ SMDMB();
+ break;
+ case 0x11:
+ INST_NAME("LOCK ADC Ed, Gd");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ SMDMB();
+ if(MODREG) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ emit_adc32(dyn, ninst, rex, ed, gd, x3, x4);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
+ MARKLOCK;
+ LDAXRxw(x1, wback);
+ emit_adc32(dyn, ninst, rex, x1, gd, x4, x5);
+ STLXRxw(x4, x1, wback);
+ CBNZx_MARKLOCK(x4);
+ }
+ SMDMB();
+ break;
case 0x21:
INST_NAME("LOCK AND Ed, Gd");
SETFLAGS(X_ALL, SF_SET_PENDING);
@@ -455,7 +495,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
ed = xRAX+(nextop&7)+(rex.b<<3);
emit_and32(dyn, ninst, rex, ed, gd, x3, x4);
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
MARKLOCK;
LDAXRxw(x1, wback);
emit_and32(dyn, ninst, rex, x1, gd, x3, x4);
@@ -464,7 +504,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
}
SMDMB();
break;
-
+
case 0x29:
INST_NAME("LOCK SUB Ed, Gd");
SETFLAGS(X_ALL, SF_SET_PENDING);
@@ -475,7 +515,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
ed = xRAX+(nextop&7)+(rex.b<<3);
emit_sub32(dyn, ninst, rex, ed, gd, x3, x4);
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
MARKLOCK;
LDAXRxw(x1, wback);
emit_sub32(dyn, ninst, rex, x1, gd, x3, x4);
@@ -502,7 +542,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
wb1 = 0;
EBBACK;
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x5, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 1);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x5, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 1);
u8 = F8;
wb1 = 1;
MARKLOCK;
@@ -522,7 +562,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
wb1 = 0;
EBBACK;
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x5, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 1);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x5, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 1);
u8 = F8;
wb1 = 1;
MARKLOCK;
@@ -543,7 +583,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
wb1 = 0;
EBBACK;
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x5, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 1);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x5, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 1);
u8 = F8;
wb1 = 1;
MARKLOCK;
@@ -564,7 +604,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
wb1 = 0;
EBBACK;
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x5, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 1);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x5, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 1);
u8 = F8;
wb1 = 1;
MARKLOCK;
@@ -584,7 +624,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
wb1 = 0;
EBBACK;
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x5, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 1);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x5, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 1);
u8 = F8;
wb1 = 1;
MARKLOCK;
@@ -604,7 +644,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
wb1 = 0;
EBBACK;
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x5, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 1);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x5, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 1);
u8 = F8;
wb1 = 1;
MARKLOCK;
@@ -624,7 +664,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
wb1 = 0;
EBBACK;
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x5, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 1);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x5, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 1);
u8 = F8;
wb1 = 1;
MARKLOCK;
@@ -669,7 +709,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MOV64xw(x5, i64);
emit_add32(dyn, ninst, rex, ed, x5, x3, x4);
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, (opcode==0x81)?4:1);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, (opcode==0x81)?4:1);
if(opcode==0x81) i64 = F32S; else i64 = F8S;
TSTx_mask(wback, 1, 0, 1+rex.w); // mask=3 or 7
B_MARK(cNE);
@@ -680,7 +720,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
CBNZx_MARKLOCK(x3);
SMDMB();
B_NEXT_nocond;
- MARK; // unaligned! also, not enough
+ MARK; // unaligned! also, not enough
LDRxw_U12(x1, wback, 0);
LDAXRB(x4, wback);
BFIxw(x1, x4, 0, 8); // re-inject
@@ -699,7 +739,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MOV64xw(x5, i64);
emit_or32(dyn, ninst, rex, ed, x5, x3, x4);
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, (opcode==0x81)?4:1);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, (opcode==0x81)?4:1);
if(opcode==0x81) i64 = F32S; else i64 = F8S;
MOV64xw(x5, i64);
MARKLOCK;
@@ -719,7 +759,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MOV64xw(x5, i64);
emit_adc32(dyn, ninst, rex, ed, x5, x3, x4);
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, (opcode==0x81)?4:1);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, (opcode==0x81)?4:1);
if(opcode==0x81) i64 = F32S; else i64 = F8S;
MOV64xw(x5, i64);
MARKLOCK;
@@ -739,7 +779,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MOV64xw(x5, i64);
emit_sbb32(dyn, ninst, rex, ed, x5, x3, x4);
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, (opcode==0x81)?4:1);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, (opcode==0x81)?4:1);
if(opcode==0x81) i64 = F32S; else i64 = F8S;
MOV64xw(x5, i64);
MARKLOCK;
@@ -758,7 +798,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MOV64xw(x5, i64);
emit_and32(dyn, ninst, rex, ed, x5, x3, x4);
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, (opcode==0x81)?4:1);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, (opcode==0x81)?4:1);
if(opcode==0x81) i64 = F32S; else i64 = F8S;
MOV64xw(x5, i64);
MARKLOCK;
@@ -777,7 +817,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MOV64xw(x5, i64);
emit_sub32(dyn, ninst, rex, ed, x5, x3, x4);
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, (opcode==0x81)?4:1);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, (opcode==0x81)?4:1);
if(opcode==0x81) i64 = F32S; else i64 = F8S;
TSTx_mask(wback, 1, 0, 1+rex.w); // mask=3 or 7
B_MARK(cNE);
@@ -788,7 +828,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
CBNZx_MARKLOCK(x3);
SMDMB();
B_NEXT_nocond;
- MARK; // unaligned! also, not enough
+ MARK; // unaligned! also, not enough
LDRxw_U12(x1, wback, 0);
LDAXRB(x4, wback);
BFIxw(x1, x4, 0, 8); // re-inject
@@ -807,7 +847,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MOV64xw(x5, i64);
emit_xor32(dyn, ninst, rex, ed, x5, x3, x4);
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, (opcode==0x81)?4:1);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, (opcode==0x81)?4:1);
if(opcode==0x81) i64 = F32S; else i64 = F8S;
MOV64xw(x5, i64);
MARKLOCK;
@@ -833,7 +873,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
}
SMDMB();
break;
-
+
case 0x86:
INST_NAME("LOCK XCHG Eb, Gb");
// Do the swap
@@ -856,7 +896,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
} else {
SMDMB();
GETGB(x4);
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
MARKLOCK;
// do the swap with exclusive locking
LDAXRB(x1, ed);
@@ -879,7 +919,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
} else {
GETGD;
SMDMB();
- addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
TSTx_mask(ed, 1, 0, 1+rex.w); // mask=3 or 7
B_MARK(cNE);
MARKLOCK;
@@ -895,7 +935,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
MOVxw_REG(gd, x1);
}
break;
-
+
case 0xF6:
nextop = F8;
switch((nextop>>3)&7) {
@@ -917,7 +957,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
EBBACK;
} else {
SMDMB();
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
MARKLOCK;
LDAXRB(x1, wback);
MVNw_REG(x1, x1);
@@ -930,7 +970,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
DEFAULT;
}
break;
-
+
case 0xFE:
nextop = F8;
switch((nextop>>3)&7)
@@ -944,7 +984,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
emit_inc8(dyn, ninst, x1, x2, x4);
EBBACK;
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
MARKLOCK;
LDAXRB(x1, wback);
emit_inc8(dyn, ninst, x1, x3, x4);
@@ -962,7 +1002,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
emit_dec8(dyn, ninst, x1, x2, x4);
EBBACK;
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
MARKLOCK;
LDAXRB(x1, wback);
emit_dec8(dyn, ninst, x1, x3, x4);
@@ -987,7 +1027,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
ed = xRAX+(nextop&7)+(rex.b<<3);
emit_inc32(dyn, ninst, rex, ed, x3, x4);
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
TSTx_mask(wback, 1, 0, 1+rex.w); // mask=3 or 7
B_MARK(cNE); // unaligned
MARKLOCK;
@@ -1016,7 +1056,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
ed = xRAX+(nextop&7)+(rex.b<<3);
emit_dec32(dyn, ninst, rex, ed, x3, x4);
} else {
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, LOCK_LOCK, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, LOCK_LOCK, 0, 0);
TSTx_mask(wback, 1, 0, 1+rex.w); // mask=3 or 7
B_MARK(cNE); // unaligned
MARKLOCK;
@@ -1041,7 +1081,7 @@ uintptr_t dynarec64_F0(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int nin
DEFAULT;
}
break;
-
+
default:
DEFAULT;
}
diff --git a/src/dynarec/arm64/dynarec_arm64_f20f.c b/src/dynarec/arm64/dynarec_arm64_f20f.c
index 746225a..c2d8a46 100755..100644
--- a/src/dynarec/arm64/dynarec_arm64_f20f.c
+++ b/src/dynarec/arm64/dynarec_arm64_f20f.c
@@ -1,7 +1,6 @@
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
-#include <pthread.h>
#include <errno.h>
#include "debug.h"
@@ -36,6 +35,7 @@ uintptr_t dynarec64_F20F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
int q0;
int d0, d1;
int64_t fixedaddress;
+ int unscaled;
MAYUSE(d0);
MAYUSE(d1);
@@ -57,8 +57,8 @@ uintptr_t dynarec64_F20F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
} else {
SMREAD();
v0 = sse_get_reg_empty(dyn, ninst, x1, gd);
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
- VLDR64_U12(v0, ed, fixedaddress); // upper part reseted
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
+ VLD64(v0, ed, fixedaddress); // upper part reseted
}
break;
case 0x11:
@@ -71,8 +71,8 @@ uintptr_t dynarec64_F20F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
d0 = sse_get_reg(dyn, ninst, x1, ed, 1);
VMOVeD(d0, 0, v0, 0);
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
- VSTR64_U12(v0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
+ VST64(v0, ed, fixedaddress);
SMWRITE2();
}
break;
@@ -87,8 +87,8 @@ uintptr_t dynarec64_F20F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
} else {
SMREAD();
v0 = sse_get_reg_empty(dyn, ninst, x1, gd);
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
- VLDR64_U12(v0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
+ VLD64(v0, ed, fixedaddress);
}
VMOVeD(v0, 1, v0, 0);
break;
@@ -154,6 +154,42 @@ uintptr_t dynarec64_F20F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
}
break;
+ case 0x38: // these are some more SSSE4.2+ opcodes
+ opcode = F8;
+ switch(opcode) {
+
+ case 0xF0:
+ INST_NAME("(unsupported) CRC32 Gd, Eb)");
+ nextop = F8;
+ addr = fakeed(dyn, addr, ninst, nextop);
+ SETFLAGS(X_ALL, SF_SET); // Hack to set flags in "don't care" state
+ GETIP(ip);
+ STORE_XEMU_CALL(xRIP);
+ CALL(native_ud, -1);
+ LOAD_XEMU_CALL(xRIP);
+ jump_to_epilog(dyn, 0, xRIP, ninst);
+ *need_epilog = 0;
+ *ok = 0;
+ break;
+ case 0xF1:
+ INST_NAME("(unsupported) CRC32 Gd, Ed)");
+ nextop = F8;
+ addr = fakeed(dyn, addr, ninst, nextop);
+ SETFLAGS(X_ALL, SF_SET); // Hack to set flags in "don't care" state
+ GETIP(ip);
+ STORE_XEMU_CALL(xRIP);
+ CALL(native_ud, -1);
+ LOAD_XEMU_CALL(xRIP);
+ jump_to_epilog(dyn, 0, xRIP, ninst);
+ *need_epilog = 0;
+ *ok = 0;
+ break;
+
+ default:
+ DEFAULT;
+ }
+ break;
+
case 0x51:
INST_NAME("SQRTSD Gx, Ex");
@@ -261,7 +297,7 @@ uintptr_t dynarec64_F20F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
VMOVeD(v0, 0, d0, 0); // to not erase uper part
#else
FCMPD(v0, v1);
- B_NEXT(cLS); //Less than or equal
+ B_NEXT(cCC); //Less than
VMOVeD(v0, 0, v1, 0); // to not erase uper part
#endif
break;
@@ -299,7 +335,7 @@ uintptr_t dynarec64_F20F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
VMOVeD(v0, 0, d0, 0); // to not erase uper part
#else
FCMPD(v0, v1);
- B_NEXT(cGE); //Greater than or equal
+ B_NEXT(cGT); //Greater than
VMOVeD(v0, 0, v1, 0); // to not erase uper part
#endif
break;
@@ -334,9 +370,9 @@ uintptr_t dynarec64_F20F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
if(MODREG) {
v1 = sse_get_reg(dyn, ninst, x1, (nextop&7)+(rex.b<<3), 0);
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<4, 15, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<4, 15, rex, NULL, 0, 0);
v1 = fpu_get_scratch(dyn);
- VLDR128_U12(v1, ed, fixedaddress);
+ VLD128(v1, ed, fixedaddress);
}
VFADDPQS(v0, v0, v1);
break;
@@ -365,7 +401,7 @@ uintptr_t dynarec64_F20F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
INST_NAME("ADDSUBPS Gx, Ex");
nextop = F8;
GETGX(v0, 1);
- GETEXSD(v1, 0, 0);
+ GETEX(v1, 0, 0);
q0 = fpu_get_scratch(dyn);
static float addsubps[4] = {-1.f, 1.f, -1.f, 1.f};
MAYUSE(addsubps);
@@ -385,13 +421,39 @@ uintptr_t dynarec64_F20F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
case 0xE6:
INST_NAME("CVTPD2DQ Gx, Ex");
nextop = F8;
- GETEXSD(v1, 0, 0);
+ GETEX(v1, 0, 0);
GETGX_empty(v0);
- u8 = sse_setround(dyn, ninst, x1, x2, x3);
- VFRINTIDQ(v0, v1);
- x87_restoreround(dyn, ninst, u8);
- VFCVTNSQD(v0, v0); // convert double -> int64
- SQXTN_32(v0, v0); // convert int64 -> int32 with saturation in lower part, RaZ high part
+ if(box64_dynarec_fastround) {
+ u8 = sse_setround(dyn, ninst, x1, x2, x3);
+ VFRINTIDQ(v0, v1);
+ x87_restoreround(dyn, ninst, u8);
+ VFCVTNSQD(v0, v0); // convert double -> int64
+ SQXTN_32(v0, v0); // convert int64 -> int32 with saturation in lower part, RaZ high part
+ } else {
+ u8 = sse_setround(dyn, ninst, x1, x2, x3);
+ MRS_fpsr(x5);
+ BFCw(x5, FPSR_IOC, 1); // reset IOC bit
+ MSR_fpsr(x5);
+ ORRw_mask(x4, xZR, 1, 0); //0x80000000
+ d0 = fpu_get_scratch(dyn);
+ for(int i=0; i<2; ++i) {
+ BFCw(x5, FPSR_IOC, 1); // reset IOC bit
+ MSR_fpsr(x5);
+ if(i) {
+ VMOVeD(d0, 0, v1, i);
+ FRINTID(d0, d0);
+ } else {
+ FRINTID(d0, v1);
+ }
+ FCVTZSwD(x1, d0);
+ MRS_fpsr(x5); // get back FPSR to check the IOC bit
+ TBZ(x5, FPSR_IOC, 4+4);
+ MOVw_REG(x1, x4);
+ VMOVQSfrom(v0, i, x1);
+ }
+ x87_restoreround(dyn, ninst, u8);
+ VMOVQDfrom(v0, 1, xZR);
+ }
break;
case 0xF0:
@@ -405,8 +467,8 @@ uintptr_t dynarec64_F20F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
} else {
v0 = sse_get_reg_empty(dyn, ninst, x1, gd);
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<4, 7, rex, NULL, 0, 0);
- VLDR128_U12(v0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<4, 7, rex, NULL, 0, 0);
+ VLD128(v0, ed, fixedaddress);
}
break;
diff --git a/src/dynarec/arm64/dynarec_arm64_f30f.c b/src/dynarec/arm64/dynarec_arm64_f30f.c
index 2d0b8c6..d57d3c8 100755..100644
--- a/src/dynarec/arm64/dynarec_arm64_f30f.c
+++ b/src/dynarec/arm64/dynarec_arm64_f30f.c
@@ -1,7 +1,6 @@
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
-#include <pthread.h>
#include <errno.h>
#include "debug.h"
@@ -35,6 +34,7 @@ uintptr_t dynarec64_F30F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
int q0, q1;
int d0, d1;
int64_t fixedaddress;
+ int unscaled;
int64_t j64;
MAYUSE(d0);
@@ -58,8 +58,8 @@ uintptr_t dynarec64_F30F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
} else {
v0 = sse_get_reg_empty(dyn, ninst, x1, gd);
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<2, 3, rex, NULL, 0, 0);
- VLDR32_U12(v0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, 0);
+ VLD32(v0, ed, fixedaddress);
}
break;
case 0x11:
@@ -71,8 +71,8 @@ uintptr_t dynarec64_F30F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
q0 = sse_get_reg(dyn, ninst, x1, (nextop&7) + (rex.b<<3), 1);
VMOVeS(q0, 0, v0, 0);
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<2, 3, rex, NULL, 0, 0);
- VSTR32_U12(v0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, 0);
+ VST32(v0, ed, fixedaddress);
SMWRITE2();
}
break;
@@ -83,9 +83,9 @@ uintptr_t dynarec64_F30F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
q1 = sse_get_reg(dyn, ninst, x1, (nextop&7)+(rex.b<<3), 0);
} else {
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<4, 15, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<4, 15, rex, NULL, 0, 0);
q1 = fpu_get_scratch(dyn);
- VLDR128_U12(q1, ed, fixedaddress);
+ VLD128(q1, ed, fixedaddress);
}
GETGX_empty(q0);
VTRNQ1_32(q0, q1, q1);
@@ -98,9 +98,9 @@ uintptr_t dynarec64_F30F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
q1 = sse_get_reg(dyn, ninst, x1, (nextop&7)+(rex.b<<3), 0);
} else {
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<4, 15, rex, NULL, 0, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<4, 15, rex, NULL, 0, 0);
q1 = fpu_get_scratch(dyn);
- VLDR128_U12(q1, ed, fixedaddress);
+ VLD128(q1, ed, fixedaddress);
}
GETGX_empty(q0);
VTRNQ2_32(q0, q1, q1);
@@ -143,7 +143,7 @@ uintptr_t dynarec64_F30F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
if(rex.w) {
ORRx_mask(gd, xZR, 1, 1, 0); //0x8000000000000000
} else {
- MOV32w(gd, 0x80000000);
+ ORRw_mask(gd, xZR, 1, 0); //0x80000000
}
}
break;
@@ -168,7 +168,7 @@ uintptr_t dynarec64_F30F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
if(rex.w) {
ORRx_mask(gd, xZR, 1, 1, 0); //0x8000000000000000
} else {
- MOV32w(gd, 0x80000000);
+ ORRw_mask(gd, xZR, 1, 0); //0x80000000
}
}
break;
@@ -239,9 +239,27 @@ uintptr_t dynarec64_F30F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
case 0x5B:
INST_NAME("CVTTPS2DQ Gx, Ex");
nextop = F8;
- GETEX(d0, 0, 0) ;
+ GETEX(v1, 0, 0) ;
GETGX_empty(v0);
- VFCVTZSQS(v0, d0);
+ if(box64_dynarec_fastround) {
+ VFCVTZSQS(v0, v1);
+ } else {
+ MRS_fpsr(x5);
+ BFCw(x5, FPSR_IOC, 1); // reset IOC bit
+ MSR_fpsr(x5);
+ ORRw_mask(x4, xZR, 1, 0); //0x80000000
+ d0 = fpu_get_scratch(dyn);
+ for(int i=0; i<4; ++i) {
+ BFCw(x5, FPSR_IOC, 1); // reset IOC bit
+ MSR_fpsr(x5);
+ VMOVeS(d0, 0, v1, i);
+ VFCVTZSs(d0, d0);
+ MRS_fpsr(x5); // get back FPSR to check the IOC bit
+ TBZ(x5, FPSR_IOC, 4+4);
+ VMOVQSfrom(d0, 0, x4);
+ VMOVeS(v0, i, d0, 0);
+ }
+ }
break;
case 0x5C:
@@ -305,8 +323,8 @@ uintptr_t dynarec64_F30F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
} else {
GETGX_empty(v0);
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<4, 15, rex, NULL, 0, 0);
- VLDR128_U12(v0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<4, 15, rex, NULL, 0, 0);
+ VLD128(v0, ed, fixedaddress);
}
break;
case 0x70:
@@ -341,8 +359,8 @@ uintptr_t dynarec64_F30F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
} else {
GETGX_empty(v0);
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
- VLDR64_U12(v0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
+ VLD64(v0, ed, fixedaddress);
}
break;
case 0x7F:
@@ -353,12 +371,48 @@ uintptr_t dynarec64_F30F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
v1 = sse_get_reg_empty(dyn, ninst, x1, (nextop&7) + (rex.b<<3));
VMOVQ(v1, v0);
} else {
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<4, 15, rex, NULL, 0, 0);
- VSTR128_U12(v0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<4, 15, rex, NULL, 0, 0);
+ VST128(v0, ed, fixedaddress);
SMWRITE2();
}
break;
+ case 0xB8:
+ INST_NAME("POPCNT Gd, Ed");
+ SETFLAGS(X_ALL, SF_SET);
+ SET_DFNONE(x1);
+ nextop = F8;
+ v1 = fpu_get_scratch(dyn);
+ GETGD;
+ if(MODREG) {
+ GETED(0);
+ if(rex.w)
+ VMOVQDfrom(v1, 0, ed);
+ else {
+ MOVxw_REG(x1, ed); // need to clear uper part
+ VMOVQDfrom(v1, 0, x1);
+ }
+ } else {
+ if(rex.w) {
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
+ VLD64(v1, ed, fixedaddress);
+ } else {
+ GETED(0); // just load and clear the upper part
+ VMOVQDfrom(v1, 0, ed);
+ }
+ }
+ CNT_8(v1, v1);
+ UADDLV_8(v1, v1);
+ VMOVQDto(gd, v1, 0);
+ IFX(X_ALL) {
+ MOV32w(x1, (1<<F_OF) | (1<<F_SF) | (1<<F_ZF) | (1<<F_AF) | (1<<F_CF) | (1<<F_PF));
+ BICw(xFlags, xFlags, x1);
+ CBNZx(gd, 4+4);
+ BFIw(xFlags, xFlags, F_ZF, 1);
+ }
+ break;
+
case 0xBC:
INST_NAME("TZCNT Gd, Ed");
SETFLAGS(X_CF|X_ZF, SF_SUBSET);
@@ -421,8 +475,8 @@ uintptr_t dynarec64_F30F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
VMOV(v0, v1);
} else {
SMREAD();
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, 0);
- VLDR64_U12(v0, ed, fixedaddress);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, 0);
+ VLD64(v0, ed, fixedaddress);
}
break;
diff --git a/src/dynarec/arm64/dynarec_arm64_functions.c b/src/dynarec/arm64/dynarec_arm64_functions.c
index 2c6ebb3..6944b78 100755..100644
--- a/src/dynarec/arm64/dynarec_arm64_functions.c
+++ b/src/dynarec/arm64/dynarec_arm64_functions.c
@@ -1,7 +1,6 @@
#define _GNU_SOURCE
#include <stdio.h>
#include <stdlib.h>
-#include <pthread.h>
#include <errno.h>
#include <string.h>
#include <math.h>
@@ -13,7 +12,6 @@
#include "box64context.h"
#include "dynarec.h"
#include "emu/x64emu_private.h"
-#include "tools/bridge_private.h"
#include "x64run.h"
#include "x64emu.h"
#include "box64stack.h"
@@ -28,332 +26,6 @@
#include "custommem.h"
#include "bridge.h"
-void arm_fstp(x64emu_t* emu, void* p)
-{
- if(ST0.q!=STld(0).uref)
- D2LD(&ST0.d, p);
- else
- memcpy(p, &STld(0).ld, 10);
-}
-
-void arm_print_armreg(x64emu_t* emu, uintptr_t reg, uintptr_t n)
-{
- (void)emu;
- dynarec_log(LOG_DEBUG, "R%lu=0x%lx (%lu)\n", n, reg, reg);
-}
-
-void arm_f2xm1(x64emu_t* emu)
-{
- ST0.d = exp2(ST0.d) - 1.0;
-}
-void arm_fyl2x(x64emu_t* emu)
-{
- ST(1).d = log2(ST0.d)*ST(1).d;
-}
-void arm_ftan(x64emu_t* emu)
-{
- ST0.d = tan(ST0.d);
- emu->sw.f.F87_C2 = 0;
-}
-void arm_fpatan(x64emu_t* emu)
-{
- ST1.d = atan2(ST1.d, ST0.d);
-}
-void arm_fxtract(x64emu_t* emu)
-{
- int32_t tmp32s = (ST1.q&0x7ff0000000000000LL)>>52;
- tmp32s -= 1023;
- ST1.d /= exp2(tmp32s);
- ST0.d = tmp32s;
-}
-void arm_fprem(x64emu_t* emu)
-{
- int32_t tmp32s = ST0.d / ST1.d;
- ST0.d -= ST1.d * tmp32s;
- emu->sw.f.F87_C2 = 0;
- emu->sw.f.F87_C0 = (tmp32s&1);
- emu->sw.f.F87_C3 = ((tmp32s>>1)&1);
- emu->sw.f.F87_C1 = ((tmp32s>>2)&1);
-}
-void arm_fyl2xp1(x64emu_t* emu)
-{
- ST(1).d = log2(ST0.d + 1.0)*ST(1).d;
-}
-void arm_fsincos(x64emu_t* emu)
-{
- sincos(ST1.d, &ST1.d, &ST0.d);
- emu->sw.f.F87_C2 = 0;
-}
-void arm_frndint(x64emu_t* emu)
-{
- ST0.d = fpu_round(emu, ST0.d);
-}
-void arm_fscale(x64emu_t* emu)
-{
- if(ST0.d!=0.0)
- ST0.d *= exp2(trunc(ST1.d));
-}
-void arm_fsin(x64emu_t* emu)
-{
- ST0.d = sin(ST0.d);
- emu->sw.f.F87_C2 = 0;
-}
-void arm_fcos(x64emu_t* emu)
-{
- ST0.d = cos(ST0.d);
- emu->sw.f.F87_C2 = 0;
-}
-
-void arm_fbld(x64emu_t* emu, uint8_t* ed)
-{
- fpu_fbld(emu, ed);
-}
-
-void arm_fild64(x64emu_t* emu, int64_t* ed)
-{
- int64_t tmp;
- memcpy(&tmp, ed, sizeof(tmp));
- ST0.d = tmp;
- STll(0).sq = tmp;
- STll(0).sref = ST0.sq;
-}
-
-void arm_fbstp(x64emu_t* emu, uint8_t* ed)
-{
- fpu_fbst(emu, ed);
-}
-
-void arm_fistp64(x64emu_t* emu, int64_t* ed)
-{
- // used of memcpy to avoid aligments issues
- if(STll(0).sref==ST(0).sq) {
- memcpy(ed, &STll(0).sq, sizeof(int64_t));
- } else {
- int64_t tmp;
- if(isgreater(ST0.d, (double)(int64_t)0x7fffffffffffffffLL) || isless(ST0.d, (double)(int64_t)0x8000000000000000LL) || !isfinite(ST0.d))
- tmp = 0x8000000000000000LL;
- else
- tmp = fpu_round(emu, ST0.d);
- memcpy(ed, &tmp, sizeof(tmp));
- }
-}
-
-void arm_fistt64(x64emu_t* emu, int64_t* ed)
-{
- // used of memcpy to avoid aligments issues
- int64_t tmp = ST0.d;
- memcpy(ed, &tmp, sizeof(tmp));
-}
-
-void arm_fld(x64emu_t* emu, uint8_t* ed)
-{
- memcpy(&STld(0).ld, ed, 10);
- LD2D(&STld(0), &ST(0).d);
- STld(0).uref = ST0.q;
-}
-
-void arm_ud(x64emu_t* emu)
-{
- emit_signal(emu, SIGILL, (void*)R_RIP, 0);
-}
-
-void arm_priv(x64emu_t* emu)
-{
- emit_signal(emu, SIGSEGV, (void*)R_RIP, 0);
-}
-
-void arm_fsave(x64emu_t* emu, uint8_t* ed)
-{
- fpu_savenv(emu, (char*)ed, 0);
-
- uint8_t* p = ed;
- p += 28;
- for (int i=0; i<8; ++i) {
- LD2D(p, &ST(i).d);
- p+=10;
- }
-}
-void arm_frstor(x64emu_t* emu, uint8_t* ed)
-{
- fpu_loadenv(emu, (char*)ed, 0);
-
- uint8_t* p = ed;
- p += 28;
- for (int i=0; i<8; ++i) {
- D2LD(&ST(i).d, p);
- p+=10;
- }
-
-}
-
-void arm_fprem1(x64emu_t* emu)
-{
- // simplified version
- int32_t tmp32s = round(ST0.d / ST1.d);
- ST0.d -= ST1.d*tmp32s;
- emu->sw.f.F87_C2 = 0;
- emu->sw.f.F87_C0 = (tmp32s&1);
- emu->sw.f.F87_C3 = ((tmp32s>>1)&1);
- emu->sw.f.F87_C1 = ((tmp32s>>2)&1);
-}
-
-static uint8_t ff_mult(uint8_t a, uint8_t b)
-{
- int retval = 0;
-
- for(int i = 0; i < 8; i++) {
- if((b & 1) == 1)
- retval ^= a;
-
- if((a & 0x80)) {
- a <<= 1;
- a ^= 0x1b;
- } else {
- a <<= 1;
- }
-
- b >>= 1;
- }
-
- return retval;
-}
-
-void arm_aesimc(x64emu_t* emu, int xmm)
-{
- sse_regs_t eax1 = emu->xmm[xmm];
-
- for(int j=0; j<4; ++j) {
- emu->xmm[xmm].ub[0+j*4] = ff_mult(0x0E, eax1.ub[0+j*4]) ^ ff_mult(0x0B, eax1.ub[1+j*4]) ^ ff_mult(0x0D, eax1.ub[2+j*4]) ^ ff_mult(0x09, eax1.ub[3+j*4]);
- emu->xmm[xmm].ub[1+j*4] = ff_mult(0x09, eax1.ub[0+j*4]) ^ ff_mult(0x0E, eax1.ub[1+j*4]) ^ ff_mult(0x0B, eax1.ub[2+j*4]) ^ ff_mult(0x0D, eax1.ub[3+j*4]);
- emu->xmm[xmm].ub[2+j*4] = ff_mult(0x0D, eax1.ub[0+j*4]) ^ ff_mult(0x09, eax1.ub[1+j*4]) ^ ff_mult(0x0E, eax1.ub[2+j*4]) ^ ff_mult(0x0B, eax1.ub[3+j*4]);
- emu->xmm[xmm].ub[3+j*4] = ff_mult(0x0B, eax1.ub[0+j*4]) ^ ff_mult(0x0D, eax1.ub[1+j*4]) ^ ff_mult(0x09, eax1.ub[2+j*4]) ^ ff_mult(0x0E, eax1.ub[3+j*4]);
- }
-}
-void arm_aesmc(x64emu_t* emu, int xmm)
-{
- sse_regs_t eax1 = emu->xmm[xmm];
-
- for(int j=0; j<4; ++j) {
- emu->xmm[xmm].ub[0+j*4] = ff_mult(0x02, eax1.ub[0+j*4]) ^ ff_mult(0x03, eax1.ub[1+j*4]) ^ eax1.ub[2+j*4] ^ eax1.ub[3+j*4] ;
- emu->xmm[xmm].ub[1+j*4] = eax1.ub[0+j*4] ^ ff_mult(0x02, eax1.ub[1+j*4]) ^ ff_mult(0x03, eax1.ub[2+j*4]) ^ eax1.ub[3+j*4] ;
- emu->xmm[xmm].ub[2+j*4] = eax1.ub[0+j*4] ^ eax1.ub[1+j*4] ^ ff_mult(0x02, eax1.ub[2+j*4]) ^ ff_mult(0x03, eax1.ub[3+j*4]);
- emu->xmm[xmm].ub[3+j*4] = ff_mult(0x03, eax1.ub[0+j*4]) ^ eax1.ub[1+j*4] ^ eax1.ub[2+j*4] ^ ff_mult(0x02, eax1.ub[3+j*4]);
- }
-}
-void arm_aesdlast(x64emu_t* emu, int xmm)
-{
- // A0 B1 C2 D3 E4 F5 G6 H7 I8 J9 Ka Lb Mc Nd Oe Pf
- // A N K H E B O L I F C P M J G D
- const uint8_t invshiftrows[] = {0,13,10, 7, 4, 1,14,11, 8, 5, 2,15,12, 9, 6, 3};
- const uint8_t invsubbytes[256] = {
- 0x52, 0x09, 0x6a, 0xd5, 0x30, 0x36, 0xa5, 0x38, 0xbf, 0x40, 0xa3, 0x9e, 0x81, 0xf3, 0xd7, 0xfb,
- 0x7c, 0xe3, 0x39, 0x82, 0x9b, 0x2f, 0xff, 0x87, 0x34, 0x8e, 0x43, 0x44, 0xc4, 0xde, 0xe9, 0xcb,
- 0x54, 0x7b, 0x94, 0x32, 0xa6, 0xc2, 0x23, 0x3d, 0xee, 0x4c, 0x95, 0x0b, 0x42, 0xfa, 0xc3, 0x4e,
- 0x08, 0x2e, 0xa1, 0x66, 0x28, 0xd9, 0x24, 0xb2, 0x76, 0x5b, 0xa2, 0x49, 0x6d, 0x8b, 0xd1, 0x25,
- 0x72, 0xf8, 0xf6, 0x64, 0x86, 0x68, 0x98, 0x16, 0xd4, 0xa4, 0x5c, 0xcc, 0x5d, 0x65, 0xb6, 0x92,
- 0x6c, 0x70, 0x48, 0x50, 0xfd, 0xed, 0xb9, 0xda, 0x5e, 0x15, 0x46, 0x57, 0xa7, 0x8d, 0x9d, 0x84,
- 0x90, 0xd8, 0xab, 0x00, 0x8c, 0xbc, 0xd3, 0x0a, 0xf7, 0xe4, 0x58, 0x05, 0xb8, 0xb3, 0x45, 0x06,
- 0xd0, 0x2c, 0x1e, 0x8f, 0xca, 0x3f, 0x0f, 0x02, 0xc1, 0xaf, 0xbd, 0x03, 0x01, 0x13, 0x8a, 0x6b,
- 0x3a, 0x91, 0x11, 0x41, 0x4f, 0x67, 0xdc, 0xea, 0x97, 0xf2, 0xcf, 0xce, 0xf0, 0xb4, 0xe6, 0x73,
- 0x96, 0xac, 0x74, 0x22, 0xe7, 0xad, 0x35, 0x85, 0xe2, 0xf9, 0x37, 0xe8, 0x1c, 0x75, 0xdf, 0x6e,
- 0x47, 0xf1, 0x1a, 0x71, 0x1d, 0x29, 0xc5, 0x89, 0x6f, 0xb7, 0x62, 0x0e, 0xaa, 0x18, 0xbe, 0x1b,
- 0xfc, 0x56, 0x3e, 0x4b, 0xc6, 0xd2, 0x79, 0x20, 0x9a, 0xdb, 0xc0, 0xfe, 0x78, 0xcd, 0x5a, 0xf4,
- 0x1f, 0xdd, 0xa8, 0x33, 0x88, 0x07, 0xc7, 0x31, 0xb1, 0x12, 0x10, 0x59, 0x27, 0x80, 0xec, 0x5f,
- 0x60, 0x51, 0x7f, 0xa9, 0x19, 0xb5, 0x4a, 0x0d, 0x2d, 0xe5, 0x7a, 0x9f, 0x93, 0xc9, 0x9c, 0xef,
- 0xa0, 0xe0, 0x3b, 0x4d, 0xae, 0x2a, 0xf5, 0xb0, 0xc8, 0xeb, 0xbb, 0x3c, 0x83, 0x53, 0x99, 0x61,
- 0x17, 0x2b, 0x04, 0x7e, 0xba, 0x77, 0xd6, 0x26, 0xe1, 0x69, 0x14, 0x63, 0x55, 0x21, 0x0c, 0x7d,
- };
-
- sse_regs_t eax1;
- for(int i=0; i<16; ++i)
- eax1.ub[i] = emu->xmm[xmm].ub[invshiftrows[i]];
- //STATE ← InvSubBytes( STATE );
- for(int i=0; i<16; ++i)
- emu->xmm[xmm].ub[i] = invsubbytes[eax1.ub[i]];
-
-}
-static const uint8_t shiftrows[] = {0, 5,10,15, 4, 9,14, 3, 8,13, 2, 7,12, 1, 6,11};
-static const uint8_t subbytes[256] = {
- 0x63, 0x7c, 0x77, 0x7b, 0xf2, 0x6b, 0x6f, 0xc5, 0x30, 0x01, 0x67, 0x2b, 0xfe, 0xd7, 0xab, 0x76,
- 0xca, 0x82, 0xc9, 0x7d, 0xfa, 0x59, 0x47, 0xf0, 0xad, 0xd4, 0xa2, 0xaf, 0x9c, 0xa4, 0x72, 0xc0,
- 0xb7, 0xfd, 0x93, 0x26, 0x36, 0x3f, 0xf7, 0xcc, 0x34, 0xa5, 0xe5, 0xf1, 0x71, 0xd8, 0x31, 0x15,
- 0x04, 0xc7, 0x23, 0xc3, 0x18, 0x96, 0x05, 0x9a, 0x07, 0x12, 0x80, 0xe2, 0xeb, 0x27, 0xb2, 0x75,
- 0x09, 0x83, 0x2c, 0x1a, 0x1b, 0x6e, 0x5a, 0xa0, 0x52, 0x3b, 0xd6, 0xb3, 0x29, 0xe3, 0x2f, 0x84,
- 0x53, 0xd1, 0x00, 0xed, 0x20, 0xfc, 0xb1, 0x5b, 0x6a, 0xcb, 0xbe, 0x39, 0x4a, 0x4c, 0x58, 0xcf,
- 0xd0, 0xef, 0xaa, 0xfb, 0x43, 0x4d, 0x33, 0x85, 0x45, 0xf9, 0x02, 0x7f, 0x50, 0x3c, 0x9f, 0xa8,
- 0x51, 0xa3, 0x40, 0x8f, 0x92, 0x9d, 0x38, 0xf5, 0xbc, 0xb6, 0xda, 0x21, 0x10, 0xff, 0xf3, 0xd2,
- 0xcd, 0x0c, 0x13, 0xec, 0x5f, 0x97, 0x44, 0x17, 0xc4, 0xa7, 0x7e, 0x3d, 0x64, 0x5d, 0x19, 0x73,
- 0x60, 0x81, 0x4f, 0xdc, 0x22, 0x2a, 0x90, 0x88, 0x46, 0xee, 0xb8, 0x14, 0xde, 0x5e, 0x0b, 0xdb,
- 0xe0, 0x32, 0x3a, 0x0a, 0x49, 0x06, 0x24, 0x5c, 0xc2, 0xd3, 0xac, 0x62, 0x91, 0x95, 0xe4, 0x79,
- 0xe7, 0xc8, 0x37, 0x6d, 0x8d, 0xd5, 0x4e, 0xa9, 0x6c, 0x56, 0xf4, 0xea, 0x65, 0x7a, 0xae, 0x08,
- 0xba, 0x78, 0x25, 0x2e, 0x1c, 0xa6, 0xb4, 0xc6, 0xe8, 0xdd, 0x74, 0x1f, 0x4b, 0xbd, 0x8b, 0x8a,
- 0x70, 0x3e, 0xb5, 0x66, 0x48, 0x03, 0xf6, 0x0e, 0x61, 0x35, 0x57, 0xb9, 0x86, 0xc1, 0x1d, 0x9e,
- 0xe1, 0xf8, 0x98, 0x11, 0x69, 0xd9, 0x8e, 0x94, 0x9b, 0x1e, 0x87, 0xe9, 0xce, 0x55, 0x28, 0xdf,
- 0x8c, 0xa1, 0x89, 0x0d, 0xbf, 0xe6, 0x42, 0x68, 0x41, 0x99, 0x2d, 0x0f, 0xb0, 0x54, 0xbb, 0x16,
-};
-void arm_aeselast(x64emu_t* emu, int xmm)
-{
- // A0 B1 C2 D3 E4 F5 G6 H7 I8 J9 Ka Lb Mc Nd Oe Pf
- // A F K P E J O D I N C H M B G L
- sse_regs_t eax1;
- for(int i=0; i<16; ++i)
- eax1.ub[i] = emu->xmm[xmm].ub[shiftrows[i]];
- //STATE ← SubBytes( STATE );
- for(int i=0; i<16; ++i)
- emu->xmm[xmm].ub[i] = subbytes[eax1.ub[i]];
-}
-void arm_aesd(x64emu_t* emu, int xmm)
-{
- arm_aesdlast(emu, xmm);
- arm_aesimc(emu, xmm);
-}
-void arm_aese(x64emu_t* emu, int xmm)
-{
- arm_aeselast(emu, xmm);
- arm_aesmc(emu, xmm);
-}
-void arm_aeskeygenassist(x64emu_t* emu, int gx, int ex, void* p, uint32_t u8)
-{
- sse_regs_t *EX = p?((sse_regs_t*)p):&emu->xmm[ex];
- sse_regs_t *GX = &emu->xmm[gx];
- for (int i = 4; i < 8; ++i)
- GX->ub[i] = subbytes[EX->ub[i]];
- for (int i = 12; i < 16; ++i)
- GX->ub[i] = subbytes[EX->ub[i]];
- GX->ud[0] = GX->ud[1];
- uint8_t tmp8u = GX->ub[4];
- GX->ud[1] = GX->ud[1] >> 8;
- GX->ub[7] = tmp8u;
- GX->ud[1] ^= u8;
- GX->ud[2] = GX->ud[3];
- tmp8u = GX->ub[12];
- GX->ud[3] = GX->ud[3] >> 8;
- GX->ub[15] = tmp8u;
- GX->ud[3] ^= u8;
-}
-
-void arm_pclmul(x64emu_t* emu, int gx, int ex, void* p, uint32_t u8)
-{
- sse_regs_t *EX = p?((sse_regs_t*)p):&emu->xmm[ex];
- sse_regs_t *GX = &emu->xmm[gx];
- int g = (u8&1)?1:0;
- int e = (u8&0b10000)?1:0;
- __int128 result = 0;
- __int128 op2 = EX->q[e];
- for (int i=0; i<64; ++i)
- if(GX->q[g]&(1LL<<i))
- result ^= (op2<<i);
-
- GX->q[0] = result&0xffffffffffffffffLL;
- GX->q[1] = (result>>64)&0xffffffffffffffffLL;
-}
-
-void arm_clflush(x64emu_t* emu, void* p)
-{
- cleanDBFromAddressRange((uintptr_t)p, 8, 0);
-}
-
-
#define XMM0 0
#define XMM8 16
#define X870 8
@@ -386,7 +58,7 @@ void fpu_free_reg(dynarec_arm_t* dyn, int reg)
{
// TODO: check upper limit?
dyn->n.fpuused[reg] = 0;
- if(dyn->n.neoncache[reg].t!=NEON_CACHE_ST_F && dyn->n.neoncache[reg].t!=NEON_CACHE_ST_D)
+ if(dyn->n.neoncache[reg].t!=NEON_CACHE_ST_F && dyn->n.neoncache[reg].t!=NEON_CACHE_ST_D && dyn->n.neoncache[reg].t!=NEON_CACHE_ST_I64)
dyn->n.neoncache[reg].v = 0;
}
// Get an MMX double reg
@@ -434,7 +106,8 @@ int neoncache_get_st(dynarec_arm_t* dyn, int ninst, int a)
}
for(int i=0; i<24; ++i)
if((dyn->insts[ninst].n.neoncache[i].t==NEON_CACHE_ST_F
- || dyn->insts[ninst].n.neoncache[i].t==NEON_CACHE_ST_D)
+ || dyn->insts[ninst].n.neoncache[i].t==NEON_CACHE_ST_D
+ || dyn->insts[ninst].n.neoncache[i].t==NEON_CACHE_ST_I64)
&& dyn->insts[ninst].n.neoncache[i].n==a)
return dyn->insts[ninst].n.neoncache[i].t;
// not in the cache yet, so will be fetched...
@@ -448,7 +121,8 @@ int neoncache_get_current_st(dynarec_arm_t* dyn, int ninst, int a)
return NEON_CACHE_ST_D;
for(int i=0; i<24; ++i)
if((dyn->n.neoncache[i].t==NEON_CACHE_ST_F
- || dyn->n.neoncache[i].t==NEON_CACHE_ST_D)
+ || dyn->n.neoncache[i].t==NEON_CACHE_ST_D
+ || dyn->n.neoncache[i].t==NEON_CACHE_ST_I64)
&& dyn->n.neoncache[i].n==a)
return dyn->n.neoncache[i].t;
// not in the cache yet, so will be fetched...
@@ -466,6 +140,17 @@ int neoncache_get_st_f(dynarec_arm_t* dyn, int ninst, int a)
return i;
return -1;
}
+int neoncache_get_st_f_i64(dynarec_arm_t* dyn, int ninst, int a)
+{
+ /*if(a+dyn->insts[ninst].n.stack_next-st<0)
+ // The STx has been pushed at the end of instructon, so stop going back
+ return -1;*/
+ for(int i=0; i<24; ++i)
+ if((dyn->insts[ninst].n.neoncache[i].t==NEON_CACHE_ST_I64 || dyn->insts[ninst].n.neoncache[i].t==NEON_CACHE_ST_F)
+ && dyn->insts[ninst].n.neoncache[i].n==a)
+ return i;
+ return -1;
+}
int neoncache_get_st_f_noback(dynarec_arm_t* dyn, int ninst, int a)
{
for(int i=0; i<24; ++i)
@@ -474,6 +159,14 @@ int neoncache_get_st_f_noback(dynarec_arm_t* dyn, int ninst, int a)
return i;
return -1;
}
+int neoncache_get_st_f_i64_noback(dynarec_arm_t* dyn, int ninst, int a)
+{
+ for(int i=0; i<24; ++i)
+ if((dyn->insts[ninst].n.neoncache[i].t==NEON_CACHE_ST_I64 || dyn->insts[ninst].n.neoncache[i].t==NEON_CACHE_ST_F)
+ && dyn->insts[ninst].n.neoncache[i].n==a)
+ return i;
+ return -1;
+}
int neoncache_get_current_st_f(dynarec_arm_t* dyn, int a)
{
for(int i=0; i<24; ++i)
@@ -482,6 +175,14 @@ int neoncache_get_current_st_f(dynarec_arm_t* dyn, int a)
return i;
return -1;
}
+int neoncache_get_current_st_f_i64(dynarec_arm_t* dyn, int a)
+{
+ for(int i=0; i<24; ++i)
+ if((dyn->n.neoncache[i].t==NEON_CACHE_ST_I64 || dyn->n.neoncache[i].t==NEON_CACHE_ST_F)
+ && dyn->n.neoncache[i].n==a)
+ return i;
+ return -1;
+}
static void neoncache_promote_double_forward(dynarec_arm_t* dyn, int ninst, int maxinst, int a);
static void neoncache_promote_double_internal(dynarec_arm_t* dyn, int ninst, int maxinst, int a);
static void neoncache_promote_double_combined(dynarec_arm_t* dyn, int ninst, int maxinst, int a)
@@ -491,7 +192,7 @@ static void neoncache_promote_double_combined(dynarec_arm_t* dyn, int ninst, int
a = dyn->insts[ninst].n.combined2;
} else
a = dyn->insts[ninst].n.combined1;
- int i = neoncache_get_st_f_noback(dyn, ninst, a);
+ int i = neoncache_get_st_f_i64_noback(dyn, ninst, a);
//if(box64_dynarec_dump) dynarec_log(LOG_NONE, "neoncache_promote_double_combined, ninst=%d combined%c %d i=%d (stack:%d/%d)\n", ninst, (a == dyn->insts[ninst].n.combined2)?'2':'1', a ,i, dyn->insts[ninst].n.stack_push, -dyn->insts[ninst].n.stack_pop);
if(i>=0) {
dyn->insts[ninst].n.neoncache[i].t = NEON_CACHE_ST_D;
@@ -510,7 +211,7 @@ static void neoncache_promote_double_internal(dynarec_arm_t* dyn, int ninst, int
return;
while(ninst>=0) {
a+=dyn->insts[ninst].n.stack_pop; // adjust Stack depth: add pop'd ST (going backward)
- int i = neoncache_get_st_f(dyn, ninst, a);
+ int i = neoncache_get_st_f_i64(dyn, ninst, a);
//if(box64_dynarec_dump) dynarec_log(LOG_NONE, "neoncache_promote_double_internal, ninst=%d, a=%d st=%d:%d, i=%d\n", ninst, a, dyn->insts[ninst].n.stack, dyn->insts[ninst].n.stack_next, i);
if(i<0) return;
dyn->insts[ninst].n.neoncache[i].t = NEON_CACHE_ST_D;
@@ -545,7 +246,7 @@ static void neoncache_promote_double_forward(dynarec_arm_t* dyn, int ninst, int
else if (a==dyn->insts[ninst].n.combined2)
a = dyn->insts[ninst].n.combined1;
}
- int i = neoncache_get_st_f_noback(dyn, ninst, a);
+ int i = neoncache_get_st_f_i64_noback(dyn, ninst, a);
//if(box64_dynarec_dump) dynarec_log(LOG_NONE, "neoncache_promote_double_forward, ninst=%d, a=%d st=%d:%d(%d/%d), i=%d\n", ninst, a, dyn->insts[ninst].n.stack, dyn->insts[ninst].n.stack_next, dyn->insts[ninst].n.stack_push, -dyn->insts[ninst].n.stack_pop, i);
if(i<0) return;
dyn->insts[ninst].n.neoncache[i].t = NEON_CACHE_ST_D;
@@ -566,7 +267,7 @@ static void neoncache_promote_double_forward(dynarec_arm_t* dyn, int ninst, int
void neoncache_promote_double(dynarec_arm_t* dyn, int ninst, int a)
{
- int i = neoncache_get_current_st_f(dyn, a);
+ int i = neoncache_get_current_st_f_i64(dyn, a);
//if(box64_dynarec_dump) dynarec_log(LOG_NONE, "neoncache_promote_double, ninst=%d a=%d st=%d i=%d\n", ninst, a, dyn->n.stack, i);
if(i<0) return;
dyn->n.neoncache[i].t = NEON_CACHE_ST_D;
@@ -599,31 +300,23 @@ int neoncache_combine_st(dynarec_arm_t* dyn, int ninst, int a, int b)
if( neoncache_get_current_st(dyn, ninst, a)==NEON_CACHE_ST_F
&& neoncache_get_current_st(dyn, ninst, b)==NEON_CACHE_ST_F )
return NEON_CACHE_ST_F;
+ // don't combine i64, it's only for load/store
+ /*if( neoncache_get_current_st(dyn, ninst, a)==NEON_CACHE_ST_I64
+ && neoncache_get_current_st(dyn, ninst, b)==NEON_CACHE_ST_I64 )
+ return NEON_CACHE_ST_I64;*/
return NEON_CACHE_ST_D;
}
-int isPred(dynarec_arm_t* dyn, int ninst, int pred) {
- for(int i=0; i<dyn->insts[ninst].pred_sz; ++i)
- if(dyn->insts[ninst].pred[i]==pred)
- return pred;
- return -1;
-}
-int getNominalPred(dynarec_arm_t* dyn, int ninst) {
- if((ninst<=0) || !dyn->insts[ninst].pred_sz)
- return -1;
- if(isPred(dyn, ninst, ninst-1)!=-1)
- return ninst-1;
- return dyn->insts[ninst].pred[0];
-}
-
-int isCacheEmpty(dynarec_arm_t* dyn, int ninst) {
+static int isCacheEmpty(dynarec_native_t* dyn, int ninst) {
if(dyn->insts[ninst].n.stack_next) {
return 0;
}
for(int i=0; i<24; ++i)
if(dyn->insts[ninst].n.neoncache[i].v) { // there is something at ninst for i
if(!(
- (dyn->insts[ninst].n.neoncache[i].t==NEON_CACHE_ST_F || dyn->insts[ninst].n.neoncache[i].t==NEON_CACHE_ST_D)
+ (dyn->insts[ninst].n.neoncache[i].t==NEON_CACHE_ST_F
+ || dyn->insts[ninst].n.neoncache[i].t==NEON_CACHE_ST_D
+ || dyn->insts[ninst].n.neoncache[i].t==NEON_CACHE_ST_I64)
&& dyn->insts[ninst].n.neoncache[i].n<dyn->insts[ninst].n.stack_pop))
return 0;
}
@@ -631,7 +324,7 @@ int isCacheEmpty(dynarec_arm_t* dyn, int ninst) {
}
-static int fpuCacheNeedsTransform(dynarec_arm_t* dyn, int ninst) {
+int fpuCacheNeedsTransform(dynarec_arm_t* dyn, int ninst) {
int i2 = dyn->insts[ninst].x64.jmp_insts;
if(i2<0)
return 1;
@@ -646,7 +339,9 @@ static int fpuCacheNeedsTransform(dynarec_arm_t* dyn, int ninst) {
for(int i=0; i<24 && !ret; ++i)
if(dyn->insts[ninst].n.neoncache[i].v) { // there is something at ninst for i
if(!(
- (dyn->insts[ninst].n.neoncache[i].t==NEON_CACHE_ST_F || dyn->insts[ninst].n.neoncache[i].t==NEON_CACHE_ST_D)
+ (dyn->insts[ninst].n.neoncache[i].t==NEON_CACHE_ST_F
+ || dyn->insts[ninst].n.neoncache[i].t==NEON_CACHE_ST_D
+ || dyn->insts[ninst].n.neoncache[i].t==NEON_CACHE_ST_I64)
&& dyn->insts[ninst].n.neoncache[i].n<dyn->insts[ninst].n.stack_pop))
ret = 1;
}
@@ -678,48 +373,6 @@ static int fpuCacheNeedsTransform(dynarec_arm_t* dyn, int ninst) {
return ret;
}
-static int flagsCacheNeedsTransform(dynarec_arm_t* dyn, int ninst) {
- int jmp = dyn->insts[ninst].x64.jmp_insts;
- if(jmp<0)
- return 0;
- if(dyn->insts[ninst].f_exit.dfnone) // flags are fully known, nothing we can do more
- return 0;
-/* if((dyn->f.pending!=SF_SET)
- && (dyn->f.pending!=SF_SET_PENDING)) {
- if(dyn->f.pending!=SF_PENDING) {*/
- switch (dyn->insts[jmp].f_entry.pending) {
- case SF_UNKNOWN: return 0;
- case SF_SET:
- if(dyn->insts[ninst].f_exit.pending!=SF_SET && dyn->insts[ninst].f_exit.pending!=SF_SET_PENDING)
- return 1;
- else
- return 0;
- case SF_SET_PENDING:
- if(dyn->insts[ninst].f_exit.pending!=SF_SET
- && dyn->insts[ninst].f_exit.pending!=SF_SET_PENDING
- && dyn->insts[ninst].f_exit.pending!=SF_PENDING)
- return 1;
- else
- return 0;
- case SF_PENDING:
- if(dyn->insts[ninst].f_exit.pending!=SF_SET
- && dyn->insts[ninst].f_exit.pending!=SF_SET_PENDING
- && dyn->insts[ninst].f_exit.pending!=SF_PENDING)
- return 1;
- else
- return (dyn->insts[jmp].f_entry.dfnone == dyn->insts[ninst].f_exit.dfnone)?0:1;
- }
- if(dyn->insts[jmp].f_entry.dfnone && !dyn->insts[ninst].f_exit.dfnone)
- return 1;
- return 0;
-}
-int CacheNeedsTransform(dynarec_arm_t* dyn, int ninst) {
- int ret = 0;
- if (fpuCacheNeedsTransform(dyn, ninst)) ret|=1;
- if (flagsCacheNeedsTransform(dyn, ninst)) ret|=2;
- return ret;
-}
-
void neoncacheUnwind(neoncache_t* cache)
{
if(cache->swapped) {
@@ -727,7 +380,7 @@ void neoncacheUnwind(neoncache_t* cache)
int a = -1;
int b = -1;
for(int j=0; j<24 && ((a==-1) || (b==-1)); ++j)
- if((cache->neoncache[j].t == NEON_CACHE_ST_D || cache->neoncache[j].t == NEON_CACHE_ST_F)) {
+ if((cache->neoncache[j].t == NEON_CACHE_ST_D || cache->neoncache[j].t == NEON_CACHE_ST_F || cache->neoncache[j].t == NEON_CACHE_ST_I64)) {
if(cache->neoncache[j].n == cache->combined1)
a = j;
else if(cache->neoncache[j].n == cache->combined2)
@@ -751,7 +404,7 @@ void neoncacheUnwind(neoncache_t* cache)
if(cache->stack_push) {
// unpush
for(int j=0; j<24; ++j) {
- if((cache->neoncache[j].t == NEON_CACHE_ST_D || cache->neoncache[j].t == NEON_CACHE_ST_F)) {
+ if((cache->neoncache[j].t == NEON_CACHE_ST_D || cache->neoncache[j].t == NEON_CACHE_ST_F || cache->neoncache[j].t == NEON_CACHE_ST_I64)) {
if(cache->neoncache[j].n<cache->stack_push)
cache->neoncache[j].v = 0;
else
@@ -796,6 +449,7 @@ void neoncacheUnwind(neoncache_t* cache)
break;
case NEON_CACHE_ST_F:
case NEON_CACHE_ST_D:
+ case NEON_CACHE_ST_I64:
cache->x87cache[x87reg] = cache->neoncache[i].n;
cache->x87reg[x87reg] = i;
++x87reg;
@@ -813,7 +467,6 @@ void neoncacheUnwind(neoncache_t* cache)
}
#define F8 *(uint8_t*)(addr++)
-#define F32 *(uint32_t*)(addr+=4, addr-4)
#define F32S64 (uint64_t)(int64_t)*(int32_t*)(addr+=4, addr-4)
// Get if ED will have the correct parity. Not emiting anything. Parity is 2 for DWORD or 3 for QWORD
int getedparity(dynarec_arm_t* dyn, int ninst, uintptr_t addr, uint8_t nextop, int parity, int delta)
@@ -853,64 +506,8 @@ int getedparity(dynarec_arm_t* dyn, int ninst, uintptr_t addr, uint8_t nextop, i
return 0; //Form [reg1 + reg2<<N + XXXXXX]
}
}
-
-// Do the GETED, but don't emit anything...
-uintptr_t fakeed(dynarec_arm_t* dyn, uintptr_t addr, int ninst, uint8_t nextop)
-{
- (void)dyn; (void)addr; (void)ninst;
-
- if((nextop&0xC0)==0xC0)
- return addr;
- if(!(nextop&0xC0)) {
- if((nextop&7)==4) {
- uint8_t sib = F8;
- if((sib&0x7)==5) {
- addr+=4;
- }
- } else if((nextop&7)==5) {
- addr+=4;
- }
- } else {
- if((nextop&7)==4) {
- ++addr;
- }
- if(nextop&0x80) {
- addr+=4;
- } else {
- ++addr;
- }
- }
- return addr;
-}
#undef F8
-#undef F32
-
-int isNativeCall(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t* calladdress, int* retn)
-{
- (void)dyn;
-
-#define PK(a) *(uint8_t*)(addr+a)
-#define PK32(a) *(int32_t*)(addr+a)
-
- if(!addr || !getProtection(addr))
- return 0;
- if(PK(0)==0xff && PK(1)==0x25) { // "absolute" jump, maybe the GOT (well, RIP relative in fact)
- uintptr_t a1 = addr + 6 + (PK32(2)); // need to add a check to see if the address is from the GOT !
- addr = (uintptr_t)getAlternate(*(void**)a1);
- }
- if(!addr || !getProtection(addr))
- return 0;
- onebridge_t *b = (onebridge_t*)(addr);
- if(b->CC==0xCC && b->S=='S' && b->C=='C' && b->w!=(wrapper_t)0 && b->f!=(uintptr_t)PltResolver) {
- // found !
- if(retn) *retn = (b->C3==0xC2)?b->N:0;
- if(calladdress) *calladdress = addr+1;
- return 1;
- }
- return 0;
-#undef PK32
-#undef PK
-}
+#undef F32S64
const char* getCacheName(int t, int n)
{
@@ -918,6 +515,7 @@ const char* getCacheName(int t, int n)
switch(t) {
case NEON_CACHE_ST_D: sprintf(buff, "ST%d", n); break;
case NEON_CACHE_ST_F: sprintf(buff, "st%d", n); break;
+ case NEON_CACHE_ST_I64: sprintf(buff, "STi%d", n); break;
case NEON_CACHE_MM: sprintf(buff, "MM%d", n); break;
case NEON_CACHE_XMMW: sprintf(buff, "XMM%d", n); break;
case NEON_CACHE_XMMR: sprintf(buff, "xmm%d", n); break;
@@ -927,20 +525,59 @@ const char* getCacheName(int t, int n)
return buff;
}
-// is inst clean for a son branch?
-int isInstClean(dynarec_arm_t* dyn, int ninst)
-{
- // check flags cache
- if(dyn->insts[ninst].f_entry.dfnone || dyn->insts[ninst].f_entry.pending)
- return 0;
- if(dyn->insts[ninst].x64.state_flags)
- return 0;
- // check neoncache
- neoncache_t* n = &dyn->insts[ninst].n;
- if(n->news || n->stack || n->stack_next)
- return 0;
- for(int i=0; i<24; ++i)
- if(n->neoncache[i].v)
- return 0;
- return 1;
+void inst_name_pass3(dynarec_native_t* dyn, int ninst, const char* name, rex_t rex)
+{
+ if(box64_dynarec_dump) {
+ printf_x64_instruction(rex.is32bits?my_context->dec32:my_context->dec, &dyn->insts[ninst].x64, name);
+ dynarec_log(LOG_NONE, "%s%p: %d emitted opcodes, inst=%d, barrier=%d state=%d/%d(%d), %s=%X/%X, use=%X, need=%X/%X, sm=%d/%d",
+ (box64_dynarec_dump>1)?"\e[32m":"",
+ (void*)(dyn->native_start+dyn->insts[ninst].address),
+ dyn->insts[ninst].size/4,
+ ninst,
+ dyn->insts[ninst].x64.barrier,
+ dyn->insts[ninst].x64.state_flags,
+ dyn->f.pending,
+ dyn->f.dfnone,
+ dyn->insts[ninst].x64.may_set?"may":"set",
+ dyn->insts[ninst].x64.set_flags,
+ dyn->insts[ninst].x64.gen_flags,
+ dyn->insts[ninst].x64.use_flags,
+ dyn->insts[ninst].x64.need_before,
+ dyn->insts[ninst].x64.need_after,
+ dyn->smread, dyn->smwrite);
+ if(dyn->insts[ninst].pred_sz) {
+ dynarec_log(LOG_NONE, ", pred=");
+ for(int ii=0; ii<dyn->insts[ninst].pred_sz; ++ii)
+ dynarec_log(LOG_NONE, "%s%d", ii?"/":"", dyn->insts[ninst].pred[ii]);
+ }
+ if(dyn->insts[ninst].x64.jmp && dyn->insts[ninst].x64.jmp_insts>=0)
+ dynarec_log(LOG_NONE, ", jmp=%d", dyn->insts[ninst].x64.jmp_insts);
+ if(dyn->insts[ninst].x64.jmp && dyn->insts[ninst].x64.jmp_insts==-1)
+ dynarec_log(LOG_NONE, ", jmp=out");
+ if(dyn->last_ip)
+ dynarec_log(LOG_NONE, ", last_ip=%p", (void*)dyn->last_ip);
+ for(int ii=0; ii<24; ++ii) {
+ switch(dyn->insts[ninst].n.neoncache[ii].t) {
+ case NEON_CACHE_ST_D: dynarec_log(LOG_NONE, " D%d:%s", ii, getCacheName(dyn->insts[ninst].n.neoncache[ii].t, dyn->insts[ninst].n.neoncache[ii].n)); break;
+ case NEON_CACHE_ST_F: dynarec_log(LOG_NONE, " S%d:%s", ii, getCacheName(dyn->insts[ninst].n.neoncache[ii].t, dyn->insts[ninst].n.neoncache[ii].n)); break;
+ case NEON_CACHE_ST_I64: dynarec_log(LOG_NONE, " D%d:%s", ii, getCacheName(dyn->insts[ninst].n.neoncache[ii].t, dyn->insts[ninst].n.neoncache[ii].n)); break;
+ case NEON_CACHE_MM: dynarec_log(LOG_NONE, " D%d:%s", ii, getCacheName(dyn->insts[ninst].n.neoncache[ii].t, dyn->insts[ninst].n.neoncache[ii].n)); break;
+ case NEON_CACHE_XMMW: dynarec_log(LOG_NONE, " Q%d:%s", ii, getCacheName(dyn->insts[ninst].n.neoncache[ii].t, dyn->insts[ninst].n.neoncache[ii].n)); break;
+ case NEON_CACHE_XMMR: dynarec_log(LOG_NONE, " Q%d:%s", ii, getCacheName(dyn->insts[ninst].n.neoncache[ii].t, dyn->insts[ninst].n.neoncache[ii].n)); break;
+ case NEON_CACHE_SCR: dynarec_log(LOG_NONE, " D%d:%s", ii, getCacheName(dyn->insts[ninst].n.neoncache[ii].t, dyn->insts[ninst].n.neoncache[ii].n)); break;
+ case NEON_CACHE_NONE:
+ default: break;
+ }
+ }
+ if(dyn->n.stack || dyn->insts[ninst].n.stack_next || dyn->insts[ninst].n.x87stack)
+ dynarec_log(LOG_NONE, " X87:%d/%d(+%d/-%d)%d", dyn->n.stack, dyn->insts[ninst].n.stack_next, dyn->insts[ninst].n.stack_push, dyn->insts[ninst].n.stack_pop, dyn->insts[ninst].n.x87stack);
+ if(dyn->insts[ninst].n.combined1 || dyn->insts[ninst].n.combined2)
+ dynarec_log(LOG_NONE, " %s:%d/%d", dyn->insts[ninst].n.swapped?"SWP":"CMB", dyn->insts[ninst].n.combined1, dyn->insts[ninst].n.combined2);
+ dynarec_log(LOG_NONE, "%s\n", (box64_dynarec_dump>1)?"\e[m":"");
+ }
}
+
+void print_opcode(dynarec_native_t* dyn, int ninst, uint32_t opcode)
+{
+ dynarec_log(LOG_NONE, "\t%08x\t%s\n", opcode, arm64_print(opcode, (uintptr_t)dyn->block));
+} \ No newline at end of file
diff --git a/src/dynarec/arm64/dynarec_arm64_functions.h b/src/dynarec/arm64/dynarec_arm64_functions.h
index f8d5d12..db31887 100755..100644
--- a/src/dynarec/arm64/dynarec_arm64_functions.h
+++ b/src/dynarec/arm64/dynarec_arm64_functions.h
@@ -1,46 +1,7 @@
#ifndef __DYNAREC_ARM_FUNCTIONS_H__
#define __DYNAREC_ARM_FUNCTIONS_H__
-typedef struct x64emu_s x64emu_t;
-
-void arm_fstp(x64emu_t* emu, void* p);
-
-void arm_print_armreg(x64emu_t* emu, uintptr_t reg, uintptr_t n);
-
-void arm_f2xm1(x64emu_t* emu);
-void arm_fyl2x(x64emu_t* emu);
-void arm_ftan(x64emu_t* emu);
-void arm_fpatan(x64emu_t* emu);
-void arm_fxtract(x64emu_t* emu);
-void arm_fprem(x64emu_t* emu);
-void arm_fyl2xp1(x64emu_t* emu);
-void arm_fsincos(x64emu_t* emu);
-void arm_frndint(x64emu_t* emu);
-void arm_fscale(x64emu_t* emu);
-void arm_fsin(x64emu_t* emu);
-void arm_fcos(x64emu_t* emu);
-void arm_fbld(x64emu_t* emu, uint8_t* ed);
-void arm_fild64(x64emu_t* emu, int64_t* ed);
-void arm_fbstp(x64emu_t* emu, uint8_t* ed);
-void arm_fistp64(x64emu_t* emu, int64_t* ed);
-void arm_fistt64(x64emu_t* emu, int64_t* ed);
-void arm_fld(x64emu_t* emu, uint8_t* ed);
-void arm_fsave(x64emu_t* emu, uint8_t* ed);
-void arm_frstor(x64emu_t* emu, uint8_t* ed);
-void arm_fprem1(x64emu_t* emu);
-
-void arm_aesd(x64emu_t* emu, int xmm);
-void arm_aese(x64emu_t* emu, int xmm);
-void arm_aesdlast(x64emu_t* emu, int xmm);
-void arm_aeselast(x64emu_t* emu, int xmm);
-void arm_aesimc(x64emu_t* emu, int xmm);
-void arm_aeskeygenassist(x64emu_t* emu, int gx, int ex, void* p, uint32_t u8);
-void arm_pclmul(x64emu_t* emu, int gx, int ex, void* p, uint32_t u8);
-
-void arm_clflush(x64emu_t* emu, void* p);
-
-void arm_ud(x64emu_t* emu);
-void arm_priv(x64emu_t* emu);
+#include "../dynarec_native_functions.h"
// Get an FPU scratch reg
int fpu_get_scratch(dynarec_arm_t* dyn);
@@ -60,38 +21,32 @@ void fpu_reset_reg(dynarec_arm_t* dyn);
// ---- Neon cache functions
// Get type for STx
int neoncache_get_st(dynarec_arm_t* dyn, int ninst, int a);
-// Get if STx is FLOAT or DOUBLE
+// Get if STx is FLOAT
int neoncache_get_st_f(dynarec_arm_t* dyn, int ninst, int a);
+// Get if STx is FLOAT or I64
+int neoncache_get_st_f_i64(dynarec_arm_t* dyn, int ninst, int a);
// Get actual type for STx
int neoncache_get_current_st(dynarec_arm_t* dyn, int ninst, int a);
-// Get actual STx is FLOAT or DOUBLE
+// Get actual STx is FLOAT
int neoncache_get_current_st_f(dynarec_arm_t* dyn, int a);
+// Get actual STx is FLOAT or I64
+int neoncache_get_current_st_f_i64(dynarec_arm_t* dyn, int a);
// Back-propagate a change float->double
void neoncache_promote_double(dynarec_arm_t* dyn, int ninst, int a);
// Combine and propagate if needed (pass 1 only)
int neoncache_combine_st(dynarec_arm_t* dyn, int ninst, int a, int b); // with stack current dyn->n_stack*
-// FPU Cache transformation (for loops)
-int CacheNeedsTransform(dynarec_arm_t* dyn, int i1);
+// FPU Cache transformation (for loops) // Specific, need to be written by backend
+int fpuCacheNeedsTransform(dynarec_arm_t* dyn, int ninst);
// Undo the changes of a neoncache to get the status before the instruction
void neoncacheUnwind(neoncache_t* cache);
-// is inst clean for a son branch?
-int isInstClean(dynarec_arm_t* dyn, int ninst);
-
-// predecessor access
-int isPred(dynarec_arm_t* dyn, int ninst, int pred);
-int getNominalPred(dynarec_arm_t* dyn, int ninst);
-
// Get if ED will have the correct parity. Not emiting anything. Parity is 2 for DWORD or 3 for QWORD
-int getedparity(dynarec_arm_t* dyn, int ninst, uintptr_t addr, uint8_t nextop, int parity, int delta);
-// Do the GETED, but don't emit anything...
-uintptr_t fakeed(dynarec_arm_t* dyn, uintptr_t addr, int ninst, uint8_t nextop);
-
-// Is what pointed at addr a native call? And if yes, to what function?
-int isNativeCall(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t* calladdress, int* retn);
+int getedparity(dynarec_native_t* dyn, int ninst, uintptr_t addr, uint8_t nextop, int parity, int delta);
const char* getCacheName(int t, int n);
-#endif //__DYNAREC_ARM_FUNCTIONS_H__ \ No newline at end of file
+void inst_name_pass3(dynarec_native_t* dyn, int ninst, const char* name, rex_t rex);
+void print_opcode(dynarec_native_t* dyn, int ninst, uint32_t opcode);
+#endif //__DYNAREC_ARM_FUNCTIONS_H__
diff --git a/src/dynarec/arm64/dynarec_arm64_helper.c b/src/dynarec/arm64/dynarec_arm64_helper.c
index aa09934..13b5835 100755..100644
--- a/src/dynarec/arm64/dynarec_arm64_helper.c
+++ b/src/dynarec/arm64/dynarec_arm64_helper.c
@@ -1,9 +1,9 @@
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
-#include <pthread.h>
#include <errno.h>
#include <assert.h>
+#include <string.h>
#include "debug.h"
#include "box64context.h"
@@ -18,7 +18,6 @@
#include "x64trace.h"
#include "dynarec_native.h"
#include "../dynablock_private.h"
-#include "../tools/bridge_private.h"
#include "custommem.h"
#include "arm64_printer.h"
@@ -26,12 +25,19 @@
#include "dynarec_arm64_functions.h"
#include "dynarec_arm64_helper.h"
+static uintptr_t geted_32(dynarec_arm_t* dyn, uintptr_t addr, int ninst, uint8_t nextop, uint8_t* ed, uint8_t hint, int64_t* fixaddress, int* unscaled, int absmax, uint32_t mask, int* l, int s);
+
/* setup r2 to address pointed by ED, also fixaddress is an optionnal delta in the range [-absmax, +absmax], with delta&mask==0 to be added to ed for LDR/STR */
-uintptr_t geted(dynarec_arm_t* dyn, uintptr_t addr, int ninst, uint8_t nextop, uint8_t* ed, uint8_t hint, int64_t* fixaddress, int absmax, uint32_t mask, rex_t rex, int *l, int s, int delta)
+uintptr_t geted(dynarec_arm_t* dyn, uintptr_t addr, int ninst, uint8_t nextop, uint8_t* ed, uint8_t hint, int64_t* fixaddress, int* unscaled, int absmax, uint32_t mask, rex_t rex, int *l, int s, int delta)
{
MAYUSE(dyn); MAYUSE(ninst); MAYUSE(delta);
+ if(rex.is32bits)
+ return geted_32(dyn, addr, ninst, nextop, ed, hint, fixaddress, unscaled, absmax, mask, l, s);
+
int lock = l?((l==LOCK_LOCK)?1:2):0;
+ if(unscaled)
+ *unscaled = 0;
if(lock==2)
*l = 0;
uint8_t ret = x2;
@@ -49,11 +55,16 @@ uintptr_t geted(dynarec_arm_t* dyn, uintptr_t addr, int ninst, uint8_t nextop, u
if((sib&0x7)==5) {
int64_t tmp = F32S;
if (sib_reg!=4) {
- if(tmp && ((tmp<absmin) || (tmp>absmax) || (tmp&mask))) {
+ if(tmp && (!((tmp>=absmin) && (tmp<=absmax) && !(tmp&mask))) || !(unscaled && (tmp>-256) && (tmp<256))) {
MOV64x(scratch, tmp);
ADDx_REG_LSL(ret, scratch, xRAX+sib_reg, (sib>>6));
} else {
- LSLx(ret, xRAX+sib_reg, (sib>>6));
+ if(sib>>6) {
+ LSLx(ret, xRAX+sib_reg, (sib>>6));
+ } else
+ ret = xRAX+sib_reg;
+ if(unscaled && (tmp>-256) && (tmp<256))
+ *unscaled = 1;
*fixaddress = tmp;
}
} else {
@@ -71,14 +82,22 @@ uintptr_t geted(dynarec_arm_t* dyn, uintptr_t addr, int ninst, uint8_t nextop, u
}
}
} else if((nextop&7)==5) {
- uint64_t tmp = F32S64;
+ int64_t tmp = F32S64;
if((tmp>=absmin) && (tmp<=absmax) && !(tmp&mask)) {
GETIP(addr+delta);
ret = xRIP;
*fixaddress = tmp;
- } else if(tmp<0x1000) {
+ } else if(unscaled && (tmp>-256) && (tmp<256)) {
+ GETIP(addr+delta);
+ ret = xRIP;
+ *fixaddress = tmp;
+ *unscaled = 1;
+ } else if(tmp>0 && tmp<0x1000) {
GETIP(addr+delta);
ADDx_U12(ret, xRIP, tmp);
+ } else if(tmp<0 && tmp>-0x1000) {
+ GETIP(addr+delta);
+ SUBx_U12(ret, xRIP, -tmp);
} else if(tmp+addr+delta<0x1000000000000LL) { // 3 opcodes to load immediate is cheap enough
MOV64x(ret, tmp+addr+delta);
} else {
@@ -103,10 +122,12 @@ uintptr_t geted(dynarec_arm_t* dyn, uintptr_t addr, int ninst, uint8_t nextop, u
}
if(nextop&0x80)
i64 = F32S;
- else
+ else
i64 = F8S;
- if(i64==0 || ((i64>=absmin) && (i64<=absmax) && !(i64&mask))) {
+ if(i64==0 || ((i64>=absmin) && (i64<=absmax) && !(i64&mask)) || (unscaled && (i64>-256) && (i64<256))) {
*fixaddress = i64;
+ if(unscaled && (i64>-256) && (i64<256))
+ *unscaled = 1;
if((nextop&7)==4) {
if (sib_reg!=4) {
ADDx_REG_LSL(ret, xRAX+(sib&0x07)+(rex.b<<3), xRAX+sib_reg, (sib>>6));
@@ -165,12 +186,149 @@ uintptr_t geted(dynarec_arm_t* dyn, uintptr_t addr, int ninst, uint8_t nextop, u
return addr;
}
+static uintptr_t geted_32(dynarec_arm_t* dyn, uintptr_t addr, int ninst, uint8_t nextop, uint8_t* ed, uint8_t hint, int64_t* fixaddress, int* unscaled, int absmax, uint32_t mask, int* l, int s)
+{
+ MAYUSE(dyn); MAYUSE(ninst);
+
+ int lock = l?((l==LOCK_LOCK)?1:2):0;
+ if(unscaled)
+ *unscaled = 0;
+ if(lock==2)
+ *l = 0;
+ uint8_t ret = x2;
+ uint8_t scratch = x2;
+ *fixaddress = 0;
+ if(hint>0) ret = hint;
+ if(hint>0 && hint<xRAX) scratch = hint;
+ int absmin = 0;
+ if(s) absmin=-absmax;
+ MAYUSE(scratch);
+ if(!(nextop&0xC0)) {
+ if((nextop&7)==4) {
+ uint8_t sib = F8;
+ int sib_reg = (sib>>3)&7;
+ if((sib&0x7)==5) {
+ int64_t tmp = F32S;
+ if (sib_reg!=4) {
+ if(tmp && (!((tmp>=absmin) && (tmp<=absmax) && !(tmp&mask))) || !(unscaled && (tmp>-256) && (tmp<256))) {
+ MOV32w(scratch, tmp);
+ ADDw_REG_LSL(ret, scratch, xRAX+sib_reg, (sib>>6));
+ } else {
+ LSLw(ret, xRAX+sib_reg, (sib>>6));
+ *fixaddress = tmp;
+ if(unscaled && (tmp>-256) && (tmp<256))
+ *unscaled = 1;
+ }
+ } else {
+ switch(lock) {
+ case 1: addLockAddress((int32_t)tmp); break;
+ case 2: if(isLockAddress((int32_t)tmp)) *l=1; break;
+ }
+ MOV32w(ret, tmp);
+ }
+ } else {
+ if (sib_reg!=4) {
+ ADDw_REG_LSL(ret, xRAX+(sib&0x7), xRAX+sib_reg, (sib>>6));
+ } else {
+ ret = xRAX+(sib&0x7);
+ }
+ }
+ } else if((nextop&7)==5) {
+ uint64_t tmp = F32;
+ MOV32w(ret, tmp);
+ switch(lock) {
+ case 1: addLockAddress(tmp); break;
+ case 2: if(isLockAddress(tmp)) *l=1; break;
+ }
+ } else {
+ ret = xRAX+(nextop&7);
+ if(ret==hint) {
+ MOVw_REG(hint, ret); //to clear upper part
+ }
+ }
+ } else {
+ int64_t i32;
+ uint8_t sib = 0;
+ int sib_reg = 0;
+ if((nextop&7)==4) {
+ sib = F8;
+ sib_reg = (sib>>3)&7;
+ }
+ if(nextop&0x80)
+ i32 = F32S;
+ else
+ i32 = F8S;
+ if(i32==0 || ((i32>=absmin) && (i32<=absmax) && !(i32&mask)) || (unscaled && (i32>-256) && (i32<256))) {
+ *fixaddress = i32;
+ if(unscaled && (i32>-256) && (i32<256))
+ *unscaled = 1;
+ if((nextop&7)==4) {
+ if (sib_reg!=4) {
+ ADDw_REG_LSL(ret, xRAX+(sib&0x07), xRAX+sib_reg, (sib>>6));
+ } else {
+ ret = xRAX+(sib&0x07);
+ }
+ } else {
+ ret = xRAX+(nextop&0x07);
+ }
+ } else {
+ int64_t sub = (i32<0)?1:0;
+ if(sub) i32 = -i32;
+ if(i32<0x1000) {
+ if((nextop&7)==4) {
+ if (sib_reg!=4) {
+ ADDw_REG_LSL(scratch, xRAX+(sib&0x07), xRAX+sib_reg, (sib>>6));
+ } else {
+ scratch = xRAX+(sib&0x07);
+ }
+ } else
+ scratch = xRAX+(nextop&0x07);
+ if(sub) {
+ SUBw_U12(ret, scratch, i32);
+ } else {
+ ADDw_U12(ret, scratch, i32);
+ }
+ } else {
+ MOV32w(scratch, i32);
+ if((nextop&7)==4) {
+ if (sib_reg!=4) {
+ if(sub) {
+ SUBw_REG(scratch, xRAX+(sib&0x07), scratch);
+ } else {
+ ADDw_REG(scratch, scratch, xRAX+(sib&0x07));
+ }
+ ADDw_REG_LSL(ret, scratch, xRAX+sib_reg, (sib>>6));
+ } else {
+ PASS3(int tmp = xRAX+(sib&0x07));
+ if(sub) {
+ SUBw_REG(ret, tmp, scratch);
+ } else {
+ ADDw_REG(ret, tmp, scratch);
+ }
+ }
+ } else {
+ PASS3(int tmp = xRAX+(nextop&0x07));
+ if(sub) {
+ SUBw_REG(ret, tmp, scratch);
+ } else {
+ ADDw_REG(ret, tmp, scratch);
+ }
+ }
+ }
+ }
+ }
+ *ed = ret;
+ return addr;
+}
+
/* setup r2 to address pointed by ED, also fixaddress is an optionnal delta in the range [-absmax, +absmax], with delta&mask==0 to be added to ed for LDR/STR */
-uintptr_t geted32(dynarec_arm_t* dyn, uintptr_t addr, int ninst, uint8_t nextop, uint8_t* ed, uint8_t hint, int64_t* fixaddress, int absmax, uint32_t mask, rex_t rex, int* l, int s, int delta)
+uintptr_t geted32(dynarec_arm_t* dyn, uintptr_t addr, int ninst, uint8_t nextop, uint8_t* ed, uint8_t hint, int64_t* fixaddress, int* unscaled, int absmax, uint32_t mask, rex_t rex, int* l, int s, int delta)
{
MAYUSE(dyn); MAYUSE(ninst); MAYUSE(delta);
int lock = l?((l==LOCK_LOCK)?1:2):0;
+ if(unscaled)
+ *unscaled = 0;
if(lock==2)
*l = 0;
uint8_t ret = x2;
@@ -188,12 +346,14 @@ uintptr_t geted32(dynarec_arm_t* dyn, uintptr_t addr, int ninst, uint8_t nextop,
if((sib&0x7)==5) {
int64_t tmp = F32S;
if (sib_reg!=4) {
- if(tmp && ((tmp<absmin) || (tmp>absmax) || (tmp&mask))) {
+ if(tmp && (!((tmp>=absmin) && (tmp<=absmax) && !(tmp&mask))) || !(unscaled && (tmp>-256) && (tmp<256))) {
MOV64x(scratch, tmp);
ADDw_REG_LSL(ret, scratch, xRAX+sib_reg, (sib>>6));
} else {
LSLw(ret, xRAX+sib_reg, (sib>>6));
*fixaddress = tmp;
+ if(unscaled && (tmp>-256) && (tmp<256))
+ *unscaled = 1;
}
} else {
switch(lock) {
@@ -234,10 +394,12 @@ uintptr_t geted32(dynarec_arm_t* dyn, uintptr_t addr, int ninst, uint8_t nextop,
}
if(nextop&0x80)
i64 = F32S;
- else
+ else
i64 = F8S;
- if(i64==0 || ((i64>=absmin) && (i64<=absmax) && !(i64&mask))) {
+ if(i64==0 || ((i64>=absmin) && (i64<=absmax) && !(i64&mask)) || (unscaled && (i64>-256) && (i64<256))) {
*fixaddress = i64;
+ if(unscaled && (i64>-256) && (i64<256))
+ *unscaled = 1;
if((nextop&7)==4) {
if (sib_reg!=4) {
ADDw_REG_LSL(ret, xRAX+(sib&0x07)+(rex.b<<3), xRAX+sib_reg, (sib>>6));
@@ -298,10 +460,12 @@ uintptr_t geted32(dynarec_arm_t* dyn, uintptr_t addr, int ninst, uint8_t nextop,
}
/* setup r2 to address pointed by ED, r3 as scratch also fixaddress is an optionnal delta in the range [-absmax, +absmax], with delta&mask==0 to be added to ed for LDR/STR */
-uintptr_t geted16(dynarec_arm_t* dyn, uintptr_t addr, int ninst, uint8_t nextop, uint8_t* ed, uint8_t hint, int64_t* fixaddress, int absmax, uint32_t mask, int s)
+uintptr_t geted16(dynarec_arm_t* dyn, uintptr_t addr, int ninst, uint8_t nextop, uint8_t* ed, uint8_t hint, int64_t* fixaddress, int* unscaled, int absmax, uint32_t mask, int s)
{
MAYUSE(dyn); MAYUSE(ninst);
+ if(unscaled)
+ *unscaled = 0;
uint8_t ret = x2;
uint8_t scratch = x3;
*fixaddress = 0;
@@ -313,8 +477,8 @@ uintptr_t geted16(dynarec_arm_t* dyn, uintptr_t addr, int ninst, uint8_t nextop,
int64_t offset = 0;
int absmin = 0;
if(s) absmin = -absmax;
- if(!n && m==6) {
- offset = F16;
+ if(!n && (m&7)==6) {
+ offset = F16S;
MOVZw(ret, offset);
} else {
switch(n) {
@@ -322,7 +486,11 @@ uintptr_t geted16(dynarec_arm_t* dyn, uintptr_t addr, int ninst, uint8_t nextop,
case 1: offset = F8S; break;
case 2: offset = F16S; break;
}
- if(offset && (offset>absmax || offset<absmin || (offset&mask))) {
+ if(offset && (offset>=absmax && offset<=absmin && !(offset&mask))) {
+ *fixaddress = offset;
+ offset = 0;
+ }
+ if(offset && (unscaled && offset>-256 && offset<256)) {
*fixaddress = offset;
offset = 0;
}
@@ -388,6 +556,7 @@ void jump_to_epilog(dynarec_arm_t* dyn, uintptr_t ip, int reg, int ninst)
} else {
GETIP_(ip);
}
+ NOTEST(x2);
TABLE64(x2, (uintptr_t)arm64_epilog);
SMEND();
BR(x2);
@@ -402,6 +571,7 @@ void jump_to_next(dynarec_arm_t* dyn, uintptr_t ip, int reg, int ninst)
if(reg!=xRIP) {
MOVx_REG(xRIP, reg);
}
+ NOTEST(x2);
uintptr_t tbl = getJumpTable64();
MAYUSE(tbl);
TABLE64(x3, tbl);
@@ -414,6 +584,7 @@ void jump_to_next(dynarec_arm_t* dyn, uintptr_t ip, int reg, int ninst)
UBFXx(x2, xRIP, JMPTABL_START0, JMPTABL_SHIFT0);
LDRx_REG_LSL3(x2, x3, x2);
} else {
+ NOTEST(x2);
uintptr_t p = getJumpTableAddress64(ip);
MAYUSE(p);
TABLE64(x3, p);
@@ -425,18 +596,18 @@ void jump_to_next(dynarec_arm_t* dyn, uintptr_t ip, int reg, int ninst)
}
CLEARIP();
#ifdef HAVE_TRACE
- //MOVx(x3, 15); no access to PC reg
+ //MOVx(x3, 15); no access to PC reg
#endif
SMEND();
BLR(x2); // save LR...
}
-void ret_to_epilog(dynarec_arm_t* dyn, int ninst)
+void ret_to_epilog(dynarec_arm_t* dyn, int ninst, rex_t rex)
{
MAYUSE(dyn); MAYUSE(ninst);
MESSAGE(LOG_DUMP, "Ret to epilog\n");
- POP1(xRIP);
- MOVx_REG(x1, xRIP);
+ POP1z(xRIP);
+ MOVz_REG(x1, xRIP);
SMEND();
if(box64_dynarec_callret) {
// pop the actual return address for ARM stack
@@ -449,6 +620,7 @@ void ret_to_epilog(dynarec_arm_t* dyn, int ninst)
// not the correct return address, regular jump
}
uintptr_t tbl = getJumpTable64();
+ NOTEST(x2);
MOV64x(x2, tbl);
UBFXx(x3, xRIP, JMPTABL_START3, JMPTABL_SHIFT3);
LDRx_REG_LSL3(x2, x2, x3);
@@ -462,18 +634,18 @@ void ret_to_epilog(dynarec_arm_t* dyn, int ninst)
CLEARIP();
}
-void retn_to_epilog(dynarec_arm_t* dyn, int ninst, int n)
+void retn_to_epilog(dynarec_arm_t* dyn, int ninst, rex_t rex, int n)
{
MAYUSE(dyn); MAYUSE(ninst);
MESSAGE(LOG_DUMP, "Retn to epilog\n");
- POP1(xRIP);
+ POP1z(xRIP);
if(n>0xfff) {
MOV32w(w1, n);
- ADDx_REG(xRSP, xRSP, x1);
+ ADDz_REG(xRSP, xRSP, x1);
} else {
- ADDx_U12(xRSP, xRSP, n);
+ ADDz_U12(xRSP, xRSP, n);
}
- MOVx_REG(x1, xRIP);
+ MOVz_REG(x1, xRIP);
SMEND();
if(box64_dynarec_callret) {
// pop the actual return address for ARM stack
@@ -486,6 +658,7 @@ void retn_to_epilog(dynarec_arm_t* dyn, int ninst, int n)
// not the correct return address, regular jump
}
uintptr_t tbl = getJumpTable64();
+ NOTEST(x2);
MOV64x(x2, tbl);
UBFXx(x3, xRIP, JMPTABL_START3, JMPTABL_SHIFT3);
LDRx_REG_LSL3(x2, x2, x3);
@@ -505,24 +678,35 @@ void iret_to_epilog(dynarec_arm_t* dyn, int ninst, int is64bits)
MAYUSE(ninst);
MESSAGE(LOG_DUMP, "IRet to epilog\n");
// POP IP
- POP1(xRIP);
- // POP CS
- POP1(x2);
+ NOTEST(x2);
+ if(is64bits) {
+ POP1(xRIP);
+ POP1(x2);
+ POP1(xFlags);
+ } else {
+ POP1_32(xRIP);
+ POP1_32(x2);
+ POP1_32(xFlags);
+ }
+ // x2 is CS
STRH_U12(x2, xEmu, offsetof(x64emu_t, segs[_CS]));
- MOVZw(x1, 0);
- STRx_U12(x1, xEmu, offsetof(x64emu_t, segs_serial[_CS]));
- STRx_U12(x1, xEmu, offsetof(x64emu_t, segs_serial[_SS]));
- // POP EFLAGS
- POP1(xFlags);
+ STRw_U12(xZR, xEmu, offsetof(x64emu_t, segs_serial[_CS]));
+ // clean EFLAGS
MOV32w(x1, 0x3F7FD7);
ANDx_REG(xFlags, xFlags, x1);
- ORRx_mask(xFlags, xFlags, 1, 0b111111, 0);
+ ORRx_mask(xFlags, xFlags, 1, 0b111111, 0); // xFlags | 0b10
SET_DFNONE(x1);
// POP RSP
- POP1(x3);
+ if(is64bits) {
+ POP1(x3); //rsp
+ POP1(x2); //ss
+ } else {
+ POP1_32(x3); //rsp
+ POP1_32(x2); //ss
+ }
// POP SS
- POP1(x2);
STRH_U12(x2, xEmu, offsetof(x64emu_t, segs[_SS]));
+ STRw_U12(xZR, xEmu, offsetof(x64emu_t, segs_serial[_SS]));
// set new RSP
MOVx_REG(xRSP, x3);
// Ret....
@@ -662,7 +846,9 @@ static void x87_reset(dynarec_arm_t* dyn)
dyn->n.swapped = 0;
dyn->n.barrier = 0;
for(int i=0; i<24; ++i)
- if(dyn->n.neoncache[i].t == NEON_CACHE_ST_F || dyn->n.neoncache[i].t == NEON_CACHE_ST_D)
+ if(dyn->n.neoncache[i].t == NEON_CACHE_ST_F
+ || dyn->n.neoncache[i].t == NEON_CACHE_ST_D
+ || dyn->n.neoncache[i].t == NEON_CACHE_ST_I64)
dyn->n.neoncache[i].v = 0;
}
@@ -723,7 +909,9 @@ int x87_do_push(dynarec_arm_t* dyn, int ninst, int s1, int t)
dyn->n.stack_push+=1;
// move all regs in cache, and find a free one
for(int j=0; j<24; ++j)
- if((dyn->n.neoncache[j].t == NEON_CACHE_ST_D) || (dyn->n.neoncache[j].t == NEON_CACHE_ST_F))
+ if((dyn->n.neoncache[j].t == NEON_CACHE_ST_D)
+ ||(dyn->n.neoncache[j].t == NEON_CACHE_ST_F)
+ ||(dyn->n.neoncache[j].t == NEON_CACHE_ST_I64))
++dyn->n.neoncache[j].n;
int ret = -1;
for(int i=0; i<8; ++i)
@@ -732,13 +920,7 @@ int x87_do_push(dynarec_arm_t* dyn, int ninst, int s1, int t)
else if(ret==-1) {
dyn->n.x87cache[i] = 0;
ret=dyn->n.x87reg[i]=fpu_get_reg_x87(dyn, t, 0);
- #if STEP == 1
- // need to check if reg is compatible with float
- if((ret>15) && (t == NEON_CACHE_ST_F))
- dyn->n.neoncache[ret].t = NEON_CACHE_ST_D;
- #else
dyn->n.neoncache[ret].t = X87_ST0;
- #endif
}
return ret;
}
@@ -752,7 +934,9 @@ void x87_do_push_empty(dynarec_arm_t* dyn, int ninst, int s1)
dyn->n.stack_push+=1;
// move all regs in cache
for(int j=0; j<24; ++j)
- if((dyn->n.neoncache[j].t == NEON_CACHE_ST_D) || (dyn->n.neoncache[j].t == NEON_CACHE_ST_F))
+ if((dyn->n.neoncache[j].t == NEON_CACHE_ST_D)
+ ||(dyn->n.neoncache[j].t == NEON_CACHE_ST_F)
+ ||(dyn->n.neoncache[j].t == NEON_CACHE_ST_I64))
++dyn->n.neoncache[j].n;
for(int i=0; i<8; ++i)
if(dyn->n.x87cache[i]!=-1)
@@ -874,10 +1058,29 @@ void x87_purgecache(dynarec_arm_t* dyn, int ninst, int next, int s1, int s2, int
MESSAGE(LOG_DUMP, "\t---Purge x87 Cache and Synch Stackcount\n");
}
-#ifdef HAVE_TRACE
static void x87_reflectcache(dynarec_arm_t* dyn, int ninst, int s1, int s2, int s3)
{
- x87_stackcount(dyn, ninst, s1);
+ // Synch top & stack counter
+ int a = dyn->n.x87stack;
+ if(a) {
+ // Add x87stack to emu fpu_stack
+ LDRw_U12(s2, xEmu, offsetof(x64emu_t, fpu_stack));
+ if(a>0) {
+ ADDw_U12(s2, s2, a);
+ } else {
+ SUBw_U12(s2, s2, -a);
+ }
+ STRw_U12(s2, xEmu, offsetof(x64emu_t, fpu_stack));
+ // Sub x87stack to top, with and 7
+ LDRw_U12(s2, xEmu, offsetof(x64emu_t, top));
+ if(a>0) {
+ SUBw_U12(s2, s2, a);
+ } else {
+ ADDw_U12(s2, s2, -a);
+ }
+ ANDw_mask(s2, s2, 0, 2); //mask=7
+ STRw_U12(s2, xEmu, offsetof(x64emu_t, top));
+ }
int ret = 0;
for (int i=0; (i<8) && (!ret); ++i)
if(dyn->n.x87cache[i] != -1)
@@ -887,7 +1090,9 @@ static void x87_reflectcache(dynarec_arm_t* dyn, int ninst, int s1, int s2, int
// prepare offset to fpu => s1
ADDx_U12(s1, xEmu, offsetof(x64emu_t, x87));
// Get top
- LDRw_U12(s2, xEmu, offsetof(x64emu_t, top));
+ if(!a) {
+ LDRw_U12(s2, xEmu, offsetof(x64emu_t, top));
+ }
// loop all cache entries
for (int i=0; i<8; ++i)
if(dyn->n.x87cache[i]!=-1) {
@@ -896,7 +1101,31 @@ static void x87_reflectcache(dynarec_arm_t* dyn, int ninst, int s1, int s2, int
VSTR64_REG_LSL3(dyn->n.x87reg[i], s1, s3);
}
}
-#endif
+
+static void x87_unreflectcache(dynarec_arm_t* dyn, int ninst, int s1, int s2, int s3)
+{
+ // go back with the top & stack counter
+ int a = dyn->n.x87stack;
+ if(a) {
+ // Sub x87stack to emu fpu_stack
+ LDRw_U12(s2, xEmu, offsetof(x64emu_t, fpu_stack));
+ if(a>0) {
+ SUBw_U12(s2, s2, a);
+ } else {
+ ADDw_U12(s2, s2, -a);
+ }
+ STRw_U12(s2, xEmu, offsetof(x64emu_t, fpu_stack));
+ // Add x87stack to top, with and 7
+ LDRw_U12(s2, xEmu, offsetof(x64emu_t, top));
+ if(a>0) {
+ ADDw_U12(s2, s2, a);
+ } else {
+ SUBw_U12(s2, s2, -a);
+ }
+ ANDw_mask(s2, s2, 0, 2); //mask=7
+ STRw_U12(s2, xEmu, offsetof(x64emu_t, top));
+ }
+}
int x87_get_current_cache(dynarec_arm_t* dyn, int ninst, int st, int t)
{
@@ -904,7 +1133,9 @@ int x87_get_current_cache(dynarec_arm_t* dyn, int ninst, int st, int t)
for (int i=0; i<8; ++i) {
if(dyn->n.x87cache[i]==st) {
#if STEP == 1
- if(t==NEON_CACHE_ST_D && (dyn->n.neoncache[dyn->n.x87reg[i]].t==NEON_CACHE_ST_F))
+ if(t==NEON_CACHE_ST_D && (dyn->n.neoncache[dyn->n.x87reg[i]].t==NEON_CACHE_ST_F || dyn->n.neoncache[dyn->n.x87reg[i]].t==NEON_CACHE_ST_I64))
+ neoncache_promote_double(dyn, ninst, st);
+ else if(t==NEON_CACHE_ST_F && (dyn->n.neoncache[dyn->n.x87reg[i]].t==NEON_CACHE_ST_I64))
neoncache_promote_double(dyn, ninst, st);
#endif
return i;
@@ -950,7 +1181,9 @@ int x87_get_cache(dynarec_arm_t* dyn, int ninst, int populate, int s1, int s2, i
int x87_get_neoncache(dynarec_arm_t* dyn, int ninst, int s1, int s2, int st)
{
for(int ii=0; ii<24; ++ii)
- if((dyn->n.neoncache[ii].t == NEON_CACHE_ST_F || dyn->n.neoncache[ii].t == NEON_CACHE_ST_D)
+ if((dyn->n.neoncache[ii].t == NEON_CACHE_ST_F
+ || dyn->n.neoncache[ii].t == NEON_CACHE_ST_D
+ || dyn->n.neoncache[ii].t == NEON_CACHE_ST_I64)
&& dyn->n.neoncache[ii].n==st)
return ii;
assert(0);
@@ -988,6 +1221,9 @@ void x87_refresh(dynarec_arm_t* dyn, int ninst, int s1, int s2, int st)
if(dyn->n.neoncache[dyn->n.x87reg[ret]].t==NEON_CACHE_ST_F) {
FCVT_D_S(31, dyn->n.x87reg[ret]);
VSTR64_REG_LSL3(31, s1, s2);
+ } else if(dyn->n.neoncache[dyn->n.x87reg[ret]].t==NEON_CACHE_ST_I64) {
+ SCVTFDD(31, dyn->n.x87reg[ret]);
+ VSTR64_REG_LSL3(31, s1, s2);
} else {
VSTR64_REG_LSL3(dyn->n.x87reg[ret], s1, s2);
}
@@ -1005,7 +1241,7 @@ void x87_forget(dynarec_arm_t* dyn, int ninst, int s1, int s2, int st)
return;
MESSAGE(LOG_DUMP, "\tForget x87 Cache for ST%d\n", st);
#if STEP == 1
- if(dyn->n.neoncache[dyn->n.x87reg[ret]].t==NEON_CACHE_ST_F)
+ if(dyn->n.neoncache[dyn->n.x87reg[ret]].t==NEON_CACHE_ST_F || dyn->n.neoncache[dyn->n.x87reg[ret]].t==NEON_CACHE_ST_I64)
neoncache_promote_double(dyn, ninst, st);
#endif
// prepare offset to fpu => s1
@@ -1036,7 +1272,7 @@ void x87_reget_st(dynarec_arm_t* dyn, int ninst, int s1, int s2, int st)
// refresh the value
MESSAGE(LOG_DUMP, "\tRefresh x87 Cache for ST%d\n", st);
#if STEP == 1
- if(dyn->n.neoncache[dyn->n.x87reg[i]].t==NEON_CACHE_ST_F)
+ if(dyn->n.neoncache[dyn->n.x87reg[i]].t==NEON_CACHE_ST_F || dyn->n.neoncache[dyn->n.x87reg[i]].t==NEON_CACHE_ST_I64)
neoncache_promote_double(dyn, ninst, st);
#endif
ADDx_U12(s1, xEmu, offsetof(x64emu_t, x87));
@@ -1197,7 +1433,7 @@ void mmx_purgecache(dynarec_arm_t* dyn, int ninst, int next, int s1)
MESSAGE(LOG_DUMP, "\t------ Purge MMX Cache\n");
}
}
-#ifdef HAVE_TRACE
+
static void mmx_reflectcache(dynarec_arm_t* dyn, int ninst, int s1)
{
for (int i=0; i<8; ++i)
@@ -1205,7 +1441,6 @@ static void mmx_reflectcache(dynarec_arm_t* dyn, int ninst, int s1)
VLDR64_U12(dyn->n.mmxcache[i], xEmu, offsetof(x64emu_t, mmx[i]));
}
}
-#endif
// SSE / SSE2 helpers
@@ -1297,7 +1532,7 @@ static void sse_purgecache(dynarec_arm_t* dyn, int ninst, int next, int s1)
MESSAGE(LOG_DUMP, "\t------ Purge SSE Cache\n");
}
}
-#ifdef HAVE_TRACE
+
static void sse_reflectcache(dynarec_arm_t* dyn, int ninst, int s1)
{
for (int i=0; i<16; ++i)
@@ -1305,7 +1540,6 @@ static void sse_reflectcache(dynarec_arm_t* dyn, int ninst, int s1)
VSTR128_U12(dyn->n.ssecache[i].reg, xEmu, offsetof(x64emu_t, xmm[i]));
}
}
-#endif
void fpu_pushcache(dynarec_arm_t* dyn, int ninst, int s1, int not07)
{
@@ -1364,10 +1598,20 @@ static int findCacheSlot(dynarec_arm_t* dyn, int ninst, int t, int n, neoncache_
case NEON_CACHE_ST_F:
if (t==NEON_CACHE_ST_D)
return i;
+ if (t==NEON_CACHE_ST_I64)
+ return i;
break;
case NEON_CACHE_ST_D:
if (t==NEON_CACHE_ST_F)
return i;
+ if (t==NEON_CACHE_ST_I64)
+ return i;
+ break;
+ case NEON_CACHE_ST_I64:
+ if (t==NEON_CACHE_ST_F)
+ return i;
+ if (t==NEON_CACHE_ST_D)
+ return i;
break;
case NEON_CACHE_XMMR:
if(t==NEON_CACHE_XMMW)
@@ -1392,7 +1636,7 @@ static void swapCache(dynarec_arm_t* dyn, int ninst, int i, int j, neoncache_t *
quad =1;
if(cache->neoncache[j].t==NEON_CACHE_XMMR || cache->neoncache[j].t==NEON_CACHE_XMMW)
quad =1;
-
+
if(!cache->neoncache[i].v) {
// a mov is enough, no need to swap
MESSAGE(LOG_DUMP, "\t - Moving %d <- %d\n", i, j);
@@ -1407,7 +1651,7 @@ static void swapCache(dynarec_arm_t* dyn, int ninst, int i, int j, neoncache_t *
}
// SWAP
neon_cache_t tmp;
- MESSAGE(LOG_DUMP, "\t - Swaping %d <-> %d\n", i, j);
+ MESSAGE(LOG_DUMP, "\t - Swapping %d <-> %d\n", i, j);
// There is no VSWP in Arm64 NEON to swap 2 register contents!
// so use a scratch...
#define SCRATCH 31
@@ -1452,12 +1696,13 @@ static void loadCache(dynarec_arm_t* dyn, int ninst, int stack_cnt, int s1, int
VLDR128_U12(i, xEmu, offsetof(x64emu_t, xmm[n]));
break;
case NEON_CACHE_MM:
- MESSAGE(LOG_DUMP, "\t - Loading %s\n", getCacheName(t, n));
+ MESSAGE(LOG_DUMP, "\t - Loading %s\n", getCacheName(t, n));
VLDR64_U12(i, xEmu, offsetof(x64emu_t, mmx[i]));
break;
case NEON_CACHE_ST_D:
case NEON_CACHE_ST_F:
- MESSAGE(LOG_DUMP, "\t - Loading %s\n", getCacheName(t, n));
+ case NEON_CACHE_ST_I64:
+ MESSAGE(LOG_DUMP, "\t - Loading %s\n", getCacheName(t, n));
if((*s3_top) == 0xffff) {
LDRw_U12(s3, xEmu, offsetof(x64emu_t, top));
*s3_top = 0;
@@ -1478,12 +1723,15 @@ static void loadCache(dynarec_arm_t* dyn, int ninst, int stack_cnt, int s1, int
if(t==NEON_CACHE_ST_F) {
FCVT_S_D(i, i);
}
- break;
+ if(t==NEON_CACHE_ST_I64) {
+ VFCVTZSQD(i, i);
+ }
+ break;
case NEON_CACHE_NONE:
case NEON_CACHE_SCR:
default: /* nothing done */
MESSAGE(LOG_DUMP, "\t - ignoring %s\n", getCacheName(t, n));
- break;
+ break;
}
cache->neoncache[i].n = n;
cache->neoncache[i].t = t;
@@ -1500,12 +1748,13 @@ static void unloadCache(dynarec_arm_t* dyn, int ninst, int stack_cnt, int s1, in
VSTR128_U12(i, xEmu, offsetof(x64emu_t, xmm[n]));
break;
case NEON_CACHE_MM:
- MESSAGE(LOG_DUMP, "\t - Unloading %s\n", getCacheName(t, n));
+ MESSAGE(LOG_DUMP, "\t - Unloading %s\n", getCacheName(t, n));
VSTR64_U12(i, xEmu, offsetof(x64emu_t, mmx[n]));
break;
case NEON_CACHE_ST_D:
case NEON_CACHE_ST_F:
- MESSAGE(LOG_DUMP, "\t - Unloading %s\n", getCacheName(t, n));
+ case NEON_CACHE_ST_I64:
+ MESSAGE(LOG_DUMP, "\t - Unloading %s\n", getCacheName(t, n));
if((*s3_top)==0xffff) {
LDRw_U12(s3, xEmu, offsetof(x64emu_t, top));
*s3_top = 0;
@@ -1524,14 +1773,16 @@ static void unloadCache(dynarec_arm_t* dyn, int ninst, int stack_cnt, int s1, in
*s2_val = 0;
if(t==NEON_CACHE_ST_F) {
FCVT_D_S(i, i);
+ } else if (t==NEON_CACHE_ST_I64) {
+ SCVTFDD(i, i);
}
VSTR64_U12(i, s2, offsetof(x64emu_t, x87));
- break;
+ break;
case NEON_CACHE_NONE:
case NEON_CACHE_SCR:
default: /* nothing done */
MESSAGE(LOG_DUMP, "\t - ignoring %s\n", getCacheName(t, n));
- break;
+ break;
}
cache->neoncache[i].v = 0;
}
@@ -1653,6 +1904,23 @@ static void fpuCacheTransform(dynarec_arm_t* dyn, int ninst, int s1, int s2, int
MESSAGE(LOG_DUMP, "\t - Convert %s\n", getCacheName(cache.neoncache[i].t, cache.neoncache[i].n));
FCVT_D_S(i, i);
cache.neoncache[i].t = NEON_CACHE_ST_D;
+ } else if(cache.neoncache[i].t == NEON_CACHE_ST_D && cache_i2.neoncache[i].t == NEON_CACHE_ST_I64) {
+ MESSAGE(LOG_DUMP, "\t - Convert %s\n", getCacheName(cache.neoncache[i].t, cache.neoncache[i].n));
+ VFCVTZSQD(i, i);
+ cache.neoncache[i].t = NEON_CACHE_ST_I64;
+ } else if(cache.neoncache[i].t == NEON_CACHE_ST_F && cache_i2.neoncache[i].t == NEON_CACHE_ST_I64) {
+ MESSAGE(LOG_DUMP, "\t - Convert %s\n", getCacheName(cache.neoncache[i].t, cache.neoncache[i].n));
+ VFCVTZSQS(i, i);
+ cache.neoncache[i].t = NEON_CACHE_ST_D;
+ } else if(cache.neoncache[i].t == NEON_CACHE_ST_I64 && cache_i2.neoncache[i].t == NEON_CACHE_ST_F) {
+ MESSAGE(LOG_DUMP, "\t - Convert %s\n", getCacheName(cache.neoncache[i].t, cache.neoncache[i].n));
+ SCVTFDD(i, i);
+ FCVT_S_D(i, i);
+ cache.neoncache[i].t = NEON_CACHE_ST_F;
+ } else if(cache.neoncache[i].t == NEON_CACHE_ST_I64 && cache_i2.neoncache[i].t == NEON_CACHE_ST_D) {
+ MESSAGE(LOG_DUMP, "\t - Convert %s\n", getCacheName(cache.neoncache[i].t, cache.neoncache[i].n));
+ SCVTFDD(i, i);
+ cache.neoncache[i].t = NEON_CACHE_ST_D;
} else if(cache.neoncache[i].t == NEON_CACHE_XMMR && cache_i2.neoncache[i].t == NEON_CACHE_XMMW)
{ cache.neoncache[i].t = NEON_CACHE_XMMW; }
else if(cache.neoncache[i].t == NEON_CACHE_XMMW && cache_i2.neoncache[i].t == NEON_CACHE_XMMR) {
@@ -1680,18 +1948,18 @@ static void flagsCacheTransform(dynarec_arm_t* dyn, int ninst, int s1)
int go = 0;
switch (dyn->insts[jmp].f_entry.pending) {
case SF_UNKNOWN: break;
- case SF_SET:
- if(dyn->f.pending!=SF_SET && dyn->f.pending!=SF_SET_PENDING)
- go = 1;
+ case SF_SET:
+ if(dyn->f.pending!=SF_SET && dyn->f.pending!=SF_SET_PENDING)
+ go = 1;
break;
case SF_SET_PENDING:
- if(dyn->f.pending!=SF_SET
+ if(dyn->f.pending!=SF_SET
&& dyn->f.pending!=SF_SET_PENDING
- && dyn->f.pending!=SF_PENDING)
- go = 1;
+ && dyn->f.pending!=SF_PENDING)
+ go = 1;
break;
case SF_PENDING:
- if(dyn->f.pending!=SF_SET
+ if(dyn->f.pending!=SF_SET
&& dyn->f.pending!=SF_SET_PENDING
&& dyn->f.pending!=SF_PENDING)
go = 1;
@@ -1704,32 +1972,34 @@ static void flagsCacheTransform(dynarec_arm_t* dyn, int ninst, int s1)
if(go) {
if(dyn->f.pending!=SF_PENDING) {
LDRw_U12(s1, xEmu, offsetof(x64emu_t, df));
- j64 = (GETMARK3)-(dyn->native_size);
+ j64 = (GETMARKF2)-(dyn->native_size);
CBZw(s1, j64);
}
CALL_(UpdateFlags, -1, 0);
- MARK3;
+ MARKF2;
}
#endif
}
void CacheTransform(dynarec_arm_t* dyn, int ninst, int cacheupd, int s1, int s2, int s3) {
- if(cacheupd&1)
- fpuCacheTransform(dyn, ninst, s1, s2, s3);
if(cacheupd&2)
+ fpuCacheTransform(dyn, ninst, s1, s2, s3);
+ if(cacheupd&1)
flagsCacheTransform(dyn, ninst, s1);
}
-#ifdef HAVE_TRACE
void fpu_reflectcache(dynarec_arm_t* dyn, int ninst, int s1, int s2, int s3)
{
x87_reflectcache(dyn, ninst, s1, s2, s3);
- if(trace_emm)
- mmx_reflectcache(dyn, ninst, s1);
- if(trace_xmm)
- sse_reflectcache(dyn, ninst, s1);
+ mmx_reflectcache(dyn, ninst, s1);
+ sse_reflectcache(dyn, ninst, s1);
+}
+
+void fpu_unreflectcache(dynarec_arm_t* dyn, int ninst, int s1, int s2, int s3)
+{
+ // need to undo some things on the x87 tracking
+ x87_unreflectcache(dyn, ninst, s1, s2, s3);
}
-#endif
void fpu_reset(dynarec_arm_t* dyn)
{
@@ -1753,3 +2023,67 @@ void emit_pf(dynarec_arm_t* dyn, int ninst, int s1, int s3, int s4)
MVNw_REG(s4, s4);
BFIw(xFlags, s4, F_PF, 1);
}
+
+
+void fpu_reset_cache(dynarec_arm_t* dyn, int ninst, int reset_n)
+{
+ MESSAGE(LOG_DEBUG, "Reset Caches with %d\n",reset_n);
+ #if STEP > 1
+ // for STEP 2 & 3, just need to refrest with current, and undo the changes (push & swap)
+ dyn->n = dyn->insts[ninst].n;
+ neoncacheUnwind(&dyn->n);
+ #ifdef HAVE_TRACE
+ if(box64_dynarec_dump)
+ if(memcmp(&dyn->n, &dyn->insts[reset_n].n, sizeof(neon_cache_t))) {
+ MESSAGE(LOG_DEBUG, "Warning, difference in neoncache: reset=");
+ for(int i=0; i<24; ++i)
+ if(dyn->insts[reset_n].n.neoncache[i].v)
+ MESSAGE(LOG_DEBUG, " %02d:%s", i, getCacheName(dyn->insts[reset_n].n.neoncache[i].t, dyn->insts[reset_n].n.neoncache[i].n));
+ if(dyn->insts[reset_n].n.combined1 || dyn->insts[reset_n].n.combined2)
+ MESSAGE(LOG_DEBUG, " %s:%02d/%02d", dyn->insts[reset_n].n.swapped?"SWP":"CMB", dyn->insts[reset_n].n.combined1, dyn->insts[reset_n].n.combined2);
+ if(dyn->insts[reset_n].n.stack_push || dyn->insts[reset_n].n.stack_pop)
+ MESSAGE(LOG_DEBUG, " (%d:%d)", dyn->insts[reset_n].n.stack_push, -dyn->insts[reset_n].n.stack_pop);
+ MESSAGE(LOG_DEBUG, " ==> ");
+ for(int i=0; i<24; ++i)
+ if(dyn->insts[ninst].n.neoncache[i].v)
+ MESSAGE(LOG_DEBUG, " %02d:%s", i, getCacheName(dyn->insts[ninst].n.neoncache[i].t, dyn->insts[ninst].n.neoncache[i].n));
+ if(dyn->insts[ninst].n.combined1 || dyn->insts[ninst].n.combined2)
+ MESSAGE(LOG_DEBUG, " %s:%02d/%02d", dyn->insts[ninst].n.swapped?"SWP":"CMB", dyn->insts[ninst].n.combined1, dyn->insts[ninst].n.combined2);
+ if(dyn->insts[ninst].n.stack_push || dyn->insts[ninst].n.stack_pop)
+ MESSAGE(LOG_DEBUG, " (%d:%d)", dyn->insts[ninst].n.stack_push, -dyn->insts[ninst].n.stack_pop);
+ MESSAGE(LOG_DEBUG, " -> ");
+ for(int i=0; i<24; ++i)
+ if(dyn->n.neoncache[i].v)
+ MESSAGE(LOG_DEBUG, " %02d:%s", i, getCacheName(dyn->n.neoncache[i].t, dyn->n.neoncache[i].n));
+ if(dyn->n.combined1 || dyn->n.combined2)
+ MESSAGE(LOG_DEBUG, " %s:%02d/%02d", dyn->n.swapped?"SWP":"CMB", dyn->n.combined1, dyn->n.combined2);
+ if(dyn->n.stack_push || dyn->n.stack_pop)
+ MESSAGE(LOG_DEBUG, " (%d:%d)", dyn->n.stack_push, -dyn->n.stack_pop);
+ MESSAGE(LOG_DEBUG, "\n");
+ }
+ #endif //HAVE_TRACE
+ #else
+ dyn->n = dyn->insts[reset_n].n;
+ #endif
+}
+
+// propagate ST stack state, especial stack pop that are deferred
+void fpu_propagate_stack(dynarec_arm_t* dyn, int ninst)
+{
+ if(dyn->n.stack_pop) {
+ for(int j=0; j<24; ++j)
+ if((dyn->n.neoncache[j].t == NEON_CACHE_ST_D
+ || dyn->n.neoncache[j].t == NEON_CACHE_ST_F
+ || dyn->n.neoncache[j].t == NEON_CACHE_ST_I64)) {
+ if(dyn->n.neoncache[j].n<dyn->n.stack_pop)
+ dyn->n.neoncache[j].v = 0;
+ else
+ dyn->n.neoncache[j].n-=dyn->n.stack_pop;
+ }
+ dyn->n.stack_pop = 0;
+ }
+ dyn->n.stack = dyn->n.stack_next;
+ dyn->n.news = 0;
+ dyn->n.stack_push = 0;
+ dyn->n.swapped = 0;
+} \ No newline at end of file
diff --git a/src/dynarec/arm64/dynarec_arm64_helper.h b/src/dynarec/arm64/dynarec_arm64_helper.h
index f13331a..5c7c21f 100755..100644
--- a/src/dynarec/arm64/dynarec_arm64_helper.h
+++ b/src/dynarec/arm64/dynarec_arm64_helper.h
@@ -34,12 +34,12 @@
// Strong mem emulation helpers
// Sequence of Read will trigger a DMB on "first" read if strongmem is 2
-// Squence of Write will trigger a DMB on "last" write if strongmem is 1
+// Sequence of Write will trigger a DMB on "last" write if strongmem is 1
// Opcode will read
#define SMREAD() if(!dyn->smread && box64_dynarec_strongmem>1) {SMDMB();}
// Opcode will read with option forced lock
#define SMREADLOCK(lock) if(lock || (!dyn->smread && box64_dynarec_strongmem>1)) {SMDMB();}
-// Opcode migh read (depend on nextop)
+// Opcode might read (depend on nextop)
#define SMMIGHTREAD() if(!MODREG) {SMREAD();}
// Opcode has wrote
#define SMWRITE() dyn->smwrite=1
@@ -47,7 +47,7 @@
#define SMWRITE2() if(box64_dynarec_strongmem>1) dyn->smwrite=1
// Opcode has wrote with option forced lock
#define SMWRITELOCK(lock) if(lock) {SMDMB();} else dyn->smwrite=1
-// Opcode migh have wrote (depend on nextop)
+// Opcode might have wrote (depend on nextop)
#define SMMIGHTWRITE() if(!MODREG) {SMWRITE();}
// Start of sequence
#define SMSTART() SMEND()
@@ -67,8 +67,8 @@
wback = 0; \
} else { \
SMREAD() \
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, D); \
- LDRxw_U12(x1, wback, fixedaddress); \
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, &unscaled, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, D); \
+ LDxw(x1, wback, fixedaddress); \
ed = x1; \
}
#define GETEDx(D) if(MODREG) { \
@@ -76,8 +76,17 @@
wback = 0; \
} else { \
SMREAD(); \
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, D); \
- LDRx_U12(x1, wback, fixedaddress); \
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, D); \
+ LDx(x1, wback, fixedaddress); \
+ ed = x1; \
+ }
+#define GETEDz(D) if(MODREG) { \
+ ed = xRAX+(nextop&7)+(rex.b<<3); \
+ wback = 0; \
+ } else { \
+ SMREAD(); \
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, D); \
+ LDz(x1, wback, fixedaddress); \
ed = x1; \
}
#define GETEDw(D) if((nextop&0xC0)==0xC0) { \
@@ -85,8 +94,8 @@
wback = 0; \
} else { \
SMREAD(); \
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0xfff<<2, 3, rex, NULL,0, D); \
- LDRw_U12(x1, wback, fixedaddress); \
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL,0, D); \
+ LDW(x1, wback, fixedaddress); \
ed = x1; \
}
#define GETSEDw(D) if((nextop&0xC0)==0xC0) { \
@@ -96,8 +105,8 @@
wback = 0; \
} else { \
SMREAD(); \
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0xfff<<2, 3, rex, NULL, 0, D); \
- LDRSW_U12(x1, wback, fixedaddress); \
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, D); \
+ LDSW(x1, wback, fixedaddress); \
wb = ed = x1; \
}
#define GETED32(D) if(MODREG) { \
@@ -105,8 +114,8 @@
wback = 0; \
} else { \
SMREAD(); \
- addr = geted32(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, D); \
- LDRxw_U12(x1, wback, fixedaddress); \
+ addr = geted32(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, &unscaled, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, D); \
+ LDxw(x1, wback, fixedaddress); \
ed = x1; \
}
#define GETSED32w(D) if((nextop&0xC0)==0xC0) { \
@@ -116,8 +125,8 @@
wback = 0; \
} else { \
SMREAD(); \
- addr = geted32(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0xfff<<2, 3, rex, NULL, 0, D); \
- LDRSW_U12(x1, wback, fixedaddress); \
+ addr = geted32(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, D); \
+ LDSW(x1, wback, fixedaddress); \
wb = ed = x1; \
}
//GETEDH can use hint for ed, and r1 or r2 for wback (depending on hint). wback is 0 if ed is xEAX..xEDI
@@ -126,18 +135,18 @@
wback = 0; \
} else { \
SMREAD(); \
- addr = geted(dyn, addr, ninst, nextop, &wback, (hint==x2)?x1:x2, &fixedaddress, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, D); \
- LDRxw_U12(hint, wback, fixedaddress); \
- ed = hint; \
+ addr = geted(dyn, addr, ninst, nextop, &wback, (hint==x2)?x1:x2, &fixedaddress, &unscaled, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, D); \
+ LDxw(hint, wback, fixedaddress); \
+ ed = hint; \
}
#define GETED32H(hint, D) if(MODREG) { \
ed = xRAX+(nextop&7)+(rex.b<<3); \
wback = 0; \
} else { \
SMREAD(); \
- addr = geted32(dyn, addr, ninst, nextop, &wback, (hint==x2)?x1:x2, &fixedaddress, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, D); \
- LDRxw_U12(hint, wback, fixedaddress); \
- ed = hint; \
+ addr = geted32(dyn, addr, ninst, nextop, &wback, (hint==x2)?x1:x2, &fixedaddress, &unscaled, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, D); \
+ LDxw(hint, wback, fixedaddress); \
+ ed = hint; \
}
//GETEDW can use hint for wback and ret for ed. wback is 0 if ed is xEAX..xEDI
#define GETEDW(hint, ret, D) if(MODREG) { \
@@ -146,9 +155,9 @@
wback = 0; \
} else { \
SMREAD(); \
- addr = geted(dyn, addr, ninst, nextop, &wback, hint, &fixedaddress, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, D); \
+ addr = geted(dyn, addr, ninst, nextop, &wback, hint, &fixedaddress, &unscaled, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, D); \
ed = ret; \
- LDRxw_U12(ed, wback, fixedaddress); \
+ LDxw(ed, wback, fixedaddress); \
}
#define GETED32W(hint, ret, D) if(MODREG) { \
ed = xRAX+(nextop&7)+(rex.b<<3); \
@@ -156,23 +165,23 @@
wback = 0; \
} else { \
SMREAD(); \
- addr = geted32(dyn, addr, ninst, nextop, &wback, hint, &fixedaddress, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, D); \
+ addr = geted32(dyn, addr, ninst, nextop, &wback, hint, &fixedaddress, &unscaled, 0xfff<<(2+rex.w), (1<<(2+rex.w))-1, rex, NULL, 0, D); \
ed = ret; \
- LDRxw_U12(ed, wback, fixedaddress); \
+ LDxw(ed, wback, fixedaddress); \
}
// Write back ed in wback (if wback not 0)
-#define WBACK if(wback) {STRxw_U12(ed, wback, fixedaddress); SMWRITE();}
+#define WBACK if(wback) {STxw(ed, wback, fixedaddress); SMWRITE();}
// Write back ed in wback (if wback not 0)
-#define WBACKx if(wback) {STRx_U12(ed, wback, fixedaddress); SMWRITE();}
+#define WBACKx if(wback) {STx(ed, wback, fixedaddress); SMWRITE();}
// Write back ed in wback (if wback not 0)
-#define WBACKw if(wback) {STRw_U12(ed, wback, fixedaddress); SMWRITE();}
+#define WBACKw if(wback) {STW(ed, wback, fixedaddress); SMWRITE();}
//GETEDO can use r1 for ed, and r2 for wback. wback is 0 if ed is xEAX..xEDI
#define GETEDO(O, D) if(MODREG) { \
ed = xRAX+(nextop&7)+(rex.b<<3); \
wback = 0; \
} else { \
SMREAD(); \
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, NULL, 0, D); \
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, NULL, 0, D); \
LDRxw_REG(x1, wback, O); \
ed = x1; \
}
@@ -183,10 +192,20 @@
wback = 0; \
} else { \
SMREAD(); \
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, NULL, 0, D); \
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, NULL, 0, D); \
LDRx_REG(x1, wback, O); \
ed = x1; \
}
+//GETEDOz can use r1 for ed, and r2 for wback. wback is 0 if ed is xEAX..xEDI
+#define GETEDOz(O, D) if(MODREG) { \
+ ed = xRAX+(nextop&7)+(rex.b<<3); \
+ wback = 0; \
+ } else { \
+ SMREAD(); \
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, NULL, 0, D); \
+ LDRz_REG(x1, wback, O); \
+ ed = x1; \
+ }
#define GETSEDOw(O, D) if((nextop&0xC0)==0xC0) { \
ed = xRAX+(nextop&7)+(rex.b<<3); \
SXTWx(x1, ed); \
@@ -194,7 +213,7 @@
wback = 0; \
} else { \
SMREAD(); \
- addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, 0, 0, rex, NULL, 0, D); \
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, &fixedaddress, NULL, 0, 0, rex, NULL, 0, D); \
LDRSW_REG(x1, wback, O); \
wb = ed = x1; \
}
@@ -214,8 +233,8 @@
wb1 = 0; \
} else { \
SMREAD(); \
- addr = geted(dyn, addr, ninst, nextop, &wback, w, &fixedaddress, 0xfff<<1, (1<<1)-1, rex, NULL, 0, D); \
- LDRH_U12(i, wback, fixedaddress); \
+ addr = geted(dyn, addr, ninst, nextop, &wback, w, &fixedaddress, &unscaled, 0xfff<<1, (1<<1)-1, rex, NULL, 0, D); \
+ LDH(i, wback, fixedaddress);\
ed = i; \
wb1 = 1; \
}
@@ -227,8 +246,8 @@
wb1 = 0; \
} else { \
SMREAD(); \
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<1, (1<<1)-1, rex, NULL, 0, D); \
- LDRH_U12(i, wback, fixedaddress); \
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<1, (1<<1)-1, rex, NULL, 0, D); \
+ LDH(i, wback, fixedaddress); \
ed = i; \
wb1 = 1; \
}
@@ -240,15 +259,15 @@
wb1 = 0; \
} else { \
SMREAD(); \
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff<<1, (1<<1)-1, rex, NULL, 0, D); \
- LDRSHx_U12(i, wback, fixedaddress);\
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff<<1, (1<<1)-1, rex, NULL, 0, D); \
+ LDSHw(i, wback, fixedaddress); \
ed = i; \
wb1 = 1; \
}
// Write ed back to original register / memory
-#define EWBACK if(wb1) {STRH_U12(ed, wback, fixedaddress); SMWRITE();} else {BFIx(wback, ed, 0, 16);}
+#define EWBACK EWBACKW(ed)
// Write w back to original register / memory
-#define EWBACKW(w) if(wb1) {STRH_U12(w, wback, fixedaddress); SMWRITE();} else {BFIx(wback, w, 0, 16);}
+#define EWBACKW(w) if(wb1) {STH(w, wback, fixedaddress); SMWRITE();} else {BFIx(wback, w, 0, 16);}
// Write back gd in correct register
#define GWBACK BFIx((xRAX+((nextop&0x38)>>3)+(rex.r<<3)), gd, 0, 16);
//GETEB will use i for ed, and can use r3 for wback.
@@ -266,8 +285,8 @@
ed = i; \
} else { \
SMREAD(); \
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff, 0, rex, NULL, 0, D); \
- LDRB_U12(i, wback, fixedaddress); \
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff, 0, rex, NULL, 0, D); \
+ LDB(i, wback, fixedaddress);\
wb1 = 1; \
ed = i; \
}
@@ -286,10 +305,10 @@
ed = i; \
} else { \
SMREAD(); \
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff, 0, rex, NULL, 0, D); \
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff, 0, rex, NULL, 0, D); \
ADDx_REG(x3, wback, i); \
if(wback!=x3) wback = x3; \
- LDRB_U12(i, wback, fixedaddress); \
+ LDB(i, wback, fixedaddress);\
wb1 = 1; \
ed = i; \
}
@@ -308,8 +327,8 @@
ed = i; \
} else { \
SMREAD(); \
- addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff, 0, rex, NULL, 0, D); \
- LDRSBx_U12(i, wback, fixedaddress); \
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff, 0, rex, NULL, 0, D); \
+ LDSBx(i, wback, fixedaddress); \
wb1 = 1; \
ed = i; \
}
@@ -328,31 +347,31 @@
ed = i; \
} else { \
SMREAD(); \
- addr = geted32(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, 0xfff, 0, rex, NULL, 0, D); \
- LDRB_U12(i, wback, fixedaddress); \
+ addr = geted32(dyn, addr, ninst, nextop, &wback, x3, &fixedaddress, &unscaled, 0xfff, 0, rex, NULL, 0, D); \
+ LDB(i, wback, fixedaddress);\
wb1 = 1; \
ed = i; \
}
// Write eb (ed) back to original register / memory
-#define EBBACK if(wb1) {STRB_U12(ed, wback, fixedaddress); SMWRITE();} else {BFIx(wback, ed, wb2, 8);}
+#define EBBACK if(wb1) {STB(ed, wback, fixedaddress); SMWRITE();} else {BFIx(wback, ed, wb2, 8);}
//GETGB will use i for gd
#define GETGB(i) if(rex.rex) { \
gb1 = xRAX+((nextop&0x38)>>3)+(rex.r<<3); \
gb2 = 0; \
} else { \
gd = (nextop&0x38)>>3; \
- gb2 = ((gd&4)>>2); \
+ gb2 = ((gd&4)<<1); \
gb1 = xRAX+(gd&3); \
} \
gd = i; \
- UBFXx(gd, gb1, gb2*8, 8);
-//GETSGB signe extend GB, will use i for gd
+ UBFXx(gd, gb1, gb2, 8);
+//GETSGB sign extend GB, will use i for gd
#define GETSGB(i) if(rex.rex) { \
gb1 = xRAX+((nextop&0x38)>>3)+(rex.r<<3); \
gb2 = 0; \
} else { \
gd = (nextop&0x38)>>3; \
- gb2 = ((gd&4)>>2); \
+ gb2 = ((gd&4)<<1); \
gb1 = xRAX+(gd&3); \
} \
gd = i; \
@@ -379,15 +398,15 @@
a = sse_get_reg(dyn, ninst, x1, (nextop&7)+(rex.b<<3), w); \
} else { \
SMREAD(); \
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<4, 15, rex, NULL, 0, D); \
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<4, 15, rex, NULL, 0, D); \
a = fpu_get_scratch(dyn); \
- VLDR128_U12(a, ed, fixedaddress); \
+ VLD128(a, ed, fixedaddress); \
}
// Put Back EX if it was a memory and not an emm register
#define PUTEX(a) \
if(!MODREG) { \
- VSTR128_U12(a, ed, fixedaddress); \
+ VST128(a, ed, fixedaddress); \
SMWRITE2(); \
}
@@ -399,8 +418,8 @@
} else { \
SMREAD(); \
a = fpu_get_scratch(dyn); \
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, D); \
- VLDR64_U12(a, ed, fixedaddress); \
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, D); \
+ VLD64(a, ed, fixedaddress); \
}
// Get Ex as a single, not a quad (warning, x1 get used)
@@ -410,8 +429,8 @@
} else { \
SMREAD(); \
a = fpu_get_scratch(dyn); \
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<2, 3, rex, NULL, 0, D); \
- VLDR32_U12(a, ed, fixedaddress); \
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<2, 3, rex, NULL, 0, D); \
+ VLD32(a, ed, fixedaddress); \
}
// Get GM, might use x1, x2 and x3
@@ -425,15 +444,15 @@
a = mmx_get_reg(dyn, ninst, x1, x2, x3, (nextop&7)); \
} else { \
SMREAD(); \
- addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, 0xfff<<3, 7, rex, NULL, 0, D); \
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, &fixedaddress, &unscaled, 0xfff<<3, 7, rex, NULL, 0, D); \
a = fpu_get_scratch(dyn); \
- VLDR64_U12(a, ed, fixedaddress); \
+ VLD64(a, ed, fixedaddress); \
}
// Put Back EM if it was a memory and not an emm register
#define PUTEM(a) \
if(!MODREG) { \
- VSTR64_U12(a, ed, fixedaddress); \
+ VST64(a, ed, fixedaddress); \
SMWRITE2(); \
}
@@ -455,17 +474,19 @@
// R0 will not be pushed/popd if ret is -2. Flags are not save/restored
#define CALL_S(F, ret) call_c(dyn, ninst, F, x7, ret, 0, 0)
-#define MARK dyn->insts[ninst].mark = dyn->native_size
-#define GETMARK dyn->insts[ninst].mark
-#define MARK2 dyn->insts[ninst].mark2 = dyn->native_size
-#define GETMARK2 dyn->insts[ninst].mark2
-#define MARK3 dyn->insts[ninst].mark3 = dyn->native_size
-#define GETMARK3 dyn->insts[ninst].mark3
-#define MARKF dyn->insts[ninst].markf = dyn->native_size
-#define GETMARKF dyn->insts[ninst].markf
-#define MARKSEG dyn->insts[ninst].markseg = dyn->native_size
-#define GETMARKSEG dyn->insts[ninst].markseg
-#define MARKLOCK dyn->insts[ninst].marklock = dyn->native_size
+#define MARK dyn->insts[ninst].mark = dyn->native_size
+#define GETMARK dyn->insts[ninst].mark
+#define MARK2 dyn->insts[ninst].mark2 = dyn->native_size
+#define GETMARK2 dyn->insts[ninst].mark2
+#define MARK3 dyn->insts[ninst].mark3 = dyn->native_size
+#define GETMARK3 dyn->insts[ninst].mark3
+#define MARKF dyn->insts[ninst].markf = dyn->native_size
+#define GETMARKF dyn->insts[ninst].markf
+#define MARKF2 dyn->insts[ninst].markf2 = dyn->native_size
+#define GETMARKF2 dyn->insts[ninst].markf2
+#define MARKSEG dyn->insts[ninst].markseg = dyn->native_size
+#define GETMARKSEG dyn->insts[ninst].markseg
+#define MARKLOCK dyn->insts[ninst].marklock = dyn->native_size
#define GETMARKLOCK dyn->insts[ninst].marklock
// Branch to MARK if cond (use j64)
@@ -504,6 +525,10 @@
#define B_MARK2_nocond \
j64 = GETMARK2-(dyn->native_size); \
B(j64)
+// Branch to MARK2 if reg is 0 (use j64)
+#define CBZx_MARK2(reg) \
+ j64 = GETMARK2-(dyn->native_size); \
+ CBZx(reg, j64)
// Branch to MARK2 if reg is not 0 (use j64)
#define CBNZx_MARK2(reg) \
j64 = GETMARK2-(dyn->native_size); \
@@ -717,7 +742,7 @@
LDP_REGS(R12, R13); \
LDP_REGS(R14, R15)
-#define SET_DFNONE(S) if(!dyn->f.dfnone) {MOVZw(S, d_none); STRw_U12(S, xEmu, offsetof(x64emu_t, df)); dyn->f.dfnone=1;}
+#define SET_DFNONE(S) if(!dyn->f.dfnone) {STRw_U12(wZR, xEmu, offsetof(x64emu_t, df)); dyn->f.dfnone=1;}
#define SET_DF(S, N) if((N)!=d_none) {MOVZw(S, (N)); STRw_U12(S, xEmu, offsetof(x64emu_t, df)); dyn->f.dfnone=0;} else SET_DFNONE(S)
#define SET_NODF() dyn->f.dfnone = 0
#define SET_DFOK() dyn->f.dfnone = 1
@@ -759,17 +784,17 @@
} else dyn->f.pending = SF_SET
#endif
#ifndef JUMP
-#define JUMP(A, C)
+#define JUMP(A, C)
#endif
#ifndef BARRIER
-#define BARRIER(A)
+#define BARRIER(A)
#endif
#ifndef BARRIER_NEXT
#define BARRIER_NEXT(A)
#endif
#define UFLAG_OP1(A) if(dyn->insts[ninst].x64.gen_flags) {STRxw_U12(A, xEmu, offsetof(x64emu_t, op1));}
#define UFLAG_OP2(A) if(dyn->insts[ninst].x64.gen_flags) {STRxw_U12(A, xEmu, offsetof(x64emu_t, op2));}
-#define UFLAG_OP12(A1, A2) if(dyn->insts[ninst].x64.gen_flags) {STRxw_U12(A1, xEmu, offsetof(x64emu_t, op1));STRxw_U12(A2, 0, offsetof(x64emu_t, op2));}
+#define UFLAG_OP12(A1, A2) if(dyn->insts[ninst].x64.gen_flags) {STRxw_U12(A1, xEmu, offsetof(x64emu_t, op1));STRxw_U12(A2, xEmu, offsetof(x64emu_t, op2));}
#define UFLAG_RES(A) if(dyn->insts[ninst].x64.gen_flags) {STRxw_U12(A, xEmu, offsetof(x64emu_t, res));}
#define UFLAG_DF(r, A) if(dyn->insts[ninst].x64.gen_flags) {SET_DF(r, A)}
#define UFLAG_IF if(dyn->insts[ninst].x64.gen_flags)
@@ -786,6 +811,10 @@
#define FTABLE64(A, V)
#endif
+#define ARCH_INIT() \
+ dyn->doublepush = 0; \
+ dyn->doublepop = 0;
+
#if STEP < 2
#define GETIP(A)
#define GETIP_(A)
@@ -828,7 +857,7 @@
#define MODREG ((nextop&0xC0)==0xC0)
-void arm64_epilog();
+void arm64_epilog(void);
void* arm64_next(x64emu_t* emu, uintptr_t addr);
#ifndef STEPNAME
@@ -969,30 +998,31 @@ void* arm64_next(x64emu_t* emu, uintptr_t addr);
#define fpu_pushcache STEPNAME(fpu_pushcache)
#define fpu_popcache STEPNAME(fpu_popcache)
#define fpu_reset STEPNAME(fpu_reset)
+#define fpu_reset_cache STEPNAME(fpu_reset_cache)
+#define fpu_propagate_stack STEPNAME(fpu_propagate_stack)
#define fpu_purgecache STEPNAME(fpu_purgecache)
#define mmx_purgecache STEPNAME(mmx_purgecache)
#define x87_purgecache STEPNAME(x87_purgecache)
-#ifdef HAVE_TRACE
#define fpu_reflectcache STEPNAME(fpu_reflectcache)
-#endif
+#define fpu_unreflectcache STEPNAME(fpu_unreflectcache)
#define CacheTransform STEPNAME(CacheTransform)
/* setup r2 to address pointed by */
-uintptr_t geted(dynarec_arm_t* dyn, uintptr_t addr, int ninst, uint8_t nextop, uint8_t* ed, uint8_t hint, int64_t* fixaddress, int absmax, uint32_t mask, rex_t rex, int* l, int s, int delta);
+uintptr_t geted(dynarec_arm_t* dyn, uintptr_t addr, int ninst, uint8_t nextop, uint8_t* ed, uint8_t hint, int64_t* fixaddress, int* unscaled, int absmax, uint32_t mask, rex_t rex, int* l, int s, int delta);
/* setup r2 to address pointed by */
-uintptr_t geted32(dynarec_arm_t* dyn, uintptr_t addr, int ninst, uint8_t nextop, uint8_t* ed, uint8_t hint, int64_t* fixaddress, int absmax, uint32_t mask, rex_t rex, int* l, int s, int delta);
+uintptr_t geted32(dynarec_arm_t* dyn, uintptr_t addr, int ninst, uint8_t nextop, uint8_t* ed, uint8_t hint, int64_t* fixaddress, int* unscaled, int absmax, uint32_t mask, rex_t rex, int* l, int s, int delta);
/* setup r2 to address pointed by */
-uintptr_t geted16(dynarec_arm_t* dyn, uintptr_t addr, int ninst, uint8_t nextop, uint8_t* ed, uint8_t hint, int64_t* fixaddress, int absmax, uint32_t mask, int s);
+uintptr_t geted16(dynarec_arm_t* dyn, uintptr_t addr, int ninst, uint8_t nextop, uint8_t* ed, uint8_t hint, int64_t* fixaddress, int* unscaled, int absmax, uint32_t mask, int s);
// generic x64 helper
void jump_to_epilog(dynarec_arm_t* dyn, uintptr_t ip, int reg, int ninst);
void jump_to_next(dynarec_arm_t* dyn, uintptr_t ip, int reg, int ninst);
-void ret_to_epilog(dynarec_arm_t* dyn, int ninst);
-void retn_to_epilog(dynarec_arm_t* dyn, int ninst, int n);
+void ret_to_epilog(dynarec_arm_t* dyn, int ninst, rex_t rex);
+void retn_to_epilog(dynarec_arm_t* dyn, int ninst, rex_t rex, int n);
void iret_to_epilog(dynarec_arm_t* dyn, int ninst, int is64bits);
void call_c(dynarec_arm_t* dyn, int ninst, void* fnc, int reg, int ret, int saveflags, int save_reg);
void call_n(dynarec_arm_t* dyn, int ninst, void* fnc, int w);
@@ -1005,7 +1035,7 @@ void emit_cmp16_0(dynarec_arm_t* dyn, int ninst, int s1, int s3, int s4);
void emit_cmp32_0(dynarec_arm_t* dyn, int ninst, rex_t rex, int s1, int s3, int s4);
void emit_test8(dynarec_arm_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5);
void emit_test16(dynarec_arm_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5);
-void emit_test32(dynarec_arm_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4);
+void emit_test32(dynarec_arm_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4, int s5);
void emit_add32(dynarec_arm_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4);
void emit_add32c(dynarec_arm_t* dyn, int ninst, rex_t rex, int s1, int64_t c, int s3, int s4, int s5);
void emit_add8(dynarec_arm_t* dyn, int ninst, int s1, int s2, int s3, int s4);
@@ -1070,7 +1100,7 @@ void emit_shld32c(dynarec_arm_t* dyn, int ninst, rex_t rex, int s1, int s2, uint
void emit_pf(dynarec_arm_t* dyn, int ninst, int s1, int s3, int s4);
// x87 helper
-// cache of the local stack counter, to avoid upadte at every call
+// cache of the local stack counter, to avoid update at every call
void x87_stackcount(dynarec_arm_t* dyn, int ninst, int scratch);
// fpu push. Return the Dd value to be used
int x87_do_push(dynarec_arm_t* dyn, int ninst, int s1, int t);
@@ -1116,16 +1146,19 @@ int neoncache_st_coherency(dynarec_arm_t* dyn, int ninst, int a, int b);
#if STEP == 0
#define ST_IS_F(A) 0
+#define ST_IS_I64(A) 0
#define X87_COMBINE(A, B) NEON_CACHE_ST_D
#define X87_ST0 NEON_CACHE_ST_D
#define X87_ST(A) NEON_CACHE_ST_D
#elif STEP == 1
#define ST_IS_F(A) (neoncache_get_current_st(dyn, ninst, A)==NEON_CACHE_ST_F)
+#define ST_IS_I64(A) (neoncache_get_current_st(dyn, ninst, A)==NEON_CACHE_ST_I64)
#define X87_COMBINE(A, B) neoncache_combine_st(dyn, ninst, A, B)
#define X87_ST0 neoncache_get_current_st(dyn, ninst, 0)
#define X87_ST(A) neoncache_get_current_st(dyn, ninst, A)
#else
#define ST_IS_F(A) (neoncache_get_st(dyn, ninst, A)==NEON_CACHE_ST_F)
+#define ST_IS_I64(A) (neoncache_get_st(dyn, ninst, A)==NEON_CACHE_ST_I64)
#if STEP == 3
#define X87_COMBINE(A, B) neoncache_st_coherency(dyn, ninst, A, B)
#else
@@ -1154,15 +1187,18 @@ void sse_purge07cache(dynarec_arm_t* dyn, int ninst, int s1);
// common coproc helpers
// reset the cache
void fpu_reset(dynarec_arm_t* dyn);
+// reset the cache with n
+void fpu_reset_cache(dynarec_arm_t* dyn, int ninst, int reset_n);
+// propagate stack state
+void fpu_propagate_stack(dynarec_arm_t* dyn, int ninst);
// purge the FPU cache (needs 3 scratch registers)
void fpu_purgecache(dynarec_arm_t* dyn, int ninst, int next, int s1, int s2, int s3);
// purge MMX cache
void mmx_purgecache(dynarec_arm_t* dyn, int ninst, int next, int s1);
// purge x87 cache
void x87_purgecache(dynarec_arm_t* dyn, int ninst, int next, int s1, int s2, int s3);
-#ifdef HAVE_TRACE
void fpu_reflectcache(dynarec_arm_t* dyn, int ninst, int s1, int s2, int s3);
-#endif
+void fpu_unreflectcache(dynarec_arm_t* dyn, int ninst, int s1, int s2, int s3);
void fpu_pushcache(dynarec_arm_t* dyn, int ninst, int s1, int not07);
void fpu_popcache(dynarec_arm_t* dyn, int ninst, int s1, int not07);
@@ -1202,7 +1238,7 @@ uintptr_t dynarec64_F30F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
#if STEP < 3
#define MAYUSE(A) (void)A
#else
-#define MAYUSE(A)
+#define MAYUSE(A)
#endif
#define GOCOND(B, T1, T2) \
@@ -1295,4 +1331,27 @@ uintptr_t dynarec64_F30F(dynarec_arm_t* dyn, uintptr_t addr, uintptr_t ip, int n
, cNE, cEQ, X_SF|X_OF|X_ZF) \
break
+#define NOTEST(s1) \
+ if(box64_dynarec_test) { \
+ STRw_U12(xZR, xEmu, offsetof(x64emu_t, test.test)); \
+ STRw_U12(xZR, xEmu, offsetof(x64emu_t, test.clean));\
+ }
+#define SKIPTEST(s1) \
+ if(box64_dynarec_test) { \
+ STRw_U12(xZR, xEmu, offsetof(x64emu_t, test.clean));\
+ }
+#define GOTEST(s1, s2) \
+ if(box64_dynarec_test) { \
+ MOV32w(s2, 1); \
+ STRw_U12(s2, xEmu, offsetof(x64emu_t, test.test)); \
+ }
+
+#define GETREX() \
+ rex.rex = 0; \
+ if(!rex.is32bits) \
+ while(opcode>=0x40 && opcode<=0x4f) { \
+ rex.rex = opcode; \
+ opcode = F8; \
+ }
+
#endif //__DYNAREC_ARM64_HELPER_H__
diff --git a/src/dynarec/arm64/dynarec_arm64_pass0.h b/src/dynarec/arm64/dynarec_arm64_pass0.h
index 61eb1bc..774d13d 100755..100644
--- a/src/dynarec/arm64/dynarec_arm64_pass0.h
+++ b/src/dynarec/arm64/dynarec_arm64_pass0.h
@@ -22,7 +22,7 @@
#define NEW_INST \
++dyn->size; \
if(dyn->size+3>=dyn->cap) { \
- dyn->insts = (instruction_native_t*)customRealloc(dyn->insts, sizeof(instruction_native_t)*dyn->cap*2);\
+ dyn->insts = (instruction_native_t*)dynaRealloc(dyn->insts, sizeof(instruction_native_t)*dyn->cap*2);\
memset(&dyn->insts[dyn->cap], 0, sizeof(instruction_native_t)*dyn->cap); \
dyn->cap *= 2; \
} \
@@ -40,9 +40,10 @@
#define DEFAULT \
--dyn->size; \
*ok = -1; \
- if(box64_dynarec_log>=LOG_INFO) {\
- dynarec_log(LOG_NONE, "%p: Dynarec stopped because of Opcode %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X", \
- (void*)ip, PKip(0), \
+ if(box64_dynarec_log>=LOG_INFO || box64_dynarec_dump || box64_dynarec_missing) {\
+ dynarec_log(LOG_NONE, "%p: Dynarec stopped because of %sOpcode %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X", \
+ (void*)ip, rex.is32bits?"32bits ":"",\
+ PKip(0), \
PKip(1), PKip(2), PKip(3), \
PKip(4), PKip(5), PKip(6), \
PKip(7), PKip(8), PKip(9), \
diff --git a/src/dynarec/arm64/dynarec_arm64_pass1.h b/src/dynarec/arm64/dynarec_arm64_pass1.h
index 6cf92fe..6cf92fe 100755..100644
--- a/src/dynarec/arm64/dynarec_arm64_pass1.h
+++ b/src/dynarec/arm64/dynarec_arm64_pass1.h
diff --git a/src/dynarec/arm64/dynarec_arm64_pass2.h b/src/dynarec/arm64/dynarec_arm64_pass2.h
index edc43ae..512e441 100755..100644
--- a/src/dynarec/arm64/dynarec_arm64_pass2.h
+++ b/src/dynarec/arm64/dynarec_arm64_pass2.h
@@ -2,19 +2,17 @@
#define FINI \
if(ninst) { \
dyn->insts[ninst].address = (dyn->insts[ninst-1].address+dyn->insts[ninst-1].size); \
- dyn->insts_size += 1+((dyn->insts[ninst].x64.size>dyn->insts[ninst].size)?dyn->insts[ninst].x64.size:dyn->insts[ninst].size)/15; \
+ dyn->insts_size += 1+((dyn->insts[ninst].x64.size>(dyn->insts[ninst].size/4))?dyn->insts[ninst].x64.size:(dyn->insts[ninst].size/4))/15; \
}
#define MESSAGE(A, ...)
-#define EMIT(A) dyn->insts[ninst].size+=4; dyn->native_size+=4
+#define EMIT(A) do{dyn->insts[ninst].size+=4; dyn->native_size+=4;}while(0)
#define NEW_INST \
if(ninst) { \
dyn->insts[ninst].address = (dyn->insts[ninst-1].address+dyn->insts[ninst-1].size); \
- if(isInstClean(dyn, ninst) && dyn->last_ip!=ip) \
- dyn->last_ip = 0; \
- dyn->insts_size += 1+((dyn->insts[ninst-1].x64.size>dyn->insts[ninst-1].size)?dyn->insts[ninst-1].x64.size:dyn->insts[ninst-1].size)/15; \
+ dyn->insts_size += 1+((dyn->insts[ninst-1].x64.size>(dyn->insts[ninst-1].size/4))?dyn->insts[ninst-1].x64.size:(dyn->insts[ninst-1].size/4))/15; \
}
#define INST_EPILOG dyn->insts[ninst].epilog = dyn->native_size;
#define INST_NAME(name)
-#define TABLE64(A, V) {Table64(dyn, (V)); EMIT(0);}
-#define FTABLE64(A, V) {mmx87_regs_t v = {.d = V}; Table64(dyn, v.q); EMIT(0);} \ No newline at end of file
+#define TABLE64(A, V) {Table64(dyn, (V), 2); EMIT(0);}
+#define FTABLE64(A, V) {mmx87_regs_t v = {.d = V}; Table64(dyn, v.q, 2); EMIT(0);} \ No newline at end of file
diff --git a/src/dynarec/arm64/dynarec_arm64_pass3.h b/src/dynarec/arm64/dynarec_arm64_pass3.h
index ae79c11..875e8af 100755..100644
--- a/src/dynarec/arm64/dynarec_arm64_pass3.h
+++ b/src/dynarec/arm64/dynarec_arm64_pass3.h
@@ -3,68 +3,20 @@
if(ninst) \
addInst(dyn->instsize, &dyn->insts_size, dyn->insts[ninst].x64.size, dyn->insts[ninst].size/4); \
addInst(dyn->instsize, &dyn->insts_size, 0, 0);
-#define EMIT(A) \
- if(box64_dynarec_dump) {dynarec_log(LOG_NONE, "\t%08x\t%s\n", (uint32_t)(A), arm64_print(A, (uintptr_t)dyn->block));} \
- *(uint32_t*)(dyn->block) = (uint32_t)(A); \
- dyn->block += 4; dyn->native_size += 4; \
- dyn->insts[ninst].size2 += 4
+#define EMIT(A) \
+ do{ \
+ if(box64_dynarec_dump) print_opcode(dyn, ninst, (uint32_t)(A)); \
+ if((uintptr_t)dyn->block<dyn->tablestart) \
+ *(uint32_t*)(dyn->block) = (uint32_t)(A); \
+ dyn->block += 4; dyn->native_size += 4; \
+ dyn->insts[ninst].size2 += 4; \
+ }while(0)
#define MESSAGE(A, ...) if(box64_dynarec_dump) dynarec_log(LOG_NONE, __VA_ARGS__)
#define NEW_INST \
- if(ninst && isInstClean(dyn, ninst)) { \
- if(dyn->last_ip!=ip) dyn->last_ip = 0; \
- } \
if(ninst) \
addInst(dyn->instsize, &dyn->insts_size, dyn->insts[ninst-1].x64.size, dyn->insts[ninst-1].size/4);
#define INST_EPILOG
-#define INST_NAME(name) \
- if(box64_dynarec_dump) {\
- printf_x64_instruction(my_context->dec, &dyn->insts[ninst].x64, name); \
- dynarec_log(LOG_NONE, "%s%p: %d emited opcodes, inst=%d, barrier=%d state=%d/%d(%d), %s=%X/%X, use=%X, need=%X/%X, sm=%d/%d", \
- (box64_dynarec_dump>1)?"\e[32m":"", \
- (void*)(dyn->native_start+dyn->insts[ninst].address), \
- dyn->insts[ninst].size/4, \
- ninst, \
- dyn->insts[ninst].x64.barrier, \
- dyn->insts[ninst].x64.state_flags, \
- dyn->f.pending, \
- dyn->f.dfnone, \
- dyn->insts[ninst].x64.may_set?"may":"set", \
- dyn->insts[ninst].x64.set_flags, \
- dyn->insts[ninst].x64.gen_flags, \
- dyn->insts[ninst].x64.use_flags, \
- dyn->insts[ninst].x64.need_before, \
- dyn->insts[ninst].x64.need_after, \
- dyn->smread, dyn->smwrite); \
- if(dyn->insts[ninst].pred_sz) { \
- dynarec_log(LOG_NONE, ", pred="); \
- for(int ii=0; ii<dyn->insts[ninst].pred_sz; ++ii)\
- dynarec_log(LOG_NONE, "%s%d", ii?"/":"", dyn->insts[ninst].pred[ii]);\
- } \
- if(dyn->insts[ninst].x64.jmp && dyn->insts[ninst].x64.jmp_insts>=0)\
- dynarec_log(LOG_NONE, ", jmp=%d", dyn->insts[ninst].x64.jmp_insts);\
- if(dyn->insts[ninst].x64.jmp && dyn->insts[ninst].x64.jmp_insts==-1)\
- dynarec_log(LOG_NONE, ", jmp=out"); \
- if(dyn->last_ip) \
- dynarec_log(LOG_NONE, ", last_ip=%p", (void*)dyn->last_ip);\
- for(int ii=0; ii<24; ++ii) { \
- switch(dyn->insts[ninst].n.neoncache[ii].t) { \
- case NEON_CACHE_ST_D: dynarec_log(LOG_NONE, " D%d:%s", ii, getCacheName(dyn->insts[ninst].n.neoncache[ii].t, dyn->insts[ninst].n.neoncache[ii].n)); break; \
- case NEON_CACHE_ST_F: dynarec_log(LOG_NONE, " S%d:%s", ii, getCacheName(dyn->insts[ninst].n.neoncache[ii].t, dyn->insts[ninst].n.neoncache[ii].n)); break; \
- case NEON_CACHE_MM: dynarec_log(LOG_NONE, " D%d:%s", ii, getCacheName(dyn->insts[ninst].n.neoncache[ii].t, dyn->insts[ninst].n.neoncache[ii].n)); break; \
- case NEON_CACHE_XMMW: dynarec_log(LOG_NONE, " Q%d:%s", ii, getCacheName(dyn->insts[ninst].n.neoncache[ii].t, dyn->insts[ninst].n.neoncache[ii].n)); break; \
- case NEON_CACHE_XMMR: dynarec_log(LOG_NONE, " Q%d:%s", ii, getCacheName(dyn->insts[ninst].n.neoncache[ii].t, dyn->insts[ninst].n.neoncache[ii].n)); break; \
- case NEON_CACHE_SCR: dynarec_log(LOG_NONE, " D%d:%s", ii, getCacheName(dyn->insts[ninst].n.neoncache[ii].t, dyn->insts[ninst].n.neoncache[ii].n)); break; \
- case NEON_CACHE_NONE: \
- default: break; \
- } \
- } \
- if(dyn->n.stack || dyn->insts[ninst].n.stack_next || dyn->insts[ninst].n.x87stack) \
- dynarec_log(LOG_NONE, " X87:%d/%d(+%d/-%d)%d", dyn->n.stack, dyn->insts[ninst].n.stack_next, dyn->insts[ninst].n.stack_push, dyn->insts[ninst].n.stack_pop, dyn->insts[ninst].n.x87stack); \
- if(dyn->insts[ninst].n.combined1 || dyn->insts[ninst].n.combined2) \
- dynarec_log(LOG_NONE, " %s:%d/%d", dyn->insts[ninst].n.swapped?"SWP":"CMB", dyn->insts[ninst].n.combined1, dyn->insts[ninst].n.combined2); \
- dynarec_log(LOG_NONE, "%s\n", (box64_dynarec_dump>1)?"\e[m":""); \
- }
-
-#define TABLE64(A, V) {int val64offset = Table64(dyn, (V)); MESSAGE(LOG_DUMP, " Table64: 0x%lx\n", (V)); LDRx_literal(A, val64offset);}
-#define FTABLE64(A, V) {mmx87_regs_t v = {.d = V}; int val64offset = Table64(dyn, v.q); MESSAGE(LOG_DUMP, " FTable64: %g\n", v.d); VLDR64_literal(A, val64offset);}
+#define INST_NAME(name) inst_name_pass3(dyn, ninst, name, rex)
+#define TABLE64(A, V) {int val64offset = Table64(dyn, (V), 3); MESSAGE(LOG_DUMP, " Table64: 0x%lx\n", (V)); LDRx_literal(A, val64offset);}
+#define FTABLE64(A, V) {mmx87_regs_t v = {.d = V}; int val64offset = Table64(dyn, v.q, 3); MESSAGE(LOG_DUMP, " FTable64: %g\n", v.d); VLDR64_literal(A, val64offset);}
diff --git a/src/dynarec/arm64/dynarec_arm64_private.h b/src/dynarec/arm64/dynarec_arm64_private.h
index d0ca7c9..6ac79d7 100755..100644
--- a/src/dynarec/arm64/dynarec_arm64_private.h
+++ b/src/dynarec/arm64/dynarec_arm64_private.h
@@ -9,13 +9,14 @@ typedef struct instsize_s instsize_t;
#define BARRIER_MAYBE 8
-#define NEON_CACHE_NONE 0
-#define NEON_CACHE_ST_D 1
-#define NEON_CACHE_ST_F 2
-#define NEON_CACHE_MM 3
-#define NEON_CACHE_XMMW 4
-#define NEON_CACHE_XMMR 5
-#define NEON_CACHE_SCR 6
+#define NEON_CACHE_NONE 0
+#define NEON_CACHE_ST_D 1
+#define NEON_CACHE_ST_F 2
+#define NEON_CACHE_ST_I64 3
+#define NEON_CACHE_MM 4
+#define NEON_CACHE_XMMW 5
+#define NEON_CACHE_XMMR 6
+#define NEON_CACHE_SCR 7
typedef union neon_cache_s {
int8_t v;
struct {
@@ -57,27 +58,27 @@ typedef struct neoncache_s {
typedef struct flagcache_s {
int pending; // is there a pending flags here, or to check?
- int dfnone; // if defered flags is already set to df_none
+ int dfnone; // if deferred flags is already set to df_none
} flagcache_t;
typedef struct instruction_arm64_s {
instruction_x64_t x64;
- uintptr_t address; // (start) address of the arm emited instruction
+ uintptr_t address; // (start) address of the arm emitted instruction
uintptr_t epilog; // epilog of current instruction (can be start of next, or barrier stuff)
- int size; // size of the arm emited instruction
- int size2; // size of the arm emited instrucion after pass2
+ int size; // size of the arm emitted instruction
+ int size2; // size of the arm emitted instrucion after pass2
int pred_sz; // size of predecessor list
int *pred; // predecessor array
uintptr_t mark, mark2, mark3;
- uintptr_t markf;
+ uintptr_t markf, markf2;
uintptr_t markseg;
uintptr_t marklock;
int pass2choice;// value for choices that are fixed on pass2 for pass3
uintptr_t natcall;
int retn;
int barrier_maybe;
- flagcache_t f_exit; // flags status at end of intruction
- neoncache_t n; // neoncache at end of intruction (but before poping)
+ flagcache_t f_exit; // flags status at end of instruction
+ neoncache_t n; // neoncache at end of instruction (but before poping)
flagcache_t f_entry; // flags status before the instruction begin
} instruction_arm64_t;
@@ -86,15 +87,16 @@ typedef struct dynarec_arm_s {
int32_t size;
int32_t cap;
uintptr_t start; // start of the block
- uint32_t isize; // size in byte of x64 instructions included
- void* block; // memory pointer where next instruction is emited
+ uint32_t isize; // size in bytes of x64 instructions included
+ void* block; // memory pointer where next instruction is emitted
uintptr_t native_start; // start of the arm code
size_t native_size; // size of emitted arm code
uintptr_t last_ip; // last set IP in RIP (or NULL if unclean state) TODO: move to a cache something
- uint64_t* table64; // table of 64bits value
+ uint64_t* table64; // table of 64bits values
int table64size;// size of table (will be appended at end of executable code)
int table64cap;
uintptr_t tablestart;
+ uintptr_t jmp_next; // address of the jump_next address
flagcache_t f;
neoncache_t n; // cache for the 8..31 double reg from fpu, plus x87 stack delta
uintptr_t* next; // variable array of "next" jump address
@@ -104,12 +106,15 @@ typedef struct dynarec_arm_s {
dynablock_t* dynablock;
instsize_t* instsize;
size_t insts_size; // size of the instruction size array (calculated)
- uint8_t smread; // for strongmem model emulation
+ uint8_t smread; // for strongmem model emulation
uint8_t smwrite; // for strongmem model emulation
uintptr_t forward; // address of the last end of code while testing forward
uintptr_t forward_to; // address of the next jump to (to check if everything is ok)
int32_t forward_size; // size at the forward point
int forward_ninst; // ninst at the forward point
+ uint8_t doublepush;
+ uint8_t doublepop;
+ uint8_t always_test;
} dynarec_arm_t;
void add_next(dynarec_arm_t *dyn, uintptr_t addr);
@@ -117,16 +122,16 @@ uintptr_t get_closest_next(dynarec_arm_t *dyn, uintptr_t addr);
int is_nops(dynarec_arm_t *dyn, uintptr_t addr, int n);
int is_instructions(dynarec_arm_t *dyn, uintptr_t addr, int n);
-int Table64(dynarec_arm_t *dyn, uint64_t val); // add a value to etable64 (if needed) and gives back the imm19 to use in LDR_literal
+int Table64(dynarec_arm_t *dyn, uint64_t val, int pass); // add a value to table64 (if needed) and gives back the imm19 to use in LDR_literal
void CreateJmpNext(void* addr, void* next);
-#define GO_TRACE() \
- GETIP_(ip); \
+#define GO_TRACE(A, B) \
+ GETIP(addr); \
MOVx_REG(x1, xRIP); \
STORE_XEMU_CALL(xRIP); \
- MOV32w(x2, 1); \
- CALL(PrintTrace, -1); \
+ MOV32w(x2, B); \
+ CALL(A, -1); \
LOAD_XEMU_CALL(xRIP)
#endif //__DYNAREC_ARM_PRIVATE_H_
diff --git a/src/dynarec/dynablock.c b/src/dynarec/dynablock.c
index 59530ae..114479b 100755..100644
--- a/src/dynarec/dynablock.c
+++ b/src/dynarec/dynablock.c
@@ -1,6 +1,5 @@
#include <stdio.h>
#include <stdlib.h>
-#include <pthread.h>
#include <errno.h>
#include <setjmp.h>
#include <sys/mman.h>
@@ -9,7 +8,6 @@
#include "box64context.h"
#include "dynarec.h"
#include "emu/x64emu_private.h"
-#include "tools/bridge_private.h"
#include "x64run.h"
#include "x64emu.h"
#include "box64stack.h"
@@ -37,6 +35,39 @@ uint32_t X31_hash_code(void* addr, int len)
return (uint32_t)h;
}
+dynablock_t* InvalidDynablock(dynablock_t* db, int need_lock)
+{
+ if(db) {
+ if(db->gone)
+ return NULL; // already in the process of deletion!
+ dynarec_log(LOG_DEBUG, "InvalidDynablock(%p), db->block=%p x64=%p:%p already gone=%d\n", db, db->block, db->x64_addr, db->x64_addr+db->x64_size-1, db->gone);
+ if(need_lock)
+ mutex_lock(&my_context->mutex_dyndump);
+ // remove jumptable
+ setJumpTableDefault64(db->x64_addr);
+ db->done = 0;
+ db->gone = 1;
+ if(need_lock)
+ mutex_unlock(&my_context->mutex_dyndump);
+ }
+ return db;
+}
+
+void FreeInvalidDynablock(dynablock_t* db, int need_lock)
+{
+ if(db) {
+ if(!db->gone)
+ return; // already in the process of deletion!
+ dynarec_log(LOG_DEBUG, "FreeInvalidDynablock(%p), db->block=%p x64=%p:%p already gone=%d\n", db, db->block, db->x64_addr, db->x64_addr+db->x64_size-1, db->gone);
+ if(need_lock)
+ mutex_lock(&my_context->mutex_dyndump);
+ FreeDynarecMap((uintptr_t)db->actual_block);
+ customFree(db);
+ if(need_lock)
+ mutex_unlock(&my_context->mutex_dyndump);
+ }
+}
+
void FreeDynablock(dynablock_t* db, int need_lock)
{
if(db) {
@@ -50,6 +81,8 @@ void FreeDynablock(dynablock_t* db, int need_lock)
dynarec_log(LOG_DEBUG, " -- FreeDyrecMap(%p, %d)\n", db->actual_block, db->size);
db->done = 0;
db->gone = 1;
+ if(db->previous)
+ FreeInvalidDynablock(db->previous, 0);
FreeDynarecMap((uintptr_t)db->actual_block);
customFree(db);
if(need_lock)
@@ -57,14 +90,26 @@ void FreeDynablock(dynablock_t* db, int need_lock)
}
}
+
+
void MarkDynablock(dynablock_t* db)
{
if(db) {
- if(db->need_test)
- return; // already done
dynarec_log(LOG_DEBUG, "MarkDynablock %p %p-%p\n", db, db->x64_addr, db->x64_addr+db->x64_size-1);
- db->need_test = 1;
- setJumpTableIfRef64(db->x64_addr, db->jmpnext, db->block);
+ if(!setJumpTableIfRef64(db->x64_addr, db->jmpnext, db->block)) {
+ dynablock_t* old = db;
+ db = getDB((uintptr_t)old->x64_addr);
+ if(!old->gone && db!=old) {
+ printf_log(LOG_INFO, "Warning, couldn't mark block as dirty for %p, block=%p, current_block=%p\n", old->x64_addr, old, db);
+ // the block is lost, need to invalidate it...
+ old->gone = 1;
+ old->done = 0;
+ if(!db || db->previous)
+ FreeInvalidDynablock(old, 1);
+ else
+ db->previous = old;
+ }
+ }
}
}
@@ -78,7 +123,7 @@ static int IntervalIntersects(uintptr_t start1, uintptr_t end1, uintptr_t start2
static int MarkedDynablock(dynablock_t* db)
{
if(db) {
- if(db->need_test)
+ if(getNeedTest((uintptr_t)db->x64_addr))
return 1; // already done
}
return 0;
@@ -90,9 +135,8 @@ void MarkRangeDynablock(dynablock_t* db, uintptr_t addr, uintptr_t size)
if(!db)
return;
dynarec_log(LOG_DEBUG, "MarkRangeDynablock %p-%p .. startdb=%p, sizedb=%p\n", (void*)addr, (void*)addr+size-1, (void*)db->x64_addr, (void*)db->x64_size);
- if(!MarkedDynablock(db))
- if(IntervalIntersects((uintptr_t)db->x64_addr, (uintptr_t)db->x64_addr+db->x64_size-1, addr, addr+size+1))
- MarkDynablock(db);
+ if(IntervalIntersects((uintptr_t)db->x64_addr, (uintptr_t)db->x64_addr+db->x64_size-1, addr, addr+size+1))
+ MarkDynablock(db);
}
int FreeRangeDynablock(dynablock_t* db, uintptr_t addr, uintptr_t size)
@@ -138,7 +182,7 @@ void cancelFillBlock()
return NULL if block is not found / cannot be created.
Don't create if create==0
*/
-static dynablock_t* internalDBGetBlock(x64emu_t* emu, uintptr_t addr, uintptr_t filladdr, int create, int need_lock)
+static dynablock_t* internalDBGetBlock(x64emu_t* emu, uintptr_t addr, uintptr_t filladdr, int create, int need_lock, int is32bits)
{
if(hasAlternate((void*)addr))
return NULL;
@@ -153,13 +197,11 @@ static dynablock_t* internalDBGetBlock(x64emu_t* emu, uintptr_t addr, uintptr_t
if(mutex_trylock(&my_context->mutex_dyndump)) // FillBlock not available for now
return NULL;
}
- }
-
- block = getDB(addr); // just in case
- if(block) {
- if(need_lock)
+ block = getDB(addr); // just in case
+ if(block) {
mutex_unlock(&my_context->mutex_dyndump);
- return block;
+ return block;
+ }
}
block = AddNewDynablock(addr);
@@ -167,26 +209,28 @@ static dynablock_t* internalDBGetBlock(x64emu_t* emu, uintptr_t addr, uintptr_t
// fill the block
block->x64_addr = (void*)addr;
if(sigsetjmp(&dynarec_jmpbuf, 1)) {
- printf_log(LOG_INFO, "FillBlock at %p triggered a segfault, cancelling\n", (void*)addr);
+ printf_log(LOG_INFO, "FillBlock at %p triggered a segfault, canceling\n", (void*)addr);
+ FreeDynablock(block, 0);
if(need_lock)
mutex_unlock(&my_context->mutex_dyndump);
return NULL;
}
- void* ret = FillBlock64(block, filladdr);
+ void* ret = FillBlock64(block, filladdr, (addr==filladdr)?0:1, is32bits);
if(!ret) {
dynarec_log(LOG_DEBUG, "Fillblock of block %p for %p returned an error\n", block, (void*)addr);
customFree(block);
block = NULL;
}
// check size
- if(block && (block->x64_size || (!block->x64_size && !block->done))) {
+ if(block) {
int blocksz = block->x64_size;
if(blocksz>my_context->max_db_size)
my_context->max_db_size = blocksz;
// fill-in jumptable
- if(!addJumpTableIfDefault64(block->x64_addr, block->block)) {
+ if(!addJumpTableIfDefault64(block->x64_addr, block->dirty?block->jmpnext:block->block)) {
FreeDynablock(block, 0);
block = getDB(addr);
+ MarkDynablock(block); // just in case...
} else {
if(block->x64_size)
block->done = 1; // don't validate the block if the size is null, but keep the block
@@ -200,15 +244,20 @@ static dynablock_t* internalDBGetBlock(x64emu_t* emu, uintptr_t addr, uintptr_t
return block;
}
-dynablock_t* DBGetBlock(x64emu_t* emu, uintptr_t addr, int create)
+dynablock_t* DBGetBlock(x64emu_t* emu, uintptr_t addr, int create, int is32bits)
{
- dynablock_t *db = internalDBGetBlock(emu, addr, addr, create, 1);
- if(db && db->done && db->block && db->need_test) {
+ dynablock_t *db = internalDBGetBlock(emu, addr, addr, create, 1, is32bits);
+ if(db && db->done && db->block && getNeedTest(addr)) {
+ if(db->always_test)
+ sched_yield(); // just calm down...
if(AreaInHotPage((uintptr_t)db->x64_addr, (uintptr_t)db->x64_addr + db->x64_size - 1)) {
+ emu->test.test = 0;
if(box64_dynarec_fastpage) {
uint32_t hash = X31_hash_code(db->x64_addr, db->x64_size);
- if(hash==db->hash) // seems ok, run it without reprotecting it
+ if(hash==db->hash) { // seems ok, run it without reprotecting it
+ setJumpTableIfRef64(db->x64_addr, db->block, db->jmpnext);
return db;
+ }
db->done = 0; // invalidating the block, it's already not good
dynarec_log(LOG_DEBUG, "Invalidating block %p from %p:%p (hash:%X/%X) for %p\n", db, db->x64_addr, db->x64_addr+db->x64_size-1, hash, db->hash, (void*)addr);
// Free db, it's now invalid!
@@ -220,52 +269,70 @@ dynablock_t* DBGetBlock(x64emu_t* emu, uintptr_t addr, int create)
}
}
uint32_t hash = X31_hash_code(db->x64_addr, db->x64_size);
- if(mutex_trylock(&my_context->mutex_dyndump)) {
- dynarec_log(LOG_DEBUG, "mutex_dyndump not available when trying to validate block %p from %p:%p (hash:%X) for %p\n", db, db->x64_addr, db->x64_addr+db->x64_size-1, db->hash, (void*)addr);
- return NULL;
- }
+ int need_lock = mutex_trylock(&my_context->mutex_dyndump);
if(hash!=db->hash) {
db->done = 0; // invalidating the block
dynarec_log(LOG_DEBUG, "Invalidating block %p from %p:%p (hash:%X/%X) for %p\n", db, db->x64_addr, db->x64_addr+db->x64_size-1, hash, db->hash, (void*)addr);
// Free db, it's now invalid!
- FreeDynablock(db, 0);
+ dynablock_t* old = InvalidDynablock(db, need_lock);
// start again... (will create a new block)
- db = internalDBGetBlock(emu, addr, addr, create, 0);
+ db = internalDBGetBlock(emu, addr, addr, create, need_lock, is32bits);
+ if(db) {
+ if(db->previous)
+ FreeInvalidDynablock(db->previous, need_lock);
+ db->previous = old;
+ } else
+ FreeInvalidDynablock(old, need_lock);
} else {
- db->need_test = 0;
dynarec_log(LOG_DEBUG, "Validating block %p from %p:%p (hash:%X) for %p\n", db, db->x64_addr, db->x64_addr+db->x64_size-1, db->hash, (void*)addr);
protectDB((uintptr_t)db->x64_addr, db->x64_size);
// fill back jumptable
- setJumpTableIfRef64(db->x64_addr, db->block, db->jmpnext);
+ if(isprotectedDB((uintptr_t)db->x64_addr, db->x64_size) && !db->always_test) {
+ setJumpTableIfRef64(db->x64_addr, db->block, db->jmpnext);
+ }
}
- mutex_unlock(&my_context->mutex_dyndump);
+ if(!need_lock)
+ mutex_unlock(&my_context->mutex_dyndump);
}
+ if(!db || !db->block || !db->done)
+ emu->test.test = 0;
return db;
}
-dynablock_t* DBAlternateBlock(x64emu_t* emu, uintptr_t addr, uintptr_t filladdr)
+dynablock_t* DBAlternateBlock(x64emu_t* emu, uintptr_t addr, uintptr_t filladdr, int is32bits)
{
- dynarec_log(LOG_DEBUG, "Creating AlternateBlock at %p for %p\n", (void*)addr, (void*)filladdr);
+ dynarec_log(LOG_DEBUG, "Creating AlternateBlock at %p for %p%s\n", (void*)addr, (void*)filladdr, is32bits?" 32bits":"");
int create = 1;
- dynablock_t *db = internalDBGetBlock(emu, addr, filladdr, create, 1);
- if(db && db->done && db->block && db->need_test) {
- if(mutex_trylock(&my_context->mutex_dyndump))
- return NULL;
+ dynablock_t *db = internalDBGetBlock(emu, addr, filladdr, create, 1, is32bits);
+ if(db && db->done && db->block && getNeedTest(filladdr)) {
+ if(db->always_test)
+ sched_yield(); // just calm down...
+ int need_lock = mutex_trylock(&my_context->mutex_dyndump);
uint32_t hash = X31_hash_code(db->x64_addr, db->x64_size);
if(hash!=db->hash) {
db->done = 0; // invalidating the block
dynarec_log(LOG_DEBUG, "Invalidating alt block %p from %p:%p (hash:%X/%X) for %p\n", db, db->x64_addr, db->x64_addr+db->x64_size, hash, db->hash, (void*)addr);
// Free db, it's now invalid!
- FreeDynablock(db, 0);
+ dynablock_t* old = InvalidDynablock(db, need_lock);
// start again... (will create a new block)
- db = internalDBGetBlock(emu, addr, filladdr, create, 0);
+ db = internalDBGetBlock(emu, addr, filladdr, create, need_lock, is32bits);
+ if(db) {
+ if(db->previous)
+ FreeInvalidDynablock(db->previous, need_lock);
+ db->previous = old;
+ } else
+ FreeInvalidDynablock(old, need_lock);
} else {
- db->need_test = 0;
protectDB((uintptr_t)db->x64_addr, db->x64_size);
// fill back jumptable
- addJumpTableIfDefault64(db->x64_addr, db->block);
+ if(isprotectedDB((uintptr_t)db->x64_addr, db->x64_size) && !db->always_test) {
+ setJumpTableIfRef64(db->x64_addr, db->block, db->jmpnext);
+ }
}
- mutex_unlock(&my_context->mutex_dyndump);
+ if(!need_lock)
+ mutex_unlock(&my_context->mutex_dyndump);
}
+ if(!db || !db->block || !db->done)
+ emu->test.test = 0;
return db;
}
diff --git a/src/dynarec/dynablock_private.h b/src/dynarec/dynablock_private.h
index dbe8c50..18666e0 100755..100644
--- a/src/dynarec/dynablock_private.h
+++ b/src/dynarec/dynablock_private.h
@@ -9,14 +9,15 @@ typedef struct instsize_s {
typedef struct dynablock_s {
void* block; // block-sizeof(void*) == self
void* actual_block; // the actual start of the block (so block-sizeof(void*))
+ struct dynablock_s* previous; // a previous block that might need to be freed
int size;
void* x64_addr;
uintptr_t x64_size;
uint32_t hash;
- uint8_t need_test;
uint8_t done;
uint8_t gone;
- uint8_t dummy;
+ uint8_t always_test;
+ uint8_t dirty; // if need to be tested as soon as it's created
int isize;
instsize_t* instsize;
void* jmpnext; // a branch jmpnext code when block is marked
diff --git a/src/dynarec/dynarec.c b/src/dynarec/dynarec.c
index 24d1d1b..bb6b3ba 100755..100644
--- a/src/dynarec/dynarec.c
+++ b/src/dynarec/dynarec.c
@@ -1,6 +1,5 @@
#include <stdio.h>
#include <stdlib.h>
-#include <pthread.h>
#include <errno.h>
#include <setjmp.h>
@@ -8,7 +7,6 @@
#include "box64context.h"
#include "dynarec.h"
#include "emu/x64emu_private.h"
-#include "tools/bridge_private.h"
#include "x64run.h"
#include "x64emu.h"
#include "box64stack.h"
@@ -31,6 +29,7 @@ uintptr_t getX64Address(dynablock_t* db, uintptr_t arm_addr);
void* LinkNext(x64emu_t* emu, uintptr_t addr, void* x2, uintptr_t* x3)
{
+ int is32bits = (R_CS == 0x23);
#ifdef HAVE_TRACE
if(!addr) {
dynablock_t* db = FindDynablockFromNativeAddress(x2-4);
@@ -38,27 +37,28 @@ void* LinkNext(x64emu_t* emu, uintptr_t addr, void* x2, uintptr_t* x3)
}
#endif
void * jblock;
- dynablock_t* block = DBGetBlock(emu, addr, 1);
+ dynablock_t* block = NULL;
+ if(hasAlternate((void*)addr)) {
+ printf_log(LOG_DEBUG, "Jmp address has alternate: %p", (void*)addr);
+ if(box64_log<LOG_DEBUG) dynarec_log(LOG_INFO, "Jmp address has alternate: %p", (void*)addr);
+ uintptr_t old_addr = addr;
+ addr = (uintptr_t)getAlternate((void*)addr); // set new address
+ R_RIP = addr; // but also new RIP!
+ *x3 = addr; // and the RIP in x27 register
+ printf_log(LOG_DEBUG, " -> %p\n", (void*)addr);
+ block = DBAlternateBlock(emu, old_addr, addr, is32bits);
+ } else
+ block = DBGetBlock(emu, addr, 1, is32bits);
if(!block) {
- // no block, let link table as is...
- if(hasAlternate((void*)addr)) {
- printf_log(LOG_DEBUG, "Jmp address has alternate: %p", (void*)addr);
- if(box64_log<LOG_DEBUG) dynarec_log(LOG_INFO, "Jmp address has alternate: %p", (void*)addr);
- addr = (uintptr_t)getAlternate((void*)addr); // set new address
- R_RIP = addr; // but also new RIP!
- *x3 = addr; // and the RIP in x27 register
- printf_log(LOG_DEBUG, " -> %p\n", (void*)addr);
- block = DBGetBlock(emu, addr, 1);
- }
- if(!block) {
- #ifdef HAVE_TRACE
+ #ifdef HAVE_TRACE
+ if(LOG_INFO<=box64_dynarec_log) {
dynablock_t* db = FindDynablockFromNativeAddress(x2-4);
elfheader_t* h = FindElfAddress(my_context, (uintptr_t)x2-4);
dynarec_log(LOG_INFO, "Warning, jumping to a no-block address %p from %p (db=%p, x64addr=%p(elf=%s))\n", (void*)addr, x2-4, db, db?(void*)getX64Address(db, (uintptr_t)x2-4):NULL, h?ElfName(h):"(none)");
- #endif
- //tableupdate(native_epilog, addr, table);
- return native_epilog;
}
+ #endif
+ //tableupdate(native_epilog, addr, table);
+ return native_epilog;
}
if(!block->done) {
// not finished yet... leave linker
@@ -73,127 +73,77 @@ void* LinkNext(x64emu_t* emu, uintptr_t addr, void* x2, uintptr_t* x3)
}
#endif
-#ifdef __GNUC__
-// Disable "clobbered" warnings
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wclobbered"
-#endif
void DynaCall(x64emu_t* emu, uintptr_t addr)
{
- // prepare setjump for signal handling
- emu_jmpbuf_t *ejb = NULL;
- int jmpbuf_reset = 0;
- if(emu->type == EMUTYPE_MAIN) {
- ejb = GetJmpBuf();
- if(!ejb->jmpbuf_ok) {
- ejb->emu = emu;
- ejb->jmpbuf_ok = 1;
- jmpbuf_reset = 1;
- if(sigsetjmp((struct __jmp_buf_tag*)ejb->jmpbuf, 1)) {
- printf_log(LOG_DEBUG, "Setjmp DynaCall, fs=0x%x\n", ejb->emu->segs[_FS]);
- addr = R_RIP; // not sure if it should still be inside DynaCall!
- }
- }
- }
-#ifdef DYNAREC
- if(!box64_dynarec)
-#endif
- EmuCall(emu, addr);
-#ifdef DYNAREC
- else {
- uint64_t old_rsp = R_RSP;
- uint64_t old_rbx = R_RBX;
- uint64_t old_rdi = R_RDI;
- uint64_t old_rsi = R_RSI;
- uint64_t old_rbp = R_RBP;
- uint64_t old_rip = R_RIP;
- PushExit(emu);
- R_RIP = addr;
- emu->df = d_none;
- while(!emu->quit) {
- dynablock_t* block = DBGetBlock(emu, R_RIP, 1);
- if(!block || !block->block || !block->done) {
- // no block, of block doesn't have DynaRec content (yet, temp is not null)
- // Use interpreter (should use single instruction step...)
- dynarec_log(LOG_DEBUG, "%04d|Calling Interpretor @%p, emu=%p\n", GetTID(), (void*)R_RIP, emu);
- Run(emu, 1);
- } else {
- dynarec_log(LOG_DEBUG, "%04d|Calling DynaRec Block @%p (%p) of %d x64 instructions emu=%p\n", GetTID(), (void*)R_RIP, block->block, block->isize ,emu);
- CHECK_FLAGS(emu);
- // block is here, let's run it!
- native_prolog(emu, block->block);
- }
- if(emu->fork) {
- int forktype = emu->fork;
- emu->quit = 0;
- emu->fork = 0;
- emu = x64emu_fork(emu, forktype);
- if(emu->type == EMUTYPE_MAIN) {
- ejb = GetJmpBuf();
- ejb->emu = emu;
- ejb->jmpbuf_ok = 1;
- jmpbuf_reset = 1;
- if(sigsetjmp((struct __jmp_buf_tag*)ejb->jmpbuf, 1)) {
- printf_log(LOG_DEBUG, "Setjmp inner DynaCall, fs=0x%x\n", ejb->emu->segs[_FS]);
- addr = R_RIP;
- }
- }
- }
- }
- emu->quit = 0; // reset Quit flags...
- emu->df = d_none;
- if(emu->quitonlongjmp && emu->longjmp) {
- if(emu->quitonlongjmp==1)
- emu->longjmp = 0; // don't change anything because of the longjmp
- } else {
- R_RBX = old_rbx;
- R_RDI = old_rdi;
- R_RSI = old_rsi;
- R_RBP = old_rbp;
- R_RSP = old_rsp;
- R_RIP = old_rip; // and set back instruction pointer
- }
+ uint64_t old_rsp = R_RSP;
+ uint64_t old_rbx = R_RBX;
+ uint64_t old_rdi = R_RDI;
+ uint64_t old_rsi = R_RSI;
+ uint64_t old_rbp = R_RBP;
+ uint64_t old_rip = R_RIP;
+ PushExit(emu);
+ R_RIP = addr;
+ emu->df = d_none;
+ DynaRun(emu);
+ emu->quit = 0; // reset Quit flags...
+ emu->df = d_none;
+ if(emu->flags.quitonlongjmp && emu->flags.longjmp) {
+ if(emu->flags.quitonlongjmp==1)
+ emu->flags.longjmp = 0; // don't change anything because of the longjmp
+ } else {
+ R_RBX = old_rbx;
+ R_RDI = old_rdi;
+ R_RSI = old_rsi;
+ R_RBP = old_rbp;
+ R_RSP = old_rsp;
+ R_RIP = old_rip; // and set back instruction pointer
}
-#endif
- // clear the setjmp
- if(ejb && jmpbuf_reset)
- ejb->jmpbuf_ok = 0;
}
-int DynaRun(x64emu_t* emu)
+void DynaRun(x64emu_t* emu)
{
// prepare setjump for signal handling
- emu_jmpbuf_t *ejb = NULL;
-#ifdef DYNAREC
- int jmpbuf_reset = 1;
-#endif
- if(emu->type == EMUTYPE_MAIN) {
- ejb = GetJmpBuf();
- if(!ejb->jmpbuf_ok) {
- ejb->emu = emu;
- ejb->jmpbuf_ok = 1;
-#ifdef DYNAREC
- jmpbuf_reset = 1;
-#endif
- if(sigsetjmp((struct __jmp_buf_tag*)ejb->jmpbuf, 1))
- printf_log(LOG_DEBUG, "Setjmp DynaRun, fs=0x%x\n", ejb->emu->segs[_FS]);
+ struct __jmp_buf_tag jmpbuf[1] = {0};
+ int skip = 0;
+ struct __jmp_buf_tag *old_jmpbuf = emu->jmpbuf;
+ emu->flags.jmpbuf_ready = 0;
+
+ while(!(emu->quit)) {
+ if(!emu->jmpbuf || (emu->flags.need_jmpbuf && emu->jmpbuf!=jmpbuf)) {
+ emu->jmpbuf = jmpbuf;
+ emu->flags.jmpbuf_ready = 1;
+ if((skip=sigsetjmp(emu->jmpbuf, 1))) {
+ printf_log(LOG_DEBUG, "Setjmp DynaRun, fs=0x%x\n", emu->segs[_FS]);
+ #ifdef DYNAREC
+ if(box64_dynarec_test) {
+ if(emu->test.clean)
+ x64test_check(emu, R_RIP);
+ emu->test.clean = 0;
+ }
+ #endif
+ }
}
- }
+ if(emu->flags.need_jmpbuf)
+ emu->flags.need_jmpbuf = 0;
+
#ifdef DYNAREC
- if(!box64_dynarec)
+ if(!box64_dynarec)
#endif
- return Run(emu, 0);
+ Run(emu, 0);
#ifdef DYNAREC
- else {
- while(!emu->quit) {
- dynablock_t* block = DBGetBlock(emu, R_RIP, 1);
+ else {
+ int is32bits = (emu->segs[_CS]==0x23);
+ dynablock_t* block = (skip)?NULL:DBGetBlock(emu, R_RIP, 1, is32bits);
if(!block || !block->block || !block->done) {
+ skip = 0;
// no block, of block doesn't have DynaRec content (yet, temp is not null)
// Use interpreter (should use single instruction step...)
- dynarec_log(LOG_DEBUG, "%04d|Running Interpretor @%p, emu=%p\n", GetTID(), (void*)R_RIP, emu);
+ dynarec_log(LOG_DEBUG, "%04d|Running Interpreter @%p, emu=%p\n", GetTID(), (void*)R_RIP, emu);
+ if(box64_dynarec_test)
+ emu->test.clean = 0;
Run(emu, 1);
} else {
- dynarec_log(LOG_DEBUG, "%04d|Running DynaRec Block @%p (%p) of %d x64 insts emu=%p\n", GetTID(), (void*)R_RIP, block->block, block->isize, emu);
+ dynarec_log(LOG_DEBUG, "%04d|Running DynaRec Block @%p (%p) of %d x64 insts (hash=0x%x) emu=%p\n", GetTID(), (void*)R_RIP, block->block, block->isize, block->hash, emu);
// block is here, let's run it!
native_prolog(emu, block->block);
}
@@ -202,23 +152,12 @@ int DynaRun(x64emu_t* emu)
emu->quit = 0;
emu->fork = 0;
emu = x64emu_fork(emu, forktype);
- if(emu->type == EMUTYPE_MAIN) {
- ejb = GetJmpBuf();
- ejb->emu = emu;
- ejb->jmpbuf_ok = 1;
- jmpbuf_reset = 1;
- if(sigsetjmp((struct __jmp_buf_tag*)ejb->jmpbuf, 1))
- printf_log(LOG_DEBUG, "Setjmp inner DynaRun, fs=0x%x\n", ejb->emu->segs[_FS]);
- }
}
}
+#endif
+ if(emu->flags.need_jmpbuf)
+ emu->quit = 0;
}
// clear the setjmp
- if(ejb && jmpbuf_reset)
- ejb->jmpbuf_ok = 0;
- return 0;
-#endif
+ emu->jmpbuf = old_jmpbuf;
}
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/src/dynarec/dynarec_arch.h b/src/dynarec/dynarec_arch.h
index e5e9865..51e74d4 100755..100644
--- a/src/dynarec/dynarec_arch.h
+++ b/src/dynarec/dynarec_arch.h
@@ -2,22 +2,45 @@
#define __DYNAREC_ARCH__H_
#ifdef ARM64
-#include "arm64/arm64_printer.h"
-#include "arm64/dynarec_arm64_private.h"
-#include "arm64/dynarec_arm64_functions.h"
#define instruction_native_t instruction_arm64_t
#define dynarec_native_t dynarec_arm_t
+#define ADDITIONNAL_DEFINITION() \
+ int fpuCacheNeedsTransform(dynarec_native_t* dyn, int ninst);
+
+#define OTHER_CACHE() \
+ if (fpuCacheNeedsTransform(dyn, ninst)) ret|=2;
+
+#include "arm64/arm64_printer.h"
+#include "arm64/dynarec_arm64_private.h"
+#include "arm64/dynarec_arm64_functions.h"
#elif defined(LA464)
+
+#define instruction_native_t instruction_la464_t
+#define dynarec_native_t dynarec_la464_t
+
+#define ADDITIONNAL_DEFINITION()
+
+#define OTHER_CACHE()
+
#include "la464/la464_printer.h"
#include "la464/dynarec_la464_private.h"
#include "la464/dynarec_la464_functions.h"
+#elif defined(RV64)
-#define instruction_native_t instruction_la464_t
-#define dynarec_native_t dynarec_la464_t
+#define instruction_native_t instruction_rv64_t
+#define dynarec_native_t dynarec_rv64_t
+
+#define ADDITIONNAL_DEFINITION() \
+ int fpuCacheNeedsTransform(dynarec_native_t* dyn, int ninst);
+#define OTHER_CACHE() \
+ if (fpuCacheNeedsTransform(dyn, ninst)) ret|=2;
+#include "rv64/rv64_printer.h"
+#include "rv64/dynarec_rv64_private.h"
+#include "rv64/dynarec_rv64_functions.h"
#else
#error Unsupported platform
#endif
diff --git a/src/dynarec/dynarec_helper.h b/src/dynarec/dynarec_helper.h
index 19f48dc..2f4b82f 100755..100644
--- a/src/dynarec/dynarec_helper.h
+++ b/src/dynarec/dynarec_helper.h
@@ -5,6 +5,8 @@
#include "arm64/dynarec_arm64_helper.h"
#elif defined(LA464)
#include "la464/dynarec_la464_helper.h"
+#elif defined(RV64)
+#include "rv64/dynarec_rv64_helper.h"
#else
#error Unsupported architecture
#endif
diff --git a/src/dynarec/dynarec_native.c b/src/dynarec/dynarec_native.c
index c3f01ff..2aade27 100755..100644
--- a/src/dynarec/dynarec_native.c
+++ b/src/dynarec/dynarec_native.c
@@ -1,6 +1,5 @@
#include <stdio.h>
#include <stdlib.h>
-#include <pthread.h>
#include <errno.h>
#include <string.h>
#include <assert.h>
@@ -10,7 +9,6 @@
#include "custommem.h"
#include "dynarec.h"
#include "emu/x64emu_private.h"
-#include "tools/bridge_private.h"
#include "x64run.h"
#include "x64emu.h"
#include "box64stack.h"
@@ -75,20 +73,22 @@ void add_next(dynarec_native_t *dyn, uintptr_t addr) {
// add slots
if(dyn->next_sz == dyn->next_cap) {
dyn->next_cap += 64;
- dyn->next = (uintptr_t*)customRealloc(dyn->next, dyn->next_cap*sizeof(uintptr_t));
+ dyn->next = (uintptr_t*)dynaRealloc(dyn->next, dyn->next_cap*sizeof(uintptr_t));
}
dyn->next[dyn->next_sz++] = addr;
}
uintptr_t get_closest_next(dynarec_native_t *dyn, uintptr_t addr) {
- // get closest, but no addresses befores
+ // get closest, but no addresses before
uintptr_t best = 0;
int i = 0;
while((i<dyn->next_sz) && (best!=addr)) {
- if(dyn->next[i]<addr) { // remove the address, it's before current address
- dyn->next[i] = 0;
- } else {
- if((dyn->next[i]<best) || !best)
- best = dyn->next[i];
+ if(dyn->next[i]) {
+ if(dyn->next[i]<addr) { // remove the address, it's before current address
+ dyn->next[i] = 0;
+ } else {
+ if((dyn->next[i]<best) || !best)
+ best = dyn->next[i];
+ }
}
++i;
}
@@ -124,8 +124,8 @@ int is_nops(dynarec_native_t *dyn, uintptr_t addr, int n)
return 0;
}
-// return size of next instuciton, -1 is unknown
-// not all instrction are setup
+// return size of next instruction, -1 is unknown
+// not all instructions are setup
int next_instruction(dynarec_native_t *dyn, uintptr_t addr)
{
uint8_t opcode = PK(0);
@@ -265,7 +265,7 @@ void addInst(instsize_t* insts, size_t* size, int x64_size, int native_size)
}
// add a value to table64 (if needed) and gives back the imm19 to use in LDR_literal
-int Table64(dynarec_native_t *dyn, uint64_t val)
+int Table64(dynarec_native_t *dyn, uint64_t val, int pass)
{
// find the value if already present
int idx = -1;
@@ -276,10 +276,14 @@ int Table64(dynarec_native_t *dyn, uint64_t val)
if(idx==-1) {
if(dyn->table64size == dyn->table64cap) {
dyn->table64cap+=16;
- dyn->table64 = (uint64_t*)customRealloc(dyn->table64, dyn->table64cap * sizeof(uint64_t));
+ if(pass<3) // do not resize on pass3, it's not the same type of memory anymore
+ dyn->table64 = (uint64_t*)dynaRealloc(dyn->table64, dyn->table64cap * sizeof(uint64_t));
}
idx = dyn->table64size++;
- dyn->table64[idx] = val;
+ if(idx < dyn->table64cap)
+ dyn->table64[idx] = val;
+ else
+ printf_log(LOG_NONE, "Warning, table64 bigger than expected %d vs %d\n", idx, dyn->table64cap);
}
// calculate offset
int delta = dyn->tablestart + idx*sizeof(uint64_t) - (uintptr_t)dyn->block;
@@ -289,7 +293,7 @@ int Table64(dynarec_native_t *dyn, uint64_t val)
static void fillPredecessors(dynarec_native_t* dyn)
{
int pred_sz = 1; // to be safe
- // compute total size of predecessor to alocate the array
+ // compute total size of predecessor to allocate the array
// first compute the jumps
for(int i=0; i<dyn->size; ++i) {
if(dyn->insts[i].x64.jmp && (dyn->insts[i].x64.jmp_insts!=-1)) {
@@ -297,6 +301,13 @@ static void fillPredecessors(dynarec_native_t* dyn)
dyn->insts[dyn->insts[i].x64.jmp_insts].pred_sz++;
}
}
+ // remove "has_next" from orphan branch
+ for(int i=0; i<dyn->size-1; ++i) {
+ if(!dyn->insts[i].x64.has_next) {
+ if(dyn->insts[i+1].x64.has_next && !dyn->insts[i+1].pred_sz)
+ dyn->insts[i+1].x64.has_next = 0;
+ }
+ }
// second the "has_next"
for(int i=0; i<dyn->size-1; ++i) {
if(dyn->insts[i].x64.has_next) {
@@ -304,7 +315,8 @@ static void fillPredecessors(dynarec_native_t* dyn)
dyn->insts[i+1].pred_sz++;
}
}
- dyn->predecessor = (int*)customMalloc(pred_sz*sizeof(int));
+ int alloc_size = pred_sz;
+ dyn->predecessor = (int*)dynaMalloc(pred_sz*sizeof(int));
// fill pred pointer
int* p = dyn->predecessor;
for(int i=0; i<dyn->size; ++i) {
@@ -321,11 +333,10 @@ static void fillPredecessors(dynarec_native_t* dyn)
dyn->insts[j].pred[dyn->insts[j].pred_sz++] = i;
}
}
-
}
-// updateNeed goes backward, from last intruction to top
-static int updateNeed(dynarec_arm_t* dyn, int ninst, uint8_t need) {
+// updateNeed goes backward, from last instruction to top
+static int updateNeed(dynarec_native_t* dyn, int ninst, uint8_t need) {
while (ninst>=0) {
// need pending but instruction is only a subset: remove pend and use an X_ALL instead
need |= dyn->insts[ninst].x64.need_after;
@@ -364,9 +375,9 @@ static int updateNeed(dynarec_arm_t* dyn, int ninst, uint8_t need) {
else
updateNeed(dyn, dyn->insts[ninst].pred[i], need);
}
- if(!ok)
- return ninst - 1;
--ninst;
+ if(!ok)
+ return ninst;
}
return ninst;
}
@@ -379,27 +390,25 @@ void CancelBlock64(int need_lock)
mutex_lock(&my_context->mutex_dyndump);
dynarec_native_t* helper = (dynarec_native_t*)current_helper;
current_helper = NULL;
- if(!helper) {
- if(need_lock)
- mutex_unlock(&my_context->mutex_dyndump);
- return;
+ if(helper) {
+ dynaFree(helper->next);
+ dynaFree(helper->insts);
+ dynaFree(helper->predecessor);
+ if(helper->table64 && (helper->table64!=(uint64_t*)helper->tablestart))
+ dynaFree(helper->table64);
+ if(helper->dynablock && helper->dynablock->actual_block) {
+ FreeDynarecMap((uintptr_t)helper->dynablock->actual_block);
+ helper->dynablock->actual_block = NULL;
+ }
}
- customFree(helper->next);
- customFree(helper->insts);
- customFree(helper->predecessor);
- customFree(helper->table64);
- if(helper->dynablock && helper->dynablock->actual_block)
- FreeDynarecMap((uintptr_t)helper->dynablock->actual_block);
- else if(helper->dynablock && helper->block)
- FreeDynarecMap((uintptr_t)helper->block-sizeof(void*));
if(need_lock)
mutex_unlock(&my_context->mutex_dyndump);
}
-uintptr_t native_pass0(dynarec_native_t* dyn, uintptr_t addr);
-uintptr_t native_pass1(dynarec_native_t* dyn, uintptr_t addr);
-uintptr_t native_pass2(dynarec_native_t* dyn, uintptr_t addr);
-uintptr_t native_pass3(dynarec_native_t* dyn, uintptr_t addr);
+uintptr_t native_pass0(dynarec_native_t* dyn, uintptr_t addr, int alternate, int is32bits);
+uintptr_t native_pass1(dynarec_native_t* dyn, uintptr_t addr, int alternate, int is32bits);
+uintptr_t native_pass2(dynarec_native_t* dyn, uintptr_t addr, int alternate, int is32bits);
+uintptr_t native_pass3(dynarec_native_t* dyn, uintptr_t addr, int alternate, int is32bits);
void* CreateEmptyBlock(dynablock_t* block, uintptr_t addr) {
block->isize = 0;
@@ -408,7 +417,7 @@ void* CreateEmptyBlock(dynablock_t* block, uintptr_t addr) {
void* actual_p = (void*)AllocDynarecMap(sz);
void* p = actual_p + sizeof(void*);
if(actual_p==NULL) {
- dynarec_log(LOG_INFO, "AllocDynarecMap(%p, %zu) failed, cancelling block\n", block, sz);
+ dynarec_log(LOG_INFO, "AllocDynarecMap(%p, %zu) failed, canceling block\n", block, sz);
CancelBlock64(0);
return NULL;
}
@@ -419,13 +428,12 @@ void* CreateEmptyBlock(dynablock_t* block, uintptr_t addr) {
*(dynablock_t**)actual_p = block;
*(void**)(p+2*sizeof(void*)) = native_epilog;
CreateJmpNext(block->jmpnext, p+2*sizeof(void*));
- block->need_test = 0;
// all done...
__clear_cache(actual_p, actual_p+sz); // need to clear the cache before execution...
return block;
}
-void* FillBlock64(dynablock_t* block, uintptr_t addr) {
+void* FillBlock64(dynablock_t* block, uintptr_t addr, int alternate, int is32bits) {
/*
A Block must have this layout:
@@ -436,11 +444,11 @@ void* FillBlock64(dynablock_t* block, uintptr_t addr) {
B+8 .. B+15 : 2 Native code for jmpnext (or jmp epilog in case of empty block)
B+16 .. B+23 : jmpnext (or jmp_epilog) address
B+24 .. B+31 : empty (in case an architecture needs more than 2 opcodes)
- B+32 .. B+32+sz : instsize (compressed array with each instruction lenght on x64 and native side)
+ B+32 .. B+32+sz : instsize (compressed array with each instruction length on x64 and native side)
*/
if(IsInHotPage(addr)) {
- dynarec_log(LOG_DEBUG, "Cancelling dynarec FillBlock on hotpage for %p\n", (void*)addr);
+ dynarec_log(LOG_DEBUG, "Canceling dynarec FillBlock on hotpage for %p\n", (void*)addr);
return NULL;
}
if(addr>=box64_nodynarec_start && addr<box64_nodynarec_end) {
@@ -448,7 +456,7 @@ void* FillBlock64(dynablock_t* block, uintptr_t addr) {
return CreateEmptyBlock(block, addr);
}
if(current_helper) {
- dynarec_log(LOG_DEBUG, "Cancelling dynarec FillBlock at %p as anothor one is going on\n", (void*)addr);
+ dynarec_log(LOG_DEBUG, "Canceling dynarec FillBlock at %p as another one is going on\n", (void*)addr);
return NULL;
}
// protect the 1st page
@@ -460,18 +468,18 @@ void* FillBlock64(dynablock_t* block, uintptr_t addr) {
helper.start = addr;
uintptr_t start = addr;
helper.cap = 128;
- helper.insts = (instruction_native_t*)customCalloc(helper.cap, sizeof(instruction_native_t));
+ helper.insts = (instruction_native_t*)dynaCalloc(helper.cap, sizeof(instruction_native_t));
// pass 0, addresses, x64 jump addresses, overall size of the block
- uintptr_t end = native_pass0(&helper, addr);
+ uintptr_t end = native_pass0(&helper, addr, alternate, is32bits);
// no need for next anymore
- customFree(helper.next);
+ dynaFree(helper.next);
helper.next_sz = helper.next_cap = 0;
helper.next = NULL;
// basic checks
if(!helper.size) {
dynarec_log(LOG_INFO, "Warning, null-sized dynarec block (%p)\n", (void*)addr);
CancelBlock64(0);
- return CreateEmptyBlock(block, addr);;
+ return CreateEmptyBlock(block, addr);
}
if(!isprotectedDB(addr, 1)) {
dynarec_log(LOG_INFO, "Warning, write on current page on pass0, aborting dynablock creation (%p)\n", (void*)addr);
@@ -489,6 +497,8 @@ void* FillBlock64(dynablock_t* block, uintptr_t addr) {
if(helper.insts[i].x64.jmp) {
uintptr_t j = helper.insts[i].x64.jmp;
if(j<start || j>=end || j==helper.insts[i].x64.addr) {
+ if(j==helper.insts[i].x64.addr) // if there is a loop on some opcode, make the block "always to tested"
+ helper.always_test = 1;
helper.insts[i].x64.jmp_insts = -1;
helper.insts[i].x64.need_after |= X_PEND;
} else {
@@ -510,96 +520,103 @@ void* FillBlock64(dynablock_t* block, uintptr_t addr) {
while (pos>=0)
pos = updateNeed(&helper, pos, 0);
- // pass 1, float optimisations, first pass for flags
- native_pass1(&helper, addr);
+ // pass 1, float optimizations, first pass for flags
+ native_pass1(&helper, addr, alternate, is32bits);
// pass 2, instruction size
- native_pass2(&helper, addr);
+ native_pass2(&helper, addr, alternate, is32bits);
// keep size of instructions for signal handling
size_t insts_rsize = (helper.insts_size+2)*sizeof(instsize_t);
insts_rsize = (insts_rsize+7)&~7; // round the size...
+ size_t native_size = (helper.native_size+7)&~7; // round the size...
// ok, now allocate mapped memory, with executable flag on
- size_t sz = sizeof(void*) + helper.native_size + helper.table64size*sizeof(uint64_t) + 4*sizeof(void*) + insts_rsize;
- // dynablock_t* block (arm insts) table64 jmpnext code instsize
+ size_t sz = sizeof(void*) + native_size + helper.table64size*sizeof(uint64_t) + 4*sizeof(void*) + insts_rsize;
+ // dynablock_t* block (arm insts) table64 jmpnext code instsize
void* actual_p = (void*)AllocDynarecMap(sz);
- void* p = actual_p + sizeof(void*);
- void* next = p + helper.native_size + helper.table64size*sizeof(uint64_t);
+ void* p = (void*)(((uintptr_t)actual_p) + sizeof(void*));
+ void* tablestart = p + native_size;
+ void* next = tablestart + helper.table64size*sizeof(uint64_t);
void* instsize = next + 4*sizeof(void*);
if(actual_p==NULL) {
- dynarec_log(LOG_INFO, "AllocDynarecMap(%p, %zu) failed, cancelling block\n", block, sz);
+ dynarec_log(LOG_INFO, "AllocDynarecMap(%p, %zu) failed, canceling block\n", block, sz);
CancelBlock64(0);
return NULL;
}
helper.block = p;
+ block->actual_block = actual_p;
helper.native_start = (uintptr_t)p;
- helper.tablestart = helper.native_start + helper.native_size;
- helper.insts_size = 0; // reset
+ helper.tablestart = (uintptr_t)tablestart;
+ helper.jmp_next = (uintptr_t)next+sizeof(void*);
helper.instsize = (instsize_t*)instsize;
*(dynablock_t**)actual_p = block;
+ helper.table64cap = helper.table64size;
+ dynaFree(helper.table64);
+ helper.table64 = (uint64_t*)helper.tablestart;
// pass 3, emit (log emit native opcode)
if(box64_dynarec_dump) {
- dynarec_log(LOG_NONE, "%s%04d|Emitting %zu bytes for %u x64 bytes", (box64_dynarec_dump>1)?"\e[01;36m":"", GetTID(), helper.native_size, helper.isize);
+ dynarec_log(LOG_NONE, "%s%04d|Emitting %zu bytes for %u %s bytes", (box64_dynarec_dump>1)?"\e[01;36m":"", GetTID(), helper.native_size, helper.isize, is32bits?"x86":"x64");
printFunctionAddr(helper.start, " => ");
dynarec_log(LOG_NONE, "%s\n", (box64_dynarec_dump>1)?"\e[m":"");
}
int oldtable64size = helper.table64size;
size_t oldnativesize = helper.native_size;
+ size_t oldinstsize = helper.insts_size;
helper.native_size = 0;
helper.table64size = 0; // reset table64 (but not the cap)
- native_pass3(&helper, addr);
- if((oldnativesize!=helper.native_size) || (oldtable64size<helper.table64size)) {
- printf_log(LOG_NONE, "BOX64: Warning, size difference in block between pass2 (%zu) & pass3 (%zu)!\n", sz, helper.native_size+helper.table64size*8);
- uint8_t *dump = (uint8_t*)helper.start;
- printf_log(LOG_NONE, "Dump of %d x64 opcodes:\n", helper.size);
- for(int i=0; i<helper.size; ++i) {
- printf_log(LOG_NONE, "%p:", dump);
- for(; dump<(uint8_t*)helper.insts[i+1].x64.addr; ++dump)
- printf_log(LOG_NONE, " %02X", *dump);
- printf_log(LOG_NONE, "\t%d -> %d\n", helper.insts[i].size2, helper.insts[i].size);
- }
- printf_log(LOG_NONE, "Table64 \t%d -> %d\n", oldtable64size*8, helper.table64size*8);
- printf_log(LOG_NONE, " ------------\n");
- //TODO: Cancel block and return empty one
- }
- // add table64 if needed
- if(helper.table64size) {
- memcpy((void*)helper.tablestart, helper.table64, helper.table64size*8);
- }
+ helper.insts_size = 0; // reset
+ native_pass3(&helper, addr, alternate, is32bits);
// keep size of instructions for signal handling
block->instsize = instsize;
// ok, free the helper now
- customFree(helper.insts);
+ dynaFree(helper.insts);
helper.insts = NULL;
- customFree(helper.table64);
helper.table64 = NULL;
helper.instsize = NULL;
- customFree(helper.predecessor);
+ dynaFree(helper.predecessor);
helper.predecessor = NULL;
block->size = sz;
block->isize = helper.size;
- block->actual_block = actual_p;
block->block = p;
block->jmpnext = next+sizeof(void*);
+ block->always_test = helper.always_test;
+ block->dirty = block->always_test;
*(dynablock_t**)next = block;
- *(void**)(next+2*sizeof(void*)) = native_next;
- CreateJmpNext(block->jmpnext, next+2*sizeof(void*));
- block->need_test = 0;
+ *(void**)(next+3*sizeof(void*)) = native_next;
+ CreateJmpNext(block->jmpnext, next+3*sizeof(void*));
//block->x64_addr = (void*)start;
block->x64_size = end-start;
// all done...
__clear_cache(actual_p, actual_p+sz); // need to clear the cache before execution...
block->hash = X31_hash_code(block->x64_addr, block->x64_size);
- // Check if something changed, to abbort if it as
+ // Check if something changed, to abort if it is
if((block->hash != hash)) {
- dynarec_log(LOG_DEBUG, "Warning, a block changed while beeing processed hash(%p:%ld)=%x/%x\n", block->x64_addr, block->x64_size, block->hash, hash);
+ dynarec_log(LOG_DEBUG, "Warning, a block changed while being processed hash(%p:%ld)=%x/%x\n", block->x64_addr, block->x64_size, block->hash, hash);
AddHotPage(addr);
CancelBlock64(0);
return NULL;
}
+ if((oldnativesize!=helper.native_size) || (oldtable64size<helper.table64size)) {
+ printf_log(LOG_NONE, "BOX64: Warning, size difference in block between pass2 (%zu) & pass3 (%zu)!\n", sz, helper.native_size+helper.table64size*8);
+ uint8_t *dump = (uint8_t*)helper.start;
+ printf_log(LOG_NONE, "Dump of %d x64 opcodes:\n", helper.size);
+ for(int i=0; i<helper.size; ++i) {
+ printf_log(LOG_NONE, "%p:", dump);
+ for(; dump<(uint8_t*)helper.insts[i+1].x64.addr; ++dump)
+ printf_log(LOG_NONE, " %02X", *dump);
+ printf_log(LOG_NONE, "\t%d -> %d\n", helper.insts[i].size2, helper.insts[i].size);
+ }
+ printf_log(LOG_NONE, "Table64 \t%d -> %d\n", oldtable64size*8, helper.table64size*8);
+ printf_log(LOG_NONE, " ------------\n");
+ CancelBlock64(0);
+ return NULL;
+ }
+ if(insts_rsize/sizeof(instsize_t)<helper.insts_size) {
+ printf_log(LOG_NONE, "BOX64: Warning, insts_size difference in block between pass2 (%zu) and pass3 (%zu), allocated: %zu\n", oldinstsize, helper.insts_size, insts_rsize/sizeof(instsize_t));
+ }
if(!isprotectedDB(addr, end-addr)) {
- dynarec_log(LOG_DEBUG, "Warning, block unprotected while beeing processed %p:%ld, cancelling\n", block->x64_addr, block->x64_size);
+ dynarec_log(LOG_DEBUG, "Warning, block unprotected while being processed %p:%ld, marking as need_test\n", block->x64_addr, block->x64_size);
AddHotPage(addr);
- block->need_test = 1;
+ block->dirty = 1;
//protectDB(addr, end-addr);
}
current_helper = NULL;
diff --git a/src/dynarec/dynarec_native_functions.c b/src/dynarec/dynarec_native_functions.c
new file mode 100644
index 0000000..7f4ec40
--- /dev/null
+++ b/src/dynarec/dynarec_native_functions.c
@@ -0,0 +1,481 @@
+#define _GNU_SOURCE
+#include <stdio.h>
+#include <stdlib.h>
+#include <errno.h>
+#include <string.h>
+#include <math.h>
+#include <signal.h>
+#include <sys/types.h>
+#include <unistd.h>
+
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "tools/bridge_private.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "emu/x64run_private.h"
+#include "emu/x87emu_private.h"
+#include "x64trace.h"
+#include "signals.h"
+#include "dynarec_native.h"
+#include "custommem.h"
+#include "bridge.h"
+#include "dynarec_native_functions.h"
+
+void native_fstp(x64emu_t* emu, void* p)
+{
+ if(ST0.q!=STld(0).uref)
+ D2LD(&ST0.d, p);
+ else
+ memcpy(p, &STld(0).ld, 10);
+}
+
+void native_print_armreg(x64emu_t* emu, uintptr_t reg, uintptr_t n)
+{
+ (void)emu;
+ dynarec_log(LOG_DEBUG, "R%lu=0x%lx (%lu)\n", n, reg, reg);
+}
+
+void native_f2xm1(x64emu_t* emu)
+{
+ ST0.d = exp2(ST0.d) - 1.0;
+}
+void native_fyl2x(x64emu_t* emu)
+{
+ ST(1).d = log2(ST0.d)*ST(1).d;
+}
+void native_ftan(x64emu_t* emu)
+{
+ ST0.d = tan(ST0.d);
+ emu->sw.f.F87_C2 = 0;
+}
+void native_fpatan(x64emu_t* emu)
+{
+ ST1.d = atan2(ST1.d, ST0.d);
+}
+void native_fxtract(x64emu_t* emu)
+{
+ int32_t tmp32s = (ST1.q&0x7ff0000000000000LL)>>52;
+ tmp32s -= 1023;
+ ST1.d /= exp2(tmp32s);
+ ST0.d = tmp32s;
+}
+void native_fprem(x64emu_t* emu)
+{
+ int32_t tmp32s = ST0.d / ST1.d;
+ ST0.d -= ST1.d * tmp32s;
+ emu->sw.f.F87_C2 = 0;
+ emu->sw.f.F87_C1 = (tmp32s&1);
+ emu->sw.f.F87_C3 = ((tmp32s>>1)&1);
+ emu->sw.f.F87_C0 = ((tmp32s>>2)&1);
+}
+void native_fyl2xp1(x64emu_t* emu)
+{
+ ST(1).d = log2(ST0.d + 1.0)*ST(1).d;
+}
+void native_fsincos(x64emu_t* emu)
+{
+ sincos(ST1.d, &ST1.d, &ST0.d);
+ emu->sw.f.F87_C2 = 0;
+}
+void native_frndint(x64emu_t* emu)
+{
+ ST0.d = fpu_round(emu, ST0.d);
+}
+void native_fscale(x64emu_t* emu)
+{
+ if(ST0.d!=0.0)
+ ST0.d *= exp2(trunc(ST1.d));
+}
+void native_fsin(x64emu_t* emu)
+{
+ ST0.d = sin(ST0.d);
+ emu->sw.f.F87_C2 = 0;
+}
+void native_fcos(x64emu_t* emu)
+{
+ ST0.d = cos(ST0.d);
+ emu->sw.f.F87_C2 = 0;
+}
+
+void native_fbld(x64emu_t* emu, uint8_t* ed)
+{
+ fpu_fbld(emu, ed);
+}
+
+void native_fild64(x64emu_t* emu, int64_t* ed)
+{
+ int64_t tmp;
+ memcpy(&tmp, ed, sizeof(tmp));
+ ST0.d = tmp;
+ STll(0).sq = tmp;
+ STll(0).sref = ST0.sq;
+}
+
+void native_fbstp(x64emu_t* emu, uint8_t* ed)
+{
+ fpu_fbst(emu, ed);
+}
+
+void native_fistp64(x64emu_t* emu, int64_t* ed)
+{
+ // used of memcpy to avoid aligments issues
+ if(STll(0).sref==ST(0).sq) {
+ memcpy(ed, &STll(0).sq, sizeof(int64_t));
+ } else {
+ int64_t tmp;
+ if(isgreater(ST0.d, (double)(int64_t)0x7fffffffffffffffLL) || isless(ST0.d, (double)(int64_t)0x8000000000000000LL) || !isfinite(ST0.d))
+ tmp = 0x8000000000000000LL;
+ else
+ tmp = fpu_round(emu, ST0.d);
+ memcpy(ed, &tmp, sizeof(tmp));
+ }
+}
+
+void native_fistt64(x64emu_t* emu, int64_t* ed)
+{
+ // used of memcpy to avoid alignments issues
+ int64_t tmp = ST0.d;
+ memcpy(ed, &tmp, sizeof(tmp));
+}
+
+void native_fld(x64emu_t* emu, uint8_t* ed)
+{
+ memcpy(&STld(0).ld, ed, 10);
+ LD2D(&STld(0), &ST(0).d);
+ STld(0).uref = ST0.q;
+}
+
+void native_ud(x64emu_t* emu)
+{
+ if(box64_dynarec_test)
+ emu->test.test = 0;
+ emit_signal(emu, SIGILL, (void*)R_RIP, 0);
+}
+
+void native_priv(x64emu_t* emu)
+{
+ emu->test.test = 0;
+ emit_signal(emu, SIGSEGV, (void*)R_RIP, 0);
+}
+
+void native_int(x64emu_t* emu, int num)
+{
+ emu->test.test = 0;
+ emit_interruption(emu, num, (void*)R_RIP);
+}
+
+void native_singlestep(x64emu_t* emu)
+{
+ emit_signal(emu, SIGTRAP, (void*)R_RIP, 1);
+}
+
+void native_fsave(x64emu_t* emu, uint8_t* ed)
+{
+ fpu_savenv(emu, (char*)ed, 0);
+
+ uint8_t* p = ed;
+ p += 28;
+ for (int i=0; i<8; ++i) {
+ LD2D(p, &ST(i).d);
+ p+=10;
+ }
+}
+void native_frstor(x64emu_t* emu, uint8_t* ed)
+{
+ fpu_loadenv(emu, (char*)ed, 0);
+
+ uint8_t* p = ed;
+ p += 28;
+ for (int i=0; i<8; ++i) {
+ D2LD(&ST(i).d, p);
+ p+=10;
+ }
+
+}
+
+void native_fprem1(x64emu_t* emu)
+{
+ // simplified version
+ int32_t tmp32s = round(ST0.d / ST1.d);
+ ST0.d -= ST1.d*tmp32s;
+ emu->sw.f.F87_C2 = 0;
+ emu->sw.f.F87_C1 = (tmp32s&1);
+ emu->sw.f.F87_C3 = ((tmp32s>>1)&1);
+ emu->sw.f.F87_C0 = ((tmp32s>>2)&1);
+}
+
+static uint8_t ff_mult(uint8_t a, uint8_t b)
+{
+ int retval = 0;
+
+ for(int i = 0; i < 8; i++) {
+ if((b & 1) == 1)
+ retval ^= a;
+
+ if((a & 0x80)) {
+ a <<= 1;
+ a ^= 0x1b;
+ } else {
+ a <<= 1;
+ }
+
+ b >>= 1;
+ }
+
+ return retval;
+}
+
+void native_aesimc(x64emu_t* emu, int xmm)
+{
+ sse_regs_t eax1 = emu->xmm[xmm];
+
+ for(int j=0; j<4; ++j) {
+ emu->xmm[xmm].ub[0+j*4] = ff_mult(0x0E, eax1.ub[0+j*4]) ^ ff_mult(0x0B, eax1.ub[1+j*4]) ^ ff_mult(0x0D, eax1.ub[2+j*4]) ^ ff_mult(0x09, eax1.ub[3+j*4]);
+ emu->xmm[xmm].ub[1+j*4] = ff_mult(0x09, eax1.ub[0+j*4]) ^ ff_mult(0x0E, eax1.ub[1+j*4]) ^ ff_mult(0x0B, eax1.ub[2+j*4]) ^ ff_mult(0x0D, eax1.ub[3+j*4]);
+ emu->xmm[xmm].ub[2+j*4] = ff_mult(0x0D, eax1.ub[0+j*4]) ^ ff_mult(0x09, eax1.ub[1+j*4]) ^ ff_mult(0x0E, eax1.ub[2+j*4]) ^ ff_mult(0x0B, eax1.ub[3+j*4]);
+ emu->xmm[xmm].ub[3+j*4] = ff_mult(0x0B, eax1.ub[0+j*4]) ^ ff_mult(0x0D, eax1.ub[1+j*4]) ^ ff_mult(0x09, eax1.ub[2+j*4]) ^ ff_mult(0x0E, eax1.ub[3+j*4]);
+ }
+}
+void native_aesmc(x64emu_t* emu, int xmm)
+{
+ sse_regs_t eax1 = emu->xmm[xmm];
+
+ for(int j=0; j<4; ++j) {
+ emu->xmm[xmm].ub[0+j*4] = ff_mult(0x02, eax1.ub[0+j*4]) ^ ff_mult(0x03, eax1.ub[1+j*4]) ^ eax1.ub[2+j*4] ^ eax1.ub[3+j*4] ;
+ emu->xmm[xmm].ub[1+j*4] = eax1.ub[0+j*4] ^ ff_mult(0x02, eax1.ub[1+j*4]) ^ ff_mult(0x03, eax1.ub[2+j*4]) ^ eax1.ub[3+j*4] ;
+ emu->xmm[xmm].ub[2+j*4] = eax1.ub[0+j*4] ^ eax1.ub[1+j*4] ^ ff_mult(0x02, eax1.ub[2+j*4]) ^ ff_mult(0x03, eax1.ub[3+j*4]);
+ emu->xmm[xmm].ub[3+j*4] = ff_mult(0x03, eax1.ub[0+j*4]) ^ eax1.ub[1+j*4] ^ eax1.ub[2+j*4] ^ ff_mult(0x02, eax1.ub[3+j*4]);
+ }
+}
+void native_aesdlast(x64emu_t* emu, int xmm)
+{
+ // A0 B1 C2 D3 E4 F5 G6 H7 I8 J9 Ka Lb Mc Nd Oe Pf
+ // A N K H E B O L I F C P M J G D
+ const uint8_t invshiftrows[] = {0,13,10, 7, 4, 1,14,11, 8, 5, 2,15,12, 9, 6, 3};
+ const uint8_t invsubbytes[256] = {
+ 0x52, 0x09, 0x6a, 0xd5, 0x30, 0x36, 0xa5, 0x38, 0xbf, 0x40, 0xa3, 0x9e, 0x81, 0xf3, 0xd7, 0xfb,
+ 0x7c, 0xe3, 0x39, 0x82, 0x9b, 0x2f, 0xff, 0x87, 0x34, 0x8e, 0x43, 0x44, 0xc4, 0xde, 0xe9, 0xcb,
+ 0x54, 0x7b, 0x94, 0x32, 0xa6, 0xc2, 0x23, 0x3d, 0xee, 0x4c, 0x95, 0x0b, 0x42, 0xfa, 0xc3, 0x4e,
+ 0x08, 0x2e, 0xa1, 0x66, 0x28, 0xd9, 0x24, 0xb2, 0x76, 0x5b, 0xa2, 0x49, 0x6d, 0x8b, 0xd1, 0x25,
+ 0x72, 0xf8, 0xf6, 0x64, 0x86, 0x68, 0x98, 0x16, 0xd4, 0xa4, 0x5c, 0xcc, 0x5d, 0x65, 0xb6, 0x92,
+ 0x6c, 0x70, 0x48, 0x50, 0xfd, 0xed, 0xb9, 0xda, 0x5e, 0x15, 0x46, 0x57, 0xa7, 0x8d, 0x9d, 0x84,
+ 0x90, 0xd8, 0xab, 0x00, 0x8c, 0xbc, 0xd3, 0x0a, 0xf7, 0xe4, 0x58, 0x05, 0xb8, 0xb3, 0x45, 0x06,
+ 0xd0, 0x2c, 0x1e, 0x8f, 0xca, 0x3f, 0x0f, 0x02, 0xc1, 0xaf, 0xbd, 0x03, 0x01, 0x13, 0x8a, 0x6b,
+ 0x3a, 0x91, 0x11, 0x41, 0x4f, 0x67, 0xdc, 0xea, 0x97, 0xf2, 0xcf, 0xce, 0xf0, 0xb4, 0xe6, 0x73,
+ 0x96, 0xac, 0x74, 0x22, 0xe7, 0xad, 0x35, 0x85, 0xe2, 0xf9, 0x37, 0xe8, 0x1c, 0x75, 0xdf, 0x6e,
+ 0x47, 0xf1, 0x1a, 0x71, 0x1d, 0x29, 0xc5, 0x89, 0x6f, 0xb7, 0x62, 0x0e, 0xaa, 0x18, 0xbe, 0x1b,
+ 0xfc, 0x56, 0x3e, 0x4b, 0xc6, 0xd2, 0x79, 0x20, 0x9a, 0xdb, 0xc0, 0xfe, 0x78, 0xcd, 0x5a, 0xf4,
+ 0x1f, 0xdd, 0xa8, 0x33, 0x88, 0x07, 0xc7, 0x31, 0xb1, 0x12, 0x10, 0x59, 0x27, 0x80, 0xec, 0x5f,
+ 0x60, 0x51, 0x7f, 0xa9, 0x19, 0xb5, 0x4a, 0x0d, 0x2d, 0xe5, 0x7a, 0x9f, 0x93, 0xc9, 0x9c, 0xef,
+ 0xa0, 0xe0, 0x3b, 0x4d, 0xae, 0x2a, 0xf5, 0xb0, 0xc8, 0xeb, 0xbb, 0x3c, 0x83, 0x53, 0x99, 0x61,
+ 0x17, 0x2b, 0x04, 0x7e, 0xba, 0x77, 0xd6, 0x26, 0xe1, 0x69, 0x14, 0x63, 0x55, 0x21, 0x0c, 0x7d,
+ };
+
+ sse_regs_t eax1;
+ for(int i=0; i<16; ++i)
+ eax1.ub[i] = emu->xmm[xmm].ub[invshiftrows[i]];
+ //STATE ← InvSubBytes( STATE );
+ for(int i=0; i<16; ++i)
+ emu->xmm[xmm].ub[i] = invsubbytes[eax1.ub[i]];
+
+}
+static const uint8_t shiftrows[] = {0, 5,10,15, 4, 9,14, 3, 8,13, 2, 7,12, 1, 6,11};
+static const uint8_t subbytes[256] = {
+ 0x63, 0x7c, 0x77, 0x7b, 0xf2, 0x6b, 0x6f, 0xc5, 0x30, 0x01, 0x67, 0x2b, 0xfe, 0xd7, 0xab, 0x76,
+ 0xca, 0x82, 0xc9, 0x7d, 0xfa, 0x59, 0x47, 0xf0, 0xad, 0xd4, 0xa2, 0xaf, 0x9c, 0xa4, 0x72, 0xc0,
+ 0xb7, 0xfd, 0x93, 0x26, 0x36, 0x3f, 0xf7, 0xcc, 0x34, 0xa5, 0xe5, 0xf1, 0x71, 0xd8, 0x31, 0x15,
+ 0x04, 0xc7, 0x23, 0xc3, 0x18, 0x96, 0x05, 0x9a, 0x07, 0x12, 0x80, 0xe2, 0xeb, 0x27, 0xb2, 0x75,
+ 0x09, 0x83, 0x2c, 0x1a, 0x1b, 0x6e, 0x5a, 0xa0, 0x52, 0x3b, 0xd6, 0xb3, 0x29, 0xe3, 0x2f, 0x84,
+ 0x53, 0xd1, 0x00, 0xed, 0x20, 0xfc, 0xb1, 0x5b, 0x6a, 0xcb, 0xbe, 0x39, 0x4a, 0x4c, 0x58, 0xcf,
+ 0xd0, 0xef, 0xaa, 0xfb, 0x43, 0x4d, 0x33, 0x85, 0x45, 0xf9, 0x02, 0x7f, 0x50, 0x3c, 0x9f, 0xa8,
+ 0x51, 0xa3, 0x40, 0x8f, 0x92, 0x9d, 0x38, 0xf5, 0xbc, 0xb6, 0xda, 0x21, 0x10, 0xff, 0xf3, 0xd2,
+ 0xcd, 0x0c, 0x13, 0xec, 0x5f, 0x97, 0x44, 0x17, 0xc4, 0xa7, 0x7e, 0x3d, 0x64, 0x5d, 0x19, 0x73,
+ 0x60, 0x81, 0x4f, 0xdc, 0x22, 0x2a, 0x90, 0x88, 0x46, 0xee, 0xb8, 0x14, 0xde, 0x5e, 0x0b, 0xdb,
+ 0xe0, 0x32, 0x3a, 0x0a, 0x49, 0x06, 0x24, 0x5c, 0xc2, 0xd3, 0xac, 0x62, 0x91, 0x95, 0xe4, 0x79,
+ 0xe7, 0xc8, 0x37, 0x6d, 0x8d, 0xd5, 0x4e, 0xa9, 0x6c, 0x56, 0xf4, 0xea, 0x65, 0x7a, 0xae, 0x08,
+ 0xba, 0x78, 0x25, 0x2e, 0x1c, 0xa6, 0xb4, 0xc6, 0xe8, 0xdd, 0x74, 0x1f, 0x4b, 0xbd, 0x8b, 0x8a,
+ 0x70, 0x3e, 0xb5, 0x66, 0x48, 0x03, 0xf6, 0x0e, 0x61, 0x35, 0x57, 0xb9, 0x86, 0xc1, 0x1d, 0x9e,
+ 0xe1, 0xf8, 0x98, 0x11, 0x69, 0xd9, 0x8e, 0x94, 0x9b, 0x1e, 0x87, 0xe9, 0xce, 0x55, 0x28, 0xdf,
+ 0x8c, 0xa1, 0x89, 0x0d, 0xbf, 0xe6, 0x42, 0x68, 0x41, 0x99, 0x2d, 0x0f, 0xb0, 0x54, 0xbb, 0x16,
+};
+void native_aeselast(x64emu_t* emu, int xmm)
+{
+ // A0 B1 C2 D3 E4 F5 G6 H7 I8 J9 Ka Lb Mc Nd Oe Pf
+ // A F K P E J O D I N C H M B G L
+ sse_regs_t eax1;
+ for(int i=0; i<16; ++i)
+ eax1.ub[i] = emu->xmm[xmm].ub[shiftrows[i]];
+ //STATE ← SubBytes( STATE );
+ for(int i=0; i<16; ++i)
+ emu->xmm[xmm].ub[i] = subbytes[eax1.ub[i]];
+}
+void native_aesd(x64emu_t* emu, int xmm)
+{
+ native_aesdlast(emu, xmm);
+ native_aesimc(emu, xmm);
+}
+void native_aese(x64emu_t* emu, int xmm)
+{
+ native_aeselast(emu, xmm);
+ native_aesmc(emu, xmm);
+}
+void native_aeskeygenassist(x64emu_t* emu, int gx, int ex, void* p, uint32_t u8)
+{
+ sse_regs_t *EX = p?((sse_regs_t*)p):&emu->xmm[ex];
+ sse_regs_t *GX = &emu->xmm[gx];
+ for (int i = 4; i < 8; ++i)
+ GX->ub[i] = subbytes[EX->ub[i]];
+ for (int i = 12; i < 16; ++i)
+ GX->ub[i] = subbytes[EX->ub[i]];
+ GX->ud[0] = GX->ud[1];
+ uint8_t tmp8u = GX->ub[4];
+ GX->ud[1] = GX->ud[1] >> 8;
+ GX->ub[7] = tmp8u;
+ GX->ud[1] ^= u8;
+ GX->ud[2] = GX->ud[3];
+ tmp8u = GX->ub[12];
+ GX->ud[3] = GX->ud[3] >> 8;
+ GX->ub[15] = tmp8u;
+ GX->ud[3] ^= u8;
+}
+
+void native_pclmul(x64emu_t* emu, int gx, int ex, void* p, uint32_t u8)
+{
+ sse_regs_t *EX = p?((sse_regs_t*)p):&emu->xmm[ex];
+ sse_regs_t *GX = &emu->xmm[gx];
+ int g = (u8&1)?1:0;
+ int e = (u8&0b10000)?1:0;
+ __int128 result = 0;
+ __int128 op2 = EX->q[e];
+ for (int i=0; i<64; ++i)
+ if(GX->q[g]&(1LL<<i))
+ result ^= (op2<<i);
+
+ GX->q[0] = result&0xffffffffffffffffLL;
+ GX->q[1] = (result>>64)&0xffffffffffffffffLL;
+}
+
+void native_clflush(x64emu_t* emu, void* p)
+{
+ cleanDBFromAddressRange((uintptr_t)p, 8, 0);
+}
+
+static int flagsCacheNeedsTransform(dynarec_native_t* dyn, int ninst) {
+ int jmp = dyn->insts[ninst].x64.jmp_insts;
+ if(jmp<0)
+ return 0;
+ if(dyn->insts[ninst].f_exit.dfnone) // flags are fully known, nothing we can do more
+ return 0;
+/* if((dyn->f.pending!=SF_SET)
+ && (dyn->f.pending!=SF_SET_PENDING)) {
+ if(dyn->f.pending!=SF_PENDING) {*/
+ switch (dyn->insts[jmp].f_entry.pending) {
+ case SF_UNKNOWN: return 0;
+ case SF_SET:
+ if(dyn->insts[ninst].f_exit.pending!=SF_SET && dyn->insts[ninst].f_exit.pending!=SF_SET_PENDING)
+ return 1;
+ else
+ return 0;
+ case SF_SET_PENDING:
+ if(dyn->insts[ninst].f_exit.pending!=SF_SET
+ && dyn->insts[ninst].f_exit.pending!=SF_SET_PENDING
+ && dyn->insts[ninst].f_exit.pending!=SF_PENDING)
+ return 1;
+ else
+ return 0;
+ case SF_PENDING:
+ if(dyn->insts[ninst].f_exit.pending!=SF_SET
+ && dyn->insts[ninst].f_exit.pending!=SF_SET_PENDING
+ && dyn->insts[ninst].f_exit.pending!=SF_PENDING)
+ return 1;
+ else
+ return (dyn->insts[jmp].f_entry.dfnone == dyn->insts[ninst].f_exit.dfnone)?0:1;
+ }
+ if(dyn->insts[jmp].f_entry.dfnone && !dyn->insts[ninst].f_exit.dfnone)
+ return 1;
+ return 0;
+}
+
+int CacheNeedsTransform(dynarec_native_t* dyn, int ninst) {
+ int ret = 0;
+ if (flagsCacheNeedsTransform(dyn, ninst)) ret|=1;
+ OTHER_CACHE()
+ return ret;
+}
+
+int isPred(dynarec_native_t* dyn, int ninst, int pred) {
+ for(int i=0; i<dyn->insts[ninst].pred_sz; ++i)
+ if(dyn->insts[ninst].pred[i]==pred)
+ return pred;
+ return -1;
+}
+int getNominalPred(dynarec_native_t* dyn, int ninst) {
+ if((ninst<=0) || !dyn->insts[ninst].pred_sz)
+ return -1;
+ if(isPred(dyn, ninst, ninst-1)!=-1)
+ return ninst-1;
+ return dyn->insts[ninst].pred[0];
+}
+
+#define F8 *(uint8_t*)(addr++)
+// Do the GETED, but don't emit anything...
+uintptr_t fakeed(dynarec_native_t* dyn, uintptr_t addr, int ninst, uint8_t nextop)
+{
+ (void)dyn; (void)addr; (void)ninst;
+
+ if((nextop&0xC0)==0xC0)
+ return addr;
+ if(!(nextop&0xC0)) {
+ if((nextop&7)==4) {
+ uint8_t sib = F8;
+ if((sib&0x7)==5) {
+ addr+=4;
+ }
+ } else if((nextop&7)==5) {
+ addr+=4;
+ }
+ } else {
+ if((nextop&7)==4) {
+ ++addr;
+ }
+ if(nextop&0x80) {
+ addr+=4;
+ } else {
+ ++addr;
+ }
+ }
+ return addr;
+}
+#undef F8
+
+int isNativeCall(dynarec_native_t* dyn, uintptr_t addr, uintptr_t* calladdress, int* retn)
+{
+ (void)dyn;
+
+#define PK(a) *(uint8_t*)(addr+a)
+#define PK32(a) *(int32_t*)(addr+a)
+
+ if(!addr || !getProtection(addr))
+ return 0;
+ if(PK(0)==0xff && PK(1)==0x25) { // "absolute" jump, maybe the GOT (well, RIP relative in fact)
+ uintptr_t a1 = addr + 6 + (PK32(2)); // need to add a check to see if the address is from the GOT !
+ addr = (uintptr_t)getAlternate(*(void**)a1);
+ }
+ if(!addr || !getProtection(addr))
+ return 0;
+ onebridge_t *b = (onebridge_t*)(addr);
+ if(b->CC==0xCC && b->S=='S' && b->C=='C' && b->w!=(wrapper_t)0 && b->f!=(uintptr_t)PltResolver) {
+ // found !
+ if(retn) *retn = (b->C3==0xC2)?b->N:0;
+ if(calladdress) *calladdress = addr+1;
+ return 1;
+ }
+ return 0;
+#undef PK32
+#undef PK
+}
diff --git a/src/dynarec/dynarec_native_functions.h b/src/dynarec/dynarec_native_functions.h
new file mode 100644
index 0000000..ed6d0f7
--- /dev/null
+++ b/src/dynarec/dynarec_native_functions.h
@@ -0,0 +1,66 @@
+#ifndef __DYNAREC_NATIVE_FUNCTIONS_H__
+#define __DYNAREC_NATIVE_FUNCTIONS_H__
+
+#include <stdint.h>
+
+#include "dynarec_arch.h"
+
+typedef struct x64emu_s x64emu_t;
+
+void native_fstp(x64emu_t* emu, void* p);
+
+void native_print_armreg(x64emu_t* emu, uintptr_t reg, uintptr_t n);
+
+void native_f2xm1(x64emu_t* emu);
+void native_fyl2x(x64emu_t* emu);
+void native_ftan(x64emu_t* emu);
+void native_fpatan(x64emu_t* emu);
+void native_fxtract(x64emu_t* emu);
+void native_fprem(x64emu_t* emu);
+void native_fyl2xp1(x64emu_t* emu);
+void native_fsincos(x64emu_t* emu);
+void native_frndint(x64emu_t* emu);
+void native_fscale(x64emu_t* emu);
+void native_fsin(x64emu_t* emu);
+void native_fcos(x64emu_t* emu);
+void native_fbld(x64emu_t* emu, uint8_t* ed);
+void native_fild64(x64emu_t* emu, int64_t* ed);
+void native_fbstp(x64emu_t* emu, uint8_t* ed);
+void native_fistp64(x64emu_t* emu, int64_t* ed);
+void native_fistt64(x64emu_t* emu, int64_t* ed);
+void native_fld(x64emu_t* emu, uint8_t* ed);
+void native_fsave(x64emu_t* emu, uint8_t* ed);
+void native_frstor(x64emu_t* emu, uint8_t* ed);
+void native_fprem1(x64emu_t* emu);
+
+void native_aesd(x64emu_t* emu, int xmm);
+void native_aese(x64emu_t* emu, int xmm);
+void native_aesdlast(x64emu_t* emu, int xmm);
+void native_aeselast(x64emu_t* emu, int xmm);
+void native_aesimc(x64emu_t* emu, int xmm);
+void native_aeskeygenassist(x64emu_t* emu, int gx, int ex, void* p, uint32_t u8);
+void native_pclmul(x64emu_t* emu, int gx, int ex, void* p, uint32_t u8);
+
+void native_clflush(x64emu_t* emu, void* p);
+
+void native_ud(x64emu_t* emu);
+void native_priv(x64emu_t* emu);
+void native_singlestep(x64emu_t* emu);
+void native_int(x64emu_t* emu, int num);
+
+// Caches transformation (for loops) // Specific, need to be written par backend
+int CacheNeedsTransform(dynarec_native_t* dyn, int i1);
+
+// predecessor access
+int isPred(dynarec_native_t* dyn, int ninst, int pred);
+int getNominalPred(dynarec_native_t* dyn, int ninst);
+
+// Do the GETED, but don't emit anything...
+uintptr_t fakeed(dynarec_native_t* dyn, uintptr_t addr, int ninst, uint8_t nextop);
+
+// Is what pointed at addr a native call? And if yes, to what function?
+int isNativeCall(dynarec_native_t* dyn, uintptr_t addr, uintptr_t* calladdress, int* retn);
+
+ADDITIONNAL_DEFINITION()
+
+#endif //__DYNAREC_NATIVE_FUNCTIONS_H__
diff --git a/src/dynarec/dynarec_native_pass.c b/src/dynarec/dynarec_native_pass.c
index ca8da16..f5ee250 100755..100644
--- a/src/dynarec/dynarec_native_pass.c
+++ b/src/dynarec/dynarec_native_pass.c
@@ -1,7 +1,6 @@
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
-#include <pthread.h>
#include <errno.h>
#include <string.h>
@@ -27,7 +26,7 @@
#error No STEP defined
#endif
-uintptr_t native_pass(dynarec_native_t* dyn, uintptr_t addr)
+uintptr_t native_pass(dynarec_native_t* dyn, uintptr_t addr, int alternate, int is32bits)
{
int ok = 1;
int ninst = 0;
@@ -45,9 +44,10 @@ uintptr_t native_pass(dynarec_native_t* dyn, uintptr_t addr)
dyn->forward_size = 0;
dyn->forward_ninst = 0;
fpu_reset(dyn);
+ ARCH_INIT();
int reset_n = -1;
- dyn->last_ip = (dyn->insts && dyn->insts[0].pred_sz)?0:ip; // RIP is always set at start of block unless there is a predecessor!
- int stopblock = 2+(FindElfAddress(my_context, addr)?0:1); // if block is in elf_memory, it can be extended with bligblocks==2, else it needs 3
+ dyn->last_ip = (alternate || (dyn->insts && dyn->insts[0].pred_sz))?0:ip; // RIP is always set at start of block unless there is a predecessor!
+ int stopblock = 2+(FindElfAddress(my_context, addr)?0:1); // if block is in elf_memory, it can be extended with box64_dynarec_bigblock==2, else it needs 3
// ok, go now
INIT;
while(ok) {
@@ -60,44 +60,7 @@ uintptr_t native_pass(dynarec_native_t* dyn, uintptr_t addr)
dyn->f.pending = 0;
fpu_reset(dyn);
} else {
- MESSAGE(LOG_DEBUG, "Reset Caches with %d\n",reset_n);
- #if STEP > 1
- // for STEP 2 & 3, just need to refrest with current, and undo the changes (push & swap)
- dyn->n = dyn->insts[ninst].n;
- neoncacheUnwind(&dyn->n);
- #ifdef HAVE_TRACE
- if(box64_dynarec_dump)
- if(memcmp(&dyn->n, &dyn->insts[reset_n].n, sizeof(neon_cache_t))) {
- MESSAGE(LOG_DEBUG, "Warning, difference in neoncache: reset=");
- for(int i=0; i<24; ++i)
- if(dyn->insts[reset_n].n.neoncache[i].v)
- MESSAGE(LOG_DEBUG, " %02d:%s", i, getCacheName(dyn->insts[reset_n].n.neoncache[i].t, dyn->insts[reset_n].n.neoncache[i].n));
- if(dyn->insts[reset_n].n.combined1 || dyn->insts[reset_n].n.combined2)
- MESSAGE(LOG_DEBUG, " %s:%02d/%02d", dyn->insts[reset_n].n.swapped?"SWP":"CMB", dyn->insts[reset_n].n.combined1, dyn->insts[reset_n].n.combined2);
- if(dyn->insts[reset_n].n.stack_push || dyn->insts[reset_n].n.stack_pop)
- MESSAGE(LOG_DEBUG, " (%d:%d)", dyn->insts[reset_n].n.stack_push, -dyn->insts[reset_n].n.stack_pop);
- MESSAGE(LOG_DEBUG, " ==> ");
- for(int i=0; i<24; ++i)
- if(dyn->insts[ninst].n.neoncache[i].v)
- MESSAGE(LOG_DEBUG, " %02d:%s", i, getCacheName(dyn->insts[ninst].n.neoncache[i].t, dyn->insts[ninst].n.neoncache[i].n));
- if(dyn->insts[ninst].n.combined1 || dyn->insts[ninst].n.combined2)
- MESSAGE(LOG_DEBUG, " %s:%02d/%02d", dyn->insts[ninst].n.swapped?"SWP":"CMB", dyn->insts[ninst].n.combined1, dyn->insts[ninst].n.combined2);
- if(dyn->insts[ninst].n.stack_push || dyn->insts[ninst].n.stack_pop)
- MESSAGE(LOG_DEBUG, " (%d:%d)", dyn->insts[ninst].n.stack_push, -dyn->insts[ninst].n.stack_pop);
- MESSAGE(LOG_DEBUG, " -> ");
- for(int i=0; i<24; ++i)
- if(dyn->n.neoncache[i].v)
- MESSAGE(LOG_DEBUG, " %02d:%s", i, getCacheName(dyn->n.neoncache[i].t, dyn->n.neoncache[i].n));
- if(dyn->n.combined1 || dyn->n.combined2)
- MESSAGE(LOG_DEBUG, " %s:%02d/%02d", dyn->n.swapped?"SWP":"CMB", dyn->n.combined1, dyn->n.combined2);
- if(dyn->n.stack_push || dyn->n.stack_pop)
- MESSAGE(LOG_DEBUG, " (%d:%d)", dyn->n.stack_push, -dyn->n.stack_pop);
- MESSAGE(LOG_DEBUG, "\n");
- }
- #endif //HAVE_TRACE
- #else
- dyn->n = dyn->insts[reset_n].n;
- #endif
+ fpu_reset_cache(dyn, ninst, reset_n);
dyn->f = dyn->insts[reset_n].f_exit;
if(dyn->insts[ninst].x64.barrier&BARRIER_FLOAT) {
MESSAGE(LOG_DEBUG, "Apply Barrier Float\n");
@@ -110,36 +73,33 @@ uintptr_t native_pass(dynarec_native_t* dyn, uintptr_t addr)
}
}
reset_n = -1;
- } else if(ninst && (dyn->insts[ninst].pred_sz!=1 || dyn->insts[ninst].pred[0]!=ninst-1))
- dyn->last_ip = 0; // reset IP if some jump are comming here
- // propagate ST stack state, especial stack pop that are defered
- if(dyn->n.stack_pop) {
- for(int j=0; j<24; ++j)
- if((dyn->n.neoncache[j].t == NEON_CACHE_ST_D || dyn->n.neoncache[j].t == NEON_CACHE_ST_F)) {
- if(dyn->n.neoncache[j].n<dyn->n.stack_pop)
- dyn->n.neoncache[j].v = 0;
- else
- dyn->n.neoncache[j].n-=dyn->n.stack_pop;
- }
- dyn->n.stack_pop = 0;
- }
- dyn->n.stack = dyn->n.stack_next;
- dyn->n.news = 0;
- dyn->n.stack_push = 0;
- dyn->n.swapped = 0;
+ } else if(ninst && (dyn->insts[ninst].pred_sz>1 || (dyn->insts[ninst].pred_sz==1 && dyn->insts[ninst].pred[0]!=ninst-1)))
+ dyn->last_ip = 0; // reset IP if some jump are coming here
+ fpu_propagate_stack(dyn, ninst);
NEW_INST;
+ if(!ninst) {
+ GOTEST(x1, x2);
+ }
if(dyn->insts[ninst].pred_sz>1) {SMSTART();}
fpu_reset_scratch(dyn);
if((dyn->insts[ninst].x64.need_before&~X_PEND) && !dyn->insts[ninst].pred_sz) {
READFLAGS(dyn->insts[ninst].x64.need_before&~X_PEND);
}
+ if(box64_dynarec_test) {
+ MESSAGE(LOG_DUMP, "TEST INIT ----\n");
+ fpu_reflectcache(dyn, ninst, x1, x2, x3);
+ GO_TRACE(x64test_init, 1);
+ fpu_unreflectcache(dyn, ninst, x1, x2, x3);
+ MESSAGE(LOG_DUMP, "----------\n");
+ }
#ifdef HAVE_TRACE
- if(my_context->dec && box64_dynarec_trace) {
+ else if(my_context->dec && box64_dynarec_trace) {
if((trace_end == 0)
|| ((ip >= trace_start) && (ip < trace_end))) {
MESSAGE(LOG_DUMP, "TRACE ----\n");
fpu_reflectcache(dyn, ninst, x1, x2, x3);
- GO_TRACE();
+ GO_TRACE(PrintTrace, 1);
+ fpu_unreflectcache(dyn, ninst, x1, x2, x3);
MESSAGE(LOG_DUMP, "----------\n");
}
}
@@ -157,11 +117,13 @@ uintptr_t native_pass(dynarec_native_t* dyn, uintptr_t addr)
pk = PK(0);
}
rex.rex = 0;
- while(pk>=0x40 && pk<=0x4f) {
- rex.rex = pk;
- ++addr;
- pk = PK(0);
- }
+ rex.is32bits = is32bits;
+ if(!rex.is32bits)
+ while(pk>=0x40 && pk<=0x4f) {
+ rex.rex = pk;
+ ++addr;
+ pk = PK(0);
+ }
addr = dynarec64_00(dyn, addr, ip, ninst, rex, rep, &ok, &need_epilog);
@@ -189,12 +151,22 @@ uintptr_t native_pass(dynarec_native_t* dyn, uintptr_t addr)
ok = 1;
// we use the 1st predecessor here
int ii = ninst+1;
- while(ii<dyn->size && !dyn->insts[ii].pred_sz)
- ++ii;
+ if(ii<dyn->size && !dyn->insts[ii].pred_sz) {
+ while(ii<dyn->size && (!dyn->insts[ii].pred_sz || (dyn->insts[ii].pred_sz==1 && dyn->insts[ii].pred[0]==ii-1))) {
+ // may need to skip opcodes to advance
+ ++ninst;
+ NEW_INST;
+ MESSAGE(LOG_DEBUG, "Skipping unused opcode\n");
+ INST_NAME("Skipped opcode");
+ INST_EPILOG;
+ addr += dyn->insts[ii].x64.size;
+ ++ii;
+ }
+ }
if((dyn->insts[ii].x64.barrier&BARRIER_FULL)==BARRIER_FULL)
reset_n = -2; // hack to say Barrier!
else {
- reset_n = getNominalPred(dyn, ii); // may get -1 if no predecessor are availble
+ reset_n = getNominalPred(dyn, ii); // may get -1 if no predecessor are available
if(reset_n==-1) {
reset_n = -2;
MESSAGE(LOG_DEBUG, "Warning, Reset Caches mark not found\n");
@@ -211,7 +183,7 @@ uintptr_t native_pass(dynarec_native_t* dyn, uintptr_t addr)
dyn->forward_size = 0;
dyn->forward_ninst = 0;
ok = 1; // in case it was 0
- } else if ((dyn->forward_to < addr) || !ok) {
+ } else if ((dyn->forward_to < addr) || ok<=0) {
// something when wrong! rollback
if(box64_dynarec_dump) dynarec_log(LOG_NONE, "Could not forward extend block for %d bytes %p -> %p\n", dyn->forward_to-dyn->forward, (void*)dyn->forward, (void*)dyn->forward_to);
ok = 0;
@@ -241,16 +213,47 @@ uintptr_t native_pass(dynarec_native_t* dyn, uintptr_t addr)
}
if(box64_dynarec_dump) dynarec_log(LOG_NONE, "Extend block %p, %p -> %p (ninst=%d, jump from %d)\n", dyn, (void*)addr, (void*)next, ninst, reset_n);
} else if(next && (next-addr)<box64_dynarec_forward && (getProtection(next)&PROT_READ)/*box64_dynarec_bigblock>=stopblock*/) {
- dyn->forward = addr;
- dyn->forward_to = next;
- dyn->forward_size = dyn->size;
- dyn->forward_ninst = ninst;
- reset_n = -2;
- ok = 1;
+ if(!((box64_dynarec_bigblock<stopblock) && !isJumpTableDefault64((void*)next))) {
+ if(dyn->forward) {
+ if(next<dyn->forward_to)
+ dyn->forward_to = next;
+ reset_n = -2;
+ ok = 1;
+ } else {
+ dyn->forward = addr;
+ dyn->forward_to = next;
+ dyn->forward_size = dyn->size;
+ dyn->forward_ninst = ninst;
+ reset_n = -2;
+ ok = 1;
+ }
+ }
}
}
#endif
- if(ok<0) {ok = 0; need_epilog=1;}
+ if(ok<0) {
+ ok = 0; need_epilog=1;
+ #if STEP == 0
+ if(ninst) {
+ --ninst;
+ if(!dyn->insts[ninst].x64.barrier) {
+ BARRIER(BARRIER_FLOAT);
+ }
+ dyn->insts[ninst].x64.need_after |= X_PEND;
+ ++ninst;
+ }
+ if(dyn->forward) {
+ // stopping too soon
+ dyn->size = dyn->forward_size;
+ ninst = dyn->forward_ninst+1;
+ addr = dyn->forward;
+ dyn->forward = 0;
+ dyn->forward_to = 0;
+ dyn->forward_size = 0;
+ dyn->forward_ninst = 0;
+ }
+ #endif
+ }
++ninst;
#if STEP == 0
if(ok && (((box64_dynarec_bigblock<stopblock) && !isJumpTableDefault64((void*)addr))
@@ -259,6 +262,18 @@ uintptr_t native_pass(dynarec_native_t* dyn, uintptr_t addr)
if(ok && (ninst==dyn->size))
#endif
{
+ #if STEP == 0
+ if(dyn->forward) {
+ // stopping too soon
+ dyn->size = dyn->forward_size;
+ ninst = dyn->forward_ninst+1;
+ addr = dyn->forward;
+ dyn->forward = 0;
+ dyn->forward_to = 0;
+ dyn->forward_size = 0;
+ dyn->forward_ninst = 0;
+ }
+ #endif
int j32;
MAYUSE(j32);
MESSAGE(LOG_DEBUG, "Stopping block %p (%d / %d)\n",(void*)init_addr, ninst, dyn->size);
@@ -272,14 +287,16 @@ uintptr_t native_pass(dynarec_native_t* dyn, uintptr_t addr)
dyn->insts[ninst].x64.need_after |= X_PEND;
#endif
++ninst;
+ NOTEST(x3);
fpu_purgecache(dyn, ninst, 0, x1, x2, x3);
jump_to_next(dyn, addr, 0, ninst);
ok=0; need_epilog=0;
}
}
if(need_epilog) {
+ NOTEST(x3);
fpu_purgecache(dyn, ninst, 0, x1, x2, x3);
- jump_to_epilog(dyn, ip, 0, ninst); // no linker here, it's an unknow instruction
+ jump_to_epilog(dyn, ip, 0, ninst); // no linker here, it's an unknown instruction
}
FINI;
MESSAGE(LOG_DUMP, "---- END OF BLOCK ---- (%d)\n", dyn->size);
diff --git a/src/dynarec/dynarec_next.h b/src/dynarec/dynarec_next.h
index 19d426b..dc37aad 100644
--- a/src/dynarec/dynarec_next.h
+++ b/src/dynarec/dynarec_next.h
@@ -4,17 +4,24 @@
#ifdef ARM64
void arm64_next(void) EXPORTDYN;
void arm64_prolog(x64emu_t* emu, void* addr) EXPORTDYN;
-void arm64_epilog() EXPORTDYN;
+void arm64_epilog(void) EXPORTDYN;
#define native_next arm64_next
#define native_prolog arm64_prolog
#define native_epilog arm64_epilog
#elif defined(LA464)
void la464_next(void) EXPORTDYN;
void la464_prolog(x64emu_t* emu, void* addr) EXPORTDYN;
-void la464_epilog() EXPORTDYN;
+void la464_epilog(void) EXPORTDYN;
#define native_next la464_next
#define native_prolog la464_prolog
#define native_epilog la464_epilog
+#elif defined(RV64)
+void rv64_next(void) EXPORTDYN;
+void rv64_prolog(x64emu_t* emu, void* addr) EXPORTDYN;
+void rv64_epilog(void) EXPORTDYN;
+#define native_next rv64_next
+#define native_prolog rv64_prolog
+#define native_epilog rv64_epilog
#else
#error Unsupported architecture
#endif
diff --git a/src/dynarec/dynarec_private.h b/src/dynarec/dynarec_private.h
index 0ab21df..0ab21df 100755..100644
--- a/src/dynarec/dynarec_private.h
+++ b/src/dynarec/dynarec_private.h
diff --git a/src/dynarec/native_lock.h b/src/dynarec/native_lock.h
index 32cf56f..dd2f3b6 100755..100644
--- a/src/dynarec/native_lock.h
+++ b/src/dynarec/native_lock.h
@@ -14,8 +14,10 @@
#define native_lock_write_dd(A, B) arm64_lock_write_dd(A, B)
#define native_lock_read_dq(A, B, C) arm64_lock_read_dq(A, B, C)
#define native_lock_write_dq(A, B, C) arm64_lock_write_dq(A, B, C)
-#define native_lock_xchg(A, B) arm64_lock_xchg(A, B)
+#define native_lock_xchg_dd(A, B) arm64_lock_xchg_dd(A, B)
#define native_lock_xchg_d(A, B) arm64_lock_xchg_d(A, B)
+#define native_lock_xchg_h(A, B) arm64_lock_xchg_h(A, B)
+#define native_lock_xchg_b(A, B) arm64_lock_xchg_b(A, B)
#define native_lock_storeifref(A, B, C) arm64_lock_storeifref(A, B, C)
#define native_lock_storeifref_d(A, B, C) arm64_lock_storeifref_d(A, B, C)
#define native_lock_storeifref2_d(A, B, C) arm64_lock_storeifref2_d(A, B, C)
@@ -27,6 +29,46 @@
#define native_lock_decifnot0(A) arm64_lock_decifnot0(A)
#define native_lock_store(A, B) arm64_lock_store(A, B)
+#elif defined(RV64)
+#include "rv64/rv64_lock.h"
+
+#define USE_CAS
+// RV64 is quite strict (or at least strongly recommand) on what you can do between an LD.A and an SD.A
+// That basicaly forbid to call a function, so there cannot be READ / WRITE separated
+// And so need to use a Compare and Swap mecanism instead
+
+// no byte or 2-bytes atomic access on RISC-V
+#define native_lock_xchg_dd(A, B) rv64_lock_xchg_dd(A, B)
+#define native_lock_xchg_d(A, B) rv64_lock_xchg_d(A, B)
+#define native_lock_storeifref(A, B, C) rv64_lock_storeifref(A, B, C)
+#define native_lock_storeifref_d(A, B, C) rv64_lock_storeifref_d(A, B, C)
+#define native_lock_storeifref2_d(A, B, C) rv64_lock_storeifref2_d(A, B, C)
+#define native_lock_storeifnull(A, B) rv64_lock_storeifnull(A, B)
+#define native_lock_storeifnull_d(A, B) rv64_lock_storeifnull_d(A, B)
+#define native_lock_decifnot0b(A) rv64_lock_decifnot0b(A)
+#define native_lock_storeb(A, B) rv64_lock_storeb(A, B)
+#define native_lock_incif0(A) rv64_lock_incif0(A)
+#define native_lock_decifnot0(A) rv64_lock_decifnot0(A)
+#define native_lock_store(A, B) rv64_lock_store(A, B)
+#define native_lock_cas_d(A, B, C) rv64_lock_cas_d(A, B, C)
+#define native_lock_cas_dd(A, B, C) rv64_lock_cas_dd(A, B, C)
+
+#define native_lock_xchg_b(A, B) rv64_lock_xchg_b(A, B)
+#define native_lock_cas_b(A, B, C) rv64_lock_cas_b(A, B, C)
+#define native_lock_cas_h(A, B, C) rv64_lock_cas_h(A, B, C)
+
+#define native_lock_read_b(A) tmpcas=*(uint8_t*)(A)
+#define native_lock_write_b(A, B) rv64_lock_cas_b(A, tmpcas, B)
+#define native_lock_read_h(A) tmpcas=*(uint16_t*)(A)
+#define native_lock_write_h(A, B) rv64_lock_cas_h(A, tmpcas, B)
+#define native_lock_read_d(A) tmpcas=*(uint32_t*)(A)
+#define native_lock_write_d(A, B) rv64_lock_cas_d(A, tmpcas, B)
+#define native_lock_read_dd(A) tmpcas=*(uint64_t*)(A)
+#define native_lock_write_dd(A, B) rv64_lock_cas_dd(A, tmpcas, B)
+// there is no atomic move on 16bytes, so faking it
+#define native_lock_read_dq(A, B, C) *A=tmpcas=((uint64_t*)(C))[0]; *B=((uint64_t*)(C))[1];
+#define native_lock_write_dq(A, B, C) rv64_lock_cas_dq(C, A, tmpcas, B);
+
#else
#error Unsupported architecture
#endif
diff --git a/src/dynarec/rv64/dynarec_rv64_00.c b/src/dynarec/rv64/dynarec_rv64_00.c
new file mode 100644
index 0000000..5f529fb
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_00.c
@@ -0,0 +1,41 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <stddef.h>
+#include <errno.h>
+#include <signal.h>
+#include <assert.h>
+
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "emu/x64run_private.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "bridge.h"
+#include "emu/x64run_private.h"
+#include "x64trace.h"
+#include "dynarec_native.h"
+#include "custommem.h"
+
+#include "rv64_printer.h"
+#include "dynarec_rv64_private.h"
+#include "dynarec_rv64_functions.h"
+#include "dynarec_rv64_helper.h"
+
+uintptr_t dynarec64_00(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog)
+{
+ uint8_t opcode;
+
+ opcode = PK(0);
+ switch(opcode) {
+ case 0x00 ... 0x3f: addr = dynarec64_00_0(dyn, addr, ip, ninst, rex, rep, ok, need_epilog); break;
+ case 0x40 ... 0x7f: addr = dynarec64_00_1(dyn, addr, ip, ninst, rex, rep, ok, need_epilog); break;
+ case 0x80 ... 0xbf: addr = dynarec64_00_2(dyn, addr, ip, ninst, rex, rep, ok, need_epilog); break;
+ case 0xc0 ... 0xff: addr = dynarec64_00_3(dyn, addr, ip, ninst, rex, rep, ok, need_epilog); break;
+ }
+
+ return addr;
+}
diff --git a/src/dynarec/rv64/dynarec_rv64_00_0.c b/src/dynarec/rv64/dynarec_rv64_00_0.c
new file mode 100644
index 0000000..4971849
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_00_0.c
@@ -0,0 +1,497 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <stddef.h>
+#include <errno.h>
+#include <signal.h>
+#include <assert.h>
+
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "emu/x64run_private.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "bridge.h"
+#include "emu/x64run_private.h"
+#include "x64trace.h"
+#include "dynarec_native.h"
+#include "custommem.h"
+
+#include "rv64_printer.h"
+#include "dynarec_rv64_private.h"
+#include "dynarec_rv64_functions.h"
+#include "dynarec_rv64_helper.h"
+
+uintptr_t dynarec64_00_0(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog)
+{
+ uint8_t nextop, opcode;
+ uint8_t gd, ed;
+ int8_t i8;
+ int32_t i32, tmp;
+ int64_t i64, j64;
+ uint8_t u8;
+ uint8_t gb1, gb2, eb1, eb2;
+ uint32_t u32;
+ uint64_t u64;
+ uint8_t wback, wb1, wb2, wb;
+ int64_t fixedaddress;
+ int lock;
+ int cacheupd = 0;
+
+ opcode = F8;
+ MAYUSE(eb1);
+ MAYUSE(eb2);
+ MAYUSE(j64);
+ MAYUSE(wb);
+ MAYUSE(lock);
+ MAYUSE(cacheupd);
+
+ switch(opcode) {
+ case 0x00:
+ INST_NAME("ADD Eb, Gb");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETEB(x1, 0);
+ GETGB(x2);
+ emit_add8(dyn, ninst, x1, x2, x4, x5);
+ EBBACK(x5, 0);
+ break;
+ case 0x01:
+ INST_NAME("ADD Ed, Gd");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED(0);
+ emit_add32(dyn, ninst, rex, ed, gd, x3, x4, x5);
+ WBACK;
+ break;
+ case 0x02:
+ INST_NAME("ADD Gb, Eb");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETEB(x1, 0);
+ GETGB(x2);
+ emit_add8(dyn, ninst, x2, x1, x4, x5);
+ GBBACK(x5);
+ break;
+ case 0x03:
+ INST_NAME("ADD Gd, Ed");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED(0);
+ emit_add32(dyn, ninst, rex, gd, ed, x3, x4, x5);
+ break;
+ case 0x04:
+ INST_NAME("ADD AL, Ib");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ u8 = F8;
+ ANDI(x1, xRAX, 0xff);
+ emit_add8c(dyn, ninst, x1, u8, x3, x4, x5);
+ ANDI(xRAX, xRAX, ~0xff);
+ OR(xRAX, xRAX, x1);
+ break;
+ case 0x05:
+ INST_NAME("ADD EAX, Id");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ i64 = F32S;
+ emit_add32c(dyn, ninst, rex, xRAX, i64, x3, x4, x5, x6);
+ break;
+ case 0x08:
+ INST_NAME("OR Eb, Gb");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETEB(x1, 0);
+ GETGB(x2);
+ emit_or8(dyn, ninst, x1, x2, x4, x5);
+ EBBACK(x5, 0);
+ break;
+ case 0x09:
+ INST_NAME("OR Ed, Gd");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED(0);
+ emit_or32(dyn, ninst, rex, ed, gd, x3, x4);
+ WBACK;
+ break;
+
+ case 0x0A:
+ INST_NAME("OR Gb, Eb");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETEB(x1, 0);
+ GETGB(x2);
+ emit_or8(dyn, ninst, x2, x1, x4, x5);
+ GBBACK(x5);
+ break;
+ case 0x0B:
+ INST_NAME("OR Gd, Ed");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED(0);
+ emit_or32(dyn, ninst, rex, gd, ed, x3, x4);
+ break;
+ case 0x0C:
+ INST_NAME("OR AL, Ib");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ u8 = F8;
+ ANDI(x1, xRAX, 0xff);
+ emit_or8c(dyn, ninst, x1, u8, x3, x4, x5);
+ ANDI(xRAX, xRAX, ~0xff);
+ OR(xRAX, xRAX, x1);
+ break;
+ case 0x0D:
+ INST_NAME("OR EAX, Id");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ i64 = F32S;
+ emit_or32c(dyn, ninst, rex, xRAX, i64, x3, x4);
+ break;
+
+ case 0x0F:
+ switch(rep) {
+ case 0:
+ addr = dynarec64_0F(dyn, addr, ip, ninst, rex, ok, need_epilog);
+ break;
+ case 1:
+ addr = dynarec64_F20F(dyn, addr, ip, ninst, rex, ok, need_epilog);
+ break;
+ case 2:
+ addr = dynarec64_F30F(dyn, addr, ip, ninst, rex, ok, need_epilog);
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+ case 0x10:
+ INST_NAME("ADC Eb, Gb");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETEB(x1, 0);
+ GETGB(x2);
+ emit_adc8(dyn, ninst, x1, x2, x4, x5, x3);
+ EBBACK(x5, 0);
+ break;
+ case 0x11:
+ INST_NAME("ADC Ed, Gd");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED(0);
+ emit_adc32(dyn, ninst, rex, ed, gd, x3, x4, x5, x6);
+ WBACK;
+ break;
+ case 0x12:
+ INST_NAME("ADC Gb, Eb");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETEB(x2, 0);
+ GETGB(x1);
+ emit_adc8(dyn, ninst, x1, x2, x4, x3, x5);
+ GBBACK(x5);
+ break;
+ case 0x13:
+ INST_NAME("ADC Gd, Ed");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED(0);
+ emit_adc32(dyn, ninst, rex, gd, ed, x3, x4, x5, x6);
+ break;
+ case 0x14:
+ INST_NAME("ADC AL, Ib");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ u8 = F8;
+ ANDI(x1, xRAX, 0xff);
+ emit_adc8c(dyn, ninst, x1, u8, x3, x4, x5, x6);
+ ANDI(xRAX, xRAX, -256);
+ OR(xRAX, xRAX, x1);
+ break;
+ case 0x15:
+ INST_NAME("ADC EAX, Id");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ i64 = F32S;
+ MOV64xw(x1, i64);
+ emit_adc32(dyn, ninst, rex, xRAX, x1, x3, x4, x5, x6);
+ break;
+ case 0x18:
+ INST_NAME("SBB Eb, Gb");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETEB(x1, 0);
+ GETGB(x2);
+ emit_sbb8(dyn, ninst, x1, x2, x4, x5, x6);
+ EBBACK(x5, 0);
+ break;
+ case 0x19:
+ INST_NAME("SBB Ed, Gd");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED(0);
+ emit_sbb32(dyn, ninst, rex, ed, gd, x3, x4, x5);
+ WBACK;
+ break;
+ case 0x1A:
+ INST_NAME("SBB Gb, Eb");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETEB(x2, 0);
+ GETGB(x1);
+ emit_sbb8(dyn, ninst, x1, x2, x3, x4, x5);
+ GBBACK(x5);
+ break;
+ case 0x1B:
+ INST_NAME("SBB Gd, Ed");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED(0);
+ emit_sbb32(dyn, ninst, rex, gd, ed, x3, x4, x5);
+ break;
+ case 0x1C:
+ INST_NAME("SBB AL, Ib");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ u8 = F8;
+ ANDI(x1, xRAX, 0xff);
+ emit_sbb8c(dyn, ninst, x1, u8, x3, x4, x5, x6);
+ ANDI(xRAX, xRAX, ~0xff);
+ OR(xRAX, xRAX, x1);
+ break;
+ case 0x1D:
+ INST_NAME("SBB EAX, Id");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ i64 = F32S;
+ MOV64xw(x2, i64);
+ emit_sbb32(dyn, ninst, rex, xRAX, x2, x3, x4, x5);
+ break;
+
+ case 0x20:
+ INST_NAME("AND Eb, Gb");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETEB(x1, 0);
+ GETGB(x2);
+ emit_and8(dyn, ninst, x1, x2, x4, x5);
+ EBBACK(x4, 0);
+ break;
+ case 0x21:
+ INST_NAME("AND Ed, Gd");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED(0);
+ emit_and32(dyn, ninst, rex, ed, gd, x3, x4);
+ WBACK;
+ break;
+ case 0x22:
+ INST_NAME("AND Gb, Eb");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETEB(x1, 0);
+ GETGB(x2);
+ emit_and8(dyn, ninst, x2, x1, x4, x5);
+ GBBACK(x5);
+ break;
+ case 0x23:
+ INST_NAME("AND Gd, Ed");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED(0);
+ emit_and32(dyn, ninst, rex, gd, ed, x3, x4);
+ break;
+ case 0x24:
+ INST_NAME("AND AL, Ib");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ u8 = F8;
+ ANDI(x1, xRAX, 0xff);
+ emit_and8c(dyn, ninst, x1, u8, x3, x4);
+ ANDI(xRAX, xRAX, ~0xff);
+ OR(xRAX, xRAX, x1);
+ break;
+ case 0x25:
+ INST_NAME("AND EAX, Id");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ i64 = F32S;
+ emit_and32c(dyn, ninst, rex, xRAX, i64, x3, x4);
+ break;
+ case 0x28:
+ INST_NAME("SUB Eb, Gb");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETEB(x1, 0);
+ GETGB(x2);
+ emit_sub8(dyn, ninst, x1, x2, x4, x5, x6);
+ EBBACK(x5, 0);
+ break;
+ case 0x29:
+ INST_NAME("SUB Ed, Gd");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED(0);
+ emit_sub32(dyn, ninst, rex, ed, gd, x3, x4, x5);
+ WBACK;
+ break;
+ case 0x2A:
+ INST_NAME("SUB Gb, Eb");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETEB(x1, 0);
+ GETGB(x2);
+ emit_sub8(dyn, ninst, x2, x1, x4, x5, x6);
+ GBBACK(x5);
+ break;
+ case 0x2B:
+ INST_NAME("SUB Gd, Ed");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED(0);
+ emit_sub32(dyn, ninst, rex, gd, ed, x3, x4, x5);
+ break;
+ case 0x2C:
+ INST_NAME("SUB AL, Ib");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ u8 = F8;
+ ANDI(x1, xRAX, 0xff);
+ emit_sub8c(dyn, ninst, x1, u8, x2, x3, x4, x5);
+ ANDI(xRAX, xRAX, ~0xff);
+ OR(xRAX, xRAX, x1);
+ break;
+ case 0x2D:
+ INST_NAME("SUB EAX, Id");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ i64 = F32S;
+ emit_sub32c(dyn, ninst, rex, xRAX, i64, x2, x3, x4, x5);
+ break;
+ case 0x30:
+ INST_NAME("XOR Eb, Gb");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETEB(x1, 0);
+ GETGB(x2);
+ emit_xor8(dyn, ninst, x1, x2, x4, x5);
+ EBBACK(x5, 0);
+ break;
+ case 0x31:
+ INST_NAME("XOR Ed, Gd");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED(0);
+ emit_xor32(dyn, ninst, rex, ed, gd, x3, x4);
+ if(ed!=gd) {
+ WBACK;
+ }
+ break;
+ case 0x32:
+ INST_NAME("XOR Gb, Eb");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETEB(x1, 0);
+ GETGB(x2);
+ emit_xor8(dyn, ninst, x2, x1, x4, x5);
+ GBBACK(x5);
+ break;
+ case 0x33:
+ INST_NAME("XOR Gd, Ed");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED(0);
+ emit_xor32(dyn, ninst, rex, gd, ed, x3, x4);
+ break;
+ case 0x34:
+ INST_NAME("XOR AL, Ib");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ u8 = F8;
+ ANDI(x1, xRAX, 0xff);
+ emit_xor8c(dyn, ninst, x1, u8, x3, x4);
+ ANDI(xRAX, xRAX, ~0xff);
+ OR(xRAX, xRAX, x1);
+ break;
+ case 0x35:
+ INST_NAME("XOR EAX, Id");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ i64 = F32S;
+ emit_xor32c(dyn, ninst, rex, xRAX, i64, x3, x4);
+ break;
+ case 0x38:
+ INST_NAME("CMP Eb, Gb");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETEB(x1, 0);
+ GETGB(x2);
+ emit_cmp8(dyn, ninst, x1, x2, x3, x4, x5, x6);
+ break;
+ case 0x39:
+ INST_NAME("CMP Ed, Gd");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED(0);
+ emit_cmp32(dyn, ninst, rex, ed, gd, x3, x4, x5, x6);
+ break;
+ case 0x3A:
+ INST_NAME("CMP Gb, Eb");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETEB(x1, 0);
+ GETGB(x2);
+ emit_cmp8(dyn, ninst, x2, x1, x3, x4, x5, x6);
+ break;
+ case 0x3B:
+ INST_NAME("CMP Gd, Ed");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED(0);
+ emit_cmp32(dyn, ninst, rex, gd, ed, x3, x4, x5, x6);
+ break;
+ case 0x3C:
+ INST_NAME("CMP AL, Ib");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ u8 = F8;
+ ANDI(x1, xRAX, 0xff);
+ if(u8) {
+ MOV32w(x2, u8);
+ emit_cmp8(dyn, ninst, x1, x2, x3, x4, x5, x6);
+ } else {
+ emit_cmp8_0(dyn, ninst, x1, x3, x4);
+ }
+ break;
+ case 0x3D:
+ INST_NAME("CMP EAX, Id");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ i64 = F32S;
+ if(i64) {
+ MOV64xw(x2, i64);
+ emit_cmp32(dyn, ninst, rex, xRAX, x2, x3, x4, x5, x6);
+ } else
+ emit_cmp32_0(dyn, ninst, rex, xRAX, x3, x4);
+ break;
+
+ default:
+ DEFAULT;
+ }
+
+ return addr;
+}
diff --git a/src/dynarec/rv64/dynarec_rv64_00_1.c b/src/dynarec/rv64/dynarec_rv64_00_1.c
new file mode 100644
index 0000000..54ca28f
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_00_1.c
@@ -0,0 +1,297 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <stddef.h>
+#include <errno.h>
+#include <signal.h>
+#include <assert.h>
+
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "emu/x64run_private.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "bridge.h"
+#include "emu/x64run_private.h"
+#include "x64trace.h"
+#include "dynarec_native.h"
+#include "custommem.h"
+
+#include "rv64_printer.h"
+#include "dynarec_rv64_private.h"
+#include "dynarec_rv64_functions.h"
+#include "dynarec_rv64_helper.h"
+
+int isSimpleWrapper(wrapper_t fun);
+
+uintptr_t dynarec64_00_1(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog)
+{
+ uint8_t nextop, opcode;
+ uint8_t gd, ed;
+ int8_t i8;
+ int32_t i32, tmp;
+ int64_t i64, j64;
+ uint8_t u8;
+ uint8_t gb1, gb2, eb1, eb2;
+ uint32_t u32;
+ uint64_t u64;
+ uint8_t wback, wb1, wb2, wb;
+ int64_t fixedaddress;
+ int lock;
+ int cacheupd = 0;
+
+ opcode = F8;
+ MAYUSE(eb1);
+ MAYUSE(eb2);
+ MAYUSE(j64);
+ MAYUSE(wb);
+ MAYUSE(lock);
+ MAYUSE(cacheupd);
+
+ switch(opcode) {
+ case 0x40:
+ case 0x41:
+ case 0x42:
+ case 0x43:
+ case 0x44:
+ case 0x45:
+ case 0x46:
+ case 0x47:
+ INST_NAME("INC Reg (32bits)");
+ SETFLAGS(X_ALL&~X_CF, SF_SUBSET_PENDING);
+ gd = xRAX + (opcode&7);
+ emit_inc32(dyn, ninst, rex, gd, x1, x2, x3, x4);
+ break;
+ case 0x48:
+ case 0x49:
+ case 0x4A:
+ case 0x4B:
+ case 0x4C:
+ case 0x4D:
+ case 0x4E:
+ case 0x4F:
+ INST_NAME("DEC Reg (32bits)");
+ SETFLAGS(X_ALL&~X_CF, SF_SUBSET_PENDING);
+ gd = xRAX + (opcode&7);
+ emit_dec32(dyn, ninst, rex, gd, x1, x2, x3, x4);
+ break;
+ case 0x50:
+ case 0x51:
+ case 0x52:
+ case 0x53:
+ case 0x54:
+ case 0x55:
+ case 0x56:
+ case 0x57:
+ INST_NAME("PUSH reg");
+ gd = xRAX+(opcode&0x07)+(rex.b<<3);
+ PUSH1z(gd);
+ break;
+ case 0x58:
+ case 0x59:
+ case 0x5A:
+ case 0x5B:
+ case 0x5C:
+ case 0x5D:
+ case 0x5E:
+ case 0x5F:
+ INST_NAME("POP reg");
+ gd = xRAX+(opcode&0x07)+(rex.b<<3);
+ POP1z(gd);
+ break;
+
+ case 0x60:
+ if(rex.is32bits) {
+ INST_NAME("PUSHAD");
+ AND(x1, xRSP, xMASK);
+ PUSH1_32(xRAX);
+ PUSH1_32(xRCX);
+ PUSH1_32(xRDX);
+ PUSH1_32(xRBX);
+ PUSH1_32(x1);
+ PUSH1_32(xRBP);
+ PUSH1_32(xRSI);
+ PUSH1_32(xRDI);
+ } else {
+ DEFAULT;
+ }
+ break;
+ case 0x61:
+ if(rex.is32bits) {
+ INST_NAME("POPAD");
+ POP1_32(xRDI);
+ POP1_32(xRSI);
+ POP1_32(xRBP);
+ POP1_32(x1);
+ POP1_32(xRBX);
+ POP1_32(xRDX);
+ POP1_32(xRCX);
+ POP1_32(xRAX);
+ } else {
+ DEFAULT;
+ }
+ break;
+
+ case 0x63:
+ if(rex.is32bits) {
+ // this is ARPL opcode
+ DEFAULT;
+ } else {
+ INST_NAME("MOVSXD Gd, Ed");
+ nextop = F8;
+ GETGD;
+ if(rex.w) {
+ if(MODREG) { // reg <= reg
+ ADDIW(gd, xRAX+(nextop&7)+(rex.b<<3), 0);
+ } else { // mem <= reg
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, NULL, 1, 0);
+ LW(gd, ed, fixedaddress);
+ }
+ } else {
+ if(MODREG) { // reg <= reg
+ AND(gd, xRAX+(nextop&7)+(rex.b<<3), xMASK);
+ } else { // mem <= reg
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, NULL, 1, 0);
+ LWU(gd, ed, fixedaddress);
+ }
+ }
+ }
+ break;
+ case 0x64:
+ addr = dynarec64_64(dyn, addr, ip, ninst, rex, rep, _FS, ok, need_epilog);
+ break;
+ case 0x65:
+ addr = dynarec64_64(dyn, addr, ip, ninst, rex, rep, _GS, ok, need_epilog);
+ break;
+ case 0x66:
+ addr = dynarec64_66(dyn, addr, ip, ninst, rex, rep, ok, need_epilog);
+ break;
+ case 0x67:
+ addr = dynarec64_67(dyn, addr, ip, ninst, rex, rep, ok, need_epilog);
+ break;
+ case 0x68:
+ INST_NAME("PUSH Id");
+ i64 = F32S;
+ if(PK(0)==0xC3) {
+ MESSAGE(LOG_DUMP, "PUSH then RET, using indirect\n");
+ TABLE64(x3, addr-4);
+ LW(x1, x3, 0);
+ PUSH1z(x1);
+ } else {
+ MOV64z(x3, i64);
+ PUSH1z(x3);
+ }
+ break;
+ case 0x69:
+ INST_NAME("IMUL Gd, Ed, Id");
+ SETFLAGS(X_ALL, SF_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED(4);
+ i64 = F32S;
+ MOV64xw(x4, i64);
+ if(rex.w) {
+ // 64bits imul
+ UFLAG_IF {
+ MULH(x3, ed, x4);
+ MUL(gd, ed, x4);
+ UFLAG_OP1(x3);
+ UFLAG_RES(gd);
+ UFLAG_DF(x3, d_imul64);
+ } else {
+ MULxw(gd, ed, x4);
+ }
+ } else {
+ // 32bits imul
+ UFLAG_IF {
+ MUL(gd, ed, x4);
+ UFLAG_RES(gd);
+ SRLI(x3, gd, 32);
+ UFLAG_OP1(x3);
+ UFLAG_DF(x3, d_imul32);
+ } else {
+ MULxw(gd, ed, x4);
+ }
+ ZEROUP(gd);
+ }
+ break;
+ case 0x6A:
+ INST_NAME("PUSH Ib");
+ i64 = F8S;
+ MOV64z(x3, i64);
+ PUSH1z(x3);
+ break;
+ case 0x6B:
+ INST_NAME("IMUL Gd, Ed, Ib");
+ SETFLAGS(X_ALL, SF_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED(1);
+ i64 = F8S;
+ MOV64xw(x4, i64);
+ if(rex.w) {
+ // 64bits imul
+ UFLAG_IF {
+ MULH(x3, ed, x4);
+ MUL(gd, ed, x4);
+ UFLAG_OP1(x3);
+ UFLAG_RES(gd);
+ UFLAG_DF(x3, d_imul64);
+ } else {
+ MUL(gd, ed, x4);
+ }
+ } else {
+ // 32bits imul
+ UFLAG_IF {
+ MUL(gd, ed, x4);
+ UFLAG_RES(gd);
+ SRLI(x3, gd, 32);
+ UFLAG_OP1(x3);
+ UFLAG_DF(x3, d_imul32);
+ } else {
+ MULW(gd, ed, x4);
+ }
+ ZEROUP(gd);
+ }
+ break;
+
+ #define GO(GETFLAGS, NO, YES, F) \
+ READFLAGS(F); \
+ i8 = F8S; \
+ BARRIER(BARRIER_MAYBE); \
+ JUMP(addr+i8, 1); \
+ GETFLAGS; \
+ if(dyn->insts[ninst].x64.jmp_insts==-1 || \
+ CHECK_CACHE()) { \
+ /* out of the block */ \
+ i32 = dyn->insts[ninst].epilog-(dyn->native_size); \
+ B##NO##_safe(x1, i32); \
+ if(dyn->insts[ninst].x64.jmp_insts==-1) { \
+ if(!(dyn->insts[ninst].x64.barrier&BARRIER_FLOAT)) \
+ fpu_purgecache(dyn, ninst, 1, x1, x2, x3); \
+ jump_to_next(dyn, addr+i8, 0, ninst); \
+ } else { \
+ CacheTransform(dyn, ninst, cacheupd, x1, x2, x3); \
+ i32 = dyn->insts[dyn->insts[ninst].x64.jmp_insts].address-(dyn->native_size);\
+ B(i32); \
+ } \
+ } else { \
+ /* inside the block */ \
+ i32 = dyn->insts[dyn->insts[ninst].x64.jmp_insts].address-(dyn->native_size); \
+ B##YES##_safe(x1, i32); \
+ }
+
+ GOCOND(0x70, "J", "ib");
+
+ #undef GO
+ default:
+ DEFAULT;
+ }
+
+ return addr;
+}
diff --git a/src/dynarec/rv64/dynarec_rv64_00_2.c b/src/dynarec/rv64/dynarec_rv64_00_2.c
new file mode 100644
index 0000000..20333f9
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_00_2.c
@@ -0,0 +1,845 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <stddef.h>
+#include <errno.h>
+#include <signal.h>
+#include <assert.h>
+
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "emu/x64run_private.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "bridge.h"
+#include "emu/x64run_private.h"
+#include "x64trace.h"
+#include "dynarec_native.h"
+#include "custommem.h"
+
+#include "rv64_printer.h"
+#include "dynarec_rv64_private.h"
+#include "dynarec_rv64_functions.h"
+#include "dynarec_rv64_helper.h"
+
+uintptr_t dynarec64_00_2(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog)
+{
+ uint8_t nextop, opcode;
+ uint8_t gd, ed;
+ int8_t i8;
+ int32_t i32, tmp;
+ int64_t i64, j64;
+ uint8_t u8;
+ uint8_t gb1, gb2, eb1, eb2;
+ uint32_t u32;
+ uint64_t u64;
+ uint8_t wback, wb1, wb2, wb;
+ int64_t fixedaddress;
+ int lock;
+ int cacheupd = 0;
+
+ opcode = F8;
+ MAYUSE(eb1);
+ MAYUSE(eb2);
+ MAYUSE(j64);
+ MAYUSE(wb);
+ MAYUSE(lock);
+ MAYUSE(cacheupd);
+
+ switch(opcode) {
+ case 0x80:
+ nextop = F8;
+ switch((nextop>>3)&7) {
+ case 0: // ADD
+ INST_NAME("ADD Eb, Ib");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEB(x1, 1);
+ u8 = F8;
+ emit_add8c(dyn, ninst, x1, u8, x2, x4, x5);
+ EBBACK(x5, 0);
+ break;
+ case 1: // OR
+ INST_NAME("OR Eb, Ib");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEB(x1, 1);
+ u8 = F8;
+ emit_or8c(dyn, ninst, x1, u8, x2, x4, x5);
+ EBBACK(x5, 0);
+ break;
+ case 2: // ADC
+ INST_NAME("ADC Eb, Ib");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEB(x1, 1);
+ u8 = F8;
+ emit_adc8c(dyn, ninst, x1, u8, x2, x4, x5, x6);
+ EBBACK(x5, 0);
+ break;
+ case 3: // SBB
+ INST_NAME("SBB Eb, Ib");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEB(x1, 1);
+ u8 = F8;
+ emit_sbb8c(dyn, ninst, x1, u8, x2, x4, x5, x6);
+ EBBACK(x5, 0);
+ break;
+ case 4: // AND
+ INST_NAME("AND Eb, Ib");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEB(x1, 1);
+ u8 = F8;
+ emit_and8c(dyn, ninst, x1, u8, x2, x4);
+ EBBACK(x5, 0);
+ break;
+ case 5: // SUB
+ INST_NAME("SUB Eb, Ib");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEB(x1, 1);
+ u8 = F8;
+ emit_sub8c(dyn, ninst, x1, u8, x2, x4, x5, x6);
+ EBBACK(x5, 0);
+ break;
+ case 6: // XOR
+ INST_NAME("XOR Eb, Ib");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEB(x1, 1);
+ u8 = F8;
+ emit_xor8c(dyn, ninst, x1, u8, x2, x4);
+ EBBACK(x5, 0);
+ break;
+ case 7: // CMP
+ INST_NAME("CMP Eb, Ib");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEB(x1, 1);
+ u8 = F8;
+ if(u8) {
+ ADDI(x2, xZR, u8);
+ emit_cmp8(dyn, ninst, x1, x2, x3, x4, x5, x6);
+ } else {
+ emit_cmp8_0(dyn, ninst, x1, x3, x4);
+ }
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+ case 0x81:
+ case 0x83:
+ nextop = F8;
+ switch((nextop>>3)&7) {
+ case 0: // ADD
+ if(opcode==0x81) {INST_NAME("ADD Ed, Id");} else {INST_NAME("ADD Ed, Ib");}
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETED((opcode==0x81)?4:1);
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ emit_add32c(dyn, ninst, rex, ed, i64, x3, x4, x5, x6);
+ WBACK;
+ break;
+ case 1: // OR
+ if(opcode==0x81) {INST_NAME("OR Ed, Id");} else {INST_NAME("OR Ed, Ib");}
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETED((opcode==0x81)?4:1);
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ emit_or32c(dyn, ninst, rex, ed, i64, x3, x4);
+ WBACK;
+ break;
+ case 2: // ADC
+ if(opcode==0x81) {INST_NAME("ADC Ed, Id");} else {INST_NAME("ADC Ed, Ib");}
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETED((opcode==0x81)?4:1);
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ MOV64xw(x5, i64);
+ emit_adc32(dyn, ninst, rex, ed, x5, x3, x4, x6, x9);
+ WBACK;
+ break;
+ case 3: // SBB
+ if(opcode==0x81) {INST_NAME("SBB Ed, Id");} else {INST_NAME("SBB Ed, Ib");}
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETED((opcode==0x81)?4:1);
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ MOV64xw(x5, i64);
+ emit_sbb32(dyn, ninst, rex, ed, x5, x3, x4, x6);
+ WBACK;
+ break;
+ case 4: // AND
+ if(opcode==0x81) {INST_NAME("AND Ed, Id");} else {INST_NAME("AND Ed, Ib");}
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETED((opcode==0x81)?4:1);
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ emit_and32c(dyn, ninst, rex, ed, i64, x3, x4);
+ WBACK;
+ break;
+ case 5: // SUB
+ if(opcode==0x81) {INST_NAME("SUB Ed, Id");} else {INST_NAME("SUB Ed, Ib");}
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETED((opcode==0x81)?4:1);
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ emit_sub32c(dyn, ninst, rex, ed, i64, x3, x4, x5, x6);
+ WBACK;
+ break;
+ case 6: // XOR
+ if(opcode==0x81) {INST_NAME("XOR Ed, Id");} else {INST_NAME("XOR Ed, Ib");}
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETED((opcode==0x81)?4:1);
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ emit_xor32c(dyn, ninst, rex, ed, i64, x3, x4);
+ WBACK;
+ break;
+ case 7: // CMP
+ if(opcode==0x81) {INST_NAME("CMP Ed, Id");} else {INST_NAME("CMP Ed, Ib");}
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETED((opcode==0x81)?4:1);
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ if(i64) {
+ MOV64xw(x2, i64);
+ emit_cmp32(dyn, ninst, rex, ed, x2, x3, x4, x5, x6);
+ } else {
+ if(!rex.w && MODREG) {
+ AND(x1, ed, xMASK);
+ ed = x1;
+ }
+ emit_cmp32_0(dyn, ninst, rex, ed, x3, x4);
+ }
+ break;
+ }
+ break;
+ case 0x84:
+ INST_NAME("TEST Eb, Gb");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop=F8;
+ GETEB(x1, 0);
+ GETGB(x2);
+ emit_test8(dyn, ninst, x1, x2, x3, x4, x5);
+ break;
+ case 0x85:
+ INST_NAME("TEST Ed, Gd");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop=F8;
+ GETGD;
+ GETED(0);
+ emit_test32(dyn, ninst, rex, ed, gd, x3, x4, x5);
+ break;
+ case 0x86:
+ INST_NAME("(LOCK)XCHG Eb, Gb");
+ nextop = F8;
+ if(MODREG) {
+ GETGB(x1);
+ GETEB(x2, 0);
+ MV(x4, gd);
+ MV(gd, ed);
+ MV(ed, x4);
+ GBBACK(x4);
+ EBBACK(x4, 0);
+ } else {
+ GETGB(x3);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, LOCK_LOCK, 0, 0);
+ SMDMB();
+ LBU(x1, ed, 0);
+ SB(gd, ed, 0);
+ SMDMB();
+ gd = x1;
+ GBBACK(x3);
+ }
+ break;
+ case 0x87:
+ INST_NAME("(LOCK)XCHG Ed, Gd");
+ nextop = F8;
+ if(MODREG) {
+ GETGD;
+ GETED(0);
+ MVxw(x1, gd);
+ MVxw(gd, ed);
+ MVxw(ed, x1);
+ } else {
+ GETGD;
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, LOCK_LOCK, 0, 0);
+ SMDMB();
+ ANDI(x3, ed, (1<<(2+rex.w))-1);
+ BNE_MARK(x3, xZR);
+ MARKLOCK;
+ LRxw(x1, ed, 1, 0);
+ SCxw(x3, gd, ed, 0, 1);
+ BNE_MARKLOCK(x3, xZR);
+ B_MARK2_nocond;
+ MARK;
+ LDxw(x1, ed, 0);
+ SDxw(gd, ed, 0);
+ MARK2;
+ SMDMB();
+ MVxw(gd, x1);
+ }
+ break;
+ case 0x88:
+ INST_NAME("MOV Eb, Gb");
+ nextop = F8;
+ gd = ((nextop&0x38)>>3)+(rex.r<<3);
+ if(rex.rex) {
+ gb2 = 0;
+ gb1 = xRAX + gd;
+ } else {
+ gb2 = ((gd&4)>>2);
+ gb1 = xRAX+(gd&3);
+ }
+ gd = x4;
+ if(gb2) {
+ SRLI(x4, gb1, 8);
+ gb1 = x4;
+ }
+ if(MODREG) {
+ ed = (nextop&7) + (rex.b<<3);
+ if(rex.rex) {
+ eb1 = xRAX+ed;
+ eb2 = 0;
+ } else {
+ eb1 = xRAX+(ed&3); // Ax, Cx, Dx or Bx
+ eb2 = ((ed&4)>>2); // L or H
+ }
+ ANDI(gd, gb1, 0xff);
+ if(eb2) {
+ MOV64x(x1, 0xffffffffffff00ffLL);
+ AND(x1, eb1, x1);
+ SLLI(gd, gd, 8);
+ OR(eb1, x1, gd);
+ } else {
+ ANDI(x1, eb1, ~0xff);
+ OR(eb1, x1, gd);
+ }
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, &lock, 1, 0);
+ SB(gb1, ed, fixedaddress);
+ SMWRITELOCK(lock);
+ }
+ break;
+ case 0x89:
+ INST_NAME("MOV Ed, Gd");
+ nextop=F8;
+ GETGD;
+ if(MODREG) { // reg <= reg
+ MVxw(xRAX+(nextop&7)+(rex.b<<3), gd);
+ } else { // mem <= reg
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, &lock, 1, 0);
+ SDxw(gd, ed, fixedaddress);
+ SMWRITELOCK(lock);
+ }
+ break;
+ case 0x8A:
+ INST_NAME("MOV Gb, Eb");
+ nextop = F8;
+ gd = ((nextop&0x38)>>3)+(rex.r<<3);
+ if(rex.rex) {
+ gb2 = 0;
+ gb1 = xRAX + gd;
+ } else {
+ gb2 = ((gd&4)>>2);
+ gb1 = xRAX+(gd&3);
+ }
+ gd = x4;
+ if(MODREG) {
+ ed = (nextop&7) + (rex.b<<3);
+ if(rex.rex) {
+ eb1 = xRAX+ed;
+ eb2 = 0;
+ } else {
+ eb1 = xRAX+(ed&3); // Ax, Cx, Dx or Bx
+ eb2 = ((ed&4)>>2); // L or H
+ }
+ if(eb2) {
+ SRLI(x1, eb1, 8);
+ ANDI(x1, x1, 0xff);
+ } else {
+ ANDI(x1, eb1, 0xff);
+ }
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, &lock, 1, 0);
+ SMREADLOCK(lock);
+ LBU(x1, ed, fixedaddress);
+ }
+ if(gb2) {
+ MOV64x(x4, ~0xff00);
+ AND(gb1, gb1, x4);
+ SLLI(x1, x1, 8);
+ } else {
+ ANDI(gb1, gb1, ~0xff);
+ }
+ OR(gb1, gb1, x1);
+ break;
+ case 0x8B:
+ INST_NAME("MOV Gd, Ed");
+ nextop=F8;
+ GETGD;
+ if(MODREG) {
+ MVxw(gd, xRAX+(nextop&7)+(rex.b<<3));
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, &lock, 1, 0);
+ SMREADLOCK(lock);
+ LDxw(gd, ed, fixedaddress);
+ }
+ break;
+ case 0x8C:
+ INST_NAME("MOV Ed, Seg");
+ nextop=F8;
+ if((nextop&0xC0)==0xC0) { // reg <= seg
+ LHU(xRAX+(nextop&7)+(rex.b<<3), xEmu, offsetof(x64emu_t, segs[(nextop&0x38)>>3]));
+ } else { // mem <= seg
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, NULL, 1, 0);
+ LHU(x3, xEmu, offsetof(x64emu_t, segs[(nextop&0x38)>>3]));
+ SH(x3, ed, fixedaddress);
+ SMWRITE2();
+ }
+ break;
+ case 0x8D:
+ INST_NAME("LEA Gd, Ed");
+ nextop=F8;
+ GETGD;
+ if(MODREG) { // reg <= reg? that's an invalid operation
+ DEFAULT;
+ } else { // mem <= reg
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, NULL, 0, 0);
+ MV(gd, ed);
+ if(!rex.w || rex.is32bits) {
+ ZEROUP(gd); // truncate the higher 32bits as asked
+ }
+ }
+ break;
+ case 0x8E:
+ INST_NAME("MOV Seg,Ew");
+ nextop = F8;
+ if((nextop&0xC0)==0xC0) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ } else {
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, &lock, 1, 0);
+ LHU(x1, ed, fixedaddress);
+ ed = x1;
+ }
+ SW(ed, xEmu, offsetof(x64emu_t, segs[(nextop&0x38)>>3]));
+ SW(xZR, xEmu, offsetof(x64emu_t, segs_serial[(nextop&0x38)>>3]));
+ break;
+ case 0x8F:
+ INST_NAME("POP Ed");
+ nextop = F8;
+ if(MODREG) {
+ POP1z(xRAX+(nextop&7)+(rex.b<<3));
+ } else {
+ POP1z(x2); // so this can handle POP [ESP] and maybe some variant too
+ addr = geted(dyn, addr, ninst, nextop, &ed, x3, x1, &fixedaddress, rex, &lock, 1, 0);
+ if(ed==xRSP) {
+ SDz(x2, ed, fixedaddress);
+ } else {
+ // complicated to just allow a segfault that can be recovered correctly
+ ADDIz(xRSP, xRSP, rex.is32bits?-4:-8);
+ SDz(x2, ed, fixedaddress);
+ ADDIz(xRSP, xRSP, rex.is32bits?4:8);
+ }
+ }
+ break;
+ case 0x90:
+ case 0x91:
+ case 0x92:
+ case 0x93:
+ case 0x94:
+ case 0x95:
+ case 0x96:
+ case 0x97:
+ gd = xRAX+(opcode&0x07)+(rex.b<<3);
+ if(gd==xRAX) {
+ INST_NAME("NOP");
+ } else {
+ INST_NAME("XCHG EAX, Reg");
+ MVxw(x2, xRAX);
+ MVxw(xRAX, gd);
+ MVxw(gd, x2);
+ }
+ break;
+ case 0x98:
+ INST_NAME("CWDE");
+ if(rex.w) {
+ SEXT_W(xRAX, xRAX);
+ } else {
+ SLLI(xRAX, xRAX, 16);
+ SRAIW(xRAX, xRAX, 16);
+ ZEROUP(xRAX);
+ }
+ break;
+ case 0x99:
+ INST_NAME("CDQ");
+ if(rex.w) {
+ SRAI(xRDX, xRAX, 63);
+ } else {
+ SLLI(xRDX, xRAX, 32);
+ SRAI(xRDX, xRDX, 63);
+ ZEROUP(xRDX);
+ }
+ break;
+ case 0x9B:
+ INST_NAME("FWAIT");
+ break;
+ case 0x9C:
+ INST_NAME("PUSHF");
+ NOTEST(x1);
+ READFLAGS(X_ALL);
+ FLAGS_ADJUST_TO11(x3, xFlags, x2);
+ PUSH1z(x3);
+ break;
+ case 0x9D:
+ INST_NAME("POPF");
+ SETFLAGS(X_ALL, SF_SET);
+ POP1z(xFlags);
+ FLAGS_ADJUST_FROM11(xFlags, x2);
+ MOV32w(x1, 0x3F7FD7);
+ AND(xFlags, xFlags, x1);
+ ORI(xFlags, xFlags, 0x2);
+ SET_DFNONE();
+ if(box64_wine) { // should this be done all the time?
+ ANDI(x1, xFlags, 1 << F_TF);
+ CBZ_NEXT(x1);
+ MOV64x(xRIP, addr);
+ STORE_XEMU_CALL();
+ CALL(native_singlestep, -1);
+ ANDI(xFlags, xFlags, ~(1 << F_TF));
+ }
+ break;
+ case 0x9F:
+ INST_NAME("LAHF");
+ READFLAGS(X_CF|X_PF|X_AF|X_ZF|X_SF);
+ ANDI(x1, xFlags, 0xFF);
+ SLLI(x1, x1, 8);
+ MOV64x(x2, 0xffffffffffff00ffLL);
+ AND(xRAX, xRAX, x2);
+ OR(xRAX, xRAX, x1);
+ break;
+ case 0xA0:
+ INST_NAME("MOV AL,Ob");
+ if(rex.is32bits) u64 = F32; else u64 = F64;
+ MOV64z(x1, u64);
+ LBU(x1, x1, 0);
+ ANDI(xRAX, xRAX, ~0xff);
+ OR(xRAX, xRAX, x1);
+ break;
+ case 0xA1:
+ INST_NAME("MOV EAX,Od");
+ if(rex.is32bits) u64 = F32; else u64 = F64;
+ MOV64z(x1, u64);
+ LDxw(xRAX, x1, 0);
+ break;
+ case 0xA2:
+ INST_NAME("MOV Ob,AL");
+ if(rex.is32bits) u64 = F32; else u64 = F64;
+ MOV64z(x1, u64);
+ SB(xRAX, x1, 0);
+ SMWRITE();
+ break;
+ case 0xA3:
+ INST_NAME("MOV Od,EAX");
+ if(rex.is32bits) u64 = F32; else u64 = F64;
+ MOV64z(x1, u64);
+ SDxw(xRAX, x1, 0);
+ SMWRITE();
+ break;
+ case 0xA4:
+ if(rep) {
+ INST_NAME("REP MOVSB");
+ CBZ_NEXT(xRCX);
+ ANDI(x1, xFlags, 1<<F_DF);
+ BNEZ_MARK2(x1);
+ MARK; // Part with DF==0
+ LBU(x1, xRSI, 0);
+ SB(x1, xRDI, 0);
+ ADDI(xRSI, xRSI, 1);
+ ADDI(xRDI, xRDI, 1);
+ SUBI(xRCX, xRCX, 1);
+ BNEZ_MARK(xRCX);
+ B_NEXT_nocond;
+ MARK2; // Part with DF==1
+ LBU(x1, xRSI, 0);
+ LBU(x1, xRDI, 0);
+ SUBI(xRSI, xRSI, 1);
+ SUBI(xRDI, xRDI, 1);
+ SUBI(xRCX, xRCX, 1);
+ BNEZ_MARK2(xRCX);
+ // done
+ } else {
+ INST_NAME("MOVSB");
+ GETDIR(x3, x1, 1);
+ LBU(x1, xRSI, 0);
+ SB(x1, xRDI, 0);
+ ADD(xRSI, xRSI, x3);
+ ADD(xRDI, xRDI, x3);
+ }
+ break;
+ case 0xA5:
+ if(rep) {
+ INST_NAME("REP MOVSD");
+ CBZ_NEXT(xRCX);
+ ANDI(x1, xFlags, 1<<F_DF);
+ BNEZ_MARK2(x1);
+ MARK; // Part with DF==0
+ LDxw(x1, xRSI, 0);
+ ADDI(xRSI, xRSI, rex.w?8:4);
+ SDxw(x1, xRDI, 0);
+ ADDI(xRDI, xRDI, rex.w?8:4);
+ SUBI(xRCX, xRCX, 1);
+ BNEZ_MARK(xRCX);
+ B_NEXT_nocond;
+ MARK2; // Part with DF==1
+ LDxw(x1, xRSI, 0);
+ SUBI(xRSI, xRSI, rex.w?8:4);
+ SDxw(x1, xRDI, 0);
+ SUBI(xRDI, xRDI, rex.w?8:4);
+ SUBI(xRCX, xRCX, 1);
+ BNEZ_MARK2(xRCX);
+ // done
+ } else {
+ INST_NAME("MOVSD");
+ GETDIR(x3, x1, rex.w?8:4);
+ LDxw(x1, xRSI, 0);
+ SDxw(x1, xRDI, 0);
+ ADD(xRSI, xRSI, x3);
+ ADD(xRDI, xRDI, x3);
+ }
+ break;
+ case 0xA6:
+ switch(rep) {
+ case 1:
+ case 2:
+ if(rep==1) {INST_NAME("REPNZ CMPSB");} else {INST_NAME("REPZ CMPSB");}
+ MAYSETFLAGS();
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ CBZ_NEXT(xRCX);
+ ANDI(x1, xFlags, 1<<F_DF);
+ BNEZ_MARK2(x1);
+ MARK; // Part with DF==0
+ LBU(x1, xRSI, 0);
+ ADDI(xRSI, xRSI, 1);
+ LBU(x2, xRDI, 0);
+ ADDI(xRDI, xRDI, 1);
+ SUBI(xRCX, xRCX, 1);
+ if (rep==1) {BEQ_MARK3(x1, x2);} else {BNE_MARK3(x1, x2);}
+ BNEZ_MARK(xRCX);
+ B_MARK3_nocond;
+ MARK2; // Part with DF==1
+ LBU(x1, xRSI, 0);
+ SUBI(xRSI, xRSI, 1);
+ LBU(x2, xRDI, 0);
+ SUBI(xRDI, xRDI, 1);
+ SUBI(xRCX, xRCX, 1);
+ if (rep==1) {BEQ_MARK3(x1, x2);} else {BNE_MARK3(x1, x2);}
+ BNEZ_MARK2(xRCX);
+ MARK3; // end
+ emit_cmp8(dyn, ninst, x1, x2, x3, x4, x5, x6);
+ break;
+ default:
+ INST_NAME("CMPSB");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETDIR(x3, x1, 1);
+ LBU(x1, xRSI, 0);
+ LBU(x2, xRDI, 0);
+ ADD(xRSI, xRSI, x3);
+ ADD(xRDI, xRDI, x3);
+ emit_cmp8(dyn, ninst, x1, x2, x3, x4, x5, x6);
+ break;
+ }
+ break;
+ case 0xA8:
+ INST_NAME("TEST AL, Ib");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ ANDI(x1, xRAX, 0xff);
+ u8 = F8;
+ MOV32w(x2, u8);
+ emit_test8(dyn, ninst, x1, x2, x3, x4, x5);
+ break;
+ case 0xA9:
+ INST_NAME("TEST EAX, Id");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ i64 = F32S;
+ MOV64xw(x2, i64);
+ emit_test32(dyn, ninst, rex, xRAX, x2, x3, x4, x5);
+ break;
+ case 0xAA:
+ if(rep) {
+ INST_NAME("REP STOSB");
+ CBZ_NEXT(xRCX);
+ ANDI(x1, xFlags, 1<<F_DF);
+ BNEZ_MARK2(x1);
+ MARK; // Part with DF==0
+ SB(xRAX, xRDI, 0);
+ ADDI(xRDI, xRDI, 1);
+ ADDI(xRCX, xRCX, -1);
+ BNEZ_MARK(xRCX);
+ B_NEXT_nocond;
+ MARK2; // Part with DF==1
+ SB(xRAX, xRDI, 0);
+ ADDI(xRDI, xRDI, -1);
+ ADDI(xRCX, xRCX, -1);
+ BNEZ_MARK2(xRCX);
+ // done
+ } else {
+ INST_NAME("STOSB");
+ GETDIR(x3, x1, 1);
+ SB(xRAX, xRDI, 0);
+ ADD(xRDI, xRDI, x3);
+ }
+ break;
+ case 0xAB:
+ if(rep) {
+ INST_NAME("REP STOSD");
+ CBZ_NEXT(xRCX);
+ ANDI(x1, xFlags, 1<<F_DF);
+ BNEZ_MARK2(x1);
+ MARK; // Part with DF==0
+ SDxw(xRAX, xRDI, 0);
+ ADDI(xRDI, xRDI, rex.w?8:4);
+ SUBI(xRCX, xRCX, 1);
+ BNEZ_MARK(xRCX);
+ B_NEXT_nocond;
+ MARK2; // Part with DF==1
+ SDxw(xRAX, xRDI, 0);
+ SUBI(xRDI, xRDI, rex.w?8:4);
+ SUBI(xRCX, xRCX, 1);
+ BNEZ_MARK2(xRCX);
+ // done
+ } else {
+ INST_NAME("STOSD");
+ GETDIR(x3, x1, rex.w?8:4);
+ SDxw(xRAX, xRDI, 0);
+ ADD(xRDI, xRDI, x3);
+ }
+ break;
+ case 0xAE:
+ switch (rep) {
+ case 1:
+ case 2:
+ if (rep==1) {INST_NAME("REPNZ SCASB");} else {INST_NAME("REPZ SCASB");}
+ MAYSETFLAGS();
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ CBZ_NEXT(xRCX);
+ ANDI(x1, xRAX, 0xff);
+ ANDI(x2, xFlags, 1<<F_DF);
+ BNEZ_MARK2(x2);
+ MARK; // Part with DF==0
+ LBU(x2, xRDI, 0);
+ ADDI(xRDI, xRDI, 1);
+ SUBI(xRCX, xRCX, 1);
+ if (rep==1) {BEQ_MARK3(x1, x2);} else {BNE_MARK3(x1, x2);}
+ BNE_MARK(xRCX, xZR);
+ B_MARK3_nocond;
+ MARK2; // Part with DF==1
+ LBU(x2, xRDI, 0);
+ SUBI(xRDI, xRDI, 1);
+ SUBI(xRCX, xRCX, 1);
+ if (rep==1) {BEQ_MARK3(x1, x2);} else {BNE_MARK3(x1, x2);}
+ BNE_MARK2(xRCX, xZR);
+ MARK3; // end
+ emit_cmp8(dyn, ninst, x1, x2, x3, x4, x5, x6);
+ break;
+ default:
+ INST_NAME("SCASB");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETDIR(x3, x1, 1);
+ ANDI(x1, xRAX, 0xff);
+ LBU(x2, xRDI, 0);
+ ADD(xRDI, xRDI, x3);
+ emit_cmp8(dyn, ninst, x1, x2, x3, x4, x5, x6);
+ break;
+ }
+ break;
+ case 0xAF:
+ switch (rep) {
+ case 1:
+ case 2:
+ if (rep==1) {INST_NAME("REPNZ SCASD");} else {INST_NAME("REPZ SCASD");}
+ MAYSETFLAGS();
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ CBZ_NEXT(xRCX);
+ if (rex.w) {MV(x1, xRAX);} else {AND(x1, xRAX, xMASK);}
+ ANDI(x2, xFlags, 1<<F_DF);
+ BNEZ_MARK2(x2);
+ MARK; // Part with DF==0
+ LDxw(x2, xRDI, 0);
+ ADDI(xRDI, xRDI, rex.w?8:4);
+ SUBI(xRCX, xRCX, 1);
+ if (rep==1) {BEQ_MARK3(x1, x2);} else {BNE_MARK3(x1, x2);}
+ BNE_MARK(xRCX, xZR);
+ B_MARK3_nocond;
+ MARK2; // Part with DF==1
+ LDxw(x2, xRDI, 0);
+ SUBI(xRDI, xRDI, rex.w?8:4);
+ SUBI(xRCX, xRCX, 1);
+ if (rep==1) {BEQ_MARK3(x1, x2);} else {BNE_MARK3(x1, x2);}
+ BNE_MARK2(xRCX, xZR);
+ MARK3; // end
+ emit_cmp32(dyn, ninst, rex, x1, x2, x3, x4, x5, x6);
+ break;
+ default:
+ INST_NAME("SCASD");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETDIR(x3, x1, rex.w?8:4);
+ AND(x1, xRAX, xMASK);
+ LDxw(x2, xRDI, 0);
+ ADD(xRDI, xRDI, x3);
+ emit_cmp32(dyn, ninst, rex, x1, x2, x3, x4, x5, x6);
+ break;
+ }
+ break;
+ case 0xB0:
+ case 0xB1:
+ case 0xB2:
+ case 0xB3:
+ INST_NAME("MOV xL, Ib");
+ u8 = F8;
+ if(rex.rex)
+ gb1 = xRAX+(opcode&7)+(rex.b<<3);
+ else
+ gb1 = xRAX+(opcode&3);
+ ANDI(gb1, gb1, ~0xff);
+ ORI(gb1, gb1, u8);
+ break;
+ case 0xB4:
+ case 0xB5:
+ case 0xB6:
+ case 0xB7:
+ INST_NAME("MOV xH, Ib");
+ u8 = F8;
+ if(rex.rex) {
+ gb1 = xRAX+(opcode&7)+(rex.b<<3);
+ ANDI(gb1, gb1, ~0xff);
+ ORI(gb1, gb1, u8);
+ } else {
+ MOV32w(x1, u8);
+ gb1 = xRAX+(opcode&3);
+ MOV64x(x2, 0xffffffffffff00ffLL);
+ AND(gb1, gb1, x2);
+ SLLI(x1, x1, 8);
+ OR(gb1, gb1, x1);
+ }
+ break;
+ case 0xB8:
+ case 0xB9:
+ case 0xBA:
+ case 0xBB:
+ case 0xBC:
+ case 0xBD:
+ case 0xBE:
+ case 0xBF:
+ INST_NAME("MOV Reg, Id");
+ gd = xRAX+(opcode&7)+(rex.b<<3);
+ if(rex.w) {
+ u64 = F64;
+ MOV64x(gd, u64);
+ } else {
+ u32 = F32;
+ MOV32w(gd, u32);
+ }
+ break;
+ default:
+ DEFAULT;
+ }
+
+ return addr;
+}
diff --git a/src/dynarec/rv64/dynarec_rv64_00_3.c b/src/dynarec/rv64/dynarec_rv64_00_3.c
new file mode 100644
index 0000000..dece35a
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_00_3.c
@@ -0,0 +1,1198 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <stddef.h>
+#include <errno.h>
+#include <signal.h>
+#include <assert.h>
+
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "emu/x64run_private.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "bridge.h"
+#include "emu/x64run_private.h"
+#include "x64trace.h"
+#include "dynarec_native.h"
+#include "custommem.h"
+
+#include "rv64_printer.h"
+#include "dynarec_rv64_private.h"
+#include "dynarec_rv64_functions.h"
+#include "dynarec_rv64_helper.h"
+
+int isSimpleWrapper(wrapper_t fun);
+int isRetX87Wrapper(wrapper_t fun);
+
+uintptr_t dynarec64_00_3(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog)
+{
+ uint8_t nextop, opcode;
+ uint8_t gd, ed;
+ int8_t i8;
+ int32_t i32, tmp;
+ int64_t i64, j64;
+ uint8_t u8;
+ uint8_t gb1, gb2, eb1, eb2;
+ uint32_t u32;
+ uint64_t u64;
+ uint8_t wback, wb1, wb2, wb;
+ int64_t fixedaddress;
+ int lock;
+ int cacheupd = 0;
+
+ opcode = F8;
+ MAYUSE(eb1);
+ MAYUSE(eb2);
+ MAYUSE(j64);
+ MAYUSE(wb);
+ MAYUSE(lock);
+ MAYUSE(cacheupd);
+
+ switch(opcode) {
+ case 0xC0:
+ nextop = F8;
+ switch((nextop>>3)&7) {
+ case 0:
+ INST_NAME("ROL Eb, Ib");
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ SETFLAGS(X_OF|X_CF, SF_SET);
+ GETEB(x1, 1);
+ u8 = F8;
+ MOV32w(x2, u8);
+ CALL_(rol8, ed, x3);
+ EBBACK(x5, 0);
+ break;
+ case 1:
+ INST_NAME("ROR Eb, Ib");
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ SETFLAGS(X_OF|X_CF, SF_SET);
+ GETEB(x1, 1);
+ u8 = F8;
+ MOV32w(x2, u8);
+ CALL_(ror8, ed, x3);
+ EBBACK(x5, 0);
+ break;
+ case 4:
+ case 6:
+ INST_NAME("SHL Eb, Ib");
+ GETEB(x1, 1);
+ u8 = (F8)&0x1f;
+ if(u8) {
+ SETFLAGS(X_ALL, SF_PENDING);
+ UFLAG_IF{
+ MOV32w(x4, u8); UFLAG_OP2(x4);
+ };
+ UFLAG_OP1(ed);
+ SLLIW(ed, ed, u8);
+ EBBACK(x5, 1);
+ UFLAG_RES(ed);
+ UFLAG_DF(x3, d_shl8);
+ } else {
+ NOP();
+ }
+ break;
+ case 5:
+ INST_NAME("SHR Eb, Ib");
+ GETEB(x1, 1);
+ u8 = (F8)&0x1f;
+ if(u8) {
+ SETFLAGS(X_ALL, SF_PENDING);
+ UFLAG_IF{
+ MOV32w(x4, u8); UFLAG_OP2(x4);
+ };
+ UFLAG_OP1(ed);
+ if(u8) {
+ SRLIW(ed, ed, u8);
+ EBBACK(x5, 1);
+ }
+ UFLAG_RES(ed);
+ UFLAG_DF(x3, d_shr8);
+ } else {
+ NOP();
+ }
+ break;
+ case 7:
+ INST_NAME("SAR Eb, Ib");
+ GETSEB(x1, 1);
+ u8 = (F8)&0x1f;
+ if(u8) {
+ SETFLAGS(X_ALL, SF_PENDING);
+ UFLAG_IF{
+ MOV32w(x4, u8); UFLAG_OP2(x4);
+ };
+ UFLAG_OP1(ed);
+ if(u8) {
+ SRAIW(ed, ed, u8);
+ EBBACK(x5, 1);
+ }
+ UFLAG_RES(ed);
+ UFLAG_DF(x3, d_sar8);
+ } else {
+ NOP();
+ }
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+ case 0xC1:
+ nextop = F8;
+ switch((nextop>>3)&7) {
+ case 0:
+ INST_NAME("ROL Ed, Ib");
+ SETFLAGS(X_OF|X_CF, SF_SUBSET_PENDING);
+ GETED(1);
+ u8 = (F8)&(rex.w?0x3f:0x1f);
+ emit_rol32c(dyn, ninst, rex, ed, u8, x3, x4);
+ if(u8) { WBACK; }
+ if(!wback && !rex.w) ZEROUP(ed);
+ break;
+ case 1:
+ INST_NAME("ROR Ed, Ib");
+ SETFLAGS(X_OF|X_CF, SF_SUBSET_PENDING);
+ GETED(1);
+ u8 = (F8)&(rex.w?0x3f:0x1f);
+ emit_ror32c(dyn, ninst, rex, ed, u8, x3, x4);
+ if(u8) { WBACK; }
+ if(!wback && !rex.w) ZEROUP(ed);
+ break;
+ case 4:
+ case 6:
+ INST_NAME("SHL Ed, Ib");
+ SETFLAGS(X_ALL, SF_SET_PENDING); // some flags are left undefined
+ GETED(1);
+ u8 = (F8)&(rex.w?0x3f:0x1f);
+ emit_shl32c(dyn, ninst, rex, ed, u8, x3, x4, x5);
+ if(u8) WBACK;
+ break;
+ case 5:
+ INST_NAME("SHR Ed, Ib");
+ SETFLAGS(X_ALL, SF_SET_PENDING); // some flags are left undefined
+ GETED(1);
+ u8 = (F8)&(rex.w?0x3f:0x1f);
+ emit_shr32c(dyn, ninst, rex, ed, u8, x3, x4);
+ if(u8) { WBACK; }
+ break;
+ case 7:
+ INST_NAME("SAR Ed, Ib");
+ SETFLAGS(X_ALL, SF_SET_PENDING); // some flags are left undefined
+ GETED(1);
+ u8 = (F8)&(rex.w?0x3f:0x1f);
+ emit_sar32c(dyn, ninst, rex, ed, u8, x3, x4);
+ if(u8) { WBACK; }
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+ case 0xC2:
+ INST_NAME("RETN");
+ //SETFLAGS(X_ALL, SF_SET); // Hack, set all flags (to an unknown state...)
+ if(box64_dynarec_safeflags) {
+ READFLAGS(X_PEND); // lets play safe here too
+ }
+ BARRIER(BARRIER_FLOAT);
+ i32 = F16;
+ retn_to_epilog(dyn, ninst, rex, i32);
+ *need_epilog = 0;
+ *ok = 0;
+ break;
+ case 0xC3:
+ INST_NAME("RET");
+ // SETFLAGS(X_ALL, SF_SET); // Hack, set all flags (to an unknown state...)
+ if(box64_dynarec_safeflags) {
+ READFLAGS(X_PEND); // so instead, force the deferred flags, so it's not too slow, and flags are not lost
+ }
+ BARRIER(BARRIER_FLOAT);
+ ret_to_epilog(dyn, ninst, rex);
+ *need_epilog = 0;
+ *ok = 0;
+ break;
+
+ case 0xC6:
+ INST_NAME("MOV Eb, Ib");
+ nextop=F8;
+ if(MODREG) { // reg <= u8
+ u8 = F8;
+ if(!rex.rex) {
+ ed = (nextop&7);
+ eb1 = xRAX+(ed&3); // Ax, Cx, Dx or Bx
+ eb2 = (ed&4)>>2; // L or H
+ } else {
+ eb1 = xRAX+(nextop&7)+(rex.b<<3);
+ eb2 = 0;
+ }
+
+ if (eb2) {
+ // load a mask to x3 (ffffffffffff00ff)
+ LUI(x3, 0xffff0);
+ ORI(x3, x3, 0xff);
+ // apply mask
+ AND(eb1, eb1, x3);
+ if(u8) {
+ if((u8<<8)<2048) {
+ ADDI(x4, xZR, u8<<8);
+ } else {
+ ADDI(x4, xZR, u8);
+ SLLI(x4, x4, 8);
+ }
+ OR(eb1, eb1, x4);
+ }
+ } else {
+ ANDI(eb1, eb1, 0xf00); // mask ffffffffffffff00
+ ORI(eb1, eb1, u8);
+ }
+ } else { // mem <= u8
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, &lock, 0, 1);
+ u8 = F8;
+ if(u8) {
+ ADDI(x3, xZR, u8);
+ ed = x3;
+ } else
+ ed = xZR;
+ SB(ed, wback, fixedaddress);
+ SMWRITELOCK(lock);
+ }
+ break;
+ case 0xC7:
+ INST_NAME("MOV Ed, Id");
+ nextop=F8;
+ if(MODREG) { // reg <= i32
+ i64 = F32S;
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ MOV64xw(ed, i64);
+ } else { // mem <= i32
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, &lock, 0, 4);
+ i64 = F32S;
+ if(i64) {
+ MOV64xw(x3, i64);
+ ed = x3;
+ } else
+ ed = xZR;
+ SDxw(ed, wback, fixedaddress);
+ SMWRITELOCK(lock);
+ }
+ break;
+
+ case 0xC9:
+ INST_NAME("LEAVE");
+ MVz(xRSP, xRBP);
+ POP1z(xRBP);
+ break;
+
+ case 0xCC:
+ SETFLAGS(X_ALL, SF_SET); // Hack, set all flags (to an unknown state...)
+ SKIPTEST(x1);
+ if(PK(0)=='S' && PK(1)=='C') {
+ addr+=2;
+ BARRIER(BARRIER_FLOAT);
+ INST_NAME("Special Box64 instruction");
+ if((PK64(0)==0))
+ {
+ addr+=8;
+ MESSAGE(LOG_DEBUG, "Exit x64 Emu\n");
+ //GETIP(ip+1+2); // no use
+ //STORE_XEMU_REGS(xRIP); // no need, done in epilog
+ MOV64x(x1, 1);
+ SW(x1, xEmu, offsetof(x64emu_t, quit));
+ *ok = 0;
+ *need_epilog = 1;
+ } else {
+ MESSAGE(LOG_DUMP, "Native Call to %s\n", GetNativeName(GetNativeFnc(ip)));
+ x87_forget(dyn, ninst, x3, x4, 0);
+ sse_purge07cache(dyn, ninst, x3);
+ // disabling isSimpleWrapper because all signed value less than 64bits needs to be sign extended
+ // and return value needs to be cleanned up
+ tmp = 0;//isSimpleWrapper(*(wrapper_t*)(addr));
+ if(isRetX87Wrapper(*(wrapper_t*)(addr)))
+ // return value will be on the stack, so the stack depth needs to be updated
+ x87_purgecache(dyn, ninst, 0, x3, x1, x4);
+ if(tmp<0 || tmp>1)
+ tmp=0; //TODO: removed when FP is in place
+ if((box64_log<2 && !cycle_log) && tmp) {
+ //GETIP(ip+3+8+8); // read the 0xCC
+ call_n(dyn, ninst, *(void**)(addr+8), tmp);
+ addr+=8+8;
+ } else {
+ GETIP(ip+1); // read the 0xCC
+ STORE_XEMU_CALL();
+ ADDI(x1, xEmu, (uint32_t)offsetof(x64emu_t, ip)); // setup addr as &emu->ip
+ CALL_S(x64Int3, -1);
+ LOAD_XEMU_CALL();
+ addr+=8+8;
+ TABLE64(x3, addr); // expected return address
+ BNE_MARK(xRIP, x3);
+ LW(w1, xEmu, offsetof(x64emu_t, quit));
+ CBZ_NEXT(w1);
+ MARK;
+ jump_to_epilog_fast(dyn, 0, xRIP, ninst);
+ }
+ }
+ } else {
+ #if 1
+ INST_NAME("INT 3");
+ // check if TRAP signal is handled
+ LD(x1, xEmu, offsetof(x64emu_t, context));
+ MOV64x(x2, offsetof(box64context_t, signals[SIGTRAP]));
+ ADD(x2, x2, x1);
+ LD(x3, x2, 0);
+ CBNZ_NEXT(x3);
+ MOV64x(x1, SIGTRAP);
+ CALL_(raise, -1, 0);
+ break;
+ #else
+ DEFAULT;
+ #endif
+ }
+ break;
+ case 0xCD:
+ u8 = F8;
+ if (box64_wine && u8 == 0x2D) {
+ INST_NAME("INT 2D");
+ // lets do nothing
+ MESSAGE(LOG_INFO, "INT 2D Windows anti-debug hack\n");
+ } else if (u8 == 0x80) {
+ INST_NAME("32bits SYSCALL");
+ NOTEST(x1);
+ SMEND();
+ GETIP(addr);
+ STORE_XEMU_CALL();
+ CALL_S(x86Syscall, -1);
+ LOAD_XEMU_CALL();
+ TABLE64(x3, addr); // expected return address
+ BNE_MARK(xRIP, x3);
+ LW(x1, xEmu, offsetof(x64emu_t, quit));
+ BEQ_NEXT(x1, xZR);
+ MARK;
+ LOAD_XEMU_REM();
+ jump_to_epilog(dyn, 0, xRIP, ninst);
+ } else {
+ INST_NAME("INT n");
+ SETFLAGS(X_ALL, SF_SET); // Hack to set flags in "don't care" state
+ GETIP(ip);
+ STORE_XEMU_CALL();
+ CALL(native_priv, -1);
+ LOAD_XEMU_CALL();
+ jump_to_epilog(dyn, 0, xRIP, ninst);
+ *need_epilog = 0;
+ *ok = 0;
+ }
+ break;
+ case 0xCF:
+ INST_NAME("IRET");
+ SETFLAGS(X_ALL, SF_SET); // Not a hack, EFLAGS are restored
+ BARRIER(BARRIER_FLOAT);
+ iret_to_epilog(dyn, ninst, rex.w);
+ *need_epilog = 0;
+ *ok = 0;
+ break;
+ case 0xD0:
+ case 0xD2: // TODO: Jump if CL is 0
+ nextop = F8;
+ switch((nextop>>3)&7) {
+ case 0:
+ if(opcode==0xD0) {
+ INST_NAME("ROL Eb, 1");
+ MOV32w(x2, 1);
+ } else {
+ INST_NAME("ROL Eb, CL");
+ ANDI(x2, xRCX, 7);
+ }
+ SETFLAGS(X_OF|X_CF, SF_PENDING);
+ GETEB(x1, 0);
+ UFLAG_OP12(ed, x2);
+ SLL(x3, ed, x2);
+ SRLI(x4, x3, 8);
+ OR(ed, x3, x4);
+ EBBACK(x5, 1);
+ UFLAG_RES(ed);
+ UFLAG_DF(x3, d_rol8);
+ break;
+ case 1:
+ if(opcode==0xD0) {
+ INST_NAME("ROR Eb, 1");
+ MOV32w(x2, 1);
+ } else {
+ INST_NAME("ROR Eb, CL");
+ ANDI(x2, xRCX, 7);
+ }
+ SETFLAGS(X_OF|X_CF, SF_PENDING);
+ GETEB(x1, 0);
+ UFLAG_OP12(ed, x2);
+ SRL(x3, ed, x2);
+ SLLI(x4, ed, 8);
+ SRL(x4, x4, x2);
+ OR(ed, x3, x4);
+ EBBACK(x5, 1);
+ UFLAG_RES(ed);
+ UFLAG_DF(x3, d_ror8);
+ break;
+ case 4:
+ case 6:
+ if(opcode==0xD0) {
+ INST_NAME("SHL Eb, 1");
+ MOV32w(x2, 1);
+ } else {
+ INST_NAME("SHL Eb, CL");
+ ANDI(x2, xRCX, 7);
+ }
+ SETFLAGS(X_ALL, SF_PENDING);
+ GETEB(x1, 0);
+ UFLAG_OP12(ed, x2)
+ SLL(ed, ed, x2);
+ EBBACK(x5, 1);
+ UFLAG_RES(ed);
+ UFLAG_DF(x3, d_shl8);
+ break;
+ case 5:
+ if(opcode==0xD0) {
+ INST_NAME("SHR Eb, 1");
+ MOV32w(x4, 1);
+ } else {
+ INST_NAME("SHR Eb, CL");
+ ANDI(x4, xRCX, 0x1F);
+ }
+ SETFLAGS(X_ALL, SF_PENDING);
+ GETEB(x1, 0);
+ UFLAG_OP12(ed, x4);
+ SRLW(ed, ed, x4);
+ EBBACK(x5, 1);
+ UFLAG_RES(ed);
+ UFLAG_DF(x3, d_shr8);
+ break;
+ case 7:
+ if(opcode==0xD0) {
+ INST_NAME("SAR Eb, 1");
+ MOV32w(x4, 1);
+ } else {
+ INST_NAME("SAR Eb, CL");
+ ANDI(x4, xRCX, 0x1f);
+ }
+ SETFLAGS(X_ALL, SF_PENDING);
+ GETSEB(x1, 0);
+ UFLAG_OP12(ed, x4)
+ SRA(ed, ed, x4);
+ EBBACK(x3, 1);
+ UFLAG_RES(ed);
+ UFLAG_DF(x3, d_sar8);
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+ case 0xD1:
+ nextop = F8;
+ switch((nextop>>3)&7) {
+ case 0:
+ INST_NAME("ROL Ed, 1");
+ SETFLAGS(X_OF|X_CF, SF_SUBSET_PENDING);
+ GETED(0);
+ emit_rol32c(dyn, ninst, rex, ed, 1, x3, x4);
+ WBACK;
+ if(!wback && !rex.w) ZEROUP(ed);
+ break;
+ case 1:
+ INST_NAME("ROR Ed, 1");
+ SETFLAGS(X_OF|X_CF, SF_SUBSET_PENDING);
+ GETED(0);
+ emit_ror32c(dyn, ninst, rex, ed, 1, x3, x4);
+ WBACK;
+ if(!wback && !rex.w) ZEROUP(ed);
+ break;
+ case 3:
+ INST_NAME("RCR Ed, 1");
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ READFLAGS(X_CF);
+ SETFLAGS(X_OF|X_CF, SF_SET);
+ MOV32w(x2, 1);
+ GETEDW(x4, x1, 0);
+ CALL_(rex.w?((void*)rcr64):((void*)rcr32), ed, x4);
+ WBACK;
+ break;
+ case 4:
+ case 6:
+ INST_NAME("SHL Ed, 1");
+ SETFLAGS(X_ALL, SF_SET_PENDING); // some flags are left undefined
+ GETED(0);
+ emit_shl32c(dyn, ninst, rex, ed, 1, x3, x4, x5);
+ WBACK;
+ break;
+ case 5:
+ INST_NAME("SHR Ed, 1");
+ SETFLAGS(X_ALL, SF_SET_PENDING); // some flags are left undefined
+ GETED(0);
+ emit_shr32c(dyn, ninst, rex, ed, 1, x3, x4);
+ WBACK;
+ break;
+ case 7:
+ INST_NAME("SAR Ed, 1");
+ SETFLAGS(X_ALL, SF_SET_PENDING); // some flags are left undefined
+ GETED(0);
+ emit_sar32c(dyn, ninst, rex, ed, 1, x3, x4);
+ WBACK;
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+
+ case 0xD3:
+ nextop = F8;
+ switch((nextop>>3)&7) {
+ case 0:
+ INST_NAME("ROL Ed, CL");
+ SETFLAGS(X_OF|X_CF, SF_SUBSET);
+ GETED(0);
+ emit_rol32(dyn, ninst, rex, ed, xRCX, x3, x4);
+ WBACK;
+ if(!wback && !rex.w) ZEROUP(ed);
+ break;
+ case 1:
+ INST_NAME("ROR Ed, CL");
+ SETFLAGS(X_OF|X_CF, SF_SUBSET);
+ GETED(0);
+ emit_ror32(dyn, ninst, rex, ed, xRCX, x3, x4);
+ WBACK;
+ if(!wback && !rex.w) ZEROUP(ed);
+ break;
+ case 4:
+ case 6:
+ INST_NAME("SHL Ed, CL");
+ SETFLAGS(X_ALL, SF_SET_PENDING); // some flags are left undefined
+ ANDI(x3, xRCX, rex.w?0x3f:0x1f);
+ GETED(0);
+ if(!rex.w && MODREG) {ZEROUP(ed);}
+ CBZ_NEXT(x3);
+ emit_shl32(dyn, ninst, rex, ed, x3, x5, x4, x6);
+ WBACK;
+ break;
+ case 5:
+ INST_NAME("SHR Ed, CL");
+ SETFLAGS(X_ALL, SF_SET_PENDING); // some flags are left undefined
+ ANDI(x3, xRCX, rex.w?0x3f:0x1f);
+ GETED(0);
+ if(!rex.w && MODREG) {ZEROUP(ed);}
+ CBZ_NEXT(x3);
+ emit_shr32(dyn, ninst, rex, ed, x3, x5, x4);
+ WBACK;
+ break;
+ case 7:
+ INST_NAME("SAR Ed, CL");
+ SETFLAGS(X_ALL, SF_PENDING);
+ ANDI(x3, xRCX, rex.w?0x3f:0x1f);
+ GETED(0);
+ if(!rex.w && MODREG) {ZEROUP(ed);}
+ CBZ_NEXT(x3);
+ UFLAG_OP12(ed, x3);
+ SRAxw(ed, ed, x3);
+ WBACK;
+ UFLAG_RES(ed);
+ UFLAG_DF(x3, rex.w?d_sar64:d_sar32);
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+
+ case 0xD8:
+ addr = dynarec64_D8(dyn, addr, ip, ninst, rex, rep, ok, need_epilog);
+ break;
+ case 0xD9:
+ addr = dynarec64_D9(dyn, addr, ip, ninst, rex, rep, ok, need_epilog);
+ break;
+
+ case 0xDB:
+ addr = dynarec64_DB(dyn, addr, ip, ninst, rex, rep, ok, need_epilog);
+ break;
+ case 0xDC:
+ addr = dynarec64_DC(dyn, addr, ip, ninst, rex, rep, ok, need_epilog);
+ break;
+ case 0xDD:
+ addr = dynarec64_DD(dyn, addr, ip, ninst, rex, rep, ok, need_epilog);
+ break;
+
+ case 0xDE:
+ addr = dynarec64_DE(dyn, addr, ip, ninst, rex, rep, ok, need_epilog);
+ break;
+ case 0xDF:
+ addr = dynarec64_DF(dyn, addr, ip, ninst, rex, rep, ok, need_epilog);
+ break;
+ #define GO(Z) \
+ BARRIER(BARRIER_MAYBE); \
+ JUMP(addr+i8, 1); \
+ if(dyn->insts[ninst].x64.jmp_insts==-1 || \
+ CHECK_CACHE()) { \
+ /* out of the block */ \
+ i32 = dyn->insts[ninst].epilog-(dyn->native_size); \
+ if(Z) {BNE(xRCX, xZR, i32);} else {BEQ(xRCX, xZR, i32);}; \
+ if(dyn->insts[ninst].x64.jmp_insts==-1) { \
+ if(!(dyn->insts[ninst].x64.barrier&BARRIER_FLOAT)) \
+ fpu_purgecache(dyn, ninst, 1, x1, x2, x3); \
+ jump_to_next(dyn, addr+i8, 0, ninst); \
+ } else { \
+ CacheTransform(dyn, ninst, cacheupd, x1, x2, x3); \
+ i32 = dyn->insts[dyn->insts[ninst].x64.jmp_insts].address-(dyn->native_size); \
+ B(i32); \
+ } \
+ } else { \
+ /* inside the block */ \
+ i32 = dyn->insts[dyn->insts[ninst].x64.jmp_insts].address-(dyn->native_size); \
+ if(Z) {BEQ(xRCX, xZR, i32);} else {BNE(xRCX, xZR, i32);}; \
+ }
+ case 0xE0:
+ INST_NAME("LOOPNZ");
+ READFLAGS(X_ZF);
+ i8 = F8S;
+ SUBI(xRCX, xRCX, 1);
+ ANDI(x1, xFlags, 1 << F_ZF);
+ CBNZ_NEXT(x1);
+ GO(0);
+ break;
+ case 0xE1:
+ INST_NAME("LOOPZ");
+ READFLAGS(X_ZF);
+ i8 = F8S;
+ SUBI(xRCX, xRCX, 1);
+ ANDI(x1, xFlags, 1 << F_ZF);
+ CBZ_NEXT(x1);
+ GO(0);
+ break;
+ case 0xE2:
+ INST_NAME("LOOP");
+ i8 = F8S;
+ SUBI(xRCX, xRCX, 1);
+ GO(0);
+ break;
+ case 0xE3:
+ INST_NAME("JECXZ");
+ i8 = F8S;
+ GO(1);
+ break;
+ #undef GO
+
+ case 0xE8:
+ INST_NAME("CALL Id");
+ i32 = F32S;
+ if(addr+i32==0) {
+ #if STEP == 3
+ printf_log(LOG_INFO, "Warning, CALL to 0x0 at %p (%p)\n", (void*)addr, (void*)(addr-1));
+ #endif
+ }
+ #if STEP < 2
+ if(!rex.is32bits && isNativeCall(dyn, addr+i32, &dyn->insts[ninst].natcall, &dyn->insts[ninst].retn))
+ tmp = dyn->insts[ninst].pass2choice = 3;
+ else
+ tmp = dyn->insts[ninst].pass2choice = 0;
+ #else
+ tmp = dyn->insts[ninst].pass2choice;
+ #endif
+ switch(tmp) {
+ case 3:
+ SETFLAGS(X_ALL, SF_SET); // Hack to set flags to "dont'care" state
+ SKIPTEST(x1);
+ BARRIER(BARRIER_FULL);
+ //BARRIER_NEXT(BARRIER_FULL);
+ if(dyn->last_ip && (addr-dyn->last_ip<0x1000)) {
+ ADDI(x2, xRIP, addr-dyn->last_ip);
+ } else {
+ TABLE64(x2, addr);
+ }
+ PUSH1(x2);
+ MESSAGE(LOG_DUMP, "Native Call to %s (retn=%d)\n", GetNativeName(GetNativeFnc(dyn->insts[ninst].natcall-1)), dyn->insts[ninst].retn);
+ // calling a native function
+ sse_purge07cache(dyn, ninst, x3);
+ if((box64_log<2 && !cycle_log) && dyn->insts[ninst].natcall) {
+ // disabling isSimpleWrapper because all signed value less than 64bits needs to be sign extended
+ // and return value needs to be cleanned up
+ tmp=0;//isSimpleWrapper(*(wrapper_t*)(dyn->insts[ninst].natcall+2));
+ if(tmp>1 || tmp<0)
+ tmp=0; // float paramters not ready!
+ } else
+ tmp=0;
+ if(dyn->insts[ninst].natcall && isRetX87Wrapper(*(wrapper_t*)(dyn->insts[ninst].natcall+2)))
+ // return value will be on the stack, so the stack depth needs to be updated
+ x87_purgecache(dyn, ninst, 0, x3, x1, x4);
+ if((box64_log<2 && !cycle_log) && dyn->insts[ninst].natcall && tmp) {
+ //GETIP(ip+3+8+8); // read the 0xCC
+ call_n(dyn, ninst, *(void**)(dyn->insts[ninst].natcall+2+8), tmp);
+ POP1(xRIP); // pop the return address
+ dyn->last_ip = addr;
+ } else {
+ GETIP_(dyn->insts[ninst].natcall); // read the 0xCC already
+ STORE_XEMU_CALL();
+ ADDI(x1, xEmu, (uint32_t)offsetof(x64emu_t, ip)); // setup addr as &emu->ip
+ CALL_S(x64Int3, -1);
+ LOAD_XEMU_CALL();
+ TABLE64(x3, dyn->insts[ninst].natcall);
+ ADDI(x3, x3, 2+8+8);
+ BNE_MARK(xRIP, x3); // Not the expected address, exit dynarec block
+ POP1(xRIP); // pop the return address
+ if(dyn->insts[ninst].retn) {
+ if(dyn->insts[ninst].retn<0x1000) {
+ ADDI(xRSP, xRSP, dyn->insts[ninst].retn);
+ } else {
+ MOV64x(x3, dyn->insts[ninst].retn);
+ ADD(xRSP, xRSP, x3);
+ }
+ }
+ TABLE64(x3, addr);
+ BNE_MARK(xRIP, x3); // Not the expected address again
+ LW(w1, xEmu, offsetof(x64emu_t, quit));
+ CBZ_NEXT(w1);
+ MARK;
+ jump_to_epilog_fast(dyn, 0, xRIP, ninst);
+ dyn->last_ip = addr;
+ }
+ break;
+ default:
+ if((box64_dynarec_safeflags>1) || (ninst && dyn->insts[ninst-1].x64.set_flags)) {
+ READFLAGS(X_PEND); // that's suspicious
+ } else {
+ SETFLAGS(X_ALL, SF_SET); // Hack to set flags to "dont'care" state
+ }
+ // regular call
+ //BARRIER_NEXT(1);
+ if(box64_dynarec_callret && box64_dynarec_bigblock>1) {
+ BARRIER(BARRIER_FULL);
+ } else {
+ BARRIER(BARRIER_FLOAT);
+ *need_epilog = 0;
+ *ok = 0;
+ }
+
+ if(rex.is32bits) {
+ MOV32w(x2, addr);
+ } else {
+ TABLE64(x2, addr);
+ }
+ PUSH1z(x2);
+ // TODO: Add support for CALLRET optim
+ /*if(box64_dynarec_callret) {
+ // Push actual return address
+ if(addr < (dyn->start+dyn->isize)) {
+ // there is a next...
+ j64 = (dyn->insts)?(dyn->insts[ninst].epilog-(dyn->native_size)):0;
+ ADR_S20(x4, j64);
+ } else {
+ j64 = getJumpTableAddress64(addr);
+ TABLE64(x4, j64);
+ LDR(x4, x4, 0);
+ }
+ PUSH1(x4);
+ PUSH1(x2);
+ } else */ //CALLRET optim disable for now.
+ {
+ *ok = 0;
+ *need_epilog = 0;
+ }
+ jump_to_next(dyn, addr+i32, 0, ninst);
+ break;
+ }
+ break;
+ case 0xE9:
+ case 0xEB:
+ BARRIER(BARRIER_MAYBE);
+ if(opcode==0xE9) {
+ INST_NAME("JMP Id");
+ i32 = F32S;
+ } else {
+ INST_NAME("JMP Ib");
+ i32 = F8S;
+ }
+ JUMP((uintptr_t)getAlternate((void*)(addr+i32)), 0);
+ if(dyn->insts[ninst].x64.jmp_insts==-1) {
+ // out of the block
+ fpu_purgecache(dyn, ninst, 1, x1, x2, x3);
+ jump_to_next(dyn, (uintptr_t)getAlternate((void*)(addr+i32)), 0, ninst);
+ } else {
+ // inside the block
+ CacheTransform(dyn, ninst, CHECK_CACHE(), x1, x2, x3);
+ tmp = dyn->insts[dyn->insts[ninst].x64.jmp_insts].address-(dyn->native_size);
+ MESSAGE(1, "Jump to %d / 0x%x\n", tmp, tmp);
+ if(tmp==4) {
+ NOP();
+ } else {
+ B(tmp);
+ }
+ }
+ *need_epilog = 0;
+ *ok = 0;
+ break;
+ case 0xF0:
+ addr = dynarec64_F0(dyn, addr, ip, ninst, rex, rep, ok, need_epilog);
+ break;
+ case 0xF5:
+ INST_NAME("CMC");
+ READFLAGS(X_CF);
+ SETFLAGS(X_CF, SF_SUBSET);
+ XORI(xFlags, xFlags, 1<<F_CF);
+ break;
+ case 0xF6:
+ nextop = F8;
+ switch((nextop>>3)&7) {
+ case 0:
+ case 1:
+ INST_NAME("TEST Eb, Ib");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEB(x1, 1);
+ u8 = F8;
+ MOV32w(x2, u8);
+ emit_test8(dyn, ninst, x1, x2, x3, x4, x5);
+ break;
+ case 2:
+ INST_NAME("NOT Eb");
+ GETEB(x1, 0);
+ NOT(x1, x1);
+ EBBACK(x5, 1);
+ break;
+ case 3:
+ INST_NAME("NEG Eb");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEB(x1, 0);
+ emit_neg8(dyn, ninst, x1, x2, x4);
+ EBBACK(x5, 0);
+ break;
+ case 4:
+ INST_NAME("MUL AL, Ed");
+ SETFLAGS(X_ALL, SF_PENDING);
+ UFLAG_DF(x1, d_mul8);
+ GETEB(x1, 0);
+ ANDI(x2, xRAX, 0xff);
+ MULW(x1, x2, x1);
+ UFLAG_RES(x1);
+ LUI(x2, 0xffff0);
+ AND(xRAX, xRAX, x2);
+ ZEXTH(x1, x1);
+ OR(xRAX, xRAX, x1);
+ break;
+ case 5:
+ INST_NAME("IMUL AL, Eb");
+ SETFLAGS(X_ALL, SF_PENDING);
+ UFLAG_DF(x1, d_imul8);
+ GETSEB(x1, 0);
+ SLLI(x2, xRAX, 56);
+ SRAI(x2, x2, 56);
+ MULW(x1, x2, x1);
+ UFLAG_RES(x1);
+ LUI(x2, 0xffff0);
+ AND(xRAX, xRAX, x2);
+ ZEXTH(x1, x1);
+ OR(xRAX, xRAX, x1);
+ break;
+ case 6:
+ INST_NAME("DIV Eb");
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ SETFLAGS(X_ALL, SF_SET);
+ GETEB(x1, 0);
+ CALL(div8, -1);
+ break;
+ case 7:
+ INST_NAME("IDIV Eb");
+ SKIPTEST(x1);
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ SETFLAGS(X_ALL, SF_SET);
+ GETEB(x1, 0);
+ CALL(idiv8, -1);
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+ case 0xF7:
+ nextop = F8;
+ switch((nextop>>3)&7) {
+ case 0:
+ case 1:
+ INST_NAME("TEST Ed, Id");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETED(4);
+ i64 = F32S;
+ emit_test32c(dyn, ninst, rex, ed, i64, x3, x4, x5);
+ break;
+ case 2:
+ INST_NAME("NOT Ed");
+ GETED(0);
+ XORI(ed, ed, -1);
+ if(!rex.w && MODREG)
+ ZEROUP(ed);
+ WBACK;
+ break;
+ case 3:
+ INST_NAME("NEG Ed");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETED(0);
+ emit_neg32(dyn, ninst, rex, ed, x3, x4);
+ WBACK;
+ break;
+ case 4:
+ INST_NAME("MUL EAX, Ed");
+ SETFLAGS(X_ALL, SF_PENDING);
+ UFLAG_DF(x2, rex.w?d_mul64:d_mul32);
+ GETED(0);
+ if(rex.w) {
+ if(ed==xRDX) gd=x3; else gd=xRDX;
+ MULHU(gd, xRAX, ed);
+ MUL(xRAX, xRAX, ed);
+ if(gd!=xRDX) {MV(xRDX, gd);}
+ } else {
+ AND(x3, xRAX, xMASK);
+ if(MODREG) {
+ AND(x4, ed, xMASK);
+ ed = x4;
+ }
+ MUL(xRDX, x3, ed); //64 <- 32x32
+ AND(xRAX, xRDX, xMASK);
+ SRLI(xRDX, xRDX, 32);
+ }
+ UFLAG_RES(xRAX);
+ UFLAG_OP1(xRDX);
+ break;
+ case 5:
+ INST_NAME("IMUL EAX, Ed");
+ SETFLAGS(X_ALL, SF_PENDING);
+ UFLAG_DF(x2, rex.w?d_imul64:d_imul32);
+ GETSED(0);
+ if(rex.w) {
+ if(ed==xRDX) gd=x3; else gd=xRDX;
+ MULH(gd, xRAX, ed);
+ MUL(xRAX, xRAX, ed);
+ if(gd!=xRDX) {MV(xRDX, gd);}
+ } else {
+ ADDIW(x3, xRAX, 0); // sign extend 32bits-> 64bits
+ MUL(xRDX, x3, ed); //64 <- 32x32
+ AND(xRAX, xRDX, xMASK);
+ SRLI(xRDX, xRDX, 32);
+ }
+ UFLAG_RES(xRAX);
+ UFLAG_OP1(xRDX);
+ break;
+ case 6:
+ INST_NAME("DIV Ed");
+ SETFLAGS(X_ALL, SF_SET);
+ if(!rex.w) {
+ SET_DFNONE();
+ GETED(0);
+ SLLI(x3, xRDX, 32);
+ AND(x2, xRAX, xMASK);
+ OR(x3, x3, x2);
+ if(MODREG) {
+ AND(x4, ed, xMASK);
+ ed = x4;
+ }
+ DIVU(x2, x3, ed);
+ REMU(xRDX, x3, ed);
+ AND(xRAX, x2, xMASK);
+ ZEROUP(xRDX);
+ } else {
+ if(ninst
+ && dyn->insts[ninst-1].x64.addr
+ && *(uint8_t*)(dyn->insts[ninst-1].x64.addr)==0x31
+ && *(uint8_t*)(dyn->insts[ninst-1].x64.addr+1)==0xD2) {
+ SET_DFNONE();
+ GETED(0);
+ DIVU(x2, xRAX, ed);
+ REMU(xRDX, xRAX, ed);
+ MV(xRAX, x2);
+ } else {
+ GETEDH(x1, 0); // get edd changed addr, so cannot be called 2 times for same op...
+ BEQ_MARK(xRDX, xZR);
+ if(ed!=x1) {MV(x1, ed);}
+ CALL(div64, -1);
+ B_NEXT_nocond;
+ MARK;
+ DIVU(x2, xRAX, ed);
+ REMU(xRDX, xRAX, ed);
+ MV(xRAX, x2);
+ SET_DFNONE();
+ }
+ }
+ break;
+ case 7:
+ INST_NAME("IDIV Ed");
+ SKIPTEST(x1);
+ SETFLAGS(X_ALL, SF_SET);
+ if(!rex.w) {
+ SET_DFNONE()
+ GETSED(0);
+ SLLI(x3, xRDX, 32);
+ AND(x2, xRAX, xMASK);
+ OR(x3, x3, x2);
+ DIV(x2, x3, ed);
+ REM(xRDX, x3, ed);
+ AND(xRAX, x2, xMASK);
+ ZEROUP(xRDX);
+ } else {
+ if(ninst && dyn->insts
+ && dyn->insts[ninst-1].x64.addr
+ && *(uint8_t*)(dyn->insts[ninst-1].x64.addr)==0x48
+ && *(uint8_t*)(dyn->insts[ninst-1].x64.addr+1)==0x99) {
+ SET_DFNONE()
+ GETED(0);
+ DIV(x2, xRAX, ed);
+ REM(xRDX, xRAX, ed);
+ MV(xRAX, x2);
+ } else {
+ GETEDH(x1, 0); // get edd changed addr, so cannot be called 2 times for same op...
+ //Need to see if RDX==0 and RAX not signed
+ // or RDX==-1 and RAX signed
+ BNE_MARK2(xRDX, xZR);
+ BGE_MARK(xRAX, xZR);
+ MARK2;
+ NOT(x2, xRDX);
+ BNE_MARK3(x2, xZR);
+ BLT_MARK(xRAX, xZR);
+ MARK3;
+ if(ed!=x1) MV(x1, ed);
+ CALL((void*)idiv64, -1);
+ B_NEXT_nocond;
+ MARK;
+ DIV(x2, xRAX, ed);
+ REM(xRDX, xRAX, ed);
+ MV(xRAX, x2);
+ SET_DFNONE()
+ }
+ }
+ break;
+ default:
+ DEFAULT;
+ };
+ break;
+
+ case 0xF8:
+ INST_NAME("CLC");
+ SETFLAGS(X_CF, SF_SUBSET);
+ SET_DFNONE();
+ ANDI(xFlags, xFlags, ~(1 << F_CF));
+ break;
+ case 0xF9:
+ INST_NAME("STC");
+ SETFLAGS(X_CF, SF_SUBSET);
+ SET_DFNONE();
+ ORI(xFlags, xFlags, 1 << F_CF);
+ break;
+ case 0xFC:
+ INST_NAME("CLD");
+ ANDI(xFlags, xFlags, ~(1<<F_CF));
+ break;
+ case 0xFE:
+ nextop = F8;
+ switch((nextop>>3)&7) {
+ case 0:
+ INST_NAME("INC Eb");
+ SETFLAGS(X_ALL&~X_CF, SF_SUBSET_PENDING);
+ GETEB(x1, 0);
+ emit_inc8(dyn, ninst, ed, x2, x4, x5);
+ EBBACK(x5, 0);
+ break;
+ case 1:
+ INST_NAME("DEC Eb");
+ SETFLAGS(X_ALL&~X_CF, SF_SUBSET_PENDING);
+ GETEB(x1, 0);
+ emit_dec8(dyn, ninst, ed, x2, x4, x5);
+ EBBACK(x5, 0);
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+ case 0xFF:
+ nextop = F8;
+ switch((nextop>>3)&7) {
+ case 0: // INC Ed
+ INST_NAME("INC Ed");
+ SETFLAGS(X_ALL&~X_CF, SF_SUBSET_PENDING);
+ GETED(0);
+ emit_inc32(dyn, ninst, rex, ed, x3, x4, x5, x6);
+ WBACK;
+ break;
+ case 1: //DEC Ed
+ INST_NAME("DEC Ed");
+ SETFLAGS(X_ALL&~X_CF, SF_SUBSET_PENDING);
+ GETED(0);
+ emit_dec32(dyn, ninst, rex, ed, x3, x4, x5, x6);
+ WBACK;
+ break;
+ case 2: // CALL Ed
+ INST_NAME("CALL Ed");
+ PASS2IF((box64_dynarec_safeflags>1) ||
+ ((ninst && dyn->insts[ninst-1].x64.set_flags)
+ || ((ninst>1) && dyn->insts[ninst-2].x64.set_flags)), 1)
+ {
+ READFLAGS(X_PEND); // that's suspicious
+ } else {
+ SETFLAGS(X_ALL, SF_SET); //Hack to put flag in "don't care" state
+ }
+ GETEDz(0);
+ if(box64_dynarec_callret && box64_dynarec_bigblock>1) {
+ BARRIER(BARRIER_FULL);
+ } else {
+ BARRIER(BARRIER_FLOAT);
+ *need_epilog = 0;
+ *ok = 0;
+ }
+ GETIP_(addr);
+ // TODO: Add suport for CALLRET optim
+ /*if(box64_dynarec_callret) {
+ // Push actual return address
+ if(addr < (dyn->start+dyn->isize)) {
+ // there is a next...
+ j64 = (dyn->insts)?(dyn->insts[ninst].epilog-(dyn->native_size)):0;
+ ADR_S20(x4, j64);
+ } else {
+ j64 = getJumpTableAddress64(addr);
+ TABLE64(x4, j64);
+ LDRx_U12(x4, x4, 0);
+ }
+ STPx_S7_preindex(x4, xRIP, xSP, -16);
+ }*/
+ PUSH1z(xRIP);
+ jump_to_next(dyn, 0, ed, ninst);
+ break;
+ case 4: // JMP Ed
+ INST_NAME("JMP Ed");
+ READFLAGS(X_PEND);
+ BARRIER(BARRIER_FLOAT);
+ GETEDz(0);
+ jump_to_next(dyn, 0, ed, ninst);
+ *need_epilog = 0;
+ *ok = 0;
+ break;
+ case 5: // JMP FAR Ed
+ if(MODREG) {
+ DEFAULT;
+ } else {
+ INST_NAME("JMP FAR Ed");
+ READFLAGS(X_PEND);
+ BARRIER(BARRIER_FLOAT);
+ SMREAD()
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, NULL, 0, 0);
+ LDxw(x1, wback, 0);
+ ed = x1;
+ LHU(x3, wback, rex.w?8:4);
+ SW(x3, xEmu, offsetof(x64emu_t, segs[_CS]));
+ SW(xZR, xEmu, offsetof(x64emu_t, segs_serial[_CS]));
+ jump_to_epilog(dyn, 0, ed, ninst);
+ *need_epilog = 0;
+ *ok = 0;
+ }
+ break;
+ case 6: // Push Ed
+ INST_NAME("PUSH Ed");
+ GETEDz(0);
+ PUSH1z(ed);
+ break;
+
+ default:
+ DEFAULT;
+ }
+ break;
+ default:
+ DEFAULT;
+ }
+
+ return addr;
+}
diff --git a/src/dynarec/rv64/dynarec_rv64_0f.c b/src/dynarec/rv64/dynarec_rv64_0f.c
new file mode 100644
index 0000000..199068c
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_0f.c
@@ -0,0 +1,1742 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <stddef.h>
+#include <errno.h>
+
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "emu/x64run_private.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "emu/x64run_private.h"
+#include "x64trace.h"
+#include "dynarec_native.h"
+#include "my_cpuid.h"
+#include "emu/x87emu_private.h"
+#include "bitutils.h"
+
+#include "rv64_printer.h"
+#include "dynarec_rv64_private.h"
+#include "dynarec_rv64_functions.h"
+#include "dynarec_rv64_helper.h"
+
+uintptr_t dynarec64_0F(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int* ok, int* need_epilog)
+{
+ (void)ip; (void)need_epilog;
+
+ uint8_t opcode = F8;
+ uint8_t nextop, u8;
+ uint8_t gd, ed;
+ uint8_t wback, wb2, gback;
+ uint8_t eb1, eb2;
+ int32_t i32, i32_;
+ int cacheupd = 0;
+ int v0, v1;
+ int q0, q1;
+ int d0, d1;
+ int s0, s1;
+ uint64_t tmp64u;
+ int64_t j64;
+ int64_t fixedaddress, gdoffset;
+ int unscaled;
+ MAYUSE(wb2);
+ MAYUSE(gback);
+ MAYUSE(eb1);
+ MAYUSE(eb2);
+ MAYUSE(q0);
+ MAYUSE(q1);
+ MAYUSE(d0);
+ MAYUSE(d1);
+ MAYUSE(s0);
+ MAYUSE(j64);
+ MAYUSE(cacheupd);
+
+ switch(opcode) {
+
+ case 0x01:
+ INST_NAME("FAKE xgetbv");
+ nextop = F8;
+ addr = fakeed(dyn, addr, ninst, nextop);
+ SETFLAGS(X_ALL, SF_SET); // Hack to set flags in "don't care" state
+ GETIP(ip);
+ STORE_XEMU_CALL();
+ CALL(native_ud, -1);
+ LOAD_XEMU_CALL();
+ jump_to_epilog(dyn, 0, xRIP, ninst);
+ *need_epilog = 0;
+ *ok = 0;
+ break;
+
+ case 0x05:
+ INST_NAME("SYSCALL");
+ NOTEST(x1);
+ SMEND();
+ GETIP(addr);
+ STORE_XEMU_CALL();
+ CALL_S(x64Syscall, -1);
+ LOAD_XEMU_CALL();
+ TABLE64(x3, addr); // expected return address
+ BNE_MARK(xRIP, x3);
+ LW(w1, xEmu, offsetof(x64emu_t, quit));
+ CBZ_NEXT(w1);
+ MARK;
+ LOAD_XEMU_REM();
+ jump_to_epilog(dyn, 0, xRIP, ninst);
+ break;
+
+ case 0x09:
+ INST_NAME("WBINVD");
+ SETFLAGS(X_ALL, SF_SET); // Hack to set flags in "don't care" state
+ GETIP(ip);
+ STORE_XEMU_CALL();
+ CALL(native_ud, -1);
+ LOAD_XEMU_CALL();
+ jump_to_epilog(dyn, 0, xRIP, ninst);
+ *need_epilog = 0;
+ *ok = 0;
+ break;
+
+ case 0x0B:
+ INST_NAME("UD2");
+ SETFLAGS(X_ALL, SF_SET); // Hack to set flags in "don't care" state
+ GETIP(ip);
+ STORE_XEMU_CALL();
+ CALL(native_ud, -1);
+ LOAD_XEMU_CALL();
+ jump_to_epilog(dyn, 0, xRIP, ninst);
+ *need_epilog = 0;
+ *ok = 0;
+ break;
+
+ case 0x0D:
+ nextop = F8;
+ switch((nextop>>3)&7) {
+ case 1:
+ INST_NAME("PREFETCHW");
+ // nop without Zicbom, Zicbop, Zicboz extensions
+ FAKEED;
+ break;
+ default: //???
+ DEFAULT;
+ }
+ break;
+
+ case 0x10:
+ INST_NAME("MOVUPS Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ LD(x3, wback, fixedaddress+0);
+ LD(x4, wback, fixedaddress+8);
+ SD(x3, gback, gdoffset+0);
+ SD(x4, gback, gdoffset+8);
+ break;
+ case 0x11:
+ INST_NAME("MOVUPS Ex,Gx");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ LD(x3, gback, gdoffset+0);
+ LD(x4, gback, gdoffset+8);
+ SD(x3, wback, fixedaddress+0);
+ SD(x4, wback, fixedaddress+8);
+ if(!MODREG)
+ SMWRITE2();
+ break;
+ case 0x12:
+ nextop = F8;
+ if(MODREG) {
+ INST_NAME("MOVHLPS Gx,Ex");
+ GETGX();
+ GETEX(x2, 0);
+ LD(x3, wback, fixedaddress+8);
+ SD(x3, gback, gdoffset+0);
+ } else {
+ INST_NAME("MOVLPS Gx,Ex");
+ GETEXSD(v0, 0);
+ GETGXSD_empty(v1);
+ FMVD(v1, v0);
+ }
+ break;
+ case 0x13:
+ INST_NAME("MOVLPS Ex,Gx");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ LD(x3, gback, gdoffset+0);
+ SD(x3, wback, fixedaddress+0);
+ if(!MODREG)
+ SMWRITE2();
+ break;
+ case 0x14:
+ INST_NAME("UNPCKLPS Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ LWU(x5, gback, gdoffset+1*4);
+ LWU(x3, wback, fixedaddress+0);
+ LWU(x4, wback, fixedaddress+4);
+ SW(x4, gback, gdoffset+3*4);
+ SW(x5, gback, gdoffset+2*4);
+ SW(x3, gback, gdoffset+1*4);
+ break;
+ case 0x15:
+ INST_NAME("UNPCKHPS Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ LWU(x3, wback, fixedaddress+2*4);
+ LWU(x4, wback, fixedaddress+3*4);
+ LWU(x5, gback, gdoffset+2*4);
+ LWU(x6, gback, gdoffset+3*4);
+ SW(x5, gback, gdoffset+0*4);
+ SW(x3, gback, gdoffset+1*4);
+ SW(x6, gback, gdoffset+2*4);
+ SW(x4, gback, gdoffset+3*4);
+ break;
+ case 0x16:
+ nextop = F8;
+ if(MODREG) {
+ INST_NAME("MOVLHPS Gx,Ex");
+ } else {
+ INST_NAME("MOVHPS Gx,Ex");
+ SMREAD();
+ }
+ GETGX();
+ GETEX(x2, 0);
+ LD(x4, wback, fixedaddress+0);
+ SD(x4, gback, gdoffset+8);
+ break;
+ case 0x17:
+ INST_NAME("MOVHPS Ex,Gx");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ LD(x4, gback, gdoffset+8);
+ SD(x4, wback, fixedaddress+0);
+ if(!MODREG)
+ SMWRITE2();
+ break;
+ case 0x18:
+ nextop = F8;
+ if((nextop&0xC0)==0xC0) {
+ INST_NAME("NOP (multibyte)");
+ } else
+ switch((nextop>>3)&7) {
+ case 0:
+ case 1:
+ case 2:
+ case 3:
+ INST_NAME("PREFETCHh Ed");
+ FAKEED;
+ break;
+ default:
+ INST_NAME("NOP (multibyte)");
+ FAKEED;
+ }
+ break;
+
+ case 0x1F:
+ INST_NAME("NOP (multibyte)");
+ nextop = F8;
+ FAKEED;
+ break;
+
+ case 0x28:
+ INST_NAME("MOVAPS Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_MV_Q(x3);
+ break;
+ case 0x29:
+ INST_NAME("MOVAPS Ex,Gx");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_MV_Q2(x3);
+ if(!MODREG)
+ SMWRITE2();
+ break;
+
+ case 0x2B:
+ INST_NAME("MOVNTPS Ex,Gx");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ LD(x3, gback, gdoffset+0);
+ LD(x4, gback, gdoffset+8);
+ SD(x3, wback, fixedaddress+0);
+ SD(x4, wback, fixedaddress+8);
+ break;
+ case 0x2E:
+ // no special check...
+ case 0x2F:
+ if(opcode==0x2F) {INST_NAME("COMISS Gx, Ex");} else {INST_NAME("UCOMISS Gx, Ex");}
+ SETFLAGS(X_ALL, SF_SET);
+ SET_DFNONE();
+ nextop = F8;
+ GETGXSS(d0);
+ GETEXSS(v0, 0);
+ CLEAR_FLAGS();
+ // if isnan(d0) || isnan(v0)
+ IFX(X_ZF | X_PF | X_CF) {
+ FEQS(x3, d0, d0);
+ FEQS(x2, v0, v0);
+ AND(x2, x2, x3);
+ BNE_MARK(x2, xZR);
+ ORI(xFlags, xFlags, (1<<F_ZF) | (1<<F_PF) | (1<<F_CF));
+ B_NEXT_nocond;
+ }
+ MARK;
+ // else if isless(d0, v0)
+ IFX(X_CF) {
+ FLTS(x2, d0, v0);
+ BEQ_MARK2(x2, xZR);
+ ORI(xFlags, xFlags, 1<<F_CF);
+ B_NEXT_nocond;
+ }
+ MARK2;
+ // else if d0 == v0
+ IFX(X_ZF) {
+ FEQS(x2, d0, v0);
+ CBZ_NEXT(x2);
+ ORI(xFlags, xFlags, 1<<F_ZF);
+ }
+ break;
+ case 0x31:
+ INST_NAME("RDTSC");
+ NOTEST(x1);
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ CALL(ReadTSC, x3); // will return the u64 in x3
+ SRLI(xRDX, x3, 32);
+ AND(xRAX, x3, 32); // wipe upper part
+ break;
+ case 0x38:
+ //SSE3
+ nextop=F8;
+ switch(nextop) {
+ case 0xF0:
+ INST_NAME("MOVBE Gd, Ed");
+ nextop=F8;
+ GETGD;
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, NULL, 1, 0);
+ LDxw(gd, ed, fixedaddress);
+ if (rv64_zbb) {
+ REV8(gd, gd);
+ if (!rex.w) {
+ SRLI(gd, gd, 32);
+ }
+ } else {
+ if (rex.w) {
+ MOV_U12(x2, 0xff);
+ SLLI(x1, gd, 56);
+ SRLI(x3, gd, 56);
+ SRLI(x4, gd, 40);
+ SLLI(x2, x2, 8);
+ AND(x4, x4, x2);
+ OR(x1, x1, x3);
+ OR(x1, x1, x4);
+ SLLI(x3, gd, 40);
+ SLLI(x4, x2, 40);
+ AND(x3, x3, x4);
+ OR(x1, x1, x3);
+
+ SRLI(x3, gd, 24);
+ SLLI(x4, x2, 8);
+ AND(x3, x3, x4);
+ OR(x1, x1, x3);
+ SLLI(x3, gd, 24);
+ SLLI(x4, x2, 32);
+ AND(x3, x3, x4);
+ OR(x1, x1, x3);
+
+ SRLI(x3, gd, 8);
+ SLLI(x4, x2, 16);
+ AND(x3, x3, x4);
+ OR(x1, x1, x3);
+ SLLI(x3, gd, 8);
+ SLLI(x4, x2, 24);
+ AND(x3, x3, x4);
+ OR(gd, x1, x3);
+ } else {
+ MOV_U12(x2, 0xff);
+ SLLIW(x2, x2, 8);
+ SLLIW(x1, gd, 24);
+ SRLIW(x3, gd, 24);
+ SRLIW(x4, gd, 8);
+ AND(x4, x4, x2);
+ OR(x1, x1, x3);
+ OR(x1, x1, x4);
+ SLLIW(gd, gd, 8);
+ LUI(x2, 0xff0);
+ AND(gd, gd, x2);
+ OR(gd, gd, x1);
+ }
+ }
+ break;
+ case 0xF1:
+ INST_NAME("MOVBE Ed, Gd");
+ nextop=F8;
+ GETGD;
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, NULL, 1, 0);
+ if (rv64_zbb) {
+ REV8(x1, gd);
+ if (!rex.w) {
+ SRLI(x1, x1, 32);
+ }
+ } else {
+ if (rex.w) {
+ MOV_U12(x2, 0xff);
+ SLLI(x1, gd, 56);
+ SRLI(x3, gd, 56);
+ SRLI(x4, gd, 40);
+ SLLI(x2, x2, 8);
+ AND(x4, x4, x2);
+ OR(x1, x1, x3);
+ OR(x1, x1, x4);
+ SLLI(x3, gd, 40);
+ SLLI(x4, x2, 40);
+ AND(x3, x3, x4);
+ OR(x1, x1, x3);
+
+ SRLI(x3, gd, 24);
+ SLLI(x4, x2, 8);
+ AND(x3, x3, x4);
+ OR(x1, x1, x3);
+ SLLI(x3, gd, 24);
+ SLLI(x4, x2, 32);
+ AND(x3, x3, x4);
+ OR(x1, x1, x3);
+
+ SRLI(x3, gd, 8);
+ SLLI(x4, x2, 16);
+ AND(x3, x3, x4);
+ OR(x1, x1, x3);
+ SLLI(x3, gd, 8);
+ SLLI(x4, x2, 24);
+ AND(x3, x3, x4);
+ OR(x1, x1, x3);
+ } else {
+ MOV_U12(x2, 0xff);
+ SLLIW(x2, x2, 8);
+ SLLIW(x1, gd, 24);
+ SRLIW(x3, gd, 24);
+ SRLIW(x4, gd, 8);
+ AND(x4, x4, x2);
+ OR(x1, x1, x3);
+ OR(x1, x1, x4);
+ SLLIW(x3, gd, 8);
+ LUI(x2, 0xff0);
+ AND(x3, x3, x2);
+ OR(x1, x1, x3);
+ }
+ }
+ SDxw(x1, wback, fixedaddress);
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+
+ #define GO(GETFLAGS, NO, YES, F) \
+ READFLAGS(F); \
+ GETFLAGS; \
+ nextop=F8; \
+ GETGD; \
+ if(MODREG) { \
+ ed = xRAX+(nextop&7)+(rex.b<<3); \
+ B##NO(x1, 8); \
+ MV(gd, ed); \
+ } else { \
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x4, &fixedaddress, rex, NULL, 1, 0); \
+ B##NO(x1, 8); \
+ LDxw(gd, ed, fixedaddress); \
+ } \
+ if(!rex.w) ZEROUP(gd);
+
+ GOCOND(0x40, "CMOV", "Gd, Ed");
+ #undef GO
+ case 0x50:
+ INST_NAME("MOVMSKPS Gd, Ex");
+ nextop = F8;
+ GETGD;
+ GETEX(x1, 0);
+ XOR(gd, gd, gd);
+ for(int i=0; i<4; ++i) {
+ LWU(x2, wback, fixedaddress+i*4);
+ SRLI(x2, x2, 31-i);
+ if (i>0) ANDI(x2, x2, 1<<i);
+ OR(gd, gd, x2);
+ }
+ break;
+ case 0x51:
+ INST_NAME("SQRTPS Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ d0 = fpu_get_scratch(dyn);
+ for(int i=0; i<4; ++i) {
+ FLW(d0, wback, fixedaddress+4*i);
+ FSQRTS(d0, d0);
+ FSW(d0, gback, gdoffset+4*i);
+ }
+ break;
+ case 0x52:
+ INST_NAME("RSQRTPS Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ s0 = fpu_get_scratch(dyn);
+ s1 = fpu_get_scratch(dyn); // 1.0f
+ v0 = fpu_get_scratch(dyn); // 0.0f
+ // do accurate computation, because riscv doesn't have rsqrt
+ MOV32w(x3, 1);
+ FCVTSW(s1, x3, RD_DYN);
+ if (!box64_dynarec_fastnan) {
+ FCVTSW(v0, xZR, RD_DYN);
+ }
+ for(int i=0; i<4; ++i) {
+ FLW(s0, wback, fixedaddress+i*4);
+ if (!box64_dynarec_fastnan) {
+ FLES(x3, v0, s0); // s0 >= 0.0f?
+ BNEZ(x3, 6*4);
+ FEQS(x3, s0, s0); // isnan(s0)?
+ BEQZ(x3, 2*4);
+ // s0 is negative, so generate a NaN
+ FDIVS(s0, s1, v0);
+ // s0 is a NaN, just copy it
+ FSW(s0, gback, gdoffset+i*4);
+ J(4*4);
+ // do regular computation
+ }
+ FSQRTS(s0, s0);
+ FDIVS(s0, s1, s0);
+ FSW(s0, gback, gdoffset+i*4);
+ }
+ break;
+ case 0x53:
+ INST_NAME("RCPPS Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ d0 = fpu_get_scratch(dyn);
+ d1 = fpu_get_scratch(dyn);
+ LUI(x3, 0x3f800);
+ FMVWX(d0, x3); // 1.0f
+ for(int i=0; i<4; ++i) {
+ FLW(d1, wback, fixedaddress+4*i);
+ FDIVS(d1, d0, d1);
+ FSW(d1, gback, gdoffset+4*i);
+ }
+ break;
+ case 0x54:
+ INST_NAME("ANDPS Gx, Ex");
+ nextop = F8;
+ gd = ((nextop&0x38)>>3)+(rex.r<<3);
+ if(!(MODREG && gd==(nextop&7)+(rex.b<<3))) {
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_Q(x3, x4, AND(x3, x3, x4));
+ }
+ break;
+ case 0x55:
+ INST_NAME("ANDNPS Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_Q(x3, x4, NOT(x3, x3); AND(x3, x3, x4));
+ break;
+ case 0x56:
+ INST_NAME("ORPS Gx, Ex");
+ nextop = F8;
+ gd = ((nextop&0x38)>>3)+(rex.r<<3);
+ if(!(MODREG && gd==(nextop&7)+(rex.b<<3))) {
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_Q(x3, x4, OR(x3, x3, x4));
+ }
+ break;
+ case 0x57:
+ INST_NAME("XORPS Gx, Ex");
+ nextop = F8;
+ //TODO: it might be possible to check if SS or SD are used and not purge them to optimize a bit
+ GETGX();
+ if(MODREG && gd==(nextop&7)+(rex.b<<3))
+ {
+ // just zero dest
+ SD(xZR, gback, gdoffset+0);
+ SD(xZR, gback, gdoffset+8);
+ } else {
+ GETEX(x2, 0);
+ SSE_LOOP_Q(x3, x4, XOR(x3, x3, x4));
+ }
+ break;
+ case 0x58:
+ INST_NAME("ADDPS Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ s0 = fpu_get_scratch(dyn);
+ s1 = fpu_get_scratch(dyn);
+ for(int i=0; i<4; ++i) {
+ // GX->f[i] += EX->f[i];
+ FLW(s0, wback, fixedaddress+i*4);
+ FLW(s1, gback, gdoffset+i*4);
+ FADDS(s1, s1, s0);
+ FSW(s1, gback, gdoffset+i*4);
+ }
+ break;
+ case 0x59:
+ INST_NAME("MULPS Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ s0 = fpu_get_scratch(dyn);
+ s1 = fpu_get_scratch(dyn);
+ for(int i=0; i<4; ++i) {
+ // GX->f[i] *= EX->f[i];
+ FLW(s0, wback, fixedaddress+i*4);
+ FLW(s1, gback, gdoffset+i*4);
+ FMULS(s1, s1, s0);
+ FSW(s1, gback, gdoffset+i*4);
+ }
+ break;
+ case 0x5A:
+ INST_NAME("CVTPS2PD Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ s0 = fpu_get_scratch(dyn);
+ s1 = fpu_get_scratch(dyn);
+ FLW(s0, wback, fixedaddress);
+ FLW(s1, wback, fixedaddress+4);
+ FCVTDS(s0, s0);
+ FCVTDS(s1, s1);
+ FSD(s0, gback, gdoffset+0);
+ FSD(s1, gback, gdoffset+8);
+ break;
+ case 0x5B:
+ INST_NAME("CVTDQ2PS Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ s0 = fpu_get_scratch(dyn);
+ for (int i=0; i<4; ++i) {
+ LW(x3, wback, fixedaddress+i*4);
+ FCVTSW(s0, x3, RD_RNE);
+ FSW(s0, gback, gdoffset+i*4);
+ }
+ break;
+ case 0x5C:
+ INST_NAME("SUBPS Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ s0 = fpu_get_scratch(dyn);
+ s1 = fpu_get_scratch(dyn);
+ for(int i=0; i<4; ++i) {
+ // GX->f[i] -= EX->f[i];
+ FLW(s0, wback, fixedaddress+i*4);
+ FLW(s1, gback, gdoffset+i*4);
+ FSUBS(s1, s1, s0);
+ FSW(s1, gback, gdoffset+i*4);
+ }
+ break;
+ case 0x5D:
+ INST_NAME("MINPS Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ s0 = fpu_get_scratch(dyn);
+ s1 = fpu_get_scratch(dyn);
+ for(int i=0; i<4; ++i) {
+ FLW(s0, wback, fixedaddress+i*4);
+ FLW(s1, gback, gdoffset+i*4);
+ if(!box64_dynarec_fastnan) {
+ FEQS(x3, s0, s0);
+ FEQS(x4, s1, s1);
+ AND(x3, x3, x4);
+ BEQZ(x3, 12);
+ FLTS(x3, s0, s1);
+ BEQZ(x3, 8);
+ FSW(s0, gback, gdoffset+i*4);
+ } else {
+ FMINS(s1, s1, s0);
+ FSW(s1, gback, gdoffset+i*4);
+ }
+ }
+ break;
+ case 0x5E:
+ INST_NAME("DIVPS Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ s0 = fpu_get_scratch(dyn);
+ s1 = fpu_get_scratch(dyn);
+ for(int i=0; i<4; ++i) {
+ // GX->f[i] /= EX->f[i];
+ FLW(s0, wback, fixedaddress+i*4);
+ FLW(s1, gback, gdoffset+i*4);
+ FDIVS(s1, s1, s0);
+ FSW(s1, gback, gdoffset+i*4);
+ }
+ break;
+ case 0x5F:
+ INST_NAME("MAXPS Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ s0 = fpu_get_scratch(dyn);
+ s1 = fpu_get_scratch(dyn);
+ for(int i=0; i<4; ++i) {
+ FLW(s0, wback, fixedaddress+i*4);
+ FLW(s1, gback, gdoffset+i*4);
+ if(!box64_dynarec_fastnan) {
+ FEQS(x3, s0, s0);
+ FEQS(x4, s1, s1);
+ AND(x3, x3, x4);
+ BEQZ(x3, 12);
+ FLTS(x3, s1, s0);
+ BEQZ(x3, 8);
+ FSW(s0, gback, gdoffset+i*4);
+ } else {
+ FMAXS(s1, s1, s0);
+ FSW(s1, gback, gdoffset+i*4);
+ }
+ }
+ break;
+ case 0x60:
+ INST_NAME("PUNPCKLBW Gm,Em");
+ nextop = F8;
+ GETGM();
+ for(int i=3; i>0; --i) { // 0 is untouched
+ // GX->ub[2 * i] = GX->ub[i];
+ LBU(x3, gback, gdoffset+i);
+ SB(x3, gback, gdoffset+2*i);
+ }
+ if (MODREG && gd==(nextop&7)) {
+ for(int i=0; i<4; ++i) {
+ // GX->ub[2 * i + 1] = GX->ub[2 * i];
+ LBU(x3, gback, gdoffset+2*i);
+ SB(x3, gback, gdoffset+2*i+1);
+ }
+ } else {
+ GETEM(x2, 0);
+ for(int i=0; i<4; ++i) {
+ // GX->ub[2 * i + 1] = EX->ub[i];
+ LBU(x3, wback, fixedaddress+i);
+ SB(x3, gback, gdoffset+2*i+1);
+ }
+ }
+ break;
+ case 0x61:
+ INST_NAME("PUNPCKLWD Gm, Em");
+ nextop = F8;
+ GETGM();
+ GETEM(x2, 0);
+ // GM->uw[3] = EM->uw[1];
+ LHU(x3, wback, fixedaddress+2*1);
+ SH(x3, gback, gdoffset+2*3);
+ // GM->uw[2] = GM->uw[1];
+ LHU(x3, gback, gdoffset+2*1);
+ SH(x3, gback, gdoffset+2*2);
+ // GM->uw[1] = EM->uw[0];
+ LHU(x3, wback, fixedaddress+2*0);
+ SH(x3, gback, gdoffset+2*1);
+ break;
+ case 0x62:
+ INST_NAME("PUNPCKLDQ Gm, Em");
+ nextop = F8;
+ GETGM();
+ GETEM(x2, 0);
+ // GM->ud[1] = EM->ud[0];
+ LWU(x3, wback, fixedaddress);
+ SW(x3, gback, gdoffset+4*1);
+ break;
+ case 0x67:
+ INST_NAME("PACKUSWB Gm, Em");
+ nextop = F8;
+ GETGM();
+ ADDI(x5, xZR, 0xFF);
+ for(int i=0; i<4; ++i) {
+ // GX->ub[i] = (GX->sw[i]<0)?0:((GX->sw[i]>0xff)?0xff:GX->sw[i]);
+ LH(x3, gback, gdoffset+i*2);
+ BGE(x5, x3, 8);
+ ADDI(x3, xZR, 0xFF);
+ NOT(x4, x3);
+ SRAI(x4, x4, 63);
+ AND(x3, x3, x4);
+ SB(x3, gback, gdoffset+i);
+ }
+ if (MODREG && gd==(nextop&7)) {
+ // GM->ud[1] = GM->ud[0];
+ LW(x3, gback, gdoffset+0*4);
+ SW(x3, gback, gdoffset+1*4);
+ } else {
+ GETEM(x1, 0);
+ for(int i=0; i<4; ++i) {
+ // GX->ub[4+i] = (EX->sw[i]<0)?0:((EX->sw[i]>0xff)?0xff:EX->sw[i]);
+ LH(x3, wback, fixedaddress+i*2);
+ BGE(x5, x3, 8);
+ ADDI(x3, xZR, 0xFF);
+ NOT(x4, x3);
+ SRAI(x4, x4, 63);
+ AND(x3, x3, x4);
+ SB(x3, gback, gdoffset+4+i);
+ }
+ }
+ break;
+ case 0x68:
+ INST_NAME("PUNPCKHBW Gm,Em");
+ nextop = F8;
+ GETGM();
+ for(int i=0; i<4; ++i) {
+ // GX->ub[2 * i] = GX->ub[i + 4];
+ LBU(x3, gback, gdoffset+i+4);
+ SB(x3, gback, gdoffset+2*i);
+ }
+ if (MODREG && gd==(nextop&7)) {
+ for(int i=0; i<4; ++i) {
+ // GX->ub[2 * i + 1] = GX->ub[2 * i];
+ LBU(x3, gback, gdoffset+2*i);
+ SB(x3, gback, gdoffset+2*i+1);
+ }
+ } else {
+ GETEM(x2, 0);
+ for(int i=0; i<4; ++i) {
+ // GX->ub[2 * i + 1] = EX->ub[i + 4];
+ LBU(x3, wback, fixedaddress+i+4);
+ SB(x3, gback, gdoffset+2*i+1);
+ }
+ }
+ break;
+ case 0x69:
+ INST_NAME("PUNPCKHWD Gm,Em");
+ nextop = F8;
+ GETGM();
+ for(int i=0; i<2; ++i) {
+ // GX->uw[2 * i] = GX->uw[i + 2];
+ LHU(x3, gback, gdoffset+(i+2)*2);
+ SH(x3, gback, gdoffset+2*i*2);
+ }
+ if (MODREG && gd==(nextop&7)) {
+ for(int i=0; i<2; ++i) {
+ // GX->uw[2 * i + 1] = GX->uw[2 * i];
+ LHU(x3, gback, gdoffset+2*i*2);
+ SH(x3, gback, gdoffset+(2*i+1)*2);
+ }
+ } else {
+ GETEM(x1, 0);
+ for(int i=0; i<2; ++i) {
+ // GX->uw[2 * i + 1] = EX->uw[i + 2];
+ LHU(x3, wback, fixedaddress+(i+2)*2);
+ SH(x3, gback, gdoffset+(2*i+1)*2);
+ }
+ }
+ break;
+ case 0x6A:
+ INST_NAME("PUNPCKHDQ Gm,Em");
+ nextop = F8;
+ GETEM(x1, 0);
+ GETGM();
+ // GM->ud[0] = GM->ud[1];
+ LWU(x3, gback, gdoffset+1*4);
+ SW(x3, gback, gdoffset+0*4);
+ if (!(MODREG && (gd==ed))) {
+ // GM->ud[1] = EM->ud[1];
+ LWU(x3, wback, fixedaddress+1*4);
+ SW(x3, gback, gdoffset+1*4);
+ }
+ break;
+ case 0x6E:
+ INST_NAME("MOVD Gm, Ed");
+ nextop = F8;
+ GETGM();
+ if(MODREG) {
+ ed = xRAX + (nextop&7) + (rex.b<<3);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &ed, x3, x2, &fixedaddress, rex, NULL, 1, 0);
+ if(rex.w) {
+ LD(x4, ed, fixedaddress);
+ } else {
+ LW(x4, ed, fixedaddress);
+ }
+ ed = x4;
+ }
+ if(rex.w) SD(ed, gback, gdoffset+0); else SW(ed, gback, gdoffset+0);
+ break;
+ case 0x6F:
+ INST_NAME("MOVQ Gm, Em");
+ nextop = F8;
+ GETGM();
+ GETEM(x2, 0);
+ LD(x3, wback, fixedaddress);
+ SD(x3, gback, gdoffset+0);
+ break;
+ case 0x71:
+ nextop = F8;
+ switch((nextop>>3)&7) {
+ case 2:
+ INST_NAME("PSRLW Em, Ib");
+ GETEM(x1, 1);
+ u8 = F8;
+ if (u8>15) {
+ // just zero dest
+ SD(xZR, wback, fixedaddress);
+ } else if(u8) {
+ for (int i=0; i<4; ++i) {
+ // EX->uw[i] >>= u8;
+ LHU(x3, wback, fixedaddress+i*2);
+ SRLI(x3, x3, u8);
+ SH(x3, wback, fixedaddress+i*2);
+ }
+ }
+ break;
+ case 4:
+ INST_NAME("PSRAW Em, Ib");
+ GETEM(x1, 1);
+ u8 = F8;
+ if(u8>15) u8=15;
+ if(u8) {
+ for (int i=0; i<4; ++i) {
+ // EX->sw[i] >>= u8;
+ LH(x3, wback, fixedaddress+i*2);
+ SRAI(x3, x3, u8);
+ SH(x3, wback, fixedaddress+i*2);
+ }
+ }
+ break;
+ case 6:
+ INST_NAME("PSLLW Em, Ib");
+ GETEM(x1, 1);
+ u8 = F8;
+ if (u8>15) {
+ // just zero dest
+ SD(xZR, wback, fixedaddress+0);
+ } else if(u8) {
+ for (int i=0; i<4; ++i) {
+ // EX->uw[i] <<= u8;
+ LHU(x3, wback, fixedaddress+i*2);
+ SLLI(x3, x3, u8);
+ SH(x3, wback, fixedaddress+i*2);
+ }
+ }
+ break;
+ default:
+ *ok = 0;
+ DEFAULT;
+ }
+ break;
+ case 0x75:
+ INST_NAME("PCMPEQW Gm,Em");
+ nextop = F8;
+ GETGM();
+ GETEM(x2, 0);
+ MMX_LOOP_W(x3, x4, SUB(x3, x3, x4); SEQZ(x3, x3); NEG(x3, x3));
+ break;
+ case 0x77:
+ INST_NAME("EMMS");
+ // empty MMX, FPU now usable
+ mmx_purgecache(dyn, ninst, 0, x1);
+ /*emu->top = 0;
+ emu->fpu_stack = 0;*/ //TODO: Check if something is needed here?
+ break;
+ case 0x7F:
+ INST_NAME("MOVQ Em, Gm");
+ nextop = F8;
+ GETGM();
+ GETEM(x2, 0);
+ LD(x3, gback, gdoffset+0);
+ SD(x3, wback, fixedaddress);
+ break;
+ #define GO(GETFLAGS, NO, YES, F) \
+ READFLAGS(F); \
+ i32_ = F32S; \
+ BARRIER(BARRIER_MAYBE); \
+ JUMP(addr+i32_, 1); \
+ GETFLAGS; \
+ if(dyn->insts[ninst].x64.jmp_insts==-1 || \
+ CHECK_CACHE()) { \
+ /* out of the block */ \
+ i32 = dyn->insts[ninst].epilog-(dyn->native_size); \
+ B##NO##_safe(x1, i32); \
+ if(dyn->insts[ninst].x64.jmp_insts==-1) { \
+ if(!(dyn->insts[ninst].x64.barrier&BARRIER_FLOAT)) \
+ fpu_purgecache(dyn, ninst, 1, x1, x2, x3); \
+ jump_to_next(dyn, addr+i32_, 0, ninst); \
+ } else { \
+ CacheTransform(dyn, ninst, cacheupd, x1, x2, x3); \
+ i32 = dyn->insts[dyn->insts[ninst].x64.jmp_insts].address-(dyn->native_size); \
+ B(i32); \
+ } \
+ } else { \
+ /* inside the block */ \
+ i32 = dyn->insts[dyn->insts[ninst].x64.jmp_insts].address-(dyn->native_size); \
+ B##YES##_safe(x1, i32); \
+ }
+
+ GOCOND(0x80, "J", "Id");
+ #undef GO
+
+ #define GO(GETFLAGS, NO, YES, F) \
+ READFLAGS(F); \
+ GETFLAGS; \
+ nextop=F8; \
+ S##YES(x3, x1); \
+ if(MODREG) { \
+ if(rex.rex) { \
+ eb1= xRAX+(nextop&7)+(rex.b<<3); \
+ eb2 = 0; \
+ } else { \
+ ed = (nextop&7); \
+ eb2 = (ed>>2)*8; \
+ eb1 = xRAX+(ed&3); \
+ } \
+ if (eb2) { \
+ LUI(x1, 0xffff0); \
+ ORI(x1, x1, 0xff); \
+ AND(eb1, eb1, x1); \
+ SLLI(x3, x3, 8); \
+ } else { \
+ ANDI(eb1, eb1, 0xf00); \
+ } \
+ OR(eb1, eb1, x3); \
+ } else { \
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress,rex, NULL, 1, 0); \
+ SB(x3, ed, fixedaddress); \
+ SMWRITE(); \
+ }
+
+ GOCOND(0x90, "SET", "Eb");
+ #undef GO
+
+ case 0xA2:
+ INST_NAME("CPUID");
+ NOTEST(x1);
+ MV(A1, xRAX);
+ CALL_(my_cpuid, -1, 0);
+ // BX and DX are not synchronized durring the call, so need to force the update
+ LD(xRDX, xEmu, offsetof(x64emu_t, regs[_DX]));
+ LD(xRBX, xEmu, offsetof(x64emu_t, regs[_BX]));
+ break;
+ case 0xA3:
+ INST_NAME("BT Ed, Gd");
+ SETFLAGS(X_CF, SF_SUBSET);
+ SET_DFNONE();
+ nextop = F8;
+ GETGD;
+ if(MODREG) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ } else {
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, x1, &fixedaddress, rex, NULL, 1, 0);
+ SRAIxw(x1, gd, 5+rex.w); // r1 = (gd>>5)
+ SLLI(x1, x1, 2+rex.w);
+ ADD(x3, wback, x1); //(&ed)+=r1*4;
+ LDxw(x1, x3, fixedaddress);
+ ed = x1;
+ }
+ ANDI(x2, gd, rex.w?0x3f:0x1f);
+ SRL(x4, ed, x2);
+ ANDI(x4, x4, 1);
+ ANDI(xFlags, xFlags, ~1); //F_CF is 1
+ OR(xFlags, xFlags, x4);
+ break;
+ case 0xA4:
+ nextop = F8;
+ INST_NAME("SHLD Ed, Gd, Ib");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETED(1);
+ GETGD;
+ u8 = F8;
+ emit_shld32c(dyn, ninst, rex, ed, gd, u8, x3, x4, x5);
+ WBACK;
+ break;
+ case 0xAB:
+ INST_NAME("BTS Ed, Gd");
+ SETFLAGS(X_CF, SF_SUBSET);
+ SET_DFNONE();
+ nextop = F8;
+ GETGD;
+ if (MODREG) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ wback = 0;
+ } else {
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, x1, &fixedaddress, rex, NULL, 1, 0);
+ SRAI(x1, gd, 5+rex.w);
+ SLLI(x1, x1, 2+rex.w);
+ ADD(x3, wback, x1);
+ LDxw(x1, x3, fixedaddress);
+ ed = x1;
+ wback = x3;
+ }
+ if (rex.w) {
+ ANDI(x2, gd, 0x3f);
+ } else {
+ ANDI(x2, gd, 0x1f);
+ }
+ SRL(x4, ed, x2);
+ ANDI(x4, x4, 1); // F_CF is 1
+ ANDI(xFlags, xFlags, ~1);
+ OR(xFlags, xFlags, x4);
+ ADDI(x3, xZR, 1);
+ SLL(x3, x3, x2);
+ OR(ed, ed, x3);
+ if(wback) {
+ SDxw(ed, wback, fixedaddress);
+ SMWRITE();
+ }
+ break;
+ case 0xAC:
+ nextop = F8;
+ INST_NAME("SHRD Ed, Gd, Ib");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETED(1);
+ GETGD;
+ u8 = F8;
+ u8&=(rex.w?0x3f:0x1f);
+ emit_shrd32c(dyn, ninst, rex, ed, gd, u8, x3, x4);
+ WBACK;
+ break;
+ case 0xAE:
+ nextop = F8;
+ if((nextop&0xF8)==0xE8) {
+ INST_NAME("LFENCE");
+ SMDMB();
+ } else
+ if((nextop&0xF8)==0xF0) {
+ INST_NAME("MFENCE");
+ SMDMB();
+ } else
+ if((nextop&0xF8)==0xF8) {
+ INST_NAME("SFENCE");
+ SMDMB();
+ } else {
+ switch((nextop>>3)&7) {
+ case 0:
+ INST_NAME("FXSAVE Ed");
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ SKIPTEST(x1);
+ fpu_purgecache(dyn, ninst, 0, x1, x2, x3);
+ if(MODREG) {
+ DEFAULT;
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, x3, &fixedaddress, rex, NULL, 0, 0);
+ if(ed!=x1) {MV(x1, ed);}
+ CALL(rex.w?((void*)fpu_fxsave64):((void*)fpu_fxsave32), -1);
+ }
+ break;
+ case 1:
+ INST_NAME("FXRSTOR Ed");
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ SKIPTEST(x1);
+ fpu_purgecache(dyn, ninst, 0, x1, x2, x3);
+ if(MODREG) {
+ DEFAULT;
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, x3, &fixedaddress, rex, NULL, 0, 0);
+ if(ed!=x1) {MV(x1, ed);}
+ CALL(rex.w?((void*)fpu_fxrstor64):((void*)fpu_fxrstor32), -1);
+ }
+ break;
+ case 2:
+ INST_NAME("LDMXCSR Md");
+ GETED(0);
+ SW(ed, xEmu, offsetof(x64emu_t, mxcsr));
+ if(box64_sse_flushto0) {
+ // TODO: applyFlushTo0 also needs to add RISC-V support.
+ }
+ break;
+ case 3:
+ INST_NAME("STMXCSR Md");
+ addr = geted(dyn, addr, ninst, nextop, &wback, x1, x2, &fixedaddress, rex, NULL, 0, 0);
+ LWU(x4, xEmu, offsetof(x64emu_t, mxcsr));
+ SW(x4, wback, fixedaddress);
+ break;
+ case 7:
+ INST_NAME("CLFLUSH Ed");
+ MESSAGE(LOG_DUMP, "Need Optimization?\n");
+ addr = geted(dyn, addr, ninst, nextop, &wback, x1, x2, &fixedaddress, rex, NULL, 0, 0);
+ if(wback!=A1) {
+ MV(A1, wback);
+ }
+ CALL_(native_clflush, -1, 0);
+ break;
+ default:
+ DEFAULT;
+ }
+ }
+ break;
+ case 0xAF:
+ INST_NAME("IMUL Gd, Ed");
+ SETFLAGS(X_ALL, SF_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED(0);
+ if(rex.w) {
+ // 64bits imul
+ UFLAG_IF {
+ MULH(x3, gd, ed);
+ MUL(gd, gd, ed);
+ UFLAG_OP1(x3);
+ UFLAG_RES(gd);
+ UFLAG_DF(x3, d_imul64);
+ } else {
+ MULxw(gd, gd, ed);
+ }
+ } else {
+ // 32bits imul
+ UFLAG_IF {
+ MUL(gd, gd, ed);
+ UFLAG_RES(gd);
+ SRLI(x3, gd, 32);
+ UFLAG_OP1(x3);
+ UFLAG_DF(x3, d_imul32);
+ } else {
+ MULxw(gd, gd, ed);
+ }
+ SLLI(gd, gd, 32);
+ SRLI(gd, gd, 32);
+ }
+ break;
+ case 0xB3:
+ INST_NAME("BTR Ed, Gd");
+ SETFLAGS(X_CF, SF_SUBSET);
+ SET_DFNONE();
+ nextop = F8;
+ GETGD;
+ if(MODREG) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ wback = 0;
+ } else {
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, NULL, 1, 0);
+ SRAI(x1, gd, 5+rex.w);
+ SLLI(x1, x1, 2+rex.w);
+ ADD(x3, wback, x1);
+ LDxw(x1, x3, fixedaddress);
+ ed = x1;
+ wback = x3;
+ }
+ if (rex.w) {
+ ANDI(x2, gd, 0x3f);
+ } else {
+ ANDI(x2, gd, 0x1f);
+ }
+ SRL(x4, ed, x2);
+ ANDI(x4, x4, 1); // F_CF is 1
+ ANDI(xFlags, xFlags, ~1);
+ OR(xFlags, xFlags, x4);
+ ADDI(x5, xZR, 1);
+ SLL(x5, x5, x2);
+ NOT(x5, x5);
+ AND(ed, ed, x5);
+ if(wback) {
+ SDxw(ed, wback, fixedaddress);
+ SMWRITE();
+ }
+ break;
+ case 0xB6:
+ INST_NAME("MOVZX Gd, Eb");
+ nextop = F8;
+ GETGD;
+ if(MODREG) {
+ if(rex.rex) {
+ eb1 = xRAX+(nextop&7)+(rex.b<<3);
+ eb2 = 0; \
+ } else {
+ ed = (nextop&7);
+ eb1 = xRAX+(ed&3); // Ax, Cx, Dx or Bx
+ eb2 = (ed&4)>>2; // L or H
+ }
+ if (eb2) {
+ SRLI(gd, eb1, 8);
+ ANDI(gd, gd, 0xff);
+ } else {
+ ANDI(gd, eb1, 0xff);
+ }
+ } else {
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, NULL, 1, 0);
+ LBU(gd, ed, fixedaddress);
+ }
+ break;
+ case 0xB7:
+ INST_NAME("MOVZX Gd, Ew");
+ nextop = F8;
+ GETGD;
+ if(MODREG) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ ZEXTH(gd, ed);
+ } else {
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, NULL, 1, 0);
+ LHU(gd, ed, fixedaddress);
+ }
+ break;
+ case 0xBA:
+ nextop = F8;
+ switch((nextop>>3)&7) {
+ case 4:
+ INST_NAME("BT Ed, Ib");
+ SETFLAGS(X_CF, SF_SUBSET);
+ SET_DFNONE();
+ GETED(1);
+ u8 = F8;
+ u8&=rex.w?0x3f:0x1f;
+ SRLIxw(x3, ed, u8);
+ ANDI(x3, x3, 1); // F_CF is 1
+ ANDI(xFlags, xFlags, ~1);
+ OR(xFlags, xFlags, x3);
+ break;
+ case 5:
+ INST_NAME("BTS Ed, Ib");
+ SETFLAGS(X_CF, SF_SUBSET);
+ SET_DFNONE();
+ GETED(1);
+ u8 = F8;
+ u8&=(rex.w?0x3f:0x1f);
+ ORI(xFlags, xFlags, 1<<F_CF);
+ if (u8 <= 10) {
+ ANDI(x6, ed, 1<<u8);
+ BNE_MARK(x6, xZR);
+ ANDI(xFlags, xFlags, ~(1<<F_CF));
+ XORI(ed, ed, 1<<u8);
+ } else {
+ ORI(x6, xZR, 1);
+ SLLI(x6, x6, u8);
+ AND(x4, ed, x6);
+ BNE_MARK(x4, xZR);
+ ANDI(xFlags, xFlags, ~(1<<F_CF));
+ XOR(ed, ed, x6);
+ }
+ if (wback) {
+ SDxw(ed, wback, fixedaddress);
+ SMWRITE();
+ }
+ MARK;
+ break;
+ case 6:
+ INST_NAME("BTR Ed, Ib");
+ SETFLAGS(X_CF, SF_SUBSET);
+ SET_DFNONE();
+ GETED(1);
+ u8 = F8;
+ u8&=(rex.w?0x3f:0x1f);
+ ANDI(xFlags, xFlags, ~(1<<F_CF));
+ if (u8 <= 10) {
+ ANDI(x6, ed, 1<<u8);
+ BEQ_MARK(x6, xZR);
+ ORI(xFlags, xFlags, 1<<F_CF);
+ XORI(ed, ed, 1<<u8);
+ } else {
+ ORI(x6, xZR, 1);
+ SLLI(x6, x6, u8);
+ AND(x6, ed, x6);
+ BEQ_MARK(x6, xZR);
+ ORI(xFlags, xFlags, 1<<F_CF);
+ XOR(ed, ed, x6);
+ }
+ if (wback) {
+ SDxw(ed, wback, fixedaddress);
+ SMWRITE();
+ }
+ MARK;
+ break;
+ case 7:
+ INST_NAME("BTC Ed, Ib");
+ SETFLAGS(X_CF, SF_SUBSET);
+ SET_DFNONE();
+ GETED(1);
+ u8 = F8;
+ u8&=rex.w?0x3f:0x1f;
+ SRLIxw(x3, ed, u8);
+ ANDI(x3, x3, 1); // F_CF is 1
+ ANDI(xFlags, xFlags, ~1);
+ OR(xFlags, xFlags, x3);
+ if (u8 <= 10) {
+ XORI(ed, ed, (1LL << u8));
+ } else {
+ MOV64xw(x3, (1LL << u8));
+ XOR(ed, ed, x3);
+ }
+ if(wback) {
+ SDxw(ed, wback, fixedaddress);
+ SMWRITE();
+ }
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+ case 0xBB:
+ INST_NAME("BTC Ed, Gd");
+ SETFLAGS(X_CF, SF_SUBSET);
+ SET_DFNONE();
+ nextop = F8;
+ GETGD;
+ if (MODREG) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ wback = 0;
+ } else {
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, x1, &fixedaddress, rex, NULL, 1, 0);
+ SRAI(x1, gd, 5+rex.w);
+ SLLI(x1, x1, 2+rex.w);
+ ADD(x3, wback, x1);
+ LDxw(x1, x3, fixedaddress);
+ ed = x1;
+ wback = x3;
+ }
+ if (rex.w) {
+ ANDI(x2, gd, 0x3f);
+ } else {
+ ANDI(x2, gd, 0x1f);
+ }
+ SRL(x4, ed, x2);
+ ANDI(x4, x4, 1); // F_CF is 1
+ ANDI(xFlags, xFlags, ~1);
+ OR(xFlags, xFlags, x4);
+ ADDI(x3, xZR, 1);
+ SLL(x3, x3, x2);
+ XOR(ed, ed, x3);
+ if(wback) {
+ SDxw(ed, wback, fixedaddress);
+ SMWRITE();
+ }
+ break;
+ case 0xBC:
+ INST_NAME("BSF Gd, Ed");
+ SETFLAGS(X_ZF, SF_SUBSET);
+ SET_DFNONE();
+ nextop = F8;
+ GETED(0);
+ GETGD;
+ if(!rex.w && MODREG) {
+ AND(x4, ed, xMASK);
+ ed = x4;
+ }
+ BNE_MARK(ed, xZR);
+ ORI(xFlags, xFlags, 1<<F_ZF);
+ B_NEXT_nocond;
+ MARK;
+ if(rv64_zbb) {
+ CTZxw(gd, ed);
+ } else {
+ NEG(x2, ed);
+ AND(x2, x2, ed);
+ TABLE64(x3, 0x03f79d71b4ca8b09ULL);
+ MUL(x2, x2, x3);
+ SRLI(x2, x2, 64-6);
+ TABLE64(x1, (uintptr_t)&deBruijn64tab);
+ ADD(x1, x1, x2);
+ LBU(gd, x1, 0);
+ }
+ ANDI(xFlags, xFlags, ~(1<<F_ZF));
+ break;
+ case 0xBD:
+ INST_NAME("BSR Gd, Ed");
+ SETFLAGS(X_ZF, SF_SUBSET);
+ SET_DFNONE();
+ nextop = F8;
+ GETED(0);
+ GETGD;
+ if(!rex.w && MODREG) {
+ AND(x4, ed, xMASK);
+ ed = x4;
+ }
+ BNE_MARK(ed, xZR);
+ ORI(xFlags, xFlags, 1<<F_ZF);
+ B_NEXT_nocond;
+ MARK;
+ ANDI(xFlags, xFlags, ~(1<<F_ZF));
+ if(rv64_zbb) {
+ MOV32w(x1, rex.w?63:31);
+ CLZxw(gd, ed);
+ SUB(gd, x1, gd);
+ } else {
+ if(ed!=gd)
+ u8 = gd;
+ else
+ u8 = x1;
+ ADDI(u8, xZR, 0);
+ if(rex.w) {
+ MV(x2, ed);
+ SRLI(x3, x2, 32);
+ BEQZ(x3, 4+2*4);
+ ADDI(u8, u8, 32);
+ MV(x2, x3);
+ } else {
+ AND(x2, ed, xMASK);
+ }
+ SRLI(x3, x2, 16);
+ BEQZ(x3, 4+2*4);
+ ADDI(u8, u8, 16);
+ MV(x2, x3);
+ SRLI(x3, x2, 8);
+ BEQZ(x3, 4+2*4);
+ ADDI(u8, u8, 8);
+ MV(x2, x3);
+ SRLI(x3, x2, 4);
+ BEQZ(x3, 4+2*4);
+ ADDI(u8, u8, 4);
+ MV(x2, x3);
+ ANDI(x2, x2, 0b1111);
+ TABLE64(x3, (uintptr_t)&lead0tab);
+ ADD(x3, x3, x2);
+ LBU(x2, x3, 0);
+ ADD(gd, u8, x2);
+ }
+ break;
+ case 0xBE:
+ INST_NAME("MOVSX Gd, Eb");
+ nextop = F8;
+ GETGD;
+ if(MODREG) {
+ if(rex.rex) {
+ wback = xRAX+(nextop&7)+(rex.b<<3);
+ wb2 = 0;
+ } else {
+ wback = (nextop&7);
+ wb2 = (wback>>2)*8;
+ wback = xRAX+(wback&3);
+ }
+ SLLI(gd, wback, 56-wb2);
+ SRAI(gd, gd, 56);
+ } else {
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &ed, x3, x1, &fixedaddress, rex, NULL, 1, 0);
+ LB(gd, ed, fixedaddress);
+ }
+ if(!rex.w)
+ ZEROUP(gd);
+ break;
+ case 0xBF:
+ INST_NAME("MOVSX Gd, Ew");
+ nextop = F8;
+ GETGD;
+ if(MODREG) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ SLLI(gd, ed, 48);
+ SRAI(gd, gd, 48);
+ } else {
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &ed, x3, x1, &fixedaddress, rex, NULL, 1, 0);
+ LH(gd, ed, fixedaddress);
+ }
+ if(!rex.w)
+ ZEROUP(gd);
+ break;
+ case 0xC2:
+ INST_NAME("CMPPS Gx, Ex, Ib");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 1);
+ u8 = F8;
+ d0 = fpu_get_scratch(dyn);
+ d1 = fpu_get_scratch(dyn);
+ for(int i=0; i<4; ++i) {
+ FLW(d0, gback, gdoffset+i*4);
+ FLW(d1, wback, fixedaddress+i*4);
+ if ((u8&7) == 0) { // Equal
+ FEQS(x3, d0, d1);
+ } else if ((u8&7) == 4) { // Not Equal or unordered
+ FEQS(x3, d0, d1);
+ XORI(x3, x3, 1);
+ } else {
+ // x4 = !(isnan(d0) || isnan(d1))
+ FEQS(x4, d0, d0);
+ FEQS(x3, d1, d1);
+ AND(x3, x3, x4);
+
+ switch(u8&7) {
+ case 1: BEQ_MARK(x3, xZR); FLTS(x3, d0, d1); break; // Less than
+ case 2: BEQ_MARK(x3, xZR); FLES(x3, d0, d1); break; // Less or equal
+ case 3: XORI(x3, x3, 1); break; // NaN
+ case 5: { // Greater or equal or unordered
+ BEQ(x3, xZR, 12); // MARK2
+ FLES(x3, d1, d0);
+ J(8); // MARK;
+ break;
+ }
+ case 6: { // Greater or unordered, test inverted, N!=V so unordered or less than (inverted)
+ BEQ(x3, xZR, 12); // MARK2
+ FLTS(x3, d1, d0);
+ J(8); // MARK;
+ break;
+ }
+ case 7: break; // Not NaN
+ }
+
+ // MARK2;
+ if ((u8&7) == 5 || (u8&7) == 6) {
+ MOV32w(x3, 1);
+ }
+ // MARK;
+ }
+ NEG(x3, x3);
+ SW(x3, gback, gdoffset+i*4);
+ }
+ break;
+ case 0xC3:
+ INST_NAME("MOVNTI Ed, Gd");
+ nextop = F8;
+ GETGD;
+ if(MODREG) {
+ MVxw(xRAX+(nextop&7)+(rex.b<<3), gd);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, NULL, 1, 0);
+ SDxw(gd, ed, fixedaddress);
+ }
+ break;
+ case 0xC6: // TODO: Optimize this!
+ INST_NAME("SHUFPS Gx, Ex, Ib");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 1);
+ u8 = F8;
+ int32_t idx;
+
+ idx = (u8>>(0*2))&3;
+ LWU(x3, gback, gdoffset+idx*4);
+ idx = (u8>>(1*2))&3;
+ LWU(x4, gback, gdoffset+idx*4);
+ idx = (u8>>(2*2))&3;
+ LWU(x5, wback, fixedaddress+idx*4);
+ idx = (u8>>(3*2))&3;
+ LWU(x6, wback, fixedaddress+idx*4);
+
+ SW(x3, gback, gdoffset+0*4);
+ SW(x4, gback, gdoffset+1*4);
+ SW(x5, gback, gdoffset+2*4);
+ SW(x6, gback, gdoffset+3*4);
+ break;
+
+ case 0xC8:
+ case 0xC9:
+ case 0xCA:
+ case 0xCB:
+ case 0xCC:
+ case 0xCD:
+ case 0xCE:
+ case 0xCF: /* BSWAP reg */
+ INST_NAME("BSWAP Reg");
+ gd = xRAX+(opcode&7)+(rex.b<<3);
+ if(rv64_zbb) {
+ REV8(gd, gd);
+ if(!rex.w)
+ SRLI(gd, gd, 32);
+ } else {
+ gback = gd;
+ if (!rex.w) {
+ AND(x4, gd, xMASK);
+ gd = x4;
+ }
+ ANDI(x1, gd, 0xff);
+ SLLI(x1, x1, (rex.w?64:32)-8);
+ SRLI(x2, gd, 8);
+ ANDI(x3, x2, 0xff);
+ SLLI(x3, x3, (rex.w?64:32)-16);
+ OR(x1, x1, x3);
+ SRLI(x2, gd, 16);
+ ANDI(x3, x2, 0xff);
+ SLLI(x3, x3, (rex.w?64:32)-24);
+ OR(x1, x1, x3);
+ SRLI(x2, gd, 24);
+ if(rex.w) {
+ ANDI(x3, x2, 0xff);
+ SLLI(x3, x3, 64-32);
+ OR(x1, x1, x3);
+ SRLI(x2, gd, 32);
+ ANDI(x3, x2, 0xff);
+ SLLI(x3, x3, 64-40);
+ OR(x1, x1, x3);
+ SRLI(x2, gd, 40);
+ ANDI(x3, x2, 0xff);
+ SLLI(x3, x3, 64-48);
+ OR(x1, x1, x3);
+ SRLI(x2, gd, 48);
+ ANDI(x3, x2, 0xff);
+ SLLI(x3, x3, 64-56);
+ OR(x1, x1, x3);
+ SRLI(x2, gd, 56);
+ }
+ OR(gback, x1, x2);
+ }
+ break;
+ case 0xE5:
+ INST_NAME("PMULHW Gm,Em");
+ nextop = F8;
+ GETGM();
+ GETEM(x2, 0);
+ for(int i=0; i<4; ++i) {
+ LH(x3, gback, gdoffset+2*i);
+ LH(x4, wback, fixedaddress+2*i);
+ MULW(x3, x3, x4);
+ SRAIW(x3, x3, 16);
+ SH(x3, gback, gdoffset+2*i);
+ }
+ break;
+ case 0xED:
+ INST_NAME("PADDSW Gm,Em");
+ nextop = F8;
+ GETGM();
+ GETEM(x2, 0);
+ for(int i=0; i<4; ++i) {
+ // tmp32s = (int32_t)GX->sw[i] + EX->sw[i];
+ // GX->sw[i] = (tmp32s>32767)?32767:((tmp32s<-32768)?-32768:tmp32s);
+ LH(x3, gback, gdoffset+2*i);
+ LH(x4, wback, fixedaddress+2*i);
+ ADDW(x3, x3, x4);
+ LUI(x4, 0xFFFF8); // -32768
+ BGE(x3, x4, 12);
+ SH(x4, gback, gdoffset+2*i);
+ J(20); // continue
+ LUI(x4, 8); // 32768
+ BLT(x3, x4, 8);
+ ADDIW(x3, x4, -1);
+ SH(x3, gback, gdoffset+2*i);
+ }
+ break;
+ case 0xEF:
+ INST_NAME("PXOR Gm,Em");
+ nextop = F8;
+ GETGM();
+ if(MODREG && gd==(nextop&7)) {
+ // just zero dest
+ SD(xZR, gback, gdoffset+0);
+ } else {
+ GETEM(x2, 0);
+ LD(x3, gback, gdoffset+0);
+ LD(x4, wback, fixedaddress);
+ XOR(x3, x3, x4);
+ SD(x3, gback, gdoffset+0);
+ }
+ break;
+ case 0xF9:
+ INST_NAME("PSUBW Gm, Em");
+ nextop = F8;
+ GETGM();
+ GETEM(x2, 0);
+ MMX_LOOP_W(x3, x4, SUBW(x3, x3, x4));
+ break;
+ case 0xFD:
+ INST_NAME("PADDW Gm, Em");
+ nextop = F8;
+ GETGM();
+ GETEM(x2, 0);
+ MMX_LOOP_W(x3, x4, ADDW(x3, x3, x4));
+ break;
+ default:
+ DEFAULT;
+ }
+ return addr;
+}
diff --git a/src/dynarec/rv64/dynarec_rv64_64.c b/src/dynarec/rv64/dynarec_rv64_64.c
new file mode 100644
index 0000000..bc3b2c9
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_64.c
@@ -0,0 +1,496 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <stddef.h>
+#include <errno.h>
+
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "emu/x64run_private.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "emu/x64run_private.h"
+#include "x64trace.h"
+#include "dynarec_native.h"
+#include "custommem.h"
+
+#include "rv64_printer.h"
+#include "dynarec_rv64_private.h"
+#include "dynarec_rv64_helper.h"
+#include "dynarec_rv64_functions.h"
+
+uintptr_t dynarec64_64(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int seg, int* ok, int* need_epilog)
+{
+ (void)ip; (void)rep; (void)need_epilog;
+
+ uint8_t opcode = F8;
+ uint8_t nextop;
+ uint8_t u8;
+ uint8_t gd, ed, eb1, eb2, gb1, gb2;
+ uint8_t gback, wback, wb1, wb2, wb;
+ int64_t i64, j64;
+ uint64_t u64;
+ int v0, v1;
+ int q0;
+ int d0;
+ int64_t fixedaddress, gdoffset;
+ int unscaled;
+ MAYUSE(eb1);
+ MAYUSE(eb2);
+ MAYUSE(wb1);
+ MAYUSE(wb2);
+ MAYUSE(gb1);
+ MAYUSE(gb2);
+ MAYUSE(j64);
+ MAYUSE(d0);
+ MAYUSE(q0);
+ MAYUSE(v0);
+ MAYUSE(v1);
+
+ while((opcode==0xF2) || (opcode==0xF3)) {
+ rep = opcode-0xF1;
+ opcode = F8;
+ }
+
+ GETREX();
+
+ switch(opcode) {
+ case 0x03:
+ INST_NAME("ADD Gd, Seg:Ed");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ grab_segdata(dyn, addr, ninst, x4, seg);
+ nextop = F8;
+ GETGD;
+ GETEDO(x4, 0, x5);
+ emit_add32(dyn, ninst, rex, gd, ed, x3, x4, x5);
+ break;
+ case 0x0F:
+ opcode = F8;
+ switch(opcode) {
+ case 0x11:
+ switch(rep) {
+ case 0:
+ INST_NAME("MOVUPS Ex,Gx");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ if(!MODREG) {
+ grab_segdata(dyn, addr, ninst, x4, seg);
+ ADD(x4, x4, wback);
+ wback = x4;
+ }
+ LD(x3, gback, gdoffset+0);
+ LD(x5, gback, gdoffset+8);
+ SD(x3, wback, fixedaddress+0);
+ SD(x5, wback, fixedaddress+8);
+ if(!MODREG)
+ SMWRITE2();
+ break;
+ case 1:
+ INST_NAME("MOVSD Ex, Gx");
+ nextop = F8;
+ GETG;
+ v0 = sse_get_reg(dyn, ninst, x1, gd, 0);
+ if(MODREG) {
+ ed = (nextop&7)+ (rex.b<<3);
+ d0 = sse_get_reg(dyn, ninst, x1, ed, 0);
+ FMVD(d0, v0);
+ } else {
+ grab_segdata(dyn, addr, ninst, x4, seg);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, x2, &fixedaddress, rex, NULL, 1, 0);
+ ADD(x4, x4, ed);
+ ed = x4;
+ FSD(v0, ed, fixedaddress);
+ SMWRITE2();
+ }
+ break;
+ case 2:
+ INST_NAME("MOVSS Ex, Gx");
+ nextop = F8;
+ GETG;
+ v0 = sse_get_reg(dyn, ninst, x1, gd, 1);
+ if(MODREG) {
+ q0 = sse_get_reg(dyn, ninst, x1, (nextop&7) + (rex.b<<3), 1);
+ FMVS(q0, v0);
+ } else {
+ grab_segdata(dyn, addr, ninst, x4, seg);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, x2, &fixedaddress, rex, NULL, 1, 0);
+ ADD(x4, x4, ed);
+ ed = x4;
+ FSW(v0, ed, fixedaddress);
+ SMWRITE2();
+ }
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+
+ default:
+ DEFAULT;
+ }
+ break;
+ case 0x2B:
+ INST_NAME("SUB Gd, Seg:Ed");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ grab_segdata(dyn, addr, ninst, x4, seg);
+ nextop = F8;
+ GETGD;
+ GETEDO(x4, 0, x5);
+ emit_sub32(dyn, ninst, rex, gd, ed, x3, x4, x5);
+ break;
+
+ case 0x33:
+ INST_NAME("XOR Gd, Seg:Ed");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ grab_segdata(dyn, addr, ninst, x4, seg);
+ nextop = F8;
+ GETGD;
+ GETEDO(x4, 0, x5);
+ emit_xor32(dyn, ninst, rex, gd, ed, x3, x4);
+ break;
+
+ case 0x66:
+ addr = dynarec64_6664(dyn, addr, ip, ninst, rex, seg, ok, need_epilog);
+ break;
+ case 0x80:
+ nextop = F8;
+ switch((nextop>>3)&7) {
+ case 0: // ADD
+ INST_NAME("ADD Eb, Ib");
+ grab_segdata(dyn, addr, ninst, x1, seg);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEBO(x1, 1);
+ u8 = F8;
+ emit_add8c(dyn, ninst, x1, u8, x2, x4, x5);
+ EBBACK(x5, 0);
+ break;
+ case 1: // OR
+ INST_NAME("OR Eb, Ib");
+ grab_segdata(dyn, addr, ninst, x1, seg);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEBO(x1, 1);
+ u8 = F8;
+ emit_or8c(dyn, ninst, x1, u8, x2, x4, x5);
+ EBBACK(x5, 0);
+ break;
+ case 2: // ADC
+ INST_NAME("ADC Eb, Ib");
+ grab_segdata(dyn, addr, ninst, x1, seg);
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEBO(x1, 1);
+ u8 = F8;
+ emit_adc8c(dyn, ninst, x1, u8, x2, x4, x5, x6);
+ EBBACK(x5, 0);
+ break;
+ case 3: // SBB
+ INST_NAME("SBB Eb, Ib");
+ grab_segdata(dyn, addr, ninst, x1, seg);
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEBO(x1, 1);
+ u8 = F8;
+ emit_sbb8c(dyn, ninst, x1, u8, x2, x4, x5, x6);
+ EBBACK(x5, 0);
+ break;
+ case 4: // AND
+ INST_NAME("AND Eb, Ib");
+ grab_segdata(dyn, addr, ninst, x1, seg);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEBO(x1, 1);
+ u8 = F8;
+ emit_and8c(dyn, ninst, x1, u8, x2, x4);
+ EBBACK(x5, 0);
+ break;
+ case 5: // SUB
+ INST_NAME("SUB Eb, Ib");
+ grab_segdata(dyn, addr, ninst, x1, seg);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEBO(x1, 1);
+ u8 = F8;
+ emit_sub8c(dyn, ninst, x1, u8, x2, x4, x5, x6);
+ EBBACK(x5, 0);
+ break;
+ case 6: // XOR
+ INST_NAME("XOR Eb, Ib");
+ grab_segdata(dyn, addr, ninst, x1, seg);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEBO(x1, 1);
+ u8 = F8;
+ emit_xor8c(dyn, ninst, x1, u8, x2, x4);
+ EBBACK(x5, 0);
+ break;
+ case 7: // CMP
+ INST_NAME("CMP Eb, Ib");
+ grab_segdata(dyn, addr, ninst, x1, seg);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEBO(x1, 1);
+ u8 = F8;
+ if(u8) {
+ MOV32w(x2, u8);
+ emit_cmp8(dyn, ninst, x1, x2, x3, x4, x5, x6);
+ } else {
+ emit_cmp8_0(dyn, ninst, x1, x3, x4);
+ }
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+ case 0x81:
+ case 0x83:
+ nextop = F8;
+ grab_segdata(dyn, addr, ninst, x6, seg);
+ switch((nextop>>3)&7) {
+ case 0: // ADD
+ if(opcode==0x81) {INST_NAME("ADD Ed, Id");} else {INST_NAME("ADD Ed, Ib");}
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEDO(x6, (opcode==0x81)?4:1, x5);
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ emit_add32c(dyn, ninst, rex, ed, i64, x3, x4, x5, x9);
+ WBACKO(x6);
+ break;
+ case 1: // OR
+ if(opcode==0x81) {INST_NAME("OR Ed, Id");} else {INST_NAME("OR Ed, Ib");}
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEDO(x6, (opcode==0x81)?4:1, x5);
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ emit_or32c(dyn, ninst, rex, ed, i64, x3, x4);
+ WBACKO(x6);
+ break;
+ case 2: // ADC
+ if(opcode==0x81) {INST_NAME("ADC Ed, Id");} else {INST_NAME("ADC Ed, Ib");}
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEDO(x6, (opcode==0x81)?4:1, x5);
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ MOV64xw(x5, i64);
+ SD(x6, xEmu, offsetof(x64emu_t, scratch));
+ emit_adc32(dyn, ninst, rex, ed, x5, x3, x4, x6, x9);
+ LD(x6, xEmu, offsetof(x64emu_t, scratch));
+ WBACKO(x6);
+ break;
+ case 3: // SBB
+ if(opcode==0x81) {INST_NAME("SBB Ed, Id");} else {INST_NAME("SBB Ed, Ib");}
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEDO(x6, (opcode==0x81)?4:1, x5);
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ MOV64xw(x5, i64);
+ emit_sbb32(dyn, ninst, rex, ed, x5, x3, x4, x9);
+ WBACKO(x6);
+ break;
+ case 4: // AND
+ if(opcode==0x81) {INST_NAME("AND Ed, Id");} else {INST_NAME("AND Ed, Ib");}
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEDO(x6, (opcode==0x81)?4:1, x5);
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ emit_and32c(dyn, ninst, rex, ed, i64, x3, x4);
+ WBACKO(x6);
+ break;
+ case 5: // SUB
+ if(opcode==0x81) {INST_NAME("SUB Ed, Id");} else {INST_NAME("SUB Ed, Ib");}
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEDO(x6, (opcode==0x81)?4:1, x5);
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ emit_sub32c(dyn, ninst, rex, ed, i64, x3, x4, x5, x9);
+ WBACKO(x6);
+ break;
+ case 6: // XOR
+ if(opcode==0x81) {INST_NAME("XOR Ed, Id");} else {INST_NAME("XOR Ed, Ib");}
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEDO(x6, (opcode==0x81)?4:1, x5);
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ emit_xor32c(dyn, ninst, rex, ed, i64, x3, x4);
+ WBACKO(x6);
+ break;
+ case 7: // CMP
+ if(opcode==0x81) {INST_NAME("CMP Ed, Id");} else {INST_NAME("CMP Ed, Ib");}
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEDO(x6, (opcode==0x81)?4:1, x5);
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ if(i64) {
+ MOV64xw(x2, i64);
+ emit_cmp32(dyn, ninst, rex, ed, x2, x3, x4, x5, x6);
+ } else
+ emit_cmp32_0(dyn, ninst, rex, ed, x3, x4);
+ break;
+ }
+ break;
+ case 0x88:
+ INST_NAME("MOV Seg:Eb, Gb");
+ grab_segdata(dyn, addr, ninst, x4, seg);
+ nextop=F8;
+ gd = ((nextop&0x38)>>3)+(rex.r<<3);
+ if(rex.rex) {
+ gb2 = 0;
+ gb1 = xRAX + gd;
+ } else {
+ gb2 = ((gd&4)>>2);
+ gb1 = xRAX+(gd&3);
+ }
+ gd = x5;
+ if(gb2) {
+ SRLI(x5, gb1, 8);
+ gb1 = x5;
+ }
+ if(MODREG) {
+ ed = (nextop&7) + (rex.b<<3);
+ if(rex.rex) {
+ eb1 = xRAX+ed;
+ eb2 = 0;
+ } else {
+ eb1 = xRAX+(ed&3); // Ax, Cx, Dx or Bx
+ eb2 = ((ed&4)>>2); // L or H
+ }
+ ANDI(gd, gb1, 0xff);
+ if(eb2) {
+ MOV64x(x1, 0xffffffffffff00ffLL);
+ ANDI(x1, eb1, x1);
+ SLLI(gd, gd, 8);
+ OR(eb1, x1, gd);
+ } else {
+ ANDI(x1, eb1, ~0xff);
+ OR(eb1, x1, gd);
+ }
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, NULL, 1, 0);
+ ADD(x4, ed, x4);
+ SB(gb1, x4, fixedaddress);
+ SMWRITE2();
+ }
+ break;
+ case 0x89:
+ INST_NAME("MOV Seg:Ed, Gd");
+ grab_segdata(dyn, addr, ninst, x4, seg);
+ nextop=F8;
+ GETGD;
+ if(MODREG) { // reg <= reg
+ MVxw(xRAX+(nextop&7)+(rex.b<<3), gd);
+ } else { // mem <= reg
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, NULL, 1, 0);
+ ADD(x4, ed, x4);
+ SDxw(gd, x4, fixedaddress);
+ SMWRITE2();
+ }
+ break;
+
+ case 0x8B:
+ INST_NAME("MOV Gd, Seg:Ed");
+ grab_segdata(dyn, addr, ninst, x4, seg);
+ nextop=F8;
+ GETGD;
+ if(MODREG) { // reg <= reg
+ MVxw(gd, xRAX+(nextop&7)+(rex.b<<3));
+ } else { // mem <= reg
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, NULL, 1, 0);
+ ADD(x4, ed, x4);
+ LDxw(gd, x4, fixedaddress);
+ }
+ break;
+
+ case 0xA1:
+ INST_NAME("MOV EAX,FS:Od");
+ grab_segdata(dyn, addr, ninst, x4, seg);
+ if(rex.is32bits)
+ u64 = F32;
+ else
+ u64 = F64;
+ // TODO: could be optimized.
+ MOV64z(x1, u64);
+ ADD(x1, x1, x4);
+ LDxw(xRAX, x1, 0);
+ break;
+
+ case 0xA3:
+ INST_NAME("MOV FS:Od,EAX");
+ grab_segdata(dyn, addr, ninst, x4, seg);
+ if(rex.is32bits)
+ u64 = F32;
+ else
+ u64 = F64;
+ // TODO: could be optimized.
+ MOV64z(x1, u64);
+ ADD(x1, x1, x4);
+ SDxw(xRAX, x1, 0);
+ SMWRITE2();
+ break;
+
+ case 0xC6:
+ INST_NAME("MOV Seg:Eb, Ib");
+ grab_segdata(dyn, addr, ninst, x4, seg);
+ nextop=F8;
+ if(MODREG) { // reg <= u8
+ u8 = F8;
+ if(!rex.rex) {
+ ed = (nextop&7);
+ eb1 = xRAX+(ed&3); // Ax, Cx, Dx or Bx
+ eb2 = (ed&4)>>2; // L or H
+ } else {
+ eb1 = xRAX+(nextop&7)+(rex.b<<3);
+ eb2 = 0;
+ }
+
+ if (eb2) {
+ // load a mask to x3 (ffffffffffff00ff)
+ LUI(x3, 0xffff0);
+ ORI(x3, x3, 0xff);
+ // apply mask
+ AND(eb1, eb1, x3);
+ if(u8) {
+ if((u8<<8)<2048) {
+ ADDI(x4, xZR, u8<<8);
+ } else {
+ ADDI(x4, xZR, u8);
+ SLLI(x4, x4, 8);
+ }
+ OR(eb1, eb1, x4);
+ }
+ } else {
+ ANDI(eb1, eb1, 0xf00); // mask ffffffffffffff00
+ ORI(eb1, eb1, u8);
+ }
+ } else { // mem <= u8
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, NULL, 1, 1);
+ u8 = F8;
+ if(u8) {
+ ADDI(x3, xZR, u8);
+ ed = x3;
+ } else
+ ed = xZR;
+ ADD(x4, wback, x4);
+ SB(ed, x4, fixedaddress);
+ SMWRITE2();
+ }
+ break;
+ case 0xC7:
+ INST_NAME("MOV Seg:Ed, Id");
+ grab_segdata(dyn, addr, ninst, x4, seg);
+ nextop=F8;
+ if(MODREG) { // reg <= i32
+ i64 = F32S;
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ MOV64xw(ed, i64);
+ } else { // mem <= i32
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, NULL, 1, 4);
+ i64 = F32S;
+ if(i64) {
+ MOV64xw(x3, i64);
+ ed = x3;
+ } else
+ ed = xZR;
+ ADD(x4, wback, x4);
+ SDxw(ed, x4, fixedaddress);
+ SMWRITE2();
+ }
+ break;
+ default:
+ DEFAULT;
+ }
+ return addr;
+}
diff --git a/src/dynarec/rv64/dynarec_rv64_66.c b/src/dynarec/rv64/dynarec_rv64_66.c
new file mode 100644
index 0000000..3e11d45
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_66.c
@@ -0,0 +1,1020 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <stddef.h>
+#include <errno.h>
+
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "emu/x64run_private.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "emu/x64run_private.h"
+#include "x64trace.h"
+#include "dynarec_native.h"
+
+#include "rv64_printer.h"
+#include "dynarec_rv64_private.h"
+#include "dynarec_rv64_helper.h"
+#include "dynarec_rv64_functions.h"
+
+
+uintptr_t dynarec64_66(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog)
+{
+ uint8_t opcode = F8;
+ uint8_t nextop, u8;
+ int16_t i16;
+ uint16_t u16;
+ uint64_t u64;
+ int32_t i32;
+ int64_t j64;
+ uint8_t gd, ed;
+ uint8_t wback, wb1;
+ int64_t fixedaddress;
+ int unscaled;
+ int lock;
+ MAYUSE(u8);
+ MAYUSE(u16);
+ MAYUSE(u64);
+ MAYUSE(j64);
+ MAYUSE(lock);
+
+ while((opcode==0x2E) || (opcode==0x36) || (opcode==0x66)) // ignoring CS:, SS: or multiple 0x66
+ opcode = F8;
+
+ while((opcode==0xF2) || (opcode==0xF3)) {
+ rep = opcode-0xF1;
+ opcode = F8;
+ }
+
+ GETREX();
+
+ if(rex.w && !(opcode==0x0f || opcode==0xf0 || opcode==0x64 || opcode==0x65)) // rex.w cancels "66", but not for 66 0f type of prefix
+ return dynarec64_00(dyn, addr-1, ip, ninst, rex, rep, ok, need_epilog); // addr-1, to "put back" opcode
+
+ switch(opcode) {
+ case 0x01:
+ INST_NAME("ADD Ew, Gw");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGW(x2);
+ GETEW(x1, 0);
+ emit_add16(dyn, ninst, x1, x2, x4, x5, x6);
+ EWBACK;
+ break;
+ case 0x03:
+ INST_NAME("ADD Gw, Ew");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGW(x1);
+ GETEW(x2, 0);
+ emit_add16(dyn, ninst, x1, x2, x3, x4, x6);
+ GWBACK;
+ break;
+ case 0x05:
+ INST_NAME("ADD AX, Iw");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ i32 = F16;
+ ZEXTH(x1 , xRAX);
+ MOV32w(x2, i32);
+ emit_add16(dyn, ninst, x1, x2, x3, x4, x6);
+ LUI(x3, 0xffff0);
+ AND(xRAX, xRAX, x3);
+ OR(xRAX, xRAX, x1);
+ break;
+ case 0x09:
+ INST_NAME("OR Ew, Gw");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGW(x2);
+ GETEW(x1, 0);
+ emit_or16(dyn, ninst, x1, x2, x4, x2);
+ EWBACK;
+ break;
+ case 0x0B:
+ INST_NAME("OR Gw, Ew");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGW(x1);
+ GETEW(x2, 0);
+ emit_or16(dyn, ninst, x1, x2, x4, x5);
+ GWBACK;
+ break;
+ case 0x0D:
+ INST_NAME("OR AX, Iw");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ i32 = F16;
+ ZEXTH(x1, xRAX);
+ MOV32w(x2, i32);
+ emit_or16(dyn, ninst, x1, x2, x3, x4);
+ LUI(x3, 0xffff0);
+ AND(xRAX, xRAX, x3);
+ OR(xRAX, xRAX, x1);
+ break;
+ case 0x0F:
+ addr = dynarec64_660F(dyn, addr, ip, ninst, rex, ok, need_epilog);
+ break;
+ case 0x11:
+ INST_NAME("ADC Ew, Gw");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGW(x2);
+ GETEW(x1, 0);
+ emit_adc16(dyn, ninst, x1, x2, x4, x3, x5);
+ EWBACK;
+ break;
+ case 0x13:
+ INST_NAME("ADC Gw, Ew");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGW(x1);
+ GETEW(x2, 0);
+ emit_adc16(dyn, ninst, x1, x2, x4, x3, x5);
+ GWBACK;
+ break;
+ case 0x15:
+ INST_NAME("ADC AX, Iw");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ i16 = F16;
+ SRLI(x6, xMASK, 16);
+ AND(x1, xRAX, x6);
+ MOV32w(x2, i16);
+ emit_adc16(dyn, ninst, x1, x2, x3, x4, x5);
+ if (rv64_zbb) {
+ ANDN(xRAX, xRAX, x6);
+ } else {
+ NOT(x6, x6);
+ AND(xRAX, xRAX, x6);
+ }
+ OR(xRAX, xRAX, x1);
+ break;
+ case 0x19:
+ INST_NAME("SBB Ew, Gw");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGW(x2);
+ GETEW(x1, 0);
+ emit_sbb16(dyn, ninst, x1, x2, x4, x5, x6);
+ EWBACK;
+ break;
+ case 0x1B:
+ INST_NAME("SBB Gw, Ew");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGW(x1);
+ GETEW(x2, 0);
+ emit_sbb16(dyn, ninst, x1, x2, x3, x4, x5);
+ GWBACK;
+ break;
+ case 0x21:
+ INST_NAME("AND Ew, Gw");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGW(x2);
+ GETEW(x1, 0);
+ emit_and16(dyn, ninst, x1, x2, x4, x5);
+ EWBACK;
+ break;
+ case 0x23:
+ INST_NAME("AND Gw, Ew");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGW(x1);
+ GETEW(x2, 0);
+ emit_and16(dyn, ninst, x1, x2, x4, x5);
+ GWBACK;
+ break;
+ case 0x25:
+ INST_NAME("AND AX, Iw");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ i32 = F16;
+ ZEXTH(x1, xRAX);
+ MOV32w(x2, i32);
+ emit_and16(dyn, ninst, x1, x2, x3, x4);
+ LUI(x3, 0xffff0);
+ AND(xRAX, xRAX, x3);
+ OR(xRAX, xRAX, x1);
+ break;
+ case 0x29:
+ INST_NAME("SUB Ew, Gw");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGW(x1);
+ GETEW(x2, 0);
+ emit_sub16(dyn, ninst, x2, x1, x4, x5, x6);
+ EWBACK;
+ break;
+ case 0x2B:
+ INST_NAME("SUB Gw, Ew");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGW(x1);
+ GETEW(x2, 0);
+ emit_sub16(dyn, ninst, x1, x2, x3, x4, x5);
+ GWBACK;
+ break;
+ case 0x2D:
+ INST_NAME("SUB AX, Iw");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ i32 = F16;
+ ZEXTH(x1, xRAX);
+ MOV32w(x2, i32);
+ emit_sub16(dyn, ninst, x1, x2, x3, x4, x5);
+ LUI(x2, 0xffff0);
+ AND(xRAX, xRAX, x2);
+ OR(xRAX, xRAX, x1);
+ break;
+ case 0x31:
+ INST_NAME("XOR Ew, Gw");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGW(x2);
+ GETEW(x1, 0);
+ emit_xor16(dyn, ninst, x1, x2, x4, x5, x6);
+ EWBACK;
+ break;
+ case 0x33:
+ INST_NAME("XOR Gw, Ew");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGW(x1);
+ GETEW(x2, 0);
+ emit_xor16(dyn, ninst, x1, x2, x4, x5, x6);
+ GWBACK;
+ break;
+ case 0x35:
+ INST_NAME("XOR AX, Iw");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ i32 = F16;
+ ZEXTH(x1, xRAX);
+ MOV32w(x2, i32);
+ emit_xor16(dyn, ninst, x1, x2, x3, x4, x5);
+ LUI(x5, 0xffff0);
+ AND(xRAX, xRAX, x5);
+ OR(xRAX, xRAX, x1);
+ break;
+ case 0x39:
+ INST_NAME("CMP Ew, Gw");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGW(x2);
+ GETEW(x1, 0);
+ emit_cmp16(dyn, ninst, x1, x2, x3, x4, x5, x6);
+ break;
+ case 0x3B:
+ INST_NAME("CMP Gw, Ew");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGW(x1);
+ GETEW(x2, 0);
+ emit_cmp16(dyn, ninst, x1, x2, x3, x4, x5, x6);
+ break;
+ case 0x3D:
+ INST_NAME("CMP AX, Iw");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ i32 = F16;
+ ZEXTH(x1, xRAX);
+ if(i32) {
+ MOV32w(x2, i32);
+ emit_cmp16(dyn, ninst, x1, x2, x3, x4, x5, x6);
+ } else {
+ emit_cmp16_0(dyn, ninst, x1, x3, x4);
+ }
+ break;
+ case 0x40:
+ case 0x41:
+ case 0x42:
+ case 0x43:
+ case 0x44:
+ case 0x45:
+ case 0x46:
+ case 0x47:
+ INST_NAME("INC Reg16 (32bits)");
+ SETFLAGS(X_ALL&~X_CF, SF_SUBSET_PENDING);
+ gd = xRAX + (opcode&7);
+ ZEXTH(x1, gd);
+ emit_inc16(dyn, ninst, x1, x2, x3, x4);
+ LUI(x3, 0xffff0);
+ AND(gd, gd, x3);
+ OR(gd, gd, x1);
+ ZEROUP(gd);
+ break;
+ case 0x48:
+ case 0x49:
+ case 0x4A:
+ case 0x4B:
+ case 0x4C:
+ case 0x4D:
+ case 0x4E:
+ case 0x4F:
+ INST_NAME("DEC Reg16 (32bits)");
+ SETFLAGS(X_ALL&~X_CF, SF_SUBSET_PENDING);
+ gd = xRAX + (opcode&7);
+ ZEXTH(x1, gd);
+ emit_dec16(dyn, ninst, x1, x2, x3, x4, x5);
+ LUI(x3, 0xffff0);
+ AND(gd, gd, x3);
+ OR(gd, gd, x1);
+ ZEROUP(gd);
+ break;
+ case 0x64:
+ addr = dynarec64_6664(dyn, addr, ip, ninst, rex, _FS, ok, need_epilog);
+ break;
+ case 0x65:
+ addr = dynarec64_6664(dyn, addr, ip, ninst, rex, _GS, ok, need_epilog);
+ break;
+ case 0x66:
+ addr = dynarec64_66(dyn, addr, ip, ninst, rex, rep, ok, need_epilog);
+ break;
+ case 0x69:
+ case 0x6B:
+ if(opcode==0x69) {
+ INST_NAME("IMUL Gw,Ew,Iw");
+ } else {
+ INST_NAME("IMUL Gw,Ew,Ib");
+ }
+ SETFLAGS(X_ALL, SF_PENDING);
+ nextop = F8;
+ UFLAG_DF(x1, d_imul16);
+ GETSEW(x1, (opcode==0x69)?2:1);
+ if(opcode==0x69) i32 = F16S; else i32 = F8S;
+ MOV32w(x2, i32);
+ MULW(x2, x2, x1);
+ ZEXTH(x2, x2);
+ UFLAG_RES(x2);
+ gd=x2;
+ GWBACK;
+ break;
+ case 0x70:
+ case 0x71:
+ case 0x72:
+ case 0x73:
+ case 0x74:
+ case 0x75:
+ case 0x76:
+ case 0x77:
+ case 0x78:
+ case 0x79:
+ case 0x7a:
+ case 0x7b:
+ case 0x7c:
+ case 0x7d:
+ case 0x7e:
+ case 0x7f:
+ // just use regular conditional jump
+ return dynarec64_00(dyn, addr-1, ip, ninst, rex, rep, ok, need_epilog);
+
+ case 0x81:
+ case 0x83:
+ nextop = F8;
+ switch((nextop>>3)&7) {
+ case 0: // ADD
+ if(opcode==0x81) {INST_NAME("ADD Ew, Iw");} else {INST_NAME("ADD Ew, Ib");}
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEW(x1, (opcode==0x81)?2:1);
+ if(opcode==0x81) i16 = F16S; else i16 = F8S;
+ MOV64x(x5, i16);
+ emit_add16(dyn, ninst, ed, x5, x2, x4, x6);
+ EWBACK;
+ break;
+ case 1: // OR
+ if(opcode==0x81) {INST_NAME("OR Ew, Iw");} else {INST_NAME("OR Ew, Ib");}
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEW(x1, (opcode==0x81)?2:1);
+ if(opcode==0x81) i16 = F16S; else i16 = F8S;
+ MOV64x(x5, i16);
+ emit_or16(dyn, ninst, x1, x5, x2, x4);
+ EWBACK;
+ break;
+ case 2: // ADC
+ if(opcode==0x81) {INST_NAME("ADC Ew, Iw");} else {INST_NAME("ADC Ew, Ib");}
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEW(x1, (opcode==0x81)?2:1);
+ if(opcode==0x81) i16 = F16S; else i16 = F8S;
+ MOV64x(x5, i16);
+ emit_adc16(dyn, ninst, x1, x5, x2, x4, x6);
+ EWBACK;
+ break;
+ case 3: // SBB
+ if(opcode==0x81) {INST_NAME("SBB Ew, Iw");} else {INST_NAME("SBB Ew, Ib");}
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEW(x1, (opcode==0x81)?2:1);
+ if(opcode==0x81) i16 = F16S; else i16 = F8S;
+ MOV64x(x5, i16);
+ emit_sbb16(dyn, ninst, x1, x5, x2, x4, x6);
+ EWBACK;
+ break;
+ case 4: // AND
+ if(opcode==0x81) {INST_NAME("AND Ew, Iw");} else {INST_NAME("AND Ew, Ib");}
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEW(x1, (opcode==0x81)?2:1);
+ if(opcode==0x81) i16 = F16S; else i16 = F8S;
+ MOV64x(x5, i16);
+ emit_and16(dyn, ninst, x1, x5, x2, x4);
+ EWBACK;
+ break;
+ case 5: // SUB
+ if(opcode==0x81) {INST_NAME("SUB Ew, Iw");} else {INST_NAME("SUB Ew, Ib");}
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEW(x1, (opcode==0x81)?2:1);
+ if(opcode==0x81) i16 = F16S; else i16 = F8S;
+ MOV32w(x5, i16);
+ emit_sub16(dyn, ninst, x1, x5, x2, x4, x6);
+ EWBACK;
+ break;
+ case 6: // XOR
+ if(opcode==0x81) {INST_NAME("XOR Ew, Iw");} else {INST_NAME("XOR Ew, Ib");}
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEW(x1, (opcode==0x81)?2:1);
+ if(opcode==0x81) i16 = F16S; else i16 = F8S;
+ MOV32w(x5, i16);
+ emit_xor16(dyn, ninst, x1, x5, x2, x4, x6);
+ EWBACK;
+ break;
+ case 7: // CMP
+ if(opcode==0x81) {INST_NAME("CMP Ew, Iw");} else {INST_NAME("CMP Ew, Ib");}
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEW(x1, (opcode==0x81)?2:1);
+ if(opcode==0x81) i16 = F16S; else i16 = F8S;
+ if(i16) {
+ MOV64x(x2, i16);
+ emit_cmp16(dyn, ninst, x1, x2, x3, x4, x5, x6);
+ } else
+ emit_cmp16_0(dyn, ninst, x1, x3, x4);
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+ case 0x85:
+ INST_NAME("TEST Ew, Gw");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETEW(x1, 0);
+ GETGW(x2);
+ emit_test16(dyn, ninst, x1, x2, x3, x4, x5);
+ break;
+ case 0x87:
+ INST_NAME("(LOCK)XCHG Ew, Gw");
+ nextop = F8;
+ if(MODREG) {
+ GETGD;
+ GETED(0);
+ ADDI(x1, gd, 0);
+ LUI(x3, 0xffff0);
+ AND(gd, gd, x3);
+ ZEXTH(x4, ed);
+ OR(gd, gd, x4);
+ AND(ed, ed, x3);
+ ZEXTH(x4, x1);
+ OR(ed, ed, x4);
+ } else {
+ GETGD;
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, LOCK_LOCK, 0, 0);
+ SMDMB();
+
+ ANDI(x3, ed, 1);
+ BNEZ_MARK(x3);
+
+ ANDI(x3, ed, 0b10);
+ LUI(x5, 0xffff0);
+ ZEXTH(x6, gd);
+ BNEZ_MARK3(x3);
+
+ MARKLOCK;
+ LR_W(x1, ed, 1, 0);
+ AND(x3, x1, x5);
+ OR(x3, x3, x6);
+ SC_W(x3, x3, ed, 0, 1);
+ BNEZ_MARKLOCK(x3);
+ ZEXTH(x1, x1);
+ B_MARK2_nocond;
+
+ MARK3;
+ NOT(x5, x5);
+ SLLI(x5, x5, 16);
+ SLLI(x6, x6, 16);
+ NOT(x5, x5);
+ LR_W(x1, ed, 1, 0);
+ AND(x3, x1, x5);
+ OR(x3, x3, x6);
+ SC_W(x3, x3, ed, 0, 1);
+ BNEZ(x3, -4 * 4);
+ SRLI(x1, x1, 16);
+ ZEXTH(x1, x1);
+ B_MARK2_nocond;
+
+ MARK;
+ LHU(x1, ed, 0);
+ SH(gd, ed, 0);
+
+ MARK2;
+ SMDMB();
+ LUI(x5, 0xffff0);
+ AND(gd, gd, x5);
+ OR(gd, gd, x1);
+ }
+ break;
+ case 0x89:
+ INST_NAME("MOV Ew, Gw");
+ nextop = F8;
+ GETGD;
+ if(MODREG) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ if(ed!=gd) {
+ // we don't use GETGW above, so we need let gd & 0xffff.
+ LUI(x1, 0xffff0);
+ AND(ed, ed, x1);
+ ZEXTH(x2, gd);
+ OR(ed, ed, x2);
+ }
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, &lock, 0, 0);
+ SH(gd, ed, fixedaddress);
+ SMWRITELOCK(lock);
+ }
+ break;
+ case 0x8B:
+ INST_NAME("MOV Gw, Ew");
+ nextop = F8;
+ GETGD; // don't need GETGW neither
+ if(MODREG) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ if(ed!=gd) {
+ LUI(x1, 0xffff0);
+ AND(gd, gd, x1);
+ ZEXTH(x2, ed);
+ OR(gd, gd, x2);
+ }
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, &lock, 1, 0);
+ SMREADLOCK(lock);
+ LHU(x1, ed, fixedaddress);
+ LUI(x4, 0xffff0);
+ AND(gd, gd, x4);
+ OR(gd, gd, x1);
+ }
+ break;
+ case 0x90:
+ case 0x91:
+ case 0x92:
+ case 0x93:
+ case 0x94:
+ case 0x95:
+ case 0x96:
+ case 0x97:
+ gd = xRAX+(opcode&0x07)+(rex.b<<3);
+ if(gd==xRAX) {
+ INST_NAME("NOP");
+ } else {
+ INST_NAME("XCHG AX, Reg");
+ LUI(x4, 0xffff0);
+ // x2 <- rax
+ MV(x2, xRAX);
+ // rax[15:0] <- gd[15:0]
+ ZEXTH(x3, gd);
+ AND(xRAX, xRAX, x4);
+ OR(xRAX, xRAX, x3);
+ // gd[15:0] <- x2[15:0]
+ ZEXTH(x2, x2);
+ AND(gd, gd, x4);
+ OR(gd, gd, x2);
+ }
+ break;
+
+ case 0x98:
+ INST_NAME("CBW");
+ SLLI(x1, xRAX, 56);
+ SRAI(x1, x1, 56);
+ LUI(x2, 0xffff0);
+ AND(xRAX, xRAX, x2);
+ NOT(x2, x2);
+ AND(x1, x1, x2);
+ OR(xRAX, xRAX, x1);
+ break;
+ case 0xA5:
+ if(rep) {
+ INST_NAME("REP MOVSW");
+ CBZ_NEXT(xRCX);
+ ANDI(x1, xFlags, 1<<F_DF);
+ BNEZ_MARK2(x1);
+ MARK; // Part with DF==0
+ LH(x1, xRSI, 0);
+ ADDI(xRSI, xRSI, 2);
+ SH(x1, xRDI, 0);
+ ADDI(xRDI, xRDI, 2);
+ SUBI(xRCX, xRCX, 1);
+ BNEZ_MARK(xRCX);
+ B_NEXT_nocond;
+ MARK2; // Part with DF==1
+ LH(x1, xRSI, 0);
+ SUBI(xRSI, xRSI, 2);
+ SH(x1, xRDI, 0);
+ SUBI(xRDI, xRDI, 2);
+ SUBI(xRCX, xRCX, 1);
+ BNEZ_MARK2(xRCX);
+ // done
+ } else {
+ INST_NAME("MOVSD");
+ GETDIR(x3, x1, 2);
+ LH(x1, xRSI, 0);
+ SH(x1, xRDI, 0);
+ ADD(xRSI, xRSI, x3);
+ ADD(xRDI, xRDI, x3);
+ }
+ break;
+ case 0xA9:
+ INST_NAME("TEST AX,Iw");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ u16 = F16;
+ MOV32w(x2, u16);
+ SLLIW(x1, xRAX, 16);
+ SRLIW(x1, x1, 16);
+ emit_test16(dyn, ninst, x1, x2, x3, x4, x5);
+ break;
+ case 0xAB:
+ if(rep) {
+ INST_NAME("REP STOSW");
+ CBZ_NEXT(xRCX);
+ ANDI(x1, xFlags, 1<<F_DF);
+ BNEZ_MARK2(x1);
+ MARK; // Part with DF==0
+ SH(xRAX, xRDI, 0);
+ ADDI(xRDI, xRDI, 2);
+ SUBI(xRCX, xRCX, 1);
+ BNEZ_MARK(xRCX);
+ B_NEXT_nocond;
+ MARK2; // Part with DF==1
+ SH(xRAX, xRDI, 0);
+ SUBI(xRDI, xRDI, 2);
+ SUBI(xRCX, xRCX, 1);
+ BNEZ_MARK2(xRCX);
+ // done
+ } else {
+ INST_NAME("STOSW");
+ GETDIR(x3, x1, 2);
+ SH(xRAX, xRDI, 0);
+ ADD(xRDI, xRDI, x3);
+ }
+ break;
+
+ case 0xAF:
+ switch (rep) {
+ case 1:
+ case 2:
+ if(rep==1) {INST_NAME("REPNZ SCASW");} else {INST_NAME("REPZ SCASW");}
+ MAYSETFLAGS();
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ CBZ_NEXT(xRCX);
+ GETDIR(x3, x1, rex.w?8:2);
+ if (rex.w) {
+ MARK;
+ LD(x2, xRDI, 0);
+ ADD(xRDI, xRDI, x3);
+ ADDI(xRCX, xRCX, -1);
+ if (rep==1) {BEQ_MARK3(xRAX, x2);} else {BNE_MARK3(xRAX, x2);}
+ BNE_MARK(xRCX, xZR);
+ MARK3;
+ emit_cmp32(dyn, ninst, rex, xRAX, x2, x3, x4, x5, x6);
+ } else {
+ ZEXTH(x1, xRAX);
+ MARK;
+ LHU(x2, xRDI, 0);
+ ADD(xRDI, xRDI, x3);
+ ADDI(xRCX, xRCX, -1);
+ if (rep==1) {BEQ_MARK3(x1, x2);} else {BNE_MARK3(x1, x2);}
+ BNE_MARK(xRCX, xZR);
+ MARK3;
+ emit_cmp16(dyn, ninst, x1, x2, x3, x4, x5, x6);
+ }
+ break;
+ default:
+ INST_NAME("SCASW");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETDIR(x3, x1, rex.w?8:2);
+ if (rex.w) {
+ LD(x2, xRDI, 0);
+ emit_cmp32(dyn, ninst, rex, xRAX, x2, x3, x4, x5, x6);
+ } else {
+ ZEXTH(x1, xRAX);
+ LHU(x2, xRDI, 0);
+ emit_cmp16(dyn, ninst, x1, x2, x3, x4, x5, x6);
+ }
+ ADD(xRDI, xRDI, x3);
+ break;
+ }
+ break;
+
+ case 0xB8:
+ case 0xB9:
+ case 0xBA:
+ case 0xBB:
+ case 0xBC:
+ case 0xBD:
+ case 0xBE:
+ case 0xBF:
+ INST_NAME("MOV Reg, Iw");
+ gd = xRAX+(opcode&7)+(rex.b<<3);
+ if(rex.w) {
+ u64 = F64;
+ MOV64x(gd, u64);
+ } else {
+ u16 = F16;
+ MOV64x(x1, ~0xffff);
+ AND(gd, gd, x1);
+ if(u16<2048) {
+ ORI(gd, gd, u16);
+ } else {
+ MOV32w(x1, u16);
+ OR(gd, gd, x1);
+ }
+ }
+ break;
+
+ case 0xC1:
+ nextop = F8;
+ switch((nextop>>3)&7) {
+ case 0:
+ INST_NAME("ROL Ew, Ib");
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ SETFLAGS(X_OF|X_CF, SF_SET);
+ GETEW(x1, 1);
+ u8 = F8;
+ MOV32w(x2, u8);
+ CALL_(rol16, x1, x3);
+ EWBACK;
+ break;
+ case 1:
+ INST_NAME("ROR Ew, Ib");
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ SETFLAGS(X_OF|X_CF, SF_SET);
+ GETEW(x1, 1);
+ u8 = F8;
+ MOV32w(x2, u8);
+ CALL_(ror16, x1, x3);
+ EWBACK;
+ break;
+ case 2:
+ INST_NAME("RCL Ew, Ib");
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ READFLAGS(X_CF);
+ SETFLAGS(X_OF|X_CF, SF_SET);
+ GETEW(x1, 1);
+ u8 = F8;
+ MOV32w(x2, u8);
+ CALL_(rcl16, x1, x3);
+ EWBACK;
+ break;
+ case 3:
+ INST_NAME("RCR Ew, Ib");
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ READFLAGS(X_CF);
+ SETFLAGS(X_OF|X_CF, SF_SET);
+ GETEW(x1, 1);
+ u8 = F8;
+ MOV32w(x2, u8);
+ CALL_(rcr16, x1, x3);
+ EWBACK;
+ break;
+ case 4:
+ case 6:
+ INST_NAME("SHL Ew, Ib");
+ UFLAG_IF {MESSAGE(LOG_DUMP, "Need Optimization for flags\n");}
+ SETFLAGS(X_ALL, SF_PENDING);
+ GETEW(x1, 1);
+ u8 = F8;
+ UFLAG_IF {MOV32w(x2, (u8&0x1f));}
+ UFLAG_OP12(ed, x2)
+ if(MODREG) {
+ SLLI(ed, ed, 48+(u8&0x1f));
+ SRLI(ed, ed, 48);
+ } else {
+ SLLI(ed, ed, u8&0x1f);
+ }
+ EWBACK;
+ UFLAG_RES(ed);
+ UFLAG_DF(x3, d_shl16);
+ break;
+ case 5:
+ INST_NAME("SHR Ed, Ib");
+ UFLAG_IF {MESSAGE(LOG_DUMP, "Need Optimization for flags\n");}
+ SETFLAGS(X_ALL, SF_PENDING);
+ GETEW(x1, 1);
+ u8 = F8;
+ UFLAG_IF {MOV32w(x2, (u8&0x1f));}
+ UFLAG_OP12(ed, x2)
+ SRLI(ed, ed, u8&0x1f);
+ EWBACK;
+ UFLAG_RES(ed);
+ UFLAG_DF(x3, d_shr16);
+ break;
+ case 7:
+ INST_NAME("SAR Ed, Ib");
+ SETFLAGS(X_ALL, SF_PENDING);
+ UFLAG_IF {MESSAGE(LOG_DUMP, "Need Optimization for flags\n");}
+ GETSEW(x1, 1);
+ u8 = F8;
+ UFLAG_IF {MOV32w(x2, (u8&0x1f));}
+ UFLAG_OP12(ed, x2)
+ SRAI(ed, ed, u8&0x1f);
+ if(MODREG) {
+ ZEXTH(ed, ed);
+ }
+ EWBACK;
+ UFLAG_RES(ed);
+ UFLAG_DF(x3, d_sar16);
+ break;
+ }
+ break;
+
+ case 0xC7:
+ INST_NAME("MOV Ew, Iw");
+ nextop = F8;
+ if(MODREG) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ ADDI(x1, xZR, -1);
+ SRLI(x1, x1, 48);
+ AND(ed, ed, x1);
+ u16 = F16;
+ MOV32w(x1, u16);
+ ORI(ed, ed, x1);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, &lock, 1, 2);
+ u16 = F16;
+ MOV32w(x1, u16);
+ SH(x1, ed, fixedaddress);
+ SMWRITELOCK(lock);
+ }
+ break;
+ case 0xD1:
+ case 0xD3:
+ nextop = F8;
+ switch((nextop>>3)&7) {
+ case 5:
+ if(opcode==0xD1) {
+ INST_NAME("SHR Ew, 1");
+ MOV32w(x4, 1);
+ } else {
+ INST_NAME("SHR Ew, CL");
+ ANDI(x4, xRCX, 0x1f);
+ }
+ UFLAG_IF {MESSAGE(LOG_DUMP, "Need Optimization for flags\n");}
+ SETFLAGS(X_ALL, SF_PENDING);
+ GETEW(x1, 0);
+ UFLAG_OP12(ed, x4)
+ SRL(ed, ed, x4);
+ EWBACK;
+ UFLAG_RES(ed);
+ UFLAG_DF(x3, d_shr16);
+ break;
+ case 4:
+ case 6:
+ if(opcode==0xD1) {
+ INST_NAME("SHL Ew, 1");
+ MOV32w(x4, 1);
+ } else {
+ INST_NAME("SHL Ew, CL");
+ ANDI(x4, xRCX, 0x1f);
+ }
+ UFLAG_IF {MESSAGE(LOG_DUMP, "Need Optimization for flags\n");}
+ SETFLAGS(X_ALL, SF_PENDING);
+ GETEW(x1, 0);
+ UFLAG_OP12(ed, x4)
+ SLL(ed, ed, x4);
+ ZEXTH(ed, ed);
+ EWBACK;
+ UFLAG_RES(ed);
+ UFLAG_DF(x3, d_shl16);
+ break;
+ case 7:
+ if(opcode==0xD1) {
+ INST_NAME("SAR Ew, 1");
+ MOV32w(x4, 1);
+ } else {
+ INST_NAME("SAR Ew, CL");
+ ANDI(x4, xRCX, 0x1f);
+ }
+ UFLAG_IF {MESSAGE(LOG_DUMP, "Need Optimization for flags\n");}
+ SETFLAGS(X_ALL, SF_PENDING);
+ GETSEW(x1, 0);
+ UFLAG_OP12(ed, x4);
+ SRA(ed, ed, x4);
+ ZEXTH(ed, ed);
+ EWBACK;
+ UFLAG_RES(ed);
+ UFLAG_DF(x3, d_sar16);
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+
+ case 0xF0:
+ return dynarec64_66F0(dyn, addr, ip, ninst, rex, rep, ok, need_epilog);
+
+ case 0xF7:
+ nextop = F8;
+ switch((nextop>>3)&7) {
+ case 0:
+ case 1:
+ INST_NAME("TEST Ew, Iw");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEW(x1, 2);
+ u16 = F16;
+ MOV32w(x2, u16);
+ emit_test16(dyn, ninst, x1, x2, x3, x4, x5);
+ break;
+ case 2:
+ INST_NAME("NOT Ew");
+ GETEW(x1, 0);
+ NOT(ed, ed); // No flags affected
+ EWBACK;
+ break;
+ case 3:
+ INST_NAME("NEG Ew");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETEW(x1, 0);
+ emit_neg16(dyn, ninst, ed, x2, x4);
+ EWBACK;
+ break;
+ case 6:
+ INST_NAME("DIV Ew");
+ SETFLAGS(X_ALL, SF_SET);
+ GETEW(x1, 0);
+ ZEXTH(x2, xRAX);
+ SLLI(x3, xRDX, 48);
+ SRLI(x3, x3, 32);
+ OR(x2, x2, x3);
+ DIVUW(x3, x2, ed);
+ REMUW(x4, x2, ed);
+ MOV64x(x5, ~0xffff);
+ AND(xRAX, xRAX, x5);
+ AND(xRDX, xRDX, x5);
+ NOT(x5, x5);
+ AND(x3, x3, x5);
+ AND(x4, x4, x5);
+ OR(xRAX, xRAX, x3);
+ OR(xRDX, xRDX, x4);
+ break;
+ case 7:
+ INST_NAME("IDIV Ew");
+ NOTEST(x1);
+ SETFLAGS(X_ALL, SF_SET);
+ GETSEW(x1, 0);
+ ZEXTH(x2, xRAX);
+ SLLI(x3, xRDX, 48);
+ SRLI(x3, x3, 32);
+ OR(x2, x2, x3);
+ DIVW(x3, x2, ed);
+ REMW(x4, x2, ed);
+ MOV64x(x5, ~0xffff);
+ AND(xRAX, xRAX, x5);
+ AND(xRDX, xRDX, x5);
+ NOT(x5, x5);
+ AND(x3, x3, x5);
+ AND(x4, x4, x5);
+ OR(xRAX, xRAX, x3);
+ OR(xRDX, xRDX, x4);
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+
+ case 0xFF:
+ nextop = F8;
+ switch((nextop>>3)&7) {
+ case 0:
+ INST_NAME("INC Ew");
+ SETFLAGS(X_ALL&~X_CF, SF_SUBSET_PENDING);
+ GETEW(x1, 0);
+ emit_inc16(dyn, ninst, x1, x2, x4, x5);
+ EWBACK;
+ break;
+ case 1:
+ INST_NAME("DEC Ew");
+ SETFLAGS(X_ALL&~X_CF, SF_SUBSET_PENDING);
+ GETEW(x1, 0);
+ emit_dec16(dyn, ninst, x1, x2, x4, x5, x6);
+ EWBACK;
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+
+ default:
+ DEFAULT;
+ }
+ return addr;
+}
diff --git a/src/dynarec/rv64/dynarec_rv64_660f.c b/src/dynarec/rv64/dynarec_rv64_660f.c
new file mode 100644
index 0000000..c60d214
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_660f.c
@@ -0,0 +1,2644 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <stddef.h>
+#include <errno.h>
+
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "emu/x64run_private.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "emu/x64run_private.h"
+#include "x64trace.h"
+#include "dynarec_native.h"
+
+#include "rv64_printer.h"
+#include "dynarec_rv64_private.h"
+#include "dynarec_rv64_functions.h"
+#include "dynarec_rv64_helper.h"
+
+uintptr_t dynarec64_660F(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int* ok, int* need_epilog)
+{
+ (void)ip; (void)need_epilog;
+
+ uint8_t opcode = F8;
+ uint8_t nextop, u8, s8;
+ int32_t i32;
+ uint8_t gd, ed;
+ uint8_t wback, wb1, wb2, gback;
+ uint8_t eb1, eb2;
+ int64_t j64;
+ uint64_t tmp64u, tmp64u2;
+ int v0, v1;
+ int q0, q1;
+ int d0, d1;
+ int64_t fixedaddress, gdoffset;
+ int unscaled;
+
+ MAYUSE(d0);
+ MAYUSE(d1);
+ MAYUSE(q0);
+ MAYUSE(q1);
+ MAYUSE(eb1);
+ MAYUSE(eb2);
+ MAYUSE(j64);
+
+ static const int8_t round_round[] = { RD_RNE, RD_RDN, RD_RUP, RD_RTZ };
+
+ switch(opcode) {
+ case 0x10:
+ INST_NAME("MOVUPD Gx,Ex");
+ nextop = F8;
+ GETEX(x1, 0);
+ GETGX();
+ SSE_LOOP_MV_Q(x3);
+ break;
+ case 0x11:
+ INST_NAME("MOVUPD Ex,Gx");
+ nextop = F8;
+ GETEX(x1, 0);
+ GETGX();
+ SSE_LOOP_MV_Q2(x3);
+ if(!MODREG) SMWRITE2();
+ break;
+ case 0x12:
+ INST_NAME("MOVLPD Gx, Eq");
+ nextop = F8;
+ GETGX();
+ if(MODREG) {
+ // access register instead of memory is bad opcode!
+ DEFAULT;
+ return addr;
+ }
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x3, &fixedaddress, rex, NULL, 1, 0);
+ LD(x3, wback, fixedaddress);
+ SD(x3, gback, gdoffset+0);
+ break;
+ case 0x13:
+ INST_NAME("MOVLPD Eq, Gx");
+ nextop = F8;
+ GETGX();
+ if(MODREG) {
+ // access register instead of memory is bad opcode!
+ DEFAULT;
+ return addr;
+ }
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x3, &fixedaddress, rex, NULL, 1, 0);
+ LD(x3, gback, gdoffset+0);
+ SD(x3, wback, fixedaddress);
+ SMWRITE2();
+ break;
+ case 0x14:
+ INST_NAME("UNPCKLPD Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ // GX->q[1] = EX->q[0];
+ LD(x3, wback, fixedaddress+0);
+ SD(x3, gback, gdoffset+8);
+ break;
+ case 0x15:
+ INST_NAME("UNPCKHPD Gx, Ex");
+ nextop = F8;
+ GETEX(x1, 0);
+ GETGX();
+ // GX->q[0] = GX->q[1];
+ LD(x3, gback, gdoffset+8);
+ SD(x3, gback, gdoffset+0);
+ // GX->q[1] = EX->q[1];
+ LD(x3, wback, fixedaddress+8);
+ SD(x3, gback, gdoffset+8);
+ break;
+ case 0x16:
+ INST_NAME("MOVHPD Gx, Eq");
+ nextop = F8;
+ GETGX();
+ if(MODREG) {
+ // access register instead of memory is bad opcode!
+ DEFAULT;
+ return addr;
+ }
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x3, &fixedaddress, rex, NULL, 1, 0);
+ LD(x3, wback, fixedaddress);
+ SD(x3, gback, gdoffset+8);
+ break;
+ case 0x1F:
+ INST_NAME("NOP (multibyte)");
+ nextop = F8;
+ FAKEED;
+ break;
+ case 0x28:
+ INST_NAME("MOVAPD Gx,Ex");
+ nextop = F8;
+ GETEX(x1, 0);
+ GETGX();
+ SSE_LOOP_MV_Q(x3);
+ break;
+ case 0x29:
+ INST_NAME("MOVAPD Ex,Gx");
+ nextop = F8;
+ GETEX(x1, 0);
+ GETGX();
+ SSE_LOOP_MV_Q2(x3);
+ if(!MODREG) SMWRITE2();
+ break;
+ case 0x2B:
+ INST_NAME("MOVNTPD Ex, Gx");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_MV_Q2(x3);
+ break;
+ case 0x2E:
+ // no special check...
+ case 0x2F:
+ if(opcode==0x2F) {INST_NAME("COMISD Gx, Ex");} else {INST_NAME("UCOMISD Gx, Ex");}
+ SETFLAGS(X_ALL, SF_SET);
+ SET_DFNONE();
+ nextop = F8;
+ GETGXSD(d0);
+ GETEXSD(v0, 0);
+ CLEAR_FLAGS();
+ // if isnan(d0) || isnan(v0)
+ IFX(X_ZF | X_PF | X_CF) {
+ FEQD(x3, d0, d0);
+ FEQD(x2, v0, v0);
+ AND(x2, x2, x3);
+ BNE_MARK(x2, xZR);
+ ORI(xFlags, xFlags, (1<<F_ZF) | (1<<F_PF) | (1<<F_CF));
+ B_NEXT_nocond;
+ }
+ MARK;
+ // else if isless(d0, v0)
+ IFX(X_CF) {
+ FLTD(x2, d0, v0);
+ BEQ_MARK2(x2, xZR);
+ ORI(xFlags, xFlags, 1<<F_CF);
+ B_NEXT_nocond;
+ }
+ MARK2;
+ // else if d0 == v0
+ IFX(X_ZF) {
+ FEQD(x2, d0, v0);
+ CBZ_NEXT(x2);
+ ORI(xFlags, xFlags, 1<<F_ZF);
+ }
+ break;
+ case 0x38: // SSSE3 opcodes
+ nextop = F8;
+ switch(nextop) {
+ case 0x00:
+ INST_NAME("PSHUFB Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ sse_forget_reg(dyn, ninst, x5);
+
+ ADDI(x5, xEmu, offsetof(x64emu_t, scratch));
+
+ // perserve gd
+ LD(x3, gback, gdoffset+0);
+ LD(x4, gback, gdoffset+8);
+ SD(x3, x5, 0);
+ SD(x4, x5, 8);
+
+ for (int i=0; i<16; ++i) {
+ LBU(x3, wback, fixedaddress+i);
+ ANDI(x4, x3, 128);
+ BEQZ(x4, 12);
+ SB(xZR, gback, gdoffset+i);
+ BEQZ(xZR, 20); // continue
+ ANDI(x4, x3, 15);
+ ADD(x4, x4, x5);
+ LBU(x4, x4, 0);
+ SB(x4, gback, gdoffset+i);
+ }
+ break;
+ case 0x01:
+ INST_NAME("PHADDW Gx, Ex");
+ nextop = F8;
+ GETGX();
+ for (int i=0; i<4; ++i) {
+ // GX->sw[i] = GX->sw[i*2+0]+GX->sw[i*2+1];
+ LH(x3, gback, gdoffset+2*(i*2+0));
+ LH(x4, gback, gdoffset+2*(i*2+1));
+ ADDW(x3, x3, x4);
+ SH(x3, gback, gdoffset+2*i);
+ }
+ if (MODREG && gd==(nextop&7)+(rex.b<<3)) {
+ // GX->q[1] = GX->q[0];
+ LD(x3, gback, gdoffset+0);
+ SD(x3, gback, gdoffset+8);
+ } else {
+ GETEX(x2, 0);
+ for (int i=0; i<4; ++i) {
+ // GX->sw[4+i] = EX->sw[i*2+0] + EX->sw[i*2+1];
+ LH(x3, wback, fixedaddress+2*(i*2+0));
+ LH(x4, wback, fixedaddress+2*(i*2+1));
+ ADDW(x3, x3, x4);
+ SH(x3, gback, gdoffset+2*(4+i));
+ }
+ }
+ break;
+ case 0x02:
+ INST_NAME("PHADDD Gx, Ex");
+ nextop = F8;
+ GETGX();
+ // GX->sd[0] += GX->sd[1];
+ LW(x3, gback, gdoffset+0*4);
+ LW(x4, gback, gdoffset+1*4);
+ ADDW(x3, x3, x4);
+ SW(x3, gback, gdoffset+0*4);
+ // GX->sd[1] = GX->sd[2] + GX->sd[3];
+ LW(x3, gback, gdoffset+2*4);
+ LW(x4, gback, gdoffset+3*4);
+ ADDW(x3, x3, x4);
+ SW(x3, gback, gdoffset+1*4);
+ if (MODREG && gd==(nextop&7)+(rex.b<<3)) {
+ // GX->q[1] = GX->q[0];
+ LD(x3, gback, gdoffset+0);
+ SD(x3, gback, gdoffset+8);
+ } else {
+ GETEX(x2, 0);
+ // GX->sd[2] = EX->sd[0] + EX->sd[1];
+ LW(x3, wback, fixedaddress+0*4);
+ LW(x4, wback, fixedaddress+1*4);
+ ADDW(x3, x3, x4);
+ SW(x3, gback, gdoffset+2*4);
+ // GX->sd[3] = EX->sd[2] + EX->sd[3];
+ LW(x3, wback, fixedaddress+2*4);
+ LW(x4, wback, fixedaddress+3*4);
+ ADDW(x3, x3, x4);
+ SW(x3, gback, gdoffset+3*4);
+ }
+ break;
+
+ case 0x04:
+ INST_NAME("PADDUBSW Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ MOV64x(x5, 32767);
+ MOV64x(x6, -32768);
+ for(int i=0; i<8; ++i) {
+ LBU(x3, gback, gdoffset+i*2);
+ LB(x4, wback, fixedaddress+i*2);
+ MUL(x9, x3, x4);
+ LBU(x3, gback, gdoffset+i*2+1);
+ LB(x4, wback, fixedaddress+i*2+1);
+ MUL(x3, x3, x4);
+ ADD(x3, x3, x9);
+ if(rv64_zbb) {
+ MIN(x3, x3, x5);
+ MAX(x3, x3, x6);
+ } else {
+ BLT(x3, x5, 4+4);
+ MV(x3, x5);
+ BLT(x6, x3, 4+4);
+ MV(x3, x6);
+ }
+ SH(x3, gback, gdoffset+i*2);
+ }
+ break;
+
+ case 0x08:
+ INST_NAME("PSIGNB Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=0; i<16; ++i) {
+ LB(x3, gback, gdoffset+i);
+ LB(x4, wback, fixedaddress+i);
+ BGE(x4, xZR, 4+4);
+ NEG(x3, x3);
+ BNE(x4, xZR, 4+4);
+ MOV_U12(x3, 0);
+ SB(x3, gback, gdoffset+i);
+ }
+ break;
+ case 0x09:
+ INST_NAME("PSIGNW Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=0; i<8; ++i) {
+ LH(x3, gback, gdoffset+i*2);
+ LH(x4, wback, fixedaddress+i*2);
+ BGE(x4, xZR, 4+4);
+ NEG(x3, x3);
+ BNE(x4, xZR, 4+4);
+ MOV_U12(x3, 0);
+ SH(x3, gback, gdoffset+i*2);
+ }
+ break;
+ case 0x0A:
+ INST_NAME("PSIGND Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=0; i<4; ++i) {
+ LW(x3, gback, gdoffset+i*4);
+ LW(x4, wback, fixedaddress+i*4);
+ BGE(x4, xZR, 4+4);
+ NEG(x3, x3);
+ BNE(x4, xZR, 4+4);
+ ADDI(x3, xZR, 0);
+ SW(x3, gback, gdoffset+i*4);
+ }
+ break;
+ case 0x0B:
+ INST_NAME("PMULHRSW Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=0; i<8; ++i) {
+ LH(x3, gback, gdoffset+i*2);
+ LH(x4, wback, fixedaddress+i*2);
+ MUL(x3, x3, x4);
+ SRAI(x3, x3, 14);
+ ADDI(x3, x3, 1);
+ SRAI(x3, x3, 1);
+ SH(x3, gback, gdoffset+i*2);
+ }
+ break;
+ case 0x10:
+ INST_NAME("PBLENDVB Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ sse_forget_reg(dyn, ninst, 0); // forget xmm[0]
+ for (int i=0; i<16; ++i) {
+ LB(x3, xEmu, offsetof(x64emu_t, xmm[0])+i);
+ BGE(x3, xZR, 12); // continue
+ LBU(x3, wback, fixedaddress+i);
+ SB(x3, gback, gdoffset+i);
+ // continue
+ }
+ break;
+ case 0x17:
+ INST_NAME("PTEST Gx, Ex");
+ nextop = F8;
+ SETFLAGS(X_ALL, SF_SET);
+ GETGX();
+ GETEX(x2, 0);
+ CLEAR_FLAGS();
+ SET_DFNONE();
+ IFX(X_ZF|X_CF) {
+ LD(x5, wback, fixedaddress+0);
+ LD(x6, wback, fixedaddress+8);
+
+ IFX(X_ZF) {
+ LD(x3, gback, gdoffset+0);
+ LD(x4, gback, gdoffset+8);
+ AND(x3, x3, x5);
+ AND(x4, x4, x6);
+ OR(x3, x3, x4);
+ BNEZ(x3, 8);
+ ORI(xFlags, xFlags, 1<<F_ZF);
+ }
+ IFX(X_CF) {
+ LD(x3, gback, gdoffset+0);
+ NOT(x3, x3);
+ LD(x4, gback, gdoffset+8);
+ NOT(x4, x4);
+ AND(x3, x3, x5);
+ AND(x4, x4, x6);
+ OR(x3, x3, x4);
+ BNEZ(x3, 8);
+ ORI(xFlags, xFlags, 1<<F_CF);
+ }
+ }
+ break;
+
+ case 0x1C:
+ INST_NAME("PABSB Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=0; i<16; ++i) {
+ LB(x4, wback, fixedaddress+i);
+ BGE(x4, xZR, 4+4);
+ NEG(x4, x4);
+ SB(x4, gback, gdoffset+i);
+ }
+ break;
+ case 0x1D:
+ INST_NAME("PABSW Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=0; i<8; ++i) {
+ LH(x4, wback, fixedaddress+i*2);
+ BGE(x4, xZR, 4+4);
+ NEG(x4, x4);
+ SH(x4, gback, gdoffset+i*2);
+ }
+ break;
+ case 0x1E:
+ INST_NAME("PABSD Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ MOV64x(x5, ~(1<<31));
+ for(int i=0; i<4; ++i) {
+ LW(x4, wback, fixedaddress+i*4);
+ BGE(x4, xZR, 4+4);
+ NEG(x4, x4);
+ SW(x4, gback, gdoffset+i*4);
+ }
+ break;
+
+ case 0x2B:
+ INST_NAME("PACKUSDW Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ MOV64x(x5, 65535);
+ for(int i=0; i<4; ++i) {
+ LW(x3, gback, gdoffset+i*4);
+ if(rv64_zbb) {
+ MIN(x3, x3, x5);
+ MAX(x3, x3, xZR);
+ } else {
+ BGE(x3, xZR, 4+4);
+ MV(x3, xZR);
+ BLT(x3, x5, 4+4);
+ MV(x3, x5);
+ }
+ SH(x3, gback, gdoffset+i*2);
+ }
+ if(MODREG && gd==ed) {
+ LD(x3, gback, gdoffset+0);
+ SD(x3, gback, gdoffset+8);
+ } else for(int i=0; i<4; ++i) {
+ LW(x3, wback, fixedaddress+i*4);
+ if(rv64_zbb) {
+ MIN(x3, x3, x5);
+ MAX(x3, x3, xZR);
+ } else {
+ BGE(x3, xZR, 4+4);
+ MV(x3, xZR);
+ BLT(x3, x5, 4+4);
+ MV(x3, x5);
+ }
+ SH(x3, gback, gdoffset+8+i*2);
+ }
+ break;
+
+ case 0x30:
+ INST_NAME("PMOVZXBW Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=7; i>=0; --i) {
+ LBU(x3, wback, fixedaddress+i);
+ SH(x3, gback, gdoffset+i*2);
+ }
+ break;
+ case 0x31:
+ INST_NAME("PMOVZXBD Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=3; i>=0; --i) {
+ LBU(x3, wback, fixedaddress+i);
+ SW(x3, gback, gdoffset+i*4);
+ }
+ break;
+ case 0x32:
+ INST_NAME("PMOVZXBQ Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=1; i>=0; --i) {
+ LBU(x3, wback, fixedaddress+i);
+ SD(x3, gback, gdoffset+i*8);
+ }
+ break;
+ case 0x33:
+ INST_NAME("PMOVZXWD Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=3; i>=0; --i) {
+ LHU(x3, wback, fixedaddress+i*2);
+ SW(x3, gback, gdoffset+i*4);
+ }
+ break;
+ case 0x34:
+ INST_NAME("PMOVZXWQ Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=1; i>=0; --i) {
+ LHU(x3, wback, fixedaddress+i*2);
+ SD(x3, gback, gdoffset+i*8);
+ }
+ break;
+ case 0x35:
+ INST_NAME("PMOVZXDQ Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=1; i>=0; --i) {
+ LWU(x3, wback, fixedaddress+i*4);
+ SD(x3, gback, gdoffset+i*8);
+ }
+ break;
+
+ case 0x38:
+ INST_NAME("PMINSB Gx, Ex"); // SSE4 opcode!
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=0; i<16; ++i) {
+ LB(x3, gback, gdoffset+i);
+ LB(x4, wback, fixedaddress+i);
+ if(rv64_zbb) MIN(x4, x3, x4); else BLT(x3, x4, 4+4);
+ SB(x4, gback, gdoffset+i);
+ }
+ break;
+ case 0x39:
+ INST_NAME("PMINSD Gx, Ex"); // SSE4 opcode!
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=0; i<4; ++i) {
+ LW(x3, gback, gdoffset+i*4);
+ LW(x4, wback, fixedaddress+i*4);
+ if(rv64_zbb) MIN(x4, x3, x4); else BLT(x3, x4, 4+4);
+ SW(x4, gback, gdoffset+i*4);
+ }
+ break;
+ case 0x3A:
+ INST_NAME("PMINUW Gx, Ex"); // SSE4 opcode!
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=0; i<8; ++i) {
+ LHU(x3, gback, gdoffset+i*2);
+ LHU(x4, wback, fixedaddress+i*2);
+ if(rv64_zbb) MINU(x4, x3, x4); else BLTU(x3, x4, 4+4);
+ SH(x4, gback, gdoffset+i*2);
+ }
+ break;
+ case 0x3B:
+ INST_NAME("PMINUD Gx, Ex"); // SSE4 opcode!
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=0; i<4; ++i) {
+ LWU(x3, gback, gdoffset+i*4);
+ LWU(x4, wback, fixedaddress+i*4);
+ if(rv64_zbb) MINU(x4, x3, x4); else BLTU(x3, x4, 4+4);
+ SW(x4, gback, gdoffset+i*4);
+ }
+ break;
+ case 0x3C:
+ INST_NAME("PMAXSB Gx, Ex"); // SSE4 opcode!
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=0; i<16; ++i) {
+ LB(x3, gback, gdoffset+i);
+ LB(x4, wback, fixedaddress+i);
+ if(rv64_zbb) MAX(x4, x3, x4); else BLT(x4, x3, 4+4);
+ SB(x4, gback, gdoffset+i);
+ }
+ break;
+ case 0x3D:
+ INST_NAME("PMAXSD Gx, Ex"); // SSE4 opcode!
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=0; i<4; ++i) {
+ LW(x3, gback, gdoffset+i*4);
+ LW(x4, wback, fixedaddress+i*4);
+ if(rv64_zbb) MAX(x4, x3, x4); else BLT(x4, x3, 4+4);
+ SW(x4, gback, gdoffset+i*4);
+ }
+ break;
+ case 0x3E:
+ INST_NAME("PMAXUW Gx, Ex"); // SSE4 opcode!
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=0; i<8; ++i) {
+ LHU(x3, gback, gdoffset+i*2);
+ LHU(x4, wback, fixedaddress+i*2);
+ if(rv64_zbb) MAXU(x4, x3, x4); else BLTU(x4, x3, 4+4);
+ SH(x4, gback, gdoffset+i*2);
+ }
+ break;
+ case 0x3F:
+ INST_NAME("PMAXUD Gx, Ex"); // SSE4 opcode!
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=0; i<4; ++i) {
+ LWU(x3, gback, gdoffset+i*4);
+ LWU(x4, wback, fixedaddress+i*4);
+ if(rv64_zbb) MAXU(x4, x3, x4); else BLTU(x4, x3, 4+4);
+ SW(x4, gback, gdoffset+i*4);
+ }
+ break;
+ case 0x40:
+ INST_NAME("PMULLD Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=0; i<4; ++i) {
+ LW(x3, gback, gdoffset+i*4);
+ LW(x4, wback, fixedaddress+i*4);
+ MUL(x3, x3, x4);
+ SW(x3, gback, gdoffset+i*4);
+ }
+ break;
+ case 0xDB:
+ INST_NAME("AESIMC Gx, Ex"); // AES-NI
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_MV_Q(x3);
+ sse_forget_reg(dyn, ninst, gd);
+ MOV32w(x1, gd);
+ CALL(native_aesimc, -1);
+ break;
+ case 0xDC:
+ INST_NAME("AESENC Gx, Ex"); // AES-NI
+ nextop = F8;
+ GETG;
+ sse_forget_reg(dyn, ninst, gd);
+ MOV32w(x1, gd);
+ CALL(native_aese, -1);
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_Q(x3, x4, XOR(x3, x3, x4));
+ break;
+ case 0xDD:
+ INST_NAME("AESENCLAST Gx, Ex"); // AES-NI
+ nextop = F8;
+ GETG;
+ sse_forget_reg(dyn, ninst, gd);
+ MOV32w(x1, gd);
+ CALL(native_aeselast, -1);
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_Q(x3, x4, XOR(x3, x3, x4));
+ break;
+ case 0xDE:
+ INST_NAME("AESDEC Gx, Ex"); // AES-NI
+ nextop = F8;
+ GETG;
+ sse_forget_reg(dyn, ninst, gd);
+ MOV32w(x1, gd);
+ CALL(native_aesd, -1);
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_Q(x3, x4, XOR(x3, x3, x4));
+ break;
+
+ case 0xDF:
+ INST_NAME("AESDECLAST Gx, Ex"); // AES-NI
+ nextop = F8;
+ GETG;
+ sse_forget_reg(dyn, ninst, gd);
+ MOV32w(x1, gd);
+ CALL(native_aesdlast, -1);
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_Q(x3, x4, XOR(x3, x3, x4));
+ break;
+ case 0xF0:
+ INST_NAME("MOVBE Gw, Ew");
+ nextop=F8;
+ GETGD;
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &ed, x3, x2, &fixedaddress, rex, NULL, 0, 1);
+ LHU(x1, ed, fixedaddress);
+ if (rv64_zbb) {
+ REV8(x1, x1);
+ SRLI(x1, x1, 48);
+ } else {
+ ANDI(x2, x1, 0xff);
+ SLLI(x2, x2, 8);
+ SRLI(x1, x1, 8);
+ OR(x1, x1, x2);
+ }
+ LUI(x2, 0xffff0);
+ AND(gd, gd, x2);
+ OR(gd, gd, x1);
+ break;
+ case 0xF1:
+ INST_NAME("MOVBE Ew, Gw");
+ nextop=F8;
+ GETGD;
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, x2, &fixedaddress, rex, NULL, 0, 1);
+ if (rv64_zbb) {
+ REV8(x1, gd);
+ SRLI(x1, x1, 48);
+ } else {
+ ANDI(x1, gd, 0xff);
+ SLLI(x1, x1, 8);
+ SRLI(x2, gd, 8);
+ ANDI(x2, x2, 0xff);
+ OR(x1, x1, x2);
+ }
+ SH(x1, wback, fixedaddress);
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+ case 0x3A: // these are some more SSSE3+ opcodes
+ opcode = F8;
+ switch(opcode) {
+ case 0x0B:
+ INST_NAME("ROUNDSD Gx, Ex, Ib");
+ nextop = F8;
+ GETEXSD(d0, 1);
+ GETGXSD_empty(v0);
+ d1 = fpu_get_scratch(dyn);
+ v1 = fpu_get_scratch(dyn);
+ u8 = F8;
+ FEQD(x2, d0, d0);
+ BNEZ_MARK(x2);
+ if (v0!=d0) FMVD(v0, d0);
+ B_NEXT_nocond;
+ MARK; // d0 is not nan
+ FABSD(v1, d0);
+ MOV64x(x3, 1ULL << __DBL_MANT_DIG__);
+ FCVTDL(d1, x3, RD_RTZ);
+ FLTD(x3, v1, d1);
+ BNEZ_MARK2(x3);
+ if (v0!=d0) FMVD(v0, d0);
+ B_NEXT_nocond;
+ MARK2;
+ if(u8&4) {
+ u8 = sse_setround(dyn, ninst, x4, x2);
+ FCVTLD(x5, d0, RD_DYN);
+ FCVTDL(v0, x5, RD_RTZ);
+ x87_restoreround(dyn, ninst, u8);
+ } else {
+ FCVTLD(x5, d0, round_round[u8&3]);
+ FCVTDL(v0, x5, RD_RTZ);
+ }
+ break;
+ case 0x09:
+ INST_NAME("ROUNDPD Gx, Ex, Ib");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 1);
+ u8 = F8;
+ d0 = fpu_get_scratch(dyn);
+ d1 = fpu_get_scratch(dyn);
+ v1 = fpu_get_scratch(dyn);
+ MOV64x(x3, 1ULL << __DBL_MANT_DIG__);
+ FCVTDL(d1, x3, RD_RTZ);
+
+ // i = 0
+ FLD(d0, wback, fixedaddress);
+ FEQD(x4, d0, d0);
+ BNEZ(x4, 8);
+ B_MARK_nocond;
+ // d0 is not nan
+ FABSD(v1, d0);
+ FLTD(x4, v1, d1);
+ BNEZ(x4, 8);
+ B_MARK_nocond;
+ if(u8&4) {
+ u8 = sse_setround(dyn, ninst, x4, x5);
+ FCVTLD(x5, d0, RD_DYN);
+ FCVTDL(d0, x5, RD_RTZ);
+ x87_restoreround(dyn, ninst, u8);
+ } else {
+ FCVTLD(x5, d0, round_round[u8&3]);
+ FCVTDL(d0, x5, RD_RTZ);
+ }
+ MARK;
+ FSD(d0, gback, gdoffset+0);
+
+ // i = 1
+ FLD(d0, wback, fixedaddress+8);
+ FEQD(x4, d0, d0);
+ BNEZ(x4, 8);
+ B_MARK2_nocond;
+ // d0 is not nan
+ FABSD(v1, d0);
+ FLTD(x4, v1, d1);
+ BNEZ(x4, 8);
+ B_MARK2_nocond;
+ if(u8&4) {
+ u8 = sse_setround(dyn, ninst, x4, x5);
+ FCVTLD(x5, d0, RD_DYN);
+ FCVTDL(d0, x5, RD_RTZ);
+ x87_restoreround(dyn, ninst, u8);
+ } else {
+ FCVTLD(x5, d0, round_round[u8&3]);
+ FCVTDL(d0, x5, RD_RTZ);
+ }
+ MARK2;
+ FSD(d0, gback, gdoffset+8);
+ break;
+ case 0x0E:
+ INST_NAME("PBLENDW Gx, Ex, Ib");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 1);
+ u8 = F8;
+ i32 = 0;
+ if (MODREG && gd==ed) break;
+ while (u8)
+ if(u8&1) {
+ if(!(i32&1) && u8&2) {
+ if(!(i32&3) && (u8&0xf)==0xf) {
+ // whole 64bits
+ LD(x3, wback, fixedaddress+8*(i32>>2));
+ SD(x3, gback, gdoffset+8*(i32>>2));
+ i32+=4;
+ u8>>=4;
+ } else {
+ // 32bits
+ LWU(x3, wback, fixedaddress+4*(i32>>1));
+ SW(x3, gback, gdoffset+4*(i32>>1));
+ i32+=2;
+ u8>>=2;
+ }
+ } else {
+ // 16 bits
+ LHU(x3, wback, fixedaddress+2*i32);
+ SH(x3, gback, gdoffset+2*i32);
+ i32++;
+ u8>>=1;
+ }
+ } else {
+ // nope
+ i32++;
+ u8>>=1;
+ }
+ break;
+ case 0x0F:
+ INST_NAME("PALIGNR Gx, Ex, Ib");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 1);
+ u8 = F8;
+ sse_forget_reg(dyn, ninst, x5);
+ ADDI(x5, xEmu, offsetof(x64emu_t, scratch));
+ // perserve gd
+ LD(x3, gback, gdoffset+0);
+ LD(x4, gback, gdoffset+8);
+ SD(x3, x5, 0);
+ SD(x4, x5, 8);
+ if(u8>31) {
+ SD(xZR, gback, gdoffset+0);
+ SD(xZR, gback, gdoffset+8);
+ } else {
+ for (int i=0; i<16; ++i, ++u8) {
+ if (u8>15) {
+ if(u8>31) {
+ SB(xZR, gback, gdoffset+i);
+ continue;
+ }
+ else LBU(x3, x5, u8-16);
+ } else {
+ LBU(x3, wback, fixedaddress+u8);
+ }
+ SB(x3, gback, gdoffset+i);
+ }
+ }
+ break;
+ case 0x16:
+ if(rex.w) {INST_NAME("PEXTRQ Ed, Gx, Ib");} else {INST_NAME("PEXTRD Ed, Gx, Ib");}
+ nextop = F8;
+ GETGX();
+ GETED(1);
+ u8 = F8;
+ if(rex.w)
+ LD(ed, gback, gdoffset+8*(u8&1));
+ else
+ LWU(ed, gback, gdoffset+4*(u8&3));
+ if (wback) {
+ SDxw(ed, wback, fixedaddress);
+ SMWRITE2();
+ }
+ break;
+ case 0x20:
+ INST_NAME("PINSRB Gx, ED, Ib");
+ nextop = F8;
+ GETGX();
+ GETED(1);
+ u8 = F8;
+ SB(ed, gback, gdoffset+u8&0xF);
+ break;
+ case 0x21:
+ INST_NAME("INSERTPS GX, EX, Ib");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 1);
+ u8 = F8;
+ if(MODREG) s8 = (u8>>6)&3; else s8 = 0;
+ // GX->ud[(tmp8u>>4)&3] = EX->ud[tmp8s];
+ LWU(x3, wback, fixedaddress+4*s8);
+ SW(x3, gback, gdoffset+4*(u8>>4));
+ for(int i=0; i<4; ++i) {
+ if(u8&(1<<i))
+ // GX->ud[i] = 0;
+ SW(xZR, gback, gdoffset+4*i);
+ }
+ break;
+ case 0x22:
+ INST_NAME("PINSRD Gx, ED, Ib");
+ nextop = F8;
+ GETGX();
+ GETED(1);
+ u8 = F8;
+ if(rex.w) {
+ SD(ed, gback, gdoffset+8*(u8&0x1));
+ } else {
+ SW(ed, gback, gdoffset+4*(u8&0x3));
+ }
+ break;
+ case 0x44:
+ INST_NAME("PCLMULQDQ Gx, Ex, Ib");
+ nextop = F8;
+ GETG;
+ sse_forget_reg(dyn, ninst, gd);
+ MOV32w(x1, gd); // gx
+ if(MODREG) {
+ ed = (nextop&7)+(rex.b<<3);
+ sse_forget_reg(dyn, ninst, ed);
+ MOV32w(x2, ed);
+ MOV32w(x3, 0); // p = NULL
+ } else {
+ MOV32w(x2, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x3, x5, &fixedaddress, rex, NULL, 0, 1);
+ if(ed!=x3) {
+ MV(x3, ed);
+ }
+ }
+ u8 = F8;
+ MOV32w(x4, u8);
+ CALL(native_pclmul, -1);
+ break;
+ case 0xDF:
+ INST_NAME("AESKEYGENASSIST Gx, Ex, Ib"); // AES-NI
+ nextop = F8;
+ GETG;
+ sse_forget_reg(dyn, ninst, gd);
+ MOV32w(x1, gd); // gx
+ if(MODREG) {
+ ed = (nextop&7)+(rex.b<<3);
+ sse_forget_reg(dyn, ninst, ed);
+ MOV32w(x2, ed);
+ MOV32w(x3, 0); //p = NULL
+ } else {
+ MOV32w(x2, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x3, x2, &fixedaddress, rex, NULL, 0, 1);
+ if(ed!=x3) {
+ MV(x3, ed);
+ }
+ }
+ u8 = F8;
+ MOV32w(x4, u8);
+ CALL(native_aeskeygenassist, -1);
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+ #define GO(GETFLAGS, NO, YES, F) \
+ READFLAGS(F); \
+ GETFLAGS; \
+ nextop=F8; \
+ GETGD; \
+ if(MODREG) { \
+ ed = xRAX+(nextop&7)+(rex.b<<3); \
+ ZEXTH(x4, ed); \
+ ed = x4; \
+ } else { \
+ SMREAD(); \
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x4, &fixedaddress, rex, NULL, 1, 0); \
+ LHU(x4, ed, fixedaddress); \
+ ed = x4; \
+ } \
+ B##NO(x1, 4+3*4); \
+ LUI(x3, 0xffff0); \
+ AND(gd, gd, x3); \
+ OR(gd, gd, ed);
+
+ GOCOND(0x40, "CMOV", "Gw, Ew");
+ #undef GO
+ case 0x50:
+ INST_NAME("PMOVMSKD Gd, Ex");
+ nextop = F8;
+ GETGD;
+ GETEX(x1, 0);
+ MV(gd, xZR);
+ for(int i=0; i<2; ++i) {
+ // GD->dword[0] |= ((EX->q[i]>>63)&1)<<i;
+ LD(x2, wback, fixedaddress+8*i);
+ SRLI(x2, x2, 63);
+ if (i) SLLI(x2, x2, 1);
+ OR(gd, gd, x2);
+ }
+ break;
+ case 0x51:
+ INST_NAME("SQRTPD Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ d0 = fpu_get_scratch(dyn);
+ if(!box64_dynarec_fastnan) {
+ d1 = fpu_get_scratch(dyn);
+ FMVDX(d1, xZR);
+ }
+ for (int i=0; i<2; ++i) {
+ FLD(d0, wback, fixedaddress+i*8);
+ if(!box64_dynarec_fastnan) {
+ FLTD(x3, d0, d1);
+ }
+ FSQRTD(d0, d0);
+ if(!box64_dynarec_fastnan) {
+ BEQ(x3, xZR, 8);
+ FNEGD(d0, d0);
+ }
+ FSD(d0, gback, gdoffset+i*8);
+ }
+ break;
+ case 0x54:
+ INST_NAME("ANDPD Gx, Ex");
+ nextop = F8;
+ GETEX(x1, 0);
+ GETGX();
+ SSE_LOOP_Q(x3, x4, AND(x3, x3, x4));
+ break;
+ case 0x55:
+ INST_NAME("ANDNPD Gx, Ex");
+ nextop = F8;
+ GETEX(x1, 0);
+ GETGX();
+ SSE_LOOP_Q(x3, x4, NOT(x3, x3); AND(x3, x3, x4));
+ break;
+ case 0x56:
+ INST_NAME("ORPD Gx, Ex");
+ nextop = F8;
+ GETEX(x1, 0);
+ GETGX();
+ SSE_LOOP_Q(x3, x4, OR(x3, x3, x4));
+ break;
+ case 0x57:
+ INST_NAME("XORPD Gx, Ex");
+ nextop = F8;
+ GETEX(x1, 0);
+ GETGX();
+ SSE_LOOP_Q(x3, x4, XOR(x3, x3, x4));
+ break;
+ case 0x58:
+ INST_NAME("ADDPD Gx, Ex");
+ nextop = F8;
+ GETEX(x1, 0);
+ GETGX();
+ SSE_LOOP_FQ(x3, x4, {
+ if(!box64_dynarec_fastnan) {
+ FEQD(x3, v0, v0);
+ FEQD(x4, v1, v1);
+ }
+ FADDD(v0, v0, v1);
+ if(!box64_dynarec_fastnan) {
+ AND(x3, x3, x4);
+ BEQZ(x3, 16);
+ FEQD(x3, v0, v0);
+ BNEZ(x3, 8);
+ FNEGD(v0, v0);
+ }
+ });
+ break;
+ case 0x59:
+ INST_NAME("MULPD Gx, Ex");
+ nextop = F8;
+ GETEX(x1, 0);
+ GETGX();
+ SSE_LOOP_FQ(x3, x4, {
+ if(!box64_dynarec_fastnan) {
+ FEQD(x3, v0, v0);
+ FEQD(x4, v1, v1);
+ }
+ FMULD(v0, v0, v1);
+ if(!box64_dynarec_fastnan) {
+ AND(x3, x3, x4);
+ BEQZ(x3, 16);
+ FEQD(x3, v0, v0);
+ BNEZ(x3, 8);
+ FNEGD(v0, v0);
+ }
+ });
+ break;
+ case 0x5A:
+ INST_NAME("CVTPD2PS Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ d0 = fpu_get_scratch(dyn);
+ // GX->f[0] = EX->d[0];
+ FLD(d0, wback, fixedaddress+0);
+ FCVTSD(d0, d0);
+ FSD(d0, gback, gdoffset+0);
+ // GX->f[1] = EX->d[1];
+ FLD(d0, wback, fixedaddress+8);
+ FCVTSD(d0, d0);
+ FSD(d0, gback, gdoffset+4);
+ // GX->q[1] = 0;
+ SD(xZR, gback, gdoffset+8);
+ break;
+ case 0x5B:
+ INST_NAME("CVTPS2DQ Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ d0 = fpu_get_scratch(dyn);
+ u8 = sse_setround(dyn, ninst, x6, x4);
+ for (int i=0; i<4; ++i) {
+ FLW(d0, wback, fixedaddress+4*i);
+ FCVTLS(x3, d0, RD_DYN);
+ SEXT_W(x5, x3);
+ SUB(x5, x5, x3);
+ BEQZ(x5, 8);
+ LUI(x3, 0x80000); // INT32_MIN
+ SW(x3, gback, gdoffset+4*i);
+ }
+ x87_restoreround(dyn, ninst, u8);
+ break;
+ case 0x5C:
+ INST_NAME("SUBPD Gx, Ex");
+ nextop = F8;
+ GETEX(x1, 0);
+ GETGX();
+ SSE_LOOP_FQ(x3, x4, {
+ if(!box64_dynarec_fastnan) {
+ FEQD(x3, v0, v0);
+ FEQD(x4, v1, v1);
+ }
+ FSUBD(v0, v0, v1);
+ if(!box64_dynarec_fastnan) {
+ AND(x3, x3, x4);
+ BEQZ(x3, 16);
+ FEQD(x3, v0, v0);
+ BNEZ(x3, 8);
+ FNEGD(v0, v0);
+ }
+ });
+ break;
+ case 0x5D:
+ INST_NAME("MINPD Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ d0 = fpu_get_scratch(dyn);
+ d1 = fpu_get_scratch(dyn);
+ for (int i=0; i<2; ++i) {
+ FLD(d0, gback, gdoffset+8*i);
+ FLD(d1, wback, fixedaddress+8*i);
+ FEQD(x3, d0, d0);
+ FEQD(x4, d1, d1);
+ AND(x3, x3, x4);
+ BEQ(x3, xZR, 12);
+ FLTD(x3, d1, d0);
+ BEQ(x3, xZR, 8); // continue
+ FSD(d1, gback, gdoffset+8*i);
+ }
+ break;
+ case 0x5E:
+ INST_NAME("DIVPD Gx, Ex");
+ nextop = F8;
+ GETEX(x1, 0);
+ GETGX();
+ SSE_LOOP_FQ(x3, x4, {
+ if(!box64_dynarec_fastnan) {
+ FEQD(x3, v0, v0);
+ FEQD(x4, v1, v1);
+ }
+ FDIVD(v0, v0, v1);
+ if(!box64_dynarec_fastnan) {
+ AND(x3, x3, x4);
+ BEQZ(x3, 16);
+ FEQD(x3, v0, v0);
+ BNEZ(x3, 8);
+ FNEGD(v0, v0);
+ }
+ });
+ break;
+ case 0x5F:
+ INST_NAME("MAXPD Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ d0 = fpu_get_scratch(dyn);
+ d1 = fpu_get_scratch(dyn);
+ for (int i=0; i<2; ++i) {
+ FLD(d0, gback, gdoffset+8*i);
+ FLD(d1, wback, fixedaddress+8*i);
+ FEQD(x3, d0, d0);
+ FEQD(x4, d1, d1);
+ AND(x3, x3, x4);
+ BEQ(x3, xZR, 12);
+ FLTD(x3, d0, d1);
+ BEQ(x3, xZR, 8); // continue
+ FSD(d1, gback, gdoffset+8*i);
+ }
+ break;
+ case 0x60:
+ INST_NAME("PUNPCKLBW Gx,Ex");
+ nextop = F8;
+ GETGX();
+ for(int i=7; i>0; --i) { // 0 is untouched
+ // GX->ub[2 * i] = GX->ub[i];
+ LBU(x3, gback, gdoffset+i);
+ SB(x3, gback, gdoffset+2*i);
+ }
+ if (MODREG && gd==(nextop&7)+(rex.b<<3)) {
+ for(int i=0; i<8; ++i) {
+ // GX->ub[2 * i + 1] = GX->ub[2 * i];
+ LBU(x3, gback, gdoffset+2*i);
+ SB(x3, gback, gdoffset+2*i+1);
+ }
+ } else {
+ GETEX(x1, 0);
+ for(int i=0; i<8; ++i) {
+ // GX->ub[2 * i + 1] = EX->ub[i];
+ LBU(x3, wback, fixedaddress+i);
+ SB(x3, gback, gdoffset+2*i+1);
+ }
+ }
+ break;
+ case 0x61:
+ INST_NAME("PUNPCKLWD Gx,Ex");
+ nextop = F8;
+ GETGX();
+ for(int i=3; i>0; --i) {
+ // GX->uw[2 * i] = GX->uw[i];
+ LHU(x3, gback, gdoffset+i*2);
+ SH(x3, gback, gdoffset+2*i*2);
+ }
+ if (MODREG && gd==(nextop&7)+(rex.b<<3)) {
+ for(int i=0; i<4; ++i) {
+ // GX->uw[2 * i + 1] = GX->uw[2 * i];
+ LHU(x3, gback, gdoffset+2*i*2);
+ SH(x3, gback, gdoffset+(2*i+1)*2);
+ }
+ } else {
+ GETEX(x1, 0);
+ for(int i=0; i<4; ++i) {
+ // GX->uw[2 * i + 1] = EX->uw[i];
+ LHU(x3, wback, fixedaddress+i*2);
+ SH(x3, gback, gdoffset+(2*i+1)*2);
+ }
+ }
+ break;
+ case 0x62:
+ INST_NAME("PUNPCKLDQ Gx,Ex");
+ nextop = F8;
+ GETEX(x1, 0);
+ GETGX();
+ // GX->ud[3] = EX->ud[1];
+ LWU(x3, wback, fixedaddress+1*4);
+ SW(x3, gback, gdoffset+3*4);
+ // GX->ud[2] = GX->ud[1];
+ LWU(x3, gback, gdoffset+1*4);
+ SW(x3, gback, gdoffset+2*4);
+ // GX->ud[1] = EX->ud[0];
+ LWU(x3, wback, fixedaddress+0*4);
+ SW(x3, gback, gdoffset+1*4);
+ break;
+ case 0x63:
+ INST_NAME("PACKSSWB Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ MOV64x(x5, 127);
+ MOV64x(x6, -128);
+ for(int i=0; i<8; ++i) {
+ LH(x3, gback, gdoffset+i*2);
+ if(rv64_zbb) {
+ MIN(x3, x3, x5);
+ MAX(x3, x3, x6);
+ } else {
+ BLT(x3, x5, 4+4);
+ MV(x3, x5);
+ BGE(x3, x6, 4+4);
+ MV(x3, x6);
+ }
+ SB(x3, gback, gdoffset+i);
+ }
+ if(MODREG && gd==ed) {
+ LD(x3, gback, gdoffset+0);
+ SD(x3, gback, gdoffset+8);
+ } else for(int i=0; i<8; ++i) {
+ LH(x3, wback, fixedaddress+i*2);
+ if(rv64_zbb) {
+ MIN(x3, x3, x5);
+ MAX(x3, x3, x6);
+ } else {
+ BLT(x3, x5, 4+4);
+ MV(x3, x5);
+ BGE(x3, x6, 4+4);
+ MV(x3, x6);
+ }
+ SB(x3, gback, gdoffset+8+i);
+ }
+ break;
+ case 0x64:
+ INST_NAME("PCMPGTB Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=0; i<16; ++i) {
+ // GX->ub[i] = (GX->sb[i]>EX->sb[i])?0xFF:0x00;
+ LB(x3, wback, fixedaddress+i);
+ LB(x4, gback, gdoffset+i);
+ SLT(x3, x3, x4);
+ NEG(x3, x3);
+ SB(x3, gback, gdoffset+i);
+ }
+ break;
+ case 0x65:
+ INST_NAME("PCMPGTW Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=0; i<8; ++i) {
+ // GX->uw[i] = (GX->sw[i]>EX->sw[i])?0xFFFF:0x0000;
+ LH(x3, wback, fixedaddress+i*2);
+ LH(x4, gback, gdoffset+i*2);
+ SLT(x3, x3, x4);
+ NEG(x3, x3);
+ SH(x3, gback, gdoffset+i*2);
+ }
+ break;
+ case 0x66:
+ INST_NAME("PCMPGTD Gx,Ex");
+ nextop = F8;
+ GETEX(x1, 0);
+ GETGX();
+ SSE_LOOP_DS(x3, x4, SLT(x4, x4, x3); SLLI(x3, x4, 63); SRAI(x3, x3, 63));
+ break;
+ case 0x67:
+ INST_NAME("PACKUSWB Gx, Ex");
+ nextop = F8;
+ GETGX();
+ ADDI(x5, xZR, 0xFF);
+ for(int i=0; i<8; ++i) {
+ // GX->ub[i] = (GX->sw[i]<0)?0:((GX->sw[i]>0xff)?0xff:GX->sw[i]);
+ LH(x3, gback, gdoffset+i*2);
+ BGE(x5, x3, 8);
+ ADDI(x3, xZR, 0xFF);
+ NOT(x4, x3);
+ SRAI(x4, x4, 63);
+ AND(x3, x3, x4);
+ SB(x3, gback, gdoffset+i);
+ }
+ if (MODREG && gd==(nextop&7)+(rex.b<<3)) {
+ // GX->q[1] = GX->q[0];
+ LD(x3, gback, gdoffset+0*8);
+ SD(x3, gback, gdoffset+1*8);
+ } else {
+ GETEX(x1, 0);
+ for(int i=0; i<8; ++i) {
+ // GX->ub[8+i] = (EX->sw[i]<0)?0:((EX->sw[i]>0xff)?0xff:EX->sw[i]);
+ LH(x3, wback, fixedaddress+i*2);
+ BGE(x5, x3, 8);
+ ADDI(x3, xZR, 0xFF);
+ NOT(x4, x3);
+ SRAI(x4, x4, 63);
+ AND(x3, x3, x4);
+ SB(x3, gback, gdoffset+8+i);
+ }
+ }
+ break;
+ case 0x68:
+ INST_NAME("PUNPCKHBW Gx,Ex");
+ nextop = F8;
+ GETGX();
+ for(int i=0; i<8; ++i) {
+ // GX->ub[2 * i] = GX->ub[i + 8];
+ LBU(x3, gback, gdoffset+i+8);
+ SB(x3, gback, gdoffset+2*i);
+ }
+ if (MODREG && gd==(nextop&7)+(rex.b<<3)) {
+ for(int i=0; i<8; ++i) {
+ // GX->ub[2 * i + 1] = GX->ub[2 * i];
+ LBU(x3, gback, gdoffset+2*i);
+ SB(x3, gback, gdoffset+2*i+1);
+ }
+ } else {
+ GETEX(x2, 0);
+ for(int i=0; i<8; ++i) {
+ // GX->ub[2 * i + 1] = EX->ub[i + 8];
+ LBU(x3, wback, fixedaddress+i+8);
+ SB(x3, gback, gdoffset+2*i+1);
+ }
+ }
+ break;
+ case 0x69:
+ INST_NAME("PUNPCKHWD Gx,Ex");
+ nextop = F8;
+ GETGX();
+ for(int i=0; i<4; ++i) {
+ // GX->uw[2 * i] = GX->uw[i + 4];
+ LHU(x3, gback, gdoffset+(i+4)*2);
+ SH(x3, gback, gdoffset+2*i*2);
+ }
+ if (MODREG && gd==(nextop&7)+(rex.b<<3)) {
+ for(int i=0; i<4; ++i) {
+ // GX->uw[2 * i + 1] = GX->uw[2 * i];
+ LHU(x3, gback, gdoffset+2*i*2);
+ SH(x3, gback, gdoffset+(2*i+1)*2);
+ }
+ } else {
+ GETEX(x1, 0);
+ for(int i=0; i<4; ++i) {
+ // GX->uw[2 * i + 1] = EX->uw[i + 4];
+ LHU(x3, wback, fixedaddress+(i+4)*2);
+ SH(x3, gback, gdoffset+(2*i+1)*2);
+ }
+ }
+ break;
+ case 0x6A:
+ INST_NAME("PUNPCKHDQ Gx,Ex");
+ nextop = F8;
+ GETEX(x1, 0);
+ GETGX();
+ // GX->ud[0] = GX->ud[2];
+ LWU(x3, gback, gdoffset+2*4);
+ SW(x3, gback, gdoffset+0*4);
+ // GX->ud[1] = EX->ud[2];
+ LWU(x3, wback, fixedaddress+2*4);
+ SW(x3, gback, gdoffset+1*4);
+ // GX->ud[2] = GX->ud[3];
+ LWU(x3, gback, gdoffset+3*4);
+ SW(x3, gback, gdoffset+2*4);
+ // GX->ud[3] = EX->ud[3];
+ if (!(MODREG && (gd==ed))) {
+ LWU(x3, wback, fixedaddress+3*4);
+ SW(x3, gback, gdoffset+3*4);
+ }
+ break;
+ case 0x6B:
+ INST_NAME("PACKSSDW Gx,Ex");
+ nextop = F8;
+ GETGX();
+ MOV64x(x5, 32768);
+ NEG(x6, x5);
+ for(int i=0; i<4; ++i) {
+ // GX->sw[i] = (GX->sd[i]<-32768)?-32768:((GX->sd[i]>32767)?32767:GX->sd[i]);
+ LW(x3, gback, gdoffset+i*4);
+ BGE(x5, x3, 8);
+ ADDI(x3, x5, -1);
+ BGE(x3, x6, 8);
+ MV(x3, x6);
+ SH(x3, gback, gdoffset+i*2);
+ }
+ if (MODREG && gd==(nextop&7)+(rex.b<<3)) {
+ // GX->q[1] = GX->q[0];
+ LD(x3, gback, gdoffset+0*8);
+ SD(x3, gback, gdoffset+1*8);
+ } else {
+ GETEX(x1, 0);
+ for(int i=0; i<4; ++i) {
+ // GX->sw[4+i] = (EX->sd[i]<-32768)?-32768:((EX->sd[i]>32767)?32767:EX->sd[i]);
+ LW(x3, wback, fixedaddress+i*4);
+ BGE(x5, x3, 8);
+ ADDI(x3, x5, -1);
+ BGE(x3, x6, 8);
+ MV(x3, x6);
+ SH(x3, gback, gdoffset+(4+i)*2);
+ }
+ }
+ break;
+ case 0x6C:
+ INST_NAME("PUNPCKLQDQ Gx,Ex");
+ nextop = F8;
+ GETGX();
+ if(MODREG) {
+ v1 = sse_get_reg(dyn, ninst, x2, (nextop&7)+(rex.b<<3), 0);
+ FSD(v1, gback, gdoffset+8);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x3, &fixedaddress, rex, NULL, 1, 0);
+ LD(x3, ed, fixedaddress+0);
+ SD(x3, gback, gdoffset+8);
+ }
+ break;
+ case 0x6D:
+ INST_NAME("PUNPCKHQDQ Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ LD(x3, gback, gdoffset+8);
+ SD(x3, gback, gdoffset+0);
+ LD(x3, wback, fixedaddress+8);
+ SD(x3, gback, gdoffset+8);
+ break;
+ case 0x6E:
+ INST_NAME("MOVD Gx, Ed");
+ nextop = F8;
+ if(rex.w) {
+ GETGXSD_empty(v0);
+ } else {
+ GETGXSS_empty(v0);
+ }
+ GETED(0);
+ if(rex.w) {
+ FMVDX(v0, ed);
+ } else {
+ FMVWX(v0, ed);
+ SW(xZR, xEmu, offsetof(x64emu_t, xmm[gd])+4);
+ }
+ SD(xZR, xEmu, offsetof(x64emu_t, xmm[gd])+8);
+ break;
+ case 0x6F:
+ INST_NAME("MOVDQA Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_MV_Q(x3);
+ break;
+ case 0x70: // TODO: Optimize this!
+ INST_NAME("PSHUFD Gx,Ex,Ib");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 1);
+ u8 = F8;
+ int32_t idx;
+
+ idx = (u8>>(0*2))&3;
+ LWU(x3, wback, fixedaddress+idx*4);
+ idx = (u8>>(1*2))&3;
+ LWU(x4, wback, fixedaddress+idx*4);
+ idx = (u8>>(2*2))&3;
+ LWU(x5, wback, fixedaddress+idx*4);
+ idx = (u8>>(3*2))&3;
+ LWU(x6, wback, fixedaddress+idx*4);
+
+ SW(x3, gback, gdoffset+0*4);
+ SW(x4, gback, gdoffset+1*4);
+ SW(x5, gback, gdoffset+2*4);
+ SW(x6, gback, gdoffset+3*4);
+ break;
+ case 0x71:
+ nextop = F8;
+ switch((nextop>>3)&7) {
+ case 2:
+ INST_NAME("PSRLW Ex, Ib");
+ GETEX(x1, 1);
+ u8 = F8;
+ if (u8>15) {
+ // just zero dest
+ SD(xZR, wback, fixedaddress+0);
+ SD(xZR, wback, fixedaddress+8);
+ } else if(u8) {
+ for (int i=0; i<8; ++i) {
+ // EX->uw[i] >>= u8;
+ LHU(x3, wback, fixedaddress+i*2);
+ SRLI(x3, x3, u8);
+ SH(x3, wback, fixedaddress+i*2);
+ }
+ }
+ break;
+ case 4:
+ INST_NAME("PSRAW Ex, Ib");
+ GETEX(x1, 1);
+ u8 = F8;
+ if(u8>15) u8=15;
+ if(u8) {
+ for (int i=0; i<8; ++i) {
+ // EX->sw[i] >>= u8;
+ LH(x3, wback, fixedaddress+i*2);
+ SRAI(x3, x3, u8);
+ SH(x3, wback, fixedaddress+i*2);
+ }
+ }
+ break;
+ case 6:
+ INST_NAME("PSLLW Ex, Ib");
+ GETEX(x1, 1);
+ u8 = F8;
+ if (u8>15) {
+ // just zero dest
+ SD(xZR, wback, fixedaddress+0);
+ SD(xZR, wback, fixedaddress+8);
+ } else if(u8) {
+ for (int i=0; i<8; ++i) {
+ // EX->uw[i] <<= u8;
+ LHU(x3, wback, fixedaddress+i*2);
+ SLLI(x3, x3, u8);
+ SH(x3, wback, fixedaddress+i*2);
+ }
+ }
+ break;
+ default:
+ *ok = 0;
+ DEFAULT;
+ }
+ break;
+ case 0x72:
+ nextop = F8;
+ switch((nextop>>3)&7) {
+ case 2:
+ INST_NAME("PSRLD Ex, Ib");
+ GETEX(x1, 1);
+ u8 = F8;
+ if(u8) {
+ if (u8>31) {
+ // just zero dest
+ SD(xZR, wback, fixedaddress+0);
+ SD(xZR, wback, fixedaddress+8);
+ } else if(u8) {
+ SSE_LOOP_D_S(x3, SRLI(x3, x3, u8));
+ }
+ }
+ break;
+ case 4:
+ INST_NAME("PSRAD Ex, Ib");
+ GETEX(x1, 1);
+ u8 = F8;
+ if(u8>31) u8=31;
+ if (u8) {
+ SSE_LOOP_D_S(x3, SRAIW(x3, x3, u8));
+ }
+ break;
+ case 6:
+ INST_NAME("PSLLD Ex, Ib");
+ GETEX(x1, 1);
+ u8 = F8;
+ if(u8) {
+ if (u8>31) {
+ // just zero dest
+ SD(xZR, wback, fixedaddress+0);
+ SD(xZR, wback, fixedaddress+8);
+ } else if(u8) {
+ SSE_LOOP_D_S(x3, SLLI(x3, x3, u8));
+ }
+ }
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+ case 0x73:
+ nextop = F8;
+ switch((nextop>>3)&7) {
+ case 2:
+ INST_NAME("PSRLQ Ex, Ib");
+ GETEX(x1, 1);
+ u8 = F8;
+ if(!u8) break;
+ if(u8>63) {
+ // just zero dest
+ SD(xZR, wback, fixedaddress+0);
+ SD(xZR, wback, fixedaddress+8);
+ } else {
+ LD(x3, wback, fixedaddress+0);
+ LD(x4, wback, fixedaddress+8);
+ SRLI(x3, x3, u8);
+ SRLI(x4, x4, u8);
+ SD(x3, wback, fixedaddress+0);
+ SD(x4, wback, fixedaddress+8);
+ }
+ break;
+ case 3:
+ INST_NAME("PSRLDQ Ex, Ib");
+ GETEX(x1, 1);
+ u8 = F8;
+ if(!u8) break;
+ if(u8>15) {
+ // just zero dest
+ SD(xZR, wback, fixedaddress+0);
+ SD(xZR, wback, fixedaddress+8);
+ } else {
+ u8*=8;
+ if (u8 < 64) {
+ LD(x3, wback, fixedaddress+0);
+ LD(x4, wback, fixedaddress+8);
+ SRLI(x3, x3, u8);
+ SLLI(x5, x4, 64-u8);
+ OR(x3, x3, x5);
+ SD(x3, wback, fixedaddress+0);
+ SRLI(x4, x4, u8);
+ SD(x4, wback, fixedaddress+8);
+ } else {
+ LD(x3, wback, fixedaddress+8);
+ if (u8-64 > 0) { SRLI(x3, x3, u8-64); }
+ SD(x3, wback, fixedaddress+0);
+ SD(xZR, wback, fixedaddress+8);
+ }
+ }
+ break;
+ case 6:
+ INST_NAME("PSLLQ Ex, Ib");
+ GETEX(x1, 1);
+ u8 = F8;
+ if(!u8) break;
+ if(u8>63) {
+ // just zero dest
+ SD(xZR, wback, fixedaddress+0);
+ SD(xZR, wback, fixedaddress+8);
+ } else {
+ LD(x3, wback, fixedaddress+0);
+ LD(x4, wback, fixedaddress+8);
+ SLLI(x3, x3, u8);
+ SLLI(x4, x4, u8);
+ SD(x3, wback, fixedaddress+0);
+ SD(x4, wback, fixedaddress+8);
+ }
+ break;
+ case 7:
+ INST_NAME("PSLLDQ Ex, Ib");
+ GETEX(x1, 1);
+ u8 = F8;
+ if(!u8) break;
+ if(u8>15) {
+ // just zero dest
+ SD(xZR, wback, fixedaddress+0);
+ SD(xZR, wback, fixedaddress+8);
+ } else {
+ u8*=8;
+ if (u8 < 64) {
+ LD(x3, wback, fixedaddress+0);
+ LD(x4, wback, fixedaddress+8);
+ SLLI(x4, x4, u8);
+ SRLI(x5, x3, 64-u8);
+ OR(x4, x4, x5);
+ SD(x4, wback, fixedaddress+8);
+ SLLI(x3, x3, u8);
+ SD(x3, wback, fixedaddress+0);
+ } else {
+ LD(x3, wback, fixedaddress+0);
+ if (u8-64 > 0) { SLLI(x3, x3, u8-64); }
+ SD(x3, wback, fixedaddress+8);
+ SD(xZR, wback, fixedaddress+0);
+ }
+ }
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+ case 0x74:
+ INST_NAME("PCMPEQB Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for (int i=0; i<16; ++i) {
+ LBU(x3, gback, gdoffset+i);
+ LBU(x4, wback, fixedaddress+i);
+ SUB(x3, x3, x4);
+ SEQZ(x3, x3);
+ NEG(x3, x3);
+ SB(x3, gback, gdoffset+i);
+ }
+ break;
+ case 0x75:
+ INST_NAME("PCMPEQW Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_W(x3, x4, SUB(x3, x3, x4); SEQZ(x3, x3); NEG(x3, x3));
+ break;
+ case 0x76:
+ INST_NAME("PCMPEQD Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_D(x3, x4, XOR(x3, x3, x4); SNEZ(x3, x3); ADDI(x3, x3, -1));
+ break;
+ case 0x7C:
+ INST_NAME("HADDPD Gx, Ex");
+ nextop = F8;
+ GETGX();
+ d0 = fpu_get_scratch(dyn);
+ d1 = fpu_get_scratch(dyn);
+ FLD(d0, gback, gdoffset+0);
+ FLD(d1, gback, gdoffset+8);
+ if(!box64_dynarec_fastnan) {
+ FEQD(x3, d0, d0);
+ FEQD(x4, d1, d1);
+ AND(x3, x3, x4);
+ }
+ FADDD(d0, d0, d1);
+ if(!box64_dynarec_fastnan) {
+ FEQD(x4, d0, d0);
+ BEQZ(x3, 12);
+ BNEZ(x4, 8);
+ FNEGD(d0, d0);
+ }
+ FSD(d0, gback, gdoffset+0);
+ if(MODREG && gd==(nextop&7)+(rex.b<<3)) {
+ FSD(d0, gback, gdoffset+8);
+ } else {
+ GETEX(x2, 0);
+ FLD(d0, wback, fixedaddress+0);
+ FLD(d1, wback, fixedaddress+8);
+ if(!box64_dynarec_fastnan) {
+ FEQD(x3, d0, d0);
+ FEQD(x4, d1, d1);
+ AND(x3, x3, x4);
+ }
+ FADDD(d0, d0, d1);
+ if(!box64_dynarec_fastnan) {
+ FEQD(x4, d0, d0);
+ BEQZ(x3, 12);
+ BNEZ(x4, 8);
+ FNEGD(d0, d0);
+ }
+ FSD(d0, gback, gdoffset+8);
+ }
+ break;
+ case 0x7E:
+ INST_NAME("MOVD Ed,Gx");
+ nextop = F8;
+ GETGX();
+ if(rex.w) {
+ if(MODREG) {
+ ed = xRAX + (nextop&7) + (rex.b<<3);
+ LD(ed, gback, gdoffset+0);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x3, &fixedaddress, rex, NULL, 1, 0);
+ LD(x3, gback, gdoffset+0);
+ SD(x3, ed, fixedaddress);
+ SMWRITE2();
+ }
+ } else {
+ if(MODREG) {
+ ed = xRAX + (nextop&7) + (rex.b<<3);
+ LWU(ed, gback, gdoffset+0);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x3, &fixedaddress, rex, NULL, 1, 0);
+ LWU(x3, gback, gdoffset+0);
+ SW(x3, ed, fixedaddress);
+ SMWRITE2();
+ }
+ }
+ break;
+ case 0x7F:
+ INST_NAME("MOVDQA Ex,Gx");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_MV_Q2(x3);
+ if(!MODREG) SMWRITE2();
+ break;
+ case 0xAF:
+ INST_NAME("IMUL Gw,Ew");
+ SETFLAGS(X_ALL, SF_PENDING);
+ nextop = F8;
+ UFLAG_DF(x1, d_imul16);
+ GETSEW(x1, 0);
+ GETSGW(x2);
+ MULW(x2, x2, x1);
+ UFLAG_RES(x2);
+ ZEXTH(x2, x2);
+ GWBACK;
+ break;
+
+ case 0xBE:
+ INST_NAME("MOVSX Gw, Eb");
+ nextop = F8;
+ GETGD;
+ if(MODREG) {
+ if(rex.rex) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ eb1=ed;
+ eb2=0;
+ } else {
+ ed = (nextop&7);
+ eb1 = xRAX+(ed&3); // Ax, Cx, Dx or Bx
+ eb2 = (ed&4)>>2; // L or H
+ }
+ SLLI(x1, eb1, 56-eb2*8);
+ SRAI(x1, x1, 56);
+ } else {
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x4, &fixedaddress, rex, NULL, 1, 0);
+ LB(x1, ed, fixedaddress);
+ }
+ LUI(x5, 0xffff0);
+ AND(gd, gd, x5);
+ NOT(x5, x5);
+ AND(x1, x1, x5);
+ OR(gd, gd, x1);
+ break;
+ case 0xC2:
+ INST_NAME("CMPPD Gx, Ex, Ib");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 1);
+ u8 = F8;
+ d0 = fpu_get_scratch(dyn);
+ d1 = fpu_get_scratch(dyn);
+ for(int i=0; i<2; ++i) {
+ FLD(d0, gback, gdoffset+8*i);
+ FLD(d1, wback, fixedaddress+8*i);
+ if ((u8&7) == 0) { // Equal
+ FEQD(x3, d0, d1);
+ } else if ((u8&7) == 4) { // Not Equal or unordered
+ FEQD(x3, d0, d1);
+ XORI(x3, x3, 1);
+ } else {
+ // x4 = !(isnan(d0) || isnan(d1))
+ FEQD(x4, d0, d0);
+ FEQD(x3, d1, d1);
+ AND(x3, x3, x4);
+
+ switch(u8&7) {
+ case 1: BEQ_MARK(x3, xZR); FLTD(x3, d0, d1); break; // Less than
+ case 2: BEQ_MARK(x3, xZR); FLED(x3, d0, d1); break; // Less or equal
+ case 3: XORI(x3, x3, 1); break; // NaN
+ case 5: { // Greater or equal or unordered
+ BEQ(x3, xZR, 12); // MARK2
+ FLED(x3, d1, d0);
+ J(8); // MARK;
+ break;
+ }
+ case 6: { // Greater or unordered
+ BEQ(x3, xZR, 12); // MARK2
+ FLTD(x3, d1, d0);
+ J(8); // MARK;
+ break;
+ }
+ case 7: break; // Not NaN
+ }
+
+ // MARK2;
+ if ((u8&7) == 5 || (u8&7) == 6) {
+ MOV32w(x3, 1);
+ }
+ // MARK;
+ }
+ NEG(x3, x3);
+ SD(x3, gback, gdoffset+8*i);
+ }
+ break;
+ case 0xC4:
+ INST_NAME("PINSRW Gx,Ed,Ib");
+ nextop = F8;
+ GETED(1);
+ GETGX();
+ u8 = (F8)&7;
+ SH(ed, gback, gdoffset+u8*2);
+ break;
+ case 0xC5:
+ INST_NAME("PEXTRW Gd,Ex,Ib");
+ nextop = F8;
+ GETGD;
+ GETEX(x1, 0);
+ u8 = (F8)&7;
+ LHU(gd, wback, fixedaddress+u8*2);
+ break;
+ case 0xC6:
+ INST_NAME("SHUFPD Gx, Ex, Ib");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 1);
+ u8 = F8;
+ if (MODREG && gd==(nextop&7)+(rex.b<<3) && u8==0) {
+ LD(x3, gback, gdoffset+0);
+ SD(x3, gback, gdoffset+8);
+ break;
+ }
+ LD(x3, gback, gdoffset+8*(u8&1));
+ LD(x4, wback, fixedaddress+8*((u8>>1)&1));
+ SD(x3, gback, gdoffset+0);
+ SD(x4, gback, gdoffset+8);
+ break;
+ case 0xD1:
+ INST_NAME("PSRLW Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ LD(x3, wback, fixedaddress);
+ ADDI(x4, xZR, 16);
+ BLTU_MARK(x3, x4);
+ SD(xZR, gback, gdoffset+0);
+ SD(xZR, gback, gdoffset+8);
+ B_NEXT_nocond;
+ MARK;
+ for (int i=0; i<8; ++i) {
+ LHU(x5, gback, gdoffset+2*i);
+ SRLW(x5, x5, x3);
+ SH(x5, gback, gdoffset+2*i);
+ }
+ break;
+ case 0xD2:
+ INST_NAME("PSRLD Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ LD(x3, wback, fixedaddress);
+ ADDI(x4, xZR, 32);
+ BLTU_MARK(x3, x4);
+ SD(xZR, gback, gdoffset+0);
+ SD(xZR, gback, gdoffset+8);
+ B_NEXT_nocond;
+ MARK;
+ for (int i=0; i<4; ++i) {
+ LWU(x5, gback, gdoffset+4*i);
+ SRLW(x5, x5, x3);
+ SW(x5, gback, gdoffset+4*i);
+ }
+ break;
+ case 0xD3:
+ INST_NAME("PSRLQ Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ LD(x3, wback, fixedaddress);
+ ADDI(x4, xZR, 64);
+ BLTU_MARK(x3, x4);
+ SD(xZR, gback, gdoffset+0);
+ SD(xZR, gback, gdoffset+8);
+ B_NEXT_nocond;
+ MARK;
+ for (int i=0; i<2; ++i) {
+ LD(x5, gback, gdoffset+8*i);
+ SRL(x5, x5, x3);
+ SD(x5, gback, gdoffset+8*i);
+ }
+ break;
+ case 0xD4:
+ INST_NAME("PADDQ Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_Q(x3, x4, ADD(x3, x3, x4));
+ break;
+ case 0xD5:
+ INST_NAME("PMULLW Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=0; i<8; ++i) {
+ LH(x3, gback, gdoffset+2*i);
+ LH(x4, wback, fixedaddress+2*i);
+ MULW(x3, x3, x4);
+ SH(x3, gback, gdoffset+2*i);
+ }
+ break;
+ case 0xD6:
+ INST_NAME("MOVQ Ex, Gx");
+ nextop = F8;
+ GETGXSD(d0);
+ GETEX(x2, 0);
+ FSD(d0, wback, fixedaddress+0);
+ if (MODREG) {
+ SD(xZR, wback, fixedaddress+8);
+ } else {
+ SMWRITE2();
+ }
+ break;
+ case 0xD7:
+ INST_NAME("PMOVMSKB Gd, Ex");
+ nextop = F8;
+ GETEX(x2, 0);
+ GETGD;
+ MV(gd, xZR);
+ for (int i=0; i<16; ++i) {
+ LB(x1, wback, fixedaddress+i);
+ SLT(x3, x1, xZR);
+ if (i > 0) SLLI(x3, x3, i);
+ OR(gd, gd, x3);
+ }
+ break;
+ case 0xD8:
+ INST_NAME("PSUBUSB Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=0; i<16; ++i) {
+ LBU(x3, gback, gdoffset+i);
+ LBU(x4, wback, fixedaddress+i);
+ SUB(x3, x3, x4);
+ NOT(x4, x3);
+ SRAI(x4, x4, 63);
+ AND(x3, x3, x4);
+ SB(x3, gback, gdoffset+i);
+ }
+ break;
+ case 0xD9:
+ INST_NAME("PSUBUSW Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_W(x3, x4, SUB(x3, x3, x4); NOT(x4, x3); SRAI(x4, x4, 63); AND(x3, x3, x4));
+ break;
+ case 0xDA:
+ INST_NAME("PMINUB Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for (int i=0; i<16; ++i) {
+ LBU(x3, gback, gdoffset+i);
+ LBU(x4, wback, fixedaddress+i);
+ BLTU(x3, x4, 8);
+ MV(x3, x4);
+ SB(x3, gback, gdoffset+i);
+ }
+ break;
+ case 0xDB:
+ INST_NAME("PAND Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_Q(x3, x4, AND(x3, x3, x4));
+ break;
+ case 0xDC:
+ INST_NAME("PADDUSB Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ ADDI(x5, xZR, 0xFF);
+ for(int i=0; i<16; ++i) {
+ LBU(x3, gback, gdoffset+i);
+ LBU(x4, wback, fixedaddress+i);
+ ADD(x3, x3, x4);
+ BLT(x3, x5, 8);
+ ADDI(x3, xZR, 0xFF);
+ SB(x3, gback, gdoffset+i);
+ }
+ break;
+ case 0xDD:
+ INST_NAME("PADDUSW Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=0; i<8; ++i) {
+ // tmp32s = (int32_t)GX->uw[i] + EX->uw[i];
+ // GX->uw[i] = (tmp32s>65535)?65535:tmp32s;
+ LHU(x3, gback, gdoffset+i*2);
+ LHU(x4, wback, fixedaddress+i*2);
+ ADDW(x3, x3, x4);
+ MOV32w(x4, 65536);
+ BLT(x3, x4, 8);
+ ADDIW(x3, x4, -1);
+ SH(x3, gback, gdoffset+i*2);
+ }
+ break;
+ case 0xDE:
+ INST_NAME("PMAXUB Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for (int i=0; i<16; ++i) {
+ LBU(x3, gback, gdoffset+i);
+ LBU(x4, wback, fixedaddress+i);
+ BLTU(x4, x3, 8);
+ MV(x3, x4);
+ SB(x3, gback, gdoffset+i);
+ }
+ break;
+ case 0xDF:
+ INST_NAME("PANDN Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_Q(x3, x4, NOT(x3, x3); AND(x3, x3, x4));
+ break;
+ case 0xE0:
+ INST_NAME("PAVGB Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for (int i=0; i<16; ++i) {
+ LBU(x3, gback, gdoffset+i);
+ LBU(x4, wback, fixedaddress+i);
+ ADDW(x3, x3, x4);
+ ADDIW(x3, x3, 1);
+ SRAIW(x3, x3, 1);
+ SB(x3, gback, gdoffset+i);
+ }
+ break;
+ case 0xE1:
+ INST_NAME("PSRAW Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ ADDI(x4, xZR, 16);
+ LD(x3, wback, fixedaddress);
+ BLTU(x3, x4, 8);
+ SUBI(x3, x4, 1);
+ for (int i=0; i<8; ++i) {
+ LH(x4, gback, gdoffset+2*i);
+ SRAW(x4, x4, x3);
+ SH(x4, gback, gdoffset+2*i);
+ }
+ break;
+ case 0xE2:
+ INST_NAME("PSRAD Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ ADDI(x4, xZR, 32);
+ LD(x3, wback, fixedaddress);
+ BLTU(x3, x4, 8);
+ SUBI(x3, x4, 1);
+ for (int i=0; i<4; ++i) {
+ LW(x4, gback, gdoffset+4*i);
+ SRAW(x4, x4, x3);
+ SW(x4, gback, gdoffset+4*i);
+ }
+ break;
+ case 0xE3:
+ INST_NAME("PAVGW Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for (int i=0; i<8; ++i) {
+ LHU(x3, gback, gdoffset+2*i);
+ LHU(x4, wback, fixedaddress+2*i);
+ ADDW(x3, x3, x4);
+ ADDIW(x3, x3, 1);
+ SRAIW(x3, x3, 1);
+ SH(x3, gback, gdoffset+2*i);
+ }
+ break;
+ case 0xE4:
+ INST_NAME("PMULHUW Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=0; i<8; ++i) {
+ LHU(x3, gback, gdoffset+2*i);
+ LHU(x4, wback, fixedaddress+2*i);
+ MULW(x3, x3, x4);
+ SRLIW(x3, x3, 16);
+ SH(x3, gback, gdoffset+2*i);
+ }
+ break;
+ case 0xE5:
+ INST_NAME("PMULHW Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=0; i<8; ++i) {
+ LH(x3, gback, gdoffset+2*i);
+ LH(x4, wback, fixedaddress+2*i);
+ MULW(x3, x3, x4);
+ SRAIW(x3, x3, 16);
+ SH(x3, gback, gdoffset+2*i);
+ }
+ break;
+ case 0xE6:
+ INST_NAME("CVTTPD2DQ Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ v0 = fpu_get_scratch(dyn);
+ v1 = fpu_get_scratch(dyn);
+ FLD(v0, wback, fixedaddress+0);
+ FLD(v1, wback, fixedaddress+8);
+ if(!box64_dynarec_fastround) {
+ FSFLAGSI(0); // // reset all bits
+ }
+ FCVTWD(x3, v0, RD_RTZ);
+ if(!box64_dynarec_fastround) {
+ FRFLAGS(x5); // get back FPSR to check the IOC bit
+ ANDI(x5, x5, (1<<FR_NV)|(1<<FR_OF));
+ BEQ_MARK(x5, xZR);
+ MOV32w(x3, 0x80000000);
+ MARK;
+ FSFLAGSI(0); // // reset all bits
+ }
+ FCVTWD(x4, v1, RD_RTZ);
+ if(!box64_dynarec_fastround) {
+ FRFLAGS(x5); // get back FPSR to check the IOC bit
+ ANDI(x5, x5, (1<<FR_NV)|(1<<FR_OF));
+ BEQ_MARK2(x5, xZR);
+ MOV32w(x4, 0x80000000);
+ MARK2;
+ }
+ SW(x3, gback, gdoffset+0);
+ SW(x4, gback, gdoffset+4);
+ SD(xZR, gback, gdoffset+8);
+ break;
+ case 0xE7:
+ INST_NAME("MOVNTDQ Ex, Gx");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_MV_Q2(x3);
+ break;
+ case 0xE8:
+ INST_NAME("PSUBSB Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=0; i<16; ++i) {
+ // tmp16s = (int16_t)GX->sb[i] - EX->sb[i];
+ // GX->sb[i] = (tmp16s<-128)?-128:((tmp16s>127)?127:tmp16s);
+ LB(x3, gback, gdoffset+i);
+ LB(x4, wback, fixedaddress+i);
+ SUBW(x3, x3, x4);
+ SLLIW(x3, x3, 16);
+ SRAIW(x3, x3, 16);
+ ADDI(x4, xZR, 0x7f);
+ BLT(x3, x4, 12); // tmp16s>127?
+ SB(x4, gback, gdoffset+i);
+ J(24); // continue
+ ADDI(x4, xZR, 0xf80);
+ BLT(x4, x3, 12); // tmp16s<-128?
+ SB(x4, gback, gdoffset+i);
+ J(8); // continue
+ SB(x3, gback, gdoffset+i);
+ }
+ break;
+ case 0xE9:
+ INST_NAME("PSUBSW Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=0; i<8; ++i) {
+ // tmp32s = (int32_t)GX->sw[i] - EX->sw[i];
+ // GX->sw[i] = (tmp32s>32767)?32767:((tmp32s<-32768)?-32768:tmp32s);
+ LH(x3, gback, gdoffset+2*i);
+ LH(x4, wback, fixedaddress+2*i);
+ SUBW(x3, x3, x4);
+ LUI(x4, 0xFFFF8); // -32768
+ BGE(x3, x4, 12);
+ SH(x4, gback, gdoffset+2*i);
+ J(20); // continue
+ LUI(x4, 8); // 32768
+ BLT(x3, x4, 8);
+ ADDIW(x3, x4, -1);
+ SH(x3, gback, gdoffset+2*i);
+ }
+ break;
+ case 0xEA:
+ INST_NAME("PMINSW Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for (int i=0; i<8; ++i) {
+ LH(x3, gback, gdoffset+2*i);
+ LH(x4, wback, fixedaddress+2*i);
+ BLT(x3, x4, 8);
+ MV(x3, x4);
+ SH(x3, gback, gdoffset+2*i);
+ }
+ break;
+ case 0xEB:
+ INST_NAME("POR Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_Q(x3, x4, OR(x3, x3, x4));
+ break;
+ case 0xEC:
+ INST_NAME("PADDSB Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=0; i<16; ++i) {
+ // tmp16s = (int16_t)GX->sb[i] + EX->sb[i];
+ // GX->sb[i] = (tmp16s>127)?127:((tmp16s<-128)?-128:tmp16s);
+ LB(x3, gback, gdoffset+i);
+ LB(x4, wback, fixedaddress+i);
+ ADDW(x3, x3, x4);
+ SLLIW(x3, x3, 16);
+ SRAIW(x3, x3, 16);
+ ADDI(x4, xZR, 0x7f);
+ BLT(x3, x4, 12); // tmp16s>127?
+ SB(x4, gback, gdoffset+i);
+ J(24); // continue
+ ADDI(x4, xZR, 0xf80);
+ BLT(x4, x3, 12); // tmp16s<-128?
+ SB(x4, gback, gdoffset+i);
+ J(8); // continue
+ SB(x3, gback, gdoffset+i);
+ }
+ break;
+ case 0xED:
+ INST_NAME("PADDSW Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=0; i<8; ++i) {
+ // tmp32s = (int32_t)GX->sw[i] + EX->sw[i];
+ // GX->sw[i] = (tmp32s>32767)?32767:((tmp32s<-32768)?-32768:tmp32s);
+ LH(x3, gback, gdoffset+2*i);
+ LH(x4, wback, fixedaddress+2*i);
+ ADDW(x3, x3, x4);
+ LUI(x4, 0xFFFF8); // -32768
+ BGE(x3, x4, 12);
+ SH(x4, gback, gdoffset+2*i);
+ J(20); // continue
+ LUI(x4, 8); // 32768
+ BLT(x3, x4, 8);
+ ADDIW(x3, x4, -1);
+ SH(x3, gback, gdoffset+2*i);
+ }
+ break;
+ case 0xEE:
+ INST_NAME("PMAXSW Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_WS(x3, x4, BGE(x3, x4, 8); MV(x3, x4));
+ break;
+ case 0xEF:
+ INST_NAME("PXOR Gx, Ex");
+ nextop = F8;
+ GETGX();
+ if(MODREG && gd==(nextop&7)+(rex.b<<3))
+ {
+ // just zero dest
+ SD(xZR, gback, gdoffset+0);
+ SD(xZR, gback, gdoffset+8);
+ } else {
+ GETEX(x2, 0);
+ SSE_LOOP_Q(x3, x4, XOR(x3, x3, x4));
+ }
+ break;
+ case 0xF1:
+ INST_NAME("PSLLQ Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ ADDI(x4, xZR, 16);
+ LD(x3, wback, fixedaddress+0);
+ BLTU_MARK(x3, x4);
+ // just zero dest
+ SD(xZR, gback, gdoffset+0);
+ SD(xZR, gback, gdoffset+8);
+ B_NEXT_nocond;
+ MARK;
+ for (int i=0; i<8; ++i) {
+ LHU(x4, gback, gdoffset+2*i);
+ SLLW(x4, x4, x3);
+ SH(x4, gback, gdoffset+2*i);
+ }
+ break;
+ case 0xF2:
+ INST_NAME("PSLLQ Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ ADDI(x4, xZR, 32);
+ LD(x3, wback, fixedaddress+0);
+ BLTU_MARK(x3, x4);
+ // just zero dest
+ SD(xZR, gback, gdoffset+0);
+ SD(xZR, gback, gdoffset+8);
+ B_NEXT_nocond;
+ MARK;
+ for (int i=0; i<4; ++i) {
+ LWU(x4, gback, gdoffset+4*i);
+ SLLW(x4, x4, x3);
+ SW(x4, gback, gdoffset+4*i);
+ }
+ break;
+ case 0xF3:
+ INST_NAME("PSLLQ Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ ADDI(x4, xZR, 64);
+ LD(x3, wback, fixedaddress+0);
+ BLTU_MARK(x3, x4);
+ // just zero dest
+ SD(xZR, gback, gdoffset+0);
+ SD(xZR, gback, gdoffset+8);
+ B_NEXT_nocond;
+ MARK;
+ for (int i=0; i<2; ++i) {
+ LD(x4, gback, gdoffset+8*i);
+ SLL(x4, x4, x3);
+ SD(x4, gback, gdoffset+8*i);
+ }
+ break;
+ case 0xF4:
+ INST_NAME("PMULUDQ Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ // GX->q[1] = (uint64_t)EX->ud[2]*GX->ud[2];
+ LWU(x3, gback, gdoffset+2*4);
+ LWU(x4, wback, fixedaddress+2*4);
+ MUL(x3, x3, x4);
+ SD(x3, gback, gdoffset+8);
+ // GX->q[0] = (uint64_t)EX->ud[0]*GX->ud[0];
+ LWU(x3, gback, gdoffset+0*4);
+ LWU(x4, wback, fixedaddress+0*4);
+ MUL(x3, x3, x4);
+ SD(x3, gback, gdoffset+0);
+ break;
+ case 0xF5:
+ INST_NAME("PMADDWD Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for (int i=0; i<4; ++i) {
+ // GX->sd[i] = (int32_t)(GX->sw[i*2+0])*EX->sw[i*2+0] +
+ // (int32_t)(GX->sw[i*2+1])*EX->sw[i*2+1];
+ LH(x3, gback, gdoffset+2*(i*2+0));
+ LH(x4, wback, fixedaddress+2*(i*2+0));
+ MULW(x5, x3, x4);
+ LH(x3, gback, gdoffset+2*(i*2+1));
+ LH(x4, wback, fixedaddress+2*(i*2+1));
+ MULW(x6, x3, x4);
+ ADDW(x5, x5, x6);
+ SW(x5, gback, gdoffset+4*i);
+ }
+ break;
+ case 0xF6:
+ INST_NAME("PSADBW Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ MV(x6, xZR);
+ for (int i=0; i<16; ++i) {
+ LBU(x3, gback, gdoffset+i);
+ LBU(x4, wback, fixedaddress+i);
+ SUBW(x3, x3, x4);
+ SRAIW(x5, x3, 31);
+ XOR(x3, x5, x3);
+ SUBW(x3, x3, x5);
+ ANDI(x3, x3, 0xff);
+ ADDW(x6, x6, x3);
+ if (i==7 || i == 15) {
+ SD(x6, gback, gdoffset+i+1-8);
+ if (i==7) MV(x6, xZR);
+ }
+ }
+ break;
+ case 0xF8:
+ INST_NAME("PSUBB Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=0; i<16; ++i) {
+ // GX->sb[i] -= EX->sb[i];
+ LB(x3, wback, fixedaddress+i);
+ LB(x4, gback, gdoffset+i);
+ SUB(x3, x4, x3);
+ SB(x3, gback, gdoffset+i);
+ }
+ break;
+ case 0xF9:
+ INST_NAME("PSUBW Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_W(x3, x4, SUBW(x3, x3, x4));
+ break;
+ case 0xFA:
+ INST_NAME("PSUBD Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_D(x3, x4, SUBW(x3, x3, x4));
+ break;
+ case 0xFB:
+ INST_NAME("PSUBQ Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_Q(x3, x4, SUB(x3, x3, x4));
+ break;
+ case 0xFC:
+ INST_NAME("PADDB Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ for(int i=0; i<16; ++i) {
+ // GX->sb[i] += EX->sb[i];
+ LB(x3, gback, gdoffset+i);
+ LB(x4, wback, fixedaddress+i);
+ ADDW(x3, x3, x4);
+ SB(x3, gback, gdoffset+i);
+ }
+ break;
+ case 0xFD:
+ INST_NAME("PADDW Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_W(x3, x4, ADDW(x3, x3, x4));
+ break;
+ case 0xFE:
+ INST_NAME("PADDD Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_D(x3, x4, ADDW(x3, x3, x4));
+ break;
+ default:
+ DEFAULT;
+ }
+ return addr;
+}
diff --git a/src/dynarec/rv64/dynarec_rv64_6664.c b/src/dynarec/rv64/dynarec_rv64_6664.c
new file mode 100644
index 0000000..3acac90
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_6664.c
@@ -0,0 +1,105 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <stddef.h>
+#include <errno.h>
+
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "emu/x64run_private.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "emu/x64run_private.h"
+#include "x64trace.h"
+#include "dynarec_native.h"
+
+#include "rv64_printer.h"
+#include "dynarec_rv64_private.h"
+#include "dynarec_rv64_helper.h"
+#include "dynarec_rv64_functions.h"
+
+uintptr_t dynarec64_6664(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int seg, int* ok, int* need_epilog)
+{
+ (void)ip; (void)need_epilog;
+
+ uint8_t opcode = F8;
+ uint8_t nextop;
+ uint8_t gd, ed;
+ int64_t j64;
+ int v0, v1;
+ int64_t fixedaddress;
+ int unscaled;
+ MAYUSE(j64);
+
+ GETREX();
+
+ switch(opcode) {
+ case 0x89:
+ INST_NAME("MOV FS:Ew, Gw");
+ nextop = F8;
+ GETGD; // don't need GETGW here
+ if(MODREG) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ if(rex.w) {
+ ADDI(ed, gd, 0);
+ } else {
+ if(ed!=gd) {
+ LUI(x1, 0xffff0);
+ AND(gd, gd, x1);
+ ZEXTH(x1, ed);
+ OR(gd, gd, x1);
+ }
+ }
+ } else {
+ grab_segdata(dyn, addr, ninst, x4, seg);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, NULL, 1, 0);
+ ADD(x4, ed, x4);
+ if(rex.w) {
+ SD(gd, x4, fixedaddress);
+ } else {
+ SH(gd, x4, fixedaddress);
+ }
+ SMWRITE();
+ }
+ break;
+
+ case 0x8B:
+ INST_NAME("MOV Gd, FS:Ed");
+ nextop=F8;
+ GETGD;
+ if(MODREG) { // reg <= reg
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ if(rex.w) {
+ MV(gd, ed);
+ } else {
+ if(ed!=gd) {
+ LUI(x1, 0xffff0);
+ AND(gd, gd, x1);
+ ZEXTH(x1, ed);
+ OR(gd, gd, x1);
+ }
+ }
+ } else { // mem <= reg
+ grab_segdata(dyn, addr, ninst, x4, seg);
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, NULL, 1, 0);
+ ADD(x4, ed, x4);
+ if(rex.w) {
+ LD(gd, x4, fixedaddress);
+ } else {
+ LHU(x1, x4, fixedaddress);
+ SRLI(gd, gd, 16);
+ SLLI(gd, gd, 16);
+ OR(gd, gd, x1);
+ }
+ }
+ break;
+
+ default:
+ DEFAULT;
+ }
+ return addr;
+}
diff --git a/src/dynarec/rv64/dynarec_rv64_66f0.c b/src/dynarec/rv64/dynarec_rv64_66f0.c
new file mode 100644
index 0000000..8416422
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_66f0.c
@@ -0,0 +1,195 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <stddef.h>
+#include <errno.h>
+
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "emu/x64run_private.h"
+#include "rv64_emitter.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "emu/x64run_private.h"
+#include "x64trace.h"
+#include "dynarec_native.h"
+
+#include "rv64_printer.h"
+#include "dynarec_rv64_private.h"
+#include "dynarec_rv64_helper.h"
+#include "dynarec_rv64_functions.h"
+
+
+uintptr_t dynarec64_66F0(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog)
+{
+ (void)ip; (void)rep; (void)need_epilog;
+
+ uint8_t opcode = F8;
+ uint8_t nextop;
+ uint8_t gd, ed, u8;
+ uint8_t wback, wb1, wb2, gb1, gb2;
+ int32_t i32;
+ int64_t i64, j64;
+ int64_t fixedaddress;
+ int unscaled;
+ MAYUSE(gb1);
+ MAYUSE(gb2);
+ MAYUSE(wb1);
+ MAYUSE(wb2);
+ MAYUSE(j64);
+
+ while((opcode==0xF2) || (opcode==0xF3)) {
+ rep = opcode-0xF1;
+ opcode = F8;
+ }
+
+ GETREX();
+
+ switch(opcode) {
+ case 0x11:
+ INST_NAME("LOCK ADC Ew, Gw");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGW(x1);
+ SMDMB();
+ if(MODREG) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ MOV32w(x6, 0xFFFF);
+ AND(x2, ed, x6);
+ emit_adc16(dyn, ninst, x1, x2, x3, x4, x5);
+ if (rv64_zbb) {
+ ANDN(ed, ed, x6);
+ } else {
+ NOT(x6, x6);
+ AND(ed, ed, x6);
+ }
+ OR(ed, ed, x2);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x3, &fixedaddress, rex, LOCK_LOCK, 0, 0);
+ ANDI(x3, wback, 0b10);
+ MOV32w(x4, 0xffff); // x4 = mask
+ BNEZ_MARK(x3);
+ // lower 16bits
+ MARKLOCK;
+ LR_W(x5, wback, 1, 1);
+ AND(x6, x5, x4); // x6 = Ed.h[0]
+ SRLIW(x5, x5, 16);
+ SLLIW(x5, x5, 16); // x5 = clear Ed.h[0]
+ ADDW(x2, x1, x6); // x2 = Gw + Ew
+ ANDI(x9, xFlags, 1 << F_CF);
+ ADDW(x2, x2, x9); // x2 = adc
+ AND(x2, x2, x4);
+ OR(x5, x5, x2);
+ SC_W(x2, x5, wback, 1, 1);
+ BNEZ_MARKLOCK(x2);
+ B_MARK3_nocond;
+ MARK;
+ // upper 16bits
+ SLLIW(x3, x4, 16); // x3 = mask
+ SUBI(wback, wback, 2); // aligning address
+ SLLI(x1, x1, 16); // x1 = extended Gw
+ MARK2;
+ LR_W(x6, wback, 1, 1); // x6 = Ed
+ AND(x5, x6, x3); // x5 = Ed.h[1] << 16
+ ADDW(x5,x5, x1);
+ ANDI(x9, xFlags, 1 << F_CF);
+ SLLIW(x9, x9, 16);
+ ADDW(x5, x5, x9); // x5 = adc << 16
+ AND(x9, x6, x4); // x9 = Ed.h[0]
+ OR(x5, x5, x9);
+ SC_W(x9, x5, wback, 1, 1);
+ BNEZ_MARK2(x9);
+ IFX(X_ALL|X_PEND) {
+ SRLIW(x6, x6, 16);
+ SRLIW(x1, x1, 16);
+ }
+ MARK3;
+ IFX(X_ALL|X_PEND) {
+ emit_adc16(dyn, ninst, x1, x6, x3, x4, x5);
+ }
+ }
+ SMDMB();
+ break;
+ case 0x81:
+ case 0x83:
+ nextop = F8;
+ SMDMB();
+ switch((nextop>>3)&7) {
+ case 0: //ADD
+ if(opcode==0x81) {
+ INST_NAME("LOCK ADD Ew, Iw");
+ } else {
+ INST_NAME("LOCK ADD Ew, Ib");
+ }
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ if(MODREG) {
+ if(opcode==0x81) i32 = F16S; else i32 = F8S;
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ MOV32w(x5, i32);
+ ZEXTH(x6, ed);
+ emit_add16(dyn, ninst, x6, x5, x3, x4, x2);
+ SRLI(ed, ed, 16);
+ SLLI(ed, ed, 16);
+ OR(ed, ed, x6);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, LOCK_LOCK, 0, (opcode==0x81)?2:1);
+ if(opcode==0x81) i32 = F16S; else i32 = F8S;
+ MOV32w(x5, i32);
+
+ ANDI(x3, wback, 0b10);
+ BNEZ_MARK(x3);
+
+ // lower 16 bits
+ MARKLOCK;
+ LR_W(x1, wback, 1, 1);
+ SRLIW(x3, x1, 16);
+ SLLIW(x3, x3, 16);
+ ADD(x4, x1, x5);
+ SLLIW(x4, x4, 16);
+ SRLIW(x4, x4, 16);
+ OR(x4, x4, x3);
+ SC_W(x3, x4, wback, 1, 1);
+ BNEZ_MARKLOCK(x3);
+ IFX(X_ALL|X_PEND) {
+ SLLIW(x1, x1, 16);
+ SRLIW(x1, x1, 16);
+ }
+ B_MARK3_nocond;
+
+ MARK;
+ // upper 16 bits
+ XORI(wback, wback, 0b10);
+ MARK2;
+ LR_W(x1, wback, 1, 1);
+ SLLIW(x3, x1, 16);
+ SRLIW(x3, x3, 16);
+ SRLIW(x1, x1, 16);
+ ADD(x4, x1, x5);
+ SLLIW(x4, x4, 16);
+ OR(x4, x4, x3);
+ SC_W(x3, x4, wback, 1, 1);
+ BNEZ_MARK2(x3);
+
+ MARK3;
+ // final
+ IFX(X_ALL|X_PEND) {
+ emit_add16(dyn, ninst, x1, x5, x3, x4, x6);
+ }
+ }
+ break;
+ default:
+ DEFAULT;
+ }
+ SMDMB();
+ break;
+
+ default:
+ DEFAULT;
+ }
+
+ return addr;
+} \ No newline at end of file
diff --git a/src/dynarec/rv64/dynarec_rv64_67.c b/src/dynarec/rv64/dynarec_rv64_67.c
new file mode 100644
index 0000000..5f10274
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_67.c
@@ -0,0 +1,631 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <stddef.h>
+#include <errno.h>
+#include <assert.h>
+
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "emu/x64run_private.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "emu/x64run_private.h"
+#include "x64trace.h"
+#include "dynarec_native.h"
+
+#include "rv64_printer.h"
+#include "dynarec_rv64_private.h"
+#include "dynarec_rv64_helper.h"
+#include "dynarec_rv64_functions.h"
+
+uintptr_t dynarec64_67(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog)
+{
+ (void)ip; (void)need_epilog;
+
+ uint8_t opcode = F8;
+ uint8_t nextop;
+ uint8_t gd, ed, wback, wb, wb1, wb2, gb1, gb2, eb1, eb2;
+ int64_t fixedaddress;
+ int unscaled;
+ int8_t i8;
+ uint8_t u8;
+ int32_t i32;
+ int64_t j64, i64;
+ int cacheupd = 0;
+ int lock;
+ int v0, v1, s0;
+ MAYUSE(i32);
+ MAYUSE(j64);
+ MAYUSE(v0);
+ MAYUSE(v1);
+ MAYUSE(s0);
+ MAYUSE(lock);
+ MAYUSE(cacheupd);
+
+ if(rex.is32bits) {
+ // should do a different file
+ DEFAULT;
+ return addr;
+ }
+
+ GETREX();
+
+ rep = 0;
+ while((opcode==0xF2) || (opcode==0xF3)) {
+ rep = opcode-0xF1;
+ opcode = F8;
+ }
+
+ switch(opcode) {
+
+ case 0x01:
+ INST_NAME("ADD Ed, Gd");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED32(0);
+ emit_add32(dyn, ninst, rex, ed, gd, x3, x4, x5);
+ WBACK;
+ break;
+ case 0x02:
+ INST_NAME("ADD Gb, Eb");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETEB32(x2, 0);
+ GETGB(x1);
+ emit_add8(dyn, ninst, x1, x2, x3, x4);
+ GBBACK(x4);
+ break;
+ case 0x03:
+ INST_NAME("ADD Gd, Ed");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED32(0);
+ emit_add32(dyn, ninst, rex, gd, ed, x3, x4, x5);
+ break;
+
+ case 0x05:
+ INST_NAME("ADD EAX, Id");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ i64 = F32S;
+ emit_add32c(dyn, ninst, rex, xRAX, i64, x3, x4, x5, x6);
+ break;
+
+ case 0x09:
+ INST_NAME("OR Ed, Gd");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED32(0);
+ emit_or32(dyn, ninst, rex, ed, gd, x3, x4);
+ WBACK;
+ break;
+ case 0x0A:
+ INST_NAME("OR Gb, Eb");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETEB32(x2, 0);
+ GETGB(x1);
+ emit_or8(dyn, ninst, x1, x2, x3, x4);
+ GBBACK(x4);
+ break;
+ case 0x0B:
+ INST_NAME("OR Gd, Ed");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED32(0);
+ emit_or32(dyn, ninst, rex, gd, ed, x3, x4);
+ break;
+
+ case 0x0D:
+ INST_NAME("OR EAX, Id");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ i64 = F32S;
+ emit_or32c(dyn, ninst, rex, xRAX, i64, x3, x4);
+ break;
+
+ case 0x0F:
+ opcode=F8;
+ switch(opcode) {
+ case 0x2E:
+ // no special check...
+ case 0x2F:
+ switch (rep) {
+ case 0:
+ if(opcode==0x2F) {INST_NAME("COMISS Gx, Ex");} else {INST_NAME("UCOMISS Gx, Ex");}
+ SETFLAGS(X_ALL, SF_SET);
+ nextop = F8;
+ GETGXSS(s0);
+ if(MODREG) {
+ v0 = sse_get_reg(dyn, ninst, x1, (nextop&7) + (rex.b<<3), 1);
+ } else {
+ v0 = fpu_get_scratch(dyn);
+ SMREAD();
+ addr = geted32(dyn, addr, ninst, nextop, &ed, x1, x2, &fixedaddress, rex, NULL, 1, 0);
+ FLW(v0, ed, fixedaddress);
+ }
+ CLEAR_FLAGS();
+ // if isnan(s0) || isnan(v0)
+ IFX(X_ZF | X_PF | X_CF) {
+ FEQS(x3, s0, s0);
+ FEQS(x2, v0, v0);
+ AND(x2, x2, x3);
+ BNE_MARK(x2, xZR);
+ ORI(xFlags, xFlags, (1<<F_ZF) | (1<<F_PF) | (1<<F_CF));
+ B_NEXT_nocond;
+ }
+ MARK;
+ // else if isless(d0, v0)
+ IFX(X_CF) {
+ FLTS(x2, s0, v0);
+ BEQ_MARK2(x2, xZR);
+ ORI(xFlags, xFlags, 1<<F_CF);
+ B_NEXT_nocond;
+ }
+ MARK2;
+ // else if d0 == v0
+ IFX(X_ZF) {
+ FEQS(x2, s0, v0);
+ CBZ_NEXT(x2);
+ ORI(xFlags, xFlags, 1<<F_ZF);
+ }
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+
+ case 0x11:
+ INST_NAME("ADC Ed, Gd");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED32(0);
+ emit_adc32(dyn, ninst, rex, ed, gd, x3, x4, x5, x6);
+ WBACK;
+ break;
+
+ case 0x13:
+ INST_NAME("ADC Gd, Ed");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED32(0);
+ emit_adc32(dyn, ninst, rex, gd, ed, x3, x4, x5, x6);
+ break;
+
+ case 0x15:
+ INST_NAME("ADC EAX, Id");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ i64 = F32S;
+ MOV64xw(x1, i64);
+ emit_adc32(dyn, ninst, rex, xRAX, x1, x3, x4, x5, x6);
+ break;
+
+ case 0x19:
+ INST_NAME("SBB Ed, Gd");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED32(0);
+ emit_sbb32(dyn, ninst, rex, ed, gd, x3, x4, x5);
+ WBACK;
+ break;
+ case 0x1A:
+ INST_NAME("SBB Gb, Eb");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETEB32(x2, 0);
+ GETGB(x1);
+ emit_sbb8(dyn, ninst, x1, x2, x3, x4, x5);
+ GBBACK(x4);
+ break;
+ case 0x1B:
+ INST_NAME("SBB Gd, Ed");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED32(0);
+ emit_sbb32(dyn, ninst, rex, gd, ed, x3, x4, x5);
+ break;
+
+ case 0x1D:
+ INST_NAME("SBB EAX, Id");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ i64 = F32S;
+ MOV64xw(x2, i64);
+ emit_sbb32(dyn, ninst, rex, xRAX, x2, x3, x4, x5);
+ break;
+
+ case 0x21:
+ INST_NAME("AND Ed, Gd");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED32(0);
+ emit_and32(dyn, ninst, rex, ed, gd, x3, x4);
+ WBACK;
+ break;
+ case 0x22:
+ INST_NAME("AND Gb, Eb");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETEB32(x2, 0);
+ GETGB(x1);
+ emit_and8(dyn, ninst, x1, x2, x3, x4);
+ GBBACK(x4);
+ break;
+ case 0x23:
+ INST_NAME("AND Gd, Ed");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED32(0);
+ emit_and32(dyn, ninst, rex, gd, ed, x3, x4);
+ break;
+
+ case 0x25:
+ INST_NAME("AND EAX, Id");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ i64 = F32S;
+ emit_and32c(dyn, ninst, rex, xRAX, i64, x3, x4);
+ break;
+
+ case 0x29:
+ INST_NAME("SUB Ed, Gd");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED32(0);
+ emit_sub32(dyn, ninst, rex, ed, gd, x3, x4, x5);
+ WBACK;
+ break;
+ case 0x2A:
+ INST_NAME("SUB Gb, Eb");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETEB32(x2, 0);
+ GETGB(x1);
+ emit_sub8(dyn, ninst, x1, x2, x3, x4, x5);
+ GBBACK(x5);
+ break;
+ case 0x2B:
+ INST_NAME("SUB Gd, Ed");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED32(0);
+ emit_sub32(dyn, ninst, rex, gd, ed, x3, x4, x5);
+ break;
+
+ case 0x2D:
+ INST_NAME("SUB EAX, Id");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ i64 = F32S;
+ emit_sub32c(dyn, ninst, rex, xRAX, i64, x3, x4, x5, x6);
+ break;
+
+ case 0x31:
+ INST_NAME("XOR Ed, Gd");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED32(0);
+ emit_xor32(dyn, ninst, rex, ed, gd, x3, x4);
+ WBACK;
+ break;
+ case 0x32:
+ INST_NAME("XOR Gb, Eb");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETEB32(x2, 0);
+ GETGB(x1);
+ emit_xor8(dyn, ninst, x1, x2, x3, x4);
+ GBBACK(x4);
+ break;
+ case 0x33:
+ INST_NAME("XOR Gd, Ed");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED32(0);
+ emit_xor32(dyn, ninst, rex, gd, ed, x3, x4);
+ break;
+
+ case 0x35:
+ INST_NAME("XOR EAX, Id");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ i64 = F32S;
+ emit_xor32c(dyn, ninst, rex, xRAX, i64, x3, x4);
+ break;
+
+ case 0x38:
+ INST_NAME("CMP Eb, Gb");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETEB32(x1, 0);
+ GETGB(x2);
+ emit_cmp8(dyn, ninst, x1, x2, x3, x4, x5, x6);
+ break;
+ case 0x39:
+ INST_NAME("CMP Ed, Gd");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED32(0);
+ emit_cmp32(dyn, ninst, rex, ed, gd, x3, x4, x5, x6);
+ break;
+ case 0x3A:
+ INST_NAME("CMP Gb, Eb");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETEB32(x2, 0);
+ GETGB(x1);
+ emit_cmp8(dyn, ninst, x1, x2, x3, x4, x5, x6);
+ break;
+ case 0x3B:
+ INST_NAME("CMP Gd, Ed");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ GETED32(0);
+ emit_cmp32(dyn, ninst, rex, gd, ed, x3, x4, x5, x6);
+ break;
+ case 0x3C:
+ INST_NAME("CMP AL, Ib");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ u8 = F8;
+ ANDI(x1, xRAX, 0xff);
+ if(u8) {
+ MOV32w(x2, u8);
+ emit_cmp8(dyn, ninst, x1, x2, x3, x4, x5, x6);
+ } else {
+ emit_cmp8_0(dyn, ninst, x1, x3, x4);
+ }
+ break;
+ case 0x3D:
+ INST_NAME("CMP EAX, Id");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ i64 = F32S;
+ if(i64) {
+ MOV64xw(x2, i64);
+ emit_cmp32(dyn, ninst, rex, xRAX, x2, x3, x4, x5, x6);
+ } else
+ emit_cmp32_0(dyn, ninst, rex, xRAX, x3, x4);
+ break;
+
+ case 0x81:
+ case 0x83:
+ nextop = F8;
+ switch((nextop>>3)&7) {
+ case 0: //ADD
+ if(opcode==0x81) {INST_NAME("ADD Ed, Id");} else {INST_NAME("ADD Ed, Ib");}
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETED32((opcode==0x81)?4:1);
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ emit_add32c(dyn, ninst, rex, ed, i64, x3, x4, x5, x6);
+ WBACK;
+ break;
+ case 1: //OR
+ if(opcode==0x81) {INST_NAME("OR Ed, Id");} else {INST_NAME("OR Ed, Ib");}
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETED32((opcode==0x81)?4:1);
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ emit_or32c(dyn, ninst, rex, ed, i64, x3, x4);
+ WBACK;
+ break;
+ case 2: //ADC
+ if(opcode==0x81) {INST_NAME("ADC Ed, Id");} else {INST_NAME("ADC Ed, Ib");}
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETED32((opcode==0x81)?4:1);
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ MOV64xw(x5, i64);
+ emit_adc32(dyn, ninst, rex, ed, x5, x3, x4, x5, x6);
+ WBACK;
+ break;
+ case 3: //SBB
+ if(opcode==0x81) {INST_NAME("SBB Ed, Id");} else {INST_NAME("SBB Ed, Ib");}
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETED32((opcode==0x81)?4:1);
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ MOV64xw(x5, i64);
+ emit_sbb32(dyn, ninst, rex, ed, x5, x3, x4, x5);
+ WBACK;
+ break;
+ case 4: //AND
+ if(opcode==0x81) {INST_NAME("AND Ed, Id");} else {INST_NAME("AND Ed, Ib");}
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETED32((opcode==0x81)?4:1);
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ emit_and32c(dyn, ninst, rex, ed, i64, x3, x4);
+ WBACK;
+ break;
+ case 5: //SUB
+ if(opcode==0x81) {INST_NAME("SUB Ed, Id");} else {INST_NAME("SUB Ed, Ib");}
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETED32((opcode==0x81)?4:1);
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ emit_sub32c(dyn, ninst, rex, ed, i64, x3, x4, x5, x6);
+ WBACK;
+ break;
+ case 6: //XOR
+ if(opcode==0x81) {INST_NAME("XOR Ed, Id");} else {INST_NAME("XOR Ed, Ib");}
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETED32((opcode==0x81)?4:1);
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ emit_xor32c(dyn, ninst, rex, ed, i64, x3, x4);
+ WBACK;
+ break;
+ case 7: //CMP
+ if(opcode==0x81) {INST_NAME("CMP Ed, Id");} else {INST_NAME("CMP Ed, Ib");}
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ GETED32((opcode==0x81)?4:1);
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ if(i64) {
+ MOV64xw(x2, i64);
+ emit_cmp32(dyn, ninst, rex, ed, x2, x3, x4, x5, x6);
+ } else
+ emit_cmp32_0(dyn, ninst, rex, ed, x3, x4);
+ break;
+ }
+ break;
+
+ case 0x88:
+ INST_NAME("MOV Eb, Gb");
+ nextop = F8;
+ gd = ((nextop&0x38)>>3)+(rex.r<<3);
+ if(rex.rex) {
+ gb2 = 0;
+ gb1 = xRAX + gd;
+ } else {
+ gb2 = ((gd&4)>>2);
+ gb1 = xRAX+(gd&3);
+ }
+ gd = x4;
+ if(gb2) {
+ SRLI(x4, gb1, 8);
+ gb1 = x4;
+ }
+ if(MODREG) {
+ ed = (nextop&7) + (rex.b<<3);
+ if(rex.rex) {
+ eb1 = xRAX+ed;
+ eb2 = 0;
+ } else {
+ eb1 = xRAX+(ed&3); // Ax, Cx, Dx or Bx
+ eb2 = ((ed&4)>>2); // L or H
+ }
+ ANDI(gd, gb1, 0xff);
+ if(eb2) {
+ MOV64x(x1, 0xffffffffffff00ffLL);
+ AND(x1, eb1, x1);
+ SLLI(gd, gd, 8);
+ OR(eb1, x1, gd);
+ } else {
+ ANDI(x1, eb1, ~0xff);
+ OR(eb1, x1, gd);
+ }
+ } else {
+ addr = geted32(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, &lock, 1, 0);
+ SB(gb1, ed, fixedaddress);
+ SMWRITELOCK(lock);
+ }
+ break;
+ case 0x89:
+ INST_NAME("MOV Ed, Gd");
+ nextop=F8;
+ GETGD;
+ if(MODREG) { // reg <= reg
+ MVxw(xRAX+(nextop&7)+(rex.b<<3), gd);
+ } else { // mem <= reg
+ addr = geted32(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, &lock, 1, 0);
+ SDxw(gd, ed, fixedaddress);
+ SMWRITELOCK(lock);
+ }
+ break;
+ case 0x8B:
+ INST_NAME("MOV Gd, Ed");
+ nextop=F8;
+ GETGD;
+ if(MODREG) {
+ MVxw(gd, xRAX+(nextop&7)+(rex.b<<3));
+ } else {
+ addr = geted32(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, &lock, 1, 0);
+ SMREADLOCK(lock);
+ LDxw(gd, ed, fixedaddress);
+ }
+ break;
+ case 0x8D:
+ INST_NAME("LEA Gd, Ed");
+ nextop=F8;
+ GETGD;
+ if(MODREG) { // reg <= reg? that's an invalid operation
+ DEFAULT;
+ } else { // mem <= reg
+ addr = geted32(dyn, addr, ninst, nextop, &ed, gd, x1, &fixedaddress, rex, NULL, 0, 0);
+ if(ed!=gd) {
+ AND(gd, ed, xMASK);
+ }
+ }
+ break;
+ #define GO(Z) \
+ BARRIER(BARRIER_MAYBE); \
+ JUMP(addr+i8, 1); \
+ if(dyn->insts[ninst].x64.jmp_insts==-1 || \
+ CHECK_CACHE()) { \
+ /* out of the block */ \
+ i32 = dyn->insts[ninst].epilog-(dyn->native_size); \
+ if(Z) {BNE(x1, xZR, i32);} else {BEQ(x1, xZR, i32);}; \
+ if(dyn->insts[ninst].x64.jmp_insts==-1) { \
+ if(!(dyn->insts[ninst].x64.barrier&BARRIER_FLOAT)) \
+ fpu_purgecache(dyn, ninst, 1, x1, x2, x3); \
+ jump_to_next(dyn, addr+i8, 0, ninst); \
+ } else { \
+ CacheTransform(dyn, ninst, cacheupd, x1, x2, x3); \
+ i32 = dyn->insts[dyn->insts[ninst].x64.jmp_insts].address-(dyn->native_size); \
+ B(i32); \
+ } \
+ } else { \
+ /* inside the block */ \
+ i32 = dyn->insts[dyn->insts[ninst].x64.jmp_insts].address-(dyn->native_size); \
+ if(Z) {BEQ(x1, xZR, i32);} else {BNE(x1, xZR, i32);}; \
+ }
+ case 0xE0:
+ INST_NAME("LOOPNZ (32bits)");
+ READFLAGS(X_ZF);
+ i8 = F8S;
+ SUBI(xRCX, xRCX, 1);
+ ANDI(x1, xFlags, 1 << F_ZF);
+ CBNZ_NEXT(x1);
+ AND(x1, xRCX, xMASK);
+ GO(0);
+ break;
+ case 0xE1:
+ INST_NAME("LOOPZ (32bits)");
+ READFLAGS(X_ZF);
+ i8 = F8S;
+ SUBI(xRCX, xRCX, 1);
+ ANDI(x1, xFlags, 1 << F_ZF);
+ CBZ_NEXT(x1);
+ AND(x1, xRCX, xMASK);
+ GO(0);
+ break;
+ case 0xE2:
+ INST_NAME("LOOP (32bits)");
+ i8 = F8S;
+ SUBI(xRCX, xRCX, 1);
+ AND(x1, xRCX, xMASK);
+ GO(0);
+ break;
+ case 0xE3:
+ INST_NAME("JECXZ (32bits)");
+ i8 = F8S;
+ AND(x1, xRCX, xMASK);
+ GO(1);
+ break;
+ #undef GO
+
+ default:
+ DEFAULT;
+ }
+ return addr;
+}
diff --git a/src/dynarec/rv64/dynarec_rv64_d8.c b/src/dynarec/rv64/dynarec_rv64_d8.c
new file mode 100644
index 0000000..7f14468
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_d8.c
@@ -0,0 +1,182 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <stddef.h>
+#include <errno.h>
+
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "emu/x64run_private.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "emu/x64run_private.h"
+#include "x64trace.h"
+#include "emu/x87emu_private.h"
+#include "dynarec_native.h"
+
+#include "rv64_printer.h"
+#include "dynarec_rv64_private.h"
+#include "dynarec_rv64_helper.h"
+#include "dynarec_rv64_functions.h"
+
+
+uintptr_t dynarec64_D8(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog)
+{
+ (void)ip; (void)rep; (void)need_epilog;
+
+ uint8_t nextop = F8;
+ uint8_t ed;
+ uint8_t wback, wb1;
+ uint8_t u8;
+ int64_t fixedaddress;
+ int unscaled;
+ int v1, v2;
+ int s0;
+ int i1, i2, i3;
+
+ MAYUSE(s0);
+ MAYUSE(v2);
+ MAYUSE(v1);
+
+ switch(nextop) {
+ case 0xC0 ... 0xC7:
+
+ case 0xC8 ... 0xCF:
+
+ case 0xD0 ... 0xD7:
+
+ case 0xD8 ... 0xDF:
+ INST_NAME("FCOMP ST0, STx");
+ v1 = x87_get_st(dyn, ninst, x1, x2, 0, X87_COMBINE(0, nextop&7));
+ v2 = x87_get_st(dyn, ninst, x1, x2, nextop&7, X87_COMBINE(0, nextop&7));
+ LHU(x3, xEmu, offsetof(x64emu_t, sw));
+ MOV32w(x1, 0b1110100011111111); // mask off c0,c1,c2,c3
+ AND(x3, x3, x1);
+ if(ST_IS_F(0)) {
+ FEQS(x5, v1, v1);
+ FEQS(x4, v2, v2);
+ AND(x5, x5, x4);
+ BEQZ(x5, 24); // undefined/NaN
+ FEQS(x5, v1, v2);
+ BNEZ(x5, 28); // equal
+ FLTS(x3, v1, v2); // x3 = (v1<v2)?1:0
+ SLLI(x1, x3, 8);
+ J(20); // end
+ // undefined/NaN
+ LUI(x1, 1);
+ ADDI(x1, x1, 0b010100000000);
+ J(8); // end
+ // equal
+ LUI(x1, 1);
+ // end
+ } else {
+ FEQD(x5, v1, v1);
+ FEQD(x4, v2, v2);
+ AND(x5, x5, x4);
+ BEQZ(x5, 24); // undefined/NaN
+ FEQD(x5, v1, v2);
+ BNEZ(x5, 28); // equal
+ FLTD(x3, v1, v2); // x3 = (v1<v2)?1:0
+ SLLI(x1, x3, 8);
+ J(20); // end
+ // undefined/NaN
+ LUI(x1, 1);
+ ADDI(x1, x1, 0b010100000000);
+ J(8); // end
+ // equal
+ LUI(x1, 1);
+ // end
+ }
+ OR(x3, x3, x1);
+ SH(x3, xEmu, offsetof(x64emu_t, sw));
+ x87_do_pop(dyn, ninst, x3);
+ break;
+ case 0xE0 ... 0xE7:
+ INST_NAME("FSUB ST0, STx");
+ v1 = x87_get_st(dyn, ninst, x1, x2, 0, X87_COMBINE(0, nextop&7));
+ v2 = x87_get_st(dyn, ninst, x1, x2, nextop&7, X87_COMBINE(0, nextop&7));
+ if(ST_IS_F(0)) {
+ FSUBS(v1, v1, v2);
+ } else {
+ FSUBD(v1, v1, v2);
+ }
+ break;
+ case 0xE8 ... 0xEF:
+
+ case 0xF0 ... 0xF7:
+ INST_NAME("FDIV ST0, STx");
+ v1 = x87_get_st(dyn, ninst, x1, x2, 0, X87_COMBINE(0, nextop&7));
+ v2 = x87_get_st(dyn, ninst, x1, x2, nextop&7, X87_COMBINE(0, nextop&7));
+ if(ST_IS_F(0)) {
+ FDIVS(v1, v1, v2);
+ } else {
+ FDIVD(v1, v1, v2);
+ }
+ break;
+ case 0xF8 ... 0xFF:
+ DEFAULT;
+ break;
+
+ default:
+ switch((nextop>>3)&7) {
+ case 0:
+ INST_NAME("FADD ST0, float[ED]");
+ v1 = x87_get_st(dyn, ninst, x1, x2, 0, X87_ST0);
+ s0 = fpu_get_scratch(dyn);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, NULL, 1, 0);
+ FLW(s0, ed, fixedaddress);
+ if(ST_IS_F(0)) {
+ FADDS(v1, v1, s0);
+ } else {
+ FCVTDS(s0, s0);
+ FADDD(v1, v1, s0);
+ }
+ break;
+ case 1:
+ INST_NAME("FMUL ST0, float[ED]");
+ v1 = x87_get_st(dyn, ninst, x1, x2, 0, X87_ST0);
+ s0 = fpu_get_scratch(dyn);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, NULL, 1, 0);
+ FLW(s0, ed, fixedaddress);
+ if(ST_IS_F(0)) {
+ FMULS(v1, v1, s0);
+ } else {
+ FCVTDS(s0, s0);
+ FMULD(v1, v1, s0);
+ }
+ break;
+ case 4:
+ INST_NAME("FSUB ST0, float[ED]");
+ v1 = x87_get_st(dyn, ninst, x1, x2, 0, X87_ST0);
+ s0 = fpu_get_scratch(dyn);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, NULL, 1, 0);
+ FLW(s0, ed, fixedaddress);
+ if(ST_IS_F(0)) {
+ FSUBS(v1, v1, s0);
+ } else {
+ FCVTDS(s0, s0);
+ FSUBD(v1, v1, s0);
+ }
+ break;
+ case 6:
+ INST_NAME("FDIV ST0, float[ED]");
+ v1 = x87_get_st(dyn, ninst, x1, x2, 0, X87_ST0);
+ s0 = fpu_get_scratch(dyn);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, NULL, 1, 0);
+ FLW(s0, ed, fixedaddress);
+ if(ST_IS_F(0)) {
+ FDIVS(v1, v1, s0);
+ } else {
+ FCVTDS(s0, s0);
+ FDIVD(v1, v1, s0);
+ }
+ break;
+ default:
+ DEFAULT;
+ }
+ }
+ return addr;
+}
diff --git a/src/dynarec/rv64/dynarec_rv64_d9.c b/src/dynarec/rv64/dynarec_rv64_d9.c
new file mode 100644
index 0000000..4940d6b
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_d9.c
@@ -0,0 +1,426 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <stddef.h>
+#include <errno.h>
+
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "emu/x64run_private.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "emu/x64run_private.h"
+#include "x64trace.h"
+#include "emu/x87emu_private.h"
+#include "dynarec_native.h"
+
+#include "rv64_printer.h"
+#include "dynarec_rv64_private.h"
+#include "dynarec_rv64_helper.h"
+#include "dynarec_rv64_functions.h"
+
+
+uintptr_t dynarec64_D9(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog)
+{
+ (void)ip; (void)rep; (void)need_epilog;
+
+ uint8_t nextop = F8;
+ uint8_t ed;
+ uint8_t wback, wb1;
+ uint8_t u8;
+ int64_t fixedaddress;
+ int unscaled;
+ int v0, v1, v2;
+ int s0;
+ int i1, i2, i3;
+ int64_t j64;
+
+ MAYUSE(s0);
+ MAYUSE(v0);
+ MAYUSE(v1);
+ MAYUSE(v2);
+ MAYUSE(j64);
+
+ switch(nextop) {
+ case 0xC0:
+ case 0xC1:
+ case 0xC2:
+ case 0xC3:
+ case 0xC4:
+ case 0xC5:
+ case 0xC6:
+ case 0xC7:
+ INST_NAME("FLD STx");
+ v2 = x87_do_push(dyn, ninst, x1, X87_ST(nextop&7));
+ v1 = x87_get_st(dyn, ninst, x1, x2, (nextop&7)+1, X87_COMBINE(0, (nextop&7)+1));
+ if(ST_IS_F(0)) {
+ FMVS(v2, v1);
+ } else {
+ FMVD(v2, v1);
+ }
+ break;
+
+ case 0xC8:
+ INST_NAME("FXCH ST0");
+ break;
+ case 0xC9:
+ case 0xCA:
+ case 0xCB:
+ case 0xCC:
+ case 0xCD:
+ case 0xCE:
+ case 0xCF:
+ INST_NAME("FXCH STx");
+ // swap the cache value, not the double value itself :p
+ x87_get_st(dyn, ninst, x1, x2, nextop&7, X87_ST(nextop&7));
+ x87_get_st(dyn, ninst, x1, x2, 0, X87_ST0);
+ x87_swapreg(dyn, ninst, x1, x2, 0, nextop&7);
+ // should set C1 to 0
+ break;
+
+ case 0xD0:
+ INST_NAME("FNOP");
+ break;
+
+ case 0xD8:
+ INST_NAME("FSTPNCE ST0, ST0");
+ x87_do_pop(dyn, ninst, x3);
+ break;
+ case 0xD9:
+ case 0xDA:
+ case 0xDB:
+ case 0xDC:
+ case 0xDD:
+ case 0xDE:
+ case 0xDF:
+ INST_NAME("FSTPNCE ST0, STx");
+ // copy the cache value for st0 to stx
+ x87_get_st_empty(dyn, ninst, x1, x2, nextop&7, X87_ST(nextop&7));
+ x87_get_st(dyn, ninst, x1, x2, 0, X87_ST0);
+ x87_swapreg(dyn, ninst, x1, x2, 0, nextop&7);
+ x87_do_pop(dyn, ninst, x3);
+ break;
+ case 0xE0:
+ INST_NAME("FCHS");
+ v1 = x87_get_st(dyn, ninst, x1, x2, 0, X87_ST0);
+ if(ST_IS_F(0)) {
+ FNEGS(v1, v1);
+ } else {
+ FNEGD(v1, v1);
+ }
+ break;
+ case 0xE1:
+ INST_NAME("FABS");
+ v1 = x87_get_st(dyn, ninst, x1, x2, 0, X87_ST0);
+ if(ST_IS_F(0)) {
+ FABSS(v1, v1);
+ } else {
+ FABSD(v1, v1);
+ }
+ break;
+
+ case 0xE4:
+ INST_NAME("FTST");
+ DEFAULT
+ break;
+ case 0xE5:
+ INST_NAME("FXAM");
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ x87_refresh(dyn, ninst, x1, x2, 0);
+ CALL(fpu_fxam, -1); // should be possible inline, but is it worth it?
+ break;
+
+ case 0xE8:
+ INST_NAME("FLD1");
+ v1 = x87_do_push(dyn, ninst, x1, EXT_CACHE_ST_F);
+ if(ST_IS_F(0)) {
+ MOV32w(x1, 0x3f800000);
+ FMVWX(v1, x1);
+ } else {
+ MOV64x(x1, 0x3FF0000000000000);
+ FMVDX(v1, x1);
+ }
+ break;
+ case 0xE9:
+ INST_NAME("FLDL2T");
+ v1 = x87_do_push(dyn, ninst, x1, EXT_CACHE_ST_D);
+ FTABLE64(v1, L2T);
+ break;
+ case 0xEA:
+ INST_NAME("FLDL2E");
+ v1 = x87_do_push(dyn, ninst, x1, EXT_CACHE_ST_D);
+ FTABLE64(v1, L2E);
+ break;
+ case 0xEB:
+ INST_NAME("FLDPI");
+ v1 = x87_do_push(dyn, ninst, x1, EXT_CACHE_ST_D);
+ FTABLE64(v1, PI);
+ break;
+ case 0xEC:
+ INST_NAME("FLDLG2");
+ v1 = x87_do_push(dyn, ninst, x1, EXT_CACHE_ST_D);
+ FTABLE64(v1, LG2);
+ break;
+ case 0xED:
+ INST_NAME("FLDLN2");
+ v1 = x87_do_push(dyn, ninst, x1, EXT_CACHE_ST_D);
+ FTABLE64(v1, LN2);
+ break;
+ case 0xEE:
+ INST_NAME("FLDZ");
+ v1 = x87_do_push(dyn, ninst, x1, EXT_CACHE_ST_F);
+ if(ST_IS_F(0)) {
+ FMVWX(v1, xZR);
+ } else {
+ FMVDX(v1, xZR);
+ }
+ break;
+
+ case 0xF0:
+ INST_NAME("F2XM1");
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ x87_forget(dyn, ninst, x1, x2, 0);
+ CALL(native_f2xm1, -1);
+ break;
+ case 0xF1:
+ INST_NAME("FYL2X");
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ x87_forget(dyn, ninst, x1, x2, 0);
+ x87_forget(dyn, ninst, x1, x2, 1);
+ CALL(native_fyl2x, -1);
+ x87_do_pop(dyn, ninst, x3);
+ break;
+ case 0xF2:
+ INST_NAME("FPTAN");
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ x87_forget(dyn, ninst, x1, x2, 0);
+ CALL(native_ftan, -1);
+ v1 = x87_do_push(dyn, ninst, x1, EXT_CACHE_ST_F);
+ if(ST_IS_F(0)) {
+ MOV32w(x1, 0x3f800000);
+ FMVWX(v1, x1);
+ } else {
+ MOV64x(x1, 0x3FF0000000000000);
+ FMVDX(v1, x1);
+ }
+ break;
+ case 0xF3:
+ INST_NAME("FPATAN");
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ x87_forget(dyn, ninst, x1, x2, 0);
+ x87_forget(dyn, ninst, x1, x2, 1);
+ CALL(native_fpatan, -1);
+ x87_do_pop(dyn, ninst, x3);
+ break;
+ case 0xF4:
+ INST_NAME("FXTRACT");
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ x87_do_push_empty(dyn, ninst, 0);
+ x87_forget(dyn, ninst, x1, x2, 1);
+ CALL(native_fxtract, -1);
+ break;
+ case 0xF5:
+ INST_NAME("FPREM1");
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ x87_forget(dyn, ninst, x1, x2, 0);
+ x87_forget(dyn, ninst, x1, x2, 1);
+ CALL(native_fprem1, -1);
+ break;
+ case 0xF6:
+ INST_NAME("FDECSTP");
+ fpu_purgecache(dyn, ninst, 0, x1, x2, x3);
+ LW(x2, xEmu, offsetof(x64emu_t, top));
+ SUBI(x2, x2, 1);
+ ANDI(x2, x2, 7);
+ SW(x2, xEmu, offsetof(x64emu_t, top));
+ break;
+ case 0xF7:
+ INST_NAME("FINCSTP");
+ fpu_purgecache(dyn, ninst, 0, x1, x2, x3);
+ LW(x2, xEmu, offsetof(x64emu_t, top));
+ ADDI(x2, x2, 1);
+ ANDI(x2, x2, 7);
+ SW(x2, xEmu, offsetof(x64emu_t, top));
+ break;
+ case 0xF8:
+ INST_NAME("FPREM");
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ x87_forget(dyn, ninst, x1, x2, 0);
+ x87_forget(dyn, ninst, x1, x2, 1);
+ CALL(native_fprem, -1);
+ break;
+ case 0xF9:
+ INST_NAME("FYL2XP1");
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ x87_forget(dyn, ninst, x1, x2, 0);
+ x87_forget(dyn, ninst, x1, x2, 1);
+ CALL(native_fyl2xp1, -1);
+ x87_do_pop(dyn, ninst, x3);
+ break;
+ case 0xFA:
+ INST_NAME("FSQRT");
+ v1 = x87_get_st(dyn, ninst, x1, x2, 0, X87_ST0);
+ if(ST_IS_F(0)) {
+ FSQRTS(v1, v1);
+ } else {
+ FSQRTD(v1, v1);
+ }
+ break;
+ case 0xFB:
+ INST_NAME("FSINCOS");
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ x87_do_push_empty(dyn, ninst, 0);
+ x87_forget(dyn, ninst, x1, x2, 1);
+ CALL(native_fsincos, -1);
+ break;
+ case 0xFC:
+ INST_NAME("FRNDINT");
+ v0 = x87_get_st(dyn, ninst, x1, x2, 0, X87_ST0);
+ v1 = fpu_get_scratch(dyn);
+ v2 = fpu_get_scratch(dyn);
+ u8 = x87_setround(dyn, ninst, x1, x2);
+
+ if(ST_IS_F(0)) {
+ FEQS(x2, v0, v0);
+ BNEZ_MARK(x2);
+ B_NEXT_nocond;
+ MARK; // v0 is not nan
+ FABSS(v1, v0);
+ MOV64x(x3, 1ULL << __FLT_MANT_DIG__);
+ FCVTSL(v2, x3, RD_RTZ);
+ FLTS(x3, v1, v2);
+ BNEZ_MARK2(x3);
+ B_NEXT_nocond;
+ MARK2;
+ FCVTLS(x3, v0, RD_DYN);
+ FCVTSL(v1, x3, RD_DYN);
+ FSGNJS(v0, v1, v0);
+ } else {
+ FEQD(x2, v0, v0);
+ BNEZ_MARK(x2);
+ B_NEXT_nocond;
+ MARK; // v0 is not nan
+ FABSD(v1, v0);
+ MOV64x(x3, 1ULL << __DBL_MANT_DIG__);
+ FCVTDL(v2, x3, RD_RTZ);
+ FLTD(x3, v1, v2);
+ BNEZ_MARK2(x3);
+ B_NEXT_nocond;
+ MARK2;
+ FCVTLD(x3, v0, RD_DYN);
+ FCVTDL(v1, x3, RD_DYN);
+ FSGNJD(v0, v1, v0);
+ }
+ x87_restoreround(dyn, ninst, u8);
+ break;
+ case 0xFD:
+ INST_NAME("FSCALE");
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ x87_forget(dyn, ninst, x1, x2, 0);
+ x87_forget(dyn, ninst, x1, x2, 1);
+ CALL(native_fscale, -1);
+ break;
+ case 0xFE:
+ INST_NAME("FSIN");
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ x87_forget(dyn, ninst, x1, x2, 0);
+ CALL(native_fsin, -1);
+ break;
+ case 0xFF:
+ INST_NAME("FCOS");
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ x87_forget(dyn, ninst, x1, x2, 0);
+ CALL(native_fcos, -1);
+ break;
+
+
+ case 0xD1:
+ case 0xD4:
+ case 0xD5:
+ case 0xD6:
+ case 0xD7:
+ case 0xE2:
+ case 0xE3:
+ case 0xE6:
+ case 0xE7:
+ case 0xEF:
+ DEFAULT;
+ break;
+
+ default:
+ switch((nextop>>3)&7) {
+ case 0:
+ INST_NAME("FLD ST0, float[ED]");
+ v1 = x87_do_push(dyn, ninst, x1, box64_dynarec_x87double?EXT_CACHE_ST_D:EXT_CACHE_ST_F);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, NULL, 1, 0);
+ FLW(v1, ed, fixedaddress);
+ if(!ST_IS_F(0)) {
+ FCVTDS(v1, v1);
+ }
+ break;
+ case 2:
+ INST_NAME("FST float[ED], ST0");
+ v1 = x87_get_st(dyn, ninst, x1, x2, 0, EXT_CACHE_ST_F);
+ if(ST_IS_F(0))
+ s0 = v1;
+ else {
+ s0 = fpu_get_scratch(dyn);
+ FCVTSD(s0, v1);
+ }
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, NULL, 1, 0);
+ FSW(s0, ed, fixedaddress);
+ break;
+ case 3:
+ INST_NAME("FSTP float[ED], ST0");
+ v1 = x87_get_st(dyn, ninst, x1, x2, 0, EXT_CACHE_ST_F);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, NULL, 1, 0);
+ if(!ST_IS_F(0)) {
+ FCVTSD(v1, v1);
+ }
+ FSW(v1, ed, fixedaddress);
+ x87_do_pop(dyn, ninst, x3);
+ break;
+ case 4:
+ INST_NAME("FLDENV Ed");
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ fpu_purgecache(dyn, ninst, 0, x1, x2, x3); // maybe only x87, not SSE?
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, x2, &fixedaddress, rex, NULL, 0, 0);
+ if(ed!=x1) {
+ MV(x1, ed);
+ }
+ MOV32w(x2, 0);
+ CALL(fpu_loadenv, -1);
+ break;
+ case 5:
+ INST_NAME("FLDCW Ew");
+ GETEW(x1, 0);
+ SH(x1, xEmu, offsetof(x64emu_t, cw)); // hopefully cw is not too far for an imm8
+ break;
+ case 6:
+ INST_NAME("FNSTENV Ed");
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ fpu_purgecache(dyn, ninst, 0, x1, x2, x3); // maybe only x87, not SSE?
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, x2, &fixedaddress, rex, NULL, 0, 0);
+ if(ed!=x1) {
+ MV(x1, ed);
+ }
+ MOV32w(x2, 0);
+ CALL(fpu_savenv, -1);
+ break;
+ case 7:
+ INST_NAME("FNSTCW Ew");
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, x1, &fixedaddress, rex, NULL, 0, 0);
+ ed = x1;
+ wb1 = 1;
+ LH(x1, xEmu, offsetof(x64emu_t, cw));
+ EWBACK;
+ break;
+ default:
+ DEFAULT;
+ }
+ }
+ return addr;
+}
diff --git a/src/dynarec/rv64/dynarec_rv64_db.c b/src/dynarec/rv64/dynarec_rv64_db.c
new file mode 100644
index 0000000..7a5dddb
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_db.c
@@ -0,0 +1,303 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <stddef.h>
+#include <errno.h>
+
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "emu/x64run_private.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "emu/x64run_private.h"
+#include "x64trace.h"
+#include "emu/x87emu_private.h"
+#include "dynarec_native.h"
+
+#include "rv64_printer.h"
+#include "dynarec_rv64_private.h"
+#include "dynarec_rv64_helper.h"
+#include "dynarec_rv64_functions.h"
+
+
+uintptr_t dynarec64_DB(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog)
+{
+ (void)ip; (void)rep; (void)need_epilog;
+
+ uint8_t nextop = F8;
+ uint8_t ed;
+ uint8_t wback;
+ uint8_t u8;
+ int64_t fixedaddress;
+ int unscaled;
+ int v1, v2;
+ int s0;
+ int64_t j64;
+
+ MAYUSE(s0);
+ MAYUSE(v2);
+ MAYUSE(v1);
+ MAYUSE(j64);
+
+ switch(nextop) {
+ case 0xC0:
+ case 0xC1:
+ case 0xC2:
+ case 0xC3:
+ case 0xC4:
+ case 0xC5:
+ case 0xC6:
+ case 0xC7:
+ INST_NAME("FCMOVNB ST0, STx");
+ READFLAGS(X_CF);
+ v1 = x87_get_st(dyn, ninst, x1, x2, 0, X87_COMBINE(0, nextop&7));
+ v2 = x87_get_st(dyn, ninst, x1, x2, nextop&7, X87_COMBINE(0, nextop&7));
+ ANDI(x1, xFlags, 1<<F_CF);
+ CBNZ_NEXT(x1);
+ if(ST_IS_F(0)) {
+ FMVS(v1, v2);
+ } else {
+ FMVD(v1, v2); // F_CF==0
+ }
+ break;
+ case 0xC8:
+ case 0xC9:
+ case 0xCA:
+ case 0xCB:
+ case 0xCC:
+ case 0xCD:
+ case 0xCE:
+ case 0xCF:
+ INST_NAME("FCMOVNE ST0, STx");
+ READFLAGS(X_ZF);
+ v1 = x87_get_st(dyn, ninst, x1, x2, 0, X87_COMBINE(0, nextop&7));
+ v2 = x87_get_st(dyn, ninst, x1, x2, nextop&7, X87_COMBINE(0, nextop&7));
+ ANDI(x1, xFlags, 1<<F_ZF);
+ CBNZ_NEXT(x1);
+ if(ST_IS_F(0)) {
+ FMVS(v1, v2);
+ } else {
+ FMVD(v1, v2); // F_ZF==0
+ }
+ break;
+ case 0xD0:
+ case 0xD1:
+ case 0xD2:
+ case 0xD3:
+ case 0xD4:
+ case 0xD5:
+ case 0xD6:
+ case 0xD7:
+ INST_NAME("FCMOVNBE ST0, STx");
+ READFLAGS(X_CF|X_ZF);
+ v1 = x87_get_st(dyn, ninst, x1, x2, 0, X87_COMBINE(0, nextop&7));
+ v2 = x87_get_st(dyn, ninst, x1, x2, nextop&7, X87_COMBINE(0, nextop&7));
+ ANDI(x1, xFlags, (1<<F_CF)|(1<<F_ZF));
+ CBNZ_NEXT(x1);
+ if(ST_IS_F(0)) {
+ FMVS(v1, v2);
+ } else {
+ FMVD(v1, v2); // F_CF==0 & F_ZF==0
+ }
+ break;
+ case 0xD8:
+ case 0xD9:
+ case 0xDA:
+ case 0xDB:
+ case 0xDC:
+ case 0xDD:
+ case 0xDE:
+ case 0xDF:
+ INST_NAME("FCMOVNU ST0, STx");
+ READFLAGS(X_PF);
+ v1 = x87_get_st(dyn, ninst, x1, x2, 0, X87_COMBINE(0, nextop&7));
+ v2 = x87_get_st(dyn, ninst, x1, x2, nextop&7, X87_COMBINE(0, nextop&7));
+ ANDI(x1, xFlags, 1<<F_PF);
+ CBNZ_NEXT(x1);
+ if(ST_IS_F(0)) {
+ FMVS(v1, v2);
+ } else {
+ FMVD(v1, v2); // F_PF==0
+ }
+ break;
+ case 0xE1:
+ INST_NAME("FDISI8087_NOP"); // so.. NOP?
+ break;
+ case 0xE2:
+ INST_NAME("FNCLEX");
+ LH(x2, xEmu, offsetof(x64emu_t, sw));
+ ANDI(x2, x2, ~(0xff)); // IE .. PE, SF, ES
+ MOV32w(x1, ~(1<<15)); // B
+ AND(x2, x2, x1);
+ SH(x2, xEmu, offsetof(x64emu_t, sw));
+ break;
+ case 0xE3:
+ INST_NAME("FNINIT");
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ x87_purgecache(dyn, ninst, 0, x1, x2, x3);
+ CALL(reset_fpu, -1);
+ break;
+ case 0xE8:
+ case 0xE9:
+ case 0xEA:
+ case 0xEB:
+ case 0xEC:
+ case 0xED:
+ case 0xEE:
+ case 0xEF:
+ INST_NAME("FUCOMI ST0, STx");
+ SETFLAGS(X_ALL, SF_SET);
+ SET_DFNONE();
+ v1 = x87_get_st(dyn, ninst, x1, x2, 0, X87_COMBINE(0, nextop&7));
+ v2 = x87_get_st(dyn, ninst, x1, x2, nextop&7, X87_COMBINE(0, nextop&7));
+ IFX(F_ZF | F_PF | F_CF) {
+ if(ST_IS_F(0)) {
+ FEQS(x5, v1, v1);
+ FEQS(x4, v2, v2);
+ AND(x5, x5, x4);
+ BEQZ(x5, 24); // undefined/NaN
+ FEQS(x5, v1, v2);
+ BNEZ(x5, 24); // equal
+ FLTS(x3, v1, v2); // x3 = (v1<v2)?1:0
+ OR(xFlags, xFlags, x3); // CF is the least significant bit
+ J(16); // end
+ // NaN
+ ORI(xFlags, xFlags, (1<<F_ZF) | (1<<F_PF) | (1<<F_CF));
+ J(8); // end
+ // equal
+ ORI(xFlags, xFlags, 1<<F_ZF);
+ // end
+ } else {
+ FEQD(x5, v1, v1);
+ FEQD(x4, v2, v2);
+ AND(x5, x5, x4);
+ BEQZ(x5, 24); // undefined/NaN
+ FEQD(x5, v1, v2);
+ BNEZ(x5, 24); // equal
+ FLTD(x3, v1, v2); // x3 = (v1<v2)?1:0
+ OR(xFlags, xFlags, x3); // CF is the least significant bit
+ J(16); // end
+ // NaN
+ ORI(xFlags, xFlags, (1<<F_ZF) | (1<<F_PF) | (1<<F_CF));
+ J(8); // end
+ // equal
+ ORI(xFlags, xFlags, 1<<F_ZF);
+ // end
+ }
+ }
+ break;
+ case 0xF0:
+ case 0xF1:
+ case 0xF2:
+ case 0xF3:
+ case 0xF4:
+ case 0xF5:
+ case 0xF6:
+ case 0xF7:
+ INST_NAME("FCOMI ST0, STx");
+ DEFAULT;
+ break;
+
+ case 0xE0:
+ case 0xE4:
+ case 0xE5:
+ case 0xE6:
+ case 0xE7:
+ DEFAULT;
+ break;
+
+ default:
+ switch((nextop>>3)&7) {
+ case 0:
+ INST_NAME("FILD ST0, Ed");
+ v1 = x87_do_push(dyn, ninst, x1, EXT_CACHE_ST_D);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x2, x1, &fixedaddress, rex, NULL, 1, 0);
+ LW(x1, ed, fixedaddress);
+ FCVTDW(v1, x1, RD_RNE); // i32 -> double
+ break;
+ case 1:
+ INST_NAME("FISTTP Ed, ST0");
+ DEFAULT;
+ break;
+ case 2:
+ INST_NAME("FIST Ed, ST0");
+ DEFAULT;
+ break;
+ case 3:
+ INST_NAME("FISTP Ed, ST0");
+ v1 = x87_get_st(dyn, ninst, x1, x2, 0, EXT_CACHE_ST_D);
+ u8 = x87_setround(dyn, ninst, x1, x2);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x3, &fixedaddress, rex, NULL, 1, 0);
+ v2 = fpu_get_scratch(dyn);
+ if(!box64_dynarec_fastround) {
+ FSFLAGSI(0); // reset all bits
+ }
+ FCVTWD(x4, v1, RD_DYN);
+ x87_restoreround(dyn, ninst, u8);
+ if(!box64_dynarec_fastround) {
+ FRFLAGS(x5); // get back FPSR to check the IOC bit
+ ANDI(x5, x5, 1<<FR_NV);
+ BEQ_MARK2(x5, xZR);
+ MOV32w(x4, 0x80000000);
+ }
+ MARK2;
+ SW(x4, wback, fixedaddress);
+ x87_do_pop(dyn, ninst, x3);
+ break;
+ case 5:
+ INST_NAME("FLD tbyte");
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, x2, &fixedaddress, rex, NULL, 8, 0);
+ if((PK(0)==0xDB && ((PK(1)>>3)&7)==7) || (PK(0)>=0x40 && PK(0)<=0x4f && PK(1)==0xDB && ((PK(2)>>3)&7)==7)) {
+ // the FLD is immediatly followed by an FSTP
+ LD(x5, ed, fixedaddress+0);
+ LH(x6, ed, fixedaddress+8);
+ // no persistant scratch register, so unrool both instruction here...
+ MESSAGE(LOG_DUMP, "\tHack: FSTP tbyte\n");
+ nextop = F8; // 0xDB or rex
+ if(nextop>=0x40 && nextop<=0x4f) {
+ rex.rex = nextop;
+ nextop = F8; //0xDB
+ } else
+ rex.rex = 0;
+ nextop = F8; //modrm
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, x2, &fixedaddress, rex, NULL, 8, 0);
+ SD(x5, ed, fixedaddress+0);
+ SH(x6, ed, fixedaddress+8);
+ } else {
+ if(box64_x87_no80bits) {
+ v1 = x87_do_push(dyn, ninst, x1, EXT_CACHE_ST_D);
+ FLD(v1, ed, fixedaddress);
+ } else {
+ if(ed!=x1) {
+ MV(x1, ed);
+ }
+ x87_do_push_empty(dyn, ninst, x3);
+ CALL(native_fld, -1);
+ }
+ }
+ break;
+ case 7:
+ INST_NAME("FSTP tbyte");
+ if(box64_x87_no80bits) {
+ v1 = x87_get_st(dyn, ninst, x1, x2, 0, EXT_CACHE_ST_D);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, NULL, 1, 0);
+ FSD(v1, wback, fixedaddress);
+ } else {
+ x87_forget(dyn, ninst, x1, x3, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, x2, &fixedaddress, rex, NULL, 0, 0);
+ if(ed!=x1) {
+ MV(x1, ed);
+ }
+ CALL(native_fstp, -1);
+ }
+ x87_do_pop(dyn, ninst, x3);
+ break;
+ default:
+ DEFAULT;
+ }
+ }
+ return addr;
+}
diff --git a/src/dynarec/rv64/dynarec_rv64_dc.c b/src/dynarec/rv64/dynarec_rv64_dc.c
new file mode 100644
index 0000000..d802e2f
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_dc.c
@@ -0,0 +1,119 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <stddef.h>
+#include <errno.h>
+
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "emu/x64run_private.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "emu/x64run_private.h"
+#include "x64trace.h"
+#include "emu/x87emu_private.h"
+#include "dynarec_native.h"
+
+#include "rv64_printer.h"
+#include "dynarec_rv64_private.h"
+#include "dynarec_rv64_helper.h"
+#include "dynarec_rv64_functions.h"
+
+
+uintptr_t dynarec64_DC(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog)
+{
+ (void)ip; (void)rep; (void)need_epilog;
+
+ uint8_t nextop = F8;
+ uint8_t wback;
+ int64_t fixedaddress;
+ int unscaled;
+ int v1, v2;
+
+ MAYUSE(v2);
+ MAYUSE(v1);
+
+ switch(nextop) {
+ case 0xC0 ... 0xC7:
+ INST_NAME("FADD STx, ST0");
+ DEFAULT;
+ break;
+ case 0xC8 ... 0xCF:
+ INST_NAME("FMUL STx, ST0");
+ DEFAULT;
+ break;
+ case 0xD0 ... 0xD7:
+ INST_NAME("FCOM ST0, STx"); //yep
+ DEFAULT;
+ break;
+ case 0xD8 ... 0xDF:
+ INST_NAME("FCOMP ST0, STx");
+ DEFAULT;
+ break;
+ case 0xE0 ... 0xE7:
+ INST_NAME("FSUBR STx, ST0");
+ DEFAULT;
+ break;
+ break;
+ case 0xE8 ... 0xEF:
+ INST_NAME("FSUB STx, ST0");
+ DEFAULT;
+ break;
+ case 0xF0 ... 0xF7:
+ INST_NAME("FDIVR STx, ST0");
+ DEFAULT;
+ break;
+ case 0xF8 ... 0xFF:
+ INST_NAME("FDIV STx, ST0");
+ DEFAULT;
+ break;
+ default:
+ switch((nextop>>3)&7) {
+ case 3:
+ INST_NAME("FCOMP ST0, double[ED]");
+ v1 = x87_get_st(dyn, ninst, x1, x2, 0, EXT_CACHE_ST_D);
+ v2 = fpu_get_scratch(dyn);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, NULL, 1, 0);
+ FLD(v2, wback, fixedaddress);
+
+ LHU(x3, xEmu, offsetof(x64emu_t, sw));
+ MOV32w(x1, 0b1110100011111111); // mask off c0,c1,c2,c3
+ AND(x3, x3, x1);
+ FEQD(x5, v1, v1);
+ FEQD(x4, v2, v2);
+ AND(x5, x5, x4);
+ BEQZ(x5, 24); // undefined/NaN
+ FEQD(x5, v1, v2);
+ BNEZ(x5, 28); // equal
+ FLTD(x3, v1, v2); // x3 = (v1<v2)?1:0
+ SLLI(x1, x3, 8);
+ J(20); // end
+ // undefined/NaN
+ LUI(x1, 1);
+ ADDI(x1, x1, 0b010100000000);
+ J(8); // end
+ // equal
+ LUI(x1, 1);
+ // end
+ OR(x3, x3, x1);
+ SH(x3, xEmu, offsetof(x64emu_t, sw));
+
+ x87_do_pop(dyn, ninst, x3);
+ break;
+ case 6:
+ INST_NAME("FDIV ST0, double[ED]");
+ v1 = x87_get_st(dyn, ninst, x1, x2, 0, EXT_CACHE_ST_D);
+ v2 = fpu_get_scratch(dyn);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, NULL, 1, 0);
+ FLD(v2, wback, fixedaddress);
+ FDIVD(v1, v1, v2);
+ break;
+ default:
+ DEFAULT;
+ }
+ }
+ return addr;
+}
diff --git a/src/dynarec/rv64/dynarec_rv64_dd.c b/src/dynarec/rv64/dynarec_rv64_dd.c
new file mode 100644
index 0000000..044f9aa
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_dd.c
@@ -0,0 +1,179 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <stddef.h>
+#include <errno.h>
+
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "emu/x64run_private.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "emu/x64run_private.h"
+#include "x64trace.h"
+#include "emu/x87emu_private.h"
+#include "dynarec_native.h"
+
+#include "rv64_printer.h"
+#include "dynarec_rv64_private.h"
+#include "dynarec_rv64_helper.h"
+#include "dynarec_rv64_functions.h"
+
+
+uintptr_t dynarec64_DD(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog)
+{
+ (void)ip; (void)rep; (void)need_epilog;
+
+ uint8_t nextop = F8;
+ uint8_t ed, wback;
+ int64_t fixedaddress;
+ int unscaled;
+ int v1, v2;
+ int s0;
+ int64_t j64;
+
+ MAYUSE(s0);
+ MAYUSE(v2);
+ MAYUSE(v1);
+ MAYUSE(j64);
+
+ switch(nextop) {
+ case 0xC0:
+ case 0xC1:
+ case 0xC2:
+ case 0xC3:
+ case 0xC4:
+ case 0xC5:
+ case 0xC6:
+ case 0xC7:
+ INST_NAME("FFREE STx");
+ MESSAGE(LOG_DUMP, "Need Optimization\n");
+ x87_purgecache(dyn, ninst, 0, x1, x2, x3);
+ MOV32w(x1, nextop&7);
+ CALL(fpu_do_free, -1);
+ break;
+ case 0xD0:
+ case 0xD1:
+ case 0xD2:
+ case 0xD3:
+ case 0xD4:
+ case 0xD5:
+ case 0xD6:
+ case 0xD7:
+ INST_NAME("FST ST0, STx");
+ DEFAULT;
+ break;
+ case 0xD8:
+ INST_NAME("FSTP ST0, ST0");
+ x87_do_pop(dyn, ninst, x3);
+ break;
+ case 0xD9:
+ case 0xDA:
+ case 0xDB:
+ case 0xDC:
+ case 0xDD:
+ case 0xDE:
+ case 0xDF:
+ INST_NAME("FSTP ST0, STx");
+ // copy the cache value for st0 to stx
+ x87_get_st_empty(dyn, ninst, x1, x2, nextop&7, X87_ST(nextop&7));
+ x87_get_st(dyn, ninst, x1, x2, 0, X87_ST0);
+ x87_swapreg(dyn, ninst, x1, x2, 0, nextop&7);
+ x87_do_pop(dyn, ninst, x3);
+ break;
+ case 0xE0:
+ case 0xE1:
+ case 0xE2:
+ case 0xE3:
+ case 0xE4:
+ case 0xE5:
+ case 0xE6:
+ case 0xE7:
+ INST_NAME("FUCOM ST0, STx");
+ DEFAULT;
+ break;
+ case 0xE8:
+ case 0xE9:
+ case 0xEA:
+ case 0xEB:
+ case 0xEC:
+ case 0xED:
+ case 0xEE:
+ case 0xEF:
+ INST_NAME("FUCOMP ST0, STx");
+ DEFAULT;
+ break;
+ case 0xC8:
+ case 0xC9:
+ case 0xCA:
+ case 0xCB:
+ case 0xCC:
+ case 0xCD:
+ case 0xCE:
+ case 0xCF:
+ case 0xF0:
+ case 0xF1:
+ case 0xF2:
+ case 0xF3:
+ case 0xF4:
+ case 0xF5:
+ case 0xF6:
+ case 0xF7:
+ case 0xF8:
+ case 0xF9:
+ case 0xFA:
+ case 0xFB:
+ case 0xFC:
+ case 0xFD:
+ case 0xFE:
+ case 0xFF:
+ DEFAULT;
+ break;
+
+ default:
+ switch((nextop>>3)&7) {
+ case 0:
+ INST_NAME("FLD double");
+ v1 = x87_do_push(dyn, ninst, x1, EXT_CACHE_ST_D);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, NULL, 1, 0);
+ FLD(v1, wback, fixedaddress);
+ break;
+ case 2:
+ INST_NAME("FST double");
+ v1 = x87_get_st(dyn, ninst, x1, x2, 0, EXT_CACHE_ST_D);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, NULL, 1, 0);
+ FSD(v1, wback, fixedaddress);
+ break;
+ case 3:
+ INST_NAME("FSTP double");
+ v1 = x87_get_st(dyn, ninst, x1, x2, 0, EXT_CACHE_ST_D);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, NULL, 1, 0);
+ FSD(v1, wback, fixedaddress);
+ x87_do_pop(dyn, ninst, x3);
+ break;
+ case 7:
+ INST_NAME("FNSTSW m2byte");
+ fpu_purgecache(dyn, ninst, 0, x1, x2, x3);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x4, x6, &fixedaddress, rex, NULL, 0, 0);
+ LWU(x2, xEmu, offsetof(x64emu_t, top));
+ LHU(x3, xEmu, offsetof(x64emu_t, sw));
+ if(dyn->e.x87stack) {
+ // update top
+ ADDI(x2, x2, -dyn->e.x87stack);
+ ANDI(x2, x2, 7);
+ }
+ MOV32w(x5, ~0x3800);
+ AND(x3, x3, x5); // mask out TOP
+ SLLI(x2, x2, 11); // shift TOP to bit 11
+ OR(x3, x3, x2); // inject TOP
+ SH(x3, ed, fixedaddress); // store whole sw flags
+ break;
+ default:
+ DEFAULT;
+ }
+ }
+ return addr;
+}
diff --git a/src/dynarec/rv64/dynarec_rv64_de.c b/src/dynarec/rv64/dynarec_rv64_de.c
new file mode 100644
index 0000000..a2341b4
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_de.c
@@ -0,0 +1,177 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <stddef.h>
+#include <errno.h>
+
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "emu/x64run_private.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "emu/x64run_private.h"
+#include "x64trace.h"
+#include "emu/x87emu_private.h"
+#include "dynarec_native.h"
+
+#include "rv64_printer.h"
+#include "dynarec_rv64_private.h"
+#include "dynarec_rv64_helper.h"
+#include "dynarec_rv64_functions.h"
+
+
+uintptr_t dynarec64_DE(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog)
+{
+ (void)ip; (void)rep; (void)need_epilog;
+
+ uint8_t nextop = F8;
+ uint8_t wback;
+ int64_t fixedaddress;
+ int v1, v2;
+
+ MAYUSE(v2);
+ MAYUSE(v1);
+
+ switch(nextop) {
+ case 0xC0:
+ case 0xC1:
+ case 0xC2:
+ case 0xC3:
+ case 0xC4:
+ case 0xC5:
+ case 0xC6:
+ case 0xC7:
+ INST_NAME("FADDP STx, ST0");
+ v2 = x87_get_st(dyn, ninst, x1, x2, 0, X87_COMBINE(0, nextop&7));
+ v1 = x87_get_st(dyn, ninst, x1, x2, nextop&7, X87_COMBINE(0, nextop&7));
+ if(ST_IS_F(0)) {
+ FADDS(v1, v1, v2);
+ } else {
+ FADDD(v1, v1, v2);
+ }
+ x87_do_pop(dyn, ninst, x3);
+ break;
+ case 0xC8:
+ case 0xC9:
+ case 0xCA:
+ case 0xCB:
+ case 0xCC:
+ case 0xCD:
+ case 0xCE:
+ case 0xCF:
+ INST_NAME("FMULP STx, ST0");
+ v2 = x87_get_st(dyn, ninst, x1, x2, 0, X87_COMBINE(0, nextop&7));
+ v1 = x87_get_st(dyn, ninst, x1, x2, nextop&7, X87_COMBINE(0, nextop&7));
+ if(ST_IS_F(0)) {
+ FMULS(v1, v1, v2);
+ } else {
+ FMULD(v1, v1, v2);
+ }
+ x87_do_pop(dyn, ninst, x3);
+ break;
+ case 0xD0:
+ case 0xD1:
+ case 0xD2:
+ case 0xD3:
+ case 0xD4:
+ case 0xD5:
+ case 0xD6:
+ case 0xD7:
+ // INST_NAME("FCOMP ST0, STx"); //yep
+ DEFAULT;
+ break;
+ case 0xD9:
+ // INST_NAME("FCOMPP ST0, STx");
+ DEFAULT;
+ break;
+ case 0xE0:
+ case 0xE1:
+ case 0xE2:
+ case 0xE3:
+ case 0xE4:
+ case 0xE5:
+ case 0xE6:
+ case 0xE7:
+ INST_NAME("FSUBRP STx, ST0");
+ v2 = x87_get_st(dyn, ninst, x1, x2, 0, X87_COMBINE(0, nextop&7));
+ v1 = x87_get_st(dyn, ninst, x1, x2, nextop&7, X87_COMBINE(0, nextop&7));
+ if(ST_IS_F(0)) {
+ FSUBS(v1, v2, v1);
+ } else {
+ FSUBD(v1, v2, v1);
+ }
+ x87_do_pop(dyn, ninst, x3);
+ break;
+ case 0xE8:
+ case 0xE9:
+ case 0xEA:
+ case 0xEB:
+ case 0xEC:
+ case 0xED:
+ case 0xEE:
+ case 0xEF:
+ INST_NAME("FSUBP STx, ST0");
+ v2 = x87_get_st(dyn, ninst, x1, x2, 0, X87_COMBINE(0, nextop&7));
+ v1 = x87_get_st(dyn, ninst, x1, x2, nextop&7, X87_COMBINE(0, nextop&7));
+ if(ST_IS_F(0)) {
+ FSUBS(v1, v1, v2);
+ } else {
+ FSUBD(v1, v1, v2);
+ }
+ x87_do_pop(dyn, ninst, x3);
+ break;
+ case 0xF0:
+ case 0xF1:
+ case 0xF2:
+ case 0xF3:
+ case 0xF4:
+ case 0xF5:
+ case 0xF6:
+ case 0xF7:
+ INST_NAME("FDIVRP STx, ST0");
+ v2 = x87_get_st(dyn, ninst, x1, x2, 0, X87_COMBINE(0, nextop&7));
+ v1 = x87_get_st(dyn, ninst, x1, x2, nextop&7, X87_COMBINE(0, nextop&7));
+ if(ST_IS_F(0)) {
+ FDIVS(v1, v2, v1);
+ } else {
+ FDIVD(v1, v2, v1);
+ }
+ x87_do_pop(dyn, ninst, x3);
+ break;
+ case 0xF8:
+ case 0xF9:
+ case 0xFA:
+ case 0xFB:
+ case 0xFC:
+ case 0xFD:
+ case 0xFE:
+ case 0xFF:
+ INST_NAME("FDIVP STx, ST0");
+ v2 = x87_get_st(dyn, ninst, x1, x2, 0, X87_COMBINE(0, nextop&7));
+ v1 = x87_get_st(dyn, ninst, x1, x2, nextop&7, X87_COMBINE(0, nextop&7));
+ if(ST_IS_F(0)) {
+ FDIVS(v1, v1, v2);
+ } else {
+ FDIVD(v1, v1, v2);
+ }
+ x87_do_pop(dyn, ninst, x3);
+ break;
+ case 0xD8:
+ case 0xDA:
+ case 0xDB:
+ case 0xDC:
+ case 0xDD:
+ case 0xDE:
+ case 0xDF:
+ return 0;
+ default:
+ switch((nextop>>3)&7) {
+ default:
+ DEFAULT;
+ }
+ }
+ return addr;
+}
diff --git a/src/dynarec/rv64/dynarec_rv64_df.c b/src/dynarec/rv64/dynarec_rv64_df.c
new file mode 100644
index 0000000..de99b02
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_df.c
@@ -0,0 +1,244 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <stddef.h>
+#include <errno.h>
+
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "emu/x64run_private.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "emu/x64run_private.h"
+#include "x64trace.h"
+#include "emu/x87emu_private.h"
+#include "dynarec_native.h"
+
+#include "rv64_printer.h"
+#include "dynarec_rv64_private.h"
+#include "dynarec_rv64_helper.h"
+#include "dynarec_rv64_functions.h"
+
+uintptr_t dynarec64_DF(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog)
+{
+ (void)ip; (void)rep; (void)need_epilog;
+
+ uint8_t nextop = F8;
+ uint8_t ed, wback, u8;
+ int v1, v2;
+ int s0;
+ int64_t j64;
+ int64_t fixedaddress;
+
+ MAYUSE(s0);
+ MAYUSE(v2);
+ MAYUSE(v1);
+ MAYUSE(j64);
+
+ switch(nextop) {
+ case 0xC0 ... 0xC7:
+ INST_NAME("FFREEP STx");
+ DEFAULT;
+ break;
+
+ case 0xE0:
+ INST_NAME("FNSTSW AX");
+ LHU(x2, xEmu, offsetof(x64emu_t, top));
+ LHU(x1, xEmu, offsetof(x64emu_t, sw));
+ MOV32w(x3, 0b1100011111111111); // mask
+ AND(x1, x1, x3);
+ SLLI(x2, x2, 11);
+ OR(x1, x1, x2); // inject top
+ SH(x1, xEmu, offsetof(x64emu_t, sw));
+ SRLI(xRAX, xRAX, 16);
+ SLLI(xRAX, xRAX, 16);
+ OR(xRAX, xRAX, x1);
+ break;
+ case 0xE8 ... 0xF7:
+ if (nextop < 0xF0) {
+ INST_NAME("FUCOMIP ST0, STx");
+ } else {
+ INST_NAME("FCOMIP ST0, STx");
+ }
+ SETFLAGS(X_ALL, SF_SET);
+ SET_DFNONE();
+ v1 = x87_get_st(dyn, ninst, x1, x2, 0, X87_COMBINE(0, nextop&7));
+ v2 = x87_get_st(dyn, ninst, x1, x2, nextop&7, X87_COMBINE(0, nextop&7));
+ CLEAR_FLAGS();
+ IFX(F_ZF | F_PF | F_CF) {
+ if(ST_IS_F(0)) {
+ FEQS(x5, v1, v1);
+ FEQS(x4, v2, v2);
+ AND(x5, x5, x4);
+ BEQZ(x5, 24); // undefined/NaN
+ FEQS(x5, v1, v2);
+ BNEZ(x5, 24); // equal
+ FLTS(x3, v1, v2); // x3 = (v1<v2)?1:0
+ OR(xFlags, xFlags, x3); // CF is the least significant bit
+ J(16); // end
+ // NaN
+ ORI(xFlags, xFlags, (1<<F_ZF) | (1<<F_PF) | (1<<F_CF));
+ J(8); // end
+ // equal
+ ORI(xFlags, xFlags, 1<<F_ZF);
+ // end
+ } else {
+ FEQD(x5, v1, v1);
+ FEQD(x4, v2, v2);
+ AND(x5, x5, x4);
+ BEQZ(x5, 24); // undefined/NaN
+ FEQD(x5, v1, v2);
+ BNEZ(x5, 24); // equal
+ FLTD(x3, v1, v2); // x3 = (v1<v2)?1:0
+ OR(xFlags, xFlags, x3); // CF is the least significant bit
+ J(16); // end
+ // NaN
+ ORI(xFlags, xFlags, (1<<F_ZF) | (1<<F_PF) | (1<<F_CF));
+ J(8); // end
+ // equal
+ ORI(xFlags, xFlags, 1<<F_ZF);
+ // end
+ }
+ }
+ x87_do_pop(dyn, ninst, x3);
+ break;
+ case 0xC8 ... 0xDF:
+ case 0xE1 ... 0xE7:
+ case 0xF8 ... 0xFF:
+ DEFAULT;
+ break;
+
+ default:
+ switch((nextop>>3)&7) {
+ case 0:
+ INST_NAME("FILD ST0, Ew");
+ v1 = x87_do_push(dyn, ninst, x1, EXT_CACHE_ST_F);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, x4, &fixedaddress, rex, NULL, 1, 0);
+ LH(x1, wback, fixedaddress);
+ if(ST_IS_F(0)) {
+ FCVTSL(v1, x1, RD_RNE);
+ } else {
+ FCVTDL(v1, x1, RD_RNE);
+ }
+ break;
+ case 1:
+ INST_NAME("FISTTP Ew, ST0");
+ v1 = x87_get_st(dyn, ninst, x1, x2, 0, EXT_CACHE_ST_F);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, x4, &fixedaddress, rex, NULL, 1, 0);
+ if(!box64_dynarec_fastround) {
+ FSFLAGSI(0); // reset all bits
+ }
+ FCVTWD(x4, v1, RD_RTZ);
+ if(!box64_dynarec_fastround) {
+ FRFLAGS(x5); // get back FPSR to check the IOC bit
+ ANDI(x5, x5, 1<<FR_NV);
+ BNEZ_MARK(x5);
+ SLLIW(x5, x4, 16);
+ SRAIW(x5, x5, 16);
+ BEQ_MARK2(x5, x4);
+ MARK;
+ MOV32w(x4, 0x8000);
+ }
+ MARK2;
+ SH(x4, wback, fixedaddress);
+ x87_do_pop(dyn, ninst, x3);
+ break;
+ case 3:
+ INST_NAME("FISTP Ew, ST0");
+ v1 = x87_get_st(dyn, ninst, x1, x2, 0, EXT_CACHE_ST_F);
+ u8 = x87_setround(dyn, ninst, x1, x2);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x3, &fixedaddress, rex, NULL, 1, 0);
+ if(!box64_dynarec_fastround) {
+ FSFLAGSI(0); // reset all bits
+ }
+ FCVTWD(x4, v1, RD_DYN);
+ x87_restoreround(dyn, ninst, u8);
+ if(!box64_dynarec_fastround) {
+ FRFLAGS(x5); // get back FPSR to check the IOC bit
+ ANDI(x5, x5, 1<<FR_NV);
+ BNEZ_MARK(x5);
+ SLLIW(x5, x4, 16);
+ SRAIW(x5, x5, 16);
+ BEQ_MARK2(x5, x4);
+ MARK;
+ MOV32w(x4, 0x8000);
+ }
+ MARK2;
+ SH(x4, wback, fixedaddress);
+ x87_do_pop(dyn, ninst, x3);
+ break;
+ case 5:
+ INST_NAME("FILD ST0, i64");
+ v1 = x87_do_push(dyn, ninst, x1, EXT_CACHE_ST_D);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x3, &fixedaddress, rex, NULL, 1, 0);
+ LD(x1, wback, fixedaddress);
+ if (rex.is32bits) {
+ // need to also feed the STll stuff...
+ ADDI(x4, xEmu, offsetof(x64emu_t, fpu_ll));
+ LWU(x5, xEmu, offsetof(x64emu_t, top));
+ int a = 0 - dyn->e.x87stack;
+ if(a) {
+ ADDIW(x5, x5, a);
+ ANDI(x5, x5, 0x7);
+ }
+ SLLI(x5, x5, 4); // fpu_ll is 2 i64
+ ADD(x5, x5, x4);
+ SD(x1, x5, 8); // ll
+ }
+ FCVTDL(v1, x1, RD_RTZ);
+ if(rex.is32bits) {
+ FSD(v1, x5, 0); // ref
+ }
+ break;
+ case 7:
+ INST_NAME("FISTP i64, ST0");
+ v1 = x87_get_st(dyn, ninst, x1, x2, 0, EXT_CACHE_ST_D);
+ u8 = x87_setround(dyn, ninst, x1, x2);
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x3, &fixedaddress, rex, NULL, 1, 0);
+
+ if(rex.is32bits) {
+ // need to check STll first...
+ ADDI(x4, xEmu, offsetof(x64emu_t, fpu_ll));
+ LWU(x5, xEmu, offsetof(x64emu_t, top));
+ int a = 0 - dyn->e.x87stack;
+ if(a) {
+ ADDIW(x5, x5, a);
+ ANDI(x5, x5, 0x7);
+ }
+ SLLI(x5, x5, 4); // fpu_ll is 2 i64
+ ADD(x5, x5, x4);
+ FMVXD(x3, v1);
+ LD(x6, x5, 0); // ref
+ BNE_MARK(x6, x3);
+ LD(x6, x5, 8); // ll
+ SD(x6, wback, fixedaddress);
+ B_MARK3_nocond;
+ MARK;
+ }
+
+ if(!box64_dynarec_fastround) {
+ FSFLAGSI(0); // reset all bits
+ }
+ FCVTLD(x4, v1, RD_DYN);
+ if(!box64_dynarec_fastround) {
+ FRFLAGS(x5); // get back FPSR to check the IOC bit
+ ANDI(x5, x5, 1<<FR_NV);
+ BEQ_MARK2(x5, xZR);
+ MOV64x(x4, 0x8000000000000000LL);
+ }
+ MARK2;
+ SD(x4, wback, fixedaddress);
+ MARK3;
+ x87_restoreround(dyn, ninst, u8);
+ x87_do_pop(dyn, ninst, x3);
+ break;
+ default:
+ DEFAULT;
+ break;
+ }
+ }
+ return addr;
+}
diff --git a/src/dynarec/rv64/dynarec_rv64_emit_logic.c b/src/dynarec/rv64/dynarec_rv64_emit_logic.c
new file mode 100644
index 0000000..1352868
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_emit_logic.c
@@ -0,0 +1,478 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <stddef.h>
+#include <errno.h>
+
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "emu/x64run_private.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "emu/x64run_private.h"
+#include "x64trace.h"
+#include "dynarec_native.h"
+
+#include "rv64_printer.h"
+#include "dynarec_rv64_private.h"
+#include "dynarec_rv64_functions.h"
+#include "dynarec_rv64_helper.h"
+
+// emit XOR8 instruction, from s1, s2, store result in s1 using s3 and s4 as scratch, s4 can be same as s2 (and so s2 destroyed)
+void emit_xor8(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4)
+{
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ SET_DF(s4, d_xor8);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+ XOR(s1, s1, s2);
+ ANDI(s1, s1, 0xff);
+ IFX(X_SF) {
+ SRLI(s3, s1, 7);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ IFX(X_PEND) {
+ SB(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+// emit XOR8 instruction, from s1 , constant c, store result in s1 using s3 and s4 as scratch
+void emit_xor8c(dynarec_rv64_t* dyn, int ninst, int s1, int32_t c, int s3, int s4)
+{
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ SET_DF(s4, d_xor8);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+ XORI(s1, s1, c&0xff);
+ ANDI(s1, s1, 0xff);
+ IFX(X_SF) {
+ SRLI(s3, s1, 7);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ IFX(X_PEND) {
+ SB(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+// emit XOR32 instruction, from s1, s2, store result in s1 using s3 and s4 as scratch
+void emit_xor32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4)
+{
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ SET_DF(s4, rex.w?d_xor64:d_xor32);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+
+ XOR(s1, s1, s2);
+
+ // test sign bit before zeroup.
+ IFX(X_SF) {
+ if (!rex.w) SEXT_W(s1, s1);
+ BGE(s1, xZR, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ if (!rex.w && s1!=s2) {
+ ZEROUP(s1);
+ }
+
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+// emit XOR32 instruction, from s1, c, store result in s1 using s3 and s4 as scratch
+void emit_xor32c(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int64_t c, int s3, int s4)
+{
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ SET_DF(s4, rex.w?d_xor64:d_xor32);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+
+ if(c>=-2048 && c<=2047) {
+ XORI(s1, s1, c);
+ } else {
+ MOV64xw(s3, c);
+ XOR(s1, s1, s3);
+ }
+
+ // test sign bit before zeroup.
+ IFX(X_SF) {
+ if (!rex.w) SEXT_W(s1, s1);
+ BGE(s1, xZR, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ if (!rex.w) {
+ ZEROUP(s1);
+ }
+
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+// emit XOR16 instruction, from s1, s2, store result in s1 using s3 and s4 as scratch, s4 can be same as s2 (and so s2 destroyed)
+void emit_xor16(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5)
+{
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ SET_DF(s4, d_xor16);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+
+ XOR(s1, s1, s2);
+ ZEXTH(s1, s1);
+
+ IFX(X_PEND) {
+ SH(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_ZF | X_SF) {
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_SF) {
+ SRLI(s3, s1, 15);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+// emit OR16 instruction, from s1, s2, store result in s1 using s3 and s4 as scratch, s4 can be same as s2 (and so s2 destroyed)
+void emit_or16(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4) {
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ SET_DF(s3, d_or16);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+
+ OR(s1, s1, s2);
+ ZEXTH(s1, s1);
+ IFX(X_PEND) {
+ SD(s1, xEmu, offsetof(x64emu_t, res));
+ }
+
+ IFX(X_SF) {
+ SRLI(s3, s1, 15);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+// emit OR32 instruction, from s1, s2, store result in s1 using s3 and s4 as scratch
+void emit_or32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4)
+{
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ SET_DF(s4, rex.w?d_or64:d_or32);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+
+ OR(s1, s1, s2);
+
+ // test sign bit before zeroup.
+ IFX(X_SF) {
+ if (!rex.w) SEXT_W(s1, s1);
+ BGE(s1, xZR, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ if (!rex.w) {
+ ZEROUP(s1);
+ }
+
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+// emit OR32 instruction, from s1, c, store result in s1 using s3 and s4 as scratch
+void emit_or32c(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int64_t c, int s3, int s4)
+{
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ SET_DF(s4, rex.w?d_or64:d_or32);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+
+ if(c>=-2048 && c<=2047) {
+ ORI(s1, s1, c);
+ } else {
+ MOV64xw(s3, c);
+ OR(s1, s1, s3);
+ }
+
+ // test sign bit before zeroup.
+ IFX(X_SF) {
+ if (!rex.w) SEXT_W(s1, s1);
+ BGE(s1, xZR, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ if (!rex.w) {
+ ZEROUP(s1);
+ }
+
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+
+// emit AND8 instruction, from s1, s2, store result in s1 using s3 and s4 as scratch, s4 can be same as s2 (and so s2 destroyed)
+void emit_and8(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4)
+{
+
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ SET_DF(s3, d_and8);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+
+ AND(s1, s1, s2);
+
+ IFX(X_PEND) {
+ SB(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_SF) {
+ SRLI(s3, s1, 7);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+
+// emit AND8 instruction, from s1 , constant c, store result in s1 using s3 and s4 as scratch
+void emit_and8c(dynarec_rv64_t* dyn, int ninst, int s1, int32_t c, int s3, int s4)
+{
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ SET_DF(s3, d_and8);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+
+ ANDI(s1, s1, c&0xff);
+
+ IFX(X_PEND) {
+ SD(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_SF) {
+ SRLI(s3, s1, 7);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+void emit_and16(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4) {
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ SET_DF(s3, d_tst16);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+
+ AND(s1, s1, s2); // res = s1 & s2
+
+ IFX(X_PEND) {
+ SH(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_SF) {
+ SRLI(s3, s1, 15);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+// emit AND32 instruction, from s1, s2, store result in s1 using s3 and s4 as scratch
+void emit_and32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4)
+{
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ SET_DF(s3, rex.w?d_tst64:d_tst32);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+
+ AND(s1, s1, s2); // res = s1 & s2
+ if (!rex.w) ZEROUP(s1);
+
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_SF) {
+ SRLI(s3, s1, rex.w?63:31);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+// emit AND32 instruction, from s1, c, store result in s1 using s3 and s4 as scratch
+void emit_and32c(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int64_t c, int s3, int s4)
+{
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ SET_DF(s3, rex.w?d_tst64:d_tst32);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+
+ if(c>=-2048 && c<=2047) {
+ ANDI(s1, s1, c);
+ } else {
+ MOV64xw(s3, c);
+ AND(s1, s1, s3); // res = s1 & s2
+ }
+ if (!rex.w && c<0 && c>=-2048) ZEROUP(s1);
+
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_SF) {
+ SRLI(s3, s1, rex.w?63:31);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+// emit OR8 instruction, from s1, s2, store result in s1 using s3 and s4 as scratch, s4 can be same as s2 (and so s2 destroyed)
+void emit_or8(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4)
+{
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ SET_DF(s3, d_or8);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+
+ OR(s1, s1, s2);
+
+ IFX(X_PEND) {
+ SB(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_SF) {
+ SRLI(s3, s1, 7);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+// emit OR8 instruction, from s1 , constant c, store result in s1 using s3 and s4 as scratch
+void emit_or8c(dynarec_rv64_t* dyn, int ninst, int s1, int32_t c, int s2, int s3, int s4)
+{
+ MOV32w(s2, c&0xff);
+ emit_or8(dyn, ninst, s1, s2, s3, s4);
+}
diff --git a/src/dynarec/rv64/dynarec_rv64_emit_math.c b/src/dynarec/rv64/dynarec_rv64_emit_math.c
new file mode 100644
index 0000000..5d6f7e0
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_emit_math.c
@@ -0,0 +1,1441 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <stddef.h>
+#include <errno.h>
+
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "emu/x64run_private.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "emu/x64run_private.h"
+#include "x64trace.h"
+#include "dynarec_native.h"
+
+#include "rv64_printer.h"
+#include "dynarec_rv64_private.h"
+#include "dynarec_rv64_functions.h"
+#include "dynarec_rv64_helper.h"
+
+// emit ADD32 instruction, from s1, s2, store result in s1 using s3 and s4 as scratch
+void emit_add32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4, int s5)
+{
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, op1));
+ SDxw(s2, xEmu, offsetof(x64emu_t, op2));
+ SET_DF(s3, rex.w?d_add64:d_add32b);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+ IFX(X_CF) {
+ if (rex.w) {
+ AND(s5, xMASK, s1);
+ if(rv64_zba) ADDUW(s5, s2, s5); else {AND(s4, xMASK, s2); ADD(s5, s5, s4);} // lo
+ SRLI(s3, s1, 0x20);
+ SRLI(s4, s2, 0x20);
+ ADD(s4, s4, s3);
+ SRLI(s5, s5, 0x20);
+ ADD(s5, s5, s4); // hi
+ SRAI(s5, s5, 0x20);
+ BEQZ(s5, 8);
+ ORI(xFlags, xFlags, 1 << F_CF);
+ } else {
+ ADD(s5, s1, s2);
+ SRLI(s5, s5, 0x20);
+ BEQZ(s5, 8);
+ ORI(xFlags, xFlags, 1 << F_CF);
+ }
+ }
+ IFX(X_AF | X_OF) {
+ OR(s3, s1, s2); // s3 = op1 | op2
+ AND(s4, s1, s2); // s4 = op1 & op2
+ }
+
+ ADDxw(s1, s1, s2);
+
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_AF | X_OF) {
+ if(rv64_zbb) {
+ ANDN(s3, s1, s3); // s3 = ~res & (op1 | op2)
+ } else {
+ NOT(s5, s1); // s5 = ~res
+ AND(s3, s5, s3); // s3 = ~res & (op1 | op2)
+ }
+ OR(s3, s3, s4); // cc = (~res & (op1 | op2)) | (op1 & op2)
+ IFX(X_AF) {
+ ANDI(s4, s3, 0x08); // AF: cc & 0x08
+ BEQZ(s4, 8);
+ ORI(xFlags, xFlags, 1 << F_AF);
+ }
+ IFX(X_OF) {
+ SRLI(s3, s3, rex.w?62:30);
+ SRLI(s4, s3, 1);
+ XOR(s3, s3, s4);
+ ANDI(s3, s3, 1); // OF: xor of two MSB's of cc
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_OF2);
+ }
+ }
+ IFX(X_SF) {
+ BGE(s1, xZR, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ if (!rex.w) {
+ ZEROUP(s1);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+}
+
+// emit ADD32 instruction, from s1, constant c, store result in s1 using s3 and s4 as scratch
+void emit_add32c(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int64_t c, int s2, int s3, int s4, int s5)
+{
+ CLEAR_FLAGS();
+ if(s1==xRSP && (!dyn->insts || dyn->insts[ninst].x64.gen_flags==X_PEND))
+ {
+ // special case when doing math on ESP and only PEND is needed: ignoring it!
+ if(c >= -2048 && c < 2048) {
+ ADDIxw(s1, s1, c);
+ } else {
+ MOV64xw(s2, c);
+ ADDxw(s1, s1, s2);
+ }
+ return;
+ }
+ IFX(X_PEND | X_AF | X_CF | X_OF) {
+ MOV64xw(s2, c);
+ }
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, op1));
+ SDxw(s2, xEmu, offsetof(x64emu_t, op2));
+ SET_DF(s3, rex.w?d_add64:d_add32b);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+ IFX(X_CF) {
+ if (rex.w) {
+ AND(s5, xMASK, s1);
+ if(rv64_zba) ADDUW(s5, s2, s5); else {AND(s4, xMASK, s2); ADD(s5, s5, s4);} // lo
+ SRLI(s3, s1, 0x20);
+ SRLI(s4, s2, 0x20);
+ ADD(s4, s4, s3);
+ SRLI(s5, s5, 0x20);
+ ADD(s5, s5, s4); // hi
+ SRAI(s5, s5, 0x20);
+ BEQZ(s5, 8);
+ ORI(xFlags, xFlags, 1 << F_CF);
+ } else {
+ ADD(s5, s1, s2);
+ SRLI(s5, s5, 0x20);
+ BEQZ(s5, 8);
+ ORI(xFlags, xFlags, 1 << F_CF);
+ }
+ }
+ IFX(X_AF | X_OF) {
+ OR(s3, s1, s2); // s3 = op1 | op2
+ AND(s4, s1, s2); // s4 = op1 & op2
+ }
+
+ if(c >= -2048 && c < 2048) {
+ ADDIxw(s1, s1, c);
+ } else {
+ IFX(X_PEND | X_AF | X_CF | X_OF) {} else {MOV64xw(s2, c);}
+ ADDxw(s1, s1, s2);
+ }
+
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_AF | X_OF) {
+ if(rv64_zbb) {
+ ANDN(s3, s1, s3); // s3 = ~res & (op1 | op2)
+ } else {
+ NOT(s2, s1); // s2 = ~res
+ AND(s3, s2, s3); // s3 = ~res & (op1 | op2)
+ }
+ OR(s3, s3, s4); // cc = (~res & (op1 | op2)) | (op1 & op2)
+ IFX(X_AF) {
+ ANDI(s4, s3, 0x08); // AF: cc & 0x08
+ BEQZ(s4, 8);
+ ORI(xFlags, xFlags, 1 << F_AF);
+ }
+ IFX(X_OF) {
+ SRLI(s3, s3, rex.w?62:30);
+ SRLI(s4, s3, 1);
+ XOR(s3, s3, s4);
+ ANDI(s3, s3, 1); // OF: xor of two MSB's of cc
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_OF2);
+ }
+ }
+ IFX(X_SF) {
+ BGE(s1, xZR, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ if (!rex.w) {
+ ZEROUP(s1);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+}
+
+// emit ADD16 instruction, from s1, s2, store result in s1 using s3 and s4 as scratch
+void emit_add16(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5)
+{
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ SH(s1, xEmu, offsetof(x64emu_t, op1));
+ SH(s2, xEmu, offsetof(x64emu_t, op2));
+ SET_DF(s3, d_add16);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+ IFX(X_AF | X_OF) {
+ OR(s3, s1, s2); // s3 = op1 | op2
+ AND(s4, s1, s2); // s4 = op1 & op2
+ }
+ ADD(s1, s1, s2);
+
+ IFX(X_PEND) {
+ SW(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_AF | X_OF) {
+ if(rv64_zbb) {
+ ANDN(s3, s1, s3); // s3 = ~res & (op1 | op2)
+ } else {
+ NOT(s5, s1); // s5 = ~res
+ AND(s3, s5, s3); // s3 = ~res & (op1 | op2)
+ }
+ OR(s3, s3, s4); // cc = (~res & (op1 | op2)) | (op1 & op2)
+ IFX(X_AF) {
+ ANDI(s4, s3, 0x08); // AF: cc & 0x08
+ BEQZ(s4, 8);
+ ORI(xFlags, xFlags, 1 << F_AF);
+ }
+ IFX(X_OF) {
+ SRLI(s3, s3, 14);
+ SRLI(s4, s3, 1);
+ XOR(s3, s3, s4);
+ ANDI(s3, s3, 1); // OF: xor of two MSB's of cc
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_OF2);
+ }
+ }
+
+ IFX(X_CF) {
+ SRLI(s3, s1, 16);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_CF);
+ }
+
+ ZEXTH(s1, s1);
+
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_SF) {
+ SRLI(s3, s1, 15);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+// emit ADD8 instruction, from s1, s2, store result in s1 using s3 and s4 as scratch
+void emit_add8(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4)
+{
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ SB(s1, xEmu, offsetof(x64emu_t, op1));
+ SB(s2, xEmu, offsetof(x64emu_t, op2));
+ SET_DF(s3, d_add8);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+ IFX(X_AF | X_OF) {
+ OR(s3, s1, s2); // s3 = op1 | op2
+ AND(s4, s1, s2); // s4 = op1 & op2
+ }
+ ADD(s1, s1, s2);
+
+ IFX(X_AF|X_OF) {
+ if(rv64_zbb) {
+ ANDN(s3, s1, s3); // s3 = ~res & (op1 | op2)
+ } else {
+ NOT(s4, s1); // s4 = ~res
+ AND(s3, s4, s3); // s3 = ~res & (op1 | op2)
+ }
+ OR(s3, s3, s2); // cc = (~res & (op1 | op2)) | (op1 & op2)
+ IFX(X_AF) {
+ ANDI(s4, s3, 0x08); // AF: cc & 0x08
+ BEQZ(s4, 8);
+ ORI(xFlags, xFlags, 1 << F_AF);
+ }
+ IFX(X_OF) {
+ SRLI(s3, s3, 6);
+ SRLI(s4, s3, 1);
+ XOR(s3, s3, s4);
+ ANDI(s3, s3, 1); // OF: xor of two MSB's of cc
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_OF2);
+ }
+ }
+ IFX(X_CF) {
+ SRLI(s3, s1, 8);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_CF);
+ }
+ IFX(X_PEND) {
+ SH(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ ANDI(s1, s1, 0xff);
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_SF) {
+ SRLI(s3, s1, 7);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+// emit ADD8 instruction, from s1, const c, store result in s1 using s3 and s4 as scratch
+void emit_add8c(dynarec_rv64_t* dyn, int ninst, int s1, int c, int s2, int s3, int s4)
+{
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ MOV32w(s4, c&0xff);
+ SB(s1, xEmu, offsetof(x64emu_t, op1));
+ SB(s4, xEmu, offsetof(x64emu_t, op2));
+ SET_DF(s3, d_add8);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+ IFX(X_AF | X_OF) {
+ if(X_PEND) {} else {MOV32w(s4, c&0xff);}
+ OR(s3, s1, s4); // s3 = op1 | op2
+ AND(s4, s1, s4); // s4 = op1 & op2
+ }
+ ADDI(s1, s1, c);
+
+ IFX(X_AF|X_OF) {
+ if(rv64_zbb) {
+ ANDN(s3, s1, s3); // s3 = ~res & (op1 | op2)
+ } else {
+ NOT(s2, s1); // s2 = ~res
+ AND(s3, s2, s3); // s3 = ~res & (op1 | op2)
+ }
+ OR(s3, s3, s4); // cc = (~res & (op1 | op2)) | (op1 & op2)
+ IFX(X_AF) {
+ ANDI(s4, s3, 0x08); // AF: cc & 0x08
+ BEQZ(s4, 8);
+ ORI(xFlags, xFlags, 1 << F_AF);
+ }
+ IFX(X_OF) {
+ SRLI(s3, s3, 6);
+ SRLI(s4, s3, 1);
+ XOR(s3, s3, s4);
+ ANDI(s3, s3, 1); // OF: xor of two MSB's of cc
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_OF2);
+ }
+ }
+ IFX(X_CF) {
+ SRLI(s3, s1, 8);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_CF);
+ }
+ IFX(X_PEND) {
+ SH(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ ANDI(s1, s1, 0xff);
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_SF) {
+ SRLI(s3, s1, 7);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+// emit SUB8 instruction, from s1, s2, store result in s1 using s3 and s4 as scratch
+void emit_sub8(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5)
+{
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ SB(s1, xEmu, offsetof(x64emu_t, op1));
+ SB(s2, xEmu, offsetof(x64emu_t, op2));
+ SET_DF(s3, d_sub8);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+
+ IFX(X_AF | X_CF | X_OF) {
+ // for later flag calculation
+ NOT(s5, s1);
+ }
+
+ SUB(s1, s1, s2);
+ ANDI(s1, s1, 0xff);
+ IFX(X_SF) {
+ SRLI(s3, s1, 7);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ IFX(X_PEND) {
+ SB(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ CALC_SUB_FLAGS(s5, s2, s1, s3, s4, 8);
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+// emit SUB8 instruction, from s1, constant c, store result in s1 using s3 and s4 as scratch
+void emit_sub8c(dynarec_rv64_t* dyn, int ninst, int s1, int c, int s2, int s3, int s4, int s5)
+{
+ MOV32w(s2, c&0xff);
+ emit_sub8(dyn, ninst, s1, s2, s3, s4, s5);
+}
+
+// emit SUB16 instruction, from s1, s2, store result in s1 using s3 and s4 as scratch
+void emit_sub16(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5)
+{
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ SH(s1, xEmu, offsetof(x64emu_t, op1));
+ SH(s2, xEmu, offsetof(x64emu_t, op2));
+ SET_DF(s3, d_sub16);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+
+ IFX(X_AF | X_CF | X_OF) {
+ // for later flag calculation
+ NOT(s5, s1);
+ }
+
+ SUBW(s1, s1, s2);
+ IFX(X_PEND) {
+ SH(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ SLLI(s1, s1, 48);
+ IFX(X_SF) {
+ BGE(s1, xZR, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ SRLI(s1, s1, 48);
+
+ CALC_SUB_FLAGS(s5, s2, s1, s3, s4, 16);
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+
+// emit SUB32 instruction, from s1, s2, store result in s1 using s3 and s4 as scratch
+void emit_sub32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4, int s5)
+{
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, op1));
+ SDxw(s2, xEmu, offsetof(x64emu_t, op2));
+ SET_DF(s3, rex.w?d_sub64:d_sub32);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+
+ IFX(X_AF | X_CF | X_OF) {
+ // for later flag calculation
+ NOT(s5, s1);
+ }
+
+ SUBxw(s1, s1, s2);
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_SF) {
+ BGE(s1, xZR, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ if (!rex.w) {
+ ZEROUP(s1);
+ }
+ CALC_SUB_FLAGS(s5, s2, s1, s3, s4, rex.w?64:32);
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+
+// emit SUB32 instruction, from s1, constant c, store result in s1 using s2, s3, s4 and s5 as scratch
+void emit_sub32c(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int64_t c, int s2, int s3, int s4, int s5)
+{
+ CLEAR_FLAGS();
+ if(s1==xRSP && (!dyn->insts || dyn->insts[ninst].x64.gen_flags==X_PEND))
+ {
+ // special case when doing math on RSP and only PEND is needed: ignoring it!
+ if (c > -2048 && c <= 2048) {
+ SUBI(s1, s1, c);
+ } else {
+ MOV64xw(s2, c);
+ SUBxw(s1, s1, s2);
+ }
+ return;
+ }
+
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, op1));
+ MOV64xw(s2, c);
+ SDxw(s2, xEmu, offsetof(x64emu_t, op2));
+ SET_DF(s3, rex.w?d_sub64:d_sub32);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+
+ IFX(X_AF | X_CF | X_OF) {
+ // for later flag calculation
+ NOT(s5, s1);
+ }
+
+ if (c > -2048 && c <= 2048) {
+ ADDIxw(s1, s1, -c);
+ } else {
+ IFX(X_PEND) {} else {MOV64xw(s2, c);}
+ SUBxw(s1, s1, s2);
+ }
+
+ IFX(X_AF | X_CF | X_OF) {
+ IFX(X_PEND) {}
+ else if (c > -2048 && c <= 2048) {
+ MOV64xw(s2, c);
+ }
+ }
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_SF) {
+ BGE(s1, xZR, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ if (!rex.w) {
+ ZEROUP(s1);
+ }
+ CALC_SUB_FLAGS(s5, s2, s1, s3, s4, rex.w?64:32);
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+// emit INC8 instruction, from s1, store result in s1 using s2, s3 and s4 as scratch
+void emit_inc8(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4)
+{
+ IFX(X_ALL) {
+ ANDI(xFlags, xFlags, ~((1UL<<F_AF) | (1UL<<F_OF2) | (1UL<<F_ZF) | (1UL<<F_SF) | (1UL<<F_PF)));
+ }
+ IFX(X_PEND) {
+ SB(s1, xEmu, offsetof(x64emu_t, op1));
+ SET_DF(s3, d_inc8);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+ IFX(X_AF | X_OF) {
+ ORI(s3, s1, 1); // s3 = op1 | op2
+ ANDI(s4, s1, 1); // s5 = op1 & op2
+ }
+
+ ADDIW(s1, s1, 1);
+
+ IFX(X_PEND) {
+ SB(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_AF | X_OF) {
+ if(rv64_zbb) {
+ ANDN(s3, s1, s3); // s3 = ~res & (op1 | op2)
+ } else {
+ NOT(s2, s1); // s2 = ~res
+ AND(s3, s2, s3); // s3 = ~res & (op1 | op2)
+ }
+ OR(s3, s3, s4); // cc = (~res & (op1 | op2)) | (op1 & op2)
+ IFX(X_AF) {
+ ANDI(s2, s3, 0x08); // AF: cc & 0x08
+ BEQZ(s2, 8);
+ ORI(xFlags, xFlags, 1 << F_AF);
+ }
+ IFX(X_OF) {
+ SRLI(s3, s3, 6);
+ SRLI(s2, s3, 1);
+ XOR(s3, s3, s2);
+ ANDI(s3, s3, 1); // OF: xor of two MSB's of cc
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_OF2);
+ }
+ }
+ IFX(X_SF) {
+ BGE(s1, xZR, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ ANDI(s1, s1, 0xff);
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s2);
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+}
+
+
+// emit DEC8 instruction, from s1, store result in s1 using s2, s3 and s4 as scratch
+void emit_dec8(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4)
+{
+ IFX(X_ALL) {
+ ANDI(xFlags, xFlags, ~((1UL<<F_AF) | (1UL<<F_OF2) | (1UL<<F_ZF) | (1UL<<F_SF) | (1UL<<F_PF)));
+ }
+ IFX(X_PEND) {
+ SB(s1, xEmu, offsetof(x64emu_t, op1));
+ SET_DF(s3, d_dec8);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+ IFX(X_AF | X_OF) {
+ NOT(s4, s1); // s4 = ~op1
+ ORI(s3, s4, 1); // s3 = ~op1 | op2
+ ANDI(s4, s4, 1); // s4 = ~op1 & op2
+ }
+
+ ADDIW(s1, s1, -1);
+
+ IFX(X_PEND) {
+ SB(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_AF | X_OF) {
+ AND(s3, s1, s3); // s3 = res & (~op1 | op2)
+ OR(s3, s3, s4); // cc = (res & (~op1 | op2)) | (~op1 & op2)
+ IFX(X_AF) {
+ ANDI(s2, s3, 0x08); // AF: cc & 0x08
+ BEQZ(s2, 8);
+ ORI(xFlags, xFlags, 1 << F_AF);
+ }
+ IFX(X_OF) {
+ SRLI(s3, s3, 6);
+ SRLI(s2, s3, 1);
+ XOR(s3, s3, s2);
+ ANDI(s3, s3, 1); // OF: xor of two MSB's of cc
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_OF2);
+ }
+ }
+ IFX(X_SF) {
+ BGE(s1, xZR, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ ANDI(s1, s1, 0xff);
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s2);
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+}
+
+// emit INC32 instruction, from s1, store result in s1 using s3 and s4 as scratch
+void emit_inc32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4, int s5)
+{
+ IFX(X_ALL) {
+ ANDI(xFlags, xFlags, ~((1UL<<F_AF) | (1UL<<F_OF2) | (1UL<<F_ZF) | (1UL<<F_SF) | (1UL<<F_PF)));
+ }
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, op1));
+ SET_DF(s3, rex.w?d_inc64:d_inc32);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+ IFX(X_AF | X_OF) {
+ ORI(s3, s1, 1); // s3 = op1 | op2
+ ANDI(s5, s1, 1); // s5 = op1 & op2
+ }
+
+ ADDIxw(s1, s1, 1);
+
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_AF | X_OF) {
+ if(rv64_zbb) {
+ ANDN(s3, s1, s3); // s3 = ~res & (op1 | op2)
+ } else {
+ NOT(s2, s1); // s2 = ~res
+ AND(s3, s2, s3); // s3 = ~res & (op1 | op2)
+ }
+ OR(s3, s3, s5); // cc = (~res & (op1 | op2)) | (op1 & op2)
+ IFX(X_AF) {
+ ANDI(s2, s3, 0x08); // AF: cc & 0x08
+ BEQZ(s2, 8);
+ ORI(xFlags, xFlags, 1 << F_AF);
+ }
+ IFX(X_OF) {
+ SRLI(s3, s3, rex.w?62:30);
+ SRLI(s2, s3, 1);
+ XOR(s3, s3, s2);
+ ANDI(s3, s3, 1); // OF: xor of two MSB's of cc
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_OF2);
+ }
+ }
+ IFX(X_SF) {
+ BGE(s1, xZR, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ if (!rex.w) {
+ ZEROUP(s1);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s2);
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+}
+
+// emit DEC32 instruction, from s1, store result in s1 using s3 and s4 as scratch
+void emit_dec32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4, int s5)
+{
+ IFX(X_ALL) {
+ ANDI(xFlags, xFlags, ~((1UL<<F_AF) | (1UL<<F_OF2) | (1UL<<F_ZF) | (1UL<<F_SF) | (1UL<<F_PF)));
+ }
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, op1));
+ SET_DF(s3, rex.w?d_dec64:d_dec32);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+ IFX(X_AF | X_OF) {
+ NOT(s5, s1);
+ ORI(s3, s5, 1); // s3 = ~op1 | op2
+ ANDI(s5, s5, 1); // s5 = ~op1 & op2
+ }
+
+ ADDIxw(s1, s1, -1);
+
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_AF | X_OF) {
+ AND(s3, s1, s3); // s3 = res & (~op1 | op2)
+ OR(s3, s3, s5); // cc = (res & (~op1 | op2)) | (~op1 & op2)
+ IFX(X_AF) {
+ ANDI(s2, s3, 0x08); // AF: cc & 0x08
+ BEQZ(s2, 8);
+ ORI(xFlags, xFlags, 1 << F_AF);
+ }
+ IFX(X_OF) {
+ SRLI(s3, s3, rex.w?62:30);
+ SRLI(s2, s3, 1);
+ XOR(s3, s3, s2);
+ ANDI(s3, s3, 1); // OF: xor of two MSB's of cc
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_OF2);
+ }
+ }
+ IFX(X_SF) {
+ BGE(s1, xZR, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ if (!rex.w) {
+ ZEROUP(s1);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s2);
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+}
+
+// emit INC16 instruction, from s1, store result in s1 using s3 and s4 as scratch
+void emit_inc16(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4)
+{
+ IFX(X_ALL) {
+ ANDI(xFlags, xFlags, ~((1UL<<F_AF) | (1UL<<F_OF2) | (1UL<<F_ZF) | (1UL<<F_SF) | (1UL<<F_PF)));
+ }
+ IFX(X_PEND) {
+ SH(s1, xEmu, offsetof(x64emu_t, op1));
+ SET_DF(s3, d_inc16);
+ } else IFX(X_ZF|X_OF|X_AF|X_SF|X_PF) {
+ SET_DFNONE();
+ }
+ IFX(X_AF | X_OF) {
+ ORI(s3, s1, 1); // s3 = op1 | op2
+ ANDI(s4, s1, 1); // s4 = op1 & op2
+ }
+
+ ADDI(s1, s1, 1);
+
+ IFX(X_PEND) {
+ SH(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_AF | X_OF) {
+ if(rv64_zbb) {
+ ANDN(s3, s1, s3); // s3 = ~res & (op1 | op2)
+ } else {
+ NOT(s2, s1); // s2 = ~res
+ AND(s3, s2, s3); // s3 = ~res & (op1 | op2)
+ }
+ OR(s3, s3, s4); // cc = (~res & (op1 | op2)) | (op1 & op2)
+ IFX(X_AF) {
+ ANDI(s4, s3, 0x08); // AF: cc & 0x08
+ BEQZ(s4, 8);
+ ORI(xFlags, xFlags, 1 << F_AF);
+ }
+ IFX(X_OF) {
+ SRLI(s3, s3, 14);
+ SRLI(s4, s3, 1);
+ XOR(s3, s3, s4);
+ ANDI(s3, s3, 1); // OF: xor of two MSB's of cc
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_OF2);
+ }
+ }
+
+ ZEXTH(s1, s1);
+
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_SF) {
+ SRLI(s3, s1, 15);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+// emit DEC16 instruction, from s1, store result in s1 using s3 and s4 as scratch
+void emit_dec16(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5)
+{
+ IFX(X_ALL) {
+ ANDI(xFlags, xFlags, ~((1UL<<F_AF) | (1UL<<F_OF2) | (1UL<<F_ZF) | (1UL<<F_SF) | (1UL<<F_PF)));
+ }
+ IFX(X_PEND) {
+ SH(s1, xEmu, offsetof(x64emu_t, op1));
+ SET_DF(s3, d_dec16);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+ IFX(X_AF | X_OF) {
+ NOT(s5, s1);
+ ORI(s3, s5, 1); // s3 = ~op1 | op2
+ ANDI(s5, s5, 1); // s5 = ~op1 & op2
+ }
+
+ ADDIW(s1, s1, -1);
+
+ IFX(X_PEND) {
+ SH(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_AF | X_OF) {
+ AND(s3, s1, s3); // s3 = res & (~op1 | op2)
+ OR(s3, s3, s5); // cc = (res & (~op1 | op2)) | (~op1 & op2)
+ IFX(X_AF) {
+ ANDI(s2, s3, 0x08); // AF: cc & 0x08
+ BEQZ(s2, 8);
+ ORI(xFlags, xFlags, 1 << F_AF);
+ }
+ IFX(X_OF) {
+ SRLI(s3, s3, 14);
+ SRLI(s2, s3, 1);
+ XOR(s3, s3, s2);
+ ANDI(s3, s3, 1); // OF: xor of two MSB's of cc
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_OF2);
+ }
+ }
+ SLLIW(s1, s1, 16);
+ IFX(X_SF) {
+ BGE(s1, xZR, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ SRLIW(s1, s1, 16);
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s2);
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+}
+
+// emit SBB8 instruction, from s1, s2, store result in s1 using s3, s4 and s5 as scratch
+void emit_sbb8(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5)
+{
+ IFX(X_PEND) {
+ SB(s1, xEmu, offsetof(x64emu_t, op1));
+ SB(s2, xEmu, offsetof(x64emu_t, op2));
+ SET_DF(s3, d_sbb8);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+
+ IFX(X_AF | X_CF | X_OF) {
+ // for later flag calculation
+ NOT(s5, s1);
+ }
+
+ SUBW(s1, s1, s2);
+ ANDI(s3, xFlags, 1 << F_CF);
+ SUBW(s1, s1, s3);
+ ANDI(s1, s1, 0xff);
+
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ SB(s1, xEmu, offsetof(x64emu_t, res));
+ }
+
+ CALC_SUB_FLAGS(s5, s2, s1, s3, s4, 8);
+ IFX(X_SF) {
+ SRLI(s3, s1, 7);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+// emit ADC8 instruction, from s1, s2, store result in s1 using s3 and s4 as scratch
+void emit_adc8(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5) {
+ IFX(X_PEND) {
+ SH(s1, xEmu, offsetof(x64emu_t, op1));
+ SH(s2, xEmu, offsetof(x64emu_t, op2));
+ SET_DF(s3, d_adc8);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+ IFX(X_AF | X_OF) {
+ OR(s4, s1, s2); // s3 = op1 | op2
+ AND(s5, s1, s2); // s4 = op1 & op2
+ }
+
+ ADD(s1, s1, s2);
+ ANDI(s3, xFlags, 1 << F_CF);
+ ADD(s1, s1, s3);
+
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ SW(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_AF | X_OF) {
+ if(rv64_zbb) {
+ ANDN(s3, s1, s4); // s3 = ~res & (op1 | op2)
+ } else {
+ NOT(s2, s1); // s2 = ~res
+ AND(s3, s2, s4); // s3 = ~res & (op1 | op2)
+ }
+ OR(s3, s3, s5); // cc = (~res & (op1 | op2)) | (op1 & op2)
+ IFX(X_AF) {
+ ANDI(s4, s3, 0x08); // AF: cc & 0x08
+ BEQZ(s4, 8);
+ ORI(xFlags, xFlags, 1 << F_AF);
+ }
+ IFX(X_OF) {
+ SRLI(s3, s3, 6);
+ SRLI(s4, s3, 1);
+ XOR(s3, s3, s4);
+ ANDI(s3, s3, 1); // OF: xor of two MSB's of cc
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_OF2);
+ }
+ }
+ IFX(X_CF) {
+ SRLI(s3, s1, 8);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_CF);
+ }
+
+ ANDI(s1, s1, 0xff);
+
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_SF) {
+ SRLI(s3, s1, 7);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+// emit ADC8 instruction, from s1, const c, store result in s1 using s3, s4, s5 and s6 as scratch
+void emit_adc8c(dynarec_rv64_t* dyn, int ninst, int s1, int32_t c, int s3, int s4, int s5, int s6) {
+ MOV32w(s5, c&0xff);
+ emit_adc8(dyn, ninst, s1, s5, s3, s4, s6);
+}
+
+// emit SBB8 instruction, from s1, constant c, store result in s1 using s3, s4, s5 and s6 as scratch
+void emit_sbb8c(dynarec_rv64_t* dyn, int ninst, int s1, int c, int s3, int s4, int s5, int s6)
+{
+ MOV32w(s6, c&0xff);
+ emit_sbb8(dyn, ninst, s1, s6, s3, s4, s5);
+}
+
+// emit SBB16 instruction, from s1, s2, store result in s1 using s3, s4 and s5 as scratch
+void emit_sbb16(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5)
+{
+ IFX(X_PEND) {
+ SH(s1, xEmu, offsetof(x64emu_t, op1));
+ SH(s2, xEmu, offsetof(x64emu_t, op2));
+ SET_DF(s3, d_sbb16);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+
+ IFX(X_AF | X_CF | X_OF) {
+ // for later flag calculation
+ NOT(s5, s1);
+ }
+
+ SUBW(s1, s1, s2);
+ ANDI(s3, xFlags, 1 << F_CF);
+ SUBW(s1, s1, s3);
+
+ CLEAR_FLAGS();
+ SLLIW(s1, s1, 16);
+ IFX(X_SF) {
+ BGE(s1, xZR, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ SRLIW(s1, s1, 16);
+
+ IFX(X_PEND) {
+ SH(s1, xEmu, offsetof(x64emu_t, res));
+ }
+
+ CALC_SUB_FLAGS(s5, s2, s1, s3, s4, 16);
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+// emit SBB32 instruction, from s1, s2, store result in s1 using s3, s4 and s5 as scratch
+void emit_sbb32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4, int s5)
+{
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, op1));
+ SDxw(s2, xEmu, offsetof(x64emu_t, op2));
+ SET_DF(s3, rex.w?d_sbb64:d_sbb32);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+
+ IFX(X_AF | X_CF | X_OF) {
+ // for later flag calculation
+ NOT(s5, s1);
+ }
+
+ SUBxw(s1, s1, s2);
+ ANDI(s3, xFlags, 1 << F_CF);
+ SUBxw(s1, s1, s3);
+
+ CLEAR_FLAGS();
+ IFX(X_SF) {
+ BGE(s1, xZR, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ if (!rex.w) {
+ ZEROUP(s1);
+ }
+
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+
+ CALC_SUB_FLAGS(s5, s2, s1, s3, s4, rex.w?64:32);
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+// emit NEG32 instruction, from s1, store result in s1 using s2 and s3 as scratch
+void emit_neg32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3)
+{
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, op1));
+ SET_DF(s3, rex.w?d_neg64:d_neg32);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+ IFX(X_AF | X_OF) {
+ MV(s3, s1); // s3 = op1
+ }
+
+ NEGxw(s1, s1);
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+
+ IFX(X_CF) {
+ BEQZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_CF);
+ }
+
+ IFX(X_AF | X_OF) {
+ OR(s3, s1, s3); // s3 = res | op1
+ IFX(X_AF) {
+ /* af = bc & 0x8 */
+ ANDI(s2, s3, 8);
+ BEQZ(s2, 8);
+ ORI(xFlags, xFlags, 1 << F_AF);
+ }
+ IFX(X_OF) {
+ /* of = ((bc >> (width-2)) ^ (bc >> (width-1))) & 0x1; */
+ SRLI(s2, s3, (rex.w?64:32)-2);
+ SRLI(s3, s2, 1);
+ XOR(s2, s2, s3);
+ ANDI(s2, s2, 1);
+ BEQZ(s2, 8);
+ ORI(xFlags, xFlags, 1 << F_OF2);
+ }
+ }
+ IFX(X_SF) {
+ BGE(s1, xZR, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ if (!rex.w) {
+ ZEROUP(s1);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s2);
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+}
+
+// emit NEG16 instruction, from s1, store result in s1 using s2 and s3 as scratch
+void emit_neg16(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3)
+{
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ SH(s1, xEmu, offsetof(x64emu_t, op1));
+ SET_DF(s3, d_neg16);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+ IFX(X_AF | X_OF) {
+ MV(s3, s1); // s3 = op1
+ }
+
+ NEG(s1, s1);
+ ZEXTH(s1, s1);
+ IFX(X_PEND) {
+ SH(s1, xEmu, offsetof(x64emu_t, res));
+ }
+
+ IFX(X_CF) {
+ BEQZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_CF);
+ }
+
+ IFX(X_AF | X_OF) {
+ OR(s3, s1, s3); // s3 = res | op1
+ IFX(X_AF) {
+ /* af = bc & 0x8 */
+ ANDI(s2, s3, 8);
+ BEQZ(s2, 8);
+ ORI(xFlags, xFlags, 1 << F_AF);
+ }
+ IFX(X_OF) {
+ /* of = ((bc >> (width-2)) ^ (bc >> (width-1))) & 0x1; */
+ SRLI(s2, s3, 14);
+ SRLI(s3, s2, 1);
+ XOR(s2, s2, s3);
+ ANDI(s2, s2, 1);
+ BEQZ(s2, 8);
+ ORI(xFlags, xFlags, 1 << F_OF2);
+ }
+ }
+ IFX(X_SF) {
+ SRLI(s3, s1, 15-F_SF); // put sign bit in place
+ ANDI(s3, s3, 1 << F_SF); // 1<<F_SF is sign bit, so just mask
+ OR(xFlags, xFlags, s3);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s2);
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+}
+
+// emit NEG8 instruction, from s1, store result in s1 using s2 and s3 as scratch
+void emit_neg8(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3)
+{
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ SB(s1, xEmu, offsetof(x64emu_t, op1));
+ SET_DF(s3, d_neg8);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+ IFX(X_AF | X_OF) {
+ MV(s3, s1); // s3 = op1
+ }
+
+ NEG(s1, s1);
+ ANDI(s1, s1, 0xff);
+ IFX(X_PEND) {
+ SB(s1, xEmu, offsetof(x64emu_t, res));
+ }
+
+ IFX(X_CF) {
+ BEQZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_CF);
+ }
+
+ IFX(X_AF | X_OF) {
+ OR(s3, s1, s3); // s3 = res | op1
+ IFX(X_AF) {
+ /* af = bc & 0x8 */
+ ANDI(s2, s3, 8);
+ BEQZ(s2, 8);
+ ORI(xFlags, xFlags, 1 << F_AF);
+ }
+ IFX(X_OF) {
+ /* of = ((bc >> (width-2)) ^ (bc >> (width-1))) & 0x1; */
+ SRLI(s2, s3, 6);
+ SRLI(s3, s2, 1);
+ XOR(s2, s2, s3);
+ ANDI(s2, s2, 1);
+ BEQZ(s2, 8);
+ ORI(xFlags, xFlags, 1 << F_OF2);
+ }
+ }
+ IFX(X_SF) {
+ ANDI(s3, s1, 1 << F_SF); // 1<<F_SF is sign bit, so just mask
+ OR(xFlags, xFlags, s3);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s2);
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+}
+
+// emit ADC16 instruction, from s1, s2, store result in s1 using s3 and s4 as scratch
+void emit_adc16(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5)
+{
+ IFX(X_PEND) {
+ SH(s1, xEmu, offsetof(x64emu_t, op1));
+ SH(s2, xEmu, offsetof(x64emu_t, op2));
+ SET_DF(s3, d_adc16);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+ IFX(X_AF | X_OF) {
+ OR(s4, s1, s2); // s3 = op1 | op2
+ AND(s5, s1, s2); // s4 = op1 & op2
+ }
+
+ ADD(s1, s1, s2);
+ ANDI(s3, xFlags, 1 << F_CF);
+ ADD(s1, s1, s3);
+
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ SW(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_AF | X_OF) {
+ if(rv64_zbb) {
+ ANDN(s3, s1, s4); // s3 = ~res & (op1 | op2)
+ } else {
+ NOT(s2, s1); // s2 = ~res
+ AND(s3, s2, s4); // s3 = ~res & (op1 | op2)
+ }
+ OR(s3, s3, s5); // cc = (~res & (op1 | op2)) | (op1 & op2)
+ IFX(X_AF) {
+ ANDI(s4, s3, 0x08); // AF: cc & 0x08
+ BEQZ(s4, 8);
+ ORI(xFlags, xFlags, 1 << F_AF);
+ }
+ IFX(X_OF) {
+ SRLI(s3, s3, 14);
+ SRLI(s4, s3, 1);
+ XOR(s3, s3, s4);
+ ANDI(s3, s3, 1); // OF: xor of two MSB's of cc
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_OF2);
+ }
+ }
+ IFX(X_CF) {
+ SRLI(s3, s1, 16);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_CF);
+ }
+
+ ZEXTH(s1, s1);
+
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_SF) {
+ SRLI(s3, s1, 15);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+// emit ADC32 instruction, from s1, s2, store result in s1 using s3 and s4 as scratch
+void emit_adc32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4, int s5, int s6)
+{
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, op1));
+ SDxw(s2, xEmu, offsetof(x64emu_t, op2));
+ SET_DF(s3, rex.w?d_adc64:d_adc32b);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+ IFX(X_CF) {
+ if (rex.w) {
+ AND(s5, xMASK, s1);
+ if(rv64_zba) ADDUW(s5, s2, s5); else {AND(s4, xMASK, s2); ADD(s5, s5, s4);} // lo
+ SRLI(s3, s1, 0x20);
+ SRLI(s4, s2, 0x20);
+ ADD(s4, s4, s3);
+ SRLI(s5, s5, 0x20);
+ ADD(s5, s5, s4); // hi
+ SRAI(s6, s5, 0x20);
+ } else {
+ ADD(s5, s1, s2);
+ SRLI(s6, s5, 0x20);
+ }
+ }
+ IFX(X_AF | X_OF) {
+ OR(s4, s1, s2); // s3 = op1 | op2
+ AND(s5, s1, s2); // s4 = op1 & op2
+ }
+
+ ADDxw(s1, s1, s2);
+ ANDI(s3, xFlags, 1 << F_CF);
+ ADDxw(s1, s1, s3);
+
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_CF) {
+ BEQZ(s6, 8);
+ ORI(xFlags, xFlags, 1 << F_CF);
+ }
+ IFX(X_AF | X_OF) {
+ if(rv64_zbb) {
+ ANDN(s3, s1, s4); // s3 = ~res & (op1 | op2)
+ } else {
+ NOT(s2, s1); // s2 = ~res
+ AND(s3, s2, s4); // s3 = ~res & (op1 | op2)
+ }
+ OR(s3, s3, s5); // cc = (~res & (op1 | op2)) | (op1 & op2)
+ IFX(X_AF) {
+ ANDI(s4, s3, 0x08); // AF: cc & 0x08
+ BEQZ(s4, 8);
+ ORI(xFlags, xFlags, 1 << F_AF);
+ }
+ IFX(X_OF) {
+ SRLI(s3, s3, rex.w?62:30);
+ SRLI(s4, s3, 1);
+ XOR(s3, s3, s4);
+ ANDI(s3, s3, 1); // OF: xor of two MSB's of cc
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_OF2);
+ }
+ }
+ IFX(X_SF) {
+ BGE(s1, xZR, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ if (!rex.w) {
+ ZEROUP(s1);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+}
diff --git a/src/dynarec/rv64/dynarec_rv64_emit_shift.c b/src/dynarec/rv64/dynarec_rv64_emit_shift.c
new file mode 100644
index 0000000..7030c67
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_emit_shift.c
@@ -0,0 +1,618 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <stddef.h>
+#include <errno.h>
+
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "emu/x64run_private.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "emu/x64run_private.h"
+#include "x64trace.h"
+#include "dynarec_native.h"
+
+#include "rv64_printer.h"
+#include "dynarec_rv64_private.h"
+#include "dynarec_rv64_functions.h"
+#include "dynarec_rv64_helper.h"
+
+// emit SHL32 instruction, from s1 , shift s2, store result in s1 using s3, s4 and s5 as scratch
+void emit_shl32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4, int s5)
+{
+ // s2 is not 0 here and is 1..1f/3f
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, op1));
+ SDxw(s2, xEmu, offsetof(x64emu_t, op2));
+ SET_DF(s4, rex.w?d_shl64:d_shl32);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+
+ IFX(X_CF|X_OF) {
+ SUBI(s5, s2, rex.w?64:32);
+ NEG(s5, s5);
+ SRL(s3, s1, s5);
+ ANDI(s5, s3, 1); // F_CF
+ IFX(X_CF) {
+ OR(xFlags, xFlags, s5);
+ }
+ }
+
+ SLL(s1, s1, s2);
+
+ IFX(X_SF) {
+ BGE(s1, xZR, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ if (!rex.w) {
+ ZEROUP(s1);
+ }
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_OF) {
+ SRLIxw(s3, s1, rex.w?63:31);
+ XOR(s3, s3, s5);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_OF2);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+// emit SHL32 instruction, from s1 , constant c, store result in s1 using s3, s4 and s5 as scratch
+void emit_shl32c(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, uint32_t c, int s3, int s4, int s5)
+{
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ if (c) {
+ MOV64x(s3, c);
+ SDxw(s3, xEmu, offsetof(x64emu_t, op2));
+ } else SDxw(xZR, xEmu, offsetof(x64emu_t, op2));
+ SDxw(s1, xEmu, offsetof(x64emu_t, op1));
+ SET_DF(s4, rex.w?d_shl64:d_shl32);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+
+ if(!c) {
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ return;
+ }
+ IFX(X_CF|X_OF) {
+ if (c > 0) {
+ SRLI(s3, s1, (rex.w?64:32)-c);
+ ANDI(s5, s3, 1); // F_CF
+ IFX(X_CF) {
+ OR(xFlags, xFlags, s5);
+ }
+ } else {
+ IFX(X_OF) MOV64x(s5, 0);
+ }
+ }
+
+ SLLIxw(s1, s1, c);
+
+ IFX(X_SF) {
+ BGE(s1, xZR, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ if (!rex.w) {
+ ZEROUP(s1);
+ }
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_OF) {
+ SRLIxw(s3, s1, rex.w?63:31);
+ XOR(s3, s3, s5);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_OF2);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+// emit SHR32 instruction, from s1 , shift s2 (!0 and and'd already), store result in s1 using s3 and s4 as scratch
+void emit_shr32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4)
+{
+ int64_t j64;
+
+ CLEAR_FLAGS();
+
+ IFX(X_PEND) {
+ SDxw(s2, xEmu, offsetof(x64emu_t, op2));
+ SDxw(s1, xEmu, offsetof(x64emu_t, op1));
+ SET_DF(s4, rex.w?d_shr64:d_shr32);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+
+ IFX(X_CF) {
+ SUBI(s3, s2, 1);
+ SRA(s3, s1, s3);
+ ANDI(s3, s3, 1); // LSB
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_CF);
+ }
+
+ SRL(s1, s1, s2);
+
+ IFX(X_SF) {
+ BGE(s1, xZR, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ if (!rex.w) {
+ ZEROUP(s1);
+ }
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_OF) {
+ ADDI(s3, xZR, 1);
+ BEQ(s2, s3, 4+6*4);
+ SRLI(s3, s1, rex.w?62:30);
+ SRLI(s4, s1, rex.w?63:31);
+ XOR(s3, s3, s4);
+ ANDI(s3, s3, 1);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_OF2);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+// emit SHR32 instruction, from s1 , constant c, store result in s1 using s3 and s4 as scratch
+void emit_shr32c(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, uint32_t c, int s3, int s4)
+{
+ CLEAR_FLAGS();
+
+ IFX(X_PEND) {
+ if (c) {
+ MOV64x(s3, c);
+ SDxw(s3, xEmu, offsetof(x64emu_t, op2));
+ } else SDxw(xZR, xEmu, offsetof(x64emu_t, op2));
+ SDxw(s1, xEmu, offsetof(x64emu_t, op1));
+ SET_DF(s4, rex.w?d_shr64:d_shr32);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+ if(!c) {
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ return;
+ }
+ IFX(X_CF) {
+ if (c > 1) {
+ SRAI(s3, s1, c-1);
+ ANDI(s3, s3, 1); // LSB
+ BEQZ(s3, 8);
+ } else {
+ // no need to shift
+ ANDI(s3, s1, 1);
+ BEQZ(s3, 8);
+ }
+ ORI(xFlags, xFlags, 1 << F_CF);
+ }
+
+ SRLIxw(s1, s1, c);
+
+ IFX(X_SF) {
+ BGE(s1, xZR, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ if (!rex.w) {
+ ZEROUP(s1);
+ }
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_OF) {
+ if(c==1) {
+ SRLI(s3, s1, rex.w?62:30);
+ SRLI(s4, s1, rex.w?63:31);
+ XOR(s3, s3, s4);
+ ANDI(s3, s3, 1);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_OF2);
+ }
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+// emit SAR32 instruction, from s1 , constant c, store result in s1 using s3 and s4 as scratch
+void emit_sar32c(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, uint32_t c, int s3, int s4)
+{
+ CLEAR_FLAGS();
+
+ IFX(X_PEND) {
+ if (c) {
+ MOV64x(s3, c);
+ SDxw(s3, xEmu, offsetof(x64emu_t, op2));
+ } else SDxw(xZR, xEmu, offsetof(x64emu_t, op2));
+ SDxw(s1, xEmu, offsetof(x64emu_t, op1));
+ SET_DF(s4, rex.w?d_sar64:d_sar32);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+ if(!c) {
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ return;
+ }
+ IFX(X_CF) {
+ if (c > 1) {
+ SRAI(s3, s1, c-1);
+ ANDI(s3, s3, 1); // LSB
+ BEQZ(s3, 8);
+ } else {
+ // no need to shift
+ ANDI(s3, s1, 1);
+ BEQZ(s3, 8);
+ }
+ ORI(xFlags, xFlags, 1 << F_CF);
+ }
+
+ SRAIxw(s1, s1, c);
+
+ // SRAIW sign-extends, so test sign bit before clearing upper bits
+ IFX(X_SF) {
+ BGE(s1, xZR, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ if (!rex.w) {
+ ZEROUP(s1);
+ }
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+// emit ROL32 instruction, from s1, s2, store result in s1 using s3 and s4 as scratch
+void emit_rol32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4)
+{
+ int64_t j64;
+ IFX(X_CF | X_OF) {
+ ANDI(xFlags, xFlags, ~(1UL<<F_CF | 1UL<<F_OF2));
+ }
+
+ IFX(X_PEND) {
+ SDxw(s2, xEmu, offsetof(x64emu_t, op2));
+ SET_DF(s4, rex.w?d_rol64:d_rol32);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+
+ if(rex.w) {
+ ANDI(s4, s2, 0x3f);
+ } else {
+ ANDI(s4, s2, 0x1f);
+ }
+ if(rv64_zbb) {
+ ROLxw(s1, s1, s4);
+ } else {
+ SLLxw(s3, s1, s4);
+ NEG(s4, s4);
+ ADDI(s4, s4, rex.w?64:32);
+ SRLxw(s1, s1, s4);
+ OR(s1, s3, s1);
+ }
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_CF) {
+ ANDI(s4, s1, 1<<F_CF);
+ OR(xFlags, xFlags, s4);
+ }
+ IFX(X_OF) {
+ ADDI(s3, xZR, 1);
+ BEQ_NEXT(s2, s3);
+ SRLIxw(s3, s1, rex.w?63:31);
+ XOR(s3, s3, s1);
+ ANDI(s3, s3, 1);
+ SLLI(s3, s3, F_OF2);
+ OR(xFlags, xFlags, s3);
+ }
+}
+
+// emit ROR32 instruction, from s1, s2, store result in s1 using s3 and s4 as scratch
+void emit_ror32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4)
+{
+ int64_t j64;
+ IFX(X_CF | X_OF) {
+ ANDI(xFlags, xFlags, ~(1UL<<F_CF | 1UL<<F_OF2));
+ }
+
+ IFX(X_PEND) {
+ SDxw(s2, xEmu, offsetof(x64emu_t, op2));
+ SET_DF(s4, rex.w?d_ror64:d_ror32);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+
+ if(rex.w) {
+ ANDI(s4, s2, 0x3f);
+ } else {
+ ANDI(s4, s2, 0x1f);
+ }
+ if(rv64_zbb) {
+ RORxw(s1, s1, s4);
+ } else {
+ SRLxw(s3, s1, s4);
+ NEG(s4, s4);
+ ADDI(s4, s4, rex.w?64:32);
+ SLLxw(s1, s1, s4);
+ OR(s1, s3, s1);
+ }
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_CF) {
+ SRLI(s3, s1, rex.w?63:31);
+ AND(xFlags, xFlags, s3);
+ }
+ IFX(X_OF) {
+ ADDI(s3, xZR, 1);
+ BEQ_NEXT(s2, s3);
+ SRLIxw(s3, s1, rex.w?63:31);
+ XOR(s3, s3, s1);
+ ANDI(s3, s3, 1);
+ SLLI(s3, s3, F_OF2);
+ OR(xFlags, xFlags, s3);
+ }
+}
+
+// emit ROL32 instruction, from s1 , constant c, store result in s1 using s3 and s4 as scratch
+void emit_rol32c(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, uint32_t c, int s3, int s4)
+{
+ IFX(X_CF | X_OF) {
+ ANDI(xFlags, xFlags, ~(1UL<<F_CF | 1UL<<F_OF2));
+ }
+
+ IFX(X_PEND) {
+ MOV32w(s3, c);
+ SDxw(s3, xEmu, offsetof(x64emu_t, op2));
+ SET_DF(s4, rex.w?d_rol64:d_rol32);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+ if(!c) {
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ return;
+ }
+ if(rv64_zbb) {
+ RORIxw(s1, s1, (rex.w?64:32)-c);
+ } else {
+ SLLIxw(s3, s1, c);
+ SRLIxw(s1, s1, (rex.w?64:32)-c);
+ OR(s1, s3, s1);
+ }
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_CF) {
+ ANDI(s4, s1, 1<<F_CF);
+ OR(xFlags, xFlags, s4);
+ }
+ IFX(X_OF) {
+ if(c==1) {
+ SRLIxw(s3, s1, rex.w?63:31);
+ XOR(s3, s3, s1);
+ ANDI(s3, s3, 1);
+ SLLI(s3, s3, F_OF2);
+ OR(xFlags, xFlags, s3);
+ }
+ }
+}
+
+// emit ROR32 instruction, from s1 , constant c, store result in s1 using s3 and s4 as scratch
+void emit_ror32c(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, uint32_t c, int s3, int s4)
+{
+ IFX(X_CF | X_OF) {
+ ANDI(xFlags, xFlags, ~(1UL<<F_CF | 1UL<<F_OF2));
+ }
+
+ IFX(X_PEND) {
+ MOV32w(s3, c);
+ SDxw(s3, xEmu, offsetof(x64emu_t, op2));
+ SET_DF(s4, rex.w?d_ror64:d_ror32);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+ if(!c) {
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ return;
+ }
+ if(rv64_zbb) {
+ RORIxw(s1, s1, c);
+ } else {
+ SRLIxw(s3, s1, c);
+ SLLIxw(s1, s1, (rex.w?64:32)-c);
+ OR(s1, s3, s1);
+ }
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_CF) {
+ SRLI(s3, s1, rex.w?63:31);
+ AND(xFlags, xFlags, s3);
+ }
+ IFX(X_OF) {
+ if(c==1) {
+ SRLI(s3, s1, rex.w?62:30);
+ SRLI(s4, s3, 1);
+ XOR(s3, s3, s4);
+ ANDI(s3, s3, 1);
+ SLLI(s3, s3, F_OF2);
+ OR(xFlags, xFlags, s3);
+ }
+ }
+}
+
+// emit SHRD32 instruction, from s1, fill s2 , constant c, store result in s1 using s3 and s4 as scratch
+void emit_shrd32c(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, uint32_t c, int s3, int s4)
+{
+ CLEAR_FLAGS();
+
+ IFX(X_PEND) {
+ if (c) {
+ MOV64x(s3, c);
+ SDxw(s3, xEmu, offsetof(x64emu_t, op2));
+ } else SDxw(xZR, xEmu, offsetof(x64emu_t, op2));
+ SDxw(s1, xEmu, offsetof(x64emu_t, op1));
+ SET_DF(s4, rex.w?d_shr64:d_shr32);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+ if(!c) {
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ return;
+ }
+ IFX(X_CF) {
+ if (c > 1) {
+ SRAI(s3, s1, c-1);
+ ANDI(s3, s3, 1); // LSB
+ BEQZ(s3, 8);
+ } else {
+ // no need to shift
+ ANDI(s3, s1, 1);
+ BEQZ(s3, 8);
+ }
+ ORI(xFlags, xFlags, 1 << F_CF);
+ }
+
+ SRLIxw(s3, s1, c);
+ SLLIxw(s1, s2, (rex.w?64:32)-c);
+ OR(s1, s1, s3);
+
+ IFX(X_SF) {
+ BGE(s1, xZR, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ if (!rex.w) {
+ ZEROUP(s1);
+ }
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_OF) {
+ if(c==1) {
+ SRLI(s3, s1, rex.w?62:30);
+ SRLI(s4, s1, rex.w?63:31);
+ XOR(s3, s3, s4);
+ ANDI(s3, s3, 1);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_OF2);
+ }
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+void emit_shld32c(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, uint32_t c, int s3, int s4, int s5) {
+ CLEAR_FLAGS();
+ IFX(X_PEND) {
+ if (c) {
+ MOV64x(s3, c);
+ SDxw(s3, xEmu, offsetof(x64emu_t, op2));
+ } else SDxw(xZR, xEmu, offsetof(x64emu_t, op2));
+ SDxw(s1, xEmu, offsetof(x64emu_t, op1));
+ SET_DF(s4, rex.w?d_shl64:d_shl32);
+ } else IFX(X_ALL) {
+ SET_DFNONE();
+ }
+
+ if(!c) {
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ return;
+ }
+ IFX(X_CF|X_OF) {
+ if (c > 0) {
+ SRLI(s3, s1, (rex.w?64:32)-c);
+ ANDI(s5, s3, 1); // F_CF
+ IFX(X_CF) {
+ OR(xFlags, xFlags, s5);
+ }
+ } else {
+ IFX(X_OF) MOV64x(s5, 0);
+ }
+ }
+
+ SLLIxw(s3, s1, c);
+ SRLIxw(s1, s2, (rex.w?64:32)-c);
+ OR(s1, s1, s3);
+
+ IFX(X_SF) {
+ BGE(s1, xZR, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ if (!rex.w) {
+ ZEROUP(s1);
+ }
+ IFX(X_PEND) {
+ SDxw(s1, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_OF) {
+ SRLIxw(s3, s1, rex.w?63:31);
+ XOR(s3, s3, s5);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_OF2);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
diff --git a/src/dynarec/rv64/dynarec_rv64_emit_tests.c b/src/dynarec/rv64/dynarec_rv64_emit_tests.c
new file mode 100644
index 0000000..00c1fb7
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_emit_tests.c
@@ -0,0 +1,349 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <stddef.h>
+#include <errno.h>
+
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "emu/x64run_private.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "emu/x64run_private.h"
+#include "x64trace.h"
+#include "dynarec_native.h"
+
+#include "rv64_printer.h"
+#include "dynarec_rv64_private.h"
+#include "dynarec_rv64_functions.h"
+#include "dynarec_rv64_helper.h"
+
+// emit CMP8 instruction, from cmp s1, s2, using s3, s4, s5 and s6 as scratch
+void emit_cmp8(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5, int s6)
+{
+ CLEAR_FLAGS();
+ IFX_PENDOR0 {
+ SB(s1, xEmu, offsetof(x64emu_t, op1));
+ SB(s2, xEmu, offsetof(x64emu_t, op2));
+ SET_DF(s4, d_cmp8);
+ } else {
+ SET_DFNONE();
+ }
+
+ IFX(X_AF | X_CF | X_OF) {
+ // for later flag calculation
+ NOT(s5, s1);
+ }
+
+ // It's a cmp, we can't store the result back to s1.
+ SUB(s6, s1, s2);
+ ANDI(s6, s6, 0xff);
+ IFX_PENDOR0 {
+ SB(s6, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_SF) {
+ SRLI(s3, s6, 7);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ CALC_SUB_FLAGS(s5, s2, s6, s3, s4, 8);
+ IFX(X_ZF) {
+ BNEZ(s6, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s6, s3, s4);
+ }
+}
+
+// emit CMP8 instruction, from cmp s1 , 0, using s3 and s4 as scratch
+void emit_cmp8_0(dynarec_rv64_t* dyn, int ninst, int s1, int s3, int s4)
+{
+ CLEAR_FLAGS();
+ IFX_PENDOR0 {
+ SB(s1, xEmu, offsetof(x64emu_t, op1));
+ SB(xZR, xEmu, offsetof(x64emu_t, op2));
+ SB(s1, xEmu, offsetof(x64emu_t, res));
+ SET_DF(s3, d_cmp8);
+ } else {
+ SET_DFNONE();
+ }
+
+ IFX(X_SF) {
+ SRLI(s3, s1, 7);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+// emit CMP16 instruction, from cmp s1, s2, using s3 and s4 as scratch
+void emit_cmp16(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5, int s6)
+{
+ CLEAR_FLAGS();
+ IFX_PENDOR0 {
+ SH(s1, xEmu, offsetof(x64emu_t, op1));
+ SH(s2, xEmu, offsetof(x64emu_t, op2));
+ SET_DF(s4, d_cmp16);
+ } else {
+ SET_DFNONE();
+ }
+
+ IFX(X_AF | X_CF | X_OF) {
+ // for later flag calculation
+ NOT(s5, s1);
+ }
+
+ // It's a cmp, we can't store the result back to s1.
+ SUB(s6, s1, s2);
+ IFX(X_ALL) {
+ ZEXTH(s6, s6);
+ }
+ IFX_PENDOR0 {
+ SH(s6, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_SF) {
+ SRLI(s3, s6, 15);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ CALC_SUB_FLAGS(s5, s2, s6, s3, s4, 16);
+ IFX(X_ZF) {
+ BNEZ(s6, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s6, s3, s4);
+ }
+}
+
+// emit CMP16 instruction, from cmp s1 , #0, using s3 and s4 as scratch
+void emit_cmp16_0(dynarec_rv64_t* dyn, int ninst, int s1, int s3, int s4)
+{
+ CLEAR_FLAGS();
+ IFX_PENDOR0 {
+ SH(s1, xEmu, offsetof(x64emu_t, op1));
+ SH(xZR, xEmu, offsetof(x64emu_t, op2));
+ SH(s1, xEmu, offsetof(x64emu_t, res));
+ SET_DF(s3, d_cmp16);
+ } else {
+ SET_DFNONE();
+ }
+
+ IFX(X_SF) {
+ SRLI(s3, s1, 15);
+ BEQZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+// emit CMP32 instruction, from cmp s1, s2, using s3 and s4 as scratch
+void emit_cmp32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4, int s5, int s6)
+{
+ CLEAR_FLAGS();
+ IFX_PENDOR0 {
+ SDxw(s1, xEmu, offsetof(x64emu_t, op1));
+ SDxw(s2, xEmu, offsetof(x64emu_t, op2));
+ SET_DF(s4, rex.w?d_cmp64:d_cmp32);
+ } else {
+ SET_DFNONE();
+ }
+
+ IFX(X_AF | X_CF | X_OF) {
+ // for later flag calculation
+ NOT(s5, s1);
+ }
+
+ // It's a cmp, we can't store the result back to s1.
+ SUBxw(s6, s1, s2);
+ IFX_PENDOR0 {
+ SDxw(s6, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_SF) {
+ BGE(s6, xZR, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ if (!rex.w) {
+ ZEROUP(s6);
+ }
+ CALC_SUB_FLAGS(s5, s2, s6, s3, s4, rex.w?64:32);
+ IFX(X_ZF) {
+ BNEZ(s6, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s6, s3, s4);
+ }
+}
+
+// emit CMP32 instruction, from cmp s1, 0, using s3 and s4 as scratch
+void emit_cmp32_0(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s3, int s4)
+{
+ CLEAR_FLAGS();
+ IFX_PENDOR0 {
+ SD(s1, xEmu, offsetof(x64emu_t, op1));
+ SD(xZR, xEmu, offsetof(x64emu_t, op2));
+ SD(s1, xEmu, offsetof(x64emu_t, res));
+ SET_DF(s4, rex.w?d_cmp64:d_cmp32);
+ } else {
+ SET_DFNONE();
+ }
+ IFX(X_SF) {
+ if (rex.w) {
+ BGE(s1, xZR, 8);
+ } else {
+ SRLI(s3, s1, 31);
+ BEQZ(s3, 8);
+ }
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ IFX(X_ZF) {
+ BNEZ(s1, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s1, s3, s4);
+ }
+}
+
+// emit TEST8 instruction, from test s1, s2, using s3, s4 and s5 as scratch
+void emit_test8(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5) {
+ CLEAR_FLAGS();
+ IFX_PENDOR0 {
+ SET_DF(s3, d_tst8);
+ } else {
+ SET_DFNONE();
+ }
+
+ AND(s3, s1, s2); // res = s1 & s2
+
+ IFX_PENDOR0 {
+ SD(s3, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_SF) {
+ SRLI(s4, s3, 7);
+ BEQZ(s4, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ IFX(X_ZF) {
+ BNEZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s3, s4, s5);
+ }
+}
+
+// emit TEST16 instruction, from test s1, s2, using s3, s4 and s5 as scratch
+void emit_test16(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5)
+{
+ CLEAR_FLAGS();
+ IFX_PENDOR0 {
+ SET_DF(s3, d_tst16);
+ } else {
+ SET_DFNONE();
+ }
+
+ AND(s3, s1, s2); // res = s1 & s2
+
+ IFX_PENDOR0 {
+ SH(s3, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_SF) {
+ SRLI(s4, s3, 15);
+ BEQZ(s4, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ IFX(X_ZF) {
+ BNEZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s3, s4, s5);
+ }
+}
+
+// emit TEST32 instruction, from test s1, s2, using s3 and s4 as scratch
+void emit_test32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4, int s5)
+{
+ CLEAR_FLAGS();
+ IFX_PENDOR0 {
+ SET_DF(s3, rex.w?d_tst64:d_tst32);
+ } else {
+ SET_DFNONE();
+ }
+
+ AND(s3, s1, s2); // res = s1 & s2
+
+ IFX_PENDOR0 {
+ SDxw(s3, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_SF|X_ZF) {
+ if (!rex.w) ZEROUP(s3);
+ }
+ IFX(X_SF) {
+ SRLI(s4, s3, rex.w?63:31);
+ BEQZ(s4, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ IFX(X_ZF) {
+ BNEZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s3, s4, s5);
+ }
+}
+
+// emit TEST32 instruction, from test s1, s2, using s3 and s4 as scratch
+void emit_test32c(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int64_t c, int s3, int s4, int s5)
+{
+ CLEAR_FLAGS();
+ IFX_PENDOR0 {
+ SET_DF(s3, rex.w?d_tst64:d_tst32);
+ } else {
+ SET_DFNONE();
+ }
+
+ if(c>=-2048 && c<=2047) {
+ ANDI(s3, s1, c);
+ IFX(X_SF|X_ZF) {
+ if (!rex.w && c<0) ZEROUP(s3);
+ }
+ } else {
+ MOV64xw(s3, c);
+ AND(s3, s1, s3); // res = s1 & s2
+ }
+
+ IFX_PENDOR0 {
+ SDxw(s3, xEmu, offsetof(x64emu_t, res));
+ }
+ IFX(X_SF) {
+ SRLI(s4, s3, rex.w?63:31);
+ BEQZ(s4, 8);
+ ORI(xFlags, xFlags, 1 << F_SF);
+ }
+ IFX(X_ZF) {
+ BNEZ(s3, 8);
+ ORI(xFlags, xFlags, 1 << F_ZF);
+ }
+ IFX(X_PF) {
+ emit_pf(dyn, ninst, s3, s4, s5);
+ }
+}
diff --git a/src/dynarec/rv64/dynarec_rv64_f0.c b/src/dynarec/rv64/dynarec_rv64_f0.c
new file mode 100644
index 0000000..bb5c78c
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_f0.c
@@ -0,0 +1,691 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <stddef.h>
+#include <errno.h>
+
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "emu/x64run_private.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "emu/x64run_private.h"
+#include "x64trace.h"
+#include "dynarec_native.h"
+
+#include "rv64_printer.h"
+#include "dynarec_rv64_private.h"
+#include "dynarec_rv64_helper.h"
+#include "dynarec_rv64_functions.h"
+
+
+uintptr_t dynarec64_F0(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog)
+{
+ (void)ip; (void)rep; (void)need_epilog;
+
+ uint8_t opcode = F8;
+ uint8_t nextop;
+ uint8_t gd, ed, u8;
+ uint8_t wback, wb1, wb2, eb1, eb2, gb1, gb2;
+ int32_t i32;
+ int64_t i64, j64;
+ int64_t fixedaddress;
+ int unscaled;
+ MAYUSE(eb1);
+ MAYUSE(eb2);
+ MAYUSE(gb1);
+ MAYUSE(gb2);
+ MAYUSE(wb1);
+ MAYUSE(wb2);
+ MAYUSE(j64);
+
+ while((opcode==0xF2) || (opcode==0xF3)) {
+ rep = opcode-0xF1;
+ opcode = F8;
+ }
+
+ GETREX();
+
+ // TODO: Take care of unligned memory access for all the LOCK ones.
+ // https://github.com/ptitSeb/box64/pull/604
+ switch(opcode) {
+ case 0x01:
+ INST_NAME("LOCK ADD Ed, Gd");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ SMDMB();
+ if((nextop&0xC0)==0xC0) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ emit_add32(dyn, ninst, rex, ed, gd, x3, x4, x5);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, LOCK_LOCK, 0, 0);
+ MARKLOCK;
+ LRxw(x1, wback, 1, 1);
+ ADDxw(x4, x1, gd);
+ SCxw(x3, x4, wback, 1, 1);
+ BNEZ_MARKLOCK(x3);
+ IFX(X_ALL|X_PEND) {
+ emit_add32(dyn, ninst, rex, x1, gd, x3, x4, x5);
+ }
+ }
+ SMDMB();
+ break;
+ case 0x09:
+ INST_NAME("LOCK OR Ed, Gd");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ SMDMB();
+ if (MODREG) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ emit_or32(dyn, ninst, rex, ed, gd, x3, x4);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, LOCK_LOCK, 0, 0);
+ MARKLOCK;
+ LRxw(x1, wback, 1, 1);
+ OR(x4, x1, gd);
+ SCxw(x3, x4, wback, 1, 1);
+ BNEZ_MARKLOCK(x3);
+ IFX(X_ALL|X_PEND)
+ emit_or32(dyn, ninst, rex, x1, gd, x3, x4);
+ }
+ SMDMB();
+ break;
+
+ case 0x0F:
+ nextop = F8;
+ switch(nextop) {
+ case 0xB0:
+ switch(rep) {
+ case 0:
+ INST_NAME("LOCK CMPXCHG Eb, Gb");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ ANDI(x6, xRAX, 0xff); // AL
+ SMDMB();
+ if(MODREG) {
+ if(rex.rex) {
+ wback = xRAX+(nextop&7)+(rex.b<<3);
+ wb2 = 0;
+ } else {
+ wback = (nextop&7);
+ wb2 = (wback>>2)*8;
+ wback = xRAX+(wback&3);
+ }
+ if (wb2) {
+ MV(x2, wback);
+ SRLI(x2, x2, wb2);
+ ANDI(x2, x2, 0xff);
+ } else {
+ ANDI(x2, wback, 0xff);
+ }
+ wb1 = 0;
+ ed = x2;
+ UFLAG_IF {
+ emit_cmp8(dyn, ninst, x6, ed, x3, x4, x5, x1);
+ }
+ BNE_MARK2(x6, x2);
+ if (wb2) {
+ MV(wback, x2);
+ SRLI(wback, wback, wb2);
+ ANDI(wback, wback, 0xff);
+ } else {
+ ANDI(wback, x2, 0xff);
+ }
+ GETGB(x1);
+ MV(ed, gd);
+ MARK2;
+ ANDI(xRAX, xRAX, ~0xff);
+ OR(xRAX, xRAX, x2);
+ B_NEXT_nocond;
+ } else {
+ // this one is tricky, and did some repetitive work.
+ // mostly because we only got 6 scratch registers,
+ // and has so much to do.
+ if(rex.rex) {
+ gb1 = xRAX+((nextop&0x38)>>3)+(rex.r<<3);
+ gb2 = 0;
+ } else {
+ gd = (nextop&0x38)>>3;
+ gb2 = ((gd&4)>>2);
+ gb1 = xRAX+(gd&3);
+ }
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, x2, &fixedaddress, rex, LOCK_LOCK, 0, 0);
+ ANDI(x5, wback, 0b11);
+ SLLI(x5, x5, 3); // shamt
+ MARKLOCK;
+ ANDI(x2, wback, ~0b11); // align to 32bit
+ LWU(x1, x2, 0);
+ LR_W(x4, x2, 1, 1);
+ SRL(x4, x4, x5);
+ ANDI(x4, x4, 0xff);
+ BNE_MARK(x6, x4); // compare AL with m8
+ // AL == m8, r8 is loaded into m8
+ ADDI(x2, xZR, 0xff);
+ SLL(x2, x2, x5);
+ NOT(x2, x2);
+ AND(x2, x1, x2);
+ if (gb2) {
+ MV(x1, gb1);
+ SRLI(x1, x1, 8);
+ ANDI(x1, x1, 0xff);
+ } else {
+ ANDI(x1, gb1, 0xff);
+ }
+ SLL(x1, x1, x5);
+ OR(x1, x1, x2);
+ ANDI(x2, wback, ~0b11); // align to 32bit again
+ SC_W(x9, x1, x2, 1, 1);
+ BNEZ_MARKLOCK(x9);
+ // done
+ MARK;
+ UFLAG_IF {emit_cmp8(dyn, ninst, x6, x4, x1, x2, x3, x5);}
+ // load m8 into AL
+ ANDI(xRAX, xRAX, ~0xff);
+ OR(xRAX, xRAX, x4);
+ }
+ SMDMB();
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+ case 0xB1:
+ switch (rep) {
+ case 0:
+ INST_NAME("LOCK CMPXCHG Ed, Gd");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ if (MODREG) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ wback = 0;
+ UFLAG_IF {emit_cmp32(dyn, ninst, rex, xRAX, ed, x3, x4, x5, x6);}
+ MV(x1, ed); // save value
+ SUB(x2, x1, xRAX);
+ BNE_MARK2(x2, xZR);
+ MV(ed, gd);
+ MARK2;
+ MVxw(xRAX, x1);
+ } else {
+ SMDMB();
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, LOCK_LOCK, 0, 0);
+ MARKLOCK;
+ LRxw(x1, wback, 1, 1);
+ SUBxw(x3, x1, xRAX);
+ BNE_MARK(x3, xZR);
+ // EAX == Ed
+ SCxw(x4, gd, wback, 1, 1);
+ BNEZ_MARKLOCK(x4);
+ MARK;
+ UFLAG_IF {emit_cmp32(dyn, ninst, rex, xRAX, x1, x3, x4, x5, x6);}
+ MVxw(xRAX, x1);
+ SMDMB();
+ }
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+ case 0xC1:
+ switch(rep) {
+ case 0:
+ INST_NAME("LOCK XADD Gd, Ed");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ SMDMB();
+ if(MODREG) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ MVxw(x1, ed);
+ MVxw(ed, gd);
+ MVxw(gd, x1);
+ emit_add32(dyn, ninst, rex, ed, gd, x3, x4, x5);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, LOCK_LOCK, 0, 0);
+ MARKLOCK;
+ LRxw(x1, wback, 1, 1);
+ ADDxw(x4, x1, gd);
+ SCxw(x3, x4, wback, 1, 1);
+ BNEZ_MARKLOCK(x3);
+ IFX(X_ALL|X_PEND) {
+ MVxw(x2, x1);
+ emit_add32(dyn, ninst, rex, x2, gd, x3, x4, x5);
+ }
+ MVxw(gd, x1);
+ }
+ SMDMB();
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+
+ case 0xC7:
+ switch(rep) {
+ case 0:
+ if (rex.w) {
+ INST_NAME("LOCK CMPXCHG16B Gq, Eq");
+ } else {
+ INST_NAME("LOCK CMPXCHG8B Gq, Eq");
+ }
+ SETFLAGS(X_ZF, SF_SUBSET);
+ nextop = F8;
+ addr = geted(dyn, addr, ninst, nextop, &wback, x1, x2, &fixedaddress, rex, LOCK_LOCK, 0, 0);
+ ANDI(xFlags, xFlags, ~(1<<F_ZF));
+ if (rex.w) {
+ // there is no atomic move on 16bytes, so implement it with mutex
+ LD(x9, xEmu, offsetof(x64emu_t, context));
+ ADDI(x9, x9, offsetof(box64context_t, mutex_16b));
+ ADDI(x4, xZR, 1);
+ MARKLOCK;
+ AMOSWAP_W(x4, x4, x9, 1, 1);
+ // x4 == 1 if locked
+ BNEZ_MARKLOCK(x4);
+
+ SMDMB();
+ LD(x2, wback, 0);
+ LD(x3, wback, 8);
+ BNE_MARK(x2, xRAX);
+ BNE_MARK(x3, xRDX);
+ SD(xRBX, wback, 0);
+ SD(xRCX, wback, 8);
+ ORI(xFlags, xFlags, 1<<F_ZF);
+ B_MARK3_nocond;
+ MARK;
+ MV(xRAX, x2);
+ MV(xRDX, x3);
+ MARK3;
+ SMDMB();
+
+ // unlock
+ AMOSWAP_W(xZR, xZR, x9, 1, 1);
+ } else {
+ SMDMB();
+ MARKLOCK;
+ LR_D(x2, wback, 1, 1);
+ AND(x3, x2, xMASK);
+ AND(x4, xRAX, xMASK);
+ SRLI(x5, x2, 32);
+ AND(x6, xRDX, xMASK);
+ BNE_MARK(x3, x4); // EAX != Ed[0]
+ BNE_MARK(x5, x6); // EDX != Ed[1]
+ SLLI(x2, xRCX, 32);
+ AND(x3, xRBX, xMASK);
+ OR(x2, x2, x3);
+ SC_D(x3, x2, wback, 1, 1);
+ BNEZ_MARKLOCK(x3);
+ ORI(xFlags, xFlags, 1<<F_ZF);
+ B_MARK3_nocond;
+ MARK;
+ ADDI(xRAX, x3, 0);
+ ADDI(xRDX, x5, 0);
+ AND(xRAX, xRAX, xMASK);
+ AND(xRDX, xRDX, xMASK);
+ MARK3;
+ SMDMB();
+ }
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+
+ default:
+ DEFAULT;
+ }
+ break;
+ case 0x10:
+ INST_NAME("LOCK ADC Eb, Gb");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGB(x2);
+ SMDMB();
+ if((nextop&0xC0)==0xC0) {
+ if(rex.rex) {
+ wback = xRAX + (nextop&7) + (rex.b<<3);
+ wb2 = 0;
+ } else {
+ wback = (nextop&7);
+ wb2 = (wback>>2);
+ wback = xRAX+(wback&3);
+ }
+ SRLIW(x1, wback, wb2*8);
+ ANDI(x1, x1, 0xFF);
+ emit_adc8(dyn, ninst, x1, x2, x3, x4, x5);
+ SLLI(x1, x1, wb2*8);
+ MOV_U12(x3, 0xFF);
+ SLLI(x3, x3, wb2*8);
+ NOT(x3, x3);
+ AND(wback, wback, x3);
+ OR(wback, wback, x1);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &wback, x1, x3, &fixedaddress, rex, LOCK_LOCK, 0, 0);
+ ANDI(x3, wback, 0b11);
+ BNEZ_MARK(x3);
+ MARKLOCK;
+ LR_W(x5, wback, 1, 1);
+ ANDI(x4, x5, 0xff); // x4 = Ed.b[0]
+ ANDI(x5, x5, -256); // x5 = clear Ed.b[0]
+ ADDW(x6, x4, x2);
+ ANDI(x9, xFlags, 1 << F_CF);
+ ADDW(x6, x6, x9); // x6 = adc
+ ANDI(x6, x6, 0xff);
+ OR(x5, x5, x6);
+ SC_W(x9, x5, wback, 1, 1);
+ BNEZ_MARKLOCK(x9);
+ B_MARK3_nocond;
+ MARK;
+ SLLI(x3, x3, 3);
+ MOV_U12(x4, 0xff);
+ ANDI(wback, wback, ~3); // aligning address
+ SLLI(x4, x4, x3); // x4 = byte mask
+ NOT(x5, x4); // x5 = ~mask
+ SLL(x2, x2, x3); // x2 = extented Gb
+ MARK2;
+ LR_W(x6, wback, 1, 1); // x6 = Ed
+ AND(x9, x6, x4); // x9 = extended Ed.b[dest]
+ AND(x6, x6, x5); // x6 = clear Ed.b[dest]
+ ADDW(x5, x9, x2);
+ ANDI(x4, xFlags, 1 << F_CF);
+ SLL(x4, x4, x3); // extented
+ ADDW(x5, x5, x4); // x5 = adc
+ OR(x5, x5, x6);
+ SC_W(x4, x5, wback, 1, 1);
+ BNEZ_MARK2(x4);
+ IFX(X_ALL|X_PEND) {
+ SRLI(x2, x2, x3); // Gb
+ SRLI(x4, x9, x3); // Eb
+ }
+ MARK3;
+ IFX(X_ALL|X_PEND) {
+ emit_adc8(dyn, ninst, x4, x2, x3, x5, x6);
+ }
+ }
+ SMDMB();
+ break;
+ case 0x11:
+ INST_NAME("LOCK ADC Ed, Gd");
+ READFLAGS(X_CF);
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ SMDMB();
+ if(MODREG) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ emit_adc32(dyn, ninst, rex, ed, gd, x3, x4, x5, x6);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, LOCK_LOCK, 0, 0);
+ MARKLOCK;
+ LRxw(x1, wback, 1, 1);
+ ADDxw(x3, x1, gd);
+ ANDI(x4, xFlags, 1 << F_CF);
+ ADDxw(x3, x3, x4);
+ SCxw(x4, x3, wback, 1, 1);
+ BNEZ_MARKLOCK(x4);
+ IFX(X_ALL|X_PEND) {
+ emit_adc32(dyn, ninst, rex, x1, gd, x3, x4, x5, x6);
+ }
+ }
+ SMDMB();
+ break;
+ case 0x21:
+ INST_NAME("LOCK AND Ed, Gd");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ SMDMB();
+ if(MODREG) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ emit_and32(dyn, ninst, rex, ed, gd, x3, x4);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, LOCK_LOCK, 0, 0);
+ MARKLOCK;
+ LRxw(x1, wback, 1, 1);
+ AND(x4, x1, gd);
+ SCxw(x3, x4, wback, 1, 1);
+ BNEZ_MARKLOCK(x3);
+ IFX(X_ALL|X_PEND)
+ emit_and32(dyn, ninst, rex, x1, gd, x3, x4);
+ }
+ SMDMB();
+ break;
+ case 0x29:
+ INST_NAME("LOCK SUB Ed, Gd");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ nextop = F8;
+ GETGD;
+ SMDMB();
+ if(MODREG) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ emit_sub32(dyn, ninst, rex, ed, gd, x3, x4, x5);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, LOCK_LOCK, 0, 0);
+ MARKLOCK;
+ LRxw(x1, wback, 1, 1);
+ SUB(x4, x1, gd);
+ SCxw(x3, x4, wback, 1, 1);
+ BNEZ_MARKLOCK(x3);
+ IFX(X_ALL|X_PEND)
+ emit_sub32(dyn, ninst, rex, x1, gd, x3, x4, x5);
+ }
+ SMDMB();
+ break;
+ case 0x66:
+ return dynarec64_66F0(dyn, addr, ip, ninst, rex, rep, ok, need_epilog);
+
+ case 0x80:
+ nextop = F8;
+ SMDMB();
+ switch((nextop>>3)&7) {
+ case 1: // OR
+ INST_NAME("LOCK OR Eb, Ib");
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ if(MODREG) {
+ GETEB(x1, 1);
+ u8 = F8;
+ emit_or8c(dyn, ninst, x1, u8, x2, x4, x5);
+ EBBACK(x5, 0);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &wback, x5, x1, &fixedaddress, rex, LOCK_LOCK, 0, 1);
+ u8 = F8;
+ ANDI(x2, wback, 3);
+ SLLI(x2, x2, 3); // offset in bits
+ ANDI(x3, wback, ~3); // aligned addr
+ ADDI(x1, xZR, u8);
+ SLL(x1, x1, x2); // Ib << offset
+ MARKLOCK;
+ LR_W(x4, x3, 1, 1);
+ OR(x6, x4, x1);
+ SC_W(x6, x6, x3, 1, 1);
+ BNEZ_MARKLOCK(x6);
+ IFX(X_ALL|X_PEND) {
+ SRL(x1, x4, x2);
+ ANDI(x1, x1, 0xFF);
+ emit_or8c(dyn, ninst, x1, u8, x2, x4, x5);
+ }
+ }
+ break;
+ default:
+ DEFAULT;
+ }
+ SMDMB();
+ break;
+ case 0x81:
+ case 0x83:
+ nextop = F8;
+ SMDMB();
+ switch((nextop>>3)&7) {
+ case 0: // ADD
+ if(opcode==0x81) {
+ INST_NAME("LOCK ADD Ed, Id");
+ } else {
+ INST_NAME("LOCK ADD Ed, Ib");
+ }
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ if(MODREG) {
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ emit_add32c(dyn, ninst, rex, ed, i64, x3, x4, x5, x6);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, LOCK_LOCK, 0, (opcode==0x81)?4:1);
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ MARKLOCK;
+ LRxw(x1, wback, 1, 1);
+ if(i64>=-2048 && i64<2048)
+ ADDIxw(x4, x1, i64);
+ else {
+ MOV64xw(x4, i64);
+ ADDxw(x4, x1, x4);
+ }
+ SCxw(x3, x4, wback, 1, 1);
+ BNEZ_MARKLOCK(x3);
+ IFX(X_ALL|X_PEND)
+ emit_add32c(dyn, ninst, rex, x1, i64, x3, x4, x5, x6);
+ }
+ break;
+ case 1: // OR
+ if(opcode==0x81) {
+ INST_NAME("LOCK OR Ed, Id");
+ } else {
+ INST_NAME("LOCK OR Ed, Ib");
+ }
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ if(MODREG) {
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ emit_or32c(dyn, ninst, rex, ed, i64, x3, x4);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, LOCK_LOCK, 0, (opcode==0x81)?4:1);
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ MARKLOCK;
+ LRxw(x1, wback, 1, 1);
+ if (i64>=-2048 && i64<2048) {
+ ORI(x4, x1, i64);
+ } else {
+ MOV64xw(x4, i64);
+ OR(x4, x1, x4);
+ }
+ if (!rex.w) ZEROUP(x4);
+ SCxw(x3, x4, wback, 1, 1);
+ BNEZ_MARKLOCK(x3);
+ IFX(X_ALL|X_PEND)
+ emit_or32c(dyn, ninst, rex, x1, i64, x3, x4);
+ }
+ break;
+ case 4: // AND
+ if(opcode==0x81) {
+ INST_NAME("LOCK AND Ed, Id");
+ } else {
+ INST_NAME("LOCK AND Ed, Ib");
+ }
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ if(MODREG) {
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ emit_and32c(dyn, ninst, rex, ed, i64, x3, x4);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, LOCK_LOCK, 0, (opcode==0x81)?4:1);
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ MARKLOCK;
+ LRxw(x1, wback, 1, 1);
+ if (i64>=-2048 && i64<2048) {
+ ANDI(x4, x1, i64);
+ } else {
+ MOV64xw(x4, i64);
+ AND(x4, x1, x4);
+ }
+ if (!rex.w) ZEROUP(x4);
+ SCxw(x3, x4, wback, 1, 1);
+ BNEZ_MARKLOCK(x3);
+ IFX(X_ALL|X_PEND)
+ emit_and32c(dyn, ninst, rex, x1, i64, x3, x4);
+ }
+ break;
+ case 5: // SUB
+ if(opcode==0x81) {
+ INST_NAME("LOCK SUB Ed, Id");
+ } else {
+ INST_NAME("LOCK SUB Ed, Ib");
+ }
+ SETFLAGS(X_ALL, SF_SET_PENDING);
+ if(MODREG) {
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ emit_sub32(dyn, ninst, rex, ed, i64, x3, x4, x5);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, LOCK_LOCK, 0, (opcode==0x81)?4:1);
+ if(opcode==0x81) i64 = F32S; else i64 = F8S;
+ MARKLOCK;
+ LRxw(x1, wback, 1, 1);
+ if (i64>-2048 && i64<=2048) {
+ ADDIxw(x4, x1, -i64);
+ } else {
+ MOV64xw(x4, i64);
+ SUBxw(x4, x1, x4);
+ }
+ SCxw(x3, x4, wback, 1, 1);
+ BNEZ_MARKLOCK(x3);
+ IFX(X_ALL|X_PEND)
+ emit_sub32c(dyn, ninst, rex, x1, i64, x3, x4, x5, x6);
+ }
+ break;
+ default:
+ DEFAULT;
+ }
+ SMDMB();
+ break;
+ case 0xFF:
+ nextop = F8;
+ switch((nextop>>3)&7)
+ {
+ case 0: // INC Ed
+ INST_NAME("LOCK INC Ed");
+ SETFLAGS(X_ALL&~X_CF, SF_SUBSET_PENDING);
+ SMDMB();
+ if(MODREG) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ emit_inc32(dyn, ninst, rex, ed, x3, x4, x5, x6);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, LOCK_LOCK, 0, 0);
+ MARKLOCK;
+ LRxw(x1, wback, 1, 1);
+ ADDIxw(x4, x1, 1);
+ SCxw(x3, x4, wback, 1, 1);
+ BNEZ_MARKLOCK(x3);
+ IFX(X_ALL|X_PEND)
+ emit_inc32(dyn, ninst, rex, x1, x3, x4, x5, x6);
+ }
+ break;
+ case 1: // DEC Ed
+ INST_NAME("LOCK DEC Ed");
+ SETFLAGS(X_ALL&~X_CF, SF_SUBSET_PENDING);
+ SMDMB();
+ if(MODREG) {
+ ed = xRAX+(nextop&7)+(rex.b<<3);
+ emit_dec32(dyn, ninst, rex, ed, x3, x4, x5, x6);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, LOCK_LOCK, 0, 0);
+ MARKLOCK;
+ LRxw(x1, wback, 1, 1);
+ ADDIxw(x4, x1, -1);
+ SCxw(x3, x4, wback, 1, 1);
+ BNEZ_MARKLOCK(x3);
+ IFX(X_ALL|X_PEND)
+ emit_inc32(dyn, ninst, rex, x1, x3, x4, x5, x6);
+ }
+ break;
+ default:
+ DEFAULT;
+ }
+ break;
+ default:
+ DEFAULT;
+ }
+ return addr;
+}
diff --git a/src/dynarec/rv64/dynarec_rv64_f20f.c b/src/dynarec/rv64/dynarec_rv64_f20f.c
new file mode 100644
index 0000000..ac3da81
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_f20f.c
@@ -0,0 +1,377 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <stddef.h>
+#include <errno.h>
+
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "emu/x64run_private.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "emu/x64run_private.h"
+#include "x64trace.h"
+#include "dynarec_native.h"
+
+#include "rv64_printer.h"
+#include "dynarec_rv64_private.h"
+#include "dynarec_rv64_functions.h"
+#include "dynarec_rv64_helper.h"
+
+uintptr_t dynarec64_F20F(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int* ok, int* need_epilog)
+{
+ (void)ip; (void)need_epilog;
+
+ uint8_t opcode = F8;
+ uint8_t nextop;
+ uint8_t gd, ed;
+ uint8_t wback, gback;
+ uint8_t u8;
+ uint64_t u64, j64;
+ int v0, v1;
+ int q0;
+ int d0, d1;
+ int64_t fixedaddress, gdoffset;
+ int unscaled;
+
+ MAYUSE(d0);
+ MAYUSE(d1);
+ MAYUSE(q0);
+ MAYUSE(v0);
+ MAYUSE(v1);
+
+ switch(opcode) {
+
+ case 0x10:
+ INST_NAME("MOVSD Gx, Ex");
+ nextop = F8;
+ GETG;
+ if(MODREG) {
+ ed = (nextop&7)+ (rex.b<<3);
+ v0 = sse_get_reg(dyn, ninst, x1, gd, 0);
+ d0 = sse_get_reg(dyn, ninst, x1, ed, 0);
+ FMVD(v0, d0);
+ } else {
+ SMREAD();
+ v0 = sse_get_reg_empty(dyn, ninst, x1, gd, 0);
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, x2, &fixedaddress, rex, NULL, 8, 0);
+ FLD(v0, ed, fixedaddress);
+ // reset upper part
+ SD(xZR, xEmu, offsetof(x64emu_t, xmm[gd])+8);
+ }
+ break;
+ case 0x11:
+ INST_NAME("MOVSD Ex, Gx");
+ nextop = F8;
+ GETG;
+ v0 = sse_get_reg(dyn, ninst, x1, gd, 0);
+ if(MODREG) {
+ ed = (nextop&7)+ (rex.b<<3);
+ d0 = sse_get_reg(dyn, ninst, x1, ed, 0);
+ FMVD(d0, v0);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, x2, &fixedaddress, rex, NULL, 1, 0);
+ FSD(v0, ed, fixedaddress);
+ SMWRITE2();
+ }
+ break;
+ case 0x12:
+ INST_NAME("MOVDDUP Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ LD(x3, wback, fixedaddress+0);
+ SD(x3, gback, gdoffset+0);
+ SD(x3, gback, gdoffset+8);
+ break;
+ case 0x2A:
+ INST_NAME("CVTSI2SD Gx, Ed");
+ nextop = F8;
+ GETGXSD(v0);
+ GETED(0);
+ if(rex.w) {
+ FCVTDL(v0, ed, RD_RNE);
+ } else {
+ FCVTDW(v0, ed, RD_RNE);
+ }
+ break;
+ case 0x2C:
+ INST_NAME("CVTTSD2SI Gd, Ex");
+ nextop = F8;
+ GETGD;
+ GETEXSD(v0, 0);
+ if(!box64_dynarec_fastround) {
+ FSFLAGSI(0); // // reset all bits
+ }
+ FCVTLDxw(gd, v0, RD_RTZ);
+ if(!rex.w)
+ ZEROUP(gd);
+ if(!box64_dynarec_fastround) {
+ FRFLAGS(x5); // get back FPSR to check the IOC bit
+ ANDI(x5, x5, (1<<FR_NV)|(1<<FR_OF));
+ CBZ_NEXT(x5);
+ if(rex.w) {
+ MOV64x(gd, 0x8000000000000000LL);
+ } else {
+ MOV32w(gd, 0x80000000);
+ }
+ }
+ break;
+ case 0x2D:
+ INST_NAME("CVTSD2SI Gd, Ex");
+ nextop = F8;
+ GETGD;
+ GETEXSD(v0, 0);
+ if(!box64_dynarec_fastround) {
+ FSFLAGSI(0); // // reset all bits
+ }
+ u8 = sse_setround(dyn, ninst, x2, x3);
+ FCVTLDxw(gd, v0, RD_DYN);
+ x87_restoreround(dyn, ninst, u8);
+ if(!box64_dynarec_fastround) {
+ FRFLAGS(x5); // get back FPSR to check the IOC bit
+ ANDI(x5, x5, (1<<FR_NV)|(1<<FR_OF));
+ CBZ_NEXT(x5);
+ if(rex.w) {
+ MOV64x(gd, 0x8000000000000000LL);
+ } else {
+ MOV32w(gd, 0x80000000);
+ }
+ }
+ break;
+ case 0x38: // these are some more SSSE4.2+ opcodes
+ opcode = F8;
+ switch(opcode) {
+
+ case 0xF0:
+ INST_NAME("(unsupported) CRC32 Gd, Eb)");
+ nextop = F8;
+ addr = fakeed(dyn, addr, ninst, nextop);
+ SETFLAGS(X_ALL, SF_SET); // Hack to set flags in "don't care" state
+ GETIP(ip);
+ STORE_XEMU_CALL();
+ CALL(native_ud, -1);
+ LOAD_XEMU_CALL();
+ jump_to_epilog(dyn, 0, xRIP, ninst);
+ *need_epilog = 0;
+ *ok = 0;
+ break;
+ case 0xF1:
+ INST_NAME("(unsupported) CRC32 Gd, Ed)");
+ nextop = F8;
+ addr = fakeed(dyn, addr, ninst, nextop);
+ SETFLAGS(X_ALL, SF_SET); // Hack to set flags in "don't care" state
+ GETIP(ip);
+ STORE_XEMU_CALL();
+ CALL(native_ud, -1);
+ LOAD_XEMU_CALL();
+ jump_to_epilog(dyn, 0, xRIP, ninst);
+ *need_epilog = 0;
+ *ok = 0;
+ break;
+
+ default:
+ DEFAULT;
+ }
+ break;
+ case 0x51:
+ INST_NAME("SQRTSD Gx, Ex");
+ nextop = F8;
+ GETEXSD(d0, 0);
+ GETGXSD_empty(d1);
+ if(!box64_dynarec_fastnan) {
+ v0 = fpu_get_scratch(dyn); // need a scratch in case d0 == d1
+ FMVDX(v0, xZR);
+ FLTD(x3, d0, v0);
+ }
+ FSQRTD(d1, d0);
+ if(!box64_dynarec_fastnan) {
+ BEQ(x3, xZR, 8);
+ FNEGD(d1, d1);
+ }
+ break;
+ case 0x58:
+ INST_NAME("ADDSD Gx, Ex");
+ nextop = F8;
+ // TODO: fastnan handling
+ GETGXSD(v0);
+ GETEXSD(v1, 0);
+ FADDD(v0, v0, v1);
+ break;
+ case 0x59:
+ INST_NAME("MULSD Gx, Ex");
+ nextop = F8;
+ //TODO: fastnan handling
+ GETGXSD(v0);
+ GETEXSD(v1, 0);
+ FMULD(v0, v0, v1);
+ break;
+ case 0x5A:
+ INST_NAME("CVTSD2SS Gx, Ex");
+ nextop = F8;
+ GETEXSD(v1, 0);
+ GETGXSS_empty(v0);
+ FCVTSD(v0, v1);
+ break;
+ case 0x5C:
+ INST_NAME("SUBSD Gx, Ex");
+ nextop = F8;
+ //TODO: fastnan handling
+ GETGXSD(v0);
+ GETEXSD(v1, 0);
+ FSUBD(v0, v0, v1);
+ break;
+ case 0x5D:
+ INST_NAME("MINSD Gx, Ex");
+ nextop = F8;
+ GETGXSD(v0);
+ GETEXSD(v1, 0);
+ FEQD(x2, v0, v0);
+ FEQD(x3, v1, v1);
+ AND(x2, x2, x3);
+ BEQ_MARK(x2, xZR);
+ FLED(x2, v1, v0);
+ BEQ_MARK2(x2, xZR);
+ MARK;
+ FMVD(v0, v1);
+ MARK2;
+ break;
+ case 0x5E:
+ INST_NAME("DIVSD Gx, Ex");
+ nextop = F8;
+ GETGXSD(v0);
+ GETEXSD(v1, 0);
+ if(!box64_dynarec_fastnan) {
+ FEQD(x3, v0, v0);
+ FEQD(x4, v1, v1);
+ }
+ FDIVD(v0, v0, v1);
+ if(!box64_dynarec_fastnan) {
+ AND(x3, x3, x4);
+ CBZ_NEXT(x3);
+ FEQD(x3, v0, v0);
+ CBNZ_NEXT(x3);
+ FNEGD(v0, v0);
+ }
+ break;
+ case 0x5F:
+ INST_NAME("MAXSD Gx, Ex");
+ nextop = F8;
+ GETGXSD(v0);
+ GETEXSD(v1, 0);
+ FEQD(x2, v0, v0);
+ FEQD(x3, v1, v1);
+ AND(x2, x2, x3);
+ BEQ_MARK(x2, xZR);
+ FLED(x2, v0, v1);
+ BEQ_MARK2(x2, xZR);
+ MARK;
+ FMVD(v0, v1);
+ MARK2;
+ break;
+ case 0x70: // TODO: Optimize this!
+ INST_NAME("PSHUFLW Gx, Ex, Ib");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 1);
+ u8 = F8;
+ int32_t idx;
+
+ idx = (u8>>(0*2))&3;
+ LHU(x3, wback, fixedaddress+idx*2);
+ idx = (u8>>(1*2))&3;
+ LHU(x4, wback, fixedaddress+idx*2);
+ idx = (u8>>(2*2))&3;
+ LHU(x5, wback, fixedaddress+idx*2);
+ idx = (u8>>(3*2))&3;
+ LHU(x6, wback, fixedaddress+idx*2);
+
+ SH(x3, gback, gdoffset+0*2);
+ SH(x4, gback, gdoffset+1*2);
+ SH(x5, gback, gdoffset+2*2);
+ SH(x6, gback, gdoffset+3*2);
+
+ if (!(MODREG && (gd==ed))) {
+ LD(x3, wback, fixedaddress+8);
+ SD(x3, gback, gdoffset+8);
+ }
+ break;
+ case 0xC2:
+ INST_NAME("CMPSD Gx, Ex, Ib");
+ nextop = F8;
+ GETGXSD(d0);
+ GETEXSD(d1, 1);
+ u8 = F8;
+ if ((u8&7) == 0) { // Equal
+ FEQD(x2, d0, d1);
+ } else if ((u8&7) == 4) { // Not Equal or unordered
+ FEQD(x2, d0, d1);
+ XORI(x2, x2, 1);
+ } else {
+ // x2 = !(isnan(d0) || isnan(d1))
+ FEQD(x3, d0, d0);
+ FEQD(x2, d1, d1);
+ AND(x2, x2, x3);
+
+ switch(u8&7) {
+ case 1: BEQ_MARK(x2, xZR); FLTD(x2, d0, d1); break; // Less than
+ case 2: BEQ_MARK(x2, xZR); FLED(x2, d0, d1); break; // Less or equal
+ case 3: XORI(x2, x2, 1); break; // NaN
+ case 5: { // Greater or equal or unordered
+ BEQ_MARK2(x2, xZR);
+ FLED(x2, d1, d0);
+ B_MARK_nocond;
+ break;
+ }
+ case 6: { // Greater or unordered, test inverted, N!=V so unordered or less than (inverted)
+ BEQ_MARK2(x2, xZR);
+ FLTD(x2, d1, d0);
+ B_MARK_nocond;
+ break;
+ }
+ case 7: break; // Not NaN
+ }
+
+ MARK2;
+ if ((u8&7) == 5 || (u8&7) == 6) {
+ MOV32w(x2, 1);
+ }
+ MARK;
+ }
+ NEG(x2, x2);
+ FMVDX(d0, x2);
+ break;
+ case 0xE6:
+ INST_NAME("CVTPD2DQ Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ d0 = fpu_get_scratch(dyn);
+ u8 = sse_setround(dyn, ninst, x6, x4);
+ for (int i=0; i<2 ; ++i) {
+ FLD(d0, wback, fixedaddress+8*i);
+ FCVTLD(x3, d0, RD_DYN);
+ SEXT_W(x5, x3);
+ SUB(x5, x5, x3);
+ BEQZ(x5, 8);
+ LUI(x3, 0x80000); // INT32_MIN
+ SW(x3, gback, gdoffset+4*i);
+ }
+ x87_restoreround(dyn, ninst, u8);
+ SD(xZR, gback, gdoffset+8);
+ break;
+ case 0xF0:
+ INST_NAME("LDDQU Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_MV_Q(x3);
+ break;
+ default:
+ DEFAULT;
+ }
+ return addr;
+}
diff --git a/src/dynarec/rv64/dynarec_rv64_f30f.c b/src/dynarec/rv64/dynarec_rv64_f30f.c
new file mode 100644
index 0000000..0c0676e
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_f30f.c
@@ -0,0 +1,522 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <stddef.h>
+#include <errno.h>
+
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "emu/x64run_private.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "emu/x64run_private.h"
+#include "x64trace.h"
+#include "dynarec_native.h"
+#include "bitutils.h"
+
+#include "rv64_printer.h"
+#include "dynarec_rv64_private.h"
+#include "dynarec_rv64_functions.h"
+#include "dynarec_rv64_helper.h"
+
+uintptr_t dynarec64_F30F(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int* ok, int* need_epilog)
+{
+ (void)ip; (void)need_epilog;
+
+ uint8_t opcode = F8;
+ uint8_t nextop, u8;
+ uint8_t gd, ed;
+ uint8_t wback, gback;
+ uint64_t u64;
+ int v0, v1;
+ int q0, q1;
+ int d0, d1;
+ int64_t fixedaddress, gdoffset;
+ int unscaled;
+ int64_t j64;
+
+ MAYUSE(d0);
+ MAYUSE(d1);
+ MAYUSE(q0);
+ MAYUSE(q1);
+ MAYUSE(v0);
+ MAYUSE(v1);
+ MAYUSE(j64);
+
+ switch(opcode) {
+ case 0x10:
+ INST_NAME("MOVSS Gx, Ex");
+ nextop = F8;
+ GETG;
+ if(MODREG) {
+ v0 = sse_get_reg(dyn, ninst, x1, gd, 1);
+ q0 = sse_get_reg(dyn, ninst, x1, (nextop&7) + (rex.b<<3), 1);
+ FMVS(v0, q0);
+ } else {
+ v0 = sse_get_reg_empty(dyn, ninst, x1, gd, 1);
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, x2, &fixedaddress, rex, NULL, 8, 0);
+ FLW(v0, ed, fixedaddress);
+ // reset upper part
+ SW(xZR, xEmu, offsetof(x64emu_t, xmm[gd])+4);
+ SD(xZR, xEmu, offsetof(x64emu_t, xmm[gd])+8);
+ }
+ break;
+ case 0x11:
+ INST_NAME("MOVSS Ex, Gx");
+ nextop = F8;
+ GETG;
+ v0 = sse_get_reg(dyn, ninst, x1, gd, 1);
+ if(MODREG) {
+ q0 = sse_get_reg(dyn, ninst, x1, (nextop&7) + (rex.b<<3), 1);
+ FMVS(q0, v0);
+ } else {
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, x2, &fixedaddress, rex, NULL, 1, 0);
+ FSW(v0, ed, fixedaddress);
+ SMWRITE2();
+ }
+ break;
+
+ case 0x12:
+ INST_NAME("MOVSLDUP Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+
+ // GX->ud[1] = GX->ud[0] = EX->ud[0];
+ // GX->ud[3] = GX->ud[2] = EX->ud[2];
+ LD(x3, wback, fixedaddress+0);
+ SD(x3, gback, gdoffset+0);
+ SD(x3, gback, gdoffset+4);
+ LD(x3, wback, fixedaddress+8);
+ SD(x3, gback, gdoffset+8);
+ SD(x3, gback, gdoffset+12);
+ break;
+ case 0x1E:
+ INST_NAME("NOP / ENDBR32 / ENDBR64");
+ nextop = F8;
+ FAKEED;
+ break;
+
+ case 0x2A:
+ INST_NAME("CVTSI2SS Gx, Ed");
+ nextop = F8;
+ GETGXSS(v0);
+ GETED(0);
+ if(rex.w) {
+ FCVTSL(v0, ed, RD_RNE);
+ } else {
+ FCVTSW(v0, ed, RD_RNE);
+ }
+ break;
+
+ case 0x2C:
+ INST_NAME("CVTTSS2SI Gd, Ex");
+ nextop = F8;
+ GETGD;
+ GETEXSS(d0, 0);
+ if(!box64_dynarec_fastround) {
+ FSFLAGSI(0); // // reset all bits
+ }
+ FCVTSxw(gd, d0, RD_RTZ);
+ if(!rex.w)
+ ZEROUP(gd);
+ if(!box64_dynarec_fastround) {
+ FRFLAGS(x5); // get back FPSR to check the IOC bit
+ ANDI(x5, x5, (1<<FR_NV)|(1<<FR_OF));
+ CBZ_NEXT(x5);
+ if(rex.w) {
+ MOV64x(gd, 0x8000000000000000LL);
+ } else {
+ MOV32w(gd, 0x80000000);
+ }
+ }
+ break;
+ case 0x2D:
+ INST_NAME("CVTSS2SI Gd, Ex");
+ nextop = F8;
+ GETGD;
+ GETEXSS(d0, 0);
+ if(!box64_dynarec_fastround) {
+ FSFLAGSI(0); // // reset all bits
+ }
+ u8 = sse_setround(dyn, ninst, x5, x6);
+ FCVTSxw(gd, d0, RD_DYN);
+ x87_restoreround(dyn, ninst, u8);
+ if(!rex.w)
+ ZEROUP(gd);
+ if(!box64_dynarec_fastround) {
+ FRFLAGS(x5); // get back FPSR to check the IOC bit
+ ANDI(x5, x5, (1<<FR_NV)|(1<<FR_OF));
+ CBZ_NEXT(x5);
+ if(rex.w) {
+ MOV64x(gd, 0x8000000000000000LL);
+ } else {
+ MOV32w(gd, 0x80000000);
+ }
+ }
+ break;
+
+ case 0x51:
+ INST_NAME("SQRTSS Gx, Ex");
+ nextop = F8;
+ GETEXSS(v0, 0);
+ GETGXSS_empty(v1);
+ FSQRTS(v1, v0);
+ break;
+ case 0x53:
+ INST_NAME("RCPSS Gx, Ex");
+ nextop = F8;
+ GETEXSS(v0, 0);
+ GETGXSS_empty(v1);
+ q0 = fpu_get_scratch(dyn);
+ LUI(x3, 0x3F800); // 1.0f
+ FMVWX(q0, x3);
+ FDIVS(v1, q0, v0);
+ break;
+ case 0x58:
+ INST_NAME("ADDSS Gx, Ex");
+ nextop = F8;
+ GETGXSS(v0);
+ GETEXSS(d0, 0);
+ FADDS(v0, v0, d0);
+ break;
+ case 0x59:
+ INST_NAME("MULSS Gx, Ex");
+ nextop = F8;
+ GETGXSS(v0);
+ GETEXSS(d0, 0);
+ FMULS(v0, v0, d0);
+ break;
+ case 0x5A:
+ INST_NAME("CVTSS2SD Gx, Ex");
+ nextop = F8;
+ GETEXSS(v1, 0);
+ GETGXSD_empty(v0);
+ FCVTDS(v0, v1);
+ break;
+ case 0x5C:
+ INST_NAME("SUBSS Gx, Ex");
+ nextop = F8;
+ GETGXSS(v0);
+ GETEXSS(d0, 0);
+ FSUBS(v0, v0, d0);
+ break;
+ case 0x5D:
+ INST_NAME("MINSS Gx, Ex");
+ nextop = F8;
+ GETGXSS(d0);
+ GETEXSS(d1, 0);
+ FEQS(x2, d0, d0);
+ FEQS(x3, d1, d1);
+ AND(x2, x2, x3);
+ BEQ_MARK(x2, xZR);
+ FLTS(x2, d1, d0);
+ BEQ_MARK2(x2, xZR);
+ MARK;
+ FMVS(d0, d1);
+ MARK2;
+ break;
+ case 0x5E:
+ INST_NAME("DIVSS Gx, Ex");
+ nextop = F8;
+ GETGXSS(v0);
+ GETEXSS(d0, 0);
+ FDIVS(v0, v0, d0);
+ break;
+ case 0x5F:
+ INST_NAME("MAXSS Gx, Ex");
+ nextop = F8;
+ GETGXSS(d0);
+ GETEXSS(d1, 0);
+ FEQS(x2, d0, d0);
+ FEQS(x3, d1, d1);
+ AND(x2, x2, x3);
+ BEQ_MARK(x2, xZR);
+ FLTS(x2, d0, d1);
+ BEQ_MARK2(x2, xZR);
+ MARK;
+ FMVS(d0, d1);
+ MARK2;
+ break;
+ case 0x6F:
+ INST_NAME("MOVDQU Gx,Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_MV_Q(x3);
+ break;
+ case 0x70: // TODO: Optimize this!
+ INST_NAME("PSHUFHW Gx, Ex, Ib");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 1);
+ u8 = F8;
+ int32_t idx;
+
+ idx = 4+((u8>>(0*2))&3);
+ LHU(x3, wback, fixedaddress+idx*2);
+ idx = 4+((u8>>(1*2))&3);
+ LHU(x4, wback, fixedaddress+idx*2);
+ idx = 4+((u8>>(2*2))&3);
+ LHU(x5, wback, fixedaddress+idx*2);
+ idx = 4+((u8>>(3*2))&3);
+ LHU(x6, wback, fixedaddress+idx*2);
+
+ SH(x3, gback, gdoffset+(4+0)*2);
+ SH(x4, gback, gdoffset+(4+1)*2);
+ SH(x5, gback, gdoffset+(4+2)*2);
+ SH(x6, gback, gdoffset+(4+3)*2);
+
+ if (!(MODREG && (gd==ed))) {
+ LD(x3, wback, fixedaddress+0);
+ SD(x3, gback, gdoffset+0);
+ }
+ break;
+ case 0x7E:
+ INST_NAME("MOVQ Gx, Ex");
+ nextop = F8;
+ // Will load Gx as SD. Is that a good choice?
+ if(MODREG) {
+ v1 = sse_get_reg(dyn, ninst, x1, (nextop&7) + (rex.b<<3), 0);
+ GETGXSD_empty(v0);
+ FMVD(v0, v1);
+ } else {
+ GETGXSD_empty(v0);
+ SMREAD();
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, x2, &fixedaddress, rex, NULL, 1, 0);
+ FLD(v0, ed, fixedaddress);
+ }
+ SD(xZR, xEmu, offsetof(x64emu_t, xmm[gd])+8);
+ break;
+ case 0x7F:
+ INST_NAME("MOVDQU Ex,Gx");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ SSE_LOOP_MV_Q2(x3);
+ if(!MODREG) SMWRITE2();
+ break;
+
+ case 0x5B:
+ INST_NAME("CVTTPS2DQ Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ v0 = fpu_get_scratch(dyn);
+ for(int i=0; i<4; ++i) {
+ if(!box64_dynarec_fastround) {
+ FSFLAGSI(0); // reset all bits
+ }
+ FLW(v0, wback, fixedaddress+i*4);
+ FCVTWS(x3, v0, RD_RTZ);
+ if(!box64_dynarec_fastround) {
+ FRFLAGS(x5); // get back FPSR to check the IOC bit
+ ANDI(x5, x5, (1<<FR_NV)|(1<<FR_OF));
+ BEQZ(x5, 8);
+ MOV32w(x3, 0x80000000);
+ }
+ SW(x3, gback, gdoffset+i*4);
+ }
+ break;
+ case 0xB8:
+ INST_NAME("POPCNT Gd, Ed");
+ SETFLAGS(X_ALL, SF_SET);
+ SET_DFNONE();
+ nextop = F8;
+ GETED(0);
+ GETGD;
+ if(!rex.w && MODREG) {
+ AND(x4, ed, xMASK);
+ ed = x4;
+ }
+ CLEAR_FLAGS();
+ BNE_MARK(ed, xZR);
+ ORI(xFlags, xFlags, 1<<F_ZF);
+ MOV32w(gd, 0);
+ B_NEXT_nocond;
+ MARK;
+ if(rv64_zbb) {
+ CPOPxw(gd, ed);
+ } else {
+ TABLE64(x1, 0x5555555555555555uLL);
+ SRLI(x5, ed, 1);
+ AND(x5, x5, x1);
+ SUB(x5, ed, x5);
+ TABLE64(x3, 0x3333333333333333uLL);
+ SRLI(x1, x5, 2);
+ AND(x1, x1, x3);
+ AND(x5, x5, x3);
+ ADD(x5, x5, x1);
+ TABLE64(x3, 0x0F0F0F0F0F0F0F0FuLL);
+ SRLI(x1, x5, 4);
+ ADD(x5, x5, x1);
+ AND(x5, x5, x3);
+ SRLI(x1, x5, 32);
+ ADDW(x5, x5, x1);
+ SRLIW(x1, x5, 16);
+ ADDW(x5, x5, x1);
+ SRLIW(x1, x5, 8);
+ ADDW(x5, x5, x1);
+ ANDI(gd, x5, 0x7F);
+ }
+ break;
+ case 0xBC:
+ INST_NAME("TZCNT Gd, Ed");
+ SETFLAGS(X_ZF, SF_SUBSET);
+ SET_DFNONE();
+ nextop = F8;
+ GETED(0);
+ GETGD;
+ if(!rex.w && MODREG) {
+ AND(x4, ed, xMASK);
+ ed = x4;
+ }
+ ANDI(xFlags, xFlags, ~((1<<F_ZF) | (1<<F_CF)));
+ BNE_MARK(ed, xZR);
+ ORI(xFlags, xFlags, 1<<F_CF);
+ MOV32w(gd, rex.w?64:32);
+ B_NEXT_nocond;
+ MARK;
+ if(rv64_zbb) {
+ CTZxw(gd, ed);
+ } else {
+ NEG(x2, ed);
+ AND(x2, x2, ed);
+ TABLE64(x3, 0x03f79d71b4ca8b09ULL);
+ MUL(x2, x2, x3);
+ SRLI(x2, x2, 64-6);
+ TABLE64(x1, (uintptr_t)&deBruijn64tab);
+ ADD(x1, x1, x2);
+ LBU(gd, x1, 0);
+ }
+ BNE(gd, xZR, 4+4);
+ ORI(xFlags, xFlags, 1<<F_ZF);
+ break;
+ case 0xBD:
+ INST_NAME("LZCNT Gd, Ed");
+ SETFLAGS(X_ZF|X_CF, SF_SUBSET);
+ SET_DFNONE();
+ nextop = F8;
+ GETED(0);
+ GETGD;
+ if(!rex.w && MODREG) {
+ AND(x4, ed, xMASK);
+ ed = x4;
+ }
+ BNE_MARK(ed, xZR);
+ MOV32w(gd, rex.w?64:32);
+ ANDI(xFlags, xFlags, ~(1<<F_ZF));
+ ORI(xFlags, xFlags, 1<<F_CF);
+ B_NEXT_nocond;
+ MARK;
+ if(rv64_zbb) {
+ CLZxw(gd, ed);
+ } else {
+ if(ed!=gd)
+ u8 = gd;
+ else
+ u8 = x1;
+ ADDI(u8, xZR, rex.w?63:31);
+ if(rex.w) {
+ MV(x2, ed);
+ SRLI(x3, x2, 32);
+ BEQZ(x3, 4+2*4);
+ SUBI(u8, u8, 32);
+ MV(x2, x3);
+ } else {
+ AND(x2, ed, xMASK);
+ }
+ SRLI(x3, x2, 16);
+ BEQZ(x3, 4+2*4);
+ SUBI(u8, u8, 16);
+ MV(x2, x3);
+ SRLI(x3, x2, 8);
+ BEQZ(x3, 4+2*4);
+ SUBI(u8, u8, 8);
+ MV(x2, x3);
+ SRLI(x3, x2, 4);
+ BEQZ(x3, 4+2*4);
+ SUBI(u8, u8, 4);
+ MV(x2, x3);
+ ANDI(x2, x2, 0b1111);
+ TABLE64(x3, (uintptr_t)&lead0tab);
+ ADD(x3, x3, x2);
+ LBU(x2, x3, 0);
+ SUB(gd, u8, x2);
+ MARK2;
+ }
+ ANDI(xFlags, xFlags, ~((1<<F_ZF) | (1<<F_CF)));
+ BNE(gd, xZR, 4+4);
+ ORI(xFlags, xFlags, 1<<F_ZF);
+ break;
+
+ case 0xC2:
+ INST_NAME("CMPSS Gx, Ex, Ib");
+ nextop = F8;
+ GETGXSS(d0);
+ GETEXSS(d1, 1);
+ u8 = F8;
+ if ((u8&7) == 0) { // Equal
+ FEQS(x2, d0, d1);
+ } else if ((u8&7) == 4) { // Not Equal or unordered
+ FEQS(x2, d0, d1);
+ XORI(x2, x2, 1);
+ } else {
+ // x2 = !(isnan(d0) || isnan(d1))
+ FEQS(x3, d0, d0);
+ FEQS(x2, d1, d1);
+ AND(x2, x2, x3);
+
+ switch(u8&7) {
+ case 1: BEQ_MARK(x2, xZR); FLTS(x2, d0, d1); break; // Less than
+ case 2: BEQ_MARK(x2, xZR); FLES(x2, d0, d1); break; // Less or equal
+ case 3: XORI(x2, x2, 1); break; // NaN
+ case 5: { // Greater or equal or unordered
+ BEQ_MARK2(x2, xZR);
+ FLES(x2, d1, d0);
+ B_MARK_nocond;
+ break;
+ }
+ case 6: { // Greater or unordered, test inverted, N!=V so unordered or less than (inverted)
+ BEQ_MARK2(x2, xZR);
+ FLTS(x2, d1, d0);
+ B_MARK_nocond;
+ break;
+ }
+ case 7: break; // Not NaN
+ }
+
+ MARK2;
+ if ((u8&7) == 5 || (u8&7) == 6) {
+ MOV32w(x2, 1);
+ }
+ MARK;
+ }
+ NEG(x2, x2);
+ FMVWX(d0, x2);
+ break;
+
+ case 0xE6:
+ INST_NAME("CVTDQ2PD Gx, Ex");
+ nextop = F8;
+ GETGX();
+ GETEX(x2, 0);
+ q0 = fpu_get_scratch(dyn);
+ q1 = fpu_get_scratch(dyn);
+ LW(x3, wback, fixedaddress+0);
+ LW(x4, wback, fixedaddress+4);
+ FCVTDW(q0, x3, RD_RTZ);
+ FCVTDW(q1, x4, RD_RTZ);
+ FSD(q0, gback, gdoffset+0);
+ FSD(q1, gback, gdoffset+8);
+ break;
+
+ default:
+ DEFAULT;
+ }
+ return addr;
+}
diff --git a/src/dynarec/rv64/dynarec_rv64_functions.c b/src/dynarec/rv64/dynarec_rv64_functions.c
new file mode 100644
index 0000000..541ac45
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_functions.c
@@ -0,0 +1,564 @@
+#define _GNU_SOURCE
+#include <stdio.h>
+#include <stdlib.h>
+#include <errno.h>
+#include <string.h>
+#include <math.h>
+#include <signal.h>
+#include <sys/types.h>
+#include <unistd.h>
+
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "emu/x64run_private.h"
+#include "emu/x87emu_private.h"
+#include "x64trace.h"
+#include "signals.h"
+#include "dynarec_rv64.h"
+#include "dynarec_rv64_private.h"
+#include "dynarec_rv64_functions.h"
+#include "custommem.h"
+#include "bridge.h"
+#include "rv64_lock.h"
+
+#define XMM0 0
+#define X870 XMM0+16
+#define EMM0 XMM0+16
+
+// Get a FPU scratch reg
+int fpu_get_scratch(dynarec_rv64_t* dyn)
+{
+ return SCRATCH0 + dyn->e.fpu_scratch++; // return an Sx
+}
+// Reset scratch regs counter
+void fpu_reset_scratch(dynarec_rv64_t* dyn)
+{
+ dyn->e.fpu_scratch = 0;
+}
+// Get a x87 double reg
+int fpu_get_reg_x87(dynarec_rv64_t* dyn, int t, int n)
+{
+ int i=X870;
+ while (dyn->e.fpuused[i]) ++i;
+ dyn->e.fpuused[i] = 1;
+ dyn->e.extcache[i].n = n;
+ dyn->e.extcache[i].t = t;
+ dyn->e.news |= (1<<i);
+ return EXTREG(i); // return a Dx
+}
+// Free a FPU reg
+void fpu_free_reg(dynarec_rv64_t* dyn, int reg)
+{
+ int idx = EXTIDX(reg);
+ // TODO: check upper limit?
+ dyn->e.fpuused[idx] = 0;
+ if(dyn->e.extcache[reg].t!=EXT_CACHE_ST_F && dyn->e.extcache[reg].t!=EXT_CACHE_ST_D)
+ dyn->e.extcache[idx].v = 0;
+}
+// Get an MMX double reg
+int fpu_get_reg_emm(dynarec_rv64_t* dyn, int emm)
+{
+ dyn->e.fpuused[EMM0 + emm] = 1;
+ dyn->e.extcache[EMM0 + emm].t = EXT_CACHE_MM;
+ dyn->e.extcache[EMM0 + emm].n = emm;
+ dyn->e.news |= (1<<(EMM0 + emm));
+ return EXTREG(EMM0 + emm);
+}
+// Get an XMM reg
+int fpu_get_reg_xmm(dynarec_rv64_t* dyn, int t, int xmm)
+{
+ int i = XMM0+xmm;
+ dyn->e.fpuused[i] = 1;
+ dyn->e.extcache[i].t = t;
+ dyn->e.extcache[i].n = xmm;
+ dyn->e.news |= (1<<i);
+ return EXTREG(i);
+}
+// Reset fpu regs counter
+void fpu_reset_reg(dynarec_rv64_t* dyn)
+{
+ dyn->e.fpu_reg = 0;
+ for (int i=0; i<24; ++i) {
+ dyn->e.fpuused[i]=0;
+ dyn->e.extcache[i].v = 0;
+ }
+}
+
+int extcache_get_st(dynarec_rv64_t* dyn, int ninst, int a)
+{
+ if (dyn->insts[ninst].e.swapped) {
+ if(dyn->insts[ninst].e.combined1 == a)
+ a = dyn->insts[ninst].e.combined2;
+ else if(dyn->insts[ninst].e.combined2 == a)
+ a = dyn->insts[ninst].e.combined1;
+ }
+ for(int i=0; i<24; ++i)
+ if((dyn->insts[ninst].e.extcache[i].t==EXT_CACHE_ST_F
+ || dyn->insts[ninst].e.extcache[i].t==EXT_CACHE_ST_D)
+ && dyn->insts[ninst].e.extcache[i].n==a)
+ return dyn->insts[ninst].e.extcache[i].t;
+ // not in the cache yet, so will be fetched...
+ return EXT_CACHE_ST_D;
+}
+
+int extcache_get_current_st(dynarec_rv64_t* dyn, int ninst, int a)
+{
+ (void)ninst;
+ if(!dyn->insts)
+ return EXT_CACHE_ST_D;
+ for(int i=0; i<24; ++i)
+ if((dyn->e.extcache[i].t==EXT_CACHE_ST_F
+ || dyn->e.extcache[i].t==EXT_CACHE_ST_D)
+ && dyn->e.extcache[i].n==a)
+ return dyn->e.extcache[i].t;
+ // not in the cache yet, so will be fetched...
+ return EXT_CACHE_ST_D;
+}
+
+int extcache_get_st_f(dynarec_rv64_t* dyn, int ninst, int a)
+{
+ for(int i=0; i<24; ++i)
+ if(dyn->insts[ninst].e.extcache[i].t==EXT_CACHE_ST_F
+ && dyn->insts[ninst].e.extcache[i].n==a)
+ return i;
+ return -1;
+}
+int extcache_get_st_f_noback(dynarec_rv64_t* dyn, int ninst, int a)
+{
+ for(int i=0; i<24; ++i)
+ if(dyn->insts[ninst].e.extcache[i].t==EXT_CACHE_ST_F
+ && dyn->insts[ninst].e.extcache[i].n==a)
+ return i;
+ return -1;
+}
+int extcache_get_current_st_f(dynarec_rv64_t* dyn, int a)
+{
+ for(int i=0; i<24; ++i)
+ if(dyn->e.extcache[i].t==EXT_CACHE_ST_F
+ && dyn->e.extcache[i].n==a)
+ return i;
+ return -1;
+}
+
+static void extcache_promote_double_forward(dynarec_rv64_t* dyn, int ninst, int maxinst, int a);
+static void extcache_promote_double_internal(dynarec_rv64_t* dyn, int ninst, int maxinst, int a);
+static void extcache_promote_double_combined(dynarec_rv64_t* dyn, int ninst, int maxinst, int a)
+{
+ if(a == dyn->insts[ninst].e.combined1 || a == dyn->insts[ninst].e.combined2) {
+ if(a == dyn->insts[ninst].e.combined1) {
+ a = dyn->insts[ninst].e.combined2;
+ } else
+ a = dyn->insts[ninst].e.combined1;
+ int i = extcache_get_st_f_noback(dyn, ninst, a);
+ //if(box64_dynarec_dump) dynarec_log(LOG_NONE, "extcache_promote_double_combined, ninst=%d combined%c %d i=%d (stack:%d/%d)\n", ninst, (a == dyn->insts[ninst].e.combined2)?'2':'1', a ,i, dyn->insts[ninst].e.stack_push, -dyn->insts[ninst].e.stack_pop);
+ if(i>=0) {
+ dyn->insts[ninst].e.extcache[i].t = EXT_CACHE_ST_D;
+ if(!dyn->insts[ninst].e.barrier)
+ extcache_promote_double_internal(dyn, ninst-1, maxinst, a-dyn->insts[ninst].e.stack_push);
+ // go forward is combined is not pop'd
+ if(a-dyn->insts[ninst].e.stack_pop>=0)
+ if(!dyn->insts[ninst+1].e.barrier)
+ extcache_promote_double_forward(dyn, ninst+1, maxinst, a-dyn->insts[ninst].e.stack_pop);
+ }
+ }
+}
+static void extcache_promote_double_internal(dynarec_rv64_t* dyn, int ninst, int maxinst, int a)
+{
+ if(dyn->insts[ninst+1].e.barrier)
+ return;
+ while(ninst>=0) {
+ a+=dyn->insts[ninst].e.stack_pop; // adjust Stack depth: add pop'd ST (going backward)
+ int i = extcache_get_st_f(dyn, ninst, a);
+ //if(box64_dynarec_dump) dynarec_log(LOG_NONE, "extcache_promote_double_internal, ninst=%d, a=%d st=%d:%d, i=%d\n", ninst, a, dyn->insts[ninst].e.stack, dyn->insts[ninst].e.stack_next, i);
+ if(i<0) return;
+ dyn->insts[ninst].e.extcache[i].t = EXT_CACHE_ST_D;
+ // check combined propagation too
+ if(dyn->insts[ninst].e.combined1 || dyn->insts[ninst].e.combined2) {
+ if(dyn->insts[ninst].e.swapped) {
+ //if(box64_dynarec_dump) dynarec_log(LOG_NONE, "extcache_promote_double_internal, ninst=%d swapped %d/%d vs %d with st %d\n", ninst, dyn->insts[ninst].e.combined1 ,dyn->insts[ninst].e.combined2, a, dyn->insts[ninst].e.stack);
+ if (a==dyn->insts[ninst].e.combined1)
+ a = dyn->insts[ninst].e.combined2;
+ else if (a==dyn->insts[ninst].e.combined2)
+ a = dyn->insts[ninst].e.combined1;
+ } else {
+ //if(box64_dynarec_dump) dynarec_log(LOG_NONE, "extcache_promote_double_internal, ninst=%d combined %d/%d vs %d with st %d\n", ninst, dyn->insts[ninst].e.combined1 ,dyn->insts[ninst].e.combined2, a, dyn->insts[ninst].e.stack);
+ extcache_promote_double_combined(dyn, ninst, maxinst, a);
+ }
+ }
+ a-=dyn->insts[ninst].e.stack_push; // // adjust Stack depth: remove push'd ST (going backward)
+ --ninst;
+ if(ninst<0 || a<0 || dyn->insts[ninst].e.barrier)
+ return;
+ }
+}
+
+static void extcache_promote_double_forward(dynarec_rv64_t* dyn, int ninst, int maxinst, int a)
+{
+ while((ninst!=-1) && (ninst<maxinst) && (a>=0)) {
+ a+=dyn->insts[ninst].e.stack_push; // // adjust Stack depth: add push'd ST (going forward)
+ if((dyn->insts[ninst].e.combined1 || dyn->insts[ninst].e.combined2) && dyn->insts[ninst].e.swapped) {
+ //if(box64_dynarec_dump) dynarec_log(LOG_NONE, "extcache_promote_double_forward, ninst=%d swapped %d/%d vs %d with st %d\n", ninst, dyn->insts[ninst].e.combined1 ,dyn->insts[ninst].e.combined2, a, dyn->insts[ninst].e.stack);
+ if (a==dyn->insts[ninst].e.combined1)
+ a = dyn->insts[ninst].e.combined2;
+ else if (a==dyn->insts[ninst].e.combined2)
+ a = dyn->insts[ninst].e.combined1;
+ }
+ int i = extcache_get_st_f_noback(dyn, ninst, a);
+ //if(box64_dynarec_dump) dynarec_log(LOG_NONE, "extcache_promote_double_forward, ninst=%d, a=%d st=%d:%d(%d/%d), i=%d\n", ninst, a, dyn->insts[ninst].e.stack, dyn->insts[ninst].e.stack_next, dyn->insts[ninst].e.stack_push, -dyn->insts[ninst].e.stack_pop, i);
+ if(i<0) return;
+ dyn->insts[ninst].e.extcache[i].t = EXT_CACHE_ST_D;
+ // check combined propagation too
+ if((dyn->insts[ninst].e.combined1 || dyn->insts[ninst].e.combined2) && !dyn->insts[ninst].e.swapped) {
+ //if(box64_dynarec_dump) dynarec_log(LOG_NONE, "extcache_promote_double_forward, ninst=%d combined %d/%d vs %d with st %d\n", ninst, dyn->insts[ninst].e.combined1 ,dyn->insts[ninst].e.combined2, a, dyn->insts[ninst].e.stack);
+ extcache_promote_double_combined(dyn, ninst, maxinst, a);
+ }
+ a-=dyn->insts[ninst].e.stack_pop; // adjust Stack depth: remove pop'd ST (going forward)
+ if(dyn->insts[ninst].x64.has_next && !dyn->insts[ninst].e.barrier)
+ ++ninst;
+ else
+ ninst=-1;
+ }
+ if(ninst==maxinst)
+ extcache_promote_double(dyn, ninst, a);
+}
+
+void extcache_promote_double(dynarec_rv64_t* dyn, int ninst, int a)
+{
+ int i = extcache_get_current_st_f(dyn, a);
+ //if(box64_dynarec_dump) dynarec_log(LOG_NONE, "extcache_promote_double, ninst=%d a=%d st=%d i=%d\n", ninst, a, dyn->e.stack, i);
+ if(i<0) return;
+ dyn->e.extcache[i].t = EXT_CACHE_ST_D;
+ dyn->insts[ninst].e.extcache[i].t = EXT_CACHE_ST_D;
+ // check combined propagation too
+ if(dyn->e.combined1 || dyn->e.combined2) {
+ if(dyn->e.swapped) {
+ //if(box64_dynarec_dump) dynarec_log(LOG_NONE, "extcache_promote_double, ninst=%d swapped! %d/%d vs %d\n", ninst, dyn->e.combined1 ,dyn->e.combined2, a);
+ if(dyn->e.combined1 == a)
+ a = dyn->e.combined2;
+ else if(dyn->e.combined2 == a)
+ a = dyn->e.combined1;
+ } else {
+ //if(box64_dynarec_dump) dynarec_log(LOG_NONE, "extcache_promote_double, ninst=%d combined! %d/%d vs %d\n", ninst, dyn->e.combined1 ,dyn->e.combined2, a);
+ if(dyn->e.combined1 == a)
+ extcache_promote_double(dyn, ninst, dyn->e.combined2);
+ else if(dyn->e.combined2 == a)
+ extcache_promote_double(dyn, ninst, dyn->e.combined1);
+ }
+ }
+ a-=dyn->insts[ninst].e.stack_push; // // adjust Stack depth: remove push'd ST (going backward)
+ if(!ninst || a<0) return;
+ extcache_promote_double_internal(dyn, ninst-1, ninst, a);
+}
+
+int extcache_combine_st(dynarec_rv64_t* dyn, int ninst, int a, int b)
+{
+ dyn->e.combined1=a;
+ dyn->e.combined2=b;
+ if( extcache_get_current_st(dyn, ninst, a)==EXT_CACHE_ST_F
+ && extcache_get_current_st(dyn, ninst, b)==EXT_CACHE_ST_F )
+ return EXT_CACHE_ST_F;
+ return EXT_CACHE_ST_D;
+}
+
+static int isCacheEmpty(dynarec_native_t* dyn, int ninst) {
+ if(dyn->insts[ninst].e.stack_next) {
+ return 0;
+ }
+ for(int i=0; i<24; ++i)
+ if(dyn->insts[ninst].e.extcache[i].v) { // there is something at ninst for i
+ if(!(
+ (dyn->insts[ninst].e.extcache[i].t==EXT_CACHE_ST_F || dyn->insts[ninst].e.extcache[i].t==EXT_CACHE_ST_D)
+ && dyn->insts[ninst].e.extcache[i].n<dyn->insts[ninst].e.stack_pop))
+ return 0;
+ }
+ return 1;
+
+}
+
+int fpuCacheNeedsTransform(dynarec_rv64_t* dyn, int ninst) {
+ int i2 = dyn->insts[ninst].x64.jmp_insts;
+ if(i2<0)
+ return 1;
+ if((dyn->insts[i2].x64.barrier&BARRIER_FLOAT))
+ // if the barrier as already been apply, no transform needed
+ return ((dyn->insts[ninst].x64.barrier&BARRIER_FLOAT))?0:(isCacheEmpty(dyn, ninst)?0:1);
+ int ret = 0;
+ if(!i2) { // just purge
+ if(dyn->insts[ninst].e.stack_next) {
+ return 1;
+ }
+ for(int i=0; i<24 && !ret; ++i)
+ if(dyn->insts[ninst].e.extcache[i].v) { // there is something at ninst for i
+ if(!(
+ (dyn->insts[ninst].e.extcache[i].t==EXT_CACHE_ST_F || dyn->insts[ninst].e.extcache[i].t==EXT_CACHE_ST_D)
+ && dyn->insts[ninst].e.extcache[i].n<dyn->insts[ninst].e.stack_pop))
+ ret = 1;
+ }
+ return ret;
+ }
+ // Check if ninst can be compatible to i2
+ if(dyn->insts[ninst].e.stack_next != dyn->insts[i2].e.stack-dyn->insts[i2].e.stack_push) {
+ return 1;
+ }
+ extcache_t cache_i2 = dyn->insts[i2].e;
+ extcacheUnwind(&cache_i2);
+
+ for(int i=0; i<24; ++i) {
+ if(dyn->insts[ninst].e.extcache[i].v) { // there is something at ninst for i
+ if(!cache_i2.extcache[i].v) { // but there is nothing at i2 for i
+ ret = 1;
+ } else if(dyn->insts[ninst].e.extcache[i].v!=cache_i2.extcache[i].v) { // there is something different
+ ret = 1;
+ }
+ } else if(cache_i2.extcache[i].v)
+ ret = 1;
+ }
+ return ret;
+}
+
+void extcacheUnwind(extcache_t* cache)
+{
+ if(cache->swapped) {
+ // unswap
+ int a = -1;
+ int b = -1;
+ for(int j=0; j<24 && ((a==-1) || (b==-1)); ++j)
+ if((cache->extcache[j].t == EXT_CACHE_ST_D || cache->extcache[j].t == EXT_CACHE_ST_F)) {
+ if(cache->extcache[j].n == cache->combined1)
+ a = j;
+ else if(cache->extcache[j].n == cache->combined2)
+ b = j;
+ }
+ if(a!=-1 && b!=-1) {
+ int tmp = cache->extcache[a].n;
+ cache->extcache[a].n = cache->extcache[b].n;
+ cache->extcache[b].n = tmp;
+ }
+ cache->swapped = 0;
+ cache->combined1 = cache->combined2 = 0;
+ }
+ if(cache->news) {
+ // remove the newly created extcache
+ for(int i=0; i<24; ++i)
+ if(cache->news&(1<<i))
+ cache->extcache[i].v = 0;
+ cache->news = 0;
+ }
+ // add/change bad regs
+ for(int i=0; i<16; ++i) {
+ if(cache->olds[i].changed) {
+ cache->extcache[i].t = cache->olds[i].single?EXT_CACHE_SS:EXT_CACHE_SD;
+ } else if(cache->olds[i].purged) {
+ cache->extcache[i].n = i;
+ cache->extcache[i].t = cache->olds[i].single?EXT_CACHE_SS:EXT_CACHE_SD;
+ }
+ }
+ if(cache->stack_push) {
+ // unpush
+ for(int j=0; j<24; ++j) {
+ if((cache->extcache[j].t == EXT_CACHE_ST_D || cache->extcache[j].t == EXT_CACHE_ST_F)) {
+ if(cache->extcache[j].n<cache->stack_push)
+ cache->extcache[j].v = 0;
+ else
+ cache->extcache[j].n-=cache->stack_push;
+ }
+ }
+ cache->x87stack-=cache->stack_push;
+ cache->stack-=cache->stack_push;
+ cache->stack_push = 0;
+ }
+ cache->x87stack+=cache->stack_pop;
+ cache->stack_next = cache->stack;
+ cache->stack_pop = 0;
+ cache->barrier = 0;
+ // And now, rebuild the x87cache info with extcache
+ cache->mmxcount = 0;
+ cache->fpu_scratch = 0;
+ cache->fpu_extra_qscratch = 0;
+ cache->fpu_reg = 0;
+ for(int i=0; i<8; ++i) {
+ cache->x87cache[i] = -1;
+ cache->mmxcache[i] = -1;
+ cache->x87reg[i] = 0;
+ cache->ssecache[i*2].v = -1;
+ cache->ssecache[i*2+1].v = -1;
+ }
+ int x87reg = 0;
+ for(int i=0; i<24; ++i) {
+ if(cache->extcache[i].v) {
+ cache->fpuused[i] = 1;
+ switch (cache->extcache[i].t) {
+ case EXT_CACHE_MM:
+ cache->mmxcache[cache->extcache[i].n] = EXTREG(i);
+ ++cache->mmxcount;
+ ++cache->fpu_reg;
+ break;
+ case EXT_CACHE_SS:
+ cache->ssecache[cache->extcache[i].n].reg = EXTREG(i);
+ cache->ssecache[cache->extcache[i].n].single = 1;
+ ++cache->fpu_reg;
+ break;
+ case EXT_CACHE_SD:
+ cache->ssecache[cache->extcache[i].n].reg = EXTREG(i);
+ cache->ssecache[cache->extcache[i].n].single = 0;
+ ++cache->fpu_reg;
+ break;
+ case EXT_CACHE_ST_F:
+ case EXT_CACHE_ST_D:
+ cache->x87cache[x87reg] = cache->extcache[i].n;
+ cache->x87reg[x87reg] = EXTREG(i);
+ ++x87reg;
+ ++cache->fpu_reg;
+ break;
+ case EXT_CACHE_SCR:
+ cache->fpuused[i] = 0;
+ cache->extcache[i].v = 0;
+ break;
+ }
+ } else {
+ cache->fpuused[i] = 0;
+ }
+ }
+}
+
+
+uint8_t extract_byte(uint32_t val, void* address){
+ int idx = (((uintptr_t)address)&3)*8;
+ return (val>>idx)&0xff;
+}
+uint32_t insert_byte(uint32_t val, uint8_t b, void* address){
+ int idx = (((uintptr_t)address)&3)*8;
+ val&=~(0xff<<idx);
+ val|=(((uint32_t)b)<<idx);
+ return val;
+}
+
+// will go badly if address is unaligned
+uint16_t extract_half(uint32_t val, void* address){
+ int idx = (((uintptr_t)address)&3)*8;
+ return (val>>idx)&0xffff;
+}
+uint32_t insert_half(uint32_t val, uint16_t h, void* address){
+ int idx = (((uintptr_t)address)&3)*8;
+ val&=~(0xffff<<idx);
+ val|=(((uint32_t)h)<<idx);
+ return val;
+}
+
+uint8_t rv64_lock_xchg_b(void* addr, uint8_t val)
+{
+ uint32_t ret;
+ uint32_t* aligned = (uint32_t*)(((uintptr_t)addr)&~3);
+ do {
+ ret = *aligned;
+ } while(rv64_lock_cas_d(aligned, ret, insert_byte(ret, val, addr)));
+ return extract_byte(ret, addr);
+}
+
+int rv64_lock_cas_b(void* addr, uint8_t ref, uint8_t val)
+{
+ uint32_t* aligned = (uint32_t*)(((uintptr_t)addr)&~3);
+ uint32_t tmp = *aligned;
+ return rv64_lock_cas_d(aligned, tmp, insert_byte(tmp, val, addr));
+}
+
+int rv64_lock_cas_h(void* addr, uint16_t ref, uint16_t val)
+{
+ uint32_t* aligned = (uint32_t*)(((uintptr_t)addr)&~3);
+ uint32_t tmp = *aligned;
+ return rv64_lock_cas_d(aligned, tmp, insert_half(tmp, val, addr));
+}
+
+
+const char* getCacheName(int t, int n)
+{
+ static char buff[20];
+ switch(t) {
+ case EXT_CACHE_ST_D: sprintf(buff, "ST%d", n); break;
+ case EXT_CACHE_ST_F: sprintf(buff, "st%d", n); break;
+ case EXT_CACHE_MM: sprintf(buff, "MM%d", n); break;
+ case EXT_CACHE_SS: sprintf(buff, "SS%d", n); break;
+ case EXT_CACHE_SD: sprintf(buff, "SD%d", n); break;
+ case EXT_CACHE_SCR: sprintf(buff, "Scratch"); break;
+ case EXT_CACHE_NONE: buff[0]='\0'; break;
+ }
+ return buff;
+}
+
+void inst_name_pass3(dynarec_native_t* dyn, int ninst, const char* name, rex_t rex)
+{
+ static const char* fnames[] = {
+ "ft0"," ft1", "ft2", "ft3", "ft4", "ft5", "ft6", "ft7",
+ "fs0", "fs1",
+ "fa0", "fa1", "fa2", "fa3", "fa4", "fa5", "fa6", "fa7",
+ "fs2", "fs3", "fs4", "fs5", "fs6", "fs7", "fs8", "fs9", "fs10", "fs11",
+ "ft8", "ft9", "ft10", "ft11"
+ };
+ if(box64_dynarec_dump) {
+ printf_x64_instruction(rex.is32bits?my_context->dec32:my_context->dec, &dyn->insts[ninst].x64, name);
+ dynarec_log(LOG_NONE, "%s%p: %d emitted opcodes, inst=%d, barrier=%d state=%d/%d(%d), %s=%X/%X, use=%X, need=%X/%X, sm=%d/%d",
+ (box64_dynarec_dump>1)?"\e[32m":"",
+ (void*)(dyn->native_start+dyn->insts[ninst].address),
+ dyn->insts[ninst].size/4,
+ ninst,
+ dyn->insts[ninst].x64.barrier,
+ dyn->insts[ninst].x64.state_flags,
+ dyn->f.pending,
+ dyn->f.dfnone,
+ dyn->insts[ninst].x64.may_set?"may":"set",
+ dyn->insts[ninst].x64.set_flags,
+ dyn->insts[ninst].x64.gen_flags,
+ dyn->insts[ninst].x64.use_flags,
+ dyn->insts[ninst].x64.need_before,
+ dyn->insts[ninst].x64.need_after,
+ dyn->smread, dyn->smwrite);
+ if(dyn->insts[ninst].pred_sz) {
+ dynarec_log(LOG_NONE, ", pred=");
+ for(int ii=0; ii<dyn->insts[ninst].pred_sz; ++ii)
+ dynarec_log(LOG_NONE, "%s%d", ii?"/":"", dyn->insts[ninst].pred[ii]);
+ }
+ if(dyn->insts[ninst].x64.jmp && dyn->insts[ninst].x64.jmp_insts>=0)
+ dynarec_log(LOG_NONE, ", jmp=%d", dyn->insts[ninst].x64.jmp_insts);
+ if(dyn->insts[ninst].x64.jmp && dyn->insts[ninst].x64.jmp_insts==-1)
+ dynarec_log(LOG_NONE, ", jmp=out");
+ if(dyn->last_ip)
+ dynarec_log(LOG_NONE, ", last_ip=%p", (void*)dyn->last_ip);
+ for(int ii=0; ii<24; ++ii) {
+ switch(dyn->insts[ninst].e.extcache[ii].t) {
+ case EXT_CACHE_ST_D: dynarec_log(LOG_NONE, " %s:%s", fnames[EXTREG(ii)], getCacheName(dyn->insts[ninst].e.extcache[ii].t, dyn->insts[ninst].e.extcache[ii].n)); break;
+ case EXT_CACHE_ST_F: dynarec_log(LOG_NONE, " %s:%s", fnames[EXTREG(ii)], getCacheName(dyn->insts[ninst].e.extcache[ii].t, dyn->insts[ninst].e.extcache[ii].n)); break;
+ case EXT_CACHE_MM: dynarec_log(LOG_NONE, " %s:%s", fnames[EXTREG(ii)], getCacheName(dyn->insts[ninst].e.extcache[ii].t, dyn->insts[ninst].e.extcache[ii].n)); break;
+ case EXT_CACHE_SS: dynarec_log(LOG_NONE, " %s:%s", fnames[EXTREG(ii)], getCacheName(dyn->insts[ninst].e.extcache[ii].t, dyn->insts[ninst].e.extcache[ii].n)); break;
+ case EXT_CACHE_SD: dynarec_log(LOG_NONE, " %s:%s", fnames[EXTREG(ii)], getCacheName(dyn->insts[ninst].e.extcache[ii].t, dyn->insts[ninst].e.extcache[ii].n)); break;
+ case EXT_CACHE_SCR: dynarec_log(LOG_NONE, " %s:%s", fnames[EXTREG(ii)], getCacheName(dyn->insts[ninst].e.extcache[ii].t, dyn->insts[ninst].e.extcache[ii].n)); break;
+ case EXT_CACHE_NONE:
+ default: break;
+ }
+ }
+ if(dyn->e.stack || dyn->insts[ninst].e.stack_next || dyn->insts[ninst].e.x87stack)
+ dynarec_log(LOG_NONE, " X87:%d/%d(+%d/-%d)%d", dyn->e.stack, dyn->insts[ninst].e.stack_next, dyn->insts[ninst].e.stack_push, dyn->insts[ninst].e.stack_pop, dyn->insts[ninst].e.x87stack);
+ if(dyn->insts[ninst].e.combined1 || dyn->insts[ninst].e.combined2)
+ dynarec_log(LOG_NONE, " %s:%d/%d", dyn->insts[ninst].e.swapped?"SWP":"CMB", dyn->insts[ninst].e.combined1, dyn->insts[ninst].e.combined2);
+ dynarec_log(LOG_NONE, "%s\n", (box64_dynarec_dump>1)?"\e[m":"");
+ }
+}
+
+void print_opcode(dynarec_native_t* dyn, int ninst, uint32_t opcode)
+{
+ dynarec_log(LOG_NONE, "\t%08x\t%s\n", opcode, rv64_print(opcode, (uintptr_t)dyn->block));
+}
+
+void print_newinst(dynarec_native_t* dyn, int ninst)
+{
+ dynarec_log(LOG_NONE, "%sNew instruction %d, native=%p (0x%x)%s\n",
+ (box64_dynarec_dump>1)?"\e[4;32m":"",
+ ninst, dyn->block, dyn->native_size,
+ (box64_dynarec_dump>1)?"\e[m":""
+ );
+} \ No newline at end of file
diff --git a/src/dynarec/rv64/dynarec_rv64_functions.h b/src/dynarec/rv64/dynarec_rv64_functions.h
new file mode 100644
index 0000000..451336b
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_functions.h
@@ -0,0 +1,52 @@
+#ifndef __DYNAREC_RV64_FUNCTIONS_H__
+#define __DYNAREC_RV64_FUNCTIONS_H__
+
+#include "../dynarec_native_functions.h"
+
+typedef struct x64emu_s x64emu_t;
+typedef struct dynarec_rv64_s dynarec_rv64_t;
+
+#define SCRATCH0 2
+
+// Get an FPU scratch reg
+int fpu_get_scratch(dynarec_rv64_t* dyn);
+// Reset scratch regs counter
+void fpu_reset_scratch(dynarec_rv64_t* dyn);
+// Get an x87 double reg
+int fpu_get_reg_x87(dynarec_rv64_t* dyn, int t, int n);
+// Get an MMX double reg
+int fpu_get_reg_emm(dynarec_rv64_t* dyn, int emm);
+// Get an XMM quad reg
+int fpu_get_reg_xmm(dynarec_rv64_t* dyn, int t, int xmm);
+// Free a FPU/MMX/XMM reg
+void fpu_free_reg(dynarec_rv64_t* dyn, int reg);
+// Reset fpu regs counter
+void fpu_reset_reg(dynarec_rv64_t* dyn);
+
+// ---- Neon cache functions
+// Get type for STx
+int extcache_get_st(dynarec_rv64_t* dyn, int ninst, int a);
+// Get if STx is FLOAT or DOUBLE
+int extcache_get_st_f(dynarec_rv64_t* dyn, int ninst, int a);
+// Get actual type for STx
+int extcache_get_current_st(dynarec_rv64_t* dyn, int ninst, int a);
+// Get actual STx is FLOAT or DOUBLE
+int extcache_get_current_st_f(dynarec_rv64_t* dyn, int a);
+// Back-propagate a change float->double
+void extcache_promote_double(dynarec_rv64_t* dyn, int ninst, int a);
+// Combine and propagate if needed (pass 1 only)
+int extcache_combine_st(dynarec_rv64_t* dyn, int ninst, int a, int b); // with stack current dyn->n_stack*
+
+// FPU Cache transformation (for loops) // Specific, need to be written par backend
+int fpuCacheNeedsTransform(dynarec_rv64_t* dyn, int ninst);
+
+// Undo the changes of a extcache to get the status before the instruction
+void extcacheUnwind(extcache_t* cache);
+
+const char* getCacheName(int t, int n);
+
+void inst_name_pass3(dynarec_native_t* dyn, int ninst, const char* name, rex_t rex);
+void print_opcode(dynarec_native_t* dyn, int ninst, uint32_t opcode);
+void print_newinst(dynarec_native_t* dyn, int ninst);
+
+#endif //__DYNAREC_RV64_FUNCTIONS_H__
diff --git a/src/dynarec/rv64/dynarec_rv64_helper.c b/src/dynarec/rv64/dynarec_rv64_helper.c
new file mode 100644
index 0000000..a005c3b
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_helper.c
@@ -0,0 +1,2174 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <stddef.h>
+#include <errno.h>
+#include <assert.h>
+#include <string.h>
+
+#include "bitutils.h"
+#include "debug.h"
+#include "box64context.h"
+#include "dynarec.h"
+#include "emu/x64emu_private.h"
+#include "emu/x64run_private.h"
+#include "x64run.h"
+#include "x64emu.h"
+#include "box64stack.h"
+#include "callback.h"
+#include "emu/x64run_private.h"
+#include "x64trace.h"
+#include "dynarec_native.h"
+#include "../dynablock_private.h"
+#include "custommem.h"
+
+#include "rv64_printer.h"
+#include "dynarec_rv64_private.h"
+#include "dynarec_rv64_functions.h"
+#include "dynarec_rv64_helper.h"
+
+static uintptr_t geted_32(dynarec_rv64_t* dyn, uintptr_t addr, int ninst, uint8_t nextop, uint8_t* ed, uint8_t hint, uint8_t scratch, int64_t* fixaddress, int *l, int i12);
+
+/* setup r2 to address pointed by ED, also fixaddress is an optionnal delta in the range [-absmax, +absmax], with delta&mask==0 to be added to ed for LDR/STR */
+uintptr_t geted(dynarec_rv64_t* dyn, uintptr_t addr, int ninst, uint8_t nextop, uint8_t* ed, uint8_t hint, uint8_t scratch, int64_t* fixaddress, rex_t rex, int *l, int i12, int delta)
+{
+ MAYUSE(dyn); MAYUSE(ninst); MAYUSE(delta);
+
+ if(rex.is32bits)
+ return geted_32(dyn, addr, ninst, nextop, ed, hint, scratch, fixaddress, l, i12);
+
+ int lock = l?((l==LOCK_LOCK)?1:2):0;
+ if(lock==2)
+ *l = 0;
+ uint8_t ret = x2;
+ *fixaddress = 0;
+ if(hint>0) ret = hint;
+ int maxval = 2047;
+ if(i12>1)
+ maxval -= i12;
+ MAYUSE(scratch);
+ if(!(nextop&0xC0)) {
+ if((nextop&7)==4) {
+ uint8_t sib = F8;
+ int sib_reg = ((sib>>3)&7)+(rex.x<<3);
+ int sib_reg2 = (sib&0x7)+(rex.b<<3);
+ if((sib&0x7)==5) {
+ int64_t tmp = F32S;
+ if (sib_reg!=4) {
+ if(tmp && ((tmp<-2048) || (tmp>maxval) || !i12)) {
+ MOV64x(scratch, tmp);
+ if((sib>>6)) {
+ if(rv64_zba) {
+ SHxADD(ret, xRAX+sib_reg, sib>>6, scratch);
+ } else {
+ SLLI(ret, xRAX+sib_reg, (sib>>6));
+ ADD(ret, ret, scratch);
+ }
+ } else {
+ ADD(ret, xRAX+sib_reg, scratch);
+ }
+ } else {
+ if(sib>>6) {
+ SLLI(ret, xRAX+sib_reg, (sib>>6));
+ } else
+ ret = xRAX+sib_reg;
+ *fixaddress = tmp;
+ }
+ } else {
+ switch(lock) {
+ case 1: addLockAddress(tmp); break;
+ case 2: if(isLockAddress(tmp)) *l=1; break;
+ }
+ MOV64x(ret, tmp);
+ }
+ } else {
+ if (sib_reg!=4) {
+ if(sib>>6) {
+ if(rv64_zba) {
+ SHxADD(ret, xRAX+sib_reg, sib>>6, xRAX+sib_reg2);
+ } else {
+ SLLI(scratch, xRAX+sib_reg, (sib>>6));
+ ADD(ret, xRAX+sib_reg2, scratch);
+ }
+ } else {
+ ADD(ret, xRAX+sib_reg2, xRAX+sib_reg);
+ }
+ } else {
+ ret = xRAX+sib_reg2;
+ }
+ }
+ } else if((nextop&7)==5) {
+ int64_t tmp = F32S64;
+ int64_t adj = dyn->last_ip?((addr+delta)-dyn->last_ip):0;
+ if(i12 && adj && (tmp+adj>=-2048) && (tmp+adj<=maxval)) {
+ ret = xRIP;
+ *fixaddress = tmp+adj;
+ } else if(i12 && (tmp>=-2048) && (tmp<=maxval)) {
+ GETIP(addr+delta);
+ ret = xRIP;
+ *fixaddress = tmp;
+ } else if(adj && (tmp+adj>=-2048) && (tmp+adj<=maxval)) {
+ ADDI(ret, xRIP, tmp+adj);
+ } else if((tmp>=-2048) && (tmp<=maxval)) {
+ GETIP(addr+delta);
+ ADDI(ret, xRIP, tmp);
+ } else if(tmp+addr+delta<0x100000000LL) {
+ MOV64x(ret, tmp+addr+delta);
+ } else {
+ if(adj) {
+ MOV64x(ret, tmp+adj);
+ } else {
+ MOV64x(ret, tmp);
+ GETIP(addr+delta);
+ }
+ ADD(ret, ret, xRIP);
+ }
+ switch(lock) {
+ case 1: addLockAddress(addr+delta+tmp); break;
+ case 2: if(isLockAddress(addr+delta+tmp)) *l=1; break;
+ }
+ } else {
+ ret = xRAX+(nextop&7)+(rex.b<<3);
+ }
+ } else {
+ int64_t i64;
+ uint8_t sib = 0;
+ int sib_reg = 0;
+ if((nextop&7)==4) {
+ sib = F8;
+ sib_reg = ((sib>>3)&7)+(rex.x<<3);
+ }
+ int sib_reg2 = (sib&0x07)+(rex.b<<3);
+ if(nextop&0x80)
+ i64 = F32S;
+ else
+ i64 = F8S;
+ if(i64==0 || ((i64>=-2048) && (i64<=2047) && i12)) {
+ *fixaddress = i64;
+ if((nextop&7)==4) {
+ if (sib_reg!=4) {
+ if(sib>>6) {
+ if(rv64_zba) {
+ SHxADD(ret, xRAX+sib_reg, sib>>6, xRAX+sib_reg2);
+ } else {
+ SLLI(scratch, xRAX+sib_reg, (sib>>6));
+ ADD(ret, xRAX+sib_reg2, scratch);
+ }
+ } else {
+ ADD(ret, xRAX+sib_reg2, xRAX+sib_reg);
+ }
+ } else {
+ ret = xRAX+sib_reg2;
+ }
+ } else
+ ret = xRAX+(nextop&0x07)+(rex.b<<3);
+ } else {
+ if(i64>=-2048 && i64<=2047) {
+ if((nextop&7)==4) {
+ if (sib_reg!=4) {
+ if(sib>>6) {
+ if(rv64_zba) {
+ SHxADD(scratch, xRAX+sib_reg, sib>>6, xRAX+sib_reg2);
+ } else {
+ SLLI(scratch, xRAX+sib_reg, (sib>>6));
+ ADD(scratch, xRAX+sib_reg2, scratch);
+ }
+ } else {
+ ADD(scratch, xRAX+sib_reg2, xRAX+sib_reg);
+ }
+ } else {
+ scratch = xRAX+sib_reg2;
+ }
+ } else
+ scratch = xRAX+(nextop&0x07)+(rex.b<<3);
+ ADDI(ret, scratch, i64);
+ } else {
+ MOV64x(scratch, i64);
+ if((nextop&7)==4) {
+ if (sib_reg!=4) {
+ ADD(scratch, scratch, xRAX+sib_reg2);
+ if(sib>>6) {
+ if(rv64_zba) {
+ SHxADD(ret, xRAX+sib_reg, sib>>6, scratch);
+ } else {
+ SLLI(ret, xRAX+sib_reg, (sib>>6));
+ ADD(ret, scratch, ret);
+ }
+ } else {
+ ADD(ret, scratch, xRAX+sib_reg);
+ }
+ } else {
+ PASS3(int tmp = xRAX+sib_reg2);
+ ADD(ret, tmp, scratch);
+ }
+ } else {
+ PASS3(int tmp = xRAX+(nextop&0x07)+(rex.b<<3));
+ ADD(ret, tmp, scratch);
+ }
+ }
+ }
+ }
+ *ed = ret;
+ return addr;
+}
+
+static uintptr_t geted_32(dynarec_rv64_t* dyn, uintptr_t addr, int ninst, uint8_t nextop, uint8_t* ed, uint8_t hint, uint8_t scratch, int64_t* fixaddress, int *l, int i12)
+{
+ MAYUSE(dyn); MAYUSE(ninst);
+
+ int lock = l?((l==LOCK_LOCK)?1:2):0;
+ if(lock==2)
+ *l = 0;
+ uint8_t ret = x2;
+ *fixaddress = 0;
+ if(hint>0) ret = hint;
+ int maxval = 2047;
+ if(i12>1)
+ maxval -= i12;
+ MAYUSE(scratch);
+ if(!(nextop&0xC0)) {
+ if((nextop&7)==4) {
+ uint8_t sib = F8;
+ int sib_reg = (sib>>3)&0x7;
+ int sib_reg2 = sib&0x7;
+ if(sib_reg2==5) {
+ int64_t tmp = F32S;
+ if (sib_reg!=4) {
+ if(tmp && ((tmp<-2048) || (tmp>maxval) || !i12)) {
+ MOV32w(scratch, tmp);
+ if((sib>>6)) {
+ if(rv64_zba) SHxADDUW(ret, xRAX+sib_reg, (sib>>6), scratch); else {SLLI(ret, xRAX+sib_reg, sib>>6); ADDW(ret, ret, scratch);}
+ } else
+ ADDW(ret, xRAX+sib_reg, scratch);
+ } else {
+ if(sib>>6)
+ SLLI(ret, xRAX+sib_reg, (sib>>6));
+ else
+ ret = xRAX+sib_reg;
+ *fixaddress = tmp;
+ }
+ } else {
+ switch(lock) {
+ case 1: addLockAddress((int32_t)tmp); break;
+ case 2: if(isLockAddress((int32_t)tmp)) *l=1; break;
+ }
+ MOV32w(ret, tmp);
+ }
+ } else {
+ if (sib_reg!=4) {
+ if((sib>>6)) {
+ if(rv64_zba) SHxADDUW(ret, xRAX+sib_reg, (sib>>6), xRAX+sib_reg2); else { SLLI(ret, xRAX+sib_reg, (sib>>6)); ADDW(ret, ret, xRAX+sib_reg2);}
+ } else
+ ADDW(ret, xRAX+sib_reg2, xRAX+sib_reg);
+ } else {
+ ret = xRAX+sib_reg2;
+ }
+ }
+ } else if((nextop&7)==5) {
+ uint32_t tmp = F32;
+ MOV32w(ret, tmp);
+ switch(lock) {
+ case 1: addLockAddress(tmp); break;
+ case 2: if(isLockAddress(tmp)) *l=1; break;
+ }
+ } else {
+ ret = xRAX+(nextop&7);
+ if(ret==hint) {
+ AND(hint, ret, xMASK); //to clear upper part
+ }
+ }
+ } else {
+ int64_t i32;
+ uint8_t sib = 0;
+ int sib_reg = 0;
+ if((nextop&7)==4) {
+ sib = F8;
+ sib_reg = (sib>>3)&7;
+ }
+ int sib_reg2 = sib&0x07;
+ if(nextop&0x80)
+ i32 = F32S;
+ else
+ i32 = F8S;
+ if(i32==0 || ((i32>=-2048) && (i32<=2047) && i12)) {
+ *fixaddress = i32;
+ if((nextop&7)==4) {
+ if (sib_reg!=4) {
+ if(sib>>6) {
+ if(rv64_zba) SHxADDUW(ret, xRAX+sib_reg, (sib>>6), xRAX+sib_reg2); else {SLLI(ret, xRAX+sib_reg, (sib>>6)); ADDW(ret, ret, xRAX+sib_reg2);}
+ } else
+ ADDW(ret, xRAX+sib_reg2, xRAX+sib_reg);
+ } else {
+ ret = xRAX+sib_reg2;
+ }
+ } else {
+ ret = xRAX+(nextop&0x07);
+ }
+ } else {
+ if(i32>=-2048 && i32<=2047) {
+ if((nextop&7)==4) {
+ if (sib_reg!=4) {
+ if(sib>>6) {
+ if(rv64_zba) SHxADDUW(scratch, xRAX+sib_reg, (sib>>6), xRAX+sib_reg2); else {SLLI(scratch, xRAX+sib_reg, sib>>6); ADDW(scratch, scratch, xRAX+sib_reg2);}
+ } else
+ ADDW(scratch, xRAX+sib_reg2, xRAX+sib_reg);
+ } else {
+ scratch = xRAX+sib_reg2;
+ }
+ } else
+ scratch = xRAX+(nextop&0x07);
+ ADDIW(ret, scratch, i32);
+ } else {
+ MOV32w(scratch, i32);
+ if((nextop&7)==4) {
+ if (sib_reg!=4) {
+ ADDW(scratch, scratch, xRAX+sib_reg2);
+ if(sib>>6) {
+ if(rv64_zba) SHxADDUW(ret, xRAX+sib_reg, (sib>>6), scratch); else {SLLI(ret, xRAX+sib_reg, (sib>>6)); ADDW(ret, ret, scratch);}
+ } else
+ ADDW(ret, scratch, xRAX+sib_reg);
+ } else {
+ PASS3(int tmp = xRAX+sib_reg2);
+ ADDW(ret, tmp, scratch);
+ }
+ } else {
+ PASS3(int tmp = xRAX+(nextop&0x07));
+ ADDW(ret, tmp, scratch);
+ }
+ }
+ }
+ }
+ *ed = ret;
+ return addr;
+}
+
+/* setup r2 to address pointed by ED, also fixaddress is an optionnal delta in the range [-absmax, +absmax], with delta&mask==0 to be added to ed for LDR/STR */
+uintptr_t geted32(dynarec_rv64_t* dyn, uintptr_t addr, int ninst, uint8_t nextop, uint8_t* ed, uint8_t hint, uint8_t scratch, int64_t* fixaddress, rex_t rex, int *l, int i12, int delta)
+{
+ MAYUSE(dyn); MAYUSE(ninst); MAYUSE(delta);
+
+ int lock = l?((l==LOCK_LOCK)?1:2):0;
+ if(lock==2)
+ *l = 0;
+ uint8_t ret = x2;
+ *fixaddress = 0;
+ if(hint>0) ret = hint;
+ int maxval = 2047;
+ if(i12>1)
+ maxval -= i12;
+ MAYUSE(scratch);
+ if(!(nextop&0xC0)) {
+ if((nextop&7)==4) {
+ uint8_t sib = F8;
+ int sib_reg = ((sib>>3)&0x7)+(rex.x<<3);
+ int sib_reg2 = (sib&0x7)+(rex.b<<3);
+ if((sib&0x7)==5) {
+ int64_t tmp = F32S;
+ if (sib_reg!=4) {
+ if(tmp && ((tmp<-2048) || (tmp>maxval) || !i12)) {
+ MOV64x(scratch, tmp);
+ if((sib>>6)) {
+ if(rv64_zba) SHxADDUW(ret, xRAX+sib_reg, (sib>>6), scratch); else {SLLI(ret, xRAX+sib_reg, sib>>6); ADDW(ret, ret, scratch);}
+ } else
+ ADDW(ret, xRAX+sib_reg, scratch);
+ } else {
+ if(sib>>6)
+ SLLI(ret, xRAX+sib_reg, (sib>>6));
+ else
+ ret = xRAX+sib_reg;
+ *fixaddress = tmp;
+ }
+ } else {
+ switch(lock) {
+ case 1: addLockAddress(tmp); break;
+ case 2: if(isLockAddress(tmp)) *l=1; break;
+ }
+ MOV64x(ret, tmp);
+ }
+ } else {
+ if (sib_reg!=4) {
+ if((sib>>6)) {
+ if(rv64_zba) SHxADDUW(ret, xRAX+sib_reg, (sib>>6), xRAX+sib_reg2); else { SLLI(ret, xRAX+sib_reg, (sib>>6)); ADDW(ret, ret, xRAX+sib_reg2);}
+ } else
+ ADDW(ret, xRAX+sib_reg2, xRAX+sib_reg);
+ } else {
+ ret = xRAX+sib_reg2;
+ }
+ }
+ } else if((nextop&7)==5) {
+ uint32_t tmp = F32;
+ MOV32w(ret, tmp);
+ GETIP(addr+delta);
+ ADDW(ret, ret, xRIP);
+ switch(lock) {
+ case 1: addLockAddress(addr+delta+tmp); break;
+ case 2: if(isLockAddress(addr+delta+tmp)) *l=1; break;
+ }
+ } else {
+ ret = xRAX+(nextop&7)+(rex.b<<3);
+ if(ret==hint) {
+ AND(hint, ret, xMASK); //to clear upper part
+ }
+ }
+ } else {
+ int64_t i64;
+ uint8_t sib = 0;
+ int sib_reg = 0;
+ if((nextop&7)==4) {
+ sib = F8;
+ sib_reg = ((sib>>3)&7)+(rex.x<<3);
+ }
+ int sib_reg2 = (sib&0x07)+(rex.b<<3);
+ if(nextop&0x80)
+ i64 = F32S;
+ else
+ i64 = F8S;
+ if(i64==0 || ((i64>=-2048) && (i64<=2047) && i12)) {
+ *fixaddress = i64;
+ if((nextop&7)==4) {
+ if (sib_reg!=4) {
+ if(sib>>6) {
+ if(rv64_zba) SHxADDUW(ret, xRAX+sib_reg, (sib>>6), xRAX+sib_reg2); else {SLLI(ret, xRAX+sib_reg, (sib>>6)); ADDW(ret, ret, xRAX+sib_reg2);}
+ } else
+ ADDW(ret, xRAX+sib_reg2, xRAX+sib_reg);
+ } else {
+ ret = xRAX+sib_reg2;
+ }
+ } else {
+ ret = xRAX+(nextop&0x07)+(rex.b<<3);
+ }
+ } else {
+ if(i64>=-2048 && i64<=2047) {
+ if((nextop&7)==4) {
+ if (sib_reg!=4) {
+ if(sib>>6) {
+ if(rv64_zba) SHxADDUW(scratch, xRAX+sib_reg, (sib>>6), xRAX+sib_reg2); else {SLLI(scratch, xRAX+sib_reg, sib>>6); ADDW(scratch, scratch, xRAX+sib_reg2);}
+ } else
+ ADDW(scratch, xRAX+sib_reg2, xRAX+sib_reg);
+ } else {
+ scratch = xRAX+sib_reg2;
+ }
+ } else
+ scratch = xRAX+(nextop&0x07)+(rex.b<<3);
+ ADDIW(ret, scratch, i64);
+ } else {
+ MOV32w(scratch, i64);
+ if((nextop&7)==4) {
+ if (sib_reg!=4) {
+ ADDW(scratch, scratch, xRAX+sib_reg2);
+ if(sib>>6) {
+ if(rv64_zba) SHxADDUW(ret, xRAX+sib_reg, (sib>>6), scratch); else {SLLI(ret, xRAX+sib_reg, (sib>>6)); ADDW(ret, ret, scratch);}
+ } else
+ ADDW(ret, scratch, xRAX+sib_reg);
+ } else {
+ PASS3(int tmp = xRAX+sib_reg2);
+ ADDW(ret, tmp, scratch);
+ }
+ } else {
+ PASS3(int tmp = xRAX+(nextop&0x07)+(rex.b<<3));
+ ADDW(ret, tmp, scratch);
+ }
+ }
+ }
+ }
+ *ed = ret;
+ return addr;
+}
+
+void jump_to_epilog(dynarec_rv64_t* dyn, uintptr_t ip, int reg, int ninst)
+{
+ MAYUSE(dyn); MAYUSE(ip); MAYUSE(ninst);
+ MESSAGE(LOG_DUMP, "Jump to epilog\n");
+
+ if(reg) {
+ if(reg!=xRIP) {
+ MV(xRIP, reg);
+ }
+ } else {
+ GETIP_(ip);
+ }
+ TABLE64(x2, (uintptr_t)rv64_epilog);
+ SMEND();
+ BR(x2);
+}
+
+void jump_to_epilog_fast(dynarec_rv64_t* dyn, uintptr_t ip, int reg, int ninst)
+{
+ MAYUSE(dyn); MAYUSE(ip); MAYUSE(ninst);
+ MESSAGE(LOG_DUMP, "Jump to epilog_fast\n");
+
+ if(reg) {
+ if(reg!=xRIP) {
+ MV(xRIP, reg);
+ }
+ } else {
+ GETIP_(ip);
+ }
+ TABLE64(x2, (uintptr_t)rv64_epilog_fast);
+ SMEND();
+ BR(x2);
+}
+
+void jump_to_next(dynarec_rv64_t* dyn, uintptr_t ip, int reg, int ninst)
+{
+ MAYUSE(dyn); MAYUSE(ninst);
+ MESSAGE(LOG_DUMP, "Jump to next\n");
+
+ if(reg) {
+ if(reg!=xRIP) {
+ MV(xRIP, reg);
+ }
+ uintptr_t tbl = getJumpTable64();
+ MAYUSE(tbl);
+ TABLE64(x3, tbl);
+ SRLI(x2, xRIP, JMPTABL_START3);
+ if(rv64_zba) SH3ADD(x3, x2, x3); else {SLLI(x2, x2, 3); ADD(x3, x3, x2);}
+ LD(x3, x3, 0); // could be LR_D(x3, x3, 1, 1); for better safety
+ MOV64x(x4, JMPTABLE_MASK2<<3); // x4 = mask
+ SRLI(x2, xRIP, JMPTABL_START2-3);
+ AND(x2, x2, x4);
+ ADD(x3, x3, x2);
+ LD(x3, x3, 0); //LR_D(x3, x3, 1, 1);
+ if(JMPTABLE_MASK2!=JMPTABLE_MASK1) {
+ MOV64x(x4, JMPTABLE_MASK1<<3); // x4 = mask
+ }
+ SRLI(x2, xRIP, JMPTABL_START1-3);
+ AND(x2, x2, x4);
+ ADD(x3, x3, x2);
+ LD(x3, x3, 0); //LR_D(x3, x3, 1, 1);
+ if(JMPTABLE_MASK0<2048) {
+ ANDI(x2, xRIP, JMPTABLE_MASK0);
+ } else {
+ if(JMPTABLE_MASK1!=JMPTABLE_MASK0) {
+ MOV64x(x4, JMPTABLE_MASK0); // x4 = mask
+ }
+ AND(x2, xRIP, x4);
+ }
+ if(rv64_zba) SH3ADD(x3, x2, x3); else {SLLI(x2, x2, 3); ADD(x3, x3, x2);}
+ LD(x2, x3, 0); //LR_D(x2, x3, 1, 1);
+ } else {
+ uintptr_t p = getJumpTableAddress64(ip);
+ MAYUSE(p);
+ TABLE64(x3, p);
+ GETIP_(ip);
+ LD(x2, x3, 0); //LR_D(x2, x3, 1, 1);
+ }
+ if(reg!=A1) {
+ MV(A1, xRIP);
+ }
+ CLEARIP();
+ #ifdef HAVE_TRACE
+ //MOVx(x3, 15); no access to PC reg
+ #endif
+ SMEND();
+ JALR(x2); // save LR...
+}
+
+void ret_to_epilog(dynarec_rv64_t* dyn, int ninst, rex_t rex)
+{
+ MAYUSE(dyn); MAYUSE(ninst);
+ MESSAGE(LOG_DUMP, "Ret to epilog\n");
+ POP1z(xRIP);
+ MVz(x1, xRIP);
+ SMEND();
+ /*if(box64_dynarec_callret) {
+ // pop the actual return address from RV64 stack
+ LDPx_S7_offset(x2, x6, xSP, 0);
+ CBZx(x6, 5*4);
+ ADDx_U12(xSP, xSP, 16);
+ SUBx_REG(x6, x6, xRIP); // is it the right address?
+ CBNZx(x6, 2*4);
+ BLR(x2);
+ // not the correct return address, regular jump
+ }*/
+ uintptr_t tbl = getJumpTable64();
+ MOV64x(x3, tbl);
+ SRLI(x2, xRIP, JMPTABL_START3);
+ if(rv64_zba) SH3ADD(x3, x2, x3); else {SLLI(x2, x2, 3); ADD(x3, x3, x2);}
+ LD(x3, x3, 0);
+ MOV64x(x4, JMPTABLE_MASK2<<3); // x4 = mask
+ SRLI(x2, xRIP, JMPTABL_START2-3);
+ AND(x2, x2, x4);
+ ADD(x3, x3, x2);
+ LD(x3, x3, 0);
+ if(JMPTABLE_MASK2!=JMPTABLE_MASK1) {
+ MOV64x(x4, JMPTABLE_MASK1<<3); // x4 = mask
+ }
+ SRLI(x2, xRIP, JMPTABL_START1-3);
+ AND(x2, x2, x4);
+ ADD(x3, x3, x2);
+ LD(x3, x3, 0);
+ if(JMPTABLE_MASK0<2048) {
+ ANDI(x2, xRIP, JMPTABLE_MASK0);
+ } else {
+ if(JMPTABLE_MASK1!=JMPTABLE_MASK0) {
+ MOV64x(x4, JMPTABLE_MASK0); // x4 = mask
+ }
+ AND(x2, xRIP, x4);
+ }
+ if(rv64_zba) SH3ADD(x3, x2, x3); else {SLLI(x2, x2, 3); ADD(x3, x3, x2);}
+ LD(x2, x3, 0);
+ JALR(x2); // save LR
+ CLEARIP();
+}
+
+void retn_to_epilog(dynarec_rv64_t* dyn, int ninst, rex_t rex, int n)
+{
+ MAYUSE(dyn); MAYUSE(ninst);
+ MESSAGE(LOG_DUMP, "Retn to epilog\n");
+ POP1z(xRIP);
+ if(n>0x7ff) {
+ MOV64x(w1, n);
+ ADDz(xRSP, xRSP, x1);
+ } else {
+ ADDIz(xRSP, xRSP, n);
+ }
+ MVz(x1, xRIP);
+ SMEND();
+ /*if(box64_dynarec_callret) {
+ // pop the actual return address from RV64 stack
+ LDPx_S7_offset(x2, x6, xSP, 0);
+ CBZx(x6, 5*4);
+ ADDx_U12(xSP, xSP, 16);
+ SUBx_REG(x6, x6, xRIP); // is it the right address?
+ CBNZx(x6, 2*4);
+ BLR(x2);
+ // not the correct return address, regular jump
+ }*/
+ uintptr_t tbl = getJumpTable64();
+ MOV64x(x3, tbl);
+ SRLI(x2, xRIP, JMPTABL_START3);
+ if(rv64_zba) SH3ADD(x3, x2, x3); else {SLLI(x2, x2, 3); ADD(x3, x3, x2);}
+ LD(x3, x3, 0);
+ MOV64x(x4, JMPTABLE_MASK2<<3); // x4 = mask
+ SRLI(x2, xRIP, JMPTABL_START2-3);
+ AND(x2, x2, x4);
+ ADD(x3, x3, x2);
+ LD(x3, x3, 0);
+ if(JMPTABLE_MASK2!=JMPTABLE_MASK1) {
+ MOV64x(x4, JMPTABLE_MASK1<<3); // x4 = mask
+ }
+ SRLI(x2, xRIP, JMPTABL_START1-3);
+ AND(x2, x2, x4);
+ ADD(x3, x3, x2);
+ LD(x3, x3, 0);
+ if(JMPTABLE_MASK0<2048) {
+ ANDI(x2, xRIP, JMPTABLE_MASK0);
+ } else {
+ if(JMPTABLE_MASK1!=JMPTABLE_MASK0) {
+ MOV64x(x4, JMPTABLE_MASK0); // x4 = mask
+ }
+ AND(x2, xRIP, x4);
+ }
+ if(rv64_zba) SH3ADD(x3, x2, x3); else {SLLI(x2, x2, 3); ADD(x3, x3, x2);}
+ LD(x2, x3, 0);
+ JALR(x2); // save LR
+ CLEARIP();
+}
+
+void iret_to_epilog(dynarec_rv64_t* dyn, int ninst, int is64bits)
+{
+ //#warning TODO: is64bits
+ MAYUSE(ninst);
+ MESSAGE(LOG_DUMP, "IRet to epilog\n");
+ NOTEST(x2);
+ if(is64bits) {
+ POP1(xRIP);
+ POP1(x2);
+ POP1(xFlags);
+ } else {
+ POP1_32(xRIP);
+ POP1_32(x2);
+ POP1_32(xFlags);
+ }
+
+ SH(x2, xEmu, offsetof(x64emu_t, segs[_CS]));
+ SW(xZR, xEmu, offsetof(x64emu_t, segs_serial[_CS]));
+ // clean EFLAGS
+ MOV32w(x1, 0x3F7FD7);
+ AND(xFlags, xFlags, x1);
+ ORI(xFlags, xFlags, 0x2);
+ SET_DFNONE();
+ // POP RSP
+ if (is64bits) {
+ POP1(x3); //rsp
+ POP1(x2); //ss
+ } else {
+ POP1_32(x3); //rsp
+ POP1_32(x2); //ss
+ }
+ // POP SS
+ SH(x2, xEmu, offsetof(x64emu_t, segs[_SS]));
+ SW(xZR, xEmu, offsetof(x64emu_t, segs_serial[_SS]));
+ // set new RSP
+ MV(xRSP, x3);
+ // Ret....
+ MOV64x(x2, (uintptr_t)rv64_epilog); // epilog on purpose, CS might have changed!
+ SMEND();
+ BR(x2);
+ CLEARIP();
+}
+
+void call_c(dynarec_rv64_t* dyn, int ninst, void* fnc, int reg, int ret, int saveflags, int savereg)
+{
+ MAYUSE(fnc);
+ if(savereg==0)
+ savereg = x6;
+ if(saveflags) {
+ FLAGS_ADJUST_TO11(xFlags, xFlags, reg);
+ SD(xFlags, xEmu, offsetof(x64emu_t, eflags));
+ }
+ fpu_pushcache(dyn, ninst, reg, 0);
+ if(ret!=-2) {
+ SUBI(xSP, xSP, 16); // RV64 stack needs to be 16byte aligned
+ SD(xEmu, xSP, 0);
+ SD(savereg, xSP, 8);
+ // x5..x8, x10..x17, x28..x31 those needs to be saved by caller
+ STORE_REG(RAX);
+ STORE_REG(RCX);
+ STORE_REG(RDX);
+ STORE_REG(R12);
+ STORE_REG(R13);
+ STORE_REG(R14);
+ STORE_REG(R15);
+ SD(xRIP, xEmu, offsetof(x64emu_t, ip));
+ }
+ TABLE64(reg, (uintptr_t)fnc);
+ JALR(reg);
+ if(ret>=0) {
+ MV(ret, xEmu);
+ }
+ if(ret!=-2) {
+ LD(xEmu, xSP, 0);
+ LD(savereg, xSP, 8);
+ ADDI(xSP, xSP, 16);
+ #define GO(A) if(ret!=x##A) {LOAD_REG(A);}
+ GO(RAX);
+ GO(RCX);
+ GO(RDX);
+ GO(R12);
+ GO(R13);
+ GO(R14);
+ GO(R15);
+ if(ret!=xRIP)
+ LD(xRIP, xEmu, offsetof(x64emu_t, ip));
+ #undef GO
+ }
+ // regenerate mask
+ XORI(xMASK, xZR, -1);
+ SRLI(xMASK, xMASK, 32);
+
+ fpu_popcache(dyn, ninst, reg, 0);
+ if(saveflags) {
+ LD(xFlags, xEmu, offsetof(x64emu_t, eflags));
+ FLAGS_ADJUST_FROM11(xFlags, reg);
+ }
+ SET_NODF();
+ dyn->last_ip = 0;
+}
+
+void call_n(dynarec_rv64_t* dyn, int ninst, void* fnc, int w)
+{
+ MAYUSE(fnc);
+ FLAGS_ADJUST_TO11(xFlags, xFlags, x3);
+ SD(xFlags, xEmu, offsetof(x64emu_t, eflags));
+ fpu_pushcache(dyn, ninst, x3, 1);
+ // x5..x8, x10..x17, x28..x31 those needs to be saved by caller
+ // RDI, RSI, RDX, RCX, R8, R9 are used for function call
+ SUBI(xSP, xSP, 16);
+ SD(xEmu, xSP, 0);
+ SD(xRIP, xSP, 8); // ARM64 stack needs to be 16byte aligned
+ STORE_REG(R12);
+ STORE_REG(R13);
+ STORE_REG(R14);
+ STORE_REG(R15);
+ // float and double args
+ if(abs(w)>1) {
+ /*MESSAGE(LOG_DUMP, "Getting %d XMM args\n", abs(w)-1);
+ for(int i=0; i<abs(w)-1; ++i) {
+ sse_get_reg(dyn, ninst, x6, i, w);
+ }*/
+ MESSAGE(LOG_DUMP, "Warning XMM args not ready\n");
+ }
+ if(w<0) {
+ /*
+ MESSAGE(LOG_DUMP, "Return in XMM0\n");
+ sse_get_reg_empty(dyn, ninst, x6, 0);
+ */
+ MESSAGE(LOG_DUMP, "Warning return in XMM args not ready\n");
+ }
+ // prepare regs for native call
+ MV(A0, xRDI);
+ MV(A1, xRSI);
+ MV(A2, xRDX);
+ MV(A3, xRCX);
+ MV(A4, xR8);
+ MV(A5, xR9);
+ // native call
+ TABLE64(16, (uintptr_t)fnc); // using x16 as scratch regs for call address
+ JALR(16);
+ // put return value in x64 regs
+ if(w>0) {
+ MV(xRAX, A0);
+ MV(xRDX, A1);
+ }
+ // all done, restore all regs
+ LD(xEmu, xSP, 0);
+ LD(xRIP, xSP, 8);
+ ADDI(xSP, xSP, 16);
+ LOAD_REG(R12);
+ LOAD_REG(R13);
+ LOAD_REG(R14);
+ LOAD_REG(R15);
+ // regenerate mask
+ XORI(xMASK, xZR, -1);
+ SRLI(xMASK, xMASK, 32);
+
+ fpu_popcache(dyn, ninst, x3, 1);
+ LD(xFlags, xEmu, offsetof(x64emu_t, eflags));
+ FLAGS_ADJUST_FROM11(xFlags, x3);
+ SET_NODF();
+}
+
+void grab_segdata(dynarec_rv64_t* dyn, uintptr_t addr, int ninst, int reg, int segment)
+{
+ (void)addr;
+ int64_t j64;
+ MAYUSE(j64);
+ MESSAGE(LOG_DUMP, "Get %s Offset\n", (segment==_FS)?"FS":"GS");
+ int t1 = x1, t2 = x4;
+ if(reg==t1) ++t1;
+ if(reg==t2) ++t2;
+ LWU(t2, xEmu, offsetof(x64emu_t, segs_serial[segment]));
+ LD(reg, xEmu, offsetof(x64emu_t, segs_offs[segment]));
+ if(segment==_GS) {
+ CBNZ_MARKSEG(t2); // fast check
+ } else {
+ LD(t1, xEmu, offsetof(x64emu_t, context));
+ LWU(t1, t1, offsetof(box64context_t, sel_serial));
+ SUBW(t1, t1, t2);
+ CBZ_MARKSEG(t1);
+ }
+ MOV64x(x1, segment);
+ call_c(dyn, ninst, GetSegmentBaseEmu, t2, reg, 0, xFlags);
+ MARKSEG;
+ MESSAGE(LOG_DUMP, "----%s Offset\n", (segment==_FS)?"FS":"GS");
+}
+
+// x87 stuffs
+static void x87_reset(dynarec_rv64_t* dyn)
+{
+ for (int i=0; i<8; ++i)
+ dyn->e.x87cache[i] = -1;
+ dyn->e.x87stack = 0;
+ dyn->e.stack = 0;
+ dyn->e.stack_next = 0;
+ dyn->e.stack_pop = 0;
+ dyn->e.stack_push = 0;
+ dyn->e.combined1 = dyn->e.combined2 = 0;
+ dyn->e.swapped = 0;
+ dyn->e.barrier = 0;
+ for(int i=0; i<24; ++i)
+ if(dyn->e.extcache[i].t == EXT_CACHE_ST_F || dyn->e.extcache[i].t == EXT_CACHE_ST_D)
+ dyn->e.extcache[i].v = 0;
+}
+
+void x87_stackcount(dynarec_rv64_t* dyn, int ninst, int scratch)
+{
+ MAYUSE(scratch);
+ if(!dyn->e.x87stack)
+ return;
+ if(dyn->e.mmxcount)
+ mmx_purgecache(dyn, ninst, 0, scratch);
+ MESSAGE(LOG_DUMP, "\tSynch x87 Stackcount (%d)\n", dyn->e.x87stack);
+ int a = dyn->e.x87stack;
+ // Add x87stack to emu fpu_stack
+ LW(scratch, xEmu, offsetof(x64emu_t, fpu_stack));
+ ADDI(scratch, scratch, a);
+ SW(scratch, xEmu, offsetof(x64emu_t, fpu_stack));
+ // Sub x87stack to top, with and 7
+ LW(scratch, xEmu, offsetof(x64emu_t, top));
+ SUBI(scratch, scratch, a);
+ ANDI(scratch, scratch, 7);
+ SW(scratch, xEmu, offsetof(x64emu_t, top));
+ // reset x87stack, but not the stack count of extcache
+ dyn->e.x87stack = 0;
+ dyn->e.stack_next -= dyn->e.stack;
+ dyn->e.stack = 0;
+ MESSAGE(LOG_DUMP, "\t------x87 Stackcount\n");
+}
+
+int extcache_st_coherency(dynarec_rv64_t* dyn, int ninst, int a, int b)
+{
+ int i1 = extcache_get_st(dyn, ninst, a);
+ int i2 = extcache_get_st(dyn, ninst, b);
+ if(i1!=i2) {
+ MESSAGE(LOG_DUMP, "Warning, ST cache incoherent between ST%d(%d) and ST%d(%d)\n", a, i1, b, i2);
+ }
+
+ return i1;
+}
+
+// On step 1, Float/Double for ST is actualy computed and back-propagated
+// On step 2-3, the value is just read for inst[...].n.neocache[..]
+// the reg returned is *2 for FLOAT
+int x87_do_push(dynarec_rv64_t* dyn, int ninst, int s1, int t)
+{
+ if(dyn->e.mmxcount)
+ mmx_purgecache(dyn, ninst, 0, s1);
+ dyn->e.x87stack+=1;
+ dyn->e.stack+=1;
+ dyn->e.stack_next+=1;
+ dyn->e.stack_push+=1;
+ // move all regs in cache, and find a free one
+ for(int j=0; j<24; ++j)
+ if((dyn->e.extcache[j].t == EXT_CACHE_ST_D) || (dyn->e.extcache[j].t == EXT_CACHE_ST_F))
+ ++dyn->e.extcache[j].n;
+ int ret = -1;
+ for(int i=0; i<8; ++i)
+ if(dyn->e.x87cache[i]!=-1)
+ ++dyn->e.x87cache[i];
+ else if(ret==-1) {
+ dyn->e.x87cache[i] = 0;
+ ret=dyn->e.x87reg[i]=fpu_get_reg_x87(dyn, t, 0);
+ }
+ return ret;
+}
+void x87_do_push_empty(dynarec_rv64_t* dyn, int ninst, int s1)
+{
+ if(dyn->e.mmxcount)
+ mmx_purgecache(dyn, ninst, 0, s1);
+ dyn->e.x87stack+=1;
+ dyn->e.stack+=1;
+ dyn->e.stack_next+=1;
+ dyn->e.stack_push+=1;
+ // move all regs in cache
+ for(int j=0; j<24; ++j)
+ if((dyn->e.extcache[j].t == EXT_CACHE_ST_D) || (dyn->e.extcache[j].t == EXT_CACHE_ST_F))
+ ++dyn->e.extcache[j].n;
+ for(int i=0; i<8; ++i)
+ if(dyn->e.x87cache[i]!=-1)
+ ++dyn->e.x87cache[i];
+ if(s1)
+ x87_stackcount(dyn, ninst, s1);
+}
+void x87_do_pop(dynarec_rv64_t* dyn, int ninst, int s1)
+{
+ if(dyn->e.mmxcount)
+ mmx_purgecache(dyn, ninst, 0, s1);
+ dyn->e.x87stack-=1;
+ dyn->e.stack_next-=1;
+ dyn->e.stack_pop+=1;
+ // move all regs in cache, poping ST0
+ for(int i=0; i<8; ++i)
+ if(dyn->e.x87cache[i]!=-1) {
+ --dyn->e.x87cache[i];
+ if(dyn->e.x87cache[i]==-1) {
+ fpu_free_reg(dyn, dyn->e.x87reg[i]);
+ dyn->e.x87reg[i] = -1;
+ }
+ }
+}
+
+void x87_purgecache(dynarec_rv64_t* dyn, int ninst, int next, int s1, int s2, int s3)
+{
+ int ret = 0;
+ for (int i=0; i<8 && !ret; ++i)
+ if(dyn->e.x87cache[i] != -1)
+ ret = 1;
+ if(!ret && !dyn->e.x87stack) // nothing to do
+ return;
+ MESSAGE(LOG_DUMP, "\tPurge %sx87 Cache and Synch Stackcount (%+d)---\n", next?"locally ":"", dyn->e.x87stack);
+ int a = dyn->e.x87stack;
+ if(a!=0) {
+ // reset x87stack
+ if(!next)
+ dyn->e.x87stack = 0;
+ // Add x87stack to emu fpu_stack
+ LW(s2, xEmu, offsetof(x64emu_t, fpu_stack));
+ ADDI(s2, s2, a);
+ SW(s2, xEmu, offsetof(x64emu_t, fpu_stack));
+ // Sub x87stack to top, with and 7
+ LW(s2, xEmu, offsetof(x64emu_t, top));
+ // update tags (and top at the same time)
+ if(a>0) {
+ // new tag to fulls
+ ADDI(s3, xZR, 0);
+ for (int i=0; i<a; ++i) {
+ SUBI(s2, s2, 1);
+ ANDI(s2, s2, 7); // (emu->top + st)&7
+ if(rv64_zba) SH2ADD(s1, s2, xEmu); else {SLLI(s1, s2, 2); ADD(s1, xEmu, s1);}
+ SW(s3, s1, offsetof(x64emu_t, p_regs));
+ }
+ } else {
+ // empty tags
+ ADDI(s3, xZR, 0b11);
+ for (int i=0; i<-a; ++i) {
+ if(rv64_zba) SH2ADD(s1, s2, xEmu); else {SLLI(s1, s2, 2); ADD(s1, xEmu, s1);}
+ SW(s3, s1, offsetof(x64emu_t, p_regs));
+ ADDI(s2, s2, 1);
+ ANDI(s2, s2, 7); // (emu->top + st)&7
+ }
+ }
+ SW(s2, xEmu, offsetof(x64emu_t, top));
+ } else {
+ LW(s2, xEmu, offsetof(x64emu_t, top));
+ }
+ if(ret!=0) {
+ // --- set values
+ // Get top
+ // loop all cache entries
+ for (int i=0; i<8; ++i)
+ if(dyn->e.x87cache[i]!=-1) {
+ #if STEP == 1
+ if(!next) { // don't force promotion here
+ // pre-apply pop, because purge happens in-between
+ extcache_promote_double(dyn, ninst, dyn->e.x87cache[i]+dyn->e.stack_pop);
+ }
+ #endif
+ #if STEP == 3
+ if(!next && extcache_get_st_f(dyn, ninst, dyn->e.x87cache[i])>=0) {
+ MESSAGE(LOG_DUMP, "Warning, incoherency with purged ST%d cache\n", dyn->e.x87cache[i]);
+ }
+ #endif
+ ADDI(s3, s2, dyn->e.x87cache[i]);
+ ANDI(s3, s3, 7); // (emu->top + st)&7
+ if(rv64_zba) SH3ADD(s1, s3, xEmu); else {SLLI(s1, s3, 3); ADD(s1, xEmu, s1);}
+ if(next) {
+ // need to check if a ST_F need local promotion
+ if(extcache_get_st_f(dyn, ninst, dyn->e.x87cache[i])>=0) {
+ FCVTDS(SCRATCH0, dyn->e.x87reg[i]);
+ FSD(SCRATCH0, s1, offsetof(x64emu_t, x87)); // save the value
+ } else {
+ FSD(dyn->e.x87reg[i], s1, offsetof(x64emu_t, x87)); // save the value
+ }
+ } else {
+ FSD(dyn->e.x87reg[i], s1, offsetof(x64emu_t, x87));
+ fpu_free_reg(dyn, dyn->e.x87reg[i]);
+ dyn->e.x87reg[i] = -1;
+ dyn->e.x87cache[i] = -1;
+ //dyn->e.stack_pop+=1; //no pop, but the purge because of barrier will have the n.barrier flags set
+ }
+ }
+ }
+ if(!next) {
+ dyn->e.stack_next = 0;
+ #if STEP < 2
+ // refresh the cached valued, in case it's a purge outside a instruction
+ dyn->insts[ninst].e.barrier = 1;
+ #endif
+ }
+ MESSAGE(LOG_DUMP, "\t---Purge x87 Cache and Synch Stackcount\n");
+}
+
+static void x87_reflectcache(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3)
+{
+ //Sync top and stack count
+ int a = dyn->e.x87stack;
+ if(a) {
+ // Add x87stack to emu fpu_stack
+ LW(s2, xEmu, offsetof(x64emu_t, fpu_stack));
+ ADDI(s2, s2, a);
+ SW(s2, xEmu, offsetof(x64emu_t, fpu_stack));
+ // Sub x87stack to top, with and 7
+ LW(s2, xEmu, offsetof(x64emu_t, top));
+ SUBI(s2, s2, a);
+ ANDI(s2, s2, 7);
+ SW(s2, xEmu, offsetof(x64emu_t, top));
+ }
+ int ret = 0;
+ for (int i=0; (i<8) && (!ret); ++i)
+ if(dyn->e.x87cache[i] != -1)
+ ret = 1;
+ if(!ret) // nothing to do
+ return;
+ // prepare offset to fpu => s1
+ // Get top
+ if(!a) {
+ LW(s2, xEmu, offsetof(x64emu_t, top));
+ }
+ // loop all cache entries
+ for (int i=0; i<8; ++i)
+ if(dyn->e.x87cache[i]!=-1) {
+ ADDI(s3, s2, dyn->e.x87cache[i]);
+ ANDI(s3, s3, 7); // (emu->top + i)&7
+ if(rv64_zba) SH3ADD(s1, s3, xEmu); else {SLLI(s1, s3, 3); ADD(s1, xEmu, s1);}
+ if(extcache_get_st_f(dyn, ninst, dyn->e.x87cache[i])>=0) {
+ FCVTDS(SCRATCH0, dyn->e.x87reg[i]);
+ FSD(SCRATCH0, s1, offsetof(x64emu_t, x87));
+ } else
+ FSD(dyn->e.x87reg[i], s1, offsetof(x64emu_t, x87));
+ }
+}
+
+static void x87_unreflectcache(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3)
+{
+ // revert top and stack count
+ int a = dyn->e.x87stack;
+ if(a) {
+ // Sub x87stack to emu fpu_stack
+ LW(s2, xEmu, offsetof(x64emu_t, fpu_stack));
+ SUBI(s2, s2, a);
+ SW(s2, xEmu, offsetof(x64emu_t, fpu_stack));
+ // Add x87stack to top, with and 7
+ LW(s2, xEmu, offsetof(x64emu_t, top));
+ ADDI(s2, s2, a);
+ ANDI(s2, s2, 7);
+ SW(s2, xEmu, offsetof(x64emu_t, top));
+ }
+}
+
+int x87_get_current_cache(dynarec_rv64_t* dyn, int ninst, int st, int t)
+{
+ // search in cache first
+ for (int i=0; i<8; ++i) {
+ if(dyn->e.x87cache[i]==st) {
+ #if STEP == 1
+ if(t==EXT_CACHE_ST_D && (dyn->e.extcache[EXTIDX(dyn->e.x87reg[i])].t==EXT_CACHE_ST_F))
+ extcache_promote_double(dyn, ninst, st);
+ #endif
+ return i;
+ }
+ assert(dyn->e.x87cache[i]<8);
+ }
+ return -1;
+}
+
+int x87_get_cache(dynarec_rv64_t* dyn, int ninst, int populate, int s1, int s2, int st, int t)
+{
+ if(dyn->e.mmxcount)
+ mmx_purgecache(dyn, ninst, 0, s1);
+ int ret = x87_get_current_cache(dyn, ninst, st, t);
+ if(ret!=-1)
+ return ret;
+ MESSAGE(LOG_DUMP, "\tCreate %sx87 Cache for ST%d\n", populate?"and populate ":"", st);
+ // get a free spot
+ for (int i=0; (i<8) && (ret==-1); ++i)
+ if(dyn->e.x87cache[i]==-1)
+ ret = i;
+ // found, setup and grab the value
+ dyn->e.x87cache[ret] = st;
+ dyn->e.x87reg[ret] = fpu_get_reg_x87(dyn, EXT_CACHE_ST_D, st);
+ if(populate) {
+ LW(s2, xEmu, offsetof(x64emu_t, top));
+ int a = st - dyn->e.x87stack;
+ if(a) {
+ ADDI(s2, s2, a);
+ ANDI(s2, s2, 7);
+ }
+ if(rv64_zba) SH3ADD(s1, s2, xEmu); else {SLLI(s2, s2, 3); ADD(s1, xEmu, s2);}
+ FLD(dyn->e.x87reg[ret], s1, offsetof(x64emu_t, x87));
+ }
+ MESSAGE(LOG_DUMP, "\t-------x87 Cache for ST%d\n", st);
+
+ return ret;
+}
+int x87_get_extcache(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int st)
+{
+ for(int ii=0; ii<24; ++ii)
+ if((dyn->e.extcache[ii].t == EXT_CACHE_ST_F || dyn->e.extcache[ii].t == EXT_CACHE_ST_D)
+ && dyn->e.extcache[ii].n==st)
+ return ii;
+ assert(0);
+ return -1;
+}
+int x87_get_st(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int a, int t)
+{
+ return dyn->e.x87reg[x87_get_cache(dyn, ninst, 1, s1, s2, a, t)];
+}
+int x87_get_st_empty(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int a, int t)
+{
+ return dyn->e.x87reg[x87_get_cache(dyn, ninst, 0, s1, s2, a, t)];
+}
+
+
+void x87_refresh(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int st)
+{
+ x87_stackcount(dyn, ninst, s1);
+ int ret = -1;
+ for (int i=0; (i<8) && (ret==-1); ++i)
+ if(dyn->e.x87cache[i] == st)
+ ret = i;
+ if(ret==-1) // nothing to do
+ return;
+ MESSAGE(LOG_DUMP, "\tRefresh x87 Cache for ST%d\n", st);
+ // prepare offset to fpu => s1
+ // Get top
+ LW(s2, xEmu, offsetof(x64emu_t, top));
+ // Update
+ if(st) {
+ ADDI(s2, s2, st);
+ ANDI(s2, s2, 7); // (emu->top + i)&7
+ }
+ ADD(s1, xEmu, s2);
+ if(dyn->e.extcache[EXTIDX(dyn->e.x87reg[ret])].t==EXT_CACHE_ST_F) {
+ FCVTDS(SCRATCH0, dyn->e.x87reg[ret]);
+ FSD(SCRATCH0, s1, offsetof(x64emu_t, x87));
+ } else {
+ FSD(dyn->e.x87reg[ret], s1, offsetof(x64emu_t, x87));
+ }
+ MESSAGE(LOG_DUMP, "\t--------x87 Cache for ST%d\n", st);
+}
+
+void x87_forget(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int st)
+{
+ x87_stackcount(dyn, ninst, s1);
+ int ret = -1;
+ for (int i=0; (i<8) && (ret==-1); ++i)
+ if(dyn->e.x87cache[i] == st)
+ ret = i;
+ if(ret==-1) // nothing to do
+ return;
+ MESSAGE(LOG_DUMP, "\tForget x87 Cache for ST%d\n", st);
+ #if STEP == 1
+ if(dyn->e.extcache[EXTIDX(dyn->e.x87reg[ret])].t==EXT_CACHE_ST_F)
+ extcache_promote_double(dyn, ninst, st);
+ #endif
+ // prepare offset to fpu => s1
+ // Get top
+ LW(s2, xEmu, offsetof(x64emu_t, top));
+ // Update
+ int a = st - dyn->e.x87stack;
+ if(a) {
+ ADDI(s2, s2, a);
+ ANDI(s2, s2, 7); // (emu->top + i)&7
+ }
+ if(rv64_zba) SH3ADD(s1, s2, xEmu); else {SLLI(s2, s2, 3); ADD(s1, xEmu, s2);}
+ FSD(dyn->e.x87reg[ret], s1, offsetof(x64emu_t, x87));
+ MESSAGE(LOG_DUMP, "\t--------x87 Cache for ST%d\n", st);
+ // and forget that cache
+ fpu_free_reg(dyn, dyn->e.x87reg[ret]);
+ dyn->e.extcache[EXTIDX(dyn->e.x87reg[ret])].v = 0;
+ dyn->e.x87cache[ret] = -1;
+ dyn->e.x87reg[ret] = -1;
+}
+
+void x87_reget_st(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int st)
+{
+ if(dyn->e.mmxcount)
+ mmx_purgecache(dyn, ninst, 0, s1);
+ // search in cache first
+ for (int i=0; i<8; ++i)
+ if(dyn->e.x87cache[i]==st) {
+ // refresh the value
+ MESSAGE(LOG_DUMP, "\tRefresh x87 Cache for ST%d\n", st);
+ #if STEP == 1
+ if(dyn->e.extcache[EXTIDX(dyn->e.x87reg[i])].t==EXT_CACHE_ST_F)
+ extcache_promote_double(dyn, ninst, st);
+ #endif
+ LW(s2, xEmu, offsetof(x64emu_t, top));
+ int a = st - dyn->e.x87stack;
+ if(a) {
+ ADDI(s2, s2, a);
+ AND(s2, s2, 7);
+ }
+ if(rv64_zba) SH3ADD(s1, s2, xEmu); else {SLLI(s2, s2, 3); ADD(s1, xEmu, s2);}
+ FLD(dyn->e.x87reg[i], s1, offsetof(x64emu_t, x87));
+ MESSAGE(LOG_DUMP, "\t-------x87 Cache for ST%d\n", st);
+ // ok
+ return;
+ }
+ // Was not in the cache? creating it....
+ MESSAGE(LOG_DUMP, "\tCreate x87 Cache for ST%d\n", st);
+ // get a free spot
+ int ret = -1;
+ for (int i=0; (i<8) && (ret==-1); ++i)
+ if(dyn->e.x87cache[i]==-1)
+ ret = i;
+ // found, setup and grab the value
+ dyn->e.x87cache[ret] = st;
+ dyn->e.x87reg[ret] = fpu_get_reg_x87(dyn, EXT_CACHE_ST_D, st);
+ LW(s2, xEmu, offsetof(x64emu_t, top));
+ int a = st - dyn->e.x87stack;
+ ADDI(s2, s2, a);
+ ANDI(s2, s2, 7); // (emu->top + i)&7
+ if(rv64_zba) SH3ADD(s1, s2, xEmu); else {SLLI(s2, s2, 3); ADD(s1, xEmu, s2);}
+ FLD(dyn->e.x87reg[ret], s1, offsetof(x64emu_t, x87));
+ MESSAGE(LOG_DUMP, "\t-------x87 Cache for ST%d\n", st);
+}
+
+void x87_swapreg(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int a, int b)
+{
+ int i1, i2, i3;
+ i1 = x87_get_cache(dyn, ninst, 1, s1, s2, b, X87_ST(b));
+ i2 = x87_get_cache(dyn, ninst, 1, s1, s2, a, X87_ST(a));
+ i3 = dyn->e.x87cache[i1];
+ dyn->e.x87cache[i1] = dyn->e.x87cache[i2];
+ dyn->e.x87cache[i2] = i3;
+ // swap those too
+ int j1, j2, j3;
+ j1 = x87_get_extcache(dyn, ninst, s1, s2, b);
+ j2 = x87_get_extcache(dyn, ninst, s1, s2, a);
+ j3 = dyn->e.extcache[j1].n;
+ dyn->e.extcache[j1].n = dyn->e.extcache[j2].n;
+ dyn->e.extcache[j2].n = j3;
+ // mark as swapped
+ dyn->e.swapped = 1;
+ dyn->e.combined1= a; dyn->e.combined2=b;
+}
+
+// Set rounding according to cw flags, return reg to restore flags
+int x87_setround(dynarec_rv64_t* dyn, int ninst, int s1, int s2)
+{
+ MAYUSE(dyn); MAYUSE(ninst);
+ MAYUSE(s1); MAYUSE(s2);
+ LW(s1, xEmu, offsetof(x64emu_t, cw));
+ SRLI(s1, s1, 10);
+ ANDI(s1, s1, 0b11);
+ // MMX/x87 Round mode: 0..3: Nearest, Down, Up, Chop
+ // RV64: 0..7: Nearest, Toward Zero (Chop), Down, Up, Nearest tie to Max, invalid, invalid, dynamic (invalid here)
+ // 0->0, 1->2, 2->3, 3->1
+ BEQ(s1, xZR, 24);
+ ADDI(s2, xZR, 3);
+ BEQ(s1, s2, 12);
+ ADDI(s1, s1, 1);
+ J(8);
+ ADDI(s1, xZR, 1);
+ // transform done (is there a faster way?)
+ FSRM(s1, s1); // exange RM with current
+ return s1;
+}
+
+// Set rounding according to mxcsr flags, return reg to restore flags
+int sse_setround(dynarec_rv64_t* dyn, int ninst, int s1, int s2)
+{
+ MAYUSE(dyn); MAYUSE(ninst);
+ MAYUSE(s1); MAYUSE(s2);
+ LW(s1, xEmu, offsetof(x64emu_t, mxcsr));
+ SRLI(s1, s1, 13);
+ ANDI(s1, s1, 0b11);
+ // MMX/x87 Round mode: 0..3: Nearest, Down, Up, Chop
+ // RV64: 0..7: Nearest, Toward Zero (Chop), Down, Up, Nearest tie to Max, invalid, invalid, dynamic (invalid here)
+ // 0->0, 1->2, 2->3, 3->1
+ BEQ(s1, xZR, 24);
+ ADDI(s2, xZR, 3);
+ BEQ(s1, s2, 12);
+ ADDI(s1, s1, 1);
+ J(8);
+ ADDI(s1, xZR, 1);
+ // transform done (is there a faster way?)
+ FSRM(s1, s1); // exange RM with current
+ return s1;
+}
+
+// Restore round flag, destroy s1 doing so
+void x87_restoreround(dynarec_rv64_t* dyn, int ninst, int s1)
+{
+ MAYUSE(dyn); MAYUSE(ninst);
+ MAYUSE(s1);
+ FSRM(s1, s1); // put back fpscr
+}
+
+// MMX helpers
+static void mmx_reset(dynarec_rv64_t* dyn)
+{
+ dyn->e.mmxcount = 0;
+ for (int i=0; i<8; ++i)
+ dyn->e.mmxcache[i] = -1;
+}
+static int isx87Empty(dynarec_rv64_t* dyn)
+{
+ for (int i=0; i<8; ++i)
+ if(dyn->e.x87cache[i] != -1)
+ return 0;
+ return 1;
+}
+
+// forget ext register for a MMX reg, does nothing if the regs is not loaded
+void mmx_forget_reg(dynarec_rv64_t* dyn, int ninst, int a)
+{
+ if (dyn->e.mmxcache[a] == -1)
+ return;
+ FSD(dyn->e.mmxcache[a], xEmu, offsetof(x64emu_t, mmx[a]));
+ fpu_free_reg(dyn, dyn->e.mmxcache[a]);
+ return;
+}
+
+// get neon register for a MMX reg, create the entry if needed
+int mmx_get_reg(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int a)
+{
+ if(!dyn->e.x87stack && isx87Empty(dyn))
+ x87_purgecache(dyn, ninst, 0, s1, s2, s3);
+ if(dyn->e.mmxcache[a]!=-1)
+ return dyn->e.mmxcache[a];
+ ++dyn->e.mmxcount;
+ int ret = dyn->e.mmxcache[a] = fpu_get_reg_emm(dyn, a);
+ FLD(ret, xEmu, offsetof(x64emu_t, mmx[a]));
+ return ret;
+}
+// get neon register for a MMX reg, but don't try to synch it if it needed to be created
+int mmx_get_reg_empty(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int a)
+{
+ if(!dyn->e.x87stack && isx87Empty(dyn))
+ x87_purgecache(dyn, ninst, 0, s1, s2, s3);
+ if(dyn->e.mmxcache[a]!=-1)
+ return dyn->e.mmxcache[a];
+ ++dyn->e.mmxcount;
+ int ret = dyn->e.mmxcache[a] = fpu_get_reg_emm(dyn, a);
+ return ret;
+}
+// purge the MMX cache only(needs 3 scratch registers)
+void mmx_purgecache(dynarec_rv64_t* dyn, int ninst, int next, int s1)
+{
+ if(!dyn->e.mmxcount)
+ return;
+ if(!next)
+ dyn->e.mmxcount = 0;
+ int old = -1;
+ for (int i=0; i<8; ++i)
+ if(dyn->e.mmxcache[i]!=-1) {
+ if (old==-1) {
+ MESSAGE(LOG_DUMP, "\tPurge %sMMX Cache ------\n", next?"locally ":"");
+ ++old;
+ }
+ FSD(dyn->e.mmxcache[i], xEmu, offsetof(x64emu_t, mmx[i]));
+ if(!next) {
+ fpu_free_reg(dyn, dyn->e.mmxcache[i]);
+ dyn->e.mmxcache[i] = -1;
+ }
+ }
+ if(old!=-1) {
+ MESSAGE(LOG_DUMP, "\t------ Purge MMX Cache\n");
+ }
+}
+
+static void mmx_reflectcache(dynarec_rv64_t* dyn, int ninst, int s1)
+{
+ for (int i=0; i<8; ++i)
+ if(dyn->e.mmxcache[i]!=-1) {
+ FLD(dyn->e.mmxcache[i], xEmu, offsetof(x64emu_t, mmx[i]));
+ }
+}
+
+// SSE / SSE2 helpers
+static void sse_reset(dynarec_rv64_t* dyn)
+{
+ for (int i=0; i<16; ++i)
+ dyn->e.ssecache[i].v = -1;
+}
+// get ext register for a SSE reg, create the entry if needed
+int sse_get_reg(dynarec_rv64_t* dyn, int ninst, int s1, int a, int single)
+{
+ if(dyn->e.ssecache[a].v!=-1) {
+ // forget / reload if change of size
+ if(dyn->e.ssecache[a].single!=single) {
+ sse_forget_reg(dyn, ninst, a);
+ // update olds after the forget...
+ dyn->e.olds[a].changed = 1;
+ dyn->e.olds[a].purged = 0;
+ dyn->e.olds[a].single = 1-single;
+ return sse_get_reg(dyn, ninst, s1, a, single);
+ }
+ return dyn->e.ssecache[a].reg;
+ }
+ dyn->e.ssecache[a].reg = fpu_get_reg_xmm(dyn, single?EXT_CACHE_SS:EXT_CACHE_SD, a);
+ int ret = dyn->e.ssecache[a].reg;
+ dyn->e.ssecache[a].single = single;
+ if(dyn->e.ssecache[a].single)
+ FLW(dyn->e.ssecache[a].reg, xEmu, offsetof(x64emu_t, xmm[a]));
+ else
+ FLD(dyn->e.ssecache[a].reg, xEmu, offsetof(x64emu_t, xmm[a]));
+ return ret;
+}
+// get ext register for a SSE reg, but don't try to synch it if it needed to be created
+int sse_get_reg_empty(dynarec_rv64_t* dyn, int ninst, int s1, int a, int single)
+{
+ if(dyn->e.ssecache[a].v!=-1) {
+ if(dyn->e.ssecache[a].single!=single && single) {
+ // writting back the double
+ FSD(dyn->e.ssecache[a].reg, xEmu, offsetof(x64emu_t, xmm[a]));
+ // need to wipe the half high 32bits of old Double because we now have a single
+ //SW(xZR, xEmu, offsetof(x64emu_t, xmm[a])+4);
+ }
+ dyn->e.olds[a].changed = 1;
+ dyn->e.olds[a].purged = 0;
+ dyn->e.olds[a].reg = EXTIDX(dyn->e.ssecache[a].reg);
+ dyn->e.olds[a].single = 1-single;
+ dyn->e.ssecache[a].single = single;
+ dyn->e.extcache[EXTIDX(dyn->e.ssecache[a].reg)].t = single?EXT_CACHE_SS:EXT_CACHE_SD;
+ return dyn->e.ssecache[a].reg;
+ }
+ dyn->e.ssecache[a].reg = fpu_get_reg_xmm(dyn, single?EXT_CACHE_SS:EXT_CACHE_SD, a);
+ dyn->e.ssecache[a].single = single;
+ return dyn->e.ssecache[a].reg;
+}
+// forget ext register for a SSE reg, does nothing if the regs is not loaded
+void sse_forget_reg(dynarec_rv64_t* dyn, int ninst, int a)
+{
+ if(dyn->e.ssecache[a].v==-1)
+ return;
+ if(dyn->e.ssecache[a].single)
+ FSW(dyn->e.ssecache[a].reg, xEmu, offsetof(x64emu_t, xmm[a]));
+ else
+ FSD(dyn->e.ssecache[a].reg, xEmu, offsetof(x64emu_t, xmm[a]));
+ fpu_free_reg(dyn, dyn->e.ssecache[a].reg);
+ dyn->e.olds[a].changed = 0;
+ dyn->e.olds[a].purged = 1;
+ dyn->e.olds[a].reg = dyn->e.ssecache[a].reg;
+ dyn->e.olds[a].single = dyn->e.ssecache[a].single;
+ dyn->e.ssecache[a].v = -1;
+ return;
+}
+// purge the SSE cache for XMM0..XMM7 (to use before function native call)
+void sse_purge07cache(dynarec_rv64_t* dyn, int ninst, int s1)
+{
+ int old = -1;
+ for (int i=0; i<8; ++i)
+ if(dyn->e.ssecache[i].v!=-1) {
+ if (old==-1) {
+ MESSAGE(LOG_DUMP, "\tPurge XMM0..7 Cache ------\n");
+ ++old;
+ }
+ if(dyn->e.ssecache[i].single)
+ FSW(dyn->e.ssecache[i].reg, xEmu, offsetof(x64emu_t, xmm[i]));
+ else
+ FSD(dyn->e.ssecache[i].reg, xEmu, offsetof(x64emu_t, xmm[i]));
+ fpu_free_reg(dyn, dyn->e.ssecache[i].reg);
+ dyn->e.ssecache[i].v = -1;
+ }
+ if(old!=-1) {
+ MESSAGE(LOG_DUMP, "\t------ Purge XMM0..7 Cache\n");
+ }
+}
+
+// purge the SSE cache only
+static void sse_purgecache(dynarec_rv64_t* dyn, int ninst, int next, int s1)
+{
+ int old = -1;
+ for (int i=0; i<16; ++i)
+ if(dyn->e.ssecache[i].v!=-1) {
+ if (old==-1) {
+ MESSAGE(LOG_DUMP, "\tPurge %sSSE Cache ------\n", next?"locally ":"");
+ ++old;
+ }
+ if(dyn->e.ssecache[i].single)
+ FSW(dyn->e.ssecache[i].reg, xEmu, offsetof(x64emu_t, xmm[i]));
+ else
+ FSD(dyn->e.ssecache[i].reg, xEmu, offsetof(x64emu_t, xmm[i]));
+ if(!next) {
+ fpu_free_reg(dyn, dyn->e.ssecache[i].reg);
+ dyn->e.olds[i].changed = 0;
+ dyn->e.olds[i].purged = 1;
+ dyn->e.olds[i].reg = dyn->e.ssecache[i].reg;
+ dyn->e.olds[i].single = dyn->e.ssecache[i].single;
+ dyn->e.ssecache[i].v = -1;
+ }
+ }
+ if(old!=-1) {
+ MESSAGE(LOG_DUMP, "\t------ Purge SSE Cache\n");
+ }
+}
+
+static void sse_reflectcache(dynarec_rv64_t* dyn, int ninst, int s1)
+{
+ for (int i=0; i<16; ++i)
+ if(dyn->e.ssecache[i].v!=-1) {
+ if(dyn->e.ssecache[i].single)
+ FSW(dyn->e.ssecache[i].reg, xEmu, offsetof(x64emu_t, xmm[i]));
+ else
+ FSD(dyn->e.ssecache[i].reg, xEmu, offsetof(x64emu_t, xmm[i]));
+ }
+}
+
+void fpu_pushcache(dynarec_rv64_t* dyn, int ninst, int s1, int not07)
+{
+ // need to save 0..1 && 10..17 (maybe) && 28..31
+ // so 0..7 (SSE) && 17..23 (x87+MMX)
+ int start = not07?8:0;
+ // only SSE regs needs to be push back to xEmu (needs to be "write")
+ int n=0;
+ for (int i=start; i<8; i++)
+ if(dyn->e.ssecache[i].v!=-1)
+ ++n;
+ if(n) {
+ MESSAGE(LOG_DUMP, "\tPush XMM Cache (%d)------\n", n);
+ for (int i=start; i<8; ++i)
+ if(dyn->e.ssecache[i].v!=-1) {
+ if(dyn->e.ssecache[i].single)
+ FSW(dyn->e.ssecache[i].reg, xEmu, offsetof(x64emu_t, xmm[i]));
+ else
+ FSD(dyn->e.ssecache[i].reg, xEmu, offsetof(x64emu_t, xmm[i]));
+ }
+ MESSAGE(LOG_DUMP, "\t------- Push XMM Cache (%d)\n", n);
+ }
+ n = 0;
+ for(int i=17; i<24; ++i)
+ if(dyn->e.extcache[i].v!=0)
+ ++n;
+ if(n) {
+ MESSAGE(LOG_DUMP, "\tPush x87/MMX Cache (%d)------\n", n);
+ SUBI(xSP, xSP, 8*((n+1)&~1));
+ int p = 0;
+ for(int i=17; i<24; ++i)
+ if(dyn->e.extcache[i].v!=0) {
+ switch(dyn->e.extcache[i].t) {
+ case EXT_CACHE_ST_F:
+ case EXT_CACHE_SS:
+ FSW(EXTREG(i), xSP, p*8);
+ break;
+ default:
+ FSD(EXTREG(i), xSP, p*8);
+ break;
+ };
+ ++p;
+ }
+ MESSAGE(LOG_DUMP, "\t------- Push x87/MMX Cache (%d)\n", n);
+ }
+}
+void fpu_popcache(dynarec_rv64_t* dyn, int ninst, int s1, int not07)
+{
+ int start = not07?8:0;
+ // only SSE regs needs to be pop back from xEmu (don't need to be "write" this time)
+ int n=0;
+ for (int i=start; i<8; i++)
+ if(dyn->e.ssecache[i].v!=-1)
+ ++n;
+ if(n) {
+ MESSAGE(LOG_DUMP, "\tPop XMM Cache (%d)------\n", n);
+ for (int i=start; i<8; ++i)
+ if(dyn->e.ssecache[i].v!=-1) {
+ if(dyn->e.ssecache[i].single)
+ FLW(dyn->e.ssecache[i].reg, xEmu, offsetof(x64emu_t, xmm[i]));
+ else
+ FLD(dyn->e.ssecache[i].reg, xEmu, offsetof(x64emu_t, xmm[i]));
+ }
+ MESSAGE(LOG_DUMP, "\t------- Pop XMM Cache (%d)\n", n);
+ }
+ n = 0;
+ for(int i=17; i<24; ++i)
+ if(dyn->e.extcache[i].v!=0)
+ ++n;
+ if(n) {
+ MESSAGE(LOG_DUMP, "\tPush x87/MMX Cache (%d)------\n", n);
+ int p = 0;
+ for(int i=17; i<24; ++i)
+ if(dyn->e.extcache[i].v!=0) {
+ switch(dyn->e.extcache[i].t) {
+ case EXT_CACHE_ST_F:
+ case EXT_CACHE_SS:
+ FLW(EXTREG(i), xSP, p*8);
+ break;
+ default:
+ FLD(EXTREG(i), xSP, p*8);
+ break;
+ };
+ ++p;
+ }
+ ADDI(xSP, xSP, 8*((n+1)&~1));
+ MESSAGE(LOG_DUMP, "\t------- Push x87/MMX Cache (%d)\n", n);
+ }
+}
+
+void fpu_purgecache(dynarec_rv64_t* dyn, int ninst, int next, int s1, int s2, int s3)
+{
+ x87_purgecache(dyn, ninst, next, s1, s2, s3);
+ mmx_purgecache(dyn, ninst, next, s1);
+ sse_purgecache(dyn, ninst, next, s1);
+ if(!next)
+ fpu_reset_reg(dyn);
+}
+
+static int findCacheSlot(dynarec_rv64_t* dyn, int ninst, int t, int n, extcache_t* cache)
+{
+ ext_cache_t f;
+ f.n = n; f.t = t;
+ for(int i=0; i<24; ++i) {
+ if(cache->extcache[i].v == f.v)
+ return i;
+ if(cache->extcache[i].n == n) {
+ switch(cache->extcache[i].t) {
+ case EXT_CACHE_ST_F:
+ if (t==EXT_CACHE_ST_D)
+ return i;
+ break;
+ case EXT_CACHE_ST_D:
+ if (t==EXT_CACHE_ST_F)
+ return i;
+ break;
+ }
+ }
+ }
+ return -1;
+}
+
+static void swapCache(dynarec_rv64_t* dyn, int ninst, int i, int j, extcache_t *cache)
+{
+ if (i==j)
+ return;
+ int reg_i = EXTREG(i);
+ int reg_j = EXTREG(j);
+ int i_single = 0;
+ if(cache->extcache[i].t==EXT_CACHE_SS || cache->extcache[i].t==EXT_CACHE_ST_F)
+ i_single =1;
+ int j_single = 0;
+ if(cache->extcache[j].t==EXT_CACHE_SS || cache->extcache[j].t==EXT_CACHE_ST_F)
+ j_single =1;
+
+ if(!cache->extcache[i].v) {
+ // a mov is enough, no need to swap
+ MESSAGE(LOG_DUMP, "\t - Moving %d <- %d\n", i, j);
+ if(j_single) {
+ FMVS(reg_i, reg_j);
+ } else {
+ FMVD(reg_i, reg_j);
+ }
+ cache->extcache[i].v = cache->extcache[j].v;
+ cache->extcache[j].v = 0;
+ return;
+ }
+ // SWAP
+ ext_cache_t tmp;
+ MESSAGE(LOG_DUMP, "\t - Swapping %d <-> %d\n", i, j);
+ // There is no VSWP in Arm64 NEON to swap 2 register contents!
+ // so use a scratch...
+ #define SCRATCH 0
+ if(i_single)
+ FMVS(SCRATCH, reg_i);
+ else
+ FMVD(SCRATCH, reg_i);
+ if(j_single)
+ FMVS(reg_i, reg_j);
+ else
+ FMVD(reg_i, reg_j);
+ if(i_single)
+ FMVS(reg_j, SCRATCH);
+ else
+ FMVD(reg_j, SCRATCH);
+ #undef SCRATCH
+ tmp.v = cache->extcache[i].v;
+ cache->extcache[i].v = cache->extcache[j].v;
+ cache->extcache[j].v = tmp.v;
+}
+
+static void loadCache(dynarec_rv64_t* dyn, int ninst, int stack_cnt, int s1, int s2, int s3, int* s1_val, int* s2_val, int* s3_top, extcache_t *cache, int i, int t, int n)
+{
+ int reg = EXTREG(i);
+ if(cache->extcache[i].v) {
+ int single = 0;
+ if(t==EXT_CACHE_SS || t==EXT_CACHE_ST_F)
+ single = 1;
+ if(cache->extcache[i].t==EXT_CACHE_SS || cache->extcache[i].t==EXT_CACHE_ST_F)
+ single = 1;
+ int j = i+1;
+ while(cache->extcache[j].v)
+ ++j;
+ MESSAGE(LOG_DUMP, "\t - Moving away %d\n", i);
+ if(single) {
+ FMVS(EXTREG(j), reg);
+ } else {
+ FMVD(EXTREG(j), reg);
+ }
+ cache->extcache[j].v = cache->extcache[i].v;
+ }
+ switch(t) {
+ case EXT_CACHE_SS:
+ MESSAGE(LOG_DUMP, "\t - Loading %s\n", getCacheName(t, n));
+ FLW(reg, xEmu, offsetof(x64emu_t, xmm[n]));
+ break;
+ case EXT_CACHE_SD:
+ MESSAGE(LOG_DUMP, "\t - Loading %s\n", getCacheName(t, n));
+ FLD(reg, xEmu, offsetof(x64emu_t, xmm[n]));
+ break;
+ case EXT_CACHE_MM:
+ MESSAGE(LOG_DUMP, "\t - Loading %s\n", getCacheName(t, n));
+ FLD(reg, xEmu, offsetof(x64emu_t, mmx[i]));
+ break;
+ case EXT_CACHE_ST_D:
+ case EXT_CACHE_ST_F:
+ MESSAGE(LOG_DUMP, "\t - Loading %s\n", getCacheName(t, n));
+ if((*s3_top) == 0xffff) {
+ LW(s3, xEmu, offsetof(x64emu_t, top));
+ *s3_top = 0;
+ }
+ int a = n - (*s3_top) - stack_cnt;
+ if(a) {
+ ADDI(s3, s3, a);
+ ANDI(s3, s3, 7); // (emu->top + i)&7
+ }
+ *s3_top += a;
+ *s2_val = 0;
+ if(rv64_zba) SH3ADD(s2, s3, xEmu); else {SLLI(s2, s3, 3); ADD(s2, xEmu, s2);}
+ FLD(reg, s2, offsetof(x64emu_t, x87));
+ if(t==EXT_CACHE_ST_F) {
+ FCVTSD(reg, reg);
+ }
+ break;
+ case EXT_CACHE_NONE:
+ case EXT_CACHE_SCR:
+ default: /* nothing done */
+ MESSAGE(LOG_DUMP, "\t - ignoring %s\n", getCacheName(t, n));
+ break;
+ }
+ cache->extcache[i].n = n;
+ cache->extcache[i].t = t;
+}
+
+static void unloadCache(dynarec_rv64_t* dyn, int ninst, int stack_cnt, int s1, int s2, int s3, int* s1_val, int* s2_val, int* s3_top, extcache_t *cache, int i, int t, int n)
+{
+ int reg = EXTREG(i);
+ switch(t) {
+ case EXT_CACHE_SS:
+ MESSAGE(LOG_DUMP, "\t - Unloading %s\n", getCacheName(t, n));
+ FSW(reg, xEmu, offsetof(x64emu_t, xmm[n]));
+ break;
+ case EXT_CACHE_SD:
+ MESSAGE(LOG_DUMP, "\t - Unloading %s\n", getCacheName(t, n));
+ FSD(reg, xEmu, offsetof(x64emu_t, xmm[n]));
+ break;
+ case EXT_CACHE_MM:
+ MESSAGE(LOG_DUMP, "\t - Unloading %s\n", getCacheName(t, n));
+ FSD(reg, xEmu, offsetof(x64emu_t, mmx[n]));
+ break;
+ case EXT_CACHE_ST_D:
+ case EXT_CACHE_ST_F:
+ MESSAGE(LOG_DUMP, "\t - Unloading %s\n", getCacheName(t, n));
+ if((*s3_top)==0xffff) {
+ LW(s3, xEmu, offsetof(x64emu_t, top));
+ *s3_top = 0;
+ }
+ int a = n - (*s3_top) - stack_cnt;
+ if(a) {
+ ADDI(s3, s3, a);
+ ANDI(s3, s3, 7);
+ }
+ *s3_top += a;
+ if(rv64_zba) SH3ADD(s2, s3, xEmu); else {SLLI(s2, s3, 3); ADD(s2, xEmu, s2);}
+ *s2_val = 0;
+ if(t==EXT_CACHE_ST_F) {
+ FCVTDS(reg, reg);
+ }
+ FSD(reg, s2, offsetof(x64emu_t, x87));
+ break;
+ case EXT_CACHE_NONE:
+ case EXT_CACHE_SCR:
+ default: /* nothing done */
+ MESSAGE(LOG_DUMP, "\t - ignoring %s\n", getCacheName(t, n));
+ break;
+ }
+ cache->extcache[i].v = 0;
+}
+
+static void fpuCacheTransform(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3)
+{
+#if STEP > 1
+ int i2 = dyn->insts[ninst].x64.jmp_insts;
+ if(i2<0)
+ return;
+ MESSAGE(LOG_DUMP, "\tCache Transform ---- ninst=%d -> %d\n", ninst, i2);
+ if((!i2) || (dyn->insts[i2].x64.barrier&BARRIER_FLOAT)) {
+ if(dyn->e.stack_next) {
+ fpu_purgecache(dyn, ninst, 1, s1, s2, s3);
+ MESSAGE(LOG_DUMP, "\t---- Cache Transform\n");
+ return;
+ }
+ for(int i=0; i<24; ++i)
+ if(dyn->e.extcache[i].v) { // there is something at ninst for i
+ fpu_purgecache(dyn, ninst, 1, s1, s2, s3);
+ MESSAGE(LOG_DUMP, "\t---- Cache Transform\n");
+ return;
+ }
+ MESSAGE(LOG_DUMP, "\t---- Cache Transform\n");
+ return;
+ }
+ extcache_t cache_i2 = dyn->insts[i2].e;
+ extcacheUnwind(&cache_i2);
+
+ if(!cache_i2.stack) {
+ int purge = 1;
+ for (int i=0; i<24 && purge; ++i)
+ if(cache_i2.extcache[i].v)
+ purge = 0;
+ if(purge) {
+ fpu_purgecache(dyn, ninst, 1, s1, s2, s3);
+ MESSAGE(LOG_DUMP, "\t---- Cache Transform\n");
+ return;
+ }
+ }
+ int stack_cnt = dyn->e.stack_next;
+ int s3_top = 0xffff;
+ if(stack_cnt != cache_i2.stack) {
+ MESSAGE(LOG_DUMP, "\t - adjust stack count %d -> %d -\n", stack_cnt, cache_i2.stack);
+ int a = stack_cnt - cache_i2.stack;
+ // Add x87stack to emu fpu_stack
+ LWU(s3, xEmu, offsetof(x64emu_t, fpu_stack));
+ ADDI(s3, s3, a);
+ SW(s3, xEmu, offsetof(x64emu_t, fpu_stack));
+ // Sub x87stack to top, with and 7
+ LWU(s3, xEmu, offsetof(x64emu_t, top));
+ // update tags (and top at the same time)
+ if(a>0) {
+ // new tag to fulls
+ ADDI(s2, xZR, 0);
+ ADDI(s1, xEmu, offsetof(x64emu_t, p_regs));
+ SLLI(s3, s3, 2);
+ for (int i=0; i<a; ++i) {
+ SUBI(s3, s3, 1<<2);
+ ANDI(s3, s3, 7<<2);
+ ADD(s3, s1, s3);
+ SW(s2, s3, 0); // that slot is full
+ SUB(s3, s3, s1);
+ }
+ SRLI(s3, s3, 2);
+ } else {
+ // empty tags
+ ADDI(s2, xZR, 0b11);
+ ADDI(s1, xEmu, offsetof(x64emu_t, p_regs));
+ SLLI(s3, s3, 2);
+ for (int i=0; i<-a; ++i) {
+ ADD(s3, s1, s3);
+ SW(s2, s3, 0); // empty slot before leaving it
+ SUB(s3, s3, s1);
+ ADDI(s3, s3, 1<<2);
+ ANDI(s3, s3, 7<<2); // (emu->top + st)&7
+ }
+ SRLI(s3, s3, 2);
+ }
+ SW(s3, xEmu, offsetof(x64emu_t, top));
+ s3_top = 0;
+ stack_cnt = cache_i2.stack;
+ }
+ extcache_t cache = dyn->e;
+ int s1_val = 0;
+ int s2_val = 0;
+ // unload every uneeded cache
+ // check SSE first, than MMX, in order, for optimisation issue
+ for(int i=0; i<16; ++i) {
+ int j=findCacheSlot(dyn, ninst, EXT_CACHE_SS, i, &cache);
+ if(j>=0 && findCacheSlot(dyn, ninst, EXT_CACHE_SS, i, &cache_i2)==-1)
+ unloadCache(dyn, ninst, stack_cnt, s1, s2, s3, &s1_val, &s2_val, &s3_top, &cache, j, cache.extcache[j].t, cache.extcache[j].n);
+ j=findCacheSlot(dyn, ninst, EXT_CACHE_SD, i, &cache);
+ if(j>=0 && findCacheSlot(dyn, ninst, EXT_CACHE_SD, i, &cache_i2)==-1)
+ unloadCache(dyn, ninst, stack_cnt, s1, s2, s3, &s1_val, &s2_val, &s3_top, &cache, j, cache.extcache[j].t, cache.extcache[j].n);
+ }
+ for(int i=0; i<8; ++i) {
+ int j=findCacheSlot(dyn, ninst, EXT_CACHE_MM, i, &cache);
+ if(j>=0 && findCacheSlot(dyn, ninst, EXT_CACHE_MM, i, &cache_i2)==-1)
+ unloadCache(dyn, ninst, stack_cnt, s1, s2, s3, &s1_val, &s2_val, &s3_top, &cache, j, cache.extcache[j].t, cache.extcache[j].n);
+ }
+ for(int i=0; i<24; ++i) {
+ if(cache.extcache[i].v)
+ if(findCacheSlot(dyn, ninst, cache.extcache[i].t, cache.extcache[i].n, &cache_i2)==-1)
+ unloadCache(dyn, ninst, stack_cnt, s1, s2, s3, &s1_val, &s2_val, &s3_top, &cache, i, cache.extcache[i].t, cache.extcache[i].n);
+ }
+ // and now load/swap the missing one
+ for(int i=0; i<24; ++i) {
+ if(cache_i2.extcache[i].v) {
+ if(cache_i2.extcache[i].v != cache.extcache[i].v) {
+ int j;
+ if((j=findCacheSlot(dyn, ninst, cache_i2.extcache[i].t, cache_i2.extcache[i].n, &cache))==-1)
+ loadCache(dyn, ninst, stack_cnt, s1, s2, s3, &s1_val, &s2_val, &s3_top, &cache, i, cache_i2.extcache[i].t, cache_i2.extcache[i].n);
+ else {
+ // it's here, lets swap if needed
+ if(j!=i)
+ swapCache(dyn, ninst, i, j, &cache);
+ }
+ }
+ if(cache.extcache[i].t != cache_i2.extcache[i].t) {
+ if(cache.extcache[i].t == EXT_CACHE_ST_D && cache_i2.extcache[i].t == EXT_CACHE_ST_F) {
+ MESSAGE(LOG_DUMP, "\t - Convert %s\n", getCacheName(cache.extcache[i].t, cache.extcache[i].n));
+ FCVTSD(EXTREG(i), EXTREG(i));
+ cache.extcache[i].t = EXT_CACHE_ST_F;
+ } else if(cache.extcache[i].t == EXT_CACHE_ST_F && cache_i2.extcache[i].t == EXT_CACHE_ST_D) {
+ MESSAGE(LOG_DUMP, "\t - Convert %s\n", getCacheName(cache.extcache[i].t, cache.extcache[i].n));
+ FCVTDS(EXTREG(i), EXTREG(i));
+ cache.extcache[i].t = EXT_CACHE_ST_D;
+ }
+ }
+ }
+ }
+ MESSAGE(LOG_DUMP, "\t---- Cache Transform\n");
+#endif
+}
+static void flagsCacheTransform(dynarec_rv64_t* dyn, int ninst, int s1)
+{
+#if STEP > 1
+ int j64;
+ int jmp = dyn->insts[ninst].x64.jmp_insts;
+ if(jmp<0)
+ return;
+ if(dyn->f.dfnone) // flags are fully known, nothing we can do more
+ return;
+ MESSAGE(LOG_DUMP, "\tFlags fetch ---- ninst=%d -> %d\n", ninst, jmp);
+ int go = 0;
+ switch (dyn->insts[jmp].f_entry.pending) {
+ case SF_UNKNOWN: break;
+ case SF_SET:
+ if(dyn->f.pending!=SF_SET && dyn->f.pending!=SF_SET_PENDING)
+ go = 1;
+ break;
+ case SF_SET_PENDING:
+ if(dyn->f.pending!=SF_SET
+ && dyn->f.pending!=SF_SET_PENDING
+ && dyn->f.pending!=SF_PENDING)
+ go = 1;
+ break;
+ case SF_PENDING:
+ if(dyn->f.pending!=SF_SET
+ && dyn->f.pending!=SF_SET_PENDING
+ && dyn->f.pending!=SF_PENDING)
+ go = 1;
+ else
+ go = (dyn->insts[jmp].f_entry.dfnone == dyn->f.dfnone)?0:1;
+ break;
+ }
+ if(dyn->insts[jmp].f_entry.dfnone && !dyn->f.dfnone)
+ go = 1;
+ if(go) {
+ if(dyn->f.pending!=SF_PENDING) {
+ LW(s1, xEmu, offsetof(x64emu_t, df));
+ j64 = (GETMARKF2)-(dyn->native_size);
+ BEQZ(s1, j64);
+ }
+ CALL_(UpdateFlags, -1, 0);
+ MARKF2;
+ }
+#endif
+}
+
+void CacheTransform(dynarec_rv64_t* dyn, int ninst, int cacheupd, int s1, int s2, int s3) {
+ if(cacheupd&2)
+ fpuCacheTransform(dyn, ninst, s1, s2, s3);
+ if(cacheupd&1)
+ flagsCacheTransform(dyn, ninst, s1);
+}
+
+
+void rv64_move32(dynarec_rv64_t* dyn, int ninst, int reg, int32_t val, int zeroup)
+{
+ // Depending on val, the following insns are emitted.
+ // val == 0 -> ADDI
+ // lo12 != 0 && hi20 == 0 -> ADDI
+ // lo12 == 0 && hi20 != 0 -> LUI
+ // else -> LUI+ADDI
+ int32_t hi20 = (val+0x800)>>12 & 0xfffff;
+ int32_t lo12 = val&0xfff;
+
+ int src = xZR;
+ if (hi20) {
+ LUI(reg, hi20);
+ src = reg;
+ }
+ if (lo12 || !hi20) ADDIW(reg, src, lo12);
+ if((zeroup && ((hi20&0x80000) || (!hi20 && (lo12&0x800)))
+ || (!zeroup && !(val&0x80000000) && ((hi20&0x80000) || (!hi20 && (lo12&0x800)))))) {
+ ZEROUP(reg);
+ }
+}
+
+void rv64_move64(dynarec_rv64_t* dyn, int ninst, int reg, int64_t val)
+{
+ if(((val<<32)>>32)==val) {
+ // 32bits value
+ rv64_move32(dyn, ninst, reg, val, 0);
+ return;
+ }
+
+ int64_t lo12 = (val<<52)>>52;
+ int64_t hi52 = (val+0x800)>>12;
+ int shift = 12+TrailingZeros64((uint64_t)hi52);
+ hi52 = ((hi52>>(shift-12))<<shift)>>shift;
+ rv64_move64(dyn, ninst, reg, hi52);
+ SLLI(reg, reg, shift);
+
+ if (lo12) {
+ ADDI(reg, reg, lo12);
+ }
+}
+
+void fpu_reflectcache(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3)
+{
+ x87_reflectcache(dyn, ninst, s1, s2, s3);
+ mmx_reflectcache(dyn, ninst, s1);
+ sse_reflectcache(dyn, ninst, s1);
+}
+
+void fpu_unreflectcache(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3)
+{
+ // need to undo the top and stack tracking that must not be reflected permenatly yet
+ x87_unreflectcache(dyn, ninst, s1, s2, s3);
+}
+
+void fpu_reset(dynarec_rv64_t* dyn)
+{
+ x87_reset(dyn);
+ mmx_reset(dyn);
+ sse_reset(dyn);
+ fpu_reset_reg(dyn);
+}
+
+void emit_pf(dynarec_rv64_t* dyn, int ninst, int s1, int s3, int s4)
+{
+ MAYUSE(dyn); MAYUSE(ninst);
+ // PF: (((emu->x64emu_parity_tab[(res&0xff) / 32] >> ((res&0xff) % 32)) & 1) == 0)
+ MOV64x(s4, (uintptr_t)GetParityTab());
+ SRLI(s3, s1, 3);
+ ANDI(s3, s3, 28);
+ ADD(s4, s4, s3);
+ LW(s4, s4, 0);
+ NOT(s4, s4);
+ SRLW(s4, s4, s1);
+ ANDI(s4, s4, 1);
+
+ BEQZ(s4, 8);
+ ORI(xFlags, xFlags, 1 << F_PF);
+}
+
+void fpu_reset_cache(dynarec_rv64_t* dyn, int ninst, int reset_n)
+{
+ MESSAGE(LOG_DEBUG, "Reset Caches with %d\n",reset_n);
+ #if STEP > 1
+ // for STEP 2 & 3, just need to refrest with current, and undo the changes (push & swap)
+ dyn->e = dyn->insts[ninst].e;
+ extcacheUnwind(&dyn->e);
+ #ifdef HAVE_TRACE
+ if(box64_dynarec_dump)
+ if(memcmp(&dyn->e, &dyn->insts[reset_n].e, sizeof(ext_cache_t))) {
+ MESSAGE(LOG_DEBUG, "Warning, difference in extcache: reset=");
+ for(int i=0; i<24; ++i)
+ if(dyn->insts[reset_n].e.extcache[i].v)
+ MESSAGE(LOG_DEBUG, " %02d:%s", i, getCacheName(dyn->insts[reset_n].e.extcache[i].t, dyn->insts[reset_n].e.extcache[i].n));
+ if(dyn->insts[reset_n].e.combined1 || dyn->insts[reset_n].e.combined2)
+ MESSAGE(LOG_DEBUG, " %s:%02d/%02d", dyn->insts[reset_n].e.swapped?"SWP":"CMB", dyn->insts[reset_n].e.combined1, dyn->insts[reset_n].e.combined2);
+ if(dyn->insts[reset_n].e.stack_push || dyn->insts[reset_n].e.stack_pop)
+ MESSAGE(LOG_DEBUG, " (%d:%d)", dyn->insts[reset_n].e.stack_push, -dyn->insts[reset_n].e.stack_pop);
+ MESSAGE(LOG_DEBUG, " ==> ");
+ for(int i=0; i<24; ++i)
+ if(dyn->insts[ninst].e.extcache[i].v)
+ MESSAGE(LOG_DEBUG, " %02d:%s", i, getCacheName(dyn->insts[ninst].e.extcache[i].t, dyn->insts[ninst].e.extcache[i].n));
+ if(dyn->insts[ninst].e.combined1 || dyn->insts[ninst].e.combined2)
+ MESSAGE(LOG_DEBUG, " %s:%02d/%02d", dyn->insts[ninst].e.swapped?"SWP":"CMB", dyn->insts[ninst].e.combined1, dyn->insts[ninst].e.combined2);
+ if(dyn->insts[ninst].e.stack_push || dyn->insts[ninst].e.stack_pop)
+ MESSAGE(LOG_DEBUG, " (%d:%d)", dyn->insts[ninst].e.stack_push, -dyn->insts[ninst].e.stack_pop);
+ MESSAGE(LOG_DEBUG, " -> ");
+ for(int i=0; i<24; ++i)
+ if(dyn->e.extcache[i].v)
+ MESSAGE(LOG_DEBUG, " %02d:%s", i, getCacheName(dyn->e.extcache[i].t, dyn->e.extcache[i].n));
+ if(dyn->e.combined1 || dyn->e.combined2)
+ MESSAGE(LOG_DEBUG, " %s:%02d/%02d", dyn->e.swapped?"SWP":"CMB", dyn->e.combined1, dyn->e.combined2);
+ if(dyn->e.stack_push || dyn->e.stack_pop)
+ MESSAGE(LOG_DEBUG, " (%d:%d)", dyn->e.stack_push, -dyn->e.stack_pop);
+ MESSAGE(LOG_DEBUG, "\n");
+ }
+ #endif //HAVE_TRACE
+ #else
+ dyn->e = dyn->insts[reset_n].e;
+ #endif
+}
+
+// propagate ST stack state, especial stack pop that are deferred
+void fpu_propagate_stack(dynarec_rv64_t* dyn, int ninst)
+{
+ if(dyn->e.stack_pop) {
+ for(int j=0; j<24; ++j)
+ if((dyn->e.extcache[j].t == EXT_CACHE_ST_D || dyn->e.extcache[j].t == EXT_CACHE_ST_F)) {
+ if(dyn->e.extcache[j].n<dyn->e.stack_pop)
+ dyn->e.extcache[j].v = 0;
+ else
+ dyn->e.extcache[j].n-=dyn->e.stack_pop;
+ }
+ dyn->e.stack_pop = 0;
+ }
+ dyn->e.stack = dyn->e.stack_next;
+ dyn->e.news = 0;
+ dyn->e.stack_push = 0;
+ dyn->e.swapped = 0;
+}
diff --git a/src/dynarec/rv64/dynarec_rv64_helper.h b/src/dynarec/rv64/dynarec_rv64_helper.h
new file mode 100644
index 0000000..0b1023b
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_helper.h
@@ -0,0 +1,1348 @@
+#ifndef __DYNAREC_RV64_HELPER_H__
+#define __DYNAREC_RV64_HELPER_H__
+
+// undef to get Close to SSE Float->int conversions
+//#define PRECISE_CVT
+
+#if STEP == 0
+#include "dynarec_rv64_pass0.h"
+#elif STEP == 1
+#include "dynarec_rv64_pass1.h"
+#elif STEP == 2
+#include "dynarec_rv64_pass2.h"
+#elif STEP == 3
+#include "dynarec_rv64_pass3.h"
+#endif
+
+#include "debug.h"
+#include "rv64_emitter.h"
+#include "../emu/x64primop.h"
+
+#define F8 *(uint8_t*)(addr++)
+#define F8S *(int8_t*)(addr++)
+#define F16 *(uint16_t*)(addr+=2, addr-2)
+#define F16S *(int16_t*)(addr+=2, addr-2)
+#define F32 *(uint32_t*)(addr+=4, addr-4)
+#define F32S *(int32_t*)(addr+=4, addr-4)
+#define F32S64 (uint64_t)(int64_t)F32S
+#define F64 *(uint64_t*)(addr+=8, addr-8)
+#define PK(a) *(uint8_t*)(addr+a)
+#define PK16(a) *(uint16_t*)(addr+a)
+#define PK32(a) *(uint32_t*)(addr+a)
+#define PK64(a) *(uint64_t*)(addr+a)
+#define PKip(a) *(uint8_t*)(ip+a)
+
+
+// Strong mem emulation helpers
+// Sequence of Read will trigger a DMB on "first" read if strongmem is 2
+// Squence of Write will trigger a DMB on "last" write if strongmem is 1
+// Opcode will read
+#define SMREAD() if(!dyn->smread && box64_dynarec_strongmem>1) {SMDMB();}
+// Opcode will read with option forced lock
+#define SMREADLOCK(lock) if(lock || (!dyn->smread && box64_dynarec_strongmem>1)) {SMDMB();}
+// Opcode migh read (depend on nextop)
+#define SMMIGHTREAD() if(!MODREG) {SMREAD();}
+// Opcode has wrote
+#define SMWRITE() dyn->smwrite=1
+// Opcode has wrote (strongmem>1 only)
+#define SMWRITE2() if(box64_dynarec_strongmem>1) dyn->smwrite=1
+// Opcode has wrote with option forced lock
+#define SMWRITELOCK(lock) if(lock) {SMDMB();} else dyn->smwrite=1
+// Opcode migh have wrote (depend on nextop)
+#define SMMIGHTWRITE() if(!MODREG) {SMWRITE();}
+// Start of sequence
+#define SMSTART() SMEND()
+// End of sequence
+#define SMEND() if(dyn->smwrite && box64_dynarec_strongmem) {FENCE();} dyn->smwrite=0; dyn->smread=0;
+// Force a Data memory barrier (for LOCK: prefix)
+#define SMDMB() FENCE(); dyn->smwrite=0; dyn->smread=1
+
+//LOCK_* define
+#define LOCK_LOCK (int*)1
+
+// GETGD get x64 register in gd
+#define GETGD gd = xRAX+((nextop&0x38)>>3)+(rex.r<<3)
+// GETED can use r1 for ed, and r2 for wback. wback is 0 if ed is xEAX..xEDI
+#define GETED(D) if(MODREG) { \
+ ed = xRAX+(nextop&7)+(rex.b<<3); \
+ wback = 0; \
+ } else { \
+ SMREAD() \
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, NULL, 1, D); \
+ LDxw(x1, wback, fixedaddress); \
+ ed = x1; \
+ }
+// GETSED can use r1 for ed, and r2 for wback. ed will be sign extended!
+#define GETSED(D) if(MODREG) { \
+ ed = xRAX+(nextop&7)+(rex.b<<3); \
+ wback = 0; \
+ if(!rex.w) { \
+ ADDW(x1, ed, xZR); \
+ ed = x1; \
+ } \
+ } else { \
+ SMREAD() \
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, NULL, 1, D); \
+ if(rex.w) \
+ LD(x1, wback, fixedaddress); \
+ else \
+ LW(x1, wback, fixedaddress); \
+ ed = x1; \
+ }
+// GETEDx can use r1 for ed, and r2 for wback. wback is 0 if ed is xEAX..xEDI
+#define GETEDx(D) if(MODREG) { \
+ ed = xRAX+(nextop&7)+(rex.b<<3); \
+ wback = 0; \
+ } else { \
+ SMREAD() \
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, NULL, 1, D); \
+ LD(x1, wback, fixedaddress); \
+ ed = x1; \
+ }
+#define GETEDz(D) if(MODREG) { \
+ ed = xRAX+(nextop&7)+(rex.b<<3); \
+ wback = 0; \
+ } else { \
+ SMREAD() \
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, NULL, 1, D); \
+ LDz(x1, wback, fixedaddress); \
+ ed = x1; \
+ }
+// GETED32 can use r1 for ed, and r2 for wback. wback is 0 if ed is xEAX..xEDI
+#define GETED32(D) if(MODREG) { \
+ ed = xRAX+(nextop&7)+(rex.b<<3); \
+ wback = 0; \
+ } else { \
+ SMREAD() \
+ addr = geted32(dyn, addr, ninst, nextop, &wback, x2, x1, &fixedaddress, rex, NULL, 1, D); \
+ LDxw(x1, wback, fixedaddress); \
+ ed = x1; \
+ }
+//GETEDH can use hint for ed, and x1 or x2 for wback (depending on hint), might also use x3. wback is 0 if ed is xEAX..xEDI
+#define GETEDH(hint, D) if(MODREG) { \
+ ed = xRAX+(nextop&7)+(rex.b<<3); \
+ wback = 0; \
+ } else { \
+ SMREAD(); \
+ addr = geted(dyn, addr, ninst, nextop, &wback, (hint==x2)?x1:x2, (hint==x1)?x1:x3, &fixedaddress, rex, NULL, 1, D); \
+ LDxw(hint, wback, fixedaddress); \
+ ed = hint; \
+ }
+//GETEDW can use hint for wback and ret for ed. wback is 0 if ed is xEAX..xEDI
+#define GETEDW(hint, ret, D) if(MODREG) { \
+ ed = xRAX+(nextop&7)+(rex.b<<3); \
+ MV(ret, ed); \
+ wback = 0; \
+ } else { \
+ SMREAD(); \
+ addr = geted(dyn, addr, ninst, nextop, &wback, (hint==x2)?x1:x2, (hint==x1)?x1:x3, &fixedaddress, rex, NULL, 0, D); \
+ ed = ret; \
+ LDxw(ed, wback, fixedaddress); \
+ }
+// GETGW extract x64 register in gd, that is i
+#define GETGW(i) gd = xRAX+((nextop&0x38)>>3)+(rex.r<<3); ZEXTH(i, gd); gd = i;
+//GETEWW will use i for ed, and can use w for wback.
+#define GETEWW(w, i, D) if(MODREG) { \
+ wback = xRAX+(nextop&7)+(rex.b<<3);\
+ ZEXTH(i, wback); \
+ ed = i; \
+ wb1 = 0; \
+ } else { \
+ SMREAD(); \
+ addr = geted(dyn, addr, ninst, nextop, &wback, w, i, &fixedaddress, rex, NULL, 1, D); \
+ LHU(i, wback, fixedaddress);\
+ ed = i; \
+ wb1 = 1; \
+ }
+//GETEW will use i for ed, and can use r3 for wback.
+#define GETEW(i, D) GETEWW(x3, i, D)
+//GETSEW will use i for ed, and can use r3 for wback. This is the Signed version
+#define GETSEW(i, D) if(MODREG) { \
+ wback = xRAX+(nextop&7)+(rex.b<<3);\
+ if(rv64_zbb) SEXTH(i, wback); else {SLLI(i, wback, 48); SRAI(i, i, 48);}\
+ ed = i; \
+ wb1 = 0; \
+ } else { \
+ SMREAD(); \
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, i, &fixedaddress, rex, NULL, 1, D); \
+ LH(i, wback, fixedaddress); \
+ ed = i; \
+ wb1 = 1; \
+ }
+// Write ed back to original register / memory
+#define EWBACK EWBACKW(ed)
+// Write w back to original register / memory (w needs to be 16bits only!)
+#define EWBACKW(w) if(wb1) {SH(w, wback, fixedaddress); SMWRITE();} else {SRLI(wback, wback, 16); SLLI(wback, wback, 16); OR(wback, wback, w);}
+// Write back gd in correct register (gd needs to be 16bits only!)
+#define GWBACK do{int g=xRAX+((nextop&0x38)>>3)+(rex.r<<3); SRLI(g, g, 16); SLLI(g, g, 16); OR(g, g, gd);}while(0)
+
+//GETEDO can use r1 for ed, and r2 for wback. wback is 0 if ed is xEAX..xEDI
+#define GETEDO(O, D, S) if(MODREG) { \
+ ed = xRAX+(nextop&7)+(rex.b<<3); \
+ wback = 0; \
+ } else { \
+ SMREAD(); \
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, S, &fixedaddress, rex, NULL, 1, D); \
+ ADD(S, wback, O); \
+ LDxw(x1, S, fixedaddress); \
+ ed = x1; \
+ }
+#define WBACKO(O) if(wback) {ADD(O, wback, O); SDxw(ed, O, 0); SMWRITE2();}
+
+// FAKEED like GETED, but doesn't get anything
+#define FAKEED if(!MODREG) { \
+ addr = fakeed(dyn, addr, ninst, nextop); \
+ }
+
+// GETGW extract x64 register in gd, that is i, Signed extented
+#define GETSGW(i) gd = xRAX+((nextop&0x38)>>3)+(rex.r<<3); SLLIW(i, gd, 16); SRAIW(i, i, 16); gd = i;
+
+// Write back ed in wback (if wback not 0)
+#define WBACK if(wback) {SDxw(ed, wback, fixedaddress); SMWRITE();}
+
+// GETEB will use i for ed, and can use r3 for wback.
+#define GETEB(i, D) if(MODREG) { \
+ if(rex.rex) { \
+ wback = xRAX+(nextop&7)+(rex.b<<3); \
+ wb2 = 0; \
+ } else { \
+ wback = (nextop&7); \
+ wb2 = (wback>>2)*8; \
+ wback = xRAX+(wback&3); \
+ } \
+ if (wb2) {MV(i, wback); SRLI(i, i, wb2); ANDI(i, i, 0xff);} else {ANDI(i, wback, 0xff);} \
+ wb1 = 0; \
+ ed = i; \
+ } else { \
+ SMREAD(); \
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, x2, &fixedaddress, rex, NULL, 1, D); \
+ LBU(i, wback, fixedaddress);\
+ wb1 = 1; \
+ ed = i; \
+ }
+//GETEBO will use i for ed, i is also Offset, and can use r3 for wback.
+#define GETEBO(i, D) if(MODREG) { \
+ if(rex.rex) { \
+ wback = xRAX+(nextop&7)+(rex.b<<3); \
+ wb2 = 0; \
+ } else { \
+ wback = (nextop&7); \
+ wb2 = (wback>>2)*8; \
+ wback = xRAX+(wback&3); \
+ } \
+ if (wb2) {MV(i, wback); SRLI(i, i, wb2); ANDI(i, i, 0xff);} else {ANDI(i, wback, 0xff);} \
+ wb1 = 0; \
+ ed = i; \
+ } else { \
+ SMREAD(); \
+ addr = geted(dyn, addr, ninst, nextop, &wback, x3, x2, &fixedaddress, rex, NULL, 1, D); \
+ ADD(x3, wback, i); \
+ if(wback!=x3) wback = x3; \
+ LBU(i, wback, fixedaddress);\
+ wb1 = 1; \
+ ed = i; \
+ }
+//GETSEB sign extend EB, will use i for ed, and can use r3 for wback.
+#define GETSEB(i, D) if(MODREG) { \
+ if(rex.rex) { \
+ wback = xRAX+(nextop&7)+(rex.b<<3); \
+ wb2 = 0; \
+ } else { \
+ wback = (nextop&7); \
+ wb2 = (wback>>2)*8; \
+ wback = xRAX+(wback&3); \
+ } \
+ MV(i, wback); \
+ SLLIW(i, i, 24-wb2); \
+ SRAIW(i, i, 24); \
+ wb1 = 0; \
+ ed = i; \
+ } else { \
+ SMREAD(); \
+ addr = geted(dyn, addr, ninst, nextop, &wback, x2, x3, &fixedaddress, rex, NULL, 1, D); \
+ LB(i, wback, fixedaddress); \
+ wb1 = 1; \
+ ed = i; \
+ }
+// GETEB32 will use i for ed, and can use r3 for wback.
+#define GETEB32(i, D) if(MODREG) { \
+ if(rex.rex) { \
+ wback = xRAX+(nextop&7)+(rex.b<<3); \
+ wb2 = 0; \
+ } else { \
+ wback = (nextop&7); \
+ wb2 = (wback>>2)*8; \
+ wback = xRAX+(wback&3); \
+ } \
+ if (wb2) {MV(i, wback); SRLI(i, i, wb2); ANDI(i, i, 0xff);} else {ANDI(i, wback, 0xff);} \
+ wb1 = 0; \
+ ed = i; \
+ } else { \
+ SMREAD(); \
+ addr = geted32(dyn, addr, ninst, nextop, &wback, x3, x2, &fixedaddress, rex, NULL, 1, D); \
+ LBU(i, wback, fixedaddress);\
+ wb1 = 1; \
+ ed = i; \
+ }
+
+//GETGB will use i for gd
+#define GETGB(i) if(rex.rex) { \
+ gb1 = xRAX+((nextop&0x38)>>3)+(rex.r<<3); \
+ gb2 = 0; \
+ } else { \
+ gd = (nextop&0x38)>>3; \
+ gb2 = ((gd&4)>>2); \
+ gb1 = xRAX+(gd&3); \
+ } \
+ gd = i; \
+ if (gb2) {MV(gd, gb1); SRLI(gd, gd, 8); ANDI(gd, gd, 0xff);} else {ANDI(gd, gb1, 0xff);}
+
+// Write gb (gd) back to original register / memory, using s1 as scratch
+#define GBBACK(s1) if(gb2) { \
+ MOV64x(s1, 0xffffffffffff00ffLL); \
+ AND(gb1, gb1, s1); \
+ SLLI(s1, gd, 8); \
+ OR(gb1, gb1, s1); \
+ } else { \
+ ANDI(gb1, gb1, ~0xff); \
+ OR(gb1, gb1, gd); \
+ }
+
+// Write eb (ed) back to original register / memory, using s1 as scratch
+#define EBBACK(s1, c) if(wb1) { \
+ SB(ed, wback, fixedaddress); \
+ SMWRITE(); \
+ } else if(wb2) { \
+ MOV64x(s1, 0xffffffffffff00ffLL); \
+ AND(wback, wback, s1); \
+ if (c) {ANDI(ed, ed, 0xff);} \
+ SLLI(s1, ed, 8); \
+ OR(wback, wback, s1); \
+ } else { \
+ ANDI(wback, wback, ~0xff); \
+ if (c) {ANDI(ed, ed, 0xff);} \
+ OR(wback, wback, ed); \
+ }
+
+// Get direction with size Z and based of F_DF flag, on register r ready for load/store fetching
+// using s as scratch.
+#define GETDIR(r, s, Z) \
+ MOV32w(r, Z); /* mask=1<<10 */ \
+ ANDI(s, xFlags, 1<<F_DF); \
+ BEQZ(s, 8); \
+ SUB(r, xZR, r); \
+
+// Generic get GD, but reg value in gd (R_RAX is not added)
+#define GETG gd = ((nextop&0x38)>>3)+(rex.r<<3)
+
+// Get GX as a Single (might use x2)
+#define GETGXSS(a) \
+ gd = ((nextop&0x38)>>3)+(rex.r<<3); \
+ a = sse_get_reg(dyn, ninst, x2, gd, 1)
+
+// Get GX as a Single (might use x2), no fetching old value
+#define GETGXSS_empty(a) \
+ gd = ((nextop&0x38)>>3)+(rex.r<<3); \
+ a = sse_get_reg_empty(dyn, ninst, x2, gd, 1)
+
+// Get GX as a Double (might use x2)
+#define GETGXSD(a) \
+ gd = ((nextop&0x38)>>3)+(rex.r<<3); \
+ a = sse_get_reg(dyn, ninst, x2, gd, 0)
+
+// Get GX as a Double (might use x2), no fetching old value
+#define GETGXSD_empty(a) \
+ gd = ((nextop&0x38)>>3)+(rex.r<<3); \
+ a = sse_get_reg_empty(dyn, ninst, x2, gd, 0)
+
+// Get Ex as a single, not a quad (warning, x1 get used, x2 might too)
+#define GETEXSS(a, D) \
+ if(MODREG) { \
+ a = sse_get_reg(dyn, ninst, x1, (nextop&7)+(rex.b<<3), 1); \
+ } else { \
+ SMREAD(); \
+ a = fpu_get_scratch(dyn); \
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, x2, &fixedaddress, rex, NULL, 1, D); \
+ FLW(a, ed, fixedaddress); \
+ }
+
+// Get Ex as a double, not a quad (warning, x1 get used, x2 might too)
+#define GETEXSD(a, D) \
+ if(MODREG) { \
+ a = sse_get_reg(dyn, ninst, x1, (nextop&7)+(rex.b<<3), 0); \
+ } else { \
+ SMREAD(); \
+ a = fpu_get_scratch(dyn); \
+ addr = geted(dyn, addr, ninst, nextop, &ed, x1, x2, &fixedaddress, rex, NULL, 1, D); \
+ FLD(a, ed, fixedaddress); \
+ }
+
+// Will get pointer to GX in general register a, will purge SS or SD if loaded. can use gback as load address
+#define GETGX() \
+ gd = ((nextop&0x38)>>3)+(rex.r<<3); \
+ sse_forget_reg(dyn, ninst, gd); \
+ gback = xEmu; \
+ gdoffset = offsetof(x64emu_t, xmm[gd])
+
+// Get Ex address in general register a, will purge SS or SD if it's reg and is loaded. May use x3. Use wback as load address!
+#define GETEX(a, D) \
+ if(MODREG) { \
+ ed = (nextop&7)+(rex.b<<3); \
+ sse_forget_reg(dyn, ninst, ed); \
+ fixedaddress = offsetof(x64emu_t, xmm[ed]); \
+ wback = xEmu; \
+ } else { \
+ SMREAD(); \
+ ed=16; \
+ addr = geted(dyn, addr, ninst, nextop, &wback, a, x3, &fixedaddress, rex, NULL, 1, D); \
+ }
+
+#define GETGM() \
+ gd = ((nextop&0x38)>>3); \
+ mmx_forget_reg(dyn, ninst, gd); \
+ gback = xEmu; \
+ gdoffset = offsetof(x64emu_t, mmx[gd])
+
+// Get EM, might use x3
+#define GETEM(a, D) \
+ if(MODREG) { \
+ ed = (nextop&7); \
+ mmx_forget_reg(dyn, ninst, ed); \
+ fixedaddress = offsetof(x64emu_t, mmx[ed]); \
+ wback = xEmu; \
+ } else { \
+ SMREAD(); \
+ ed=8; \
+ addr = geted(dyn, addr, ninst, nextop, &wback, a, x3, &fixedaddress, rex, NULL, 1, D); \
+ }
+
+#define SSE_LOOP_D_ITEM(GX1, EX1, F, i) \
+ LWU(GX1, gback, gdoffset+i*4); \
+ LWU(EX1, wback, fixedaddress+i*4); \
+ F; \
+ SW(GX1, gback, gdoffset+i*4);
+
+// Loop for SSE opcode that use 32bits value and write to GX.
+#define SSE_LOOP_D(GX1, EX1, F) \
+ SSE_LOOP_D_ITEM(GX1, EX1, F, 0) \
+ SSE_LOOP_D_ITEM(GX1, EX1, F, 1) \
+ SSE_LOOP_D_ITEM(GX1, EX1, F, 2) \
+ SSE_LOOP_D_ITEM(GX1, EX1, F, 3)
+
+#define SSE_LOOP_DS_ITEM(GX1, EX1, F, i) \
+ LW(GX1, gback, gdoffset+i*4); \
+ LW(EX1, wback, fixedaddress+i*4); \
+ F; \
+ SW(GX1, gback, gdoffset+i*4);
+
+// Loop for SSE opcode that use 32bits value and write to GX.
+#define SSE_LOOP_DS(GX1, EX1, F) \
+ SSE_LOOP_DS_ITEM(GX1, EX1, F, 0) \
+ SSE_LOOP_DS_ITEM(GX1, EX1, F, 1) \
+ SSE_LOOP_DS_ITEM(GX1, EX1, F, 2) \
+ SSE_LOOP_DS_ITEM(GX1, EX1, F, 3)
+
+#define MMX_LOOP_W(GX1, EX1, F) \
+ for (int i=0; i<4; ++i) { \
+ LHU(GX1, gback, gdoffset+i*2); \
+ LHU(EX1, wback, fixedaddress+i*2); \
+ F; \
+ SH(GX1, gback, gdoffset+i*2); \
+ }
+
+#define SSE_LOOP_W(GX1, EX1, F) \
+ for (int i=0; i<8; ++i) { \
+ LHU(GX1, gback, gdoffset+i*2); \
+ LHU(EX1, wback, fixedaddress+i*2); \
+ F; \
+ SH(GX1, gback, gdoffset+i*2); \
+ }
+
+#define SSE_LOOP_WS(GX1, EX1, F) \
+ for (int i=0; i<8; ++i) { \
+ LH(GX1, gback, gdoffset+i*2); \
+ LH(EX1, wback, fixedaddress+i*2); \
+ F; \
+ SH(GX1, gback, gdoffset+i*2); \
+ }
+
+#define SSE_LOOP_D_S_ITEM(EX1, F, i) \
+ LWU(EX1, wback, fixedaddress+i*4); \
+ F; \
+ SW(EX1, wback, fixedaddress+i*4);
+
+// Loop for SSE opcode that use 32bits value and write to EX.
+#define SSE_LOOP_D_S(EX1, F) \
+ SSE_LOOP_D_S_ITEM(EX1, F, 0) \
+ SSE_LOOP_D_S_ITEM(EX1, F, 1) \
+ SSE_LOOP_D_S_ITEM(EX1, F, 2) \
+ SSE_LOOP_D_S_ITEM(EX1, F, 3)
+
+#define SSE_LOOP_Q_ITEM(GX1, EX1, F, i) \
+ LD(GX1, gback, gdoffset+i*8); \
+ LD(EX1, wback, fixedaddress+i*8); \
+ F; \
+ SD(GX1, gback, gdoffset+i*8);
+
+// Loop for SSE opcode that use 64bits value and write to GX.
+#define SSE_LOOP_Q(GX1, EX1, F) \
+ SSE_LOOP_Q_ITEM(GX1, EX1, F, 0) \
+ SSE_LOOP_Q_ITEM(GX1, EX1, F, 1)
+
+
+#define SSE_LOOP_FQ_ITEM(GX1, EX1, F, i) \
+ FLD(v0, gback, gdoffset+i*8); \
+ FLD(v1, wback, fixedaddress+i*8); \
+ F; \
+ FSD(v0, gback, gdoffset+i*8);
+
+#define SSE_LOOP_FQ(GX1, EX1, F) \
+ v0 = fpu_get_scratch(dyn); \
+ v1 = fpu_get_scratch(dyn); \
+ SSE_LOOP_FQ_ITEM(GX1, EX1, F, 0) \
+ SSE_LOOP_FQ_ITEM(GX1, EX1, F, 1)
+
+
+#define SSE_LOOP_MV_Q_ITEM(s, i) \
+ LD(s, wback, fixedaddress+i*8); \
+ SD(s, gback, gdoffset+i*8);
+
+// Loop for SSE opcode that moves 64bits value from wback to gback, use s as scratch.
+#define SSE_LOOP_MV_Q(s) \
+ SSE_LOOP_MV_Q_ITEM(s, 0) \
+ SSE_LOOP_MV_Q_ITEM(s, 1)
+
+#define SSE_LOOP_MV_Q_ITEM2(s, i) \
+ LD(s, gback, gdoffset+i*8); \
+ SD(s, wback, fixedaddress+i*8);
+
+// Loop for SSE opcode that moves 64bits value from gback to wback, use s as scratch.
+#define SSE_LOOP_MV_Q2(s) \
+ SSE_LOOP_MV_Q_ITEM2(s, 0) \
+ SSE_LOOP_MV_Q_ITEM2(s, 1)
+
+// CALL will use x6 for the call address. Return value can be put in ret (unless ret is -1)
+// R0 will not be pushed/popd if ret is -2
+#define CALL(F, ret) call_c(dyn, ninst, F, x6, ret, 1, 0)
+// CALL_ will use x6 for the call address. Return value can be put in ret (unless ret is -1)
+// R0 will not be pushed/popd if ret is -2
+#define CALL_(F, ret, reg) call_c(dyn, ninst, F, x6, ret, 1, reg)
+// CALL_S will use x6 for the call address. Return value can be put in ret (unless ret is -1)
+// R0 will not be pushed/popd if ret is -2. Flags are not save/restored
+#define CALL_S(F, ret) call_c(dyn, ninst, F, x6, ret, 0, 0)
+
+#define MARK dyn->insts[ninst].mark = dyn->native_size
+#define GETMARK dyn->insts[ninst].mark
+#define MARK2 dyn->insts[ninst].mark2 = dyn->native_size
+#define GETMARK2 dyn->insts[ninst].mark2
+#define MARK3 dyn->insts[ninst].mark3 = dyn->native_size
+#define GETMARK3 dyn->insts[ninst].mark3
+#define MARKF dyn->insts[ninst].markf = dyn->native_size
+#define GETMARKF dyn->insts[ninst].markf
+#define MARKF2 dyn->insts[ninst].markf2 = dyn->native_size
+#define GETMARKF2 dyn->insts[ninst].markf2
+#define MARKSEG dyn->insts[ninst].markseg = dyn->native_size
+#define GETMARKSEG dyn->insts[ninst].markseg
+#define MARKLOCK dyn->insts[ninst].marklock = dyn->native_size
+#define GETMARKLOCK dyn->insts[ninst].marklock
+
+#define Bxx_gen(OP, M, reg1, reg2) \
+ j64 = GET##M - dyn->native_size; \
+ B##OP (reg1, reg2, j64)
+
+// Branch to MARK if reg1==reg2 (use j64)
+#define BEQ_MARK(reg1, reg2) Bxx_gen(EQ, MARK, reg1, reg2)
+// Branch to MARK if reg1!=reg2 (use j64)
+#define BNE_MARK(reg1, reg2) Bxx_gen(NE, MARK, reg1, reg2)
+// Branch to MARK if reg1!=0 (use j64)
+#define BNEZ_MARK(reg) BNE_MARK(reg, xZR)
+// Branch to MARK instruction unconditionnal (use j64)
+#define B_MARK_nocond Bxx_gen(__, MARK, 0, 0)
+// Branch to MARK if reg1<reg2 (use j64)
+#define BLT_MARK(reg1, reg2) Bxx_gen(LT, MARK, reg1, reg2)
+// Branch to MARK if reg1<reg2 (use j64)
+#define BLTU_MARK(reg1, reg2) Bxx_gen(LTU, MARK, reg1, reg2)
+// Branch to MARK if reg1>=reg2 (use j64)
+#define BGE_MARK(reg1, reg2) Bxx_gen(GE, MARK, reg1, reg2)
+// Branch to MARK2 if reg1==reg2 (use j64)
+#define BEQ_MARK2(reg1, reg2) Bxx_gen(EQ, MARK2, reg1,reg2)
+// Branch to MARK2 if reg1!=reg2 (use j64)
+#define BNE_MARK2(reg1, reg2) Bxx_gen(NE, MARK2, reg1,reg2)
+// Branch to MARK2 if reg1!=0 (use j64)
+#define BNEZ_MARK2(reg) BNE_MARK2(reg, xZR)
+// Branch to MARK2 if reg1<reg2 (use j64)
+#define BLT_MARK2(reg1, reg2) Bxx_gen(LT, MARK2, reg1,reg2)
+// Branch to MARK2 instruction unconditionnal (use j64)
+#define B_MARK2_nocond Bxx_gen(__, MARK2, 0, 0)
+// Branch to MARK3 if reg1==reg2 (use j64)
+#define BEQ_MARK3(reg1, reg2) Bxx_gen(EQ, MARK3, reg1, reg2)
+// Branch to MARK3 if reg1!=reg2 (use j64)
+#define BNE_MARK3(reg1, reg2) Bxx_gen(NE, MARK3, reg1, reg2)
+// Branch to MARK3 if reg1!=0 (use j64)
+#define BNEZ_MARK3(reg) BNE_MARK3(reg, xZR)
+// Branch to MARK3 instruction unconditionnal (use j64)
+#define B_MARK3_nocond Bxx_gen(__, MARK3, 0, 0)
+// Branch to MARKLOCK if reg1!=reg2 (use j64)
+#define BNE_MARKLOCK(reg1, reg2) Bxx_gen(NE, MARKLOCK, reg1, reg2)
+// Branch to MARKLOCK if reg1!=0 (use j64)
+#define BNEZ_MARKLOCK(reg) BNE_MARKLOCK(reg, xZR)
+
+// Branch to NEXT if reg1==reg2 (use j64)
+#define BEQ_NEXT(reg1, reg2) \
+ j64 = (dyn->insts)?(dyn->insts[ninst].epilog-(dyn->native_size)):0; \
+ BEQ(reg1, reg2, j64)
+
+// Branch to NEXT if reg1==0 (use j64)
+#define CBZ_NEXT(reg1) \
+ j64 = (dyn->insts)?(dyn->insts[ninst].epilog-(dyn->native_size)):0; \
+ BEQ(reg1, xZR, j64)
+// Branch to NEXT if reg1!=0 (use j64)
+#define CBNZ_NEXT(reg1) \
+ j64 = (dyn->insts)?(dyn->insts[ninst].epilog-(dyn->native_size)):0; \
+ BNE(reg1, xZR, j64)
+// Branch to next instruction unconditionnal (use j64)
+#define B_NEXT_nocond \
+ j64 = (dyn->insts)?(dyn->insts[ninst].epilog-(dyn->native_size)):0;\
+ B(j64)
+
+// Branch to MARKSEG if reg is 0 (use j64)
+#define CBZ_MARKSEG(reg) \
+ j64 = GETMARKSEG-(dyn->native_size); \
+ BEQZ(reg, j64);
+// Branch to MARKSEG if reg is not 0 (use j64)
+#define CBNZ_MARKSEG(reg) \
+ j64 = GETMARKSEG-(dyn->native_size); \
+ BNEZ(reg, j64);
+
+#define IFX(A) if((dyn->insts[ninst].x64.gen_flags&(A)))
+#define IFX_PENDOR0 if((dyn->insts[ninst].x64.gen_flags&(X_PEND) || !dyn->insts[ninst].x64.gen_flags))
+#define IFXX(A) if((dyn->insts[ninst].x64.gen_flags==(A)))
+#define IFX2X(A, B) if((dyn->insts[ninst].x64.gen_flags==(A) || dyn->insts[ninst].x64.gen_flags==(B) || dyn->insts[ninst].x64.gen_flags==((A)|(B))))
+#define IFXN(A, B) if((dyn->insts[ninst].x64.gen_flags&(A) && !(dyn->insts[ninst].x64.gen_flags&(B))))
+
+#define STORE_REG(A) SD(x##A, xEmu, offsetof(x64emu_t, regs[_##A]))
+#define LOAD_REG(A) LD(x##A, xEmu, offsetof(x64emu_t, regs[_##A]))
+
+// Need to also store current value of some register, as they may be used by functions like setjmp
+#define STORE_XEMU_CALL() \
+ STORE_REG(RBX); \
+ STORE_REG(RDX); \
+ STORE_REG(RSP); \
+ STORE_REG(RBP); \
+ STORE_REG(RDI); \
+ STORE_REG(RSI); \
+ STORE_REG(R8); \
+ STORE_REG(R9); \
+ STORE_REG(R10); \
+ STORE_REG(R11); \
+
+#define LOAD_XEMU_CALL() \
+
+#define LOAD_XEMU_REM() \
+ LOAD_REG(RBX); \
+ LOAD_REG(RDX); \
+ LOAD_REG(RSP); \
+ LOAD_REG(RBP); \
+ LOAD_REG(RDI); \
+ LOAD_REG(RSI); \
+ LOAD_REG(R8); \
+ LOAD_REG(R9); \
+ LOAD_REG(R10); \
+ LOAD_REG(R11); \
+
+
+#define SET_DFNONE() if(!dyn->f.dfnone) {SW(xZR, xEmu, offsetof(x64emu_t, df)); dyn->f.dfnone=1;}
+#define SET_DF(S, N) if((N)!=d_none) {MOV_U12(S, (N)); SW(S, xEmu, offsetof(x64emu_t, df)); dyn->f.dfnone=0;} else SET_DFNONE()
+#define SET_NODF() dyn->f.dfnone = 0
+#define SET_DFOK() dyn->f.dfnone = 1
+
+#define CLEAR_FLAGS() IFX(X_ALL) {ANDI(xFlags, xFlags, ~((1UL<<F_AF) | (1UL<<F_CF) | (1UL<<F_OF2) | (1UL<<F_ZF) | (1UL<<F_SF) | (1UL<<F_PF)));}
+
+#define CALC_SUB_FLAGS(op1_, op2, res, scratch1, scratch2, width) \
+ IFX(X_AF | X_CF | X_OF) { \
+ /* calc borrow chain */ \
+ /* bc = (res & (~op1 | op2)) | (~op1 & op2) */ \
+ OR(scratch1, op1_, op2); \
+ AND(scratch2, res, scratch1); \
+ AND(op1_, op1_, op2); \
+ OR(scratch2, scratch2, op1_); \
+ IFX(X_AF) { \
+ /* af = bc & 0x8 */ \
+ ANDI(scratch1, scratch2, 8); \
+ BEQZ(scratch1, 8); \
+ ORI(xFlags, xFlags, 1 << F_AF); \
+ } \
+ IFX(X_CF) { \
+ /* cf = bc & (1<<(width-1)) */ \
+ if ((width) == 8) { \
+ ANDI(scratch1, scratch2, 0x80); \
+ } else { \
+ SRLI(scratch1, scratch2, (width)-1); \
+ if(width!=64) ANDI(scratch1, scratch1, 1); \
+ } \
+ BEQZ(scratch1, 8); \
+ ORI(xFlags, xFlags, 1 << F_CF); \
+ } \
+ IFX(X_OF) { \
+ /* of = ((bc >> (width-2)) ^ (bc >> (width-1))) & 0x1; */ \
+ SRLI(scratch1, scratch2, (width)-2); \
+ SRLI(scratch2, scratch1, 1); \
+ XOR(scratch1, scratch1, scratch2); \
+ ANDI(scratch1, scratch1, 1); \
+ BEQZ(scratch1, 8); \
+ ORI(xFlags, xFlags, 1 << F_OF2); \
+ } \
+ }
+
+// Adjust the xFlags bit 11 -> bit 5, result in reg (can be xFlags, but not s1)
+#define FLAGS_ADJUST_FROM11(reg, s1)\
+ ANDI(reg, xFlags, ~(1<<5)); \
+ SRLI(s1, reg, 11-5); \
+ ANDI(s1, s1, 1<<5); \
+ OR(reg, reg, s1)
+
+// Adjust the xFlags bit 5 -> bit 11, src and dst can be the same (and can be xFlags, but not s1)
+#define FLAGS_ADJUST_TO11(dst, src, s1) \
+ LUI(s1, 0xFFFFF); \
+ ADDIW(s1, s1, 0x7DF); \
+ AND(s1, src, s1); \
+ ANDI(dst, src, 1<<5); \
+ SLLI(dst, dst, 11-5); \
+ OR(dst, dst, s1)
+
+#ifndef MAYSETFLAGS
+#define MAYSETFLAGS()
+#endif
+
+#ifndef READFLAGS
+#define READFLAGS(A) \
+ if(((A)!=X_PEND && dyn->f.pending!=SF_SET) \
+ && (dyn->f.pending!=SF_SET_PENDING)) { \
+ if(dyn->f.pending!=SF_PENDING) { \
+ LD(x3, xEmu, offsetof(x64emu_t, df)); \
+ j64 = (GETMARKF)-(dyn->native_size); \
+ BEQ(x3, xZR, j64); \
+ } \
+ CALL_(UpdateFlags, -1, 0); \
+ FLAGS_ADJUST_FROM11(xFlags, x3); \
+ MARKF; \
+ dyn->f.pending = SF_SET; \
+ SET_DFOK(); \
+ }
+#endif
+
+#ifndef SETFLAGS
+#define SETFLAGS(A, B) \
+ if(dyn->f.pending!=SF_SET \
+ && ((B)&SF_SUB) \
+ && (dyn->insts[ninst].x64.gen_flags&(~(A)))) \
+ READFLAGS(((dyn->insts[ninst].x64.gen_flags&X_PEND)?X_ALL:dyn->insts[ninst].x64.gen_flags)&(~(A)));\
+ if(dyn->insts[ninst].x64.gen_flags) switch(B) { \
+ case SF_SUBSET: \
+ case SF_SET: dyn->f.pending = SF_SET; break; \
+ case SF_PENDING: dyn->f.pending = SF_PENDING; break; \
+ case SF_SUBSET_PENDING: \
+ case SF_SET_PENDING: \
+ dyn->f.pending = (dyn->insts[ninst].x64.gen_flags&X_PEND)?SF_SET_PENDING:SF_SET; \
+ break; \
+ } else dyn->f.pending = SF_SET
+#endif
+#ifndef JUMP
+#define JUMP(A, C)
+#endif
+#ifndef BARRIER
+#define BARRIER(A)
+#endif
+#ifndef BARRIER_NEXT
+#define BARRIER_NEXT(A)
+#endif
+#define UFLAG_OP1(A) if(dyn->insts[ninst].x64.gen_flags) {SDxw(A, xEmu, offsetof(x64emu_t, op1));}
+#define UFLAG_OP2(A) if(dyn->insts[ninst].x64.gen_flags) {SDxw(A, xEmu, offsetof(x64emu_t, op2));}
+#define UFLAG_OP12(A1, A2) if(dyn->insts[ninst].x64.gen_flags) {SDxw(A1, xEmu, offsetof(x64emu_t, op1));SDxw(A2, xEmu, offsetof(x64emu_t, op2));}
+#define UFLAG_RES(A) if(dyn->insts[ninst].x64.gen_flags) {SDxw(A, xEmu, offsetof(x64emu_t, res));}
+#define UFLAG_DF(r, A) if(dyn->insts[ninst].x64.gen_flags) {SET_DF(r, A)}
+#define UFLAG_IF if(dyn->insts[ninst].x64.gen_flags)
+#ifndef DEFAULT
+#define DEFAULT *ok = -1; BARRIER(2)
+#endif
+
+#ifndef TABLE64
+#define TABLE64(A, V)
+#endif
+#ifndef FTABLE64
+#define FTABLE64(A, V)
+#endif
+
+#define ARCH_INIT()
+
+
+#if STEP < 2
+#define GETIP(A)
+#define GETIP_(A)
+#else
+// put value in the Table64 even if not using it for now to avoid difference between Step2 and Step3. Needs to be optimized later...
+#define GETIP(A) \
+ if(dyn->last_ip && ((A)-dyn->last_ip)<2048) { \
+ uint64_t _delta_ip = (A)-dyn->last_ip; \
+ dyn->last_ip += _delta_ip; \
+ if(_delta_ip) { \
+ ADDI(xRIP, xRIP, _delta_ip); \
+ } \
+ } else { \
+ dyn->last_ip = (A); \
+ if(dyn->last_ip<0xffffffff) { \
+ MOV64x(xRIP, dyn->last_ip); \
+ } else \
+ TABLE64(xRIP, dyn->last_ip); \
+ }
+#define GETIP_(A) \
+ if(dyn->last_ip && ((A)-dyn->last_ip)<2048) { \
+ int64_t _delta_ip = (A)-dyn->last_ip; \
+ if(_delta_ip) {ADDI(xRIP, xRIP, _delta_ip);} \
+ } else { \
+ if((A)<0xffffffff) { \
+ MOV64x(xRIP, (A)); \
+ } else \
+ TABLE64(xRIP, (A)); \
+ }
+#endif
+#define CLEARIP() dyn->last_ip=0
+
+#if STEP < 2
+#define PASS2IF(A, B) if(A)
+#elif STEP == 2
+#define PASS2IF(A, B) if(A) dyn->insts[ninst].pass2choice = B; if(dyn->insts[ninst].pass2choice == B)
+#else
+#define PASS2IF(A, B) if(dyn->insts[ninst].pass2choice == B)
+#endif
+
+#define MODREG ((nextop&0xC0)==0xC0)
+
+void rv64_epilog(void);
+void rv64_epilog_fast(void);
+void* rv64_next(x64emu_t* emu, uintptr_t addr);
+
+#ifndef STEPNAME
+#define STEPNAME3(N,M) N##M
+#define STEPNAME2(N,M) STEPNAME3(N,M)
+#define STEPNAME(N) STEPNAME2(N, STEP)
+#endif
+
+#define native_pass STEPNAME(native_pass)
+
+#define dynarec64_00 STEPNAME(dynarec64_00)
+#define dynarec64_00_0 STEPNAME(dynarec64_00_0)
+#define dynarec64_00_1 STEPNAME(dynarec64_00_1)
+#define dynarec64_00_2 STEPNAME(dynarec64_00_2)
+#define dynarec64_00_3 STEPNAME(dynarec64_00_3)
+#define dynarec64_0F STEPNAME(dynarec64_0F)
+#define dynarec64_64 STEPNAME(dynarec64_64)
+#define dynarec64_65 STEPNAME(dynarec64_65)
+#define dynarec64_66 STEPNAME(dynarec64_66)
+#define dynarec64_67 STEPNAME(dynarec64_67)
+#define dynarec64_D8 STEPNAME(dynarec64_D8)
+#define dynarec64_D9 STEPNAME(dynarec64_D9)
+#define dynarec64_DA STEPNAME(dynarec64_DA)
+#define dynarec64_DB STEPNAME(dynarec64_DB)
+#define dynarec64_DC STEPNAME(dynarec64_DC)
+#define dynarec64_DD STEPNAME(dynarec64_DD)
+#define dynarec64_DE STEPNAME(dynarec64_DE)
+#define dynarec64_DF STEPNAME(dynarec64_DF)
+#define dynarec64_F0 STEPNAME(dynarec64_F0)
+#define dynarec64_660F STEPNAME(dynarec64_660F)
+#define dynarec64_6664 STEPNAME(dynarec64_6664)
+#define dynarec64_66F0 STEPNAME(dynarec64_66F0)
+#define dynarec64_F20F STEPNAME(dynarec64_F20F)
+#define dynarec64_F30F STEPNAME(dynarec64_F30F)
+
+#define geted STEPNAME(geted)
+#define geted32 STEPNAME(geted32)
+#define geted16 STEPNAME(geted16)
+#define jump_to_epilog STEPNAME(jump_to_epilog)
+#define jump_to_epilog_fast STEPNAME(jump_to_epilog_fast)
+#define jump_to_next STEPNAME(jump_to_next)
+#define ret_to_epilog STEPNAME(ret_to_epilog)
+#define retn_to_epilog STEPNAME(retn_to_epilog)
+#define iret_to_epilog STEPNAME(iret_to_epilog)
+#define call_c STEPNAME(call_c)
+#define call_n STEPNAME(call_n)
+#define grab_segdata STEPNAME(grab_segdata)
+#define emit_cmp8 STEPNAME(emit_cmp8)
+#define emit_cmp16 STEPNAME(emit_cmp16)
+#define emit_cmp32 STEPNAME(emit_cmp32)
+#define emit_cmp8_0 STEPNAME(emit_cmp8_0)
+#define emit_cmp16_0 STEPNAME(emit_cmp16_0)
+#define emit_cmp32_0 STEPNAME(emit_cmp32_0)
+#define emit_test8 STEPNAME(emit_test8)
+#define emit_test16 STEPNAME(emit_test16)
+#define emit_test32 STEPNAME(emit_test32)
+#define emit_test32c STEPNAME(emit_test32)
+#define emit_add32 STEPNAME(emit_add32)
+#define emit_add32c STEPNAME(emit_add32c)
+#define emit_add8 STEPNAME(emit_add8)
+#define emit_add8c STEPNAME(emit_add8c)
+#define emit_sub32 STEPNAME(emit_sub32)
+#define emit_sub32c STEPNAME(emit_sub32c)
+#define emit_sub8 STEPNAME(emit_sub8)
+#define emit_sub8c STEPNAME(emit_sub8c)
+#define emit_or32 STEPNAME(emit_or32)
+#define emit_or32c STEPNAME(emit_or32c)
+#define emit_xor32 STEPNAME(emit_xor32)
+#define emit_xor32c STEPNAME(emit_xor32c)
+#define emit_and32 STEPNAME(emit_and32)
+#define emit_and32c STEPNAME(emit_and32c)
+#define emit_or8 STEPNAME(emit_or8)
+#define emit_or8c STEPNAME(emit_or8c)
+#define emit_xor8 STEPNAME(emit_xor8)
+#define emit_xor8c STEPNAME(emit_xor8c)
+#define emit_and8 STEPNAME(emit_and8)
+#define emit_and8c STEPNAME(emit_and8c)
+#define emit_add16 STEPNAME(emit_add16)
+#define emit_add16c STEPNAME(emit_add16c)
+#define emit_sub16 STEPNAME(emit_sub16)
+#define emit_sub16c STEPNAME(emit_sub16c)
+#define emit_or16 STEPNAME(emit_or16)
+#define emit_or16c STEPNAME(emit_or16c)
+#define emit_xor16 STEPNAME(emit_xor16)
+#define emit_xor16c STEPNAME(emit_xor16c)
+#define emit_and16 STEPNAME(emit_and16)
+#define emit_and16c STEPNAME(emit_and16c)
+#define emit_inc32 STEPNAME(emit_inc32)
+#define emit_inc16 STEPNAME(emit_inc16)
+#define emit_inc8 STEPNAME(emit_inc8)
+#define emit_dec32 STEPNAME(emit_dec32)
+#define emit_dec16 STEPNAME(emit_dec16)
+#define emit_dec8 STEPNAME(emit_dec8)
+#define emit_adc32 STEPNAME(emit_adc32)
+#define emit_adc32c STEPNAME(emit_adc32c)
+#define emit_adc8 STEPNAME(emit_adc8)
+#define emit_adc8c STEPNAME(emit_adc8c)
+#define emit_adc16 STEPNAME(emit_adc16)
+#define emit_adc16c STEPNAME(emit_adc16c)
+#define emit_sbb32 STEPNAME(emit_sbb32)
+#define emit_sbb32c STEPNAME(emit_sbb32c)
+#define emit_sbb8 STEPNAME(emit_sbb8)
+#define emit_sbb8c STEPNAME(emit_sbb8c)
+#define emit_sbb16 STEPNAME(emit_sbb16)
+#define emit_sbb16c STEPNAME(emit_sbb16c)
+#define emit_neg32 STEPNAME(emit_neg32)
+#define emit_neg16 STEPNAME(emit_neg16)
+#define emit_neg8 STEPNAME(emit_neg8)
+#define emit_shl32 STEPNAME(emit_shl32)
+#define emit_shl32c STEPNAME(emit_shl32c)
+#define emit_shr32 STEPNAME(emit_shr32)
+#define emit_shr32c STEPNAME(emit_shr32c)
+#define emit_sar32c STEPNAME(emit_sar32c)
+#define emit_rol32 STEPNAME(emit_rol32)
+#define emit_ror32 STEPNAME(emit_ror32)
+#define emit_rol32c STEPNAME(emit_rol32c)
+#define emit_ror32c STEPNAME(emit_ror32c)
+#define emit_shrd32c STEPNAME(emit_shrd32c)
+#define emit_shld32c STEPNAME(emit_shld32c)
+
+#define emit_pf STEPNAME(emit_pf)
+
+#define x87_do_push STEPNAME(x87_do_push)
+#define x87_do_push_empty STEPNAME(x87_do_push_empty)
+#define x87_do_pop STEPNAME(x87_do_pop)
+#define x87_get_current_cache STEPNAME(x87_get_current_cache)
+#define x87_get_cache STEPNAME(x87_get_cache)
+#define x87_get_extcache STEPNAME(x87_get_extcache)
+#define x87_get_st STEPNAME(x87_get_st)
+#define x87_get_st_empty STEPNAME(x87_get_st)
+#define x87_refresh STEPNAME(x87_refresh)
+#define x87_forget STEPNAME(x87_forget)
+#define x87_reget_st STEPNAME(x87_reget_st)
+#define x87_stackcount STEPNAME(x87_stackcount)
+#define x87_swapreg STEPNAME(x87_swapreg)
+#define x87_setround STEPNAME(x87_setround)
+#define x87_restoreround STEPNAME(x87_restoreround)
+#define sse_setround STEPNAME(sse_setround)
+#define mmx_get_reg STEPNAME(mmx_get_reg)
+#define mmx_get_reg_empty STEPNAME(mmx_get_reg_empty)
+#define mmx_forget_reg STEPNAME(mmx_forget_reg)
+#define sse_get_reg STEPNAME(sse_get_reg)
+#define sse_get_reg_empty STEPNAME(sse_get_reg_empty)
+#define sse_forget_reg STEPNAME(sse_forget_reg)
+#define sse_purge07cache STEPNAME(sse_purge07cache)
+
+#define fpu_pushcache STEPNAME(fpu_pushcache)
+#define fpu_popcache STEPNAME(fpu_popcache)
+#define fpu_reset STEPNAME(fpu_reset)
+#define fpu_reset_cache STEPNAME(fpu_reset_cache)
+#define fpu_propagate_stack STEPNAME(fpu_propagate_stack)
+#define fpu_purgecache STEPNAME(fpu_purgecache)
+#define mmx_purgecache STEPNAME(mmx_purgecache)
+#define x87_purgecache STEPNAME(x87_purgecache)
+#define sse_purgecache STEPNAME(sse_purgecache)
+#define fpu_reflectcache STEPNAME(fpu_reflectcache)
+#define fpu_unreflectcache STEPNAME(fpu_unreflectcache)
+
+#define CacheTransform STEPNAME(CacheTransform)
+#define rv64_move64 STEPNAME(rv64_move64)
+#define rv64_move32 STEPNAME(rv64_move32)
+
+/* setup r2 to address pointed by */
+uintptr_t geted(dynarec_rv64_t* dyn, uintptr_t addr, int ninst, uint8_t nextop, uint8_t* ed, uint8_t hint, uint8_t scratch, int64_t* fixaddress, rex_t rex, int* l, int i12, int delta);
+
+/* setup r2 to address pointed by */
+uintptr_t geted32(dynarec_rv64_t* dyn, uintptr_t addr, int ninst, uint8_t nextop, uint8_t* ed, uint8_t hint, uint8_t scratch, int64_t* fixaddress, rex_t rex, int* l, int i12, int delta);
+
+/* setup r2 to address pointed by */
+//uintptr_t geted16(dynarec_rv64_t* dyn, uintptr_t addr, int ninst, uint8_t nextop, uint8_t* ed, uint8_t hint, int64_t* fixaddress, int absmax, uint32_t mask, int s);
+
+
+// generic x64 helper
+void jump_to_epilog(dynarec_rv64_t* dyn, uintptr_t ip, int reg, int ninst);
+void jump_to_epilog_fast(dynarec_rv64_t* dyn, uintptr_t ip, int reg, int ninst);
+void jump_to_next(dynarec_rv64_t* dyn, uintptr_t ip, int reg, int ninst);
+void ret_to_epilog(dynarec_rv64_t* dyn, int ninst, rex_t rex);
+void retn_to_epilog(dynarec_rv64_t* dyn, int ninst, rex_t rex, int n);
+void iret_to_epilog(dynarec_rv64_t* dyn, int ninst, int is64bits);
+void call_c(dynarec_rv64_t* dyn, int ninst, void* fnc, int reg, int ret, int saveflags, int save_reg);
+void call_n(dynarec_rv64_t* dyn, int ninst, void* fnc, int w);
+void grab_segdata(dynarec_rv64_t* dyn, uintptr_t addr, int ninst, int reg, int segment);
+void emit_cmp8(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5, int s6);
+void emit_cmp16(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5, int s6);
+void emit_cmp32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4, int s5, int s6);
+void emit_cmp8_0(dynarec_rv64_t* dyn, int ninst, int s1, int s3, int s4);
+void emit_cmp16_0(dynarec_rv64_t* dyn, int ninst, int s1, int s3, int s4);
+void emit_cmp32_0(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s3, int s4);
+void emit_test8(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5);
+void emit_test16(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5);
+void emit_test32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4, int s5);
+void emit_test32c(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int64_t c, int s3, int s4, int s5);
+void emit_add32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4, int s5);
+void emit_add32c(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int64_t c, int s2, int s3, int s4, int s5);
+void emit_add8(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4);
+void emit_add8c(dynarec_rv64_t* dyn, int ninst, int s1, int32_t c, int s2, int s3, int s4);
+void emit_sub32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4, int s5);
+void emit_sub32c(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int64_t c, int s2, int s3, int s4, int s5);
+void emit_sub8(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5);
+void emit_sub8c(dynarec_rv64_t* dyn, int ninst, int s1, int32_t c, int s2, int s3, int s4, int s5);
+void emit_or32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4);
+void emit_or32c(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int64_t c, int s3, int s4);
+void emit_xor32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4);
+void emit_xor32c(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int64_t c, int s3, int s4);
+void emit_and32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4);
+void emit_and32c(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int64_t c, int s3, int s4);
+void emit_or8(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4);
+void emit_or8c(dynarec_rv64_t* dyn, int ninst, int s1, int32_t c, int s2, int s3, int s4);
+void emit_xor8(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4);
+void emit_xor8c(dynarec_rv64_t* dyn, int ninst, int s1, int32_t c, int s3, int s4);
+void emit_and8(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4);
+void emit_and8c(dynarec_rv64_t* dyn, int ninst, int s1, int32_t c, int s3, int s4);
+void emit_add16(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5);
+//void emit_add16c(dynarec_rv64_t* dyn, int ninst, int s1, int32_t c, int s3, int s4);
+void emit_sub16(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5);
+//void emit_sub16c(dynarec_rv64_t* dyn, int ninst, int s1, int32_t c, int s3, int s4);
+void emit_or16(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4);
+//void emit_or16c(dynarec_rv64_t* dyn, int ninst, int s1, int32_t c, int s3, int s4);
+void emit_xor16(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5);
+//void emit_xor16c(dynarec_rv64_t* dyn, int ninst, int s1, int32_t c, int s3, int s4);
+void emit_and16(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4);
+//void emit_and16c(dynarec_rv64_t* dyn, int ninst, int s1, int32_t c, int s3, int s4);
+void emit_inc32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4, int s5);
+void emit_inc16(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4);
+void emit_inc8(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4);
+void emit_dec32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4, int s5);
+void emit_dec16(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5);
+void emit_dec8(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4);
+void emit_adc32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4, int s5, int s6);
+//void emit_adc32c(dynarec_rv64_t* dyn, int ninst, int s1, int32_t c, int s3, int s4);
+void emit_adc8(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5);
+void emit_adc8c(dynarec_rv64_t* dyn, int ninst, int s1, int32_t c, int s3, int s4, int s5, int s6);
+void emit_adc16(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5);
+//void emit_adc16c(dynarec_rv64_t* dyn, int ninst, int s1, int32_t c, int s3, int s4);
+void emit_sbb32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4, int s5);
+//void emit_sbb32c(dynarec_rv64_t* dyn, int ninst, int s1, int32_t c, int s3, int s4);
+void emit_sbb8(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5);
+void emit_sbb8c(dynarec_rv64_t* dyn, int ninst, int s1, int32_t c, int s3, int s4, int s5, int s6);
+void emit_sbb16(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int s4, int s5);
+//void emit_sbb16c(dynarec_rv64_t* dyn, int ninst, int s1, int32_t c, int s3, int s4);
+void emit_neg32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3);
+void emit_neg16(dynarec_rv64_t* dyn, int ninst, int s1, int s3, int s4);
+void emit_neg8(dynarec_rv64_t* dyn, int ninst, int s1, int s3, int s4);
+void emit_shl32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4, int s5);
+void emit_shl32c(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, uint32_t c, int s3, int s4, int s5);
+void emit_shr32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4);
+void emit_shr32c(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, uint32_t c, int s3, int s4);
+void emit_sar32c(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, uint32_t c, int s3, int s4);
+void emit_rol32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4);
+void emit_ror32(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, int s3, int s4);
+void emit_rol32c(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, uint32_t c, int s3, int s4);
+void emit_ror32c(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, uint32_t c, int s3, int s4);
+void emit_shrd32c(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, uint32_t c, int s3, int s4);
+void emit_shld32c(dynarec_rv64_t* dyn, int ninst, rex_t rex, int s1, int s2, uint32_t c, int s3, int s4, int s5);
+
+void emit_pf(dynarec_rv64_t* dyn, int ninst, int s1, int s3, int s4);
+
+// x87 helper
+// cache of the local stack counter, to avoid upadte at every call
+void x87_stackcount(dynarec_rv64_t* dyn, int ninst, int scratch);
+// fpu push. Return the Dd value to be used
+int x87_do_push(dynarec_rv64_t* dyn, int ninst, int s1, int t);
+// fpu push. Do not allocate a cache register. Needs a scratch register to do x87stack synch (or 0 to not do it)
+void x87_do_push_empty(dynarec_rv64_t* dyn, int ninst, int s1);
+// fpu pop. All previous returned Dd should be considered invalid
+void x87_do_pop(dynarec_rv64_t* dyn, int ninst, int s1);
+// get cache index for a x87 reg, return -1 if cache doesn't exist
+int x87_get_current_cache(dynarec_rv64_t* dyn, int ninst, int st, int t);
+// get cache index for a x87 reg, create the entry if needed
+int x87_get_cache(dynarec_rv64_t* dyn, int ninst, int populate, int s1, int s2, int a, int t);
+// get extcache index for a x87 reg
+int x87_get_extcache(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int a);
+// get vfpu register for a x87 reg, create the entry if needed
+int x87_get_st(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int a, int t);
+// get vfpu register for a x87 reg, create the entry if needed. Do not fetch the Stx if not already in cache
+int x87_get_st_empty(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int a, int t);
+// refresh a value from the cache ->emu (nothing done if value is not cached)
+void x87_refresh(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int st);
+// refresh a value from the cache ->emu and then forget the cache (nothing done if value is not cached)
+void x87_forget(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int st);
+// refresh the cache value from emu
+void x87_reget_st(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int st);
+// swap 2 x87 regs
+void x87_swapreg(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int a, int b);
+// Set rounding according to cw flags, return reg to restore flags
+int x87_setround(dynarec_rv64_t* dyn, int ninst, int s1, int s2);
+// Restore round flag
+void x87_restoreround(dynarec_rv64_t* dyn, int ninst, int s1);
+// Set rounding according to mxcsr flags, return reg to restore flags
+int sse_setround(dynarec_rv64_t* dyn, int ninst, int s1, int s2);
+
+void CacheTransform(dynarec_rv64_t* dyn, int ninst, int cacheupd, int s1, int s2, int s3);
+
+void rv64_move64(dynarec_rv64_t* dyn, int ninst, int reg, int64_t val);
+void rv64_move32(dynarec_rv64_t* dyn, int ninst, int reg, int32_t val, int zeroup);
+
+#if STEP < 2
+#define CHECK_CACHE() 0
+#else
+#define CHECK_CACHE() (cacheupd = CacheNeedsTransform(dyn, ninst))
+#endif
+#define extcache_st_coherency STEPNAME(extcache_st_coherency)
+int extcache_st_coherency(dynarec_rv64_t* dyn, int ninst, int a, int b);
+
+#if STEP == 0
+#define ST_IS_F(A) 0
+#define X87_COMBINE(A, B) EXT_CACHE_ST_D
+#define X87_ST0 EXT_CACHE_ST_D
+#define X87_ST(A) EXT_CACHE_ST_D
+#elif STEP == 1
+#define ST_IS_F(A) (extcache_get_current_st(dyn, ninst, A)==EXT_CACHE_ST_F)
+#define X87_COMBINE(A, B) extcache_combine_st(dyn, ninst, A, B)
+#define X87_ST0 extcache_get_current_st(dyn, ninst, 0)
+#define X87_ST(A) extcache_get_current_st(dyn, ninst, A)
+#else
+#define ST_IS_F(A) (extcache_get_st(dyn, ninst, A)==EXT_CACHE_ST_F)
+#if STEP == 3
+#define X87_COMBINE(A, B) extcache_st_coherency(dyn, ninst, A, B)
+#else
+#define X87_COMBINE(A, B) extcache_get_st(dyn, ninst, A)
+#endif
+#define X87_ST0 extcache_get_st(dyn, ninst, 0)
+#define X87_ST(A) extcache_get_st(dyn, ninst, A)
+#endif
+
+//MMX helpers
+// get float register for a MMX reg, create the entry if needed
+int mmx_get_reg(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int a);
+// get float register for a MMX reg, but don't try to synch it if it needed to be created
+int mmx_get_reg_empty(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3, int a);
+// forget float register for a MMX reg, create the entry if needed
+void mmx_forget_reg(dynarec_rv64_t* dyn, int ninst, int a);
+
+//SSE/SSE2 helpers
+// get float register for a SSE reg, create the entry if needed
+int sse_get_reg(dynarec_rv64_t* dyn, int ninst, int s1, int a, int single);
+// get float register for a SSE reg, but don't try to synch it if it needed to be created
+int sse_get_reg_empty(dynarec_rv64_t* dyn, int ninst, int s1, int a, int single);
+// forget float register for a SSE reg, create the entry if needed
+void sse_forget_reg(dynarec_rv64_t* dyn, int ninst, int a);
+// purge the XMM0..XMM7 cache (before function call)
+void sse_purge07cache(dynarec_rv64_t* dyn, int ninst, int s1);
+
+// common coproc helpers
+// reset the cache
+void fpu_reset(dynarec_rv64_t* dyn);
+// reset the cache with n
+void fpu_reset_cache(dynarec_rv64_t* dyn, int ninst, int reset_n);
+// propagate stack state
+void fpu_propagate_stack(dynarec_rv64_t* dyn, int ninst);
+// purge the FPU cache (needs 3 scratch registers)
+void fpu_purgecache(dynarec_rv64_t* dyn, int ninst, int next, int s1, int s2, int s3);
+// purge MMX cache
+void mmx_purgecache(dynarec_rv64_t* dyn, int ninst, int next, int s1);
+// purge x87 cache
+void x87_purgecache(dynarec_rv64_t* dyn, int ninst, int next, int s1, int s2, int s3);
+void fpu_reflectcache(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3);
+void fpu_unreflectcache(dynarec_rv64_t* dyn, int ninst, int s1, int s2, int s3);
+void fpu_pushcache(dynarec_rv64_t* dyn, int ninst, int s1, int not07);
+void fpu_popcache(dynarec_rv64_t* dyn, int ninst, int s1, int not07);
+
+
+uintptr_t dynarec64_00(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog);
+uintptr_t dynarec64_00_0(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog);
+uintptr_t dynarec64_00_1(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog);
+uintptr_t dynarec64_00_2(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog);
+uintptr_t dynarec64_00_3(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog);
+uintptr_t dynarec64_0F(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int* ok, int* need_epilog);
+uintptr_t dynarec64_64(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int seg, int* ok, int* need_epilog);
+//uintptr_t dynarec64_65(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep,int* ok, int* need_epilog);
+uintptr_t dynarec64_66(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog);
+uintptr_t dynarec64_67(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog);
+uintptr_t dynarec64_D8(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog);
+uintptr_t dynarec64_D9(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog);
+//uintptr_t dynarec64_DA(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog);
+uintptr_t dynarec64_DB(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog);
+uintptr_t dynarec64_DC(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog);
+uintptr_t dynarec64_DD(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog);
+uintptr_t dynarec64_DE(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog);
+uintptr_t dynarec64_DF(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog);
+uintptr_t dynarec64_F0(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog);
+uintptr_t dynarec64_660F(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int* ok, int* need_epilog);
+uintptr_t dynarec64_6664(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int seg, int* ok, int* need_epilog);
+uintptr_t dynarec64_66F0(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int rep, int* ok, int* need_epilog);
+uintptr_t dynarec64_F20F(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int* ok, int* need_epilog);
+uintptr_t dynarec64_F30F(dynarec_rv64_t* dyn, uintptr_t addr, uintptr_t ip, int ninst, rex_t rex, int* ok, int* need_epilog);
+
+#if STEP < 2
+#define PASS2(A)
+#else
+#define PASS2(A) A
+#endif
+
+#if STEP < 3
+#define PASS3(A)
+#else
+#define PASS3(A) A
+#endif
+
+#if STEP < 3
+#define MAYUSE(A) (void)A
+#else
+#define MAYUSE(A)
+#endif
+
+// GOCOND will use x1 and x3
+#define GOCOND(B, T1, T2) \
+ case B+0x0: \
+ INST_NAME(T1 "O " T2); \
+ GO( ANDI(x1, xFlags, 1<<F_OF2) \
+ , EQZ, NEZ, X_OF) \
+ break; \
+ case B+0x1: \
+ INST_NAME(T1 "NO " T2); \
+ GO( ANDI(x1, xFlags, 1<<F_OF2) \
+ , NEZ, EQZ, X_OF) \
+ break; \
+ case B+0x2: \
+ INST_NAME(T1 "C " T2); \
+ GO( ANDI(x1, xFlags, 1<<F_CF) \
+ , EQZ, NEZ, X_CF) \
+ break; \
+ case B+0x3: \
+ INST_NAME(T1 "NC " T2); \
+ GO( ANDI(x1, xFlags, 1<<F_CF) \
+ , NEZ, EQZ, X_CF) \
+ break; \
+ case B+0x4: \
+ INST_NAME(T1 "Z " T2); \
+ GO( ANDI(x1, xFlags, 1<<F_ZF) \
+ , EQZ, NEZ, X_ZF) \
+ break; \
+ case B+0x5: \
+ INST_NAME(T1 "NZ " T2); \
+ GO( ANDI(x1, xFlags, 1<<F_ZF) \
+ , NEZ, EQZ, X_ZF) \
+ break; \
+ case B+0x6: \
+ INST_NAME(T1 "BE " T2); \
+ GO( ANDI(x1, xFlags, (1<<F_CF)|(1<<F_ZF)) \
+ , EQZ, NEZ, X_CF|X_ZF) \
+ break; \
+ case B+0x7: \
+ INST_NAME(T1 "NBE " T2); \
+ GO( ANDI(x1, xFlags, (1<<F_CF)|(1<<F_ZF)) \
+ , NEZ, EQZ, X_CF|X_ZF) \
+ break; \
+ case B+0x8: \
+ INST_NAME(T1 "S " T2); \
+ GO( ANDI(x1, xFlags, 1<<F_SF) \
+ , EQZ, NEZ, X_SF) \
+ break; \
+ case B+0x9: \
+ INST_NAME(T1 "NS " T2); \
+ GO( ANDI(x1, xFlags, 1<<F_SF) \
+ , NEZ, EQZ, X_SF) \
+ break; \
+ case B+0xA: \
+ INST_NAME(T1 "P " T2); \
+ GO( ANDI(x1, xFlags, 1<<F_PF) \
+ , EQZ, NEZ, X_PF) \
+ break; \
+ case B+0xB: \
+ INST_NAME(T1 "NP " T2); \
+ GO( ANDI(x1, xFlags, 1<<F_PF) \
+ , NEZ, EQZ, X_PF) \
+ break; \
+ case B+0xC: \
+ INST_NAME(T1 "L " T2); \
+ GO( SRLI(x1, xFlags, F_SF-F_OF2); \
+ XOR(x1, x1, xFlags); \
+ ANDI(x1, x1, 1<<F_OF2) \
+ , EQZ, NEZ, X_SF|X_OF) \
+ break; \
+ case B+0xD: \
+ INST_NAME(T1 "GE " T2); \
+ GO( SRLI(x1, xFlags, F_SF-F_OF2); \
+ XOR(x1, x1, xFlags); \
+ ANDI(x1, x1, 1<<F_OF2) \
+ , NEZ, EQZ, X_SF|X_OF) \
+ break; \
+ case B+0xE: \
+ INST_NAME(T1 "LE " T2); \
+ GO( SRLI(x1, xFlags, F_SF-F_OF2); \
+ XOR(x1, x1, xFlags); \
+ ANDI(x1, x1, 1<<F_OF2); \
+ ANDI(x3, xFlags, 1<<F_ZF); \
+ OR(x1, x1, x3); \
+ ANDI(x1, x1, (1<<F_OF2) | (1<<F_ZF)) \
+ , EQZ, NEZ, X_SF|X_OF|X_ZF) \
+ break; \
+ case B+0xF: \
+ INST_NAME(T1 "G " T2); \
+ GO( SRLI(x1, xFlags, F_SF-F_OF2); \
+ XOR(x1, x1, xFlags); \
+ ANDI(x1, x1, 1<<F_OF2); \
+ ANDI(x3, xFlags, 1<<F_ZF); \
+ OR(x1, x1, x3); \
+ ANDI(x1, x1, (1<<F_OF2) | (1<<F_ZF)) \
+ , NEZ, EQZ, X_SF|X_OF|X_ZF) \
+ break
+
+#define NOTEST(s1) \
+ if(box64_dynarec_test) { \
+ SW(xZR, xEmu, offsetof(x64emu_t, test.test)); \
+ SW(xZR, xEmu, offsetof(x64emu_t, test.clean)); \
+ }
+#define SKIPTEST(s1) \
+ if(box64_dynarec_test) { \
+ SW(xZR, xEmu, offsetof(x64emu_t, test.clean)); \
+ }
+#define GOTEST(s1, s2) \
+ if(box64_dynarec_test) { \
+ MOV32w(s2, 1); \
+ SW(s2, xEmu, offsetof(x64emu_t, test.test)); \
+ }
+
+#define GETREX() \
+ rex.rex = 0; \
+ if(!rex.is32bits) \
+ while(opcode>=0x40 && opcode<=0x4f) { \
+ rex.rex = opcode; \
+ opcode = F8; \
+ }
+
+#endif //__DYNAREC_RV64_HELPER_H__
diff --git a/src/dynarec/rv64/dynarec_rv64_jmpnext.c b/src/dynarec/rv64/dynarec_rv64_jmpnext.c
new file mode 100644
index 0000000..9150dd4
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_jmpnext.c
@@ -0,0 +1,19 @@
+#include <stdint.h>
+
+#include "rv64_emitter.h"
+
+#define EMIT(A) *block = (A); ++block
+void CreateJmpNext(void* addr, void* next)
+{
+ uint32_t* block = (uint32_t*)addr;
+ uintptr_t diff = (intptr_t)next - (intptr_t)addr;
+ AUIPC(x2, SPLIT20(diff));
+ #if 1
+ LD(x2, x2, SPLIT12(diff));
+ #else
+ // Probably not usefull, but keeping the code, just in case
+ ADDI(x2, x2, SPLIT12(diff));
+ LR_D(x2, x2, 1, 1);
+ #endif
+ BR(x2);
+} \ No newline at end of file
diff --git a/src/dynarec/rv64/dynarec_rv64_pass0.h b/src/dynarec/rv64/dynarec_rv64_pass0.h
new file mode 100644
index 0000000..fbba8f2
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_pass0.h
@@ -0,0 +1,55 @@
+
+#define INIT uintptr_t sav_addr=addr
+#define FINI \
+ dyn->isize = addr-sav_addr; \
+ dyn->insts[ninst].x64.addr = addr; \
+ if(ninst) dyn->insts[ninst-1].x64.size = dyn->insts[ninst].x64.addr - dyn->insts[ninst-1].x64.addr
+
+#define MESSAGE(A, ...)
+#define MAYSETFLAGS() dyn->insts[ninst].x64.may_set = 1
+#define READFLAGS(A) \
+ dyn->insts[ninst].x64.use_flags = A; dyn->f.dfnone = 1;\
+ dyn->f.pending=SF_SET
+#define SETFLAGS(A,B) \
+ dyn->insts[ninst].x64.set_flags = A; \
+ dyn->insts[ninst].x64.state_flags = B; \
+ dyn->f.pending=(B)&SF_SET_PENDING; \
+ dyn->f.dfnone=((B)&SF_SET)?1:0;
+#define EMIT(A)
+#define JUMP(A, C) add_next(dyn, (uintptr_t)A); dyn->insts[ninst].x64.jmp = A; dyn->insts[ninst].x64.jmp_cond = C
+#define BARRIER(A) if(A!=BARRIER_MAYBE) {fpu_purgecache(dyn, ninst, 0, x1, x2, x3); dyn->insts[ninst].x64.barrier = A;} else dyn->insts[ninst].barrier_maybe = 1
+#define BARRIER_NEXT(A) dyn->insts[ninst+1].x64.barrier = A
+#define NEW_INST \
+ ++dyn->size; \
+ if(dyn->size+3>=dyn->cap) { \
+ dyn->insts = (instruction_native_t*)dynaRealloc(dyn->insts, sizeof(instruction_native_t)*dyn->cap*2);\
+ memset(&dyn->insts[dyn->cap], 0, sizeof(instruction_native_t)*dyn->cap); \
+ dyn->cap *= 2; \
+ } \
+ dyn->insts[ninst].x64.addr = ip; \
+ dyn->e.combined1 = dyn->e.combined2 = 0;\
+ dyn->e.swapped = 0; dyn->e.barrier = 0; \
+ for(int i=0; i<16; ++i) dyn->e.olds[i].v = 0;\
+ dyn->insts[ninst].f_entry = dyn->f; \
+ if(ninst) {dyn->insts[ninst-1].x64.size = dyn->insts[ninst].x64.addr - dyn->insts[ninst-1].x64.addr;}
+
+#define INST_EPILOG \
+ dyn->insts[ninst].f_exit = dyn->f; \
+ dyn->insts[ninst].e = dyn->e; \
+ dyn->insts[ninst].x64.has_next = (ok>0)?1:0;
+#define INST_NAME(name)
+#define DEFAULT \
+ --dyn->size; \
+ *ok = -1; \
+ if(box64_dynarec_log>=LOG_INFO || box64_dynarec_dump || box64_dynarec_missing) {\
+ dynarec_log(LOG_NONE, "%p: Dynarec stopped because of %sOpcode %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X", \
+ (void*)ip, rex.is32bits?"32bits ":"",\
+ PKip(0), \
+ PKip(1), PKip(2), PKip(3), \
+ PKip(4), PKip(5), PKip(6), \
+ PKip(7), PKip(8), PKip(9), \
+ PKip(10),PKip(11),PKip(12), \
+ PKip(13),PKip(14)); \
+ printFunctionAddr(ip, " => "); \
+ dynarec_log(LOG_NONE, "\n"); \
+ }
diff --git a/src/dynarec/rv64/dynarec_rv64_pass1.h b/src/dynarec/rv64/dynarec_rv64_pass1.h
new file mode 100644
index 0000000..34d0a46
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_pass1.h
@@ -0,0 +1,15 @@
+#define INIT
+#define FINI
+#define MESSAGE(A, ...)
+#define EMIT(A)
+#define NEW_INST \
+ dyn->insts[ninst].f_entry = dyn->f; \
+ dyn->e.combined1 = dyn->e.combined2 = 0;\
+ for(int i=0; i<16; ++i) dyn->e.olds[i].v = 0;\
+ dyn->e.swapped = 0; dyn->e.barrier = 0
+
+#define INST_EPILOG \
+ dyn->insts[ninst].e = dyn->e; \
+ dyn->insts[ninst].f_exit = dyn->f
+
+#define INST_NAME(name)
diff --git a/src/dynarec/rv64/dynarec_rv64_pass2.h b/src/dynarec/rv64/dynarec_rv64_pass2.h
new file mode 100644
index 0000000..1c6e473
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_pass2.h
@@ -0,0 +1,18 @@
+#define INIT dyn->native_size = 0
+#define FINI \
+ if(ninst) { \
+ dyn->insts[ninst].address = (dyn->insts[ninst-1].address+dyn->insts[ninst-1].size); \
+ dyn->insts_size += 1+((dyn->insts[ninst].x64.size>(dyn->insts[ninst].size/4))?dyn->insts[ninst].x64.size:(dyn->insts[ninst].size/4))/15; \
+ }
+
+#define MESSAGE(A, ...)
+#define EMIT(A) do {dyn->insts[ninst].size+=4; dyn->native_size+=4;}while(0)
+#define NEW_INST \
+ if(ninst) { \
+ dyn->insts[ninst].address = (dyn->insts[ninst-1].address+dyn->insts[ninst-1].size); \
+ dyn->insts_size += 1+((dyn->insts[ninst-1].x64.size>(dyn->insts[ninst-1].size/4))?dyn->insts[ninst-1].x64.size:(dyn->insts[ninst-1].size/4))/15; \
+ }
+#define INST_EPILOG dyn->insts[ninst].epilog = dyn->native_size;
+#define INST_NAME(name)
+#define TABLE64(A, V) {Table64(dyn, (V), 2); EMIT(0); EMIT(0);}
+#define FTABLE64(A, V) {mmx87_regs_t v = {.d = V}; Table64(dyn, v.q, 2); EMIT(0); EMIT(0);} \ No newline at end of file
diff --git a/src/dynarec/rv64/dynarec_rv64_pass3.h b/src/dynarec/rv64/dynarec_rv64_pass3.h
new file mode 100644
index 0000000..459c4e1
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_pass3.h
@@ -0,0 +1,23 @@
+#define INIT
+#define FINI \
+ if(ninst) \
+ addInst(dyn->instsize, &dyn->insts_size, dyn->insts[ninst].x64.size, dyn->insts[ninst].size/4); \
+ addInst(dyn->instsize, &dyn->insts_size, 0, 0);
+#define EMIT(A) \
+ do { \
+ if(box64_dynarec_dump) print_opcode(dyn, ninst, (uint32_t)A); \
+ *(uint32_t*)(dyn->block) = (uint32_t)(A); \
+ dyn->block += 4; dyn->native_size += 4; \
+ dyn->insts[ninst].size2 += 4; \
+ }while(0)
+
+#define MESSAGE(A, ...) if(box64_dynarec_dump) dynarec_log(LOG_NONE, __VA_ARGS__)
+#define NEW_INST \
+ if(box64_dynarec_dump) print_newinst(dyn, ninst); \
+ if(ninst) \
+ addInst(dyn->instsize, &dyn->insts_size, dyn->insts[ninst-1].x64.size, dyn->insts[ninst-1].size/4);
+#define INST_EPILOG
+#define INST_NAME(name) inst_name_pass3(dyn, ninst, name, rex)
+
+#define TABLE64(A, V) {int val64offset = Table64(dyn, (V), 3); MESSAGE(LOG_DUMP, " Table64: 0x%lx\n", (V)); AUIPC(A, SPLIT20(val64offset)); LD(A, A, SPLIT12(val64offset));}
+#define FTABLE64(A, V) {mmx87_regs_t v = {.d = V}; int val64offset = Table64(dyn, v.q, 3); MESSAGE(LOG_DUMP, " FTable64: %g\n", v.d); AUIPC(x1, SPLIT20(val64offset)); FLD(A, x1, SPLIT12(val64offset));}
diff --git a/src/dynarec/rv64/dynarec_rv64_private.h b/src/dynarec/rv64/dynarec_rv64_private.h
new file mode 100644
index 0000000..9913529
--- /dev/null
+++ b/src/dynarec/rv64/dynarec_rv64_private.h
@@ -0,0 +1,150 @@
+#ifndef __DYNAREC_RV64_PRIVATE_H_
+#define __DYNAREC_RV64_PRIVATE_H_
+#include <stdint.h>
+
+#include "../dynarec_private.h"
+
+typedef struct x64emu_s x64emu_t;
+typedef struct dynablock_s dynablock_t;
+typedef struct instsize_s instsize_t;
+
+#define BARRIER_MAYBE 8
+
+#define EXT_CACHE_NONE 0
+#define EXT_CACHE_ST_D 1
+#define EXT_CACHE_ST_F 2
+#define EXT_CACHE_MM 3
+#define EXT_CACHE_SS 4
+#define EXT_CACHE_SD 5
+#define EXT_CACHE_SCR 6
+typedef union ext_cache_s {
+ int8_t v;
+ struct {
+ uint8_t t:4; // reg type
+ uint8_t n:4; // reg number
+ };
+} ext_cache_t;
+typedef union sse_cache_s {
+ int8_t v;
+ struct {
+ uint8_t reg:7;
+ uint8_t single:1;
+ };
+} sse_cache_t;
+typedef union sse_old_s {
+ int8_t v;
+ struct {
+ uint8_t changed:1;
+ uint8_t purged:1;
+ uint8_t reg:4;
+ uint8_t single:1;
+ };
+} sse_old_t;
+typedef struct extcache_s {
+ // ext cache
+ ext_cache_t extcache[24];
+ int8_t stack;
+ int8_t stack_next;
+ int8_t stack_pop;
+ int8_t stack_push;
+ uint8_t combined1;
+ uint8_t combined2;
+ uint8_t swapped; // the combined reg were swapped
+ uint8_t barrier; // is there a barrier at instruction epilog?
+ uint32_t news; // bitmask, wich neoncache are new for this opcode
+ sse_old_t olds[16]; // SSE regs has changed or has been removed
+ // fpu cache
+ int8_t x87cache[8]; // cache status for the 8 x87 register behind the fpu stack
+ int8_t x87reg[8]; // reg used for x87cache entry
+ int8_t mmxcache[8]; // cache status for the 8 MMX registers
+ sse_cache_t ssecache[16]; // cache status for the 16 SSE(2) registers
+ int8_t fpuused[24]; // all 10..31 & 0..1 double reg from fpu, used by x87, sse and mmx
+ int8_t x87stack; // cache stack counter
+ int8_t mmxcount; // number of mmx register used (not both mmx and x87 at the same time)
+ int8_t fpu_scratch; // scratch counter
+ int8_t fpu_extra_qscratch; // some opcode need an extra quad scratch register
+ int8_t fpu_reg; // x87/sse/mmx reg counter
+} extcache_t;
+
+typedef struct flagcache_s {
+ int pending; // is there a pending flags here, or to check?
+ int dfnone; // if deferred flags is already set to df_none
+} flagcache_t;
+
+typedef struct instruction_rv64_s {
+ instruction_x64_t x64;
+ uintptr_t address; // (start) address of the arm emitted instruction
+ uintptr_t epilog; // epilog of current instruction (can be start of next, or barrier stuff)
+ int size; // size of the arm emitted instruction
+ int size2; // size of the arm emitted instrucion after pass2
+ int pred_sz; // size of predecessor list
+ int *pred; // predecessor array
+ uintptr_t mark, mark2, mark3;
+ uintptr_t markf, markf2;
+ uintptr_t markseg;
+ uintptr_t marklock;
+ int pass2choice;// value for choices that are fixed on pass2 for pass3
+ uintptr_t natcall;
+ int retn;
+ int barrier_maybe;
+ flagcache_t f_exit; // flags status at end of intruction
+ extcache_t e; // extcache at end of intruction (but before poping)
+ flagcache_t f_entry; // flags status before the instruction begin
+} instruction_rv64_t;
+
+typedef struct dynarec_rv64_s {
+ instruction_rv64_t* insts;
+ int32_t size;
+ int32_t cap;
+ uintptr_t start; // start of the block
+ uint32_t isize; // size in byte of x64 instructions included
+ void* block; // memory pointer where next instruction is emitted
+ uintptr_t native_start; // start of the arm code
+ size_t native_size; // size of emitted arm code
+ uintptr_t last_ip; // last set IP in RIP (or NULL if unclean state) TODO: move to a cache something
+ uint64_t* table64; // table of 64bits value
+ int table64size;// size of table (will be appended at end of executable code)
+ int table64cap;
+ uintptr_t tablestart;
+ uintptr_t jmp_next; // address of the jump_next address
+ flagcache_t f;
+ extcache_t e; // cache for the 10..31 0..1 double reg from fpu, plus x87 stack delta
+ uintptr_t* next; // variable array of "next" jump address
+ int next_sz;
+ int next_cap;
+ int* predecessor;// single array of all predecessor
+ dynablock_t* dynablock;
+ instsize_t* instsize;
+ size_t insts_size; // size of the instruction size array (calculated)
+ uint8_t smread; // for strongmem model emulation
+ uint8_t smwrite; // for strongmem model emulation
+ uintptr_t forward; // address of the last end of code while testing forward
+ uintptr_t forward_to; // address of the next jump to (to check if everything is ok)
+ int32_t forward_size; // size at the forward point
+ int forward_ninst; // ninst at the forward point
+ uint8_t always_test;
+} dynarec_rv64_t;
+
+// convert idx (0..24) to reg index (10..31 0..1)
+#define EXTREG(A) (((A)+10)&31)
+// convert reg index (10..31 0..1) or idx (0..24)
+#define EXTIDX(A) (((A)-10)&31)
+
+void add_next(dynarec_rv64_t *dyn, uintptr_t addr);
+uintptr_t get_closest_next(dynarec_rv64_t *dyn, uintptr_t addr);
+int is_nops(dynarec_rv64_t *dyn, uintptr_t addr, int n);
+int is_instructions(dynarec_rv64_t *dyn, uintptr_t addr, int n);
+
+int Table64(dynarec_rv64_t *dyn, uint64_t val, int pass); // add a value to table64 (if needed) and gives back the imm19 to use in LDR_literal
+
+void CreateJmpNext(void* addr, void* next);
+
+#define GO_TRACE(A, B) \
+ GETIP(addr); \
+ MV(A1, xRIP); \
+ STORE_XEMU_CALL(); \
+ MOV64x(A2, B); \
+ CALL(A, -1); \
+ LOAD_XEMU_CALL()
+
+#endif //__DYNAREC_RV64_PRIVATE_H_ \ No newline at end of file
diff --git a/src/dynarec/rv64/rv64_emitter.h b/src/dynarec/rv64/rv64_emitter.h
new file mode 100644
index 0000000..f23c671
--- /dev/null
+++ b/src/dynarec/rv64/rv64_emitter.h
@@ -0,0 +1,654 @@
+#ifndef __RV64_EMITTER_H__
+#define __RV64_EMITTER_H__
+/*
+ RV64 Emitter
+
+*/
+
+// RV64 ABI
+/*
+reg name description saver
+------------------------------------------------------
+x0 zero Hard-wired zero —
+x1 ra Return address Caller
+x2 sp Stack pointer Callee
+x3 gp Global pointer —
+x4 tp Thread pointer —
+x5–7 t0–2 Temporaries Caller
+x8 s0/fp Saved register/frame pointer Callee
+x9 s1 Saved register Callee
+x10–11 a0–1 Function arguments/return val. Caller
+x12–17 a2–7 Function arguments Caller
+x18–27 s2–11 Saved registers Callee
+x28–31 t3–6 Temporaries Caller
+-------------------------------------------------------
+f0–7 ft0–7 FP temporaries Caller
+f8–9 fs0–1 FP saved registers Callee
+f10–11 fa0–1 FP arguments/return values Caller
+f12–17 fa2–7 FP arguments Caller
+f18–27 fs2–11 FP saved registers Callee
+f28–31 ft8–11 FP temporaries Caller
+*/
+// x86 Register mapping
+#define xRAX 16
+#define xRCX 17
+#define xRDX 18
+#define xRBX 19
+#define xRSP 20
+#define xRBP 21
+#define xRSI 22
+#define xRDI 23
+#define xR8 24
+#define xR9 25
+#define xR10 26
+#define xR11 27
+#define xR12 28
+#define xR13 29
+#define xR14 30
+#define xR15 31
+#define xFlags 8
+#define xRIP 7
+
+// 32bits version
+#define wEAX xRAX
+#define wECX xRCX
+#define wEDX xRDX
+#define wEBX xRBX
+#define wESP xRSP
+#define wEBP xRBP
+#define wESI xRSI
+#define wEDI xRDI
+#define wR8 xR8
+#define wR9 xR9
+#define wR10 xR10
+#define wR11 xR11
+#define wR12 xR12
+#define wR13 xR13
+#define wR14 xR14
+#define wR15 xR15
+#define wFlags xFlags
+// scratch registers
+#define x1 11
+#define x2 12
+#define x3 13
+#define x4 14
+#define x5 15
+#define x6 6
+#define x9 9
+// used to clear the upper 32bits
+#define xMASK 5
+// 32bits version of scratch
+#define w1 x1
+#define w2 x2
+#define w3 x3
+#define w4 x4
+#define w5 x5
+#define w6 x6
+// emu is r10
+#define xEmu 10
+// RV64 RA
+#define xRA 1
+#define xSP 2
+// RV64 args
+#define A0 10
+#define A1 11
+#define A2 12
+#define A3 13
+#define A4 14
+#define A5 15
+#define A6 16
+#define A7 17
+// xZR reg is 0
+#define xZR 0
+#define wZR xZR
+
+// replacement for F_OF internaly, using a reserved bit. Need to use F_OF2 internaly, never F_OF directly!
+#define F_OF2 F_res3
+
+// split a 32bits value in 20bits + 12bits, adjust the upper part is 12bits is negative
+#define SPLIT20(A) (((A)+0x800)>>12)
+#define SPLIT12(A) ((A)&0xfff)
+
+// MOV64x/MOV32w is quite complex, so use a function for this
+#define MOV64x(A, B) rv64_move64(dyn, ninst, A, B)
+#define MOV32w(A, B) rv64_move32(dyn, ninst, A, B, 1)
+#define MOV64xw(A, B) if(rex.w) {MOV64x(A, B);} else {MOV32w(A, B);}
+#define MOV64z(A, B) if(rex.is32bits) {MOV32w(A, B);} else {MOV64x(A, B);}
+
+// ZERO the upper part
+#define ZEROUP(r) AND(r, r, xMASK)
+
+#define R_type(funct7, rs2, rs1, funct3, rd, opcode) ((funct7)<<25 | (rs2)<<20 | (rs1)<<15 | (funct3)<<12 | (rd)<<7 | (opcode))
+#define I_type(imm12, rs1, funct3, rd, opcode) ((imm12)<<20 | (rs1)<<15 | (funct3)<<12 | (rd)<<7 | (opcode))
+#define S_type(imm12, rs2, rs1, funct3, opcode) (((imm12)>>5)<<25 | (rs2)<<20 | (rs1)<<15 | (funct3)<<12 | ((imm12)&31)<<7 | (opcode))
+#define B_type(imm13, rs2, rs1, funct3, opcode) ((((imm13)>>12)&1)<<31 | (((imm13)>>5)&63)<<25 | (rs2)<<20 | (rs1)<<15 | (funct3)<<12 | (((imm13)>>1)&15)<<8 | (((imm13)>>11)&1)<<7 | (opcode))
+#define U_type(imm32, rd, opcode) (((imm32)>>12)<<12 | (rd)<<7 | (opcode))
+#define J_type(imm21, rd, opcode) ((((imm21)>>20)&1)<<31 | (((imm21)>>1)&0b1111111111)<<21 | (((imm21)>>11)&1)<<20 | (((imm21)>>12)&0b11111111)<<12 | (rd)<<7 | (opcode))
+
+// RV32I
+// put imm20 in the [31:12] bits of rd, zero [11:0] and sign extend bits31
+#define LUI(rd, imm20) EMIT(U_type((imm20)<<12, rd, 0b0110111))
+
+// put PC+imm20 in rd
+#define AUIPC(rd, imm20) EMIT(U_type((imm20)<<12, rd, 0b0010111))
+
+#define JAL_gen(rd, imm21) J_type(imm21, rd, 0b1101111)
+// Unconditional branch, no return address set
+#define B(imm21) EMIT(JAL_gen(xZR, imm21))
+#define B__(reg1, reg2, imm21) B(imm21)
+// Unconditional branch, return set to xRA
+#define JAL(imm21) EMIT(JAL_gen(xRA, imm21))
+// Unconditional branch, without link
+#define J(imm21) EMIT(JAL_gen(xZR, imm21))
+
+#define JALR_gen(rd, rs1, imm12) I_type(imm12, rs1, 0b000, rd, 0b1100111)
+// Unconditionnal branch to r, no return address set
+#define BR(r) EMIT(JALR_gen(xZR, r, 0))
+// Unconditionnal branch to r+i12, no return address set
+#define BR_I12(r, imm12) EMIT(JALR_gen(xZR, r, (imm12)&0b111111111111))
+// Unconditionnal branch to r, return address set to xRA
+#define JALR(r) EMIT(JALR_gen(xRA, r, 0))
+// Unconditionnal branch to r+i12, return address set to xRA
+#define JALR_I12(r, imm12) EMIT(JALR_gen(xRA, r, (imm12)&0b111111111111))
+
+// rd = rs1 + imm12
+#define ADDI(rd, rs1, imm12) EMIT(I_type((imm12)&0b111111111111, rs1, 0b000, rd, 0b0010011))
+// rd = rs1 - imm12 (pseudo instruction)
+#define SUBI(rd, rs1, imm12) EMIT(I_type((-(imm12))&0b111111111111, rs1, 0b000, rd, 0b0010011))
+// rd = (rs1<imm12)?1:0
+#define SLTI(rd, rs1, imm12) EMIT(I_type((imm12)&0b111111111111, rs1, 0b010, rd, 0b0010011))
+// rd = (rs1<imm12)?1:0 unsigned
+#define SLTIU(rd, rs1, imm12) EMIT(I_type((imm12)&0b111111111111, rs1, 0b011, rd, 0b0010011))
+// rd = rs1 ^ imm12
+#define XORI(rd, rs1, imm12) EMIT(I_type((imm12)&0b111111111111, rs1, 0b100, rd, 0b0010011))
+// rd = rs1 | imm12
+#define ORI(rd, rs1, imm12) EMIT(I_type((imm12)&0b111111111111, rs1, 0b110, rd, 0b0010011))
+// rd = rs1 & imm12
+#define ANDI(rd, rs1, imm12) EMIT(I_type((imm12)&0b111111111111, rs1, 0b111, rd, 0b0010011))
+
+// rd = imm12
+#define MOV_U12(rd, imm12) ADDI(rd, xZR, imm12)
+// nop
+#define NOP() ADDI(xZR, xZR, 0)
+
+// rd = rs1 + rs2
+#define ADD(rd, rs1, rs2) EMIT(R_type(0b0000000, rs2, rs1, 0b000, rd, 0b0110011))
+// rd = rs1 + rs2
+#define ADDW(rd, rs1, rs2) EMIT(R_type(0b0000000, rs2, rs1, 0b000, rd, 0b0111011))
+// rd = rs1 + rs2
+#define ADDxw(rd, rs1, rs2) EMIT(R_type(0b0000000, rs2, rs1, 0b000, rd, rex.w?0b0110011:0b0111011))
+// rd = rs1 + rs2
+#define ADDz(rd, rs1, rs2) EMIT(R_type(0b0000000, rs2, rs1, 0b000, rd, rex.is32bits?0b0111011:0b0110011))
+// rd = rs1 - rs2
+#define SUB(rd, rs1, rs2) EMIT(R_type(0b0100000, rs2, rs1, 0b000, rd, 0b0110011))
+// rd = rs1 - rs2
+#define SUBW(rd, rs1, rs2) EMIT(R_type(0b0100000, rs2, rs1, 0b000, rd, 0b0111011))
+// rd = rs1 - rs2
+#define SUBxw(rd, rs1, rs2) EMIT(R_type(0b0100000, rs2, rs1, 0b000, rd, rex.w?0b0110011:0b0111011))
+// rd = rs1 - rs2
+#define SUBz(rd, rs1, rs2) EMIT(R_type(0b0100000, rs2, rs1, 0b000, rd, rex.is32bits?0b0111011:0b0110011))
+// rd = rs1<<rs2
+#define SLL(rd, rs1, rs2) EMIT(R_type(0b0000000, rs2, rs1, 0b001, rd, 0b0110011))
+// rd = (rs1<rs2)?1:0
+#define SLT(rd, rs1, rs2) EMIT(R_type(0b0000000, rs2, rs1, 0b010, rd, 0b0110011))
+// rd = (rs1<rs2)?1:0 Unsigned
+#define SLTU(rd, rs1, rs2) EMIT(R_type(0b0000000, rs2, rs1, 0b011, rd, 0b0110011))
+// rd = rs1 ^ rs2
+#define XOR(rd, rs1, rs2) EMIT(R_type(0b0000000, rs2, rs1, 0b100, rd, 0b0110011))
+// rd = rs1 ^ rs2
+#define XORxw(rd, rs1, rs2) do{ XOR(rd, rs1, rs2); if (!rex.w) ZEROUP(rd); }while(0)
+// rd = rs1>>rs2 logical
+#define SRL(rd, rs1, rs2) EMIT(R_type(0b0000000, rs2, rs1, 0b101, rd, 0b0110011))
+// rd = rs1>>rs2 arithmetic
+#define SRA(rd, rs1, rs2) EMIT(R_type(0b0100000, rs2, rs1, 0b101, rd, 0b0110011))
+// rd = rs1 | rs2
+#define OR(rd, rs1, rs2) EMIT(R_type(0b0000000, rs2, rs1, 0b110, rd, 0b0110011))
+// rd = rs1 & rs2
+#define AND(rd, rs1, rs2) EMIT(R_type(0b0000000, rs2, rs1, 0b111, rd, 0b0110011))
+
+// rd = rs1 (pseudo instruction)
+#define MV(rd, rs1) ADDI(rd, rs1, 0)
+// rd = rs1 (pseudo instruction)
+#define MVxw(rd, rs1) if(rex.w) {MV(rd, rs1);} else {AND(rd, rs1, xMASK);}
+// rd = rs1 (pseudo instruction)
+#define MVz(rd, rs1) if(rex.is32bits) {AND(rd, rs1, xMASK);} else {MV(rd, rs1);}
+// rd = !rs1
+#define NOT(rd, rs1) XORI(rd, rs1, -1)
+// rd = -rs1
+#define NEG(rd, rs1) SUB(rd, xZR, rs1)
+// rd = -rs1
+#define NEGxw(rd, rs1) SUBxw(rd, xZR, rs1)
+// rd = rs1 == 0
+#define SEQZ(rd, rs1) SLTIU(rd, rs1, 1)
+// rd = rs1 != 0
+#define SNEZ(rd, rs1) SLTU(rd, xZR, rs1)
+
+
+#define BEQ(rs1, rs2, imm13) EMIT(B_type(imm13, rs2, rs1, 0b000, 0b1100011))
+#define BNE(rs1, rs2, imm13) EMIT(B_type(imm13, rs2, rs1, 0b001, 0b1100011))
+#define BLT(rs1, rs2, imm13) EMIT(B_type(imm13, rs2, rs1, 0b100, 0b1100011))
+#define BGE(rs1, rs2, imm13) EMIT(B_type(imm13, rs2, rs1, 0b101, 0b1100011))
+#define BLTU(rs1, rs2, imm13) EMIT(B_type(imm13, rs2, rs1, 0b110, 0b1100011))
+#define BGEU(rs1, rs2, imm13) EMIT(B_type(imm13, rs2, rs1, 0b111, 0b1100011))
+
+// TODO: Find a better way to have conditionnal jumps? Imm is a relative jump address, so the the 2nd jump needs to be addapted
+#define BEQ_safe(rs1, rs2, imm) if((imm)>-0x1000 && (imm)<0x1000) {BEQ(rs1, rs2, imm); NOP();} else {BNE(rs1, rs2, 8); B(imm-4);}
+#define BNE_safe(rs1, rs2, imm) if((imm)>-0x1000 && (imm)<0x1000) {BNE(rs1, rs2, imm); NOP();} else {BEQ(rs1, rs2, 8); B(imm-4);}
+#define BLT_safe(rs1, rs2, imm) if((imm)>-0x1000 && (imm)<0x1000) {BLT(rs1, rs2, imm); NOP();} else {BGE(rs2, rs1, 8); B(imm-4);}
+#define BGE_safe(rs1, rs2, imm) if((imm)>-0x1000 && (imm)<0x1000) {BGE(rs1, rs2, imm); NOP();} else {BLT(rs2, rs1, 8); B(imm-4);}
+#define BLTU_safe(rs1, rs2, imm) if((imm)>-0x1000 && (imm)<0x1000) {BLTU(rs1, rs2, imm); NOP();} else {BGEU(rs2, rs1, 8); B(imm-4);}
+#define BGEU_safe(rs1, rs2, imm) if((imm)>-0x1000 && (imm)<0x1000) {BGEU(rs1, rs2, imm); NOP();} else {BLTU(rs2, rs1, 8); B(imm-4);}
+
+#define BEQZ(rs1, imm13) BEQ(rs1, 0, imm13)
+#define BNEZ(rs1, imm13) BNE(rs1, 0, imm13)
+
+#define BEQZ_safe(rs1, imm) if((imm)>-0x1000 && (imm)<0x1000) {BEQZ(rs1, imm); NOP();} else {BNEZ(rs1, 8); B(imm-4);}
+#define BNEZ_safe(rs1, imm) if((imm)>-0x1000 && (imm)<0x1000) {BNEZ(rs1, imm); NOP();} else {BEQZ(rs1, 8); B(imm-4);}
+
+// rd = 4-bytes[rs1+imm12] signed extended
+#define LW(rd, rs1, imm12) EMIT(I_type(imm12, rs1, 0b010, rd, 0b0000011))
+// rd = 2-bytes[rs1+imm12] signed extended
+#define LH(rd, rs1, imm12) EMIT(I_type(imm12, rs1, 0b001, rd, 0b0000011))
+// rd = byte[rs1+imm12] signed extended
+#define LB(rd, rs1, imm12) EMIT(I_type(imm12, rs1, 0b000, rd, 0b0000011))
+// rd = 2-bytes[rs1+imm12] zero extended
+#define LHU(rd, rs1, imm12) EMIT(I_type(imm12, rs1, 0b101, rd, 0b0000011))
+// rd = byte[rs1+imm12] zero extended
+#define LBU(rd, rs1, imm12) EMIT(I_type(imm12, rs1, 0b100, rd, 0b0000011))
+// byte[rs1+imm12] = rs2
+#define SB(rs2, rs1, imm12) EMIT(S_type(imm12, rs2, rs1, 0b000, 0b0100011))
+// 2-bytes[rs1+imm12] = rs2
+#define SH(rs2, rs1, imm12) EMIT(S_type(imm12, rs2, rs1, 0b001, 0b0100011))
+// 4-bytes[rs1+imm12] = rs2
+#define SW(rs2, rs1, imm12) EMIT(S_type(imm12, rs2, rs1, 0b010, 0b0100011))
+
+#define PUSH1(reg) do {SD(reg, xRSP, -8); SUBI(xRSP, xRSP, 8);} while(0)
+#define POP1(reg) do {LD(reg, xRSP, 0); if (reg!=xRSP) ADDI(xRSP, xRSP, 8);} while(0)
+#define PUSH1_32(reg) do {SW(reg, xRSP, -4); SUBIW(xRSP, xRSP, 4);} while(0)
+#define POP1_32(reg) do {LWU(reg, xRSP, 0); if (reg!=xRSP) ADDIW(xRSP, xRSP, 4);} while(0)
+
+#define POP1z(reg) if(rex.is32bits) {POP1_32(reg);} else {POP1(reg);}
+#define PUSH1z(reg) if(rex.is32bits) {PUSH1_32(reg);} else {PUSH1(reg);}
+
+#define FENCE_gen(pred, succ) (((pred)<<24) | ((succ)<<20) | 0b0001111)
+#define FENCE() EMIT(FENCE_gen(3, 3))
+
+#define FENCE_I_gen() ((0b001<<12) | 0b0001111)
+#define FENCE_I() EMIT(FENCE_I_gen())
+
+#define EBREAK() EMIT(I_type(1, 0, 0, 0, 0b1110011))
+
+// RV64I
+#define LWU(rd, rs1, imm12) EMIT(I_type(imm12, rs1, 0b110, rd, 0b0000011))
+
+// rd = [rs1 + imm12]
+#define LD(rd, rs1, imm12) EMIT(I_type(imm12, rs1, 0b011, rd, 0b0000011))
+// rd = [rs1 + imm12]
+#define LDxw(rd, rs1, imm12) EMIT(I_type(imm12, rs1, 0b011<<(1-rex.w), rd, 0b0000011))
+// rd = [rs1 + imm12]
+#define LDz(rd, rs1, imm12) EMIT(I_type(imm12, rs1, 0b011<<rex.is32bits, rd, 0b0000011))
+// [rs1 + imm12] = rs2
+#define SD(rs2, rs1, imm12) EMIT(S_type(imm12, rs2, rs1, 0b011, 0b0100011))
+// [rs1 + imm12] = rs2
+#define SDxw(rs2, rs1, imm12) EMIT(S_type(imm12, rs2, rs1, 0b010+rex.w, 0b0100011))
+// [rs1 + imm12] = rs2
+#define SDz(rs2, rs1, imm12) EMIT(S_type(imm12, rs2, rs1, 0b010+(1-rex.is32bits), 0b0100011))
+
+// Shift Left Immediate
+#define SLLI(rd, rs1, imm6) EMIT(I_type(imm6, rs1, 0b001, rd, 0b0010011))
+// Shift Right Logical Immediate
+#define SRLI(rd, rs1, imm6) EMIT(I_type(imm6, rs1, 0b101, rd, 0b0010011))
+// Shift Right Arithmetic Immediate
+#define SRAI(rd, rs1, imm6) EMIT(I_type((imm6)|(0b010000<<6), rs1, 0b101, rd, 0b0010011))
+
+// rd = rs1 + imm12
+#define ADDIW(rd, rs1, imm12) EMIT(I_type((imm12)&0b111111111111, rs1, 0b000, rd, 0b0011011))
+// rd = rs1 - imm12
+#define SUBIW(rd, rs1, imm12) EMIT(I_type((-imm12)&0b111111111111, rs1, 0b000, rd, 0b0011011))
+// rd = rs1 + imm12
+#define ADDIxw(rd, rs1, imm12) EMIT(I_type((imm12)&0b111111111111, rs1, 0b000, rd, rex.w?0b0010011:0b0011011))
+// rd = rs1 + imm12
+#define ADDIz(rd, rs1, imm12) EMIT(I_type((imm12)&0b111111111111, rs1, 0b000, rd, rex.is32bits?0b0011011:0b0010011))
+
+#define SEXT_W(rd, rs1) ADDIW(rd, rs1, 0)
+
+// rd = rs1<<rs2
+#define SLLW(rd, rs1, rs2) EMIT(R_type(0b0000000, rs2, rs1, 0b001, rd, 0b0111011))
+// rd = rs1>>rs2 logical
+#define SRLW(rd, rs1, rs2) EMIT(R_type(0b0000000, rs2, rs1, 0b101, rd, 0b0111011))
+// rd = rs1>>rs2 arithmetic
+#define SRAW(rd, rs1, rs2) EMIT(R_type(0b0100000, rs2, rs1, 0b101, rd, 0b0111011))
+
+#define SLLxw(rd, rs1, rs2) EMIT(R_type(0b0000000, rs2, rs1, 0b001, rd, rex.w?0b0110011:0b0111011))
+#define SRLxw(rd, rs1, rs2) EMIT(R_type(0b0000000, rs2, rs1, 0b101, rd, rex.w?0b0110011:0b0111011))
+#define SRAxw(rd, rs1, rs2) if(rex.w) {SRA(rd, rs1, rs2);} else {SRAW(rd, rs1, rs2); ZEROUP(rd);}
+
+// Shift Left Immediate, 32-bit, sign-extended
+#define SLLIW(rd, rs1, imm5) EMIT(I_type(imm5, rs1, 0b001, rd, 0b0011011))
+// Shift Left Immediate
+#define SLLIxw(rd, rs1, imm) if (rex.w) { SLLI(rd, rs1, imm); } else { SLLIW(rd, rs1, imm); }
+// Shift Right Logical Immediate, 32-bit, sign-extended
+#define SRLIW(rd, rs1, imm5) EMIT(I_type(imm5, rs1, 0b101, rd, 0b0011011))
+// Shift Right Logical Immediate
+#define SRLIxw(rd, rs1, imm) if (rex.w) { SRLI(rd, rs1, imm); } else { SRLIW(rd, rs1, imm); }
+// Shift Right Arithmetic Immediate, 32-bit, sign-extended
+#define SRAIW(rd, rs1, imm5) EMIT(I_type((imm5)|(0b0100000<<5), rs1, 0b101, rd, 0b0011011))
+// Shift Right Arithmetic Immediate
+#define SRAIxw(rd, rs1, imm) if (rex.w) { SRAI(rd, rs1, imm); } else { SRAIW(rd, rs1, imm); }
+
+#define CSRRW(rd, rs1, csr) EMIT(I_type(csr, rs1, 0b001, rd, 0b1110011))
+#define CSRRS(rd, rs1, csr) EMIT(I_type(csr, rs1, 0b010, rd, 0b1110011))
+#define CSRRC(rd, rs1, csr) EMIT(I_type(csr, rs1, 0b011, rd, 0b1110011))
+#define CSRRWI(rd, imm, csr) EMIT(I_type(csr, imm, 0b101, rd, 0b1110011))
+#define CSRRSI(rd, imm, csr) EMIT(I_type(csr, imm, 0b110, rd, 0b1110011))
+#define CSRRCI(rd, imm, csr) EMIT(I_type(csr, imm, 0b111, rd, 0b1110011))
+
+// RV32M
+// rd =(lower) rs1 * rs2 (both signed)
+#define MUL(rd, rs1, rs2) EMIT(R_type(0b0000001, rs2, rs1, 0b000, rd, 0b0110011))
+// rd =(upper) rs1 * rs2 (both signed)
+#define MULH(rd, rs1, rs2) EMIT(R_type(0b0000001, rs2, rs1, 0b001, rd, 0b0110011))
+// rd =(upper) (signed)rs1 * (unsigned)rs2
+#define MULHSU(rd, rs1, rs2) EMIT(R_type(0b0000001, rs2, rs1, 0b010, rd, 0b0110011))
+// rd =(upper) rs1 * rs2 (both unsigned)
+#define MULHU(rd, rs1, rs2) EMIT(R_type(0b0000001, rs2, rs1, 0b011, rd, 0b0110011))
+// rd =(upper) rs1 / rs2
+#define DIV(rd, rs1, rs2) EMIT(R_type(0b0000001, rs2, rs1, 0b100, rd, 0b0110011))
+#define DIVU(rd, rs1, rs2) EMIT(R_type(0b0000001, rs2, rs1, 0b101, rd, 0b0110011))
+// rd = rs1 mod rs2
+#define REM(rd, rs1, rs2) EMIT(R_type(0b0000001, rs2, rs1, 0b110, rd, 0b0110011))
+#define REMU(rd, rs1, rs2) EMIT(R_type(0b0000001, rs2, rs1, 0b111, rd, 0b0110011))
+
+// RV64M
+// rd = rs1 * rs2
+#define MULW(rd, rs1, rs2) EMIT(R_type(0b0000001, rs2, rs1, 0b000, rd, 0b0111011))
+// rd = rs1 * rs2
+#define MULxw(rd, rs1, rs2) EMIT(R_type(0b0000001, rs2, rs1, 0b000, rd, rex.w?0b0110011:0b0111011))
+// rd = rs1 / rs2
+#define DIVW(rd, rs1, rs2) EMIT(R_type(0b0000001, rs2, rs1, 0b100, rd, 0b0111011))
+#define DIVxw(rd, rs1, rs2) EMIT(R_type(0b0000001, rs2, rs1, 0b100, rd, rex.w?0b0110011:0b0111011))
+#define DIVUW(rd, rs1, rs2) EMIT(R_type(0b0000001, rs2, rs1, 0b101, rd, 0b0111011))
+#define DIVUxw(rd, rs1, rs2) EMIT(R_type(0b0000001, rs2, rs1, 0b101, rd, rex.w?0b0110011:0b0111011))
+// rd = rs1 mod rs2
+#define REMW(rd, rs1, rs2) EMIT(R_type(0b0000001, rs2, rs1, 0b110, rd, 0b0111011))
+#define REMxw(rd, rs1, rs2) EMIT(R_type(0b0000001, rs2, rs1, 0b110, rd, rex.w?0b0110011:0b0111011))
+#define REMUW(rd, rs1, rs2) EMIT(R_type(0b0000001, rs2, rs1, 0b111, rd, 0b0111011))
+#define REMUxw(rd, rs1, rs2) EMIT(R_type(0b0000001, rs2, rs1, 0b111, rd, rex.w?0b0110011:0b0111011))
+
+#define AQ_RL(f5, aq, rl) ((f5 << 2) | ((aq&1) << 1) | (rl&1))
+
+// RV32A
+#define LR_W(rd, rs1, aq, rl) EMIT(R_type(AQ_RL(0b00010, aq, rl), 0, rs1, 0b010, rd, 0b0101111))
+#define SC_W(rd, rs2, rs1, aq, rl) EMIT(R_type(AQ_RL(0b00011, aq, rl), rs2, rs1, 0b010, rd, 0b0101111))
+
+#define AMOSWAP_W(rd, rs2, rs1, aq, rl) EMIT(R_type(AQ_RL(0b00001, aq, rl), rs2, rs1, 0b010, rd, 0b0101111))
+
+// RV64A
+#define LR_D(rd, rs1, aq, rl) EMIT(R_type(AQ_RL(0b00010, aq, rl), 0, rs1, 0b011, rd, 0b0101111))
+#define SC_D(rd, rs2, rs1, aq, rl) EMIT(R_type(AQ_RL(0b00011, aq, rl), rs2, rs1, 0b011, rd, 0b0101111))
+
+#define LRxw(rd, rs1, aq, rl) EMIT(R_type(AQ_RL(0b00010, aq, rl), 0, rs1, 0b010|rex.w, rd, 0b0101111))
+#define SCxw(rd, rs2, rs1, aq, rl) EMIT(R_type(AQ_RL(0b00011, aq, rl), rs2, rs1, 0b010|rex.w, rd, 0b0101111))
+
+#define AMOSWAP_D(rd, rs2, rs1, aq, rl) EMIT(R_type(AQ_RL(0b00001, aq, rl), rs2, rs1, 0b011, rd, 0b0101111))
+
+// RV32F
+// Read round mode
+#define FRRM(rd) CSRRS(rd, xZR, 0x002)
+// Swap round mode
+#define FSRM(rd, rs) CSRRW(rd, rs, 0x002)
+// Write FP exception flags, immediate
+#define FSFLAGSI(imm) CSRRWI(xZR, imm, 0x0001)
+// Read FP exception flags to rd
+#define FRFLAGS(rd) CSRRS(rd, xZR, 0x0001)
+// Inexact
+#define FR_NX 0
+// Underflow
+#define FR_UF 1
+// Overflow
+#define FR_OF 2
+// Divide by Zero
+#define FR_DZ 3
+// Invalid Operation
+#define FR_NV 4
+
+// Round to Nearest, ties to Even
+#define RD_RNE 0b000
+// Round towards Zero
+#define RD_RTZ 0b001
+// Round Down (towards −∞)
+#define RD_RDN 0b010
+// Round Up (towards +∞)
+#define RD_RUP 0b011
+// Round to Nearest, ties to Max Magnitude
+#define RD_RMM 0b100
+// In instruction’s rm field, selects dynamic rounding mode;
+#define RD_RM 0b111
+#define RD_DYN RD_RM
+
+// load single precision from rs1+imm12 to frd
+#define FLW(frd, rs1, imm12) EMIT(I_type(imm12, rs1, 0b010, frd, 0b0000111))
+// store single precision frs2 to rs1+imm12
+#define FSW(frs2, rs1, imm12) EMIT(S_type(imm12, frs2, rs1, 0b010, 0b0100111))
+// store rs1 with rs2 sign bit to rd
+#define FSGNJS(rd, rs1, rs2) EMIT(R_type(0b0010000, rs2, rs1, 0b000, rd, 0b1010011))
+// move rs1 to rd
+#define FMVS(rd, rs1) FSGNJS(rd, rs1, rs1)
+// store rs1 with oposite rs2 sign bit to rd
+#define FSGNJNS(rd, rs1, rs2) EMIT(R_type(0b0010000, rs2, rs1, 0b001, rd, 0b1010011))
+// -rs1 => rd
+#define FNEGS(rd, rs1) FSGNJNS(rd, rs1, rs1)
+// store rs1 with rs1^rs2 sign bit to rd
+#define FSGNJXS(rd, rs1, rs2) EMIT(R_type(0b0010000, rs2, rs1, 0b010, rd, 0b1010011))
+// |rs1| => rd
+#define FABSS(rd, rs1) FSGNJXS(rd, rs1, rs1)
+// Move from Single
+#define FMVXW(rd, frs1) EMIT(R_type(0b1110000, 0b00000, frs1, 0b000, rd, 0b1010011))
+// Move to Single
+#define FMVWX(frd, rs1) EMIT(R_type(0b1111000, 0b00000, rs1, 0b000, frd, 0b1010011))
+// Convert from signed 32bits to Single
+#define FCVTSW(frd, rs1, rm) EMIT(R_type(0b1101000, 0b00000, rs1, rm, frd, 0b1010011))
+// Convert from Single to signed 32bits (trucated)
+#define FCVTWS(rd, frs1, rm) EMIT(R_type(0b1100000, 0b00000, frs1, rm, rd, 0b1010011))
+
+#define FADDS(frd, frs1, frs2) EMIT(R_type(0b0000000, frs2, frs1, 0b000, frd, 0b1010011))
+#define FSUBS(frd, frs1, frs2) EMIT(R_type(0b0000100, frs2, frs1, 0b000, frd, 0b1010011))
+#define FMULS(frd, frs1, frs2) EMIT(R_type(0b0001000, frs2, frs1, 0b000, frd, 0b1010011))
+#define FDIVS(frd, frs1, frs2) EMIT(R_type(0b0001100, frs2, frs1, 0b000, frd, 0b1010011))
+#define FSQRTS(frd, frs1) EMIT(R_type(0b0101100, 0b00000, frs1, 0b000, frd, 0b1010011))
+#define FMINS(frd, frs1, frs2) EMIT(R_type(0b0010100, frs2, frs1, 0b000, frd, 0b1010011))
+#define FMAXS(frd, frs1, frs2) EMIT(R_type(0b0010100, frs2, frs1, 0b001, frd, 0b1010011))
+
+// compare
+#define FEQS(rd, frs1, frs2) EMIT(R_type(0b1010000, frs2, frs1, 0b010, rd, 0b1010011))
+#define FLTS(rd, frs1, frs2) EMIT(R_type(0b1010000, frs2, frs1, 0b001, rd, 0b1010011))
+#define FLES(rd, frs1, frs2) EMIT(R_type(0b1010000, frs2, frs1, 0b000, rd, 0b1010011))
+
+// RV64F
+// Convert from signed 64bits to Single
+#define FCVTSL(frd, rs1, rm) EMIT(R_type(0b1101000, 0b00010, rs1, rm, frd, 0b1010011))
+// Convert from unsigned 64bits to Single
+#define FCVTSLU(frd, rs1, rm) EMIT(R_type(0b1101000, 0b00011, rs1, rm, frd, 0b1010011))
+// Convert from Single to signed 64bits
+#define FCVTLS(rd, frs1, rm) EMIT(R_type(0b1100000, 0b00010, frs1, rm, rd, 0b1010011))
+// Convert from Single to unsigned 64bits
+#define FCVTLUS(rd, frs1, rm) EMIT(R_type(0b1100000, 0b00011, frs1, rm, rd, 0b1010011))
+// onvert from Single to signed 32/64bits (trucated)
+#define FCVTSxw(rd, frs1, rm) EMIT(R_type(0b1100000, rex.w?0b00010:0b00000, frs1, rm, rd, 0b1010011))
+
+// RV32D
+// load double precision from rs1+imm12 to frd
+#define FLD(frd, rs1, imm12) EMIT(I_type(imm12, rs1, 0b011, frd, 0b0000111))
+// store double precision frs2 to rs1+imm12
+#define FSD(frs2, rs1, imm12) EMIT(S_type(imm12, frs2, rs1, 0b011, 0b0100111))
+// Convert Double frs1 to Single frd
+#define FCVTSD(frd, frs1) EMIT(R_type(0b0100000, 0b00001, frs1, 0b000, frd, 0b1010011))
+// Convert Single frs1 to Double frd
+#define FCVTDS(frd, frs1) EMIT(R_type(0b0100001, 0b00000, frs1, 0b000, frd, 0b1010011))
+// Convert from Double to signed 32bits
+#define FCVTWD(rd, frs1, rm) EMIT(R_type(0b1100001, 0b00000, frs1, rm, rd, 0b1010011))
+// Convert from Double to unsigned 32bits
+#define FCVTWUD(rd, frs1, rm) EMIT(R_type(0b1100001, 0b00001, frs1, rm, rd, 0b1010011))
+// store rs1 with rs2 sign bit to rd
+#define FSGNJD(rd, rs1, rs2) EMIT(R_type(0b0010001, rs2, rs1, 0b000, rd, 0b1010011))
+// move rs1 to rd
+#define FMVD(rd, rs1) FSGNJD(rd, rs1, rs1)
+// store rs1 with oposite rs2 sign bit to rd
+#define FSGNJND(rd, rs1, rs2) EMIT(R_type(0b0010001, rs2, rs1, 0b001, rd, 0b1010011))
+// -rs1 => rd
+#define FNEGD(rd, rs1) FSGNJND(rd, rs1, rs1)
+// store rs1 with rs1^rs2 sign bit to rd
+#define FSGNJXD(rd, rs1, rs2) EMIT(R_type(0b0010001, rs2, rs1, 0b010, rd, 0b1010011))
+// |rs1| => rd
+#define FABSD(rd, rs1) FSGNJXD(rd, rs1, rs1)
+// Convert from signed 32bits to Double
+#define FCVTDW(frd, rs1, rm) EMIT(R_type(0b1101001, 0b00000, rs1, rm, frd, 0b1010011))
+
+#define FEQD(rd, frs1, frs2) EMIT(R_type(0b1010001, frs2, frs1, 0b010, rd, 0b1010011))
+#define FLTD(rd, frs1, frs2) EMIT(R_type(0b1010001, frs2, frs1, 0b001, rd, 0b1010011))
+#define FLED(rd, frs1, frs2) EMIT(R_type(0b1010001, frs2, frs1, 0b000, rd, 0b1010011))
+
+#define FADDD(frd, frs1, frs2) EMIT(R_type(0b0000001, frs2, frs1, 0b000, frd, 0b1010011))
+#define FSUBD(frd, frs1, frs2) EMIT(R_type(0b0000101, frs2, frs1, 0b000, frd, 0b1010011))
+#define FMULD(frd, frs1, frs2) EMIT(R_type(0b0001001, frs2, frs1, 0b000, frd, 0b1010011))
+#define FDIVD(frd, frs1, frs2) EMIT(R_type(0b0001101, frs2, frs1, 0b000, frd, 0b1010011))
+#define FSQRTD(frd, frs1) EMIT(R_type(0b0101101, 0b00000, frs1, 0b000, frd, 0b1010011))
+#define FMIND(frd, frs1, frs2) EMIT(R_type(0b0010101, frs2, frs1, 0b000, frd, 0b1010011))
+#define FMAXD(frd, frs1, frs2) EMIT(R_type(0b0010101, frs2, frs1, 0b001, frd, 0b1010011))
+
+//RV64D
+// Move from Double
+#define FMVXD(rd, frs1) EMIT(R_type(0b1110001, 0b00000, frs1, 0b000, rd, 0b1010011))
+// Move to Double
+#define FMVDX(frd, rs1) EMIT(R_type(0b1111001, 0b00000, rs1, 0b000, frd, 0b1010011))
+// Convert from signed 64bits to Double
+#define FCVTDL(frd, rs1, rm) EMIT(R_type(0b1101001, 0b00010, rs1, rm, frd, 0b1010011))
+// Convert from unsigned 64bits to Double
+#define FCVTDLU(frd, rs1, rm) EMIT(R_type(0b1101001, 0b00011, rs1, rm, frd, 0b1010011))
+// Convert from Double to signed 64bits
+#define FCVTLD(rd, frs1, rm) EMIT(R_type(0b1100001, 0b00010, frs1, rm, rd, 0b1010011))
+// Convert from Double to unsigned 64bits
+#define FCVTLUD(rd, frs1, rm) EMIT(R_type(0b1100001, 0b00011, frs1, rm, rd, 0b1010011))
+
+// Convert from Double to signed integer
+#define FCVTLDxw(rd, frs1, rm) EMIT(R_type(0b1100001, 0b00000+(rex.w?0b10:0b00), frs1, rm, rd, 0b1010011))
+// Convert from Double to unsigned integer
+#define FCVTLUDxw(rd, frs1, rm) EMIT(R_type(0b1100001, 0b00001+(rex.w?0b10:0b00), frs1, rm, rd, 0b1010011))
+
+//Zba
+// Add unsigned word (Wz(rs1) + X(rs2))
+#define ADDUW(rd, rs1, rs2) EMIT(R_type(0b0000100, rs2, rs1, 0b000, rd, 0b0111011))
+// Zero-extend Word
+#define ZEXTW(rd, rs1) ADDUW(rd, rs1, xZR)
+// Shift left by 1 and add (rd = X(rs2) + X(rs1)<<1)
+#define SH1ADD(rd, rs1, rs2) EMIT(R_type(0b0010000, rs2, rs1, 0b010, rd, 0b0110011))
+// Shift unsigned word left by 1 and add (rd = X(rs2) + Wz(rs1)<<1)
+#define SH1ADDUW(rd, rs1, rs2) EMIT(R_type(0b0010000, rs2, rs1, 0b010, rd, 0b0111011))
+// Shift left by 2 and add (rd = X(rs2) + X(rs1)<<2)
+#define SH2ADD(rd, rs1, rs2) EMIT(R_type(0b0010000, rs2, rs1, 0b100, rd, 0b0110011))
+// Shift unsigned word left by 2 and add (rd = X(rs2) + Wz(rs1)<<2)
+#define SH2ADDUW(rd, rs1, rs2) EMIT(R_type(0b0010000, rs2, rs1, 0b100, rd, 0b0111011))
+// Shift left by 3 and add (rd = X(rs2) + X(rs1)<<3)
+#define SH3ADD(rd, rs1, rs2) EMIT(R_type(0b0010000, rs2, rs1, 0b110, rd, 0b0110011))
+// Shift unsigned word left by 3 and add (rd = X(rs2) + Wz(rs1)<<3)
+#define SH3ADDUW(rd, rs1, rs2) EMIT(R_type(0b0010000, rs2, rs1, 0b110, rd, 0b0111011))
+// Shift left unsigned word (immediate)
+#define SLLIUW(rd, rs1, imm) EMIT(R_type(0b0000100, imm, rs1, 0b001, rd, 0b0011011))
+// Shift left by 1,2 or 3 and add (rd = X(rs2) + X(rs1)<<x)
+#define SHxADD(rd, rs1, x, rs2) EMIT(R_type(0b0010000, rs2, rs1, (x)<<1, rd, 0b0110011))
+// Shift unsigned word left by 1,2 or 3 and add (rd = X(rs2) + Wz(rs1)<<x)
+#define SHxADDUW(rd, rs1, x, rs2) EMIT(R_type(0b0010000, rs2, rs1, (x)<<1, rd, 0b0111011))
+
+//Zbb
+// AND with reverted operand (rs1 & ~rs2)
+#define ANDN(rd, rs1, rs2) EMIT(R_type(0b0100000, rs2, rs1, 0b111, rd, 0b0110011))
+// OR with reverted operand (rs1 | ~rs2)
+#define ORN(rd, rs1, rs2) EMIT(R_type(0b0100000, rs2, rs1, 0b110, rd, 0b0110011))
+// Exclusive NOR (~(rs1 ^ rs2))
+#define XNOR(rd, rs1, rs2) EMIT(R_type(0b0100000, rs2, rs1, 0b100, rd, 0b0110011))
+// Count leading zero bits
+#define CLZ(rd, rs) EMIT(R_type(0b0110000, 0b00000, rs, 0b001, rd, 0b0010011))
+// Count leading zero bits in word
+#define CLZW(rd, rs) EMIT(R_type(0b0110000, 0b00000, rs, 0b001, rd, 0b0011011))
+// Count leading zero bits
+#define CLZxw(rd, rs) EMIT(R_type(0b0110000, 0b00000, rs, 0b001, rd, rex.w?0b0010011:0b0011011))
+// Count trailing zero bits
+#define CTZ(rd, rs) EMIT(R_type(0b0110000, 0b00001, rs, 0b001, rd, 0b0010011))
+// Count trailing zero bits in word
+#define CTZW(rd, rs) EMIT(R_type(0b0110000, 0b00001, rs, 0b001, rd, 0b0011011))
+// Count trailing zero bits
+#define CTZxw(rd, rs) EMIT(R_type(0b0110000, 0b00001, rs, 0b001, rd, rex.w?0b0010011:0b0011011))
+// Count set bits
+#define CPOP(rd, rs) EMIT(R_type(0b0110000, 0b00010, rs, 0b001, rd, 0b0010011))
+// Count set bits in word
+#define CPOPW(rd, rs) EMIT(R_type(0b0110000, 0b00010, rs, 0b001, rd, 0b0011011))
+// Count set bits
+#define CPOPxw(rd, rs) EMIT(R_type(0b0110000, 0b00010, rs, 0b001, rd, rex.w?0b0010011:0b0011011))
+// Maximum
+#define MAX(rd, rs1, rs2) EMIT(R_type(0b0000101, rs2, rs1, 0b110, rd, 0b0110011))
+// Unisgned maximum
+#define MAXU(rd, rs1, rs2) EMIT(R_type(0b0000101, rs2, rs1, 0b111, rd, 0b0110011))
+// Minimum
+#define MIN(rd, rs1, rs2) EMIT(R_type(0b0000101, rs2, rs1, 0b100, rd, 0b0110011))
+// Unsigned minimum
+#define MINU(rd, rs1, rs2) EMIT(R_type(0b0000101, rs2, rs1, 0b101, rd, 0b0110011))
+// Sign-extend byte
+#define SEXTB(rd, rs) EMIT(R_type(0b0110000, 0b00100, rs, 0b001, rd, 0b0010011))
+// Sign-extend half-word
+#define SEXTH(rd, rs) EMIT(R_type(0b0110000, 0b00101, rs, 0b001, rd, 0b0010011))
+// Zero-extend half-word
+#define ZEXTH_(rd, rs) EMIT(R_type(0b0000100, 0b00000, rs, 0b100, rd, 0b0111011))
+// Zero-extend half-word
+#define ZEXTH(rd, rs) if(rv64_zbb) ZEXTH_(rd, rs); else {SLLI(rd, rs, 48); SRLI(rd, rd, 48);}
+// Rotate left (register)
+#define ROL(rd, rs1, rs2) EMIT(R_type(0b0110000, rs2, rs1, 0b001, rd, 0b0110011))
+// Rotate left word (register)
+#define ROLW(rd, rs1, rs2) EMIT(R_type(0b0110000, rs2, rs1, 0b001, rd, 0b0111011))
+// Rotate left (register)
+#define ROLxw(rd, rs1, rs2) EMIT(R_type(0b0110000, rs2, rs1, 0b001, rd, rex.w?0b0110011:0b0111011))
+// Rotate right (register)
+#define ROR(rd, rs1, rs2) EMIT(R_type(0b0110000, rs2, rs1, 0b101, rd, 0b0110011))
+// Rotate right (immediate)
+#define RORI(rd, rs1, shamt) EMIT(R_type(0b0110000, shamt, rs1, 0b101, rd, 0b0010011))
+// Rotate right word (immediate)
+#define RORIW(rd, rs1, shamt) EMIT(R_type(0b0110000, shamt, rs1, 0b101, rd, 0b0011011))
+// Rotate right (immediate)
+#define RORIxw(rd, rs1, shamt) EMIT(R_type(0b0110000, shamt, rs1, 0b101, rd, rex.w?0b0010011:0b0011011))
+// Rotate right word (register)
+#define RORW(rd, rs1, rs2) EMIT(R_type(0b0110000, rs2, rs1, 0b101, rd, 0b0111011))
+// Rotate right (register)
+#define RORxw(rd, rs1, rs2) EMIT(R_type(0b0110000, rs2, rs1, 0b101, rd, rex.w?0b0110011:0b0111011))
+// Bitwise OR Combine, byte granule (for all byte, if byte==0, res.byte=0, else res.byte=0xff)
+#define ORCB(rd, rs) EMIT(I_type(0b001010000111, rs, 0b101, rd, 0b0010011))
+// Byte-reverse register
+#define REV8(rd, rs) EMIT(I_type(0b011010111000, rs, 0b101, rd, 0b0010011))
+
+//Zbc
+// Carry-less multily (low-part)
+#define CLMUL(rd, rs1, rs2) EMIT(R_type(0b0000101, rs2, rs1, 0b001, rd, 0b0110011))
+// Carry-less multiply (high-part)
+#define CLMULH(rd, rs1, rs2) EMIT(R_type(0b0000101, rs2, rs1, 0b011, rd, 0b0110011))
+// Carry-less multiply (reversed)
+#define CLMULR(rd, rs1, rs2) EMIT(R_type(0b0000101, rs2, rs1, 0b010, rd, 0b0110011))
+
+//Zbs
+// encoding of the "imm" on RV64 use a slight different mask, but it will work using R_type with high bit of imm ovewriting low bit op func
+// Single-bit Clear (Register)
+#define BCLR(rd, rs1, rs2) EMIT(R_type(0b0100100, rs2, rs1, 0b001, rd, 0b0110011))
+// Single-bit Clear (Immediate)
+#define BCLI(rd, rs1, imm) EMIT(R_type(0b0100100, imm, rs1, 0b001, rd, 0b0010011))
+// Single-bit Extreact (Register)
+#define BEXT(rd, rs1, rs2) EMIT(R_type(0b0100100, rs2, rs1, 0b101, rd, 0b0110011))
+// Single-bit Extract (Immediate)
+#define BEXTI(rd, rs1, imm) EMIT(R_type(0b0100100, imm, rs1, 0b101, rd, 0b0010011))
+// Single-bit Invert (Register)
+#define BINV(rd, rs1, rs2) EMIT(R_type(0b0110100, rs2, rs1, 0b001, rd, 0b0110011))
+// Single-bit Invert (Immediate)
+#define BINVI(rd, rs1, imm) EMIT(R_type(0b0110100, imm, rs1, 0b001, rd, 0b0010011))
+// Single-bit Set (Register)
+#define BSET(rd, rs1, rs2) EMIT(R_type(0b0010100, rs2, rs1, 0b001, rd, 0b0110011))
+// Single-bit Set (Immediate)
+#define BSETI(rd, rs1, imm) EMIT(R_type(0b0010100, imm, rs1, 0b001, rd, 0b0010011))
+
+
+#endif //__RV64_EMITTER_H__
diff --git a/src/dynarec/rv64/rv64_epilog.S b/src/dynarec/rv64/rv64_epilog.S
new file mode 100644
index 0000000..17dc117
--- /dev/null
+++ b/src/dynarec/rv64/rv64_epilog.S
@@ -0,0 +1,65 @@
+//riscv epilog for dynarec
+//Save stuff, prepare stack and register
+//called with pointer to emu as 1st parameter
+//and address to jump to as 2nd parameter
+
+.text
+.align 4
+
+.global rv64_epilog
+.global rv64_epilog_fast
+
+rv64_epilog:
+ //update register -> emu
+ sd x16, (a0)
+ sd x17, 8(a0)
+ sd x18, 16(a0)
+ sd x19, 24(a0)
+ sd x20, 32(a0)
+ sd x21, 40(a0)
+ sd x22, 48(a0)
+ sd x23, 56(a0)
+ sd x24, 64(a0)
+ sd x25, 72(a0)
+ sd x26, 80(a0)
+ sd x27, 88(a0)
+ sd x28, 96(a0)
+ sd x29, 104(a0)
+ sd x30, 112(a0)
+ sd x31, 120(a0)
+ // adjust flags bit 5 -> bit 11
+ li x5, ~(1<<11)
+ and x8, x8, x5
+ andi x5, x8, 1<<5
+ slli x5, x5, 11-5
+ or x8, x8, x5
+ sd x8, 128(a0) //xFlags
+ sd x7, 136(a0) // put back reg value in emu, including EIP (so x7 must be EIP now)
+ // fallback to epilog_fast now, just restoring saved regs
+rv64_epilog_fast:
+ ld ra, (sp) // save ra
+ ld x8, 8(sp) // save fp
+ ld x18, (2*8)(sp)
+ ld x19, (3*8)(sp)
+ ld x20, (4*8)(sp)
+ ld x21, (5*8)(sp)
+ ld x22, (6*8)(sp)
+ ld x23, (7*8)(sp)
+ ld x24, (8*8)(sp)
+ ld x25, (9*8)(sp)
+ ld x26, (10*8)(sp)
+ ld x27, (11*8)(sp)
+ ld x9, (12*8)(sp)
+ fld f18, (13*8)(sp)
+ fld f19, (14*8)(sp)
+ fld f20, (15*8)(sp)
+ fld f21, (16*8)(sp)
+ fld f22, (17*8)(sp)
+ fld f23, (19*8)(sp)
+ fld f24, (19*8)(sp)
+ fld f25, (20*8)(sp)
+ fld f26, (21*8)(sp)
+ fld f27, (22*8)(sp)
+ addi sp, sp, (8 * 24)
+ //end, return...
+ ret
diff --git a/src/dynarec/rv64/rv64_lock.S b/src/dynarec/rv64/rv64_lock.S
new file mode 100644
index 0000000..d6ea9c4
--- /dev/null
+++ b/src/dynarec/rv64/rv64_lock.S
@@ -0,0 +1,232 @@
+// RV64 lock helper
+// there is 2 part: read and write
+// write return 0 on success, 1 on fail (value has been changed)
+
+.text
+.align 4
+
+.global rv64_lock_xchg_dd
+.global rv64_lock_xchg_d
+.global rv64_lock_storeifnull
+.global rv64_lock_storeifnull_d
+.global rv64_lock_storeifref
+.global rv64_lock_storeifref_d
+.global rv64_lock_storeifref2_d
+.global rv64_lock_decifnot0b
+.global rv64_lock_storeb
+.global rv64_lock_incif0
+.global rv64_lock_decifnot0
+.global rv64_lock_store
+.global rv64_lock_cas_d
+.global rv64_lock_cas_dd
+.global rv64_lock_cas_dq
+
+rv64_lock_xchg_dd:
+ // address is a0, value is a1, return old value in a0
+ amoswap.d.aqrl a0, a1, (a0)
+ ret
+
+rv64_lock_xchg_d:
+ // address is a0, value is a1, return old value in a0
+ amoswap.w.aqrl a0, a1, (a0)
+ ret
+
+rv64_lock_storeifnull:
+ // address is a0, value is a1, a1 store to a0 only if [a0] is 0. return old [a0] value
+ fence rw, rw
+1:
+ lr.d a2, (a0)
+ bnez a2, 2f
+ sc.d a3, a1, (a0)
+ bnez a3, 1b
+2:
+ mv a0, a2
+ ret
+
+rv64_lock_storeifnull_d:
+ // address is a0, value is a1, a1 store to a0 only if [a0] is 0. return old [a0] value
+ fence rw, rw
+1:
+ lr.w a2, (a0)
+ bnez a2, 2f
+ sc.w a3, a1, (a0)
+ bnez a3, 1b
+2:
+ mv a0, a2
+ ret
+
+rv64_lock_storeifref:
+ // address is a0, value is a1, a1 store to a0 only if [a0] is a2. return new [a0] value (so a1 or old value)
+ fence rw, rw
+1:
+ lr.d a3, (a0)
+ bne a2, a3, 2f
+ sc.d a4, a1, (a0)
+ bnez a4, 1b
+ fence rw, rw
+ mv a0, a1
+ ret
+2:
+ fence rw, rw
+ mv a0, a3
+ ret
+
+rv64_lock_storeifref_d:
+ // address is a0, value is a1, a1 store to a0 only if [a0] is a2. return new [a0] value (so a1 or old value)
+ fence rw, rw
+1:
+ lr.w a3, (a0)
+ bne a2, a3, 2f
+ sc.w a4, a1, (a0)
+ bnez a4, 1b
+ mv a0, a1
+ ret
+2:
+ mv a0, a3
+ ret
+
+rv64_lock_storeifref2_d:
+ // address is a0, value is a1, a1 store to a0 only if [a0] is a2. return old [a0] value
+ fence rw, rw
+1:
+ lr.w a3, (a0)
+ bne a2, a3, 2f
+ sc.w a4, a1, (a0)
+ bnez a4, 1b
+2:
+ mv a0, a3
+ ret
+
+rv64_lock_decifnot0b:
+ fence rw, rw
+ andi a3, a0, 3
+ andi a0, a0, ~3
+ slli a3, a3, 1 //TODO: make a jump table less hacky!
+ la a4, table
+ add a4, a4, a3
+ jr a4, 10
+table:
+ j 1f
+ j rv64_lock_decifnot0b_1 // all those are compressed
+ j rv64_lock_decifnot0b_2
+ j rv64_lock_decifnot0b_3
+1:
+ lr.w a1, (a0)
+ andi a3, a1, 0xff
+ beqz a3, 2f
+ addi a3, a3, -1
+ andi a1, a1, ~0xff
+ or a1, a1, a3
+ sc.w a2, a1, (a0)
+ bnez a2, 1b
+2:
+ ret
+rv64_lock_decifnot0b_1:
+ li a4, 0xffff00ff
+1:
+ lr.w a1, (a0)
+ srli a3, a1, 8
+ andi a3, a3, 0xff
+ beqz a3, 2f
+ addi a3, a3, -1
+ and a1, a1, a4
+ slli a3, a3, 8
+ or a1, a1, a3
+ sc.w a2, a1, (a0)
+ bnez a2, 1b
+2:
+ ret
+rv64_lock_decifnot0b_2:
+ li a4, 0xff00ffff
+1:
+ lr.w a1, (a0)
+ srli a3, a1, 16
+ andi a3, a3, 0xff
+ beqz a3, 2f
+ addi a3, a3, -1
+ and a1, a1, a4
+ slli a3, a3, 16
+ or a1, a1, a3
+ sc.w a2, a1, (a0)
+ bnez a2, 1b
+2:
+ ret
+rv64_lock_decifnot0b_3:
+ li a4, 0x00ffffff
+1:
+ lr.w a1, (a0)
+ srli a3, a1, 24
+ andi a3, a3, 0xff
+ beqz a3, 2f
+ addi a3, a3, -1
+ and a1, a1, a4
+ slli a3, a3, 24
+ or a1, a1, a3
+ sc.w a2, a1, (a0)
+ bnez a2, 1b
+2:
+ ret
+
+
+rv64_lock_storeb:
+ sb a1, 0(a0)
+ fence rw, rw
+ ret
+
+rv64_lock_decifnot0:
+ fence rw, rw
+1:
+ lr.w a1, (a0)
+ beqz a1, 2f
+ addi a1, a1, -1
+ sc.w a2, a1, (a0)
+ bnez a2, 1b
+2:
+ mv a0, a1
+ ret
+
+rv64_lock_incif0:
+ fence rw, rw
+1:
+ lr.w a1, (a0)
+ bnez a1, 2f
+ addi a1, a1, 1
+ sc.w a2, a1, (a0)
+ bnez a2, 1b
+2:
+ mv a0, a1
+ ret
+
+rv64_lock_store:
+ sw a1, 0(a0)
+ fence rw, rw
+ ret
+
+rv64_lock_cas_d:
+ lr.w t0, (a0)
+ bne t0, a1, 1f
+ sc.w a0, a2, (a0)
+ ret
+1:
+ li a0, 1
+ ret
+
+rv64_lock_cas_dd:
+ lr.d t0, (a0)
+ bne t0, a1, 1f
+ sc.d a0, a2, (a0)
+ ret
+1:
+ li a0, 1
+ ret
+
+rv64_lock_cas_dq:
+ mv a4, a0
+ lr.d t0, (a0)
+ bne t0, a1, 1f
+ sc.d a0, a2, (a0)
+ sd a3,(a4)
+ ret
+1:
+ li a0, 1
+ ret \ No newline at end of file
diff --git a/src/dynarec/rv64/rv64_lock.h b/src/dynarec/rv64/rv64_lock.h
new file mode 100644
index 0000000..33ce09a
--- /dev/null
+++ b/src/dynarec/rv64/rv64_lock.h
@@ -0,0 +1,60 @@
+#ifndef __RV64_LOCK__H__
+#define __RV64_LOCK__H__
+#include <stdint.h>
+
+// Atomically store val at [p] if old [p] is ref. Return 0 if OK, 1 is not. p needs to be aligned
+extern int rv64_lock_cas_d(void* p, int32_t ref, int32_t val);
+
+// Atomically store val at [p] if old [p] is ref. Return 0 if OK, 1 is not. p needs to be aligned
+extern int rv64_lock_cas_dd(void* p, int64_t ref, int64_t val);
+
+// Atomically exchange value at [p] with val, return old p
+extern uintptr_t rv64_lock_xchg_dd(void* p, uintptr_t val);
+
+// Atomically exchange value at [p] with val, return old p
+extern uint32_t rv64_lock_xchg_d(void* p, uint32_t val);
+
+// Atomically store value to [p] only if [p] is NULL. Return old [p] value
+extern uint32_t rv64_lock_storeifnull_d(void*p, uint32_t val);
+
+// Atomically store value to [p] only if [p] is NULL. Return old [p] value
+extern void* rv64_lock_storeifnull(void*p, void* val);
+
+// Atomically store value to [p] only if [p] is ref. Return new [p] value (so val or old)
+extern void* rv64_lock_storeifref(void*p, void* val, void* ref);
+
+// Atomically store value to [p] only if [p] is ref. Return new [p] value (so val or old)
+extern uint32_t rv64_lock_storeifref_d(void*p, uint32_t val, uint32_t ref);
+
+// Atomically store value to [p] only if [p] is ref. Return new [p] value (so val or old)
+extern uint32_t rv64_lock_storeifref2_d(void*p, uint32_t val, uint32_t ref);
+
+// decrement atomically the byte at [p] (but only if p not 0)
+extern void rv64_lock_decifnot0b(void*p);
+
+// atomic store (with memory barrier)
+extern void rv64_lock_storeb(void*p, uint8_t b);
+
+// increment atomically the int at [p] only if it was 0. Return the old value of [p]
+extern int rv64_lock_incif0(void*p);
+
+// decrement atomically the int at [p] (but only if p not 0)
+extern int rv64_lock_decifnot0(void*p);
+
+// atomic store (with memory barrier)
+extern void rv64_lock_store(void*p, uint32_t v);
+
+// (mostly) Atomically store val1 and val2 at [p] if old [p] is ref. Return 0 if OK, 1 is not. p needs to be aligned
+extern int rv64_lock_cas_dq(void* p, uint64_t ref, uint64_t val1, uint64_t val2);
+
+// Not defined in assembler but in dynarec_rv64_functions
+uint8_t extract_byte(uint32_t val, void* address);
+uint32_t insert_byte(uint32_t val, uint8_t b, void* address);
+uint16_t extract_half(uint32_t val, void* address);
+uint32_t insert_half(uint32_t val, uint16_t h, void* address);
+
+uint8_t rv64_lock_xchg_b(void* addr, uint8_t v);
+extern int rv64_lock_cas_b(void* p, uint8_t ref, uint8_t val);
+extern int rv64_lock_cas_h(void* p, uint16_t ref, uint16_t val);
+
+#endif //__RV64_LOCK__H__
diff --git a/src/dynarec/rv64/rv64_next.S b/src/dynarec/rv64/rv64_next.S
new file mode 100644
index 0000000..ce34bb7
--- /dev/null
+++ b/src/dynarec/rv64/rv64_next.S
@@ -0,0 +1,51 @@
+//riscv update linker table for dynarec
+//called with pointer to emu as 1st parameter
+//and address of table to as 2nd parameter
+//ip is at r12
+
+.text
+.align 4
+
+.extern LinkNext
+
+.global rv64_next
+
+ .8byte 0 // NULL pointer before rv64_next, for getDB
+rv64_next:
+ // emu is a0
+ // IP address is a1
+ addi sp, sp, -(8 * 10)
+ sd a0, (sp)
+ sd a1, 8(sp)
+ sd x5, 16(sp)
+ sd x7, 24(sp)
+ sd x16, 32(sp)
+ sd x17, 40(sp)
+ sd x28, 48(sp)
+ sd x29, 56(sp)
+ sd x30, 64(sp)
+ sd x31, 72(sp)
+
+ mv a2, ra // "from" is in ra, so put in a2
+ addi a3, sp, 24 // a3 is address to change rip
+ // call the function
+1:
+ auipc a4, %pcrel_hi(LinkNext)
+ jalr a4, %pcrel_lo(1b)
+ // preserve return value
+ mv a3, a0
+ // pop regs
+ ld a0, (sp)
+ ld a1, 8(sp)
+ ld x5, 16(sp)
+ ld x7, 24(sp)
+ ld x16, 32(sp)
+ ld x17, 40(sp)
+ ld x28, 48(sp)
+ ld x29, 56(sp)
+ ld x30, 64(sp)
+ ld x31, 72(sp)
+ addi sp, sp, (8 * 10)
+ // return offset is jump address
+ jr a3
+
diff --git a/src/dynarec/rv64/rv64_printer.c b/src/dynarec/rv64/rv64_printer.c
new file mode 100644
index 0000000..db013c3
--- /dev/null
+++ b/src/dynarec/rv64/rv64_printer.c
@@ -0,0 +1,1450 @@
+#include <assert.h>
+#include <stddef.h>
+#include <string.h>
+#include <stdio.h>
+#include <inttypes.h>
+
+#include "rv64_printer.h"
+#include "debug.h"
+
+typedef struct {
+ int8_t rd;
+ int8_t rs1;
+ int8_t rs2;
+ int8_t rs3;
+ int32_t imm;
+ uint16_t csr;
+ char *name;
+ bool rvc;
+ bool f;
+} insn_t;
+
+static const char gpnames[32][9] = {
+ "zero", "ra", "sp", "gp", "tp", "t0_mask", "t1", "t2_rip",
+ "s0_flags", "s1", "a0", "a1", "a2", "a3", "a4", "a5",
+ "a6_rax", "a7_rcx", "s2_rdx", "s3_rbx", "s4_rsp", "s5_rbp", "s6_rsi", "s7_rdi",
+ "s8_r8", "s9_r9", "s10_r10", "s11_r11", "t3_r12", "t4_r13", "t5_r14", "t6_r15",
+};
+
+static const char fpnames[32][5] = {
+ "ft0", "ft1", "ft2", "ft3", "ft4", "ft5", "ft6", "ft7",
+ "fs0", "fs1", "fa0", "fa1", "fa2", "fa3", "fa4", "fa5",
+ "fa6", "fa7", "fs2", "fs3", "fs4", "fs5", "fs6", "fs7",
+ "fs8", "fs9", "fs10", "fs11", "ft8", "ft9", "ft10", "ft11",
+};
+
+#define QUADRANT(data) (((data) >> 0) & 0x3 )
+
+/**
+ * normal types
+*/
+#define OPCODE(data) (((data) >> 2) & 0x1f)
+#define RD(data) (((data) >> 7) & 0x1f)
+#define RS1(data) (((data) >> 15) & 0x1f)
+#define RS2(data) (((data) >> 20) & 0x1f)
+#define RS3(data) (((data) >> 27) & 0x1f)
+#define FUNCT2(data) (((data) >> 25) & 0x3 )
+#define FUNCT3(data) (((data) >> 12) & 0x7 )
+#define FUNCT7(data) (((data) >> 25) & 0x7f)
+#define IMM116(data) (((data) >> 26) & 0x3f)
+#define AQ(data) (((data) >> 26) & 0x1)
+#define RL(data) (((data) >> 25) & 0x1)
+
+static inline insn_t insn_utype_read(uint32_t data)
+{
+ return (insn_t) {
+ .imm = (int32_t)data & 0xfffff000,
+ .rd = RD(data),
+ };
+}
+
+static inline insn_t insn_itype_read(uint32_t data)
+{
+ return (insn_t) {
+ .imm = (int32_t)data >> 20,
+ .rs1 = RS1(data),
+ .rd = RD(data),
+ };
+}
+
+static inline insn_t insn_jtype_read(uint32_t data)
+{
+ uint32_t imm20 = (data >> 31) & 0x1;
+ uint32_t imm101 = (data >> 21) & 0x3ff;
+ uint32_t imm11 = (data >> 20) & 0x1;
+ uint32_t imm1912 = (data >> 12) & 0xff;
+
+ int32_t imm = (imm20 << 20) | (imm1912 << 12) | (imm11 << 11) | (imm101 << 1);
+ imm = (imm << 11) >> 11;
+
+ return (insn_t) {
+ .imm = imm,
+ .rd = RD(data),
+ };
+}
+
+static inline insn_t insn_btype_read(uint32_t data)
+{
+ uint32_t imm12 = (data >> 31) & 0x1;
+ uint32_t imm105 = (data >> 25) & 0x3f;
+ uint32_t imm41 = (data >> 8) & 0xf;
+ uint32_t imm11 = (data >> 7) & 0x1;
+
+ int32_t imm = (imm12 << 12) | (imm11 << 11) |(imm105 << 5) | (imm41 << 1);
+ imm = (imm << 19) >> 19;
+
+ return (insn_t) {
+ .imm = imm,
+ .rs1 = RS1(data),
+ .rs2 = RS2(data),
+ };
+}
+
+static inline insn_t insn_rtype_read(uint32_t data)
+{
+ return (insn_t) {
+ .rs1 = RS1(data),
+ .rs2 = RS2(data),
+ .rd = RD(data),
+ };
+}
+
+static inline insn_t insn_stype_read(uint32_t data)
+{
+ uint32_t imm115 = (data >> 25) & 0x7f;
+ uint32_t imm40 = (data >> 7) & 0x1f;
+
+ int32_t imm = (imm115 << 5) | imm40;
+ imm = (imm << 20) >> 20;
+ return (insn_t) {
+ .imm = imm,
+ .rs1 = RS1(data),
+ .rs2 = RS2(data),
+ };
+}
+
+static inline insn_t insn_csrtype_read(uint32_t data)
+{
+ return (insn_t) {
+ .csr = data >> 20,
+ .rs1 = RS1(data),
+ .rd = RD(data),
+ };
+}
+
+static inline insn_t insn_fprtype_read(uint32_t data)
+{
+ return (insn_t) {
+ .rs1 = RS1(data),
+ .rs2 = RS2(data),
+ .rs3 = RS3(data),
+ .rd = RD(data),
+ };
+}
+
+/**
+ * compressed types
+*/
+#define COPCODE(data) (((data) >> 13) & 0x7 )
+#define CFUNCT1(data) (((data) >> 12) & 0x1 )
+#define CFUNCT2LOW(data) (((data) >> 5) & 0x3 )
+#define CFUNCT2HIGH(data) (((data) >> 10) & 0x3 )
+#define RP1(data) (((data) >> 7) & 0x7 )
+#define RP2(data) (((data) >> 2) & 0x7 )
+#define RC1(data) (((data) >> 7) & 0x1f)
+#define RC2(data) (((data) >> 2) & 0x1f)
+
+static inline insn_t insn_catype_read(uint16_t data)
+{
+ return (insn_t) {
+ .rd = RP1(data) + 8,
+ .rs2 = RP2(data) + 8,
+ .rvc = true,
+ };
+}
+
+static inline insn_t insn_crtype_read(uint16_t data)
+{
+ return (insn_t) {
+ .rs1 = RC1(data),
+ .rs2 = RC2(data),
+ .rvc = true,
+ };
+}
+
+static inline insn_t insn_citype_read(uint16_t data)
+{
+ uint32_t imm40 = (data >> 2) & 0x1f;
+ uint32_t imm5 = (data >> 12) & 0x1;
+ int32_t imm = (imm5 << 5) | imm40;
+ imm = (imm << 26) >> 26;
+
+ return (insn_t) {
+ .imm = imm,
+ .rd = RC1(data),
+ .rvc = true,
+ };
+}
+
+static inline insn_t insn_citype_read2(uint16_t data)
+{
+ uint32_t imm86 = (data >> 2) & 0x7;
+ uint32_t imm43 = (data >> 5) & 0x3;
+ uint32_t imm5 = (data >> 12) & 0x1;
+
+ int32_t imm = (imm86 << 6) | (imm43 << 3) | (imm5 << 5);
+
+ return (insn_t) {
+ .imm = imm,
+ .rd = RC1(data),
+ .rvc = true,
+ };
+}
+
+static inline insn_t insn_citype_read3(uint16_t data)
+{
+ uint32_t imm5 = (data >> 2) & 0x1;
+ uint32_t imm87 = (data >> 3) & 0x3;
+ uint32_t imm6 = (data >> 5) & 0x1;
+ uint32_t imm4 = (data >> 6) & 0x1;
+ uint32_t imm9 = (data >> 12) & 0x1;
+
+ int32_t imm = (imm5 << 5) | (imm87 << 7) | (imm6 << 6) | (imm4 << 4) | (imm9 << 9);
+ imm = (imm << 22) >> 22;
+
+ return (insn_t) {
+ .imm = imm,
+ .rd = RC1(data),
+ .rvc = true,
+ };
+}
+
+static inline insn_t insn_citype_read4(uint16_t data)
+{
+ uint32_t imm5 = (data >> 12) & 0x1;
+ uint32_t imm42 = (data >> 4) & 0x7;
+ uint32_t imm76 = (data >> 2) & 0x3;
+
+ int32_t imm = (imm5 << 5) | (imm42 << 2) | (imm76 << 6);
+
+ return (insn_t) {
+ .imm = imm,
+ .rd = RC1(data),
+ .rvc = true,
+ };
+}
+
+static inline insn_t insn_citype_read5(uint16_t data)
+{
+ uint32_t imm1612 = (data >> 2) & 0x1f;
+ uint32_t imm17 = (data >> 12) & 0x1;
+
+ int32_t imm = (imm1612 << 12) | (imm17 << 17);
+ imm = (imm << 14) >> 14;
+ return (insn_t) {
+ .imm = imm,
+ .rd = RC1(data),
+ .rvc = true,
+ };
+}
+
+static inline insn_t insn_cbtype_read(uint16_t data)
+{
+ uint32_t imm5 = (data >> 2) & 0x1;
+ uint32_t imm21 = (data >> 3) & 0x3;
+ uint32_t imm76 = (data >> 5) & 0x3;
+ uint32_t imm43 = (data >> 10) & 0x3;
+ uint32_t imm8 = (data >> 12) & 0x1;
+
+ int32_t imm = (imm8 << 8) | (imm76 << 6) | (imm5 << 5) | (imm43 << 3) | (imm21 << 1);
+ imm = (imm << 23) >> 23;
+
+ return (insn_t) {
+ .imm = imm,
+ .rs1 = RP1(data) + 8,
+ .rvc = true,
+ };
+}
+
+static inline insn_t insn_cbtype_read2(uint16_t data)
+{
+ uint32_t imm40 = (data >> 2) & 0x1f;
+ uint32_t imm5 = (data >> 12) & 0x1;
+ int32_t imm = (imm5 << 5) | imm40;
+ imm = (imm << 26) >> 26;
+
+ return (insn_t) {
+ .imm = imm,
+ .rd = RP1(data) + 8,
+ .rvc = true,
+ };
+}
+
+static inline insn_t insn_cstype_read(uint16_t data)
+{
+ uint32_t imm76 = (data >> 5) & 0x3;
+ uint32_t imm53 = (data >> 10) & 0x7;
+
+ int32_t imm = ((imm76 << 6) | (imm53 << 3));
+
+ return (insn_t) {
+ .imm = imm,
+ .rs1 = RP1(data) + 8,
+ .rs2 = RP2(data) + 8,
+ .rvc = true,
+ };
+}
+
+static inline insn_t insn_cstype_read2(uint16_t data)
+{
+ uint32_t imm6 = (data >> 5) & 0x1;
+ uint32_t imm2 = (data >> 6) & 0x1;
+ uint32_t imm53 = (data >> 10) & 0x7;
+
+ int32_t imm = ((imm6 << 6) | (imm2 << 2) | (imm53 << 3));
+
+ return (insn_t) {
+ .imm = imm,
+ .rs1 = RP1(data) + 8,
+ .rs2 = RP2(data) + 8,
+ .rvc = true,
+ };
+}
+
+static inline insn_t insn_cjtype_read(uint16_t data)
+{
+ uint32_t imm5 = (data >> 2) & 0x1;
+ uint32_t imm31 = (data >> 3) & 0x7;
+ uint32_t imm7 = (data >> 6) & 0x1;
+ uint32_t imm6 = (data >> 7) & 0x1;
+ uint32_t imm10 = (data >> 8) & 0x1;
+ uint32_t imm98 = (data >> 9) & 0x3;
+ uint32_t imm4 = (data >> 11) & 0x1;
+ uint32_t imm11 = (data >> 12) & 0x1;
+
+ int32_t imm = ((imm5 << 5) | (imm31 << 1) | (imm7 << 7) | (imm6 << 6) |
+ (imm10 << 10) | (imm98 << 8) | (imm4 << 4) | (imm11 << 11));
+ imm = (imm << 20) >> 20;
+ return (insn_t) {
+ .imm = imm,
+ .rvc = true,
+ };
+}
+
+static inline insn_t insn_cltype_read(uint16_t data)
+{
+ uint32_t imm6 = (data >> 5) & 0x1;
+ uint32_t imm2 = (data >> 6) & 0x1;
+ uint32_t imm53 = (data >> 10) & 0x7;
+
+ int32_t imm = (imm6 << 6) | (imm2 << 2) | (imm53 << 3);
+
+ return (insn_t) {
+ .imm = imm,
+ .rs1 = RP1(data) + 8,
+ .rd = RP2(data) + 8,
+ .rvc = true,
+ };
+}
+
+static inline insn_t insn_cltype_read2(uint16_t data)
+{
+ uint32_t imm76 = (data >> 5) & 0x3;
+ uint32_t imm53 = (data >> 10) & 0x7;
+
+ int32_t imm = (imm76 << 6) | (imm53 << 3);
+
+ return (insn_t) {
+ .imm = imm,
+ .rs1 = RP1(data) + 8,
+ .rd = RP2(data) + 8,
+ .rvc = true,
+ };
+}
+
+static inline insn_t insn_csstype_read(uint16_t data)
+{
+ uint32_t imm86 = (data >> 7) & 0x7;
+ uint32_t imm53 = (data >> 10) & 0x7;
+
+ int32_t imm = (imm86 << 6) | (imm53 << 3);
+
+ return (insn_t) {
+ .imm = imm,
+ .rs2 = RC2(data),
+ .rvc = true,
+ };
+}
+
+static inline insn_t insn_csstype_read2(uint16_t data)
+{
+ uint32_t imm76 = (data >> 7) & 0x3;
+ uint32_t imm52 = (data >> 9) & 0xf;
+
+ int32_t imm = (imm76 << 6) | (imm52 << 2);
+
+ return (insn_t) {
+ .imm = imm,
+ .rs2 = RC2(data),
+ .rvc = true,
+ };
+}
+
+static inline insn_t insn_ciwtype_read(uint16_t data)
+{
+ uint32_t imm3 = (data >> 5) & 0x1;
+ uint32_t imm2 = (data >> 6) & 0x1;
+ uint32_t imm96 = (data >> 7) & 0xf;
+ uint32_t imm54 = (data >> 11) & 0x3;
+
+ int32_t imm = (imm3 << 3) | (imm2 << 2) | (imm96 << 6) | (imm54 << 4);
+
+ return (insn_t) {
+ .imm = imm,
+ .rd = RP2(data) + 8,
+ .rvc = true,
+ };
+}
+
+#define RN(r) insn.f ? fpnames[insn.r] : gpnames[insn.r]
+
+#define PRINT_none() snprintf(buff, sizeof(buff), "%s", insn.name); return buff
+#define PRINT_rd_rs1() snprintf(buff, sizeof(buff), "%s\t%s, %s", insn.name, RN(rd), RN(rs1)); return buff
+#define PRINT_rd_rs1_rs2() snprintf(buff, sizeof(buff), "%s\t%s, %s, %s", insn.name, RN(rd), RN(rs1), RN(rs2)); return buff
+#define PRINT_rd_rs1_rs2_rs3() snprintf(buff, sizeof(buff), "%s\t%s, %s, %s, %s", insn.name, RN(rd), RN(rs1), RN(rs2), RN(rs3)); return buff
+#define PRINT_rd_rs1_imm() snprintf(buff, sizeof(buff), "%s\t%s, %s, %d", insn.name, RN(rd), RN(rs1), insn.imm); return buff
+#define PRINT_rd_rs1_immx() snprintf(buff, sizeof(buff), "%s\t%s, %s, 0x%x", insn.name, RN(rd), RN(rs1), insn.imm); return buff
+#define PRINT_rd_imm_rs1() snprintf(buff, sizeof(buff), "%s\t%s, %d(%s)", insn.name, RN(rd), insn.imm, gpnames[insn.rs1]); return buff
+#define PRINT_rs2_imm_rs1() snprintf(buff, sizeof(buff), "%s\t%s, %d(%s)", insn.name, RN(rs2), insn.imm, gpnames[insn.rs1]); return buff
+#define PRINT_rd_imm() snprintf(buff, sizeof(buff), "%s\t%s, %d", insn.name, RN(rd), insn.imm); return buff
+#define PRINT_rd_imm_rel() snprintf(buff, sizeof(buff), "%s\t%s, pc%+d # 0x%"PRIx64, insn.name, RN(rd), insn.imm, insn.imm+(uint64_t)addr); return buff
+#define PRINT_imm_rel() snprintf(buff, sizeof(buff), "%s\tpc%+d # 0x%"PRIx64, insn.name, insn.imm, insn.imm+(uint64_t)addr); return buff
+#define PRINT_rd_immx() snprintf(buff, sizeof(buff), "%s\t%s, 0x%x", insn.name, RN(rd), insn.imm); return buff
+#define PRINT_rs1_rs2_imm() snprintf(buff, sizeof(buff), "%s\t%s, %s, %d", insn.name, RN(rs1), RN(rs2), insn.imm); return buff
+#define PRINT_rs1_rs2_imm_rel() snprintf(buff, sizeof(buff), "%s\t%s, %s, pc%+d # 0x%"PRIx64, insn.name, RN(rs1), RN(rs2), insn.imm, insn.imm+(uint64_t)addr); return buff
+#define PRINT_fd_fs1() snprintf(buff, sizeof(buff), "%s\t%s, %s", insn.name, fpnames[insn.rd], fpnames[insn.rs1]); return buff
+#define PRINT_xd_fs1() snprintf(buff, sizeof(buff), "%s\t%s, %s", insn.name, gpnames[insn.rd], fpnames[insn.rs1]); return buff
+#define PRINT_fd_xs1() snprintf(buff, sizeof(buff), "%s\t%s, %s", insn.name, fpnames[insn.rd], gpnames[insn.rs1]); return buff
+#define PRINT_rd_fs1_fs2() snprintf(buff, sizeof(buff), "%s\t%s, %s, %s", insn.name, gpnames[insn.rd], RN(rs1), RN(rs2)); return buff
+#define PRINT_rd_rs1_aqrl() snprintf(buff, sizeof(buff), "%s%s%s\t%s, (%s)", insn.name, aq?".aq":"", rl?".rl":"", gpnames[insn.rd], gpnames[insn.rs1]); return buff
+#define PRINT_rd_rs1_rs2_aqrl() snprintf(buff, sizeof(buff), "%s%s%s\t%s, %s, (%s)", insn.name, aq?".aq":"", rl?".rl":"", gpnames[insn.rd], gpnames[insn.rs2], gpnames[insn.rs1]); return buff
+
+// TODO: display csr name
+#define PRINT_rd_csr_rs1() snprintf(buff, sizeof(buff), "%s\t%s, %d, %s", insn.name, RN(rd), insn.csr, RN(rs1)); return buff
+#define PRINT_rd_csr_uimm() snprintf(buff, sizeof(buff), "%s\t%s, %d, %d", insn.name, RN(rd), insn.csr, (uint32_t)insn.imm); return buff
+
+const char* rv64_print(uint32_t data, uintptr_t addr)
+{
+ static char buff[200] = {0};
+
+ insn_t insn = { 0 };
+ uint32_t quadrant = QUADRANT(data);
+ switch (quadrant) {
+ case 0x0: {
+ uint32_t copcode = COPCODE(data);
+
+ switch (copcode) {
+ case 0x0: /* C.ADDI4SPN */
+ insn = insn_ciwtype_read(data);
+ insn.rs1 = 2; /* sp */
+ insn.name = "addi";
+ assert(insn.imm != 0);
+ PRINT_rd_rs1_imm();
+ case 0x1: /* C.FLD */
+ insn = insn_cltype_read2(data);
+ insn.name = "fld";
+ insn.f = true;
+ PRINT_rd_imm_rs1();
+ case 0x2: /* C.LW */
+ insn = insn_cltype_read(data);
+ insn.name = "lw";
+ PRINT_rd_imm_rs1();
+ case 0x3: /* C.LD */
+ insn = insn_cltype_read2(data);
+ insn.name = "ld";
+ PRINT_rd_imm_rs1();
+ case 0x5: /* C.FSD */
+ insn = insn_cstype_read(data);
+ insn.name = "fsd";
+ insn.f = true;
+ PRINT_rs2_imm_rs1();
+ case 0x6: /* C.SW */
+ insn = insn_cstype_read2(data);
+ insn.name = "sw";
+ PRINT_rd_imm_rs1();
+ case 0x7: /* C.SD */
+ insn = insn_cstype_read(data);
+ insn.name = "sd";
+ PRINT_rs2_imm_rs1();
+ }
+ }
+ case 0x1: {
+ uint32_t copcode = COPCODE(data);
+
+ switch (copcode) {
+ case 0x0: /* C.ADDI */
+ insn = insn_citype_read(data);
+ insn.rs1 = insn.rd;
+ insn.name = "addi";
+ PRINT_rd_rs1_imm();
+ case 0x1: /* C.ADDIW */
+ insn = insn_citype_read(data);
+ assert(insn.rd != 0);
+ insn.rs1 = insn.rd;
+ insn.name = "addiw";
+ PRINT_rd_rs1_imm();
+ case 0x2: /* C.LI */
+ insn = insn_citype_read(data);
+ insn.rs1 = 0;
+ insn.name = "addi";
+ PRINT_rd_rs1_imm();
+ case 0x3: {
+ int32_t rd = RC1(data);
+ if (rd == 2) { /* C.ADDI16SP */
+ insn = insn_citype_read3(data);
+ assert(insn.imm != 0);
+ insn.rs1 = insn.rd;
+ insn.name = "addi";
+ PRINT_rd_rs1_imm();
+ } else { /* C.LUI */
+ insn = insn_citype_read5(data);
+ assert(insn.imm != 0);
+ insn.name = "lui";
+ PRINT_rd_immx();
+ }
+ }
+ case 0x4: {
+ uint32_t cfunct2high = CFUNCT2HIGH(data);
+
+ switch (cfunct2high) {
+ case 0x0: /* C.SRLI */
+ case 0x1: /* C.SRAI */
+ case 0x2: { /* C.ANDI */
+ insn = insn_cbtype_read2(data);
+ insn.rs1 = insn.rd;
+
+ if (cfunct2high == 0x0) {
+ insn.name = "srli";
+ } else if (cfunct2high == 0x1) {
+ insn.name = "srai";
+ } else {
+ insn.name = "andi";
+ }
+ PRINT_rd_rs1_imm();
+ }
+ case 0x3: {
+ uint32_t cfunct1 = CFUNCT1(data);
+
+ switch (cfunct1) {
+ case 0x0: {
+ uint32_t cfunct2low = CFUNCT2LOW(data);
+
+ insn = insn_catype_read(data);
+ insn.rs1 = insn.rd;
+
+ switch (cfunct2low) {
+ case 0x0: /* C.SUB */
+ insn.name = "sub";
+ break;
+ case 0x1: /* C.XOR */
+ insn.name = "xor";
+ break;
+ case 0x2: /* C.OR */
+ insn.name = "or";
+ break;
+ case 0x3: /* C.AND */
+ insn.name = "and";
+ break;
+ }
+ break;
+ }
+ case 0x1: {
+ uint32_t cfunct2low = CFUNCT2LOW(data);
+
+ insn = insn_catype_read(data);
+ insn.rs1 = insn.rd;
+
+ switch (cfunct2low) {
+ case 0x0: /* C.SUBW */
+ insn.name = "subw";
+ break;
+ case 0x1: /* C.ADDW */
+ insn.name = "addw";
+ break;
+ }
+ break;
+ }
+ }
+ PRINT_rd_rs1_rs2();
+ }
+ }
+ }
+ case 0x5: /* C.J */
+ insn = insn_cjtype_read(data);
+ insn.rd = 0;
+ insn.name = "jal";
+ PRINT_rd_imm();
+ case 0x6: /* C.BEQZ */
+ case 0x7: /* C.BNEZ */
+ insn = insn_cbtype_read(data);
+ insn.rs2 = 0;
+ insn.name = copcode == 0x6 ? "beq" : "bne";
+ PRINT_rs1_rs2_imm();
+ }
+ }
+ case 0x2: {
+ uint32_t copcode = COPCODE(data);
+ switch (copcode) {
+ case 0x0: /* C.SLLI */
+ insn = insn_citype_read(data);
+ insn.rs1 = insn.rd;
+ insn.name = "slli";
+ PRINT_rd_rs1_imm();
+ case 0x1: /* C.FLDSP */
+ insn = insn_citype_read2(data);
+ insn.rs1 = 2; /* sp */
+ insn.f = true;
+ insn.name = "fld";
+ PRINT_rd_imm_rs1();
+ case 0x2: /* C.LWSP */
+ insn = insn_citype_read4(data);
+ assert(insn.rd != 0);
+ insn.rs1 = 2; /* sp */
+ insn.name = "lw";
+ PRINT_rd_imm_rs1();
+ case 0x3: /* C.LDSP */
+ insn = insn_citype_read2(data);
+ assert(insn.rd != 0);
+ insn.rs1 = 2; /* sp */
+ insn.name = "ld";
+ PRINT_rd_imm_rs1();
+ case 0x4: {
+ uint32_t cfunct1 = CFUNCT1(data);
+
+ switch (cfunct1) {
+ case 0x0: {
+ insn = insn_crtype_read(data);
+
+ if (insn.rs2 == 0) { /* C.JR */
+ assert(insn.rs1 != 0);
+ insn.rd = 0;
+ insn.name = "jalr";
+ PRINT_rd_imm_rs1();
+ } else { /* C.MV */
+ insn.rd = insn.rs1;
+ insn.rs1 = 0;
+ insn.name = "add";
+ PRINT_rd_rs1_rs2();
+ }
+ }
+ case 0x1: {
+ insn = insn_crtype_read(data);
+ if (insn.rs1 == 0 && insn.rs2 == 0) { /* C.EBREAK */
+ insn.name = "ebreak";
+ PRINT_none();
+ } else if (insn.rs2 == 0) { /* C.JALR */
+ insn.rd = 1; /* ra */
+ insn.name = "jalr";
+ PRINT_rd_imm_rs1();
+ } else { /* C.ADD */
+ insn.rd = insn.rs1;
+ insn.name = "add";
+ PRINT_rd_rs1_rs2();
+ }
+ }
+ }
+ }
+ case 0x5: /* C.FSDSP */
+ insn = insn_csstype_read(data);
+ insn.rs1 = 2; /* sp */
+ insn.f = true;
+ insn.name = "fsd";
+ PRINT_rs2_imm_rs1();
+ case 0x6: /* C.SWSP */
+ insn = insn_csstype_read2(data);
+ insn.rs1 = 2; /* sp */
+ insn.name = "sw";
+ PRINT_rs2_imm_rs1();
+ case 0x7: /* C.SDSP */
+ insn = insn_csstype_read(data);
+ insn.rs1 = 2; /* sp */
+ insn.name = "sd";
+ PRINT_rs2_imm_rs1();
+ }
+ }
+ case 0x3: {
+ uint32_t opcode = OPCODE(data);
+ switch (opcode) {
+ case 0x0: {
+ uint32_t funct3 = FUNCT3(data);
+
+ insn = insn_itype_read(data);
+ switch (funct3) {
+ case 0x0: /* LB */
+ insn.name = "lb";
+ break;
+ case 0x1: /* LH */
+ insn.name = "lh";
+ break;
+ case 0x2: /* LW */
+ insn.name = "lw";
+ break;
+ case 0x3: /* LD */
+ insn.name = "ld";
+ break;
+ case 0x4: /* LBU */
+ insn.name = "lbu";
+ break;
+ case 0x5: /* LHU */
+ insn.name = "lhu";
+ break;
+ case 0x6: /* LWU */
+ insn.name = "lwu";
+ break;
+ }
+ PRINT_rd_imm_rs1();
+ }
+ case 0x1: {
+ uint32_t funct3 = FUNCT3(data);
+
+ insn = insn_itype_read(data);
+ switch (funct3) {
+ case 0x2: /* FLW */
+ insn.name = "flw";
+ insn.f = true;
+ break;
+ case 0x3: /* FLD */
+ insn.name = "fld";
+ insn.f = true;
+ break;
+ }
+ PRINT_rd_imm_rs1();
+ }
+ case 0x3: {
+ uint32_t funct3 = FUNCT3(data);
+
+ switch (funct3) {
+ case 0x0: { /* FENCE */
+ insn.name = "fence";
+ // TODO: handle pred succ
+ PRINT_none();
+ }
+ case 0x1: { /* FENCE.I */
+ insn.name = "fence.i";
+ PRINT_none();
+ }
+ }
+ }
+ case 0x4: {
+ int hex = 0;
+ int mv_alias = 0;
+ int nop_alias = 0;
+ int not_alias = 0;
+ uint32_t funct3 = FUNCT3(data);
+
+ insn = insn_itype_read(data);
+ switch (funct3) {
+ case 0x0: /* ADDI */
+ insn.name = "addi";
+ if (insn.imm == 0) {
+ if (insn.rd == 0 && insn.rs1 == 0) {
+ nop_alias = 1;
+ insn.name = "nop";
+ } else {
+ mv_alias = 1;
+ insn.name = "mv";
+ }
+ }
+ break;
+ case 0x1: {
+ uint32_t imm116 = IMM116(data);
+ if (imm116 == 0) { /* SLLI */
+ insn.name = "slli";
+ }
+ break;
+ }
+ case 0x2: /* SLTI */
+ insn.name = "slti";
+ break;
+ case 0x3: /* SLTIU */
+ insn.name = "sltiu";
+ break;
+ case 0x4: /* XORI */
+ insn.name = "xori";
+ hex = 1;
+ if (insn.imm == -1) {
+ not_alias = 1;
+ insn.name = "not";
+ }
+ break;
+ case 0x5: {
+ uint32_t imm116 = IMM116(data);
+
+ if (imm116 == 0x0) { /* SRLI */
+ insn.name = "srli";
+ } else if (imm116 == 0x10) { /* SRAI */
+ insn.name = "srai";
+ insn.imm&=0b111111;
+ } else if (insn.imm==0b011010111000) {
+ insn.name = "rev8";
+ PRINT_rd_rs1();
+ }
+ break;
+ }
+ case 0x6: /* ORI */
+ insn.name = "ori";
+ hex = 1;
+ break;
+ case 0x7: /* ANDI */
+ insn.name = "andi";
+ hex = 1;
+ break;
+ }
+ if (not_alias) {
+ PRINT_rd_rs1();
+ } else if (nop_alias) {
+ PRINT_none();
+ } else if (mv_alias) {
+ PRINT_rd_rs1();
+ } else if(hex) {
+ PRINT_rd_rs1_immx();
+ } else {
+ PRINT_rd_rs1_imm();
+ }
+ }
+ case 0x5: /* AUIPC */
+ insn = insn_utype_read(data);
+ insn.name = "auipc";
+ PRINT_rd_imm_rel();
+ case 0x6: {
+ uint32_t funct3 = FUNCT3(data);
+ uint32_t funct7 = FUNCT7(data);
+
+ insn = insn_itype_read(data);
+
+ switch (funct3) {
+ case 0x0: /* ADDIW */
+ insn.name = "addiw";
+ break;
+ case 0x1: /* SLLIW */
+ assert(funct7 == 0);
+ insn.name = "slliw";
+ break;
+ case 0x5: {
+ switch (funct7) {
+ case 0x0: /* SRLIW */
+ insn.name = "srliw";
+ break;
+ case 0x20: /* SRAIW */
+ insn.name = "sraiw";
+ insn.imm&=0b111111;
+ break;
+ }
+ }
+ }
+ PRINT_rd_rs1_imm();
+ }
+ case 0x8: {
+ uint32_t funct3 = FUNCT3(data);
+
+ insn = insn_stype_read(data);
+ switch (funct3) {
+ case 0x0: /* SB */
+ insn.name = "sb";
+ break;
+ case 0x1: /* SH */
+ insn.name = "sh";
+ break;
+ case 0x2: /* SW */
+ insn.name = "sw";
+ break;
+ case 0x3: /* SD */
+ insn.name = "sd";
+ break;
+ }
+ PRINT_rs2_imm_rs1();
+ }
+ case 0x9: {
+ uint32_t funct3 = FUNCT3(data);
+
+ insn = insn_stype_read(data);
+ switch (funct3) {
+ case 0x2: /* FSW */
+ insn.name = "fsw";
+ insn.f = true;
+ break;
+ case 0x3: /* FSD */
+ insn.name = "fsd";
+ insn.f = true;
+ break;
+ }
+ PRINT_rs2_imm_rs1();
+ }
+ case 0xb: {
+ uint32_t funct3 = FUNCT3(data);
+ uint32_t rs1 = RS3(data);
+ bool aq = AQ(data), rl = RL(data);
+ insn = insn_rtype_read(data);
+ switch(funct3) {
+ case 0x2:
+ switch (rs1) {
+ case 0x2: /* LR.W */
+ insn.name = "lr.w";
+ PRINT_rd_rs1_aqrl();
+ case 0x3: /* SC.W */
+ insn.name = "sc.w";
+ PRINT_rd_rs1_rs2_aqrl();
+ }
+ case 0x3:
+ switch (rs1) {
+ case 0x2: /* LR.D */
+ insn.name = "lr.d";
+ PRINT_rd_rs1_aqrl();
+ case 0x3: /* SC.D */
+ insn.name = "sc.d";
+ PRINT_rd_rs1_rs2_aqrl();
+ }
+ }
+ }
+ case 0xc: {
+ insn = insn_rtype_read(data);
+
+ uint32_t funct3 = FUNCT3(data);
+ uint32_t funct7 = FUNCT7(data);
+
+ switch (funct7) {
+ case 0x0: {
+ switch (funct3) {
+ case 0x0: /* ADD */
+ insn.name = "add";
+ break;
+ case 0x1: /* SLL */
+ insn.name = "sll";
+ break;
+ case 0x2: /* SLT */
+ insn.name = "slt";
+ break;
+ case 0x3: /* SLTU */
+ insn.name = "sltu";
+ break;
+ case 0x4: /* XOR */
+ insn.name = "xor";
+ break;
+ case 0x5: /* SRL */
+ insn.name = "srl";
+ break;
+ case 0x6: /* OR */
+ insn.name = "or";
+ break;
+ case 0x7: /* AND */
+ insn.name = "and";
+ break;
+ }
+ }
+ break;
+ case 0x1: {
+ switch (funct3) {
+ case 0x0: /* MUL */
+ insn.name = "mul";
+ break;
+ case 0x1: /* MULH */
+ insn.name = "mulh";
+ break;
+ case 0x2: /* MULHSU */
+ insn.name = "mulhsu";
+ break;
+ case 0x3: /* MULHU */
+ insn.name = "mulhu";
+ break;
+ case 0x4: /* DIV */
+ insn.name = "div";
+ break;
+ case 0x5: /* DIVU */
+ insn.name = "divu";
+ break;
+ case 0x6: /* REM */
+ insn.name = "rem";
+ break;
+ case 0x7: /* REMU */
+ insn.name = "remu";
+ break;
+ }
+ }
+ break;
+ case 0x10: {
+ switch (funct3) {
+ case 0b010:
+ insn.name = "sh1add";
+ break;
+ case 0b100:
+ insn.name = "sh2add";
+ break;
+ case 0b110:
+ insn.name = "sh3add";
+ break;
+ }
+ }
+ break;
+ case 0x20: {
+ switch (funct3) {
+ case 0x0: /* SUB */
+ insn.name = "sub";
+ break;
+ case 0x5: /* SRA */
+ insn.name = "sra";
+ break;
+ }
+ }
+ break;
+ }
+ PRINT_rd_rs1_rs2();
+ }
+ case 0xd: /* LUI */
+ insn = insn_utype_read(data);
+ insn.name = "lui";
+ PRINT_rd_immx();
+ case 0xe: {
+ insn = insn_rtype_read(data);
+
+ uint32_t funct3 = FUNCT3(data);
+ uint32_t funct7 = FUNCT7(data);
+
+ switch (funct7) {
+ case 0x0: {
+ switch (funct3) {
+ case 0x0: /* ADDW */
+ insn.name = "addw";
+ break;
+ case 0x1: /* SLLW */
+ insn.name = "sllw";
+ break;
+ case 0x5: /* SRLW */
+ insn.name = "srlw";
+ break;
+ }
+ }
+ break;
+ case 0x1: {
+ switch (funct3) {
+ case 0x0: /* MULW */
+ insn.name = "mulw";
+ break;
+ case 0x4: /* DIVW */
+ insn.name = "divw";
+ break;
+ case 0x5: /* DIVUW */
+ insn.name = "divuw";
+ break;
+ case 0x6: /* REMW */
+ insn.name = "remw";
+ break;
+ case 0x7: /* REMUW */
+ insn.name = "remuw";
+ break;
+ }
+ }
+ break;
+ case 0x20: {
+ switch (funct3) {
+ case 0x0: /* SUBW */
+ insn.name = "subw";
+ break;
+ case 0x5: /* SRAW */
+ insn.name = "sraw";
+ break;
+ }
+ }
+ break;
+ }
+ PRINT_rd_rs1_rs2();
+ }
+ case 0x10: {
+ uint32_t funct2 = FUNCT2(data);
+
+ insn = insn_fprtype_read(data);
+ switch (funct2) {
+ case 0x0: /* FMADD.S */
+ insn.name = "fmadd.s";
+ insn.f = true;
+ break;
+ case 0x1: /* FMADD.D */
+ insn.name = "fmadd.d";
+ insn.f = true;
+ break;
+ }
+ PRINT_rd_rs1_rs2();
+ }
+ case 0x11: {
+ uint32_t funct2 = FUNCT2(data);
+
+ insn = insn_fprtype_read(data);
+ switch (funct2) {
+ case 0x0: /* FMSUB.S */
+ insn.name = "fmsub.s";
+ insn.f = true;
+ break;
+ case 0x1: /* FMSUB.D */
+ insn.name = "fmsub.d";
+ insn.f = true;
+ break;
+ }
+ PRINT_rd_rs1_rs2();
+ }
+ case 0x12: {
+ uint32_t funct2 = FUNCT2(data);
+
+ insn = insn_fprtype_read(data);
+ switch (funct2) {
+ case 0x0: /* FNMSUB.S */
+ insn.name = "fnmsub.s";
+ insn.f = true;
+ break;
+ case 0x1: /* FNMSUB.D */
+ insn.name = "fnmsub.d";
+ insn.f = true;
+ break;
+ }
+ PRINT_rd_rs1_rs2_rs3();
+ }
+ case 0x13: {
+ uint32_t funct2 = FUNCT2(data);
+
+ insn = insn_fprtype_read(data);
+ switch (funct2) {
+ case 0x0: /* FNMADD.S */
+ insn.name = "fnmadd.s";
+ insn.f = true;
+ break;
+ case 0x1: /* FNMADD.D */
+ insn.name = "fnmadd.d";
+ insn.f = true;
+ break;
+ }
+ PRINT_rd_rs1_rs2_rs3();
+ }
+ case 0x14: {
+ uint32_t funct7 = FUNCT7(data);
+
+ insn = insn_rtype_read(data);
+ insn.f = true;
+ switch (funct7) {
+ case 0x0: /* FADD.S */
+ insn.name = "fadd.s";
+ PRINT_rd_rs1_rs2();
+ case 0x1: /* FADD.D */
+ insn.name = "fadd.d";
+ PRINT_rd_rs1_rs2();
+ case 0x4: /* FSUB.S */
+ insn.name = "fsub.s";
+ PRINT_rd_rs1_rs2();
+ case 0x5: /* FSUB.D */
+ insn.name = "fsub.d";
+ PRINT_rd_rs1_rs2();
+ case 0x8: /* FMUL.S */
+ insn.name = "fmul.s";
+ PRINT_rd_rs1_rs2();
+ case 0x9: /* FMUL.D */
+ insn.name = "fmul.d";
+ PRINT_rd_rs1_rs2();
+ case 0xc: /* FDIV.S */
+ insn.name = "fdiv.s";
+ PRINT_rd_rs1_rs2();
+ case 0xd: /* FDIV.D */
+ insn.name = "fdiv.d";
+ PRINT_rd_rs1_rs2();
+ case 0x10: {
+ uint32_t funct3 = FUNCT3(data);
+
+ switch (funct3) {
+ case 0x0: /* FSGNJ.S */
+ insn.name = "fsgnj.s";
+ break;
+ case 0x1: /* FSGNJN.S */
+ insn.name = "fsgnjn.s";
+ break;
+ case 0x2: /* FSGNJX.S */
+ insn.name = "fsgnjx.s";
+ break;
+ }
+ PRINT_rd_rs1_rs2();
+ }
+ case 0x11: {
+ uint32_t funct3 = FUNCT3(data);
+
+ switch (funct3) {
+ case 0x0: /* FSGNJ.D */
+ insn.name = "fsgnj.d";
+ break;
+ case 0x1: /* FSGNJN.D */
+ insn.name = "fsgnjn.d";
+ break;
+ case 0x2: /* FSGNJX.D */
+ insn.name = "fsgnjx.d";
+ break;
+ }
+ PRINT_rd_rs1_rs2();
+ }
+ case 0x14: {
+ uint32_t funct3 = FUNCT3(data);
+
+ switch (funct3) {
+ case 0x0: /* FMIN.S */
+ insn.name = "fmin.s";
+ break;
+ case 0x1: /* FMAX.S */
+ insn.name = "fmax.s";
+ break;
+ }
+ PRINT_rd_rs1_rs2();
+ }
+ case 0x15: {
+ uint32_t funct3 = FUNCT3(data);
+
+ switch (funct3) {
+ case 0x0: /* FMIN.D */
+ insn.name = "fmin.d";
+ break;
+ case 0x1: /* FMAX.D */
+ insn.name = "fmax.d";
+ break;
+ }
+ PRINT_rd_rs1_rs2();
+ }
+ case 0x20: /* FCVT.S.D */
+ assert(RS2(data) == 1);
+ insn.name = "fcvt.s.d";
+ PRINT_fd_fs1();
+ case 0x21: /* FCVT.D.S */
+ assert(RS2(data) == 0);
+ insn.name = "fcvt.d.s";
+ PRINT_fd_fs1();
+ case 0x2c: /* FSQRT.S */
+ assert(insn.rs2 == 0);
+ insn.name = "fsqrt.s";
+ PRINT_fd_fs1();
+ case 0x2d: /* FSQRT.D */
+ assert(insn.rs2 == 0);
+ insn.name = "fsqrt.d";
+ PRINT_fd_fs1();
+ case 0x50: {
+ uint32_t funct3 = FUNCT3(data);
+
+ switch (funct3) {
+ case 0x0: /* FLE.S */
+ insn.name = "fle.s";
+ break;
+ case 0x1: /* FLT.S */
+ insn.name = "flt.s";
+ break;
+ case 0x2: /* FEQ.S */
+ insn.name = "feq.s";
+ break;
+ }
+ PRINT_rd_fs1_fs2();
+ }
+ case 0x51: {
+ uint32_t funct3 = FUNCT3(data);
+
+ switch (funct3) {
+ case 0x0: /* FLE.D */
+ insn.name = "fle.d";
+ break;
+ case 0x1: /* FLT.D */
+ insn.name = "flt.d";
+ break;
+ case 0x2: /* FEQ.D */
+ insn.name = "feq.d";
+ break;
+ }
+ PRINT_rd_fs1_fs2();
+ }
+ case 0x60: {
+ uint32_t rs2 = RS2(data);
+
+ switch (rs2) {
+ case 0x0: /* FCVT.W.S */
+ insn.name = "fcvt.w.s";
+ break;
+ case 0x1: /* FCVT.WU.S */
+ insn.name = "fcvt.wu.s";
+ break;
+ case 0x2: /* FCVT.L.S */
+ insn.name = "fcvt.l.s";
+ break;
+ case 0x3: /* FCVT.LU.S */
+ insn.name = "fcvt.lu.s";
+ break;
+ }
+ PRINT_xd_fs1();
+ }
+ case 0x61: {
+ uint32_t rs2 = RS2(data);
+
+ switch (rs2) {
+ case 0x0: /* FCVT.W.D */
+ insn.name = "fcvt.w.d";
+ break;
+ case 0x1: /* FCVT.WU.D */
+ insn.name = "fcvt.wu.d";
+ break;
+ case 0x2: /* FCVT.L.D */
+ insn.name = "fcvt.l.d";
+ break;
+ case 0x3: /* FCVT.LU.D */
+ insn.name = "fcvt.lu.d";
+ break;
+ }
+ PRINT_xd_fs1();
+ }
+ case 0x68: {
+ uint32_t rs2 = RS2(data);
+
+ switch (rs2) {
+ case 0x0: /* FCVT.S.W */
+ insn.name = "fcvt.s.w";
+ break;
+ case 0x1: /* FCVT.S.WU */
+ insn.name = "fcvt.s.wu";
+ break;
+ case 0x2: /* FCVT.S.L */
+ insn.name = "fcvt.s.l";
+ break;
+ case 0x3: /* FCVT.S.LU */
+ insn.name = "fcvt.s.lu";
+ break;
+ }
+ PRINT_fd_xs1();
+ }
+ case 0x69: {
+ uint32_t rs2 = RS2(data);
+
+ switch (rs2) {
+ case 0x0: /* FCVT.D.W */
+ insn.name = "fcvt.d.w";
+ break;
+ case 0x1: /* FCVT.D.WU */
+ insn.name = "fcvt.d.wu";
+ break;
+ case 0x2: /* FCVT.D.L */
+ insn.name = "fcvt.d.l";
+ break;
+ case 0x3: /* FCVT.D.LU */
+ insn.name = "fcvt.d.lu";
+ break;
+ }
+ PRINT_fd_xs1();
+ }
+ case 0x70: {
+ assert(RS2(data) == 0);
+ uint32_t funct3 = FUNCT3(data);
+
+ switch (funct3) {
+ case 0x0: /* FMV.X.W */
+ insn.name = "fmv.x.w";
+ break;
+ case 0x1: /* FCLASS.S */
+ insn.name = "fclass.s";
+ break;
+ }
+ PRINT_xd_fs1();
+ }
+ case 0x71: {
+ assert(RS2(data) == 0);
+ uint32_t funct3 = FUNCT3(data);
+
+ switch (funct3) {
+ case 0x0: /* FMV.X.D */
+ insn.name = "fmv.x.d";
+ break;
+ case 0x1: /* FCLASS.D */
+ insn.name = "fclass.d";
+ break;
+ }
+ PRINT_xd_fs1();
+ }
+ case 0x78: /* FMV_W_X */
+ assert(RS2(data) == 0 && FUNCT3(data) == 0);
+ insn.name = "fmv.w.x";
+ PRINT_fd_xs1();
+ case 0x79: /* FMV_D_X */
+ assert(RS2(data) == 0 && FUNCT3(data) == 0);
+ insn.name = "fmv.d.x";
+ PRINT_fd_xs1();
+ }
+ }
+ case 0x18: {
+ insn = insn_btype_read(data);
+
+ uint32_t funct3 = FUNCT3(data);
+ switch (funct3) {
+ case 0x0: /* BEQ */
+ insn.name = "beq";
+ break;
+ case 0x1: /* BNE */
+ insn.name = "bne";
+ break;
+ case 0x4: /* BLT */
+ insn.name = "blt";
+ break;
+ case 0x5: /* BGE */
+ insn.name = "bge";
+ break;
+ case 0x6: /* BLTU */
+ insn.name = "bltu";
+ break;
+ case 0x7: /* BGEU */
+ insn.name = "bgeu";
+ break;
+ }
+
+ PRINT_rs1_rs2_imm_rel();
+ }
+ case 0x19: /* JALR */
+ insn = insn_itype_read(data);
+ insn.name = "jalr";
+ PRINT_rd_imm_rs1();
+ case 0x1b: /* JAL */
+ insn = insn_jtype_read(data);
+ if (insn.rd != 0) {
+ insn.name = "jal";
+ PRINT_rd_imm_rel();
+ } else {
+ insn.name = "j";
+ PRINT_imm_rel();
+ }
+ case 0x1c: {
+ if (data == 0x73) { /* ECALL */
+ insn.name = "ecall";
+ PRINT_none();
+ }
+
+ uint32_t funct3 = FUNCT3(data);
+ insn = insn_csrtype_read(data);
+ switch(funct3) {
+ case 0x1: /* CSRRW */
+ insn.name = "csrrw";
+ PRINT_rd_csr_rs1();
+ case 0x2: /* CSRRS */
+ insn.name = "csrrs";
+ PRINT_rd_csr_rs1();
+ case 0x3: /* CSRRC */
+ insn.name = "csrrc";
+ PRINT_rd_csr_rs1();
+ case 0x5: /* CSRRWI */
+ insn.name = "csrrwi";
+ PRINT_rd_csr_uimm();
+ case 0x6: /* CSRRSI */
+ insn.name = "csrrsi";
+ PRINT_rd_csr_uimm();
+ case 0x7: /* CSRRCI */
+ insn.name = "csrrci";
+ PRINT_rd_csr_uimm();
+ }
+ }
+ }
+ }
+ }
+
+ snprintf(buff, sizeof(buff), "%08X ???", __builtin_bswap32(data));
+ return buff;
+}
diff --git a/src/dynarec/rv64/rv64_printer.h b/src/dynarec/rv64/rv64_printer.h
new file mode 100644
index 0000000..e22a208
--- /dev/null
+++ b/src/dynarec/rv64/rv64_printer.h
@@ -0,0 +1,8 @@
+#ifndef _RV64_PRINTER_H_
+#define _RV64_PRINTER_H_
+#include <stdint.h>
+#include<stdbool.h>
+
+const char* rv64_print(uint32_t data, uint64_t addr);
+
+#endif //_RV64_PRINTER_H_
diff --git a/src/dynarec/rv64/rv64_prolog.S b/src/dynarec/rv64/rv64_prolog.S
new file mode 100644
index 0000000..96a85d3
--- /dev/null
+++ b/src/dynarec/rv64/rv64_prolog.S
@@ -0,0 +1,66 @@
+//arm prologue for dynarec
+//Save stuff, prepare stack and register
+//called with pointer to emu as 1st parameter
+//and address to jump to as 2nd parameter
+
+.text
+.align 4
+
+.extern rv64_next
+
+.global rv64_prolog
+rv64_prolog:
+ //save all 18 used register
+ addi sp, sp, -(8 * 24) // 16 bytes aligned
+ sd ra, (sp) // save ra
+ sd x8, 8(sp) // save fp
+ sd x18, (2*8)(sp)
+ sd x19, (3*8)(sp)
+ sd x20, (4*8)(sp)
+ sd x21, (5*8)(sp)
+ sd x22, (6*8)(sp)
+ sd x23, (7*8)(sp)
+ sd x24, (8*8)(sp)
+ sd x25, (9*8)(sp)
+ sd x26, (10*8)(sp)
+ sd x27, (11*8)(sp)
+ sd x9, (12*8)(sp)
+ fsd f18, (13*8)(sp)
+ fsd f19, (14*8)(sp)
+ fsd f20, (15*8)(sp)
+ fsd f21, (16*8)(sp)
+ fsd f22, (17*8)(sp)
+ fsd f23, (19*8)(sp)
+ fsd f24, (19*8)(sp)
+ fsd f25, (20*8)(sp)
+ fsd f26, (21*8)(sp)
+ fsd f27, (22*8)(sp)
+ //setup emu -> register
+ ld x16, (a0)
+ ld x17, 8(a0)
+ ld x18, 16(a0)
+ ld x19, 24(a0)
+ ld x20, 32(a0)
+ ld x21, 40(a0)
+ ld x22, 48(a0)
+ ld x23, 56(a0)
+ ld x24, 64(a0)
+ ld x25, 72(a0)
+ ld x26, 80(a0)
+ ld x27, 88(a0)
+ ld x28, 96(a0)
+ ld x29, 104(a0)
+ ld x30, 112(a0)
+ ld x31, 120(a0)
+ ld x8, 128(a0) //xFlags
+ ld x7, 136(a0) // xRIP
+ // // adjust flags bit 11 -> bit 5
+ andi x8, x8, ~(1<<5) // probably not usefull?
+ srli x5, x8, 11-5
+ andi x5, x5, 1<<5
+ or x8, x8, x5
+ // setup xMASK
+ xori x5, x0, -1
+ srli x5, x5, 32
+ // jump to block
+ jalr a1
diff --git a/src/elfs/elfdwarf_private.c b/src/elfs/elfdwarf_private.c
index aeba39b..90316a3 100644
--- a/src/elfs/elfdwarf_private.c
+++ b/src/elfs/elfdwarf_private.c
@@ -108,11 +108,11 @@ uintptr_t get_parent_registers(dwarf_unwind_t *unwind, const elfheader_t *ehdr,
*success = 0;
return 0;
}
- if(!IsAddressInElfSpace(ehdr, ehdr->ehframehdr)) {
+ if(!IsAddressInElfSpace(ehdr, ehdr->ehframehdr+ehdr->delta)) {
*success = 0;
return 0;
}
- unsigned char ehfh_version = *(unsigned char*)ehdr->ehframehdr;
+ unsigned char ehfh_version = *(unsigned char*)(ehdr->ehframehdr+ehdr->delta);
if (ehfh_version != 1) {
*success = 0;
return 0;
@@ -122,8 +122,8 @@ uintptr_t get_parent_registers(dwarf_unwind_t *unwind, const elfheader_t *ehdr,
// Not using the binary search table (for now)
- unsigned char *cur_addr = (unsigned char*)ehdr->ehframe;
- unsigned char *end_addr = (unsigned char*)ehdr->ehframe_end;
+ unsigned char *cur_addr = (unsigned char*)(ehdr->ehframe+ehdr->delta);
+ unsigned char *end_addr = (unsigned char*)(ehdr->ehframe_end+ehdr->delta);
#define AUG_EHDATA (1 << 0)
#define AUG_AUGDATA (1 << 1)
@@ -538,7 +538,7 @@ uintptr_t get_parent_registers(dwarf_unwind_t *unwind, const elfheader_t *ehdr,
break; \
}
#define RESTORE_REG(reg) \
- printf_log(LOG_DEBUG, "Trying to restore register 0x%02lX while in the intial CFIs\n", (uint64_t)reg); \
+ printf_log(LOG_DEBUG, "Trying to restore register 0x%02lX while in the initial CFIs\n", (uint64_t)reg); \
FAILED
#define FAILED \
box_free(unwind_constr.statuses); \
diff --git a/src/elfs/elfload_dump.c b/src/elfs/elfload_dump.c
index d7d11e4..d7d11e4 100755..100644
--- a/src/elfs/elfload_dump.c
+++ b/src/elfs/elfload_dump.c
diff --git a/src/elfs/elfloader.c b/src/elfs/elfloader.c
index 2082322..6a51660 100755..100644
--- a/src/elfs/elfloader.c
+++ b/src/elfs/elfloader.c
@@ -37,6 +37,7 @@
#include "dynablock.h"
#endif
#include "../emu/x64emu_private.h"
+#include "../emu/x64run_private.h"
#include "x64tls.h"
void* my__IO_2_1_stderr_ = NULL;
@@ -65,6 +66,8 @@ elfheader_t* LoadAndCheckElfHeader(FILE* f, const char* name, int exec)
h->mapsymbols = NewMapSymbols();
h->weaksymbols = NewMapSymbols();
h->localsymbols = NewMapSymbols();
+ h->globaldefver = NewDefaultVersion();
+ h->weakdefver = NewDefaultVersion();
h->refcnt = 1;
return h;
@@ -75,14 +78,9 @@ void FreeElfHeader(elfheader_t** head)
if(!head || !*head)
return;
elfheader_t *h = *head;
-#ifdef DYNAREC
- /*if(h->text) {
- dynarec_log(LOG_INFO, "Free Dynarec block for %s\n", h->path);
- cleanDBFromAddressRange(my_context, h->text, h->textsz, 1);
- }*/ // will be free at the end, no need to free it now
-#endif
- box_free(h->name);
- box_free(h->path);
+ if(my_context)
+ RemoveElfHeader(my_context, h);
+
box_free(h->PHEntries);
box_free(h->SHEntries);
box_free(h->SHStrTab);
@@ -95,8 +93,13 @@ void FreeElfHeader(elfheader_t** head)
FreeMapSymbols(&h->mapsymbols);
FreeMapSymbols(&h->weaksymbols);
FreeMapSymbols(&h->localsymbols);
+ FreeDefaultVersion(&h->globaldefver);
+ FreeDefaultVersion(&h->weakdefver);
FreeElfMemory(h);
+
+ box_free(h->name);
+ box_free(h->path);
box_free(h);
*head = NULL;
@@ -170,7 +173,7 @@ int AllocElfMemory(box64context_t* context, elfheader_t* head, int mainbin)
{
uintptr_t offs = 0;
if(!head->vaddr && box64_load_addr) {
- offs = box64_load_addr;
+ offs = (uintptr_t)find47bitBlockNearHint((void*)box64_load_addr, head->memsz);
box64_load_addr += head->memsz;
box64_load_addr = (box64_load_addr+0x10ffffffLL)&~0xffffffLL;
}
@@ -255,13 +258,25 @@ int AllocElfMemory(box64context_t* context, elfheader_t* head, int mainbin)
}
} else {
// vaddr is 0, load everything has a One block
- if(!offs && box64_wine)
+ uintptr_t old_offs = offs;
+ if(!offs /*&& box64_wine*/)
offs = (uintptr_t)find47bitBlock(head->memsz); // limit to 47bits...
printf_log(log_level, "Allocating 0x%zx memory @%p for Elf \"%s\"\n", head->memsz, (void*)offs, head->name);
void* p = mmap((void*)offs, head->memsz
, PROT_READ | PROT_WRITE | PROT_EXEC
, MAP_PRIVATE | MAP_ANONYMOUS /*| (((offs&&wine_preloaded)?MAP_FIXED:0))*/
, -1, 0);
+ if(offs &&!old_offs && p!=MAP_FAILED && offs!=(uintptr_t)p) {
+ // try again
+ munmap(p, head->memsz);
+ loadProtectionFromMap();
+ offs = (uintptr_t)find47bitBlock(head->memsz);
+ printf_log(log_level, "New, try. Allocating 0x%zx memory @%p for Elf \"%s\"\n", head->memsz, (void*)offs, head->name);
+ p = mmap((void*)offs, head->memsz
+ , PROT_READ | PROT_WRITE | PROT_EXEC
+ , MAP_PRIVATE | MAP_ANONYMOUS /*| (((offs&&wine_preloaded)?MAP_FIXED:0))*/
+ , -1, 0);
+ }
if(p==MAP_FAILED) {
printf_log(LOG_NONE, "Cannot create memory map (@%p 0x%zx/0x%zx) for elf \"%s\"\n", (void*)offs, head->memsz, head->align, head->name);
return 1;
@@ -293,8 +308,16 @@ int AllocElfMemory(box64context_t* context, elfheader_t* head, int mainbin)
void FreeElfMemory(elfheader_t* head)
{
if(head->multiblock_n) {
- for(int i=0; i<head->multiblock_n; ++i)
+ for(int i=0; i<head->multiblock_n; ++i) {
+#ifdef DYNAREC
+ dynarec_log(LOG_INFO, "Free DynaBlocks for %s\n", head->path);
+ if(box64_dynarec) {
+ cleanDBFromAddressRange((uintptr_t)head->multiblock[i], head->multiblock_size[i], 1);
+ freeProtection((uintptr_t)head->multiblock[i], head->multiblock_size[i]);
+ }
+#endif
munmap(head->multiblock[i], head->multiblock_size[i]);
+ }
box_free(head->multiblock);
box_free(head->multiblock_size);
box_free(head->multiblock_offs);
@@ -353,6 +376,23 @@ int LoadElfMemory(FILE* f, box64context_t* context, elfheader_t* head)
return 0;
}
+int isElfHasNeededVer(elfheader_t* head, const char* libname, elfheader_t* verneeded)
+{
+ if(!verneeded || !head)
+ return 1;
+ if(!head->VerDef || !verneeded->VerNeed)
+ return 1;
+ int cnt = GetNeededVersionCnt(verneeded, libname);
+ for (int i=0; i<cnt; ++i) {
+ const char* vername = GetNeededVersionString(verneeded, libname, i);
+ if(vername && !GetVersionIndice(head, vername)) {
+ printf_log(/*LOG_DEBUG*/LOG_INFO, "Discarding %s for missing version %s\n", head->path, vername);
+ return 0; // missing version
+ }
+ }
+ return 1;
+}
+
int ReloadElfMemory(FILE* f, box64context_t* context, elfheader_t* head)
{
(void)context;
@@ -401,9 +441,9 @@ int FindR64COPYRel(elfheader_t* h, const char* name, uintptr_t *offs, uint64_t**
if(t==R_X86_64_COPY && symname && !strcmp(symname, name) && sym->st_size==size) {
int version2 = h->VerSym?((Elf64_Half*)((uintptr_t)h->VerSym+h->delta))[ELF64_R_SYM(rela[i].r_info)]:-1;
if(version2!=-1) version2 &= 0x7fff;
- if(version && !version2) version2=-1; // match a versionned symbol against a global "local" symbol
+ if(version && !version2) version2=-1; // match a versioned symbol against a global "local" symbol
const char* vername2 = GetSymbolVersion(h, version2);
- if(SameVersionnedSymbol(name, version, vername, symname, version2, vername2)) {
+ if(SameVersionedSymbol(name, version, vername, symname, version2, vername2)) {
*offs = sym->st_value + h->delta;
*p = (uint64_t*)(rela[i].r_offset + h->delta + rela[i].r_addend);
return 1;
@@ -430,30 +470,40 @@ int RelocateElfREL(lib_t *maplib, lib_t *local_maplib, int bindnow, elfheader_t*
int version = head->VerSym?((Elf64_Half*)((uintptr_t)head->VerSym+head->delta))[ELF64_R_SYM(rel[i].r_info)]:-1;
if(version!=-1) version &=0x7fff;
const char* vername = GetSymbolVersion(head, version);
- const char* defver = GetDefaultVersion((bind==STB_WEAK)?my_context->weakdefver:my_context->globaldefver, symname);
+ const char* globdefver = (bind==STB_WEAK)?NULL:GetMaplibDefaultVersion(maplib, local_maplib, 0, symname);
+ const char* weakdefver = (bind==STB_WEAK)?GetMaplibDefaultVersion(maplib, local_maplib, 1, symname):NULL;
if(bind==STB_LOCAL) {
if(!symname || !symname[0]) {
offs = sym->st_value + head->delta;
end = offs + sym->st_size;
} else {
if(!offs && !end && local_maplib)
- GetLocalSymbolStartEnd(local_maplib, symname, &offs, &end, head, version, vername);
+ GetLocalSymbolStartEnd(local_maplib, symname, &offs, &end, head, version, vername, globdefver, weakdefver);
if(!offs && !end)
- GetLocalSymbolStartEnd(maplib, symname, &offs, &end, head, version, vername);
+ GetLocalSymbolStartEnd(maplib, symname, &offs, &end, head, version, vername, globdefver, weakdefver);
}
} else {
- // this is probably very very wrong. A proprer way to get reloc need to be writen, but this hack seems ok for now
+ // this is probably very very wrong. A proprer way to get reloc need to be written, but this hack seems ok for now
// at least it work for half-life, unreal, ut99, zsnes, Undertale, ColinMcRae Remake, FTL, ShovelKnight...
/*if(bind==STB_GLOBAL && (ndx==10 || ndx==19) && t!=R_X86_64_GLOB_DAT) {
offs = sym->st_value + head->delta;
end = offs + sym->st_size;
}*/
// so weak symbol are the one left
- if(!offs && !end) {
- if(!offs && !end && local_maplib)
- GetGlobalSymbolStartEnd(local_maplib, symname, &offs, &end, head, version, vername);
- if(!offs && !end && local_maplib)
- GetGlobalSymbolStartEnd(maplib, symname, &offs, &end, head, version, vername);
+ if(bind==STB_WEAK) {
+ if(!offs && !end) {
+ if(!offs && !end && local_maplib)
+ GetGlobalWeakSymbolStartEnd(local_maplib, symname, &offs, &end, head, version, vername, globdefver, weakdefver);
+ if(!offs && !end && local_maplib)
+ GetGlobalWeakSymbolStartEnd(maplib, symname, &offs, &end, head, version, vername, globdefver, weakdefver);
+ }
+ } else {
+ if(!offs && !end) {
+ if(!offs && !end && local_maplib)
+ GetGlobalSymbolStartEnd(local_maplib, symname, &offs, &end, head, version, vername, globdefver, weakdefver);
+ if(!offs && !end && local_maplib)
+ GetGlobalSymbolStartEnd(maplib, symname, &offs, &end, head, version, vername, globdefver, weakdefver);
+ }
}
}
uintptr_t globoffs, globend;
@@ -474,21 +524,22 @@ int RelocateElfREL(lib_t *maplib, lib_t *local_maplib, int bindnow, elfheader_t*
*p += offs;
break;
case R_X86_64_GLOB_DAT:
- if(head!=my_context->elfs[0] && !IsGlobalNoWeakSymbolInNative(maplib, symname, version, vername) && FindR64COPYRel(my_context->elfs[0], symname, &globoffs, &globp, size, version, vername)) {
+ if(head!=my_context->elfs[0] && !IsGlobalNoWeakSymbolInNative(maplib, symname, version, vername, globdefver) && FindR64COPYRel(my_context->elfs[0], symname, &globoffs, &globp, size, version, vername)) {
// set global offs / size for the symbol
offs = sym->st_value;
end = offs + sym->st_size;
if(sym->st_size && offs) {
printf_dump(LOG_NEVER, "Apply %s R_X86_64_GLOB_DAT with R_X86_64_COPY @%p/%p (%p/%p -> %p/%p) size=%ld on sym=%s \n", (bind==STB_LOCAL)?"Local":"Global", p, globp, (void*)(p?(*p):0), (void*)(globp?(*globp):0), (void*)(offs + head->delta), (void*)globoffs, sym->st_size, symname);
memmove((void*)globoffs, (void*)offs, sym->st_size); // preapply to copy part from lib to main elf
- AddUniqueSymbol(GetGlobalData(maplib), symname, offs + head->delta, sym->st_size, version, vername);
+ AddUniqueSymbol(GetGlobalData(maplib), symname, globoffs, sym->st_size, version, vername);
+ AddUniqueSymbol(my_context->globdata, symname, offs + head->delta, sym->st_size, version, vername);
} else {
printf_dump(LOG_NEVER, "Apply %s R_X86_64_GLOB_DAT with R_X86_64_COPY @%p/%p (%p/%p -> %p/%p) null sized on sym=%s \n", (bind==STB_LOCAL)?"Local":"Global", p, globp, (void*)(p?(*p):0), (void*)(globp?(*globp):0), (void*)offs, (void*)globoffs, symname);
}
*p = globoffs;
} else {
// Look for same symbol already loaded but not in self (so no need for local_maplib here)
- if (GetGlobalNoWeakSymbolStartEnd(local_maplib?local_maplib:maplib, symname, &globoffs, &globend, version, vername)) {
+ if (GetGlobalNoWeakSymbolStartEnd(local_maplib?local_maplib:maplib, symname, &globoffs, &globend, version, vername, globdefver)) {
offs = globoffs;
end = globend;
}
@@ -506,11 +557,11 @@ int RelocateElfREL(lib_t *maplib, lib_t *local_maplib, int bindnow, elfheader_t*
uintptr_t old_offs = offs;
uintptr_t old_end = end;
offs = 0;
- GetSizedSymbolStartEnd(GetGlobalData(maplib), symname, &offs, &end, size, version, vername, 1, defver); // try globaldata symbols first
+ GetSizedSymbolStartEnd(my_context->globdata, symname, &offs, &end, size, version, vername, 1, globdefver); // try globaldata symbols first
if(offs==0) {
- GetNoSelfSymbolStartEnd(maplib, symname, &offs, &end, head, size, version, vername); // get original copy if any
+ GetNoSelfSymbolStartEnd(maplib, symname, &offs, &end, head, size, version, vername, globdefver, weakdefver); // get original copy if any
if(!offs && local_maplib)
- GetNoSelfSymbolStartEnd(local_maplib, symname, &offs, &end, head, size, version, vername);
+ GetNoSelfSymbolStartEnd(local_maplib, symname, &offs, &end, head, size, version, vername, globdefver, weakdefver);
}
if(!offs) {
offs = old_offs;
@@ -534,8 +585,9 @@ int RelocateElfREL(lib_t *maplib, lib_t *local_maplib, int bindnow, elfheader_t*
break;
case R_X86_64_64:
if (!offs) {
- printf_log(LOG_NONE, "Error: Symbol %s not found, cannot apply R_X86_64_64 @%p (%p) in %s\n", symname, p, *(void**)p, head->name);
- ret_ok = 1;
+ printf_log(LOG_NONE, "%s: Symbol %s not found, cannot apply R_X86_64_64 @%p (%p) in %s\n", (bind==STB_GLOBAL)?"Error":"Warning", symname, p, *(void**)p, head->name);
+ if(bind==STB_GLOBAL)
+ ret_ok = 1;
// return -1;
} else {
printf_dump(LOG_NEVER, "Apply %s R_X86_64_64 @%p with sym=%s (%p -> %p)\n", (bind==STB_LOCAL)?"Local":"Global", p, symname, *(void**)p, (void*)(offs+*(uint64_t*)p));
@@ -596,6 +648,13 @@ EXPORT uintptr_t _dl_tlsdesc_undefweak(x64emu_t* emu)
int RelocateElfRELA(lib_t *maplib, lib_t *local_maplib, int bindnow, elfheader_t* head, int cnt, Elf64_Rela *rela, int* need_resolv)
{
int ret_ok = 0;
+ const char* old_globdefver = NULL;
+ const char* old_weakdefver = NULL;
+ int old_bind = -1;
+ const char* old_symname = NULL;
+ uintptr_t old_offs = 0;
+ uintptr_t old_end = 0;
+ int old_version = -1;
for (int i=0; i<cnt; ++i) {
int t = ELF64_R_TYPE(rela[i].r_info);
Elf64_Sym *sym = &head->DynSym[ELF64_R_SYM(rela[i].r_info)];
@@ -610,32 +669,62 @@ int RelocateElfRELA(lib_t *maplib, lib_t *local_maplib, int bindnow, elfheader_t
int version = head->VerSym?((Elf64_Half*)((uintptr_t)head->VerSym+head->delta))[ELF64_R_SYM(rela[i].r_info)]:-1;
if(version!=-1) version &=0x7fff;
const char* vername = GetSymbolVersion(head, version);
- const char* defver = GetDefaultVersion((bind==STB_WEAK)?my_context->weakdefver:my_context->globaldefver, symname);
+ const char* globdefver = NULL;
+ const char* weakdefver = NULL;
+ if(old_bind==bind && old_symname==symname) {
+ globdefver = old_globdefver;
+ weakdefver = old_weakdefver;
+ } else {
+ old_globdefver = globdefver = (bind==STB_WEAK)?NULL:GetMaplibDefaultVersion(maplib, local_maplib, 0, symname);
+ old_weakdefver = weakdefver = (bind==STB_WEAK)?GetMaplibDefaultVersion(maplib, local_maplib, 1, symname):NULL;
+ }
if(bind==STB_LOCAL) {
if(!symname || !symname[0]) {
offs = sym->st_value + head->delta;
end = offs + sym->st_size;
} else {
- if(!offs && !end && local_maplib)
- GetLocalSymbolStartEnd(local_maplib, symname, &offs, &end, head, version, vername);
- if(!offs && !end)
- GetLocalSymbolStartEnd(maplib, symname, &offs, &end, head, version, vername);
+ if(old_version==version && old_bind==bind && old_symname==symname) {
+ offs = old_offs;
+ end = old_end;
+ } else {
+ if(local_maplib)
+ GetLocalSymbolStartEnd(local_maplib, symname, &offs, &end, head, version, vername, globdefver, weakdefver);
+ if(!offs && !end)
+ GetLocalSymbolStartEnd(maplib, symname, &offs, &end, head, version, vername, globdefver, weakdefver);
+ }
}
} else {
- // this is probably very very wrong. A proprer way to get reloc need to be writen, but this hack seems ok for now
+ // this is probably very very wrong. A proprer way to get reloc need to be written, but this hack seems ok for now
// at least it work for half-life, unreal, ut99, zsnes, Undertale, ColinMcRae Remake, FTL, ShovelKnight...
/*if(bind==STB_GLOBAL && (ndx==10 || ndx==19) && t!=R_X86_64_GLOB_DAT) {
offs = sym->st_value + head->delta;
end = offs + sym->st_size;
}*/
// so weak symbol are the one left
- if(!offs && !end) {
- GetGlobalSymbolStartEnd(maplib, symname, &offs, &end, head, version, vername);
- if(!offs && !end && local_maplib) {
- GetGlobalSymbolStartEnd(local_maplib, symname, &offs, &end, head, version, vername);
+ if(bind==STB_WEAK) {
+ if(old_version==version && old_bind==bind && old_symname==symname) {
+ offs = old_offs;
+ end = old_end;
+ } else {
+ GetGlobalWeakSymbolStartEnd(maplib, symname, &offs, &end, head, version, vername, globdefver, weakdefver);
+ if(!offs && !end && local_maplib)
+ GetGlobalWeakSymbolStartEnd(local_maplib, symname, &offs, &end, head, version, vername, globdefver, weakdefver);
+ }
+ } else {
+ if(old_version==version && old_bind==bind && old_symname==symname) {
+ offs = old_offs;
+ end = old_end;
+ } else {
+ GetGlobalSymbolStartEnd(maplib, symname, &offs, &end, head, version, vername, globdefver, weakdefver);
+ if(!offs && !end && local_maplib)
+ GetGlobalSymbolStartEnd(local_maplib, symname, &offs, &end, head, version, vername, globdefver, weakdefver);
}
}
}
+ old_bind = bind;
+ old_symname = symname;
+ old_offs = offs;
+ old_end = end;
uintptr_t globoffs, globend;
uint64_t* globp;
uintptr_t tmp = 0;
@@ -663,11 +752,11 @@ int RelocateElfRELA(lib_t *maplib, lib_t *local_maplib, int bindnow, elfheader_t
globoffs = offs;
globend = end;
offs = end = 0;
- GetSizedSymbolStartEnd(GetGlobalData(maplib), symname, &offs, &end, size, version, vername, 1, defver); // try globaldata symbols first
+ GetSizedSymbolStartEnd(my_context->globdata, symname, &offs, &end, size, version, vername, 1, globdefver); // try globaldata symbols first
if(!offs && local_maplib)
- GetNoSelfSymbolStartEnd(local_maplib, symname, &offs, &end, head, size, version, vername);
+ GetNoSelfSymbolStartEnd(local_maplib, symname, &offs, &end, head, size, version, vername, globdefver, weakdefver);
if(!offs)
- GetNoSelfSymbolStartEnd(maplib, symname, &offs, &end, head, size, version, vername);
+ GetNoSelfSymbolStartEnd(maplib, symname, &offs, &end, head, size, version, vername, globdefver, weakdefver);
if(!offs) {offs = globoffs; end = globend;}
if(offs) {
// add r_addend to p?
@@ -679,7 +768,7 @@ int RelocateElfRELA(lib_t *maplib, lib_t *local_maplib, int bindnow, elfheader_t
}
break;
case R_X86_64_GLOB_DAT:
- if(head!=my_context->elfs[0] && !IsGlobalNoWeakSymbolInNative(maplib, symname, version, vername) && FindR64COPYRel(my_context->elfs[0], symname, &globoffs, &globp, size, version, vername)) {
+ if(head!=my_context->elfs[0] && !IsGlobalNoWeakSymbolInNative(maplib, symname, version, vername, globdefver) && FindR64COPYRel(my_context->elfs[0], symname, &globoffs, &globp, size, version, vername)) {
// set global offs / size for the symbol
offs = sym->st_value + head->delta;
end = offs + sym->st_size;
@@ -688,7 +777,8 @@ int RelocateElfRELA(lib_t *maplib, lib_t *local_maplib, int bindnow, elfheader_t
(bind==STB_LOCAL)?"Local":"Global", p, globp, (void*)(p?(*p):0),
(void*)(globp?(*globp):0), (void*)offs, (void*)globoffs, sym->st_size, symname, version, vername?vername:"(none)");
//memmove((void*)globoffs, (void*)offs, sym->st_size); // preapply to copy part from lib to main elf
- AddUniqueSymbol(GetGlobalData(maplib), symname, offs, sym->st_size, version, vername);
+ AddUniqueSymbol(GetGlobalData(maplib), symname, globoffs, sym->st_size, version, vername);
+ AddUniqueSymbol(my_context->globdata, symname, offs, sym->st_size, version, vername);
} else {
printf_dump(LOG_NEVER, "Apply %s R_X86_64_GLOB_DAT with R_X86_64_COPY @%p/%p (%p/%p -> %p/%p) null sized on sym=%s (ver=%d/%s)\n",
(bind==STB_LOCAL)?"Local":"Global", p, globp, (void*)(p?(*p):0),
@@ -697,7 +787,7 @@ int RelocateElfRELA(lib_t *maplib, lib_t *local_maplib, int bindnow, elfheader_t
*p = globoffs;
} else {
// Look for same symbol already loaded but not in self (so no need for local_maplib here)
- if (GetGlobalNoWeakSymbolStartEnd(local_maplib?local_maplib:maplib, symname, &globoffs, &globend, version, vername)) {
+ if (GetGlobalNoWeakSymbolStartEnd(local_maplib?local_maplib:maplib, symname, &globoffs, &globend, version, vername, globdefver)) {
offs = globoffs;
end = globend;
}
@@ -750,8 +840,9 @@ int RelocateElfRELA(lib_t *maplib, lib_t *local_maplib, int bindnow, elfheader_t
if(symname && !strcmp(symname, "__gxx_personality_v0")) {
printf_dump(LOG_NEVER, "Warning: Symbol %s not found, cannot apply R_X86_64_64 @%p (%p) in %s\n", symname, p, *(void**)p, head->name);
} else {
- printf_log(LOG_NONE, "Error: Symbol %s not found, cannot apply R_X86_64_64 @%p (%p) in %s\n", symname, p, *(void**)p, head->name);
- ret_ok = 1;
+ printf_log(LOG_INFO, "%s: Symbol %s not found, cannot apply R_X86_64_64 @%p (%p) in %s\n", (bind==STB_GLOBAL)?"Error":"Warning", symname, p, *(void**)p, head->name);
+ if(bind==STB_GLOBAL)
+ ret_ok = 1;
// return -1;
}
} else {
@@ -799,7 +890,7 @@ int RelocateElfRELA(lib_t *maplib, lib_t *local_maplib, int bindnow, elfheader_t
printf_dump(LOG_NEVER, "Apply %s %s @%p with sym=%s (%p -> %p)\n", (bind==STB_LOCAL)?"Local":"Global", "R_X86_64_DTPMOD64", p, symname, *(void**)p, (void*)offs);
*p = offs;
} else {
- printf_log(LOG_NONE, "Warning, Symbol %s or Elf not found, but R_X86_64_DTPMOD64 Slot Offset is NULL \n", symname);
+ printf_log(LOG_INFO, "Warning, Symbol %s or Elf not found, but R_X86_64_DTPMOD64 Slot Offset is NULL \n", symname);
}
break;
case R_X86_64_DTPOFF64:
@@ -808,7 +899,7 @@ int RelocateElfRELA(lib_t *maplib, lib_t *local_maplib, int bindnow, elfheader_t
if(bind==STB_WEAK) {
printf_log(LOG_INFO, "Warning: Weak Symbol %s not found, cannot apply R_X86_64_DTPOFF64 @%p (%p)\n", symname, p, *(void**)p);
} else {
- printf_log(LOG_NONE, "Error: Symbol %s not found, cannot apply R_X86_64_DTPOFF64 @%p (%p) in %s\n", symname, p, *(void**)p, head->name);
+ printf_log(LOG_INFO, "Error: Symbol %s not found, cannot apply R_X86_64_DTPOFF64 @%p (%p) in %s\n", symname, p, *(void**)p, head->name);
}
// return -1;
} else {
@@ -819,7 +910,7 @@ int RelocateElfRELA(lib_t *maplib, lib_t *local_maplib, int bindnow, elfheader_t
printf_dump(LOG_NEVER, "Apply %s R_X86_64_DTPOFF64 @%p with sym=%s (%p -> %p)\n", (bind==STB_LOCAL)?"Local":"Global", p, symname, (void*)tlsoffset, (void*)offs);
*p = tlsoffset;
} else {
- printf_log(LOG_NONE, "Warning, Symbol %s found, but R_X86_64_DTPOFF64 Slot Offset is NULL \n", symname);
+ printf_log(LOG_INFO, "Warning, Symbol %s found, but R_X86_64_DTPOFF64 Slot Offset is NULL \n", symname);
}
}
break;
@@ -832,7 +923,7 @@ int RelocateElfRELA(lib_t *maplib, lib_t *local_maplib, int bindnow, elfheader_t
td->entry = tlsdescUndefweak;
td->arg = (uintptr_t)(head->tlsbase + rela[i].r_addend);
} else {
- printf_log(LOG_NONE, "Warning, R_X86_64_TLSDESC used with Symbol %s(%p) not supported for now \n", symname, sym);
+ printf_log(LOG_INFO, "Warning, R_X86_64_TLSDESC used with Symbol %s(%p) not supported for now \n", symname, sym);
}
break;
default:
@@ -841,9 +932,12 @@ int RelocateElfRELA(lib_t *maplib, lib_t *local_maplib, int bindnow, elfheader_t
}
return bindnow?ret_ok:0;
}
-void checkHookedSymbols(lib_t *maplib, elfheader_t* h); // in mallochook.c
int RelocateElf(lib_t *maplib, lib_t *local_maplib, int bindnow, elfheader_t* head)
{
+ if((head->flags&DF_BIND_NOW) && !bindnow) {
+ bindnow = 1;
+ printf_log(LOG_DEBUG, "Forcing %s to Bind Now\n", head->name);
+ }
if(head->rel) {
int cnt = head->relsz / head->relent;
DumpRelTable(head, cnt, (Elf64_Rel *)(head->rel + head->delta), "Rel");
@@ -858,13 +952,16 @@ int RelocateElf(lib_t *maplib, lib_t *local_maplib, int bindnow, elfheader_t* he
if(RelocateElfRELA(maplib, local_maplib, bindnow, head, cnt, (Elf64_Rela *)(head->rela + head->delta), NULL))
return -1;
}
- checkHookedSymbols(maplib, head);
return 0;
}
int RelocateElfPlt(lib_t *maplib, lib_t *local_maplib, int bindnow, elfheader_t* head)
{
int need_resolver = 0;
+ if((head->flags&DF_BIND_NOW) && !bindnow) {
+ bindnow = 1;
+ printf_log(LOG_DEBUG, "Forcing %s to Bind Now\n", head->name);
+ }
if(head->pltrel) {
int cnt = head->pltsz / head->pltent;
if(head->pltrel==DT_REL) {
@@ -963,6 +1060,7 @@ uintptr_t GetLastByte(elfheader_t* h)
return (uintptr_t)h->memory/* + h->delta*/ + h->memsz;
}
+void checkHookedSymbols(elfheader_t* h); // in mallochook.c
void AddSymbols(lib_t *maplib, kh_mapsymbols_t* mapsymbols, kh_mapsymbols_t* weaksymbols, kh_mapsymbols_t* localsymbols, elfheader_t* h)
{
if(box64_dump && h->DynSym) DumpDynSym(h);
@@ -976,19 +1074,19 @@ void AddSymbols(lib_t *maplib, kh_mapsymbols_t* mapsymbols, kh_mapsymbols_t* wea
if((type==STT_OBJECT || type==STT_FUNC || type==STT_COMMON || type==STT_TLS || type==STT_NOTYPE)
&& (vis==STV_DEFAULT || vis==STV_PROTECTED || (vis==STV_HIDDEN && bind==STB_LOCAL)) && (h->SymTab[i].st_shndx!=0)) {
if(sz && strstr(symname, "@@")) {
- char symnameversionned[strlen(symname)+1];
- strcpy(symnameversionned, symname);
+ char symnameversioned[strlen(symname)+1];
+ strcpy(symnameversioned, symname);
// extact symname@@vername
- char* p = strchr(symnameversionned, '@');
+ char* p = strchr(symnameversioned, '@');
*p=0;
p+=2;
- symname = AddDictionnary(my_context->versym, symnameversionned);
+ symname = AddDictionnary(my_context->versym, symnameversioned);
const char* vername = AddDictionnary(my_context->versym, p);
- AddDefaultVersion((bind==STB_WEAK)?my_context->weakdefver:my_context->globaldefver, symname, vername);
+ AddDefaultVersion((bind==STB_WEAK)?h->weakdefver:h->globaldefver, symname, vername);
if((bind==STB_GNU_UNIQUE /*|| (bind==STB_GLOBAL && type==STT_FUNC)*/) && FindGlobalSymbol(maplib, symname, 2, p))
continue;
uintptr_t offs = (type==STT_TLS)?h->SymTab[i].st_value:(h->SymTab[i].st_value + h->delta);
- printf_dump(LOG_NEVER, "Adding Default Versionned Symbol(bind=%s) \"%s@%s\" with offset=%p sz=%zu\n", (bind==STB_LOCAL)?"LOCAL":((bind==STB_WEAK)?"WEAK":"GLOBAL"), symname, vername, (void*)offs, sz);
+ printf_dump(LOG_NEVER, "Adding Default Versioned Symbol(bind=%s) \"%s@%s\" with offset=%p sz=%zu\n", (bind==STB_LOCAL)?"LOCAL":((bind==STB_WEAK)?"WEAK":"GLOBAL"), symname, vername, (void*)offs, sz);
if(bind==STB_LOCAL)
AddSymbol(localsymbols, symname, offs, sz, 2, vername);
else // add in local and global map
@@ -1026,17 +1124,17 @@ void AddSymbols(lib_t *maplib, kh_mapsymbols_t* mapsymbols, kh_mapsymbols_t* wea
uintptr_t offs = (type==STT_TLS)?h->DynSym[i].st_value:(h->DynSym[i].st_value + h->delta);
size_t sz = h->DynSym[i].st_size;
int version = h->VerSym?((Elf64_Half*)((uintptr_t)h->VerSym+h->delta))[i]:-1;
- int add_default = (version!=-1 && (version&0x7fff)>1 && !(version&0x8000) && !GetDefaultVersion((bind==STB_WEAK)?my_context->weakdefver:my_context->globaldefver, symname))?1:0;
+ int add_default = (version!=-1 && (version&0x7fff)>1 && !(version&0x8000) && !GetMaplibDefaultVersion(my_context->maplib, (maplib==my_context->maplib)?NULL:maplib, (bind==STB_WEAK)?1:0, symname))?1:0;
if(version!=-1) version &= 0x7fff;
const char* vername = GetSymbolVersion(h, version);
if(add_default) {
- AddDefaultVersion((bind==STB_WEAK)?my_context->weakdefver:my_context->globaldefver, symname, vername);
+ AddDefaultVersion((bind==STB_WEAK)?h->weakdefver:h->globaldefver, symname, vername);
printf_dump(LOG_NEVER, "Adding Default Version \"%s\" for Symbol\"%s\"\n", vername, symname);
}
int to_add = 1;
if(!to_add || (bind==STB_GNU_UNIQUE && FindGlobalSymbol(maplib, symname, version, vername)))
continue;
- printf_dump(LOG_NEVER, "Adding Versionned Symbol(bind=%s) \"%s\" (ver=%d/%s) with offset=%p sz=%zu\n", (bind==STB_LOCAL)?"LOCAL":((bind==STB_WEAK)?"WEAK":"GLOBAL"), symname, version, vername?vername:"(none)", (void*)offs, sz);
+ printf_dump(LOG_NEVER, "Adding Versioned Symbol(bind=%s) \"%s\" (ver=%d/%s) with offset=%p sz=%zu\n", (bind==STB_LOCAL)?"LOCAL":((bind==STB_WEAK)?"WEAK":"GLOBAL"), symname, version, vername?vername:"(none)", (void*)offs, sz);
if(bind==STB_LOCAL)
AddSymbol(localsymbols, symname, offs, sz, version, vername);
else // add in local and global map
@@ -1047,6 +1145,7 @@ void AddSymbols(lib_t *maplib, kh_mapsymbols_t* mapsymbols, kh_mapsymbols_t* wea
}
}
}
+ checkHookedSymbols(h);
}
/*
@@ -1127,9 +1226,13 @@ int LoadNeededLibs(elfheader_t* h, lib_t *maplib, int local, int bindnow, box64c
DumpDynamicNeeded(h);
int cnt = 0;
- for (int i=0; i<h->numDynamic; ++i)
+ // count the number of needed libs, and also grab soname
+ for (int i=0; i<h->numDynamic; ++i) {
if(h->Dynamic[i].d_tag==DT_NEEDED)
++cnt;
+ if(h->Dynamic[i].d_tag==DT_SONAME)
+ h->soname = h->DynStrTab+h->delta+h->Dynamic[i].d_un.d_val;
+ }
h->needed = new_neededlib(cnt);
if(h == my_context->elfs[0])
my_context->neededlibs = h->needed;
@@ -1139,7 +1242,7 @@ int LoadNeededLibs(elfheader_t* h, lib_t *maplib, int local, int bindnow, box64c
h->needed->names[j++] = h->DynStrTab+h->delta+h->Dynamic[i].d_un.d_val;
// TODO: Add LD_LIBRARY_PATH and RPATH handling
- if(AddNeededLib(maplib, local, bindnow, h->needed, box64, emu)) {
+ if(AddNeededLib(maplib, local, bindnow, h->needed, h, box64, emu)) {
printf_log(LOG_INFO, "Error loading one of needed lib\n");
if(!allow_missing_libs)
return 1; //error...
@@ -1184,6 +1287,7 @@ void MarkElfInitDone(elfheader_t* h)
if(h)
h->init_done = 1;
}
+void startMallocHook();
void RunElfInitPltResolver(elfheader_t* h, x64emu_t *emu)
{
if(!h || h->init_done)
@@ -1198,17 +1302,20 @@ void RunElfInitPltResolver(elfheader_t* h, x64emu_t *emu)
}
printf_dump(LOG_DEBUG, "Calling Init for %s @%p\n", ElfName(h), (void*)p);
if(h->initentry)
- RunSafeFunction(my_context, p, 3, my_context->argc, my_context->argv, my_context->envv);
+ RunSafeFunction(p, 3, my_context->argc, my_context->argv, my_context->envv);
printf_dump(LOG_DEBUG, "Done Init for %s\n", ElfName(h));
// and check init array now
Elf64_Addr *addr = (Elf64_Addr*)(h->initarray + h->delta);
for (size_t i=0; i<h->initarray_sz; ++i) {
if(addr[i]) {
printf_dump(LOG_DEBUG, "Calling Init[%zu] for %s @%p\n", i, ElfName(h), (void*)addr[i]);
- RunSafeFunction(my_context, (uintptr_t)addr[i], 3, my_context->argc, my_context->argv, my_context->envv);
+ RunSafeFunction((uintptr_t)addr[i], 3, my_context->argc, my_context->argv, my_context->envv);
}
}
+ if(h->malloc_hook_2)
+ startMallocHook();
+
h->fini_done = 0; // can be fini'd now (in case it was re-inited)
printf_dump(LOG_DEBUG, "All Init Done for %s\n", ElfName(h));
return;
@@ -1224,13 +1331,13 @@ void RunElfInit(elfheader_t* h, x64emu_t *emu)
box64context_t* context = GetEmuContext(emu);
// Refresh no-file part of TLS in case default value changed
RefreshElfTLS(h);
- // check if in deferedInit
- if(context->deferedInit) {
- if(context->deferedInitSz==context->deferedInitCap) {
- context->deferedInitCap += 4;
- context->deferedInitList = (elfheader_t**)box_realloc(context->deferedInitList, context->deferedInitCap*sizeof(elfheader_t*));
+ // check if in deferredInit
+ if(context->deferredInit) {
+ if(context->deferredInitSz==context->deferredInitCap) {
+ context->deferredInitCap += 4;
+ context->deferredInitList = (elfheader_t**)box_realloc(context->deferredInitList, context->deferredInitCap*sizeof(elfheader_t*));
}
- context->deferedInitList[context->deferedInitSz++] = h;
+ context->deferredInitList[context->deferredInitSz++] = h;
return;
}
h->init_done = 1;
@@ -1253,24 +1360,27 @@ void RunElfInit(elfheader_t* h, x64emu_t *emu)
}
}
+ if(h->malloc_hook_2)
+ startMallocHook();
+
h->fini_done = 0; // can be fini'd now (in case it was re-inited)
printf_dump(LOG_DEBUG, "All Init Done for %s\n", ElfName(h));
return;
}
EXPORTDYN
-void RunDeferedElfInit(x64emu_t *emu)
+void RunDeferredElfInit(x64emu_t *emu)
{
box64context_t* context = GetEmuContext(emu);
- if(!context->deferedInit)
+ if(!context->deferredInit)
return;
- context->deferedInit = 0;
- if(!context->deferedInitList)
+ context->deferredInit = 0;
+ if(!context->deferredInitList)
return;
- int Sz = context->deferedInitSz;
- elfheader_t** List = context->deferedInitList;
- context->deferedInitList = NULL;
- context->deferedInitCap = context->deferedInitSz = 0;
+ int Sz = context->deferredInitSz;
+ elfheader_t** List = context->deferredInitList;
+ context->deferredInitList = NULL;
+ context->deferredInitCap = context->deferredInitSz = 0;
for (int i=0; i<Sz; ++i)
RunElfInit(List[i], emu);
box_free(List);
@@ -1278,7 +1388,7 @@ void RunDeferedElfInit(x64emu_t *emu)
void RunElfFini(elfheader_t* h, x64emu_t *emu)
{
- if(!h || h->fini_done)
+ if(!h || h->fini_done || !h->init_done)
return;
h->fini_done = 1;
// first check fini array
@@ -1294,8 +1404,6 @@ void RunElfFini(elfheader_t* h, x64emu_t *emu)
RunFunctionWithEmu(emu, 0, p, 0);
}
h->init_done = 0; // can be re-inited again...
- for(int i=0; i<h->needed->size; ++i)
- FiniLibrary(h->needed->libs[i], emu);
return;
}
@@ -1407,7 +1515,7 @@ const char* FindNearestSymbolName(elfheader_t* h, void* p, uintptr_t* start, uin
return ret;
}
-const char* VersionnedName(const char* name, int ver, const char* vername)
+const char* VersionedName(const char* name, int ver, const char* vername)
{
if(ver==-1)
return name;
@@ -1427,7 +1535,7 @@ const char* VersionnedName(const char* name, int ver, const char* vername)
return AddDictionnary(my_context->versym, buf);
}
-int SameVersionnedSymbol(const char* name1, int ver1, const char* vername1, const char* name2, int ver2, const char* vername2)
+int SameVersionedSymbol(const char* name1, int ver1, const char* vername1, const char* name2, int ver2, const char* vername2)
{
if(strcmp(name1, name2)) //name are different, no need to go further
return 0;
@@ -1451,24 +1559,19 @@ void* GetDTatOffset(box64context_t* context, unsigned long int index, unsigned l
int32_t GetTLSBase(elfheader_t* h)
{
- return h->tlsbase;
+ return h?h->tlsbase:0;
}
uint32_t GetTLSSize(elfheader_t* h)
{
- return h->tlssize;
+ return h?h->tlssize:0;
}
void* GetTLSPointer(box64context_t* context, elfheader_t* h)
{
- if(!h->tlssize)
+ if(!h || !h->tlssize)
return NULL;
- tlsdatasize_t* ptr;
- if ((ptr = (tlsdatasize_t*)pthread_getspecific(context->tlskey)) == NULL) {
- ptr = (tlsdatasize_t*)fillTLSData(context);
- }
- if(ptr->tlssize != context->tlssize)
- ptr = (tlsdatasize_t*)resizeTLSData(context, ptr);
+ tlsdatasize_t* ptr = getTLSData(context);
return ptr->data+h->tlsbase;
}
@@ -1532,7 +1635,7 @@ static int my_dl_iterate_phdr_##A(struct dl_phdr_info* a, size_t b, void* c)
return 0; \
if(!a->dlpi_name[0]) /*don't send informations about box64 itself*/ \
return 0; \
- return (int)RunFunction(my_context, my_dl_iterate_phdr_fct_##A, 3, a, b, c); \
+ return (int)RunFunction(my_dl_iterate_phdr_fct_##A, 3, a, b, c); \
}
SUPER()
#undef GO
@@ -1557,13 +1660,15 @@ EXPORT int my_dl_iterate_phdr(x64emu_t *emu, void* F, void *data) {
const char* empty = "";
int ret = 0;
for (int idx=0; idx<context->elfsize; ++idx) {
- my_dl_phdr_info_t info;
- info.dlpi_addr = GetElfDelta(context->elfs[idx]);
- info.dlpi_name = idx?context->elfs[idx]->name:empty; //1st elf is program, and this one doesn't get a name
- info.dlpi_phdr = context->elfs[idx]->PHEntries;
- info.dlpi_phnum = context->elfs[idx]->numPHEntries;
- if((ret = dl_iterate_phdr_callback(emu, F, &info, sizeof(info), data))) {
- return ret;
+ if(context->elfs[idx]) {
+ my_dl_phdr_info_t info;
+ info.dlpi_addr = GetElfDelta(context->elfs[idx]);
+ info.dlpi_name = idx?context->elfs[idx]->name:empty; //1st elf is program, and this one doesn't get a name
+ info.dlpi_phdr = context->elfs[idx]->PHEntries;
+ info.dlpi_phnum = context->elfs[idx]->numPHEntries;
+ if((ret = dl_iterate_phdr_callback(emu, F, &info, sizeof(info), data))) {
+ return ret;
+ }
}
}
// and now, go on native version
@@ -1737,7 +1842,7 @@ int dl_iterate_phdr_findsymbol(struct dl_phdr_info* info, size_t size, void* dat
return 0;
}
-void* GetNativeSymbolUnversionned(void* lib, const char* name)
+void* GetNativeSymbolUnversioned(void* lib, const char* name)
{
// try to find "name" in loaded elf, whithout checking for the symbol version (like dlsym, but no version check)
search_symbol_t s;
@@ -1752,6 +1857,16 @@ void* GetNativeSymbolUnversionned(void* lib, const char* name)
return s.addr;
}
+kh_defaultversion_t* GetGlobalDefaultVersion(elfheader_t* h)
+{
+ return h?h->globaldefver:NULL;
+}
+kh_defaultversion_t* GetWeakDefaultVersion(elfheader_t* h)
+{
+ return h?h->weakdefver:NULL;
+}
+
+
uintptr_t pltResolver = ~0LL;
EXPORT void PltResolver(x64emu_t* emu)
{
@@ -1774,12 +1889,14 @@ EXPORT void PltResolver(x64emu_t* emu)
library_t* lib = h->lib;
lib_t* local_maplib = GetMaplib(lib);
- GetGlobalSymbolStartEnd(my_context->maplib, symname, &offs, &end, h, version, vername);
+ const char* globdefver = (bind==STB_WEAK)?NULL:GetMaplibDefaultVersion(my_context->maplib, (my_context->maplib==local_maplib)?NULL:local_maplib, 0, symname);
+ const char* weakdefver = (bind==STB_WEAK)?GetMaplibDefaultVersion(my_context->maplib, (my_context->maplib==local_maplib)?NULL:local_maplib, 1, symname):NULL;
+ GetGlobalSymbolStartEnd(my_context->maplib, symname, &offs, &end, h, version, vername, globdefver, weakdefver);
if(!offs && !end && local_maplib) {
- GetGlobalSymbolStartEnd(local_maplib, symname, &offs, &end, h, version, vername);
+ GetGlobalSymbolStartEnd(local_maplib, symname, &offs, &end, h, version, vername, globdefver, weakdefver);
}
if(!offs && !end && !version)
- GetGlobalSymbolStartEnd(my_context->maplib, symname, &offs, &end, h, -1, NULL);
+ GetGlobalSymbolStartEnd(my_context->maplib, symname, &offs, &end, h, -1, NULL, globdefver, weakdefver);
if (!offs) {
printf_log(LOG_NONE, "Error: PltResolver: Symbol %s(ver %d: %s%s%s) not found, cannot apply R_X86_64_JUMP_SLOT %p (%p) in %s\n", symname, version, symname, vername?"@":"", vername?vername:"", p, *(void**)p, h->name);
@@ -1791,6 +1908,7 @@ EXPORT void PltResolver(x64emu_t* emu)
printf_dump(LOG_DEBUG, "symbol %s from %s but elf not initialized yet, run Init now (from %s)\n", symname, ElfName(sym_elf), ElfName(h));
RunElfInitPltResolver(sym_elf, emu);
}
+ offs = (uintptr_t)getAlternate((void*)offs);
if(p) {
printf_dump(LOG_DEBUG, " Apply %s R_X86_64_JUMP_SLOT %p with sym=%s(ver %d: %s%s%s) (%p -> %p / %s)\n", (bind==STB_LOCAL)?"Local":"Global", p, symname, version, symname, vername?"@":"", vername?vername:"",*(void**)p, (void*)offs, ElfName(sym_elf));
diff --git a/src/elfs/elfloader_private.h b/src/elfs/elfloader_private.h
index c463753..d2bc255 100755..100644
--- a/src/elfs/elfloader_private.h
+++ b/src/elfs/elfloader_private.h
@@ -4,6 +4,7 @@
typedef struct library_s library_t;
typedef struct needed_libs_s needed_libs_t;
typedef struct kh_mapsymbols_s kh_mapsymbols_t;
+typedef struct kh_defaultversion_s kh_defaultversion_t;
#include <elf.h>
#include "elfloader.h"
@@ -11,6 +12,7 @@ typedef struct kh_mapsymbols_s kh_mapsymbols_t;
struct elfheader_s {
char* name;
char* path; // Resolved path to file
+ char* soname; // soname of the elf
size_t numPHEntries;
Elf64_Phdr *PHEntries;
size_t numSHEntries;
@@ -34,6 +36,7 @@ struct elfheader_s {
Elf64_Verdef* VerDef;
int szVerDef;
int e_type;
+ uint32_t flags;
intptr_t delta; // should be 0
@@ -84,6 +87,7 @@ struct elfheader_s {
int init_done;
int fini_done;
int refcnt; // ref count for the elf
+ int malloc_hook_2; // this elf hook malloc, hacking it
char* memory; // char* and not void* to allow math on memory pointer
void** multiblock;
@@ -97,6 +101,8 @@ struct elfheader_s {
kh_mapsymbols_t *mapsymbols;
kh_mapsymbols_t *weaksymbols;
kh_mapsymbols_t *localsymbols;
+ kh_defaultversion_t *globaldefver; // the global default version for symbols (the XXX@@vvvv of symbols)
+ kh_defaultversion_t *weakdefver; // the weak default version for symbols (the XXX@@vvvv of symbols)
};
#define R_X86_64_NONE 0 /* No reloc */
diff --git a/src/elfs/elfparser.c b/src/elfs/elfparser.c
index 1fd3ca0..1701378 100755..100644
--- a/src/elfs/elfparser.c
+++ b/src/elfs/elfparser.c
@@ -278,6 +278,10 @@ elfheader_t* ParseElfHeader(FILE* f, const char* name, int exec)
h->VerDef = (Elf64_Verdef*)ptr;
printf_dump(LOG_DEBUG, "The DT_VERDEF is at address %p\n", h->VerDef);
break;
+ case DT_FLAGS:
+ h->flags = val;
+ printf_dump(LOG_DEBUG, "The DT_FLAGS is 0x%x\n", h->flags);
+ break;
}
}
if(h->rel) {
@@ -412,18 +416,6 @@ int GetVersionIndice(elfheader_t* h, const char* vername)
{
if(!vername)
return 0;
- if(h->VerNeed) {
- Elf64_Verneed *ver = (Elf64_Verneed*)((uintptr_t)h->VerNeed + h->delta);
- while(ver) {
- Elf64_Vernaux *aux = (Elf64_Vernaux*)((uintptr_t)ver + ver->vn_aux);
- for(int j=0; j<ver->vn_cnt; ++j) {
- if(!strcmp(h->DynStr+aux->vna_name, vername))
- return aux->vna_other;
- aux = (Elf64_Vernaux*)((uintptr_t)aux + aux->vna_next);
- }
- ver = ver->vn_next?((Elf64_Verneed*)((uintptr_t)ver + ver->vn_next)):NULL;
- }
- }
if(h->VerDef) {
Elf64_Verdef *def = (Elf64_Verdef*)((uintptr_t)h->VerDef + h->delta);
while(def) {
@@ -434,4 +426,44 @@ int GetVersionIndice(elfheader_t* h, const char* vername)
}
}
return 0;
+}
+
+int GetNeededVersionCnt(elfheader_t* h, const char* libname)
+{
+ if(!libname)
+ return 0;
+ if(h->VerNeed) {
+ Elf64_Verneed *ver = (Elf64_Verneed*)((uintptr_t)h->VerNeed + h->delta);
+ while(ver) {
+ char *filename = h->DynStr + ver->vn_file;
+ Elf64_Vernaux *aux = (Elf64_Vernaux*)((uintptr_t)ver + ver->vn_aux);
+ if(!strcmp(filename, libname))
+ return ver->vn_cnt;
+ ver = ver->vn_next?((Elf64_Verneed*)((uintptr_t)ver + ver->vn_next)):NULL;
+ }
+ }
+ return 0;
+}
+
+const char* GetNeededVersionString(elfheader_t* h, const char* libname, int idx)
+{
+ if(!libname)
+ return 0;
+ if(h->VerNeed) {
+ Elf64_Verneed *ver = (Elf64_Verneed*)((uintptr_t)h->VerNeed + h->delta);
+ while(ver) {
+ char *filename = h->DynStr + ver->vn_file;
+ Elf64_Vernaux *aux = (Elf64_Vernaux*)((uintptr_t)ver + ver->vn_aux);
+ if(!strcmp(filename, libname)) {
+ for(int j=0; j<ver->vn_cnt; ++j) {
+ if(j==idx)
+ return h->DynStr+aux->vna_name;
+ aux = (Elf64_Vernaux*)((uintptr_t)aux + aux->vna_next);
+ }
+ return NULL; // idx out of bound, return NULL...
+ }
+ ver = ver->vn_next?((Elf64_Verneed*)((uintptr_t)ver + ver->vn_next)):NULL;
+ }
+ }
+ return NULL;
} \ No newline at end of file
diff --git a/src/emu/modrm.h b/src/emu/modrm.h
index c01343b..cd967c0 100644
--- a/src/emu/modrm.h
+++ b/src/emu/modrm.h
@@ -18,7 +18,37 @@
#define STEP3
#endif
+#ifdef TEST_INTERPRETER
+#define GETED(D) oped=TestEd(test, &addr, rex, nextop, D)
+#define GETE4(D) oped=TestEd4(test, &addr, rex, nextop, D)
+#define GETE8(D) oped=TestEd8(test, &addr, rex, nextop, D)
+#define GETET(D) oped=TestEdt(test, &addr, rex, nextop, D)
+#define GETE8xw(D) oped=TestEd8xw(test, rex.w, &addr, rex, nextop, D)
+#define GETED32(D) oped=TestEd32O(test, &addr, rex, nextop, D, 0)
+#define GETED_OFFS(D, O) oped=TestEdO(test, &addr, rex, nextop, D, O)
+#define GETGD opgd=GetGd(test->emu, &addr, rex, nextop)
+#define GETEB(D) oped=TestEb(test, &addr, rex, nextop, D)
+#define GETEB32(D) oped=TestEb32O(test, &addr, rex, nextop, D, 0)
+#define GETEB_OFFS(D, O) oped=TestEbO(test, &addr, rex, nextop, D, O)
+#define GETGB opgd=GetGb(test->emu, &addr, rex, nextop)
+#define GETEW(D) oped=TestEw(test, &addr, rex, nextop, D)
+#define GETEW32(D) oped=TestEw32O(test, &addr, rex, nextop, D, 0)
+#define GETEW_OFFS(D, O) oped=TestEdO(test, &addr, rex, nextop, D, O)
+#define GETEW_OFFS_16(O) oped=TestEw16off(test, &addr, rex, nextop, O)
+#define GETGW opgd=GetGw(test->emu, &addr, rex, nextop)
+#define GETEX(D) opex=TestEx(test, &addr, rex, nextop, D)
+#define GETEX32(D) opex=TestEx32O(test, &addr, rex, nextop, D, 0)
+#define GETEX_OFFS(D, O) opex=TestExO(test, &addr, rex, nextop, D, O)
+#define GETGX opgx=GetGx(test->emu, &addr, rex, nextop)
+#define GETEM(D) opem=TestEm(test, &addr, rex, nextop, D)
+#define GETEM32(D) opem=TestEm32O(test, &addr, rex, nextop, D, 0)
+#define GETGM opgm=GetGm(test->emu, &addr, rex, nextop)
+#else
#define GETED(D) oped=GetEd(emu, &addr, rex, nextop, D)
+#define GETE4(D) GETED(D)
+#define GETE8(D) GETED(D)
+#define GETET(D) GETED(D)
+#define GETE8xw(D) GETED(D)
#define GETED32(D) oped=GetEd32O(emu, &addr, rex, nextop, D, 0)
#define GETED_OFFS(D, O) oped=GetEdO(emu, &addr, rex, nextop, D, O)
#define GETGD opgd=GetGd(emu, &addr, rex, nextop)
@@ -29,6 +59,7 @@
#define GETEW(D) oped=GetEw(emu, &addr, rex, nextop, D)
#define GETEW32(D) oped=GetEw32O(emu, &addr, rex, nextop, D, 0)
#define GETEW_OFFS(D, O) oped=GetEdO(emu, &addr, rex, nextop, D, O)
+#define GETEW_OFFS_16(O) oped=GetEw16off(emu, &addr, rex, nextop, O)
#define GETGW opgd=GetGw(emu, &addr, rex, nextop)
#define GETEX(D) opex=GetEx(emu, &addr, rex, nextop, D)
#define GETEX32(D) opex=GetEx32O(emu, &addr, rex, nextop, D, 0)
@@ -37,6 +68,7 @@
#define GETEM(D) opem=GetEm(emu, &addr, rex, nextop, D)
#define GETEM32(D) opem=GetEm32O(emu, &addr, rex, nextop, D, 0)
#define GETGM opgm=GetGm(emu, &addr, rex, nextop)
+#endif
#define ED oped
#define GD opgd
#define EB oped
@@ -47,6 +79,11 @@
#define GX opgx
#define EM opem
#define GM opgm
+#define FAKEED(D) GetEd(emu, &addr, rex, nextop, D)
+#define FAKEED32(D) GetEd32O(emu, &addr, rex, nextop, D, 0)
+#define GETEA(D) GetEA(emu, &addr, rex, nextop, D)
+#define _GETED(D) oped=GetEd(emu, &addr, rex, nextop, D)
+#define _GETED32(D) oped=GetEd32O(emu, &addr, rex, nextop, D, 0)
#define MODREG ((nextop&0xC0)==0xC0)
diff --git a/src/emu/x64emu.c b/src/emu/x64emu.c
index 9a328bb..95077d4 100755..100644
--- a/src/emu/x64emu.c
+++ b/src/emu/x64emu.c
@@ -38,6 +38,7 @@ typedef struct cleanup_s {
void* f;
int arg;
void* a;
+ void* dso;
} cleanup_t;
static uint32_t x86emu_parity_tab[8] =
@@ -57,17 +58,6 @@ uint32_t* GetParityTab()
return x86emu_parity_tab;
}
-void PushExit(x64emu_t* emu)
-{
- uintptr_t endMarker = AddCheckBridge(my_context->system, NULL, NULL, 0, "ExitEmulation");
- Push(emu, endMarker);
-}
-
-void* GetExit()
-{
- return (void*)AddCheckBridge(my_context->system, NULL, NULL, 0, "ExitEmulation");
-}
-
static void internalX64Setup(x64emu_t* emu, box64context_t *context, uintptr_t start, uintptr_t stack, int stacksize, int ownstack)
{
emu->context = context;
@@ -85,9 +75,9 @@ static void internalX64Setup(x64emu_t* emu, box64context_t *context, uintptr_t s
R_RIP = start;
R_RSP = (stack + stacksize) & ~7; // align stack start, always
// fake init of segments...
- emu->segs[_CS] = 0x73;
- emu->segs[_DS] = emu->segs[_ES] = emu->segs[_SS] = 0x7b;
- emu->segs[_FS] = 0x33;
+ emu->segs[_CS] = 0x33;
+ emu->segs[_DS] = emu->segs[_ES] = emu->segs[_SS] = 0x2b;
+ emu->segs[_FS] = 0x43;
emu->segs[_GS] = default_gs;
// setup fpu regs
reset_fpu(emu);
@@ -116,10 +106,18 @@ x64emu_t *NewX64EmuFromStack(x64emu_t* emu, box64context_t *context, uintptr_t s
}
EXPORTDYN
-void SetupX64Emu(x64emu_t *emu)
+void SetupX64Emu(x64emu_t *emu, x64emu_t *ref)
{
printf_log(LOG_DEBUG, "Setup X86_64 Emu\n");
- (void)emu; // Not doing much here...
+ if(ref) {
+ // save RIP and RSP
+ uintptr_t old_rip = R_RIP;
+ uintptr_t old_rsp = R_RSP;
+ CloneEmu(emu, ref);
+ // restore RIP and RSP
+ R_RIP = old_rip;
+ R_RSP = old_rsp;
+ }
}
#ifdef HAVE_TRACE
@@ -139,7 +137,7 @@ void SetTraceEmu(uintptr_t start, uintptr_t end)
}
#endif
-void AddCleanup(x64emu_t *emu, void *p)
+void AddCleanup(x64emu_t *emu, void *p, void* dso_handle)
{
(void)emu;
@@ -149,10 +147,11 @@ void AddCleanup(x64emu_t *emu, void *p)
}
my_context->cleanups[my_context->clean_sz].arg = 0;
my_context->cleanups[my_context->clean_sz].a = NULL;
+ my_context->cleanups[my_context->clean_sz].dso = dso_handle;
my_context->cleanups[my_context->clean_sz++].f = p;
}
-void AddCleanup1Arg(x64emu_t *emu, void *p, void* a)
+void AddCleanup1Arg(x64emu_t *emu, void *p, void* a, void* dso_handle)
{
(void)emu;
@@ -162,6 +161,7 @@ void AddCleanup1Arg(x64emu_t *emu, void *p, void* a)
}
my_context->cleanups[my_context->clean_sz].arg = 1;
my_context->cleanups[my_context->clean_sz].a = a;
+ my_context->cleanups[my_context->clean_sz].dso = dso_handle;
my_context->cleanups[my_context->clean_sz++].f = p;
}
@@ -169,7 +169,7 @@ void CallCleanup(x64emu_t *emu, void* p)
{
printf_log(LOG_DEBUG, "Calling atexit registered functions for %p mask\n", p);
for(int i=my_context->clean_sz-1; i>=0; --i) {
- if(p==my_context->cleanups[i].f) {
+ if(p==my_context->cleanups[i].dso) {
printf_log(LOG_DEBUG, "Call cleanup #%d\n", i);
RunFunctionWithEmu(emu, 0, (uintptr_t)(my_context->cleanups[i].f), my_context->cleanups[i].arg, my_context->cleanups[i].a );
// now remove the cleanup
@@ -205,6 +205,11 @@ void FreeX64Emu(x64emu_t **emu)
return;
printf_log(LOG_DEBUG, "%04d|Free a X86_64 Emu (%p)\n", GetTID(), *emu);
+ if((*emu)->test.emu) {
+ internalFreeX64((*emu)->test.emu);
+ box_free((*emu)->test.emu);
+ (*emu)->test.emu = NULL;
+ }
internalFreeX64(*emu);
box_free(*emu);
@@ -238,6 +243,13 @@ void CloneEmu(x64emu_t *newemu, const x64emu_t* emu)
newemu->top = emu->top;
newemu->fpu_stack = emu->fpu_stack;
memcpy(newemu->xmm, emu->xmm, sizeof(emu->xmm));
+ newemu->df = emu->df;
+ newemu->df_sav = emu->df_sav;
+ newemu->op1 = emu->op1;
+ newemu->op2 = emu->op2;
+ newemu->res = emu->res;
+ newemu->op1_sav = emu->op1_sav;
+ newemu->res_sav = emu->res_sav;
newemu->mxcsr = emu->mxcsr;
newemu->quit = emu->quit;
newemu->error = emu->error;
@@ -247,6 +259,37 @@ void CloneEmu(x64emu_t *newemu, const x64emu_t* emu)
newemu->regs[_SP].q[0] = emu->regs[_SP].q[0] + (intptr_t)(newst - oldst);
}
+void CopyEmu(x64emu_t *newemu, const x64emu_t* emu)
+{
+ memcpy(newemu->regs, emu->regs, sizeof(emu->regs));
+ memcpy(&newemu->ip, &emu->ip, sizeof(emu->ip));
+ memcpy(&newemu->eflags, &emu->eflags, sizeof(emu->eflags));
+ newemu->old_ip = emu->old_ip;
+ memcpy(newemu->segs, emu->segs, sizeof(emu->segs));
+ memcpy(newemu->segs_serial, emu->segs_serial, sizeof(emu->segs_serial));
+ memcpy(newemu->segs_offs, emu->segs_offs, sizeof(emu->segs_offs));
+ memcpy(newemu->x87, emu->x87, sizeof(emu->x87));
+ memcpy(newemu->mmx, emu->mmx, sizeof(emu->mmx));
+ memcpy(newemu->xmm, emu->xmm, sizeof(emu->xmm));
+ memcpy(newemu->fpu_ld, emu->fpu_ld, sizeof(emu->fpu_ld));
+ memcpy(newemu->fpu_ll, emu->fpu_ll, sizeof(emu->fpu_ll));
+ memcpy(newemu->p_regs, emu->p_regs, sizeof(emu->p_regs));
+ newemu->cw = emu->cw;
+ newemu->sw = emu->sw;
+ newemu->top = emu->top;
+ newemu->fpu_stack = emu->fpu_stack;
+ newemu->df = emu->df;
+ newemu->df_sav = emu->df_sav;
+ newemu->op1 = emu->op1;
+ newemu->op2 = emu->op2;
+ newemu->res = emu->res;
+ newemu->op1_sav = emu->op1_sav;
+ newemu->res_sav = emu->res_sav;
+ newemu->mxcsr = emu->mxcsr;
+ newemu->quit = emu->quit;
+ newemu->error = emu->error;
+}
+
box64context_t* GetEmuContext(x64emu_t* emu)
{
return emu->context;
@@ -352,11 +395,13 @@ void ResetFlags(x64emu_t *emu)
emu->df = d_none;
}
-const char* DumpCPURegs(x64emu_t* emu, uintptr_t ip)
+const char* DumpCPURegs(x64emu_t* emu, uintptr_t ip, int is32bits)
{
static char buff[1000];
- char* regname[] = {"RAX", "RCX", "RDX", "RBX", "RSP", "RBP", "RSI", "RDI",
- " R8", " R9", "R10", "R11", "R12", "R13", "R14", "R15"};
+ static const char* regname[] = {"RAX", "RCX", "RDX", "RBX", "RSP", "RBP", "RSI", "RDI",
+ " R8", " R9", "R10", "R11", "R12", "R13", "R14", "R15"};
+ static const char* regname32[]={"EAX", "ECX", "EDX", "EBX", "ESP", "EBP", "ESI", "EDI"};
+ static const char* segname[] = {"ES", "CS", "SS", "DS", "FS", "GS"};
char tmp[160];
buff[0] = '\0';
#ifdef HAVE_TRACE
@@ -370,8 +415,14 @@ const char* DumpCPURegs(x64emu_t* emu, uintptr_t ip)
}
if(trace_xmm) {
// do xmm reg if needed
- for(int i=0; i<8; ++i) {
- sprintf(tmp, "%d:%016lx%016lx", i, emu->xmm[i].q[1], emu->xmm[i].q[0]);
+ for(int i=0; i<(is32bits?8:16); ++i) {
+ if (trace_regsdiff && (emu->old_xmm[i].q[0] != emu->xmm[i].q[0] || emu->old_xmm[i].q[1] != emu->xmm[i].q[1])) {
+ sprintf(tmp, "\e[1;35m%02d:%016lx-%016lx\e[m", i, emu->xmm[i].q[1], emu->xmm[i].q[0]);
+ emu->old_xmm[i].q[0] = emu->xmm[i].q[0];
+ emu->old_xmm[i].q[1] = emu->xmm[i].q[1];
+ } else {
+ sprintf(tmp, "%02d:%016lx-%016lx", i, emu->xmm[i].q[1], emu->xmm[i].q[0]);
+ }
strcat(buff, tmp);
if ((i&3)==3) strcat(buff, "\n"); else strcat(buff, " ");
}
@@ -389,21 +440,28 @@ const char* DumpCPURegs(x64emu_t* emu, uintptr_t ip)
}
strcat(buff, "\n");
}
- for (int i=_AX; i<=_R15; ++i) {
+ for (int i=0; i<6; ++i) {
+ sprintf(tmp, "%s=0x%04x", segname[i], emu->segs[i]);
+ strcat(buff, tmp);
+ if(i!=_GS)
+ strcat(buff, " ");
+ }
+ strcat(buff, "\n");
+ if(is32bits)
+ for (int i=_AX; i<=_RDI; ++i) {
#ifdef HAVE_TRACE
- if (trace_regsdiff && (emu->regs[i].q[0] != emu->oldregs[i].q[0])) {
- sprintf(tmp, "\e[1;35m%s=%016lx\e[m ", regname[i], emu->regs[i].q[0]);
- emu->oldregs[i].q[0] = emu->regs[i].q[0];
- } else {
- sprintf(tmp, "%s=%016lx ", regname[i], emu->regs[i].q[0]);
- }
+ if (trace_regsdiff && (emu->regs[i].dword[0] != emu->oldregs[i].q[0])) {
+ sprintf(tmp, "\e[1;35m%s=%08x\e[m ", regname32[i], emu->regs[i].dword[0]);
+ emu->oldregs[i].q[0] = emu->regs[i].dword[0];
+ } else {
+ sprintf(tmp, "%s=%08x ", regname32[i], emu->regs[i].dword[0]);
+ }
#else
- sprintf(tmp, "%s=%016lx ", regname[i], emu->regs[i].q[0]);
+ sprintf(tmp, "%s=%08x ", regname[i], emu->regs[i].dword[0]);
#endif
- strcat(buff, tmp);
+ strcat(buff, tmp);
- if (i%5==4) {
- if(i==4) {
+ if(i==_RBX) {
if(emu->df) {
#define FLAG_CHAR(f) (ACCESS_FLAG(F_##f##F)) ? #f : "?"
sprintf(tmp, "flags=%s%s%s%s%s%s%s\n", FLAG_CHAR(O), FLAG_CHAR(D), FLAG_CHAR(S), FLAG_CHAR(Z), FLAG_CHAR(A), FLAG_CHAR(P), FLAG_CHAR(C));
@@ -415,22 +473,54 @@ const char* DumpCPURegs(x64emu_t* emu, uintptr_t ip)
strcat(buff, tmp);
#undef FLAG_CHAR
}
+ }
+ }
+ else
+ for (int i=_AX; i<=_R15; ++i) {
+#ifdef HAVE_TRACE
+ if (trace_regsdiff && (emu->regs[i].q[0] != emu->oldregs[i].q[0])) {
+ sprintf(tmp, "\e[1;35m%s=%016lx\e[m ", regname[i], emu->regs[i].q[0]);
+ emu->oldregs[i].q[0] = emu->regs[i].q[0];
} else {
- strcat(buff, "\n");
+ sprintf(tmp, "%s=%016lx ", regname[i], emu->regs[i].q[0]);
}
- }
+#else
+ sprintf(tmp, "%s=%016lx ", regname[i], emu->regs[i].q[0]);
+#endif
+ strcat(buff, tmp);
+
+ if (i%5==4) {
+ if(i==4) {
+ if(emu->df) {
+#define FLAG_CHAR(f) (ACCESS_FLAG(F_##f##F)) ? #f : "?"
+ sprintf(tmp, "flags=%s%s%s%s%s%s%s\n", FLAG_CHAR(O), FLAG_CHAR(D), FLAG_CHAR(S), FLAG_CHAR(Z), FLAG_CHAR(A), FLAG_CHAR(P), FLAG_CHAR(C));
+ strcat(buff, tmp);
+#undef FLAG_CHAR
+ } else {
+#define FLAG_CHAR(f) (ACCESS_FLAG(F_##f##F)) ? #f : "-"
+ sprintf(tmp, "FLAGS=%s%s%s%s%s%s%s\n", FLAG_CHAR(O), FLAG_CHAR(D), FLAG_CHAR(S), FLAG_CHAR(Z), FLAG_CHAR(A), FLAG_CHAR(P), FLAG_CHAR(C));
+ strcat(buff, tmp);
+#undef FLAG_CHAR
+ }
+ } else {
+ strcat(buff, "\n");
+ }
+ }
}
- sprintf(tmp, "RIP=%016lx ", ip);
+ if(is32bits)
+ sprintf(tmp, "EIP=%08lx ", ip);
+ else
+ sprintf(tmp, "RIP=%016lx ", ip);
strcat(buff, tmp);
return buff;
}
-void StopEmu(x64emu_t* emu, const char* reason)
+void StopEmu(x64emu_t* emu, const char* reason, int is32bits)
{
emu->quit = 1;
printf_log(LOG_NONE, "%s", reason);
// dump stuff...
- printf_log(LOG_NONE, "==== CPU Registers ====\n%s\n", DumpCPURegs(emu, R_RIP));
+ printf_log(LOG_NONE, "==== CPU Registers ====\n%s\n", DumpCPURegs(emu, R_RIP, is32bits));
printf_log(LOG_NONE, "======== Stack ========\nStack is from %lX to %lX\n", R_RBP, R_RSP);
if (R_RBP == R_RSP) {
printf_log(LOG_NONE, "RBP = RSP: leaf function detected; next 128 bytes should be either data or random.\n");
@@ -445,13 +535,13 @@ void StopEmu(x64emu_t* emu, const char* reason)
#endif
}
-void UnimpOpcode(x64emu_t* emu)
+void UnimpOpcode(x64emu_t* emu, int is32bits)
{
R_RIP = emu->old_ip;
int tid = syscall(SYS_gettid);
- printf_log(LOG_NONE, "%04d|%p: Unimplemented Opcode (%02X %02X %02X %02X) %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X\n",
- tid, (void*)emu->old_ip,
+ printf_log(LOG_NONE, "%04d|%p: Unimplemented %sOpcode (%02X %02X %02X %02X) %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X\n",
+ tid, (void*)emu->old_ip, is32bits?"32bits ":"",
Peek(emu, -4), Peek(emu, -3), Peek(emu, -2), Peek(emu, -1),
Peek(emu, 0), Peek(emu, 1), Peek(emu, 2), Peek(emu, 3),
Peek(emu, 4), Peek(emu, 5), Peek(emu, 6), Peek(emu, 7),
@@ -477,9 +567,9 @@ void EmuCall(x64emu_t* emu, uintptr_t addr)
Run(emu, 0);
emu->quit = 0; // reset Quit flags...
emu->df = d_none;
- if(emu->quitonlongjmp && emu->longjmp) {
- if(emu->quitonlongjmp==1)
- emu->longjmp = 0; // don't change anything because of the longjmp
+ if(emu->flags.quitonlongjmp && emu->flags.longjmp) {
+ if(emu->flags.quitonlongjmp==1)
+ emu->flags.longjmp = 0; // don't change anything because of the longjmp
} else {
R_RBX = old_rbx;
R_RDI = old_rdi;
diff --git a/src/emu/x64emu_private.h b/src/emu/x64emu_private.h
index 68fa5f8..8076049 100755..100644
--- a/src/emu/x64emu_private.h
+++ b/src/emu/x64emu_private.h
@@ -25,6 +25,25 @@ typedef union multiuint_s {
uint64_t u64;
} multiuint_t;
+typedef struct x64emu_s x64emu_t;
+
+typedef struct x64test_s {
+ x64emu_t* emu;
+ uintptr_t memaddr;
+ int memsize;
+ int test;
+ int clean;
+ uint8_t mem[16];
+} x64test_t;
+
+typedef struct emu_flags_s {
+ uint32_t need_jmpbuf:1; // need a new jmpbuff for signal handling
+ uint32_t quitonlongjmp:2; // quit if longjmp is called
+ uint32_t quitonexit:2; // quit if exit/_exit is called
+ uint32_t longjmp:1; // if quit because of longjmp
+ uint32_t jmpbuf_ready:1; // the jmpbuf in the emu is ok and don't need refresh
+} emu_flags_t;
+
typedef struct x64emu_s {
// cpu
reg64_t regs[16];
@@ -37,7 +56,7 @@ typedef struct x64emu_s {
mmx87_regs_t mmx[8];
x87control_t cw;
x87flags_t sw;
- uint32_t top; // top is part of sw, but it's faster to have it separatly
+ uint32_t top; // top is part of sw, but it's faster to have it separately
int fpu_stack;
mmxcontrol_t mxcsr;
fpu_ld_t fpu_ld[8]; // for long double emulation / 80bits fld fst
@@ -45,15 +64,15 @@ typedef struct x64emu_s {
fpu_p_reg_t p_regs[8];
// old ip
uintptr_t old_ip;
- // defered flags
+ // deferred flags
int dummy1; // to align on 64bits with df
- defered_flags_t df;
+ deferred_flags_t df;
multiuint_t op1;
multiuint_t op2;
multiuint_t res;
- multiuint_t op1_sav; // for dec/inc defered flags, to be able to compute CF
+ multiuint_t op1_sav; // for dec/inc deferred flags, to be able to compute CF
multiuint_t res_sav;
- defered_flags_t df_sav;
+ deferred_flags_t df_sav;
uint32_t *x64emu_parity_tab; // helper
#ifdef HAVE_TRACE
reg64_t oldregs[16];
@@ -72,22 +91,24 @@ typedef struct x64emu_s {
int quit;
int error;
int fork; // quit because need to fork
- forkpty_t* forkpty_info;
int exit;
- int quitonlongjmp; // quit if longjmp is called
- int quitonexit; // quit if exit/_exit is called
- int longjmp; // if quit because of longjmp
- // scratch stack, used for alignement of double and 64bits ints on arm. 200 elements should be enough
+ forkpty_t* forkpty_info;
+ emu_flags_t flags;
+ x64test_t test; // used for dynarec testing
+ #ifdef HAVE_TRACE
+ sse_regs_t old_xmm[16];
+ #endif
+ // scratch stack, used for alignment of double and 64bits ints on arm. 200 elements should be enough
uint64_t scratch[200];
// local stack, do be deleted when emu is freed
void* stack2free; // this is the stack to free (can be NULL)
void* init_stack; // initial stack (owned or not)
uint32_t size_stack; // stack size (owned or not)
+ struct __jmp_buf_tag *jmpbuf;
x64_ucontext_t *uc_link; // to handle setcontext
int type; // EMUTYPE_xxx define
-
} x64emu_t;
#define EMUTYPE_NONE 0
diff --git a/src/emu/x64int3.c b/src/emu/x64int3.c
index 49cc000..d58574c 100755..100644
--- a/src/emu/x64int3.c
+++ b/src/emu/x64int3.c
@@ -12,6 +12,7 @@
#include <signal.h>
#include <poll.h>
#include <sys/wait.h>
+#include <elf.h>
#include "debug.h"
#include "box64stack.h"
@@ -25,6 +26,7 @@
#include "wrapper.h"
#include "box64context.h"
#include "librarian.h"
+#include "elfload_dump.h"
#include <elf.h>
#include "elfloader.h"
@@ -120,7 +122,17 @@ void x64Int3(x64emu_t* emu, uintptr_t* addr)
const char *s = NULL;
s = GetNativeName((void*)a);
if(a==(uintptr_t)PltResolver) {
- snprintf(buff, 256, "%s", cycle_log?"PltResolver ":" ... ");
+ if(cycle_log) {
+ uintptr_t addr = *((uint64_t*)(R_RSP));
+ int slot = *((uint64_t*)(R_RSP+8));
+ elfheader_t *h = (elfheader_t*)addr;
+ Elf64_Rela * rel = (Elf64_Rela *)(h->jmprel + h->delta) + slot;
+ Elf64_Sym *sym = &h->DynSym[ELF64_R_SYM(rel->r_info)];
+ const char* symname = SymName(h, sym);
+ snprintf(buff, 256, "%04d|PltResolver \"%s\"", tid, symname?symname:"???");
+ } else {
+ snprintf(buff, 256, "%s", " ... ");
+ }
} else if (!strcmp(s, "__open") || !strcmp(s, "open") || !strcmp(s, "open ") || !strcmp(s, "open64")) {
tmp = (char*)(R_RDI);
snprintf(buff, 256, "%04d|%p: Calling %s(\"%s\", %d (,%d))", tid, *(void**)(R_RSP), s, (tmp)?tmp:"(nil)", (int)(R_ESI), (int)(R_EDX));
@@ -141,6 +153,10 @@ void x64Int3(x64emu_t* emu, uintptr_t* addr)
tmp = (char*)(R_RDI);
snprintf(buff, 256, "%04d|%p: Calling %s(\"%s\", %p, %zd)", tid, *(void**)(R_RSP), s, (tmp)?tmp:"(nil)", (void*)(R_RSI), (size_t)R_RDX);
perr = 1;
+ } else if (!strcmp(s, "execv")) {
+ tmp = (char*)(R_RDI);
+ snprintf(buff, 256, "%04d|%p: Calling %s(\"%s\", %p)", tid, *(void**)(R_RSP), s, (tmp)?tmp:"(nil)", (void*)(R_RSI));
+ perr = 1;
} else if (strstr(s, "mkdir")==s) {
tmp = (char*)(R_RDI);
snprintf(buff, 256, "%04d|%p: Calling %s(\"%s\", %d)", tid, *(void**)(R_RSP), s, (tmp)?tmp:"(nil)", (int)(R_ESI));
@@ -202,11 +218,18 @@ void x64Int3(x64emu_t* emu, uintptr_t* addr)
pu64 = (uint64_t*)R_RDI;
post = 3;
snprintf(buff, 256, "%04d|%p: Calling %s(%p, %zu, %d, %zu, \"%s\" (,%p))", tid, *(void**)(R_RSP), s, (void*)R_RDI, R_RSI, R_EDX, R_RCX, (tmp)?tmp:"(nil)", (void*)(R_R9));
- } else if (!strcmp(s, "snprintf")) {
+ } else if (strstr(s, "__vfprintf_chk")) {
+ tmp = (char*)(R_RDX);
+ pu64 = (uint64_t*)R_RDI;
+ snprintf(buff, 256, "%04d|%p: Calling %s(%p, %d, \"%s\", ... )", tid, *(void**)(R_RSP), s, (void*)R_RDI, R_ESI, (tmp)?tmp:"(nil)");
+ } else if (strstr(s, "snprintf")==s) {
tmp = (char*)(R_RDX);
pu64 = (uint64_t*)R_RDI;
post = 3;
snprintf(buff, 256, "%04d|%p: Calling %s(%p, %zu, \"%s\" (,%p))", tid, *(void**)(R_RSP), s, (void*)R_RDI, R_RSI, (tmp)?tmp:"(nil)", (void*)(R_RCX));
+ } else if (!strcmp(s, "vfprintf")) {
+ tmp = (char*)((R_RSI>2)?R_RSI:R_RDX);
+ snprintf(buff, 256, "%04d|%p: Calling %s(%p, \"%s\", ...)", tid, *(void**)(R_RSP), s, (void*)R_RDI, (tmp)?tmp:"(nil)");
} else if (!strcmp(s, "getcwd")) {
post = 2;
snprintf(buff, 256, "%04d|%p: Calling %s(%p, %zu)", tid, *(void**)(R_RSP), s, (void*)R_RDI, R_RSI);
@@ -237,6 +260,8 @@ void x64Int3(x64emu_t* emu, uintptr_t* addr)
snprintf(buff, 256, "%04d|%p: Calling %s(0x%x, %d, 0x%x, %p)", tid, *(void**)(R_RSP), s, R_EDI, R_ESI, R_EDX, (void*)R_RCX);
} else if (!strcmp(s, "glUniform4fv")) {
snprintf(buff, 256, "%04d|%p: Calling %s(%d, %d, %p[%g/%g/%g/%g...])", tid, *(void**)(R_RSP), s, R_EDI, R_ESI, (void*)R_RDX, ((float*)(R_RDX))[0], ((float*)(R_RDX))[1], ((float*)(R_RDX))[2], ((float*)(R_RDX))[3]);
+ } else if (!strcmp(s, "ov_read")) {
+ snprintf(buff, 256, "%04d|%p: Calling %s(%p, %p, %d, %d, %d, %d, %p)", tid, *(void**)(R_RSP), s, (void*)R_RDI, (void*)R_RSI, R_EDX, R_ECX, R_R8d, R_R9d, *(void**)(R_RSP+8));
} else if (!strcmp(s, "mmap64") || !strcmp(s, "mmap")) {
snprintf(buff, 256, "%04d|%p: Calling %s(%p, %lu, 0x%x, 0x%x, %d, %ld)", tid, *(void**)(R_RSP), s,
(void*)R_RDI, R_RSI, (int)(R_RDX), (int)R_RCX, (int)R_R8, R_R9);
diff --git a/src/emu/x64primop.c b/src/emu/x64primop.c
index b027049..b027049 100755..100644
--- a/src/emu/x64primop.c
+++ b/src/emu/x64primop.c
diff --git a/src/emu/x64primop.h b/src/emu/x64primop.h
index a0f465a..a0f465a 100755..100644
--- a/src/emu/x64primop.h
+++ b/src/emu/x64primop.h
diff --git a/src/emu/x64run.c b/src/emu/x64run.c
index 032614d..1f2f9dd 100755..100644
--- a/src/emu/x64run.c
+++ b/src/emu/x64run.c
@@ -28,7 +28,11 @@
int my_setcontext(x64emu_t* emu, void* ucp);
+#ifdef TEST_INTERPRETER
+int RunTest(x64test_t *test)
+#else
int Run(x64emu_t *emu, int step)
+#endif
{
uint8_t opcode;
uint8_t nextop;
@@ -40,10 +44,15 @@ int Run(x64emu_t *emu, int step)
uint32_t tmp32u, tmp32u2;
int64_t tmp64s;
uint64_t tmp64u, tmp64u2, tmp64u3;
+ #ifdef TEST_INTERPRETER
+ x64emu_t* emu = test->emu;
+ int step = 0;
+ #endif
uintptr_t addr = R_RIP;
- rex_t rex;
+ rex_t rex = {0};
int rep; // 0 none, 1=F2 prefix, 2=F3 prefix
int unimp = 0;
+ int is32bits = (emu->segs[_CS]==0x23);
if(emu->quit)
return 0;
@@ -54,12 +63,14 @@ int Run(x64emu_t *emu, int step)
return 0;
}
//ref opcode: http://ref.x64asm.net/geek32.html#xA1
- printf_log(LOG_DEBUG, "Run X86 (%p), RIP=%p, Stack=%p\n", emu, (void*)addr, (void*)R_RSP);
+ printf_log(LOG_DEBUG, "Run X86 (%p), RIP=%p, Stack=%p is32bits=%d\n", emu, (void*)addr, (void*)R_RSP, is32bits);
x64emurun:
-
- while(1) {
-#ifdef HAVE_TRACE
+#ifndef TEST_INTERPRETER
+ while(1)
+#endif
+ {
+#if defined(HAVE_TRACE)
__builtin_prefetch((void*)addr, 0, 0);
emu->prev2_ip = emu->old_ip;
if(my_context->dec && (
@@ -76,13 +87,15 @@ x64emurun:
rep = opcode-0xF1;
opcode = F8;
}
- while((opcode==0x3E)) //Branch Taken Hint ignored
+ while((opcode==0x3E) || (opcode==0x26)) //Branch Taken Hint ignored
opcode = F8;
rex.rex = 0;
- while(opcode>=0x40 && opcode<=0x4f) {
- rex.rex = opcode;
- opcode = F8;
- }
+ rex.is32bits = is32bits;
+ if(!is32bits)
+ while(opcode>=0x40 && opcode<=0x4f) {
+ rex.rex = opcode;
+ opcode = F8;
+ }
switch(opcode) {
@@ -132,28 +145,58 @@ x64emurun:
break;
GO(0x00, add) /* ADD 0x00 -> 0x05 */
+ case 0x06: /* PUSH ES */
+ if(!rex.is32bits) {
+ unimp = 1;
+ goto fini;
+ }
+ Push32(emu, emu->segs[_ES]); // even if a segment is a 16bits, a 32bits push/pop is done
+ break;
+ case 0x07: /* POP ES */
+ if(!rex.is32bits) {
+ unimp = 1;
+ goto fini;
+ }
+ emu->segs[_ES] = Pop32(emu); // no check, no use....
+ emu->segs_serial[_ES] = 0;
+ break;
GO(0x08, or) /* OR 0x08 -> 0x0D */
case 0x0F: /* More instructions */
switch(rep) {
case 1:
+ #ifdef TEST_INTERPRETER
+ if(!(addr = TestF20F(test, rex, addr, &step)))
+ unimp = 1;
+ #else
if(!(addr = RunF20F(emu, rex, addr, &step))) {
unimp = 1;
goto fini;
}
if(step==2) STEP2;
+ #endif
break;
case 2:
+ #ifdef TEST_INTERPRETER
+ if(!(addr = TestF30F(test, rex, addr)))
+ unimp = 1;
+ #else
if(!(addr = RunF30F(emu, rex, addr))) {
unimp = 1;
goto fini;
}
+ #endif
break;
default:
+ #ifdef TEST_INTERPRETER
+ if(!(addr = Test0F(test, rex, addr, &step)))
+ unimp = 1;
+ #else
if(!(addr = Run0F(emu, rex, addr, &step))) {
unimp = 1;
goto fini;
}
if(step==2) STEP2;
+ #endif
break;
}
if(emu->quit) {
@@ -168,10 +211,50 @@ x64emurun:
GO(0x30, xor) /* XOR 0x30 -> 0x35 */
#undef GO
+ case 0x1E: /* PUSH DS */
+ if(!rex.is32bits) {
+ unimp = 1;
+ goto fini;
+ }
+ Push32(emu, emu->segs[_DS]); // even if a segment is a 16bits, a 32bits push/pop is done
+ break;
+ case 0x1F: /* POP DS */
+ if(!rex.is32bits) {
+ unimp = 1;
+ goto fini;
+ }
+ emu->segs[_DS] = Pop32(emu); // no check, no use....
+ emu->segs_serial[_DS] = 0;
+ break;
+
+ case 0x27: /* DAA */
+ if(rex.is32bits) {
+ R_AL = daa8(emu, R_AL);
+ } else {
+ unimp = 1;
+ goto fini;
+ }
+ break;
+ case 0x2F: /* DAS */
+ if(rex.is32bits) {
+ R_AL = das8(emu, R_AL);
+ } else {
+ unimp = 1;
+ goto fini;
+ }
+ break;
case 0x2E: /* segments are ignored */
+ case 0x26:
case 0x36: /* SS: (ignored) */
break;
-
+ case 0x37: /* AAA */
+ if(rex.is32bits) {
+ R_AX = aaa16(emu, R_AX);
+ } else {
+ unimp = 1;
+ goto fini;
+ }
+ break;
case 0x38:
nextop = F8;
GETEB(0);
@@ -212,12 +295,47 @@ x64emurun:
cmp32(emu, R_EAX, F32);
break;
+ case 0x3F: /* AAS */
+ if(rex.is32bits) {
+ R_AX = aas16(emu, R_AX);
+ } else {
+ unimp = 1;
+ goto fini;
+ }
+ break;
+ case 0x40:
+ case 0x41:
+ case 0x42:
+ case 0x43:
+ case 0x44:
+ case 0x45:
+ case 0x46:
+ case 0x47: /* INC Reg (32bits only)*/
+ tmp8u = opcode&7;
+ emu->regs[tmp8u].dword[0] = inc32(emu, emu->regs[tmp8u].dword[0]);
+ break;
+ case 0x48:
+ case 0x49:
+ case 0x4A:
+ case 0x4B:
+ case 0x4C:
+ case 0x4D:
+ case 0x4E:
+ case 0x4F: /* DEC Reg (32bits only)*/
+ tmp8u = opcode&7;
+ emu->regs[tmp8u].dword[0] = dec32(emu, emu->regs[tmp8u].dword[0]);
+ break;
case 0x54: /* PUSH ESP */
if(rex.b)
- Push(emu, R_R12);
+ Push64(emu, R_R12);
else {
- tmp64u = R_RSP;
- Push(emu, tmp64u);
+ if(rex.is32bits) {
+ tmp32u = R_ESP;
+ Push32(emu, tmp32u);
+ } else {
+ tmp64u = R_RSP;
+ Push64(emu, tmp64u);
+ }
}
break;
case 0x50:
@@ -228,7 +346,10 @@ x64emurun:
case 0x56:
case 0x57: /* PUSH Reg */
tmp8u = (opcode&7)+(rex.b<<3);
- Push(emu, emu->regs[tmp8u].q[0]);
+ if(rex.is32bits)
+ Push32(emu, emu->regs[tmp8u].dword[0]);
+ else
+ Push64(emu, emu->regs[tmp8u].q[0]);
break;
case 0x58:
case 0x59:
@@ -239,22 +360,70 @@ x64emurun:
case 0x5E:
case 0x5F: /* POP Reg */
tmp8u = (opcode&7)+(rex.b<<3);
- emu->regs[tmp8u].q[0] = Pop(emu);
+ emu->regs[tmp8u].q[0] = is32bits?Pop32(emu):Pop64(emu);
+ break;
+ case 0x60: /* PUSHAD */
+ if(rex.is32bits) {
+ tmp32u = R_ESP;
+ Push32(emu, R_EAX);
+ Push32(emu, R_ECX);
+ Push32(emu, R_EDX);
+ Push32(emu, R_EBX);
+ Push32(emu, tmp32u);
+ Push32(emu, R_EBP);
+ Push32(emu, R_ESI);
+ Push32(emu, R_EDI);
+ } else {
+ unimp = 1;
+ goto fini;
+ }
+ break;
+ case 0x61: /* POPAD */
+ if(rex.is32bits) {
+ R_EDI = Pop32(emu);
+ R_ESI = Pop32(emu);
+ R_EBP = Pop32(emu);
+ R_ESP+=4; // POP ESP
+ R_EBX = Pop32(emu);
+ R_EDX = Pop32(emu);
+ R_ECX = Pop32(emu);
+ R_EAX = Pop32(emu);
+ } else {
+ unimp = 1;
+ goto fini;
+ }
+ break;
+ case 0x62: /* BOUND Gd, Ed */
+ if(rex.is32bits) {
+ FAKEED(0);
+ } else {
+ unimp = 1;
+ goto fini;
+ }
break;
-
case 0x63: /* MOVSXD Gd,Ed */
nextop = F8;
GETED(0);
GETGD;
- if(rex.w)
- GD->sq[0] = ED->sdword[0];
- else
- if(MODREG)
- GD->q[0] = ED->dword[0]; // not really a sign extension
+ if(rex.is32bits) {
+ // ARPL here
+ // faking to always happy...
+ SET_FLAG(F_ZF);
+ } else {
+ if(rex.w)
+ GD->sq[0] = ED->sdword[0];
else
- GD->sdword[0] = ED->sdword[0]; // meh?
+ if(MODREG)
+ GD->q[0] = ED->dword[0]; // not really a sign extension
+ else
+ GD->sdword[0] = ED->sdword[0]; // meh?
+ }
break;
case 0x64: /* FS: prefix */
+ #ifdef TEST_INTERPRETER
+ if(!(addr = Test64(test, rex, _FS, addr)))
+ unimp = 1;
+ #else
if(!(addr = Run64(emu, rex, _FS, addr))) {
unimp = 1;
goto fini;
@@ -263,8 +432,14 @@ x64emurun:
R_RIP = addr;
goto fini;
}
+ is32bits = (emu->segs[_CS]==0x23);
+ #endif
break;
case 0x65: /* GS: prefix */
+ #ifdef TEST_INTERPRETER
+ if(!(addr = Test64(test, rex, _GS, addr)))
+ unimp = 1;
+ #else
if(!(addr = Run64(emu, rex, _GS, addr))) {
unimp = 1;
goto fini;
@@ -273,8 +448,14 @@ x64emurun:
R_RIP = addr;
goto fini;
}
+ is32bits = (emu->segs[_CS]==0x23);
+ #endif
break;
case 0x66: /* 16bits prefix */
+ #ifdef TEST_INTERPRETER
+ if(!(addr = Test66(test, rex, rep, addr)))
+ unimp = 1;
+ #else
if(!(addr = Run66(emu, rex, rep, addr))) {
unimp = 1;
goto fini;
@@ -283,8 +464,13 @@ x64emurun:
R_RIP = addr;
goto fini;
}
+ #endif
break;
case 0x67: /* reduce EASize prefix */
+ #ifdef TEST_INTERPRETER
+ if(!(addr = Test67(test, rex, rep, addr)))
+ unimp = 1;
+ #else
if(!(addr = Run67(emu, rex, rep, addr))) {
unimp = 1;
goto fini;
@@ -293,9 +479,13 @@ x64emurun:
R_RIP = addr;
goto fini;
}
+ #endif
break;
case 0x68: /* Push Id */
- Push(emu, F32S64);
+ if(rex.is32bits)
+ Push32(emu, F32);
+ else
+ Push64(emu, F32S64);
break;
case 0x69: /* IMUL Gd,Ed,Id */
nextop = F8;
@@ -308,8 +498,13 @@ x64emurun:
GD->q[0] = imul32(emu, ED->dword[0], tmp64u);
break;
case 0x6A: /* Push Ib */
- tmp64s = F8S;
- Push(emu, (uint64_t)tmp64s);
+ if(rex.is32bits) {
+ tmp32s = F8S;
+ Push32(emu, (uint32_t)tmp32s);
+ } else {
+ tmp64s = F8S;
+ Push64(emu, (uint64_t)tmp64s);
+ }
break;
case 0x6B: /* IMUL Gd,Ed,Ib */
nextop = F8;
@@ -322,12 +517,78 @@ x64emurun:
GD->q[0] = imul32(emu, ED->dword[0], (uint32_t)tmp64s);
break;
case 0x6C: /* INSB DX */
+ if(rex.is32bits) {
+ tmp32u = rep?R_ECX:1;
+ while(tmp32u--) {
+ *(int8_t*)(R_EDI+GetESBaseEmu(emu)) = 0; // faking port read, using explicit ES segment
+ if(ACCESS_FLAG(F_DF))
+ R_EDI-=1;
+ else
+ R_EDI+=1;
+ }
+ if(rep)
+ R_ECX = 0;
+ } else {
+ // this is a privilege opcode in 64bits, but not in 32bits...
+ #ifndef TEST_INTERPRETOR
+ emit_signal(emu, SIGSEGV, (void*)R_RIP, 0);
+ STEP;
+ #endif
+ }
+ break;
case 0x6D: /* INSL DX */
+ if(rex.is32bits) {
+ tmp32u = rep?R_ECX:1;
+ while(tmp32u--) {
+ *(int32_t*)(R_EDI+GetESBaseEmu(emu)) = 0; // faking port read, using explicit ES segment
+ if(ACCESS_FLAG(F_DF))
+ R_EDI-=4;
+ else
+ R_EDI+=4;
+ }
+ if(rep)
+ R_ECX = 0;
+ } else {
+ // this is a privilege opcode in 64bits, but not in 32bits...
+ #ifndef TEST_INTERPRETOR
+ emit_signal(emu, SIGSEGV, (void*)R_RIP, 0);
+ STEP;
+ #endif
+ }
+ break;
case 0x6E: /* OUTSB DX */
+ if(rex.is32bits) {
+ // faking port write, using explicit ES segment
+ if(ACCESS_FLAG(F_DF))
+ R_ESI-=rep?R_ECX:1;
+ else
+ R_ESI+=1?R_ECX:1;
+ if(rep)
+ R_ECX = 0;
+ } else {
+ // this is a privilege opcode in 64bits, but not in 32bits...
+ #ifndef TEST_INTERPRETOR
+ emit_signal(emu, SIGSEGV, (void*)R_RIP, 0);
+ STEP;
+ #endif
+ }
+ break;
case 0x6F: /* OUTSL DX */
- // this is a privilege opcode...
- emit_signal(emu, SIGSEGV, (void*)R_RIP, 0);
- STEP;
+ if(rex.is32bits) {
+ // faking port write, using explicit ES segment
+ if(ACCESS_FLAG(F_DF))
+ R_ESI-=(rep?R_ECX:1)*4;
+ else
+ R_ESI+=(rep?R_ECX:1)*4;
+ if(rep)
+ R_ECX = 0;
+ } else {
+ // this is a privilege opcode in 64bits, but not in 32bits...
+ #ifndef TEST_INTERPRETOR
+ emit_signal(emu, SIGSEGV, (void*)R_RIP, 0);
+ STEP;
+ #endif
+ }
break;
GOCOND(0x70
@@ -336,6 +597,12 @@ x64emurun:
,,STEP2
) /* Jxx Ib */
+ case 0x82:
+ if(!rex.is32bits) {
+ unimp = 1;
+ goto fini;
+ }
+ // fallthru
case 0x80: /* GRP Eb,Ib */
nextop = F8;
GETEB(1);
@@ -416,7 +683,7 @@ x64emurun:
break;
case 0x86: /* XCHG Eb,Gb */
nextop = F8;
-#ifdef DYNAREC
+#if defined(DYNAREC) && !defined(TEST_INTERPRETER)
GETEB(0);
GETGB;
if(MODREG) { // reg / reg: no lock
@@ -424,27 +691,24 @@ x64emurun:
GB = EB->byte[0];
EB->byte[0] = tmp8u;
} else {
- do {
- tmp8u = native_lock_read_b(EB);
- } while(native_lock_write_b(EB, GB));
- GB = tmp8u;
+ GB = native_lock_xchg_b(EB, GB);
}
// dynarec use need it's own mecanism
#else
GETEB(0);
GETGB;
if(!MODREG)
- pthread_mutex_lock(&emu->context->mutex_lock); // XCHG always LOCK (but when accessing memory only)
+ pthread_mutex_lock(&my_context->mutex_lock); // XCHG always LOCK (but when accessing memory only)
tmp8u = GB;
GB = EB->byte[0];
EB->byte[0] = tmp8u;
if(!MODREG)
- pthread_mutex_unlock(&emu->context->mutex_lock);
+ pthread_mutex_unlock(&my_context->mutex_lock);
#endif
break;
case 0x87: /* XCHG Ed,Gd */
nextop = F8;
-#ifdef DYNAREC
+#if defined(DYNAREC) && !defined(TEST_INTERPRETER)
GETED(0);
GETGD;
if(MODREG) {
@@ -459,19 +723,16 @@ x64emurun:
}
} else {
if(rex.w) {
- GD->q[0] = native_lock_xchg(ED, GD->q[0]);
+ GD->q[0] = native_lock_xchg_dd(ED, GD->q[0]);
} else {
- do {
- tmp32u = native_lock_read_d(ED);
- } while(native_lock_write_d(ED, GD->dword[0]));
- GD->q[0] = tmp32u;
+ GD->q[0] = native_lock_xchg_d(ED, GD->dword[0]);
}
}
#else
GETED(0);
GETGD;
if(!MODREG)
- pthread_mutex_lock(&emu->context->mutex_lock); // XCHG always LOCK (but when accessing memory only)
+ pthread_mutex_lock(&my_context->mutex_lock); // XCHG always LOCK (but when accessing memory only)
if(rex.w) {
tmp64u = GD->q[0];
GD->q[0] = ED->q[0];
@@ -485,7 +746,7 @@ x64emurun:
ED->dword[0] = tmp32u;
}
if(!MODREG)
- pthread_mutex_unlock(&emu->context->mutex_lock);
+ pthread_mutex_unlock(&my_context->mutex_lock);
#endif
break;
case 0x88: /* MOV Eb,Gb */
@@ -533,24 +794,37 @@ x64emurun:
break;
case 0x8D: /* LEA Gd,M */
nextop = F8;
- GETED(0);
GETGD;
+ tmp64u = GETEA(0);
if(rex.w)
- GD->q[0] = (uint64_t)ED;
+ GD->q[0] = tmp64u;
else
- GD->q[0] = ((uintptr_t)ED)&0xffffffff;
+ GD->q[0] = tmp64u&0xffffffff;
+ break;
+ case 0x8E: /* MOV Seg, Ew */
+ nextop = F8;
+ GETED(0);
+ emu->segs[((nextop&0x38)>>3)] = ED->word[0];
+ emu->segs_serial[((nextop&0x38)>>3)] = 0;
break;
-
case 0x8F: /* POP Ed */
nextop = F8;
if(MODREG) {
- emu->regs[(nextop&7)+(rex.b<<3)].q[0] = Pop(emu);
+ emu->regs[(nextop&7)+(rex.b<<3)].q[0] = rex.is32bits?Pop32(emu):Pop64(emu);
} else {
- tmp64u = Pop(emu); // this order allows handling POP [ESP] and variant
- GETED(0);
- R_ESP -= sizeof(void*); // to prevent issue with SEGFAULT
- ED->q[0] = tmp64u;
- R_ESP += sizeof(void*);
+ if(rex.is32bits) {
+ tmp32u = Pop32(emu); // this order allows handling POP [ESP] and variant
+ GETED(0);
+ R_ESP -= 4; // to prevent issue with SEGFAULT
+ ED->dword[0] = tmp32u;
+ R_ESP += 4;
+ } else {
+ tmp64u = Pop64(emu); // this order allows handling POP [ESP] and variant
+ GETED(0);
+ R_RSP -= sizeof(void*); // to prevent issue with SEGFAULT
+ ED->q[0] = tmp64u;
+ R_RSP += sizeof(void*);
+ }
}
break;
case 0x90: /* NOP or XCHG R8, RAX*/
@@ -594,11 +868,23 @@ x64emurun:
break;
case 0x9C: /* PUSHF */
CHECK_FLAGS(emu);
- Push(emu, emu->eflags.x64);
+ if(rex.is32bits)
+ Push32(emu, emu->eflags.x64);
+ else
+ Push64(emu, emu->eflags.x64);
break;
case 0x9D: /* POPF */
- emu->eflags.x64 = ((Pop(emu) & 0x3F7FD7)/* & (0xffff-40)*/ ) | 0x2; // mask off res2 and res3 and on res1
+ emu->eflags.x64 = (((rex.is32bits?Pop32(emu):Pop64(emu)) & 0x3F7FD7)/* & (0xffff-40)*/ ) | 0x2; // mask off res2 and res3 and on res1
RESET_FLAGS(emu);
+ #ifndef TEST_INTERPRETER
+ if(ACCESS_FLAG(F_TF)) {
+ R_RIP = addr;
+ emit_signal(emu, SIGTRAP, (void*)addr, 1);
+ if(emu->quit) goto fini;
+ CLEAR_FLAG(F_TF);
+ STEP;
+ }
+ #endif
break;
case 0x9E: /* SAHF */
CHECK_FLAGS(emu);
@@ -615,28 +901,44 @@ x64emurun:
R_AH = (uint8_t)emu->eflags.x64;
break;
case 0xA0: /* MOV AL,Ob */
- R_AL = *(uint8_t*)F64;
+ if(rex.is32bits)
+ R_AL = *(uint8_t*)(uintptr_t)F32;
+ else
+ R_AL = *(uint8_t*)F64;
break;
case 0xA1: /* MOV EAX,Od */
- if(rex.w)
- R_RAX = *(uint64_t*)F64;
- else
- R_RAX = *(uint32_t*)F64;
+ if(rex.is32bits)
+ R_EAX = *(int32_t*)(uintptr_t)F32;
+ else {
+ if(rex.w)
+ R_RAX = *(uint64_t*)F64;
+ else
+ R_RAX = *(uint32_t*)F64;
+ }
break;
case 0xA2: /* MOV Ob,AL */
- *(uint8_t*)F64 = R_AL;
+ if(rex.is32bits)
+ *(uint8_t*)(uintptr_t)F32 = R_AL;
+ else
+ *(uint8_t*)F64 = R_AL;
break;
case 0xA3: /* MOV Od,EAX */
- if(rex.w)
- *(uint64_t*)F64 = R_RAX;
- else
- *(uint32_t*)F64 = R_EAX;
+ if(rex.is32bits)
+ *(uint32_t*)(uintptr_t)F32 = R_EAX;
+ else {
+ if(rex.w)
+ *(uint64_t*)F64 = R_RAX;
+ else
+ *(uint32_t*)F64 = R_EAX;
+ }
break;
case 0xA4: /* MOVSB */
tmp8s = ACCESS_FLAG(F_DF)?-1:+1;
tmp64u = (rep)?R_RCX:1L;
while(tmp64u) {
+ #ifndef TEST_INTERPRETER
*(uint8_t*)R_RDI = *(uint8_t*)R_RSI;
+ #endif
R_RDI += tmp8s;
R_RSI += tmp8s;
--tmp64u;
@@ -651,7 +953,9 @@ x64emurun:
tmp8s *= 8;
while(tmp64u) {
--tmp64u;
+ #ifndef TEST_INTERPRETER
*(uint64_t*)R_RDI = *(uint64_t*)R_RSI;
+ #endif
R_RDI += tmp8s;
R_RSI += tmp8s;
}
@@ -659,7 +963,9 @@ x64emurun:
tmp8s *= 4;
while(tmp64u) {
--tmp64u;
+ #ifndef TEST_INTERPRETER
*(uint32_t*)R_RDI = *(uint32_t*)R_RSI;
+ #endif
R_RDI += tmp8s;
R_RSI += tmp8s;
}
@@ -699,7 +1005,6 @@ x64emurun:
R_RCX = tmp64u;
break;
default:
- tmp8s = ACCESS_FLAG(F_DF)?-1:+1;
tmp8u = *(uint8_t*)R_RDI;
tmp8u2 = *(uint8_t*)R_RSI;
R_RDI += tmp8s;
@@ -769,14 +1074,12 @@ x64emurun:
break;
default:
if(rex.w) {
- tmp8s = ACCESS_FLAG(F_DF)?-8:+8;
tmp64u = *(uint64_t*)R_RDI;
tmp64u2 = *(uint64_t*)R_RSI;
R_RDI += tmp8s;
R_RSI += tmp8s;
cmp64(emu, tmp64u2, tmp64u);
} else {
- tmp8s = ACCESS_FLAG(F_DF)?-4:+4;
tmp32u = *(uint32_t*)R_RDI;
tmp32u2 = *(uint32_t*)R_RSI;
R_RDI += tmp8s;
@@ -799,7 +1102,9 @@ x64emurun:
tmp8s = ACCESS_FLAG(F_DF)?-1:+1;
tmp64u = (rep)?R_RCX:1L;
while(tmp64u) {
+ #ifndef TEST_INTERPRETER
*(uint8_t*)R_RDI = R_AL;
+ #endif
R_RDI += tmp8s;
--tmp64u;
}
@@ -814,7 +1119,9 @@ x64emurun:
tmp64u = (rep)?R_RCX:1L;
if((rex.w))
while(tmp64u) {
+ #ifndef TEST_INTERPRETER
*(uint64_t*)R_RDI = R_RAX;
+ #endif
R_RDI += tmp8s;
--tmp64u;
}
@@ -1039,15 +1346,40 @@ x64emurun:
break;
case 0xC2: /* RETN Iw */
tmp16u = F16;
- addr = Pop(emu);
+ addr = rex.is32bits?Pop32(emu):Pop64(emu);
R_RSP += tmp16u;
STEP2
break;
case 0xC3: /* RET */
- addr = Pop(emu);
+ addr = rex.is32bits?Pop32(emu):Pop64(emu);
STEP2
break;
-
+ case 0xC4: /* LES Gd,Ed */
+ if(rex.is32bits) {
+ nextop = F8;
+ GETED(0);
+ GETGD;
+ emu->segs[_ES] = *(__uint16_t*)(((char*)ED)+4);
+ emu->segs_serial[_ES] = 0;
+ GD->dword[0] = *(uint32_t*)ED;
+ } else {
+ // AVX not supported yet
+ emit_signal(emu, SIGILL, (void*)R_RIP, 0);
+ }
+ break;
+ case 0xC5: /* LDS Gd,Ed */
+ if(rex.is32bits) {
+ nextop = F8;
+ GETED(0);
+ GETGD;
+ emu->segs[_DS] = *(__uint16_t*)(((char*)ED)+4);
+ emu->segs_serial[_DS] = 0;
+ GD->dword[0] = *(uint32_t*)ED;
+ } else {
+ // AVX not supported yet
+ emit_signal(emu, SIGILL, (void*)R_RIP, 0);
+ }
+ break;
case 0xC6: /* MOV Eb,Ib */
nextop = F8;
GETEB(1);
@@ -1067,47 +1399,84 @@ x64emurun:
case 0xC8: /* ENTER Iw,Ib */
tmp16u = F16;
tmp8u = (F8) & 0x1f;
- tmp64u = R_RBP;
- Push(emu, R_RBP);
- R_RBP = R_RSP;
- if (tmp8u) {
- for (tmp8u2 = 1; tmp8u2 < tmp8u; tmp8u2++) {
- tmp64u -= sizeof(void*);
- Push(emu, *((uintptr_t*)tmp64u));
+ if(rex.is32bits) {
+ tmp64u = R_EBP;
+ Push32(emu, R_EBP);
+ R_EBP = R_ESP;
+ if (tmp8u) {
+ for (tmp8u2 = 1; tmp8u2 < tmp8u; tmp8u2++) {
+ tmp64u -= 4;
+ Push32(emu, *((uint32_t*)tmp64u));
+ }
+ Push32(emu, R_EBP);
+ }
+ } else {
+ tmp64u = R_RBP;
+ Push64(emu, R_RBP);
+ R_RBP = R_RSP;
+ if (tmp8u) {
+ for (tmp8u2 = 1; tmp8u2 < tmp8u; tmp8u2++) {
+ tmp64u -= sizeof(void*);
+ Push64(emu, *((uintptr_t*)tmp64u));
+ }
+ Push64(emu, R_RBP);
}
- Push(emu, R_RBP);
}
R_RSP -= tmp16u;
break;
case 0xC9: /* LEAVE */
R_RSP = R_RBP;
- R_RBP = Pop(emu);
+ R_RBP = rex.is32bits?Pop32(emu):Pop64(emu);
break;
case 0xCC: /* INT 3 */
+ #ifndef TEST_INTERPRETER
x64Int3(emu, &addr);
if(emu->quit) goto fini; // R_RIP is up to date when returning from x64Int3
addr = R_RIP;
+ #endif
break;
case 0xCD: /* INT n */
+ tmp8u = F8;
// this is a privilege opcode...
- emit_signal(emu, SIGSEGV, (void*)R_RIP, 0);
- STEP;
+ if(box64_wine && tmp8u==0x2D) {
+ // lets ignore the INT 2D
+ printf_log(LOG_DEBUG, "INT 2D called\n");
+ emit_interruption(emu, 0x2d, (void*)R_RIP);
+ } else if(box64_wine && tmp8u==0x2c) {
+ printf_log(LOG_DEBUG, "INT 2c called\n");
+ emit_interruption(emu, 0x2c, (void*)R_RIP);
+ } else if(box64_wine && tmp8u==0x29) {
+ // INT 29 is __fastfail
+ printf_log(LOG_DEBUG, "INT 29 called => __fastfail(0x%x)\n", R_ECX);
+ emit_interruption(emu, 0x29, (void*)R_RIP);
+ } else if (tmp8u==0x80) {
+ // 32bits syscall
+ #ifndef TEST_INTERPRETER
+ x86Syscall(emu);
+ STEP;
+ #endif
+ } else {
+ #ifndef TEST_INTERPRETER
+ emit_signal(emu, SIGSEGV, (void*)R_RIP, 0);
+ STEP;
+ #endif
+ }
break;
-
case 0xCF: /* IRET */
- addr = Pop(emu);
- emu->segs[_CS] = Pop(emu)&0xffff;
+ addr = rex.is32bits?Pop32(emu):Pop64(emu);
+ emu->segs[_CS] = (rex.is32bits?Pop32(emu):Pop64(emu))&0xffff;
emu->segs_serial[_CS] = 0;
- emu->eflags.x64 = ((Pop(emu) & 0x3F7FD7)/* & (0xffff-40)*/ ) | 0x2; // mask off res2 and res3 and on res1
- tmp64u = Pop(emu); //RSP
- emu->segs[_SS] = Pop(emu)&0xffff;
+ emu->eflags.x64 = (((rex.is32bits?Pop32(emu):Pop64(emu)) & 0x3F7FD7)/* & (0xffff-40)*/ ) | 0x2; // mask off res2 and res3 and on res1
+ tmp64u = rex.is32bits?Pop32(emu):Pop64(emu); //RSP
+ emu->segs[_SS] = (rex.is32bits?Pop32(emu):Pop64(emu))&0xffff;
emu->segs_serial[_SS] = 0;
- R_RSP= tmp64u;
+ R_RSP = tmp64u;
RESET_FLAGS(emu);
R_RIP = addr;
- goto fini; // exit, to recompute CS if needed
+ STEP;
+ is32bits = (emu->segs[_CS]==0x23);
break;
case 0xD0: /* GRP2 Eb,1 */
case 0xD2: /* GRP2 Eb,CL */
@@ -1167,10 +1536,23 @@ x64emurun:
}
break;
+ case 0xD6: /* SALC */
+ if(rex.is32bits) {
+ CHECK_FLAGS(emu);
+ R_AL = ACCESS_FLAG(F_CF)?0xff:0x00;
+ } else {
+ unimp = 1;
+ goto fini;
+ };
+ break;
case 0xD7: /* XLAT */
R_AL = *(uint8_t*)(R_RBX + R_AL);
break;
case 0xD8: /* x87 opcodes */
+ #ifdef TEST_INTERPRETER
+ if(!(addr = TestD8(test, rex, addr)))
+ unimp = 1;
+ #else
if(!(addr = RunD8(emu, rex, addr))) {
unimp = 1;
goto fini;
@@ -1179,8 +1561,13 @@ x64emurun:
R_RIP = addr;
goto fini;
}
+ #endif
break;
case 0xD9: /* x87 opcodes */
+ #ifdef TEST_INTERPRETER
+ if(!(addr = TestD9(test, rex, addr)))
+ unimp = 1;
+ #else
if(!(addr = RunD9(emu, rex, addr))) {
unimp = 1;
goto fini;
@@ -1189,8 +1576,13 @@ x64emurun:
R_RIP = addr;
goto fini;
}
+ #endif
break;
case 0xDA: /* x87 opcodes */
+ #ifdef TEST_INTERPRETER
+ if(!(addr = TestDA(test, rex, addr)))
+ unimp = 1;
+ #else
if(!(addr = RunDA(emu, rex, addr))) {
unimp = 1;
goto fini;
@@ -1199,8 +1591,13 @@ x64emurun:
R_RIP = addr;
goto fini;
}
+ #endif
break;
case 0xDB: /* x87 opcodes */
+ #ifdef TEST_INTERPRETER
+ if(!(addr = TestDB(test, rex, addr)))
+ unimp = 1;
+ #else
if(!(addr = RunDB(emu, rex, addr))) {
unimp = 1;
goto fini;
@@ -1209,8 +1606,13 @@ x64emurun:
R_RIP = addr;
goto fini;
}
+ #endif
break;
case 0xDC: /* x87 opcodes */
+ #ifdef TEST_INTERPRETER
+ if(!(addr = TestDC(test, rex, addr)))
+ unimp = 1;
+ #else
if(!(addr = RunDC(emu, rex, addr))) {
unimp = 1;
goto fini;
@@ -1219,8 +1621,13 @@ x64emurun:
R_RIP = addr;
goto fini;
}
+ #endif
break;
case 0xDD: /* x87 opcodes */
+ #ifdef TEST_INTERPRETER
+ if(!(addr = TestDD(test, rex, addr)))
+ unimp = 1;
+ #else
if(!(addr = RunDD(emu, rex, addr))) {
unimp = 1;
goto fini;
@@ -1229,8 +1636,13 @@ x64emurun:
R_RIP = addr;
goto fini;
}
+ #endif
break;
case 0xDE: /* x87 opcodes */
+ #ifdef TEST_INTERPRETER
+ if(!(addr = TestDE(test, rex, addr)))
+ unimp = 1;
+ #else
if(!(addr = RunDE(emu, rex, addr))) {
unimp = 1;
goto fini;
@@ -1239,8 +1651,13 @@ x64emurun:
R_RIP = addr;
goto fini;
}
+ #endif
break;
case 0xDF: /* x87 opcodes */
+ #ifdef TEST_INTERPRETER
+ if(!(addr = TestDF(test, rex, addr)))
+ unimp = 1;
+ #else
if(!(addr = RunDF(emu, rex, addr))) {
unimp = 1;
goto fini;
@@ -1249,6 +1666,7 @@ x64emurun:
R_RIP = addr;
goto fini;
}
+ #endif
break;
case 0xE0: /* LOOPNZ */
CHECK_FLAGS(emu);
@@ -1284,18 +1702,24 @@ x64emurun:
case 0xE6: /* OUT XX, AL */
case 0xE7: /* OUT XX, EAX */
// this is a privilege opcode...
+ #ifndef TEST_INTERPRETER
emit_signal(emu, SIGSEGV, (void*)R_RIP, 0);
STEP;
+ #endif
break;
case 0xE8: /* CALL Id */
tmp32s = F32S; // call is relative
- Push(emu, addr);
+ if(rex.is32bits)
+ Push32(emu, addr);
+ else
+ Push64(emu, addr);
addr += tmp32s;
STEP2
break;
case 0xE9: /* JMP Id */
tmp32s = F32S; // jmp is relative
addr += tmp32s;
+ addr = (uintptr_t)getAlternate((void*)addr);
STEP2
break;
@@ -1309,10 +1733,16 @@ x64emurun:
case 0xEE: /* OUT DX, AL */
case 0xEF: /* OUT DX, EAX */
// this is a privilege opcode...
+ #ifndef TEST_INTERPRETER
emit_signal(emu, SIGSEGV, (void*)R_RIP, 0);
STEP;
+ #endif
break;
case 0xF0: /* LOCK prefix */
+ #ifdef TEST_INTERPRETER
+ if(!(addr = TestF0(test, rex, addr)))
+ unimp = 1;
+ #else
if(!(addr = RunF0(emu, rex, addr))) {
unimp = 1;
goto fini;
@@ -1321,12 +1751,15 @@ x64emurun:
R_RIP = addr;
goto fini;
}
+ #endif
break;
case 0xF4: /* HLT */
// this is a privilege opcode...
+ #ifndef TEST_INTERPRETER
emit_signal(emu, SIGSEGV, (void*)R_RIP, 0);
STEP;
+ #endif
break;
case 0xF5: /* CMC */
CHECK_FLAGS(emu);
@@ -1443,12 +1876,12 @@ x64emurun:
SET_FLAG(F_CF);
break;
case 0xFA: /* CLI */
- // this is a privilege opcode...
+ // this is a privilege opcode
emit_signal(emu, SIGSEGV, (void*)R_RIP, 0);
STEP;
break;
case 0xFB: /* STI */
- // this is a privilege opcode...
+ // this is a privilege opcode
emit_signal(emu, SIGSEGV, (void*)R_RIP, 0);
STEP;
break;
@@ -1475,9 +1908,9 @@ x64emurun:
break;
case 0xFF: /* GRP 5 Ed */
nextop = F8;
- GETED(0);
switch((nextop>>3)&7) {
case 0: /* INC Ed */
+ GETED(0);
if(rex.w)
ED->q[0] = inc64(emu, ED->q[0]);
else {
@@ -1488,6 +1921,7 @@ x64emurun:
}
break;
case 1: /* DEC Ed */
+ GETED(0);
if(rex.w)
ED->q[0] = dec64(emu, ED->q[0]);
else {
@@ -1498,49 +1932,78 @@ x64emurun:
}
break;
case 2: /* CALL NEAR Ed */
- tmp64u = (uintptr_t)getAlternate((void*)ED->q[0]);
- Push(emu, addr);
+ GETE8(0);
+ if(rex.is32bits) {
+ tmp64u = (uintptr_t)ED->dword[0];
+ Push32(emu, addr);
+ } else {
+ tmp64u = (uintptr_t)getAlternate((void*)ED->q[0]);
+ Push64(emu, addr);
+ }
addr = tmp64u;
STEP2
break;
case 3: /* CALL FAR Ed */
+ GETET(0);
if(MODREG) {
- printf_log(LOG_NONE, "Illegal Opcode %p: %02X %02X %02X %02X\n", (void*)R_RIP, opcode, nextop, PK(2), PK(3));
- emu->quit=1;
- emu->error |= ERR_ILLEGAL;
+ printf_log(LOG_NONE, "Illegal Opcode %p: (%02X %02X %02X %02X) %02X %02X %02X %02X\n", (void*)R_RIP, PK(-6), PK(-5), PK(-4), PK(-3), opcode, nextop, PK(0), PK(1));
+ emit_signal(emu, SIGILL, (void*)R_RIP, 0);
goto fini;
} else {
- Push(emu, R_CS);
- Push(emu, addr);
- R_RIP = addr = (uintptr_t)getAlternate((void*)ED->q[0]); // check CS?
- R_CS = (ED+1)->word[0];
- goto fini; // exit loop to recompute new CS...
+ if(rex.is32bits || !rex.w) {
+ Push32(emu, R_CS);
+ Push32(emu, addr);
+ addr = (uintptr_t)getAlternate((void*)(uintptr_t)ED->dword[0]);
+ R_CS = ED->word[2];
+ } else {
+ Push64(emu, R_CS);
+ Push64(emu, addr);
+ addr = (uintptr_t)getAlternate((void*)ED->q[0]);
+ R_CS = (ED+1)->word[0];
+ }
+ STEP2;
+ is32bits = (emu->segs[_CS]==0x23);
}
break;
case 4: /* JMP NEAR Ed */
- addr = (uintptr_t)getAlternate((void*)ED->q[0]);
+ GETE8(0);
+ if(rex.is32bits)
+ addr = (uintptr_t)ED->dword[0];
+ else
+ addr = (uintptr_t)getAlternate((void*)ED->q[0]);
STEP2
break;
case 5: /* JMP FAR Ed */
+ GETET(0);
if(MODREG) {
- printf_log(LOG_NONE, "Illegal Opcode %p: 0x%02X 0x%02X %02X %02X\n", (void*)R_RIP, opcode, nextop, PK(2), PK(3));
- emu->quit=1;
- emu->error |= ERR_ILLEGAL;
+ printf_log(LOG_NONE, "Illegal Opcode %p: (%02X %02X %02X %02X) %02X %02X %02X %02X\n", (void*)R_RIP, PK(-6), PK(-5), PK(-4), PK(-3), opcode, nextop, PK(0), PK(1));
+ emit_signal(emu, SIGILL, (void*)R_RIP, 0);
goto fini;
} else {
- R_RIP = (uintptr_t)getAlternate((void*)ED->q[0]); //check CS?
- R_CS = (ED+1)->word[0];
- goto fini; // exit loop to recompute CS...
+ if(rex.is32bits || !rex.w) {
+ addr = (uintptr_t)getAlternate((void*)(uintptr_t)ED->dword[0]);
+ R_CS = ED->word[2];
+ } else {
+ addr = (uintptr_t)getAlternate((void*)ED->q[0]);
+ R_CS = (ED+1)->word[0];
+ }
+ STEP2;
+ is32bits = (emu->segs[_CS]==0x23);
}
break;
case 6: /* Push Ed */
- tmp64u = ED->q[0]; // rex.w ignored
- Push(emu, tmp64u); // avoid potential issue with push [esp+...]
+ _GETED(0);
+ if(rex.is32bits) {
+ tmp32u = ED->dword[0];
+ Push32(emu, tmp32u); // avoid potential issue with push [esp+...]
+ } else {
+ tmp64u = ED->q[0]; // rex.w ignored
+ Push64(emu, tmp64u); // avoid potential issue with push [esp+...]
+ }
break;
default:
- printf_log(LOG_NONE, "Illegal Opcode %p: %02X %02X %02X %02X %02X %02X\n",(void*)R_RIP, opcode, nextop, PK(2), PK(3), PK(4), PK(5));
- emu->quit=1;
- emu->error |= ERR_ILLEGAL;
+ printf_log(LOG_NONE, "Illegal Opcode %p: (%02X %02X %02X %02X) %02X %02X %02X %02X %02X %02X\n", (void*)R_RIP, PK(-6), PK(-5), PK(-4), PK(-3), opcode, nextop, PK(0), PK(1), PK(2), PK(3));
+ emit_signal(emu, SIGILL, (void*)R_RIP, 0);
goto fini;
}
break;
@@ -1553,10 +2016,12 @@ x64emurun:
fini:
+if(emu->segs[_CS]!=0x33 && emu->segs[_CS]!=0x23) printf_log(LOG_NONE, "Warning, CS is not default value: 0x%x\n", emu->segs[_CS]);
+#ifndef TEST_INTERPRETER
printf_log(LOG_DEBUG, "End of X86 run (%p), RIP=%p, Stack=%p, unimp=%d, emu->fork=%d, emu->uc_link=%p, emu->quit=%d\n", emu, (void*)R_RIP, (void*)R_RSP, unimp, emu->fork, emu->uc_link, emu->quit);
if(unimp) {
emu->quit = 1;
- UnimpOpcode(emu);
+ UnimpOpcode(emu, is32bits);
}
// fork handling
if(emu->fork) {
@@ -1576,5 +2041,11 @@ fini:
addr = R_RIP;
goto x64emurun;
}
+#else
+ if(unimp) {
+ printf_log(LOG_INFO, "Warning, inimplemented opcode in Test Interpreter\n");
+ } else
+ addr = R_RIP;
+#endif
return 0;
}
diff --git a/src/emu/x64run0f.c b/src/emu/x64run0f.c
index 05c9aab..466220b 100644
--- a/src/emu/x64run0f.c
+++ b/src/emu/x64run0f.c
@@ -28,7 +28,11 @@
#include "modrm.h"
+#ifdef TEST_INTERPRETER
+uintptr_t Test0F(x64test_t *test, rex_t rex, uintptr_t addr, int *step)
+#else
uintptr_t Run0F(x64emu_t *emu, rex_t rex, uintptr_t addr, int *step)
+#endif
{
uint8_t opcode;
uint8_t nextop;
@@ -42,27 +46,38 @@ uintptr_t Run0F(x64emu_t *emu, rex_t rex, uintptr_t addr, int *step)
sse_regs_t *opex, *opgx, eax1;
mmx87_regs_t *opem, *opgm, eam1;
+#ifdef TEST_INTERPRETER
+ x64emu_t *emu = test->emu;
+#endif
opcode = F8;
switch(opcode) {
case 0x05: /* SYSCALL */
+ #ifndef TEST_INTERPRETER
R_RIP = addr;
x64Syscall(emu);
+ #endif
break;
case 0x06: /* CLTS */
// this is a privilege opcode...
+ #ifndef TEST_INTERPRETER
emit_signal(emu, SIGSEGV, (void*)R_RIP, 0);
+ #endif
break;
case 0x08: /* INVD */
case 0x09: /* WBINVD */
// this is a privilege opcode...
+ #ifndef TEST_INTERPRETER
emit_signal(emu, SIGSEGV, (void*)R_RIP, 0);
+ #endif
break;
case 0x0B: /* UD2 */
+ #ifndef TEST_INTERPRETER
emit_signal(emu, SIGILL, (void*)R_RIP, 0);
+ #endif
break;
case 0x0D:
@@ -93,7 +108,7 @@ uintptr_t Run0F(x64emu_t *emu, rex_t rex, uintptr_t addr, int *step)
nextop = F8;
GETEX(0);
GETGX;
- if((nextop&0xC0)==0xC0) /* MOVHLPS Gx,Ex */
+ if(MODREG) /* MOVHLPS Gx,Ex */
GX->q[0] = EX->q[1];
else
GX->q[0] = EX->q[0]; /* MOVLPS Gx,Ex */
@@ -135,7 +150,7 @@ uintptr_t Run0F(x64emu_t *emu, rex_t rex, uintptr_t addr, int *step)
break;
case 0x18: /* PREFETCHh Ed */
nextop = F8;
- GETED(0);
+ _GETED(0);
if(MODREG) {
} else
switch((nextop>>3)&7) {
@@ -152,14 +167,16 @@ uintptr_t Run0F(x64emu_t *emu, rex_t rex, uintptr_t addr, int *step)
case 0x1F: /* NOP (multi-byte) */
nextop = F8;
- GETED(0);
+ FAKEED(0);
break;
case 0x20: /* MOV REG, crX */
case 0x21: /* MOV REG, drX */
case 0x22: /* MOV cxR, REG */
case 0x23: /* MOV drX, REG */
// this is a privilege opcode...
+ #ifndef TEST_INTERPRETER
emit_signal(emu, SIGSEGV, (void*)R_RIP, 0);
+ #endif
break;
case 0x28: /* MOVAPS Gx,Ex */
@@ -194,38 +211,45 @@ uintptr_t Run0F(x64emu_t *emu, rex_t rex, uintptr_t addr, int *step)
nextop = F8;
GETEX(0);
GETGM;
- if(isnanf(EX->f[1]) || isinff(EX->f[1]) || EX->f[1]>0x7fffffff)
- GM->sd[1] = 0x80000000;
+ tmp64s = EX->f[1];
+ if (tmp64s==(int32_t)tmp64s && !isnanf(EX->f[1]))
+ GM->sd[1] = (int32_t)tmp64s;
else
- GM->sd[1] = EX->f[1];
- if(isnanf(EX->f[0]) || isinff(EX->f[0]) || EX->f[0]>0x7fffffff)
- GM->sd[0] = 0x80000000;
+ GM->sd[1] = INT32_MIN;
+ tmp64s = EX->f[0];
+ if (tmp64s==(int32_t)tmp64s && !isnanf(EX->f[0]))
+ GM->sd[0] = (int32_t)tmp64s;
else
- GM->sd[0] = EX->f[0];
+ GM->sd[0] = INT32_MIN;
break;
case 0x2D: /* CVTPS2PI Gm, Ex */
// rounding should be done; and indefinite integer should also be assigned if overflow or NaN/Inf
nextop = F8;
GETEX(0);
GETGM;
- for(int i=1; i>=0; --i)
- if(isnanf(EX->f[i]) || isinff(EX->f[i]) || EX->f[i]>0x7fffffff)
- GM->sd[i] = 0x80000000;
+ for(int i=1; i>=0; --i) {
+ if(isnanf(EX->f[i]))
+ tmp64s = INT32_MIN;
else
switch(emu->mxcsr.f.MXCSR_RC) {
case ROUND_Nearest:
- GM->sd[i] = nearbyintf(EX->f[i]);
+ tmp64s = nearbyintf(EX->f[i]);
break;
case ROUND_Down:
- GM->sd[i] = floorf(EX->f[i]);
+ tmp64s = floorf(EX->f[i]);
break;
case ROUND_Up:
- GM->sd[i] = ceilf(EX->f[i]);
+ tmp64s = ceilf(EX->f[i]);
break;
case ROUND_Chop:
- GM->sd[i] = EX->f[i];
+ tmp64s = EX->f[i];
break;
}
+ if (tmp64s==(int32_t)tmp64s)
+ GM->sd[i] = (int32_t)tmp64s;
+ else
+ GM->sd[i] = INT32_MIN;
+ }
break;
case 0x2E: /* UCOMISS Gx, Ex */
// same for now
@@ -326,8 +350,12 @@ uintptr_t Run0F(x64emu_t *emu, rex_t rex, uintptr_t addr, int *step)
GETED(0);
if(rex.w)
ED->q[0] = __builtin_bswap64(GD->q[0]);
- else
- ED->q[0] = __builtin_bswap32(GD->dword[0]);
+ else {
+ if(MODREG)
+ ED->q[0] = __builtin_bswap32(GD->dword[0]);
+ else
+ ED->dword[0] = __builtin_bswap32(GD->dword[0]);
+ }
break;
default:
@@ -785,7 +813,19 @@ uintptr_t Run0F(x64emu_t *emu, rex_t rex, uintptr_t addr, int *step)
, EB->byte[0]=0;
,
) /* 0x90 -> 0x9F SETxx Eb */
-
+ case 0xA0: /* PUSH FS */
+ if(rex.is32bits)
+ Push32(emu, emu->segs[_FS]);
+ else
+ Push64(emu, emu->segs[_FS]);
+ break;
+ case 0xA1: /* POP FS */
+ if(rex.is32bits)
+ emu->segs[_FS] = Pop32(emu);
+ else
+ emu->segs[_FS] = Pop64(emu);
+ emu->segs_serial[_FS] = 0;
+ break;
case 0xA2: /* CPUID */
tmp32u = R_EAX;
my_cpuid(emu, tmp32u);
@@ -800,7 +840,15 @@ uintptr_t Run0F(x64emu_t *emu, rex_t rex, uintptr_t addr, int *step)
tmp32s >>= (rex.w?6:5);
if(!MODREG)
{
+ #ifdef TEST_INTERPRETER
+ test->memaddr=((test->memaddr)+(tmp32s<<(rex.w?3:2)));
+ if(rex.w)
+ *(uint64_t*)test->mem = *(uint64_t*)test->memaddr;
+ else
+ *(uint32_t*)test->mem = *(uint32_t*)test->memaddr;
+ #else
ED=(reg64_t*)(((uintptr_t)(ED))+(tmp32s<<(rex.w?3:2)));
+ #endif
}
if(rex.w) {
if(ED->q[0] & (1LL<<tmp8u))
@@ -833,6 +881,20 @@ uintptr_t Run0F(x64emu_t *emu, rex_t rex, uintptr_t addr, int *step)
}
break;
+ case 0xA8: /* PUSH GS */
+ if(rex.is32bits)
+ Push32(emu, emu->segs[_GS]);
+ else
+ Push64(emu, emu->segs[_GS]);
+ break;
+ case 0xA9: /* POP GS */
+ if(rex.is32bits)
+ emu->segs[_GS] = Pop32(emu);
+ else
+ emu->segs[_GS] = Pop64(emu);
+ emu->segs_serial[_FS] = 0;
+ break;
+
case 0xAB: /* BTS Ed,Gd */
CHECK_FLAGS(emu);
nextop = F8;
@@ -843,7 +905,15 @@ uintptr_t Run0F(x64emu_t *emu, rex_t rex, uintptr_t addr, int *step)
tmp64s >>= (rex.w?6:5);
if(!MODREG)
{
+ #ifdef TEST_INTERPRETER
+ test->memaddr=((test->memaddr)+(tmp64s<<(rex.w?3:2)));
+ if(rex.w)
+ *(uint64_t*)test->mem = *(uint64_t*)test->memaddr;
+ else
+ *(uint32_t*)test->mem = *(uint32_t*)test->memaddr;
+ #else
ED=(reg64_t*)(((uintptr_t)(ED))+(tmp64s<<(rex.w?3:2)));
+ #endif
}
if(rex.w) {
if(ED->q[0] & (1LL<<tmp8u))
@@ -889,30 +959,38 @@ uintptr_t Run0F(x64emu_t *emu, rex_t rex, uintptr_t addr, int *step)
if((nextop&0xF8)==0xF8) {
return addr; /* SFENCE */
}
- GETED(0);
switch((nextop>>3)&7) {
case 0: /* FXSAVE Ed */
+ _GETED(0);
+ #ifndef TEST_INTERPRETER
if(rex.w)
fpu_fxsave64(emu, ED);
else
fpu_fxsave32(emu, ED);
+ #endif
break;
case 1: /* FXRSTOR Ed */
+ _GETED(0);
if(rex.w)
fpu_fxrstor64(emu, ED);
else
fpu_fxrstor32(emu, ED);
break;
case 2: /* LDMXCSR Md */
+ GETED(0);
emu->mxcsr.x32 = ED->dword[0];
+ #ifndef TEST_INTERPRETER
if(box64_sse_flushto0)
applyFlushTo0(emu);
+ #endif
break;
case 3: /* STMXCSR Md */
+ GETED(0);
ED->dword[0] = emu->mxcsr.x32;
break;
case 7: /* CLFLUSH Ed */
- #ifdef DYNAREC
+ _GETED(0);
+ #if defined(DYNAREC) && !defined(TEST_INTERPRETER)
if(box64_dynarec)
cleanDBFromAddressRange((uintptr_t)ED, 8, 0);
#endif
@@ -975,7 +1053,15 @@ uintptr_t Run0F(x64emu_t *emu, rex_t rex, uintptr_t addr, int *step)
tmp64s >>= (rex.w?6:5);
if(!MODREG)
{
+ #ifdef TEST_INTERPRETER
+ test->memaddr=((test->memaddr)+(tmp64s<<(rex.w?3:2)));
+ if(rex.w)
+ *(uint64_t*)test->mem = *(uint64_t*)test->memaddr;
+ else
+ *(uint32_t*)test->mem = *(uint32_t*)test->memaddr;
+ #else
ED=(reg64_t*)(((uintptr_t)(ED))+(tmp64s<<(rex.w?3:2)));
+ #endif
}
if(rex.w) {
if(ED->q[0] & (1LL<<tmp8u)) {
@@ -1105,7 +1191,15 @@ uintptr_t Run0F(x64emu_t *emu, rex_t rex, uintptr_t addr, int *step)
tmp64s >>= (rex.w?6:5);
if(!MODREG)
{
+ #ifdef TEST_INTERPRETER
+ test->memaddr=((test->memaddr)+(tmp64s<<(rex.w?3:2)));
+ if(rex.w)
+ *(uint64_t*)test->mem = *(uint64_t*)test->memaddr;
+ else
+ *(uint32_t*)test->mem = *(uint32_t*)test->memaddr;
+ #else
ED=(reg64_t*)(((uintptr_t)(ED))+(tmp64s<<(rex.w?3:2)));
+ #endif
}
if(rex.w) {
if(ED->q[0] & (1LL<<tmp8u))
@@ -1289,6 +1383,10 @@ uintptr_t Run0F(x64emu_t *emu, rex_t rex, uintptr_t addr, int *step)
CHECK_FLAGS(emu);
nextop = F8;
GETED(0);
+ #ifdef TEST_INTERPRETER
+ test->memsize = 16;
+ ((uint64_t*)test->mem)[1] = ((uint64_t*)test->memaddr)[1];
+ #endif
switch((nextop>>3)&7) {
case 1:
if(rex.w) {
@@ -1366,7 +1464,12 @@ uintptr_t Run0F(x64emu_t *emu, rex_t rex, uintptr_t addr, int *step)
GETGM;
GM->q = (EM->q > 63) ? 0L : (GM->q >> EM->q);
break;
-
+ case 0xD4: /* PADDQ Gm,Em */
+ nextop = F8;
+ GETEM(0);
+ GETGM;
+ GM->sq += EM->sq;
+ break;
case 0xD5: /* PMULLW Gm,Em */
nextop = F8;
GETEM(0);
@@ -1506,7 +1609,7 @@ uintptr_t Run0F(x64emu_t *emu, rex_t rex, uintptr_t addr, int *step)
break;
case 0xE7: /* MOVNTQ Em,Gm */
nextop = F8;
- if((nextop&0xC0)==0xC0)
+ if(MODREG)
return 0;
GETEM(0);
GETGM;
@@ -1530,7 +1633,13 @@ uintptr_t Run0F(x64emu_t *emu, rex_t rex, uintptr_t addr, int *step)
GM->sw[i] = (tmp32s>32767)?32767:((tmp32s<-32768)?-32768:tmp32s);
}
break;
-
+ case 0xEA: /* PMINSW Gm,Em */
+ nextop = F8;
+ GETEM(0);
+ GETGM;
+ for (int i=0; i<4; ++i)
+ GM->sw[i] = (GM->sw[i]<EM->sw[i])?GM->sw[i]:EM->sw[i];
+ break;
case 0xEB: /* POR Gm, Em */
nextop = F8;
GETEM(0);
@@ -1555,7 +1664,13 @@ uintptr_t Run0F(x64emu_t *emu, rex_t rex, uintptr_t addr, int *step)
GM->sw[i] = (tmp32s>32767)?32767:((tmp32s<-32768)?-32768:tmp32s);
}
break;
-
+ case 0xEE: /* PMAXSW Gm,Em */
+ nextop = F8;
+ GETEM(0);
+ GETGM;
+ for (int i=0; i<4; ++i)
+ GM->sw[i] = (GM->sw[i]>EM->sw[i])?GM->sw[i]:EM->sw[i];
+ break;
case 0xEF: /* PXOR Gm, Em */
nextop = F8;
GETEM(0);
@@ -1593,7 +1708,12 @@ uintptr_t Run0F(x64emu_t *emu, rex_t rex, uintptr_t addr, int *step)
GETGM;
GM->q = (EM->q > 63) ? 0L : (GM->q << EM->ub[0]);
break;
-
+ case 0xF4: /* PMULUDQ Gm,Em */
+ nextop = F8;
+ GETEM(0);
+ GETGM;
+ GM->q = (uint64_t)GM->ud[0] * (uint64_t)EM->ud[0];
+ break;
case 0xF5: /* PMADDWD Gm, Em */
nextop = F8;
GETEM(0);
@@ -1636,7 +1756,12 @@ uintptr_t Run0F(x64emu_t *emu, rex_t rex, uintptr_t addr, int *step)
for(int i=0; i<2; ++i)
GM->ud[i] -= EM->ud[i];
break;
-
+ case 0xFB: /* PSUBQ Gm, Em */
+ nextop = F8;
+ GETEM(0);
+ GETGM;
+ GM->sq -= EM->sq;
+ break;
case 0xFC: /* PADDB Gm, Em */
nextop = F8;
GETEM(0);
@@ -1663,4 +1788,4 @@ uintptr_t Run0F(x64emu_t *emu, rex_t rex, uintptr_t addr, int *step)
return 0;
}
return addr;
-} \ No newline at end of file
+}
diff --git a/src/emu/x64run64.c b/src/emu/x64run64.c
index fa1ea28..587cc81 100644
--- a/src/emu/x64run64.c
+++ b/src/emu/x64run64.c
@@ -22,7 +22,11 @@
#include "modrm.h"
+#ifdef TEST_INTERPRETER
+uintptr_t Test64(x64test_t *test, rex_t rex, int seg, uintptr_t addr)
+#else
uintptr_t Run64(x64emu_t *emu, rex_t rex, int seg, uintptr_t addr)
+#endif
{
uint8_t opcode;
uint8_t nextop;
@@ -35,24 +39,29 @@ uintptr_t Run64(x64emu_t *emu, rex_t rex, int seg, uintptr_t addr)
reg64_t *oped, *opgd;
sse_regs_t *opex, *opgx;
int rep;
+ #ifdef TEST_INTERPRETER
+ x64emu_t* emu = test->emu;
+ #endif
uintptr_t tlsdata = GetSegmentBaseEmu(emu, seg);
opcode = F8;
// REX prefix before the F0 are ignored
rex.rex = 0;
- while(opcode>=0x40 && opcode<=0x4f) {
- rex.rex = opcode;
- opcode = F8;
- }
+ if(!rex.is32bits)
+ while(opcode>=0x40 && opcode<=0x4f) {
+ rex.rex = opcode;
+ opcode = F8;
+ }
rep = 0;
while((opcode==0xF2) || (opcode==0xF3)) {
rep = opcode-0xF1;
opcode = F8;
}
- while(opcode>=0x40 && opcode<=0x4f) {
- rex.rex = opcode;
- opcode = F8;
- }
+ if(!rex.is32bits)
+ while(opcode>=0x40 && opcode<=0x4f) {
+ rex.rex = opcode;
+ opcode = F8;
+ }
switch(opcode) {
#define GO(B, OP) \
@@ -114,6 +123,12 @@ uintptr_t Run64(x64emu_t *emu, rex_t rex, int seg, uintptr_t addr)
case 0x10:
switch(rep) {
+ case 0: /* MOVUPS Gx, FS:Ex */
+ nextop = F8;
+ GETEX_OFFS(0, tlsdata);
+ GETGX;
+ GX->u128 = EX->u128;
+ break;
case 1: /* MOVSD Gx, FS:Ex */
nextop = F8;
GETEX_OFFS(0, tlsdata);
@@ -162,7 +177,18 @@ uintptr_t Run64(x64emu_t *emu, rex_t rex, int seg, uintptr_t addr)
return 0;
}
break;
-
+ case 0x28:
+ switch(rep) {
+ case 0: /* MOVAPS Gx, FS:Ex */
+ nextop = F8;
+ GETEX_OFFS(0, tlsdata);
+ GETGX;
+ GX->u128 = EX->u128;
+ break;
+ default:
+ return 0;
+ }
+ break;
case 0x29: /* MOVAPS FS:Ex,Gx */
switch(rep) {
case 0:
@@ -283,17 +309,28 @@ uintptr_t Run64(x64emu_t *emu, rex_t rex, int seg, uintptr_t addr)
nextop = F8;
GETED_OFFS(0, tlsdata);
GETGD;
- if(rex.w)
- GD->sq[0] = ED->sdword[0];
- else
- if(MODREG)
- GD->q[0] = ED->dword[0]; // not really a sign extension
+ if(rex.is32bits) {
+ // ARPL here
+ // faking to always happy...
+ SET_FLAG(F_ZF);
+ } else {
+ if(rex.w)
+ GD->sq[0] = ED->sdword[0];
else
- GD->sdword[0] = ED->sdword[0]; // meh?
+ if(MODREG)
+ GD->q[0] = ED->dword[0]; // not really a sign extension
+ else
+ GD->sdword[0] = ED->sdword[0]; // meh?
+ }
break;
case 0x66:
return Run6664(emu, rex, seg, addr);
+ case 0x67:
+ if(rex.is32bits)
+ return Run6764_32(emu, rex, seg, seg, addr);
+ else
+ return 0;
case 0x80: /* GRP Eb,Ib */
nextop = F8;
@@ -371,7 +408,6 @@ uintptr_t Run64(x64emu_t *emu, rex_t rex, int seg, uintptr_t addr)
if(rex.w) {
ED->q[0] = GD->q[0];
} else {
- //if ED is a reg, than the opcode works like movzx
if(MODREG)
ED->q[0] = GD->dword[0];
else
@@ -394,6 +430,63 @@ uintptr_t Run64(x64emu_t *emu, rex_t rex, int seg, uintptr_t addr)
GD->q[0] = ED->dword[0];
break;
+ case 0x8D: /* LEA Gd,M */
+ nextop = F8;
+ GETGD;
+ tmp64u = GETEA(0);
+ if(rex.w)
+ GD->q[0] = tmp64u;
+ else
+ GD->q[0] = tmp64u&0xffffffff;
+ break;
+
+ case 0x8F: /* POP FS:Ed */
+ nextop = F8;
+ if(MODREG) {
+ emu->regs[(nextop&7)+(rex.b<<3)].q[0] = Pop64(emu);
+ } else {
+ if(rex.is32bits) {
+ tmp32u = Pop32(emu); // this order allows handling POP [ESP] and variant
+ GETED_OFFS(0, tlsdata);
+ R_ESP -= 4; // to prevent issue with SEGFAULT
+ ED->dword[0] = tmp32u;
+ R_ESP += 4;
+ } else {
+ tmp64u = Pop64(emu); // this order allows handling POP [ESP] and variant
+ GETED_OFFS(0, tlsdata);
+ R_RSP -= sizeof(void*); // to prevent issue with SEGFAULT
+ ED->q[0] = tmp64u;
+ R_RSP += sizeof(void*);
+ }
+ }
+ break;
+
+ case 0xA1: /* MOV EAX,FS:Od */
+ if(rex.is32bits) {
+ tmp32s = F32S;
+ R_EAX = *(uint32_t*)(tlsdata+tmp32s);
+ } else {
+ tmp64u = F64;
+ if(rex.w)
+ R_RAX = *(uint64_t*)(tlsdata+tmp64u);
+ else
+ R_RAX = *(uint32_t*)(tlsdata+tmp64u);
+ }
+ break;
+
+ case 0xA3: /* MOV FS:Od,EAX */
+ if(rex.is32bits) {
+ tmp32s = F32S;
+ *(uint32_t*)(uintptr_t)(tlsdata+tmp32s) = R_EAX;
+ } else {
+ tmp64u = F64;
+ if(rex.w)
+ *(uint64_t*)(tlsdata+tmp64u) = R_RAX;
+ else
+ *(uint32_t*)(tlsdata+tmp64u) = R_EAX;
+ }
+ break;
+
case 0xC6: /* MOV FS:Eb, Ib */
nextop = F8;
GETEB_OFFS(1, tlsdata);
@@ -549,42 +642,66 @@ uintptr_t Run64(x64emu_t *emu, rex_t rex, int seg, uintptr_t addr)
}
break;
case 2: /* CALL NEAR Ed */
- tmp64u = (uintptr_t)getAlternate((void*)ED->q[0]);
- Push(emu, addr);
+ if(rex.is32bits) {
+ tmp64u = (uintptr_t)getAlternate((void*)(uintptr_t)ED->dword[0]);
+ Push32(emu, addr);
+ } else {
+ tmp64u = (uintptr_t)getAlternate((void*)ED->q[0]);
+ Push64(emu, addr);
+ }
addr = tmp64u;
break;
case 3: /* CALL FAR Ed */
- if(nextop>0xC0) {
+ if(MODREG) {
printf_log(LOG_NONE, "Illegal Opcode %p: %02X %02X %02X %02X\n", (void*)R_RIP, opcode, nextop, PK(2), PK(3));
emu->quit=1;
emu->error |= ERR_ILLEGAL;
return 0;
} else {
- Push16(emu, R_CS);
- Push(emu, addr);
- R_RIP = addr = ED->dword[0];
- R_CS = (ED+1)->word[0];
+ if(rex.is32bits || !rex.w) {
+ Push32(emu, R_CS);
+ Push32(emu, addr);
+ R_RIP = addr = ED->dword[0];
+ R_CS = ED->word[2];
+ } else {
+ Push64(emu, R_CS);
+ Push64(emu, addr);
+ R_RIP = addr = ED->q[0];
+ R_CS = (ED+1)->word[0];
+ }
return 0; // exit loop to recompute new CS...
}
break;
case 4: /* JMP NEAR Ed */
- addr = (uintptr_t)getAlternate((void*)ED->q[0]);
+ if(rex.is32bits)
+ addr = (uintptr_t)getAlternate((void*)(uintptr_t)ED->dword[0]);
+ else
+ addr = (uintptr_t)getAlternate((void*)ED->q[0]);
break;
case 5: /* JMP FAR Ed */
- if(nextop>0xc0) {
+ if(MODREG) {
printf_log(LOG_NONE, "Illegal Opcode %p: 0x%02X 0x%02X %02X %02X\n", (void*)R_RIP, opcode, nextop, PK(2), PK(3));
emu->quit=1;
emu->error |= ERR_ILLEGAL;
return 0;
} else {
- R_RIP = addr = ED->q[0];
- R_CS = (ED+1)->word[0];
- return 0; // exit loop to recompute CS...
+ if(rex.is32bits || !rex.w) {
+ R_RIP = addr = ED->dword[0];
+ R_CS = ED->word[2];
+ } else {
+ R_RIP = addr = ED->q[0];
+ R_CS = (ED+1)->word[0];
+ }
}
break;
case 6: /* Push Ed */
- tmp64u = ED->q[0]; // rex.w ignored
- Push(emu, tmp64u); // avoid potential issue with push [esp+...]
+ if(rex.is32bits) {
+ tmp32u = ED->dword[0];
+ Push32(emu, tmp32u); // avoid potential issue with push [esp+...]
+ } else {
+ tmp64u = ED->q[0]; // rex.w ignored
+ Push64(emu, tmp64u); // avoid potential issue with push [esp+...]
+ }
break;
default:
printf_log(LOG_NONE, "Illegal Opcode %p: %02X %02X %02X %02X %02X %02X\n",(void*)R_RIP, opcode, nextop, PK(2), PK(3), PK(4), PK(5));
diff --git a/src/emu/x64run66.c b/src/emu/x64run66.c
index f7696ee..938fde4 100644
--- a/src/emu/x64run66.c
+++ b/src/emu/x64run66.c
@@ -25,7 +25,11 @@
#include "modrm.h"
+#ifdef TEST_INTERPRETER
+uintptr_t Test66(x64test_t *test, rex_t rex, int rep, uintptr_t addr)
+#else
uintptr_t Run66(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr)
+#endif
{
uint8_t opcode;
uint8_t nextop;
@@ -37,6 +41,9 @@ uintptr_t Run66(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr)
int64_t tmp64s;
uint64_t tmp64u, tmp64u2, tmp64u3;
reg64_t *oped, *opgd;
+ #ifdef TEST_INTERPRETER
+ x64emu_t* emu = test->emu;
+ #endif
opcode = F8;
@@ -49,10 +56,11 @@ uintptr_t Run66(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr)
}
rex.rex = 0;
- while(opcode>=0x40 && opcode<=0x4f) {
- rex.rex = opcode;
- opcode = F8;
- }
+ if(!rex.is32bits)
+ while(opcode>=0x40 && opcode<=0x4f) {
+ rex.rex = opcode;
+ opcode = F8;
+ }
switch(opcode) {
#define GO(B, OP) \
@@ -84,7 +92,7 @@ uintptr_t Run66(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr)
if(rex.w) \
GW->q[0] = OP##64(emu, GW->q[0], EW->q[0]); \
else \
- GW->word[0] = OP##16(emu, GW->word[0], EW->word[0]); \
+ GW->word[0] = OP##16(emu, GW->word[0], EW->word[0]); \
break; \
case B+4: \
R_AL = OP##8(emu, R_AL, F8); \
@@ -105,7 +113,11 @@ uintptr_t Run66(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr)
GO(0x30, xor) /* XOR 0x31 ~> 0x35 */
case 0x0F: /* more opcdes */
+ #ifdef TEST_INTERPRETER
+ return Test660F(test, rex, addr);
+ #else
return Run660F(emu, rex, addr);
+ #endif
case 0x39:
nextop = F8;
@@ -132,10 +144,97 @@ uintptr_t Run66(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr)
cmp16(emu, R_AX, F16);
break;
+ case 0x40:
+ case 0x41:
+ case 0x42:
+ case 0x43:
+ case 0x44:
+ case 0x45:
+ case 0x46:
+ case 0x47: /* INC Reg (32bits only) */
+ tmp8u = opcode&7;
+ emu->regs[tmp8u].word[0] = inc16(emu, emu->regs[tmp8u].word[0]);
+ break;
+ case 0x48:
+ case 0x49:
+ case 0x4A:
+ case 0x4B:
+ case 0x4C:
+ case 0x4D:
+ case 0x4E:
+ case 0x4F: /* DEC Reg (32bits only) */
+ tmp8u = opcode&7;
+ emu->regs[tmp8u].word[0] = dec16(emu, emu->regs[tmp8u].word[0]);
+ break;
+ case 0x50:
+ case 0x51:
+ case 0x52:
+ case 0x53:
+ case 0x55:
+ case 0x56:
+ case 0x57: /* PUSH Reg */
+ if(rex.is32bits) {
+ tmp8u = opcode&7;
+ Push16(emu, emu->regs[tmp8u].word[0]);
+ } else
+ return 0;
+ break;
+ case 0x58:
+ case 0x59:
+ case 0x5A:
+ case 0x5B:
+ case 0x5C: /* POP ESP */
+ case 0x5D:
+ case 0x5E:
+ case 0x5F: /* POP Reg */
+ if(rex.is32bits) {
+ tmp8u = opcode&7;
+ emu->regs[tmp8u].word[0] = Pop16(emu);
+ } else
+ return 0;
+ break;
+ case 0x60: /* PUSHA */
+ if(rex.is32bits) {
+ tmp16u = R_SP;
+ Push16(emu, R_AX);
+ Push16(emu, R_CX);
+ Push16(emu, R_DX);
+ Push16(emu, R_BX);
+ Push16(emu, tmp16u);
+ Push16(emu, R_BP);
+ Push16(emu, R_SI);
+ Push16(emu, R_DI);
+ } else {
+ return 0;
+ }
+ break;
+ case 0x61: /* POPA */
+ if(rex.is32bits) {
+ R_DI = Pop16(emu);
+ R_SI = Pop16(emu);
+ R_BP = Pop16(emu);
+ R_ESP+=2; // POP ESP
+ R_BX = Pop16(emu);
+ R_DX = Pop16(emu);
+ R_CX = Pop16(emu);
+ R_AX = Pop16(emu);
+ } else {
+ return 0;
+ }
+ break;
+
case 0x64: /* FS: */
+ #ifdef TEST_INTERPRETER
+ return Test6664(test, rex, _FS, addr);
+ #else
return Run6664(emu, rex, _FS, addr);
+ #endif
case 0x65: /* GS: */
+ #ifdef TEST_INTERPRETER
+ return Test6664(test, rex, _GS, addr);
+ #else
return Run6664(emu, rex, _GS, addr);
+ #endif
case 0x69: /* IMUL Gw,Ew,Iw */
nextop = F8;
@@ -257,35 +356,34 @@ uintptr_t Run66(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr)
break;
case 0x8D: /* LEA Gw,M */
nextop = F8;
- GETED(0);
GETGD;
+ tmp64u = GETEA(0);
if(rex.w)
- GD->q[0] = (uint64_t)ED;
+ GD->q[0] = tmp64u;
else
- GD->word[0] = (uint16_t)(uintptr_t)ED;
- break;
-
- case 0x90: /* NOP or XCHG R8d, AX*/
- case 0x91:
- case 0x92:
- case 0x93:
- case 0x94:
- case 0x95:
- case 0x96:
- case 0x97: /* XCHG reg,AX */
- tmp8u = _AX+(opcode&7)+(rex.b<<3);
- if(tmp8u!=_AX) {
- if(rex.w) {
- tmp64u = R_RAX;
- R_RAX = emu->regs[tmp8u].q[0];
- emu->regs[tmp8u].q[0] = tmp64u;
- } else {
- tmp16u = R_AX;
- R_AX = emu->regs[tmp8u].word[0];
- emu->regs[tmp8u].word[0] = tmp16u;
- }
+ GD->word[0] = (uint16_t)tmp64u;
+ break;
+
+ case 0x90: /* NOP or XCHG R8d, AX*/
+ case 0x91:
+ case 0x92:
+ case 0x93:
+ case 0x94:
+ case 0x95:
+ case 0x96:
+ case 0x97: /* XCHG reg,AX */
+ tmp8u = _AX+(opcode&7)+(rex.b<<3);
+ if(tmp8u!=_AX) {
+ if(rex.w) {
+ tmp64u = R_RAX;
+ R_RAX = emu->regs[tmp8u].q[0];
+ emu->regs[tmp8u].q[0] = tmp64u;
+ } else {
+ tmp16u = R_AX;
+ R_AX = emu->regs[tmp8u].word[0];
+ emu->regs[tmp8u].word[0] = tmp16u;
}
- break;
+ }
break;
case 0x98: /* CBW */
@@ -295,18 +393,36 @@ uintptr_t Run66(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr)
R_DX=((R_AX & 0x8000)?0xFFFF:0x0000);
break;
+ case 0x9C: /* PUSHFW */
+ CHECK_FLAGS(emu);
+ Push16(emu, (uint16_t)emu->eflags.x64);
+ break;
+ case 0x9D: /* POPFW */
+ CHECK_FLAGS(emu);
+ emu->eflags.x64 &=0xffff0000;
+ emu->eflags.x64 |= (Pop16(emu) & 0x3F7FD7) | 0x2;
+ break;
+
case 0xA1: /* MOV EAX,Od */
- if(rex.w)
- R_RAX = *(uint64_t*)F64;
- else
- R_AX = *(uint16_t*)F64;
+ if(rex.is32bits) {
+ R_AX = *(uint16_t*)(uintptr_t)F32;
+ } else {
+ if(rex.w)
+ R_RAX = *(uint64_t*)F64;
+ else
+ R_AX = *(uint16_t*)F64;
+ }
break;
case 0xA3: /* MOV Od,EAX */
- if(rex.w)
- *(uint64_t*)F64 = R_RAX;
- else
- *(uint16_t*)F64 = R_AX;
+ if(rex.is32bits) {
+ *(uint16_t*)(uintptr_t)F32 = R_AX;
+ } else {
+ if(rex.w)
+ *(uint64_t*)F64 = R_RAX;
+ else
+ *(uint16_t*)F64 = R_AX;
+ }
break;
case 0xA5: /* (REP) MOVSW */
@@ -395,14 +511,12 @@ uintptr_t Run66(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr)
break;
default:
if(rex.w) {
- tmp8s = ACCESS_FLAG(F_DF)?-8:+8;
tmp64u = *(uint64_t*)R_RDI;
tmp64u2 = *(uint64_t*)R_RSI;
R_RDI += tmp8s;
R_RSI += tmp8s;
cmp64(emu, tmp64u2, tmp64u);
} else {
- tmp8s = ACCESS_FLAG(F_DF)?-2:+2;
tmp16u = *(uint16_t*)R_RDI;
tmp16u2 = *(uint16_t*)R_RSI;
R_RDI += tmp8s;
@@ -427,13 +541,17 @@ uintptr_t Run66(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr)
tmp64u = (rep)?R_RCX:1L;
if((rex.w))
while(tmp64u) {
+ #ifndef TEST_INTERPRETER
*(uint64_t*)R_RDI = R_RAX;
+ #endif
R_RDI += tmp8s;
--tmp64u;
}
else
while(tmp64u) {
+ #ifndef TEST_INTERPRETER
*(uint16_t*)R_RDI = R_AX;
+ #endif
R_RDI += tmp8s;
--tmp64u;
}
@@ -462,7 +580,7 @@ uintptr_t Run66(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr)
R_RCX = tmp64u;
break;
- case 0xAF: /* (REPZ/REPNE) SCASD */
+ case 0xAF: /* (REPZ/REPNE) SCASW */
if(rex.w)
tmp8s = ACCESS_FLAG(F_DF)?-8:+8;
else
@@ -609,19 +727,34 @@ uintptr_t Run66(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr)
break;
case 0xD9: /* x87 opcdes */
+ #ifdef TEST_INTERPRETER
+ return Test66D9(test, rex, addr);
+ #else
return Run66D9(emu, rex, addr);
+ #endif
case 0xDD: /* x87 opcdes */
+ #ifdef TEST_INTERPRETER
+ return Test66DD(test, rex, addr);
+ #else
return Run66DD(emu, rex, addr);
+ #endif
case 0xE8: /* CALL Id */
tmp32s = F32S; // call is relative
- Push(emu, addr);
+ if(rex.is32bits)
+ Push32(emu, addr);
+ else
+ Push64(emu, addr);
addr += tmp32s;
break;
case 0xF0: /* LOCK: */
+ #ifdef TEST_INTERPRETER
+ return Test66F0(test, rex, addr);
+ #else
return Run66F0(emu, rex, addr);
+ #endif
case 0xF7: /* GRP3 Ew(,Iw) */
nextop = F8;
@@ -691,7 +824,6 @@ uintptr_t Run66(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr)
case 0xFF: /* GRP 5 Ew */
nextop = F8;
GETEW(0);
- GETGW;
switch((nextop>>3)&7) {
case 0: /* INC Ed */
EW->word[0] = inc16(emu, EW->word[0]);
@@ -700,13 +832,21 @@ uintptr_t Run66(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr)
EW->word[0] = dec16(emu, EW->word[0]);
break;
case 2: /* CALL NEAR Ed */
- tmp64u = (uintptr_t)getAlternate((void*)ED->q[0]);
- Push(emu, addr);
+ if(rex.is32bits) {
+ tmp64u = (uintptr_t)getAlternate((void*)(uintptr_t)ED->dword[0]);
+ Push32(emu, addr);
+ } else {
+ tmp64u = (uintptr_t)getAlternate((void*)ED->q[0]);
+ Push64(emu, addr);
+ }
addr = tmp64u;
break;
- /*case 6:
- Push16(emu, EW->word[0]);
- break;*/
+ case 6: /* Push Ew */
+ if(rex.is32bits) {
+ Push16(emu, EW->word[0]);
+ } else
+ return 0;
+ break;
default:
printf_log(LOG_NONE, "Illegal Opcode %p: 66 %02X %02X %02X %02X %02X %02X\n",(void*)R_RIP, opcode, nextop, PK(2), PK(3), PK(4), PK(5));
emu->quit=1;
diff --git a/src/emu/x64run660f.c b/src/emu/x64run660f.c
index 5744099..902772e 100644
--- a/src/emu/x64run660f.c
+++ b/src/emu/x64run660f.c
@@ -43,7 +43,11 @@ static uint8_t ff_mult(uint8_t a, uint8_t b)
return retval;
}
+#ifdef TEST_INTERPRETER
+uintptr_t Test660F(x64test_t *test, rex_t rex, uintptr_t addr)
+#else
uintptr_t Run660F(x64emu_t *emu, rex_t rex, uintptr_t addr)
+#endif
{
uint8_t opcode;
uint8_t nextop;
@@ -54,8 +58,9 @@ uintptr_t Run660F(x64emu_t *emu, rex_t rex, uintptr_t addr)
int32_t tmp32s;
uint32_t tmp32u;
uint64_t tmp64u;
- int64_t tmp64s;
+ int64_t tmp64s, i64[4];
float tmpf;
+ double tmpd;
#ifndef NOALIGN
int is_nan;
#endif
@@ -106,6 +111,9 @@ uintptr_t Run660F(x64emu_t *emu, rex_t rex, uintptr_t addr)
0x17, 0x2b, 0x04, 0x7e, 0xba, 0x77, 0xd6, 0x26, 0xe1, 0x69, 0x14, 0x63, 0x55, 0x21, 0x0c, 0x7d,
};
+ #ifdef TEST_INTERPRETER
+ x64emu_t* emu = test->emu;
+ #endif
opcode = F8;
switch(opcode) {
@@ -124,13 +132,13 @@ uintptr_t Run660F(x64emu_t *emu, rex_t rex, uintptr_t addr)
break;
case 0x12: /* MOVLPD Gx, Eq */
nextop = F8;
- GETED(0);
+ GETE8(0);
GETGX;
GX->q[0] = ED->q[0];
break;
case 0x13: /* MOVLPD Eq, Gx */
nextop = F8;
- GETED(0);
+ GETE8(0);
GETGX;
ED->q[0] = GX->q[0];
break;
@@ -149,20 +157,20 @@ uintptr_t Run660F(x64emu_t *emu, rex_t rex, uintptr_t addr)
break;
case 0x16: /* MOVHPD Gx, Ed */
nextop = F8;
- GETED(0);
+ GETE8(0);
GETGX;
GX->q[1] = ED->q[0];
break;
case 0x17: /* MOVHPD Ed, Gx */
nextop = F8;
- GETED(0);
+ GETE8(0);
GETGX;
ED->q[0] = GX->q[1];
break;
case 0x1F: /* NOP (multi-byte) */
nextop = F8;
- GETED(0);
+ FAKEED(0);
break;
case 0x28: /* MOVAPD Gx, Ex */
@@ -186,13 +194,27 @@ uintptr_t Run660F(x64emu_t *emu, rex_t rex, uintptr_t addr)
GX->d[0] = EM->sd[0];
GX->d[1] = EM->sd[1];
break;
-
+ case 0x2B: /* MOVNTPD Ex, Gx */
+ nextop = F8;
+ GETEX(0);
+ GETGX;
+ EX->q[0] = GX->q[0];
+ EX->q[1] = GX->q[1];
+ break;
case 0x2C: /* CVTTPD2PI Gm, Ex */
nextop = F8;
GETEX(0);
GETGM;
- GM->sd[0] = EX->d[0];
- GM->sd[1] = EX->d[1];
+ tmp64s = EX->d[0];
+ if (tmp64s==(int32_t)tmp64s && !isnan(EX->d[0]))
+ GX->sd[0] = (int32_t)tmp64s;
+ else
+ GX->sd[0] = INT32_MIN;
+ tmp64s = EX->d[1];
+ if (tmp64s==(int32_t)tmp64s && !isnan(EX->d[1]))
+ GX->sd[1] = (int32_t)tmp64s;
+ else
+ GX->sd[1] = INT32_MIN;
break;
case 0x2D: /* CVTPD2PI Gm, Ex */
nextop = F8;
@@ -200,22 +222,28 @@ uintptr_t Run660F(x64emu_t *emu, rex_t rex, uintptr_t addr)
GETGM;
switch(emu->mxcsr.f.MXCSR_RC) {
case ROUND_Nearest:
- GM->sd[0] = nearbyint(EX->d[0]);
- GM->sd[1] = nearbyint(EX->d[1]);
+ i64[0] = nearbyint(EX->d[0]);
+ i64[1] = nearbyint(EX->d[1]);
break;
case ROUND_Down:
- GM->sd[0] = floor(EX->d[0]);
- GM->sd[1] = floor(EX->d[1]);
+ i64[0] = floor(EX->d[0]);
+ i64[1] = floor(EX->d[1]);
break;
case ROUND_Up:
- GM->sd[0] = ceil(EX->d[0]);
- GM->sd[1] = ceil(EX->d[1]);
+ i64[0] = ceil(EX->d[0]);
+ i64[1] = ceil(EX->d[1]);
break;
case ROUND_Chop:
- GM->sd[0] = EX->d[0];
- GM->sd[1] = EX->d[1];
+ i64[0] = EX->d[0];
+ i64[1] = EX->d[1];
break;
}
+ for(int i=0; i<2; ++i)
+ if (i64[i]==(int32_t)i64[i] && !isnan(EX->d[i]))
+ GM->sd[i] = (int32_t)i64[i];
+ else
+ GM->sd[i] = INT32_MIN;
+
break;
case 0x2E: /* UCOMISD Gx, Ex */
// no special check...
@@ -316,7 +344,36 @@ uintptr_t Run660F(x64emu_t *emu, rex_t rex, uintptr_t addr)
GX->sw[4+i] = EX->sw[i*2+0] - EX->sw[i*2+1];
}
break;
-
+ case 0x06: /* PHSUBD Gx, Ex */
+ nextop = F8;
+ GETEX(0);
+ GETGX;
+ for (int i=0; i<2; ++i)
+ GX->sd[i] = GX->sd[i*2+0] - GX->sd[i*2+1];
+ if(GX == EX) {
+ GX->q[1] = GX->q[0];
+ } else {
+ for (int i=0; i<2; ++i)
+ GX->sd[2+i] = EX->sd[i*2+0] - EX->sd[i*2+1];
+ }
+ break;
+ case 0x07: /* PHSUBSW Gx, Ex */
+ nextop = F8;
+ GETEX(0);
+ GETGX;
+ for (int i=0; i<4; ++i) {
+ tmp32s = GX->sw[i*2+0] - GX->sw[i*2+1];
+ GX->sw[i] = (tmp32s<-32768)?-32768:((tmp32s>32767)?32767:tmp32s);
+ }
+ if(GX == EX) {
+ GX->q[1] = GX->q[0];
+ } else {
+ for (int i=0; i<4; ++i) {
+ tmp32s = EX->sw[i*2+0] - EX->sw[i*2+1];
+ GX->sw[4+i] = (tmp32s<-32768)?-32768:((tmp32s>32767)?32767:tmp32s);
+ }
+ }
+ break;
case 0x08: /* PSIGNB Gx, Ex */
nextop = F8;
GETEX(0);
@@ -367,14 +424,27 @@ uintptr_t Run660F(x64emu_t *emu, rex_t rex, uintptr_t addr)
GX->ud[i] = EX->ud[i];
}
break;
+ case 0x15: /* BLENDVPD Gx, Ex */
+ nextop = F8;
+ GETEX(0);
+ GETGX;
+ for (int i=0; i<2; ++i) {
+ if(emu->xmm[0].q[i]&0x8000000000000000LL)
+ GX->q[i] = EX->q[i];
+ }
+ break;
case 0x17: // PTEST GX, EX
nextop = F8;
GETEX(0);
GETGX;
- CHECK_FLAGS(emu);
+ RESET_FLAGS(emu);
CONDITIONAL_SET_FLAG(!(GX->u128&EX->u128), F_ZF);
CONDITIONAL_SET_FLAG(!((~GX->u128)&EX->u128), F_CF);
+ CLEAR_FLAG(F_AF);
+ CLEAR_FLAG(F_OF);
+ CLEAR_FLAG(F_SF);
+ CLEAR_FLAG(F_PF);
break;
case 0x1C: /* PABSB Gx, Ex */
@@ -445,6 +515,40 @@ uintptr_t Run660F(x64emu_t *emu, rex_t rex, uintptr_t addr)
GX->sq[i] = EX->sd[i];
break;
+ case 0x28: /* PMULDQ Gx, Ex */
+ nextop = F8;
+ GETEX(0);
+ GETGX;
+ GX->sq[1] = ((int64_t)GX->sd[2])*(int64_t)EX->sd[2];
+ GX->sq[0] = ((int64_t)GX->sd[0])*(int64_t)EX->sd[0];
+ break;
+ case 0x29: /* PCMPEQQ Gx, Ex */
+ nextop = F8;
+ GETEX(0);
+ GETGX;
+ for(int i=1; i>=0; --i)
+ GX->sq[i] = (GX->sq[i]==EX->sq[i])?-1LL:0LL;
+ break;
+ case 0x2A: /* MOVNTDQA Gx, Ex */
+ nextop = F8;
+ GETEX(0);
+ GETGX;
+ GX->q[0] = EX->q[0];
+ GX->q[1] = EX->q[1];
+ break;
+ case 0x2B: /* PACKUSDW Gx, Ex */
+ nextop = F8;
+ GETEX(0);
+ GETGX;
+ for(int i=0; i<4; ++i)
+ GX->uw[i] = (GX->sd[i]<0)?0:((GX->sd[i]>65535)?65535:GX->sd[i]);
+ if(GX==EX)
+ GX->q[1] = GX->q[0];
+ else
+ for(int i=0; i<4; ++i)
+ GX->uw[i+4] = (EX->sd[i]<0)?0:((EX->sd[i]>65535)?65535:EX->sd[i]);
+ break;
+
case 0x30: /* PMOVZXBW Gx, Ex */
nextop = F8;
GETEX(0);
@@ -487,7 +591,13 @@ uintptr_t Run660F(x64emu_t *emu, rex_t rex, uintptr_t addr)
for(int i=1; i>=0; --i)
GX->q[i] = EX->ud[i];
break;
-
+ case 0x37: /* PCMPGTQ Gx, Ex */
+ nextop = F8;
+ GETEX(0);
+ GETGX;
+ for(int i=1; i>=0; --i)
+ GX->sq[i] = (GX->sq[i]>EX->sq[i])?-1LL:0LL;
+ break;
case 0x38: /* PMINSB Gx, Ex */
nextop = F8;
GETEX(0);
@@ -552,6 +662,30 @@ uintptr_t Run660F(x64emu_t *emu, rex_t rex, uintptr_t addr)
if(GX->ud[i]<EX->ud[i])
GX->ud[i] = EX->ud[i];
break;
+ case 0x40: /* PMULLD Gx, Ex */
+ nextop = F8;
+ GETEX(0);
+ GETGX;
+ for(int i=0; i<4; ++i)
+ GX->ud[i] *= EX->ud[i];
+ break;
+ case 0x41: /* PHMINPOSUW Gx, Ex */
+ nextop = F8;
+ GETEX(0);
+ GETGX;
+ tmp16u = EX->uw[0];
+ tmp16s = 0;
+ for(int i=1; i<8; ++i) {
+ if(EX->uw[i]<tmp16u) {
+ tmp16u = EX->uw[i];
+ tmp16s = i;
+ }
+ }
+ GX->q[1] = 0;
+ GX->uw[0] = tmp16u;
+ GX->uw[1] = tmp16s;
+ GX->ud[1] = 0;
+ break;
case 0xDB: /* AESIMC Gx, Ex */
nextop = F8;
@@ -654,7 +788,18 @@ uintptr_t Run660F(x64emu_t *emu, rex_t rex, uintptr_t addr)
GX->q[0] ^= EX->q[0];
GX->q[1] ^= EX->q[1];
break;
-
+ case 0xF0: /* MOVBE Gw, Ew */
+ nextop = F8;
+ GETEX(0);
+ GETGX;
+ GX->uw[0] = __builtin_bswap16(EX->uw[0]);
+ break;
+ case 0xF1: /* MOVBE Ew, Gw */
+ nextop = F8;
+ GETEX(0);
+ GETGX;
+ EX->uw[0] = __builtin_bswap16(GX->uw[0]);
+ break;
default:
return 0;
}
@@ -663,6 +808,62 @@ uintptr_t Run660F(x64emu_t *emu, rex_t rex, uintptr_t addr)
case 0x3A: // these are some SSE3 & SSE4.x opcodes
opcode = F8;
switch(opcode) {
+ case 0x08: // ROUNDPS Gx, Ex, u8
+ nextop = F8;
+ GETEX(1);
+ GETGX;
+ tmp8u = F8; // ignoring bit 3 interupt thingy
+ if(tmp8u&4)
+ tmp8u = emu->mxcsr.f.MXCSR_RC;
+ else
+ tmp8u &= 3;
+ switch(tmp8u) {
+ case ROUND_Nearest:
+ for(int i=0; i<4; ++i)
+ GX->f[i] = nearbyintf(EX->f[i]);
+ break;
+ case ROUND_Down:
+ for(int i=0; i<4; ++i)
+ GX->f[i] = floorf(EX->f[i]);
+ break;
+ case ROUND_Up:
+ for(int i=0; i<4; ++i)
+ GX->f[i] = ceilf(EX->f[i]);
+ break;
+ case ROUND_Chop:
+ for(int i=0; i<4; ++i)
+ GX->f[i] = truncf(EX->f[i]);
+ break;
+ }
+ break;
+ case 0x09: // ROUNDPD Gx, Ex, u8
+ nextop = F8;
+ GETEX(1);
+ GETGX;
+ tmp8u = F8; // ignoring bit 3 interupt thingy
+ if(tmp8u&4)
+ tmp8u = emu->mxcsr.f.MXCSR_RC;
+ else
+ tmp8u &= 3;
+ switch(tmp8u) {
+ case ROUND_Nearest:
+ GX->d[0] = nearbyint(EX->d[0]);
+ GX->d[1] = nearbyint(EX->d[1]);
+ break;
+ case ROUND_Down:
+ GX->d[0] = floor(EX->d[0]);
+ GX->d[1] = floor(EX->d[1]);
+ break;
+ case ROUND_Up:
+ GX->d[0] = ceil(EX->d[0]);
+ GX->d[1] = ceil(EX->d[1]);
+ break;
+ case ROUND_Chop:
+ GX->d[0] = trunc(EX->d[0]);
+ GX->d[1] = trunc(EX->d[1]);
+ break;
+ }
+ break;
case 0x0A: // ROUNDSS Gx, Ex, u8
nextop = F8;
GETEX(1);
@@ -683,7 +884,7 @@ uintptr_t Run660F(x64emu_t *emu, rex_t rex, uintptr_t addr)
GX->f[0] = ceilf(EX->f[0]);
break;
case ROUND_Chop:
- GX->f[0] = EX->f[0];
+ GX->f[0] = truncf(EX->f[0]);
break;
}
break;
@@ -707,11 +908,22 @@ uintptr_t Run660F(x64emu_t *emu, rex_t rex, uintptr_t addr)
GX->d[0] = ceil(EX->d[0]);
break;
case ROUND_Chop:
- GX->d[0] = EX->d[0];
+ GX->d[0] = trunc(EX->d[0]);
break;
}
break;
+ case 0x0C: /* PBLENDPS Gx, Ex, Ib */
+ nextop = F8;
+ GETEX(1);
+ GETGX;
+ tmp8u = F8;
+ for (int i=0; i<4; ++i) {
+ if(tmp8u&(1<<i))
+ GX->ud[i] = EX->ud[i];
+ }
+ break;
+
case 0x0E: /* PBLENDW Gx, Ex, Ib */
nextop = F8;
GETEX(1);
@@ -738,14 +950,26 @@ uintptr_t Run660F(x64emu_t *emu, rex_t rex, uintptr_t addr)
}
break;
- case 0x14: // PEXTRB EB, GX, u8
+ case 0x14: // PEXTRB ED, GX, u8
nextop = F8;
- GETEB(1);
+ GETED(1);
GETGX;
tmp8u = F8;
- EB->byte[0] = GX->ub[tmp8u&0x0f];
+ if(MODREG)
+ ED->q[0] = GX->ub[tmp8u&0x0f];
+ else
+ ED->byte[0] = GX->ub[tmp8u&0x0f];
+ break;
+ case 0x15: // PEXTRW Ew,Gx,Ib
+ nextop = F8;
+ GETED(1);
+ GETGX;
+ tmp8u = F8;
+ if(MODREG)
+ ED->q[0] = GX->uw[tmp8u&7]; // 16bits extract, 0 extended
+ else
+ ED->word[0] = GX->uw[tmp8u&7];
break;
-
case 0x16: // PEXTRD/Q ED, GX, u8
nextop = F8;
GETED(1);
@@ -754,7 +978,10 @@ uintptr_t Run660F(x64emu_t *emu, rex_t rex, uintptr_t addr)
if(rex.w) {
ED->q[0] = GX->q[tmp8u&1];
} else {
- ED->q[0] = GX->ud[tmp8u&3];
+ if(MODREG)
+ ED->q[0] = GX->ud[tmp8u&3];
+ else
+ ED->dword[0] = GX->ud[tmp8u&3];
}
break;
case 0x17: // EXTRACTPS ED, GX, u8
@@ -807,6 +1034,40 @@ uintptr_t Run660F(x64emu_t *emu, rex_t rex, uintptr_t addr)
for(int i=0; i<4; ++i)
GX->f[i] = (tmp8u&(1<<i))?tmpf:0.0f;
break;
+ case 0x41: /* DPPD Gx, Ex, Ib */
+ nextop = F8;
+ GETEX(1);
+ GETGX;
+ tmp8u = F8;
+ tmpd = 0.0;
+ if(tmp8u&(1<<(4+0)))
+ tmpd += GX->d[0]*EX->d[0];
+ if(tmp8u&(1<<(4+1)))
+ tmpd += GX->d[1]*EX->d[1];
+ GX->d[0] = (tmp8u&(1<<(0)))?tmpd:0.0;
+ GX->d[1] = (tmp8u&(1<<(1)))?tmpd:0.0;
+ break;
+
+ case 0x42: /* MPSADBW Gx, Ex, Ib */
+ nextop = F8;
+ GETEX(1);
+ GETGX;
+ tmp8u = F8;
+ {
+ int src = tmp8u&3;
+ int dst = (tmp8u>>2)&1;
+ int b[11];
+ for (int i=0; i<11; ++i)
+ b[i] = GX->ub[dst*4+i];
+ for(int i=0; i<8; ++i) {
+ int tmp = abs(b[i+0]-EX->ub[src*4+0]);
+ tmp += abs(b[i+1]-EX->ub[src*4+1]);
+ tmp += abs(b[i+2]-EX->ub[src*4+2]);
+ tmp += abs(b[i+3]-EX->ub[src*4+3]);
+ GX->uw[i] = tmp;
+ }
+ }
+ break;
case 0x44: /* PCLMULQDQ Gx, Ex, Ib */
nextop = F8;
@@ -952,24 +1213,30 @@ uintptr_t Run660F(x64emu_t *emu, rex_t rex, uintptr_t addr)
nextop = F8;
GETEX(0);
GETGX;
- for(int i=0; i<4; ++i)
- if(isnanf(EX->f[i]) || isinff(EX->f[i]) || EX->f[i]>0x7fffffff || EX->f[i]<-0x80000000)
- GX->sd[i] = 0x80000000;
+ for(int i=0; i<4; ++i) {
+ if(isnanf(EX->f[i]))
+ tmp64s = INT32_MIN;
else
switch(emu->mxcsr.f.MXCSR_RC) {
case ROUND_Nearest:
- GX->sd[i] = nearbyintf(EX->f[i]);
+ tmp64s = nearbyintf(EX->f[i]);
break;
case ROUND_Down:
- GX->sd[i] = floorf(EX->f[i]);
+ tmp64s = floorf(EX->f[i]);
break;
case ROUND_Up:
- GX->sd[i] = ceilf(EX->f[i]);
+ tmp64s = ceilf(EX->f[i]);
break;
case ROUND_Chop:
- GX->sd[i] = EX->f[i];
+ tmp64s = EX->f[i];
break;
}
+ if (tmp64s==(int32_t)tmp64s) {
+ GX->sd[i] = (int32_t)tmp64s;
+ } else {
+ GX->sd[i] = INT32_MIN;
+ }
+ }
break;
case 0x5C: /* SUBPD Gx, Ex */
nextop = F8;
@@ -1263,7 +1530,7 @@ uintptr_t Run660F(x64emu_t *emu, rex_t rex, uintptr_t addr)
tmp8u = F8;
if(tmp8u>15)
{EX->q[0] = EX->q[1] = 0;}
- else {
+ else if (tmp8u!=0) {
tmp8u*=8;
if (tmp8u < 64) {
EX->q[0] = (EX->q[0] >> tmp8u) | (EX->q[1] << (64 - tmp8u));
@@ -1285,7 +1552,7 @@ uintptr_t Run660F(x64emu_t *emu, rex_t rex, uintptr_t addr)
tmp8u = F8;
if(tmp8u>15)
{EX->q[0] = EX->q[1] = 0;}
- else {
+ else if (tmp8u!=0) {
tmp8u*=8;
if (tmp8u < 64) {
EX->q[1] = (EX->q[1] << tmp8u) | (EX->q[0] >> (64 - tmp8u));
@@ -1516,7 +1783,15 @@ uintptr_t Run660F(x64emu_t *emu, rex_t rex, uintptr_t addr)
tmp32s >>= (rex.w?6:4);
if(!MODREG)
{
+ #ifdef TEST_INTERPRETER
+ test->memaddr=((test->memaddr)+(tmp32s<<(rex.w?3:1)));
+ if(rex.w)
+ *(uint64_t*)test->mem = *(uint64_t*)test->memaddr;
+ else
+ *(uint16_t*)test->mem = *(uint16_t*)test->memaddr;
+ #else
EW=(reg64_t*)(((uintptr_t)(EW))+(tmp32s<<(rex.w?3:1)));
+ #endif
}
if(rex.w) {
if(EW->q[0] & (1LL<<tmp8u)) {
@@ -2198,4 +2473,4 @@ uintptr_t Run660F(x64emu_t *emu, rex_t rex, uintptr_t addr)
return 0;
}
return addr;
-} \ No newline at end of file
+}
diff --git a/src/emu/x64run6664.c b/src/emu/x64run6664.c
index 9753dfc..48a3be9 100644
--- a/src/emu/x64run6664.c
+++ b/src/emu/x64run6664.c
@@ -22,21 +22,29 @@
#include "modrm.h"
+#ifdef TEST_INTERPRETER
+uintptr_t Test6664(x64test_t *test, rex_t rex, int seg, uintptr_t addr)
+#else
uintptr_t Run6664(x64emu_t *emu, rex_t rex, int seg, uintptr_t addr)
+#endif
{
uint8_t opcode;
uint8_t nextop;
reg64_t *oped, *opgd;
sse_regs_t *opex, *opgx;
+ #ifdef TEST_INTERPRETER
+ x64emu_t* emu = test->emu;
+ #endif
uintptr_t tlsdata = GetSegmentBaseEmu(emu, seg);
opcode = F8;
// REX prefix before the F0 are ignored
rex.rex = 0;
- while(opcode>=0x40 && opcode<=0x4f) {
- rex.rex = opcode;
- opcode = F8;
- }
+ if(!rex.is32bits)
+ while(opcode>=0x40 && opcode<=0x4f) {
+ rex.rex = opcode;
+ opcode = F8;
+ }
switch(opcode) {
@@ -84,7 +92,7 @@ uintptr_t Run6664(x64emu_t *emu, rex_t rex, int seg, uintptr_t addr)
}
break;
- case 0x89: /* MOV Ew,Gw */
+ case 0x89: /* MOV FS:Ew,Gw */
nextop = F8;
GETEW_OFFS(0, tlsdata);
GETGW;
@@ -93,8 +101,7 @@ uintptr_t Run6664(x64emu_t *emu, rex_t rex, int seg, uintptr_t addr)
else
EW->word[0] = GW->word[0];
break;
-
- case 0x8B: /* MOV Gd,Ed */
+ case 0x8B: /* MOV Gw,FS:Ew */
nextop = F8;
GETEW_OFFS(0, tlsdata);
GETGW;
@@ -103,9 +110,16 @@ uintptr_t Run6664(x64emu_t *emu, rex_t rex, int seg, uintptr_t addr)
else
GW->word[0] = EW->word[0];
break;
-
+ case 0xC7: /* MOV FS:Ew,Iw */
+ nextop = F8;
+ GETEW_OFFS(2, tlsdata);
+ if(rex.w)
+ EW->q[0] = F16S;
+ else
+ EW->word[0] = F16;
+ break;
default:
return 0;
}
return addr;
-} \ No newline at end of file
+}
diff --git a/src/emu/x64run66d9.c b/src/emu/x64run66d9.c
index 198c3a8..84b554d 100644
--- a/src/emu/x64run66d9.c
+++ b/src/emu/x64run66d9.c
@@ -22,10 +22,17 @@
#include "modrm.h"
+#ifdef TEST_INTERPRETER
+uintptr_t Test66D9(x64test_t *test, rex_t rex, uintptr_t addr)
+#else
uintptr_t Run66D9(x64emu_t *emu, rex_t rex, uintptr_t addr)
+#endif
{
uint8_t nextop;
reg64_t *oped;
+ #ifdef TEST_INTERPRETER
+ x64emu_t* emu = test->emu;
+ #endif
nextop = F8;
switch (nextop) {
@@ -84,7 +91,9 @@ uintptr_t Run66D9(x64emu_t *emu, rex_t rex, uintptr_t addr)
case 6: /* FNSTENV m */
// warning, incomplete
GETEW(0);
+ #ifndef TEST_INTERPRETER
fpu_savenv(emu, (char*)ED, 1);
+ #endif
break;
default:
return 0;
diff --git a/src/emu/x64run66dd.c b/src/emu/x64run66dd.c
index d0fc703..e8465dd 100644
--- a/src/emu/x64run66dd.c
+++ b/src/emu/x64run66dd.c
@@ -22,10 +22,17 @@
#include "modrm.h"
+#ifdef TEST_INTERPRETER
+uintptr_t Test66DD(x64test_t *test, rex_t rex, uintptr_t addr)
+#else
uintptr_t Run66DD(x64emu_t *emu, rex_t rex, uintptr_t addr)
+#endif
{
uint8_t nextop;
reg64_t *oped;
+ #ifdef TEST_INTERPRETER
+ x64emu_t* emu = test->emu;
+ #endif
nextop = F8;
switch (nextop) {
@@ -92,6 +99,7 @@ uintptr_t Run66DD(x64emu_t *emu, rex_t rex, uintptr_t addr)
case 6: /* FNSAVE m94byte */
GETEW(0);
// ENV first...
+ #ifndef TEST_INTERPRETER
fpu_savenv(emu, (char*)ED, 1);
// save the STx
{
@@ -102,6 +110,7 @@ uintptr_t Run66DD(x64emu_t *emu, rex_t rex, uintptr_t addr)
p+=10;
}
}
+ #endif
reset_fpu(emu);
break;
default:
diff --git a/src/emu/x64run66f0.c b/src/emu/x64run66f0.c
index 7bf48a4..77c0249 100644
--- a/src/emu/x64run66f0.c
+++ b/src/emu/x64run66f0.c
@@ -25,25 +25,37 @@
#include "modrm.h"
+#ifdef TEST_INTERPRETER
+uintptr_t Test66F0(x64test_t *test, rex_t rex, uintptr_t addr)
+#else
uintptr_t Run66F0(x64emu_t *emu, rex_t rex, uintptr_t addr)
+#endif
{
uint8_t opcode;
uint8_t nextop;
+ int16_t tmp16s;
uint16_t tmp16u, tmp16u2;
int32_t tmp32s;
int64_t tmp64s;
uint64_t tmp64u, tmp64u2;
reg64_t *oped, *opgd;
-
+ #ifdef USE_CAS
+ uint64_t tmpcas;
+ #endif
+ #ifdef TEST_INTERPRETER
+ x64emu_t* emu = test->emu;
+ #endif
opcode = F8;
// REX prefix before the F0 are ignored
rex.rex = 0;
- while(opcode>=0x40 && opcode<=0x4f) {
- rex.rex = opcode;
- opcode = F8;
- }
+ uintptr_t addr_entry = addr;
+ if(!rex.is32bits)
+ while(opcode>=0x40 && opcode<=0x4f) {
+ rex.rex = opcode;
+ opcode = F8;
+ }
- if(rex.w) return RunF0(emu, rex, addr);
+ if(rex.w) return RunF0(emu, rex, addr_entry);
switch(opcode) {
@@ -55,7 +67,7 @@ uintptr_t Run66F0(x64emu_t *emu, rex_t rex, uintptr_t addr)
nextop = F8;
GETEW(0);
GETGW;
-#ifdef DYNAREC
+#if defined(DYNAREC) && !defined(TEST_INTERPRETER)
do {
tmp16u = native_lock_read_h(EW);
cmp16(emu, R_AX, tmp16u);
@@ -67,14 +79,14 @@ uintptr_t Run66F0(x64emu_t *emu, rex_t rex, uintptr_t addr)
}
} while(tmp32s);
#else
- pthread_mutex_lock(&emu->context->mutex_lock);
+ pthread_mutex_lock(&my_context->mutex_lock);
cmp16(emu, R_AX, EW->word[0]);
if(ACCESS_FLAG(F_ZF)) {
EW->word[0] = GW->word[0];
} else {
R_AX = EW->word[0];
}
- pthread_mutex_unlock(&emu->context->mutex_lock);
+ pthread_mutex_unlock(&my_context->mutex_lock);
#endif
break;
@@ -82,41 +94,27 @@ uintptr_t Run66F0(x64emu_t *emu, rex_t rex, uintptr_t addr)
nextop = F8;
GETEW(0);
GETGW;
-#ifdef DYNAREC
- if(rex.w) {
+#if defined(DYNAREC) && !defined(TEST_INTERPRETER)
+ if(((uintptr_t)ED)&1) {
do {
- tmp64u = native_lock_read_dd(ED);
- tmp64u2 = add64(emu, tmp64u, GD->q[0]);
- } while(native_lock_write_dd(ED, tmp64u2));
- GD->q[0] = tmp64u;
+ tmp16u = ED->word[0] & ~0xff;
+ tmp16u |= native_lock_read_h(ED);
+ tmp16u2 = add16(emu, tmp16u, GD->word[0]);
+ } while(native_lock_write_h(ED, tmp16u2&0xff));
+ ED->word[0] = tmp16u2;
} else {
- if(((uintptr_t)ED)&1) {
- do {
- tmp16u = ED->word[0] & ~0xff;
- tmp16u |= native_lock_read_h(ED);
- tmp16u2 = add16(emu, tmp16u, GD->word[0]);
- } while(native_lock_write_h(ED, tmp16u2&0xff));
- ED->word[0] = tmp16u2;
- } else {
- do {
- tmp16u = native_lock_read_h(ED);
- tmp16u2 = add16(emu, tmp16u, GD->word[0]);
- } while(native_lock_write_h(ED, tmp16u2));
- }
- GD->word[0] = tmp16u;
+ do {
+ tmp16u = native_lock_read_h(ED);
+ tmp16u2 = add16(emu, tmp16u, GD->word[0]);
+ } while(native_lock_write_h(ED, tmp16u2));
}
+ GD->word[0] = tmp16u;
#else
- pthread_mutex_lock(&emu->context->mutex_lock);
- if(rex.w) {
- tmp64u = add64(emu, ED->q[0], GD->q[0]);
- GD->q[0] = ED->q[0];
- ED->q[0] = tmp64u;
- } else {
- tmp16u = add16(emu, ED->word[0], GD->word[0]);
- GD->word[0] = ED->word[0];
- ED->word[0] = tmp16u;
- }
- pthread_mutex_unlock(&emu->context->mutex_lock);
+ pthread_mutex_lock(&my_context->mutex_lock);
+ tmp16u = add16(emu, ED->word[0], GD->word[0]);
+ GD->word[0] = ED->word[0];
+ ED->word[0] = tmp16u;
+ pthread_mutex_unlock(&my_context->mutex_lock);
#endif
break;
@@ -125,38 +123,24 @@ uintptr_t Run66F0(x64emu_t *emu, rex_t rex, uintptr_t addr)
}
break;
-#ifdef DYNAREC
+#if defined(DYNAREC) && !defined(TEST_INTERPRETER)
#define GO(B, OP) \
case B+1: \
nextop = F8; \
GETEW(0); \
GETGW; \
- if(rex.w) { \
- do { \
- tmp64u = native_lock_read_dd(ED); \
- tmp64u = OP##64(emu, tmp64u, GD->q[0]); \
- } while (native_lock_write_dd(ED, tmp64u)); \
- } else { \
- do { \
- tmp16u = native_lock_read_h(ED); \
- tmp16u = OP##16(emu, tmp16u, GW->word[0]); \
- } while (native_lock_write_h(ED, tmp16u)); \
- } \
+ do { \
+ tmp16u = native_lock_read_h(ED); \
+ tmp16u = OP##16(emu, tmp16u, GW->word[0]); \
+ } while (native_lock_write_h(ED, tmp16u)); \
break; \
case B+3: \
nextop = F8; \
GETEW(0); \
GETGW; \
- if(rex.w) \
- GD->q[0] = OP##64(emu, GD->q[0], ED->q[0]); \
- else \
- GW->word[0] = OP##16(emu, GW->word[0], EW->word[0]);\
- break; \
+ GW->word[0] = OP##16(emu, GW->word[0], EW->word[0]); \
case B+5: \
- if(rex.w) \
- R_RAX = OP##64(emu, R_RAX, F32S64); \
- else \
- R_AX = OP##16(emu, R_AX, F16); \
+ R_AX = OP##16(emu, R_AX, F16); \
break;
#else
#define GO(B, OP) \
@@ -164,31 +148,22 @@ uintptr_t Run66F0(x64emu_t *emu, rex_t rex, uintptr_t addr)
nextop = F8; \
GETEW(0); \
GETGW; \
- pthread_mutex_lock(&emu->context->mutex_lock); \
- if(rex.w) \
- ED->q[0] = OP##64(emu, ED->q[0], GD->q[0]); \
- else \
- EW->word[0] = OP##16(emu, EW->word[0], GW->word[0]);\
- pthread_mutex_unlock(&emu->context->mutex_lock); \
+ pthread_mutex_lock(&my_context->mutex_lock); \
+ EW->word[0] = OP##16(emu, EW->word[0], GW->word[0]); \
+ pthread_mutex_unlock(&my_context->mutex_lock); \
break; \
case B+3: \
nextop = F8; \
GETEW(0); \
GETGW; \
- pthread_mutex_lock(&emu->context->mutex_lock); \
- if(rex.w) \
- GD->q[0] = OP##64(emu, GD->q[0], ED->q[0]); \
- else \
- GW->word[0] = OP##16(emu, GW->word[0], EW->word[0]);\
- pthread_mutex_unlock(&emu->context->mutex_lock); \
+ pthread_mutex_lock(&my_context->mutex_lock); \
+ GW->word[0] = OP##16(emu, GW->word[0], EW->word[0]); \
+ pthread_mutex_unlock(&my_context->mutex_lock); \
break; \
case B+5: \
- pthread_mutex_lock(&emu->context->mutex_lock); \
- if(rex.w) \
- R_RAX = OP##64(emu, R_RAX, F32S64); \
- else \
- R_AX = OP##16(emu, R_AX, F16); \
- pthread_mutex_unlock(&emu->context->mutex_lock); \
+ pthread_mutex_lock(&my_context->mutex_lock); \
+ R_AX = OP##16(emu, R_AX, F16); \
+ pthread_mutex_unlock(&my_context->mutex_lock); \
break;
#endif
GO(0x00, add) /* ADD 0x00 -> 0x05 */
@@ -204,44 +179,44 @@ uintptr_t Run66F0(x64emu_t *emu, rex_t rex, uintptr_t addr)
case 0x83: /* GRP Ew,Ib */
nextop = F8;
GETED((opcode==0x83)?1:2);
- tmp64s = (opcode==0x83)?(F8S):(F16S);
- tmp64u = (uint64_t)tmp64s;
-#ifdef DYNAREC
+ tmp16s = (opcode==0x83)?(F8S):(F16S);
+ tmp16u = (uint16_t)tmp16s;
+#if defined(DYNAREC) && !defined(TEST_INTERPRETER)
if(MODREG)
switch((nextop>>3)&7) {
- case 0: ED->word[0] = add16(emu, ED->word[0], tmp64u); break;
- case 1: ED->word[0] = or16(emu, ED->word[0], tmp64u); break;
- case 2: ED->word[0] = adc16(emu, ED->word[0], tmp64u); break;
- case 3: ED->word[0] = sbb16(emu, ED->word[0], tmp64u); break;
- case 4: ED->word[0] = and16(emu, ED->word[0], tmp64u); break;
- case 5: ED->word[0] = sub16(emu, ED->word[0], tmp64u); break;
- case 6: ED->word[0] = xor16(emu, ED->word[0], tmp64u); break;
- case 7: cmp16(emu, ED->word[0], tmp64u); break;
+ case 0: ED->word[0] = add16(emu, ED->word[0], tmp16u); break;
+ case 1: ED->word[0] = or16(emu, ED->word[0], tmp16u); break;
+ case 2: ED->word[0] = adc16(emu, ED->word[0], tmp16u); break;
+ case 3: ED->word[0] = sbb16(emu, ED->word[0], tmp16u); break;
+ case 4: ED->word[0] = and16(emu, ED->word[0], tmp16u); break;
+ case 5: ED->word[0] = sub16(emu, ED->word[0], tmp16u); break;
+ case 6: ED->word[0] = xor16(emu, ED->word[0], tmp16u); break;
+ case 7: cmp16(emu, ED->word[0], tmp16u); break;
}
else
switch((nextop>>3)&7) {
- case 0: do { tmp16u2 = native_lock_read_h(ED); tmp16u2 = add16(emu, tmp16u2, tmp64u);} while(native_lock_write_h(ED, tmp16u2)); break;
- case 1: do { tmp16u2 = native_lock_read_h(ED); tmp16u2 = or16(emu, tmp16u2, tmp64u);} while(native_lock_write_h(ED, tmp16u2)); break;
- case 2: do { tmp16u2 = native_lock_read_h(ED); tmp16u2 = adc16(emu, tmp16u2, tmp64u);} while(native_lock_write_h(ED, tmp16u2)); break;
- case 3: do { tmp16u2 = native_lock_read_h(ED); tmp16u2 = sbb16(emu, tmp16u2, tmp64u);} while(native_lock_write_h(ED, tmp16u2)); break;
- case 4: do { tmp16u2 = native_lock_read_h(ED); tmp16u2 = and16(emu, tmp16u2, tmp64u);} while(native_lock_write_h(ED, tmp16u2)); break;
- case 5: do { tmp16u2 = native_lock_read_h(ED); tmp16u2 = sub16(emu, tmp16u2, tmp64u);} while(native_lock_write_h(ED, tmp16u2)); break;
- case 6: do { tmp16u2 = native_lock_read_h(ED); tmp16u2 = xor16(emu, tmp16u2, tmp64u);} while(native_lock_write_h(ED, tmp16u2)); break;
- case 7: cmp16(emu, ED->word[0], tmp64u); break;
+ case 0: do { tmp16u2 = native_lock_read_h(ED); tmp16u2 = add16(emu, tmp16u2, tmp16u);} while(native_lock_write_h(ED, tmp16u2)); break;
+ case 1: do { tmp16u2 = native_lock_read_h(ED); tmp16u2 = or16(emu, tmp16u2, tmp16u);} while(native_lock_write_h(ED, tmp16u2)); break;
+ case 2: do { tmp16u2 = native_lock_read_h(ED); tmp16u2 = adc16(emu, tmp16u2, tmp16u);} while(native_lock_write_h(ED, tmp16u2)); break;
+ case 3: do { tmp16u2 = native_lock_read_h(ED); tmp16u2 = sbb16(emu, tmp16u2, tmp16u);} while(native_lock_write_h(ED, tmp16u2)); break;
+ case 4: do { tmp16u2 = native_lock_read_h(ED); tmp16u2 = and16(emu, tmp16u2, tmp16u);} while(native_lock_write_h(ED, tmp16u2)); break;
+ case 5: do { tmp16u2 = native_lock_read_h(ED); tmp16u2 = sub16(emu, tmp16u2, tmp16u);} while(native_lock_write_h(ED, tmp16u2)); break;
+ case 6: do { tmp16u2 = native_lock_read_h(ED); tmp16u2 = xor16(emu, tmp16u2, tmp16u);} while(native_lock_write_h(ED, tmp16u2)); break;
+ case 7: cmp16(emu, ED->word[0], tmp16u); break;
}
#else
- pthread_mutex_lock(&emu->context->mutex_lock);
+ pthread_mutex_lock(&my_context->mutex_lock);
switch((nextop>>3)&7) {
- case 0: ED->word[0] = add16(emu, ED->word[0], tmp64u); break;
- case 1: ED->word[0] = or16(emu, ED->word[0], tmp64u); break;
- case 2: ED->word[0] = adc16(emu, ED->word[0], tmp64u); break;
- case 3: ED->word[0] = sbb16(emu, ED->word[0], tmp64u); break;
- case 4: ED->word[0] = and16(emu, ED->word[0], tmp64u); break;
- case 5: ED->word[0] = sub16(emu, ED->word[0], tmp64u); break;
- case 6: ED->word[0] = xor16(emu, ED->word[0], tmp64u); break;
- case 7: cmp16(emu, ED->word[0], tmp64u); break;
+ case 0: ED->word[0] = add16(emu, ED->word[0], tmp16u); break;
+ case 1: ED->word[0] = or16(emu, ED->word[0], tmp16u); break;
+ case 2: ED->word[0] = adc16(emu, ED->word[0], tmp16u); break;
+ case 3: ED->word[0] = sbb16(emu, ED->word[0], tmp16u); break;
+ case 4: ED->word[0] = and16(emu, ED->word[0], tmp16u); break;
+ case 5: ED->word[0] = sub16(emu, ED->word[0], tmp16u); break;
+ case 6: ED->word[0] = xor16(emu, ED->word[0], tmp16u); break;
+ case 7: cmp16(emu, ED->word[0], tmp16u); break;
}
- pthread_mutex_unlock(&emu->context->mutex_lock);
+ pthread_mutex_unlock(&my_context->mutex_lock);
#endif
break;
@@ -250,76 +225,36 @@ uintptr_t Run66F0(x64emu_t *emu, rex_t rex, uintptr_t addr)
GETED(0);
switch((nextop>>3)&7) {
case 0: /* INC Ed */
-#ifdef DYNAREC
- if(rex.w)
- if(((uintptr_t)ED)&7) {
- // unaligned
- do {
- tmp64u = ED->q[0] & 0xffffffffffffff00LL;
- tmp64u |= native_lock_read_b(ED);
- tmp64u = inc64(emu, tmp64u);
- } while(native_lock_write_b(ED, tmp64u&0xff));
- ED->q[0] = tmp64u;
- }
- else
- do {
- tmp64u = native_lock_read_dd(ED);
- } while(native_lock_write_dd(ED, inc64(emu, tmp64u)));
- else {
- if((uintptr_t)ED&1) {
- //meh.
- do {
- tmp16u = ED->word[0];
- tmp16u &=~0xff;
- tmp16u |= native_lock_read_b(ED);
- tmp16u = inc16(emu, tmp16u);
- } while(native_lock_write_b(ED, tmp16u&0xff));
- ED->word[0] = tmp16u;
- } else {
- do {
- tmp16u = native_lock_read_h(ED);
- } while(native_lock_write_h(ED, inc16(emu, tmp16u)));
- }
- }
-#else
- pthread_mutex_lock(&emu->context->mutex_lock);
- if(rex.w) {
- ED->q[0] = inc64(emu, ED->q[0]);
+#if defined(DYNAREC) && !defined(TEST_INTERPRETER)
+ if((uintptr_t)ED&1) {
+ //meh.
+ do {
+ tmp16u = ED->word[0];
+ tmp16u &=~0xff;
+ tmp16u |= native_lock_read_b(ED);
+ tmp16u = inc16(emu, tmp16u);
+ } while(native_lock_write_b(ED, tmp16u&0xff));
+ ED->word[0] = tmp16u;
} else {
- ED->word[0] = inc16(emu, ED->word[0]);
+ do {
+ tmp16u = native_lock_read_h(ED);
+ } while(native_lock_write_h(ED, inc16(emu, tmp16u)));
}
- pthread_mutex_unlock(&emu->context->mutex_lock);
+#else
+ pthread_mutex_lock(&my_context->mutex_lock);
+ ED->word[0] = inc16(emu, ED->word[0]);
+ pthread_mutex_unlock(&my_context->mutex_lock);
#endif
break;
case 1: /* DEC Ed */
-#ifdef DYNAREC
- if(rex.w)
- if(((uintptr_t)ED)&7) {
- // unaligned
- do {
- tmp64u = ED->q[0] & 0xffffffffffffff00LL;
- tmp64u |= native_lock_read_b(ED);
- tmp64u = dec64(emu, tmp64u);
- } while(native_lock_write_b(ED, tmp64u&0xff));
- ED->q[0] = tmp64u;
- }
- else
- do {
- tmp64u = native_lock_read_dd(ED);
- } while(native_lock_write_dd(ED, dec64(emu, tmp64u)));
- else {
- do {
- tmp16u = native_lock_read_h(ED);
- } while(native_lock_write_h(ED, dec16(emu, tmp16u)));
- }
+#if defined(DYNAREC) && !defined(TEST_INTERPRETER)
+ do {
+ tmp16u = native_lock_read_h(ED);
+ } while(native_lock_write_h(ED, dec16(emu, tmp16u)));
#else
- pthread_mutex_lock(&emu->context->mutex_lock);
- if(rex.w) {
- ED->q[0] = dec64(emu, ED->q[0]);
- } else {
- ED->word[0] = dec16(emu, ED->word[0]);
- }
- pthread_mutex_unlock(&emu->context->mutex_lock);
+ pthread_mutex_lock(&my_context->mutex_lock);
+ ED->word[0] = dec16(emu, ED->word[0]);
+ pthread_mutex_unlock(&my_context->mutex_lock);
#endif
break;
default:
diff --git a/src/emu/x64run67.c b/src/emu/x64run67.c
index 034fd64..5d9f41c 100644
--- a/src/emu/x64run67.c
+++ b/src/emu/x64run67.c
@@ -22,7 +22,11 @@
#include "modrm.h"
+#ifdef TEST_INTERPRETER
+uintptr_t Test67(x64test_t *test, rex_t rex, int rep, uintptr_t addr)
+#else
uintptr_t Run67(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr)
+#endif
{
uint8_t opcode;
uint8_t nextop;
@@ -32,6 +36,15 @@ uintptr_t Run67(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr)
int32_t tmp32s;
uint64_t tmp64u;
reg64_t *oped, *opgd;
+ #ifdef TEST_INTERPRETER
+ x64emu_t* emu = test->emu;
+ #endif
+ if(rex.is32bits)
+ #ifdef TEST_INTERPRETER
+ return Test67_32(test, rex, rep, addr);
+ #else
+ return Run67_32(emu, rex, rep, addr);
+ #endif
opcode = F8;
@@ -145,8 +158,25 @@ uintptr_t Run67(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr)
cmp32(emu, R_EAX, F32);
break;
+ case 0x63: /* MOVSXD Gd,Ed */
+ nextop = F8;
+ GETED32(0);
+ GETGD;
+ if(rex.w)
+ GD->sq[0] = ED->sdword[0];
+ else
+ if(MODREG)
+ GD->q[0] = ED->dword[0]; // not really a sign extension
+ else
+ GD->sdword[0] = ED->sdword[0]; // meh?
+ break;
+
case 0x66:
+ #ifdef TEST_INTERPRETER
+ return Test6766(test, rex, rep, addr);
+ #else
return Run6766(emu, rex, rep, addr);
+ #endif
case 0x80: /* GRP Eb,Ib */
nextop = F8;
@@ -249,7 +279,7 @@ uintptr_t Run67(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr)
case 0x8D: /* LEA Gd,M */
nextop = F8;
- GETED32(0);
+ _GETED32(0);
GETGD;
if(rex.w)
GD->q[0] = (uint64_t)ED;
@@ -338,7 +368,7 @@ uintptr_t Run67(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr)
case 0xE8: /* CALL Id */
tmp32s = F32S; // call is relative
- Push(emu, addr);
+ Push64(emu, addr);
addr += tmp32s;
break;
diff --git a/src/emu/x64run670f.c b/src/emu/x64run670f.c
index d122d0e..015b371 100644
--- a/src/emu/x64run670f.c
+++ b/src/emu/x64run670f.c
@@ -26,7 +26,11 @@
#include "modrm.h"
+#ifdef TEST_INTERPRETER
+uintptr_t Test670F(x64test_t *test, rex_t rex, int rep, uintptr_t addr)
+#else
uintptr_t Run670F(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr)
+#endif
{
(void)rep;
uint8_t opcode;
@@ -40,10 +44,26 @@ uintptr_t Run670F(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr)
sse_regs_t *opex, *opgx, eax1; (void)eax1;
mmx87_regs_t *opem, *opgm, eam1; (void)opem; (void)opgm; (void)eam1;
+ #ifdef TEST_INTERPRETER
+ x64emu_t* emu = test->emu;
+ #endif
opcode = F8;
switch(opcode) {
+ case 0x11:
+ switch(rep) {
+ case 0: /* MOVUPS Ex,Gx */
+ nextop = F8;
+ GETEX32(0);
+ GETGX;
+ EX->u128 = GX->u128;
+ break;
+ default:
+ return 0;
+ }
+ break;
+
case 0x2E:
// same for now
case 0x2F:
@@ -77,6 +97,12 @@ uintptr_t Run670F(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr)
GETGM;
GM->q = EM->q;
break;
+ case 2: /* MOVDQU Gx, Ex */
+ nextop = F8;
+ GETEX32(0);
+ GETGX;
+ memcpy(GX, EX, 16); // unaligned...
+ break;
default:
return 0;
}
@@ -95,18 +121,34 @@ uintptr_t Run670F(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr)
}
break;
+ case 0xB6: /* MOVZX Gd,Eb */
+ nextop = F8;
+ GETEB32(0);
+ GETGD;
+ GD->q[0] = EB->byte[0];
+ break;
+
case 0xB9:
switch(rep) {
case 0: /* UD1 Ed */
nextop = F8;
- GETED32(0);
+ FAKEED32(0);
+ #ifndef TEST_INTERPRETER
emit_signal(emu, SIGILL, (void*)R_RIP, 0);
+ #endif
break;
default:
return 0;
}
break;
+ case 0xB7: /* MOVZX Gd,Ew */
+ nextop = F8;
+ GETEW32(0);
+ GETGD;
+ GD->q[0] = EW->word[0];
+ break;
+
default:
return 0;
}
diff --git a/src/emu/x64run6764_32.c b/src/emu/x64run6764_32.c
new file mode 100644
index 0000000..6f6b060
--- /dev/null
+++ b/src/emu/x64run6764_32.c
@@ -0,0 +1,67 @@
+#define _GNU_SOURCE
+#include <stdint.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <math.h>
+#include <string.h>
+#include <signal.h>
+#include <sys/types.h>
+#include <unistd.h>
+
+#include "debug.h"
+#include "box64stack.h"
+#include "x64emu.h"
+#include "x64run.h"
+#include "x64emu_private.h"
+#include "x64run_private.h"
+#include "x64primop.h"
+#include "x64trace.h"
+#include "x87emu_private.h"
+#include "box64context.h"
+#include "bridge.h"
+
+#include "modrm.h"
+
+#ifdef TEST_INTERPRETER
+uintptr_t Test6764_32(x64test_t *test, rex_t rex, int rep, int seg, uintptr_t addr)
+#else
+uintptr_t Run6764_32(x64emu_t *emu, rex_t rex, int rep, int seg, uintptr_t addr)
+#endif
+{
+ uint8_t opcode;
+ uint8_t nextop;
+ int8_t tmp8s;
+ uint8_t tmp8u;
+ uint32_t tmp32u;
+ int32_t tmp32s;
+ uint64_t tmp64u;
+ reg64_t *oped, *opgd;
+ #ifdef TEST_INTERPRETER
+ x64emu_t* emu = test->emu;
+ #endif
+ uintptr_t tlsdata = GetSegmentBaseEmu(emu, seg);
+ opcode = F8;
+
+ while(opcode==0x67)
+ opcode = F8;
+
+ rex.rex = 0;
+ while((opcode==0xF2) || (opcode==0xF3)) {
+ rep = opcode-0xF1;
+ opcode = F8;
+ }
+
+ switch(opcode) {
+
+ case 0x8B: /* MOV Gw, FS:Ew */
+ nextop = F8;
+ GETEW_OFFS_16(tlsdata);
+ GETGW;
+ GW->word[0] = EW->word[0];
+ break;
+
+ default:
+ return 0;
+ }
+ return addr;
+} \ No newline at end of file
diff --git a/src/emu/x64run6766.c b/src/emu/x64run6766.c
index c12e903..35219b2 100644
--- a/src/emu/x64run6766.c
+++ b/src/emu/x64run6766.c
@@ -25,7 +25,11 @@
#include "modrm.h"
+#ifdef TEST_INTERPRETER
+uintptr_t Test6766(x64test_t *test, rex_t rex, int rep, uintptr_t addr)
+#else
uintptr_t Run6766(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr)
+#endif
{
// Hmmmm....
(void)rep;
@@ -39,7 +43,9 @@ uintptr_t Run6766(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr)
int64_t tmp64s; (void)tmp64s;
uint64_t tmp64u, tmp64u2, tmp64u3; (void)tmp64u; (void)tmp64u2; (void)tmp64u3;
reg64_t *oped, *opgd; (void)oped; (void)opgd;
-
+ #ifdef TEST_INTERPRETER
+ x64emu_t* emu = test->emu;
+ #endif
opcode = F8;
while((opcode==0x2E) || (opcode==0x66)) // ignoring CS: or multiple 0x66
@@ -51,15 +57,30 @@ uintptr_t Run6766(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr)
}
// REX prefix before the 66 are ignored
rex.rex = 0;
- while(opcode>=0x40 && opcode<=0x4f) {
- rex.rex = opcode;
- opcode = F8;
- }
+ if(!rex.is32bits)
+ while(opcode>=0x40 && opcode<=0x4f) {
+ rex.rex = opcode;
+ opcode = F8;
+ }
switch(opcode) {
case 0x0F: /* more opcodes */
+ #ifdef TEST_INTERPRETER
+ return Test67660F(test, rex, addr);
+ #else
return Run67660F(emu, rex, addr);
+ #endif
+
+ case 0x89: /* MOV Ew,Gw */
+ nextop = F8;
+ GETEW32(0);
+ GETGW;
+ if(rex.w)
+ EW->q[0] = GW->q[0];
+ else
+ EW->word[0] = GW->word[0];
+ break;
default:
return 0;
diff --git a/src/emu/x64run67660f.c b/src/emu/x64run67660f.c
index 7550642..ba031c8 100644
--- a/src/emu/x64run67660f.c
+++ b/src/emu/x64run67660f.c
@@ -22,7 +22,11 @@
#include "modrm.h"
+#ifdef TEST_INTERPRETER
+uintptr_t Test67660F(x64test_t *test, rex_t rex, uintptr_t addr)
+#else
uintptr_t Run67660F(x64emu_t *emu, rex_t rex, uintptr_t addr)
+#endif
{
uint8_t opcode;
uint8_t nextop;
@@ -36,7 +40,9 @@ uintptr_t Run67660F(x64emu_t *emu, rex_t rex, uintptr_t addr)
uint64_t tmp64u; (void)tmp64u;
reg64_t *oped, *opgd; (void)oped; (void)opgd;
sse_regs_t *opex, *opgx;
-
+ #ifdef TEST_INTERPRETER
+ x64emu_t* emu = test->emu;
+ #endif
opcode = F8;
switch(opcode) {
diff --git a/src/emu/x64run67_32.c b/src/emu/x64run67_32.c
new file mode 100644
index 0000000..a1df3ba
--- /dev/null
+++ b/src/emu/x64run67_32.c
@@ -0,0 +1,100 @@
+#define _GNU_SOURCE
+#include <stdint.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <math.h>
+#include <string.h>
+#include <signal.h>
+#include <sys/types.h>
+#include <unistd.h>
+
+#include "debug.h"
+#include "box64stack.h"
+#include "x64emu.h"
+#include "x64run.h"
+#include "x64emu_private.h"
+#include "x64run_private.h"
+#include "x64primop.h"
+#include "x64trace.h"
+#include "x87emu_private.h"
+#include "box64context.h"
+#include "bridge.h"
+
+#include "modrm.h"
+
+#ifdef TEST_INTERPRETER
+uintptr_t Test67_32(x64test_t *test, rex_t rex, int rep, uintptr_t addr)
+#else
+uintptr_t Run67_32(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr)
+#endif
+{
+ uint8_t opcode;
+ uint8_t nextop;
+ int8_t tmp8s;
+ uint8_t tmp8u;
+ uint32_t tmp32u;
+ int32_t tmp32s;
+ uint64_t tmp64u;
+ reg64_t *oped, *opgd;
+ #ifdef TEST_INTERPRETER
+ x64emu_t* emu = test->emu;
+ #endif
+ opcode = F8;
+
+ while(opcode==0x67)
+ opcode = F8;
+
+ rex.rex = 0;
+ while((opcode==0xF2) || (opcode==0xF3)) {
+ rep = opcode-0xF1;
+ opcode = F8;
+ }
+
+ switch(opcode) {
+
+ case 0x64: /* FS: prefix */
+ #ifdef TEST_INTERPRETER
+ return Test6764_32(test, rex, rep, _FS, addr);
+ #else
+ return Run6764_32(emu, rex, rep, _FS, addr);
+ #endif
+ break;
+ case 0x65: /* GS: prefix */
+ #ifdef TEST_INTERPRETER
+ return Test6764_32(test, rex, rep, _GS, addr);
+ #else
+ return Run6764_32(emu, rex, rep, _GS, addr);
+ #endif
+ break;
+
+ case 0xE0: /* LOOPNZ */
+ CHECK_FLAGS(emu);
+ tmp8s = F8S;
+ --R_CX; // don't update flags
+ if(R_CX && !ACCESS_FLAG(F_ZF))
+ addr += tmp8s;
+ break;
+ case 0xE1: /* LOOPZ */
+ CHECK_FLAGS(emu);
+ tmp8s = F8S;
+ --R_CX; // don't update flags
+ if(R_CX && ACCESS_FLAG(F_ZF))
+ addr += tmp8s;
+ break;
+ case 0xE2: /* LOOP */
+ tmp8s = F8S;
+ --R_CX; // don't update flags
+ if(R_CX)
+ addr += tmp8s;
+ break;
+ case 0xE3: /* JECXZ Ib */
+ tmp8s = F8S;
+ if(!R_CX)
+ addr += tmp8s;
+ break;
+
+ default:
+ return 0;
+ }
+ return addr;
+} \ No newline at end of file
diff --git a/src/emu/x64run_private.c b/src/emu/x64run_private.c
index a78ca67..ffddd73 100755..100644
--- a/src/emu/x64run_private.c
+++ b/src/emu/x64run_private.c
@@ -33,6 +33,8 @@ int32_t EXPORT my___libc_start_main(x64emu_t* emu, int *(main) (int, char * *, c
(void)argc; (void)ubp_av; (void)fini; (void)rtld_fini; (void)stack_end;
if(init) {
+ uintptr_t old_rsp = GetRSP(emu);
+ uintptr_t old_rbp = GetRBP(emu); // should not be needed, but seems to be without dynarec
Push64(emu, GetRBP(emu)); // set frame pointer
SetRBP(emu, GetRSP(emu)); // save RSP
SetRSP(emu, GetRSP(emu)&~0xFLL); // Align RSP
@@ -47,11 +49,17 @@ int32_t EXPORT my___libc_start_main(x64emu_t* emu, int *(main) (int, char * *, c
return 0;
SetRSP(emu, GetRBP(emu)); // restore RSP
SetRBP(emu, Pop64(emu)); // restore RBP
+ SetRSP(emu, old_rsp);
+ SetRBP(emu, old_rbp);
emu->quit = 0;
} else {
- RunElfInit(my_context->elfs[0], emu);
+ if(my_context->elfs[0]) {
+ RunElfInit(my_context->elfs[0], emu);
+ }
+ }
+ if(my_context->elfs[0]) {
+ MarkElfInitDone(my_context->elfs[0]);
}
- MarkElfInitDone(my_context->elfs[0]);
printf_log(LOG_DEBUG, "Transfert to main(%d, %p, %p)=>%p from __libc_start_main\n", my_context->argc, my_context->argv, my_context->envv, main);
// call main and finish
Push64(emu, GetRBP(emu)); // set frame pointer
@@ -939,7 +947,7 @@ void UpdateFlags(x64emu_t *emu)
case d_rcr32:
case d_rcr64:
case d_unknown:
- printf_log(LOG_NONE, "Box64: %p trying to evaluate Unknown defered Flags\n", (void*)R_RIP);
+ printf_log(LOG_NONE, "Box64: %p trying to evaluate Unknown deferred Flags\n", (void*)R_RIP);
break;
case d_dec8i:
@@ -951,7 +959,7 @@ void UpdateFlags(x64emu_t *emu)
case d_inc32i:
case d_inc64i:
{
- defered_flags_t df = emu->df - (d_dec8i - d_dec8);
+ deferred_flags_t df = emu->df - (d_dec8i - d_dec8);
if(emu->df_sav!=d_none) {
// compute CF
multiuint_t op1 = emu->op1;
@@ -1006,7 +1014,7 @@ const char* getAddrFunctionName(uintptr_t addr)
return ret;
}
-void printFunctionAddr(uintptr_t nextaddr, const char* text)
+int printFunctionAddr(uintptr_t nextaddr, const char* text)
{
uint64_t sz = 0;
uintptr_t start = 0;
@@ -1017,7 +1025,9 @@ void printFunctionAddr(uintptr_t nextaddr, const char* text)
printf_log(LOG_NONE, " (%s%s:%s)", text, ElfName(FindElfAddress(my_context, nextaddr)), symbname);
else
printf_log(LOG_NONE, " (%s%s:%s + %ld)", text, ElfName(FindElfAddress(my_context, nextaddr)), symbname, nextaddr - start);
+ return 1;
}
+ return 0;
}
#ifdef HAVE_TRACE
@@ -1028,6 +1038,7 @@ extern uint64_t start_cnt;
void PrintTrace(x64emu_t* emu, uintptr_t ip, int dynarec)
{
+ int is32bits = (emu->segs[_CS]==0x23);
if(start_cnt) --start_cnt;
if(!start_cnt && my_context->dec && (
(trace_end == 0)
@@ -1047,7 +1058,7 @@ void PrintTrace(x64emu_t* emu, uintptr_t ip, int dynarec)
my_context->trace_tid = tid;
}
#endif
- printf_log(LOG_NONE, "%s", DumpCPURegs(emu, ip));
+ printf_log(LOG_NONE, "%s", DumpCPURegs(emu, ip, is32bits));
if(R_RIP==0) {
printf_log(LOG_NONE, "Running at NULL address\n");
mutex_unlock(&my_context->mutex_trace);
@@ -1061,32 +1072,51 @@ void PrintTrace(x64emu_t* emu, uintptr_t ip, int dynarec)
printf_log(LOG_NONE, "%p: Native call to %p => %s\n", (void*)ip, (void*)a, GetNativeName(*(void**)(ip+11)));
}
} else {
- printf_log(LOG_NONE, "%s", DecodeX64Trace(my_context->dec, ip));
+ printf_log(LOG_NONE, "%s", DecodeX64Trace(is32bits?my_context->dec32:my_context->dec, ip));
uint8_t peek = PK(0);
rex_t rex = {0};
- if(peek>=0x40 && peek<=0x4f) {
+ if(!is32bits && peek>=0x40 && peek<=0x4f) {
rex.rex = peek;
ip++;
peek = PK(0);
}
if(peek==0xC3 || peek==0xC2 || (peek==0xF3 && PK(1)==0xC3)) {
- printf_log(LOG_NONE, " => %p", *(void**)(R_RSP));
- printFunctionAddr(*(uintptr_t*)(R_RSP), "=> ");
+ if(is32bits) {
+ printf_log(LOG_NONE, " => %p", (void*)(uintptr_t)*(uint32_t*)(R_RSP));
+ printFunctionAddr(*(uint32_t*)(R_RSP), "=> ");
+ } else {
+ printf_log(LOG_NONE, " => %p", *(void**)(R_RSP));
+ printFunctionAddr(*(uintptr_t*)(R_RSP), "=> ");
+ }
} else if(peek==0x57 && rex.b) {
printf_log(LOG_NONE, " => STACK_TOP: %p", *(void**)(R_RSP));
printFunctionAddr(ip, "here: ");
- } else if(peek==0x55 || peek==0x53) {
+ } else if((peek==0x55 || peek==0x53) && !is32bits) {
printFunctionAddr(*(uintptr_t*)(R_RSP), " STACK_TOP: ");
- } else if(peek==0xF3 && PK(1)==0x0F && PK(2)==0x1E && PK(3)==0xFA) {
+ } else if((peek==0x55 || peek==0x56) && is32bits) {
+ if(!printFunctionAddr(*(uint32_t*)(R_RSP), " STACK_TOP: "))
+ printf_log(LOG_NONE, " STACK_TOP: %p ", (void*)(uintptr_t)*(uint32_t*)(R_RSP));
+ } else if(peek==0xF3 && PK(1)==0x0F && PK(2)==0x1E && PK(3)==0xFA && !is32bits) {
printFunctionAddr(*(uintptr_t*)(R_RSP), " STACK_TOP: ");
- } else if(peek==0xE8) { // Call
- uintptr_t nextaddr = ip + 5 + PK64(1);
+ } else if(peek==0xE8 || peek==0xE9) { // Call & Jmp
+ uintptr_t nextaddr = ip + 5 + PK32(1);
printFunctionAddr(nextaddr, "=> ");
} else if(peek==0xFF) {
if(PK(1)==0x25) {
- uintptr_t nextaddr = ip + 6 + PK64(2);
+ uintptr_t nextaddr = *(uintptr_t*)(ip + 6 + PK32(2));
+ if(!printFunctionAddr(nextaddr, "=> "))
+ printf_log(LOG_NONE, " => %p", (void*)nextaddr);
+ } else if((PK(1)==0x14) && (PK(2)==0x25)) {
+ uintptr_t nextaddr = *(uintptr_t*)(uintptr_t)PK32(3);
+ printf_log(LOG_NONE, " => %p", (void*)nextaddr);
printFunctionAddr(nextaddr, "=> ");
+ } else if((PK(1)==0x14) && (PK(2)==0xC2) && rex.rex==0x41) {
+ uintptr_t nextaddr = *(uintptr_t*)(R_R10 + R_RAX*8);
+ printf_log(LOG_NONE, " => %p", (void*)nextaddr);
+ printFunctionAddr(nextaddr, "=> ");
+
}
+
}
printf_log(LOG_NONE, "\n");
}
@@ -1132,8 +1162,56 @@ static uint64_t F64(uintptr_t* addr) {
return ret;
}
+reg64_t* GetECommon_32(x64emu_t* emu, uintptr_t* addr, uint8_t m, uint32_t base)
+{
+ if (m<=7) {
+ if(m==0x4) {
+ uint8_t sib = F8(addr);
+ base += ((sib&0x7)==5)?((uint32_t)F32S(addr)):(emu->regs[(sib&0x7)].dword[0]); // base
+ base += (emu->sbiidx[((sib>>3)&7)]->sdword[0] << (sib>>6));
+ return (reg64_t*)(uintptr_t)base;
+ } else if (m==0x5) { //disp32
+ base += F32S(addr);
+ return (reg64_t*)(uintptr_t)base;
+ }
+ return (reg64_t*)(uintptr_t)(base + emu->regs[m].dword[0]);
+ } else {
+ if((m&7)==4) {
+ uint8_t sib = F8(addr);
+ base += emu->regs[(sib&0x7)].dword[0]; // base
+ base += (emu->sbiidx[((sib>>3)&7)]->sdword[0] << (sib>>6));
+ } else {
+ base += emu->regs[(m&0x7)].dword[0];
+ }
+ base+=(m&0x80)?F32S(addr):F8S(addr);
+ return (reg64_t*)(uintptr_t)base;
+ }
+}
+reg64_t* GetEw16_32(x64emu_t *emu, uintptr_t* addr, uint8_t m, uint32_t base)
+{
+ switch(m&7) {
+ case 0: base+= R_BX+R_SI; break;
+ case 1: base+= R_BX+R_DI; break;
+ case 2: base+= R_BP+R_SI; break;
+ case 3: base+= R_BP+R_DI; break;
+ case 4: base+= R_SI; break;
+ case 5: base+= R_DI; break;
+ case 6: base+= R_BP; break;
+ case 7: base+= R_BX; break;
+ }
+ switch((m>>6)&3) {
+ case 0: if((m&7)==6) base= F16S(addr); break;
+ case 1: base += F8S(addr); break;
+ case 2: base += F16S(addr); break;
+ // case 3 is C0..C7, already dealt with
+ }
+ return (reg64_t*)(uintptr_t)base;
+}
+
reg64_t* GetECommon(x64emu_t* emu, uintptr_t* addr, rex_t rex, uint8_t m, uint8_t delta)
{
+ if(rex.is32bits)
+ return GetECommon_32(emu, addr, m, 0);
if (m<=7) {
if(m==0x4) {
uint8_t sib = F8(addr);
@@ -1161,6 +1239,8 @@ reg64_t* GetECommon(x64emu_t* emu, uintptr_t* addr, rex_t rex, uint8_t m, uint8_
reg64_t* GetECommonO(x64emu_t* emu, uintptr_t* addr, rex_t rex, uint8_t m, uint8_t delta, uintptr_t base)
{
+ if(rex.is32bits)
+ return GetECommon_32(emu, addr, m, base);
if (m<=7) {
if(m==0x4) {
uint8_t sib = F8(addr);
@@ -1187,6 +1267,8 @@ reg64_t* GetECommonO(x64emu_t* emu, uintptr_t* addr, rex_t rex, uint8_t m, uint8
reg64_t* GetECommon32O(x64emu_t* emu, uintptr_t* addr, rex_t rex, uint8_t m, uint8_t delta, uintptr_t base)
{
+ if(rex.is32bits)
+ return GetEw16_32(emu, addr, m, base);
if (m<=7) {
if(m==0x4) {
uint8_t sib = F8(addr);
@@ -1225,6 +1307,26 @@ reg64_t* GetEb(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t del
} else return GetECommon(emu, addr, rex, m, delta);
}
+reg64_t* TestEb(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta)
+{
+ // rex ignored here
+ uint8_t m = v&0xC7; // filter Eb
+ if(m>=0xC0) {
+ if(rex.rex) {
+ return &test->emu->regs[(m&0x07)+(rex.b<<3)];
+ } else {
+ int lowhigh = (m&4)>>2;
+ return (reg64_t *)(((char*)(&test->emu->regs[(m&0x03)]))+lowhigh); //?
+ }
+ } else {
+ reg64_t* ret = GetECommon(test->emu, addr, rex, m, delta);
+ test->memsize = 1;
+ test->memaddr = (uintptr_t)ret;
+ test->mem[0] = ret->byte[0];
+ return (reg64_t*)test->mem;
+ }
+}
+
reg64_t* GetEbO(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta, uintptr_t offset)
{
// rex ignored here
@@ -1239,6 +1341,26 @@ reg64_t* GetEbO(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t de
} else return GetECommonO(emu, addr, rex, m, delta, offset);
}
+reg64_t* TestEbO(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta, uintptr_t offset)
+{
+ // rex ignored here
+ uint8_t m = v&0xC7; // filter Eb
+ if(m>=0xC0) {
+ if(rex.rex) {
+ return &test->emu->regs[(m&0x07)+(rex.b<<3)];
+ } else {
+ int lowhigh = (m&4)>>2;
+ return (reg64_t *)(((char*)(&test->emu->regs[(m&0x03)]))+lowhigh); //?
+ }
+ } else {
+ reg64_t* ret = GetECommonO(test->emu, addr, rex, m, delta, offset);
+ test->memsize = 1;
+ test->memaddr = (uintptr_t)ret;
+ test->mem[0] = ret->byte[0];
+ return (reg64_t*)test->mem;
+ }
+}
+
reg64_t* GetEd(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta)
{
uint8_t m = v&0xC7; // filter Ed
@@ -1247,6 +1369,85 @@ reg64_t* GetEd(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t del
} else return GetECommon(emu, addr, rex, m, delta);
}
+reg64_t* TestEd(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta)
+{
+ uint8_t m = v&0xC7; // filter Ed
+ if(m>=0xC0) {
+ return &test->emu->regs[(m&0x07)+(rex.b<<3)];
+ } else {
+ reg64_t* ret = GetECommon(test->emu, addr, rex, m, delta);
+ test->memsize = 4<<rex.w;
+ test->memaddr = (uintptr_t)ret;
+ if(rex.w)
+ *(uint64_t*)test->mem = ret->q[0];
+ else
+ *(uint32_t*)test->mem = ret->dword[0];
+ return (reg64_t*)test->mem;
+ }
+}
+reg64_t* TestEd4(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta)
+{
+ uint8_t m = v&0xC7; // filter Ed
+ if(m>=0xC0) {
+ return &test->emu->regs[(m&0x07)+(rex.b<<3)];
+ } else {
+ reg64_t* ret = GetECommon(test->emu, addr, rex, m, delta);
+ test->memsize = 4;
+ test->memaddr = (uintptr_t)ret;
+ *(uint32_t*)test->mem = ret->dword[0];
+ return (reg64_t*)test->mem;
+ }
+}
+reg64_t* TestEd8(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta)
+{
+ uint8_t m = v&0xC7; // filter Ed
+ if(m>=0xC0) {
+ return &test->emu->regs[(m&0x07)+(rex.b<<3)];
+ } else {
+ reg64_t* ret = GetECommon(test->emu, addr, rex, m, delta);
+ test->memsize = 8;
+ test->memaddr = (uintptr_t)ret;
+ *(uint64_t*)test->mem = ret->q[0];
+ return (reg64_t*)test->mem;
+ }
+}
+reg64_t* TestEdt(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta)
+{
+ uint8_t m = v&0xC7; // filter Ed
+ if(m>=0xC0) {
+ return &test->emu->regs[(m&0x07)+(rex.b<<3)];
+ } else {
+ reg64_t* ret = GetECommon(test->emu, addr, rex, m, delta);
+ test->memsize = 4;
+ test->memaddr = (uintptr_t)ret;
+ memcpy(test->mem, ret, 10);
+ return (reg64_t*)test->mem;
+ }
+}
+reg64_t* TestEd8xw(x64test_t *test, int w, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta)
+{
+ uint8_t m = v&0xC7; // filter Ed
+ if(m>=0xC0) {
+ return &test->emu->regs[(m&0x07)+(rex.b<<3)];
+ } else {
+ reg64_t* ret = GetECommon(test->emu, addr, rex, m, delta);
+ test->memsize = 8<<w;
+ test->memaddr = (uintptr_t)ret;
+ *(uint64_t*)test->mem = ret->q[0];
+ if(w)
+ ((uint64_t*)test->mem)[1] = ret->q[1];
+ return (reg64_t*)test->mem;
+ }
+}
+
+uintptr_t GetEA(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta)
+{
+ uint8_t m = v&0xC7; // filter Ed
+ if(m>=0xC0) {
+ return (uintptr_t)&emu->regs[(m&0x07)+(rex.b<<3)];
+ } else return (uintptr_t)GetECommon(emu, addr, rex, m, delta);
+}
+
reg64_t* GetEdO(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta, uintptr_t offset)
{
uint8_t m = v&0xC7; // filter Ed
@@ -1255,6 +1456,23 @@ reg64_t* GetEdO(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t de
} else return GetECommonO(emu, addr, rex, m, delta, offset);
}
+reg64_t* TestEdO(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta, uintptr_t offset)
+{
+ uint8_t m = v&0xC7; // filter Ed
+ if(m>=0xC0) {
+ return &test->emu->regs[(m&0x07)+(rex.b<<3)];
+ } else {
+ reg64_t* ret = GetECommonO(test->emu, addr, rex, m, delta, offset);
+ test->memsize = 4<<rex.w;
+ test->memaddr = (uintptr_t)ret;
+ if(rex.w)
+ *(uint64_t*)test->mem = ret->q[0];
+ else
+ *(uint32_t*)test->mem = ret->dword[0];
+ return (reg64_t*)test->mem;
+ }
+}
+
reg64_t* GetEd32O(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta, uintptr_t offset)
{
uint8_t m = v&0xC7; // filter Ed
@@ -1263,6 +1481,23 @@ reg64_t* GetEd32O(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t
} else return GetECommon32O(emu, addr, rex, m, delta, offset);
}
+reg64_t* TestEd32O(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta, uintptr_t offset)
+{
+ uint8_t m = v&0xC7; // filter Ed
+ if(m>=0xC0) {
+ return &test->emu->regs[(m&0x07)+(rex.b<<3)];
+ } else {
+ reg64_t* ret = GetECommon32O(test->emu, addr, rex, m, delta, offset);
+ test->memsize = 4<<rex.w;
+ test->memaddr = (uintptr_t)ret;
+ if(rex.w)
+ *(uint64_t*)test->mem = ret->q[0];
+ else
+ *(uint32_t*)test->mem = ret->dword[0];
+ return (reg64_t*)test->mem;
+ }
+}
+
reg64_t* GetEb32O(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta, uintptr_t offset)
{
uint8_t m = v&0xC7; // filter Eb
@@ -1276,7 +1511,27 @@ reg64_t* GetEb32O(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t
} else return GetECommon32O(emu, addr, rex, m, delta, offset);
}
+reg64_t* TestEb32O(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta, uintptr_t offset)
+{
+ uint8_t m = v&0xC7; // filter Eb
+ if(m>=0xC0) {
+ if(rex.rex) {
+ return &test->emu->regs[(m&0x07)+(rex.b<<3)];
+ } else {
+ int lowhigh = (m&4)>>2;
+ return (reg64_t *)(((char*)(&test->emu->regs[(m&0x03)]))+lowhigh); //?
+ }
+ } else {
+ reg64_t* ret = GetECommon32O(test->emu, addr, rex, m, delta, offset);
+ test->memsize = 1;
+ test->memaddr = (uintptr_t)ret;
+ test->mem[0] = ret->byte[0];
+ return (reg64_t*)test->mem;
+ }
+}
+
#define GetEw GetEd
+#define TestEw TestEd
reg64_t* GetEw16(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v)
{
@@ -1298,7 +1553,7 @@ reg64_t* GetEw16(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v)
case 7: base = R_BX; break;
}
switch((m>>6)&3) {
- case 0: if(m==6) base = F16(addr); break;
+ case 0: if((m&7)==6) base = F16S(addr); break;
case 1: base += F8S(addr); break;
case 2: base += F16S(addr); break;
// case 3 is C0..C7, already dealt with
@@ -1307,6 +1562,39 @@ reg64_t* GetEw16(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v)
}
}
+reg64_t* TestEw16(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v)
+{
+ (void)rex;
+ x64emu_t* emu = test->emu;
+
+ uint8_t m = v&0xC7; // filter Ed
+ if(m>=0xC0) {
+ return &emu->regs[(m&0x07)];
+ } else {
+ uintptr_t base = 0;
+ switch(m&7) {
+ case 0: base = R_BX+R_SI; break;
+ case 1: base = R_BX+R_DI; break;
+ case 2: base = R_BP+R_SI; break;
+ case 3: base = R_BP+R_DI; break;
+ case 4: base = R_SI; break;
+ case 5: base = R_DI; break;
+ case 6: base = R_BP; break;
+ case 7: base = R_BX; break;
+ }
+ switch((m>>6)&3) {
+ case 0: if((m&7)==6) base = F16S(addr); break;
+ case 1: base += F8S(addr); break;
+ case 2: base += F16S(addr); break;
+ // case 3 is C0..C7, already dealt with
+ }
+ test->memsize = 2;
+ *(uint16_t*)test->mem = *(uint16_t*)base;
+ test->memaddr = (uintptr_t)base;
+ return (reg64_t*)test->mem;
+ }
+}
+
reg64_t* GetEw16off(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uintptr_t offset)
{
(void)rex;
@@ -1327,7 +1615,7 @@ reg64_t* GetEw16off(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uintpt
case 7: base = R_BX; break;
}
switch((m>>6)&3) {
- case 0: if(m==6) base = F16(addr); break;
+ case 0: if((m&7)==6) base = F16S(addr); break;
case 1: base += F8S(addr); break;
case 2: base += F16S(addr); break;
// case 3 is C0..C7, already dealt with
@@ -1336,6 +1624,39 @@ reg64_t* GetEw16off(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uintpt
}
}
+reg64_t* TestEw16off(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uintptr_t offset)
+{
+ (void)rex;
+ x64emu_t* emu = test->emu;
+
+ uint32_t m = v&0xC7; // filter Ed
+ if(m>=0xC0) {
+ return &emu->regs[(m&0x07)];
+ } else {
+ uint32_t base = 0;
+ switch(m&7) {
+ case 0: base = R_BX+R_SI; break;
+ case 1: base = R_BX+R_DI; break;
+ case 2: base = R_BP+R_SI; break;
+ case 3: base = R_BP+R_DI; break;
+ case 4: base = R_SI; break;
+ case 5: base = R_DI; break;
+ case 6: base = R_BP; break;
+ case 7: base = R_BX; break;
+ }
+ switch((m>>6)&3) {
+ case 0: if((m&7)==6) base = F16S(addr); break;
+ case 1: base += F8S(addr); break;
+ case 2: base += F16S(addr); break;
+ // case 3 is C0..C7, already dealt with
+ }
+ test->memsize = 2;
+ *(uint16_t*)test->mem = *(uint16_t*)(base+offset);
+ test->memaddr = (uintptr_t)(base+offset);
+ return (reg64_t*)test->mem;
+ }
+}
+
mmx87_regs_t* GetEm(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta)
{
uint8_t m = v&0xC7; // filter Ed
@@ -1344,6 +1665,20 @@ mmx87_regs_t* GetEm(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_
} else return (mmx87_regs_t*)GetECommon(emu, addr, rex, m, delta);
}
+mmx87_regs_t* TestEm(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta)
+{
+ uint8_t m = v&0xC7; // filter Ed
+ if(m>=0xC0) {
+ return &test->emu->mmx[m&0x07];
+ } else {
+ mmx87_regs_t* ret = (mmx87_regs_t*)GetECommon(test->emu, addr, rex, m, delta);
+ test->memsize = 8;
+ *(uint64_t*)test->mem = ret->q;
+ test->memaddr = (uintptr_t)ret;
+ return (mmx87_regs_t*)test->mem;
+ }
+}
+
sse_regs_t* GetEx(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta)
{
uint8_t m = v&0xC7; // filter Ed
@@ -1352,6 +1687,22 @@ sse_regs_t* GetEx(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t
} else return (sse_regs_t*)GetECommon(emu, addr, rex, m, delta);
}
+sse_regs_t* TestEx(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta)
+{
+ uint8_t m = v&0xC7; // filter Ed
+ if(m>=0xC0) {
+ test->memsize=0;
+ return &test->emu->xmm[(m&0x07)+(rex.b<<3)];
+ } else {
+ sse_regs_t* ret = (sse_regs_t*)GetECommon(test->emu, addr, rex, m, delta);
+ test->memsize = 16;
+ ((uint64_t*)test->mem)[0] = ret->q[0];
+ ((uint64_t*)test->mem)[1] = ret->q[1];
+ test->memaddr = (uintptr_t)ret;
+ return (sse_regs_t*)test->mem;
+ }
+}
+
sse_regs_t* GetExO(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta, uintptr_t offset)
{
uint8_t m = v&0xC7; // filter Ed
@@ -1360,6 +1711,21 @@ sse_regs_t* GetExO(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t
} else return (sse_regs_t*)GetECommonO(emu, addr, rex, m, delta, offset);
}
+sse_regs_t* TestExO(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta, uintptr_t offset)
+{
+ uint8_t m = v&0xC7; // filter Ed
+ if(m>=0xC0) {
+ return &test->emu->xmm[(m&0x07)+(rex.b<<3)];
+ } else {
+ sse_regs_t* ret = (sse_regs_t*)GetECommonO(test->emu, addr, rex, m, delta, offset);
+ test->memsize = 16;
+ ((uint64_t*)test->mem)[0] = ret->q[0];
+ ((uint64_t*)test->mem)[1] = ret->q[1];
+ test->memaddr = (uintptr_t)ret;
+ return (sse_regs_t*)test->mem;
+ }
+}
+
sse_regs_t* GetEx32O(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta, uintptr_t offset)
{
uint8_t m = v&0xC7; // filter Ed
@@ -1368,6 +1734,21 @@ sse_regs_t* GetEx32O(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8
} else return (sse_regs_t*)GetECommon32O(emu, addr, rex, m, delta, offset);
}
+sse_regs_t* TestEx32O(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta, uintptr_t offset)
+{
+ uint8_t m = v&0xC7; // filter Ed
+ if(m>=0xC0) {
+ return &test->emu->xmm[(m&0x07)+(rex.b<<3)];
+ } else {
+ sse_regs_t* ret = (sse_regs_t*)GetECommon32O(test->emu, addr, rex, m, delta, offset);
+ test->memsize = 16;
+ ((uint64_t*)test->mem)[0] = ret->q[0];
+ ((uint64_t*)test->mem)[1] = ret->q[1];
+ test->memaddr = (uintptr_t)ret;
+ return (sse_regs_t*)test->mem;
+ }
+}
+
mmx87_regs_t* GetEm32O(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta, uintptr_t offset)
{
uint8_t m = v&0xC7; // filter Ed
@@ -1376,6 +1757,19 @@ mmx87_regs_t* GetEm32O(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uin
} else return (mmx87_regs_t*)GetECommon32O(emu, addr, rex, m, delta, offset);
}
+mmx87_regs_t* TestEm32O(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta, uintptr_t offset)
+{
+ uint8_t m = v&0xC7; // filter Ed
+ if(m>=0xC0) {
+ return &test->emu->mmx[(m&0x07)];
+ } else {
+ mmx87_regs_t* ret = (mmx87_regs_t*)GetECommon32O(test->emu, addr, rex, m, delta, offset);
+ test->memsize = 8;
+ *(uint64_t*)test->mem = ret->q;
+ test->memaddr = (uintptr_t)ret;
+ return (mmx87_regs_t*)test->mem;
+ }
+}
reg64_t* GetGd(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v)
{
diff --git a/src/emu/x64run_private.h b/src/emu/x64run_private.h
index c4704a7..dcda399 100755..100644
--- a/src/emu/x64run_private.h
+++ b/src/emu/x64run_private.h
@@ -4,34 +4,75 @@
#include <stdint.h>
#include "regs.h"
#include "x64emu_private.h"
+#include "box64context.h"
typedef struct x64emu_s x64emu_t;
-typedef union rex_s {
- uint8_t rex;
- struct {
- unsigned int b:1;
- unsigned int x:1;
- unsigned int r:1;
- unsigned int w:1;
- unsigned int s:4;
+typedef struct rex_s {
+ union {
+ uint8_t rex;
+ struct {
+ unsigned int b:1;
+ unsigned int x:1;
+ unsigned int r:1;
+ unsigned int w:1;
+ unsigned int s:4;
+ };
};
+ int is32bits;
} rex_t;
static inline uint8_t Peek(x64emu_t *emu, int offset){return *(uint8_t*)(R_RIP + offset);}
-static inline uint64_t Pop(x64emu_t *emu)
+#ifdef TEST_INTERPRETER
+#define Push16(E, V) do{E->regs[_SP].q[0] -=2; test->memsize = 2; *(uint16_t*)test->mem = (V); test->memaddr = E->regs[_SP].q[0];}while(0)
+#define Push32(E, V) do{E->regs[_SP].q[0] -=4; test->memsize = 4; *(uint32_t*)test->mem = (V); test->memaddr = E->regs[_SP].q[0];}while(0)
+#define Push64(E, V) do{E->regs[_SP].q[0] -=8; test->memsize = 8; *(uint64_t*)test->mem = (V); test->memaddr = E->regs[_SP].q[0];}while(0)
+#else
+static inline void Push16(x64emu_t *emu, uint16_t v)
{
- uint64_t* st = ((uint64_t*)(R_RSP));
- R_RSP += 8;
- return *st;
+ R_RSP -= 2;
+ *((uint16_t*)R_RSP) = v;
+}
+
+static inline void Push32(x64emu_t *emu, uint32_t v)
+{
+ R_RSP -= 4;
+ *((uint32_t*)R_RSP) = v;
}
-static inline void Push(x64emu_t *emu, uint64_t v)
+static inline void Push64(x64emu_t *emu, uint64_t v)
{
R_RSP -= 8;
*((uint64_t*)R_RSP) = v;
}
+#endif
+
+static inline uint16_t Pop16(x64emu_t *emu)
+{
+ uint16_t* st = (uint16_t*)R_RSP;
+ R_RSP += 2;
+ return *st;
+}
+
+static inline uint32_t Pop32(x64emu_t *emu)
+{
+ uint32_t* st = (uint32_t*)R_RSP;
+ R_RSP += 4;
+ return *st;
+}
+
+static inline uint64_t Pop64(x64emu_t *emu)
+{
+ uint64_t* st = (uint64_t*)R_RSP;
+ R_RSP += 8;
+ return *st;
+}
+static inline void PushExit(x64emu_t* emu)
+{
+ R_RSP -= 8;
+ *((uint64_t*)R_RSP) = my_context->exit_bridge;
+}
// the op code definition can be found here: http://ref.x86asm.net/geek32.html
@@ -39,24 +80,44 @@ reg64_t* GetECommon(x64emu_t* emu, uintptr_t* addr, rex_t rex, uint8_t m, uint8_
reg64_t* GetECommonO(x64emu_t* emu, uintptr_t* addr, rex_t rex, uint8_t m, uint8_t delta, uintptr_t offset);
reg64_t* GetECommon32O(x64emu_t* emu, uintptr_t* addr, rex_t rex, uint8_t m, uint8_t delta, uintptr_t offset);
reg64_t* GetEb(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta);
+reg64_t* TestEb(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta);
reg64_t* GetEbO(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta, uintptr_t offset);
+reg64_t* TestEbO(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta, uintptr_t offset);
reg64_t* GetEd(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta);
+reg64_t* TestEd(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta);
+reg64_t* TestEd4(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta);
+reg64_t* TestEd8(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta);
+reg64_t* TestEd8xw(x64test_t *test, int w, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta);
+reg64_t* TestEdt(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta);
+uintptr_t GetEA(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta);
reg64_t* GetEdO(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta, uintptr_t offset);
+reg64_t* TestEdO(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta, uintptr_t offset);
reg64_t* GetEd32O(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta, uintptr_t offset);
+reg64_t* TestEd32O(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta, uintptr_t offset);
reg64_t* GetEb32O(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta, uintptr_t offset);
+reg64_t* TestEb32O(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta, uintptr_t offset);
#define GetEw GetEd
+#define TestEw TestEd
#define GetEw32O GetEd32O
+#define TestEw32O TestEd32O
reg64_t* GetEw16(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v);
+reg64_t* TestEw16(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v);
reg64_t* GetEw16off(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uintptr_t offset);
+reg64_t* TestEw16off(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uintptr_t offset);
mmx87_regs_t* GetEm(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta);
+mmx87_regs_t* TestEm(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta);
sse_regs_t* GetEx(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta);
+sse_regs_t* TestEx(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta);
sse_regs_t* GetExO(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta, uintptr_t offset);
+sse_regs_t* TestExO(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta, uintptr_t offset);
sse_regs_t* GetEx32O(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta, uintptr_t offset);
+sse_regs_t* TestEx32O(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta, uintptr_t offset);
reg64_t* GetGd(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v);
#define GetGw GetGd
reg64_t* GetGb(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v);
mmx87_regs_t* GetGm(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v);
mmx87_regs_t* GetEm32O(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta, uintptr_t offset);
+mmx87_regs_t* TestEm32O(x64test_t *test, uintptr_t* addr, rex_t rex, uint8_t v, uint8_t delta, uintptr_t offset);
sse_regs_t* GetGx(x64emu_t *emu, uintptr_t* addr, rex_t rex, uint8_t v);
void UpdateFlags(x64emu_t *emu);
@@ -73,6 +134,8 @@ uintptr_t Run66D9(x64emu_t *emu, rex_t rex, uintptr_t addr);
uintptr_t Run66DD(x64emu_t *emu, rex_t rex, uintptr_t addr);
uintptr_t Run66F0(x64emu_t *emu, rex_t rex, uintptr_t addr);
uintptr_t Run67(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr);
+uintptr_t Run67_32(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr);
+uintptr_t Run6764_32(x64emu_t *emu, rex_t rex, int rep, int seg, uintptr_t addr);
uintptr_t Run670F(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr);
uintptr_t Run6766(x64emu_t *emu, rex_t rex, int rep, uintptr_t addr);
uintptr_t Run67660F(x64emu_t *emu, rex_t rex, uintptr_t addr);
@@ -88,9 +151,37 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr);
uintptr_t RunF20F(x64emu_t *emu, rex_t rex, uintptr_t addr, int *step);
uintptr_t RunF30F(x64emu_t *emu, rex_t rex, uintptr_t addr);
+uintptr_t Test0F(x64test_t *test, rex_t rex, uintptr_t addr, int *step);
+uintptr_t Test64(x64test_t *test, rex_t rex, int seg, uintptr_t addr);
+uintptr_t Test66(x64test_t *test, rex_t rex, int rep, uintptr_t addr);
+uintptr_t Test660F(x64test_t *test, rex_t rex, uintptr_t addr);
+uintptr_t Test6664(x64test_t *test, rex_t rex, int seg, uintptr_t addr);
+uintptr_t Test66D9(x64test_t *test, rex_t rex, uintptr_t addr);
+uintptr_t Test66DD(x64test_t *test, rex_t rex, uintptr_t addr);
+uintptr_t Test66F0(x64test_t *test, rex_t rex, uintptr_t addr);
+uintptr_t Test67(x64test_t *test, rex_t rex, int rep, uintptr_t addr);
+uintptr_t Test67_32(x64test_t *test, rex_t rex, int rep, uintptr_t addr);
+uintptr_t Test6764_32(x64test_t *test, rex_t rex, int rep, int seg, uintptr_t addr);
+uintptr_t Test670F(x64test_t *test, rex_t rex, int rep, uintptr_t addr);
+uintptr_t Test6766(x64test_t *test, rex_t rex, int rep, uintptr_t addr);
+uintptr_t Test67660F(x64test_t *test, rex_t rex, uintptr_t addr);
+uintptr_t TestD8(x64test_t *test, rex_t rex, uintptr_t addr);
+uintptr_t TestD9(x64test_t *test, rex_t rex, uintptr_t addr);
+uintptr_t TestDA(x64test_t *test, rex_t rex, uintptr_t addr);
+uintptr_t TestDB(x64test_t *test, rex_t rex, uintptr_t addr);
+uintptr_t TestDC(x64test_t *test, rex_t rex, uintptr_t addr);
+uintptr_t TestDD(x64test_t *test, rex_t rex, uintptr_t addr);
+uintptr_t TestDE(x64test_t *test, rex_t rex, uintptr_t addr);
+uintptr_t TestDF(x64test_t *test, rex_t rex, uintptr_t addr);
+uintptr_t TestF0(x64test_t *test, rex_t rex, uintptr_t addr);
+uintptr_t TestF20F(x64test_t *test, rex_t rex, uintptr_t addr, int *step);
+uintptr_t TestF30F(x64test_t *test, rex_t rex, uintptr_t addr);
+
+
void x64Syscall(x64emu_t *emu);
void x64Int3(x64emu_t* emu, uintptr_t* addr);
x64emu_t* x64emu_fork(x64emu_t* e, int forktype);
+void x86Syscall(x64emu_t *emu); //32bits syscall
uintptr_t GetSegmentBaseEmu(x64emu_t* emu, int seg);
#define GetGSBaseEmu(emu) GetSegmentBaseEmu(emu, _GS)
diff --git a/src/emu/x64rund8.c b/src/emu/x64rund8.c
index 1f851bb..c44ca5b 100644
--- a/src/emu/x64rund8.c
+++ b/src/emu/x64rund8.c
@@ -22,11 +22,18 @@
#include "modrm.h"
+#ifdef TEST_INTERPRETER
+uintptr_t TestD8(x64test_t *test, rex_t rex, uintptr_t addr)
+#else
uintptr_t RunD8(x64emu_t *emu, rex_t rex, uintptr_t addr)
+#endif
{
uint8_t nextop;
float f;
reg64_t *oped;
+ #ifdef TEST_INTERPRETER
+ x64emu_t*emu = test->emu;
+ #endif
nextop = F8;
switch (nextop) {
@@ -115,36 +122,36 @@ uintptr_t RunD8(x64emu_t *emu, rex_t rex, uintptr_t addr)
default:
switch((nextop>>3)&7) {
case 0: /* FADD ST0, float */
- GETED(0);
+ GETE4(0);
ST0.d += *(float*)ED;
break;
case 1: /* FMUL ST0, float */
- GETED(0);
+ GETE4(0);
ST0.d *= *(float*)ED;
break;
case 2: /* FCOM ST0, float */
- GETED(0);
+ GETE4(0);
fpu_fcom(emu, *(float*)ED);
break;
case 3: /* FCOMP */
- GETED(0);
+ GETE4(0);
fpu_fcom(emu, *(float*)ED);
fpu_do_pop(emu);
break;
case 4: /* FSUB ST0, float */
- GETED(0);
+ GETE4(0);
ST0.d -= *(float*)ED;
break;
case 5: /* FSUBR ST0, float */
- GETED(0);
+ GETE4(0);
ST0.d = *(float*)ED - ST0.d;
break;
case 6: /* FDIV ST0, float */
- GETED(0);
+ GETE4(0);
ST0.d /= *(float*)ED;
break;
case 7: /* FDIVR ST0, float */
- GETED(0);
+ GETE4(0);
ST0.d = *(float*)ED / ST0.d;
break;
default:
diff --git a/src/emu/x64rund9.c b/src/emu/x64rund9.c
index e50f5bf..1b097f9 100644
--- a/src/emu/x64rund9.c
+++ b/src/emu/x64rund9.c
@@ -22,13 +22,20 @@
#include "modrm.h"
+#ifdef TEST_INTERPRETER
+uintptr_t TestD9(x64test_t *test, rex_t rex, uintptr_t addr)
+#else
uintptr_t RunD9(x64emu_t *emu, rex_t rex, uintptr_t addr)
+#endif
{
uint8_t nextop;
int32_t tmp32s;
uint64_t ll;
float f;
reg64_t *oped;
+ #ifdef TEST_INTERPRETER
+ x64emu_t*emu = test->emu;
+ #endif
nextop = F8;
switch (nextop) {
@@ -230,22 +237,22 @@ uintptr_t RunD9(x64emu_t *emu, rex_t rex, uintptr_t addr)
default:
switch((nextop>>3)&7) {
case 0: /* FLD ST0, Ed float */
- GETED(0);
+ GETE4(0);
fpu_do_push(emu);
ST0.d = *(float*)ED;
break;
case 2: /* FST Ed, ST0 */
- GETED(0);
+ GETE4(0);
*(float*)ED = ST0.d;
break;
case 3: /* FSTP Ed, ST0 */
- GETED(0);
+ GETE4(0);
*(float*)ED = ST0.d;
fpu_do_pop(emu);
break;
case 4: /* FLDENV m */
// warning, incomplete
- GETED(0);
+ _GETED(0);
fpu_loadenv(emu, (char*)ED, 0);
break;
case 5: /* FLDCW Ew */
@@ -255,8 +262,10 @@ uintptr_t RunD9(x64emu_t *emu, rex_t rex, uintptr_t addr)
break;
case 6: /* FNSTENV m */
// warning, incomplete
- GETED(0);
+ _GETED(0);
+ #ifndef TEST_INTERPRETER
fpu_savenv(emu, (char*)ED, 0);
+ #endif
// intruction pointer: 48bits
// data (operand) pointer: 48bits
// last opcode: 11bits save: 16bits restaured (1st and 2nd opcode only)
diff --git a/src/emu/x64runda.c b/src/emu/x64runda.c
index 8a0f793..bb678a8 100644
--- a/src/emu/x64runda.c
+++ b/src/emu/x64runda.c
@@ -22,10 +22,17 @@
#include "modrm.h"
+#ifdef TEST_INTERPRETER
+uintptr_t TestDA(x64test_t *test, rex_t rex, uintptr_t addr)
+#else
uintptr_t RunDA(x64emu_t *emu, rex_t rex, uintptr_t addr)
+#endif
{
uint8_t nextop;
reg64_t *oped;
+ #ifdef TEST_INTERPRETER
+ x64emu_t*emu = test->emu;
+ #endif
nextop = F8;
switch (nextop) {
@@ -98,36 +105,36 @@ uintptr_t RunDA(x64emu_t *emu, rex_t rex, uintptr_t addr)
default:
switch((nextop>>3)&7) {
case 0: /* FIADD ST0, Ed int */
- GETED(0);
+ GETE4(0);
ST0.d += ED->sdword[0];
break;
case 1: /* FIMUL ST0, Ed int */
- GETED(0);
+ GETE4(0);
ST0.d *= ED->sdword[0];
break;
case 2: /* FICOM ST0, Ed int */
- GETED(0);
+ GETE4(0);
fpu_fcom(emu, ED->sdword[0]);
break;
case 3: /* FICOMP ST0, Ed int */
- GETED(0);
+ GETE4(0);
fpu_fcom(emu, ED->sdword[0]);
fpu_do_pop(emu);
break;
case 4: /* FISUB ST0, Ed int */
- GETED(0);
+ GETE4(0);
ST0.d -= ED->sdword[0];
break;
case 5: /* FISUBR ST0, Ed int */
- GETED(0);
+ GETE4(0);
ST0.d = (double)ED->sdword[0] - ST0.d;
break;
case 6: /* FIDIV ST0, Ed int */
- GETED(0);
+ GETE4(0);
ST0.d /= ED->sdword[0];
break;
case 7: /* FIDIVR ST0, Ed int */
- GETED(0);
+ GETE4(0);
ST0.d = (double)ED->sdword[0] / ST0.d;
break;
}
diff --git a/src/emu/x64rundb.c b/src/emu/x64rundb.c
index 5791b58..ad5952b 100644
--- a/src/emu/x64rundb.c
+++ b/src/emu/x64rundb.c
@@ -22,11 +22,18 @@
#include "modrm.h"
+#ifdef TEST_INTERPRETER
+uintptr_t TestDB(x64test_t *test, rex_t rex, uintptr_t addr)
+#else
uintptr_t RunDB(x64emu_t *emu, rex_t rex, uintptr_t addr)
+#endif
{
uint8_t nextop;
int32_t tmp32s;
reg64_t *oped;
+ #ifdef TEST_INTERPRETER
+ x64emu_t*emu = test->emu;
+ #endif
nextop = F8;
switch(nextop) {
@@ -127,21 +134,21 @@ uintptr_t RunDB(x64emu_t *emu, rex_t rex, uintptr_t addr)
default:
switch((nextop>>3)&7) {
case 0: /* FILD ST0, Ed */
- GETED(0);
+ GETE4(0);
fpu_do_push(emu);
ST0.d = ED->sdword[0];
break;
case 1: /* FISTTP Ed, ST0 */
- GETED(0);
- if(isgreater(ST0.d, (double)(int32_t)0x7fffffff) || isless(ST0.d, (double)(int32_t)0x80000000) || !isfinite(ST0.d))
+ GETE4(0);
+ if(isgreater(ST0.d, (double)0x7fffffff) || isless(ST0.d, -(double)0x80000000U) || !isfinite(ST0.d))
ED->sdword[0] = 0x80000000;
else
ED->sdword[0] = ST0.d;
fpu_do_pop(emu);
break;
case 2: /* FIST Ed, ST0 */
- GETED(0);
- if(isgreater(ST0.d, (double)(int32_t)0x7fffffff) || isless(ST0.d, (double)(int32_t)0x80000000) || !isfinite(ST0.d))
+ GETE4(0);
+ if(isgreater(ST0.d, (double)0x7fffffff) || isless(ST0.d, -(double)0x80000000U) || !isfinite(ST0.d))
ED->sdword[0] = 0x80000000;
else {
volatile int32_t tmp = fpu_round(emu, ST0.d); // tmp to avoid BUS ERROR
@@ -149,8 +156,8 @@ uintptr_t RunDB(x64emu_t *emu, rex_t rex, uintptr_t addr)
}
break;
case 3: /* FISTP Ed, ST0 */
- GETED(0);
- if(isgreater(ST0.d, (double)(int32_t)0x7fffffff) || isless(ST0.d, (double)(int32_t)0x80000000) || !isfinite(ST0.d))
+ GETE4(0);
+ if(isgreater(ST0.d, (double)0x7fffffff) || isless(ST0.d, -(double)0x80000000U) || !isfinite(ST0.d))
ED->sdword[0] = 0x80000000;
else {
volatile int32_t tmp = fpu_round(emu, ST0.d); // tmp to avoid BUS ERROR
@@ -159,14 +166,14 @@ uintptr_t RunDB(x64emu_t *emu, rex_t rex, uintptr_t addr)
fpu_do_pop(emu);
break;
case 5: /* FLD ST0, Et */
- GETED(0);
+ GETET(0);
fpu_do_push(emu);
memcpy(&STld(0).ld, ED, 10);
LD2D(&STld(0), &ST(0).d);
STld(0).uref = ST0.q;
break;
case 7: /* FSTP tbyte */
- GETED(0);
+ GETET(0);
if(ST0.q!=STld(0).uref)
D2LD(&ST0.d, ED);
else
diff --git a/src/emu/x64rundc.c b/src/emu/x64rundc.c
index dbe4d45..0893113 100644
--- a/src/emu/x64rundc.c
+++ b/src/emu/x64rundc.c
@@ -22,10 +22,17 @@
#include "modrm.h"
+#ifdef TEST_INTERPRETER
+uintptr_t TestDC(x64test_t *test, rex_t rex, uintptr_t addr)
+#else
uintptr_t RunDC(x64emu_t *emu, rex_t rex, uintptr_t addr)
+#endif
{
uint8_t nextop;
reg64_t *oped;
+ #ifdef TEST_INTERPRETER
+ x64emu_t*emu = test->emu;
+ #endif
nextop = F8;
switch(nextop) {
@@ -111,7 +118,7 @@ uintptr_t RunDC(x64emu_t *emu, rex_t rex, uintptr_t addr)
ST(nextop&7).d /= ST0.d;
break;
default:
- GETED(0);
+ GETE8(0);
switch((nextop>>3)&7) {
case 0: /* FADD ST0, double */
ST0.d += *(double*)ED;
diff --git a/src/emu/x64rundd.c b/src/emu/x64rundd.c
index abb18f7..fc65f01 100644
--- a/src/emu/x64rundd.c
+++ b/src/emu/x64rundd.c
@@ -22,10 +22,17 @@
#include "modrm.h"
+#ifdef TEST_INTERPRETER
+uintptr_t TestDD(x64test_t *test, rex_t rex, uintptr_t addr)
+#else
uintptr_t RunDD(x64emu_t *emu, rex_t rex, uintptr_t addr)
+#endif
{
uint8_t nextop;
reg64_t *oped;
+ #ifdef TEST_INTERPRETER
+ x64emu_t*emu = test->emu;
+ #endif
nextop = F8;
switch (nextop) {
@@ -112,26 +119,33 @@ uintptr_t RunDD(x64emu_t *emu, rex_t rex, uintptr_t addr)
default:
switch((nextop>>3)&7) {
case 0: /* FLD double */
- GETED(0);
+ GETE8(0);
fpu_do_push(emu);
ST0.d = *(double*)ED;
break;
case 1: /* FISTTP ED qword */
- GETED(0);
- *(int64_t*)ED = ST0.d;
+ GETE8(0);
+ if(STll(0).sref==ST(0).sq)
+ ED->sq[0] = STll(0).sq;
+ else {
+ if(isgreater(ST0.d, (double)0x7fffffffffffffffLL) || isless(ST0.d, -(double)0x8000000000000000LL) || !isfinite(ST0.d))
+ *(uint64_t*)ED = 0x8000000000000000LL;
+ else
+ *(int64_t*)ED = ST0.d;
+ }
fpu_do_pop(emu);
break;
case 2: /* FST double */
- GETED(0);
+ GETE8(0);
*(double*)ED = ST0.d;
break;
case 3: /* FSTP double */
- GETED(0);
+ GETE8(0);
*(double*)ED = ST0.d;
fpu_do_pop(emu);
break;
case 4: /* FRSTOR m108byte */
- GETED(0);
+ _GETED(0);
fpu_loadenv(emu, (char*)ED, 0);
// get the STx
{
@@ -144,9 +158,10 @@ uintptr_t RunDD(x64emu_t *emu, rex_t rex, uintptr_t addr)
}
break;
case 6: /* FNSAVE m108byte */
- GETED(0);
+ _GETED(0);
// ENV first...
// warning, incomplete
+ #ifndef TEST_INTERPRETER
fpu_savenv(emu, (char*)ED, 0);
// save the STx
{
@@ -157,10 +172,11 @@ uintptr_t RunDD(x64emu_t *emu, rex_t rex, uintptr_t addr)
p+=10;
}
}
+ #endif
reset_fpu(emu);
break;
case 7: /* FNSTSW m2byte */
- GETED(0);
+ GETEW(0);
emu->sw.f.F87_TOP = emu->top&7;
*(uint16_t*)ED = emu->sw.x16;
break;
diff --git a/src/emu/x64runde.c b/src/emu/x64runde.c
index 4911be3..4ec5828 100644
--- a/src/emu/x64runde.c
+++ b/src/emu/x64runde.c
@@ -22,10 +22,17 @@
#include "modrm.h"
+#ifdef TEST_INTERPRETER
+uintptr_t TestDE(x64test_t *test, rex_t rex, uintptr_t addr)
+#else
uintptr_t RunDE(x64emu_t *emu, rex_t rex, uintptr_t addr)
+#endif
{
uint8_t nextop;
reg64_t *oped;
+ #ifdef TEST_INTERPRETER
+ x64emu_t*emu = test->emu;
+ #endif
nextop = F8;
switch(nextop) {
diff --git a/src/emu/x64rundf.c b/src/emu/x64rundf.c
index 657c1a4..d707863 100644
--- a/src/emu/x64rundf.c
+++ b/src/emu/x64rundf.c
@@ -22,12 +22,19 @@
#include "modrm.h"
+#ifdef TEST_INTERPRETER
+uintptr_t TestDF(x64test_t *test, rex_t rex, uintptr_t addr)
+#else
uintptr_t RunDF(x64emu_t *emu, rex_t rex, uintptr_t addr)
+#endif
{
uint8_t nextop;
int16_t tmp16s;
int64_t tmp64s;
reg64_t *oped;
+ #ifdef TEST_INTERPRETER
+ x64emu_t*emu = test->emu;
+ #endif
nextop = F8;
switch(nextop) {
@@ -124,7 +131,10 @@ uintptr_t RunDF(x64emu_t *emu, rex_t rex, uintptr_t addr)
case 1: /* FISTTP Ew, ST0 */
GETEW(0);
tmp16s = ST0.d;
- EW->sword[0] = tmp16s;
+ if(isgreater(ST0.d, (double)(int32_t)0x7fff) || isless(ST0.d, -(double)(int32_t)0x8000) || !isfinite(ST0.d))
+ EW->sword[0] = 0x8000;
+ else
+ EW->sword[0] = tmp16s;
fpu_do_pop(emu);
break;
case 2: /* FIST Ew, ST0 */
@@ -143,12 +153,12 @@ uintptr_t RunDF(x64emu_t *emu, rex_t rex, uintptr_t addr)
fpu_do_pop(emu);
break;
case 4: /* FBLD ST0, tbytes */
- GETED(0);
+ GETET(0);
fpu_do_push(emu);
fpu_fbld(emu, (uint8_t*)ED);
break;
case 5: /* FILD ST0, Gq */
- GETED(0);
+ GETE8(0);
tmp64s = ED->sq[0];
fpu_do_push(emu);
ST0.d = tmp64s;
@@ -156,16 +166,16 @@ uintptr_t RunDF(x64emu_t *emu, rex_t rex, uintptr_t addr)
STll(0).sref = ST0.sq;
break;
case 6: /* FBSTP tbytes, ST0 */
- GETED(0);
+ GETET(0);
fpu_fbst(emu, (uint8_t*)ED);
fpu_do_pop(emu);
break;
case 7: /* FISTP i64 */
- GETED(0);
+ GETE8(0);
if(STll(0).sref==ST(0).sq)
ED->sq[0] = STll(0).sq;
else {
- if(isgreater(ST0.d, (double)(int64_t)0x7fffffffffffffffLL) || isless(ST0.d, (double)(int64_t)0x8000000000000000LL) || !isfinite(ST0.d))
+ if(isgreater(ST0.d, (double)0x7fffffffffffffffLL) || isless(ST0.d, -(double)0x8000000000000000LL) || !isfinite(ST0.d))
ED->sq[0] = 0x8000000000000000LL;
else
ED->sq[0] = fpu_round(emu, ST0.d);
diff --git a/src/emu/x64runf0.c b/src/emu/x64runf0.c
index 13eed9a..e1dbace 100644
--- a/src/emu/x64runf0.c
+++ b/src/emu/x64runf0.c
@@ -26,7 +26,11 @@
#include "modrm.h"
+#ifdef TEST_INTERPRETER
+uintptr_t TestF0(x64test_t *test, rex_t rex, uintptr_t addr)
+#else
uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
+#endif
{
uint8_t opcode;
uint8_t nextop;
@@ -36,17 +40,24 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
int64_t tmp64s;
uint64_t tmp64u, tmp64u2;
reg64_t *oped, *opgd;
+ #ifdef USE_CAS
+ uint64_t tmpcas;
+ #endif
+ #ifdef TEST_INTERPRETER
+ x64emu_t*emu = test->emu;
+ #endif
opcode = F8;
// REX prefix before the F0 are ignored
rex.rex = 0;
- while(opcode>=0x40 && opcode<=0x4f) {
- rex.rex = opcode;
- opcode = F8;
- }
+ if(!rex.is32bits)
+ while(opcode>=0x40 && opcode<=0x4f) {
+ rex.rex = opcode;
+ opcode = F8;
+ }
switch(opcode) {
-#ifdef DYNAREC
+#if defined(DYNAREC) && !defined(TEST_INTERPRETER)
#define GO(B, OP) \
case B+0: \
nextop = F8; \
@@ -105,15 +116,15 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
nextop = F8; \
GETEB(0); \
GETGB; \
- pthread_mutex_lock(&emu->context->mutex_lock); \
+ pthread_mutex_lock(&my_context->mutex_lock); \
EB->byte[0] = OP##8(emu, EB->byte[0], GB); \
- pthread_mutex_unlock(&emu->context->mutex_lock); \
+ pthread_mutex_unlock(&my_context->mutex_lock); \
break; \
case B+1: \
nextop = F8; \
GETED(0); \
GETGD; \
- pthread_mutex_lock(&emu->context->mutex_lock); \
+ pthread_mutex_lock(&my_context->mutex_lock); \
if(rex.w) \
ED->q[0] = OP##64(emu, ED->q[0], GD->q[0]); \
else \
@@ -121,39 +132,39 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
ED->q[0] = OP##32(emu, ED->dword[0], GD->dword[0]); \
else \
ED->dword[0] = OP##32(emu, ED->dword[0], GD->dword[0]); \
- pthread_mutex_unlock(&emu->context->mutex_lock); \
+ pthread_mutex_unlock(&my_context->mutex_lock); \
break; \
case B+2: \
nextop = F8; \
GETEB(0); \
GETGB; \
- pthread_mutex_lock(&emu->context->mutex_lock); \
+ pthread_mutex_lock(&my_context->mutex_lock); \
GB = OP##8(emu, GB, EB->byte[0]); \
- pthread_mutex_unlock(&emu->context->mutex_lock); \
+ pthread_mutex_unlock(&my_context->mutex_lock); \
break; \
case B+3: \
nextop = F8; \
GETED(0); \
GETGD; \
- pthread_mutex_lock(&emu->context->mutex_lock); \
+ pthread_mutex_lock(&my_context->mutex_lock); \
if(rex.w) \
GD->q[0] = OP##64(emu, GD->q[0], ED->q[0]); \
else \
GD->q[0] = OP##32(emu, GD->dword[0], ED->dword[0]); \
- pthread_mutex_unlock(&emu->context->mutex_lock); \
+ pthread_mutex_unlock(&my_context->mutex_lock); \
break; \
case B+4: \
- pthread_mutex_lock(&emu->context->mutex_lock); \
+ pthread_mutex_lock(&my_context->mutex_lock); \
R_AL = OP##8(emu, R_AL, F8); \
- pthread_mutex_unlock(&emu->context->mutex_lock); \
+ pthread_mutex_unlock(&my_context->mutex_lock); \
break; \
case B+5: \
- pthread_mutex_lock(&emu->context->mutex_lock); \
+ pthread_mutex_lock(&my_context->mutex_lock); \
if(rex.w) \
R_RAX = OP##64(emu, R_RAX, F32S64); \
else \
R_RAX = OP##32(emu, R_EAX, F32); \
- pthread_mutex_unlock(&emu->context->mutex_lock); \
+ pthread_mutex_unlock(&my_context->mutex_lock); \
break;
#endif
GO(0x00, add) /* ADD 0x00 -> 0x05 */
@@ -178,9 +189,17 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
tmp64s >>= (rex.w?6:5);
if(!MODREG)
{
+ #ifdef TEST_INTERPRETER
+ test->memaddr=((test->memaddr)+(tmp32s<<(rex.w?3:2)));
+ if(rex.w)
+ *(uint64_t*)test->mem = *(uint64_t*)test->memaddr;
+ else
+ *(uint32_t*)test->mem = *(uint32_t*)test->memaddr;
+ #else
ED=(reg64_t*)(((uintptr_t)(ED))+(tmp64s<<(rex.w?3:2)));
+ #endif
}
-#ifdef DYNAREC
+#if defined(DYNAREC) && !defined(TEST_INTERPRETER)
if(rex.w) {
tmp8u&=63;
if(MODREG) {
@@ -226,7 +245,7 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
} while(tmp32s);
}
#else
- pthread_mutex_lock(&emu->context->mutex_lock);
+ pthread_mutex_lock(&my_context->mutex_lock);
if(rex.w) {
tmp8u&=63;
if(ED->q[0] & (1LL<<tmp8u))
@@ -246,7 +265,7 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
if(MODREG)
ED->dword[1] = 0;
}
- pthread_mutex_unlock(&emu->context->mutex_lock);
+ pthread_mutex_unlock(&my_context->mutex_lock);
#endif
break;
@@ -255,7 +274,7 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
nextop = F8;
GETGB;
GETEB(0);
-#ifdef DYNAREC
+#if defined(DYNAREC) && !defined(TEST_INTERPRETER)
do {
tmp8u = native_lock_read_b(EB);
cmp8(emu, R_AL, tmp8u);
@@ -267,21 +286,21 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
}
} while(tmp32s);
#else
- pthread_mutex_lock(&emu->context->mutex_lock);
+ pthread_mutex_lock(&my_context->mutex_lock);
cmp8(emu, R_AL, EB->byte[0]);
if(ACCESS_FLAG(F_ZF)) {
EB->byte[0] = GB;
} else {
R_AL = EB->byte[0];
}
- pthread_mutex_unlock(&emu->context->mutex_lock);
+ pthread_mutex_unlock(&my_context->mutex_lock);
#endif
break;
case 0xB1: /* CMPXCHG Ed,Gd */
nextop = F8;
GETED(0);
GETGD;
-#ifdef DYNAREC
+#if defined(DYNAREC) && !defined(TEST_INTERPRETER)
if(rex.w)
if(((uintptr_t)ED)&7) {
do {
@@ -324,7 +343,7 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
ED->dword[1] = 0;
}
#else
- pthread_mutex_lock(&emu->context->mutex_lock);
+ pthread_mutex_lock(&my_context->mutex_lock);
if(rex.w) {
cmp64(emu, R_RAX, ED->q[0]);
if(ACCESS_FLAG(F_ZF)) {
@@ -343,7 +362,7 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
if(MODREG)
ED->dword[1] = 0;
}
- pthread_mutex_unlock(&emu->context->mutex_lock);
+ pthread_mutex_unlock(&my_context->mutex_lock);
#endif
break;
@@ -357,10 +376,18 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
tmp64s >>= (rex.w?6:5);
if(!MODREG)
{
+ #ifdef TEST_INTERPRETER
+ test->memaddr=((test->memaddr)+(tmp32s<<(rex.w?3:2)));
+ if(rex.w)
+ *(uint64_t*)test->mem = *(uint64_t*)test->memaddr;
+ else
+ *(uint32_t*)test->mem = *(uint32_t*)test->memaddr;
+ #else
ED=(reg64_t*)(((uintptr_t)(ED))+(tmp64s<<(rex.w?3:2)));
+ #endif
}
tmp8u&=rex.w?63:31;
-#ifdef DYNAREC
+#if defined(DYNAREC) && !defined(TEST_INTERPRETER)
if(rex.w)
do {
tmp64u = native_lock_read_dd(ED);
@@ -389,7 +416,7 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
ED->dword[1] = 0;
}
#else
- pthread_mutex_lock(&emu->context->mutex_lock);
+ pthread_mutex_lock(&my_context->mutex_lock);
if(rex.w) {
if(ED->q[0] & (1<<tmp8u)) {
SET_FLAG(F_CF);
@@ -405,7 +432,7 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
if(MODREG)
ED->dword[1] = 0;
}
- pthread_mutex_unlock(&emu->context->mutex_lock);
+ pthread_mutex_unlock(&my_context->mutex_lock);
#endif
break;
@@ -434,7 +461,7 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
CHECK_FLAGS(emu);
GETED(1);
tmp8u = F8;
-#ifdef DYNAREC
+#if defined(DYNAREC) && !defined(TEST_INTERPRETER)
if(rex.w) {
tmp8u&=63;
do {
@@ -463,7 +490,7 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
} while(tmp32s);
}
#else
- pthread_mutex_lock(&emu->context->mutex_lock);
+ pthread_mutex_lock(&my_context->mutex_lock);
if(rex.w) {
tmp8u&=63;
if(ED->q[0] & (1LL<<tmp8u)) {
@@ -481,14 +508,14 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
CLEAR_FLAG(F_CF);
}
}
- pthread_mutex_unlock(&emu->context->mutex_lock);
+ pthread_mutex_unlock(&my_context->mutex_lock);
#endif
break;
case 6: /* BTR Ed, Ib */
CHECK_FLAGS(emu);
GETED(1);
tmp8u = F8;
-#ifdef DYNAREC
+#if defined(DYNAREC) && !defined(TEST_INTERPRETER)
if(rex.w) {
do {
tmp8u&=63;
@@ -517,7 +544,7 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
} while(tmp32s);
}
#else
- pthread_mutex_lock(&emu->context->mutex_lock);
+ pthread_mutex_lock(&my_context->mutex_lock);
if(rex.w) {
tmp8u&=63;
if(ED->q[0] & (1LL<<tmp8u)) {
@@ -533,14 +560,14 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
} else
CLEAR_FLAG(F_CF);
}
- pthread_mutex_unlock(&emu->context->mutex_lock);
+ pthread_mutex_unlock(&my_context->mutex_lock);
#endif
break;
case 7: /* BTC Ed, Ib */
CHECK_FLAGS(emu);
GETED(1);
tmp8u = F8;
-#ifdef DYNAREC
+#if defined(DYNAREC) && !defined(TEST_INTERPRETER)
if(rex.w) {
tmp8u&=63;
do {
@@ -565,7 +592,7 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
} while(tmp32s);
}
#else
- pthread_mutex_lock(&emu->context->mutex_lock);
+ pthread_mutex_lock(&my_context->mutex_lock);
if(rex.w) {
tmp8u&=63;
if(ED->q[0] & (1LL<<tmp8u))
@@ -581,7 +608,7 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
CLEAR_FLAG(F_CF);
ED->dword[0] ^= (1<<tmp8u);
}
- pthread_mutex_unlock(&emu->context->mutex_lock);
+ pthread_mutex_unlock(&my_context->mutex_lock);
#endif
break;
@@ -594,25 +621,25 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
nextop = F8;
GETEB(0);
GETGB;
-#ifdef DYNAREC
+#if defined(DYNAREC) && !defined(TEST_INTERPRETER)
do {
tmp8u = native_lock_read_b(EB);
tmp8u2 = add8(emu, tmp8u, GB);
} while(native_lock_write_b(EB, tmp8u2));
GB = tmp8u;
#else
- pthread_mutex_lock(&emu->context->mutex_lock);
+ pthread_mutex_lock(&my_context->mutex_lock);
tmp8u = add8(emu, EB->byte[0], GB);
GB = EB->byte[0];
EB->byte[0] = tmp8u;
- pthread_mutex_unlock(&emu->context->mutex_lock);
+ pthread_mutex_unlock(&my_context->mutex_lock);
#endif
break;
case 0xC1: /* XADD Gd,Ed */
nextop = F8;
GETED(0);
GETGD;
-#ifdef DYNAREC
+#if defined(DYNAREC) && !defined(TEST_INTERPRETER)
if(rex.w) {
do {
tmp64u = native_lock_read_dd(ED);
@@ -638,7 +665,7 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
ED->dword[1] = 0;
}
#else
- pthread_mutex_lock(&emu->context->mutex_lock);
+ pthread_mutex_lock(&my_context->mutex_lock);
if(rex.w) {
tmp64u = add64(emu, ED->q[0], GD->q[0]);
GD->q[0] = ED->q[0];
@@ -651,18 +678,18 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
else
ED->dword[0] = tmp32u;
}
- pthread_mutex_unlock(&emu->context->mutex_lock);
+ pthread_mutex_unlock(&my_context->mutex_lock);
#endif
break;
case 0xC7: /* CMPXCHG8B Gq */
nextop = F8;
- GETED(0);
+ GETE8xw(0);
switch((nextop>>3)&7) {
case 1:
CHECK_FLAGS(emu);
GETGD;
-#ifdef DYNAREC
+#if defined(DYNAREC) && !defined(TEST_INTERPRETER)
if(rex.w)
do {
native_lock_read_dq(&tmp64u, &tmp64u2, ED);
@@ -690,8 +717,11 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
}
} while(tmp32s);
#else
- pthread_mutex_lock(&emu->context->mutex_lock);
+ pthread_mutex_lock(&my_context->mutex_lock);
if(rex.w) {
+ #ifdef TEST_INTERPRETER
+ test->memsize = 16;
+ #endif
tmp64u = ED->q[0];
tmp64u2= ED->q[1];
if(R_RAX == tmp64u && R_RDX == tmp64u2) {
@@ -704,6 +734,9 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
R_RDX = tmp64u2;
}
} else {
+ #ifdef TEST_INTERPRETER
+ test->memsize = 8;
+ #endif
tmp32u = ED->dword[0];
tmp32u2= ED->dword[1];
if(R_EAX == tmp32u && R_EDX == tmp32u2) {
@@ -716,7 +749,7 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
R_RDX = tmp32u2;
}
}
- pthread_mutex_unlock(&emu->context->mutex_lock);
+ pthread_mutex_unlock(&my_context->mutex_lock);
#endif
break;
default:
@@ -730,13 +763,17 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
break;
case 0x66:
+ #ifdef TEST_INTERPRETER
+ return Test66F0(test, rex, addr);
+ #else
return Run66F0(emu, rex, addr); // more opcode F0 66 and 66 F0 is the same
+ #endif
case 0x80: /* GRP Eb,Ib */
nextop = F8;
GETEB(1);
tmp8u = F8;
-#ifdef DYNAREC
+#if defined(DYNAREC) && !defined(TEST_INTERPRETER)
switch((nextop>>3)&7) {
case 0: do { tmp8u2 = native_lock_read_b(EB); tmp8u2 = add8(emu, tmp8u2, tmp8u);} while(native_lock_write_b(EB, tmp8u2)); break;
case 1: do { tmp8u2 = native_lock_read_b(EB); tmp8u2 = or8(emu, tmp8u2, tmp8u);} while(native_lock_write_b(EB, tmp8u2)); break;
@@ -748,7 +785,7 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
case 7: cmp8(emu, EB->byte[0], tmp8u); break;
}
#else
- pthread_mutex_lock(&emu->context->mutex_lock);
+ pthread_mutex_lock(&my_context->mutex_lock);
switch((nextop>>3)&7) {
case 0: EB->byte[0] = add8(emu, EB->byte[0], tmp8u); break;
case 1: EB->byte[0] = or8(emu, EB->byte[0], tmp8u); break;
@@ -759,7 +796,7 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
case 6: EB->byte[0] = xor8(emu, EB->byte[0], tmp8u); break;
case 7: cmp8(emu, EB->byte[0], tmp8u); break;
}
- pthread_mutex_unlock(&emu->context->mutex_lock);
+ pthread_mutex_unlock(&my_context->mutex_lock);
#endif
break;
case 0x81: /* GRP Ed,Id */
@@ -771,7 +808,7 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
tmp64u = (uint64_t)tmp64s;
} else
tmp64u = F32S64;
-#ifdef DYNAREC
+#if defined(DYNAREC) && !defined(TEST_INTERPRETER)
if(rex.w) {
switch((nextop>>3)&7) {
case 0: do { tmp64u2 = native_lock_read_dd(ED); tmp64u2 = add64(emu, tmp64u2, tmp64u);} while(native_lock_write_dd(ED, tmp64u2)); break;
@@ -808,7 +845,7 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
}
}
#else
- pthread_mutex_lock(&emu->context->mutex_lock);
+ pthread_mutex_lock(&my_context->mutex_lock);
if(rex.w) {
switch((nextop>>3)&7) {
case 0: ED->q[0] = add64(emu, ED->q[0], tmp64u); break;
@@ -844,13 +881,13 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
case 7: cmp32(emu, ED->dword[0], tmp64u); break;
}
}
- pthread_mutex_unlock(&emu->context->mutex_lock);
+ pthread_mutex_unlock(&my_context->mutex_lock);
#endif
break;
case 0x86: /* XCHG Eb,Gb */
nextop = F8;
-#ifdef DYNAREC
+#if defined(DYNAREC) && !defined(TEST_INTERPRETER)
GETEB(0);
GETGB;
if(MODREG) { // reg / reg: no lock
@@ -867,17 +904,17 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
GETEB(0);
GETGB;
if(!MODREG)
- pthread_mutex_lock(&emu->context->mutex_lock); // XCHG always LOCK (but when accessing memory only)
+ pthread_mutex_lock(&my_context->mutex_lock); // XCHG always LOCK (but when accessing memory only)
tmp8u = GB;
GB = EB->byte[0];
EB->byte[0] = tmp8u;
if(!MODREG)
- pthread_mutex_unlock(&emu->context->mutex_lock);
+ pthread_mutex_unlock(&my_context->mutex_lock);
#endif
break;
case 0x87: /* XCHG Ed,Gd */
nextop = F8;
-#ifdef DYNAREC
+#if defined(DYNAREC) && !defined(TEST_INTERPRETER)
GETED(0);
GETGD;
if(MODREG) {
@@ -892,7 +929,7 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
}
} else {
if(rex.w) {
- GD->q[0] = native_lock_xchg(ED, GD->q[0]);
+ GD->q[0] = native_lock_xchg_dd(ED, GD->q[0]);
} else {
GD->dword[0] = native_lock_xchg_d(ED, GD->dword[0]);
}
@@ -900,7 +937,7 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
#else
GETED(0);
GETGD;
- pthread_mutex_lock(&emu->context->mutex_lock);
+ pthread_mutex_lock(&my_context->mutex_lock);
if(rex.w) {
tmp64u = GD->q[0];
GD->q[0] = ED->q[0];
@@ -913,7 +950,7 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
else
ED->dword[0] = tmp32u;
}
- pthread_mutex_unlock(&emu->context->mutex_lock);
+ pthread_mutex_unlock(&my_context->mutex_lock);
#endif
break;
@@ -923,15 +960,15 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
GETEB((tmp8u<2)?1:0);
switch(tmp8u) {
case 2: /* NOT Eb */
-#ifdef DYNAREC
+#if defined(DYNAREC) && !defined(TEST_INTERPRETER)
do {
tmp8u2 = native_lock_read_b(EB);
tmp8u2 = not8(emu, tmp8u2);
} while(native_lock_write_b(EB, tmp8u2));
#else
- pthread_mutex_lock(&emu->context->mutex_lock);
+ pthread_mutex_lock(&my_context->mutex_lock);
EB->byte[0] = not8(emu, EB->byte[0]);
- pthread_mutex_unlock(&emu->context->mutex_lock);
+ pthread_mutex_unlock(&my_context->mutex_lock);
#endif
break;
default:
@@ -944,25 +981,25 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
GETED(0);
switch((nextop>>3)&7) {
case 0: /* INC Eb */
-#ifdef DYNAREC
+#if defined(DYNAREC) && !defined(TEST_INTERPRETER)
do {
tmp8u = native_lock_read_b(ED);
} while(native_lock_write_b(ED, inc8(emu, tmp8u)));
#else
- pthread_mutex_lock(&emu->context->mutex_lock);
+ pthread_mutex_lock(&my_context->mutex_lock);
ED->byte[0] = inc8(emu, ED->byte[0]);
- pthread_mutex_unlock(&emu->context->mutex_lock);
+ pthread_mutex_unlock(&my_context->mutex_lock);
#endif
break;
case 1: /* DEC Ed */
-#ifdef DYNAREC
+#if defined(DYNAREC) && !defined(TEST_INTERPRETER)
do {
tmp8u = native_lock_read_b(ED);
} while(native_lock_write_b(ED, dec8(emu, tmp8u)));
#else
- pthread_mutex_lock(&emu->context->mutex_lock);
+ pthread_mutex_lock(&my_context->mutex_lock);
ED->byte[0] = dec8(emu, ED->byte[0]);
- pthread_mutex_unlock(&emu->context->mutex_lock);
+ pthread_mutex_unlock(&my_context->mutex_lock);
#endif
break;
default:
@@ -977,7 +1014,7 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
GETED(0);
switch((nextop>>3)&7) {
case 0: /* INC Ed */
-#ifdef DYNAREC
+#if defined(DYNAREC) && !defined(TEST_INTERPRETER)
if(rex.w)
if(((uintptr_t)ED)&7) {
// unaligned
@@ -1010,7 +1047,7 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
if(MODREG) ED->dword[1] = 0;
}
#else
- pthread_mutex_lock(&emu->context->mutex_lock);
+ pthread_mutex_lock(&my_context->mutex_lock);
if(rex.w) {
ED->q[0] = inc64(emu, ED->q[0]);
} else {
@@ -1019,11 +1056,11 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
else
ED->dword[0] = inc32(emu, ED->dword[0]);
}
- pthread_mutex_unlock(&emu->context->mutex_lock);
+ pthread_mutex_unlock(&my_context->mutex_lock);
#endif
break;
case 1: /* DEC Ed */
-#ifdef DYNAREC
+#if defined(DYNAREC) && !defined(TEST_INTERPRETER)
if(rex.w)
if(((uintptr_t)ED)&7) {
// unaligned
@@ -1045,7 +1082,7 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
if(MODREG) ED->dword[1] = 0;
}
#else
- pthread_mutex_lock(&emu->context->mutex_lock);
+ pthread_mutex_lock(&my_context->mutex_lock);
if(rex.w) {
ED->q[0] = dec64(emu, ED->q[0]);
} else {
@@ -1054,7 +1091,7 @@ uintptr_t RunF0(x64emu_t *emu, rex_t rex, uintptr_t addr)
else
ED->dword[0] = dec32(emu, ED->dword[0]);
}
- pthread_mutex_unlock(&emu->context->mutex_lock);
+ pthread_mutex_unlock(&my_context->mutex_lock);
#endif
break;
default:
diff --git a/src/emu/x64runf20f.c b/src/emu/x64runf20f.c
index a2c0e8e..3375031 100644
--- a/src/emu/x64runf20f.c
+++ b/src/emu/x64runf20f.c
@@ -22,19 +22,27 @@
#include "modrm.h"
+#ifdef TEST_INTERPRETER
+uintptr_t TestF20F(x64test_t *test, rex_t rex, uintptr_t addr, int *step)
+#else
uintptr_t RunF20F(x64emu_t *emu, rex_t rex, uintptr_t addr, int *step)
+#endif
{
uint8_t opcode;
uint8_t nextop;
int8_t tmp8s;
uint8_t tmp8u;
int32_t tmp32s;
+ int64_t tmp64s0, tmp64s1;
reg64_t *oped, *opgd;
sse_regs_t *opex, *opgx, eax1;
mmx87_regs_t *opgm;
#ifndef NOALIGN
int is_nan;
#endif
+ #ifdef TEST_INTERPRETER
+ x64emu_t*emu = test->emu;
+ #endif
opcode = F8;
@@ -197,6 +205,8 @@ uintptr_t RunF20F(x64emu_t *emu, rex_t rex, uintptr_t addr, int *step)
nextop = F8;
GETEX(0);
GETGX;
+ if (GX->d[0] == 0.0 && EX->d[0] == 0.0)
+ GX->d[0] = EX->d[0];
if (isnan(GX->d[0]) || isnan(EX->d[0]) || isless(EX->d[0], GX->d[0]))
GX->d[0] = EX->d[0];
break;
@@ -217,6 +227,8 @@ uintptr_t RunF20F(x64emu_t *emu, rex_t rex, uintptr_t addr, int *step)
nextop = F8;
GETEX(0);
GETGX;
+ if (GX->d[0] == 0.0 && EX->d[0] == 0.0)
+ GX->d[0] = EX->d[0];
if (isnan(GX->d[0]) || isnan(EX->d[0]) || isgreater(EX->d[0], GX->d[0]))
GX->d[0] = EX->d[0];
break;
@@ -314,22 +326,33 @@ uintptr_t RunF20F(x64emu_t *emu, rex_t rex, uintptr_t addr, int *step)
GETGX;
switch(emu->mxcsr.f.MXCSR_RC) {
case ROUND_Nearest:
- GX->sd[0] = nearbyint(EX->d[0]);
- GX->sd[1] = nearbyint(EX->d[1]);
+ tmp64s0 = nearbyint(EX->d[0]);
+ tmp64s1 = nearbyint(EX->d[1]);
break;
case ROUND_Down:
- GX->sd[0] = floor(EX->d[0]);
- GX->sd[1] = floor(EX->d[1]);
+ tmp64s0 = floor(EX->d[0]);
+ tmp64s1 = floor(EX->d[1]);
break;
case ROUND_Up:
- GX->sd[0] = ceil(EX->d[0]);
- GX->sd[1] = ceil(EX->d[1]);
+ tmp64s0 = ceil(EX->d[0]);
+ tmp64s1 = ceil(EX->d[1]);
break;
case ROUND_Chop:
- GX->sd[0] = EX->d[0];
- GX->sd[1] = EX->d[1];
+ tmp64s0 = EX->d[0];
+ tmp64s1 = EX->d[1];
break;
}
+ if (tmp64s0==(int32_t)tmp64s0 && !isnan(EX->d[0])) {
+ GX->sd[0] = (int32_t)tmp64s0;
+ } else {
+ GX->sd[0] = INT32_MIN;
+ }
+ if (tmp64s1==(int32_t)tmp64s1 && !isnan(EX->d[1])) {
+ GX->sd[1] = (int32_t)tmp64s1;
+ } else {
+ GX->sd[1] = INT32_MIN;
+ }
+
GX->q[1] = 0;
break;
@@ -344,4 +367,4 @@ uintptr_t RunF20F(x64emu_t *emu, rex_t rex, uintptr_t addr, int *step)
return 0;
}
return addr;
-} \ No newline at end of file
+}
diff --git a/src/emu/x64runf30f.c b/src/emu/x64runf30f.c
index acfd789..d5b70b2 100644
--- a/src/emu/x64runf30f.c
+++ b/src/emu/x64runf30f.c
@@ -22,17 +22,25 @@
#include "modrm.h"
+#ifdef TEST_INTERPRETER
+uintptr_t TestF30F(x64test_t *test, rex_t rex, uintptr_t addr)
+#else
uintptr_t RunF30F(x64emu_t *emu, rex_t rex, uintptr_t addr)
+#endif
{
uint8_t opcode;
uint8_t nextop;
int8_t tmp8s;
uint8_t tmp8u;
uint32_t tmp32u;
+ int64_t tmp64s;
uint64_t tmp64u;
reg64_t *oped, *opgd;
sse_regs_t *opex, *opgx, eax1;
mmx87_regs_t *opem;
+ #ifdef TEST_INTERPRETER
+ x64emu_t*emu = test->emu;
+ #endif
opcode = F8;
@@ -89,12 +97,12 @@ uintptr_t RunF30F(x64emu_t *emu, rex_t rex, uintptr_t addr)
nextop = F8;
GETEX(0);
GETGD;
- if (rex.w)
- if(isnanf(EX->f[0]) || isinff(EX->f[0]) || EX->f[0]>0x7fffffffffffffffLL)
+ if (rex.w) {
+ if(isnanf(EX->f[0]) || isinff(EX->f[0]) || EX->f[0]>(float)0x7fffffffffffffffLL)
GD->q[0] = 0x8000000000000000LL;
else
GD->sq[0] = EX->f[0];
- else {
+ } else {
if(isnanf(EX->f[0]) || isinff(EX->f[0]) || EX->f[0]>0x7fffffff)
GD->dword[0] = 0x80000000;
else
@@ -107,7 +115,7 @@ uintptr_t RunF30F(x64emu_t *emu, rex_t rex, uintptr_t addr)
GETEX(0);
GETGD;
if(rex.w) {
- if(isnanf(EX->f[0]) || isinff(EX->f[0]) || EX->f[0]>0x7fffffffffffffffLL)
+ if(isnanf(EX->f[0]) || isinff(EX->f[0]) || EX->f[0]>(float)0x7fffffffffffffffLL)
GD->q[0] = 0x8000000000000000LL;
else
switch(emu->mxcsr.f.MXCSR_RC) {
@@ -125,23 +133,27 @@ uintptr_t RunF30F(x64emu_t *emu, rex_t rex, uintptr_t addr)
break;
}
} else {
- if(isnanf(EX->f[0]) || isinff(EX->f[0]) || EX->f[0]>0x7fffffff)
- GD->dword[0] = 0x80000000;
+ if(isnanf(EX->f[0]))
+ tmp64s = INT32_MIN;
else
switch(emu->mxcsr.f.MXCSR_RC) {
case ROUND_Nearest:
- GD->sdword[0] = nearbyintf(EX->f[0]);
+ tmp64s = nearbyintf(EX->f[0]);
break;
case ROUND_Down:
- GD->sdword[0] = floorf(EX->f[0]);
+ tmp64s = floorf(EX->f[0]);
break;
case ROUND_Up:
- GD->sdword[0] = ceilf(EX->f[0]);
+ tmp64s = ceilf(EX->f[0]);
break;
case ROUND_Chop:
- GD->sdword[0] = EX->f[0];
+ tmp64s = EX->f[0];
break;
}
+ if (tmp64s==(int32_t)tmp64s)
+ GD->sdword[0] = (int32_t)tmp64s;
+ else
+ GD->sdword[0] = INT32_MIN;
GD->dword[1] = 0;
}
break;
@@ -187,10 +199,17 @@ uintptr_t RunF30F(x64emu_t *emu, rex_t rex, uintptr_t addr)
nextop = F8;
GETEX(0);
GETGX;
- GX->sd[0] = EX->f[0];
- GX->sd[1] = EX->f[1];
- GX->sd[2] = EX->f[2];
- GX->sd[3] = EX->f[3];
+ for(int i=0; i<4; ++i) {
+ if(isnanf(EX->f[i]))
+ tmp64s = INT32_MIN;
+ else
+ tmp64s = EX->f[i];
+ if (tmp64s==(int32_t)tmp64s) {
+ GX->sd[i] = (int32_t)tmp64s;
+ } else {
+ GX->sd[i] = INT32_MIN;
+ }
+ }
break;
case 0x5C: /* SUBSS Gx, Ex */
nextop = F8;
diff --git a/src/emu/x64syscall.c b/src/emu/x64syscall.c
index f0faea7..24dd442 100755..100644
--- a/src/emu/x64syscall.c
+++ b/src/emu/x64syscall.c
@@ -62,6 +62,7 @@ int32_t my_epoll_pwait(x64emu_t* emu, int32_t epfd, void* events, int32_t maxeve
pid_t my_vfork(x64emu_t* emu);
#endif
int32_t my_fcntl(x64emu_t* emu, int32_t a, int32_t b, void* c);
+int32_t my_execve(x64emu_t* emu, const char* path, char* const argv[], char* const envp[]);
// cannot include <fcntl.h>, it conflict with some asm includes...
#ifndef O_NONBLOCK
@@ -77,7 +78,7 @@ typedef struct scwrap_s {
int nbpars;
} scwrap_t;
-scwrap_t syscallwrap[] = {
+static scwrap_t syscallwrap[] = {
//{ 0, __NR_read, 3 }, // wrapped so SA_RESTART can be handled by libc
//{ 1, __NR_write, 3 }, // same
//{ 2, __NR_open, 3 }, // flags need transformation
@@ -124,6 +125,8 @@ scwrap_t syscallwrap[] = {
{ 45, __NR_recvfrom, 6},
{ 46, __NR_sendmsg, 3},
{ 47, __NR_recvmsg, 3},
+ { 49, __NR_bind, 3},
+ { 50, __NR_listen, 2},
{ 51, __NR_getsockname, 3},
{ 52, __NR_getpeername, 3},
{ 53, __NR_socketpair, 4},
@@ -134,6 +137,7 @@ scwrap_t syscallwrap[] = {
{ 57, __NR_fork, 0 }, // should wrap this one, because of the struct pt_regs (the only arg)?
#endif
//{58, __NR_vfork, 0},
+ //{59, __NR_execve, 3},
{ 60, __NR_exit, 1}, // Nees wrapping?
{ 61, __NR_wait4, 4},
{ 62, __NR_kill, 2 },
@@ -146,6 +150,7 @@ scwrap_t syscallwrap[] = {
{ 78, __NR_getdents, 3},
#endif
{ 79, __NR_getcwd, 2},
+ { 80, __NR_chdir, 1},
#ifdef __NR_rename
{ 82, __NR_rename, 2},
#endif
@@ -159,7 +164,18 @@ scwrap_t syscallwrap[] = {
{ 96, __NR_gettimeofday, 2},
{ 97, __NR_getrlimit, 2},
{ 101, __NR_ptrace, 4},
+ { 102, __NR_getuid, 0},
+ { 104, __NR_getgid, 0},
+ { 105, __NR_setuid, 1},
+ { 106, __NR_setgid, 1},
+ { 107, __NR_geteuid, 0},
+ { 108, __NR_getegid, 0},
+ { 109, __NR_setpgid, 2},
+ { 110, __NR_getppid, 0},
+ //{ 111, __NR_getpgrp, 0},
{ 112, __NR_setsid, 0},
+ { 113, __NR_setreuid, 2},
+ { 114, __NR_setregid, 2},
{ 118, __NR_getresuid, 3},
{ 120, __NR_getresgid, 3},
{ 125, __NR_capget, 2},
@@ -167,9 +183,11 @@ scwrap_t syscallwrap[] = {
{ 127, __NR_rt_sigpending, 2},
{ 128, __NR_rt_sigtimedwait, 4},
//{ 131, __NR_sigaltstack, 2}, // wrapped to use my_sigaltstack*
+ { 140, __NR_getpriority, 2},
{ 155, __NR_pivot_root, 2},
{ 157, __NR_prctl, 5 }, // needs wrapping?
//{ 158, __NR_arch_prctl, 2}, //need wrapping
+ { 160, __NR_setrlimit, 2},
{ 161, __NR_chroot, 1},
{ 186, __NR_gettid, 0 }, //0xBA
{ 200, __NR_tkill, 2 },
@@ -184,6 +202,7 @@ scwrap_t syscallwrap[] = {
{ 208, __NR_io_getevents, 4},
{ 209, __NR_io_submit, 3},
{ 210, __NR_io_cancel, 3},
+ { 212, __NR_lookup_dcookie, 3},
#ifdef __NR_epoll_create
{ 213, __NR_epoll_create, 1},
#endif
@@ -201,6 +220,8 @@ scwrap_t syscallwrap[] = {
{ 233, __NR_epoll_ctl, 4},
#endif
{ 234, __NR_tgkill, 3},
+ { 238, __NR_set_mempolicy, 3},
+ { 239, __NR_get_mempolicy, 5},
{ 247, __NR_waitid, 5},
#ifdef __NR_inotify_init
{ 253, __NR_inotify_init, 0}, //0xFD
@@ -217,6 +238,7 @@ scwrap_t syscallwrap[] = {
{ 264, __NR_renameat, 4},
#endif
{ 267, __NR_readlinkat, 4},
+ { 268, __NR_fchmodat, 3},
{ 270, __NR_pselect6, 6},
{ 272, __NR_unshare, 1},
{ 273, __NR_set_robust_list, 2},
@@ -227,6 +249,8 @@ scwrap_t syscallwrap[] = {
#ifdef _NR_eventfd
{ 284, __NR_eventfd, 1},
#endif
+ { 285, __NR_fallocate, 4},
+ { 288, __NR_accept4, 4},
{ 290, __NR_eventfd2, 2},
{ 291, __NR_epoll_create1, 1},
{ 292, __NR_dup3, 3},
@@ -541,8 +565,8 @@ void EXPORT x64Syscall(x64emu_t *emu)
}
}
x64emu_t * newemu = NewX64Emu(emu->context, R_RIP, (uintptr_t)stack_base, stack_size, (R_RSI)?0:1);
- SetupX64Emu(newemu);
- CloneEmu(newemu, emu);
+ SetupX64Emu(newemu, emu);
+ //CloneEmu(newemu, emu);
Push64(newemu, 0);
PushExit(newemu);
void* mystack = NULL;
@@ -580,6 +604,14 @@ void EXPORT x64Syscall(x64emu_t *emu)
R_RAX = (uint64_t)-errno;
}
break;
+ case 59: // execve
+ {
+ int64_t r = my_execve(emu, (const char*)R_RDI, (char* const*)R_RSI, (char* const*)R_RDX);
+ R_RAX = r;
+ if(R_EAX==0xffffffff)
+ R_RAX = (uint64_t)-errno;
+ }
+ break;
case 63: //uname
{
old_utsname_t *old = (old_utsname_t*)R_RDI;
@@ -733,7 +765,7 @@ uintptr_t EXPORT my_syscall(x64emu_t *emu)
{
static uint32_t warned = 0;
uint32_t s = R_EDI;
- printf_dump(LOG_DEBUG, "%p: Calling libc syscall 0x%02X (%d) %p %p %p %p %p\n", (void*)R_RIP, s, s, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9);
+ printf_dump(LOG_DEBUG, "%04d| %p: Calling libc syscall 0x%02X (%d) %p %p %p %p %p\n", GetTID(), (void*)R_RIP, s, s, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9);
// check wrapper first
int cnt = sizeof(syscallwrap) / sizeof(scwrap_t);
for (int i=0; i<cnt; i++) {
@@ -842,8 +874,8 @@ uintptr_t EXPORT my_syscall(x64emu_t *emu)
}
}
x64emu_t * newemu = NewX64Emu(emu->context, R_RIP, (uintptr_t)stack_base, stack_size, (R_RDX)?0:1);
- SetupX64Emu(newemu);
- CloneEmu(newemu, emu);
+ SetupX64Emu(newemu, emu);
+ //CloneEmu(newemu, emu);
Push64(newemu, 0);
PushExit(newemu);
void* mystack = NULL;
@@ -876,6 +908,8 @@ uintptr_t EXPORT my_syscall(x64emu_t *emu)
#endif
case 58: // vfork
return my_vfork(emu);
+ case 59: // execve
+ return my_execve(emu, (const char*)R_RSI, (char* const*)R_RDX, (char* const*)R_RCX);
case 63: //uname
{
old_utsname_t *old = (old_utsname_t*)R_RSI;
diff --git a/src/emu/x64test.c b/src/emu/x64test.c
new file mode 100644
index 0000000..8e0327a
--- /dev/null
+++ b/src/emu/x64test.c
@@ -0,0 +1,160 @@
+#define _GNU_SOURCE
+#include <stdint.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <math.h>
+#include <string.h>
+#include <signal.h>
+#include <sys/types.h>
+#include <unistd.h>
+#include <stddef.h>
+
+#include "debug.h"
+#include "box64stack.h"
+#include "x64emu.h"
+#include "x64run.h"
+#include "x64emu_private.h"
+#include "x64run_private.h"
+#include "x64primop.h"
+#include "x64trace.h"
+#include "x87emu_private.h"
+#include "box64context.h"
+#include "bridge.h"
+#include "signals.h"
+
+void print_banner(x64emu_t* ref)
+{
+ printf_log(LOG_NONE, "Warning, difference between Interpreter and Dynarec in %p (%02x %02x %02x %02x %02x %02x %02x %02x)\n"\
+ "=======================================\n",
+ (void*)ref->old_ip,
+ ((uint8_t*)ref->old_ip)[0], ((uint8_t*)ref->old_ip)[1], ((uint8_t*)ref->old_ip)[2], ((uint8_t*)ref->old_ip)[3],
+ ((uint8_t*)ref->old_ip)[4], ((uint8_t*)ref->old_ip)[5], ((uint8_t*)ref->old_ip)[6], ((uint8_t*)ref->old_ip)[7]
+ );
+ printf_log(LOG_NONE, "DIFF: Dynarec | Interpreter\n----------------------\n");
+}
+#define BANNER if(!banner) {banner=1; print_banner(ref);}
+void x64test_check(x64emu_t* ref, uintptr_t ip)
+{
+ int banner = 0;
+ x64test_t* test = &ref->test;
+ x64emu_t* emu = test->emu;
+ if(memcmp(ref->regs, emu->regs, sizeof(emu->regs))) {
+ static const char* regname[] = {"RAX", "RCX", "RDX", "RBX", "RSP", "RBP", "RSI", "RDI",
+ " R8", " R9", "R10", "R11", "R12", "R13", "R14", "R15"};
+ BANNER;
+ for(int i=0; i<16; ++i) {
+ if(ref->regs[i].q[0]!=emu->regs[i].q[0]) {
+ printf_log(LOG_NONE, "%s: %016zx | %016zx\n", regname[i], ref->regs[i].q[0], emu->regs[i].q[0]);
+ }
+ }
+ }
+ if(ip!=emu->ip.q[0]) {
+ BANNER;
+ printf_log(LOG_NONE, "RIP: %016zx | %016zx\n", ip, emu->ip.q[0]);
+ }
+ // flags are volatile, so don't test them
+ //memcpy(&ref->eflags, &emu->eflags, sizeof(emu->eflags));
+ if(memcmp(ref->segs, emu->segs, sizeof(emu->segs))) {
+ static const char* segname[] = {"ES", "CS", "SS", "DS", "FS", "GS"};
+ BANNER;
+ for(int i=0; i<6; ++i) {
+ if(ref->segs[i]!=emu->segs[i]) {
+ printf_log(LOG_NONE, "%s: %04x | %04x\n", segname[i], ref->segs[i], emu->segs[i]);
+ }
+ }
+ }
+ if(ref->top != emu->top) {
+ BANNER;
+ printf_log(LOG_NONE, "X87 TOP: %d | %d\n", ref->top, emu->top);
+ }
+ if(ref->fpu_stack != emu->fpu_stack) {
+ BANNER;
+ printf_log(LOG_NONE, "X87 STACK: %d | %d\n", ref->fpu_stack, emu->fpu_stack);
+ }
+ if(ref->fpu_stack && memcmp(ref->x87, emu->x87, sizeof(emu->x87))) {
+ // need to check each regs, unused one might have different left over value
+ for(int i=0; i<ref->fpu_stack; ++i) {
+ if(ref->x87[(ref->top+i)&7].d != emu->x87[(emu->top+i)&7].d) {
+ BANNER;
+ printf_log(LOG_NONE, "ST%d: %g | %g\n", i, ref->x87[(ref->top+i)&7].d, emu->x87[(emu->top+i)&7].d);
+ }
+ }
+ }
+ //memcpy(ref->fpu_ld, emu->fpu_ld, sizeof(emu->fpu_ld));
+ //memcpy(ref->fpu_ll, emu->fpu_ll, sizeof(emu->fpu_ll));
+ /*if(ref->p_regs != emu->p_regs) {
+ BANNER;
+ printf_log(LOG_NONE, "X87 PREG: %x | %x\n", ref->p_regs, emu->p_regs);
+ }*/
+ if(ref->cw.x16 != emu->cw.x16) {
+ BANNER;
+ printf_log(LOG_NONE, "X87 CW: %x | %x\n", ref->cw.x16, emu->cw.x16);
+ }
+ if(ref->sw.x16 != emu->sw.x16) {
+ BANNER;
+ printf_log(LOG_NONE, "X87 SW: %x | %x\n", ref->sw.x16, emu->sw.x16);
+ }
+ if(memcmp(ref->mmx, emu->mmx, sizeof(emu->mmx))) {
+ BANNER;
+ for(int i=0; i<8; ++i) {
+ if(ref->mmx[i].q!=emu->mmx[i].q) {
+ printf_log(LOG_NONE, "EMM[%d]: %016x | %016x\n", i, ref->mmx[i].q, emu->mmx[i].q);
+ }
+ }
+ }
+ if(ref->mxcsr.x32 != emu->mxcsr.x32) {
+ BANNER;
+ printf_log(LOG_NONE, "MXCSR: %x | %x\n", ref->mxcsr.x32, emu->mxcsr.x32);
+ }
+ if(memcmp(ref->xmm, emu->xmm, sizeof(emu->xmm))) {
+ BANNER;
+ for(int i=0; i<16; ++i) {
+ if(ref->xmm[i].q[0]!=emu->xmm[i].q[0] || ref->xmm[i].q[1]!=emu->xmm[i].q[1] ) {
+ printf_log(LOG_NONE, "XMM[%02d]: %016zx-%016zx | %016zx-%016zx\n", i, ref->xmm[i].q[1], ref->xmm[i].q[0], emu->xmm[i].q[1], emu->xmm[i].q[0]);
+ }
+ }
+ }
+ if(test->memsize) {
+ if(memcmp(test->mem, (void*)test->memaddr, test->memsize)) {
+ BANNER;
+ printf_log(LOG_NONE, "MEM: @%p :", (void*)test->memaddr);
+ for(int i=0; i<test->memsize; ++i)
+ printf_log(LOG_NONE, " %02x", test->mem[i]);
+ printf_log(LOG_NONE, " |");
+ for(int i=0; i<test->memsize; ++i)
+ printf_log(LOG_NONE, " %02x", ((uint8_t*)test->memaddr)[i]);
+ printf_log(LOG_NONE, "\n");
+ }
+ }
+ if(banner) // there was an error, re-sync!
+ CopyEmu(emu, ref);
+}
+#undef BANNER
+
+void x64test_init(x64emu_t* ref, uintptr_t ip)
+{
+ x64test_t* test = &ref->test;
+ if(!test->test) {
+ test->clean = 0;
+ return;
+ }
+ // check if test as a valid emu struct
+ if(!test->emu) {
+ test->emu = NewX64Emu(my_context, ip, (uintptr_t)ref->init_stack, ref->size_stack, 0);
+ CopyEmu(test->emu, ref);
+ } else {
+ // check if IP is same, else, sync
+ uintptr_t prev_ip = test->emu->ip.q[0];
+ if(test->clean)
+ x64test_check(ref, ip);
+ if(ip != prev_ip || !test->test || !test->clean) {
+ CopyEmu(test->emu, ref);
+ }
+ }
+ // Do a Dry single Step
+ test->memsize = 0;
+ test->clean = 1;
+ ref->old_ip = ip;
+ RunTest(test);
+ // this will be anakyzed next step
+}
diff --git a/src/emu/x64tls.c b/src/emu/x64tls.c
index a059ecf..83fc1f6 100755..100644
--- a/src/emu/x64tls.c
+++ b/src/emu/x64tls.c
@@ -15,7 +15,7 @@
typedef struct thread_area_s
{
int entry_number;
- uintptr_t base_addr;
+ uint64_t base_addr;
unsigned int limit;
unsigned int seg_32bit:1;
unsigned int contents:2;
@@ -23,29 +23,26 @@ typedef struct thread_area_s
unsigned int limit_in_pages:1;
unsigned int seg_not_present:1;
unsigned int useable:1;
+ unsigned int lm:1;
} thread_area_t;
+typedef struct thread_area_32_s
+{
+ int entry_number;
+ uint32_t base_addr;
+ unsigned int limit;
+ unsigned int seg_32bit:1;
+ unsigned int contents:2;
+ unsigned int read_exec_only:1;
+ unsigned int limit_in_pages:1;
+ unsigned int seg_not_present:1;
+ unsigned int useable:1;
+} thread_area_32_t;
-static pthread_once_t thread_key_once0 = PTHREAD_ONCE_INIT;
-static pthread_once_t thread_key_once1 = PTHREAD_ONCE_INIT;
-static pthread_once_t thread_key_once2 = PTHREAD_ONCE_INIT;
-static pthread_once_t thread_key_once3 = PTHREAD_ONCE_INIT;
-
-static void thread_key_alloc0() {
- pthread_key_create(&my_context->segtls[0].key, NULL);
-}
-static void thread_key_alloc1() {
- pthread_key_create(&my_context->segtls[1].key, NULL);
-}
-static void thread_key_alloc2() {
- pthread_key_create(&my_context->segtls[2].key, NULL);
-}
-static void thread_key_alloc3() {
- pthread_key_create(&my_context->segtls[3].key, NULL);
-}
+int GetTID();
-uint32_t my_set_thread_area(thread_area_t* td)
+uint32_t my_set_thread_area_32(x64emu_t* emu, thread_area_32_t* td)
{
- printf_log(LOG_DEBUG, "set_thread_area(%p[%d/base=%p/limit=%u/32bits:%u/%u/%u...])\n", td, td->entry_number, (void*)td->base_addr, td->limit_in_pages, td->seg_32bit, td->contents, td->read_exec_only);
+ printf_log(LOG_DEBUG, "%04d| set_thread_area_32(%p[%d/base=%p/limit=%u/32bits:%u/%u/%u...])\n", GetTID(), td, td->entry_number, (void*)(uintptr_t)td->base_addr, td->limit_in_pages, td->seg_32bit, td->contents, td->read_exec_only);
int isempty = 0;
// first, check if the "user_desc", here td, is "empty"
@@ -60,48 +57,47 @@ uint32_t my_set_thread_area(thread_area_t* td)
int idx = td->entry_number;
if(idx==-1) {
// find a free one
- for (int i=0; i<3 && idx==-1; ++i)
+ for (int i=9; i<15 && idx==-1; ++i)
if(!my_context->segtls[i].present)
idx=i;
if(idx==-1) {
errno = ESRCH;
return (uint32_t)-1;
}
- idx+=7;
td->entry_number = idx;
}
- if(isempty && (td->entry_number<7 || td->entry_number>7+2)) {
+ if(isempty && (td->entry_number<9 || td->entry_number>15)) {
errno = EINVAL;
return (uint32_t)-1;
}
if(isempty) {
- memset(&my_context->segtls[td->entry_number-7], 0, sizeof(base_segment_t));
+ memset(&my_context->segtls[td->entry_number], 0, sizeof(base_segment_t));
return 0;
}
- if((idx<7 || idx>7+2)) {
+ if((idx<9 || idx>15)) {
errno = EINVAL;
return (uint32_t)-1;
}
- my_context->segtls[idx-7].base = td->base_addr;
- my_context->segtls[idx-7].limit = td->limit;
- my_context->segtls[idx-7].present = 1;
- switch (idx-7) {
- case 0: pthread_once(&thread_key_once0, thread_key_alloc0); break;
- case 1: pthread_once(&thread_key_once1, thread_key_alloc1); break;
- case 2: pthread_once(&thread_key_once2, thread_key_alloc2); break;
+ my_context->segtls[idx].base = td->base_addr;
+ my_context->segtls[idx].limit = td->limit;
+ my_context->segtls[idx].present = 1;
+ my_context->segtls[idx].is32bits = 1;
+ if(!my_context->segtls[idx].key_init) {
+ pthread_key_create(&my_context->segtls[idx].key, NULL);
+ my_context->segtls[idx].key_init = 1;
}
- pthread_setspecific(my_context->segtls[idx-7].key, (void*)my_context->segtls[idx-7].base);
+ pthread_setspecific(my_context->segtls[idx].key, (void*)my_context->segtls[idx].base);
- ResetSegmentsCache(thread_get_emu());
+ ResetSegmentsCache(emu);
return 0;
}
uint32_t my_modify_ldt(x64emu_t* emu, int op, thread_area_t* td, int size)
{
- printf_log(/*LOG_DEBUG*/LOG_INFO, "modify_ldt(0x%x, %p[0x%x/base=%p/limit=%u/32bits:%u/%u/%u...], %d)\n", op, td, td->entry_number, (void*)td->base_addr, td->limit_in_pages, td->seg_32bit, td->contents, td->read_exec_only, size);
+ printf_log(LOG_DEBUG, "%04d| modify_ldt(0x%x, %p[0x%x/base=%p/limit=%u/32bits:%u/%u/%u...], %d)\n", GetTID(), op, td, td->entry_number, (void*)td->base_addr, td->limit_in_pages, td->seg_32bit, td->contents, td->read_exec_only, size);
if(!td) {
errno = EFAULT;
return (uint32_t)-1;
@@ -116,8 +112,8 @@ uint32_t my_modify_ldt(x64emu_t* emu, int op, thread_area_t* td, int size)
return (uint32_t)-1;
}
- int idx = td->entry_number - 7;
- if(idx<0 || idx>2) {
+ int idx = td->entry_number;
+ if(idx<9 || idx>15) {
errno = EINVAL;
return (uint32_t)-1;
}
@@ -133,33 +129,78 @@ uint32_t my_modify_ldt(x64emu_t* emu, int op, thread_area_t* td, int size)
return 0;
}
+static void* GetSeg43Base();
+static const char* arch_prctl_param(int code)
+{
+ static char ret[10] = {0};
+ switch (code) {
+ case 0x1001: return "ARCH_SET_GS";
+ case 0x1002: return "ARCH_SET_FS";
+ case 0x1003: return "ARCH_GET_FS";
+ case 0x1004: return "ARCH_GET_GS";
+ }
+ sprintf(ret, "0x%x", code);
+ return ret;
+}
int my_arch_prctl(x64emu_t *emu, int code, void* addr)
{
+ printf_log(LOG_DEBUG, "%04d| arch_prctl(%s, %p) (RSP=%p, FS=0x%x, GS=0x%x)\n", GetTID(), arch_prctl_param(code), addr,(void*)R_RSP, emu->segs[_FS], emu->segs[_GS]);
+
#define ARCH_SET_GS 0x1001
#define ARCH_SET_FS 0x1002
#define ARCH_GET_FS 0x1003
#define ARCH_GET_GS 0x1004
+ int seg = 0;
+ int idx = 0;
switch(code) {
case ARCH_GET_GS:
*(void**)addr = GetSegmentBase(emu->segs[_GS]);
return 0;
- case ARCH_SET_GS:
- pthread_once(&thread_key_once3, thread_key_alloc3);
- if(emu->segs[_GS]!=(0xa<<3))
- emu->segs[_GS] = 0xa<<3; // should not move!
- emu->segs_serial[_GS] = 0;
- my_context->segtls[3].base = (uintptr_t)addr;
- my_context->segtls[3].limit = 0;
- my_context->segtls[3].present = 1;
- pthread_setspecific(my_context->segtls[3].key, (void*)my_context->segtls[3].base);
- ResetSegmentsCache(emu);
- return 0;
case ARCH_GET_FS:
*(void**)addr = GetSegmentBase(emu->segs[_FS]);
return 0;
+ case ARCH_SET_FS:
+ case ARCH_SET_GS:
+ seg=(code==ARCH_SET_FS)?_FS:_GS;
+ int idx = -1;
+ // search if it's a TLS base
+ if(GetSeg43Base()==addr)
+ idx = 0x43>>3;
+ // Is this search only occurs when seg==0?
+ for (int i=9; i<15 && idx==-1; ++i)
+ if(my_context->segtls[i].present && my_context->segtls[i].base==(uintptr_t)addr)
+ idx=i;
+ // found...
+ if(idx!=-1) {
+ printf_log(LOG_DEBUG, "Changing segment selector from 0x%x to 0x%x\n", emu->segs[seg], (idx<<3) +3);
+ emu->segs[seg]=(idx<<3) +3;
+ }
+ if(emu->segs[seg]==0) {
+ printf_log(LOG_DEBUG, "Warning, set seg, but it's 0!\n");
+ errno = EINVAL;
+ return -1;
+ }
+ idx = emu->segs[seg] >> 3;
+ if(idx<0 || idx>15) {
+ errno = EINVAL;
+ return -1;
+ }
+ emu->segs_serial[seg] = 0;
+ my_context->segtls[idx].base = (uintptr_t)addr;
+ my_context->segtls[idx].limit = 0;
+ my_context->segtls[idx].present = 1;
+ if(idx>8 && !my_context->segtls[idx].key_init) {
+ pthread_key_create(&my_context->segtls[idx].key, NULL);
+ my_context->segtls[idx].key_init = 1;
+ }
+ if(my_context->segtls[idx].key_init)
+ pthread_setspecific(my_context->segtls[idx].key, addr);
+ ResetSegmentsCache(emu);
+ return 0;
}
// other are unsupported
printf_log(LOG_INFO, "warning, call to unsupported arch_prctl(0x%x, %p)\n", code, addr);
+ errno = ENOSYS;
return -1;
}
@@ -227,7 +268,7 @@ static tlsdatasize_t* setupTLSData(box64context_t* context)
return data;
}
-void* fillTLSData(box64context_t *context)
+static void* fillTLSData(box64context_t *context)
{
mutex_lock(&context->mutex_tls);
tlsdatasize_t *data = setupTLSData(context);
@@ -235,12 +276,12 @@ void* fillTLSData(box64context_t *context)
return data;
}
-void* resizeTLSData(box64context_t *context, void* oldptr)
+static void* resizeTLSData(box64context_t *context, void* oldptr)
{
mutex_lock(&context->mutex_tls);
tlsdatasize_t* oldata = (tlsdatasize_t*)oldptr;
if(sizeTLSData(oldata->tlssize)!=sizeTLSData(context->tlssize) || (oldata->n_elfs/0xff)!=(context->elfsize/0xff)) {
- printf_log(LOG_INFO, "Warning, resizing of TLS occured! size: %d->%d / n_elfs: %d->%d\n", sizeTLSData(oldata->tlssize), sizeTLSData(context->tlssize), 1+(oldata->n_elfs/0xff), 1+(context->elfsize/0xff));
+ printf_log(LOG_INFO, "Warning, resizing of TLS occurred! size: %d->%d / n_elfs: %d->%d\n", sizeTLSData(oldata->tlssize), sizeTLSData(context->tlssize), 1+(oldata->n_elfs/0xff), 1+(context->elfsize/0xff));
tlsdatasize_t *data = setupTLSData(context);
// copy the relevent old part, in case something changed
memcpy((void*)((uintptr_t)data->data-oldata->tlssize), (void*)((uintptr_t)oldata->data-oldata->tlssize), oldata->tlssize);
@@ -272,14 +313,21 @@ void* resizeTLSData(box64context_t *context, void* oldptr)
}
}
-static void* GetSeg33Base()
+tlsdatasize_t* getTLSData(box64context_t *context)
{
- tlsdatasize_t* ptr;
- if ((ptr = (tlsdatasize_t*)pthread_getspecific(my_context->tlskey)) == NULL) {
- ptr = (tlsdatasize_t*)fillTLSData(my_context);
- }
- if(ptr->tlssize != my_context->tlssize)
- ptr = (tlsdatasize_t*)resizeTLSData(my_context, ptr);
+ tlsdatasize_t* ptr = NULL;
+ if(!ptr)
+ if ((ptr = (tlsdatasize_t*)pthread_getspecific(context->tlskey)) == NULL) {
+ ptr = (tlsdatasize_t*)fillTLSData(context);
+ }
+ if(ptr->tlssize != context->tlssize)
+ ptr = (tlsdatasize_t*)resizeTLSData(context, ptr);
+ return ptr;
+}
+
+static void* GetSeg43Base()
+{
+ tlsdatasize_t* ptr = getTLSData(my_context);
return ptr->data;
}
@@ -290,16 +338,17 @@ void* GetSegmentBase(uint32_t desc)
return NULL;
}
int base = desc>>3;
- if(base==0xe || base==0xf)
- return NULL; // regular value...
- if(base==0x6)
- return GetSeg33Base();
-
- if(base>6 && base<11 && my_context->segtls[base-7].present) {
- void* ptr = pthread_getspecific(my_context->segtls[base-7].key);
+ if(base==0x8 && !my_context->segtls[base].key_init)
+ return GetSeg43Base();
+ if(base>15) {
+ printf_log(LOG_NONE, "Warning, accessing segment unknown 0x%x or unset\n", desc);
+ return NULL;
+ }
+ if(my_context->segtls[base].key_init) {
+ void* ptr = pthread_getspecific(my_context->segtls[base].key);
return ptr;
}
-
- printf_log(LOG_NONE, "Warning, accessing segment unknown 0x%x or unset\n", desc);
- return NULL;
+
+ void* ptr = (void*)my_context->segtls[base].base;
+ return ptr;
}
diff --git a/src/emu/x64trace.c b/src/emu/x64trace.c
index b5ddb5b..ac65504 100755..100644
--- a/src/emu/x64trace.c
+++ b/src/emu/x64trace.c
@@ -59,6 +59,7 @@ int InitX64Trace(box64context_t *context)
#undef GO
context->dec = InitX64TraceDecoder(context);
+ context->dec32 = InitX86TraceDecoder(context);
return 0;
}
@@ -73,6 +74,24 @@ void DeleteX64Trace(box64context_t *context)
context->zydis = NULL;
}
+zydis_dec_t* InitX86TraceDecoder(box64context_t *context)
+{
+ if(!context->zydis)
+ return NULL;
+ zydis_dec_t *dec = (zydis_dec_t*)box_calloc(1, sizeof(zydis_dec_t));
+ dec->ZydisDecoderDecodeBuffer = context->zydis->ZydisDecoderDecodeBuffer;
+ dec->ZydisFormatterFormatInstruction = context->zydis->ZydisFormatterFormatInstruction;
+ context->zydis->ZydisDecoderInit(&dec->decoder, ZYDIS_MACHINE_MODE_LEGACY_32, ZYDIS_ADDRESS_WIDTH_32);
+ context->zydis->ZydisFormatterInit(&dec->formatter, ZYDIS_FORMATTER_STYLE_INTEL);
+
+ return dec;
+}
+void DeleteX86TraceDecoder(zydis_dec_t **dec)
+{
+ box_free(*dec);
+ *dec = NULL;
+}
+
zydis_dec_t* InitX64TraceDecoder(box64context_t *context)
{
if(!context->zydis)
diff --git a/src/emu/x86syscall.c b/src/emu/x86syscall.c
new file mode 100755
index 0000000..b41b006
--- /dev/null
+++ b/src/emu/x86syscall.c
@@ -0,0 +1,284 @@
+#define _GNU_SOURCE /* See feature_test_macros(7) */
+#include <stdint.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+
+#include <sys/syscall.h> /* For SYS_xxx definitions */
+#include <unistd.h>
+#include <time.h>
+#include <sys/mman.h>
+#include <sys/select.h>
+#include <sys/types.h>
+#include <sys/ioctl.h>
+#include <asm/stat.h>
+#include <errno.h>
+#include <sched.h>
+#include <sys/wait.h>
+#include <sys/utsname.h>
+#ifndef __NR_socketcall
+#include <linux/net.h>
+#include <sys/socket.h>
+#endif
+#include <sys/resource.h>
+#include <poll.h>
+
+#include "debug.h"
+#include "box64stack.h"
+#include "x64emu.h"
+#include "x64run.h"
+#include "x64emu_private.h"
+#include "x64trace.h"
+#include "myalign.h"
+#include "box64context.h"
+#include "callback.h"
+#include "signals.h"
+#include "x64tls.h"
+
+
+// Syscall table for x86_64 can be found
+typedef struct scwrap_s {
+ uint32_t x86s;
+ int nats;
+ int nbpars;
+} scwrap_t;
+
+static scwrap_t syscallwrap[] = {
+ //{ 2, __NR_fork, 1 },
+ //{ 3, __NR_read, 3 }, // wrapped so SA_RESTART can be handled by libc
+ //{ 4, __NR_write, 3 }, // same
+ //{ 5, __NR_open, 3 }, // flags need transformation
+ //{ 6, __NR_close, 1 }, // wrapped so SA_RESTART can be handled by libc
+ //{ 7, __NR_waitpid, 3 },
+ //{ 10, __NR_unlink, 1 },
+ //{ 12, __NR_chdir, 1 },
+ //{ 13, __NR_time, 1 },
+ //{ 15, __NR_chmod, 2 },
+ //{ 19, __NR_lseek, 3 },
+ //{ 20, __NR_getpid, 0 },
+ //{ 24, __NR_getuid, 0 },
+ //{ 33, __NR_access, 2 },
+ //{ 37, __NR_kill, 2 },
+ //{ 38, __NR_rename, 2 },
+ //{ 39, __NR_mkdir, 2 },
+ //{ 40, __NR_rmdir, 1 },
+ //{ 41, __NR_dup, 1 },
+ //{ 42, __NR_pipe, 1 },
+ //{ 45, __NR_brk, 1 },
+ //{ 47, __NR_getgid, 0 },
+ //{ 49, __NR_geteuid, 0 },
+ //{ 50, __NR_getegid, 0 },
+ //{ 54, __NR_ioctl, 3 }, // should be wrapped to allow SA_RESTART handling by libc, but syscall is only 3 arguments, ioctl can be 5
+ //{ 55, __NR_fcntl, 3 }, // wrapped to allow filter of F_SETFD
+ //{ 60, __NR_umask, 1 },
+ //{ 63, __NR_dup2, 2 },
+ //{ 64, __NR_getppid, 0 },
+ //{ 66, __NR_setsid, 0 },
+ //{ 75, __NR_setrlimit, 2 },
+ //{ 76, __NR_getrlimit, 2 },
+ //{ 77, __NR_getrusage, 2 },
+ //{ 78, __NR_gettimeofday, 2 },
+ //{ 83, __NR_symlink, 2 },
+ //{ 82, __NR_select, 5 },
+ //{ 85, __NR_readlink, 3 },
+ //{ 91, __NR_munmap, 2 },
+ //{ 94, __NR_fchmod, 2 },
+ //{ 99, __NR_statfs, 2 },
+ //{ 102, __NR_socketcall, 2 },
+ //{ 104, __NR_setitimer, 3 },
+ //{ 105, __NR_getitimer, 2 },
+ //{ 106, __NR_newstat, 2 },
+ //{ 106, __NR_stat, 2 },
+ //{ 107, __NR_newlstat, 2 },
+ //{ 107, __NR_lstat, 2 },
+ //{ 108, __NR_newfstat, 2 },
+ //{ 108, __NR_fstat, 2 },
+ //{ 109, __NR_olduname, 1 },
+ //{ 110, __NR_iopl, 1 },
+ //{ 114, __NR_wait4, 4 }, //TODO: check struct rusage alignment
+ //{ 117, __NR_ipc, 6 },
+ //{ 119, __NR_sigreturn, 0},
+ //{ 120, __NR_clone, 5 }, // need works
+ //{ 122, __NR_uname, 1 },
+ //{ 123, __NR_modify_ldt },
+ //{ 125, __NR_mprotect, 3 },
+ //{ 136, __NR_personality, 1 },
+ //{ 140, __NR__llseek, 5 },
+ //{ 141, __NR_getdents, 3 },
+ //{ 142, __NR__newselect, 5 },
+ //{ 143, __NR_flock, 2 },
+ //{ 144, __NR_msync, 3 },
+ //{ 145, __NR_readv, 3 },
+ //{ 146, __NR_writev, 3 },
+ //{ 148, __NR_fdatasync, 1 },
+ //{ 149, __NR__sysctl, 1 }, // need wrapping?
+ //{ 156, __NR_sched_setscheduler, 3 },
+ //{ 157, __NR_sched_getscheduler, 1 },
+ //{ 158, __NR_sched_yield, 0 },
+ //{ 162, __NR_nanosleep, 2 },
+ //{ 164, __NR_setresuid, 3 },
+ //{ 168, __NR_poll, 3 }, // wrapped to allow SA_RESTART wrapping by libc
+ //{ 172, __NR_prctl, 5 },
+ //{ 173, __NR_rt_sigreturn, 0 },
+ //{ 175, __NR_rt_sigprocmask, 4 },
+ //{ 179, __NR_rt_sigsuspend, 2 },
+ //{ 183, __NR_getcwd, 2 },
+ //{ 184, __NR_capget, 2},
+ //{ 185, __NR_capset, 2},
+ //{ 186, __NR_sigaltstack, 2 }, // neeed wrap or something?
+ //{ 191, __NR_ugetrlimit, 2 },
+// { 192, __NR_mmap2, 6},
+ //{ 195, __NR_stat64, 2 }, // need proprer wrap because of structure size change
+ //{ 196, __NR_lstat64, 2 }, // need proprer wrap because of structure size change
+ //{ 197, __NR_fstat64, 2 }, // need proprer wrap because of structure size change
+ //{ 199, __NR_getuid32, 0 },
+ //{ 200, __NR_getgid32, 0 },
+ //{ 201, __NR_geteuid32, 0 },
+ //{ 202, __NR_getegid32, 0 },
+ //{ 208, __NR_setresuid32, 3 },
+ //{ 209, __NR_getresuid32, 3 },
+ //{ 210, __NR_setresgid32, 3 },
+ //{ 211, __NR_getresgid32, 3 },
+ //{ 220, __NR_getdents64, 3 },
+ //{ 221, __NR_fcntl64, 3 },
+ { 224, __NR_gettid, 0 },
+ //{ 240, __NR_futex, 6 },
+ //{ 241, __NR_sched_setaffinity, 3 },
+ //{ 242, __NR_sched_getaffinity, 3 },
+ //{ 252, __NR_exit_group, 1 },
+ //{ 254, __NR_epoll_create, 1 },
+ //{ 255, __NR_epoll_ctl, 4 },
+ //{ 256, __NR_epoll_wait, 4 },
+ //{ 265, __NR_clock_gettime, 2 },
+ //{ 266, __NR_clock_getres, 2 },
+ //{ 270, __NR_tgkill, 3 },
+ //{ 271, __NR_utimes, 2 },
+ //{ 291, __NR_inotify_init, 0},
+ //{ 292, __NR_inotify_add_watch, 3},
+ //{ 293, __NR_inotify_rm_watch, 2},
+ //{ 311, __NR_set_robust_list, 2 },
+ //{ 312, __NR_get_robust_list, 4 },
+ //{ 318, __NR_getcpu, 3},
+ //{ 328, __NR_eventfd2, 2},
+ //{ 329, __NR_epoll_create1, 1 },
+ //{ 331, __NR_pipe2, 2},
+ //{ 332, __NR_inotify_init1, 1},
+ //{ 355, __NR_getrandom, 3 },
+ //{ 356, __NR_memfd_create, 2},
+ //{ 449, __NR_futex_waitv, 5},
+};
+
+struct mmap_arg_struct {
+ unsigned long addr;
+ unsigned long len;
+ unsigned long prot;
+ unsigned long flags;
+ unsigned long fd;
+ unsigned long offset;
+};
+
+#undef st_atime
+#undef st_ctime
+#undef st_mtime
+
+struct x64_pt_regs {
+ long ebx;
+ long ecx;
+ long edx;
+ long esi;
+ long edi;
+ long ebp;
+ long eax;
+ int xds;
+ int xes;
+ int xfs;
+ int xgs;
+ long orig_eax;
+ long eip;
+ int xcs;
+ long eflags;
+ long esp;
+ int xss;
+};
+
+#ifndef __NR_olduname
+struct oldold_utsname {
+ char sysname[9];
+ char nodename[9];
+ char release[9];
+ char version[9];
+ char machine[9];
+};
+#endif
+struct old_utsname {
+ char sysname[65];
+ char nodename[65];
+ char release[65];
+ char version[65];
+ char machine[65];
+};
+
+struct i386_user_desc {
+ unsigned int entry_number;
+ unsigned long base_addr;
+ unsigned int limit;
+ unsigned int seg_32bit:1;
+ unsigned int contents:2;
+ unsigned int read_exec_only:1;
+ unsigned int limit_in_pages:1;
+ unsigned int seg_not_present:1;
+ unsigned int useable:1;
+};
+
+void EXPORT x86Syscall(x64emu_t *emu)
+{
+ uint32_t s = R_EAX;
+ printf_log(LOG_DEBUG, "%p: Calling 32bits syscall 0x%02X (%d) %p %p %p %p %p", (void*)R_RIP, s, s, (void*)(uintptr_t)R_EBX, (void*)(uintptr_t)R_ECX, (void*)(uintptr_t)R_EDX, (void*)(uintptr_t)R_ESI, (void*)(uintptr_t)R_EDI);
+ // check wrapper first
+ int cnt = sizeof(syscallwrap) / sizeof(scwrap_t);
+ for (int i=0; i<cnt; i++) {
+ if(syscallwrap[i].x86s == s) {
+ int sc = syscallwrap[i].nats;
+ switch(syscallwrap[i].nbpars) {
+ case 0: *(int32_t*)&R_EAX = syscall(sc); break;
+ case 1: *(int32_t*)&R_EAX = syscall(sc, R_EBX); break;
+ case 2: *(int32_t*)&R_EAX = syscall(sc, R_EBX, R_ECX); break;
+ case 3: *(int32_t*)&R_EAX = syscall(sc, R_EBX, R_ECX, R_EDX); break;
+ case 4: *(int32_t*)&R_EAX = syscall(sc, R_EBX, R_ECX, R_EDX, R_ESI); break;
+ case 5: *(int32_t*)&R_EAX = syscall(sc, R_EBX, R_ECX, R_EDX, R_ESI, R_EDI); break;
+ case 6: *(int32_t*)&R_EAX = syscall(sc, R_EBX, R_ECX, R_EDX, R_ESI, R_EDI, R_EBP); break;
+ default:
+ printf_log(LOG_NONE, "ERROR, Unimplemented syscall wrapper (%d, %d)\n", s, syscallwrap[i].nbpars);
+ emu->quit = 1;
+ return;
+ }
+ if(R_EAX==0xffffffff && errno>0)
+ R_EAX = (uint32_t)-errno;
+ printf_log(LOG_DEBUG, " => 0x%x\n", R_EAX);
+ return;
+ }
+ }
+ switch (s) {
+ case 1: // sys_exit
+ emu->quit = 1;
+ emu->exit = 1;
+ //R_EAX = syscall(__NR_exit, R_EBX); // the syscall should exit only current thread
+ R_EAX = R_EBX; // faking the syscall here, we don't want to really terminate the thread now
+ break;
+ /*case 123: // SYS_modify_ldt
+ R_EAX = my_modify_ldt(emu, R_EBX, (thread_area_t*)(uintptr_t)R_ECX, R_EDX);
+ if(R_EAX==0xffffffff && errno>0)
+ R_EAX = (uint32_t)-errno;
+ break;*/
+ case 243: // set_thread_area
+ R_EAX = my_set_thread_area_32(emu, (thread_area_32_t*)(uintptr_t)R_EBX);
+ if(R_EAX==0xffffffff && errno>0)
+ R_EAX = (uint32_t)-errno;
+ break;
+ default:
+ printf_log(LOG_INFO, "Warning: Unsupported Syscall 0x%02Xh (%d)\n", s, s);
+ R_EAX = (uint32_t)-ENOSYS;
+ return;
+ }
+ printf_log(LOG_DEBUG, " => 0x%x\n", R_EAX);
+}
diff --git a/src/emu/x86zydis.h b/src/emu/x86zydis.h
index ec7aea7..ec7aea7 100755..100644
--- a/src/emu/x86zydis.h
+++ b/src/emu/x86zydis.h
diff --git a/src/emu/x87emu_private.c b/src/emu/x87emu_private.c
index 9f4b8af..67573c3 100755..100644
--- a/src/emu/x87emu_private.c
+++ b/src/emu/x87emu_private.c
@@ -339,8 +339,6 @@ void fpu_fxsave32(x64emu_t* emu, void* ed)
p->ErrorSelector = 0;
p->DataOffset = 0;
p->DataSelector = 0;
- p->MxCsr = 0;
- p->MxCsr_Mask = 0;
// copy FPU/MMX regs...
for(int i=0; i<8; ++i)
memcpy(&p->FloatRegisters[i].q[0], (i<stack)?&ST(i):&emu->mmx[i], sizeof(mmx87_regs_t));
@@ -367,8 +365,6 @@ void fpu_fxsave64(x64emu_t* emu, void* ed)
p->ErrorOpcode = 0;
p->ErrorOffset = 0;
p->DataOffset = 0;
- p->MxCsr = 0;
- p->MxCsr_Mask = 0;
// copy FPU/MMX regs...
for(int i=0; i<8; ++i)
memcpy(&p->FloatRegisters[i].q[0], (i<stack)?&ST(i):&emu->mmx[i], sizeof(mmx87_regs_t));
diff --git a/src/emu/x87emu_private.h b/src/emu/x87emu_private.h
index a228705..5721088 100755..100644
--- a/src/emu/x87emu_private.h
+++ b/src/emu/x87emu_private.h
@@ -129,14 +129,14 @@ static inline void fpu_fxam(x64emu_t* emu) {
return;
}
if(isinf(ST0.d))
- { // TODO: Unsuported and denormal not analysed...
+ { // TODO: Unsupported and denormal not analysed...
emu->sw.f.F87_C3 = 0;
emu->sw.f.F87_C2 = 1;
emu->sw.f.F87_C0 = 1;
return;
}
if(isnan(ST0.d))
- { // TODO: Unsuported and denormal not analysed...
+ { // TODO: Unsupported and denormal not analysed...
emu->sw.f.F87_C3 = 0;
emu->sw.f.F87_C2 = 0;
emu->sw.f.F87_C0 = 1;
@@ -159,7 +159,7 @@ static inline void fpu_fxam(x64emu_t* emu) {
static inline void fpu_ftst(x64emu_t* emu) {
emu->sw.f.F87_C1 = 0;
if(isinf(ST0.d) || isnan(ST0.d))
- { // TODO: Unsuported and denormal not analysed...
+ { // TODO: Unsupported and denormal not analysed...
emu->sw.f.F87_C3 = 1;
emu->sw.f.F87_C2 = 1;
emu->sw.f.F87_C0 = 1;
diff --git a/src/include/auxval.h b/src/include/auxval.h
index ecbdf55..ecbdf55 100755..100644
--- a/src/include/auxval.h
+++ b/src/include/auxval.h
diff --git a/src/include/bitutils.h b/src/include/bitutils.h
new file mode 100644
index 0000000..50622da
--- /dev/null
+++ b/src/include/bitutils.h
@@ -0,0 +1,10 @@
+#ifndef __BITUTILS_H_
+#define __BITUTILS_H_
+#include <stdint.h>
+
+extern const uint8_t deBruijn64tab[64];
+extern const uint8_t lead0tab[16];
+
+int TrailingZeros64(uint64_t x);
+
+#endif //__BITUTILS_H_
diff --git a/src/include/box64context.h b/src/include/box64context.h
index 010521e..aa8c95b 100755..100644
--- a/src/include/box64context.h
+++ b/src/include/box64context.h
@@ -8,6 +8,11 @@
#include "dynarec/native_lock.h"
#endif
+#ifdef DYNAREC
+// disabling for now, seems to have a negative impact on performances
+//#define USE_CUSTOM_MUTEX
+#endif
+
typedef struct elfheader_s elfheader_t;
typedef struct cleanup_s cleanup_t;
typedef struct x64emu_s x64emu_t;
@@ -18,6 +23,7 @@ typedef struct bridge_s bridge_t;
typedef struct dlprivate_s dlprivate_t;
typedef struct kh_symbolmap_s kh_symbolmap_t;
typedef struct kh_defaultversion_s kh_defaultversion_t;
+typedef struct kh_mapsymbols_s kh_mapsymbols_t;
typedef struct library_s library_t;
typedef struct linkmap_s linkmap_t;
typedef struct kh_threadstack_s kh_threadstack_t;
@@ -57,13 +63,17 @@ typedef struct needed_libs_s {
void free_neededlib(needed_libs_t* needed);
needed_libs_t* new_neededlib(int n);
+needed_libs_t* copy_neededlib(needed_libs_t* needed);
void add1_neededlib(needed_libs_t* needed);
+void add1lib_neededlib(needed_libs_t* needed, library_t* lib, const char* name);
typedef struct base_segment_s {
uintptr_t base;
uint64_t limit;
- int present;
pthread_key_t key;
+ uint8_t present;
+ uint8_t is32bits;
+ uint8_t key_init;
} base_segment_t;
typedef struct box64context_s {
@@ -107,10 +117,12 @@ typedef struct box64context_s {
lib_t *maplib; // lib and symbols handling
lib_t *local_maplib; // libs and symbols openned has local (only collection of libs, no symbols)
- dic_t *versym; // dictionnary of versionned symbols
+ dic_t *versym; // dictionnary of versioned symbols
+ kh_mapsymbols_t *globdata; // GLOBAL_DAT relocation for COPY mapping in main elf
kh_threadstack_t *stacksizes; // stack sizes attributes for thread (temporary)
bridge_t *system; // other bridges
+ uintptr_t exit_bridge; // exit bridge value
uintptr_t vsyscall; // vsyscall bridge value
uintptr_t vsyscalls[3]; // the 3 x86 VSyscall pseudo bridges (mapped at 0xffffffffff600000+)
dlprivate_t *dlprivate; // dlopen library map
@@ -118,8 +130,6 @@ typedef struct box64context_s {
kh_symbolmap_t *almymap; // link to the mysymbolmap if libOpenAL
kh_symbolmap_t *vkwrappers; // the map of wrapper for VulkanProcs (TODO: check SDL2)
kh_symbolmap_t *vkmymap; // link to the mysymbolmap of libGL
- kh_defaultversion_t *globaldefver; // the global default version for symbols (the XXX@@vvvv of symbols)
- kh_defaultversion_t *weakdefver; // the weak default version for symbols (the XXX@@vvvv of symbols)
vkprocaddess_t vkprocaddress;
#ifndef DYNAREC
@@ -129,13 +139,25 @@ typedef struct box64context_s {
pthread_mutex_t mutex_thread;
pthread_mutex_t mutex_bridge;
#else
+ #ifdef USE_CUSTOM_MUTEX
uint32_t mutex_dyndump;
uint32_t mutex_trace;
uint32_t mutex_tls;
uint32_t mutex_thread;
uint32_t mutex_bridge;
+ #else
+ pthread_mutex_t mutex_dyndump;
+ pthread_mutex_t mutex_trace;
+ pthread_mutex_t mutex_tls;
+ pthread_mutex_t mutex_thread;
+ pthread_mutex_t mutex_bridge;
+ #endif
uintptr_t max_db_size; // the biggest (in x86_64 instructions bytes) built dynablock
int trace_dynarec;
+ pthread_mutex_t mutex_lock; // this is for the Test interpreter
+ #ifdef __riscv
+ uint32_t mutex_16b;
+ #endif
#endif
library_t *libclib; // shortcut to libc library (if loaded, so probably yes)
@@ -148,15 +170,15 @@ typedef struct box64context_s {
void* sdl2allocrw; // SDL2 AllocRW/FreeRW function
void* sdl2freerw;
- int deferedInit;
- elfheader_t **deferedInitList;
- int deferedInitSz;
- int deferedInitCap;
+ int deferredInit;
+ elfheader_t **deferredInitList;
+ int deferredInitSz;
+ int deferredInitCap;
pthread_key_t tlskey; // then tls key to have actual tlsdata
void* tlsdata; // the initial global tlsdata
int64_t tlssize; // wanted size of tlsdata
- base_segment_t segtls[4]; // only handling 0/1/2 descriptors (3 is internal use)
+ base_segment_t segtls[16];
uintptr_t *auxval_start;
@@ -165,6 +187,7 @@ typedef struct box64context_s {
int clean_cap;
zydis_dec_t *dec; // trace
+ zydis_dec_t *dec32; // trace
int forked; // how many forks... cleanup only when < 0
@@ -191,12 +214,12 @@ typedef struct box64context_s {
} box64context_t;
-#ifndef DYNAREC
+#ifndef USE_CUSTOM_MUTEX
#define mutex_lock(A) pthread_mutex_lock(A)
#define mutex_trylock(A) pthread_mutex_trylock(A)
#define mutex_unlock(A) pthread_mutex_unlock(A)
#else
-int GetTID();
+int GetTID(void);
#define mutex_lock(A) {uint32_t tid = (uint32_t)GetTID(); while(native_lock_storeifnull_d(A, tid)) sched_yield();}
#define mutex_trylock(A) native_lock_storeifnull_d(A, (uint32_t)GetTID())
#define mutex_unlock(A) native_lock_storeifref_d(A, 0, (uint32_t)GetTID())
@@ -214,16 +237,18 @@ void print_cycle_log(int loglevel);
// return the index of the added header
int AddElfHeader(box64context_t* ctx, elfheader_t* head);
+// remove an elf from list (but list is never reduced, so there can be holes)
+void RemoveElfHeader(box64context_t* ctx, elfheader_t* head);
// return the tlsbase (negative) for the new TLS partition created (no partition index is stored in the context)
int AddTLSPartition(box64context_t* context, int tlssize);
// defined in fact in threads.c
void thread_set_emu(x64emu_t* emu);
-x64emu_t* thread_get_emu();
+x64emu_t* thread_get_emu(void);
// unlock mutex that are locked by current thread (for signal handling). Return a mask of unlock mutex
-int unlockMutex();
+int unlockMutex(void);
// relock the muxtex that were unlocked
void relockMutex(int locks);
diff --git a/src/include/box64stack.h b/src/include/box64stack.h
index 997e064..0607f23 100755..100644
--- a/src/include/box64stack.h
+++ b/src/include/box64stack.h
@@ -9,11 +9,4 @@ typedef struct x64emu_s x64emu_t;
int CalcStackSize(box64context_t *context);
void SetupInitialStack(x64emu_t *emu);
-uint16_t Pop16(x64emu_t *emu);
-void Push16(x64emu_t *emu, uint16_t v);
-uint32_t Pop32(x64emu_t *emu);
-void Push32(x64emu_t *emu, uint32_t v);
-uint64_t Pop64(x64emu_t *emu);
-void Push64(x64emu_t *emu, uint64_t v);
-
-#endif //__BOX64_STACK_H_ \ No newline at end of file
+#endif //__BOX64_STACK_H_
diff --git a/src/include/bridge.h b/src/include/bridge.h
index 9859ae8..0c23808 100755..100644
--- a/src/include/bridge.h
+++ b/src/include/bridge.h
@@ -7,13 +7,13 @@ typedef struct bridge_s bridge_t;
typedef struct box64context_s box64context_t;
typedef void (*wrapper_t)(x64emu_t* emu, uintptr_t fnc);
-bridge_t *NewBridge();
+bridge_t *NewBridge(void);
void FreeBridge(bridge_t** bridge);
uintptr_t AddBridge(bridge_t* bridge, wrapper_t w, void* fnc, int N, const char* name);
uintptr_t CheckBridged(bridge_t* bridge, void* fnc);
uintptr_t AddCheckBridge(bridge_t* bridge, wrapper_t w, void* fnc, int N, const char* name);
-uintptr_t AddAutomaticBridge(x64emu_t* emu, bridge_t* bridge, wrapper_t w, void* fnc, int N);
+uintptr_t AddAutomaticBridge(x64emu_t* emu, bridge_t* bridge, wrapper_t w, void* fnc, int N, const char* name);
void* GetNativeFnc(uintptr_t fnc);
void* GetNativeFncOrFnc(uintptr_t fnc);
@@ -22,13 +22,13 @@ uintptr_t AddVSyscall(bridge_t* bridge, int num);
int hasAlternate(void* addr);
void* getAlternate(void* addr);
void addAlternate(void* addr, void* alt);
-void cleanAlternate();
+void cleanAlternate(void);
#ifdef HAVE_TRACE
const char* getBridgeName(void* addr);
#endif
-void init_bridge_helper();
-void fini_bridge_helper();
+void init_bridge_helper(void);
+void fini_bridge_helper(void);
#endif //__BRIDGE_H_ \ No newline at end of file
diff --git a/src/include/callback.h b/src/include/callback.h
index eecbc3d..48d360c 100755..100644
--- a/src/include/callback.h
+++ b/src/include/callback.h
@@ -5,13 +5,14 @@
typedef struct x64emu_s x64emu_t;
-uint64_t RunFunction(box64context_t *context, uintptr_t fnc, int nargs, ...);
+uint64_t RunFunction(uintptr_t fnc, int nargs, ...);
+uint64_t RunFunctionFmt(uintptr_t fnc, const char* fmt, ...);
// save all modified register
-uint64_t RunSafeFunction(box64context_t *context, uintptr_t fnc, int nargs, ...);
+uint64_t RunSafeFunction(uintptr_t fnc, int nargs, ...);
// use emu state to run function
uint64_t RunFunctionWithEmu(x64emu_t *emu, int QuitOnLongJumpExit, uintptr_t fnc, int nargs, ...);
// using the Windows x64 calling convention
-uint64_t RunFunctionWindows(box64context_t *context, uintptr_t fnc, int nargs, ...);
+uint64_t RunFunctionWindows(uintptr_t fnc, int nargs, ...);
#endif //__CALLBACK_H__ \ No newline at end of file
diff --git a/src/include/complext.h b/src/include/complext.h
new file mode 100644
index 0000000..60d2215
--- /dev/null
+++ b/src/include/complext.h
@@ -0,0 +1,33 @@
+#ifndef __COMPLEX_T__H_
+#define __COMPLEX_T__H_
+
+typedef struct complex_s { double r; double i;} complex_t;
+typedef struct complexf_s { float r; float i;} complexf_t;
+
+#endif //__COMPLEX_T__H_
+
+#ifdef COMPLEX_IMPL
+#ifndef __COMPLEX_T_IMPL_H_
+#define __COMPLEX_T_IMPL_H_
+static inline complexf_t to_complexf(x64emu_t* emu, int i) {
+ complexf_t ret;
+ ret.r = emu->xmm[i].f[0];
+ ret.i = emu->xmm[i].f[1];
+ return ret;
+}
+static inline complex_t to_complex(x64emu_t* emu, int i) {
+ complex_t ret;
+ ret.r = emu->xmm[i].d[0];
+ ret.i = emu->xmm[i+1].d[0];
+ return ret;
+}
+static inline void from_complexf(x64emu_t* emu, complexf_t v) {
+ emu->xmm[0].f[0]=v.r;
+ emu->xmm[0].f[1]=v.i;
+}
+static inline void from_complex(x64emu_t* emu, complex_t v) {
+ emu->xmm[0].d[0]=v.r;
+ emu->xmm[1].d[0]=v.i;
+}
+#endif // __COMPLEX_T_IMPL_H_
+#endif // COMPLEX_IMPL
diff --git a/src/include/cpu_info.h b/src/include/cpu_info.h
index 18c4a1b..18c4a1b 100755..100644
--- a/src/include/cpu_info.h
+++ b/src/include/cpu_info.h
diff --git a/src/include/custommem.h b/src/include/custommem.h
index e03db81..13e73c4 100644
--- a/src/include/custommem.h
+++ b/src/include/custommem.h
@@ -26,12 +26,13 @@ void addDBFromAddressRange(uintptr_t addr, size_t size);
void cleanDBFromAddressRange(uintptr_t addr, size_t size, int destroy);
dynablock_t* getDB(uintptr_t idx);
+int getNeedTest(uintptr_t idx);
int addJumpTableIfDefault64(void* addr, void* jmp); // return 1 if write was succesfull
int setJumpTableIfRef64(void* addr, void* jmp, void* ref); // return 1 if write was succesfull
void setJumpTableDefault64(void* addr);
void setJumpTableDefaultRef64(void* addr, void* jmp);
int isJumpTableDefault64(void* addr);
-uintptr_t getJumpTable64();
+uintptr_t getJumpTable64(void);
uintptr_t getJumpTableAddress64(uintptr_t addr);
uintptr_t getJumpAddress64(uintptr_t addr);
@@ -51,9 +52,10 @@ uintptr_t getJumpAddress64(uintptr_t addr);
#define PROT_DYNAREC 0x80
#define PROT_DYNAREC_R 0x40
-#define PROT_MMAP 0x20
-#define PROT_DYN (PROT_DYNAREC | PROT_DYNAREC_R)
-#define PROT_CUSTOM (PROT_DYNAREC | PROT_DYNAREC_R | PROT_MMAP)
+#define PROT_NOPROT 0x20
+#define PROT_MMAP 0x10
+#define PROT_DYN (PROT_DYNAREC | PROT_DYNAREC_R | PROT_NOPROT)
+#define PROT_CUSTOM (PROT_DYNAREC | PROT_DYNAREC_R | PROT_MMAP | PROT_NOPROT)
void updateProtection(uintptr_t addr, size_t size, uint32_t prot);
void setProtection(uintptr_t addr, size_t size, uint32_t prot);
@@ -62,7 +64,7 @@ void freeProtection(uintptr_t addr, size_t size);
void refreshProtection(uintptr_t addr);
uint32_t getProtection(uintptr_t addr);
int getMmapped(uintptr_t addr);
-void loadProtectionFromMap();
+void loadProtectionFromMap(void);
#ifdef DYNAREC
void protectDB(uintptr_t addr, size_t size);
void unprotectDB(uintptr_t addr, size_t size, int mark); // if mark==0, the blocks are not marked as potentially dirty
@@ -77,7 +79,7 @@ void* find47bitBlock(size_t size);
void* find47bitBlockNearHint(void* hint, size_t size);
// unlock mutex that are locked by current thread (for signal handling). Return a mask of unlock mutex
-int unlockCustommemMutex();
+int unlockCustommemMutex(void);
// relock the muxtex that were unlocked
void relockCustommemMutex(int locks);
diff --git a/src/include/debug.h b/src/include/debug.h
index e13de64..8397d6c 100755..100644
--- a/src/include/debug.h
+++ b/src/include/debug.h
@@ -23,15 +23,23 @@ extern int box64_dynarec_x87double;
extern int box64_dynarec_safeflags;
extern int box64_dynarec_callret;
extern int box64_dynarec_bleeding_edge;
+extern int box64_dynarec_jvm;
extern int box64_dynarec_hotpage;
extern int box64_dynarec_fastpage;
extern int box64_dynarec_wait;
+extern int box64_dynarec_test;
+extern int box64_dynarec_missing;
#ifdef ARM64
extern int arm64_asimd;
extern int arm64_aes;
extern int arm64_pmull;
extern int arm64_crc32;
extern int arm64_atomics;
+#elif defined(RV64)
+extern int rv64_zba;
+extern int rv64_zbb;
+extern int rv64_zbc;
+extern int rv64_zbs;
#endif
#endif
extern int box64_libcef;
@@ -95,7 +103,7 @@ void printf_ftrace(const char* fmt, ...);
#define EXPORTDYN
#endif
-void init_malloc_hook();
+void init_malloc_hook(void);
extern size_t(*box_malloc_usable_size)(void*);
#ifdef ANDROID
extern void*(*__libc_malloc)(size_t);
diff --git a/src/include/dictionnary.h b/src/include/dictionnary.h
index e2ec146..efa5e1c 100755..100644
--- a/src/include/dictionnary.h
+++ b/src/include/dictionnary.h
@@ -4,7 +4,7 @@
typedef void dic_t;
-dic_t *NewDictionnary();
+dic_t *NewDictionnary(void);
void FreeDictionnary(dic_t **dic);
const char* AddDictionnary(dic_t* dic, const char* s);
diff --git a/src/include/dynablock.h b/src/include/dynablock.h
index 1868dee..757ca4a 100755..100644
--- a/src/include/dynablock.h
+++ b/src/include/dynablock.h
@@ -9,14 +9,16 @@ void FreeDynablock(dynablock_t* db, int need_lock);
void MarkDynablock(dynablock_t* db);
void MarkRangeDynablock(dynablock_t* db, uintptr_t addr, uintptr_t size);
int FreeRangeDynablock(dynablock_t* db, uintptr_t addr, uintptr_t size);
+void FreeInvalidDynablock(dynablock_t* db, int need_lock);
+dynablock_t* InvalidDynablock(dynablock_t* db, int need_lock);
dynablock_t* FindDynablockFromNativeAddress(void* addr); // defined in box64context.h
// Handling of Dynarec block (i.e. an exectable chunk of x64 translated code)
-dynablock_t* DBGetBlock(x64emu_t* emu, uintptr_t addr, int create); // return NULL if block is not found / cannot be created. Don't create if create==0
-dynablock_t* DBAlternateBlock(x64emu_t* emu, uintptr_t addr, uintptr_t filladdr);
+dynablock_t* DBGetBlock(x64emu_t* emu, uintptr_t addr, int create, int is32bits); // return NULL if block is not found / cannot be created. Don't create if create==0
+dynablock_t* DBAlternateBlock(x64emu_t* emu, uintptr_t addr, uintptr_t filladdr, int is32bits);
// for use in signal handler
-void cancelFillBlock();
+void cancelFillBlock(void);
#endif //__DYNABLOCK_H_ \ No newline at end of file
diff --git a/src/include/dynarec.h b/src/include/dynarec.h
index a68c6d6..64da604 100755..100644
--- a/src/include/dynarec.h
+++ b/src/include/dynarec.h
@@ -5,4 +5,7 @@ typedef struct x64emu_s x64emu_t;
void DynaCall(x64emu_t* emu, uintptr_t addr); // try to use DynaRec... Fallback to EmuCall if no dynarec available
+void x64test_init(x64emu_t* ref, uintptr_t ip);
+void x64test_check(x64emu_t* ref, uintptr_t ip);
+
#endif // __DYNAREC_H_ \ No newline at end of file
diff --git a/src/include/dynarec_native.h b/src/include/dynarec_native.h
index eff5a6b..05bfc3b 100755..100644
--- a/src/include/dynarec_native.h
+++ b/src/include/dynarec_native.h
@@ -5,9 +5,22 @@ typedef struct dynablock_s dynablock_t;
typedef struct x64emu_s x64emu_t;
typedef struct instsize_s instsize_t;
+//#define USE_CUSTOM_MEM
+#ifdef USE_CUSTOM_MEM
+#define dynaMalloc customMalloc
+#define dynaCalloc customCalloc
+#define dynaRealloc customRealloc
+#define dynaFree customFree
+#else
+#define dynaMalloc box_malloc
+#define dynaCalloc box_calloc
+#define dynaRealloc box_realloc
+#define dynaFree box_free
+#endif
+
void addInst(instsize_t* insts, size_t* size, int x64_size, int native_size);
void CancelBlock64(int need_lock);
-void* FillBlock64(dynablock_t* block, uintptr_t addr);
+void* FillBlock64(dynablock_t* block, uintptr_t addr, int alternate, int is32bits);
#endif //__DYNAREC_ARM_H_ \ No newline at end of file
diff --git a/src/include/dynarec_rv64.h b/src/include/dynarec_rv64.h
new file mode 100644
index 0000000..dd3b734
--- /dev/null
+++ b/src/include/dynarec_rv64.h
@@ -0,0 +1,10 @@
+#ifndef __DYNAREC_RV64_H_
+#define __DYNAREC_RV64_H_
+
+typedef struct dynablock_s dynablock_t;
+typedef struct x64emu_s x64emu_t;
+
+void CancelBlock64(void);
+void* FillBlock64(dynablock_t* block, uintptr_t addr);
+
+#endif //__DYNAREC_RV64_H_ \ No newline at end of file
diff --git a/src/include/elfload_dump.h b/src/include/elfload_dump.h
index ce0e9c1..ce0e9c1 100755..100644
--- a/src/include/elfload_dump.h
+++ b/src/include/elfload_dump.h
diff --git a/src/include/elfloader.h b/src/include/elfloader.h
index d5116f5..ca8839d 100755..100644
--- a/src/include/elfloader.h
+++ b/src/include/elfloader.h
@@ -9,6 +9,7 @@ typedef struct kh_mapsymbols_s kh_mapsymbols_t;
typedef struct box64context_s box64context_t;
typedef struct x64emu_s x64emu_t;
typedef struct needed_libs_s needed_libs_t;
+typedef struct kh_defaultversion_s kh_defaultversion_t;
#ifdef DYNAREC
typedef struct dynablock_s dynablock_t;
#endif
@@ -24,6 +25,7 @@ int CalcLoadAddr(elfheader_t* head);
int AllocElfMemory(box64context_t* context, elfheader_t* head, int mainbin);
void FreeElfMemory(elfheader_t* head);
int LoadElfMemory(FILE* f, box64context_t* context, elfheader_t* head);
+int isElfHasNeededVer(elfheader_t* head, const char* libname, elfheader_t* verneeded);
int ReloadElfMemory(FILE* f, box64context_t* context, elfheader_t* head);
int RelocateElf(lib_t *maplib, lib_t* local_maplib, int bindnow, elfheader_t* head);
int RelocateElfPlt(lib_t *maplib, lib_t* local_maplib, int bindnow, elfheader_t* head);
@@ -37,7 +39,7 @@ uintptr_t GetElfFini(elfheader_t* h);
void RefreshElfTLS(elfheader_t* h);
void RunElfInit(elfheader_t* h, x64emu_t *emu);
void RunElfFini(elfheader_t* h, x64emu_t *emu);
-void RunDeferedElfInit(x64emu_t *emu);
+void RunDeferredElfInit(x64emu_t *emu);
void MarkElfInitDone(elfheader_t* h);
void* GetBaseAddress(elfheader_t* h);
void* GetElfDelta(elfheader_t* h);
@@ -60,15 +62,19 @@ int ElfCheckIfUseTCMallocMinimal(elfheader_t* h); // return 1 if tcmalloc is u
const char* GetSymbolVersion(elfheader_t* h, int version);
const char* GetParentSymbolVersion(elfheader_t* h, int index);
-const char* VersionnedName(const char* name, int ver, const char* vername);
-int SameVersionnedSymbol(const char* name1, int ver1, const char* vername1, const char* name2, int ver2, const char* vername2);
+const char* VersionedName(const char* name, int ver, const char* vername);
+int SameVersionedSymbol(const char* name1, int ver1, const char* vername1, const char* name2, int ver2, const char* vername2);
int GetVersionIndice(elfheader_t* h, const char* vername);
+int GetNeededVersionCnt(elfheader_t* h, const char* libname);
+const char* GetNeededVersionString(elfheader_t* h, const char* libname, int idx);
kh_mapsymbols_t* GetMapSymbols(elfheader_t* h);
kh_mapsymbols_t* GetWeakSymbols(elfheader_t* h);
kh_mapsymbols_t* GetLocalSymbols(elfheader_t* h);
+kh_defaultversion_t* GetGlobalDefaultVersion(elfheader_t* h);
+kh_defaultversion_t* GetWeakDefaultVersion(elfheader_t* h);
-void* GetNativeSymbolUnversionned(void* lib, const char* name);
+void* GetNativeSymbolUnversioned(void* lib, const char* name);
void AddMainElfToLinkmap(elfheader_t* lib);
diff --git a/src/include/fileutils.h b/src/include/fileutils.h
index c666f0b..2e983c7 100755..100644
--- a/src/include/fileutils.h
+++ b/src/include/fileutils.h
@@ -19,13 +19,13 @@ int FileIsX64ELF(const char* filename);
int FileIsShell(const char* filename);
// return temp folder (will return /tmp if nothing is correct)
-const char* GetTmpDir();
+const char* GetTmpDir(void);
// will lower case the string and return a copy. Nothing fancy here, just A..Z transformed to a..z, rest is untouched
char* LowerCase(const char* s);
#if defined(RPI) || defined(RK3399) || defined(RK3326)
-void sanitize_mojosetup_gtk_background();
+void sanitize_mojosetup_gtk_background(void);
#endif
#endif //__FILEUTILS_H_ \ No newline at end of file
diff --git a/src/include/globalsymbols.h b/src/include/globalsymbols.h
index fc2753e..d0eb301 100755..100644
--- a/src/include/globalsymbols.h
+++ b/src/include/globalsymbols.h
@@ -2,18 +2,18 @@
#define _GLOBAL_SYMBOLS_H_
//GTK stuff
-void my_checkGlobalGdkDisplay();
-void my_setGlobalGThreadsInit();
+void my_checkGlobalGdkDisplay(void);
+void my_setGlobalGThreadsInit(void);
-//void** my_GetGTKDisplay();
-void** my_GetGthreadsGotInitialized(); // defined in wrappedgthread2
+//void** my_GetGTKDisplay(void);
+void** my_GetGthreadsGotInitialized(void); // defined in wrappedgthread2
// NCurse / TInfo
-void my_checkGlobalTInfo();
-void my_updateGlobalTInfo();
+void my_checkGlobalTInfo(void);
+void my_updateGlobalTInfo(void);
// getopt
-void my_checkGlobalOpt();
-void my_updateGlobalOpt();
+void my_checkGlobalOpt(void);
+void my_updateGlobalOpt(void);
#endif //_GLOBAL_SYMBOLS_H_ \ No newline at end of file
diff --git a/src/include/gtkclass.h b/src/include/gtkclass.h
index 6e8d302..8a88a0d 100755..100644
--- a/src/include/gtkclass.h
+++ b/src/include/gtkclass.h
@@ -55,6 +55,41 @@ typedef struct my_GInitiallyUnownedClass_s
void* pdummy[6];
} my_GInitiallyUnownedClass_t;
+typedef struct my_GamesScoresImporterClass_s
+{
+ my_GObjectClass_t parent_class;
+ void (*importOldScores) (void *self, void* context, void* new_scores_dir, void *error);
+}my_GamesScoresImporterClass_t;
+
+typedef struct my_GApplicationClass_s
+{
+ void* construct_properties;
+ void (* startup) (void* application);
+ void (* activate) (void* application);
+ void (* open) (void* application, void* files, int n_files, void* hint);
+ int (* command_line) (void* application, void* command_line);
+ int (* local_command_line) (void* application, void* arguments, void* exit_status);
+ void (* before_emit) (void* application, void* platform_data);
+ void (* after_emit) (void* application, void* platform_data);
+ void (* add_platform_data) (void* application, void* builder);
+ void (* quit_mainloop) (void* application);
+ void (* run_mainloop) (void* application);
+ void (* shutdown) (void* application);
+ int (* dbus_register) (void* application, void* connection, void* object_path, void* error);
+ void (* dbus_unregister) (void* appvoidlication, void* connection, void* object_path);
+ int (* handle_local_options) (void* application, void* options);
+ int (* name_lost) (void* application);
+ uint32_t flags;
+ void* pdummy[6];
+} my_GApplicationClass_t;
+
+typedef struct my_GtkApplicationClass_s
+{
+ my_GApplicationClass_t parent_class;
+ void (*window_added) (void* application, void* window);
+ void (*window_removed) (void* application, void* window);
+} my_GtkApplicationClass_t;
+
typedef struct my_GtkObjectClass_s
{
my_GObjectClass_t parent_class;
@@ -283,6 +318,7 @@ typedef struct my_GtkActionClass_s
void (* connect_proxy) (void* action, void* proxy);
void (* disconnect_proxy) (void* action, void* proxy);
void* (* create_menu) (void* action);
+ void (*_gtk_reserved1) (void);
void (*_gtk_reserved2) (void);
void (*_gtk_reserved3) (void);
void (*_gtk_reserved4) (void);
@@ -293,6 +329,21 @@ typedef struct my_GtkMisc2Class_s
my_GtkWidget2Class_t parent_class;
} my_GtkMisc2Class_t;
+typedef struct my_GtkMisc3Class_s
+{
+ my_GtkWidget3Class_t parent_class;
+ void (*_gtk_reserved1) (void);
+ void (*_gtk_reserved2) (void);
+ void (*_gtk_reserved3) (void);
+ void (*_gtk_reserved4) (void);
+} my_GtkMisc3Class_t;
+
+typedef struct my_GtkMenuButtonClass_s
+{
+ my_GtkWidget3Class_t parent_class;
+ void (* activate) (void *self);
+}my_GtkMenuButtonClass_t;
+
typedef struct my_GtkLabel2Class_s
{
my_GtkMisc2Class_t parent_class;
@@ -305,6 +356,23 @@ typedef struct my_GtkLabel2Class_s
void (*_gtk_reserved3) (void);
} my_GtkLabel2Class_t;
+typedef struct my_GtkLabel3Class_s
+{
+ my_GtkMisc3Class_t parent_class;
+ void (* move_cursor) (void* label, int step, int count, int extend_selection);
+ void (* copy_clipboard) (void* label);
+ void (* populate_popup) (void* label, void* menu);
+ int (*activate_link) (void* label, void* uri);
+ void (*_gtk_reserved1) (void);
+ void (*_gtk_reserved2) (void);
+ void (*_gtk_reserved3) (void);
+ void (*_gtk_reserved4) (void);
+ void (*_gtk_reserved5) (void);
+ void (*_gtk_reserved6) (void);
+ void (*_gtk_reserved7) (void);
+ void (*_gtk_reserved8) (void);
+} my_GtkLabel3Class_t;
+
typedef struct my_GtkTreeView2Class_s
{
my_GtkContainer2Class_t parent_class;
@@ -340,6 +408,15 @@ typedef struct my_GtkBin2Class_s
void (*_gtk_reserved4) (void);
} my_GtkBin2Class_t;
+typedef struct my_GtkBin3Class_s
+{
+ my_GtkContainer3Class_t parent_class;
+ void (*_gtk_reserved1) (void);
+ void (*_gtk_reserved2) (void);
+ void (*_gtk_reserved3) (void);
+ void (*_gtk_reserved4) (void);
+} my_GtkBin3Class_t;
+
typedef struct my_GtkWindow2Class_s {
my_GtkBin2Class_t parent_class;
void (* set_focus) (void* window, void* focus);
@@ -354,6 +431,47 @@ typedef struct my_GtkWindow2Class_s {
void (*_gtk_reserved4) (void);
} my_GtkWindow2Class_t;
+typedef struct my_GtkWindow3Class_s
+{
+ my_GtkBin3Class_t parent_class;
+ void (* set_focus) (void* window, void* focus);
+ void (* activate_focus) (void* window);
+ void (* activate_default) (void* window);
+ void (* keys_changed) (void* window);
+ int (* enable_debugging) (void* window, int toggle);
+ void (* _gtk_reserved1) (void);
+ void (* _gtk_reserved2) (void);
+ void (* _gtk_reserved3) (void);
+}my_GtkWindow3Class_t;
+
+typedef struct my_GtkApplicationWindowClass_s
+{
+ my_GtkWindow3Class_t parent_class;
+}my_GtkApplicationWindowClass_t;
+
+typedef struct my_GtkListBoxClass_s
+{
+ my_GtkContainer3Class_t parent_class;
+ void (*row_selected) (void *box, void *row);
+ void (*row_activated) (void *box, void *row);
+ void (*activate_cursor_row) (void *box);
+ void (*toggle_cursor_row) (void *box);
+ void (*move_cursor) (void *box, int step, int count);
+ void (*selected_rows_changed) (void *box);
+ void (*select_all) (void *box);
+ void (*unselect_all) (void *box);
+ void (* _gtk_reserved1) (void);
+ void (* _gtk_reserved2) (void);
+ void (* _gtk_reserved3) (void);
+}my_GtkListBoxClass_t;
+
+typedef struct my_GtkListBoxRowClass_s {
+ my_GtkBin3Class_t parent_class;
+ void (* activate) (void* row);
+ void (* _gtk_reserved1) (void);
+ void (* _gtk_reserved2) (void);
+}my_GtkListBoxRowClass_t;
+
typedef struct my_GtkButton2Class_s {
my_GtkBin2Class_t parent_class;
void (* pressed) (void *button);
@@ -368,6 +486,20 @@ typedef struct my_GtkButton2Class_s {
void (*_gtk_reserved4) (void);
} my_GtkButton2Class_t;
+typedef struct my_GtkButton3Class_s {
+ my_GtkBin3Class_t parent_class;
+ void (* pressed) (void *button);
+ void (* released) (void *button);
+ void (* clicked) (void *button);
+ void (* enter) (void *button);
+ void (* leave) (void *button);
+ void (* activate) (void *button);
+ void (*_gtk_reserved1) (void);
+ void (*_gtk_reserved2) (void);
+ void (*_gtk_reserved3) (void);
+ void (*_gtk_reserved4) (void);
+} my_GtkButton3Class_t;
+
typedef struct my_GtkToggleButton2Class_s {
my_GtkButton2Class_t parent_class;
void (* toggled) (void* toggle_button);
@@ -517,6 +649,53 @@ typedef struct my_GtkTextView3Class_s {
void (*_gtk_reserved4) (void);
} my_GtkTextView3Class_t;
+typedef struct my_GtkGrid3Class_s {
+ my_GtkContainer3Class_t parent_class;
+ void (* _gtk_reserved1) (void);
+ void (* _gtk_reserved2) (void);
+ void (* _gtk_reserved3) (void);
+ void (* _gtk_reserved4) (void);
+ void (* _gtk_reserved5) (void);
+ void (* _gtk_reserved6) (void);
+ void (* _gtk_reserved7) (void);
+ void (* _gtk_reserved8) (void);
+}my_GtkGrid3Class_t;
+
+typedef struct my_GtkEventControllerClass_s {
+ my_GObjectClass_t parent_class;
+ void (* set_widget) (void *controller, void *widget);
+ void (* unset_widget) (void *controller);
+ int (* handle_event) (void *controller, void *event, double x, double y);
+ void (* reset) (void *controller);
+ void (* handle_crossing) (void *controller, void *crossing, double x, double y);
+ int (* filter_event) (void *controller, void *event);
+ void* padding[10];
+}my_GtkEventControllerClass_t;
+
+typedef struct my_GtkGestureClass_s {
+ my_GtkEventControllerClass_t parent_class;
+ int (* check) (void *gesture);
+ void (* begin) (void *gesture, void *sequence);
+ void (* update) (void *gesture, void *sequence);
+ void (* end) (void *gesture, void *sequence);
+ void (* cancel) (void *gesture, void *sequence);
+ void (* sequence_state_changed) (void *gesture, void *sequence, int state);
+ void* padding[10];
+}my_GtkGestureClass_t;
+
+typedef struct my_GtkGestureSingleClass_s {
+ my_GtkGestureClass_t parent_class;
+ void* padding[10];
+}my_GtkGestureSingleClass_t;
+
+typedef struct my_GtkGestureLongPressClass_s {
+ my_GtkGestureSingleClass_t parent_class;
+ void (* pressed) (void *gesture, double x, double y);
+ void (* cancelled) (void *gesture);
+ /*< private >*/
+ void* padding[10];
+}my_GtkGestureLongPressClass_t;
+
typedef struct my_MetaFrames2Class_s
{
my_GtkWindow2Class_t parent_class;
@@ -599,6 +778,22 @@ typedef struct my_GstAllocatorClass_s {
void* _gst_reserved[4];
} my_GstAllocatorClass_t;
+typedef struct my_GstTaskPoolClass_s {
+ my_GstObjectClass_t parent_class;
+ void (*prepare) (void* pool, void* error);
+ void (*cleanup) (void* pool);
+ void* (*push) (void* pool, void* func, void* user_data, void* error);
+ void (*join) (void* pool, void* id);
+ void (*dispose_handle) (void* pool, void* id);
+ void* _gst_reserved[4-1];
+} my_GstTaskPoolClass_t;
+
+typedef struct my_GDBusProxyClass_s {
+ my_GObjectClass_t parent_class;
+ void (*g_properties_changed) (void* proxy, void* changed_properties, const char* const* invalidated_properties);
+ void (*g_signal) (void* proxy, const char* sender_name, const char* signal_name, void* parameters);
+ void* padding[32];
+} my_GDBusProxyClass_t;
// GTypeValueTable
typedef struct my_GTypeValueTable_s {
@@ -652,11 +847,14 @@ my_GTypeInfo_t* findFreeGTypeInfo(my_GTypeInfo_t* fcts, size_t parent);
my_GtkTypeInfo_t* findFreeGtkTypeInfo(my_GtkTypeInfo_t* fcts, size_t parent);
void InitGTKClass(bridge_t *bridge);
-void FiniGTKClass();
+void FiniGTKClass(void);
#define GTKCLASSES() \
GTKCLASS(GObject) \
GTKCLASS(GInitiallyUnowned) \
+GTKCLASS(GamesScoresImporter) \
+GTKCLASS(GApplication) \
+GTKCLASS(GtkApplication) \
GTKCLASS(GtkObject) \
GTKCLASS(GtkWidget2) \
GTKCLASS(GtkWidget3) \
@@ -664,13 +862,21 @@ GTKCLASS(GtkContainer2) \
GTKCLASS(GtkContainer3) \
GTKCLASS(GtkAction) \
GTKCLASS(GtkLabel2) \
+GTKCLASS(GtkLabel3) \
GTKCLASS(GtkMisc2) \
+GTKCLASS(GtkMisc3) \
GTKCLASS(GtkTreeView2) \
GTKCLASS(GtkBin2) \
+GTKCLASS(GtkBin3) \
GTKCLASS(GtkWindow2) \
+GTKCLASS(GtkWindow3) \
GTKCLASS(GtkTable2) \
GTKCLASS(GtkFixed2) \
+GTKCLASS(GtkApplicationWindow) \
+GTKCLASS(GtkListBox) \
+GTKCLASS(GtkListBoxRow) \
GTKCLASS(GtkButton2) \
+GTKCLASS(GtkButton3) \
GTKCLASS(GtkComboBox2) \
GTKCLASS(GtkToggleButton2) \
GTKCLASS(GtkCheckButton2) \
@@ -683,12 +889,19 @@ GTKCLASS(GtkMenuShell2) \
GTKCLASS(GtkMenuBar2) \
GTKCLASS(GtkTextView2) \
GTKCLASS(GtkTextView3) \
+GTKCLASS(GtkGrid3) \
+GTKCLASS(GtkEventController) \
+GTKCLASS(GtkGesture) \
+GTKCLASS(GtkGestureSingle) \
+GTKCLASS(GtkGestureLongPress) \
GTKCLASS(MetaFrames2) \
GTKCLASS(GDBusObjectManagerClient) \
GTKCLASS(AtkObject) \
GTKCLASS(AtkUtil) \
GTKCLASS(GstObject) \
GTKCLASS(GstAllocator) \
+GTKCLASS(GstTaskPool) \
+GTKCLASS(GDBusProxy) \
#define GTKCLASS(A) void Set##A##ID(size_t id);
GTKCLASSES()
@@ -717,4 +930,4 @@ int my_signal_cb(void* a, void* b, void* c, void* d);
void my_add_signal_offset(size_t klass, uint32_t offset, int n);
-#endif //__GTKCLASS_H__ \ No newline at end of file
+#endif //__GTKCLASS_H__
diff --git a/src/include/khash.h b/src/include/khash.h
index 9d20a0e..9d20a0e 100755..100644
--- a/src/include/khash.h
+++ b/src/include/khash.h
diff --git a/src/include/librarian.h b/src/include/librarian.h
index 5c1fe0f..6fc8932 100755..100644
--- a/src/include/librarian.h
+++ b/src/include/librarian.h
@@ -16,21 +16,29 @@ typedef char* cstr_t;
lib_t *NewLibrarian(box64context_t* context, int ownlibs);
void FreeLibrarian(lib_t **maplib, x64emu_t* emu);
-dlprivate_t *NewDLPrivate();
+dlprivate_t *NewDLPrivate(void);
void FreeDLPrivate(dlprivate_t **lib);
box64context_t* GetLibrarianContext(lib_t* maplib);
kh_mapsymbols_t* GetGlobalData(lib_t* maplib);
-int AddNeededLib(lib_t* maplib, int local, int bindnow, needed_libs_t* needed, box64context_t* box64, x64emu_t* emu); // 0=success, 1=error
+int AddNeededLib(lib_t* maplib, int local, int bindnow, needed_libs_t* needed, elfheader_t* verneeded, box64context_t* box64, x64emu_t* emu); // 0=success, 1=error
+void RemoveNeededLib(lib_t* maplib, int local, needed_libs_t* needed, box64context_t* box64, x64emu_t* emu);
library_t* GetLibMapLib(lib_t* maplib, const char* name);
library_t* GetLibInternal(const char* name);
+void promoteLocalLibGlobal(library_t* lib);
+int isLibLocal(library_t* lib);
uintptr_t FindGlobalSymbol(lib_t *maplib, const char* name, int version, const char* vername);
-int GetNoSelfSymbolStartEnd(lib_t *maplib, const char* name, uintptr_t* start, uintptr_t* end, elfheader_t* self, size_t size, int version, const char* vername);
-int GetGlobalSymbolStartEnd(lib_t *maplib, const char* name, uintptr_t* start, uintptr_t* end, elfheader_t *self, int version, const char* vername);
-int GetGlobalNoWeakSymbolStartEnd(lib_t *maplib, const char* name, uintptr_t* start, uintptr_t* end, int version, const char* vername);
-int GetLocalSymbolStartEnd(lib_t *maplib, const char* name, uintptr_t* start, uintptr_t* end, elfheader_t *self, int version, const char* vername);
+int GetNoSelfSymbolStartEnd(lib_t *maplib, const char* name, uintptr_t* start, uintptr_t* end, elfheader_t* self, size_t size, int version, const char* vername, const char* globdefver, const char* weakdefver);
+int GetGlobalSymbolStartEnd(lib_t *maplib, const char* name, uintptr_t* start, uintptr_t* end, elfheader_t *self, int version, const char* vername, const char* globdefver, const char* weakdefver);
+int GetGlobalWeakSymbolStartEnd(lib_t *maplib, const char* name, uintptr_t* start, uintptr_t* end, elfheader_t *self, int version, const char* vername, const char* globdefver, const char* weakdefver);
+int GetGlobalNoWeakSymbolStartEnd(lib_t *maplib, const char* name, uintptr_t* start, uintptr_t* end, int version, const char* vername, const char* defver);
+int GetLocalSymbolStartEnd(lib_t *maplib, const char* name, uintptr_t* start, uintptr_t* end, elfheader_t *self, int version, const char* vername, const char* globdefver, const char* weakdefver);
elfheader_t* GetGlobalSymbolElf(lib_t *maplib, const char* name, int version, const char* vername);
-int IsGlobalNoWeakSymbolInNative(lib_t *maplib, const char* name, int version, const char* vername);
+int IsGlobalNoWeakSymbolInNative(lib_t *maplib, const char* name, int version, const char* vername, const char* defver);
+
+void MapLibRemoveLib(lib_t* maplib, library_t* lib);
+
+const char* GetMaplibDefaultVersion(lib_t *maplib, lib_t *local_maplib, int isweak, const char* symname);
const char* FindSymbolName(lib_t *maplib, void* p, void** start, uint64_t* sz, const char** libname, void** base, library_t** lib);
diff --git a/src/include/library.h b/src/include/library.h
index afe108e..b08927e 100755..100644
--- a/src/include/library.h
+++ b/src/include/library.h
@@ -15,19 +15,15 @@ typedef struct elfheader_s elfheader_t;
#define LIB_EMULATED 1
#define LIB_UNNKNOW -1
-library_t *NewLibrary(const char* path, box64context_t* box64);
+library_t *NewLibrary(const char* path, box64context_t* box64, elfheader_t* verneeded);
int AddSymbolsLibrary(lib_t* maplib, library_t* lib, x64emu_t* emu);
int FinalizeLibrary(library_t* lib, lib_t* local_maplib, int bindnow, x64emu_t* emu);
-int ReloadLibrary(library_t* lib, x64emu_t* emu);
-int FiniLibrary(library_t* lib, x64emu_t* emu);
-void InactiveLibrary(library_t* lib);
-void Free1Library(library_t **lib, x64emu_t* emu);
char* GetNameLib(library_t *lib);
int IsSameLib(library_t* lib, const char* path); // check if lib is same (path -> name)
-int GetLibGlobalSymbolStartEnd(library_t* lib, const char* name, uintptr_t* start, uintptr_t* end, size_t size, int* weak, int version, const char* vername, int local);
-int GetLibWeakSymbolStartEnd(library_t* lib, const char* name, uintptr_t* start, uintptr_t* end, size_t size, int* weak, int version, const char* vername, int local);
-int GetLibLocalSymbolStartEnd(library_t* lib, const char* name, uintptr_t* start, uintptr_t* end, size_t size, int* weak, int version, const char* vername, int local);
+int GetLibGlobalSymbolStartEnd(library_t* lib, const char* name, uintptr_t* start, uintptr_t* end, size_t size, int* weak, int version, const char* vername, int local, const char* defver);
+int GetLibWeakSymbolStartEnd(library_t* lib, const char* name, uintptr_t* start, uintptr_t* end, size_t size, int* weak, int version, const char* vername, int local, const char* defver);
+int GetLibLocalSymbolStartEnd(library_t* lib, const char* name, uintptr_t* start, uintptr_t* end, size_t size, int* weak, int version, const char* vername, int local, const char* defver);
char** GetNeededLibsNames(library_t* lib);
int GetNeededLibsN(library_t* lib);
library_t* GetNeededLib(library_t* lib, int idx);
@@ -37,5 +33,8 @@ int GetElfIndex(library_t* lib); // -1 if no elf (i.e. wrapped)
elfheader_t* GetElf(library_t* lib); // NULL if no elf (i.e. wrapped)
void* GetHandle(library_t* lib); // NULL if not wrapped
void IncRefCount(library_t* lib, x64emu_t* emu);
+int DecRefCount(library_t** lib, x64emu_t* emu); // might unload the lib!
+int GetRefCount(library_t* lib);
+void SetDlOpenIdx(library_t* lib, int dlopen);
#endif //__LIBRARY_H_
diff --git a/src/include/myalign.h b/src/include/myalign.h
index cc4922b..247ea1b 100755..100644
--- a/src/include/myalign.h
+++ b/src/include/myalign.h
@@ -114,8 +114,8 @@ typdef struct {
{ \
uintptr_t *p = (uintptr_t*)(SCRATCH); \
int n = (X64_VA_MAX_REG - (VA)->gp_offset)/8; \
- if(n) memcpy(&p[0], (VA)->reg_save_area, n*8); \
- memcpy(&p[n], (VA)->overflow_arg_area, 100*8); \
+ if(n) memcpy(&p[0], (VA)->reg_save_area+X64_VA_MAX_REG-n*8, n*8); \
+ memcpy(&p[n], (VA)->overflow_arg_area, 20*8); \
sysv_varargs.__offset = (VA)->gp_offset; \
sysv_varargs.__base = (char*)p; \
}
@@ -126,7 +126,7 @@ typdef struct {
uintptr_t *p = (uintptr_t*)(SCRATCH); \
p[0]=R_RDI; p[1]=R_RSI; p[2]=R_RDX; \
p[3]=R_RCX; p[4]=R_R8; p[5]=R_R9; \
- memcpy(&p[8+N], STACK, 100*8 - (8+N)*8); \
+ memcpy(&p[8+N], STACK, 20*8); \
sysv_varargs.__offset = N*8; \
sysv_varargs.__base = (char*)p; \
}
@@ -139,10 +139,11 @@ typdef struct {
#define CREATE_VALIST_FROM_VALIST(VA, SCRATCH) \
va_list sysv_varargs; \
{ \
+ if((VA)->fp_offset!=X64_VA_MAX_XMM) printf_log(LOG_DEBUG, "Warning: %s: CREATE_VALIST_FROM_VALIST with %d XMM register!\n", __FUNCTION__, (X64_VA_MAX_XMM - (VA)->fp_offset)/16);\
uintptr_t *p = (uintptr_t*)(SCRATCH); \
int n = (X64_VA_MAX_REG - (VA)->gp_offset)/8; \
- if(n) memcpy(&p[0], (VA)->reg_save_area, n*8); \
- memcpy(&p[n], (VA)->overflow_arg_area, 100*8); \
+ if(n) memcpy(&p[0], (VA)->reg_save_area+X64_VA_MAX_REG-n*8, n*8); \
+ memcpy(&p[n], (VA)->overflow_arg_area, 20*8); \
sysv_varargs = (va_list)p; \
}
// this is an approximation, and if the va_list have some float/double, it will fail!
@@ -153,7 +154,7 @@ typdef struct {
uintptr_t *p = (uintptr_t*)(SCRATCH); \
p[0]=R_RDI; p[1]=R_RSI; p[2]=R_RDX; \
p[3]=R_RCX; p[4]=R_R8; p[5]=R_R9; \
- memcpy(&p[6], STACK, 100*8); \
+ memcpy(&p[6], STACK, 20*8); \
sysv_varargs = (va_list)&p[N]; \
}
#else
@@ -213,4 +214,4 @@ void AlignSemidDs(void *dest, const void* source);
uintptr_t getVArgs(x64emu_t* emu, int pos, uintptr_t* b, int N);
-#endif //__MY_ALIGN__H_ \ No newline at end of file
+#endif //__MY_ALIGN__H_
diff --git a/src/include/pathcoll.h b/src/include/pathcoll.h
index 5b730d3..5b730d3 100755..100644
--- a/src/include/pathcoll.h
+++ b/src/include/pathcoll.h
diff --git a/src/include/rcfile.h b/src/include/rcfile.h
index c194e9a..ebad704 100644
--- a/src/include/rcfile.h
+++ b/src/include/rcfile.h
@@ -2,7 +2,7 @@
#define __RCFILE_H__
void LoadRCFile(const char* filename);
-void DeleteParams();
+void DeleteParams(void);
void ApplyParams(const char* name);
#endif //__RCFILE_H__ \ No newline at end of file
diff --git a/src/include/regs.h b/src/include/regs.h
index 0097e72..a80b393 100755..100644
--- a/src/include/regs.h
+++ b/src/include/regs.h
@@ -17,7 +17,7 @@ enum {
#define _DI _RDI
enum {
- _CS, _DS, _SS, _ES, _FS, _GS
+ _ES, _CS, _SS, _DS, _FS, _GS
};
@@ -131,7 +131,7 @@ typedef enum {
d_rcr16,
d_rcr32,
d_rcr64,
- d_dec8i, // interpretor version, to handle the CF flags that is untouched
+ d_dec8i, // interpreter version, to handle the CF flags that is untouched
d_dec16i,
d_dec32i,
d_dec64i,
@@ -140,7 +140,7 @@ typedef enum {
d_inc32i,
d_inc64i,
d_unknown //95
-} defered_flags_t;
+} deferred_flags_t;
#pragma pack(push, 1)
diff --git a/src/include/sdl1rwops.h b/src/include/sdl1rwops.h
index 46b7351..76fd890 100755..100644
--- a/src/include/sdl1rwops.h
+++ b/src/include/sdl1rwops.h
@@ -4,7 +4,7 @@
typedef struct SDL1_RWops_s SDL1_RWops_t; // the actual SDL1 SDL_RWops
typedef struct x64emu_s x64emu_t;
-typedef SDL1_RWops_t* (*sdl1_allocrw)();
+typedef SDL1_RWops_t* (*sdl1_allocrw)(void);
typedef void (*sdl1_freerw)(SDL1_RWops_t*);
// each function will be added to dictionary, and each native functions will be wrapped so they run in emulated world
diff --git a/src/include/sdl2rwops.h b/src/include/sdl2rwops.h
index f03f17c..1b13c09 100755..100644
--- a/src/include/sdl2rwops.h
+++ b/src/include/sdl2rwops.h
@@ -4,7 +4,7 @@
typedef struct SDL2_RWops_s SDL2_RWops_t; // the actual SDL2 SDL_RWops
typedef struct x64emu_s x64emu_t;
-typedef SDL2_RWops_t* (*sdl2_allocrw)();
+typedef SDL2_RWops_t* (*sdl2_allocrw)(void);
typedef void (*sdl2_freerw)(SDL2_RWops_t*);
typedef struct SDL2RWSave_s {
diff --git a/src/include/signals.h b/src/include/signals.h
index 22e96d1..3fe8a2f 100755..100644
--- a/src/include/signals.h
+++ b/src/include/signals.h
@@ -34,8 +34,9 @@ int my___sigaction(x64emu_t* emu, int signum, const x64_sigaction_t *act, x64_si
int my_syscall_rt_sigaction(x64emu_t* emu, int signum, const x64_sigaction_restorer_t *act, x64_sigaction_restorer_t *oldact, int sigsetsize);
void init_signal_helper(box64context_t* context);
-void fini_signal_helper();
+void fini_signal_helper(void);
void emit_signal(x64emu_t* emu, int sig, void* addr, int code);
+void emit_interruption(x64emu_t* emu, int num, void* addr);
#endif //__SIGNALS_H__
diff --git a/src/include/symbols.h b/src/include/symbols.h
index b00a354..32e54b2 100644
--- a/src/include/symbols.h
+++ b/src/include/symbols.h
@@ -9,14 +9,15 @@ typedef struct versymbols_s versymbols_t;
KHASH_MAP_DECLARE_STR(mapsymbols, versymbols_t)
-kh_mapsymbols_t* NewMapSymbols();
+kh_mapsymbols_t* NewMapSymbols(void);
void FreeMapSymbols(kh_mapsymbols_t** map);
// replace if already there
void AddSymbol(kh_mapsymbols_t *mapsymbols, const char* name, uintptr_t addr, uint32_t sz, int ver, const char* vername);
uintptr_t FindSymbol(kh_mapsymbols_t *mapsymbols, const char* name, int ver, const char* vername, int local, const char* defver);
+// Update addr and sz of existing symbols
+void ForceUpdateSymbol(kh_mapsymbols_t *mapsymbols, const char* name, uintptr_t addr, uint32_t sz);
// don't add if already there
-
void AddUniqueSymbol(kh_mapsymbols_t *mapsymbols, const char* name, uintptr_t addr, uint32_t sz, int ver, const char* vername);
int GetSymbolStartEnd(kh_mapsymbols_t* mapsymbols, const char* name, uintptr_t* start, uintptr_t* end, int ver, const char* vername, int local, const char* defver);
int GetSizedSymbolStartEnd(kh_mapsymbols_t* mapsymbols, const char* name, uintptr_t* start, uintptr_t* end, size_t size, int ver, const char* vername, int local, const char* defver);
@@ -24,7 +25,7 @@ const char* GetSymbolName(kh_mapsymbols_t* mapsymbols, void* p, uintptr_t* offs,
// default version handling
KHASH_MAP_DECLARE_STR(defaultversion, const char*)
-kh_defaultversion_t* NewDefaultVersion();
+kh_defaultversion_t* NewDefaultVersion(void);
void FreeDefaultVersion(kh_defaultversion_t** def);
void AddDefaultVersion(kh_defaultversion_t* def, const char* symname, const char* vername);
diff --git a/src/include/threads.h b/src/include/threads.h
index d094dc0..af58046 100755..100644
--- a/src/include/threads.h
+++ b/src/include/threads.h
@@ -4,25 +4,15 @@
typedef struct box64context_s box64context_t;
typedef struct x64emu_s x64emu_t;
-typedef struct emu_jmpbuf_s {
- x64emu_t* emu;
- void* jmpbuf;
- int jmpbuf_ok;
-} emu_jmpbuf_t;
-
void CleanStackSize(box64context_t* context);
-emu_jmpbuf_t* GetJmpBuf();
-
-void init_pthread_helper();
+void init_pthread_helper(void);
void fini_pthread_helper(box64context_t* context);
// prepare an "emuthread structure" in pet and return address of function pointer for a "thread creation routine"
void* my_prepare_thread(x64emu_t *emu, void* f, void* arg, int ssize, void** pet);
-#ifndef DYNAREC
//check and unlock if a mutex is locked by current thread (works only for PTHREAD_MUTEX_ERRORCHECK typed mutex)
int checkUnlockMutex(void* m);
-#endif
#endif //_THREADS_H_ \ No newline at end of file
diff --git a/src/include/wine_tools.h b/src/include/wine_tools.h
index 52993ce..5c60fec 100755..100644
--- a/src/include/wine_tools.h
+++ b/src/include/wine_tools.h
@@ -4,10 +4,10 @@
void wine_prereserve(const char* reserve);
extern int wine_preloaded;
-void* get_wine_prereserve();
+void* get_wine_prereserve(void);
#ifdef DYNAREC
-void dynarec_wine_prereserve();
+void dynarec_wine_prereserve(void);
#endif
#endif //__WINE_TOOLS_H__
diff --git a/src/include/wrappedlibs.h b/src/include/wrappedlibs.h
index 07014e4..2d87a93 100755..100644
--- a/src/include/wrappedlibs.h
+++ b/src/include/wrappedlibs.h
@@ -7,7 +7,7 @@ typedef struct box64context_s box64context_t;
typedef int (*wrappedlib_init_t)(library_t * lib, box64context_t* box64); // 0 = success
typedef void (*wrappedlib_fini_t)(library_t * lib);
-typedef int (*wrappedlib_get_t)(library_t* lib, const char* name, uintptr_t *offs, uintptr_t *sz, size_t size, int* weak, int version, const char* vername, int local);
+typedef int (*wrappedlib_get_t)(library_t* lib, const char* name, uintptr_t *offs, uintptr_t *sz, size_t size, int* weak, int version, const char* vername, int local, const char* defver);
void setNeededLibs(library_t* lib, int n, ...);
#define SETALT(A) lib->w.altmy = box_strdup(#A)
diff --git a/src/include/x64emu.h b/src/include/x64emu.h
index e7efbb0..51a27a1 100755..100644
--- a/src/include/x64emu.h
+++ b/src/include/x64emu.h
@@ -6,14 +6,15 @@ typedef struct box64context_s box64context_t;
x64emu_t *NewX64Emu(box64context_t *context, uintptr_t start, uintptr_t stack, int stacksize, int ownstack);
x64emu_t *NewX64EmuFromStack(x64emu_t* emu, box64context_t *context, uintptr_t start, uintptr_t stack, int stacksize, int ownstack);
-void SetupX64Emu(x64emu_t *emu);
+void SetupX64Emu(x64emu_t *emu, x64emu_t *ref);
void FreeX64Emu(x64emu_t **x64emu);
void FreeX64EmuFromStack(x64emu_t **emu);
void CloneEmu(x64emu_t *newemu, const x64emu_t* emu);
+void CopyEmu(x64emu_t *newemu, const x64emu_t* emu);
void SetTraceEmu(uintptr_t trace_start, uintptr_t trace_end);
box64context_t* GetEmuContext(x64emu_t* emu);
-uint32_t* GetParityTab();
+uint32_t* GetParityTab(void);
uint32_t GetEAX(x64emu_t *emu);
uint64_t GetRAX(x64emu_t *emu);
@@ -40,17 +41,15 @@ uint64_t GetRSP(x64emu_t *emu);
uint64_t GetRBP(x64emu_t *emu);
void ResetFlags(x64emu_t *emu);
void ResetSegmentsCache(x64emu_t *emu);
-const char* DumpCPURegs(x64emu_t* emu, uintptr_t ip);
+const char* DumpCPURegs(x64emu_t* emu, uintptr_t ip, int is32bits);
-void StopEmu(x64emu_t* emu, const char* reason);
-void PushExit(x64emu_t* emu);
-void* GetExit();
+void StopEmu(x64emu_t* emu, const char* reason, int is32bits);
void EmuCall(x64emu_t* emu, uintptr_t addr);
-void AddCleanup(x64emu_t *emu, void *p);
-void AddCleanup1Arg(x64emu_t *emu, void *p, void* a);
+void AddCleanup(x64emu_t *emu, void *p, void* dso_handle);
+void AddCleanup1Arg(x64emu_t *emu, void *p, void* a, void* dso_handle);
void CallCleanup(x64emu_t *emu, void* p);
void CallAllCleanup(x64emu_t *emu);
-void UnimpOpcode(x64emu_t* emu);
+void UnimpOpcode(x64emu_t* emu, int is32bits);
uint64_t ReadTSC(x64emu_t* emu);
@@ -59,7 +58,7 @@ long double LD2localLD(void* ld); // long double (80bits pointer) -> long
void LD2D(void* ld, void* d); // long double (80bits) -> double (64bits)
void D2LD(void* d, void* ld); // double (64bits) -> long double (64bits)
-void printFunctionAddr(uintptr_t nextaddr, const char* text);
+int printFunctionAddr(uintptr_t nextaddr, const char* text); // 0 if nothing was found
const char* getAddrFunctionName(uintptr_t addr);
#endif //__X86EMU_H_ \ No newline at end of file
diff --git a/src/include/x64run.h b/src/include/x64run.h
index 78903bb..b6c9e96 100755..100644
--- a/src/include/x64run.h
+++ b/src/include/x64run.h
@@ -3,12 +3,14 @@
#include <stdint.h>
typedef struct x64emu_s x64emu_t;
+typedef struct x64test_s x64test_t;
int Run(x64emu_t *emu, int step); // 0 if run was successfull, 1 if error in x86 world
-int DynaRun(x64emu_t *emu);
+int RunTest(x64test_t *test);
+void DynaRun(x64emu_t *emu);
uint32_t LibSyscall(x64emu_t *emu);
void PltResolver(x64emu_t* emu);
extern uintptr_t pltResolver;
-int GetTID();
+int GetTID(void);
#endif //__X64RUN_H_ \ No newline at end of file
diff --git a/src/include/x64tls.h b/src/include/x64tls.h
index f26827c..66f0d9e 100755..100644
--- a/src/include/x64tls.h
+++ b/src/include/x64tls.h
@@ -2,12 +2,12 @@
#define __X64_TLS_H__
typedef struct thread_area_s thread_area_t;
+typedef struct thread_area_32_s thread_area_32_t;
-uint32_t my_set_thread_area(thread_area_t* td);
+uint32_t my_set_thread_area_32(x64emu_t* emu, thread_area_32_t* td);
uint32_t my_modify_ldt(x64emu_t* emu, int op, thread_area_t* td, int size);
-void* fillTLSData(box64context_t *context);
-void* resizeTLSData(box64context_t *context, void* oldptr);
+tlsdatasize_t* getTLSData(box64context_t *context);
void* GetSegmentBase(uint32_t desc);
int my_arch_prctl(x64emu_t *emu, int code, void* addr);
diff --git a/src/include/x64trace.h b/src/include/x64trace.h
index 662f274..e7c3efd 100755..100644
--- a/src/include/x64trace.h
+++ b/src/include/x64trace.h
@@ -8,10 +8,11 @@ typedef struct zydis_dec_s zydis_dec_t;
int InitX64Trace(box64context_t *context);
void DeleteX64Trace(box64context_t *context);
+zydis_dec_t* InitX86TraceDecoder(box64context_t *context);
+void DeleteX86TraceDecoder(zydis_dec_t **dec);
zydis_dec_t* InitX64TraceDecoder(box64context_t *context);
void DeleteX64TraceDecoder(zydis_dec_t **dec);
-const char* DecodeX64Trace(zydis_dec_t *dec, uintptr_t p);
-#define ZYDIS_RUNTIME_ADDRESS_NONE (uint64_t)(-1)
+const char* DecodeX64Trace(zydis_dec_t *dec, uintptr_t p);
#endif //__X64TRACE_H_ \ No newline at end of file
diff --git a/src/librarian/dictionnary.c b/src/librarian/dictionnary.c
index 9d5e375..9d5e375 100755..100644
--- a/src/librarian/dictionnary.c
+++ b/src/librarian/dictionnary.c
diff --git a/src/librarian/globalsymbols.c b/src/librarian/globalsymbols.c
index 3a932d8..462af7f 100755..100644
--- a/src/librarian/globalsymbols.c
+++ b/src/librarian/globalsymbols.c
@@ -16,16 +16,24 @@
// workaround for Globals symbols
-#define GLOB(A) \
- if (GetGlobalNoWeakSymbolStartEnd(my_context->maplib, #A, &globoffs, &globend, -1, NULL)) { \
- printf_log(LOG_DEBUG, "Global " #A " workaround, @%p <- %p\n", (void*)globoffs, &A); \
- memcpy((void*)globoffs, &A, sizeof(A)); \
+#define GLOB(A, B) \
+ if (GetGlobalNoWeakSymbolStartEnd(my_context->maplib, #A, &globoffs, &globend, -1, NULL, NULL)) { \
+ printf_log(LOG_DEBUG, "Global " #A " workaround, @%p <- %p\n", (void*)globoffs, &A); \
+ memcpy((void*)globoffs, &A, sizeof(A)); \
+ } \
+ if (B && GetGlobalNoWeakSymbolStartEnd(my_context->maplib, #A, &globoffs, &globend, -1, NULL, B)) { \
+ printf_log(LOG_DEBUG, "Global " #A " workaround, @%p <- %p\n", (void*)globoffs, &A); \
+ memcpy((void*)globoffs, &A, sizeof(A)); \
}
-#define TOGLOB(A) \
- if (GetGlobalNoWeakSymbolStartEnd(my_context->maplib, #A, &globoffs, &globend, -1, NULL)) { \
- printf_log(LOG_DEBUG, "Global " #A " workaround, @%p -> %p\n", (void*)globoffs, &A); \
- memcpy(&A, (void*)globoffs, sizeof(A)); \
+#define TOGLOB(A, B) \
+ if (GetGlobalNoWeakSymbolStartEnd(my_context->maplib, #A, &globoffs, &globend, -1, NULL, NULL)) { \
+ printf_log(LOG_DEBUG, "Global " #A " workaround, @%p -> %p\n", (void*)globoffs, &A); \
+ memcpy(&A, (void*)globoffs, sizeof(A)); \
+ } \
+ if (B && GetGlobalNoWeakSymbolStartEnd(my_context->maplib, #A, &globoffs, &globend, -1, NULL, B)) { \
+ printf_log(LOG_DEBUG, "Global " #A " workaround, @%p -> %p\n", (void*)globoffs, &A); \
+ memcpy(&A, (void*)globoffs, sizeof(A)); \
}
@@ -35,14 +43,14 @@ EXPORT void* gdk_display = NULL; // in case it's used...
void my_checkGlobalGdkDisplay()
{
uintptr_t globoffs, globend;
- GLOB(gdk_display)
+ GLOB(gdk_display, NULL)
}
void my_setGlobalGThreadsInit()
{
int val = 1;
uintptr_t globoffs, globend;
- if (GetGlobalNoWeakSymbolStartEnd(my_context->maplib, "g_threads_got_initialized", &globoffs, &globend, -1, NULL)) {
+ if (GetGlobalNoWeakSymbolStartEnd(my_context->maplib, "g_threads_got_initialized", &globoffs, &globend, -1, NULL, NULL)) {
printf_log(LOG_DEBUG, "Global g_threads_got_initialized workaround, @%p <= %d\n", (void*)globoffs, val);
memcpy((void*)globoffs, &val, sizeof(val));
}
@@ -79,35 +87,35 @@ EXPORT void* ttytype;
void my_checkGlobalTInfo()
{
uintptr_t globoffs, globend;
- GLOB(COLS)
- GLOB(LINES)
- GLOB(TABSIZE)
- GLOB(curscr)
- GLOB(newscr)
- GLOB(stdscr)
- GLOB(acs_map)
- GLOB(UP)
- GLOB(BC)
- GLOB(PC)
- GLOB(ospeed)
- GLOB(ttytype)
+ GLOB(COLS, NULL)
+ GLOB(LINES, NULL)
+ GLOB(TABSIZE, NULL)
+ GLOB(curscr, NULL)
+ GLOB(newscr, NULL)
+ GLOB(stdscr, NULL)
+ GLOB(acs_map, NULL)
+ GLOB(UP, NULL)
+ GLOB(BC, NULL)
+ GLOB(PC, NULL)
+ GLOB(ospeed, NULL)
+ GLOB(ttytype, NULL)
}
void my_updateGlobalTInfo()
{
uintptr_t globoffs, globend;
- TOGLOB(COLS)
- TOGLOB(LINES)
- TOGLOB(TABSIZE)
- TOGLOB(curscr)
- TOGLOB(newscr)
- TOGLOB(stdscr)
- TOGLOB(acs_map)
- TOGLOB(UP)
- TOGLOB(BC)
- TOGLOB(PC)
- TOGLOB(ospeed)
- TOGLOB(ttytype)
+ TOGLOB(COLS, NULL)
+ TOGLOB(LINES, NULL)
+ TOGLOB(TABSIZE, NULL)
+ TOGLOB(curscr, NULL)
+ TOGLOB(newscr, NULL)
+ TOGLOB(stdscr, NULL)
+ TOGLOB(acs_map, NULL)
+ TOGLOB(UP, NULL)
+ TOGLOB(BC, NULL)
+ TOGLOB(PC, NULL)
+ TOGLOB(ospeed, NULL)
+ TOGLOB(ttytype, NULL)
}
// **************** getopts ****************
@@ -117,17 +125,17 @@ EXPORT int optind, opterr, optopt;
void my_updateGlobalOpt()
{
uintptr_t globoffs, globend;
- TOGLOB(optarg);
- TOGLOB(optind);
- TOGLOB(opterr);
- TOGLOB(optopt);
+ TOGLOB(optarg, "GLIBC_2.2.5");
+ TOGLOB(optind, "GLIBC_2.2.5");
+ TOGLOB(opterr, "GLIBC_2.2.5");
+ TOGLOB(optopt, "GLIBC_2.2.5");
}
void my_checkGlobalOpt()
{
uintptr_t globoffs, globend;
- GLOB(optarg);
- GLOB(optind);
- GLOB(opterr);
- GLOB(optopt);
+ GLOB(optarg, "GLIBC_2.2.5");
+ GLOB(optind, "GLIBC_2.2.5");
+ GLOB(opterr, "GLIBC_2.2.5");
+ GLOB(optopt, "GLIBC_2.2.5");
} \ No newline at end of file
diff --git a/src/librarian/librarian.c b/src/librarian/librarian.c
index 919389b..072ef81 100755..100644
--- a/src/librarian/librarian.c
+++ b/src/librarian/librarian.c
@@ -39,15 +39,12 @@ void FreeLibrarian(lib_t **maplib, x64emu_t *emu)
library_t* owner = (*maplib)->owner;
(*maplib)->owner = NULL; // to avoid recursive free...
- // free the memory only. All the uninit logic is elsewhere
-
-
- if((*maplib)->ownlibs && (*maplib)->libsz) {
+ /*if((*maplib)->ownlibs && (*maplib)->libsz) {
for(int i=0; i<(*maplib)->libsz; ++i) {
printf_log(LOG_DEBUG, "Unloading %s\n", (*maplib)->libraries[i]->name);
- Free1Library(&(*maplib)->libraries[i], emu);
+ DecRefCount(&(*maplib)->libraries[i], emu);
}
- }
+ }*/
box_free((*maplib)->libraries);
(*maplib)->libraries = NULL;
@@ -108,8 +105,6 @@ void MapLibAddLib(lib_t* maplib, library_t* lib)
++maplib->libsz;
}
-static void MapLibRemoveLib(lib_t* maplib, library_t* lib);
-
static void MapLibAddMapLib(lib_t* dest, library_t* lib_src, lib_t* src)
{
if(!src)
@@ -130,7 +125,7 @@ static void MapLibAddMapLib(lib_t* dest, library_t* lib_src, lib_t* src)
FreeLibrarian(&src, NULL);
}
-static void MapLibRemoveLib(lib_t* maplib, library_t* lib)
+void MapLibRemoveLib(lib_t* maplib, library_t* lib)
{
if(!maplib || !lib)
return;
@@ -161,7 +156,28 @@ static void MapLibRemoveMapLib(lib_t* dest, lib_t* src)
}
}
-int AddNeededLib_add(lib_t* maplib, int local, needed_libs_t* needed, int n, box64context_t* box64, x64emu_t* emu)
+void promoteLocalLibGlobal(library_t* lib)
+{
+ if(!lib || !my_context)
+ return;
+ // promote lib from local to global...
+ // for add the depending local libs...
+ if(lib->maplib) {
+ MapLibAddMapLib(my_context->maplib, lib, lib->maplib);
+ }
+ if(!libraryInMapLib(my_context->maplib, lib))
+ MapLibAddLib(my_context->maplib, lib);
+ MapLibRemoveMapLib(my_context->local_maplib, my_context->maplib);
+}
+
+int isLibLocal(library_t* lib)
+{
+ if(!lib || !my_context)
+ return 0;
+ return libraryInMapLib(my_context->local_maplib, lib);
+}
+
+static int AddNeededLib_add(lib_t* maplib, int local, needed_libs_t* needed, int n, elfheader_t* verneeded, box64context_t* box64, x64emu_t* emu)
{
const char* path = needed->names[n];
printf_log(LOG_DEBUG, "Trying to add \"%s\" to maplib%s\n", path, local?" (local)":"");
@@ -192,18 +208,12 @@ int AddNeededLib_add(lib_t* maplib, int local, needed_libs_t* needed, int n, box
}
} else {
// promote lib from local to global...
- // for add the depending local libs...
- if(lib->maplib) {
- MapLibAddMapLib(my_context->maplib, lib, lib->maplib);
- }
- if(!libraryInMapLib(my_context->maplib, lib))
- MapLibAddLib(my_context->maplib, lib);
- MapLibRemoveMapLib(my_context->local_maplib, my_context->maplib);
+ promoteLocalLibGlobal(lib);
}
return 0;
}
// load a new one
- needed->libs[n] = lib = NewLibrary(path, box64);
+ needed->libs[n] = lib = NewLibrary(path, box64, verneeded);
if(!lib) {
printf_log(LOG_DEBUG, "Faillure to create lib => fail\n");
return 1; //Error
@@ -240,28 +250,28 @@ int AddNeededLib_add(lib_t* maplib, int local, needed_libs_t* needed, int n, box
printf_log(LOG_DEBUG, "Failure to add lib linkmap\n");
return 1;
}
- lm->l_addr = (Elf64_Addr)GetElfDelta(my_context->elfs[lib->e.elf_index]);
+ lm->l_addr = (Elf64_Addr)GetElfDelta(lib->e.elf);
lm->l_name = lib->name;
- lm->l_ld = GetDynamicSection(my_context->elfs[lib->e.elf_index]);
+ lm->l_ld = GetDynamicSection(lib->e.elf);
}
return 0;
}
-int AddNeededLib_init(lib_t* maplib, int local, int bindnow, library_t* lib, box64context_t* box64, x64emu_t* emu)
+int AddNeededLib_init(lib_t* maplib, int local, int bindnow, library_t* lib, elfheader_t* verneeded, box64context_t* box64, x64emu_t* emu)
{
if(!lib) // no lib, error is already detected, no need to return a new one
return 0;
if(!maplib)
maplib = (local)?lib->maplib:my_context->maplib;
- int mainelf = GetElfIndex(lib);
+ elfheader_t* mainelf = GetElf(lib);
- if(mainelf==-1) {
+ if(!mainelf) {
// It's a native libs, nothing else to do
} else {
// it's an emulated lib,
// load dependancies and launch init sequence
- if(LoadNeededLibs(box64->elfs[mainelf], maplib, 0, bindnow, box64, emu)) {
+ if(LoadNeededLibs(mainelf, maplib, 0, bindnow, box64, emu)) {
printf_log(LOG_DEBUG, "Failure to Add dependant lib => fail\n");
return 1;
}
@@ -273,7 +283,7 @@ int AddNeededLib_init(lib_t* maplib, int local, int bindnow, library_t* lib, box
tmp.size = tmp.cap = 1;
tmp.names = names;
tmp.libs = libs;
- AddNeededLib(maplib, 0, 0, &tmp, box64, emu);
+ AddNeededLib(maplib, 0, 0, &tmp, verneeded, box64, emu);
}
if(!strcmp(GetNameLib(lib), "libmss.so.6")) {
char* names[] = {"libSDL-1.2.so.0", "libdl.so.2"}; // TODO: they will never be uninit...
@@ -282,7 +292,7 @@ int AddNeededLib_init(lib_t* maplib, int local, int bindnow, library_t* lib, box
tmp.size = tmp.cap = 2;
tmp.names = names;
tmp.libs = libs;
- AddNeededLib(maplib, 0, 0, &tmp, box64, emu);
+ AddNeededLib(maplib, 0, 0, &tmp, verneeded, box64, emu);
}
// finalize the lib
@@ -296,9 +306,19 @@ int AddNeededLib_init(lib_t* maplib, int local, int bindnow, library_t* lib, box
return 0;
}
+void AddNeededLib_remove(lib_t* maplib, int local, library_t** lib, box64context_t* box64, x64emu_t* emu)
+{
+
+ if(!lib || !*lib) // no lib, error is already detected, no need to return a new one
+ return;
+ if(!maplib)
+ maplib = (local)?(*lib)->maplib:my_context->maplib;
+
+ DecRefCount(lib, emu);
+}
EXPORTDYN
-int AddNeededLib(lib_t* maplib, int local, int bindnow, needed_libs_t* needed, box64context_t* box64, x64emu_t* emu)
+int AddNeededLib(lib_t* maplib, int local, int bindnow, needed_libs_t* needed, elfheader_t* verneeded, box64context_t* box64, x64emu_t* emu)
{
if(!needed) // no needed libs, no problems
return 0;
@@ -306,19 +326,35 @@ int AddNeededLib(lib_t* maplib, int local, int bindnow, needed_libs_t* needed, b
int ret = 0;
// Add libs and symbol
for(int i=0; i<needed->size; ++i) {
- if(AddNeededLib_add(maplib, local, needed, i, box64, emu)) {
+ if(AddNeededLib_add(maplib, local, needed, i, verneeded, box64, emu)) {
printf_log(strchr(needed->names[i],'/')?LOG_DEBUG:LOG_INFO, "Error loading needed lib %s\n", needed->names[i]);
ret = 1;
}
}
+ // error while loadind lib, unload...
+ if(ret) {
+ return ret;
+ }
// add dependant libs and init them
for (int i=0; i<needed->size; ++i)
- if(AddNeededLib_init(maplib, local, bindnow, needed->libs[i], box64, emu)) {
+ if(AddNeededLib_init(maplib, local, bindnow, needed->libs[i], verneeded, box64, emu)) {
printf_log(LOG_INFO, "Error initializing needed lib %s\n", needed->names[i]);
if(!allow_missing_libs) ret = 1;
}
+ // error while loadind lib, unload...
return ret;
}
+EXPORTDYN
+void RemoveNeededLib(lib_t* maplib, int local, needed_libs_t* needed, box64context_t* box64, x64emu_t* emu)
+{
+ if(!needed) // no needed libs, no problems
+ return;
+ for(int i=0; i<needed->size; ++i) {
+ if(box64_log>=LOG_DEBUG && needed->libs[i])
+ printf_log(LOG_DEBUG, "Will remove after failed init %s\n", needed->names[i]);
+ AddNeededLib_remove(maplib, local, &needed->libs[i], box64, emu);
+ }
+}
library_t* GetLibMapLib(lib_t* maplib, const char* name)
{
@@ -338,7 +374,9 @@ EXPORTDYN
uintptr_t FindGlobalSymbol(lib_t *maplib, const char* name, int version, const char* vername)
{
uintptr_t start = 0, end = 0;
- if(GetGlobalSymbolStartEnd(maplib, name, &start, &end, (void*)1, version, vername))
+ const char *globdefver = GetMaplibDefaultVersion(my_context->maplib, (my_context->maplib==maplib)?NULL:maplib, 0, name);
+ const char *weakdefver = GetMaplibDefaultVersion(my_context->maplib, (my_context->maplib==maplib)?NULL:maplib, 1, name);
+ if(GetGlobalSymbolStartEnd(maplib, name, &start, &end, (void*)1, version, vername, globdefver, weakdefver))
return start;
return 0;
}
@@ -350,7 +388,7 @@ static int isLocal(elfheader_t* self, library_t* l)
return 0;
}
-int GetNoSelfSymbolStartEnd(lib_t *maplib, const char* name, uintptr_t* start, uintptr_t* end, elfheader_t* self, size_t size, int version, const char* vername)
+int GetNoSelfSymbolStartEnd(lib_t *maplib, const char* name, uintptr_t* start, uintptr_t* end, elfheader_t* self, size_t size, int version, const char* vername, const char* globdefver, const char* weakdefver)
{
assert(self); // need self for this one
//search for the self, to start "next"
@@ -362,39 +400,40 @@ int GetNoSelfSymbolStartEnd(lib_t *maplib, const char* name, uintptr_t* start, u
}
if(go<0)
go = 0; // not found...
+ if(maplib)
for(int i=go; i<maplib->libsz; ++i) {
- if(GetElfIndex(maplib->libraries[i])==-1 || (my_context->elfs[GetElfIndex(maplib->libraries[i])]!=self))
- if(GetLibGlobalSymbolStartEnd(maplib->libraries[i], name, start, end, size, &weak, version, vername, 0))
+ if(GetElfIndex(maplib->libraries[i])==-1 || (GetElf(maplib->libraries[i])!=self))
+ if(GetLibGlobalSymbolStartEnd(maplib->libraries[i], name, start, end, size, &weak, version, vername, 0, globdefver))
if(*start)
return 1;
}
+ if(maplib)
for(int i=go; i<maplib->libsz; ++i)
- if(GetElfIndex(maplib->libraries[i])==-1 || (my_context->elfs[GetElfIndex(maplib->libraries[i])]!=self))
- GetLibWeakSymbolStartEnd(maplib->libraries[i], name, start, end, size, &weak, version, vername, 0);
+ if(GetElfIndex(maplib->libraries[i])==-1 || (GetElf(maplib->libraries[i])!=self))
+ GetLibWeakSymbolStartEnd(maplib->libraries[i], name, start, end, size, &weak, version, vername, 0, weakdefver);
// loop done, weak symbol found
if(weak && *start)
return 1;
// if self defined, give it another chance with self...
if(self) {
if(my_context->elfs[0]!=self) {
- const char* defver = GetDefaultVersion(my_context->globaldefver, name);
- if(GetSizedSymbolStartEnd(GetMapSymbols(my_context->elfs[0]), name, start, end, size, version, vername, 1, defver))
+ if(GetSizedSymbolStartEnd(GetMapSymbols(my_context->elfs[0]), name, start, end, size, version, vername, 1, globdefver))
if(*start)
return 1;
- defver = GetDefaultVersion(my_context->weakdefver, name);
- if(GetSizedSymbolStartEnd(GetWeakSymbols(my_context->elfs[0]), name, start, end, size, version, vername, 1, defver))
+ if(GetSizedSymbolStartEnd(GetWeakSymbols(my_context->elfs[0]), name, start, end, size, version, vername, 1, weakdefver))
if(*start)
weak = 1;
}
for(int i=0; i<go; ++i) {
- if(GetElfIndex(maplib->libraries[i])==-1 || (my_context->elfs[GetElfIndex(maplib->libraries[i])]!=self))
- if(GetLibGlobalSymbolStartEnd(maplib->libraries[i], name, start, end, size, &weak, version, vername, 1))
+ if(GetElfIndex(maplib->libraries[i])==-1 || (GetElf(maplib->libraries[i])!=self))
+ if(GetLibGlobalSymbolStartEnd(maplib->libraries[i], name, start, end, size, &weak, version, vername, 1, globdefver))
if(*start)
return 1;
}
+ if(maplib)
for(int i=0; i<go; ++i) {
- if(GetElfIndex(maplib->libraries[i])==-1 || (my_context->elfs[GetElfIndex(maplib->libraries[i])]!=self))
- GetLibWeakSymbolStartEnd(maplib->libraries[i], name, start, end, size, &weak, version, vername, 1);
+ if(GetElfIndex(maplib->libraries[i])==-1 || (GetElf(maplib->libraries[i])!=self))
+ GetLibWeakSymbolStartEnd(maplib->libraries[i], name, start, end, size, &weak, version, vername, 1, weakdefver);
}
if(weak && *start)
return 1;
@@ -402,63 +441,146 @@ int GetNoSelfSymbolStartEnd(lib_t *maplib, const char* name, uintptr_t* start, u
// nope, not found
return 0;
}
-static int GetGlobalSymbolStartEnd_internal(lib_t *maplib, const char* name, uintptr_t* start, uintptr_t* end, elfheader_t* self, int version, const char* vername)
+static int GetGlobalSymbolStartEnd_internal(lib_t *maplib, const char* name, uintptr_t* start, uintptr_t* end, elfheader_t* self, int version, const char* vername, const char* globdefver, const char* weakdefver)
{
int weak = 0;
size_t size = 0;
+ // search in needed libs from preloaded first, in order
+ if(my_context->preload)
+ for(int i=0; i<my_context->preload->size; ++i)
+ if(GetLibGlobalSymbolStartEnd(my_context->preload->libs[i], name, start, end, size, &weak, version, vername, isLocal(self, my_context->preload->libs[i]), globdefver))
+ if(*start)
+ return 1;
+ // search non-weak symbol, from older to newer (first GLOBAL object wins, starting with self)
+ if(GetSymbolStartEnd(GetMapSymbols(my_context->elfs[0]), name, start, end, version, vername, (my_context->elfs[0]==self || !self)?1:0, globdefver))
+ if(*start)
+ return 1;
+ // TODO: create a temporary map to search lib only 1 time, and in order of needed...
+ // search in needed libs from neededlibs first, in order
+ if(my_context->neededlibs)
+ for(int i=0; i<my_context->neededlibs->size; ++i)
+ if(GetLibGlobalSymbolStartEnd(my_context->neededlibs->libs[i], name, start, end, size, &weak, version, vername, isLocal(self, my_context->neededlibs->libs[i]), globdefver))
+ if(*start)
+ return 1;
+ // search in global symbols
+ if(maplib) {
+ if(self && self!=my_context->elfs[0] && self!=(void*)1)
+ if(GetSymbolStartEnd(GetMapSymbols(self), name, start, end, version, vername, 1, globdefver))
+ if(*start)
+ return 1;
+ for(int i=0; i<maplib->libsz; ++i) {
+ if(GetLibGlobalSymbolStartEnd(maplib->libraries[i], name, start, end, size, &weak, version, vername, isLocal(self, maplib->libraries[i]), globdefver))
+ if(*start)
+ return 1;
+ }
+ }
+
// check with default version...
- const char* defver = GetDefaultVersion(my_context->globaldefver, name);
+ int ok = 0;
+ // GetSymbolStartEnd should not change start/end if symbol is not found
+ if(GetSymbolStartEnd(GetWeakSymbols(my_context->elfs[0]), name, start, end, version, vername, (my_context->elfs[0]==self || !self)?1:0, weakdefver))
+ if(*start)
+ ok = 1;
+
+ if(maplib)
+ for(int i=0; i<maplib->libsz; ++i) {
+ if(GetLibWeakSymbolStartEnd(maplib->libraries[i], name, start, end, size, &weak, version, vername, isLocal(self, maplib->libraries[i]), weakdefver))
+ if(*start)
+ ok = 1;
+ }
+ // nope, not found
+ return (ok && *start)?1:0;
+}
+void** my_GetGTKDisplay();
+void** my_GetGthreadsGotInitialized();
+int GetGlobalSymbolStartEnd(lib_t *maplib, const char* name, uintptr_t* start, uintptr_t* end, elfheader_t* self, int version, const char* vername, const char* globdefver, const char* weakdefver)
+{
+ if(GetGlobalSymbolStartEnd_internal(maplib, name, start, end, self, version, vername, globdefver, weakdefver)) {
+ if(start && end && *end==*start) { // object is of 0 sized, try to see an "_END" object of null size
+ uintptr_t start2, end2;
+ char* buff = (char*)malloc(strlen(name) + strlen("_END") + 1);
+ strcpy(buff, name);
+ strcat(buff, "_END");
+ if(GetGlobalSymbolStartEnd_internal(maplib, buff, &start2, &end2, self, version, vername, globdefver, weakdefver)) {
+ if(end2>*end && start2==end2)
+ *end = end2;
+ }
+ box_free(buff);
+ }
+ return 1;
+ }
+ // some special case symbol, defined inside box64 itself
+ if(!strcmp(name, "gdk_display")) {
+ *start = (uintptr_t)my_GetGTKDisplay();
+ *end = *start+sizeof(void*);
+ printf_log(LOG_INFO, "Using global gdk_display for gdk-x11 (%p:%p)\n", start, *(void**)start);
+ return 1;
+ }
+ if(!strcmp(name, "g_threads_got_initialized")) {
+ *start = (uintptr_t)my_GetGthreadsGotInitialized();
+ *end = *start+sizeof(int);
+ printf_log(LOG_INFO, "Using global g_threads_got_initialized for gthread2 (%p:%p)\n", start, *(void**)start);
+ return 1;
+ }
+ // not found...
+ return 0;
+}
+
+static int GetGlobalWeakSymbolStartEnd_internal(lib_t *maplib, const char* name, uintptr_t* start, uintptr_t* end, elfheader_t* self, int version, const char* vername, const char* globdefver, const char* weakdefver)
+{
+ int weak = 0;
+ size_t size = 0;
// search in needed libs from preloaded first, in order
if(my_context->preload)
for(int i=0; i<my_context->preload->size; ++i)
- if(GetLibGlobalSymbolStartEnd(my_context->preload->libs[i], name, start, end, size, &weak, version, vername, isLocal(self, my_context->preload->libs[i])))
+ if(GetLibGlobalSymbolStartEnd(my_context->preload->libs[i], name, start, end, size, &weak, version, vername, isLocal(self, my_context->preload->libs[i]), globdefver))
if(*start)
return 1;
// search non-weak symbol, from older to newer (first GLOBAL object wins)
- if(GetSymbolStartEnd(GetMapSymbols(my_context->elfs[0]), name, start, end, version, vername, (my_context->elfs[0]==self || !self)?1:0, defver))
+ if(GetSymbolStartEnd(GetMapSymbols(my_context->elfs[0]), name, start, end, version, vername, (my_context->elfs[0]==self || !self)?1:0, globdefver))
if(*start)
return 1;
// TODO: create a temporary map to search lib only 1 time, and in order of needed...
// search in needed libs from neededlibs first, in order
if(my_context->neededlibs)
for(int i=0; i<my_context->neededlibs->size; ++i)
- if(GetLibGlobalSymbolStartEnd(my_context->neededlibs->libs[i], name, start, end, size, &weak, version, vername, isLocal(self, my_context->neededlibs->libs[i])))
+ if(GetLibGlobalSymbolStartEnd(my_context->neededlibs->libs[i], name, start, end, size, &weak, version, vername, isLocal(self, my_context->neededlibs->libs[i]), globdefver))
if(*start)
return 1;
// search in global symbols
+ if(maplib)
for(int i=0; i<maplib->libsz; ++i) {
- if(GetLibGlobalSymbolStartEnd(maplib->libraries[i], name, start, end, size, &weak, version, vername, isLocal(self, maplib->libraries[i])))
+ if(GetLibGlobalSymbolStartEnd(maplib->libraries[i], name, start, end, size, &weak, version, vername, isLocal(self, maplib->libraries[i]), globdefver))
if(*start)
return 1;
}
// check with default version...
- defver = GetDefaultVersion(my_context->weakdefver, name);
int ok = 0;
// GetSymbolStartEnd should not change start/end if symbol is not found
- if(GetSymbolStartEnd(GetWeakSymbols(my_context->elfs[0]), name, start, end, version, vername, (my_context->elfs[0]==self || !self)?1:0, defver))
+ if(GetSymbolStartEnd(GetWeakSymbols(my_context->elfs[0]), name, start, end, version, vername, (my_context->elfs[0]==self || !self)?1:0, weakdefver))
if(*start)
ok = 1;
+ if(maplib)
for(int i=0; i<maplib->libsz; ++i) {
- if(GetLibWeakSymbolStartEnd(maplib->libraries[i], name, start, end, size, &weak, version, vername, isLocal(self, maplib->libraries[i])))
+ if(GetLibWeakSymbolStartEnd(maplib->libraries[i], name, start, end, size, &weak, version, vername, isLocal(self, maplib->libraries[i]), weakdefver))
if(*start)
ok = 1;
}
// nope, not found
return (ok && *start)?1:0;
}
-void** my_GetGTKDisplay();
-void** my_GetGthreadsGotInitialized();
-int GetGlobalSymbolStartEnd(lib_t *maplib, const char* name, uintptr_t* start, uintptr_t* end, elfheader_t* self, int version, const char* vername)
+
+int GetGlobalWeakSymbolStartEnd(lib_t *maplib, const char* name, uintptr_t* start, uintptr_t* end, elfheader_t* self, int version, const char* vername, const char* globdefver, const char* weakdefver)
{
- if(GetGlobalSymbolStartEnd_internal(maplib, name, start, end, self, version, vername)) {
+ if(GetGlobalWeakSymbolStartEnd_internal(maplib, name, start, end, self, version, vername, globdefver, weakdefver)) {
if(start && end && *end==*start) { // object is of 0 sized, try to see an "_END" object of null size
uintptr_t start2, end2;
char* buff = (char*)malloc(strlen(name) + strlen("_END") + 1);
strcpy(buff, name);
strcat(buff, "_END");
- if(GetGlobalSymbolStartEnd_internal(maplib, buff, &start2, &end2, self, version, vername)) {
+ if(GetGlobalWeakSymbolStartEnd_internal(maplib, buff, &start2, &end2, self, version, vername, globdefver, weakdefver)) {
if(end2>*end && start2==end2)
*end = end2;
}
@@ -483,6 +605,30 @@ int GetGlobalSymbolStartEnd(lib_t *maplib, const char* name, uintptr_t* start, u
return 0;
}
+const char* GetMaplibDefaultVersion(lib_t *maplib, lib_t* local_maplib, int isweak, const char* symname)
+{
+ const char* ret = GetDefaultVersion(isweak?GetWeakDefaultVersion(my_context->elfs[0]):GetGlobalDefaultVersion(my_context->elfs[0]), symname);
+ if(ret)
+ return ret;
+ for(int i=0; i<maplib->libsz; ++i) {
+ elfheader_t *h = GetElf(maplib->libraries[i]);
+ if(h)
+ ret = GetDefaultVersion(isweak?GetWeakDefaultVersion(h):GetGlobalDefaultVersion(h), symname);
+ if(ret)
+ return ret;
+ }
+ if(local_maplib)
+ for(int i=0; i<local_maplib->libsz; ++i) {
+ elfheader_t *h = GetElf(local_maplib->libraries[i]);
+ if(h)
+ ret = GetDefaultVersion(isweak?GetWeakDefaultVersion(h):GetGlobalDefaultVersion(h), symname);
+ if(ret)
+ return ret;
+ }
+
+ return NULL;
+}
+
elfheader_t* GetGlobalSymbolElf(lib_t *maplib, const char* name, int version, const char* vername)
{
uintptr_t start = 0;
@@ -491,63 +637,65 @@ elfheader_t* GetGlobalSymbolElf(lib_t *maplib, const char* name, int version, co
int weak = 0;
elfheader_t* ret = NULL;
// check with default version...
- const char* defver = GetDefaultVersion(my_context->globaldefver, name);
+ const char* defver = GetMaplibDefaultVersion(my_context->maplib, (my_context->maplib==maplib)?NULL:maplib, 0, name);
if(GetSymbolStartEnd(GetMapSymbols(my_context->elfs[0]), name, &start, &end, version, vername, 1, defver))
return my_context->elfs[0];
for(int i=0; i<maplib->libsz; ++i) {
- if(GetLibGlobalSymbolStartEnd(maplib->libraries[i], name, &start, &end, size, &weak, version, vername, 1)) {
- int idx = GetElfIndex(maplib->libraries[i]);
- if(idx==-1) {
+ if(GetLibGlobalSymbolStartEnd(maplib->libraries[i], name, &start, &end, size, &weak, version, vername, 1, defver)) {
+ elfheader_t* h = GetElf(maplib->libraries[i]);
+ if(!h) {
printf_log(LOG_NONE, "Warning, getting Elf info for a native symbol \"%s\" from lib \"%s\"\n", name, GetNameLib(maplib->libraries[i]));
return NULL;
}
if(weak)
- ret = my_context->elfs[idx];
+ ret = h;
else
- return my_context->elfs[idx];
+ return h;
}
}
- defver = GetDefaultVersion(my_context->weakdefver, name);
+ defver = GetMaplibDefaultVersion(my_context->maplib, (my_context->maplib==maplib)?NULL:maplib, 1, name);
if(GetSymbolStartEnd(GetWeakSymbols(my_context->elfs[0]), name, &start, &end, version, vername, 1, defver))
ret = my_context->elfs[0];
for(int i=0; i<maplib->libsz; ++i) {
- if(GetLibWeakSymbolStartEnd(maplib->libraries[i], name, &start, &end, size, &weak, version, vername, 1)) {
- int idx = GetElfIndex(maplib->libraries[i]);
- if(idx==-1) {
+ if(GetLibWeakSymbolStartEnd(maplib->libraries[i], name, &start, &end, size, &weak, version, vername, 1, defver)) {
+ elfheader_t* h = GetElf(maplib->libraries[i]);
+ if(!h) {
printf_log(LOG_NONE, "Warning, getting Elf info for a native symbol \"%s\" from lib \"%s\"\n", name, GetNameLib(maplib->libraries[i]));
return NULL;
}
if(weak)
- ret = my_context->elfs[idx];
+ ret = h;
else
- return my_context->elfs[idx];
+ return h;
}
}
// return what has been found (maybe nothing)
return ret;
}
-int GetGlobalNoWeakSymbolStartEnd(lib_t *maplib, const char* name, uintptr_t* start, uintptr_t* end, int version, const char* vername)
+int GetGlobalNoWeakSymbolStartEnd(lib_t *maplib, const char* name, uintptr_t* start, uintptr_t* end, int version, const char* vername, const char* defver)
{
int weak = 0;
size_t size = 0;
+ // check global GLOB_DAT kind of symbols
+ if(GetSymbolStartEnd(GetGlobalData(maplib), name, start, end, version, vername, 1, defver))
+ if(*start || *end)
+ return 1;
// check with default version...
- const char* defver = GetDefaultVersion(my_context->globaldefver, name);
-
if(GetSymbolStartEnd(GetMapSymbols(my_context->elfs[0]), name, start, end, version, vername, 1, defver))
if(*start || *end)
return 1;
for(int i=0; i<maplib->libsz; ++i)
- if(GetLibGlobalSymbolStartEnd(maplib->libraries[i], name, start, end, size, &weak, version, vername, 1))
+ if(GetLibGlobalSymbolStartEnd(maplib->libraries[i], name, start, end, size, &weak, version, vername, 1, defver))
if(*start || *end)
return 1;
// nope, not found
return 0;
}
-int IsGlobalNoWeakSymbolInNative(lib_t *maplib, const char* name, int version, const char* vername)
+int IsGlobalNoWeakSymbolInNative(lib_t *maplib, const char* name, int version, const char* vername, const char* defver)
{
uintptr_t start, end;
size_t size = 0;
@@ -555,7 +703,7 @@ int IsGlobalNoWeakSymbolInNative(lib_t *maplib, const char* name, int version, c
// check with default version...
for(int i=0; i<maplib->libsz; ++i)
if(GetElfIndex(maplib->libraries[i])==-1)
- if(GetLibGlobalSymbolStartEnd(maplib->libraries[i], name, &start, &end, size, &weak, version, vername, 1))
+ if(GetLibGlobalSymbolStartEnd(maplib->libraries[i], name, &start, &end, size, &weak, version, vername, 1, defver))
if(start || end)
return 1;
// nope, not found
@@ -563,22 +711,23 @@ int IsGlobalNoWeakSymbolInNative(lib_t *maplib, const char* name, int version, c
}
-int GetLocalSymbolStartEnd(lib_t *maplib, const char* name, uintptr_t* start, uintptr_t* end, elfheader_t *self, int version, const char* vername)
+int GetLocalSymbolStartEnd(lib_t *maplib, const char* name, uintptr_t* start, uintptr_t* end, elfheader_t *self, int version, const char* vername, const char* globdefver, const char* weakdefver)
{
// check with default version...
int weak;
size_t size = 0;
+ const char* defver = globdefver?globdefver:weakdefver;
if(my_context->elfs[0]==self || !self) {
- if(GetSymbolStartEnd(GetLocalSymbols(my_context->elfs[0]), name, start, end, version, vername, 1, NULL))
+ if(GetSymbolStartEnd(GetLocalSymbols(my_context->elfs[0]), name, start, end, version, vername, 1, defver))
if(*start || *end)
return 1;
if(self)
return 0;
}
for(int i=0; i<maplib->libsz; ++i) {
- if(GetElfIndex(maplib->libraries[i])!=-1 && (!self || my_context->elfs[GetElfIndex(maplib->libraries[i])]==self)) {
- if(GetLibLocalSymbolStartEnd(maplib->libraries[i], name, start, end, size, &weak, version, vername, 1))
+ if(GetElfIndex(maplib->libraries[i])!=-1 && (!self || GetElf(maplib->libraries[i])==self)) {
+ if(GetLibLocalSymbolStartEnd(maplib->libraries[i], name, start, end, size, &weak, version, vername, 1, defver))
if(*start || *end)
return 1;
if(self)
@@ -613,15 +762,15 @@ const char* FindSymbolName(lib_t *maplib, void* p, void** start, uint64_t* sz, c
*lib = NULL; // main elf
else {
for(int i=0; i<my_context->maplib->libsz; ++i) {
- int idx = GetElfIndex(my_context->maplib->libraries[i]);
- if((idx!=-1) && (my_context->elfs[idx]==h)) {
+ elfheader_t* head = GetElf(my_context->maplib->libraries[i]);
+ if((head) && (head==h)) {
*lib = my_context->maplib->libraries[i];
return ret;
}
}
for(int i=0; i<my_context->local_maplib->libsz; ++i) {
- int idx = GetElfIndex(my_context->local_maplib->libraries[i]);
- if((idx!=-1) && (my_context->elfs[idx]==h)) {
+ elfheader_t* head = GetElf(my_context->local_maplib->libraries[i]);
+ if((head) && (head==h)) {
*lib = my_context->local_maplib->libraries[i];
return ret;
}
diff --git a/src/librarian/librarian_private.h b/src/librarian/librarian_private.h
index b7ff5c0..b7ff5c0 100755..100644
--- a/src/librarian/librarian_private.h
+++ b/src/librarian/librarian_private.h
diff --git a/src/librarian/library.c b/src/librarian/library.c
index 4891922..18fbe24 100755..100644
--- a/src/librarian/library.c
+++ b/src/librarian/library.c
@@ -116,7 +116,7 @@ void WrappedLib_FinishFini(library_t* lib)
FreeBridge(&lib->w.bridge);
}
-int WrappedLib_GetWeak(library_t* lib, const char* name, uintptr_t *offs, uintptr_t *sz, size_t asked_size, int* weak, int version, const char* vername, int local)
+int WrappedLib_GetWeak(library_t* lib, const char* name, uintptr_t *offs, uintptr_t *sz, size_t asked_size, int* weak, int version, const char* vername, int local, const char* defver)
{
// ignoring asked size on wrapped libs
uintptr_t addr = 0;
@@ -134,11 +134,10 @@ int WrappedLib_GetWeak(library_t* lib, const char* name, uintptr_t *offs, uintpt
*weak = wk;
return 1;
}
-int EmuLib_GetWeak(library_t* lib, const char* name, uintptr_t *offs, uintptr_t *sz, size_t asked_size, int*weak, int version, const char* vername, int local)
+int EmuLib_GetWeak(library_t* lib, const char* name, uintptr_t *offs, uintptr_t *sz, size_t asked_size, int*weak, int version, const char* vername, int local, const char* defver)
{
// symbols...
uintptr_t start, end;
- const char* defver = GetDefaultVersion(my_context->weakdefver, name);
// weak symbols...
if(GetSizedSymbolStartEnd(GetWeakSymbols(lib->e.elf), name, &start, &end, asked_size, version, vername, local, defver))
{
@@ -149,7 +148,7 @@ int EmuLib_GetWeak(library_t* lib, const char* name, uintptr_t *offs, uintptr_t
}
return 0;
}
-int WrappedLib_GetGlobal(library_t* lib, const char* name, uintptr_t *offs, uintptr_t *sz, size_t asked_size, int* weak, int version, const char* vername, int local)
+int WrappedLib_GetGlobal(library_t* lib, const char* name, uintptr_t *offs, uintptr_t *sz, size_t asked_size, int* weak, int version, const char* vername, int local, const char* defver)
{
// ignoring asked size on wrapped libs
uintptr_t addr = 0;
@@ -167,10 +166,9 @@ int WrappedLib_GetGlobal(library_t* lib, const char* name, uintptr_t *offs, uint
*weak = 0;
return 1;
}
-int EmuLib_GetGlobal(library_t* lib, const char* name, uintptr_t *offs, uintptr_t *sz, size_t asked_size, int* weak, int version, const char* vername, int local)
+int EmuLib_GetGlobal(library_t* lib, const char* name, uintptr_t *offs, uintptr_t *sz, size_t asked_size, int* weak, int version, const char* vername, int local, const char* defver)
{
uintptr_t start, end;
- const char* defver = GetDefaultVersion(my_context->globaldefver, name);
if(GetSizedSymbolStartEnd(GetMapSymbols(lib->e.elf), name, &start, &end, asked_size, version, vername, local, defver))
{
*offs = start;
@@ -180,12 +178,10 @@ int EmuLib_GetGlobal(library_t* lib, const char* name, uintptr_t *offs, uintptr_
}
return 0;
}
-int EmuLib_GetLocal(library_t* lib, const char* name, uintptr_t *offs, uintptr_t *sz, size_t asked_size, int* weak, int version, const char* vername, int local)
+int EmuLib_GetLocal(library_t* lib, const char* name, uintptr_t *offs, uintptr_t *sz, size_t asked_size, int* weak, int version, const char* vername, int local, const char* defver)
{
// ignoring asked size on wrapped libs
uintptr_t start, end;
- const char* defver = GetDefaultVersion(my_context->globaldefver, name);
- if(!defver) defver = GetDefaultVersion(my_context->weakdefver, name);
if(GetSymbolStartEnd(GetLocalSymbols(lib->e.elf), name, &start, &end, version, vername, local, defver))
{
*offs = start;
@@ -196,7 +192,7 @@ int EmuLib_GetLocal(library_t* lib, const char* name, uintptr_t *offs, uintptr_t
return 0;
}
-int WrappedLib_GetLocal(library_t* lib, const char* name, uintptr_t *offs, uintptr_t *sz, size_t asked_size, int* weak, int version, const char* vername, int local)
+int WrappedLib_GetLocal(library_t* lib, const char* name, uintptr_t *offs, uintptr_t *sz, size_t asked_size, int* weak, int version, const char* vername, int local, const char* defver)
{
(void)lib; (void)name; (void)offs; (void)sz; (void)version; (void)vername; (void)local;
return 0;
@@ -221,7 +217,7 @@ static void initWrappedLib(library_t *lib, box64context_t* context) {
lib->type = LIB_WRAPPED;
lib->w.refcnt = 1;
// Call librarian to load all dependant elf
- if(AddNeededLib(context->maplib, 0, 0, lib->w.needed, context, thread_get_emu())) {
+ if(AddNeededLib(context->maplib, 0, 0, lib->w.needed, NULL, context, thread_get_emu())) {
printf_log(LOG_NONE, "Error: loading a needed libs in elf %s\n", lib->name);
return;
}
@@ -244,7 +240,7 @@ static void initWrappedLib(library_t *lib, box64context_t* context) {
}
}
-static int loadEmulatedLib(const char* libname, library_t *lib, box64context_t* context)
+static int loadEmulatedLib(const char* libname, library_t *lib, box64context_t* context, elfheader_t* verneeded)
{
if(FileExist(libname, IS_FILE))
{
@@ -259,28 +255,36 @@ static int loadEmulatedLib(const char* libname, library_t *lib, box64context_t*
fclose(f);
return 0;
}
- int mainelf = AddElfHeader(context, elf_header);
if(CalcLoadAddr(elf_header)) {
printf_log(LOG_NONE, "Error: reading elf header of %s\n", libname);
+ FreeElfHeader(&elf_header);
fclose(f);
return 0;
}
// allocate memory
if(AllocElfMemory(context, elf_header, 0)) {
printf_log(LOG_NONE, "Error: allocating memory for elf %s\n", libname);
+ FreeElfHeader(&elf_header);
fclose(f);
return 0;
}
// Load elf into memory
if(LoadElfMemory(f, context, elf_header)) {
printf_log(LOG_NONE, "Error: loading in memory elf %s\n", libname);
+ FreeElfHeader(&elf_header);
fclose(f);
return 0;
}
// can close the file now
fclose(f);
+ if(verneeded && !isElfHasNeededVer(elf_header, lib->name, verneeded)) {
+ // incompatible, discard and continue the search
+ FreeElfHeader(&elf_header);
+ return 0;
+ }
+ int mainelf = AddElfHeader(context, elf_header);
ElfAttachLib(elf_header, lib);
lib->type = LIB_EMULATED;
@@ -305,6 +309,11 @@ static int loadEmulatedLib(const char* libname, library_t *lib, box64context_t*
box64_dynarec_bigblock = 0;
box64_dynarec_strongmem = 1;
}
+ if(libname && box64_dynarec_jvm && strstr(libname, "libjvm.so")) {
+ printf_log(LOG_INFO, "libjvm detected, disable Dynarec BigBlock and enable Dynarec StrongMem\n");
+ box64_dynarec_bigblock = 0;
+ box64_dynarec_strongmem = 1;
+ }
#endif
if(libname && box64_libcef && strstr(libname, "libcef.so")) {
printf_log(LOG_INFO, "libcef detected, using malloc_hack_2\n");
@@ -315,13 +324,13 @@ static int loadEmulatedLib(const char* libname, library_t *lib, box64context_t*
return 0;
}
-static void initEmulatedLib(const char* path, library_t *lib, box64context_t* context)
+static void initEmulatedLib(const char* path, library_t *lib, box64context_t* context, elfheader_t* verneeded)
{
char libname[MAX_PATH];
strcpy(libname, path);
int found = FileIsX64ELF(libname);
if(found)
- if(loadEmulatedLib(libname, lib, context))
+ if(loadEmulatedLib(libname, lib, context, verneeded))
return;
if(!strchr(path, '/'))
for(int i=0; i<context->box64_ld_lib.size; ++i)
@@ -329,8 +338,15 @@ static void initEmulatedLib(const char* path, library_t *lib, box64context_t* co
strcpy(libname, context->box64_ld_lib.paths[i]);
strcat(libname, path);
if(FileIsX64ELF(libname))
- if(loadEmulatedLib(libname, lib, context))
+ if(loadEmulatedLib(libname, lib, context, verneeded))
return;
+ // also try x86_64 variant
+ strcpy(libname, context->box64_ld_lib.paths[i]);
+ strcat(libname, "x86_64/");
+ strcat(libname, path);
+ if(FileIsX64ELF(libname))
+ if(loadEmulatedLib(libname, lib, context, verneeded))
+ return;
}
}
@@ -352,7 +368,7 @@ static int isEssentialLib(const char* name) {
return 0;
}
-library_t *NewLibrary(const char* path, box64context_t* context)
+library_t *NewLibrary(const char* path, box64context_t* context, elfheader_t* verneeded)
{
printf_log(LOG_DEBUG, "Trying to load \"%s\"\n", path);
library_t *lib = (library_t*)box_calloc(1, sizeof(library_t));
@@ -398,7 +414,7 @@ library_t *NewLibrary(const char* path, box64context_t* context)
initWrappedLib(lib, context);
// then look for a native one
if(lib->type==LIB_UNNKNOW)
- initEmulatedLib(path, lib, context);
+ initEmulatedLib(path, lib, context, verneeded);
// still not loaded but notwrapped indicated: use wrapped...
if(lib->type==LIB_UNNKNOW && notwrapped && !precise)
initWrappedLib(lib, context);
@@ -420,7 +436,6 @@ int AddSymbolsLibrary(lib_t *maplib, library_t* lib, x64emu_t* emu)
{
(void)emu;
- lib->active = 1;
if(lib->type==LIB_EMULATED) {
elfheader_t *elf_header = lib->e.elf;
// add symbols
@@ -449,12 +464,12 @@ int FinalizeLibrary(library_t* lib, lib_t* local_maplib, int bindnow, x64emu_t*
#ifdef HAVE_TRACE
if(trace_func) {
int weak;
- if (GetGlobalSymbolStartEnd(local_maplib, trace_func, &trace_start, &trace_end, elf_header, -1, NULL)) {
+ if (GetGlobalSymbolStartEnd(local_maplib, trace_func, &trace_start, &trace_end, elf_header, -1, NULL, NULL, NULL)) {
SetTraceEmu(trace_start, trace_end);
printf_log(LOG_INFO, "TRACE on %s only (%p-%p)\n", trace_func, (void*)trace_start, (void*)trace_end);
box_free(trace_func);
trace_func = NULL;
- } else if(GetLibLocalSymbolStartEnd(lib, trace_func, &trace_start, &trace_end, 0, &weak, -1, NULL, 0)) {
+ } else if(GetLibLocalSymbolStartEnd(lib, trace_func, &trace_start, &trace_end, 0, &weak, -1, NULL, 0, NULL)) {
SetTraceEmu(trace_start, trace_end);
printf_log(LOG_INFO, "TRACE on %s only (%p-%p)\n", trace_func, (void*)trace_start, (void*)trace_end);
box_free(trace_func);
@@ -469,7 +484,6 @@ int FinalizeLibrary(library_t* lib, lib_t* local_maplib, int bindnow, x64emu_t*
int ReloadLibrary(library_t* lib, x64emu_t* emu)
{
- lib->active = 1;
if(lib->type==LIB_EMULATED) {
elfheader_t *elf_header = lib->e.elf;
// reload image in memory and re-run the mapping
@@ -514,90 +528,94 @@ int ReloadLibrary(library_t* lib, x64emu_t* emu)
int FiniLibrary(library_t* lib, x64emu_t* emu)
{
- if(!lib->active)
- return 0; // nothing to do
switch (lib->type) {
case LIB_WRAPPED:
- if(!--lib->w.refcnt)
- lib->active = 0;
return 0;
case LIB_EMULATED:
- if(!--lib->e.elf->refcnt) {
- if(emu)
- RunElfFini(lib->e.elf, emu);
- lib->active = 0;
- }
+ RunElfFini(lib->e.elf, emu);
return 0;
}
return 1; // bad type
}
-void InactiveLibrary(library_t* lib)
+void Free1Library(library_t **the_lib, x64emu_t* emu)
{
- lib->active = 0;
-}
+ if(!(*the_lib)) return;
-void Free1Library(library_t **lib, x64emu_t* emu)
-{
- if(!(*lib)) return;
+ library_t* lib = *the_lib;
+
+ printf_log(LOG_DEBUG, "Free1Library %s\n", lib->name);
+ // remove lib from maplib/local_maplib...
+ if(my_context) {
+ MapLibRemoveLib(my_context->maplib, lib);
+ MapLibRemoveLib(my_context->local_maplib, lib);
+ }
+ // free elf is relevant
+ if(lib->type==LIB_EMULATED) {
+ FreeElfHeader(&lib->e.elf);
+ }
// No "Fini" logic here, only memory handling
- if((*lib)->maplib)
- FreeLibrarian(&(*lib)->maplib, emu);
+ if(lib->maplib)
+ FreeLibrarian(&lib->maplib, emu);
- if((*lib)->type!=LIB_UNNKNOW && (*lib)->fini) {
- (*lib)->fini(*lib);
+ if(lib->type!=LIB_UNNKNOW && lib->fini) {
+ lib->fini(lib);
}
- box_free((*lib)->name);
- box_free((*lib)->path);
+ box_free(lib->name);
+ box_free(lib->path);
- if((*lib)->gbridgemap) {
+ if(lib->gbridgemap) {
bridged_t *br;
- kh_foreach_value_ref((*lib)->gbridgemap, br,
+ kh_foreach_value_ref(lib->gbridgemap, br,
box_free(br->name);
);
- kh_destroy(bridgemap, (*lib)->gbridgemap);
+ kh_destroy(bridgemap, lib->gbridgemap);
}
- if((*lib)->wbridgemap) {
+ if(lib->wbridgemap) {
bridged_t *br;
- kh_foreach_value_ref((*lib)->wbridgemap, br,
+ kh_foreach_value_ref(lib->wbridgemap, br,
box_free(br->name);
);
- kh_destroy(bridgemap, (*lib)->wbridgemap);
+ kh_destroy(bridgemap, lib->wbridgemap);
}
- if((*lib)->lbridgemap) {
+ if(lib->lbridgemap) {
bridged_t *br;
- kh_foreach_value_ref((*lib)->lbridgemap, br,
+ kh_foreach_value_ref(lib->lbridgemap, br,
box_free(br->name);
);
- kh_destroy(bridgemap, (*lib)->lbridgemap);
+ kh_destroy(bridgemap, lib->lbridgemap);
}
- if((*lib)->type == LIB_WRAPPED) {
- if((*lib)->w.symbolmap)
- kh_destroy(symbolmap, (*lib)->w.symbolmap);
- if((*lib)->w.wsymbolmap)
- kh_destroy(symbolmap, (*lib)->w.wsymbolmap);
- if((*lib)->w.datamap)
- kh_destroy(datamap, (*lib)->w.datamap);
- if((*lib)->w.wdatamap)
- kh_destroy(datamap, (*lib)->w.wdatamap);
- if((*lib)->w.mydatamap)
- kh_destroy(datamap, (*lib)->w.mydatamap);
- if((*lib)->w.mysymbolmap)
- kh_destroy(symbolmap, (*lib)->w.mysymbolmap);
- if((*lib)->w.wmysymbolmap)
- kh_destroy(symbolmap, (*lib)->w.wmysymbolmap);
- if((*lib)->w.stsymbolmap)
- kh_destroy(symbolmap, (*lib)->w.stsymbolmap);
- if((*lib)->w.symbol2map)
- kh_destroy(symbol2map, (*lib)->w.symbol2map);
+ if(lib->type == LIB_WRAPPED) {
+ if(lib->w.symbolmap)
+ kh_destroy(symbolmap, lib->w.symbolmap);
+ if(lib->w.wsymbolmap)
+ kh_destroy(symbolmap, lib->w.wsymbolmap);
+ if(lib->w.datamap)
+ kh_destroy(datamap, lib->w.datamap);
+ if(lib->w.wdatamap)
+ kh_destroy(datamap, lib->w.wdatamap);
+ if(lib->w.mydatamap)
+ kh_destroy(datamap, lib->w.mydatamap);
+ if(lib->w.mysymbolmap)
+ kh_destroy(symbolmap, lib->w.mysymbolmap);
+ if(lib->w.wmysymbolmap)
+ kh_destroy(symbolmap, lib->w.wmysymbolmap);
+ if(lib->w.stsymbolmap)
+ kh_destroy(symbolmap, lib->w.stsymbolmap);
+ if(lib->w.symbol2map)
+ kh_destroy(symbol2map, lib->w.symbol2map);
}
- box_free(*lib);
- *lib = NULL;
+ // remove frim the dlopen collection
+ if(lib->dlopen)
+ RemoveDlopen(the_lib, lib->dlopen);
+ box_free(lib);
+ if(*the_lib == lib)
+ *the_lib = NULL;
}
-char* GetNameLib(library_t *lib)
+char* GetNameLib(library_t* lib)
{
return lib->name;
}
@@ -606,15 +624,22 @@ int IsSameLib(library_t* lib, const char* path)
int ret = 0;
if(!lib)
return 0;
+ if(lib->type==LIB_UNNKNOW)
+ return 0;
char* name = Path2Name(path);
if(!strchr(path, '/') || lib->type==LIB_WRAPPED || !lib->path) {
if(strcmp(name, lib->name)==0)
ret=1;
+ if(lib->type==LIB_EMULATED && lib->e.elf->soname && !strcmp(lib->e.elf->soname, path))
+ ret=1;
} else {
char rpath[PATH_MAX];
box_realpath(path, rpath);
if(!strcmp(rpath, lib->path))
ret=1;
+ if(lib->type==LIB_EMULATED && lib->e.elf->path && !strcmp(lib->e.elf->path, rpath)) {
+ ret=1;
+ }
}
if(!ret) {
int n = NbDot(name);
@@ -626,23 +651,23 @@ int IsSameLib(library_t* lib, const char* path)
box_free(name);
return ret;
}
-int GetLibWeakSymbolStartEnd(library_t* lib, const char* name, uintptr_t* start, uintptr_t* end, size_t size, int* weak, int version, const char* vername, int local)
+int GetLibWeakSymbolStartEnd(library_t* lib, const char* name, uintptr_t* start, uintptr_t* end, size_t size, int* weak, int version, const char* vername, int local, const char* defver)
{
- if(!name[0] || !lib->active)
+ if(!name[0])
return 0;
khint_t k;
// get a new symbol
- if(lib->getweak(lib, name, start, end, size, weak, version, vername, local)) {
+ if(lib->getweak(lib, name, start, end, size, weak, version, vername, local, defver)) {
*end += *start; // lib->get(...) gives size, not end
kh_bridgemap_t *map = local?lib->lbridgemap:((*weak)?lib->wbridgemap:lib->gbridgemap);
// check first if already in the map
- k = kh_get(bridgemap, map, VersionnedName(name, version, vername));
+ k = kh_get(bridgemap, map, VersionedName(name, version, vername));
if(k!=kh_end(map)) {
*start = kh_value(map, k).start;
*end = kh_value(map, k).end;
return 1;
}
- char* symbol = box_strdup(VersionnedName(name, version, vername));
+ char* symbol = box_strdup(VersionedName(name, version, vername));
int ret;
k = kh_put(bridgemap, map, symbol, &ret);
kh_value(map, k).name = symbol;
@@ -653,23 +678,23 @@ int GetLibWeakSymbolStartEnd(library_t* lib, const char* name, uintptr_t* start,
// nope
return 0;
}
-int GetLibGlobalSymbolStartEnd(library_t* lib, const char* name, uintptr_t* start, uintptr_t* end, size_t size, int* weak, int version, const char* vername, int local)
+int GetLibGlobalSymbolStartEnd(library_t* lib, const char* name, uintptr_t* start, uintptr_t* end, size_t size, int* weak, int version, const char* vername, int local, const char* defver)
{
- if(!name[0] || !lib || !lib->active)
+ if(!name[0] || !lib)
return 0;
khint_t k;
// get a new symbol
- if(lib->getglobal(lib, name, start, end, size, weak, version, vername, local)) {
+ if(lib->getglobal(lib, name, start, end, size, weak, version, vername, local, defver)) {
*end += *start; // lib->get(...) gives size, not end
kh_bridgemap_t *map = local?lib->lbridgemap:((*weak)?lib->wbridgemap:lib->gbridgemap);
// check if already in the map
- k = kh_get(bridgemap, map, VersionnedName(name, version, vername));
+ k = kh_get(bridgemap, map, VersionedName(name, version, vername));
if(k!=kh_end(map)) {
*start = kh_value(map, k).start;
*end = kh_value(map, k).end;
return 1;
}
- char* symbol = box_strdup(VersionnedName(name, version, vername));
+ char* symbol = box_strdup(VersionedName(name, version, vername));
int ret;
k = kh_put(bridgemap, map, symbol, &ret);
kh_value(map, k).name = symbol;
@@ -680,22 +705,22 @@ int GetLibGlobalSymbolStartEnd(library_t* lib, const char* name, uintptr_t* star
// nope
return 0;
}
-int GetLibLocalSymbolStartEnd(library_t* lib, const char* name, uintptr_t* start, uintptr_t* end, size_t size, int* weak, int version, const char* vername, int local)
+int GetLibLocalSymbolStartEnd(library_t* lib, const char* name, uintptr_t* start, uintptr_t* end, size_t size, int* weak, int version, const char* vername, int local, const char* defver)
{
- if(!name[0] || !lib->active)
+ if(!name[0])
return 0;
khint_t k;
// get a new symbol
- if(lib->getlocal(lib, name, start, end, size, weak, version, vername, local)) {
+ if(lib->getlocal(lib, name, start, end, size, weak, version, vername, local, defver)) {
*end += *start; // lib->get(...) gives size, not end
// check first if already in the map
- k = kh_get(bridgemap, lib->lbridgemap, VersionnedName(name, version, vername));
+ k = kh_get(bridgemap, lib->lbridgemap, VersionedName(name, version, vername));
if(k!=kh_end(lib->lbridgemap)) {
*start = kh_value(lib->lbridgemap, k).start;
*end = kh_value(lib->lbridgemap, k).end;
return 1;
}
- char* symbol = box_strdup(VersionnedName(name, version, vername));
+ char* symbol = box_strdup(VersionedName(name, version, vername));
int ret;
k = kh_put(bridgemap, lib->lbridgemap, symbol, &ret);
kh_value(lib->lbridgemap, k).name = symbol;
@@ -820,12 +845,12 @@ static int getSymbolInSymbolMaps(library_t*lib, const char* name, int noweak, ui
symbol = dlsym(lib->w.lib, newname);
}
if(!symbol)
- symbol = GetNativeSymbolUnversionned(lib->w.lib, name);
+ symbol = GetNativeSymbolUnversioned(lib->w.lib, name);
if(!symbol && lib->w.altprefix) {
char newname[200];
strcpy(newname, lib->w.altprefix);
strcat(newname, name);
- symbol = GetNativeSymbolUnversionned(lib->w.lib, newname);
+ symbol = GetNativeSymbolUnversioned(lib->w.lib, newname);
}
if(!symbol) {
printf_log(LOG_INFO, "Warning, function %s not found in lib %s\n", name, lib->name);
@@ -867,12 +892,12 @@ static int getSymbolInSymbolMaps(library_t*lib, const char* name, int noweak, ui
symbol = dlsym(lib->w.lib, newname);
}
if(!symbol)
- symbol = GetNativeSymbolUnversionned(lib->w.lib, name);
+ symbol = GetNativeSymbolUnversioned(lib->w.lib, name);
if(!symbol && lib->w.altprefix) {
char newname[200];
strcpy(newname, lib->w.altprefix);
strcat(newname, name);
- symbol = GetNativeSymbolUnversionned(lib->w.lib, newname);
+ symbol = GetNativeSymbolUnversioned(lib->w.lib, newname);
}
if(!symbol) {
printf_log(LOG_INFO, "Warning, function %s not found in lib %s\n", name, lib->name);
@@ -894,7 +919,7 @@ static int getSymbolInSymbolMaps(library_t*lib, const char* name, int noweak, ui
if(!symbol)
symbol = dlsym(RTLD_DEFAULT, kh_value(lib->w.symbol2map, k).name); // search globaly maybe
if(!symbol)
- symbol = GetNativeSymbolUnversionned(lib->w.lib, kh_value(lib->w.symbol2map, k).name);
+ symbol = GetNativeSymbolUnversioned(lib->w.lib, kh_value(lib->w.symbol2map, k).name);
if(!symbol) {
printf_log(LOG_INFO, "Warning, function %s not found in lib %s\n", kh_value(lib->w.symbol2map, k).name, lib->name);
return 0;
@@ -911,15 +936,13 @@ static int getSymbolInSymbolMaps(library_t*lib, const char* name, int noweak, ui
int getSymbolInMaps(library_t *lib, const char* name, int noweak, uintptr_t *addr, uintptr_t *size, int* weak, int version, const char* vername, int local)
{
- if(!lib->active)
- return 0;
if(version==-2) // don't send global native symbol for a version==-2 search
return 0;
// check in datamaps (but no version, it's not handled there)
if(getSymbolInDataMaps(lib, name, noweak, addr, size, weak))
return 1;
- if(getSymbolInSymbolMaps(lib, VersionnedName(name, version, vername), noweak, addr, size, weak))
+ if(getSymbolInSymbolMaps(lib, VersionedName(name, version, vername), noweak, addr, size, weak))
return 1;
if(getSymbolInSymbolMaps(lib, name, noweak, addr, size, weak))
@@ -984,6 +1007,16 @@ linkmap_t* getLinkMapLib(library_t* lib)
}
return NULL;
}
+linkmap_t* getLinkMapElf(elfheader_t* h)
+{
+ linkmap_t* lm = my_context->linkmap;
+ while(lm) {
+ if(lm->l_lib && lm->l_lib->type==LIB_EMULATED && lm->l_lib->e.elf == h)
+ return lm;
+ lm = lm->l_next;
+ }
+ return NULL;
+}
linkmap_t* addLinkMapLib(library_t* lib)
{
if(!my_context->linkmap) {
@@ -1049,6 +1082,37 @@ void add1_neededlib(needed_libs_t* needed)
needed->names = (char**)realloc(needed->names, needed->cap*sizeof(char*));
needed->size++;
}
+void add1lib_neededlib(needed_libs_t* needed, library_t* lib, const char* name)
+{
+ if(!needed || !lib)
+ return;
+ // check if lib is already present
+ for (int i=0; i<needed->size; ++i)
+ if(needed->libs[i]==lib)
+ return;
+ // add it
+ if(needed->size+1<=needed->cap)
+ return;
+ needed->cap = needed->size+1;
+ needed->libs = (library_t**)realloc(needed->libs, needed->cap*sizeof(library_t*));
+ needed->names = (char**)realloc(needed->names, needed->cap*sizeof(char*));
+ needed->libs[needed->size] = lib;
+ needed->names[needed->size] = (char*)name;
+ needed->size++;
+}
+needed_libs_t* copy_neededlib(needed_libs_t* needed)
+{
+ if(!needed)
+ return NULL;
+ needed_libs_t* ret = (needed_libs_t*)calloc(1, sizeof(needed_libs_t));
+ ret->cap = needed->cap;
+ ret->size = needed->size;
+ ret->libs = (library_t**)calloc(ret->cap, sizeof(library_t*));
+ ret->names = (char**)calloc(ret->cap, sizeof(char*));
+ memcpy(ret->libs, needed->libs, ret->size*sizeof(library_t*));
+ memcpy(ret->names, needed->names, ret->size*sizeof(char*));
+ return ret;
+}
void setNeededLibs(library_t* lib, int n, ...)
{
@@ -1065,15 +1129,80 @@ void setNeededLibs(library_t* lib, int n, ...)
void IncRefCount(library_t* lib, x64emu_t* emu)
{
- if(lib->type==LIB_UNNKNOW)
+ if(!lib || lib->type==LIB_UNNKNOW)
return;
- if(!lib->active)
- ReloadLibrary(lib, emu);
switch (lib->type) {
case LIB_WRAPPED:
++lib->w.refcnt;
+ /*if(lib->w.needed)
+ for(int i=0; i<lib->w.needed->size; ++i) {
+ IncRefCount(lib->w.needed->libs[i], emu);
+ }*/
break;
case LIB_EMULATED:
++lib->e.elf->refcnt;
+ /*if(lib->e.elf->needed)
+ for(int i=0; i<lib->e.elf->needed->size; ++i) // some libs may not be loaded yet
+ IncRefCount(lib->e.elf->needed->libs[i], emu);*/
}
-} \ No newline at end of file
+}
+
+int DecRefCount(library_t** lib, x64emu_t* emu)
+{
+ if(!lib || !*lib)
+ return 1;
+ if((*lib)->type==LIB_UNNKNOW) {
+ Free1Library(lib, emu);
+ return 0;
+ }
+ int ret = 1;
+ needed_libs_t* needed = NULL;
+ int freed = 0;
+ switch ((*lib)->type) {
+ case LIB_WRAPPED:
+ needed = (*lib)->w.needed;
+ ret=--(*lib)->w.refcnt;
+ if(!ret) {
+ needed = copy_neededlib(needed);
+ freed=1;
+ Free1Library(lib, emu);
+ }
+ break;
+ case LIB_EMULATED:
+ needed = (*lib)->e.elf->needed;
+ ret=--(*lib)->e.elf->refcnt;
+ if(!ret) {
+ needed = copy_neededlib(needed);
+ freed=1;
+ removeLinkMapLib(*lib);
+ FiniLibrary(*lib, emu);
+ Free1Library(lib, emu);
+ }
+ break;
+ }
+ /*if(needed)
+ for(int i=0; i<needed->size; ++i)
+ DecRefCount(&needed->libs[i], emu);*/
+ if(freed)
+ free_neededlib(needed);
+ return ret;
+}
+
+int GetRefCount(library_t* lib)
+{
+ switch (lib->type) {
+ case LIB_WRAPPED:
+ return lib->w.refcnt;
+ break;
+ case LIB_EMULATED:
+ return lib->e.elf->refcnt;
+ default:
+ return 0;
+ }
+}
+
+void SetDlOpenIdx(library_t* lib, int dlopen)
+{
+ if(lib)
+ lib->dlopen = dlopen;
+}
diff --git a/src/librarian/library_private.h b/src/librarian/library_private.h
index 2b2c5ef..27d3fef 100755..100644
--- a/src/librarian/library_private.h
+++ b/src/librarian/library_private.h
@@ -62,7 +62,6 @@ typedef struct library_s {
char* path; // original path
int nbdot; // nombre of "." after .so
int type; // 0: native(wrapped) 1: emulated(elf) -1: undetermined
- int active;
wrappedlib_fini_t fini;
wrappedlib_get_t getglobal; // get global (non-weak)
wrappedlib_get_t getweak; // get weak symbol
@@ -75,6 +74,7 @@ typedef struct library_s {
kh_bridgemap_t *gbridgemap; // global symbol bridgemap
kh_bridgemap_t *wbridgemap; // weak symbol bridgemap
kh_bridgemap_t *lbridgemap; // local symbol bridgemap
+ int dlopen; // idx to the dlopen idx (or 0 if not dlopen)
} library_t;
// type for map elements
@@ -109,7 +109,13 @@ typedef struct linkmap_s {
} linkmap_t;
linkmap_t* getLinkMapLib(library_t* lib);
+linkmap_t* getLinkMapElf(elfheader_t* h);
linkmap_t* addLinkMapLib(library_t* lib);
void removeLinkMapLib(library_t* lib);
+int FiniLibrary(library_t* lib, x64emu_t* emu);
+void Free1Library(library_t **lib, x64emu_t* emu);
+
+void RemoveDlopen(library_t** lib, int idx); // defined in wrappedlibdl.c
+
#endif //__LIBRARY_PRIVATE_H_
diff --git a/src/librarian/symbols.c b/src/librarian/symbols.c
index 4584c8f..cb59430 100644
--- a/src/librarian/symbols.c
+++ b/src/librarian/symbols.c
@@ -17,7 +17,7 @@ typedef struct onesymbol_s {
} onesymbol_t;
typedef struct versymbol_s {
- int version; // -1 = no-version, 0=local, 1=global, X=versionned
+ int version; // -1 = no-version, 0=local, 1=global, X=versioned
const char* vername; // NULL or version name if version=X
onesymbol_t sym;
} versymbol_t;
@@ -170,6 +170,19 @@ void AddSymbol(kh_mapsymbols_t *mapsymbols, const char* name, uintptr_t addr, ui
v->syms[idx].sym.sz = sz;
}
+void ForceUpdateSymbol(kh_mapsymbols_t *mapsymbols, const char* name, uintptr_t addr, uint32_t sz)
+{
+ int ret;
+ khint_t k = kh_put(mapsymbols, mapsymbols, name, &ret);
+ versymbols_t * v = &kh_val(mapsymbols, k);
+ if(ret) {v->sz = v->cap = 0; v->syms = NULL;}
+ // now check if that version already exist, and update record and exit if yes
+ for(int i=0; i<v->sz; ++i) {
+ v->syms[i].sym.offs = addr;
+ v->syms[i].sym.sz = sz;
+ }
+}
+
uintptr_t FindSymbol(kh_mapsymbols_t *mapsymbols, const char* name, int ver, const char* vername, int local, const char* defver)
{
if(!mapsymbols)
diff --git a/src/library_list.h b/src/library_list.h
index 9fbb551..9770518 100755..100644
--- a/src/library_list.h
+++ b/src/library_list.h
@@ -3,7 +3,7 @@
#endif
GO("libc.so.6", libc)
-GO("libc.musl-x86_64.so.1", libdl)
+GO("libc.musl-x86_64.so.1", libcmusl)
GO("libpthread.so.0", libpthread)
GO("librt.so.1", librt)
GO("libEGL.so.1", libegl)
@@ -15,6 +15,7 @@ GO("libGLX.so.0", libglx)
GO("libGLX.so", libglx)
GO("libX11.so.6", libx11)
GO("libasound.so.2", libasound)
+GO("libasound.so", libasound)
GO("libdl.so.2", libdl)
GO("libm.so.6", libm)
GO("libSDL2-2.0.so.0", sdl2)
@@ -106,6 +107,8 @@ GO("libexpat.so.1", expat)
GO("libexpat.so", expat)
GO("libcrypto.so.1", crypto)
GO("libssl.so.1", libssl)
+GO("libcrypto.so.3", crypto3)
+GO("libssl.so.3", libssl3)
GO("libcrypt.so.1", libcrypt)
GO("libgcrypt.so.20", gcrypt)
GO("libutil.so.1", util)
@@ -150,6 +153,7 @@ GO("libpango-1.0.so", pango)
GO("libibus-1.0.so.5", libibus)
GO("libfontconfig.so.1", fontconfig)
GO("libfreetype.so.6", freetype)
+GO("libharfbuzz.so.0", libharfbuzz)
GO("libbz2.so.1", bz2)
GO("liblzma.so.5", lzma)
GO("libSM.so.6", libsm)
@@ -166,19 +170,21 @@ GO("libncurses.so.6", libncurses6)
GO("libtinfo.so.6", libtinfo6)
GO("libtbbmalloc.so.2", tbbmalloc)
GO("libtbbmalloc_proxy.so.2", tbbmallocproxy)
+GO("libtbbbind_2_5.so", tbbbind)
GO("libtcmalloc_minimal.so.0", tcmallocminimal)
GO("libtcmalloc_minimal.so.4", tcmallocminimal)
GO("libmpg123.so.0", mpg123)
GO("libgnutls.so.30", gnutls)
GO("libpcre.so.3", libpcre)
GO("libcups.so.2", libcups)
-//GO("d3dadapter9.so.1", d3dadapter9)
GO("libvulkan.so.1", vulkan)
GO("libvulkan.so", vulkan)
//GO("libwayland-client.so.0", waylandclient)
GO("libgbm.so.1", gbm)
GO("libxml2.so.2", xml2)
GO("libxslt.so.1", xslt)
+GO("libgomp.so.1", gomp)
+GO("libcap.so.2", cap)
GO("libldap_r-2.4.so.2", ldapr)
GO("liblber-2.4.so.2", lber)
//GO("libnsl.so.1", nsl)
@@ -220,7 +226,13 @@ GO("libva-drm.so.2", libvadrm)
GO("libva-x11.so.2", libvax11)
GO("libva-wayland.so.2", libvawayland)
GO("libvdpau.so.1", libvdpau)
+GO("libnuma.so.1", libnuma)
+GO("libnuma.so", libnuma)
GO("d3dadapter9.so.1", d3dadapter9)
+GO("libicuuc.so.67", icuuc67)
+GO("libicui18n.so.67", icui18n67)
+GO("libicuuc.so.72", icuuc72)
+GO("libicui18n.so.72", icui18n72)
GO("ld-linux-x86-64.so.2", ldlinux)
diff --git a/src/libtools/auxval.c b/src/libtools/auxval.c
index 789902d..789902d 100755..100644
--- a/src/libtools/auxval.c
+++ b/src/libtools/auxval.c
diff --git a/src/libtools/myalign.c b/src/libtools/myalign.c
index 3d2e49a..36873cb 100755..100644
--- a/src/libtools/myalign.c
+++ b/src/libtools/myalign.c
@@ -717,7 +717,7 @@ void myStackAlignValist(x64emu_t* emu, const char* fmt, uint64_t* mystack, x64_v
case 15: //%zg, meh.. double?
if(fprs<X64_VA_MAX_XMM) {
*mystack = area[fprs/8];
- fprs+=8;
+ fprs+=16;
mystack++;
} else {
*mystack = *st;
@@ -862,7 +862,7 @@ void myStackAlignWValist(x64emu_t* emu, const char* fmt, uint64_t* mystack, x64_
case 15: //%zg, meh .. double
if(fprs<X64_VA_MAX_XMM) {
*mystack = area[fprs/8];
- fprs+=8;
+ fprs+=16;
mystack++;
} else {
*mystack = *st;
@@ -1130,4 +1130,4 @@ void myStackAlignScanfWValist(x64emu_t* emu, const char* fmt, uint64_t* mystack,
}
}
-#endif \ No newline at end of file
+#endif
diff --git a/src/libtools/obstack.c b/src/libtools/obstack.c
index 42b9356..b3f2fc5 100755..100644
--- a/src/libtools/obstack.c
+++ b/src/libtools/obstack.c
@@ -44,7 +44,7 @@ GO(4)
static uintptr_t my_chunkfun_fct_##A = 0; \
static void* my_chunkfun_##A(size_t a) \
{ \
- return (void*)RunFunction(my_context, my_chunkfun_fct_##A, 1, a); \
+ return (void*)RunFunction(my_chunkfun_fct_##A, 1, a); \
}
SUPER()
#undef GO
@@ -77,7 +77,7 @@ static void* reverse_chunkfunFct(library_t* lib, void* fct)
static uintptr_t my_freefun_fct_##A = 0; \
static void my_freefun_##A(void* a) \
{ \
- RunFunction(my_context, my_freefun_fct_##A, 1, a); \
+ RunFunction(my_freefun_fct_##A, 1, a); \
}
SUPER()
#undef GO
@@ -239,7 +239,7 @@ void actual_obstack_alloc_failed_handler()
{
if(ref_obstack_alloc_failed_handler == my_obstack_alloc_failed_handler)
real_obstack_alloc_failed_handler();
- RunFunction(my_context, (uintptr_t)my_obstack_alloc_failed_handler, 0);
+ RunFunction((uintptr_t)my_obstack_alloc_failed_handler, 0);
}
void obstackSetup()
{
diff --git a/src/libtools/sdl1rwops.c b/src/libtools/sdl1rwops.c
index c7349af..ec3f8ab 100755..100644
--- a/src/libtools/sdl1rwops.c
+++ b/src/libtools/sdl1rwops.c
@@ -72,20 +72,20 @@ EXPORT int32_t my_native_close(SDL1_RWops_t *context)
}
EXPORT int32_t my_emulated_seek(SDL1_RWops_t *context, int32_t offset, int32_t whence)
{
- return (int32_t)RunFunction(my_context, (uintptr_t)context->hidden.my.orig->seek, 3, context->hidden.my.orig, offset, whence);
+ return (int32_t)RunFunctionFmt((uintptr_t)context->hidden.my.orig->seek, "pii", context->hidden.my.orig, offset, whence);
}
EXPORT int32_t my_emulated_read(SDL1_RWops_t *context, void *ptr, int32_t size, int32_t maxnum)
{
- return (int32_t)RunFunction(my_context, (uintptr_t)context->hidden.my.orig->read, 4, context->hidden.my.orig, ptr, size, maxnum);
+ return (int32_t)RunFunctionFmt((uintptr_t)context->hidden.my.orig->read, "ppii", context->hidden.my.orig, ptr, size, maxnum);
}
EXPORT int32_t my_emulated_write(SDL1_RWops_t *context, const void *ptr, int32_t size, int32_t num)
{
- return (int32_t)RunFunction(my_context, (uintptr_t)context->hidden.my.orig->write, 4, context->hidden.my.orig, ptr, size, num);
+ return (int32_t)RunFunctionFmt((uintptr_t)context->hidden.my.orig->write, "ppii", context->hidden.my.orig, ptr, size, num);
}
EXPORT int32_t my_emulated_close(SDL1_RWops_t *context)
{
- return (int32_t)RunFunction(my_context, (uintptr_t)context->hidden.my.orig->close, 1, context->hidden.my.orig);
+ return (int32_t)RunFunctionFmt((uintptr_t)context->hidden.my.orig->close, "p", context->hidden.my.orig);
}
SDL1_RWops_t* AddNativeRW(x64emu_t* emu, SDL1_RWops_t* ops)
@@ -180,4 +180,4 @@ void RWSetType(SDL1_RWops_t* r, int awesome)
{
if(r)
r->type = awesome; // I like shoot'em up :D
-} \ No newline at end of file
+}
diff --git a/src/libtools/sdl2rwops.c b/src/libtools/sdl2rwops.c
index f57dc56..085c783 100755..100644
--- a/src/libtools/sdl2rwops.c
+++ b/src/libtools/sdl2rwops.c
@@ -13,6 +13,7 @@
#include "librarian/library_private.h"
#include "bridge.h"
#include "callback.h"
+#include "librarian.h"
typedef struct SDL2_RWops_s SDL2_RWops_t;
@@ -84,31 +85,56 @@ EXPORT int32_t my2_native_close(SDL2_RWops_t *context)
}
EXPORT int64_t my2_emulated_size(SDL2_RWops_t *context)
{
- return (int64_t)RunFunction(my_context, (uintptr_t)context->hidden.my.orig->size, 1, context->hidden.my.orig);
+ return (int64_t)RunFunctionFmt((uintptr_t)context->hidden.my.orig->size, "p", context->hidden.my.orig);
}
EXPORT int64_t my2_emulated_seek(SDL2_RWops_t *context, int64_t offset, int32_t whence)
{
- return (int64_t)RunFunction(my_context, (uintptr_t)context->hidden.my.orig->seek, 3, context->hidden.my.orig, offset, whence);
+ return (int64_t)RunFunctionFmt((uintptr_t)context->hidden.my.orig->seek, "pIi", context->hidden.my.orig, offset, whence);
}
EXPORT int32_t my2_emulated_read(SDL2_RWops_t *context, void *ptr, int32_t size, int32_t maxnum)
{
- return (int32_t)RunFunction(my_context, (uintptr_t)context->hidden.my.orig->read, 4, context->hidden.my.orig, ptr, size, maxnum);
+ return (int32_t)RunFunctionFmt((uintptr_t)context->hidden.my.orig->read, "ppii", context->hidden.my.orig, ptr, size, maxnum);
}
EXPORT int32_t my2_emulated_write(SDL2_RWops_t *context, const void *ptr, int32_t size, int32_t num)
{
- return (int32_t)RunFunction(my_context, (uintptr_t)context->hidden.my.orig->write, 4, context->hidden.my.orig, ptr, size, num);
+ return (int32_t)RunFunctionFmt((uintptr_t)context->hidden.my.orig->write, "ppii", context->hidden.my.orig, ptr, size, num);
}
EXPORT int32_t my2_emulated_close(SDL2_RWops_t *context)
{
- int ret = (int32_t)RunFunction(my_context, (uintptr_t)context->hidden.my.orig->close, 1, context->hidden.my.orig);
+ int ret = (int32_t)RunFunctionFmt((uintptr_t)context->hidden.my.orig->close, "p", context->hidden.my.orig);
context->hidden.my.custom_free(context);
return ret;
}
+static uintptr_t emulated_sdl2allocrw = 0;
+EXPORT SDL2_RWops_t* my_wrapped_sdl2allocrw()
+{
+ return (SDL2_RWops_t*)RunFunctionFmt(emulated_sdl2allocrw, "");
+}
+static uintptr_t emulated_sdl2freerw = 0;
+EXPORT void my_wrapped_sdl2freerw(SDL2_RWops_t* p)
+{
+ RunFunctionFmt(emulated_sdl2freerw, "p", p);
+}
+
+static void checkSDL2isNative()
+{
+ if(my_context->sdl2allocrw)
+ return;
+ emulated_sdl2allocrw = FindGlobalSymbol(my_context->maplib, "SDL_AllocRW", -1, NULL);
+ emulated_sdl2freerw = FindGlobalSymbol(my_context->maplib, "SDL_FreeRW", -1, NULL);
+ if(emulated_sdl2allocrw && emulated_sdl2freerw) {
+ my_context->sdl2allocrw = my_wrapped_sdl2allocrw;
+ my_context->sdl2freerw = my_wrapped_sdl2freerw;
+ } else
+ printf_log(LOG_NONE, "Warning, cannot find SDL_AllocRW and/or SDL_FreeRW function in loaded libs");
+}
+
SDL2_RWops_t* AddNativeRW2(x64emu_t* emu, SDL2_RWops_t* ops)
{
if(!ops)
return NULL;
+ checkSDL2isNative();
uintptr_t fnc;
bridge_t* system = emu->context->system;
@@ -141,13 +167,14 @@ SDL2_RWops_t* RWNativeStart2(x64emu_t* emu, SDL2_RWops_t* ops)
if(ops->type == BOX64RW)
return ops->hidden.my.orig;
+ checkSDL2isNative();
sdl2_allocrw Alloc = (sdl2_allocrw)emu->context->sdl2allocrw;
SDL2_RWops_t* newrw = Alloc();
newrw->type = BOX64RW;
newrw->hidden.my.orig = ops;
newrw->hidden.my.custom_free = (sdl2_freerw)emu->context->sdl2freerw;
-
+
// create wrapper
#define GO(A, W) \
newrw->A = my2_emulated_##A;
@@ -202,4 +229,4 @@ int32_t RWNativeWrite2(SDL2_RWops_t *ops, const void *ptr, int32_t size, int32_t
int32_t RWNativeClose2(SDL2_RWops_t* ops)
{
return ops->close(ops);
-} \ No newline at end of file
+}
diff --git a/src/libtools/signals.c b/src/libtools/signals.c
index 0558a88..e47a3da 100755..100644
--- a/src/libtools/signals.c
+++ b/src/libtools/signals.c
@@ -1,3 +1,4 @@
+#define _GNU_SOURCE
#include <stdlib.h>
#include <stdio.h>
#include <stdint.h>
@@ -269,7 +270,7 @@ static void sigstack_key_alloc() {
//1<<8 is mutex_dyndump
#define is_dyndump_locked (1<<8)
-uint64_t RunFunctionHandler(int* exit, x64_ucontext_t* sigcontext, uintptr_t fnc, int nargs, ...)
+uint64_t RunFunctionHandler(int* exit, int dynarec, x64_ucontext_t* sigcontext, uintptr_t fnc, int nargs, ...)
{
if(fnc==0 || fnc==1) {
va_list va;
@@ -291,8 +292,10 @@ uint64_t RunFunctionHandler(int* exit, x64_ucontext_t* sigcontext, uintptr_t fnc
#endif
x64emu_t *emu = thread_get_emu();
-
- printf_log(LOG_DEBUG, "%04d|signal function handler %p called, RSP=%p\n", GetTID(), (void*)fnc, (void*)R_RSP);
+ #ifdef DYNAREC
+ if(box64_dynarec_test)
+ emu->test.test = 0;
+ #endif
/*SetFS(emu, default_fs);*/
for (int i=0; i<6; ++i)
@@ -316,19 +319,37 @@ uint64_t RunFunctionHandler(int* exit, x64_ucontext_t* sigcontext, uintptr_t fnc
}
va_end (va);
- int oldquitonlongjmp = emu->quitonlongjmp;
- emu->quitonlongjmp = 2;
+ printf_log(LOG_DEBUG, "%04d|signal #%d function handler %p called, RSP=%p\n", GetTID(), R_EDI, (void*)fnc, (void*)R_RSP);
+
+ int oldquitonlongjmp = emu->flags.quitonlongjmp;
+ emu->flags.quitonlongjmp = 2;
+ int old_cs = R_CS;
+ R_CS = 0x33;
- EmuCall(emu, fnc); // avoid DynaCall for now
- //DynaCall(emu, fnc);
- if(nargs>6)
+ emu->eflags.x64 &= ~(1<<F_TF); // this one needs to cleared
+
+ if(dynarec)
+ DynaCall(emu, fnc);
+ else
+ EmuCall(emu, fnc);
+
+ if(nargs>6 && !emu->flags.longjmp)
R_RSP+=((nargs-6)*sizeof(void*));
- emu->quitonlongjmp = oldquitonlongjmp;
+ if(!emu->flags.longjmp && R_CS==0x33)
+ R_CS = old_cs;
+
+ emu->flags.quitonlongjmp = oldquitonlongjmp;
+
+ #ifdef DYNAREC
+ if(box64_dynarec_test)
+ emu->test.test = 0;
+ emu->test.clean = 0;
+ #endif
- if(emu->longjmp) {
+ if(emu->flags.longjmp) {
// longjmp inside signal handler, lets grab all relevent value and do the actual longjmp in the signal handler
- emu->longjmp = 0;
+ emu->flags.longjmp = 0;
if(sigcontext) {
sigcontext->uc_mcontext.gregs[X64_R8] = R_R8;
sigcontext->uc_mcontext.gregs[X64_R9] = R_R9;
@@ -439,6 +460,25 @@ uintptr_t getX64Address(dynablock_t* db, uintptr_t arm_addr)
} while(db->instsize[i].x64 || db->instsize[i].nat);
return x64addr;
}
+x64emu_t* getEmuSignal(x64emu_t* emu, ucontext_t* p, dynablock_t* db)
+{
+#if defined(ARM64)
+ if(db && p->uc_mcontext.regs[0]>0x10000) {
+ emu = (x64emu_t*)p->uc_mcontext.regs[0];
+ }
+#elif defined(LA464)
+ if(db && p->uc_mcontext.__gregs[4]>0x10000) {
+ emu = (x64emu_t*)p->uc_mcontext.__gregs[4];
+ }
+#elif defined(RV64)
+ if(db && p->uc_mcontext.__gregs[10]>0x10000) {
+ emu = (x64emu_t*)p->uc_mcontext.__gregs[10];
+ }
+#else
+#error Unsupported Architecture
+#endif //arch
+ return emu;
+}
#endif
void copyUCTXreg2Emu(x64emu_t* emu, ucontext_t* p, uintptr_t ip) {
@@ -481,6 +521,25 @@ void copyUCTXreg2Emu(x64emu_t* emu, ucontext_t* p, uintptr_t ip) {
emu->regs[_R15].q[0] = p->uc_mcontext.__gregs[30];
emu->ip.q[0] = ip;
emu->eflags.x64 = p->uc_mcontext.__gregs[31];
+#elif defined(RV64)
+ emu->regs[_AX].q[0] = p->uc_mcontext.__gregs[16];
+ emu->regs[_CX].q[0] = p->uc_mcontext.__gregs[17];
+ emu->regs[_DX].q[0] = p->uc_mcontext.__gregs[18];
+ emu->regs[_BX].q[0] = p->uc_mcontext.__gregs[19];
+ emu->regs[_SP].q[0] = p->uc_mcontext.__gregs[20];
+ emu->regs[_BP].q[0] = p->uc_mcontext.__gregs[21];
+ emu->regs[_SI].q[0] = p->uc_mcontext.__gregs[22];
+ emu->regs[_DI].q[0] = p->uc_mcontext.__gregs[23];
+ emu->regs[_R8].q[0] = p->uc_mcontext.__gregs[24];
+ emu->regs[_R9].q[0] = p->uc_mcontext.__gregs[25];
+ emu->regs[_R10].q[0] = p->uc_mcontext.__gregs[26];
+ emu->regs[_R11].q[0] = p->uc_mcontext.__gregs[27];
+ emu->regs[_R12].q[0] = p->uc_mcontext.__gregs[28];
+ emu->regs[_R13].q[0] = p->uc_mcontext.__gregs[29];
+ emu->regs[_R14].q[0] = p->uc_mcontext.__gregs[30];
+ emu->regs[_R15].q[0] = p->uc_mcontext.__gregs[31];
+ emu->ip.q[0] = ip;
+ emu->eflags.x64 = p->uc_mcontext.__gregs[5];
#else
#error Unsupported architecture
#endif
@@ -512,12 +571,22 @@ void my_sigactionhandler_oldcode(int32_t sig, int simple, siginfo_t* info, void
if(db) {
frame = (uintptr_t)p->uc_mcontext.__gregs[12+_SP];
}
+#elif defined(RV64)
+ ucontext_t *p = (ucontext_t *)ucntx;
+ void * pc = (void*)p->uc_mcontext.__gregs[0];
+ dynablock_t* db = (dynablock_t*)cur_db;//FindDynablockFromNativeAddress(pc);
+ if(db) {
+ frame = (uintptr_t)p->uc_mcontext.__gregs[16+_SP];
+ }
#else
#error Unsupported architecture
#endif
#else
(void)ucntx; (void)cur_db;
#endif
+ // setup libc context stack frame, on caller stack
+ frame = frame&~15;
+
// stack tracking
x64_stack_t *new_ss = my_context->onstack[sig]?(x64_stack_t*)pthread_getspecific(sigstack_key):NULL;
int used_stack = 0;
@@ -604,6 +673,26 @@ void my_sigactionhandler_oldcode(int32_t sig, int simple, siginfo_t* info, void
sigcontext->uc_mcontext.gregs[X64_R15] = p->uc_mcontext.__gregs[30];
sigcontext->uc_mcontext.gregs[X64_RIP] = getX64Address(db, (uintptr_t)pc);
}
+#elif defined(RV64)
+ if(db) {
+ sigcontext->uc_mcontext.gregs[X64_RAX] = p->uc_mcontext.__gregs[16];
+ sigcontext->uc_mcontext.gregs[X64_RCX] = p->uc_mcontext.__gregs[17];
+ sigcontext->uc_mcontext.gregs[X64_RDX] = p->uc_mcontext.__gregs[18];
+ sigcontext->uc_mcontext.gregs[X64_RBX] = p->uc_mcontext.__gregs[19];
+ sigcontext->uc_mcontext.gregs[X64_RSP] = p->uc_mcontext.__gregs[20];
+ sigcontext->uc_mcontext.gregs[X64_RBP] = p->uc_mcontext.__gregs[21];
+ sigcontext->uc_mcontext.gregs[X64_RSI] = p->uc_mcontext.__gregs[22];
+ sigcontext->uc_mcontext.gregs[X64_RDI] = p->uc_mcontext.__gregs[23];
+ sigcontext->uc_mcontext.gregs[X64_R8] = p->uc_mcontext.__gregs[24];
+ sigcontext->uc_mcontext.gregs[X64_R9] = p->uc_mcontext.__gregs[25];
+ sigcontext->uc_mcontext.gregs[X64_R10] = p->uc_mcontext.__gregs[26];
+ sigcontext->uc_mcontext.gregs[X64_R11] = p->uc_mcontext.__gregs[27];
+ sigcontext->uc_mcontext.gregs[X64_R12] = p->uc_mcontext.__gregs[28];
+ sigcontext->uc_mcontext.gregs[X64_R13] = p->uc_mcontext.__gregs[29];
+ sigcontext->uc_mcontext.gregs[X64_R14] = p->uc_mcontext.__gregs[30];
+ sigcontext->uc_mcontext.gregs[X64_R15] = p->uc_mcontext.__gregs[31];
+ sigcontext->uc_mcontext.gregs[X64_RIP] = getX64Address(db, (uintptr_t)pc);
+ }
#else
#error Unsupported architecture
#endif
@@ -648,8 +737,8 @@ void my_sigactionhandler_oldcode(int32_t sig, int simple, siginfo_t* info, void
sigcontext->uc_mcontext.gregs[X64_TRAPNO] = 17;
else if(sig==SIGSEGV) {
if((uintptr_t)info->si_addr == sigcontext->uc_mcontext.gregs[X64_RIP]) {
- sigcontext->uc_mcontext.gregs[X64_ERR] = (info->si_errno==0x1234)?0:0x0010; // execution flag issue (probably), unless it's a #GP(0)
- sigcontext->uc_mcontext.gregs[X64_TRAPNO] = (info->si_code == SEGV_ACCERR || (info->si_errno==0x1234) || (uintptr_t)info->si_addr==0)?13:14;
+ sigcontext->uc_mcontext.gregs[X64_ERR] = (info->si_errno==0x1234)?0:((info->si_errno==0xdead)?(0x2|(info->si_code<<3)):0x0010); // execution flag issue (probably), unless it's a #GP(0)
+ sigcontext->uc_mcontext.gregs[X64_TRAPNO] = (info->si_code == SEGV_ACCERR || (info->si_errno==0x1234) || (info->si_errno==0xdead) || (uintptr_t)info->si_addr==0)?13:14;
} else if(info->si_code==SEGV_ACCERR && !(prot&PROT_WRITE)) {
sigcontext->uc_mcontext.gregs[X64_ERR] = 0x0002; // write flag issue
if(labs((intptr_t)info->si_addr-(intptr_t)sigcontext->uc_mcontext.gregs[X64_RSP])<16)
@@ -657,16 +746,21 @@ void my_sigactionhandler_oldcode(int32_t sig, int simple, siginfo_t* info, void
else
sigcontext->uc_mcontext.gregs[X64_TRAPNO] = 14; // PAGE_FAULT
} else {
- sigcontext->uc_mcontext.gregs[X64_TRAPNO] = (info->si_code == SEGV_ACCERR)?13:14;
+ sigcontext->uc_mcontext.gregs[X64_TRAPNO] = (info->si_code == SEGV_ACCERR)?14:13;
//X64_ERR seems to be INT:8 CODE:8. So for write access segfault it's 0x0002 For a read it's 0x0004 (and 8 for exec). For an int 2d it could be 0x2D01 for example
sigcontext->uc_mcontext.gregs[X64_ERR] = 0x0004; // read error? there is no execute control in box64 anyway
}
if(info->si_code == SEGV_ACCERR && old_code)
*old_code = -1;
- } else if(sig==SIGFPE)
- sigcontext->uc_mcontext.gregs[X64_TRAPNO] = 19;
- else if(sig==SIGILL)
+ } else if(sig==SIGFPE) {
+ if (info->si_code == FPE_INTOVF)
+ sigcontext->uc_mcontext.gregs[X64_TRAPNO] = 4;
+ else
+ sigcontext->uc_mcontext.gregs[X64_TRAPNO] = 19;
+ } else if(sig==SIGILL)
sigcontext->uc_mcontext.gregs[X64_TRAPNO] = 6;
+ else if(sig==SIGTRAP)
+ sigcontext->uc_mcontext.gregs[X64_TRAPNO] = info->si_code;
//TODO: SIGABRT generate what?
// call the signal handler
x64_ucontext_t sigcontext_copy = *sigcontext;
@@ -688,10 +782,15 @@ void my_sigactionhandler_oldcode(int32_t sig, int simple, siginfo_t* info, void
int exits = 0;
int ret;
- if (simple)
- ret = RunFunctionHandler(&exits, sigcontext, my_context->signals[sig], 1, sig);
- else
- ret = RunFunctionHandler(&exits, sigcontext, my_context->signals[sig], 3, sig, info2, sigcontext);
+ int dynarec = 0;
+ #ifdef DYNAREC
+ if(sig!=SIGSEGV && !(Locks&is_dyndump_locked))
+ dynarec = 1;
+ #endif
+ /*if (simple)
+ ret = RunFunctionHandler(&exits, dynarec, sigcontext, my_context->signals[sig], 1, sig);
+ else*/
+ ret = RunFunctionHandler(&exits, dynarec, sigcontext, my_context->signals[sig], 3, sig, info2, sigcontext);
// restore old value from emu
if(used_stack) // release stack
new_ss->ss_flags = 0;
@@ -707,9 +806,8 @@ void my_sigactionhandler_oldcode(int32_t sig, int simple, siginfo_t* info, void
#undef GO
if(memcmp(sigcontext, &sigcontext_copy, sizeof(x64_ucontext_t))) {
- emu_jmpbuf_t* ejb = GetJmpBuf();
- if(ejb->jmpbuf_ok) {
- #define GO(R) ejb->emu->regs[_##R].q[0]=sigcontext->uc_mcontext.gregs[X64_R##R]
+ if(emu->jmpbuf) {
+ #define GO(R) emu->regs[_##R].q[0]=sigcontext->uc_mcontext.gregs[X64_R##R]
GO(AX);
GO(CX);
GO(DX);
@@ -719,7 +817,7 @@ void my_sigactionhandler_oldcode(int32_t sig, int simple, siginfo_t* info, void
GO(SP);
GO(BX);
#undef GO
- #define GO(R) ejb->emu->regs[_##R].q[0]=sigcontext->uc_mcontext.gregs[X64_##R]
+ #define GO(R) emu->regs[_##R].q[0]=sigcontext->uc_mcontext.gregs[X64_##R]
GO(R8);
GO(R9);
GO(R10);
@@ -729,20 +827,22 @@ void my_sigactionhandler_oldcode(int32_t sig, int simple, siginfo_t* info, void
GO(R14);
GO(R15);
#undef GO
- ejb->emu->ip.q[0]=sigcontext->uc_mcontext.gregs[X64_RIP];
+ emu->ip.q[0]=sigcontext->uc_mcontext.gregs[X64_RIP];
sigcontext->uc_mcontext.gregs[X64_RIP] = R_RIP;
// flags
- ejb->emu->eflags.x64=sigcontext->uc_mcontext.gregs[X64_EFL];
+ emu->eflags.x64=sigcontext->uc_mcontext.gregs[X64_EFL];
// get segments
uint16_t seg;
seg = (sigcontext->uc_mcontext.gregs[X64_CSGSFS] >> 0)&0xffff;
- #define GO(S) if(ejb->emu->segs[_##S]!=seg) {ejb->emu->segs[_##S]=seg; ejb->emu->segs_serial[_##S] = 0;}
+ #define GO(S) if(emu->segs[_##S]!=seg) emu->segs[_##S]=seg
GO(CS);
seg = (sigcontext->uc_mcontext.gregs[X64_CSGSFS] >> 16)&0xffff;
GO(GS);
seg = (sigcontext->uc_mcontext.gregs[X64_CSGSFS] >> 32)&0xffff;
GO(FS);
#undef GO
+ for(int i=0; i<6; ++i)
+ emu->segs_serial[i] = 0;
printf_log(LOG_DEBUG, "Context has been changed in Sigactionhanlder, doing siglongjmp to resume emu at %p\n", (void*)R_RIP);
if(old_code)
*old_code = -1; // re-init the value to allow another segfault at the same place
@@ -753,7 +853,7 @@ void my_sigactionhandler_oldcode(int32_t sig, int simple, siginfo_t* info, void
if(Locks & is_dyndump_locked)
CancelBlock64(1);
#endif
- siglongjmp(ejb->jmpbuf, 1);
+ siglongjmp(emu->jmpbuf, 1);
}
printf_log(LOG_INFO, "Warning, context has been changed in Sigactionhanlder%s\n", (sigcontext->uc_mcontext.gregs[X64_RIP]!=sigcontext_copy.uc_mcontext.gregs[X64_RIP])?" (EIP changed)":"");
}
@@ -798,13 +898,23 @@ void my_sigactionhandler_oldcode(int32_t sig, int simple, siginfo_t* info, void
exit(ret);
}
if(restorer)
- RunFunctionHandler(&exits, NULL, restorer, 0);
+ RunFunctionHandler(&exits, 0, NULL, restorer, 0);
relockMutex(Locks);
}
extern void* current_helper;
-#ifdef DYNAREC
+#define USE_SIGNAL_MUTEX
+#ifdef USE_SIGNAL_MUTEX
+#ifdef USE_CUSTOM_MUTEX
static uint32_t mutex_dynarec_prot = 0;
+#else
+static pthread_mutex_t mutex_dynarec_prot = PTHREAD_ERRORCHECK_MUTEX_INITIALIZER_NP;
+#endif
+#define lock_signal() mutex_lock(&mutex_dynarec_prot)
+#define unlock_signal() mutex_unlock(&mutex_dynarec_prot)
+#else // USE_SIGNAL_MUTEX
+#define lock_signal()
+#define unlock_signal()
#endif
extern int box64_quit;
@@ -820,6 +930,7 @@ void my_box64signalhandler(int32_t sig, siginfo_t* info, void * ucntx)
ucontext_t *p = (ucontext_t *)ucntx;
void* addr = (void*)info->si_addr; // address that triggered the issue
void* rsp = NULL;
+ x64emu_t* emu = thread_get_emu();
#ifdef __aarch64__
void * pc = (void*)p->uc_mcontext.pc;
struct fpsimd_context *fpsimd = NULL;
@@ -859,14 +970,15 @@ void my_box64signalhandler(int32_t sig, siginfo_t* info, void * ucntx)
#endif
#ifdef DYNAREC
if((Locks & is_dyndump_locked) && (sig==SIGSEGV) && current_helper) {
- relockMutex(Locks);
+ printf_log(LOG_INFO, "FillBlock triggered a segfault at %p from %p\n", addr, pc);
CancelBlock64(0);
cancelFillBlock(); // Segfault inside a Fillblock, cancel it's creation...
+ relockMutex(Locks);
}
dynablock_t* db = NULL;
int db_searched = 0;
if ((sig==SIGSEGV) && (addr) && (info->si_code == SEGV_ACCERR) && (prot&PROT_DYNAREC)) {
- mutex_lock(&mutex_dynarec_prot);
+ lock_signal();
// check if SMC inside block
db = FindDynablockFromNativeAddress(pc);
db_searched = 1;
@@ -883,24 +995,33 @@ void my_box64signalhandler(int32_t sig, siginfo_t* info, void * ucntx)
}
// access error, unprotect the block (and mark them dirty)
unprotectDB((uintptr_t)addr, 1, 1); // unprotect 1 byte... But then, the whole page will be unprotected
- if(db && ((addr>=db->x64_addr && addr<(db->x64_addr+db->x64_size)) || db->need_test)) {
+ int db_need_test = (db && !box64_dynarec_fastpage)?getNeedTest((uintptr_t)db->x64_addr):0;
+ if(db && ((addr>=db->x64_addr && addr<(db->x64_addr+db->x64_size)) || db_need_test)) {
+ emu = getEmuSignal(emu, p, db);
// dynablock got auto-dirty! need to get out of it!!!
- emu_jmpbuf_t* ejb = GetJmpBuf();
- if(ejb->jmpbuf_ok) {
- copyUCTXreg2Emu(ejb->emu, p, getX64Address(db, (uintptr_t)pc));
+ if(emu->jmpbuf) {
+ copyUCTXreg2Emu(emu, p, getX64Address(db, (uintptr_t)pc));
#ifdef ARM64
- if(fpsimd) {
- ejb->emu->xmm[0].u128 = fpsimd->vregs[0];
- ejb->emu->xmm[1].u128 = fpsimd->vregs[1];
- ejb->emu->xmm[2].u128 = fpsimd->vregs[2];
- ejb->emu->xmm[3].u128 = fpsimd->vregs[3];
- }
+ //TODO: Need proper SIMD/x87 register traking!
+ /*if(fpsimd) {
+ emu->xmm[0].u128 = fpsimd->vregs[0];
+ emu->xmm[1].u128 = fpsimd->vregs[1];
+ emu->xmm[2].u128 = fpsimd->vregs[2];
+ emu->xmm[3].u128 = fpsimd->vregs[3];
+ }*/
#elif defined(LA464)
/*if(fpsimd) {
- ejb->emu->xmm[0].u128 = fpsimd->vregs[0];
- ejb->emu->xmm[1].u128 = fpsimd->vregs[1];
- ejb->emu->xmm[2].u128 = fpsimd->vregs[2];
- ejb->emu->xmm[3].u128 = fpsimd->vregs[3];
+ emu->xmm[0].u128 = fpsimd->vregs[0];
+ emu->xmm[1].u128 = fpsimd->vregs[1];
+ emu->xmm[2].u128 = fpsimd->vregs[2];
+ emu->xmm[3].u128 = fpsimd->vregs[3];
+ }*/
+#elif defined(RV64)
+ /*if(fpsimd) {
+ emu->xmm[0].u128 = fpsimd->vregs[0];
+ emu->xmm[1].u128 = fpsimd->vregs[1];
+ emu->xmm[2].u128 = fpsimd->vregs[2];
+ emu->xmm[3].u128 = fpsimd->vregs[3];
}*/
#else
#error Unsupported architecture
@@ -911,30 +1032,31 @@ void my_box64signalhandler(int32_t sig, siginfo_t* info, void * ucntx)
dynarec_log(LOG_INFO, "Dynablock unprotected, getting out!\n");
}
//relockMutex(Locks);
- mutex_unlock(&mutex_dynarec_prot);
- #ifdef DYNAREC
+ unlock_signal();
if(Locks & is_dyndump_locked)
CancelBlock64(1);
- #endif
- siglongjmp(ejb->jmpbuf, 2);
+ emu->test.clean = 0;
+ siglongjmp(emu->jmpbuf, 2);
}
dynarec_log(LOG_INFO, "Warning, Auto-SMC (%p for db %p/%p) detected, but jmpbuffer not ready!\n", (void*)addr, db, (void*)db->x64_addr);
}
// done
- if((prot&PROT_WRITE) || (prot&PROT_DYNAREC)) {
- mutex_unlock(&mutex_dynarec_prot);
+ if((prot&PROT_WRITE)/*|| (prot&PROT_DYNAREC)*/) {
+ unlock_signal();
// if there is no write permission, don't return and continue to program signal handling
relockMutex(Locks);
return;
}
- mutex_unlock(&mutex_dynarec_prot);
+ unlock_signal();
} else if ((sig==SIGSEGV) && (addr) && (info->si_code == SEGV_ACCERR) && ((prot&(PROT_READ|PROT_WRITE))==(PROT_READ|PROT_WRITE))) {
- mutex_lock(&mutex_dynarec_prot);
+ lock_signal();
db = FindDynablockFromNativeAddress(pc);
db_searched = 1;
if(db && db->x64_addr>= addr && (db->x64_addr+db->x64_size)<addr) {
dynarec_log(LOG_INFO, "Warning, addr inside current dynablock!\n");
}
+ // mark stuff as unclean
+ cleanDBFromAddressRange(((uintptr_t)addr)&~(box64_pagesize-1), box64_pagesize, 0);
static void* glitch_pc = NULL;
static void* glitch_addr = NULL;
static int glitch_prot = 0;
@@ -946,7 +1068,7 @@ void my_box64signalhandler(int32_t sig, siginfo_t* info, void * ucntx)
glitch_addr = addr;
glitch_prot = prot;
relockMutex(Locks);
- mutex_unlock(&mutex_dynarec_prot);
+ unlock_signal();
return; // try again
}
dynarec_log(/*LOG_DEBUG*/LOG_INFO, "Repeated SIGSEGV with Access error on %p for %p, db=%p, prot=0x%x\n", pc, addr, db, prot);
@@ -968,14 +1090,14 @@ dynarec_log(/*LOG_DEBUG*/LOG_INFO, "Repeated SIGSEGV with Access error on %p for
refreshProtection((uintptr_t)addr);
relockMutex(Locks);
sched_yield(); // give time to the other process
- mutex_unlock(&mutex_dynarec_prot);
+ unlock_signal();
return; // try again
}
glitch2_pc = NULL;
glitch2_addr = NULL;
glitch2_prot = 0;
}
- mutex_unlock(&mutex_dynarec_prot);
+ unlock_signal();
} else if ((sig==SIGSEGV) && (addr) && (info->si_code == SEGV_ACCERR) && (prot&PROT_DYNAREC_R)) {
// unprotect and continue to signal handler, because Write is not there on purpose
unprotectDB((uintptr_t)addr, 1, 1); // unprotect 1 byte... But then, the whole page will be unprotected
@@ -994,10 +1116,13 @@ dynarec_log(/*LOG_DEBUG*/LOG_INFO, "Repeated SIGSEGV with Access error on %p for
printf_log(log_minimum, "%04d|Double %s (code=%d, pc=%p, addr=%p)!\n", GetTID(), signame, old_code, old_pc, old_addr);
exit(-1);
} else {
- if(sig==SIGSEGV && info->si_code==2 && ((prot&~PROT_DYN)==5 || (prot&~PROT_DYN)==7)) {
+ if((sig==SIGSEGV) && (info->si_code == SEGV_ACCERR) && ((prot&~PROT_CUSTOM)==5 || (prot&~PROT_CUSTOM)==7)) {
static uintptr_t old_addr = 0;
printf_log(/*LOG_DEBUG*/LOG_INFO, "Strange SIGSEGV with Access error on %p for %p, db=%p, prot=0x%x (old_addr=%p)\n", pc, addr, db, prot, (void*)old_addr);
- if(old_addr!=(uintptr_t)addr) {
+ #ifdef DYNAREC
+ cleanDBFromAddressRange(((uintptr_t)addr)&~(box64_pagesize-1), box64_pagesize, 0);
+ #endif
+ if(old_addr!=(uintptr_t)addr || getMmapped((uintptr_t)addr)) {
old_addr = (uintptr_t)addr;
refreshProtection(old_addr);
relockMutex(Locks);
@@ -1009,11 +1134,10 @@ exit(-1);
old_pc = pc;
old_addr = addr;
old_tid = GetTID();
- const char* name = GetNativeName(pc);
+ const char* name = (log_minimum<=box64_log)?GetNativeName(pc):NULL;
uintptr_t x64pc = (uintptr_t)-1;
const char* x64name = NULL;
const char* elfname = NULL;
- x64emu_t* emu = thread_get_emu();
// Adjust RIP for special case of NULL function run
if(sig==SIGSEGV && R_RIP==0x1 && (uintptr_t)info->si_addr==0x0)
R_RIP = 0x0;
@@ -1021,9 +1145,6 @@ exit(-1);
rsp = (void*)R_RSP;
#if defined(DYNAREC)
#if defined(ARM64)
- if(db && p->uc_mcontext.regs[0]>0x10000) {
- emu = (x64emu_t*)p->uc_mcontext.regs[0];
- }
if(db) {
x64pc = getX64Address(db, (uintptr_t)pc);
rsp = (void*)p->uc_mcontext.regs[10+_SP];
@@ -1036,16 +1157,26 @@ exit(-1);
x64pc = getX64Address(db, (uintptr_t)pc);
rsp = (void*)p->uc_mcontext.__gregs[12+_SP];
}
+#elif defined(RV64)
+ if(db && p->uc_mcontext.__gregs[10]>0x10000) {
+ emu = (x64emu_t*)p->uc_mcontext.__gregs[10];
+ }
+ if(db) {
+ x64pc = getX64Address(db, (uintptr_t)pc);
+ rsp = (void*)p->uc_mcontext.__gregs[16+_SP];
+ }
#else
#error Unsupported Architecture
#endif //arch
#endif //DYNAREC
if(!db && (sig==SIGSEGV) && ((uintptr_t)addr==x64pc-1))
x64pc--;
- x64name = getAddrFunctionName(x64pc);
- elfheader_t* elf = FindElfAddress(my_context, x64pc);
- if(elf)
- elfname = ElfName(elf);
+ if(log_minimum<=box64_log) {
+ x64name = getAddrFunctionName(x64pc);
+ elfheader_t* elf = FindElfAddress(my_context, x64pc);
+ if(elf)
+ elfname = ElfName(elf);
+ }
if(jit_gdb) {
pid_t pid = getpid();
int v = vfork(); // is this ok in a signal handler???
@@ -1138,50 +1269,75 @@ exit(-1);
GO(RIP);
#undef GO
}
- static const char* reg_name[] = {"RAX", "RCX", "RDX", "RBX", "RSP", "RBP", "RSI", "RDI", " R8", " R9","R10","R11", "R12","R13","R14","R15"};
- int shown_regs = 0;
+ if(log_minimum<=box64_log) {
+ static const char* reg_name[] = {"RAX", "RCX", "RDX", "RBX", "RSP", "RBP", "RSI", "RDI", " R8", " R9","R10","R11", "R12","R13","R14","R15"};
+ static const char* seg_name[] = {"ES", "CS", "SS", "DS", "FS", "GS"};
+ int shown_regs = 0;
#ifdef DYNAREC
- uint32_t hash = 0;
- if(db)
- hash = X31_hash_code(db->x64_addr, db->x64_size);
- printf_log(log_minimum, "%04d|%s @%p (%s) (x64pc=%p/%s:\"%s\", rsp=%p, stack=%p:%p own=%p fp=%p), for accessing %p (code=%d/prot=%x), db=%p(%p:%p/%p:%p/%s:%s, hash:%x/%x) handler=%p",
- GetTID(), signame, pc, name, (void*)x64pc, elfname?elfname:"???", x64name?x64name:"???", rsp,
- emu->init_stack, emu->init_stack+emu->size_stack, emu->stack2free, (void*)R_RBP,
- addr, info->si_code,
- prot, db, db?db->block:0, db?(db->block+db->size):0,
- db?db->x64_addr:0, db?(db->x64_addr+db->x64_size):0,
- getAddrFunctionName((uintptr_t)(db?db->x64_addr:0)),
- (db?db->need_test:0)?"need_stest":"clean", db?db->hash:0, hash,
- (void*)my_context->signals[sig]);
+ uint32_t hash = 0;
+ if(db)
+ hash = X31_hash_code(db->x64_addr, db->x64_size);
+ printf_log(log_minimum, "%04d|%s @%p (%s) (x64pc=%p/%s:\"%s\", rsp=%p, stack=%p:%p own=%p fp=%p), for accessing %p (code=%d/prot=%x), db=%p(%p:%p/%p:%p/%s:%s, hash:%x/%x) handler=%p",
+ GetTID(), signame, pc, name, (void*)x64pc, elfname?elfname:"???", x64name?x64name:"???", rsp,
+ emu->init_stack, emu->init_stack+emu->size_stack, emu->stack2free, (void*)R_RBP,
+ addr, info->si_code,
+ prot, db, db?db->block:0, db?(db->block+db->size):0,
+ db?db->x64_addr:0, db?(db->x64_addr+db->x64_size):0,
+ getAddrFunctionName((uintptr_t)(db?db->x64_addr:0)),
+ (db?getNeedTest((uintptr_t)db->x64_addr):0)?"need_stest":"clean", db?db->hash:0, hash,
+ (void*)my_context->signals[sig]);
#if defined(ARM64)
- if(db) {
- shown_regs = 1;
- for (int i=0; i<16; ++i) {
- if(!(i%4)) printf_log(log_minimum, "\n");
- printf_log(log_minimum, "%s:0x%016llx ", reg_name[i], p->uc_mcontext.regs[10+i]);
+ if(db) {
+ shown_regs = 1;
+ for (int i=0; i<16; ++i) {
+ if(!(i%4)) printf_log(log_minimum, "\n");
+ printf_log(log_minimum, "%s:0x%016llx ", reg_name[i], p->uc_mcontext.regs[10+i]);
+ }
+ printf_log(log_minimum, "\n");
+ for (int i=0; i<6; ++i)
+ printf_log(log_minimum, "%s:0x%04x ", seg_name[i], emu->segs[i]);
}
- }
- if(rsp!=addr)
- for (int i=-4; i<4; ++i) {
- printf_log(log_minimum, "%sRSP%c0x%02x:0x%016lx", (i%4)?" ":"\n", i<0?'-':'+', abs(i)*8, *(uintptr_t*)(rsp+i*8));
+ if(rsp!=addr && getProtection((uintptr_t)rsp-4*8) && getProtection((uintptr_t)rsp+4*8))
+ for (int i=-4; i<4; ++i) {
+ printf_log(log_minimum, "%sRSP%c0x%02x:0x%016lx", (i%4)?" ":"\n", i<0?'-':'+', abs(i)*8, *(uintptr_t*)(rsp+i*8));
+ }
+#elif defined(RV64)
+ if(db) {
+ shown_regs = 1;
+ for (int i=0; i<16; ++i) {
+ if(!(i%4)) printf_log(log_minimum, "\n");
+ printf_log(log_minimum, "%s:0x%016llx ", reg_name[i], p->uc_mcontext.__gregs[16+i]);
+ }
+ printf_log(log_minimum, "\n");
+ for (int i=0; i<6; ++i)
+ printf_log(log_minimum, "%s:0x%04x ", seg_name[i], emu->segs[i]);
}
+ if(rsp!=addr && getProtection((uintptr_t)rsp-4*8) && getProtection((uintptr_t)rsp+4*8))
+ for (int i=-4; i<4; ++i) {
+ printf_log(log_minimum, "%sRSP%c0x%02x:0x%016lx", (i%4)?" ":"\n", i<0?'-':'+', abs(i)*8, *(uintptr_t*)(rsp+i*8));
+ }
#else
- #warning TODO
+ #warning TODO
#endif
#else
- printf_log(log_minimum, "%04d|%s @%p (%s) (x64pc=%p/%s:\"%s\", rsp=%p), for accessing %p (code=%d)", GetTID(), signame, pc, name, (void*)x64pc, elfname?elfname:"???", x64name?x64name:"???", rsp, addr, info->si_code);
+ printf_log(log_minimum, "%04d|%s @%p (%s) (x64pc=%p/%s:\"%s\", rsp=%p), for accessing %p (code=%d)", GetTID(), signame, pc, name, (void*)x64pc, elfname?elfname:"???", x64name?x64name:"???", rsp, addr, info->si_code);
#endif
- if(!shown_regs)
- for (int i=0; i<16; ++i) {
- if(!(i%4)) printf_log(log_minimum, "\n");
- printf_log(log_minimum, "%s:0x%016llx ", reg_name[i], emu->regs[i].q[0]);
+ if(!shown_regs) {
+ for (int i=0; i<16; ++i) {
+ if(!(i%4)) printf_log(log_minimum, "\n");
+ printf_log(log_minimum, "%s:0x%016llx ", reg_name[i], emu->regs[i].q[0]);
+ }
+ printf_log(log_minimum, "\n");
+ for (int i=0; i<6; ++i)
+ printf_log(log_minimum, "%s:0x%04x ", seg_name[i], emu->segs[i]);
}
- if(sig==SIGILL)
- printf_log(log_minimum, " opcode=%02X %02X %02X %02X %02X %02X %02X %02X (%02X %02X %02X %02X %02X)\n", ((uint8_t*)pc)[0], ((uint8_t*)pc)[1], ((uint8_t*)pc)[2], ((uint8_t*)pc)[3], ((uint8_t*)pc)[4], ((uint8_t*)pc)[5], ((uint8_t*)pc)[6], ((uint8_t*)pc)[7], ((uint8_t*)x64pc)[0], ((uint8_t*)x64pc)[1], ((uint8_t*)x64pc)[2], ((uint8_t*)x64pc)[3], ((uint8_t*)x64pc)[4]);
- else if(sig==SIGBUS)
- printf_log(log_minimum, " x86opcode=%02X %02X %02X %02X %02X %02X %02X %02X\n", ((uint8_t*)x64pc)[0], ((uint8_t*)x64pc)[1], ((uint8_t*)x64pc)[2], ((uint8_t*)x64pc)[3], ((uint8_t*)x64pc)[4], ((uint8_t*)x64pc)[5], ((uint8_t*)x64pc)[6], ((uint8_t*)x64pc)[7]);
- else
- printf_log(log_minimum, "\n");
+ if(sig==SIGILL)
+ printf_log(log_minimum, " opcode=%02X %02X %02X %02X %02X %02X %02X %02X (%02X %02X %02X %02X %02X)\n", ((uint8_t*)pc)[0], ((uint8_t*)pc)[1], ((uint8_t*)pc)[2], ((uint8_t*)pc)[3], ((uint8_t*)pc)[4], ((uint8_t*)pc)[5], ((uint8_t*)pc)[6], ((uint8_t*)pc)[7], ((uint8_t*)x64pc)[0], ((uint8_t*)x64pc)[1], ((uint8_t*)x64pc)[2], ((uint8_t*)x64pc)[3], ((uint8_t*)x64pc)[4]);
+ else if(sig==SIGBUS)
+ printf_log(log_minimum, " x86opcode=%02X %02X %02X %02X %02X %02X %02X %02X\n", ((uint8_t*)x64pc)[0], ((uint8_t*)x64pc)[1], ((uint8_t*)x64pc)[2], ((uint8_t*)x64pc)[3], ((uint8_t*)x64pc)[4], ((uint8_t*)x64pc)[5], ((uint8_t*)x64pc)[6], ((uint8_t*)x64pc)[7]);
+ else
+ printf_log(log_minimum, "\n");
+ }
}
relockMutex(Locks);
if(my_context->signals[sig] && my_context->signals[sig]!=1) {
@@ -1203,6 +1359,8 @@ void my_sigactionhandler(int32_t sig, siginfo_t* info, void * ucntx)
void * pc = (void*)p->uc_mcontext.pc;
#elif defined(LA464)
void * pc = (void*)p->uc_mcontext.__pc;
+ #elif defined(RV64)
+ void * pc = (void*)p->uc_mcontext.__gregs[0];
#else
#error Unsupported architecture
#endif
@@ -1234,6 +1392,26 @@ void emit_signal(x64emu_t* emu, int sig, void* addr, int code)
my_sigactionhandler_oldcode(sig, 0, &info, &ctx, NULL, NULL);
}
+void emit_interruption(x64emu_t* emu, int num, void* addr)
+{
+ ucontext_t ctx = {0};
+ siginfo_t info = {0};
+ info.si_signo = SIGSEGV;
+ info.si_errno = 0xdead;
+ info.si_code = num;
+ info.si_addr = addr;
+ const char* x64name = NULL;
+ const char* elfname = NULL;
+ if(box64_log>LOG_INFO) {
+ x64name = getAddrFunctionName(R_RIP);
+ elfheader_t* elf = FindElfAddress(my_context, R_RIP);
+ if(elf)
+ elfname = ElfName(elf);
+ printf_log(LOG_NONE, "Emit Interruption 0x%x at IP=%p(%s / %s) / addr=%p\n", num, (void*)R_RIP, x64name?x64name:"???", elfname?elfname:"?", addr);
+ }
+ my_sigactionhandler_oldcode(SIGSEGV, 0, &info, &ctx, NULL, NULL);
+}
+
EXPORT sighandler_t my_signal(x64emu_t* emu, int signum, sighandler_t handler)
{
if(signum<0 || signum>=MAX_SIGNAL)
@@ -1266,6 +1444,7 @@ EXPORT sighandler_t my_sysv_signal(x64emu_t* emu, int signum, sighandler_t handl
int EXPORT my_sigaction(x64emu_t* emu, int signum, const x64_sigaction_t *act, x64_sigaction_t *oldact)
{
+ printf_log(LOG_DEBUG, "Sigaction(signum=%d, act=%p(f=%p, flags=0x%x), old=%p)\n", signum, act, act?act->_u._sa_handler:NULL, act?act->sa_flags:0, oldact);
if(signum<0 || signum>=MAX_SIGNAL) {
errno = EINVAL;
return -1;
@@ -1278,6 +1457,7 @@ int EXPORT my_sigaction(x64emu_t* emu, int signum, const x64_sigaction_t *act, x
return 0;
struct sigaction newact = {0};
struct sigaction old = {0};
+ uintptr_t old_handler = my_context->signals[signum];
if(act) {
newact.sa_mask = act->sa_mask;
newact.sa_flags = act->sa_flags&~0x04000000; // No sa_restorer...
@@ -1310,6 +1490,8 @@ int EXPORT my_sigaction(x64emu_t* emu, int signum, const x64_sigaction_t *act, x
oldact->_u._sa_sigaction = old.sa_sigaction; //TODO should wrap...
else
oldact->_u._sa_handler = old.sa_handler; //TODO should wrap...
+ if((uintptr_t)oldact->_u._sa_sigaction == (uintptr_t)my_sigactionhandler && old_handler)
+ oldact->_u._sa_sigaction = (void*)old_handler;
oldact->sa_restorer = NULL; // no handling for now...
}
return ret;
@@ -1377,7 +1559,7 @@ int EXPORT my_syscall_rt_sigaction(x64emu_t* emu, int signum, const x64_sigactio
struct sigaction newact = {0};
struct sigaction old = {0};
if(act) {
- printf_log(LOG_DEBUG, " New action flags=0x%x mask=0x%lx\n", act->sa_flags, *(uint64_t*)&act->sa_mask);
+ printf_log(LOG_DEBUG, " New action for signal #%d flags=0x%x mask=0x%lx\n", signum, act->sa_flags, *(uint64_t*)&act->sa_mask);
newact.sa_mask = act->sa_mask;
newact.sa_flags = act->sa_flags&~0x04000000; // No sa_restorer...
if(act->sa_flags&0x04) {
@@ -1554,7 +1736,7 @@ EXPORT int my_makecontext(x64emu_t* emu, void* ucp, void* fnc, int32_t argc, int
}
// push the return value
--rsp;
- *rsp = (uintptr_t)GetExit();
+ *rsp = my_context->exit_bridge;
u->uc_mcontext.gregs[X64_RSP] = (uintptr_t)rsp;
return 0;
@@ -1569,10 +1751,15 @@ EXPORT int my_swapcontext(x64emu_t* emu, void* ucp1, void* ucp2)
my_setcontext(emu, ucp2);
return 0;
}
-#ifdef DYNAREC
+#ifdef USE_SIGNAL_MUTEX
static void atfork_child_dynarec_prot(void)
{
+ #ifdef USE_CUSTOM_MUTEX
native_lock_store(&mutex_dynarec_prot, 0);
+ #else
+ pthread_mutex_t tmp = PTHREAD_ERRORCHECK_MUTEX_INITIALIZER_NP;
+ memcpy(&mutex_dynarec_prot, &tmp, sizeof(mutex_dynarec_prot));
+ #endif
}
#endif
void init_signal_helper(box64context_t* context)
@@ -1596,7 +1783,7 @@ void init_signal_helper(box64context_t* context)
sigaction(SIGABRT, &action, NULL);
pthread_once(&sigstack_key_once, sigstack_key_alloc);
-#ifdef DYNAREC
+#ifdef USE_SIGNAL_MUTEX
atfork_child_dynarec_prot();
pthread_atfork(NULL, NULL, atfork_child_dynarec_prot);
#endif
diff --git a/src/libtools/threads.c b/src/libtools/threads.c
index 32b9c7f..90c665e 100755..100644
--- a/src/libtools/threads.c
+++ b/src/libtools/threads.c
@@ -14,7 +14,6 @@
#include "box64context.h"
#include "threads.h"
#include "emu/x64emu_private.h"
-#include "tools/bridge_private.h"
#include "x64run.h"
#include "x64emu.h"
#include "box64stack.h"
@@ -128,7 +127,7 @@ int GetStackSize(x64emu_t* emu, uintptr_t attr, void** stack, size_t* stacksize)
}
mutex_unlock(&my_context->mutex_thread);
}
- // should a Warning be emited?
+ // should a Warning be emitted?
*stack = emu->init_stack;
*stacksize = emu->size_stack;
return 0;
@@ -215,7 +214,7 @@ x64emu_t* thread_get_emu()
}
void* stack = my_mmap(NULL, NULL, stacksize, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS|MAP_GROWSDOWN, -1, 0);
x64emu_t *emu = NewX64Emu(my_context, 0, (uintptr_t)stack, stacksize, 1);
- SetupX64Emu(emu);
+ SetupX64Emu(emu, NULL);
thread_set_emu(emu);
return emu;
}
@@ -490,7 +489,7 @@ EXPORT int my_pthread_create(x64emu_t *emu, void* t, void* attr, void* start_rou
emuthread_t *et = (emuthread_t*)box_calloc(1, sizeof(emuthread_t));
x64emu_t *emuthread = NewX64Emu(my_context, (uintptr_t)start_routine, (uintptr_t)stack, stacksize, own);
- SetupX64Emu(emuthread);
+ SetupX64Emu(emuthread, emu);
//SetFS(emuthread, GetFS(emu));
et->emu = emuthread;
et->fnc = (uintptr_t)start_routine;
@@ -498,7 +497,7 @@ EXPORT int my_pthread_create(x64emu_t *emu, void* t, void* attr, void* start_rou
#ifdef DYNAREC
if(box64_dynarec) {
// pre-creation of the JIT code for the entry point of the thread
- DBGetBlock(emu, (uintptr_t)start_routine, 1);
+ DBGetBlock(emu, (uintptr_t)start_routine, 1, 0); // function wrapping are 64bits only on box64
}
#endif
// create thread
@@ -512,14 +511,14 @@ void* my_prepare_thread(x64emu_t *emu, void* f, void* arg, int ssize, void** pet
void* stack = my_mmap(NULL, NULL, stacksize, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS|MAP_GROWSDOWN, -1, 0);
emuthread_t *et = (emuthread_t*)box_calloc(1, sizeof(emuthread_t));
x64emu_t *emuthread = NewX64Emu(emu->context, (uintptr_t)f, (uintptr_t)stack, stacksize, 1);
- SetupX64Emu(emuthread);
+ SetupX64Emu(emuthread, emu );
//SetFS(emuthread, GetFS(emu));
et->emu = emuthread;
et->fnc = (uintptr_t)f;
et->arg = arg;
#ifdef DYNAREC
// pre-creation of the JIT code for the entry point of the thread
- DBGetBlock(emu, (uintptr_t)f, 1);
+ DBGetBlock(emu, (uintptr_t)f, 1, 0); // function wrapping are 64bits only on box64
#endif
*pet = et;
return pthread_routine;
@@ -535,7 +534,7 @@ EXPORT void my___pthread_register_cancel(void* E, void* B)
{
// get a stack local copy of the args, as may be live in some register depending the architecture (like ARM)
if(cancel_deep<0) {
- printf_log(LOG_NONE/*LOG_INFO*/, "BOX64: Warning, inconsistant value in __pthread_register_cancel (%d)\n", cancel_deep);
+ printf_log(LOG_NONE/*LOG_INFO*/, "BOX64: Warning, inconsistent value in __pthread_register_cancel (%d)\n", cancel_deep);
cancel_deep = 0;
}
if(cancel_deep!=CANCEL_MAX-1)
@@ -619,7 +618,7 @@ GO(29)
static uintptr_t my_key_destructor_fct_##A = 0; \
static void my_key_destructor_##A(void* a) \
{ \
- RunFunction(my_context, my_key_destructor_fct_##A, 1, a);\
+ RunFunction(my_key_destructor_fct_##A, 1, a);\
}
SUPER()
#undef GO
@@ -641,7 +640,7 @@ static void* findkey_destructorFct(void* fct)
static uintptr_t my_cleanup_routine_fct_##A = 0; \
static void my_cleanup_routine_##A(void* a) \
{ \
- RunFunction(my_context, my_cleanup_routine_fct_##A, 1, a);\
+ RunFunction(my_cleanup_routine_fct_##A, 1, a);\
}
SUPER()
#undef GO
@@ -807,11 +806,6 @@ EXPORT int my_pthread_kill_old(x64emu_t* emu, void* thread, int sig)
//}
#ifndef NOALIGN
-EXPORT int my_pthread_mutex_destroy(pthread_mutex_t *m)
-{
- int ret = pthread_mutex_destroy(m);
- return ret;
-}
typedef union my_mutexattr_s {
int x86;
pthread_mutexattr_t nat;
@@ -851,6 +845,14 @@ EXPORT int my_pthread_mutexattr_gettype(x64emu_t* emu, my_mutexattr_t *attr, voi
attr->x86 = mattr.x86;
return ret;
}
+EXPORT int my_pthread_mutexattr_getrobust(x64emu_t* emu, my_mutexattr_t *attr, void* p)
+{
+ my_mutexattr_t mattr = {0};
+ mattr.x86 = attr->x86;
+ int ret = pthread_mutexattr_getrobust(&mattr.nat, p);
+ attr->x86 = mattr.x86;
+ return ret;
+}
EXPORT int my_pthread_mutexattr_init(x64emu_t* emu, my_mutexattr_t *attr)
{
my_mutexattr_t mattr = {0};
@@ -894,9 +896,14 @@ EXPORT int my_pthread_mutexattr_settype(x64emu_t* emu, my_mutexattr_t *attr, int
return ret;
}
EXPORT int my___pthread_mutexattr_settype(x64emu_t* emu, my_mutexattr_t *attr, int t) __attribute__((alias("my_pthread_mutexattr_settype")));
-
-// mutex
-int my___pthread_mutex_destroy(pthread_mutex_t *m) __attribute__((alias("my_pthread_mutex_destroy")));
+EXPORT int my_pthread_mutexattr_setrobust(x64emu_t* emu, my_mutexattr_t *attr, int t)
+{
+ my_mutexattr_t mattr = {0};
+ mattr.x86 = attr->x86;
+ int ret = pthread_mutexattr_setrobust(&mattr.nat, t);
+ attr->x86 = mattr.x86;
+ return ret;
+}
#ifdef __SIZEOF_PTHREAD_MUTEX_T
#if __SIZEOF_PTHREAD_MUTEX_T == 48
@@ -914,7 +921,7 @@ EXPORT int my_pthread_mutex_init(pthread_mutex_t *m, my_mutexattr_t *att)
#ifdef MUTEX_OVERSIZED_8
uint64_t save = *(uint64_t*)(((uintptr_t)m) + 40);
int ret = pthread_mutex_init(m, att?(&mattr.nat):NULL);
- *(uint64_t*)(((uintptr_t)m) + 40) = save; // put back overwriten value. Nasty but should be fast and quite safe
+ *(uint64_t*)(((uintptr_t)m) + 40) = save; // put back overwritten value. Nasty but should be fast and quite safe
#elif defined(MUTEX_SIZE_X64)
int ret = pthread_mutex_init(m, att?(&mattr.nat):NULL);
#else
@@ -926,33 +933,6 @@ EXPORT int my_pthread_mutex_init(pthread_mutex_t *m, my_mutexattr_t *att)
}
EXPORT int my___pthread_mutex_init(pthread_mutex_t *m, my_mutexattr_t *att) __attribute__((alias("my_pthread_mutex_init")));
-EXPORT int my_pthread_mutex_lock(pthread_mutex_t *m)
-{
- int ret = pthread_mutex_lock(m);
- return ret;
-}
-EXPORT int my___pthread_mutex_lock(pthread_mutex_t *m) __attribute__((alias("my_pthread_mutex_lock")));
-
-EXPORT int my_pthread_mutex_timedlock(pthread_mutex_t *m, const struct timespec * t)
-{
- int ret = pthread_mutex_timedlock(m, t);
- return ret;
-}
-EXPORT int my___pthread_mutex_trylock(pthread_mutex_t *m, const struct timespec * t) __attribute__((alias("my_pthread_mutex_timedlock")));
-
-EXPORT int my_pthread_mutex_trylock(pthread_mutex_t *m)
-{
- int ret = pthread_mutex_trylock(m);
- return ret;
-}
-EXPORT int my___pthread_mutex_unlock(pthread_mutex_t *m) __attribute__((alias("my_pthread_mutex_trylock")));
-
-EXPORT int my_pthread_mutex_unlock(pthread_mutex_t *m)
-{
- int ret = pthread_mutex_unlock(m);
- return ret;
-}
-
typedef union my_condattr_s {
int x86;
pthread_condattr_t nat;
@@ -1086,28 +1066,6 @@ EXPORT int my_pthread_barrier_init(x64emu_t* emu, pthread_barrier_t* bar, my_bar
#endif
-static void emujmpbuf_destroy(void* p)
-{
- emu_jmpbuf_t *ej = (emu_jmpbuf_t*)p;
- if(ej) {
- box_free(ej->jmpbuf);
- box_free(ej);
- }
-}
-
-static pthread_key_t jmpbuf_key;
-
-emu_jmpbuf_t* GetJmpBuf()
-{
- emu_jmpbuf_t *ejb = (emu_jmpbuf_t*)pthread_getspecific(jmpbuf_key);
- if(!ejb) {
- ejb = (emu_jmpbuf_t*)box_calloc(1, sizeof(emu_jmpbuf_t));
- ejb->jmpbuf = box_calloc(1, sizeof(struct __jmp_buf_tag));
- pthread_setspecific(jmpbuf_key, ejb);
- }
- return ejb;
-}
-
void init_pthread_helper()
{
real_pthread_cleanup_push_defer = (vFppp_t)dlsym(NULL, "_pthread_cleanup_push_defer");
@@ -1128,8 +1086,6 @@ void init_pthread_helper()
}
InitCancelThread();
- pthread_key_create(&jmpbuf_key, emujmpbuf_destroy);
- pthread_setspecific(jmpbuf_key, NULL);
pthread_key_create(&thread_key, emuthread_destroy);
pthread_setspecific(thread_key, NULL);
}
@@ -1138,11 +1094,6 @@ void fini_pthread_helper(box64context_t* context)
{
FreeCancelThread(context);
CleanStackSize(context);
- emu_jmpbuf_t *ejb = (emu_jmpbuf_t*)pthread_getspecific(jmpbuf_key);
- if(ejb) {
- pthread_setspecific(jmpbuf_key, NULL);
- emujmpbuf_destroy(ejb);
- }
emuthread_t *et = (emuthread_t*)pthread_getspecific(thread_key);
if(et) {
pthread_setspecific(thread_key, NULL);
@@ -1150,7 +1101,6 @@ void fini_pthread_helper(box64context_t* context)
}
}
-#ifndef DYNAREC
int checkUnlockMutex(void* m)
{
pthread_mutex_t* mutex = (pthread_mutex_t*)m;
@@ -1160,4 +1110,3 @@ int checkUnlockMutex(void* m)
}
return 0;
}
-#endif \ No newline at end of file
diff --git a/src/main.c b/src/main.c
index 8f95636..14e04d1 100755..100644
--- a/src/main.c
+++ b/src/main.c
@@ -35,6 +35,7 @@
#include "x64run.h"
#include "symbols.h"
#include "rcfile.h"
+#include "emu/x64run_private.h"
box64context_t *my_context = NULL;
int box64_quit = 0;
@@ -58,10 +59,13 @@ int box64_dynarec_fastnan = 1;
int box64_dynarec_fastround = 1;
int box64_dynarec_safeflags = 1;
int box64_dynarec_callret = 0;
-int box64_dynarec_hotpage = 4;
+int box64_dynarec_hotpage = 0;
int box64_dynarec_fastpage = 0;
int box64_dynarec_bleeding_edge = 1;
+int box64_dynarec_jvm = 1;
int box64_dynarec_wait = 1;
+int box64_dynarec_test = 0;
+int box64_dynarec_missing = 0;
uintptr_t box64_nodynarec_start = 0;
uintptr_t box64_nodynarec_end = 0;
#ifdef ARM64
@@ -70,6 +74,11 @@ int arm64_aes = 0;
int arm64_pmull = 0;
int arm64_crc32 = 0;
int arm64_atomics = 0;
+#elif defined(RV64)
+int rv64_zba = 0;
+int rv64_zbb = 0;
+int rv64_zbc = 0;
+int rv64_zbs = 0;
#endif
#else //DYNAREC
int box64_dynarec = 0;
@@ -113,7 +122,7 @@ int box64_isglibc234 = 0;
char* box64_libGL = NULL;
uintptr_t fmod_smc_start = 0;
uintptr_t fmod_smc_end = 0;
-uint32_t default_gs = 0xa<<3;
+uint32_t default_gs = 0x53;
int jit_gdb = 0;
int box64_tcmalloc_minimal = 0;
@@ -353,6 +362,17 @@ HWCAP2_ECV
#elif defined(LA464)
printf_log(LOG_INFO, "Dynarec for LoongArch");
printf_log(LOG_INFO, " PageSize:%zd ", box64_pagesize);
+#elif defined(RV64)
+ void RV64_Detect_Function();
+ if(!getenv("BOX64_DYNAREC_RV64NOEXT"))
+ RV64_Detect_Function();
+ printf_log(LOG_INFO, "Dynarec for RISC-V ");
+ printf_log(LOG_INFO, "With extension: I M A F D C");
+ if(rv64_zba) printf_log(LOG_INFO, " Zba");
+ if(rv64_zbb) printf_log(LOG_INFO, " Zbb");
+ if(rv64_zbc) printf_log(LOG_INFO, " Zbc");
+ if(rv64_zbs) printf_log(LOG_INFO, " Zbs");
+ printf_log(LOG_INFO, " PageSize:%zd ", box64_pagesize);
#else
#error Unsupported architecture
#endif
@@ -374,7 +394,7 @@ void LoadLogEnv()
}
// grab BOX64_TRACE_FILE envvar, and change %pid to actual pid is present in the name
openFTrace(NULL);
- box64_log = ftrace_name?LOG_INFO:(isatty(fileno(ftrace))?LOG_INFO:LOG_NONE); //default LOG value different if stdout is redirected or not
+ box64_log = ftrace_name?LOG_INFO:(isatty(fileno(stdout))?LOG_INFO:LOG_NONE); //default LOG value different if stdout is redirected or not
p = getenv("BOX64_LOG");
if(p) {
if(strlen(p)==1) {
@@ -557,6 +577,15 @@ void LoadLogEnv()
if(!box64_dynarec_bleeding_edge)
printf_log(LOG_INFO, "Dynarec will not detect MonoBleedingEdge\n");
}
+ p = getenv("BOX64_DYNAREC_JVM");
+ if(p) {
+ if(strlen(p)==1) {
+ if(p[0]>='0' && p[0]<='1')
+ box64_dynarec_jvm = p[0]-'0';
+ }
+ if(!box64_dynarec_jvm)
+ printf_log(LOG_INFO, "Dynarec will not detect libjvm\n");
+ }
p = getenv("BOX64_DYNAREC_WAIT");
if(p) {
if(strlen(p)==1) {
@@ -587,6 +616,15 @@ void LoadLogEnv()
if(box64_dynarec_fastpage)
printf_log(LOG_INFO, "Dynarec will use Fast HotPage\n");
}
+ p = getenv("BOX64_DYNAREC_MISSING");
+ if(p) {
+ if(strlen(p)==1) {
+ if(p[0]>='0' && p[0]<='1')
+ box64_dynarec_missing = p[0]-'0';
+ }
+ if(box64_dynarec_missing)
+ printf_log(LOG_INFO, "Dynarec will print missing opcodes\n");
+ }
p = getenv("BOX64_NODYNAREC");
if(p) {
if (strchr(p,'-')) {
@@ -597,6 +635,19 @@ void LoadLogEnv()
printf_log(LOG_INFO, "No dynablock creation that start in the range %p - %p\n", (void*)box64_nodynarec_start, (void*)box64_nodynarec_end);
}
}
+ p = getenv("BOX64_DYNAREC_TEST");
+ if(p) {
+ if(strlen(p)==1) {
+ if(p[0]>='0' && p[0]<='1')
+ box64_dynarec_test = p[0]-'0';
+ }
+ if(box64_dynarec_test) {
+ box64_dynarec_fastnan = 0;
+ box64_dynarec_fastround = 0;
+ box64_dynarec_callret = 0;
+ printf_log(LOG_INFO, "Dynarec will compare it's execution with the interpreter (super slow, only for testing)\n");
+ }
+ }
#endif
#ifdef HAVE_TRACE
@@ -722,7 +773,7 @@ void LoadLogEnv()
if(box64_malloc_hack==1) {
printf_log(LOG_INFO, "Malloc hook will not be redirected\n");
} else
- printf_log(LOG_INFO, "Malloc hook will check for mmap/free occurences\n");
+ printf_log(LOG_INFO, "Malloc hook will check for mmap/free occurrences\n");
}
}
p = getenv("BOX64_NOPULSE");
@@ -866,7 +917,7 @@ int GatherEnv(char*** dest, char** env, char* prog)
(*dest)[idx++] = box_strdup("BOX64_PATH=.:bin");
}
if(!ld_path) {
- (*dest)[idx++] = box_strdup("BOX64_LD_LIBRARY_PATH=.:lib:lib64");
+ (*dest)[idx++] = box_strdup("BOX64_LD_LIBRARY_PATH=.:lib:lib64:x86_64:bin64:libs64");
}
// add "_=prog" at the end...
if(prog) {
@@ -920,9 +971,9 @@ void PrintHelp() {
printf(" BOX64_NOSIGILL=1 to disable handling of SigILL\n");
printf(" BOX64_SHOWSEGV=1 to show Segfault signal even if a signal handler is present\n");
printf(" BOX64_X11THREADS=1 to call XInitThreads when loading X11 (for old Loki games with Loki_Compat lib)");
- printf(" BOX64_LIBGL=libXXXX set the name (and optionnaly full path) for libGL.so.1\n");
+ printf(" BOX64_LIBGL=libXXXX set the name (and optionnally full path) for libGL.so.1\n");
printf(" BOX64_LD_PRELOAD=XXXX[:YYYYY] force loading XXXX (and YYYY...) libraries with the binary\n");
- printf(" BOX64_ALLOWMISSINGLIBS with 1 to allow to continue even if a lib is missing (unadvised, will probably crash later)\n");
+ printf(" BOX64_ALLOWMISSINGLIBS with 1 to allow one to continue even if a lib is missing (unadvised, will probably crash later)\n");
printf(" BOX64_PREFER_EMULATED=1 to prefer emulated libs first (execpt for glibc, alsa, pulse, GL, vulkan and X11\n");
printf(" BOX64_PREFER_WRAPPED if box64 will use wrapped libs even if the lib is specified with absolute path\n");
printf(" BOX64_CRASHHANDLER=0 to not use a dummy crashhandler lib\n");
@@ -976,6 +1027,8 @@ void LoadEnvVars(box64context_t *context)
AddPath("/lib/x86_64-linux-gnu", &context->box64_ld_lib, 1);
if(FileExist("/usr/lib/x86_64-linux-gnu", 0))
AddPath("/usr/lib/x86_64-linux-gnu", &context->box64_ld_lib, 1);
+ if(FileExist("/usr/x86_64-linux-gnu/lib", 0))
+ AddPath("/usr/x86_64-linux-gnu/lib", &context->box64_ld_lib, 1);
if(getenv("LD_LIBRARY_PATH"))
PrependList(&context->box64_ld_lib, getenv("LD_LIBRARY_PATH"), 1); // in case some of the path are for x86 world
if(getenv("BOX64_EMULATED_LIBS")) {
@@ -994,6 +1047,7 @@ void LoadEnvVars(box64context_t *context)
AddPath("libcrypto.so.1", &context->box64_emulated_libs, 0);
AddPath("libcrypto.so.1.0.0", &context->box64_emulated_libs, 0);
AddPath("libunwind.so.8", &context->box64_emulated_libs, 0);
+ AddPath("libpng12.so.0", &context->box64_emulated_libs, 0);
if(getenv("BOX64_SSE_FLUSHTO0")) {
if (strcmp(getenv("BOX64_SSE_FLUSHTO0"), "1")==0) {
@@ -1079,10 +1133,10 @@ void setupTraceInit()
if(s_trace_start || s_trace_end)
SetTraceEmu(s_trace_start, s_trace_end);
} else {
- if (GetGlobalSymbolStartEnd(my_context->maplib, p, &s_trace_start, &s_trace_end, NULL, -1, NULL)) {
+ if (GetGlobalSymbolStartEnd(my_context->maplib, p, &s_trace_start, &s_trace_end, NULL, -1, NULL, NULL, NULL)) {
SetTraceEmu(s_trace_start, s_trace_end);
printf_log(LOG_INFO, "TRACE on %s only (%p-%p)\n", p, (void*)s_trace_start, (void*)s_trace_end);
- } else if(GetLocalSymbolStartEnd(my_context->maplib, p, &s_trace_start, &s_trace_end, NULL, -1, NULL)) {
+ } else if(GetLocalSymbolStartEnd(my_context->maplib, p, &s_trace_start, &s_trace_end, NULL, -1, NULL, NULL, NULL)) {
SetTraceEmu(s_trace_start, s_trace_end);
printf_log(LOG_INFO, "TRACE on %s only (%p-%p)\n", p, (void*)s_trace_start, (void*)s_trace_end);
} else {
@@ -1123,10 +1177,10 @@ void setupTrace()
}
}
} else {
- if (GetGlobalSymbolStartEnd(my_context->maplib, p, &s_trace_start, &s_trace_end, NULL, -1, NULL)) {
+ if (GetGlobalSymbolStartEnd(my_context->maplib, p, &s_trace_start, &s_trace_end, NULL, -1, NULL, NULL, NULL)) {
SetTraceEmu(s_trace_start, s_trace_end);
printf_log(LOG_INFO, "TRACE on %s only (%p-%p)\n", p, (void*)s_trace_start, (void*)s_trace_end);
- } else if(GetLocalSymbolStartEnd(my_context->maplib, p, &s_trace_start, &s_trace_end, NULL, -1, NULL)) {
+ } else if(GetLocalSymbolStartEnd(my_context->maplib, p, &s_trace_start, &s_trace_end, NULL, -1, NULL, NULL, NULL)) {
SetTraceEmu(s_trace_start, s_trace_end);
printf_log(LOG_INFO, "TRACE on %s only (%p-%p)\n", p, (void*)s_trace_start, (void*)s_trace_end);
} else {
@@ -1140,12 +1194,14 @@ void setupTrace()
}
#endif
}
+void endMallocHook();
void endBox64()
{
if(!my_context || box64_quit)
return;
-
+
+ endMallocHook();
x64emu_t* emu = thread_get_emu();
// atexit first
printf_log(LOG_DEBUG, "Calling atexit registered functions (exiting box64)\n");
@@ -1154,10 +1210,6 @@ void endBox64()
box64_quit = 1;
printf_log(LOG_DEBUG, "Calling fini for all loaded elfs and unload native libs\n");
RunElfFini(my_context->elfs[0], emu);
- #ifdef DYNAREC
- // disable dynarec now
- box64_dynarec = 0;
- #endif
FreeLibrarian(&my_context->local_maplib, emu); // unload all libs
FreeLibrarian(&my_context->maplib, emu); // unload all libs
#if 0
@@ -1201,6 +1253,10 @@ void endBox64()
#endif
// all done, free context
FreeBox64Context(&my_context);
+ #ifdef DYNAREC
+ // disable dynarec now
+ box64_dynarec = 0;
+ #endif
if(box64_libGL) {
box_free(box64_libGL);
box64_libGL = NULL;
@@ -1326,8 +1382,13 @@ int main(int argc, const char **argv, char **env) {
wine_prereserve(prereserve);
// special case for winedbg, doesn't work anyway
if(argv[nextarg+1] && strstr(argv[nextarg+1], "winedbg")==argv[nextarg+1]) {
- printf_log(LOG_NONE, "winedbg detected, not launching it!\n");
- exit(0); // exiting, it doesn't work anyway
+ if(getenv("BOX64_WINEDBG")) {
+ box64_nobanner = 1;
+ box64_log = 0;
+ } else {
+ printf_log(LOG_NONE, "winedbg detected, not launching it!\n");
+ exit(0); // exiting, it doesn't work anyway
+ }
}
box64_wine = 1;
} else
@@ -1362,7 +1423,7 @@ int main(int argc, const char **argv, char **env) {
LoadEnvVars(my_context);
// Append ld_list if it exist
if(ld_libs_args!=-1)
- AppendList(&my_context->box64_ld_lib, argv[ld_libs_args], 1);
+ PrependList(&my_context->box64_ld_lib, argv[ld_libs_args], 1);
my_context->box64path = ResolveFile(argv[0], &my_context->box64_path);
// prepare all other env. var
@@ -1652,7 +1713,7 @@ int main(int argc, const char **argv, char **env) {
x64emu_t *emu = NewX64Emu(my_context, my_context->ep, (uintptr_t)my_context->stack, my_context->stacksz, 0);
// stack setup is much more complicated then just that!
SetupInitialStack(emu); // starting here, the argv[] don't need free anymore
- SetupX64Emu(emu);
+ SetupX64Emu(emu, NULL);
SetRSI(emu, my_context->argc);
SetRDX(emu, (uint64_t)my_context->argv);
SetRCX(emu, (uint64_t)my_context->envv);
@@ -1684,12 +1745,19 @@ int main(int argc, const char **argv, char **env) {
AddMainElfToLinkmap(elf_header);
// pre-load lib if needed
if(ld_preload.size) {
- my_context->preload = new_neededlib(ld_preload.size);
- for(int i=0; i<ld_preload.size; ++i)
- my_context->preload->names[i] = ld_preload.paths[i];
- if(AddNeededLib(my_context->maplib, 0, 0, my_context->preload, my_context, emu)) {
- printf_log(LOG_INFO, "Warning, cannot pre-load of the libs\n");
- }
+ my_context->preload = new_neededlib(0);
+ for(int i=0; i<ld_preload.size; ++i) {
+ needed_libs_t* tmp = new_neededlib(1);
+ tmp->names[0] = ld_preload.paths[i];
+ if(AddNeededLib(my_context->maplib, 0, 0, tmp, elf_header, my_context, emu)) {
+ printf_log(LOG_INFO, "Warning, cannot pre-load of %s\n", tmp->names[0]);
+ RemoveNeededLib(my_context->maplib, 0, tmp, my_context, emu);
+ } else {
+ for(int j=0; j<tmp->size; ++j)
+ add1lib_neededlib(my_context->preload, tmp->libs[j], tmp->names[j]);
+ free_neededlib(tmp);
+ }
+ }
}
FreeCollection(&ld_preload);
// Call librarian to load all dependant elf
@@ -1707,9 +1775,9 @@ int main(int argc, const char **argv, char **env) {
}
// and handle PLT
RelocateElfPlt(my_context->maplib, NULL, 0, elf_header);
- // defered init
+ // deferred init
setupTraceInit();
- RunDeferedElfInit(emu);
+ RunDeferredElfInit(emu);
// update TLS of main elf
RefreshElfTLS(elf_header);
// do some special case check, _IO_2_1_stderr_ and friends, that are setup by libc, but it's already done here, so need to do a copy
@@ -1727,7 +1795,7 @@ int main(int argc, const char **argv, char **env) {
// Stack is ready, with stacked: NULL env NULL argv argc
SetRIP(emu, my_context->ep);
ResetFlags(emu);
- PushExit(emu); // push to pop it just after
+ Push64(emu, my_context->exit_bridge); // push to pop it just after
SetRDX(emu, Pop64(emu)); // RDX is exit function
Run(emu, 0);
// Get EAX
diff --git a/src/mallochook.c b/src/mallochook.c
index e502a1a..885e38c 100644
--- a/src/mallochook.c
+++ b/src/mallochook.c
@@ -13,6 +13,7 @@
#include "librarian.h"
#include "elfs/elfloader_private.h"
#include "custommem.h"
+#include "symbols.h"
/*
This file here is for handling overriding of malloc functions
@@ -26,8 +27,8 @@
The 2 different strategies to handle this can be defined as "Embrace" and "Exterminate" (as it cannot simply be ignored,
or you end up with mixing free/realloc from one lib and malloc/free from libc)
- In the "Embrace" strategy, the overriden malloc function are taken into account as soon as possible, and are used for all loaded lib, including native
- In the "Exterminate" strategy, the overriden malloc function are erased, and replaced with libc malloc as soon as they are defined.
+ In the "Embrace" strategy, the overridden malloc function are taken into account as soon as possible, and are used for all loaded lib, including native
+ In the "Exterminate" strategy, the overridden malloc function are erased, and replaced with libc malloc as soon as they are defined.
The advantage of "Embrace" is that the system will run the function it supposed to be using, and potential side-effect and staticaly linked functions
will run as intended.
@@ -42,7 +43,6 @@
*/
#include "bridge.h"
-#include "tools/bridge_private.h"
#include "wrapper.h"
#define SUPER() \
@@ -146,6 +146,9 @@ uint32_t getProtection(uintptr_t addr);
// mmap history
static int malloc_hack_2 = 0;
+#define ALLOC 0
+#define FREE 1
+
char* box_strdup(const char* s) {
char* ret = box_calloc(1, strlen(s)+1);
memcpy(ret, s, strlen(s));
@@ -180,18 +183,29 @@ static int ispot(size_t l) {
return pot(l)==l;
}
+#define GO(A, B) static uintptr_t real_##A = 0;
+#define GO2(A, B) static uintptr_t real_##A = 0;
+SUPER()
+#undef GO2
+#undef GO
+
// redefining all libc memory allocation routines
EXPORT void* malloc(size_t l)
{
+ if(malloc_hack_2 && ALLOC && real_malloc) {
+ return (void*)RunFunctionFmt(real_malloc, "L", l);
+ }
return box_calloc(1, l);
}
EXPORT void free(void* p)
{
- if(malloc_hack_2 && p) {
+ if(malloc_hack_2 && FREE && p) {
if(getMmapped((uintptr_t)p)) {
printf_log(LOG_DEBUG, "%04d|Malloc_Hack_2: not freeing %p\n", GetTID(), p);
- // Mmaped, do not free...
+ // Mmaped, free with original function
+ if(real_free)
+ RunFunctionFmt(real_free, "p", p);
return;
}
}
@@ -200,19 +214,30 @@ EXPORT void free(void* p)
EXPORT void* calloc(size_t n, size_t s)
{
+ if(malloc_hack_2 && ALLOC && real_calloc) {
+ return (void*)RunFunctionFmt(real_calloc, "LL", n,s);
+ }
return box_calloc(n, s);
}
EXPORT void* realloc(void* p, size_t s)
{
if(malloc_hack_2)
- if(getMmapped((uintptr_t)p)) {
- // found! Will realloc using regular malloc then copy from old address as much as possible, but need to check size first
- void* ret = box_malloc(s);
- printf_log(LOG_DEBUG, "Malloc_Hack_2: hacking realloc(%p, %zu)", p, s);
- while(s && !(getProtection((uintptr_t)p+s)&PROT_READ)) {if(s>box64_pagesize) s-=box64_pagesize; else s=0;}
- memcpy(ret, p, s);
- printf_log(LOG_DEBUG, " -> %p (copied %zu from old)\n", ret, s);
+ if(getMmapped((uintptr_t)p) || (!p && ALLOC && real_realloc)) {
+ void* ret = p;
+ if(real_realloc) {
+ ret = (void*)RunFunctionFmt(real_realloc, "pL", p, s);
+ } else {
+ // found! Will realloc using regular malloc then copy from old address as much as possible, but need to check size first
+ ret = box_malloc(s);
+ printf_log(LOG_DEBUG, "Malloc_Hack_2: hacking realloc(%p, %zu)", p, s);
+ while(s && !(getProtection((uintptr_t)p+s)&PROT_READ)) {if(s>box64_pagesize) s-=box64_pagesize; else s=0;}
+ memcpy(ret, p, s);
+ printf_log(LOG_DEBUG, " -> %p (copied %zu from old)\n", ret, s);
+ // Mmaped, free with original function
+ if(real_free)
+ RunFunctionFmt(real_free, "p", p);
+ }
return ret;
}
return box_realloc(p, s);
@@ -220,16 +245,25 @@ EXPORT void* realloc(void* p, size_t s)
EXPORT void* aligned_alloc(size_t align, size_t size)
{
+ if(malloc_hack_2 && ALLOC && real_aligned_alloc) {
+ return (void*)RunFunctionFmt(real_aligned_alloc, "LL", align, size);
+ }
return box_memalign(align, size);
}
EXPORT void* memalign(size_t align, size_t size)
{
+ if(malloc_hack_2 && ALLOC && real_aligned_alloc) {
+ return (void*)RunFunctionFmt(real_aligned_alloc, "LL", align, size);
+ }
return box_memalign(align, size);
}
EXPORT int posix_memalign(void** p, size_t align, size_t size)
{
+ if(malloc_hack_2 && ALLOC && real_posix_memalign) {
+ return RunFunctionFmt(real_posix_memalign, "pLL", p, align, size);
+ }
if(align%sizeof(void*) || pot(align)!=align)
return EINVAL;
void* ret = box_memalign(align, size);
@@ -241,20 +275,28 @@ EXPORT int posix_memalign(void** p, size_t align, size_t size)
EXPORT void* valloc(size_t size)
{
+ if(malloc_hack_2 && ALLOC && real_valloc) {
+ return (void*)RunFunctionFmt(real_valloc, "L", size);
+ }
return box_memalign(box64_pagesize, size);
}
EXPORT void* pvalloc(size_t size)
{
+ if(malloc_hack_2 && ALLOC && real_pvalloc) {
+ return (void*)RunFunctionFmt(real_pvalloc, "L", size);
+ }
return box_memalign(box64_pagesize, (size+box64_pagesize-1)&~(box64_pagesize-1));
}
EXPORT void cfree(void* p)
{
- if(malloc_hack_2 && p) {
+ if(malloc_hack_2 && FREE && p) {
if(getMmapped((uintptr_t)p)) {
printf_log(LOG_DEBUG, "%04d|Malloc_Hack_2: not freeing %p\n", GetTID(), p);
- // Mmaped, do not free...
+ // Mmaped, free with original function
+ if(real_free)
+ RunFunctionFmt(real_free, "p", p);
return;
}
}
@@ -263,26 +305,42 @@ EXPORT void cfree(void* p)
EXPORT size_t malloc_usable_size(void* p)
{
+ if(malloc_hack_2 && real_malloc_usable_size) {
+ if(getMmapped((uintptr_t)p))
+ return RunFunctionFmt(real_malloc_usable_size, "p", p);
+ }
return box_malloc_usable_size(p);
}
EXPORT void* my__Znwm(size_t sz) //operator new(size_t)
{
+ if(malloc_hack_2 && real__Znwm) {
+ return (void*)RunFunctionFmt(real__Znwm, "L", sz);
+ }
return box_malloc(sz);
}
EXPORT void* my__ZnwmRKSt9nothrow_t(size_t sz, void* p) //operator new(size_t, std::nothrow_t const&)
{
+ if(malloc_hack_2 && real__ZnwmRKSt9nothrow_t) {
+ return (void*)RunFunctionFmt(real__ZnwmRKSt9nothrow_t, "Lp", sz, p);
+ }
return box_malloc(sz);
}
EXPORT void* my__Znam(size_t sz) //operator new[](size_t)
{
+ if(malloc_hack_2 && real__Znam) {
+ return (void*)RunFunctionFmt(real__Znam, "L", sz);
+ }
return box_malloc(sz);
}
EXPORT void* my__ZnamRKSt9nothrow_t(size_t sz, void* p) //operator new[](size_t, std::nothrow_t const&)
{
+ if(malloc_hack_2 && real__ZnamRKSt9nothrow_t) {
+ return (void*)RunFunctionFmt(real__ZnamRKSt9nothrow_t, "Lp", sz, p);
+ }
return box_malloc(sz);
}
@@ -292,7 +350,9 @@ EXPORT void my__ZdaPv(void* p) //operator delete[](void*)
if(malloc_hack_2 && p) {
if(getMmapped((uintptr_t)p)) {
printf_log(LOG_DEBUG, "%04d|Malloc_Hack_2: not freeing %p\n", GetTID(), p);
- // Mmaped, do not free...
+ // Mmaped, free with original function
+ if(real__ZdaPv)
+ RunFunctionFmt(real__ZdaPv, "p", p);
return;
}
}
@@ -304,7 +364,9 @@ EXPORT void my__ZdaPvm(void* p, size_t sz) //operator delete[](void*, size_t)
if(malloc_hack_2 && p) {
if(getMmapped((uintptr_t)p)) {
printf_log(LOG_DEBUG, "%04d|Malloc_Hack_2: not freeing %p\n", GetTID(), p);
- // Mmaped, do not free...
+ // Mmaped, free with original function
+ if(real__ZdaPvm)
+ RunFunctionFmt(real__ZdaPvm, "pL", p, sz);
return;
}
}
@@ -316,7 +378,9 @@ EXPORT void my__ZdaPvmSt11align_val_t(void* p, size_t sz, size_t align) //oper
if(malloc_hack_2 && p) {
if(getMmapped((uintptr_t)p)) {
printf_log(LOG_DEBUG, "%04d|Malloc_Hack_2: not freeing %p\n", GetTID(), p);
- // Mmaped, do not free...
+ // Mmaped, free with original function
+ if(real__ZdaPvmSt11align_val_t)
+ RunFunctionFmt(real__ZdaPvmSt11align_val_t, "pLL", p, sz, align);
return;
}
}
@@ -328,7 +392,9 @@ EXPORT void my__ZdlPv(void* p) //operator delete(void*)
if(malloc_hack_2 && p) {
if(getMmapped((uintptr_t)p)) {
printf_log(LOG_DEBUG, "%04d|Malloc_Hack_2: not freeing %p\n", GetTID(), p);
- // Mmaped, do not free...
+ // Mmaped, free with original function
+ if(real__ZdlPv)
+ RunFunctionFmt(real__ZdlPv, "p", p);
return;
}
}
@@ -340,7 +406,9 @@ EXPORT void my__ZdlPvm(void* p, size_t sz) //operator delete(void*, size_t)
if(malloc_hack_2 && p) {
if(getMmapped((uintptr_t)p)) {
printf_log(LOG_DEBUG, "%04d|Malloc_Hack_2: not freeing %p\n", GetTID(), p);
- // Mmaped, do not free...
+ // Mmaped, free with original function
+ if(real__ZdlPvm)
+ RunFunctionFmt(real__ZdlPvm, "pL", p, sz);
return;
}
}
@@ -349,21 +417,33 @@ EXPORT void my__ZdlPvm(void* p, size_t sz) //operator delete(void*, size_t)
EXPORT void* my__ZnwmSt11align_val_t(size_t sz, size_t align) //// operator new(unsigned long, std::align_val_t)
{
+ if(malloc_hack_2 && real__ZnwmSt11align_val_t) {
+ return (void*)RunFunctionFmt(real__ZnwmSt11align_val_t, "LL", sz, align);
+ }
return box_memalign(align, sz);
}
EXPORT void* my__ZnwmSt11align_val_tRKSt9nothrow_t(size_t sz, size_t align, void* p) //// operator new(unsigned long, std::align_val_t, std::nothrow_t const&)
{
+ if(malloc_hack_2 && real__ZnwmSt11align_val_tRKSt9nothrow_t) {
+ return (void*)RunFunctionFmt(real__ZnwmSt11align_val_tRKSt9nothrow_t, "LLp", sz, align, p);
+ }
return box_memalign(align, sz);
}
EXPORT void* my__ZnamSt11align_val_t(size_t sz, size_t align) //// operator new[](unsigned long, std::align_val_t)
{
+ if(malloc_hack_2 && real__ZnamSt11align_val_t) {
+ return (void*)RunFunctionFmt(real__ZnamSt11align_val_t, "LL", sz, align);
+ }
return box_memalign(align, sz);
}
EXPORT void* my__ZnamSt11align_val_tRKSt9nothrow_t(size_t sz, size_t align, void* p) //// operator new[](unsigned long, std::align_val_t, std::nothrow_t const&)
{
+ if(malloc_hack_2 && real__ZnamSt11align_val_tRKSt9nothrow_t) {
+ return (void*)RunFunctionFmt(real__ZnamSt11align_val_tRKSt9nothrow_t, "LLp", sz, align, p);
+ }
return box_memalign(align, sz);
}
@@ -372,7 +452,9 @@ EXPORT void my__ZdlPvRKSt9nothrow_t(void* p, void* n) //operator delete(void*,
if(malloc_hack_2 && p) {
if(getMmapped((uintptr_t)p)) {
printf_log(LOG_DEBUG, "%04d|Malloc_Hack_2: not freeing %p\n", GetTID(), p);
- // Mmaped, do not free...
+ // Mmaped, free with original function
+ if(real__ZdlPvRKSt9nothrow_t)
+ RunFunctionFmt(real__ZdlPvRKSt9nothrow_t, "pp", p, n);
return;
}
}
@@ -384,7 +466,9 @@ EXPORT void my__ZdaPvSt11align_val_tRKSt9nothrow_t(void* p, size_t align, void*
if(malloc_hack_2 && p) {
if(getMmapped((uintptr_t)p)) {
printf_log(LOG_DEBUG, "%04d|Malloc_Hack_2: not freeing %p\n", GetTID(), p);
- // Mmaped, do not free...
+ // Mmaped, free with original function
+ if(real_free)
+ RunFunctionFmt(real_free, "p", p);
return;
}
}
@@ -396,7 +480,9 @@ EXPORT void my__ZdlPvmSt11align_val_t(void* p, size_t sz, size_t align) //oper
if(malloc_hack_2 && p) {
if(getMmapped((uintptr_t)p)) {
printf_log(LOG_DEBUG, "%04d|Malloc_Hack_2: not freeing %p\n", GetTID(), p);
- // Mmaped, do not free...
+ // Mmaped, free with original function
+ if(real_free)
+ RunFunctionFmt(real_free, "p", p);
return;
}
}
@@ -408,7 +494,9 @@ EXPORT void my__ZdaPvRKSt9nothrow_t(void* p, void* n) //operator delete[](void
if(malloc_hack_2 && p) {
if(getMmapped((uintptr_t)p)) {
printf_log(LOG_DEBUG, "%04d|Malloc_Hack_2: not freeing %p\n", GetTID(), p);
- // Mmaped, do not free...
+ // Mmaped, free with original function
+ if(real_free)
+ RunFunctionFmt(real_free, "p", p);
return;
}
}
@@ -420,7 +508,9 @@ EXPORT void my__ZdaPvSt11align_val_t(void* p, size_t align) //operator delete[
if(malloc_hack_2 && p) {
if(getMmapped((uintptr_t)p)) {
printf_log(LOG_DEBUG, "%04d|Malloc_Hack_2: not freeing %p\n", GetTID(), p);
- // Mmaped, do not free...
+ // Mmaped, free with original function
+ if(real_free)
+ RunFunctionFmt(real_free, "p", p);
return;
}
}
@@ -432,7 +522,9 @@ EXPORT void my__ZdlPvSt11align_val_t(void* p, size_t align) //operator delete(
if(malloc_hack_2 && p) {
if(getMmapped((uintptr_t)p)) {
printf_log(LOG_DEBUG, "%04d|Malloc_Hack_2: not freeing %p\n", GetTID(), p);
- // Mmaped, do not free...
+ // Mmaped, free with original function
+ if(real_free)
+ RunFunctionFmt(real_free, "p", p);
return;
}
}
@@ -444,7 +536,9 @@ EXPORT void my__ZdlPvSt11align_val_tRKSt9nothrow_t(void* p, size_t align, void*
if(malloc_hack_2 && p) {
if(getMmapped((uintptr_t)p)) {
printf_log(LOG_DEBUG, "%04d|Malloc_Hack_2: not freeing %p\n", GetTID(), p);
- // Mmaped, do not free...
+ // Mmaped, free with original function
+ if(real__ZdlPvSt11align_val_tRKSt9nothrow_t)
+ RunFunctionFmt(real__ZdlPvSt11align_val_tRKSt9nothrow_t, "pLp", p, align, n);
return;
}
}
@@ -674,34 +768,15 @@ typedef struct simple_jmp_s {
} simple_jmp_t;
#pragma pack(pop)
-static void addRelocJmp(void* offs, void* where, size_t size, const char* name)
+static void addRelocJmp(void* offs, void* where, size_t size, const char* name, elfheader_t* h, uintptr_t *real)
{
- reloc_jmp_t r_jmp = {0};
- simple_jmp_t s_jmp = {0};
- size_t sz = 0;
- intptr_t off64 = (intptr_t)where - ((intptr_t)offs+5);
- void* p = NULL;
- int32_t off32 = (int32_t)off64;
- if(off32 == off64) {
- s_jmp._e9 = 0xe9;
- s_jmp.delta = (uint32_t)off32;
- p = &s_jmp;
- sz = sizeof(s_jmp);
- } else {
- r_jmp._ff = 0xff;
- r_jmp._25 = 0x25;
- r_jmp.addr = where;
- p = &r_jmp;
- sz = sizeof(r_jmp);
- }
- if(size>=sz)
- memcpy(offs, p, sz);
- else {
- printf_log(LOG_INFO, "Warning, cannot redirect %s, too small %zu vs %zu\n", name, size, sz);
+ if(real && !*real) {
+ *real = (uintptr_t)offs;
}
+ addAlternate(offs, where);
}
-void checkHookedSymbols(lib_t *maplib, elfheader_t* h)
+void checkHookedSymbols(elfheader_t* h)
{
int hooked = 0;
if(box64_malloc_hack==1)
@@ -716,7 +791,7 @@ void checkHookedSymbols(lib_t *maplib, elfheader_t* h)
uintptr_t offs = h->DynSym[i].st_value + h->delta;
size_t sz = h->DynSym[i].st_size;
if(bind!=STB_LOCAL && bind!=STB_WEAK && sz>=sizeof(reloc_jmp_t)) {
- #define GO(A, B) if(!strcmp(symname, #A)) ++hooked; else if(!strcmp(symname, "scalable_" #A)) ++hooked; else if(!strcmp(symname, "__TBB_internal_" #A)) ++hooked;
+ #define GO(A, B) if(!strcmp(symname, #A)) ++hooked; else if(!strcmp(symname, "__libc_" #A)) ++hooked;
#define GO2(A, B)
SUPER()
#undef GO
@@ -726,9 +801,7 @@ void checkHookedSymbols(lib_t *maplib, elfheader_t* h)
}
if(hooked<2)
return; // only redirect on lib that hooked / redefined the operators
- if(box64_malloc_hack==2)
- malloc_hack_2 = 1;
- printf_log(LOG_INFO, "Redirecting overriden malloc%s function for %s\n", malloc_hack_2?" with hack":"", ElfName(h));
+ printf_log(LOG_INFO, "Redirecting overridden malloc%s function for %s\n", malloc_hack_2?" with hack":"", ElfName(h));
for (size_t i=0; i<h->numDynSym; ++i) {
const char * symname = h->DynStr+h->DynSym[i].st_name;
int bind = ELF64_ST_BIND(h->DynSym[i].st_info);
@@ -739,29 +812,30 @@ void checkHookedSymbols(lib_t *maplib, elfheader_t* h)
uintptr_t offs = h->DynSym[i].st_value + h->delta;
size_t sz = h->DynSym[i].st_size;
if(bind!=STB_LOCAL && bind!=STB_WEAK) {
- #define GO(A, B) if(!strcmp(symname, "__libc_" #A)) {uintptr_t alt = AddCheckBridge(my_context->system, B, A, 0, #A); printf_log(LOG_DEBUG, "Redirecting %s function from %p (%s)\n", symname, (void*)offs, ElfName(h)); addRelocJmp((void*)offs, (void*)alt, sz, #A);}
+ #define GO(A, B) if(!strcmp(symname, "__libc_" #A)) {uintptr_t alt = AddCheckBridge(my_context->system, B, A, 0, #A); printf_log(LOG_DEBUG, "Redirecting %s function from %p (%s)\n", symname, (void*)offs, ElfName(h)); addRelocJmp((void*)offs, (void*)alt, sz, "__libc_" #A, h, NULL);}
#define GO2(A, B)
SUPER()
#undef GO
#undef GO2
- #define GO(A, B) if(!strcmp(symname, "scalable_" #A)) {uintptr_t alt = AddCheckBridge(my_context->system, B, A, 0, #A); printf_log(LOG_DEBUG, "Redirecting %s function from %p (%s)\n", symname, (void*)offs, ElfName(h)); addRelocJmp((void*)offs, (void*)alt, sz, #A);}
- #define GO2(A, B)
- SUPER()
- #undef GO
- #undef GO2
- #define GO(A, B) if(!strcmp(symname, "__TBB_internal_" #A)) {uintptr_t alt = AddCheckBridge(my_context->system, B, A, 0, #A); printf_log(LOG_DEBUG, "Redirecting %s function from %p (%s)\n", symname, (void*)offs, ElfName(h)); addRelocJmp((void*)offs, (void*)alt, sz, #A);}
- #define GO2(A, B)
- SUPER()
- #undef GO
- #undef GO2
- #define GO(A, B) if(!strcmp(symname, #A)) {uintptr_t alt = AddCheckBridge(my_context->system, B, A, 0, #A); printf_log(LOG_DEBUG, "Redirecting %s function from %p (%s)\n", symname, (void*)offs, ElfName(h)); addRelocJmp((void*)offs, (void*)alt, sz, #A);}
- #define GO2(A, B) if(!strcmp(symname, #A)) {uintptr_t alt = AddCheckBridge(my_context->system, B, my_##A, 0, #A); printf_log(LOG_DEBUG, "Redirecting %s function from %p (%s)\n", symname, (void*)offs, ElfName(h)); addRelocJmp((void*)offs, (void*)alt, sz, #A);}
+ #define GO(A, B) if(!strcmp(symname, #A)) {uintptr_t alt = AddCheckBridge(my_context->system, B, A, 0, #A); printf_log(LOG_DEBUG, "Redirecting %s function from %p (%s)\n", symname, (void*)offs, ElfName(h)); addRelocJmp((void*)offs, (void*)alt, sz, #A, h, &real_##A);}
+ #define GO2(A, B) if(!strcmp(symname, #A)) {uintptr_t alt = AddCheckBridge(my_context->system, B, my_##A, 0, "my_" #A); printf_log(LOG_DEBUG, "Redirecting %s function from %p (%s)\n", symname, (void*)offs, ElfName(h)); addRelocJmp((void*)offs, (void*)alt, sz, "my_" #A, h, &real_##A);}
SUPER()
#undef GO
#undef GO2
}
}
}
+ if(box64_malloc_hack==2)
+ h->malloc_hook_2 = 1;
+}
+
+void startMallocHook()
+{
+ malloc_hack_2 = 1;
+}
+void endMallocHook()
+{
+ malloc_hack_2 = 0;
}
EXPORT int my___TBB_internal_find_original_malloc(int n, char* names[], void* ptr[])
diff --git a/src/rv64detect.c b/src/rv64detect.c
new file mode 100644
index 0000000..9976d1d
--- /dev/null
+++ b/src/rv64detect.c
@@ -0,0 +1,70 @@
+#include <string.h>
+#include <stdio.h>
+#include <stdint.h>
+#include <signal.h>
+#include <sys/mman.h>
+#include <setjmp.h>
+
+#include "debug.h"
+#include "dynarec/rv64/rv64_emitter.h"
+
+// Detect RV64 extensions, by executing on of the opcode with a SIGILL signal handler
+
+static sigjmp_buf sigbuf = {0};
+typedef void(*vFii_t)(int, int);
+static void detect_sigill(int sig)
+{
+ siglongjmp(sigbuf, 1);
+}
+
+static int Check(void* block)
+{
+ // Clear instruction cache
+ __clear_cache(block, block+box64_pagesize);
+ // Setup SIGILL signal handler
+ __sighandler_t old = signal(SIGILL, detect_sigill);
+ if(sigsetjmp(sigbuf, 1)) {
+ // didn't work, extension not present
+ signal(SIGILL, old);
+ return 0;
+ }
+ ((vFii_t)block)(0, 1);
+ // done...
+ signal(SIGILL, old);
+ return 1;
+}
+
+void RV64_Detect_Function()
+{
+ // Alloc memory to execute stuffs
+ void* my_block = mmap(NULL, box64_pagesize, PROT_READ|PROT_WRITE|PROT_EXEC, MAP_ANONYMOUS|MAP_PRIVATE, -1, 0);
+ if(my_block==(void*)-1) {
+ return;
+ }
+ uint32_t* block;
+ #define EMIT(A) *block = (A); ++block
+ // Test Zba with ADDUW
+ block = (uint32_t*)my_block;
+ ADDUW(A0, A0, A1);
+ BR(xRA);
+ rv64_zba = Check(my_block);
+ // Test Zbb with ANDN
+ block = (uint32_t*)my_block;
+ ANDN(A0, A0, A1);
+ BR(xRA);
+ rv64_zbb = Check(my_block);
+ // Test Zbc with CLMUL
+ block = (uint32_t*)my_block;
+ CLMUL(A0, A0, A1);
+ BR(xRA);
+ rv64_zbc = Check(my_block);
+ // Test Zbs with BCLR
+ block = (uint32_t*)my_block;
+ BCLR(A0, A0, A1);
+ BR(xRA);
+ rv64_zbs = Check(my_block);
+
+ // Finish
+ // Free the memory my_block
+ munmap(my_block, box64_pagesize);
+} \ No newline at end of file
diff --git a/src/tools/bitutils.c b/src/tools/bitutils.c
new file mode 100644
index 0000000..7d4b3a3
--- /dev/null
+++ b/src/tools/bitutils.c
@@ -0,0 +1,22 @@
+#include <stdint.h>
+
+const uint8_t deBruijn64tab[64] = {
+ 0, 1, 56, 2, 57, 49, 28, 3, 61, 58, 42, 50, 38, 29, 17, 4,
+ 62, 47, 59, 36, 45, 43, 51, 22, 53, 39, 33, 30, 24, 18, 12, 5,
+ 63, 55, 48, 27, 60, 41, 37, 16, 46, 35, 44, 21, 52, 32, 23, 11,
+ 54, 26, 40, 15, 34, 20, 31, 10, 25, 14, 19, 9, 13, 8, 7, 6,
+};
+
+int TrailingZeros64(uint64_t x) {
+ static const uint64_t deBruijn64 = 0x03f79d71b4ca8b09ULL;
+ if (x == 0) {
+ return 64;
+ }
+
+ return (int)deBruijn64tab[(x&-x)*deBruijn64>>(64-6)];
+}
+
+const uint8_t lead0tab[16] = {
+ //0b0000 0b0001 0b0010 0b0011 0b0100 0b0101 0b0110 0b0111 0b1000...
+ 0, 0, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3
+}; \ No newline at end of file
diff --git a/src/tools/box64stack.c b/src/tools/box64stack.c
index 42412e2..44596b9 100755..100644
--- a/src/tools/box64stack.c
+++ b/src/tools/box64stack.c
@@ -35,45 +35,6 @@ int CalcStackSize(box64context_t *context)
return 0;
}
-uint16_t Pop16(x64emu_t *emu)
-{
- uint16_t* st = ((uint16_t*)(R_RSP));
- R_RSP += 2;
- return *st;
-}
-
-void Push16(x64emu_t *emu, uint16_t v)
-{
- R_RSP -= 2;
- *((uint16_t*)R_RSP) = v;
-}
-
-uint32_t Pop32(x64emu_t *emu)
-{
- uint32_t* st = ((uint32_t*)(R_RSP));
- R_RSP += 4;
- return *st;
-}
-
-void Push32(x64emu_t *emu, uint32_t v)
-{
- R_RSP -= 4;
- *((uint32_t*)R_RSP) = v;
-}
-
-uint64_t Pop64(x64emu_t *emu)
-{
- uint64_t* st = ((uint64_t*)(R_RSP));
- R_RSP += 8;
- return *st;
-}
-
-void Push64(x64emu_t *emu, uint64_t v)
-{
- R_RSP -= 8;
- *((uint64_t*)R_RSP) = v;
-}
-
void PushString(x64emu_t *emu, const char* s)
{
int sz = strlen(s) + 1;
@@ -86,7 +47,7 @@ EXPORTDYN
void SetupInitialStack(x64emu_t *emu)
{
// start with 0
- Push(emu, 0);
+ Push64(emu, 0);
// push program executed
PushString(emu, emu->context->argv[0]);
uintptr_t p_arg0 = R_RSP;
@@ -116,7 +77,7 @@ void SetupInitialStack(x64emu_t *emu)
uintptr_t p_random = real_getauxval(25);
if(!p_random) {
for (int i=0; i<4; ++i)
- Push(emu, random());
+ Push64(emu, random());
p_random = R_RSP;
}
// align
@@ -146,21 +107,21 @@ void SetupInitialStack(x64emu_t *emu)
31 0x7ffd5074efea
33 0x7ffd507e6000
*/
- Push(emu, 0); Push(emu, 0); //AT_NULL(0)=0
- //Push(emu, ); Push(emu, 3); //AT_PHDR(3)=address of the PH of the executable
- //Push(emu, ); Push(emu, 4); //AT_PHENT(4)=size of PH entry
- //Push(emu, ); Push(emu, 5); //AT_PHNUM(5)=number of elf headers
- Push(emu, box64_pagesize); Push(emu, 6); //AT_PAGESZ(6)
- //Push(emu, real_getauxval(7)); Push(emu, 7); //AT_BASE(7)=ld-2.27.so start (in memory)
- Push(emu, 0); Push(emu, 8); //AT_FLAGS(8)=0
- Push(emu, R_RIP); Push(emu, 9); //AT_ENTRY(9)=entrypoint
- Push(emu, real_getauxval(11)); Push(emu, 11); //AT_UID(11)
- Push(emu, real_getauxval(12)); Push(emu, 12); //AT_EUID(12)
- Push(emu, real_getauxval(13)); Push(emu, 13); //AT_GID(13)
- Push(emu, real_getauxval(14)); Push(emu, 14); //AT_EGID(14)
- Push(emu, p_x86_64); Push(emu, 15); //AT_PLATFORM(15)=&"x86_64"
- // Push HWCAP: same as CPUID 1.EDX
- Push(emu, 1 // fpu
+ Push64(emu, 0); Push64(emu, 0); //AT_NULL(0)=0
+ //Push64(emu, ); Push64(emu, 3); //AT_PHDR(3)=address of the PH of the executable
+ //Push64(emu, ); Push64(emu, 4); //AT_PHENT(4)=size of PH entry
+ //Push64(emu, ); Push64(emu, 5); //AT_PHNUM(5)=number of elf headers
+ Push64(emu, box64_pagesize); Push64(emu, 6); //AT_PAGESZ(6)
+ //Push64(emu, real_getauxval(7)); Push64(emu, 7); //AT_BASE(7)=ld-2.27.so start (in memory)
+ Push64(emu, 0); Push64(emu, 8); //AT_FLAGS(8)=0
+ Push64(emu, R_RIP); Push64(emu, 9); //AT_ENTRY(9)=entrypoint
+ Push64(emu, real_getauxval(11)); Push64(emu, 11); //AT_UID(11)
+ Push64(emu, real_getauxval(12)); Push64(emu, 12); //AT_EUID(12)
+ Push64(emu, real_getauxval(13)); Push64(emu, 13); //AT_GID(13)
+ Push64(emu, real_getauxval(14)); Push64(emu, 14); //AT_EGID(14)
+ Push64(emu, p_x86_64); Push64(emu, 15); //AT_PLATFORM(15)=&"x86_64"
+ // Push64 HWCAP: same as CPUID 1.EDX
+ Push64(emu, 1<<0 // fpu
| 1<<4 // rdtsc
| 1<<8 // cmpxchg8
| 1<<11 // sep (sysenter & sysexit)
@@ -170,28 +131,30 @@ void SetupInitialStack(x64emu_t *emu)
| 1<<24 // fxsr (fxsave, fxrestore)
| 1<<25 // SSE
| 1<<26 // SSE2
+ | 1<<28 // hyper threading
+ | 1<<30 // ia64
);
- Push(emu, 16); //AT_HWCAP(16)=...
- //Push(emu, sysconf(_SC_CLK_TCK)); Push(emu, 17); //AT_CLKTCK(17)=times() frequency
- Push(emu, real_getauxval(23)); Push(emu, 23); //AT_SECURE(23)
- Push(emu, p_random); Push(emu, 25); //AT_RANDOM(25)=p_random
- Push(emu, 0); Push(emu, 26); //AT_HWCAP2(26)=0
- Push(emu, p_arg0); Push(emu, 31); //AT_EXECFN(31)=p_arg0
- Push(emu, emu->context->vsyscall); Push(emu, 32); //AT_SYSINFO(32)=vsyscall
- //Push(emu, 0); Push(emu, 33); //AT_SYSINFO_EHDR(33)=address of vDSO
+ Push64(emu, 16); //AT_HWCAP(16)=...
+ //Push64(emu, sysconf(_SC_CLK_TCK)); Push64(emu, 17); //AT_CLKTCK(17)=times() frequency
+ Push64(emu, real_getauxval(23)); Push64(emu, 23); //AT_SECURE(23)
+ Push64(emu, p_random); Push64(emu, 25); //AT_RANDOM(25)=p_random
+ Push64(emu, 0); Push64(emu, 26); //AT_HWCAP2(26)=0
+ Push64(emu, p_arg0); Push64(emu, 31); //AT_EXECFN(31)=p_arg0
+ Push64(emu, emu->context->vsyscall); Push64(emu, 32); //AT_SYSINFO(32)=vsyscall
+ //Push64(emu, 0); Push64(emu, 33); //AT_SYSINFO_EHDR(33)=address of vDSO
if(!emu->context->auxval_start) // store auxval start if needed
emu->context->auxval_start = (uintptr_t*)R_RSP;
// push nil / envs / nil / args / argc
- Push(emu, 0);
+ Push64(emu, 0);
for (int i=emu->context->envc-1; i>=0; --i)
- Push(emu, p_envv[i]);
+ Push64(emu, p_envv[i]);
box_free(emu->context->envv);
emu->context->envv = (char**)R_RSP;
- Push(emu, 0);
+ Push64(emu, 0);
for (int i=emu->context->argc-1; i>=0; --i)
- Push(emu, p_argv[i]);
+ Push64(emu, p_argv[i]);
box_free(emu->context->argv);
emu->context->argv = (char**)R_RSP;
- Push(emu, emu->context->argc);
+ Push64(emu, emu->context->argc);
}
diff --git a/src/tools/bridge.c b/src/tools/bridge.c
index 3bc7ca2..220e06a 100755..100644
--- a/src/tools/bridge.c
+++ b/src/tools/bridge.c
@@ -60,6 +60,9 @@ brick_t* NewBrick(void* old)
if(ptr == MAP_FAILED) {
printf_log(LOG_NONE, "Warning, cannot allocate 0x%lx aligned bytes for bridge, will probably crash later\n", NBRICK*sizeof(onebridge_t));
}
+ #ifdef DYNAREC
+ setProtection((uintptr_t)ptr, NBRICK * sizeof(onebridge_t), PROT_READ | PROT_WRITE | PROT_EXEC | PROT_NOPROT | PROT_MMAP);
+ #endif
dynarec_log(LOG_INFO, "New Bridge brick at %p (size 0x%zx)\n", ptr, NBRICK*sizeof(onebridge_t));
ret->b = ptr;
return ret;
@@ -82,10 +85,7 @@ void FreeBridge(bridge_t** bridge)
x64emu_t* emu = thread_get_emu();
while(b) {
brick_t *n = b->next;
- #ifdef DYNAREC
- if(getProtection((uintptr_t)b->b)&(PROT_DYNAREC|PROT_DYNAREC_R))
- unprotectDB((uintptr_t)b->b, NBRICK*sizeof(onebridge_t), 0);
- #endif
+ dynarec_log(LOG_INFO, "FreeBridge brick at %p (size 0x%zx)\n", b->b, NBRICK*sizeof(onebridge_t));
my_munmap(emu, b->b, NBRICK*sizeof(onebridge_t));
box_free(b);
b = n;
@@ -119,24 +119,12 @@ uintptr_t AddBridge(bridge_t* bridge, wrapper_t w, void* fnc, int N, const char*
kh_value(bridge->bridgemap, k) = (uintptr_t)&b->b[sz].CC;
mutex_unlock(&my_context->mutex_bridge);
- #ifdef DYNAREC
- int prot = 0;
- if(box64_dynarec) {
- prot=(getProtection((uintptr_t)b->b)&(PROT_DYNAREC|PROT_DYNAREC_R))?1:0;
- if(prot)
- unprotectDB((uintptr_t)b->b, NBRICK*sizeof(onebridge_t), 0); // don't mark blocks, it's only new one
- }
- #endif
b->b[sz].CC = 0xCC;
b->b[sz].S = 'S'; b->b[sz].C='C';
b->b[sz].w = w;
b->b[sz].f = (uintptr_t)fnc;
b->b[sz].C3 = N?0xC2:0xC3;
b->b[sz].N = N;
- #ifdef DYNAREC
- if(box64_dynarec)
- protectDB((uintptr_t)b->b, NBRICK*sizeof(onebridge_t));
- #endif
#ifdef HAVE_TRACE
if(name)
addBridgeName(fnc, name);
@@ -164,7 +152,7 @@ uintptr_t AddCheckBridge(bridge_t* bridge, wrapper_t w, void* fnc, int N, const
return ret;
}
-uintptr_t AddAutomaticBridge(x64emu_t* emu, bridge_t* bridge, wrapper_t w, void* fnc, int N)
+uintptr_t AddAutomaticBridge(x64emu_t* emu, bridge_t* bridge, wrapper_t w, void* fnc, int N, const char* name)
{
(void)emu;
@@ -172,14 +160,14 @@ uintptr_t AddAutomaticBridge(x64emu_t* emu, bridge_t* bridge, wrapper_t w, void*
return 0;
uintptr_t ret = CheckBridged(bridge, fnc);
if(!ret)
- ret = AddBridge(bridge, w, fnc, N, NULL);
+ ret = AddBridge(bridge, w, fnc, N, name);
if(!hasAlternate(fnc)) {
printf_log(LOG_DEBUG, "Adding AutomaticBridge for %p to %p\n", fnc, (void*)ret);
addAlternate(fnc, (void*)ret);
#ifdef DYNAREC
// now, check if dynablock at native address exist
if(box64_dynarec)
- DBAlternateBlock(emu, (uintptr_t)fnc, ret);
+ DBAlternateBlock(emu, (uintptr_t)fnc, ret, 0); // function wrapping is exclusive to 64bits on box64
#endif
}
return ret;
@@ -230,41 +218,22 @@ uintptr_t AddVSyscall(bridge_t* bridge, int num)
{
brick_t *b = NULL;
int sz = -1;
- #ifdef DYNAREC
- int prot = 0;
- do {
- #endif
- mutex_lock(&my_context->mutex_bridge);
- b = bridge->last;
- if(b->sz == NBRICK) {
- b->next = NewBrick(b->b);
- b = b->next;
- bridge->last = b;
- }
- sz = b->sz;
- #ifdef DYNAREC
- mutex_unlock(&my_context->mutex_bridge);
- if(box64_dynarec) {
- prot=(getProtection((uintptr_t)b->b)&(PROT_DYNAREC|PROT_DYNAREC_R))?1:0;
- if(prot)
- unprotectDB((uintptr_t)b->b, NBRICK*sizeof(onebridge_t), 1);
- else // only add DB if there is no protection
- addDBFromAddressRange((uintptr_t)&b->b[b->sz].CC, sizeof(onebridge_t));
- }
- } while(sz!=b->sz); // this while loop if someone took the slot when the bridge mutex was unlocked doing memory protection managment
mutex_lock(&my_context->mutex_bridge);
- #endif
+ b = bridge->last;
+ if(b->sz == NBRICK) {
+ b->next = NewBrick(b->b);
+ b = b->next;
+ bridge->last = b;
+ }
+ sz = b->sz;
b->sz++;
+ mutex_unlock(&my_context->mutex_bridge);
+
b->b[sz].B8 = 0xB8;
b->b[sz].num = num;
b->b[sz]._0F = 0x0F;
b->b[sz]._05 = 0x05;
b->b[sz]._C3 = 0xC3;
- mutex_unlock(&my_context->mutex_bridge);
- #ifdef DYNAREC
- if(box64_dynarec)
- protectDB((uintptr_t)b->b, NBRICK*sizeof(onebridge_t));
- #endif
return (uintptr_t)&b->b[sz].CC;
}
diff --git a/src/tools/bridge_private.h b/src/tools/bridge_private.h
index 0983cea..0983cea 100755..100644
--- a/src/tools/bridge_private.h
+++ b/src/tools/bridge_private.h
diff --git a/src/tools/callback.c b/src/tools/callback.c
index 9aafa6d..162c801 100755..100644
--- a/src/tools/callback.c
+++ b/src/tools/callback.c
@@ -14,10 +14,8 @@
#include "dynarec.h"
EXPORTDYN
-uint64_t RunFunction(box64context_t *context, uintptr_t fnc, int nargs, ...)
+uint64_t RunFunction(uintptr_t fnc, int nargs, ...)
{
- (void)context;
-
x64emu_t *emu = thread_get_emu();
int align = (nargs>6)?(((nargs-6)&1)):0;
int stackn = align + ((nargs>6)?(nargs-6):0);
@@ -56,11 +54,101 @@ uint64_t RunFunction(box64context_t *context, uintptr_t fnc, int nargs, ...)
}
EXPORTDYN
-uint64_t RunSafeFunction(box64context_t *context, uintptr_t fnc, int nargs, ...)
+uint64_t RunFunctionFmt(uintptr_t fnc, const char* fmt, ...)
{
- (void)context;
-
x64emu_t *emu = thread_get_emu();
+ int nargs = 0;
+ int ni = 0;
+ int ndf = 0;
+ for (int i=0; fmt[i]; ++i) {
+ switch(fmt[i]) {
+ case 'f':
+ case 'd': if(ndf<8) ++ndf; else ++nargs; break;
+ case 'p':
+ case 'i':
+ case 'u':
+ case 'I':
+ case 'U':
+ case 'L':
+ case 'l':
+ case 'w':
+ case 'W':
+ case 'c':
+ case 'C': if(ni<6) ++ni; else ++nargs; break;
+ default:
+ if(ni<6) ++ni; else ++nargs; break;
+ }
+ }
+ ni = 0;
+ ndf = 0;
+ int align = nargs&1;
+ int stackn = align + nargs;
+
+ Push64(emu, R_RBP); // push rbp
+ R_RBP = R_RSP; // mov rbp, rsp
+
+ R_RSP -= stackn*sizeof(void*); // need to push in reverse order
+
+ uint64_t *p = (uint64_t*)R_RSP;
+
+ static const int nn[] = {_DI, _SI, _DX, _CX, _R8, _R9};
+ #define GO(c, A, B, B2, C) case c: if(ni<6) emu->regs[nn[ni++]].A[0] = C va_arg(va, B2); else {*p = 0; *((B*)p) = va_arg(va, B2); ++p;}; break;
+ va_list va;
+ va_start (va, fmt);
+ for (int i=0; fmt[i]; ++i) {
+ switch(fmt[i]) {
+ case 'f': if(ndf<8)
+ emu->xmm[ndf++].f[0] = va_arg(va, double); // float are promoted to double in ...
+ else {
+ *p = 0;
+ *((float*)p) = va_arg(va, double);
+ ++p;
+ }
+ break;
+ case 'd': if(ndf<8)
+ emu->xmm[ndf++].d[0] = va_arg(va, double);
+ else {
+ *((double*)p) = va_arg(va, double);
+ ++p;
+ }
+ break;
+ GO('p', q, void*, void*, (uintptr_t))
+ GO('i', sdword, int, int, )
+ GO('u', dword, uint32_t, uint32_t, )
+ GO('I', sq, int64_t, int64_t, )
+ GO('U', q, uint64_t, uint64_t, )
+ GO('L', q, uint64_t, uint64_t, )
+ GO('l', sq, int64_t, int64_t, )
+ GO('w', sword, int16_t, int, )
+ GO('W', word, uint16_t, int, )
+ GO('c', sbyte, int8_t, int, )
+ GO('C', byte, uint8_t, int, )
+ default:
+ printf_log(LOG_NONE, "Error, unhandled arg %d: '%c' in RunFunctionFmt\n", i, fmt[i]);
+ if(ni<6) emu->regs[nn[ni++]].q[0] = va_arg(va, uint64_t); else {*p = va_arg(va, uint64_t); ++p;};
+ break;
+ }
+ }
+ va_end (va);
+
+ uintptr_t oldip = R_RIP;
+ DynaCall(emu, fnc);
+
+ if(oldip==R_RIP) {
+ R_RSP = R_RBP; // mov rsp, rbp
+ R_RBP = Pop64(emu); // pop rbp
+ }
+
+ uint64_t ret = R_RAX;
+
+ return ret;
+}
+
+EXPORTDYN
+uint64_t RunSafeFunction(uintptr_t fnc, int nargs, ...)
+{
+ x64emu_t * emu = thread_get_emu();
+
int align = (nargs>6)?(((nargs-6)&1)):0;
int stackn = align + ((nargs>6)?(nargs-6):0);
@@ -145,10 +233,10 @@ uint64_t RunFunctionWithEmu(x64emu_t *emu, int QuitOnLongJump, uintptr_t fnc, in
uintptr_t oldip = R_RIP;
int old_quit = emu->quit;
- int oldlong = emu->quitonlongjmp;
+ int oldlong = emu->flags.quitonlongjmp;
emu->quit = 0;
- emu->quitonlongjmp = QuitOnLongJump;
+ emu->flags.quitonlongjmp = QuitOnLongJump;
DynaCall(emu, fnc);
@@ -158,17 +246,15 @@ uint64_t RunFunctionWithEmu(x64emu_t *emu, int QuitOnLongJump, uintptr_t fnc, in
}
emu->quit = old_quit;
- emu->quitonlongjmp = oldlong;
+ emu->flags.quitonlongjmp = oldlong;
return R_RAX;
}
EXPORTDYN
-uint64_t RunFunctionWindows(box64context_t *context, uintptr_t fnc, int nargs, ...)
+uint64_t RunFunctionWindows(uintptr_t fnc, int nargs, ...)
{
- (void)context;
-
x64emu_t *emu = thread_get_emu();
int align = (nargs>4)?(((nargs-4)&1)):0;
int stackn = align + ((nargs>4)?(nargs-4):0);
diff --git a/src/tools/fileutils.c b/src/tools/fileutils.c
index d6d1556..d6d1556 100755..100644
--- a/src/tools/fileutils.c
+++ b/src/tools/fileutils.c
diff --git a/src/tools/gtkclass.c b/src/tools/gtkclass.c
index 0335154..269d842 100755..100644
--- a/src/tools/gtkclass.c
+++ b/src/tools/gtkclass.c
@@ -58,12 +58,12 @@ GO(10) \
GO(11) \
GO(12)
-#define WRAPPED(A, NAME, RET, DEF, N, ...) \
+#define WRAPPED(A, NAME, RET, DEF, FMT, ...) \
static uintptr_t my_##NAME##_fct_##A = 0; \
static RET my_##NAME##_##A DEF \
{ \
printf_log(LOG_DEBUG, "Calling " #NAME "_" #A " wrapper\n"); \
- return (RET)RunFunction(my_context, my_##NAME##_fct_##A, N, __VA_ARGS__);\
+ return (RET)RunFunctionFmt(my_##NAME##_fct_##A, FMT, __VA_ARGS__);\
}
#define FIND(A, NAME) \
@@ -117,32 +117,32 @@ static void autobridge_##NAME##_##A(wrapper_t W, void* fct) \
return; \
Dl_info info; \
if(dladdr(fct, &info)) \
- AddAutomaticBridge(thread_get_emu(), my_bridge, W, fct, 0); \
-}
-
-#define WRAPPER(A, NAME, RET, DEF, N, ...) \
-WRAPPED(0, NAME##_##A, RET, DEF, N, __VA_ARGS__) \
-WRAPPED(1, NAME##_##A, RET, DEF, N, __VA_ARGS__) \
-WRAPPED(2, NAME##_##A, RET, DEF, N, __VA_ARGS__) \
-WRAPPED(3, NAME##_##A, RET, DEF, N, __VA_ARGS__) \
-WRAPPED(4, NAME##_##A, RET, DEF, N, __VA_ARGS__) \
-WRAPPED(5, NAME##_##A, RET, DEF, N, __VA_ARGS__) \
-WRAPPED(6, NAME##_##A, RET, DEF, N, __VA_ARGS__) \
-WRAPPED(7, NAME##_##A, RET, DEF, N, __VA_ARGS__) \
+ AddAutomaticBridge(thread_get_emu(), my_bridge, W, fct, 0, #NAME "_" #A); \
+}
+
+#define WRAPPER(A, NAME, RET, DEF, FMT, ...) \
+WRAPPED(0, NAME##_##A, RET, DEF, FMT, __VA_ARGS__) \
+WRAPPED(1, NAME##_##A, RET, DEF, FMT, __VA_ARGS__) \
+WRAPPED(2, NAME##_##A, RET, DEF, FMT, __VA_ARGS__) \
+WRAPPED(3, NAME##_##A, RET, DEF, FMT, __VA_ARGS__) \
+WRAPPED(4, NAME##_##A, RET, DEF, FMT, __VA_ARGS__) \
+WRAPPED(5, NAME##_##A, RET, DEF, FMT, __VA_ARGS__) \
+WRAPPED(6, NAME##_##A, RET, DEF, FMT, __VA_ARGS__) \
+WRAPPED(7, NAME##_##A, RET, DEF, FMT, __VA_ARGS__) \
FIND(A, NAME) \
REVERSE(A, NAME) \
AUTOBRIDGE(A, NAME)
// ----- GObjectClass ------
// wrapper x64 -> natives of callbacks
-WRAPPER(GObject, constructor, void*, (size_t type, uint32_t n_construct_properties, void* construct_properties), 3, type, n_construct_properties, construct_properties);
-WRAPPER(GObject, set_property, void, (void* object, uint32_t property_id, void* value, void* pspec), 4, object, property_id, value, pspec);
-WRAPPER(GObject, get_property, void, (void* object, uint32_t property_id, void* value, void* pspec), 4, object, property_id, value, pspec);
-WRAPPER(GObject, dispose, void, (void* object), 1, object);
-WRAPPER(GObject, finalize, void, (void* object), 1, object);
-WRAPPER(GObject, dispatch_properties_changed, void*, (size_t type, uint32_t n_pspecs, void* pspecs), 3, type, n_pspecs, pspecs);
-WRAPPER(GObject, notify, void*, (size_t type, void* pspecs), 2, type, pspecs);
-WRAPPER(GObject, constructed, void, (void* object), 1, object);
+WRAPPER(GObject, constructor, void*, (size_t type, uint32_t n_construct_properties, void* construct_properties), "Lup", type, n_construct_properties, construct_properties);
+WRAPPER(GObject, set_property, void, (void* object, uint32_t property_id, void* value, void* pspec), "pupp", object, property_id, value, pspec);
+WRAPPER(GObject, get_property, void, (void* object, uint32_t property_id, void* value, void* pspec), "pupp", object, property_id, value, pspec);
+WRAPPER(GObject, dispose, void, (void* object), "p", object);
+WRAPPER(GObject, finalize, void, (void* object), "p", object);
+WRAPPER(GObject, dispatch_properties_changed, void*, (size_t type, uint32_t n_pspecs, void* pspecs), "Lup", type, n_pspecs, pspecs);
+WRAPPER(GObject, notify, void*, (size_t type, void* pspecs), "Lp", type, pspecs);
+WRAPPER(GObject, constructed, void, (void* object), "p", object);
#define SUPERGO() \
GO(constructor, pFLup); \
@@ -163,7 +163,7 @@ static void wrapGObjectClass(my_GObjectClass_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGObjectClass(my_GObjectClass_t* class)
-{
+{
#define GO(A, W) class->A = find_##A##_GObject (class->A)
SUPERGO()
#undef GO
@@ -179,14 +179,14 @@ static void bridgeGObjectClass(my_GObjectClass_t* class)
// ----- GInitiallyUnownedClass ------
// wrapper x86 -> natives of callbacks
-WRAPPER(GInitiallyUnowned, constructor, void*, (size_t type, uint32_t n_construct_properties, void* construct_properties), 3, type, n_construct_properties, construct_properties);
-WRAPPER(GInitiallyUnowned, set_property, void, (void* object, uint32_t property_id, void* value, void* pspec), 4, object, property_id, value, pspec);
-WRAPPER(GInitiallyUnowned, get_property, void, (void* object, uint32_t property_id, void* value, void* pspec), 4, object, property_id, value, pspec);
-WRAPPER(GInitiallyUnowned, dispose, void, (void* object), 1, object);
-WRAPPER(GInitiallyUnowned, finalize, void, (void* object), 1, object);
-WRAPPER(GInitiallyUnowned, dispatch_properties_changed, void*, (size_t type, uint32_t n_pspecs, void* pspecs), 3, type, n_pspecs, pspecs);
-WRAPPER(GInitiallyUnowned, notify, void*, (size_t type, void* pspecs), 2, type, pspecs);
-WRAPPER(GInitiallyUnowned, constructed, void, (void* object), 1, object);
+WRAPPER(GInitiallyUnowned, constructor, void*, (size_t type, uint32_t n_construct_properties, void* construct_properties), "Lup", type, n_construct_properties, construct_properties);
+WRAPPER(GInitiallyUnowned, set_property, void, (void* object, uint32_t property_id, void* value, void* pspec), "pupp", object, property_id, value, pspec);
+WRAPPER(GInitiallyUnowned, get_property, void, (void* object, uint32_t property_id, void* value, void* pspec), "pupp", object, property_id, value, pspec);
+WRAPPER(GInitiallyUnowned, dispose, void, (void* object), "p", object);
+WRAPPER(GInitiallyUnowned, finalize, void, (void* object), "p", object);
+WRAPPER(GInitiallyUnowned, dispatch_properties_changed, void*, (size_t type, uint32_t n_pspecs, void* pspecs), "Lup", type, n_pspecs, pspecs);
+WRAPPER(GInitiallyUnowned, notify, void*, (size_t type, void* pspecs), "Lp", type, pspecs);
+WRAPPER(GInitiallyUnowned, constructed, void, (void* object), "p", object);
#define SUPERGO() \
GO(constructor, pFLup); \
@@ -207,7 +207,7 @@ static void wrapGInitiallyUnownedClass(my_GInitiallyUnownedClass_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGInitiallyUnownedClass(my_GInitiallyUnownedClass_t* class)
-{
+{
#define GO(A, W) class->A = find_##A##_GInitiallyUnowned (class->A)
SUPERGO()
#undef GO
@@ -221,11 +221,138 @@ static void bridgeGInitiallyUnownedClass(my_GInitiallyUnownedClass_t* class)
}
#undef SUPERGO
+// ----- GamesScoresImporterClass ------
+// wrapper x86 -> natives of callbacks
+WRAPPER(GamesScoresImporter, importOldScores, void, (void *self, void* context, void* new_scores_dir, void *error), "pppp", self, context, new_scores_dir, error);
+
+#define SUPERGO() \
+ GO(importOldScores, vFpppp);
+
+// wrap (so bridge all calls, just in case)
+static void wrapGamesScoresImporterClass(my_GamesScoresImporterClass_t* class)
+{
+ wrapGObjectClass(&class->parent_class);
+ #define GO(A, W) class->A = reverse_##A##_GamesScoresImporter (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+// unwrap (and use callback if not a native call anymore)
+static void unwrapGamesScoresImporterClass(my_GamesScoresImporterClass_t* class)
+{
+ unwrapGObjectClass(&class->parent_class);
+ #define GO(A, W) class->A = find_##A##_GamesScoresImporter (class->A)
+ SUPERGO()
+ #undef GO
+}
+// autobridge
+static void bridgeGamesScoresImporterClass(my_GamesScoresImporterClass_t* class)
+{
+ bridgeGObjectClass(&class->parent_class);
+ #define GO(A, W) autobridge_##A##_GamesScoresImporter (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+#undef SUPERGO
+
+// ----- GApplicationClass ------
+// wrapper x86 -> natives of callbacks
+WRAPPER(GApplication, startup, void, (void* application), "p", application);
+WRAPPER(GApplication, activate, void, (void* application), "p", application);
+WRAPPER(GApplication, open, void, (void* application, void* files, int n_files, void* hint), "ppip", application, files, n_files, hint);
+WRAPPER(GApplication, command_line, void, (void* application, void* command_line), "pp", application, command_line);
+WRAPPER(GApplication, local_command_line, void, (void* application, void* arguments, void* exit_status), "ppp", application, arguments, exit_status);
+WRAPPER(GApplication, before_emit, void*, (void* application, void* platform_data), "pp", application, platform_data);
+WRAPPER(GApplication, after_emit, void, (void* application, void* platform_data), "pp", application, platform_data);
+WRAPPER(GApplication, add_platform_data, void, (void* application, void* builder), "pp", application, builder);
+WRAPPER(GApplication, quit_mainloop, void, (void* application), "p", application);
+WRAPPER(GApplication, run_mainloop, void, (void* application), "p", application);
+WRAPPER(GApplication, shutdown, void, (void* application), "p", application);
+WRAPPER(GApplication, dbus_register, void, (void* application, void* connection, void* object_path, void* error), "pppp", application, connection, object_path, error);
+WRAPPER(GApplication, dbus_unregister, void, (void* application, void* connection, void* object_path), "ppp", application, connection, object_path);
+WRAPPER(GApplication, handle_local_options, void, (void* application, void* options), "pp", application, options);
+WRAPPER(GApplication, name_lost, void, (void* application), "p", application);
+
+#define SUPERGO() \
+ GO(startup, vFp); \
+ GO(activate, vFp); \
+ GO(open, vFppip); \
+ GO(command_line, vFpp); \
+ GO(local_command_line, vFppp); \
+ GO(before_emit, vFpp); \
+ GO(after_emit, vFpp); \
+ GO(add_platform_data, vFpp); \
+ GO(quit_mainloop, vFp); \
+ GO(run_mainloop, vFp); \
+ GO(shutdown, vFp); \
+ GO(dbus_register, vFpppp); \
+ GO(dbus_unregister, vFppp); \
+ GO(handle_local_options, vFpp); \
+ GO(name_lost, vFp);
+
+// wrap (so bridge all calls, just in case)
+static void wrapGApplicationClass(my_GApplicationClass_t* class)
+{
+ #define GO(A, W) class->A = reverse_##A##_GApplication (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+// unwrap (and use callback if not a native call anymore)
+static void unwrapGApplicationClass(my_GApplicationClass_t* class)
+{
+ #define GO(A, W) class->A = find_##A##_GApplication (class->A) //SUPERGO() defined but not used
+ SUPERGO()
+ #undef GO
+}
+// autobridge
+static void bridgeGApplicationClass(my_GApplicationClass_t* class)
+{
+ #define GO(A, W) autobridge_##A##_GApplication (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+
+#undef SUPERGO
+
+// ----- GtkApplicationClass ------
+// wrapper x86 -> natives of callbacks
+WRAPPER(GtkApplication, window_added, void, (void* application, void* window), "pp", application, window);
+WRAPPER(GtkApplication, window_removed, void, (void* application, void* window), "pp", application, window);
+
+#define SUPERGO() \
+ GO(window_added, pFpp); \
+ GO(window_removed, vFpp);
+
+static void wrapGtkApplicationClass(my_GtkApplicationClass_t* class)
+{
+ wrapGApplicationClass(&class->parent_class);
+ #define GO(A, W) class->A = reverse_##A##_GtkApplication (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+
+static void unwrapGtkApplicationClass(my_GtkApplicationClass_t* class)
+{
+ unwrapGApplicationClass(&class->parent_class);
+ #define GO(A, W) class->A = find_##A##_GtkApplication (class->A)
+ SUPERGO()
+ #undef GO
+}
+
+static void bridgeGtkApplicationClass(my_GtkApplicationClass_t* class)
+{
+ bridgeGApplicationClass(&class->parent_class);
+ #define GO(A, W) autobridge_##A##_GtkApplication (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+
+#undef SUPERGO
+
// ----- GtkObjectClass ------
// wrapper x64 -> natives of callbacks
-WRAPPER(GtkObject, set_arg, void, (void* object, void* arg, uint32_t arg_id), 3, object, arg, arg_id);
-WRAPPER(GtkObject, get_arg, void, (void* object, void* arg, uint32_t arg_id), 3, object, arg, arg_id);
-WRAPPER(GtkObject, destroy, void, (void* object), 1, object);
+WRAPPER(GtkObject, set_arg, void, (void* object, void* arg, uint32_t arg_id), "ppu", object, arg, arg_id);
+WRAPPER(GtkObject, get_arg, void, (void* object, void* arg, uint32_t arg_id), "ppu", object, arg, arg_id);
+WRAPPER(GtkObject, destroy, void, (void* object), "p", object);
#define SUPERGO() \
GO(set_arg, vFppu); \
@@ -241,7 +368,7 @@ static void wrapGtkObjectClass(my_GtkObjectClass_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGtkObjectClass(my_GtkObjectClass_t* class)
-{
+{
unwrapGObjectClass(&class->parent_class);
#define GO(A, W) class->A = find_##A##_GtkObject (class->A)
SUPERGO()
@@ -260,72 +387,72 @@ static void bridgeGtkObjectClass(my_GtkObjectClass_t* class)
// ----- GtkWidget2Class ------
// wrapper x86 -> natives of callbacks
-WRAPPER(GtkWidget2, dispatch_child_properties_changed, void, (void* widget, uint32_t n_pspecs, void* pspecs), 3, widget, n_pspecs, pspecs);
-WRAPPER(GtkWidget2, show, void, (void* widget), 1, widget);
-WRAPPER(GtkWidget2, show_all, void, (void* widget), 1, widget);
-WRAPPER(GtkWidget2, hide, void, (void* widget), 1, widget);
-WRAPPER(GtkWidget2, hide_all, void, (void* widget), 1, widget);
-WRAPPER(GtkWidget2, map, void, (void* widget), 1, widget);
-WRAPPER(GtkWidget2, unmap, void, (void* widget), 1, widget);
-WRAPPER(GtkWidget2, realize, void, (void* widget), 1, widget);
-WRAPPER(GtkWidget2, unrealize, void, (void* widget), 1, widget);
-WRAPPER(GtkWidget2, size_request, void, (void* widget, void* requisition), 2, widget, requisition);
-WRAPPER(GtkWidget2, size_allocate, void, (void* widget, void* allocation), 2, widget, allocation);
-WRAPPER(GtkWidget2, state_changed, void, (void* widget, int previous_state), 2, widget, previous_state);
-WRAPPER(GtkWidget2, parent_set, void, (void* widget, void* previous_parent), 2, widget, previous_parent);
-WRAPPER(GtkWidget2, hierarchy_changed, void, (void* widget, void* previous_toplevel), 2, widget, previous_toplevel);
-WRAPPER(GtkWidget2, style_set, void, (void* widget, void* previous_style), 2, widget, previous_style);
-WRAPPER(GtkWidget2, direction_changed, void, (void* widget, int previous_direction), 2, widget, previous_direction);
-WRAPPER(GtkWidget2, grab_notify, void, (void* widget, int was_grabbed), 2, widget, was_grabbed);
-WRAPPER(GtkWidget2, child_notify, void, (void* widget, void* pspec), 2, widget, pspec);
-WRAPPER(GtkWidget2, mnemonic_activate, int, (void* widget, int group_cycling), 2, widget, group_cycling);
-WRAPPER(GtkWidget2, grab_focus, void, (void* widget), 1, widget);
-WRAPPER(GtkWidget2, focus, int, (void* widget, int direction), 2, widget, direction);
-WRAPPER(GtkWidget2, event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget2, button_press_event,int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget2, button_release_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget2, scroll_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget2, motion_notify_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget2, delete_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget2, destroy_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget2, expose_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget2, key_press_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget2, key_release_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget2, enter_notify_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget2, leave_notify_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget2, configure_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget2, focus_in_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget2, focus_out_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget2, map_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget2, unmap_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget2, property_notify_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget2, selection_clear_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget2, selection_request_event,int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget2, selection_notify_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget2, proximity_in_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget2, proximity_out_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget2, visibility_notify_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget2, client_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget2, no_expose_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget2, window_state_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget2, selection_get, void, (void* widget, void* selection_data, uint32_t info, uint32_t time_), 4, widget, selection_data, info, time_);
-WRAPPER(GtkWidget2, selection_received, void, (void* widget, void* selection_data, uint32_t time_), 3, widget, selection_data, time_);
-WRAPPER(GtkWidget2, drag_begin, void, (void* widget, void* context), 2, widget, context);
-WRAPPER(GtkWidget2, drag_end, void, (void* widget, void* context), 2, widget, context);
-WRAPPER(GtkWidget2, drag_data_get, void, (void* widget, void* context, void* selection_data, uint32_t info, uint32_t time_), 5, widget, context, selection_data, info, time_);
-WRAPPER(GtkWidget2, drag_data_delete, void, (void* widget, void* context), 2, widget, context);
-WRAPPER(GtkWidget2, drag_leave, void, (void* widget, void* context, uint32_t time_), 3, widget, context, time_);
-WRAPPER(GtkWidget2, drag_motion, int, (void* widget, void* context, int32_t x, int32_t y, uint32_t time_), 5, widget, context, x, y, time_);
-WRAPPER(GtkWidget2, drag_drop, int, (void* widget, void* context, int32_t x, int32_t y, uint32_t time_), 5, widget, context, x, y, time_);
-WRAPPER(GtkWidget2, drag_data_received, void, (void* widget, void* context, int32_t x, int32_t y, void* selection_data, uint32_t info, uint32_t time_), 7, widget, context, x, y, selection_data, info, time_);
-WRAPPER(GtkWidget2, popup_menu, int , (void* widget), 1, widget);
-WRAPPER(GtkWidget2, show_help, int , (void* widget, int help_type), 2, widget, help_type);
-WRAPPER(GtkWidget2, get_accessible, void*, (void* widget), 1, widget);
-WRAPPER(GtkWidget2, screen_changed, void , (void* widget, void* previous_screen), 2, widget, previous_screen);
-WRAPPER(GtkWidget2, can_activate_accel, int , (void* widget, uint32_t signal_id), 2, widget, signal_id);
-WRAPPER(GtkWidget2, grab_broken_event, int , (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget2, composited_changed, void , (void* widget), 1, widget);
-WRAPPER(GtkWidget2, query_tooltip, int , (void* widget, int32_t x, int32_t y, int keyboard_tooltip, void* tooltip), 5, widget, x, y, keyboard_tooltip, tooltip);
+WRAPPER(GtkWidget2, dispatch_child_properties_changed, void, (void* widget, uint32_t n_pspecs, void* pspecs), "pup", widget, n_pspecs, pspecs);
+WRAPPER(GtkWidget2, show, void, (void* widget), "p", widget);
+WRAPPER(GtkWidget2, show_all, void, (void* widget), "p", widget);
+WRAPPER(GtkWidget2, hide, void, (void* widget), "p", widget);
+WRAPPER(GtkWidget2, hide_all, void, (void* widget), "p", widget);
+WRAPPER(GtkWidget2, map, void, (void* widget), "p", widget);
+WRAPPER(GtkWidget2, unmap, void, (void* widget), "p", widget);
+WRAPPER(GtkWidget2, realize, void, (void* widget), "p", widget);
+WRAPPER(GtkWidget2, unrealize, void, (void* widget), "p", widget);
+WRAPPER(GtkWidget2, size_request, void, (void* widget, void* requisition), "pp", widget, requisition);
+WRAPPER(GtkWidget2, size_allocate, void, (void* widget, void* allocation), "pp", widget, allocation);
+WRAPPER(GtkWidget2, state_changed, void, (void* widget, int previous_state), "pi", widget, previous_state);
+WRAPPER(GtkWidget2, parent_set, void, (void* widget, void* previous_parent), "pp", widget, previous_parent);
+WRAPPER(GtkWidget2, hierarchy_changed, void, (void* widget, void* previous_toplevel), "pp", widget, previous_toplevel);
+WRAPPER(GtkWidget2, style_set, void, (void* widget, void* previous_style), "pp", widget, previous_style);
+WRAPPER(GtkWidget2, direction_changed, void, (void* widget, int previous_direction), "pi", widget, previous_direction);
+WRAPPER(GtkWidget2, grab_notify, void, (void* widget, int was_grabbed), "pi", widget, was_grabbed);
+WRAPPER(GtkWidget2, child_notify, void, (void* widget, void* pspec), "pp", widget, pspec);
+WRAPPER(GtkWidget2, mnemonic_activate, int, (void* widget, int group_cycling), "pi", widget, group_cycling);
+WRAPPER(GtkWidget2, grab_focus, void, (void* widget), "p", widget);
+WRAPPER(GtkWidget2, focus, int, (void* widget, int direction), "pi", widget, direction);
+WRAPPER(GtkWidget2, event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget2, button_press_event,int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget2, button_release_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget2, scroll_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget2, motion_notify_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget2, delete_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget2, destroy_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget2, expose_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget2, key_press_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget2, key_release_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget2, enter_notify_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget2, leave_notify_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget2, configure_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget2, focus_in_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget2, focus_out_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget2, map_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget2, unmap_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget2, property_notify_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget2, selection_clear_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget2, selection_request_event,int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget2, selection_notify_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget2, proximity_in_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget2, proximity_out_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget2, visibility_notify_event, int, (void* widget, void* event), "p", widget, event);
+WRAPPER(GtkWidget2, client_event, int, (void* widget, void* event), "p", widget, event);
+WRAPPER(GtkWidget2, no_expose_event, int, (void* widget, void* event), "p", widget, event);
+WRAPPER(GtkWidget2, window_state_event, int, (void* widget, void* event), "p", widget, event);
+WRAPPER(GtkWidget2, selection_get, void, (void* widget, void* selection_data, uint32_t info, uint32_t time_), "ppuu", widget, selection_data, info, time_);
+WRAPPER(GtkWidget2, selection_received, void, (void* widget, void* selection_data, uint32_t time_), "ppu", widget, selection_data, time_);
+WRAPPER(GtkWidget2, drag_begin, void, (void* widget, void* context), "pp", widget, context);
+WRAPPER(GtkWidget2, drag_end, void, (void* widget, void* context), "pp", widget, context);
+WRAPPER(GtkWidget2, drag_data_get, void, (void* widget, void* context, void* selection_data, uint32_t info, uint32_t time_), "pppuu", widget, context, selection_data, info, time_);
+WRAPPER(GtkWidget2, drag_data_delete, void, (void* widget, void* context), "pp", widget, context);
+WRAPPER(GtkWidget2, drag_leave, void, (void* widget, void* context, uint32_t time_), "ppu", widget, context, time_);
+WRAPPER(GtkWidget2, drag_motion, int, (void* widget, void* context, int32_t x, int32_t y, uint32_t time_), "ppiiu", widget, context, x, y, time_);
+WRAPPER(GtkWidget2, drag_drop, int, (void* widget, void* context, int32_t x, int32_t y, uint32_t time_), "ppiiu", widget, context, x, y, time_);
+WRAPPER(GtkWidget2, drag_data_received, void, (void* widget, void* context, int32_t x, int32_t y, void* selection_data, uint32_t info, uint32_t time_), "ppiipuu", widget, context, x, y, selection_data, info, time_);
+WRAPPER(GtkWidget2, popup_menu, int , (void* widget), "p", widget);
+WRAPPER(GtkWidget2, show_help, int , (void* widget, int help_type), "pi", widget, help_type);
+WRAPPER(GtkWidget2, get_accessible, void*, (void* widget), "p", widget);
+WRAPPER(GtkWidget2, screen_changed, void , (void* widget, void* previous_screen), "pp", widget, previous_screen);
+WRAPPER(GtkWidget2, can_activate_accel, int , (void* widget, uint32_t signal_id), "pu", widget, signal_id);
+WRAPPER(GtkWidget2, grab_broken_event, int , (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget2, composited_changed, void , (void* widget), "p", widget);
+WRAPPER(GtkWidget2, query_tooltip, int , (void* widget, int32_t x, int32_t y, int keyboard_tooltip, void* tooltip), "piiip", widget, x, y, keyboard_tooltip, tooltip);
#define SUPERGO() \
GO(dispatch_child_properties_changed, vFpup); \
@@ -405,7 +532,7 @@ static void wrapGtkWidget2Class(my_GtkWidget2Class_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGtkWidget2Class(my_GtkWidget2Class_t* class)
-{
+{
unwrapGtkObjectClass(&class->parent_class);
#define GO(A, W) class->A = find_##A##_GtkWidget2 (class->A)
SUPERGO()
@@ -424,88 +551,88 @@ static void bridgeGtkWidget2Class(my_GtkWidget2Class_t* class)
// ----- GtkWidget3Class ------
// wrapper x86 -> natives of callbacks
-WRAPPER(GtkWidget3, dispatch_child_properties_changed, void, (void* widget, uint32_t n_pspecs, void* pspecs), 3, widget, n_pspecs, pspecs);
-WRAPPER(GtkWidget3, destroy, void, (void* widget), 1, widget);
-WRAPPER(GtkWidget3, show, void, (void* widget), 1, widget);
-WRAPPER(GtkWidget3, show_all, void, (void* widget), 1, widget);
-WRAPPER(GtkWidget3, hide, void, (void* widget), 1, widget);
-WRAPPER(GtkWidget3, map, void, (void* widget), 1, widget);
-WRAPPER(GtkWidget3, unmap, void, (void* widget), 1, widget);
-WRAPPER(GtkWidget3, realize, void, (void* widget), 1, widget);
-WRAPPER(GtkWidget3, unrealize, void, (void* widget), 1, widget);
-WRAPPER(GtkWidget3, size_allocate, void, (void* widget, void* allocation), 2, widget, allocation);
-WRAPPER(GtkWidget3, state_changed, void, (void* widget, int previous_state), 2, widget, previous_state);
-WRAPPER(GtkWidget3, state_flags_changed, void, (void* widget, int previous_state_flags), 2, widget, previous_state_flags);
-WRAPPER(GtkWidget3, parent_set, void, (void* widget, void* previous_parent), 2, widget, previous_parent);
-WRAPPER(GtkWidget3, hierarchy_changed, void, (void* widget, void* previous_toplevel), 2, widget, previous_toplevel);
-WRAPPER(GtkWidget3, style_set, void, (void* widget, void* previous_style), 2, widget, previous_style);
-WRAPPER(GtkWidget3, direction_changed, void, (void* widget, int previous_direction), 2, widget, previous_direction);
-WRAPPER(GtkWidget3, grab_notify, void, (void* widget, int was_grabbed), 2, widget, was_grabbed);
-WRAPPER(GtkWidget3, child_notify, void, (void* widget, void* child_property), 2, widget, child_property);
-WRAPPER(GtkWidget3, draw, int, (void* widget, void* cr), 2, widget, cr);
-WRAPPER(GtkWidget3, get_request_mode, int, (void* widget), 1, widget);
-WRAPPER(GtkWidget3, get_preferred_height, void, (void* widget, void* minimum_height, void* natural_height), 3, widget, minimum_height, natural_height);
-WRAPPER(GtkWidget3, get_preferred_width_for_height, void, (void* widget, int height, void* minimum_width, void* natural_width), 4, widget, height, minimum_width, natural_width);
-WRAPPER(GtkWidget3, get_preferred_width, void, (void* widget, void* minimum_width, void* natural_width), 3, widget, minimum_width, natural_width);
-WRAPPER(GtkWidget3, get_preferred_height_for_width, void, (void* widget, int width, void* minimum_height, void* natural_height), 4, widget, width, minimum_height, natural_height);
-WRAPPER(GtkWidget3, mnemonic_activate, int, (void* widget, int group_cycling), 2, widget, group_cycling);
-WRAPPER(GtkWidget3, grab_focus, void, (void* widget), 1, widget);
-WRAPPER(GtkWidget3, focus, int, (void* widget, int direction), 2, widget, direction);
-WRAPPER(GtkWidget3, move_focus, void, (void* widget, int direction), 2, widget, direction);
-WRAPPER(GtkWidget3, keynav_failed, int, (void* widget, int direction), 2, widget, direction);
-WRAPPER(GtkWidget3, event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget3, button_press_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget3, button_release_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget3, scroll_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget3, motion_notify_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget3, delete_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget3, destroy_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget3, key_press_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget3, key_release_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget3, enter_notify_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget3, leave_notify_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget3, configure_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget3, focus_in_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget3, focus_out_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget3, map_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget3, unmap_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget3, property_notify_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget3, selection_clear_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget3, selection_request_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget3, selection_notify_event, int,(void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget3, proximity_in_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget3, proximity_out_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget3, visibility_notify_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget3, window_state_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget3, damage_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget3, grab_broken_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget3, selection_get, void, (void* widget, void* selection_data, uint32_t info, uint32_t time_), 4, widget, selection_data, info, time_);
-WRAPPER(GtkWidget3, selection_received, void, (void* widget, void* selection_data, uint32_t time_), 3, widget, selection_data, time_);
-WRAPPER(GtkWidget3, drag_begin, void, (void* widget, void* context), 2, widget, context);
-WRAPPER(GtkWidget3, drag_end, void, (void* widget, void* context), 2, widget, context);
-WRAPPER(GtkWidget3, drag_data_get, void, (void* widget, void* context, void* selection_data, uint32_t info, uint32_t time_), 5, widget, context, selection_data, info, time_);
-WRAPPER(GtkWidget3, drag_data_delete, void, (void* widget, void* context), 2, widget, context);
-WRAPPER(GtkWidget3, drag_leave, void, (void* widget, void* context, uint32_t time_), 3, widget, context, time_);
-WRAPPER(GtkWidget3, drag_motion, int, (void* widget, void* context, int x, int y, uint32_t time_), 5, widget, context, x, y, time_);
-WRAPPER(GtkWidget3, drag_drop, int, (void* widget, void* context, int x, int y, uint32_t time_), 5, widget, context, x, y, time_);
-WRAPPER(GtkWidget3, drag_data_received, void, (void* widget, void* context, int x, int y, void* selection_data, uint32_t info, uint32_t time_), 7, widget, context, x, y, selection_data, info, time_);
-WRAPPER(GtkWidget3, drag_failed, int, (void* widget, void* context, int result), 3, widget, context, result);
-WRAPPER(GtkWidget3, popup_menu, int, (void* widget), 1, widget);
-WRAPPER(GtkWidget3, show_help, int, (void* widget, int help_type), 2, widget, help_type);
-WRAPPER(GtkWidget3, get_accessible, void*, (void *widget), 1, widget);
-WRAPPER(GtkWidget3, screen_changed, void, (void* widget, void* previous_screen), 2, widget, previous_screen);
-WRAPPER(GtkWidget3, can_activate_accel, int, (void* widget, uint32_t signal_id), 2, widget, signal_id);
-WRAPPER(GtkWidget3, composited_changed, void, (void* widget), 1, widget);
-WRAPPER(GtkWidget3, query_tooltip, int, (void* widget, int x, int y, int keyboard_tooltip, void* tooltip), 5, widget, x, y, keyboard_tooltip, tooltip);
-WRAPPER(GtkWidget3, compute_expand, void, (void* widget, void* hexpand_p, void* vexpand_p), 3, widget, hexpand_p, vexpand_p);
-WRAPPER(GtkWidget3, adjust_size_request, void, (void* widget, int orientation, void* minimum_size, void* natural_size), 4, widget, orientation, minimum_size, natural_size);
-WRAPPER(GtkWidget3, adjust_size_allocation, void, (void*widget, int orientation, void* minimum_size, void* natural_size, void* allocated_pos, void* allocated_size), 6, widget, orientation, minimum_size, natural_size, allocated_pos, allocated_size);
-WRAPPER(GtkWidget3, style_updated, void, (void* widget), 1, widget);
-WRAPPER(GtkWidget3, touch_event, int, (void* widget, void* event), 2, widget, event);
-WRAPPER(GtkWidget3, get_preferred_height_and_baseline_for_width, void, (void* widget, int width, void* minimum_height, void* natural_height, void* minimum_baseline, void* natural_baseline), 6, widget, width, minimum_height, natural_height, minimum_baseline, natural_baseline);
-WRAPPER(GtkWidget3, adjust_baseline_request, void, (void* widget, void* minimum_baseline, void* natural_baseline), 3, widget, minimum_baseline, natural_baseline);
-WRAPPER(GtkWidget3, adjust_baseline_allocation, void, (void* widget, void* baseline), 2, widget, baseline);
-WRAPPER(GtkWidget3, queue_draw_region, void, (void* widget, void* region), 2, widget, region);
+WRAPPER(GtkWidget3, dispatch_child_properties_changed, void, (void* widget, uint32_t n_pspecs, void* pspecs), "pup", widget, n_pspecs, pspecs);
+WRAPPER(GtkWidget3, destroy, void, (void* widget), "p", widget);
+WRAPPER(GtkWidget3, show, void, (void* widget), "p", widget);
+WRAPPER(GtkWidget3, show_all, void, (void* widget), "p", widget);
+WRAPPER(GtkWidget3, hide, void, (void* widget), "p", widget);
+WRAPPER(GtkWidget3, map, void, (void* widget), "p", widget);
+WRAPPER(GtkWidget3, unmap, void, (void* widget), "p", widget);
+WRAPPER(GtkWidget3, realize, void, (void* widget), "p", widget);
+WRAPPER(GtkWidget3, unrealize, void, (void* widget), "p", widget);
+WRAPPER(GtkWidget3, size_allocate, void, (void* widget, void* allocation), "pp", widget, allocation);
+WRAPPER(GtkWidget3, state_changed, void, (void* widget, int previous_state), "pi", widget, previous_state);
+WRAPPER(GtkWidget3, state_flags_changed, void, (void* widget, int previous_state_flags), "pi", widget, previous_state_flags);
+WRAPPER(GtkWidget3, parent_set, void, (void* widget, void* previous_parent), "pp", widget, previous_parent);
+WRAPPER(GtkWidget3, hierarchy_changed, void, (void* widget, void* previous_toplevel), "pp", widget, previous_toplevel);
+WRAPPER(GtkWidget3, style_set, void, (void* widget, void* previous_style), "pp", widget, previous_style);
+WRAPPER(GtkWidget3, direction_changed, void, (void* widget, int previous_direction), "pi", widget, previous_direction);
+WRAPPER(GtkWidget3, grab_notify, void, (void* widget, int was_grabbed), "pi", widget, was_grabbed);
+WRAPPER(GtkWidget3, child_notify, void, (void* widget, void* child_property), "pp", widget, child_property);
+WRAPPER(GtkWidget3, draw, int, (void* widget, void* cr), "pp", widget, cr);
+WRAPPER(GtkWidget3, get_request_mode, int, (void* widget), "p", widget);
+WRAPPER(GtkWidget3, get_preferred_height, void, (void* widget, void* minimum_height, void* natural_height), "ppp", widget, minimum_height, natural_height);
+WRAPPER(GtkWidget3, get_preferred_width_for_height, void, (void* widget, int height, void* minimum_width, void* natural_width), "pipp", widget, height, minimum_width, natural_width);
+WRAPPER(GtkWidget3, get_preferred_width, void, (void* widget, void* minimum_width, void* natural_width), "ppp", widget, minimum_width, natural_width);
+WRAPPER(GtkWidget3, get_preferred_height_for_width, void, (void* widget, int width, void* minimum_height, void* natural_height), "pipp", widget, width, minimum_height, natural_height);
+WRAPPER(GtkWidget3, mnemonic_activate, int, (void* widget, int group_cycling), "pi", widget, group_cycling);
+WRAPPER(GtkWidget3, grab_focus, void, (void* widget), "p", widget);
+WRAPPER(GtkWidget3, focus, int, (void* widget, int direction), "pi", widget, direction);
+WRAPPER(GtkWidget3, move_focus, void, (void* widget, int direction), "pi", widget, direction);
+WRAPPER(GtkWidget3, keynav_failed, int, (void* widget, int direction), "pi", widget, direction);
+WRAPPER(GtkWidget3, event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget3, button_press_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget3, button_release_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget3, scroll_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget3, motion_notify_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget3, delete_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget3, destroy_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget3, key_press_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget3, key_release_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget3, enter_notify_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget3, leave_notify_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget3, configure_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget3, focus_in_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget3, focus_out_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget3, map_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget3, unmap_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget3, property_notify_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget3, selection_clear_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget3, selection_request_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget3, selection_notify_event, int,(void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget3, proximity_in_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget3, proximity_out_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget3, visibility_notify_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget3, window_state_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget3, damage_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget3, grab_broken_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget3, selection_get, void, (void* widget, void* selection_data, uint32_t info, uint32_t time_), "ppuu", widget, selection_data, info, time_);
+WRAPPER(GtkWidget3, selection_received, void, (void* widget, void* selection_data, uint32_t time_), "ppu", widget, selection_data, time_);
+WRAPPER(GtkWidget3, drag_begin, void, (void* widget, void* context), "pp", widget, context);
+WRAPPER(GtkWidget3, drag_end, void, (void* widget, void* context), "pp", widget, context);
+WRAPPER(GtkWidget3, drag_data_get, void, (void* widget, void* context, void* selection_data, uint32_t info, uint32_t time_), "pppuu", widget, context, selection_data, info, time_);
+WRAPPER(GtkWidget3, drag_data_delete, void, (void* widget, void* context), "pp", widget, context);
+WRAPPER(GtkWidget3, drag_leave, void, (void* widget, void* context, uint32_t time_), "ppu", widget, context, time_);
+WRAPPER(GtkWidget3, drag_motion, int, (void* widget, void* context, int x, int y, uint32_t time_), "ppiiu", widget, context, x, y, time_);
+WRAPPER(GtkWidget3, drag_drop, int, (void* widget, void* context, int x, int y, uint32_t time_), "ppiiu", widget, context, x, y, time_);
+WRAPPER(GtkWidget3, drag_data_received, void, (void* widget, void* context, int x, int y, void* selection_data, uint32_t info, uint32_t time_), "ppiipuu", widget, context, x, y, selection_data, info, time_);
+WRAPPER(GtkWidget3, drag_failed, int, (void* widget, void* context, int result), "ppi", widget, context, result);
+WRAPPER(GtkWidget3, popup_menu, int, (void* widget), "p", widget);
+WRAPPER(GtkWidget3, show_help, int, (void* widget, int help_type), "pi", widget, help_type);
+WRAPPER(GtkWidget3, get_accessible, void*, (void *widget), "p", widget);
+WRAPPER(GtkWidget3, screen_changed, void, (void* widget, void* previous_screen), "pp", widget, previous_screen);
+WRAPPER(GtkWidget3, can_activate_accel, int, (void* widget, uint32_t signal_id), "pu", widget, signal_id);
+WRAPPER(GtkWidget3, composited_changed, void, (void* widget), "p", widget);
+WRAPPER(GtkWidget3, query_tooltip, int, (void* widget, int x, int y, int keyboard_tooltip, void* tooltip), "piiip", widget, x, y, keyboard_tooltip, tooltip);
+WRAPPER(GtkWidget3, compute_expand, void, (void* widget, void* hexpand_p, void* vexpand_p), "ppp", widget, hexpand_p, vexpand_p);
+WRAPPER(GtkWidget3, adjust_size_request, void, (void* widget, int orientation, void* minimum_size, void* natural_size), "pipp", widget, orientation, minimum_size, natural_size);
+WRAPPER(GtkWidget3, adjust_size_allocation, void, (void*widget, int orientation, void* minimum_size, void* natural_size, void* allocated_pos, void* allocated_size), "pipppp", widget, orientation, minimum_size, natural_size, allocated_pos, allocated_size);
+WRAPPER(GtkWidget3, style_updated, void, (void* widget), "p", widget);
+WRAPPER(GtkWidget3, touch_event, int, (void* widget, void* event), "pp", widget, event);
+WRAPPER(GtkWidget3, get_preferred_height_and_baseline_for_width, void, (void* widget, int width, void* minimum_height, void* natural_height, void* minimum_baseline, void* natural_baseline), "pipppp", widget, width, minimum_height, natural_height, minimum_baseline, natural_baseline);
+WRAPPER(GtkWidget3, adjust_baseline_request, void, (void* widget, void* minimum_baseline, void* natural_baseline), "ppp", widget, minimum_baseline, natural_baseline);
+WRAPPER(GtkWidget3, adjust_baseline_allocation, void, (void* widget, void* baseline), "pp", widget, baseline);
+WRAPPER(GtkWidget3, queue_draw_region, void, (void* widget, void* region), "pp", widget, region);
#define SUPERGO() \
GO(dispatch_child_properties_changed, vFpup); \
@@ -602,7 +729,7 @@ static void wrapGtkWidget3Class(my_GtkWidget3Class_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGtkWidget3Class(my_GtkWidget3Class_t* class)
-{
+{
unwrapGInitiallyUnownedClass(&class->parent_class);
#define GO(A, W) class->A = find_##A##_GtkWidget3 (class->A)
SUPERGO()
@@ -621,15 +748,15 @@ static void bridgeGtkWidget3Class(my_GtkWidget3Class_t* class)
// ----- GtkContainer2Class ------
// wrapper x86 -> natives of callbacks
-WRAPPER(GtkContainer2, add, void, (void* container, void* widget), 2, container, widget);
-WRAPPER(GtkContainer2, remove, void, (void* container, void* widget), 2, container, widget);
-WRAPPER(GtkContainer2, check_resize, void, (void* container), 1, container);
-WRAPPER(GtkContainer2, forall, void, (void* container, int include_internals, void* callback, void* callback_data), 4, container, include_internals, AddCheckBridge(my_bridge, vFpp, callback, 0, NULL), callback_data);
-WRAPPER(GtkContainer2, set_focus_child, void, (void* container, void* widget), 2, container, widget);
-WRAPPER(GtkContainer2, child_type, int, (void* container), 1, container);
-WRAPPER(GtkContainer2, composite_name, void*, (void* container, void* child), 2, container, child);
-WRAPPER(GtkContainer2, set_child_property, void, (void* container, void* child, uint32_t property_id, void* value, void* pspec), 5, container, child, property_id, value, pspec);
-WRAPPER(GtkContainer2, get_child_property, void, (void* container, void* child, uint32_t property_id, void* value, void* pspec), 5, container, child, property_id, value, pspec);
+WRAPPER(GtkContainer2, add, void, (void* container, void* widget), "pp", container, widget);
+WRAPPER(GtkContainer2, remove, void, (void* container, void* widget), "pp", container, widget);
+WRAPPER(GtkContainer2, check_resize, void, (void* container), "p", container);
+WRAPPER(GtkContainer2, forall, void, (void* container, int include_internals, void* callback, void* callback_data), "pipp", container, include_internals, AddCheckBridge(my_bridge, vFpp, callback, 0, NULL), callback_data);
+WRAPPER(GtkContainer2, set_focus_child, void, (void* container, void* widget), "pp", container, widget);
+WRAPPER(GtkContainer2, child_type, int, (void* container), "p", container);
+WRAPPER(GtkContainer2, composite_name, void*, (void* container, void* child), "pp", container, child);
+WRAPPER(GtkContainer2, set_child_property, void, (void* container, void* child, uint32_t property_id, void* value, void* pspec), "ppupp", container, child, property_id, value, pspec);
+WRAPPER(GtkContainer2, get_child_property, void, (void* container, void* child, uint32_t property_id, void* value, void* pspec), "ppupp", container, child, property_id, value, pspec);
#define SUPERGO() \
GO(add, vFpp); \
@@ -652,7 +779,7 @@ static void wrapGtkContainer2Class(my_GtkContainer2Class_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGtkContainer2Class(my_GtkContainer2Class_t* class)
-{
+{
unwrapGtkWidget2Class(&class->parent_class);
#define GO(A, W) class->A = find_##A##_GtkContainer2 (class->A)
SUPERGO()
@@ -671,16 +798,16 @@ static void bridgeGtkContainer2Class(my_GtkContainer2Class_t* class)
// ----- GtkContainer3Class ------
// wrapper x86 -> natives of callbacks
-WRAPPER(GtkContainer3, add, void, (void* container, void* widget), 2, container, widget);
-WRAPPER(GtkContainer3, remove, void, (void* container, void* widget), 2, container, widget);
-WRAPPER(GtkContainer3, check_resize, void, (void* container), 1, container);
-WRAPPER(GtkContainer3, forall, void, (void* container, int include_internals, void* callback, void* callback_data), 4, container, include_internals, AddCheckBridge(my_bridge, vFpp, callback, 0, NULL), callback_data);
-WRAPPER(GtkContainer3, set_focus_child, void, (void* container, void* widget), 2, container, widget);
-WRAPPER(GtkContainer3, child_type, int, (void* container), 1, container);
-WRAPPER(GtkContainer3, composite_name, void*, (void* container, void* child), 2, container, child);
-WRAPPER(GtkContainer3, set_child_property, void, (void* container, void* child, uint32_t property_id, void* value, void* pspec), 5, container, child, property_id, value, pspec);
-WRAPPER(GtkContainer3, get_child_property, void, (void* container, void* child, uint32_t property_id, void* value, void* pspec), 5, container, child, property_id, value, pspec);
-WRAPPER(GtkContainer3, get_path_for_child, void*, (void* container, void* child), 2, container, child);
+WRAPPER(GtkContainer3, add, void, (void* container, void* widget), "pp", container, widget);
+WRAPPER(GtkContainer3, remove, void, (void* container, void* widget), "pp", container, widget);
+WRAPPER(GtkContainer3, check_resize, void, (void* container), "p", container);
+WRAPPER(GtkContainer3, forall, void, (void* container, int include_internals, void* callback, void* callback_data), "pipp", container, include_internals, AddCheckBridge(my_bridge, vFpp, callback, 0, NULL), callback_data);
+WRAPPER(GtkContainer3, set_focus_child, void, (void* container, void* widget), "pp", container, widget);
+WRAPPER(GtkContainer3, child_type, int, (void* container), "p", container);
+WRAPPER(GtkContainer3, composite_name, void*, (void* container, void* child), "pp", container, child);
+WRAPPER(GtkContainer3, set_child_property, void, (void* container, void* child, uint32_t property_id, void* value, void* pspec), "ppupp", container, child, property_id, value, pspec);
+WRAPPER(GtkContainer3, get_child_property, void, (void* container, void* child, uint32_t property_id, void* value, void* pspec), "ppupp", container, child, property_id, value, pspec);
+WRAPPER(GtkContainer3, get_path_for_child, void*, (void* container, void* child), "pp", container, child);
#define SUPERGO() \
GO(add, vFpp); \
@@ -704,7 +831,7 @@ static void wrapGtkContainer3Class(my_GtkContainer3Class_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGtkContainer3Class(my_GtkContainer3Class_t* class)
-{
+{
unwrapGtkWidget3Class(&class->parent_class);
#define GO(A, W) class->A = find_##A##_GtkContainer3 (class->A)
SUPERGO()
@@ -723,12 +850,12 @@ static void bridgeGtkContainer3Class(my_GtkContainer3Class_t* class)
// ----- GtkActionClass ------
// wrapper x86 -> natives of callbacks
-WRAPPER(GtkAction, activate, void, (void* action), 1, action);
-WRAPPER(GtkAction, create_menu_item, void*, (void* action), 1, action);
-WRAPPER(GtkAction, create_tool_item, void*, (void* action), 1, action);
-WRAPPER(GtkAction, connect_proxy, void , (void* action, void* proxy), 2, action, proxy);
-WRAPPER(GtkAction, disconnect_proxy, void , (void* action, void* proxy), 2, action, proxy);
-WRAPPER(GtkAction, create_menu, void*, (void* action), 1, action);
+WRAPPER(GtkAction, activate, void, (void* action), "p", action);
+WRAPPER(GtkAction, create_menu_item, void*, (void* action), "p", action);
+WRAPPER(GtkAction, create_tool_item, void*, (void* action), "p", action);
+WRAPPER(GtkAction, connect_proxy, void , (void* action, void* proxy), "pp", action, proxy);
+WRAPPER(GtkAction, disconnect_proxy, void , (void* action, void* proxy), "pp", action, proxy);
+WRAPPER(GtkAction, create_menu, void*, (void* action), "p", action);
#define SUPERGO() \
GO(activate, vFp); \
@@ -748,7 +875,7 @@ static void wrapGtkActionClass(my_GtkActionClass_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGtkActionClass(my_GtkActionClass_t* class)
-{
+{
unwrapGObjectClass(&class->parent_class);
#define GO(A, W) class->A = find_##A##_GtkAction (class->A)
SUPERGO()
@@ -773,7 +900,7 @@ static void wrapGtkMisc2Class(my_GtkMisc2Class_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGtkMisc2Class(my_GtkMisc2Class_t* class)
-{
+{
unwrapGtkWidget2Class(&class->parent_class);
}
// autobridge
@@ -782,13 +909,77 @@ static void bridgeGtkMisc2Class(my_GtkMisc2Class_t* class)
bridgeGtkWidget2Class(&class->parent_class);
}
+// ----- GtkMisc3Class ------
+// no wrapper x86 -> natives of callbacks
+
+#define SUPERGO() \
+
+// wrap (so bridge all calls, just in case)
+static void wrapGtkMisc3Class(my_GtkMisc3Class_t* class)
+{
+ wrapGtkWidget3Class(&class->parent_class);
+ #define GO(A, W) class->A = reverse_##A##_GtkMisc3 (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+// unwrap (and use callback if not a native call anymore)
+static void unwrapGtkMisc3Class(my_GtkMisc3Class_t* class)
+{
+ unwrapGtkWidget3Class(&class->parent_class);
+ #define GO(A, W) class->A = find_##A##_GtkMisc3 (class->A)
+ SUPERGO()
+ #undef GO
+}
+// autobridge
+static void bridgeGtkMisc3Class(my_GtkMisc3Class_t* class)
+{
+ bridgeGtkWidget3Class(&class->parent_class);
+ #define GO(A, W) autobridge_##A##_GtkMisc3 (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+
+#undef SUPERGO
+
+// ----- GtkGtkMenuButtonClass ------
+// wrapper x86 -> natives of callbacks
+WRAPPER(GtkMenuButton, activate, void, (void* self), "p", self);
+
+#define SUPERGO() \
+ GO(activate, vFp);
+
+// wrap (so bridge all calls, just in case)
+static void wrapGtkMenuButtonClass(my_GtkMenuButtonClass_t* class)
+{
+ wrapGtkWidget3Class(&class->parent_class);
+ #define GO(A, W) class->A = reverse_##A##_GtkMenuButton (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+// unwrap (and use callback if not a native call anymore)
+static void unwrapGtkMenuButtonClass(my_GtkMenuButtonClass_t* class)
+{
+ unwrapGtkWidget3Class(&class->parent_class);
+ #define GO(A, W) class->A = find_##A##_GtkMenuButton (class->A)
+ SUPERGO()
+ #undef GO
+}
+// autobridge
+static void bridgeGtkMenuButtonClass(my_GtkMenuButtonClass_t* class)
+{
+ bridgeGtkWidget3Class(&class->parent_class);
+ #define GO(A, W) autobridge_##A##_GtkMenuButton (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+#undef SUPERGO
// ----- GtkLabel2Class ------
// wrapper x86 -> natives of callbacks
-WRAPPER(GtkMisc2, move_cursor, void, (void* label, int step, int count, int extend_selection), 4, label, step, count, extend_selection);
-WRAPPER(GtkMisc2, copy_clipboard, void, (void* label), 1, label);
-WRAPPER(GtkMisc2, populate_popup, void, (void* label, void* menu), 2, label, menu);
-WRAPPER(GtkMisc2, activate_link, int, (void* label, void* uri), 2, label, uri);
+WRAPPER(GtkLabel2, move_cursor, void, (void* label, int step, int count, int extend_selection), "piii", label, step, count, extend_selection);
+WRAPPER(GtkLabel2, copy_clipboard, void, (void* label), "p", label);
+WRAPPER(GtkLabel2, populate_popup, void, (void* label, void* menu), "pp", label, menu);
+WRAPPER(GtkLabel2, activate_link, int, (void* label, void* uri), "pp", label, uri);
#define SUPERGO() \
GO(move_cursor, vFpiii); \
@@ -800,15 +991,15 @@ WRAPPER(GtkMisc2, activate_link, int, (void* label, void* uri), 2, label, uri);
static void wrapGtkLabel2Class(my_GtkLabel2Class_t* class)
{
wrapGtkMisc2Class(&class->parent_class);
- #define GO(A, W) class->A = reverse_##A##_GtkMisc2 (W, class->A)
+ #define GO(A, W) class->A = reverse_##A##_GtkLabel2 (W, class->A)
SUPERGO()
#undef GO
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGtkLabel2Class(my_GtkLabel2Class_t* class)
-{
+{
unwrapGtkMisc2Class(&class->parent_class);
- #define GO(A, W) class->A = find_##A##_GtkMisc2 (class->A)
+ #define GO(A, W) class->A = find_##A##_GtkLabel2 (class->A)
SUPERGO()
#undef GO
}
@@ -816,30 +1007,70 @@ static void unwrapGtkLabel2Class(my_GtkLabel2Class_t* class)
static void bridgeGtkLabel2Class(my_GtkLabel2Class_t* class)
{
bridgeGtkMisc2Class(&class->parent_class);
- #define GO(A, W) autobridge_##A##_GtkMisc2 (W, class->A)
+ #define GO(A, W) autobridge_##A##_GtkLabel2 (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+#undef SUPERGO
+
+// ----- GtkLabel3Class ------
+// wrapper x86 -> natives of callbacks
+WRAPPER(GtkLabel3, move_cursor, void, (void* label, int step, int count, int extend_selection), "piii", label, step, count, extend_selection);
+WRAPPER(GtkLabel3, copy_clipboard, void, (void* label), "p", label);
+WRAPPER(GtkLabel3, populate_popup, void, (void* label, void* menu), "pp", label, menu);
+WRAPPER(GtkLabel3, activate_link, int, (void* label, void* uri), "pp", label, uri);
+
+#define SUPERGO() \
+ GO(move_cursor, vFpiii); \
+ GO(copy_clipboard, vFp); \
+ GO(populate_popup, vFpp); \
+ GO(activate_link, iFpp); \
+
+// wrap (so bridge all calls, just in case)
+static void wrapGtkLabel3Class(my_GtkLabel3Class_t* class)
+{
+ wrapGtkMisc3Class(&class->parent_class);
+ #define GO(A, W) class->A = reverse_##A##_GtkLabel3 (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+// unwrap (and use callback if not a native call anymore)
+static void unwrapGtkLabel3Class(my_GtkLabel3Class_t* class)
+{
+ unwrapGtkMisc3Class(&class->parent_class);
+ #define GO(A, W) class->A = find_##A##_GtkLabel3 (class->A)
+ SUPERGO()
+ #undef GO
+}
+// autobridge
+static void bridgeGtkLabel3Class(my_GtkLabel3Class_t* class)
+{
+ bridgeGtkMisc3Class(&class->parent_class);
+ #define GO(A, W) autobridge_##A##_GtkLabel3 (W, class->A)
SUPERGO()
#undef GO
}
+
#undef SUPERGO
// ----- GtkTreeView2Class ------
// wrapper x86 -> natives of callbacks
-WRAPPER(GtkTreeView2, set_scroll_adjustments, void, (void* tree_view, void* hadjustment, void* vadjustment), 3, tree_view, hadjustment, vadjustment);
-WRAPPER(GtkTreeView2, row_activated, void, (void* tree_view, void* path, void* column), 3, tree_view, path, column);
-WRAPPER(GtkTreeView2, test_expand_row, int, (void* tree_view, void* iter, void* path), 3, tree_view, iter, path);
-WRAPPER(GtkTreeView2, test_collapse_row, int, (void* tree_view, void* iter, void* path), 3, tree_view, iter, path);
-WRAPPER(GtkTreeView2, row_expanded, void, (void* tree_view, void* iter, void* path), 3, tree_view, iter, path);
-WRAPPER(GtkTreeView2, row_collapsed, void, (void* tree_view, void* iter, void* path), 3, tree_view, iter, path);
-WRAPPER(GtkTreeView2, columns_changed, void, (void* tree_view), 1, tree_view);
-WRAPPER(GtkTreeView2, cursor_changed, void, (void* tree_view), 1, tree_view);
-WRAPPER(GtkTreeView2, move_cursor, int, (void* tree_view, int step, int count), 3, tree_view, step, count);
-WRAPPER(GtkTreeView2, select_all, int, (void* tree_view), 1, tree_view);
-WRAPPER(GtkTreeView2, unselect_all, int, (void* tree_view), 1, tree_view);
-WRAPPER(GtkTreeView2, select_cursor_row, int, (void* tree_view, int start_editing), 2, tree_view, start_editing);
-WRAPPER(GtkTreeView2, toggle_cursor_row, int, (void* tree_view), 1, tree_view);
-WRAPPER(GtkTreeView2, expand_collapse_cursor_row, int, (void* tree_view, int logical, int expand, int open_all), 4, tree_view, logical, expand, open_all);
-WRAPPER(GtkTreeView2, select_cursor_parent, int, (void* tree_view), 1, tree_view);
-WRAPPER(GtkTreeView2, start_interactive_search, int, (void* tree_view), 1, tree_view);
+WRAPPER(GtkTreeView2, set_scroll_adjustments, void, (void* tree_view, void* hadjustment, void* vadjustment), "ppp", tree_view, hadjustment, vadjustment);
+WRAPPER(GtkTreeView2, row_activated, void, (void* tree_view, void* path, void* column), "ppp", tree_view, path, column);
+WRAPPER(GtkTreeView2, test_expand_row, int, (void* tree_view, void* iter, void* path), "ppp", tree_view, iter, path);
+WRAPPER(GtkTreeView2, test_collapse_row, int, (void* tree_view, void* iter, void* path), "ppp", tree_view, iter, path);
+WRAPPER(GtkTreeView2, row_expanded, void, (void* tree_view, void* iter, void* path), "ppp", tree_view, iter, path);
+WRAPPER(GtkTreeView2, row_collapsed, void, (void* tree_view, void* iter, void* path), "ppp", tree_view, iter, path);
+WRAPPER(GtkTreeView2, columns_changed, void, (void* tree_view), "p", tree_view);
+WRAPPER(GtkTreeView2, cursor_changed, void, (void* tree_view), "p", tree_view);
+WRAPPER(GtkTreeView2, move_cursor, int, (void* tree_view, int step, int count), "pii", tree_view, step, count);
+WRAPPER(GtkTreeView2, select_all, int, (void* tree_view), "p", tree_view);
+WRAPPER(GtkTreeView2, unselect_all, int, (void* tree_view), "p", tree_view);
+WRAPPER(GtkTreeView2, select_cursor_row, int, (void* tree_view, int start_editing), "pi", tree_view, start_editing);
+WRAPPER(GtkTreeView2, toggle_cursor_row, int, (void* tree_view), "p", tree_view);
+WRAPPER(GtkTreeView2, expand_collapse_cursor_row, int, (void* tree_view, int logical, int expand, int open_all), "piii", tree_view, logical, expand, open_all);
+WRAPPER(GtkTreeView2, select_cursor_parent, int, (void* tree_view), "p", tree_view);
+WRAPPER(GtkTreeView2, start_interactive_search, int, (void* tree_view), "p", tree_view);
#define SUPERGO() \
GO(set_scroll_adjustments, vFppp); \
@@ -869,7 +1100,7 @@ static void wrapGtkTreeView2Class(my_GtkTreeView2Class_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGtkTreeView2Class(my_GtkTreeView2Class_t* class)
-{
+{
unwrapGtkContainer2Class(&class->parent_class);
#define GO(A, W) class->A = find_##A##_GtkTreeView2 (class->A)
SUPERGO()
@@ -895,7 +1126,7 @@ static void wrapGtkBin2Class(my_GtkBin2Class_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGtkBin2Class(my_GtkBin2Class_t* class)
-{
+{
unwrapGtkContainer2Class(&class->parent_class);
}
// autobridge
@@ -904,14 +1135,30 @@ static void bridgeGtkBin2Class(my_GtkBin2Class_t* class)
bridgeGtkContainer2Class(&class->parent_class);
}
+// ----- GtkBin3Class ------
+static void wrapGtkBin3Class(my_GtkBin3Class_t* class)
+{
+ wrapGtkContainer3Class(&class->parent_class);
+}
+// unwrap (and use callback if not a native call anymore)
+static void unwrapGtkBin3Class(my_GtkBin3Class_t* class)
+{
+ unwrapGtkContainer3Class(&class->parent_class);
+}
+// autobridge
+static void bridgeGtkBin3Class(my_GtkBin3Class_t* class)
+{
+ bridgeGtkContainer3Class(&class->parent_class);
+}
+
// ----- GtkWindow2Class ------
// wrapper x86 -> natives of callbacks
-WRAPPER(GtkWindow2, set_focus, void, (void* window, void* focus), 2, window, focus);
-WRAPPER(GtkWindow2, frame_event, int, (void* window, void* event), 2, window, event);
-WRAPPER(GtkWindow2, activate_focus, void, (void* window), 1, window);
-WRAPPER(GtkWindow2, activate_default, void, (void* window), 1, window);
-WRAPPER(GtkWindow2, move_focus, void, (void* window, int direction), 2, window, direction);
-WRAPPER(GtkWindow2, keys_changed, void, (void* window), 1, window);
+WRAPPER(GtkWindow2, set_focus, void, (void* window, void* focus), "pp", window, focus);
+WRAPPER(GtkWindow2, frame_event, int, (void* window, void* event), "pp", window, event);
+WRAPPER(GtkWindow2, activate_focus, void, (void* window), "p", window);
+WRAPPER(GtkWindow2, activate_default, void, (void* window), "p", window);
+WRAPPER(GtkWindow2, move_focus, void, (void* window, int direction), "pi", window, direction);
+WRAPPER(GtkWindow2, keys_changed, void, (void* window), "p", window);
#define SUPERGO() \
GO(set_focus, vFpp); \
@@ -932,7 +1179,7 @@ static void wrapGtkWindow2Class(my_GtkWindow2Class_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGtkWindow2Class(my_GtkWindow2Class_t* class)
-{
+{
unwrapGtkBin2Class(&class->parent_class);
#define GO(A, W) class->A = find_##A##_GtkWindow2 (class->A)
SUPERGO()
@@ -949,6 +1196,148 @@ static void bridgeGtkWindow2Class(my_GtkWindow2Class_t* class)
#undef SUPERGO
+// ----- GtkWindow3Class ------
+// wrapper x86 -> natives of callbacks
+WRAPPER(GtkWindow3, set_focus, void, (void* window, void* focus), "pp", window, focus);
+WRAPPER(GtkWindow3, activate_focus, void, (void* window), "p", window);
+WRAPPER(GtkWindow3, activate_default, void, (void* window), "p", window);
+WRAPPER(GtkWindow3, keys_changed, void, (void* window), "p", window);
+WRAPPER(GtkWindow3, enable_debugging, int, (void* window, int toggle), "pi", window, toggle);
+
+#define SUPERGO() \
+ GO(set_focus, vFpp); \
+ GO(activate_focus, vFp); \
+ GO(activate_default, vFp); \
+ GO(keys_changed, vFp); \
+ GO(enable_debugging, iFpi);
+
+
+// wrap (so bridge all calls, just in case)
+static void wrapGtkWindow3Class(my_GtkWindow3Class_t* class)
+{
+ wrapGtkBin3Class(&class->parent_class);
+ #define GO(A, W) class->A = reverse_##A##_GtkWindow3 (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+// unwrap (and use callback if not a native call anymore)
+static void unwrapGtkWindow3Class(my_GtkWindow3Class_t* class)
+{
+ unwrapGtkBin3Class(&class->parent_class);
+ #define GO(A, W) class->A = find_##A##_GtkWindow3 (class->A)
+ SUPERGO()
+ #undef GO
+}
+// autobridge
+static void bridgeGtkWindow3Class(my_GtkWindow3Class_t* class)
+{
+ bridgeGtkBin3Class(&class->parent_class);
+ #define GO(A, W) autobridge_##A##_GtkWindow3 (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+
+#undef SUPERGO
+
+// ----- GtkApplicationWindowClass ------
+// wrap (so bridge all calls, just in case)
+static void wrapGtkApplicationWindowClass(my_GtkApplicationWindowClass_t* class)
+{
+ wrapGtkWindow3Class(&class->parent_class);
+}
+// unwrap (and use callback if not a native call anymore)
+static void unwrapGtkApplicationWindowClass(my_GtkApplicationWindowClass_t* class)
+{
+ unwrapGtkWindow3Class(&class->parent_class);
+}
+// autobridge
+static void bridgeGtkApplicationWindowClass(my_GtkApplicationWindowClass_t* class)
+{
+ bridgeGtkWindow3Class(&class->parent_class);
+}
+
+// ----- GtkListBoxClass ------
+// wrapper x86 -> natives of callbacks
+WRAPPER(GtkListBoxClass,row_selected, void, (void *box, void *row), "pp", box, row);
+WRAPPER(GtkListBoxClass,row_activated, void, (void *box, void *row), "pp", box, row);
+WRAPPER(GtkListBoxClass,activate_cursor_row, void, (void *box), "p", box);
+WRAPPER(GtkListBoxClass,toggle_cursor_row, void, (void *box), "p", box);
+WRAPPER(GtkListBoxClass,move_cursor, void, (void *box, int step, int count), "pii", box, step, count);
+WRAPPER(GtkListBoxClass,selected_rows_changed, void, (void *box), "p", box);
+WRAPPER(GtkListBoxClass,select_all, void, (void *box), "p", box);
+WRAPPER(GtkListBoxClass,unselect_all, void, (void *box), "p", box);
+
+#define SUPERGO() \
+ GO(row_selected, vFpp); \
+ GO(row_activated, vFpp); \
+ GO(activate_cursor_row, vFp); \
+ GO(toggle_cursor_row, vFp); \
+ GO(move_cursor, vFpii); \
+ GO(selected_rows_changed, vFp); \
+ GO(select_all, vFp); \
+ GO(unselect_all, vFp);
+
+// wrap (so bridge all calls, just in case)
+static void wrapGtkListBoxClass(my_GtkListBoxClass_t* class)
+{
+ wrapGtkContainer3Class(&class->parent_class);
+ #define GO(A, W) class->A = reverse_##A##_GtkListBoxClass (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+// unwrap (and use callback if not a native call anymore)
+static void unwrapGtkListBoxClass(my_GtkListBoxClass_t* class)
+{
+ unwrapGtkContainer3Class(&class->parent_class);
+ #define GO(A, W) class->A = find_##A##_GtkListBoxClass (class->A)
+ SUPERGO()
+ #undef GO
+}
+// autobridge
+static void bridgeGtkListBoxClass(my_GtkListBoxClass_t* class)
+{
+ bridgeGtkContainer3Class(&class->parent_class);
+ #define GO(A, W) autobridge_##A##_GtkListBoxClass (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+
+#undef SUPERGO
+
+// ----- GtkListBoxRowClass ------
+// wrapper x86 -> natives of callbacks
+WRAPPER(GtkListBoxRowClass, activate, void, (void *row), "p", row);
+
+#define SUPERGO() \
+ GO(activate, vFpp);
+
+// wrap (so bridge all calls, just in case)
+static void wrapGtkListBoxRowClass(my_GtkListBoxRowClass_t* class)
+{
+ wrapGtkBin3Class(&class->parent_class);
+ #define GO(A, W) class->A = reverse_##A##_GtkListBoxRowClass (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+// unwrap (and use callback if not a native call anymore)
+static void unwrapGtkListBoxRowClass(my_GtkListBoxRowClass_t* class)
+{
+ unwrapGtkBin3Class(&class->parent_class);
+ #define GO(A, W) class->A = find_##A##_GtkListBoxRowClass (class->A)
+ SUPERGO()
+ #undef GO
+}
+// autobridge
+static void bridgeGtkListBoxRowClass(my_GtkListBoxRowClass_t* class)
+{
+ bridgeGtkBin3Class(&class->parent_class);
+ #define GO(A, W) autobridge_##A##_GtkListBoxRowClass (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+
+#undef SUPERGO
+
// ----- GtkTable2Class ------
// wrap (so bridge all calls, just in case)
static void wrapGtkTable2Class(my_GtkTable2Class_t* class)
@@ -957,7 +1346,7 @@ static void wrapGtkTable2Class(my_GtkTable2Class_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGtkTable2Class(my_GtkTable2Class_t* class)
-{
+{
unwrapGtkContainer2Class(&class->parent_class);
}
// autobridge
@@ -975,7 +1364,7 @@ static void wrapGtkFixed2Class(my_GtkFixed2Class_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGtkFixed2Class(my_GtkFixed2Class_t* class)
-{
+{
unwrapGtkContainer2Class(&class->parent_class);
}
// autobridge
@@ -993,7 +1382,7 @@ static void wrapMetaFrames2Class(my_MetaFrames2Class_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapMetaFrames2Class(my_MetaFrames2Class_t* class)
-{
+{
unwrapGtkWindow2Class(&class->parent_class);
}
// autobridge
@@ -1004,8 +1393,8 @@ static void bridgeMetaFrames2Class(my_MetaFrames2Class_t* class)
// ----- GDBusObjectManagerClientClass ------
// wrapper x86 -> natives of callbacks
-WRAPPER(GDBusObjectManagerClient,interface_proxy_signal, void, (void* manager, void* object_proxy, void* interface_proxy, void* sender_name, void* signal_name, void* parameters), 6, manager, object_proxy, interface_proxy, sender_name, signal_name, parameters);
-WRAPPER(GDBusObjectManagerClient,interface_proxy_properties_changed, void, (void* manager, void* object_proxy, void* interface_proxy, void* changed_properties, void* invalidated_properties), 5, manager, object_proxy, interface_proxy, changed_properties, invalidated_properties);
+WRAPPER(GDBusObjectManagerClient,interface_proxy_signal, void, (void* manager, void* object_proxy, void* interface_proxy, void* sender_name, void* signal_name, void* parameters), "pppppp", manager, object_proxy, interface_proxy, sender_name, signal_name, parameters);
+WRAPPER(GDBusObjectManagerClient,interface_proxy_properties_changed, void, (void* manager, void* object_proxy, void* interface_proxy, void* changed_properties, void* invalidated_properties), "ppppp", manager, object_proxy, interface_proxy, changed_properties, invalidated_properties);
#define SUPERGO() \
GO(interface_proxy_signal, vFpppppp); \
@@ -1022,7 +1411,7 @@ static void wrapGDBusObjectManagerClientClass(my_GDBusObjectManagerClientClass_t
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGDBusObjectManagerClientClass(my_GDBusObjectManagerClientClass_t* class)
-{
+{
unwrapGObjectClass(&class->parent_class);
#define GO(A, W) class->A = find_##A##_GDBusObjectManagerClient (class->A)
SUPERGO()
@@ -1041,12 +1430,12 @@ static void bridgeGDBusObjectManagerClientClass(my_GDBusObjectManagerClientClass
// ----- GtkButton2Class ------
// wrapper x86 -> natives of callbacks
-WRAPPER(GtkButton2, pressed, void, (void* button), 1, button);
-WRAPPER(GtkButton2, released, void, (void* button), 1, button);
-WRAPPER(GtkButton2, clicked, void, (void* button), 1, button);
-WRAPPER(GtkButton2, enter, void, (void* button), 1, button);
-WRAPPER(GtkButton2, leave, void, (void* button), 1, button);
-WRAPPER(GtkButton2, activate, void, (void* button), 1, button);
+WRAPPER(GtkButton2, pressed, void, (void* button), "p", button);
+WRAPPER(GtkButton2, released, void, (void* button), "p", button);
+WRAPPER(GtkButton2, clicked, void, (void* button), "p", button);
+WRAPPER(GtkButton2, enter, void, (void* button), "p", button);
+WRAPPER(GtkButton2, leave, void, (void* button), "p", button);
+WRAPPER(GtkButton2, activate, void, (void* button), "p", button);
#define SUPERGO() \
GO(pressed, vFp); \
@@ -1067,7 +1456,7 @@ static void wrapGtkButton2Class(my_GtkButton2Class_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGtkButton2Class(my_GtkButton2Class_t* class)
-{
+{
unwrapGtkBin2Class(&class->parent_class);
#define GO(A, W) class->A = find_##A##_GtkButton2 (class->A)
SUPERGO()
@@ -1084,10 +1473,55 @@ static void bridgeGtkButton2Class(my_GtkButton2Class_t* class)
#undef SUPERGO
+// ----- GtkButton3Class ------
+// wrapper x86 -> natives of callbacks
+WRAPPER(GtkButton3, pressed, void, (void* button), "p", button);
+WRAPPER(GtkButton3, released, void, (void* button), "p", button);
+WRAPPER(GtkButton3, clicked, void, (void* button), "p", button);
+WRAPPER(GtkButton3, enter, void, (void* button), "p", button);
+WRAPPER(GtkButton3, leave, void, (void* button), "p", button);
+WRAPPER(GtkButton3, activate, void, (void* button), "p", button);
+
+#define SUPERGO() \
+ GO(pressed, vFp); \
+ GO(released, vFp); \
+ GO(clicked, vFp); \
+ GO(enter, vFp); \
+ GO(leave, vFp); \
+ GO(activate, vFp); \
+
+
+// wrap (so bridge all calls, just in case)
+static void wrapGtkButton3Class(my_GtkButton3Class_t* class)
+{
+ wrapGtkBin3Class(&class->parent_class);
+ #define GO(A, W) class->A = reverse_##A##_GtkButton3 (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+// unwrap (and use callback if not a native call anymore)
+static void unwrapGtkButton3Class(my_GtkButton3Class_t* class)
+{
+ unwrapGtkBin3Class(&class->parent_class);
+ #define GO(A, W) class->A = find_##A##_GtkButton3 (class->A)
+ SUPERGO()
+ #undef GO
+}
+// autobridge
+static void bridgeGtkButton3Class(my_GtkButton3Class_t* class)
+{
+ bridgeGtkBin3Class(&class->parent_class);
+ #define GO(A, W) autobridge_##A##_GtkButton3 (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+
+#undef SUPERGO
+
// ----- GtkComboBox2Class ------
// wrapper x86 -> natives of callbacks
-WRAPPER(GtkComboBox2, changed, void, (void* combo_box), 1, combo_box);
-WRAPPER(GtkComboBox2, get_active_text, void*, (void* combo_box), 1, combo_box);
+WRAPPER(GtkComboBox2, changed, void, (void* combo_box), "p", combo_box);
+WRAPPER(GtkComboBox2, get_active_text, void*, (void* combo_box), "p", combo_box);
#define SUPERGO() \
GO(changed, vFp); \
@@ -1104,7 +1538,7 @@ static void wrapGtkComboBox2Class(my_GtkComboBox2Class_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGtkComboBox2Class(my_GtkComboBox2Class_t* class)
-{
+{
unwrapGtkBin2Class(&class->parent_class);
#define GO(A, W) class->A = find_##A##_GtkComboBox2 (class->A)
SUPERGO()
@@ -1123,7 +1557,7 @@ static void bridgeGtkComboBox2Class(my_GtkComboBox2Class_t* class)
// ----- GtkToggleButton2Class ------
// wrapper x86 -> natives of callbacks
-WRAPPER(GtkToggleButton2, toggled, void, (void* toggle_button), 1, toggle_button);
+WRAPPER(GtkToggleButton2, toggled, void, (void* toggle_button), "p", toggle_button);
#define SUPERGO() \
GO(toggled, vFp); \
@@ -1139,7 +1573,7 @@ static void wrapGtkToggleButton2Class(my_GtkToggleButton2Class_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGtkToggleButton2Class(my_GtkToggleButton2Class_t* class)
-{
+{
unwrapGtkButton2Class(&class->parent_class);
#define GO(A, W) class->A = find_##A##_GtkToggleButton2 (class->A)
SUPERGO()
@@ -1158,7 +1592,7 @@ static void bridgeGtkToggleButton2Class(my_GtkToggleButton2Class_t* class)
// ----- GtkCheckButton2Class ------
// wrapper x86 -> natives of callbacks
-WRAPPER(GtkCheckButton2, draw_indicator, void, (void* check_button, void* area), 2, check_button, area);
+WRAPPER(GtkCheckButton2, draw_indicator, void, (void* check_button, void* area), "pp", check_button, area);
#define SUPERGO() \
GO(draw_indicator, vFpp); \
@@ -1174,7 +1608,7 @@ static void wrapGtkCheckButton2Class(my_GtkCheckButton2Class_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGtkCheckButton2Class(my_GtkCheckButton2Class_t* class)
-{
+{
unwrapGtkToggleButton2Class(&class->parent_class);
#define GO(A, W) class->A = find_##A##_GtkCheckButton2 (class->A)
SUPERGO()
@@ -1193,17 +1627,17 @@ static void bridgeGtkCheckButton2Class(my_GtkCheckButton2Class_t* class)
// ----- GtkEntry2Class ------
// wrapper x86 -> natives of callbacks
-WRAPPER(GtkEntry2, populate_popup, void, (void* entry, void* menu), 2, entry, menu);
-WRAPPER(GtkEntry2, activate, void, (void* entry), 1, entry);
-WRAPPER(GtkEntry2, move_cursor, void, (void* entry, int step, int count, int extend_selection), 4, entry, step, count, extend_selection);
-WRAPPER(GtkEntry2, insert_at_cursor, void, (void* entry, void* str), 2, entry, str);
-WRAPPER(GtkEntry2, delete_from_cursor, void, (void* entry, size_t type, int count), 3, entry, type, count);
-WRAPPER(GtkEntry2, backspace, void, (void* entry), 1, entry);
-WRAPPER(GtkEntry2, cut_clipboard, void, (void* entry), 1, entry);
-WRAPPER(GtkEntry2, copy_clipboard, void, (void* entry), 1, entry);
-WRAPPER(GtkEntry2, paste_clipboard, void, (void* entry), 1, entry);
-WRAPPER(GtkEntry2, toggle_overwrite, void, (void* entry), 1, entry);
-WRAPPER(GtkEntry2, get_text_area_size, void, (void* entry, void* x, void* y, void* width, void* height), 5, entry, x, y, width, height);
+WRAPPER(GtkEntry2, populate_popup, void, (void* entry, void* menu), "pp", entry, menu);
+WRAPPER(GtkEntry2, activate, void, (void* entry), "p", entry);
+WRAPPER(GtkEntry2, move_cursor, void, (void* entry, int step, int count, int extend_selection), "piii", entry, step, count, extend_selection);
+WRAPPER(GtkEntry2, insert_at_cursor, void, (void* entry, void* str), "pp", entry, str);
+WRAPPER(GtkEntry2, delete_from_cursor, void, (void* entry, size_t type, int count), "pLi", entry, type, count);
+WRAPPER(GtkEntry2, backspace, void, (void* entry), "p", entry);
+WRAPPER(GtkEntry2, cut_clipboard, void, (void* entry), "p", entry);
+WRAPPER(GtkEntry2, copy_clipboard, void, (void* entry), "p", entry);
+WRAPPER(GtkEntry2, paste_clipboard, void, (void* entry), "p", entry);
+WRAPPER(GtkEntry2, toggle_overwrite, void, (void* entry), "p", entry);
+WRAPPER(GtkEntry2, get_text_area_size, void, (void* entry, void* x, void* y, void* width, void* height), "ppppp", entry, x, y, width, height);
#define SUPERGO() \
GO(populate_popup, vFpp); \
@@ -1228,7 +1662,7 @@ static void wrapGtkEntry2Class(my_GtkEntry2Class_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGtkEntry2Class(my_GtkEntry2Class_t* class)
-{
+{
unwrapGtkWidget2Class(&class->parent_class);
#define GO(A, W) class->A = find_##A##_GtkEntry2 (class->A)
SUPERGO()
@@ -1247,11 +1681,11 @@ static void bridgeGtkEntry2Class(my_GtkEntry2Class_t* class)
// ----- GtkSpinButton2Class ------
// wrapper x86 -> natives of callbacks
-WRAPPER(GtkSpinButton2, input, int, (void* spin_button, void* new_value), 2, spin_button, new_value);
-WRAPPER(GtkSpinButton2, output, int, (void* spin_button), 1, spin_button);
-WRAPPER(GtkSpinButton2, value_changed, void, (void* spin_button), 1, spin_button);
-WRAPPER(GtkSpinButton2, change_value, void, (void* spin_button, int scroll), 2, spin_button, scroll);
-WRAPPER(GtkSpinButton2, wrapped, void, (void* spin_button), 1, spin_button);
+WRAPPER(GtkSpinButton2, input, int, (void* spin_button, void* new_value), "pp", spin_button, new_value);
+WRAPPER(GtkSpinButton2, output, int, (void* spin_button), "p", spin_button);
+WRAPPER(GtkSpinButton2, value_changed, void, (void* spin_button), "p", spin_button);
+WRAPPER(GtkSpinButton2, change_value, void, (void* spin_button, int scroll), "pi", spin_button, scroll);
+WRAPPER(GtkSpinButton2, wrapped, void, (void* spin_button), "p", spin_button);
#define SUPERGO() \
GO(input, iFpp); \
@@ -1270,7 +1704,7 @@ static void wrapGtkSpinButton2Class(my_GtkSpinButton2Class_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGtkSpinButton2Class(my_GtkSpinButton2Class_t* class)
-{
+{
unwrapGtkEntry2Class(&class->parent_class);
#define GO(A, W) class->A = find_##A##_GtkSpinButton2 (class->A)
SUPERGO()
@@ -1289,9 +1723,9 @@ static void bridgeGtkSpinButton2Class(my_GtkSpinButton2Class_t* class)
// ----- GtkProgress2Class ------
// wrapper x86 -> natives of callbacks
-WRAPPER(GtkProgress2, paint, void, (void* progress), 1, progress);
-WRAPPER(GtkProgress2, update, void, (void* progress), 1, progress);
-WRAPPER(GtkProgress2, act_mode_enter, void, (void* progress), 1, progress);
+WRAPPER(GtkProgress2, paint, void, (void* progress), "p", progress);
+WRAPPER(GtkProgress2, update, void, (void* progress), "p", progress);
+WRAPPER(GtkProgress2, act_mode_enter, void, (void* progress), "p", progress);
#define SUPERGO() \
GO(paint, vFp); \
@@ -1308,7 +1742,7 @@ static void wrapGtkProgress2Class(my_GtkProgress2Class_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGtkProgress2Class(my_GtkProgress2Class_t* class)
-{
+{
unwrapGtkWidget2Class(&class->parent_class);
#define GO(A, W) class->A = find_##A##_GtkProgress2 (class->A)
SUPERGO()
@@ -1340,7 +1774,7 @@ static void wrapGtkProgressBar2Class(my_GtkProgressBar2Class_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGtkProgressBar2Class(my_GtkProgressBar2Class_t* class)
-{
+{
unwrapGtkProgress2Class(&class->parent_class);
#define GO(A, W) class->A = find_##A##_GtkProgressBar2 (class->A)
SUPERGO()
@@ -1359,7 +1793,7 @@ static void bridgeGtkProgressBar2Class(my_GtkProgressBar2Class_t* class)
// ----- GtkFrame2Class ------
// wrapper x86 -> natives of callbacks
-WRAPPER(GtkFrame2, compute_child_allocation, void, (void* frame, void* allocation), 2, frame, allocation);
+WRAPPER(GtkFrame2, compute_child_allocation, void, (void* frame, void* allocation), "pp", frame, allocation);
#define SUPERGO() \
GO(compute_child_allocation, vFpp); \
@@ -1374,7 +1808,7 @@ static void wrapGtkFrame2Class(my_GtkFrame2Class_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGtkFrame2Class(my_GtkFrame2Class_t* class)
-{
+{
unwrapGtkBin2Class(&class->parent_class);
#define GO(A, W) class->A = find_##A##_GtkFrame2 (class->A)
SUPERGO()
@@ -1393,15 +1827,15 @@ static void bridgeGtkFrame2Class(my_GtkFrame2Class_t* class)
// ----- GtkMenuShell2Class ------
// wrapper x86 -> natives of callbacks
-WRAPPER(GtkMenuShell2,deactivate, void, (void* menu_shell), 1, menu_shell);
-WRAPPER(GtkMenuShell2,selection_done, void, (void* menu_shell), 1, menu_shell);
-WRAPPER(GtkMenuShell2,move_current, void, (void* menu_shell, int direction), 2, menu_shell, direction);
-WRAPPER(GtkMenuShell2,activate_current, void,(void* menu_shell, int force_hide), 2, menu_shell, force_hide);
-WRAPPER(GtkMenuShell2,cancel, void, (void* menu_shell), 1, menu_shell);
-WRAPPER(GtkMenuShell2,select_item, void, (void* menu_shell, void* menu_item), 2, menu_shell, menu_item);
-WRAPPER(GtkMenuShell2,insert, void, (void* menu_shell, void* child, int position), 3, menu_shell, child, position);
-WRAPPER(GtkMenuShell2,get_popup_delay, int, (void* menu_shell), 1, menu_shell);
-WRAPPER(GtkMenuShell2,move_selected, int, (void* menu_shell, int distance), 2, menu_shell, distance);
+WRAPPER(GtkMenuShell2,deactivate, void, (void* menu_shell), "p", menu_shell);
+WRAPPER(GtkMenuShell2,selection_done, void, (void* menu_shell), "p", menu_shell);
+WRAPPER(GtkMenuShell2,move_current, void, (void* menu_shell, int direction), "pi", menu_shell, direction);
+WRAPPER(GtkMenuShell2,activate_current, void,(void* menu_shell, int force_hide), "pi", menu_shell, force_hide);
+WRAPPER(GtkMenuShell2,cancel, void, (void* menu_shell), "p", menu_shell);
+WRAPPER(GtkMenuShell2,select_item, void, (void* menu_shell, void* menu_item), "pp", menu_shell, menu_item);
+WRAPPER(GtkMenuShell2,insert, void, (void* menu_shell, void* child, int position), "ppi", menu_shell, child, position);
+WRAPPER(GtkMenuShell2,get_popup_delay, int, (void* menu_shell), "p", menu_shell);
+WRAPPER(GtkMenuShell2,move_selected, int, (void* menu_shell, int distance), "pi", menu_shell, distance);
#define SUPERGO() \
GO(deactivate, vFp); \
@@ -1424,7 +1858,7 @@ static void wrapGtkMenuShell2Class(my_GtkMenuShell2Class_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGtkMenuShell2Class(my_GtkMenuShell2Class_t* class)
-{
+{
unwrapGtkContainer2Class(&class->parent_class);
#define GO(A, W) class->A = find_##A##_GtkMenuShell2 (class->A)
SUPERGO()
@@ -1456,7 +1890,7 @@ static void wrapGtkMenuBar2Class(my_GtkMenuBar2Class_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGtkMenuBar2Class(my_GtkMenuBar2Class_t* class)
-{
+{
unwrapGtkMenuShell2Class(&class->parent_class);
#define GO(A, W) class->A = find_##A##_GtkMenuBar2 (class->A)
SUPERGO()
@@ -1475,19 +1909,19 @@ static void bridgeGtkMenuBar2Class(my_GtkMenuBar2Class_t* class)
// ----- GtkTextView2Class ------
// wrapper x86 -> natives of callbacks
-WRAPPER(GtkTextView2, set_scroll_adjustments, void, (void* text_view, void* hadjustment, void* vadjustment), 3, text_view, hadjustment, vadjustment);
-WRAPPER(GtkTextView2, populate_popup, void, (void* text_view, void* menu), 2, text_view, menu);
-WRAPPER(GtkTextView2, move_cursor, void, (void* text_view, int step, int count, int extend_selection), 4, text_view, step, count, extend_selection);
-WRAPPER(GtkTextView2, page_horizontally, void, (void* text_view, int count, int extend_selection), 3, text_view, count, extend_selection);
-WRAPPER(GtkTextView2, set_anchor, void, (void* text_view), 1, text_view);
-WRAPPER(GtkTextView2, insert_at_cursor, void, (void* text_view, void* str), 2, text_view, str);
-WRAPPER(GtkTextView2, delete_from_cursor, void, (void* text_view, int type, int count), 3, text_view, type, count);
-WRAPPER(GtkTextView2, backspace, void, (void* text_view), 1, text_view);
-WRAPPER(GtkTextView2, cut_clipboard, void, (void* text_view), 1, text_view);
-WRAPPER(GtkTextView2, copy_clipboard, void, (void* text_view), 1, text_view);
-WRAPPER(GtkTextView2, paste_clipboard, void, (void* text_view), 1, text_view);
-WRAPPER(GtkTextView2, toggle_overwrite, void, (void* text_view), 1, text_view);
-WRAPPER(GtkTextView2, move_focus, void, (void* text_view, int direction), 2, text_view, direction);
+WRAPPER(GtkTextView2, set_scroll_adjustments, void, (void* text_view, void* hadjustment, void* vadjustment), "ppp", text_view, hadjustment, vadjustment);
+WRAPPER(GtkTextView2, populate_popup, void, (void* text_view, void* menu), "pp", text_view, menu);
+WRAPPER(GtkTextView2, move_cursor, void, (void* text_view, int step, int count, int extend_selection), "piii", text_view, step, count, extend_selection);
+WRAPPER(GtkTextView2, page_horizontally, void, (void* text_view, int count, int extend_selection), "pii", text_view, count, extend_selection);
+WRAPPER(GtkTextView2, set_anchor, void, (void* text_view), "p", text_view);
+WRAPPER(GtkTextView2, insert_at_cursor, void, (void* text_view, void* str), "pp", text_view, str);
+WRAPPER(GtkTextView2, delete_from_cursor, void, (void* text_view, int type, int count), "pii", text_view, type, count);
+WRAPPER(GtkTextView2, backspace, void, (void* text_view), "p", text_view);
+WRAPPER(GtkTextView2, cut_clipboard, void, (void* text_view), "p", text_view);
+WRAPPER(GtkTextView2, copy_clipboard, void, (void* text_view), "p", text_view);
+WRAPPER(GtkTextView2, paste_clipboard, void, (void* text_view), "p", text_view);
+WRAPPER(GtkTextView2, toggle_overwrite, void, (void* text_view), "p", text_view);
+WRAPPER(GtkTextView2, move_focus, void, (void* text_view, int direction), "pi", text_view, direction);
#define SUPERGO() \
GO(set_scroll_adjustments, vFppp); \
@@ -1514,7 +1948,7 @@ static void wrapGtkTextView2Class(my_GtkTextView2Class_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGtkTextView2Class(my_GtkTextView2Class_t* class)
-{
+{
unwrapGtkContainer2Class(&class->parent_class);
#define GO(A, W) class->A = find_##A##_GtkTextView2 (class->A)
SUPERGO()
@@ -1533,20 +1967,20 @@ static void bridgeGtkTextView2Class(my_GtkTextView2Class_t* class)
// ----- GtkTextView3Class ------
// wrapper x86 -> natives of callbacks
-WRAPPER(GtkTextView3, populate_popup, void, (void* text_view, void* menu), 2, text_view, menu);
-WRAPPER(GtkTextView3, move_cursor, void, (void* text_view, int step, int count, int extend_selection), 4, text_view, step, count, extend_selection);
-WRAPPER(GtkTextView3, set_anchor, void, (void* text_view), 1, text_view);
-WRAPPER(GtkTextView3, insert_at_cursor, void, (void* text_view, void* str), 2, text_view, str);
-WRAPPER(GtkTextView3, delete_from_cursor, void, (void* text_view, int type, int count), 3, text_view, type, count);
-WRAPPER(GtkTextView3, backspace, void, (void* text_view), 1, text_view);
-WRAPPER(GtkTextView3, cut_clipboard, void, (void* text_view), 1, text_view);
-WRAPPER(GtkTextView3, copy_clipboard, void, (void* text_view), 1, text_view);
-WRAPPER(GtkTextView3, paste_clipboard, void, (void* text_view), 1, text_view);
-WRAPPER(GtkTextView3, toggle_overwrite, void, (void* text_view), 1, text_view);
-WRAPPER(GtkTextView3, create_buffer, void*, (void* text_view), 1, text_view);
-WRAPPER(GtkTextView3, draw_layer, void, (void* text_view, int layer, void* cr), 3, text_view, layer, cr);
-WRAPPER(GtkTextView3, extend_selection, int, (void* text_view, int granularity, void* location, void* start, void* end), 5, text_view, granularity, location, start, end);
-WRAPPER(GtkTextView3, insert_emoji, void, (void* text_view), 1, text_view);
+WRAPPER(GtkTextView3, populate_popup, void, (void* text_view, void* menu), "pp", text_view, menu);
+WRAPPER(GtkTextView3, move_cursor, void, (void* text_view, int step, int count, int extend_selection), "piii", text_view, step, count, extend_selection);
+WRAPPER(GtkTextView3, set_anchor, void, (void* text_view), "p", text_view);
+WRAPPER(GtkTextView3, insert_at_cursor, void, (void* text_view, void* str), "pp", text_view, str);
+WRAPPER(GtkTextView3, delete_from_cursor, void, (void* text_view, int type, int count), "pii", text_view, type, count);
+WRAPPER(GtkTextView3, backspace, void, (void* text_view), "p", text_view);
+WRAPPER(GtkTextView3, cut_clipboard, void, (void* text_view), "p", text_view);
+WRAPPER(GtkTextView3, copy_clipboard, void, (void* text_view), "p", text_view);
+WRAPPER(GtkTextView3, paste_clipboard, void, (void* text_view), "p", text_view);
+WRAPPER(GtkTextView3, toggle_overwrite, void, (void* text_view), "p", text_view);
+WRAPPER(GtkTextView3, create_buffer, void*, (void* text_view), "p", text_view);
+WRAPPER(GtkTextView3, draw_layer, void, (void* text_view, int layer, void* cr), "pip", text_view, layer, cr);
+WRAPPER(GtkTextView3, extend_selection, int, (void* text_view, int granularity, void* location, void* start, void* end), "pippp", text_view, granularity, location, start, end);
+WRAPPER(GtkTextView3, insert_emoji, void, (void* text_view), "p", text_view);
#define SUPERGO() \
GO(populate_popup, vFpp); \
@@ -1574,7 +2008,7 @@ static void wrapGtkTextView3Class(my_GtkTextView3Class_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGtkTextView3Class(my_GtkTextView3Class_t* class)
-{
+{
unwrapGtkContainer3Class(&class->parent_class);
#define GO(A, W) class->A = find_##A##_GtkTextView3 (class->A)
SUPERGO()
@@ -1591,34 +2025,207 @@ static void bridgeGtkTextView3Class(my_GtkTextView3Class_t* class)
#undef SUPERGO
+// ----- GtkGrid3Class ------
+// no wrapper x86 -> natives of callbacks
+
+#define SUPERGO() \
+
+// wrap (so bridge all calls, just in case)
+static void wrapGtkGrid3Class(my_GtkGrid3Class_t* class)
+{
+ wrapGtkContainer3Class(&class->parent_class);
+ #define GO(A, W) class->A = reverse_##A##_GtkGrid3 (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+// unwrap (and use callback if not a native call anymore)
+static void unwrapGtkGrid3Class(my_GtkGrid3Class_t* class)
+{
+ unwrapGtkContainer3Class(&class->parent_class);
+ #define GO(A, W) class->A = find_##A##_GtkGrid3 (class->A)
+ SUPERGO()
+ #undef GO
+}
+// autobridge
+static void bridgeGtkGrid3Class(my_GtkGrid3Class_t* class)
+{
+ bridgeGtkContainer3Class(&class->parent_class);
+ #define GO(A, W) autobridge_##A##_GtkGrid3 (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+
+#undef SUPERGO
+
+// ----- GtkEventControllerClass ------
+// wrapper x86 -> natives of callbacks
+WRAPPER(GtkEventController, set_widget, void, (void* controller, void* widget), "pp", controller, widget);
+WRAPPER(GtkEventController, unset_widget, void, (void* controller), "p", controller);
+WRAPPER(GtkEventController, handle_event, int, (void *controller, void *event, double x, double y), "ppdd", controller, event, x, y);
+WRAPPER(GtkEventController, reset, void, (void* controller), "p", controller);
+WRAPPER(GtkEventController, handle_crossing, void, (void *controller, void *crossing, double x, double y), "ppdd", controller, crossing, x, y);
+WRAPPER(GtkEventController, filter_event, void, (void *controller, void *event), "pp", controller, event);
+
+#define SUPERGO() \
+ GO(set_widget, vFpp); \
+ GO(unset_widget, vFp); \
+ GO(handle_event, iFppdd); \
+ GO(reset, vFp); \
+ GO(handle_crossing, vFppdd);\
+ GO(filter_event, vFpp);
+
+// wrap (so bridge all calls, just in case)
+static void wrapGtkEventControllerClass(my_GtkEventControllerClass_t* class)
+{
+ wrapGObjectClass(&class->parent_class);
+ #define GO(A, W) class->A = reverse_##A##_GtkEventController(W, class->A)
+ SUPERGO()
+ #undef GO
+}
+// unwrap (and use callback if not a native call anymore)
+static void unwrapGtkEventControllerClass(my_GtkEventControllerClass_t* class)
+{
+ unwrapGObjectClass(&class->parent_class);
+ #define GO(A, W) class->A = find_##A##_GtkEventController (class->A)
+ SUPERGO()
+ #undef GO
+}
+// autobridge
+static void bridgeGtkEventControllerClass(my_GtkEventControllerClass_t* class)
+{
+ bridgeGObjectClass(&class->parent_class);
+ #define GO(A, W) autobridge_##A##_GtkEventController (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+
+#undef SUPERGO
+
+// ----- GtkGestureClass ------
+// wrapper x86 -> natives of callbacks
+WRAPPER(GtkGesture, check, void, (void* gesture), "p", gesture);
+WRAPPER(GtkGesture, begin, void, (void *gesture, void *sequence), "pp", gesture, sequence);
+WRAPPER(GtkGesture, update, void, (void *gesture, void *sequence), "pp", gesture, sequence);
+WRAPPER(GtkGesture, end, void, (void *gesture, void *sequence), "pp", gesture, sequence);
+WRAPPER(GtkGesture, cancel, void, (void *gesture, void *sequence), "pp", gesture, sequence);
+WRAPPER(GtkGesture, sequence_state_changed, void, (void *gesture, void *sequence, int state), "ppi", gesture, sequence, state);
+
+#define SUPERGO() \
+ GO(check, vFp); \
+ GO(begin, vFpp); \
+ GO(update, vFpp); \
+ GO(end, vFpp); \
+ GO(cancel, vFpp); \
+ GO(sequence_state_changed, vFppi);
+
+// wrap (so bridge all calls, just in case)
+static void wrapGtkGestureClass(my_GtkGestureClass_t* class)
+{
+ wrapGtkEventControllerClass(&class->parent_class);
+ #define GO(A, W) class->A = reverse_##A##_GtkGesture(W, class->A)
+ SUPERGO()
+ #undef GO
+}
+// unwrap (and use callback if not a native call anymore)
+static void unwrapGtkGestureClass(my_GtkGestureClass_t* class)
+{
+ unwrapGtkEventControllerClass(&class->parent_class);
+ #define GO(A, W) class->A = find_##A##_GtkGesture (class->A)
+ SUPERGO()
+ #undef GO
+}
+// autobridge
+static void bridgeGtkGestureClass(my_GtkGestureClass_t* class)
+{
+ bridgeGtkEventControllerClass(&class->parent_class);
+ #define GO(A, W) autobridge_##A##_GtkGesture (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+
+#undef SUPERGO
+
+// ----- GtkGestureSingleClass ------
+// wrap (so bridge all calls, just in case)
+static void wrapGtkGestureSingleClass(my_GtkGestureSingleClass_t* class)
+{
+ wrapGtkGestureClass(&class->parent_class);
+}
+// unwrap (and use callback if not a native call anymore)
+static void unwrapGtkGestureSingleClass(my_GtkGestureSingleClass_t* class)
+{
+ unwrapGtkGestureClass(&class->parent_class);
+}
+// autobridge
+static void bridgeGtkGestureSingleClass(my_GtkGestureSingleClass_t* class)
+{
+ bridgeGtkGestureClass(&class->parent_class);
+}
+
+// ----- GtkGestureClass ------
+// wrapper x86 -> natives of callbacks
+WRAPPER(GtkGestureLongPress, pressed, void, (void *gesture, double x, double y), "pdd", gesture, x, y);
+WRAPPER(GtkGestureLongPress, cancelled, void, (void *cancelled), "p", cancelled);
+
+#define SUPERGO() \
+ GO(pressed, vFpdd); \
+ GO(cancelled, vFp);
+
+// wrap (so bridge all calls, just in case)
+static void wrapGtkGestureLongPressClass(my_GtkGestureLongPressClass_t* class)
+{
+ wrapGtkGestureSingleClass(&class->parent_class);
+ #define GO(A, W) class->A = reverse_##A##_GtkGestureLongPress(W, class->A)
+ SUPERGO()
+ #undef GO
+}
+// unwrap (and use callback if not a native call anymore)
+static void unwrapGtkGestureLongPressClass(my_GtkGestureLongPressClass_t* class)
+{
+ unwrapGtkGestureSingleClass(&class->parent_class);
+ #define GO(A, W) class->A = find_##A##_GtkGestureLongPress (class->A)
+ SUPERGO()
+ #undef GO
+}
+// autobridge
+static void bridgeGtkGestureLongPressClass(my_GtkGestureLongPressClass_t* class)
+{
+ bridgeGtkGestureSingleClass(&class->parent_class);
+ #define GO(A, W) autobridge_##A##_GtkGestureLongPress (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+
+#undef SUPERGO
+
// ----- AtkObjectClass ------
// wrapper x86 -> natives of callbacks
-WRAPPER(AtkObject, get_name, void*, (void* accessible), 1, accessible);
-WRAPPER(AtkObject, get_description, void*, (void* accessible), 1, accessible);
-WRAPPER(AtkObject, get_parent, void*, (void* accessible), 1, accessible);
-WRAPPER(AtkObject, get_n_children, int, (void* accessible), 1, accessible);
-WRAPPER(AtkObject, ref_child, void*, (void* accessible, int i), 2, accessible, i);
-WRAPPER(AtkObject, get_index_in_parent, int, (void* accessible), 1, accessible);
-WRAPPER(AtkObject, ref_relation_set, void*, (void* accessible), 1, accessible);
-WRAPPER(AtkObject, get_role, int, (void* accessible), 1, accessible);
-WRAPPER(AtkObject, get_layer, int, (void* accessible), 1, accessible);
-WRAPPER(AtkObject, get_mdi_zorder, int, (void* accessible), 1, accessible);
-WRAPPER(AtkObject, ref_state_set, void*, (void* accessible), 1, accessible);
-WRAPPER(AtkObject, set_name, void, (void* accessible, void* name), 2, accessible, name);
-WRAPPER(AtkObject, set_description, void, (void* accessible, void* description), 2, accessible, description);
-WRAPPER(AtkObject, set_parent, void, (void* accessible, void* parent), 2, accessible, parent);
-WRAPPER(AtkObject, set_role, void, (void* accessible, int role), 2, accessible, role);
-WRAPPER(AtkObject, connect_property_change_handler, uint32_t, (void* accessible, void* handler), 2, accessible, AddCheckBridge(my_bridge, vFpp, handler, 0, NULL));
-WRAPPER(AtkObject, remove_property_change_handler, void, (void* accessible, uint32_t handler_id), 2, accessible, handler_id);
-WRAPPER(AtkObject, initialize, void, (void* accessible, void* data), 2, accessible, data);
-WRAPPER(AtkObject, children_changed, void, (void* accessible, uint32_t change_index, void* changed_child), 3, accessible, change_index, changed_child);
-WRAPPER(AtkObject, focus_event, void, (void* accessible, int focus_in), 2, accessible, focus_in);
-WRAPPER(AtkObject, property_change, void, (void* accessible, void* values), 2, accessible, values);
-WRAPPER(AtkObject, state_change, void, (void* accessible, void* name, int state_set), 3, accessible, name, state_set);
-WRAPPER(AtkObject, visible_data_changed, void, (void* accessible), 1, accessible);
-WRAPPER(AtkObject, active_descendant_changed, void, (void* accessible, void* child), 2, accessible, child);
-WRAPPER(AtkObject, get_attributes, void*, (void* accessible), 1, accessible);
-WRAPPER(AtkObject, get_object_locale, void*, (void* accessible), 1, accessible);
+WRAPPER(AtkObject, get_name, void*, (void* accessible), "p", accessible);
+WRAPPER(AtkObject, get_description, void*, (void* accessible), "p", accessible);
+WRAPPER(AtkObject, get_parent, void*, (void* accessible), "p", accessible);
+WRAPPER(AtkObject, get_n_children, int, (void* accessible), "p", accessible);
+WRAPPER(AtkObject, ref_child, void*, (void* accessible, int i), "pi", accessible, i);
+WRAPPER(AtkObject, get_index_in_parent, int, (void* accessible), "p", accessible);
+WRAPPER(AtkObject, ref_relation_set, void*, (void* accessible), "p", accessible);
+WRAPPER(AtkObject, get_role, int, (void* accessible), "p", accessible);
+WRAPPER(AtkObject, get_layer, int, (void* accessible), "p", accessible);
+WRAPPER(AtkObject, get_mdi_zorder, int, (void* accessible), "p", accessible);
+WRAPPER(AtkObject, ref_state_set, void*, (void* accessible), "p", accessible);
+WRAPPER(AtkObject, set_name, void, (void* accessible, void* name), "pp", accessible, name);
+WRAPPER(AtkObject, set_description, void, (void* accessible, void* description), "pp", accessible, description);
+WRAPPER(AtkObject, set_parent, void, (void* accessible, void* parent), "pp", accessible, parent);
+WRAPPER(AtkObject, set_role, void, (void* accessible, int role), "pi", accessible, role);
+WRAPPER(AtkObject, connect_property_change_handler, uint32_t, (void* accessible, void* handler), "pp", accessible, AddCheckBridge(my_bridge, vFpp, handler, 0, NULL));
+WRAPPER(AtkObject, remove_property_change_handler, void, (void* accessible, uint32_t handler_id), "pu", accessible, handler_id);
+WRAPPER(AtkObject, initialize, void, (void* accessible, void* data), "pp", accessible, data);
+WRAPPER(AtkObject, children_changed, void, (void* accessible, uint32_t change_index, void* changed_child), "pup", accessible, change_index, changed_child);
+WRAPPER(AtkObject, focus_event, void, (void* accessible, int focus_in), "pi", accessible, focus_in);
+WRAPPER(AtkObject, property_change, void, (void* accessible, void* values), "pp", accessible, values);
+WRAPPER(AtkObject, state_change, void, (void* accessible, void* name, int state_set), "ppi", accessible, name, state_set);
+WRAPPER(AtkObject, visible_data_changed, void, (void* accessible), "p", accessible);
+WRAPPER(AtkObject, active_descendant_changed, void, (void* accessible, void* child), "pp", accessible, child);
+WRAPPER(AtkObject, get_attributes, void*, (void* accessible), "p", accessible);
+WRAPPER(AtkObject, get_object_locale, void*, (void* accessible), "p", accessible);
#define SUPERGO() \
GO(get_name, pFp); \
@@ -1658,7 +2265,7 @@ static void wrapAtkObjectClass(my_AtkObjectClass_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapAtkObjectClass(my_AtkObjectClass_t* class)
-{
+{
unwrapGObjectClass(&class->parent);
#define GO(A, W) class->A = find_##A##_AtkObject (class->A)
SUPERGO()
@@ -1677,13 +2284,13 @@ static void bridgeAtkObjectClass(my_AtkObjectClass_t* class)
// ----- AtkUtilClass ------
// wrapper x86 -> natives of callbacks
-WRAPPER(AtkUtil,add_global_event_listener, uint32_t,(void* listener, void* event_type), 2, AddCheckBridge(my_bridge, iFpupp, listener, 0, NULL), event_type);
-WRAPPER(AtkUtil,remove_global_event_listener, void ,(uint32_t listener_id), 1, listener_id);
-WRAPPER(AtkUtil,add_key_event_listener, uint32_t ,(void* listener, void* data), 2, AddCheckBridge(my_bridge, iFpp, listener, 0, NULL), data);
-WRAPPER(AtkUtil,remove_key_event_listener, void ,(uint32_t listener_id), 1, listener_id);
-WRAPPER(AtkUtil,get_root, void* ,(void), 0, 0);
-WRAPPER(AtkUtil,get_toolkit_name, void* ,(void), 0, 0);
-WRAPPER(AtkUtil,get_toolkit_version, void* ,(void), 0, 0);
+WRAPPER(AtkUtil,add_global_event_listener, uint32_t,(void* listener, void* event_type), "pp", AddCheckBridge(my_bridge, iFpupp, listener, 0, NULL), event_type);
+WRAPPER(AtkUtil,remove_global_event_listener, void ,(uint32_t listener_id), "u", listener_id);
+WRAPPER(AtkUtil,add_key_event_listener, uint32_t ,(void* listener, void* data), "pp", AddCheckBridge(my_bridge, iFpp, listener, 0, NULL), data);
+WRAPPER(AtkUtil,remove_key_event_listener, void ,(uint32_t listener_id), "u", listener_id);
+WRAPPER(AtkUtil,get_root, void* ,(void), "", 0);
+WRAPPER(AtkUtil,get_toolkit_name, void* ,(void), "", 0);
+WRAPPER(AtkUtil,get_toolkit_version, void* ,(void), "", 0);
#define SUPERGO() \
GO(add_global_event_listener, uFpp); \
@@ -1704,7 +2311,7 @@ static void wrapAtkUtilClass(my_AtkUtilClass_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapAtkUtilClass(my_AtkUtilClass_t* class)
-{
+{
unwrapGObjectClass(&class->parent);
#define GO(A, W) class->A = find_##A##_AtkUtil (class->A)
SUPERGO()
@@ -1723,7 +2330,7 @@ static void bridgeAtkUtilClass(my_AtkUtilClass_t* class)
// ----- GstObjectClass ------
// wrapper x86 -> natives of callbacks
-WRAPPER(GstObject, deep_notify, void, (void* object, void* origin, void* pspec), 3, object, origin, pspec);
+WRAPPER(GstObject, deep_notify, void, (void* object, void* origin, void* pspec), "ppp", object, origin, pspec);
#define SUPERGO() \
GO(deep_notify, vFppp); \
@@ -1738,7 +2345,7 @@ static void wrapGstObjectClass(my_GstObjectClass_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGstObjectClass(my_GstObjectClass_t* class)
-{
+{
unwrapGInitiallyUnownedClass(&class->parent);
#define GO(A, W) class->A = find_##A##_GstObject (class->A)
SUPERGO()
@@ -1757,8 +2364,8 @@ static void bridgeGstObjectClass(my_GstObjectClass_t* class)
// ----- GstAllocatorClass ------
// wrapper x86 -> natives of callbacks
-WRAPPER(GstAllocator, alloc, void*, (void *allocator, size_t size, void *params), 3, allocator, size, params);
-WRAPPER(GstAllocator,free, void, (void *allocator, void *memory), 2, allocator, memory);
+WRAPPER(GstAllocator, alloc, void*, (void *allocator, size_t size, void *params), "pLp", allocator, size, params);
+WRAPPER(GstAllocator,free, void, (void *allocator, void *memory), "pp", allocator, memory);
#define SUPERGO() \
GO(alloc, pFpLp); \
@@ -1774,7 +2381,7 @@ static void wrapGstAllocatorClass(my_GstAllocatorClass_t* class)
}
// unwrap (and use callback if not a native call anymore)
static void unwrapGstAllocatorClass(my_GstAllocatorClass_t* class)
-{
+{
unwrapGstObjectClass(&class->parent);
#define GO(A, W) class->A = find_##A##_GstAllocator (class->A)
SUPERGO()
@@ -1791,6 +2398,84 @@ static void bridgeGstAllocatorClass(my_GstAllocatorClass_t* class)
#undef SUPERGO
+// ----- GstTaskPoolClass ------
+// wrapper x86 -> natives of callbacks
+WRAPPER(GstTaskPool, prepare, void, (void* pool, void* error), "pp", pool, error);
+WRAPPER(GstTaskPool, cleanup, void, (void* pool), "p", pool);
+WRAPPER(GstTaskPool, push, void*, (void* pool, void* func, void* user_data, void* error), "pppp", pool, AddCheckBridge(my_bridge, vFp, func, 0, NULL), user_data, error);
+WRAPPER(GstTaskPool, join, void, (void* pool, void* id), "pp", pool, id);
+WRAPPER(GstTaskPool, dispose_handle, void, (void* pool, void* id), "pp", pool, id);
+
+#define SUPERGO() \
+ GO(prepare, vFpp); \
+ GO(cleanup, vFp); \
+ GO(push, pFpppp); \
+ GO(join, vFpp); \
+ GO(dispose_handle, vFpp); \
+
+// wrap (so bridge all calls, just in case)
+static void wrapGstTaskPoolClass(my_GstTaskPoolClass_t* class)
+{
+ wrapGstObjectClass(&class->parent_class);
+ #define GO(A, W) class->A = reverse_##A##_GstTaskPool (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+// unwrap (and use callback if not a native call anymore)
+static void unwrapGstTaskPoolClass(my_GstTaskPoolClass_t* class)
+{
+ unwrapGstObjectClass(&class->parent_class);
+ #define GO(A, W) class->A = find_##A##_GstTaskPool (class->A)
+ SUPERGO()
+ #undef GO
+}
+// autobridge
+static void bridgeGstTaskPoolClass(my_GstTaskPoolClass_t* class)
+{
+ bridgeGstObjectClass(&class->parent_class);
+ #define GO(A, W) autobridge_##A##_GstTaskPool (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+
+#undef SUPERGO
+
+// ----- GDBusProxyClass ------
+// wrapper x86 -> natives of callbacks
+WRAPPER(GDBusProxy, g_properties_changed, void, (void* proxy, void* changed_properties, const char* const* invalidated_properties), "ppp", proxy, changed_properties, invalidated_properties);
+WRAPPER(GDBusProxy, g_signal, void, (void* proxy, const char* sender_name, const char* signal_name, void* parameters), "pppp", proxy, sender_name, signal_name, parameters);
+
+#define SUPERGO() \
+ GO(g_properties_changed, vFppp);\
+ GO(g_signal, vFpppp); \
+
+// wrap (so bridge all calls, just in case)
+static void wrapGDBusProxyClass(my_GDBusProxyClass_t* class)
+{
+ wrapGObjectClass(&class->parent_class);
+ #define GO(A, W) class->A = reverse_##A##_GDBusProxy (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+// unwrap (and use callback if not a native call anymore)
+static void unwrapGDBusProxyClass(my_GDBusProxyClass_t* class)
+{
+ unwrapGObjectClass(&class->parent_class);
+ #define GO(A, W) class->A = find_##A##_GDBusProxy (class->A)
+ SUPERGO()
+ #undef GO
+}
+// autobridge
+static void bridgeGDBusProxyClass(my_GDBusProxyClass_t* class)
+{
+ bridgeGObjectClass(&class->parent_class);
+ #define GO(A, W) autobridge_##A##_GDBusProxy (W, class->A)
+ SUPERGO()
+ #undef GO
+}
+
+#undef SUPERGO
+
// No more wrap/unwrap
#undef WRAPPER
#undef FIND
@@ -1803,11 +2488,12 @@ static void wrapGTKClass(void* cl, size_t type)
#define GTKCLASS(A) \
if(type==my_##A) \
wrap##A##Class((my_##A##Class_t*)cl); \
- else
+ else
printf_log(LOG_DEBUG, "wrapGTKClass(%p, %zd (%s))\n", cl, type, g_type_name(type));
GTKCLASSES()
- {
+ if(type==8) {} // GInterface have no structure
+ else {
if(my_MetaFrames2==-1 && !strcmp(g_type_name(type), "MetaFrames")) {
my_MetaFrames2 = type;
wrapMetaFrames2Class((my_MetaFrames2Class_t*)cl);
@@ -1822,10 +2508,12 @@ static void unwrapGTKClass(void* cl, size_t type)
#define GTKCLASS(A) \
if(type==my_##A) \
unwrap##A##Class((my_##A##Class_t*)cl); \
- else
+ else
printf_log(LOG_DEBUG, "unwrapGTKClass(%p, %zd (%s))\n", cl, type, g_type_name(type));
GTKCLASSES()
+ if(type==8) {} // GInterface have no structure
+ else
{} // else no warning, one is enough...
#undef GTKCLASS
}
@@ -1835,11 +2523,12 @@ static void bridgeGTKClass(void* cl, size_t type)
#define GTKCLASS(A) \
if(type==my_##A) \
bridge##A##Class((my_##A##Class_t*)cl); \
- else
+ else
printf_log(LOG_DEBUG, "bridgeGTKClass(%p, %zd (%s))\n", cl, type, g_type_name(type));
GTKCLASSES()
- {
+ if(type==8) {} // GInterface have no structure
+ else {
printf_log(LOG_NONE, "Warning, AutoBridge GTK Class with unknown class type %zd (%s)\n", type, g_type_name(type));
}
#undef GTKCLASS
@@ -1869,7 +2558,8 @@ void* unwrapCopyGTKClass(void* klass, size_t type)
size_t sz = 0;
#define GTKCLASS(A) if(type==my_##A) sz = sizeof(my_##A##Class_t); else
GTKCLASSES()
- {
+ if(type==8) {} // GInterface have no structure
+ else {
printf_log(LOG_NONE, "Warning, unwrapCopyGTKClass called with unknown class type %zu (%s)\n", type, g_type_name(type));
return klass;
}
@@ -1906,7 +2596,8 @@ void* wrapCopyGTKClass(void* klass, size_t type)
int sz = 0;
#define GTKCLASS(A) if(type==my_##A) sz = sizeof(my_##A##Class_t); else
GTKCLASSES()
- {
+ if(type==8) {} // GInterface have no structure
+ else {
if(my_MetaFrames2==-1 && !strcmp(g_type_name(type), "MetaFrames")) {
my_MetaFrames2 = type;
sz = sizeof(my_MetaFrames2Class_t);
@@ -1941,10 +2632,10 @@ SUPER()
// Then the static functions callback that may be used with the structure
// value_init ...
#define GO(A) \
-static uintptr_t my_value_init_fct_##A = 0; \
-static void my_value_init_##A(void* a) \
-{ \
- RunFunction(my_context, my_value_init_fct_##A, 1, a); \
+static uintptr_t my_value_init_fct_##A = 0; \
+static void my_value_init_##A(void* a) \
+{ \
+ RunFunctionFmt(my_value_init_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -1963,10 +2654,10 @@ static void* find_value_init_Fct(void* fct)
}
// value_free ...
#define GO(A) \
-static uintptr_t my_value_free_fct_##A = 0; \
-static void my_value_free_##A(void* a) \
-{ \
- RunFunction(my_context, my_value_free_fct_##A, 1, a); \
+static uintptr_t my_value_free_fct_##A = 0; \
+static void my_value_free_##A(void* a) \
+{ \
+ RunFunctionFmt(my_value_free_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -1985,10 +2676,10 @@ static void* find_value_free_Fct(void* fct)
}
// value_copy ...
#define GO(A) \
-static uintptr_t my_value_copy_fct_##A = 0; \
-static void my_value_copy_##A(void* a, void* b) \
-{ \
- RunFunction(my_context, my_value_copy_fct_##A, 2, a, b);\
+static uintptr_t my_value_copy_fct_##A = 0; \
+static void my_value_copy_##A(void* a, void* b) \
+{ \
+ RunFunctionFmt(my_value_copy_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -2007,10 +2698,10 @@ static void* find_value_copy_Fct(void* fct)
}
// value_peek_pointer ...
#define GO(A) \
-static uintptr_t my_value_peek_pointer_fct_##A = 0; \
-static void* my_value_peek_pointer_##A(void* a) \
-{ \
- return (void*)RunFunction(my_context, my_value_peek_pointer_fct_##A, 1, a); \
+static uintptr_t my_value_peek_pointer_fct_##A = 0; \
+static void* my_value_peek_pointer_##A(void* a) \
+{ \
+ return (void*)RunFunctionFmt(my_value_peek_pointer_fct_##A, "p", a);\
}
SUPER()
#undef GO
@@ -2029,10 +2720,10 @@ static void* find_value_peek_pointer_Fct(void* fct)
}
// collect_value ...
#define GO(A) \
-static uintptr_t my_collect_value_fct_##A = 0; \
-static void* my_collect_value_##A(void* a, uint32_t b, void* c, uint32_t d) \
-{ \
- return (void*)RunFunction(my_context, my_collect_value_fct_##A, 4, a, b, c, d); \
+static uintptr_t my_collect_value_fct_##A = 0; \
+static void* my_collect_value_##A(void* a, uint32_t b, void* c, uint32_t d) \
+{ \
+ return (void*)RunFunctionFmt(my_collect_value_fct_##A, "pupu", a, b, c, d); \
}
SUPER()
#undef GO
@@ -2051,10 +2742,10 @@ static void* find_collect_value_Fct(void* fct)
}
// lcopy_value ...
#define GO(A) \
-static uintptr_t my_lcopy_value_fct_##A = 0; \
-static void* my_lcopy_value_##A(void* a, uint32_t b, void* c, uint32_t d) \
-{ \
- return (void*)RunFunction(my_context, my_lcopy_value_fct_##A, 4, a, b, c, d); \
+static uintptr_t my_lcopy_value_fct_##A = 0; \
+static void* my_lcopy_value_##A(void* a, uint32_t b, void* c, uint32_t d) \
+{ \
+ return (void*)RunFunctionFmt(my_lcopy_value_fct_##A, "pupu", a, b, c, d); \
}
SUPER()
#undef GO
@@ -2098,10 +2789,10 @@ my_GTypeValueTable_t* findFreeGTypeValueTable(my_GTypeValueTable_t* fcts)
// signal2 ...
#define GO(A) \
-static uintptr_t my_signal2_fct_##A = 0; \
-static void* my_signal2_##A(void* a, void* b) \
-{ \
- return (void*)RunFunction(my_context, my_signal2_fct_##A, 2, a, b); \
+static uintptr_t my_signal2_fct_##A = 0; \
+static void* my_signal2_##A(void* a, void* b) \
+{ \
+ return (void*)RunFunctionFmt(my_signal2_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -2120,10 +2811,10 @@ static void* find_signal2_Fct(void* fct)
}
// signal3 ...
#define GO(A) \
-static uintptr_t my_signal3_fct_##A = 0; \
-static void* my_signal3_##A(void* a, void* b, void* c) \
-{ \
- return (void*)RunFunction(my_context, my_signal3_fct_##A, 3, a, b, c); \
+static uintptr_t my_signal3_fct_##A = 0; \
+static void* my_signal3_##A(void* a, void* b, void* c) \
+{ \
+ return (void*)RunFunctionFmt(my_signal3_fct_##A, "ppp", a, b, c); \
}
SUPER()
#undef GO
@@ -2142,10 +2833,10 @@ static void* find_signal3_Fct(void* fct)
}
// signal4 ...
#define GO(A) \
-static uintptr_t my_signal4_fct_##A = 0; \
-static void* my_signal4_##A(void* a, void* b, void* c, void* d) \
-{ \
- return (void*)RunFunction(my_context, my_signal4_fct_##A, 4, a, b, c, d); \
+static uintptr_t my_signal4_fct_##A = 0; \
+static void* my_signal4_##A(void* a, void* b, void* c, void* d) \
+{ \
+ return (void*)RunFunctionFmt(my_signal4_fct_##A, "pppp", a, b, c, d); \
}
SUPER()
#undef GO
@@ -2164,10 +2855,10 @@ static void* find_signal4_Fct(void* fct)
}
// signal5 ...
#define GO(A) \
-static uintptr_t my_signal5_fct_##A = 0; \
-static void* my_signal5_##A(void* a, void* b, void* c, void* d, void* e) \
-{ \
- return (void*)RunFunction(my_context, my_signal5_fct_##A, 5, a, b, c, d, e);\
+static uintptr_t my_signal5_fct_##A = 0; \
+static void* my_signal5_##A(void* a, void* b, void* c, void* d, void* e) \
+{ \
+ return (void*)RunFunctionFmt(my_signal5_fct_##A, "ppppp", a, b, c, d, e); \
}
SUPER()
#undef GO
@@ -2186,10 +2877,10 @@ static void* find_signal5_Fct(void* fct)
}
// signal6 ...
#define GO(A) \
-static uintptr_t my_signal6_fct_##A = 0; \
-static void* my_signal6_##A(void* a, void* b, void* c, void* d, void* e, void* f) \
-{ \
- return (void*)RunFunction(my_context, my_signal6_fct_##A, 6, a, b, c, d, e, f); \
+static uintptr_t my_signal6_fct_##A = 0; \
+static void* my_signal6_##A(void* a, void* b, void* c, void* d, void* e, void* f) \
+{ \
+ return (void*)RunFunctionFmt(my_signal6_fct_##A, "pppppp", a, b, c, d, e, f); \
}
SUPER()
#undef GO
@@ -2208,10 +2899,10 @@ static void* find_signal6_Fct(void* fct)
}
// signal7 ...
#define GO(A) \
-static uintptr_t my_signal7_fct_##A = 0; \
-static void* my_signal7_##A(void* a, void* b, void* c, void* d, void* e, void* f, void* g) \
-{ \
- return (void*)RunFunction(my_context, my_signal7_fct_##A, 7, a, b, c, d, e, f, g); \
+static uintptr_t my_signal7_fct_##A = 0; \
+static void* my_signal7_##A(void* a, void* b, void* c, void* d, void* e, void* f, void* g) \
+{ \
+ return (void*)RunFunctionFmt(my_signal7_fct_##A, "ppppppp", a, b, c, d, e, f, g); \
}
SUPER()
#undef GO
@@ -2300,7 +2991,7 @@ SUPER()
static uintptr_t my_base_init_fct_##A = 0; \
static int my_base_init_##A(void* a) \
{ \
- return RunFunction(my_context, my_base_init_fct_##A, 1, a); \
+ return RunFunctionFmt(my_base_init_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -2322,7 +3013,7 @@ static void* find_base_init_Fct(void* fct)
static uintptr_t my_base_finalize_fct_##A = 0; \
static int my_base_finalize_##A(void* a) \
{ \
- return RunFunction(my_context, my_base_finalize_fct_##A, 1, a); \
+ return RunFunctionFmt(my_base_finalize_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -2341,21 +3032,21 @@ static void* find_base_finalize_Fct(void* fct)
}
// class_init ...
#define GO(A) \
-static uintptr_t my_class_init_fct_##A = 0; \
-static size_t parent_class_init_##A = 0; \
-static int my_class_init_##A(void* a, void* b) \
-{ \
+static uintptr_t my_class_init_fct_##A = 0; \
+static size_t parent_class_init_##A = 0; \
+static int my_class_init_##A(void* a, void* b) \
+{ \
printf_log(LOG_DEBUG, "Custom Class init %d for class %p (parent=%p:%s)\n", A, a, (void*)parent_class_init_##A, g_type_name(parent_class_init_##A));\
- int ret = RunFunction(my_context, my_class_init_fct_##A, 2, a, b); \
- unwrapGTKClass(a, parent_class_init_##A); \
- bridgeGTKClass(a, parent_class_init_##A); \
- my_unwrap_signal_offset(a); \
- if(!strcmp(g_type_name(parent_class_init_##A), "AtkUtil")) { \
+ int ret = RunFunctionFmt(my_class_init_fct_##A, "pp", a, b);\
+ unwrapGTKClass(a, parent_class_init_##A); \
+ bridgeGTKClass(a, parent_class_init_##A); \
+ my_unwrap_signal_offset(a); \
+ if(!strcmp(g_type_name(parent_class_init_##A), "AtkUtil")) { \
my_AtkUtilClass_t* p = (my_AtkUtilClass_t*)g_type_class_peek(parent_class_init_##A);\
- unwrapGTKClass(p, parent_class_init_##A); \
- bridgeGTKClass(p, parent_class_init_##A); \
- } \
- return ret; \
+ unwrapGTKClass(p, parent_class_init_##A); \
+ bridgeGTKClass(p, parent_class_init_##A); \
+ } \
+ return ret; \
}
SUPER()
#undef GO
@@ -2374,10 +3065,10 @@ static void* find_class_init_Fct(void* fct, size_t parent)
}
// class_finalize ...
#define GO(A) \
-static uintptr_t my_class_finalize_fct_##A = 0; \
-static int my_class_finalize_##A(void* a, void* b) \
-{ \
- return RunFunction(my_context, my_class_finalize_fct_##A, 2, a, b); \
+static uintptr_t my_class_finalize_fct_##A = 0; \
+static int my_class_finalize_##A(void* a, void* b) \
+{ \
+ return RunFunctionFmt(my_class_finalize_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -2396,10 +3087,10 @@ static void* find_class_finalize_Fct(void* fct)
}
// instance_init ...
#define GO(A) \
-static uintptr_t my_instance_init_fct_##A = 0; \
-static int my_instance_init_##A(void* a, void* b) \
-{ \
- return RunFunction(my_context, my_instance_init_fct_##A, 2, a, b); \
+static uintptr_t my_instance_init_fct_##A = 0; \
+static int my_instance_init_##A(void* a, void* b) \
+{ \
+ return RunFunctionFmt(my_instance_init_fct_##A, "pp", a, b);\
}
SUPER()
#undef GO
@@ -2459,20 +3150,20 @@ static int fct_gtk_parent_##A = 0 ; \
static uintptr_t fct_gtk_class_init_##A = 0; \
static int my_gtk_class_init_##A(void* g_class) { \
printf_log(LOG_DEBUG, "Calling fct_gtk_class_init_" #A " wrapper\n"); \
- int ret = (int)RunFunction(my_context, fct_gtk_class_init_##A, 1, g_class); \
+ int ret = (int)RunFunctionFmt(fct_gtk_class_init_##A, "p", g_class);\
unwrapGTKClass(g_class, fct_gtk_parent_##A); \
bridgeGTKClass(g_class, fct_gtk_parent_##A); \
return ret; \
} \
-static uintptr_t fct_gtk_object_init_##A = 0; \
-static int my_gtk_object_init_##A(void* object, void* data) { \
- printf_log(LOG_DEBUG, "Calling fct_gtk_object_init_" #A " wrapper\n"); \
- return (int)RunFunction(my_context, fct_gtk_object_init_##A, 2, object, data); \
+static uintptr_t fct_gtk_object_init_##A = 0; \
+static int my_gtk_object_init_##A(void* object, void* data) { \
+ printf_log(LOG_DEBUG, "Calling fct_gtk_object_init_" #A " wrapper\n"); \
+ return (int)RunFunctionFmt(fct_gtk_object_init_##A, "pp", object, data);\
} \
-static uintptr_t fct_gtk_base_class_init_##A = 0; \
-static int my_gtk_base_class_init_##A(void* instance, void* data) { \
- printf_log(LOG_DEBUG, "Calling fct_gtk_base_class_init_" #A " wrapper\n"); \
- return (int)RunFunction(my_context, fct_gtk_base_class_init_##A, 2, instance, data); \
+static uintptr_t fct_gtk_base_class_init_##A = 0; \
+static int my_gtk_base_class_init_##A(void* instance, void* data) { \
+ printf_log(LOG_DEBUG, "Calling fct_gtk_base_class_init_" #A " wrapper\n"); \
+ return (int)RunFunctionFmt(fct_gtk_base_class_init_##A, "pp", instance, data); \
}
SUPER()
@@ -2588,7 +3279,7 @@ void my_signal_delete(my_signal_t* sig)
}
uintptr_t d = sig->destroy;
if(d) {
- RunFunction(my_context, d, 1, sig->data);
+ RunFunctionFmt(d, "p", sig->data);
}
printf_log(LOG_DEBUG, "gtk Data deleted, sig=%p, data=%p, destroy=%p\n", sig, sig->data, (void*)d);
box_free(sig);
@@ -2630,10 +3321,10 @@ int my_signal_cb(void* a, void* b, void* c, void* d)
}
printf_log(LOG_DEBUG, "gtk Signal called, sig=%p, NArgs=%d\n", sig, i);
switch(i) {
- case 1: return (int)RunFunction(my_context, sig->c_handler, 1, sig->data);
- case 2: return (int)RunFunction(my_context, sig->c_handler, 2, a, sig->data);
- case 3: return (int)RunFunction(my_context, sig->c_handler, 3, a, b, sig->data);
- case 4: return (int)RunFunction(my_context, sig->c_handler, 4, a, b, c, sig->data);
+ case 1: return (int)RunFunctionFmt(sig->c_handler, "p", sig->data);
+ case 2: return (int)RunFunctionFmt(sig->c_handler, "pp", a, sig->data);
+ case 3: return (int)RunFunctionFmt(sig->c_handler, "ppp", a, b, sig->data);
+ case 4: return (int)RunFunctionFmt(sig->c_handler, "pppp", a, b, c, sig->data);
}
printf_log(LOG_NONE, "Warning, Gtk signal callback but no data found!");
return 0;
diff --git a/src/tools/my_cpuid.c b/src/tools/my_cpuid.c
index 06b725a..c80a531 100644
--- a/src/tools/my_cpuid.c
+++ b/src/tools/my_cpuid.c
@@ -87,7 +87,9 @@ void my_cpuid(x64emu_t* emu, uint32_t tmp32u)
| 1<<9 // SSSE3
| 1<<12 // fma
| 1<<13 // cx16 (cmpxchg16)
+ | 1<<19 // SSE4_1
| 1<<22 // MOVBE
+ | 1<<23 // POPCOUNT
| 1<<25 // aesni
;
break;
@@ -144,8 +146,10 @@ void my_cpuid(x64emu_t* emu, uint32_t tmp32u)
R_EDX = 0;
break;
case 0x7: // extended bits...
- if(R_ECX==1) R_EAX = 0; // Bit 5 is avx512_bf16
- else R_EAX = R_ECX = R_EBX = R_EDX = 0; // TODO
+ if(R_ECX==1) {
+ R_EAX = 0; // Bit 5 is avx512_bf16
+ } else
+ R_EAX = R_ECX = R_EBX = R_EDX = 0; // TODO
break;
case 0xB: // Extended Topology Enumeration Leaf
//TODO!
diff --git a/src/tools/pathcoll.c b/src/tools/pathcoll.c
index 1ee5572..1ee5572 100755..100644
--- a/src/tools/pathcoll.c
+++ b/src/tools/pathcoll.c
diff --git a/src/tools/rcfile.c b/src/tools/rcfile.c
index 2e99bf2..e41980c 100644
--- a/src/tools/rcfile.c
+++ b/src/tools/rcfile.c
@@ -32,13 +32,22 @@ static const char default_rcfile[] =
"BOX64_CRASHHANDLER=1\n"
"BOX64_DYNAREC_STRONGMEM=1\n"
"\n"
+"[factorio]\n"
+"BOX64_DYNAREC_FASTROUND=0\n"
+"\n"
"[heroic]\n"
"BOX64_NOSANDBOX=1\n"
"BOX64_MALLOC_HACK=2\n"
"\n"
+"[LotCG.x86_64]\n"
+"BOX64_DYNAREC_FASTROUND=0\n"
+"\n"
"[pressure-vessel-wrap]\n"
"BOX64_NOGTK=1\n"
"\n"
+"[Soma.bin.x86_64]\n"
+"BOX64_DYNAREC_FASTROUND=0\n"
+"\n"
"[streaming_client]\n"
"BOX64_EMULATED_LIBS=libSDL2-2.0.so.0:libSDL2_ttf-2.0.so.0\n"
"\n"
@@ -46,7 +55,7 @@ static const char default_rcfile[] =
"BOX64_NOSANDBOX=1\n"
"BOX64_MALLOC_HACK=2\n"
"BOX64_LOG=0\n"
-"BOX64_NOGTK=1\n"
+"BOX64_DYNAREC_BIGBLOCK=0\n"
"\n"
"[steam-runtime-check-requirements]\n"
"BOX64_EXIT=1\n"
@@ -120,10 +129,13 @@ ENTRYBOOL(BOX64_DYNAREC_FASTROUND, box64_dynarec_fastround) \
ENTRYINT(BOX64_DYNAREC_SAFEFLAGS, box64_dynarec_safeflags, 0, 2, 2) \
ENTRYBOOL(BOX64_DYNAREC_CALLRET, box64_dynarec_callret) \
ENTRYBOOL(BOX64_DYNAREC_BLEEDING_EDGE, box64_dynarec_bleeding_edge) \
+ENTRYBOOL(BOX64_DYNAREC_JVM, box64_dynarec_jvm) \
ENTRYINT(BOX64_DYNAREC_HOTPAGE, box64_dynarec_hotpage, 0, 255, 8) \
ENTRYBOOL(BOX64_DYNAREC_FASTPAGE, box64_dynarec_fastpage) \
ENTRYBOOL(BOX64_DYNAREC_WAIT, box64_dynarec_wait) \
ENTRYSTRING_(BOX64_NODYNAREC, box64_nodynarec) \
+ENTRYBOOL(BOX64_DYNAREC_TEST, box64_dynarec_test) \
+ENTRYBOOL(BOX64_DYNAREC_MISSING, box64_dynarec_missing) \
#else
#define SUPER3() \
@@ -139,10 +151,13 @@ IGNORE(BOX64_DYNAREC_FASTROUND) \
IGNORE(BOX64_DYNAREC_SAFEFLAGS) \
IGNORE(BOX64_DYNAREC_CALLRET) \
IGNORE(BOX64_DYNAREC_BLEEDING_EDGE) \
+IGNORE(BOX64_DYNAREC_JVM) \
IGNORE(BOX64_DYNAREC_HOTPAGE) \
IGNORE(BOX64_DYNAREC_FASTPAGE) \
IGNORE(BOX64_DYNAREC_WAIT) \
IGNORE(BOX64_NODYNAREC) \
+IGNORE(BOX64_DYNAREC_TEST) \
+IGNORE(BOX64_DYNAREC_MISSING) \
#endif
diff --git a/src/tools/wine_tools.c b/src/tools/wine_tools.c
index 130ce92..199a0fc 100755..100644
--- a/src/tools/wine_tools.c
+++ b/src/tools/wine_tools.c
@@ -31,8 +31,8 @@ static int get_prereserve(const char* reserve, void** addr, size_t* size)
if(*reserve>='0' && *reserve<='9') r=r*16+(*reserve)-'0';
else if(*reserve>='A' && *reserve<='F') r=r*16+(*reserve)-'A'+10;
else if(*reserve>='a' && *reserve<='f') r=r*16+(*reserve)-'a'+10;
- else if(*reserve=='-') {if(first) {*addr=(void*)(r&~(box64_pagesize-1)); r=0; first=0;} else {printf_log(LOG_NONE, "Warning, Wine prereserve badly formated\n"); return 0;}}
- else {printf_log(LOG_NONE, "Warning, Wine prereserve badly formated\n"); return 0;}
+ else if(*reserve=='-') {if(first) {*addr=(void*)(r&~(box64_pagesize-1)); r=0; first=0;} else {printf_log(LOG_NONE, "Warning, Wine prereserve badly formatted\n"); return 0;}}
+ else {printf_log(LOG_NONE, "Warning, Wine prereserve badly formatted\n"); return 0;}
++reserve;
}
*size = r;
diff --git a/src/wrapped/generated/functions_list.txt b/src/wrapped/generated/functions_list.txt
deleted file mode 100644
index 73f50f8..0000000
--- a/src/wrapped/generated/functions_list.txt
+++ /dev/null
@@ -1,4517 +0,0 @@
-#() vFE
-#() vFv
-#() vFi
-#() vFu
-#() vFU
-#() vFf
-#() vFd
-#() vFl
-#() vFL
-#() vFp
-#() vFS
-#() cFv
-#() cFi
-#() cFu
-#() cFf
-#() cFp
-#() wFp
-#() iFE
-#() iFv
-#() iFw
-#() iFi
-#() iFI
-#() iFC
-#() iFW
-#() iFu
-#() iFU
-#() iFf
-#() iFd
-#() iFD
-#() iFl
-#() iFL
-#() iFp
-#() iFO
-#() iFS
-#() IFv
-#() IFi
-#() IFI
-#() IFf
-#() IFd
-#() IFp
-#() CFC
-#() CFp
-#() WFi
-#() WFW
-#() WFp
-#() uFv
-#() uFi
-#() uFu
-#() uFd
-#() uFl
-#() uFL
-#() uFp
-#() UFv
-#() UFu
-#() UFp
-#() UFV
-#() fFi
-#() fFf
-#() fFp
-#() dFv
-#() dFi
-#() dFu
-#() dFd
-#() dFp
-#() lFE
-#() lFv
-#() lFi
-#() lFu
-#() lFl
-#() lFp
-#() LFv
-#() LFu
-#() LFL
-#() LFp
-#() pFE
-#() pFv
-#() pFw
-#() pFi
-#() pFI
-#() pFC
-#() pFW
-#() pFu
-#() pFU
-#() pFd
-#() pFl
-#() pFL
-#() pFp
-#() pFV
-#() HFi
-#() HFp
-#() vWp
-#() iWp
-#() uWp
-#() fWp
-#() vFEi
-#() vFEp
-#() vFii
-#() vFiI
-#() vFiu
-#() vFiU
-#() vFif
-#() vFid
-#() vFip
-#() vFWW
-#() vFWp
-#() vFui
-#() vFuu
-#() vFuU
-#() vFuf
-#() vFud
-#() vFul
-#() vFup
-#() vFUi
-#() vFfi
-#() vFff
-#() vFfp
-#() vFdd
-#() vFlp
-#() vFLL
-#() vFLp
-#() vFpc
-#() vFpi
-#() vFpI
-#() vFpC
-#() vFpW
-#() vFpu
-#() vFpU
-#() vFpf
-#() vFpd
-#() vFpl
-#() vFpL
-#() vFpp
-#() vFpS
-#() vFSi
-#() cFpp
-#() iFEi
-#() iFEp
-#() iFwp
-#() iFii
-#() iFiu
-#() iFil
-#() iFiL
-#() iFip
-#() iFiS
-#() iFIi
-#() iFui
-#() iFuu
-#() iFuU
-#() iFuL
-#() iFup
-#() iFUp
-#() iFli
-#() iFlp
-#() iFLu
-#() iFLL
-#() iFLp
-#() iFpw
-#() iFpi
-#() iFpI
-#() iFpC
-#() iFpW
-#() iFpu
-#() iFpU
-#() iFpf
-#() iFpd
-#() iFpl
-#() iFpL
-#() iFpp
-#() iFpO
-#() iFSi
-#() IFEp
-#() IFII
-#() IFpi
-#() IFpu
-#() IFpd
-#() CFip
-#() CFui
-#() CFpi
-#() CFpu
-#() CFpp
-#() WFpp
-#() uFEp
-#() uFii
-#() uFiu
-#() uFip
-#() uFui
-#() uFuu
-#() uFup
-#() uFUp
-#() uFpw
-#() uFpi
-#() uFpu
-#() uFpU
-#() uFpf
-#() uFpL
-#() uFpp
-#() UFEp
-#() UFuu
-#() UFUp
-#() UFpi
-#() UFpp
-#() fFEp
-#() fFif
-#() fFfi
-#() fFff
-#() fFfD
-#() fFfl
-#() fFfp
-#() fFpp
-#() dFid
-#() dFdi
-#() dFdd
-#() dFdD
-#() dFdl
-#() dFdp
-#() dFll
-#() dFpi
-#() dFpd
-#() dFpp
-#() DFDi
-#() DFDD
-#() DFDp
-#() DFpp
-#() lFii
-#() lFll
-#() lFpi
-#() lFpl
-#() lFpp
-#() LFEL
-#() LFii
-#() LFuu
-#() LFLi
-#() LFLL
-#() LFpi
-#() LFpL
-#() LFpp
-#() pFEi
-#() pFEL
-#() pFEp
-#() pFii
-#() pFiI
-#() pFiu
-#() pFip
-#() pFiV
-#() pFII
-#() pFui
-#() pFuC
-#() pFuu
-#() pFup
-#() pFUi
-#() pFUU
-#() pFdi
-#() pFdd
-#() pFlp
-#() pFLu
-#() pFLL
-#() pFLp
-#() pFpi
-#() pFpC
-#() pFpu
-#() pFpU
-#() pFpd
-#() pFpl
-#() pFpL
-#() pFpp
-#() pFpV
-#() pFSi
-#() HFII
-#() HFll
-#() HFpi
-#() iWpi
-#() iWpu
-#() iWpf
-#() iWpp
-#() uWpu
-#() pWEp
-#() pWpu
-#() vFEpi
-#() vFEpu
-#() vFEpp
-#() vFEpV
-#() vFEpA
-#() vFiii
-#() vFiiu
-#() vFiif
-#() vFiip
-#() vFiII
-#() vFiui
-#() vFiuu
-#() vFiuU
-#() vFiup
-#() vFiUU
-#() vFiff
-#() vFidd
-#() vFill
-#() vFilp
-#() vFipi
-#() vFipu
-#() vFipp
-#() vFuii
-#() vFuiI
-#() vFuiu
-#() vFuiU
-#() vFuif
-#() vFuid
-#() vFuip
-#() vFuui
-#() vFuuu
-#() vFuuU
-#() vFuuf
-#() vFuud
-#() vFuup
-#() vFuff
-#() vFufp
-#() vFudd
-#() vFull
-#() vFulp
-#() vFuLp
-#() vFupu
-#() vFupp
-#() vFfff
-#() vFfpp
-#() vFddd
-#() vFdpp
-#() vFlip
-#() vFlll
-#() vFllp
-#() vFlpp
-#() vFLup
-#() vFLpL
-#() vFLpp
-#() vFpii
-#() vFpiI
-#() vFpiC
-#() vFpiu
-#() vFpif
-#() vFpid
-#() vFpip
-#() vFpui
-#() vFpuI
-#() vFpuW
-#() vFpuu
-#() vFpuU
-#() vFpup
-#() vFpUi
-#() vFpUu
-#() vFpUU
-#() vFpUf
-#() vFpUp
-#() vFpff
-#() vFpdd
-#() vFpll
-#() vFplp
-#() vFpLi
-#() vFpLu
-#() vFpLL
-#() vFpLp
-#() vFppi
-#() vFppu
-#() vFppU
-#() vFppd
-#() vFppl
-#() vFppL
-#() vFppp
-#() iFEiw
-#() iFEip
-#() iFEWW
-#() iFEup
-#() iFEUU
-#() iFELp
-#() iFEpi
-#() iFEpU
-#() iFEpL
-#() iFEpp
-#() iFEpV
-#() iFEpA
-#() iFESp
-#() iFwww
-#() iFwpp
-#() iFiwC
-#() iFiii
-#() iFiiu
-#() iFiil
-#() iFiip
-#() iFiiO
-#() iFiuu
-#() iFill
-#() iFiLi
-#() iFiLp
-#() iFiLN
-#() iFipi
-#() iFipu
-#() iFipL
-#() iFipp
-#() iFipO
-#() iFCiW
-#() iFuwp
-#() iFuip
-#() iFuui
-#() iFuuu
-#() iFuup
-#() iFuUu
-#() iFuff
-#() iFuLL
-#() iFuLp
-#() iFupL
-#() iFupp
-#() iFfff
-#() iFlip
-#() iFLip
-#() iFLLi
-#() iFLpp
-#() iFpwp
-#() iFpii
-#() iFpiI
-#() iFpiu
-#() iFpiU
-#() iFpiL
-#() iFpip
-#() iFpIi
-#() iFpII
-#() iFpCp
-#() iFpui
-#() iFpuu
-#() iFpuU
-#() iFpuL
-#() iFpup
-#() iFpUi
-#() iFpUu
-#() iFpUU
-#() iFpUp
-#() iFpfu
-#() iFpff
-#() iFpdd
-#() iFpli
-#() iFpll
-#() iFplp
-#() iFpLi
-#() iFpLu
-#() iFpLL
-#() iFpLp
-#() iFppi
-#() iFppI
-#() iFppC
-#() iFppW
-#() iFppu
-#() iFppU
-#() iFppd
-#() iFppl
-#() iFppL
-#() iFppp
-#() iFpOu
-#() iFpOM
-#() iFSpL
-#() IFiIi
-#() IFpIi
-#() IFppi
-#() IFppI
-#() IFppu
-#() IFSIi
-#() uFEpW
-#() uFEpu
-#() uFEpU
-#() uFEpp
-#() uFipu
-#() uFuip
-#() uFuuu
-#() uFuup
-#() uFufp
-#() uFupu
-#() uFupp
-#() uFpii
-#() uFpip
-#() uFpCi
-#() uFpWi
-#() uFpWu
-#() uFpWf
-#() uFpWp
-#() uFpui
-#() uFpuC
-#() uFpuu
-#() uFpup
-#() uFpfu
-#() uFpLp
-#() uFppi
-#() uFppu
-#() uFppp
-#() UFUUU
-#() UFpiU
-#() UFppi
-#() UFppu
-#() fFull
-#() fFfff
-#() fFffp
-#() fFppi
-#() fFppL
-#() fFppp
-#() dFddd
-#() dFddp
-#() dFpdd
-#() dFppi
-#() dFppp
-#() DFppi
-#() DFppp
-#() lFili
-#() lFilL
-#() lFipi
-#() lFipL
-#() lFlll
-#() lFpli
-#() lFpLu
-#() lFpLp
-#() lFppi
-#() lFppL
-#() lFppp
-#() lFSpl
-#() LFEpA
-#() LFipL
-#() LFLLl
-#() LFLpu
-#() LFLpL
-#() LFpii
-#() LFpip
-#() LFpLi
-#() LFpLp
-#() LFppi
-#() LFppL
-#() LFppp
-#() LFSpL
-#() pFEip
-#() pFEiV
-#() pFEup
-#() pFEuV
-#() pFEpi
-#() pFEpu
-#() pFEpp
-#() pFEpV
-#() pFEpA
-#() pFiii
-#() pFiiu
-#() pFiip
-#() pFiIi
-#() pFiIp
-#() pFipi
-#() pFipL
-#() pFipp
-#() pFIpi
-#() pFCiW
-#() pFWWW
-#() pFuii
-#() pFuui
-#() pFuuu
-#() pFupi
-#() pFupL
-#() pFUpi
-#() pFdip
-#() pFdUU
-#() pFddd
-#() pFDip
-#() pFLup
-#() pFLLp
-#() pFpii
-#() pFpiu
-#() pFpid
-#() pFpil
-#() pFpiL
-#() pFpip
-#() pFpCC
-#() pFpCu
-#() pFpWW
-#() pFpui
-#() pFpuu
-#() pFpuL
-#() pFpup
-#() pFpUi
-#() pFpUp
-#() pFpdu
-#() pFplC
-#() pFplu
-#() pFpll
-#() pFplp
-#() pFpLu
-#() pFpLL
-#() pFpLp
-#() pFppi
-#() pFppI
-#() pFppC
-#() pFppu
-#() pFppU
-#() pFppf
-#() pFppl
-#() pFppL
-#() pFppp
-#() pFpOM
-#() pFSpl
-#() vWpup
-#() iWEip
-#() iWEpp
-#() iWpiu
-#() iWpip
-#() iWpui
-#() iWpuu
-#() iWpup
-#() iWppu
-#() iWppp
-#() uWpui
-#() uWpup
-#() vFEiip
-#() vFEipp
-#() vFEipV
-#() vFEipA
-#() vFELLp
-#() vFEpii
-#() vFEpip
-#() vFEpiA
-#() vFEpup
-#() vFEpUp
-#() vFEppp
-#() vFEppV
-#() vFEppA
-#() vFiiii
-#() vFiiip
-#() vFiill
-#() vFiIII
-#() vFiuiu
-#() vFiuip
-#() vFiuuu
-#() vFiuup
-#() vFiulp
-#() vFiupu
-#() vFiupV
-#() vFiUUU
-#() vFifff
-#() vFiddd
-#() vFilil
-#() vFilip
-#() vFiluU
-#() vFilpu
-#() vFilpp
-#() vFipii
-#() vFipup
-#() vFipll
-#() vFippi
-#() vFippu
-#() vFippp
-#() vFuiii
-#() vFuiiu
-#() vFuiip
-#() vFuiII
-#() vFuiui
-#() vFuiuu
-#() vFuiup
-#() vFuiUU
-#() vFuifi
-#() vFuiff
-#() vFuidd
-#() vFuill
-#() vFuilp
-#() vFuipi
-#() vFuipu
-#() vFuipp
-#() vFuuii
-#() vFuuiu
-#() vFuuil
-#() vFuuip
-#() vFuuui
-#() vFuuuu
-#() vFuuuf
-#() vFuuud
-#() vFuuup
-#() vFuulp
-#() vFuupi
-#() vFuupp
-#() vFuUii
-#() vFuUip
-#() vFufff
-#() vFuddd
-#() vFulil
-#() vFulip
-#() vFuluU
-#() vFullp
-#() vFulpi
-#() vFulpu
-#() vFulpp
-#() vFupii
-#() vFuppi
-#() vFUUpi
-#() vFffff
-#() vFdddd
-#() vFllll
-#() vFpiii
-#() vFpiiu
-#() vFpiip
-#() vFpiuu
-#() vFpiuL
-#() vFpiup
-#() vFpiUu
-#() vFpiUU
-#() vFpifi
-#() vFpipi
-#() vFpipp
-#() vFpIdi
-#() vFpCiW
-#() vFpuip
-#() vFpuui
-#() vFpuuu
-#() vFpuup
-#() vFpudd
-#() vFpupp
-#() vFpUui
-#() vFpUuu
-#() vFpUup
-#() vFpUUi
-#() vFpUUu
-#() vFpUUp
-#() vFpUpp
-#() vFpfff
-#() vFpdii
-#() vFpdip
-#() vFpddi
-#() vFpddd
-#() vFplpp
-#() vFpLLL
-#() vFppii
-#() vFppiu
-#() vFppid
-#() vFppil
-#() vFppiL
-#() vFppip
-#() vFppui
-#() vFppuu
-#() vFppup
-#() vFppfi
-#() vFppdu
-#() vFppdd
-#() vFppdp
-#() vFpplp
-#() vFppLp
-#() vFpppi
-#() vFpppI
-#() vFpppu
-#() vFpppU
-#() vFpppd
-#() vFpppL
-#() vFpppp
-#() cFpiii
-#() iFEiip
-#() iFEiiN
-#() iFEipp
-#() iFEipV
-#() iFEupu
-#() iFEupp
-#() iFEpii
-#() iFEpip
-#() iFEpiV
-#() iFEpiA
-#() iFEpui
-#() iFEpup
-#() iFEpUi
-#() iFEpUp
-#() iFEpLi
-#() iFEpLp
-#() iFEppi
-#() iFEppd
-#() iFEppL
-#() iFEppp
-#() iFEppV
-#() iFEppA
-#() iFEpOu
-#() iFwwww
-#() iFwppp
-#() iFiiii
-#() iFiiiu
-#() iFiiip
-#() iFiiiN
-#() iFiiui
-#() iFiiup
-#() iFiill
-#() iFiipi
-#() iFiipp
-#() iFiuwp
-#() iFiuii
-#() iFiuup
-#() iFiupp
-#() iFilli
-#() iFillu
-#() iFipii
-#() iFipip
-#() iFipui
-#() iFipuu
-#() iFipup
-#() iFipLi
-#() iFipLu
-#() iFipLp
-#() iFippi
-#() iFippu
-#() iFippL
-#() iFippp
-#() iFipON
-#() iFuipu
-#() iFuipp
-#() iFuuff
-#() iFuupi
-#() iFupLp
-#() iFuppi
-#() iFuppp
-#() iFLLiW
-#() iFpwww
-#() iFpwpp
-#() iFpiii
-#() iFpiiI
-#() iFpiiu
-#() iFpiid
-#() iFpiiL
-#() iFpiip
-#() iFpiuu
-#() iFpiuL
-#() iFpiup
-#() iFpiUp
-#() iFpild
-#() iFpipi
-#() iFpipC
-#() iFpipu
-#() iFpipL
-#() iFpipp
-#() iFpipV
-#() iFpIip
-#() iFpCCC
-#() iFpCpi
-#() iFpWWu
-#() iFpuwp
-#() iFpuiL
-#() iFpuip
-#() iFpuui
-#() iFpuuu
-#() iFpuup
-#() iFpuUp
-#() iFpuLL
-#() iFpuLp
-#() iFpupi
-#() iFpupu
-#() iFpupU
-#() iFpupL
-#() iFpupp
-#() iFpupV
-#() iFpUup
-#() iFpUUU
-#() iFpULp
-#() iFpUpp
-#() iFplii
-#() iFplip
-#() iFpLii
-#() iFpLip
-#() iFpLLu
-#() iFpLpi
-#() iFpLpf
-#() iFpLpd
-#() iFpLpD
-#() iFpLpL
-#() iFpLpp
-#() iFppii
-#() iFppiu
-#() iFppiU
-#() iFppiL
-#() iFppip
-#() iFppIL
-#() iFppCC
-#() iFppuw
-#() iFppui
-#() iFppuu
-#() iFppup
-#() iFppdp
-#() iFppll
-#() iFpplp
-#() iFppLi
-#() iFppLL
-#() iFppLp
-#() iFpppi
-#() iFpppC
-#() iFpppu
-#() iFpppU
-#() iFpppL
-#() iFpppp
-#() IFEpIi
-#() IFpIip
-#() IFppii
-#() IFppip
-#() IFpppp
-#() IFSIii
-#() CFpupp
-#() uFEipp
-#() uFEupp
-#() uFEpup
-#() uFEppp
-#() uFifff
-#() uFuuuu
-#() uFpiip
-#() uFpipu
-#() uFpipp
-#() uFpCCC
-#() uFpuip
-#() uFpuuu
-#() uFpuup
-#() uFpupu
-#() uFppiu
-#() uFppLp
-#() uFpppi
-#() uFpppu
-#() uFpppp
-#() UFpipp
-#() UFpUui
-#() UFppii
-#() UFppip
-#() UFpppp
-#() dFpppp
-#() lFEipV
-#() lFEpip
-#() lFEppL
-#() lFEppp
-#() lFiiLu
-#() lFiipL
-#() lFipil
-#() lFipLi
-#() lFipLI
-#() lFipLu
-#() lFipLl
-#() lFipLL
-#() lFipLp
-#() lFippL
-#() lFuipp
-#() lFpili
-#() lFpilp
-#() lFppii
-#() lFppip
-#() lFpppL
-#() LFEppL
-#() LFEppp
-#() LFippL
-#() LFippp
-#() LFpuuu
-#() LFpLCL
-#() LFpLLp
-#() LFpLpL
-#() LFpLpp
-#() LFppii
-#() LFppip
-#() LFppLL
-#() LFppLp
-#() LFpppi
-#() LFpppp
-#() pFEipp
-#() pFEupp
-#() pFELpV
-#() pFELpA
-#() pFEpii
-#() pFEpip
-#() pFEppi
-#() pFEppp
-#() pFEppV
-#() pFiiii
-#() pFiiiu
-#() pFiiuu
-#() pFiiup
-#() pFiipi
-#() pFiipp
-#() pFiIIi
-#() pFillu
-#() pFipii
-#() pFipip
-#() pFippi
-#() pFippu
-#() pFuiii
-#() pFuuii
-#() pFulli
-#() pFullu
-#() pFffff
-#() pFdipp
-#() pFdddd
-#() pFDipp
-#() pFlfff
-#() pFLiip
-#() pFpiii
-#() pFpiip
-#() pFpiuu
-#() pFpiLL
-#() pFpipi
-#() pFpipd
-#() pFpipp
-#() pFpCWp
-#() pFpCuW
-#() pFpCuu
-#() pFpuii
-#() pFpuip
-#() pFpuWp
-#() pFpuuC
-#() pFpuuu
-#() pFpuup
-#() pFpupi
-#() pFpupu
-#() pFpdIU
-#() pFplpl
-#() pFplpp
-#() pFpLip
-#() pFpLLp
-#() pFpLpL
-#() pFppii
-#() pFppiu
-#() pFppiL
-#() pFppip
-#() pFppWW
-#() pFppuW
-#() pFppuu
-#() pFppuL
-#() pFppup
-#() pFppUU
-#() pFppdd
-#() pFppll
-#() pFppLL
-#() pFppLp
-#() pFpppi
-#() pFpppu
-#() pFpppU
-#() pFpppL
-#() pFpppp
-#() pFSppi
-#() vWpiiu
-#() vWpuup
-#() iWEpip
-#() iWEpup
-#() iWEppu
-#() iWEppp
-#() iWpiii
-#() iWpiuu
-#() iWpuiu
-#() iWpuip
-#() iWpuup
-#() iWpupu
-#() iWpupp
-#() iWppuu
-#() iWpppu
-#() iWpppp
-#() vFEiipV
-#() vFEiipA
-#() vFEippp
-#() vFEpipV
-#() vFEpipA
-#() vFEpuup
-#() vFEpuuV
-#() vFEpupp
-#() vFEpupA
-#() vFEpLLp
-#() vFEppip
-#() vFEppiV
-#() vFEppup
-#() vFEpppi
-#() vFEpppp
-#() vFiiiii
-#() vFiiiiu
-#() vFiiipi
-#() vFiiuii
-#() vFiiuup
-#() vFiillu
-#() vFiilll
-#() vFiipii
-#() vFiipll
-#() vFiIIII
-#() vFiuiip
-#() vFiuipi
-#() vFiuuuu
-#() vFiulpp
-#() vFiuppu
-#() vFiUUUU
-#() vFiffff
-#() vFidddd
-#() vFilill
-#() vFilipi
-#() vFilipl
-#() vFillpu
-#() vFipipu
-#() vFipipp
-#() vFipupi
-#() vFiplli
-#() vFiplll
-#() vFuiiii
-#() vFuiiiu
-#() vFuiiip
-#() vFuiifi
-#() vFuiill
-#() vFuiilp
-#() vFuiIII
-#() vFuiuii
-#() vFuiuiu
-#() vFuiuip
-#() vFuiuuu
-#() vFuiuup
-#() vFuiull
-#() vFuiupi
-#() vFuiUUU
-#() vFuifff
-#() vFuiddd
-#() vFuipii
-#() vFuipip
-#() vFuipup
-#() vFuippp
-#() vFuuiii
-#() vFuuiiu
-#() vFuuiui
-#() vFuuiuu
-#() vFuuiup
-#() vFuuipi
-#() vFuuipu
-#() vFuuipp
-#() vFuuuii
-#() vFuuuiu
-#() vFuuuip
-#() vFuuuui
-#() vFuuuuu
-#() vFuuuup
-#() vFuuull
-#() vFuuulp
-#() vFuulll
-#() vFuullp
-#() vFuulpp
-#() vFuupii
-#() vFuffff
-#() vFudddd
-#() vFulill
-#() vFullip
-#() vFullpp
-#() vFupupi
-#() vFuppip
-#() vFupppp
-#() vFUUppp
-#() vFfffff
-#() vFddddp
-#() vFpiiii
-#() vFpiiiI
-#() vFpiiiu
-#() vFpiiip
-#() vFpiiII
-#() vFpiiff
-#() vFpiipp
-#() vFpiIiI
-#() vFpiIII
-#() vFpiUUp
-#() vFpilpp
-#() vFpipii
-#() vFpipiu
-#() vFpuiip
-#() vFpuipp
-#() vFpuuuu
-#() vFpuuup
-#() vFpuupp
-#() vFpuUUu
-#() vFpuddd
-#() vFpupup
-#() vFpUuiu
-#() vFpUUuu
-#() vFpUUup
-#() vFpUUUu
-#() vFpUUUp
-#() vFpUppp
-#() vFpffff
-#() vFpdiII
-#() vFpddii
-#() vFpdddd
-#() vFpddpp
-#() vFpliil
-#() vFplppp
-#() vFpLLpp
-#() vFppiii
-#() vFppiiu
-#() vFppiip
-#() vFppiup
-#() vFppiff
-#() vFppipi
-#() vFppipp
-#() vFppWui
-#() vFppuui
-#() vFppuuu
-#() vFppuup
-#() vFppupi
-#() vFppupp
-#() vFppddp
-#() vFpppii
-#() vFpppip
-#() vFpppuu
-#() vFpppup
-#() vFpppdd
-#() vFppppi
-#() vFppppu
-#() vFppppL
-#() vFppppp
-#() iFEiipp
-#() iFEiipV
-#() iFEippi
-#() iFEippL
-#() iFEippp
-#() iFEpiii
-#() iFEpipi
-#() iFEpipp
-#() iFEpipV
-#() iFEpipA
-#() iFEpUup
-#() iFEpLpp
-#() iFEpLpV
-#() iFEpLpA
-#() iFEppii
-#() iFEppip
-#() iFEppiV
-#() iFEppiA
-#() iFEpplp
-#() iFEpppi
-#() iFEpppL
-#() iFEpppp
-#() iFEpppV
-#() iFiiipu
-#() iFiiipp
-#() iFiiupp
-#() iFiipup
-#() iFiuLip
-#() iFipiii
-#() iFipiup
-#() iFipipi
-#() iFipipu
-#() iFipuip
-#() iFipuui
-#() iFipLup
-#() iFippip
-#() iFippLi
-#() iFippLp
-#() iFipppi
-#() iFipppp
-#() iFuppLp
-#() iFpwwww
-#() iFpwppp
-#() iFpiiii
-#() iFpiiiu
-#() iFpiiiL
-#() iFpiiip
-#() iFpiiui
-#() iFpiiuu
-#() iFpiipi
-#() iFpiipp
-#() iFpiIip
-#() iFpiuwp
-#() iFpiUUU
-#() iFpipii
-#() iFpipiu
-#() iFpipiL
-#() iFpipip
-#() iFpippi
-#() iFpippW
-#() iFpippp
-#() iFpCCCC
-#() iFpuill
-#() iFpuipi
-#() iFpuuip
-#() iFpuuui
-#() iFpuuup
-#() iFpuuLL
-#() iFpuupp
-#() iFpupiU
-#() iFpupup
-#() iFpuppp
-#() iFpUiUi
-#() iFpUupp
-#() iFplluu
-#() iFpLiLi
-#() iFpLlpp
-#() iFpLLpp
-#() iFpLppi
-#() iFppiiu
-#() iFppiip
-#() iFppiup
-#() iFppiLi
-#() iFppiLL
-#() iFppipi
-#() iFppipp
-#() iFppuwp
-#() iFppuip
-#() iFppuup
-#() iFppupi
-#() iFppupp
-#() iFppllp
-#() iFpplpp
-#() iFppLip
-#() iFppLpi
-#() iFppLpL
-#() iFppLpp
-#() iFpppii
-#() iFpppiL
-#() iFpppip
-#() iFpppui
-#() iFpppUi
-#() iFpppLi
-#() iFpppLp
-#() iFppppi
-#() iFppppL
-#() iFppppp
-#() IFppIII
-#() uFEippp
-#() uFEpipp
-#() uFEppuu
-#() uFEpppp
-#() uFEpppV
-#() uFiuuuu
-#() uFipipp
-#() uFipLpp
-#() uFuiiiu
-#() uFpCCCC
-#() uFpWuip
-#() uFpuuuu
-#() uFpupuu
-#() uFppiip
-#() uFppipp
-#() uFppuup
-#() uFppupp
-#() uFpplip
-#() uFppLpp
-#() uFppppu
-#() uFppppp
-#() UFuiiii
-#() lFipili
-#() lFipLli
-#() lFipLlL
-#() lFipLLi
-#() lFipLpp
-#() LFELppi
-#() LFEpppp
-#() LFpuipp
-#() LFpuppi
-#() LFpLLLp
-#() LFpLppL
-#() LFpLppp
-#() LFppLLp
-#() LFpppii
-#() LFppppp
-#() pFEpiii
-#() pFEpipL
-#() pFEpipp
-#() pFEpipV
-#() pFEpipA
-#() pFEpupp
-#() pFEppii
-#() pFEppip
-#() pFEppLp
-#() pFEpppi
-#() pFEpppu
-#() pFEpppp
-#() pFiiiii
-#() pFiiipL
-#() pFipipL
-#() pFipppu
-#() pFuiiiu
-#() pFuiipp
-#() pFpiiii
-#() pFpiiip
-#() pFpiiuu
-#() pFpiipi
-#() pFpiipp
-#() pFpiCCC
-#() pFpiuuu
-#() pFpippi
-#() pFpippp
-#() pFpCpup
-#() pFpCppp
-#() pFpuiii
-#() pFpuiip
-#() pFpuWWW
-#() pFpuuip
-#() pFpuuWW
-#() pFpuuuu
-#() pFpuuup
-#() pFpuppp
-#() pFpUdii
-#() pFpdddd
-#() pFplppp
-#() pFppiii
-#() pFppiip
-#() pFppiup
-#() pFppipi
-#() pFppipp
-#() pFppuuu
-#() pFppuup
-#() pFppddi
-#() pFppLii
-#() pFppLLp
-#() pFpppii
-#() pFpppip
-#() pFpppIi
-#() pFpppui
-#() pFpppuu
-#() pFpppup
-#() pFpppLi
-#() pFppppi
-#() pFppppu
-#() pFppppp
-#() iWEpiup
-#() iWEpipp
-#() iWpiiii
-#() iWpiupu
-#() iWpuiii
-#() iWpuiup
-#() iWpuupu
-#() iWpuupp
-#() iWpupuu
-#() iWpupup
-#() iWpuppu
-#() iWpuppp
-#() iWpppuu
-#() iWpppup
-#() iWppppp
-#() vFEiiipp
-#() vFEpiLpp
-#() vFEpippp
-#() vFEpuipp
-#() vFEpupup
-#() vFEpLLpp
-#() vFEppipV
-#() vFEppipA
-#() vFEppupp
-#() vFEppppp
-#() vFiiiiii
-#() vFiiiuil
-#() vFiiilpi
-#() vFiiuiil
-#() vFiiuilp
-#() vFiiuulp
-#() vFiililp
-#() vFiiplli
-#() vFiiplll
-#() vFiuippp
-#() vFiffiff
-#() vFiddidd
-#() vFililuU
-#() vFililll
-#() vFilipli
-#() vFiliplu
-#() vFillill
-#() vFipiplp
-#() vFipllli
-#() vFuiiiii
-#() vFuiiiil
-#() vFuiiiip
-#() vFuiiilp
-#() vFuiiuii
-#() vFuiiuup
-#() vFuiIIII
-#() vFuiuiii
-#() vFuiuiil
-#() vFuiuiip
-#() vFuiuiuu
-#() vFuiuuip
-#() vFuiuuuu
-#() vFuiuulp
-#() vFuiupii
-#() vFuiupiu
-#() vFuiUUUU
-#() vFuiffff
-#() vFuidddd
-#() vFuuiiii
-#() vFuuiiiu
-#() vFuuiuii
-#() vFuuiuiu
-#() vFuuiuup
-#() vFuuuiup
-#() vFuuuipi
-#() vFuuuipp
-#() vFuuuuii
-#() vFuuuuip
-#() vFuuuuuu
-#() vFuuuuff
-#() vFuuuppi
-#() vFuuuppp
-#() vFuuffff
-#() vFuudddd
-#() vFuulppp
-#() vFuupupp
-#() vFuffiip
-#() vFufffff
-#() vFuddiip
-#() vFuliluU
-#() vFulilli
-#() vFulilll
-#() vFullill
-#() vFulplup
-#() vFupupip
-#() vFuppppu
-#() vFuppppp
-#() vFffffff
-#() vFdddddd
-#() vFpiiiii
-#() vFpiiipp
-#() vFpiiuuu
-#() vFpiippp
-#() vFpiUuup
-#() vFpipipV
-#() vFpipppi
-#() vFpipppp
-#() vFpuiiii
-#() vFpuiiiu
-#() vFpuiipp
-#() vFpuuuiu
-#() vFpuuppp
-#() vFpudddd
-#() vFpupiUu
-#() vFpupuuu
-#() vFpupppp
-#() vFpUiuup
-#() vFpUiUup
-#() vFpUipup
-#() vFpUUiup
-#() vFpdddii
-#() vFpddddd
-#() vFpddddp
-#() vFppiiii
-#() vFppiiip
-#() vFppiiui
-#() vFppiipi
-#() vFppiipp
-#() vFppilpp
-#() vFppippi
-#() vFppippp
-#() vFppuuuu
-#() vFppuUUU
-#() vFppupii
-#() vFppuppp
-#() vFppdidd
-#() vFppdddd
-#() vFpplppi
-#() vFpplppp
-#() vFppLppi
-#() vFppLppp
-#() vFpppiii
-#() vFpppiip
-#() vFpppiff
-#() vFpppipu
-#() vFpppuii
-#() vFppppii
-#() vFpppppi
-#() vFpppppu
-#() vFpppppU
-#() vFpppppL
-#() vFpppppp
-#() cFppLppi
-#() iFEiippi
-#() iFEiippp
-#() iFEiLLLL
-#() iFEippLp
-#() iFElpppp
-#() iFEpiipp
-#() iFEpiipV
-#() iFEpilpV
-#() iFEpippi
-#() iFEpIppp
-#() iFEpuppp
-#() iFEpUppp
-#() iFEppppp
-#() iFiiiiii
-#() iFiiiiip
-#() iFiiiuwp
-#() iFiuiipi
-#() iFipiipi
-#() iFipipip
-#() iFipippp
-#() iFipuufp
-#() iFipupup
-#() iFipuppp
-#() iFipppLp
-#() iFippppp
-#() iFuppppp
-#() iFdipppL
-#() iFDipppL
-#() iFlpippp
-#() iFLppipp
-#() iFpiiiii
-#() iFpiiiip
-#() iFpiiipp
-#() iFpiipip
-#() iFpiippu
-#() iFpiippp
-#() iFpiuuup
-#() iFpiuupp
-#() iFpiUUpp
-#() iFpipipi
-#() iFpippip
-#() iFpipppL
-#() iFpipppp
-#() iFpCpipu
-#() iFpWpppp
-#() iFpuiCpp
-#() iFpuippp
-#() iFpupuui
-#() iFpUuuLp
-#() iFpUuupp
-#() iFpUUUip
-#() iFpUUUUp
-#() iFpLLppp
-#() iFppiiii
-#() iFppiiip
-#() iFppiiuu
-#() iFppiipi
-#() iFppiipp
-#() iFppipii
-#() iFppipiL
-#() iFppipip
-#() iFppIipp
-#() iFppIppp
-#() iFppuiii
-#() iFppuiiL
-#() iFppuipp
-#() iFppuIII
-#() iFppuupp
-#() iFppupip
-#() iFppuppp
-#() iFppUipp
-#() iFppUUup
-#() iFppdidd
-#() iFpplppi
-#() iFppLupp
-#() iFppLpLp
-#() iFpppiuu
-#() iFpppipi
-#() iFpppipp
-#() iFpppuii
-#() iFpppupu
-#() iFpppLpp
-#() iFppppii
-#() iFppppiu
-#() iFppppip
-#() iFppppup
-#() iFpppppi
-#() iFpppppL
-#() iFpppppp
-#() uFEiippp
-#() uFEiuppp
-#() uFEpCppp
-#() uFEpuppp
-#() uFpippup
-#() uFpWuwCp
-#() uFpWuipp
-#() uFpWuuCp
-#() uFpuippp
-#() uFppippp
-#() uFppuuup
-#() uFppuupu
-#() uFpppppi
-#() uFpppppp
-#() UFpippup
-#() lFEpippp
-#() lFipipLu
-#() lFipLipu
-#() lFipLipp
-#() lFipLpLL
-#() LFEupppp
-#() LFELpppi
-#() LFEppppi
-#() LFpipipi
-#() LFpLippp
-#() LFSpLiip
-#() pFEpiupp
-#() pFEpippp
-#() pFEpuipp
-#() pFEpuupp
-#() pFEpuppp
-#() pFEpLLiN
-#() pFEppLLp
-#() pFEpppLp
-#() pFEppppi
-#() pFEppppp
-#() pFEppppV
-#() pFEppApp
-#() pFiiiiii
-#() pFiCiiCi
-#() pFdddddd
-#() pFpiiiiu
-#() pFpiiCCC
-#() pFpiUUUU
-#() pFpippip
-#() pFpipppp
-#() pFpCuuCC
-#() pFpCuuWW
-#() pFpCuuup
-#() pFpuuwwu
-#() pFpuuuuu
-#() pFpuuupu
-#() pFpuuUUU
-#() pFplpppp
-#() pFppiiii
-#() pFppiipp
-#() pFppiCCC
-#() pFppippi
-#() pFppippp
-#() pFpppiii
-#() pFpppiui
-#() pFpppiup
-#() pFpppupp
-#() pFppppii
-#() pFppppWW
-#() pFpppppi
-#() pFpppppu
-#() pFpppppp
-#() pFSpiiii
-#() iWEpuuip
-#() iWEppppp
-#() iWpiiiip
-#() iWpiiuii
-#() iWpiuppu
-#() iWpuiiii
-#() iWpppppi
-#() iWpppppu
-#() vFEpiiipp
-#() vFEpipppp
-#() vFEpuipuV
-#() vFEppippp
-#() vFEpppppp
-#() vFiiiiiip
-#() vFiiiiuup
-#() vFiiuilil
-#() vFiiffffp
-#() vFiipllli
-#() vFiuulipi
-#() vFililluU
-#() vFilipliu
-#() vFilulipi
-#() vFuiiiiii
-#() vFuiiiuip
-#() vFuiiiuup
-#() vFuiiliip
-#() vFuiililp
-#() vFuiuiiii
-#() vFuiuiiip
-#() vFuiuiiuu
-#() vFuiupiiu
-#() vFuilliip
-#() vFuipiiii
-#() vFuipffff
-#() vFuipdddd
-#() vFuuiiiii
-#() vFuuiiiip
-#() vFuuiiiui
-#() vFuuiiiuu
-#() vFuuiiuup
-#() vFuuiuiii
-#() vFuuipppp
-#() vFuuuiiii
-#() vFuuuiiip
-#() vFuuuiuii
-#() vFuuuiupi
-#() vFuuuuiip
-#() vFuuuuuuu
-#() vFuuuufff
-#() vFuuuulll
-#() vFuuuffff
-#() vFuuudddd
-#() vFuuffiip
-#() vFuuddiip
-#() vFuuppppu
-#() vFuuppppp
-#() vFuffffff
-#() vFudddddd
-#() vFulilluU
-#() vFulillli
-#() vFulipulp
-#() vFulpiill
-#() vFlipuiip
-#() vFlliiiip
-#() vFpiiiipp
-#() vFpiiliip
-#() vFpiipCpp
-#() vFpiipppp
-#() vFpipipii
-#() vFpipppii
-#() vFpuuuuuu
-#() vFpuuUUuu
-#() vFpuupppp
-#() vFpupuuup
-#() vFpUiUiup
-#() vFpUUUUuu
-#() vFpddiidd
-#() vFpdddddd
-#() vFpLiLiLp
-#() vFppiiiii
-#() vFppiiiip
-#() vFppiiipi
-#() vFppiipii
-#() vFppiipuu
-#() vFppiippp
-#() vFppilppi
-#() vFppiLiLp
-#() vFppipiip
-#() vFppipipp
-#() vFppipppp
-#() vFppddddi
-#() vFppddpii
-#() vFppLpppi
-#() vFppLpppp
-#() vFpppiiii
-#() vFpppiipi
-#() vFpppiipp
-#() vFpppippi
-#() vFpppuuuu
-#() vFppppiii
-#() vFppppiip
-#() vFppppipi
-#() vFpppppip
-#() vFppppppi
-#() vFppppppp
-#() iFEpupppp
-#() iFEpUuppp
-#() iFEpLiLpV
-#() iFEppuppp
-#() iFEppLpIi
-#() iFEpppiiu
-#() iFEpppppL
-#() iFEpppppp
-#() iFiiiiiip
-#() iFpiiiiii
-#() iFpiiiiip
-#() iFpiiiuwp
-#() iFpiiuuiu
-#() iFpiipppp
-#() iFpiuiipp
-#() iFpiupiii
-#() iFpiupppp
-#() iFpipipip
-#() iFpipippp
-#() iFpippLpp
-#() iFpippppW
-#() iFpippppp
-#() iFpIIpppp
-#() iFpWppppW
-#() iFpuiCuCp
-#() iFpuiuupp
-#() iFpuuiuui
-#() iFpuupppp
-#() iFpupiLpL
-#() iFpupuuui
-#() iFpupupui
-#() iFpuppppp
-#() iFpLipipi
-#() iFppiiiip
-#() iFppiiuui
-#() iFppiiuup
-#() iFppiipii
-#() iFppiipiL
-#() iFppiuppi
-#() iFppipiii
-#() iFppipiip
-#() iFppipipi
-#() iFppipipp
-#() iFppippip
-#() iFppipppi
-#() iFppipppp
-#() iFppuipiL
-#() iFppLiipp
-#() iFpppiiii
-#() iFpppiiuu
-#() iFpppiiup
-#() iFpppiipi
-#() iFpppiuwu
-#() iFpppippi
-#() iFpppippp
-#() iFpppuiii
-#() iFppppiii
-#() iFppppipp
-#() iFppppdpi
-#() iFpppppip
-#() iFpppppup
-#() iFppppppi
-#() iFppppppp
-#() uFEiipppp
-#() uFEpiippp
-#() uFEpuuppp
-#() uFuippppp
-#() uFppiuppp
-#() uFppuuuup
-#() LFEppLppU
-#() LFEpppppu
-#() pFEpLiiii
-#() pFEpLiiiI
-#() pFEpLiiil
-#() pFEppuipp
-#() pFEppppip
-#() pFEpppppi
-#() pFifffppp
-#() pFuupupup
-#() pFdiiiIiI
-#() pFpiiUdii
-#() pFpCuwwWW
-#() pFpCuWCCC
-#() pFpCuuwwp
-#() pFpCuuuuu
-#() pFpCpWWup
-#() pFpuuuwwu
-#() pFpuupwwC
-#() pFplppppp
-#() pFpLppiip
-#() pFppiiipp
-#() pFppiiCCC
-#() pFppiippp
-#() pFppipipp
-#() pFppipLpp
-#() pFppuuppp
-#() pFppLiiip
-#() pFppLipip
-#() pFpppccci
-#() pFpppiiii
-#() pFpppiipp
-#() pFpppIIIi
-#() pFpppCCCi
-#() pFpppuuui
-#() pFpppuupp
-#() pFpppUUUi
-#() pFpppfffi
-#() pFpppdddi
-#() pFpppllli
-#() pFpppLLLi
-#() pFppppuuu
-#() pFpppppuu
-#() pFppppppi
-#() pFppppppp
-#() iWpiiuuuu
-#() iWpuiiiip
-#() iWpuiiuii
-#() iWpuipupp
-#() iWpuuuppu
-#() iWpupuufu
-#() iWpppuppp
-#() vFEiippppV
-#() vFEiupippp
-#() vFEipAippp
-#() vFEppipppp
-#() vFEpppippp
-#() vFEpppuipV
-#() vFEpppppuu
-#() vFiiiiuuip
-#() vFiilliilp
-#() vFililliuU
-#() vFilillluU
-#() vFilipufip
-#() vFuiiiiiii
-#() vFuiiiiill
-#() vFuiiiiuup
-#() vFuiuiiiii
-#() vFuiuiiiip
-#() vFuiuiuuuu
-#() vFuiulplpp
-#() vFuipuliuf
-#() vFuuiiiiii
-#() vFuuiiiuip
-#() vFuuiiiuup
-#() vFuuiiuupp
-#() vFuuiuiiii
-#() vFuuiuiiip
-#() vFuuuiiiii
-#() vFuuuiuiii
-#() vFuuuipipp
-#() vFuuuuuuuu
-#() vFuuuuufff
-#() vFuuufffff
-#() vFulilliuU
-#() vFulillluU
-#() vFulllplip
-#() vFffffffff
-#() vFlipuiuip
-#() vFpiiiiiii
-#() vFpiiiipii
-#() vFpiiULipp
-#() vFpiUuupup
-#() vFpippiiuu
-#() vFpippiipi
-#() vFpuppLLLL
-#() vFpUiUiupi
-#() vFpUuuUUUi
-#() vFppiiiiii
-#() vFppiiipii
-#() vFppipipii
-#() vFppipppui
-#() vFppippppi
-#() vFppippppp
-#() vFpplppppi
-#() vFpplppppp
-#() vFppppiipi
-#() vFpppppuuu
-#() vFpppppppp
-#() iFEpippppp
-#() iFEpuuLppp
-#() iFEpUUuppp
-#() iFEppipppp
-#() iFEppppipp
-#() iFiiiiiiip
-#() iFiiupiupi
-#() iFipippppp
-#() iFuipuuluf
-#() iFuuuuuuuu
-#() iFullfpppp
-#() iFpippuuii
-#() iFpCCWWpWu
-#() iFpWCuWCuu
-#() iFpWWipppp
-#() iFpuiipppp
-#() iFpuippLpp
-#() iFpuuiiiii
-#() iFpuuupupu
-#() iFpupppWWu
-#() iFpupppppp
-#() iFpUuuLpUi
-#() iFpdiiiIiI
-#() iFpLpipppp
-#() iFppiiiiiu
-#() iFppiiipip
-#() iFppIIIppp
-#() iFpppiiipi
-#() iFpppiippp
-#() iFpppipipi
-#() iFppppiipi
-#() iFppppippp
-#() iFppppppii
-#() iFpppppppi
-#() iFpppppppp
-#() uFEipipppp
-#() uFEpiupppp
-#() uFEppipppp
-#() uFEpppuppp
-#() uFEppppppp
-#() uFuipppppp
-#() uFulpppppp
-#() uFpupuuuCp
-#() uFppuuuupp
-#() uFppuuuppi
-#() uFppuppppp
-#() LFELpLpLpi
-#() LFEpiupppp
-#() pFEiplllpp
-#() pFEpiuCppp
-#() pFEppLiiip
-#() pFEpppuipV
-#() pFEpppppiV
-#() pFEppppppi
-#() pFEppppppp
-#() pFiipppppp
-#() pFuiiiuuuu
-#() pFuupupipp
-#() pFpiiiiiuu
-#() pFpiUdiiUi
-#() pFpipiiiip
-#() pFpipppppp
-#() pFpCCuuwwC
-#() pFpCuwwWWu
-#() pFpCuuuCup
-#() pFpWWiCpup
-#() pFpuuWWCuu
-#() pFpuuuuupp
-#() pFpuuuupup
-#() pFpuuupwwp
-#() pFpdwwWWui
-#() pFplpppppp
-#() pFppiiiiii
-#() pFpppuuLLu
-#() pFpppppupp
-#() iWEpuuiipp
-#() iWEpuuuipp
-#() iWpuipuppp
-#() vFEpiiiiipp
-#() vFEpippippV
-#() vFEpippippA
-#() vFEpuuuippp
-#() vFEppiipppp
-#() vFEpppiippp
-#() vFEppppippp
-#() vFiiiiiiiii
-#() vFiiiiiiill
-#() vFiiiiillli
-#() vFiiilllilp
-#() vFilillliuU
-#() vFuiiiiiiii
-#() vFuiiiiiuip
-#() vFuiiiiiuup
-#() vFuiiiillli
-#() vFuiiilliip
-#() vFuiiillilp
-#() vFuiuiiiiip
-#() vFuuiiiiiii
-#() vFuuiuiiiii
-#() vFuuiuiiiip
-#() vFuuiuiiuup
-#() vFuuuiiiiip
-#() vFuuuuuuuuu
-#() vFuffffffff
-#() vFulillliuU
-#() vFffuuuufff
-#() vFddddddddd
-#() vFlipuiuiip
-#() vFpipiuiipp
-#() vFpipippppi
-#() vFpipppiipi
-#() vFppiiiiiii
-#() vFppiiiiipi
-#() vFppiiipiii
-#() vFppiipiiii
-#() vFppipppiii
-#() vFppipppiip
-#() vFppuuiiiii
-#() vFppUUiUUUU
-#() vFppddddidd
-#() vFpplpppppi
-#() vFpppiiiiii
-#() vFppppipiip
-#() vFpppppippp
-#() iFEpiiiiipi
-#() iFEpppipppp
-#() iFEppplPPPP
-#() iFEpppppupp
-#() iFEppPPPPPP
-#() iFiiiiiiiip
-#() iFiiiipiiip
-#() iFipiipippi
-#() iFuilpluluf
-#() iFdddpppppp
-#() iFpipLpiiip
-#() iFpuuuuuuuu
-#() iFpdiiiUiUp
-#() iFppiiiiiii
-#() iFppiuiippL
-#() iFppLpiippp
-#() iFpppiiipip
-#() iFpppiiuuii
-#() iFpppiipiiu
-#() iFppppiiupp
-#() iFppppppppu
-#() iFppppppppp
-#() uFEipippppp
-#() uFEpppufppp
-#() uFppppppppp
-#() LFEppppppii
-#() pFEppiiuuLi
-#() pFEppuippuu
-#() pFEpppppiiV
-#() pFEpppppppi
-#() pFEpppppppp
-#() pFpiiiiuuuu
-#() pFpCuWCCuuu
-#() pFpuuwwWWww
-#() pFpupuuuuup
-#() pFppiiiiiip
-#() pFppiiuuuLL
-#() pFppipppppp
-#() pFpppiiiiii
-#() pFpppiipppp
-#() pFpppWWWWWp
-#() pFpppppiipp
-#() pFpppppuuCC
-#() iWEpuuiippu
-#() iWEpuuuiipp
-#() iWpiuuupipu
-#() iWpuiuuipip
-#() iWppppupiii
-#() vFEiippppppp
-#() vFEpippppppp
-#() vFEpppiipppp
-#() vFiiiiiiiiii
-#() vFiiiiiiiiiu
-#() vFiiiiiiiiui
-#() vFiiillliiip
-#() vFuiiiiiiiii
-#() vFuiiiiiiill
-#() vFuiiiiiiuup
-#() vFuiiiillllp
-#() vFuiuiiiiuup
-#() vFuipulipiuf
-#() vFuuiiiiiiii
-#() vFuuiiiiiuip
-#() vFuuiiiiiuup
-#() vFuuiuiiiiip
-#() vFuuiuiiiuup
-#() vFuuuuuuuiii
-#() vFuuuuuuuuuu
-#() vFuffiiffiip
-#() vFuddiiddiip
-#() vFffffffffff
-#() vFpipippppip
-#() vFppiiiiiiii
-#() vFppiiiiipip
-#() vFppiipppiip
-#() vFppiippppii
-#() vFppipppiiii
-#() vFppuuuuiiuu
-#() vFppdddddddd
-#() vFpppppppppp
-#() iFEpiiiiippp
-#() iFEpupppLppL
-#() iFEppppppipp
-#() iFEppppppppp
-#() iFiiiiiiiiip
-#() iFpiipiiipip
-#() iFpippddiidd
-#() iFpCuWCCCCup
-#() iFpuupiuiipp
-#() iFpddpippppp
-#() iFppuuiiiiii
-#() iFppuuiiuupi
-#() iFpppiiipipi
-#() iFpppLLipppp
-#() iFppppiiuuii
-#() iFpppppppipi
-#() uFpppppppppp
-#() pFEiippppppp
-#() pFEpiiiiiipp
-#() pFEpippppppp
-#() pFpCuWCCuuCW
-#() pFpuwwWWuCuu
-#() pFpuuuwwwwWW
-#() pFpuuuWWWCCi
-#() pFplllllllll
-#() pFppuiipuuii
-#() pFpppppppppp
-#() iWEpuipupppp
-#() iWEpuuiiuipp
-#() iWEpuuuuiipp
-#() vFEpiiiupupup
-#() vFiiiiillliip
-#() vFiiiiilllilp
-#() vFuiiiiiiiiip
-#() vFuiiiiiiiuip
-#() vFuiiiiiiiuup
-#() vFuiiiillliip
-#() vFuiiiilllilp
-#() vFuiuiiiiiuup
-#() vFuuiuiiiiuup
-#() vFuuuuuuuuuuu
-#() vFuuupupppppp
-#() vFuuffiiffiip
-#() vFuufffffffff
-#() vFuuddiiddiip
-#() vFuffffffffff
-#() vFUufffffffff
-#() vFpipipiipiii
-#() vFpipppiiiipi
-#() vFpupiiupupup
-#() vFppiiiiiiiii
-#() vFppiiiiipiii
-#() vFppiiiiddddi
-#() vFppiipppiiii
-#() vFppipppiiiii
-#() vFppipppuiiii
-#() vFppppppppppp
-#() iFEpppipppppp
-#() iFEppppiiiiuu
-#() iFiiiiiiiiiip
-#() iFpiippiiipip
-#() iFppippipppip
-#() iFpppiiuuiiuu
-#() iFppppiiuuiiL
-#() uFEpLiupppLuV
-#() uFEpLippppLup
-#() uFEpLippppLuA
-#() uFEppppppippp
-#() uFppppppppppp
-#() pFEpipppppppi
-#() pFEppiiLpppip
-#() pFEppuiipuuii
-#() pFpppppppiipp
-#() pFppppppppppp
-#() iWEpuipuppppp
-#() iWEpuuiiuippu
-#() iWEpuuuuuiipp
-#() vFuiiiillliilp
-#() vFuuiiiiiiiiui
-#() vFuuiiiiiiiuip
-#() vFuuiiiiiiiuup
-#() vFuuuuuuuuuuuu
-#() vFffffffffffff
-#() vFpipppiiiipii
-#() vFpippppiiiipi
-#() vFppiiiiddddii
-#() vFppiiuuuiupup
-#() vFppiipppiiiii
-#() vFpppiiiiiiiii
-#() vFpppppppppppp
-#() iFEpppippppppp
-#() iFEppppiiiiuui
-#() iFpipllipppppp
-#() iFpipppppppppp
-#() iFpCCCWCWCCCWp
-#() iFpppllipppppp
-#() iFpppppppppppp
-#() pFEppiiuuuipii
-#() pFEppppppppppp
-#() pFWWiCCCCiipup
-#() pFpCuuWWwwCCup
-#() pFpuuuWWWWWWWW
-#() pFppiiuuuiupLp
-#() pFpppppppppppp
-#() vFEpppppppiippp
-#() vFuiiiiiiiiiuup
-#() vFuuuuuuuuuuuuu
-#() vFuffffffffffff
-#() vFpipppiiiiiiuu
-#() vFpippppppppppp
-#() vFppiiiiiiiiiii
-#() vFppiipppiiiiii
-#() vFppppppppppppp
-#() iFddddpppddpppp
-#() iFpippuuuiipppp
-#() iFpupiiiipppppp
-#() uFppppuuupppppp
-#() pFpCuuwwWWWWuup
-#() pFpuupppwwwwWWC
-#() pFppppppppppppp
-#() vFuffiiffiiffiip
-#() vFuddiiddiiddiip
-#() vFppiipppiiiiiii
-#() iFpipppppppppppp
-#() iFpppwwWWwwWWpuu
-#() pFppCpppwwwwwwWW
-#() vFuiiiiiuiiiiilll
-#() vFuuiiiiuuiiiiiii
-#() vFfffffffffffffff
-#() vFpUUUUUUUUUUUuuu
-#() vFpppippppppppppp
-#() vFppppppppppppppp
-#() pFpuiippppppppppp
-#() pFppipppppppppppp
-#() pFppppppppppppppp
-#() vFpppppppppppppppp
-#() iFpppppppppppppppp
-#() pFpuuWWWWWWwwCCCuu
-#() pFppipipipipipipip
-#() pFpppppppppppppppp
-#() vFuuuiiiiiuiiiiilll
-#() vFppiiiiddddiiiiiuu
-#() vFpppuppiipppuUUUpi
-#() pFpuuuuuwwuuuuUUUup
-#() pFppippipipipipipip
-#() vFppuiiiiipuiiiiiiii
-#() vFpppipppppppppppppp
-#() iFpppppppppppppppppp
-#() LFpppppppppppppppppp
-#() pFippppppppppppppppp
-#() vFpiiiiiiiiiiiiiiiiii
-#() pFiiiippppppppppppppp
-#() pFpippppppppppppppppp
-#() pFpppWWCCpCpCpCWpCpCpC
-#() iFpppppppppppppppppppppp
-#() vFpppppppppppppppppppppppp
-#() iFpppppppppppppppppppppppppppppppppp
-#defined(HAVE_LD80BITS) IFD
-#defined(HAVE_LD80BITS) DFD
-#defined(HAVE_LD80BITS) vFppippDDC
-#!defined(HAVE_LD80BITS) IFK
-#!defined(HAVE_LD80BITS) KFK
-#!defined(HAVE_LD80BITS) KFKK
-#!defined(HAVE_LD80BITS) KFKp
-#!defined(HAVE_LD80BITS) vFppippKKC
-#defined(NOALIGN) iFipiip
-#!defined(NOALIGN) iFEppu
-#!defined(NOALIGN) iFEiiip
-#!defined(NOALIGN) iFEipii
-#!defined(NOALIGN) iFEipiip
-#() vFEv -> vFE
-#() iFEv -> iFE
-#() lFEv -> lFE
-#() pFEv -> pFE
-#() iFEvpp -> iFEpp
-#() pFEppv -> pFEpp
-#() iFEpvpp -> iFEppp
-#() iFEpvvppp -> iFEpppp
-#() iFEpLvvpp -> iFEpLpp
-#() iFEpuvvppp -> iFEpuppp
-wrappedalure:
-wrappedalut:
-wrappedatk:
-- vFp:
- - atk_focus_tracker_init
-- uFp:
- - atk_add_focus_tracker
-- uFpp:
- - atk_add_key_event_listener
-wrappedatkbridge:
-wrappedatomic:
-wrappedatspi:
-wrappedbz2:
-- iFp:
- - BZ2_bzCompressEnd
- - BZ2_bzDecompress
- - BZ2_bzDecompressEnd
-- iFpi:
- - BZ2_bzCompress
-- iFpii:
- - BZ2_bzDecompressInit
-- iFpiii:
- - BZ2_bzCompressInit
-wrappedcairo:
-wrappedcairogobject:
-wrappedcrashhandler:
-wrappedcrypto:
-- vFp:
- - CRYPTO_set_id_callback
- - CRYPTO_set_locking_callback
-- pFp:
- - sk_new
-- vFpp:
- - X509_STORE_CTX_set_verify_cb
- - sk_pop_free
-- pFpp:
- - OPENSSL_sk_pop_free
-- iFppp:
- - ASN1_i2d_bio
-- pFpppp:
- - ASN1_d2i_bio
- - PEM_read_bio_DSAPrivateKey
- - PEM_read_bio_DSA_PUBKEY
- - PEM_read_bio_ECPrivateKey
- - PEM_read_bio_EC_PUBKEY
- - PEM_read_bio_PKCS7
- - PEM_read_bio_RSAPrivateKey
- - PEM_read_bio_RSA_PUBKEY
- - PEM_read_bio_X509
- - PEM_read_bio_X509_AUX
- - PEM_read_bio_X509_CERT_PAIR
- - PEM_read_bio_X509_CRL
- - PEM_read_bio_X509_REQ
-- iFpiipp:
- - ENGINE_ctrl
-- iFpplppi:
- - ENGINE_ctrl_cmd
-- iFppppipp:
- - PEM_write_bio_DSAPrivateKey
- - PEM_write_bio_ECPrivateKey
- - PEM_write_bio_RSAPrivateKey
-wrappedcurl:
-- iFpup:
- - curl_multi_setopt
-- uFpup:
- - curl_easy_setopt
-wrappedd3dadapter9:
-- pWp:
- - D3DAdapter9GetProc
-- iWip:
- - dummy_d3d
-wrappeddbus:
-- vFppp:
- - dbus_connection_remove_filter
- - dbus_timeout_set_data
- - dbus_watch_set_data
-- iFpiV:
- - dbus_message_append_args
-- iFpiA:
- - dbus_message_append_args_valist
-- vFpppp:
- - dbus_connection_set_dispatch_status_function
- - dbus_connection_set_wakeup_main_function
-- iFpipp:
- - dbus_connection_set_data
- - dbus_message_set_data
- - dbus_pending_call_set_data
-- iFppip:
- - dbus_message_get_args
-- iFppiA:
- - dbus_message_get_args_valist
-- iFpppp:
- - dbus_connection_add_filter
- - dbus_pending_call_set_notify
-- iFppppp:
- - dbus_connection_try_register_fallback
- - dbus_connection_try_register_object_path
-- iFpppppp:
- - dbus_connection_set_timeout_functions
- - dbus_connection_set_watch_functions
-wrappeddbusglib1:
-- vFppp:
- - dbus_g_type_collection_value_iterate
- - dbus_g_type_map_value_iterate
-- vFpppp:
- - dbus_g_proxy_disconnect_signal
-- vFppppp:
- - dbus_g_proxy_connect_signal
-- pFpppppiV:
- - dbus_g_proxy_begin_call
-- pFpppppiiV:
- - dbus_g_proxy_begin_call_with_timeout
-wrappedexpat:
-- vFpp:
- - XML_SetAttlistDeclHandler
- - XML_SetCharacterDataHandler
- - XML_SetCommentHandler
- - XML_SetDefaultHandler
- - XML_SetDefaultHandlerExpand
- - XML_SetElementDeclHandler
- - XML_SetEndCdataSectionHandler
- - XML_SetEndDoctypeDeclHandler
- - XML_SetEndElementHandler
- - XML_SetEndNamespaceDeclHandler
- - XML_SetEntityDeclHandler
- - XML_SetExternalEntityRefHandler
- - XML_SetNotStandaloneHandler
- - XML_SetNotationDeclHandler
- - XML_SetProcessingInstructionHandler
- - XML_SetSkippedEntityHandler
- - XML_SetStartCdataSectionHandler
- - XML_SetStartDoctypeDeclHandler
- - XML_SetStartElementHandler
- - XML_SetStartNamespaceDeclHandler
- - XML_SetUnparsedEntityDeclHandler
- - XML_SetXmlDeclHandler
-- vFppp:
- - XML_SetElementHandler
- - XML_SetNamespaceDeclHandler
- - XML_SetUnknownEncodingHandler
-wrappedfaudio:
-- vFpp:
- - FAudio_UnregisterForCallbacks
-- uFpp:
- - FAudio_RegisterForCallbacks
-- vFppp:
- - FAudio_SetEngineProcedureEXT
-- uFpCppp:
- - FAudioCOMConstructWithCustomAllocatorEXT
-- uFpuppp:
- - FAudioCreateReverb9WithCustomAllocatorEXT
- - FAudioCreateReverbWithCustomAllocatorEXT
- - FAudioCreateVolumeMeterWithCustomAllocatorEXT
-- uFpuuppp:
- - FAudioCreateWithCustomAllocatorEXT
-- uFpppuppp:
- - FAPOFX_CreateFXWithCustomAllocatorEXT
-- uFpppufppp:
- - FAudio_CreateSourceVoice
-wrappedflac:
-- iFppPPPPPP:
- - FLAC__metadata_chain_read_with_callbacks
-- iFppppppppp:
- - FLAC__stream_decoder_init_stream
-wrappedfontconfig:
-- pFpV:
- - FcObjectSetBuild
-- pFpA:
- - FcObjectSetVaBuild
-wrappedfreebl3:
-wrappedfreetype:
-- iFpp:
- - FT_New_Library
-- iFppp:
- - FT_Outline_Decompose
-- iFpplp:
- - FT_Open_Face
-- iFpuuLppp:
- - FTC_Manager_New
-wrappedgbm:
-wrappedgconf2:
-wrappedgcrypt:
-- uFpppV:
- - gcry_sexp_build
-wrappedgdk3:
-- vFpp:
- - gdk_init
-- iFpp:
- - gdk_init_check
-- vFppp:
- - gdk_event_handler_set
- - gdk_window_add_filter
- - gdk_window_remove_filter
-- iFiipp:
- - gdk_input_add
-- iFiippp:
- - gdk_input_add_full
-wrappedgdkpixbuf2:
-- pFpiiiiiipp:
- - gdk_pixbuf_new_from_data
-wrappedgdkx112:
-- vFpp:
- - gdk_init
-- iFpp:
- - gdk_init_check
-- vFppp:
- - gdk_event_handler_set
- - gdk_window_add_filter
- - gdk_window_remove_filter
-- iFiipp:
- - gdk_input_add
-- iFiippp:
- - gdk_input_add_full
-wrappedgio2:
-- vFppp:
- - g_simple_async_result_set_op_res_gpointer
-- vFippp:
- - g_bus_get
-- vFppip:
- - g_simple_async_result_run_in_thread
-- vFpppp:
- - g_dbus_connection_close
- - g_dbus_connection_flush
- - g_simple_async_report_gerror_in_idle
- - g_simple_async_report_take_gerror_in_idle
-- uFpppp:
- - g_dbus_connection_add_filter
-- LFpppp:
- - g_cancellable_connect
-- pFpppp:
- - g_simple_async_result_new
- - g_simple_async_result_new_from_error
- - g_simple_async_result_new_take_error
-- vFpippp:
- - g_async_initable_init_async
-- vFppipV:
- - g_simple_async_result_set_error
-- vFppipA:
- - g_simple_async_result_set_error_va
-- pFppppV:
- - g_initable_new
-- pFppApp:
- - g_initable_new_valist
-- vFpipppp:
- - g_dbus_connection_new_for_address
-- vFiippppV:
- - g_async_initable_new_async
-- vFiupippp:
- - g_async_initable_newv_async
-- vFipAippp:
- - g_async_initable_new_valist_async
-- vFppipppp:
- - g_dbus_connection_new
-- vFpppuipV:
- - g_simple_async_report_error_in_idle
-- uFipipppp:
- - g_bus_watch_name
-- uFppipppp:
- - g_bus_own_name_on_connection
- - g_bus_watch_name_on_connection
-- uFppppppp:
- - g_dbus_connection_register_object
-- pFpppuipV:
- - g_simple_async_result_new_error
-- vFppiipppp:
- - g_dbus_connection_send_message_with_reply
-- vFpppiippp:
- - g_dbus_proxy_call
-- uFipippppp:
- - g_bus_own_name
-- vFiippppppp:
- - g_dbus_proxy_new_for_bus
-- vFpippppppp:
- - g_dbus_proxy_new
-- vFpppiipppp:
- - g_dbus_proxy_call_with_unix_fd_list
-- pFiippppppp:
- - g_dbus_object_manager_client_new_for_bus_sync
-- uFppppppippp:
- - g_dbus_connection_signal_subscribe
-- vFpppppppiippp:
- - g_dbus_connection_call
-wrappedglib2:
-- vFp:
- - g_atexit
-- pFp:
- - g_completion_new
- - g_main_context_get_poll_func
- - g_private_new
- - g_ptr_array_new_with_free_func
- - g_set_print_handler
- - g_set_printerr_handler
-- vFpp:
- - g_array_set_clear_func
- - g_array_sort
- - g_completion_set_compare
- - g_list_free_full
- - g_main_context_set_poll_func
- - g_ptr_array_set_free_func
- - g_ptr_array_sort
- - g_slist_free_full
- - g_source_set_funcs
- - g_thread_foreach
-- vFpV:
- - g_print
- - g_printerr
-- iFpp:
- - g_source_remove_by_funcs_user_data
-- iFpV:
- - g_printf
-- iFpA:
- - g_vprintf
-- uFpp:
- - g_idle_add
-- LFpA:
- - g_printf_string_upper_bound
-- pFup:
- - g_ptr_array_new_full
-- pFpu:
- - g_source_new
-- pFpp:
- - g_hash_table_new
- - g_list_sort
- - g_log_set_default_handler
- - g_slist_sort
- - g_strjoinv
- - g_variant_new_parsed_va
-- pFpV:
- - g_build_filename
- - g_markup_printf_escaped
- - g_strconcat
- - g_strdup_printf
- - g_strjoin
- - g_variant_new
-- pFpA:
- - g_markup_vprintf_escaped
- - g_strdup_vprintf
-- vFppp:
- - g_array_sort_with_data
- - g_hash_table_foreach
- - g_list_foreach
- - g_option_context_add_main_entries
- - g_ptr_array_foreach
- - g_ptr_array_sort_with_data
- - g_static_private_set
-- vFppV:
- - g_string_append_printf
- - g_string_printf
- - g_variant_builder_add
- - g_variant_get
-- vFppA:
- - g_string_append_vprintf
- - g_string_vprintf
-- iFppV:
- - g_fprintf
- - g_sprintf
-- iFppA:
- - g_vasprintf
- - g_vfprintf
- - g_vsprintf
-- uFipp:
- - g_child_watch_add
-- uFupp:
- - g_timeout_add
- - g_timeout_add_seconds
-- uFppp:
- - g_hash_table_foreach_remove
- - g_hash_table_foreach_steal
-- pFppp:
- - g_hash_table_find
- - g_list_find_custom
- - g_list_insert_sorted
- - g_list_sort_with_data
- - g_node_copy_deep
- - g_queue_find_custom
- - g_slist_find_custom
- - g_slist_foreach
- - g_slist_insert_sorted
- - g_slist_sort_with_data
- - g_variant_new_va
-- pFppV:
- - g_build_path
-- vFpipV:
- - g_log
-- vFpipA:
- - g_logv
-- vFpupp:
- - g_datalist_id_set_data_full
-- vFpppp:
- - g_source_set_callback
-- iFpLpV:
- - g_snprintf
-- iFpLpA:
- - g_vsnprintf
-- uFippp:
- - g_idle_add_full
-- uFpipp:
- - g_io_add_watch
- - g_log_set_handler
-- pFpipp:
- - g_markup_parse_context_new
-- pFpipV:
- - g_error_new
-- pFpipA:
- - g_error_new_valist
-- pFpupp:
- - g_datalist_id_dup_data
-- pFppip:
- - g_thread_create
-- pFpppp:
- - g_hash_table_new_full
- - g_slist_insert_sorted_with_data
- - g_thread_try_new
-- vFpiLpp:
- - g_qsort_with_data
-- vFppipV:
- - g_set_error
-- uFiippp:
- - g_child_watch_add_full
-- uFiuppp:
- - g_timeout_add_full
- - g_timeout_add_seconds_full
-- pFppppp:
- - g_option_group_new
-- vFpiiipp:
- - g_node_traverse
-- iFpupppp:
- - g_datalist_id_replace_data
-- uFpiippp:
- - g_io_add_watch_full
-- pFppuipp:
- - g_variant_new_from_data
-- pFppLiiip:
- - g_thread_create_full
-- iFpppipppp:
- - g_spawn_async
-- iFpppipppppp:
- - g_spawn_sync
-- iFpppippppppp:
- - g_spawn_async_with_pipes
-wrappedgmodule2:
-wrappedgmp:
-wrappedgnutls:
-- vFp:
- - gnutls_global_set_log_function
-- vFpp:
- - gnutls_transport_set_pull_function
- - gnutls_transport_set_pull_timeout_function
- - gnutls_transport_set_push_function
-wrappedgobject2:
-- pFL:
- - g_type_value_table_peek
-- pFp:
- - g_type_class_peek_parent
-- vFpp:
- - g_closure_set_marshal
-- iFpp:
- - g_param_type_register_static
-- pFpp:
- - g_value_array_sort
-- vFiip:
- - g_value_register_transform_func
-- vFLLp:
- - g_type_add_interface_static
-- vFpup:
- - g_object_class_install_properties
-- vFppp:
- - g_closure_add_finalize_notifier
- - g_object_weak_ref
- - g_signal_override_class_handler
-- vFppV:
- - g_object_get
- - g_object_set
-- vFppA:
- - g_object_get_valist
- - g_object_set_valist
-- LFppp:
- - g_boxed_type_register_static
-- pFLpV:
- - g_object_new
-- pFLpA:
- - g_object_new_valist
-- pFppp:
- - g_value_array_sort_with_data
-- pFppV:
- - g_object_connect
-- vFpuuV:
- - g_signal_emit
-- vFpupp:
- - g_param_spec_set_qdata_full
-- vFpupA:
- - g_signal_emit_valist
-- vFpppp:
- - g_object_set_data_full
- - g_object_set_qdata_full
-- LFLppi:
- - g_type_register_static
-- LFupppp:
- - g_signal_add_emission_hook
-- LFLpppi:
- - g_type_register_fundamental
-- LFppppi:
- - g_signal_connect_object
-- LFpppppu:
- - g_signal_connect_data
-- uFpiupppp:
- - g_signal_handlers_block_matched
- - g_signal_handlers_disconnect_matched
- - g_signal_handlers_unblock_matched
-- LFLpLpLpi:
- - g_type_register_static_simple
-- LFpiupppp:
- - g_signal_handler_find
-- uFpLiupppLuV:
- - g_signal_new
-- uFpLippppLup:
- - g_signal_newv
-- uFpLippppLuA:
- - g_signal_new_valist
-wrappedgssapi:
-wrappedgssapikrb5:
-wrappedgstapp:
-wrappedgstaudio:
-wrappedgstbase:
-wrappedgstgl:
-wrappedgstreamer:
-- vFppV:
- - gst_caps_set_simple
- - gst_structure_remove_fields
-- vFppA:
- - gst_caps_set_simple_valist
- - gst_structure_remove_fields_valist
-- iFppV:
- - gst_structure_get
-- iFppA:
- - gst_structure_get_valist
-- pFppV:
- - gst_structure_new
-- vFpppp:
- - gst_bus_set_sync_handler
- - gst_pad_set_activatemode_function_full
- - gst_pad_set_chain_function_full
- - gst_pad_set_event_function_full
- - gst_pad_set_getrange_function_full
- - gst_pad_set_query_function_full
-- pFiplllpp:
- - gst_buffer_new_wrapped_full
-- vFpippippV:
- - gst_debug_log
-- vFpippippA:
- - gst_debug_log_valist
-wrappedgsttag:
-wrappedgstvideo:
-wrappedgthread2:
-- vFp:
- - g_thread_init
- - g_thread_init_with_errorcheck_mutexes
-wrappedgtk3:
-- pFi:
- - gtk_type_class
-- vFpp:
- - gtk_builder_connect_signals
- - gtk_init
-- vFpA:
- - gtk_style_context_get_style_valist
-- iFLp:
- - gtk_type_unique
-- iFpp:
- - gtk_init_check
-- pFuV:
- - gtk_tree_store_new
-- vFpiA:
- - gtk_style_context_get_valist
-- vFppp:
- - gtk_builder_connect_signals_full
- - gtk_container_forall
- - gtk_container_foreach
- - gtk_menu_attach_to_widget
-- vFppV:
- - gtk_dialog_add_buttons
- - gtk_message_dialog_format_secondary_markup
- - gtk_message_dialog_format_secondary_text
-- uFupp:
- - gtk_timeout_add
-- vFpppi:
- - gtk_enumerate_printers
-- vFpppp:
- - gtk_object_set_data_full
- - gtk_print_job_send
- - gtk_stock_set_translate_func
- - gtk_tree_sortable_set_default_sort_func
- - gtk_tree_view_set_search_equal_func
-- iFpppp:
- - gtk_text_iter_backward_find_char
- - gtk_text_iter_forward_find_char
-- vFpippp:
- - gtk_tree_sortable_set_sort_func
-- vFppppp:
- - gtk_tree_view_column_set_cell_data_func
-- iFppuppp:
- - gtk_clipboard_set_with_data
- - gtk_clipboard_set_with_owner
-- iFpppppp:
- - gtk_init_with_args
-- vFpppppuu:
- - gtk_menu_popup
-- pFppppppi:
- - gtk_toolbar_insert_stock
-- pFppppppp:
- - gtk_toolbar_append_item
- - gtk_toolbar_prepend_item
-- LFppppppii:
- - gtk_signal_connect_full
-- pFpppppppi:
- - gtk_toolbar_insert_item
-- pFpippppppp:
- - gtk_toolbar_append_element
- - gtk_toolbar_prepend_element
-- pFpipppppppi:
- - gtk_toolbar_insert_element
-wrappedgtkx112:
-- fFp:
- - gtk_spin_button_get_value_as_float
-- pFi:
- - gtk_type_class
-- vFpp:
- - gtk_builder_connect_signals
- - gtk_init
-- iFpp:
- - gtk_init_check
- - gtk_type_unique
-- pFiV:
- - gtk_list_store_new
- - gtk_tree_store_new
-- pFpi:
- - gtk_type_check_object_cast
-- vFppp:
- - gtk_builder_connect_signals_full
- - gtk_clipboard_request_text
- - gtk_container_forall
- - gtk_container_foreach
- - gtk_menu_attach_to_widget
- - gtk_tree_model_foreach
- - gtk_tree_selection_selected_foreach
-- vFppV:
- - gtk_dialog_add_buttons
- - gtk_list_store_set
- - gtk_message_dialog_format_secondary_markup
- - gtk_message_dialog_format_secondary_text
- - gtk_tree_model_get
- - gtk_widget_style_get
-- vFppA:
- - gtk_list_store_set_valist
- - gtk_tree_model_get_valist
- - gtk_widget_style_get_valist
-- uFupp:
- - gtk_timeout_add
-- pFppp:
- - gtk_link_button_set_uri_hook
-- vFppiV:
- - gtk_list_store_insert_with_values
-- vFppup:
- - gtk_action_group_add_actions
-- vFpppp:
- - gtk_clipboard_request_contents
- - gtk_object_set_data_full
- - gtk_stock_set_translate_func
- - gtk_tree_sortable_set_default_sort_func
- - gtk_tree_view_set_search_equal_func
-- iFpppp:
- - gtk_text_iter_backward_find_char
- - gtk_text_iter_forward_find_char
-- LFpppp:
- - gtk_signal_connect
-- vFpippp:
- - gtk_tree_sortable_set_sort_func
-- vFppupp:
- - gtk_action_group_add_actions_full
-- vFppppp:
- - gtk_cell_layout_set_cell_data_func
- - gtk_tree_view_column_set_cell_data_func
-- vFpuipuV:
- - gtk_binding_entry_add_signal
-- iFppuppp:
- - gtk_clipboard_set_with_data
- - gtk_clipboard_set_with_owner
-- iFpppppp:
- - gtk_init_with_args
-- uFiipppp:
- - gtk_input_add_full
-- vFpppppuu:
- - gtk_menu_popup
-- pFppppppi:
- - gtk_toolbar_insert_stock
-- pFppppppp:
- - gtk_toolbar_append_item
- - gtk_toolbar_prepend_item
-- LFppppppii:
- - gtk_signal_connect_full
-- pFpppppppi:
- - gtk_toolbar_insert_item
-- pFpippppppp:
- - gtk_toolbar_append_element
- - gtk_toolbar_prepend_element
-- pFpipppppppi:
- - gtk_toolbar_insert_element
-wrappedkrb5:
-- iFppppppipp:
- - krb5_get_init_creds_password
-wrappedlber:
-wrappedldapr:
-- iFpppppupp:
- - ldap_sasl_interactive_bind_s
-wrappedldlinux:
-- pFp:
- - __tls_get_addr
-wrappedlibasound:
-- iFp:
- - snd_dlclose
- - snd_lib_error_set_handler
-- pFppp:
- - snd_dlsym
-- iFpipp:
- - snd_async_add_handler
-- iFpppp:
- - snd_async_add_pcm_handler
-- pFpipL:
- - snd_dlopen
-wrappedlibc:
-- vFv:
- - _Jv_RegisterClasses
- - __cxa_pure_virtual
- - __stack_chk_fail
-- vFi:
- - _exit
- - exit
-- vFp:
- - _ITM_deregisterTMCloneTable
- - __cxa_finalize
-- iFv:
- - fork
- - vfork
-- iFi:
- - iopl
-- iFp:
- - _setjmp
- - atexit
- - getcontext
- - register_printf_type
- - setcontext
- - setjmp
- - stime
- - uname
-- lFv:
- - syscall
-- LFL:
- - getauxval
-- pFp:
- - __deregister_frame_info
- - mallinfo
-- vFpi:
- - __longjmp_chk
- - _longjmp
- - _obstack_newchunk
- - longjmp
- - siglongjmp
-- vFpu:
- - _ITM_registerTMCloneTable
-- vFpp:
- - __register_frame_info
- - _obstack_free
- - obstack_free
- - tdestroy
-- vFpV:
- - warn
- - warnx
-- iFip:
- - fstat
- - fstat64
-- iFpi:
- - __sigsetjmp
- - backtrace
- - sigsetjmp
-- iFpL:
- - munmap
-- iFpp:
- - __vprintf_chk
- - dl_iterate_phdr
- - execv
- - execvp
- - lstat
- - lstat64
- - sigaltstack
- - stat
- - stat64
- - swapcontext
-- iFpV:
- - __isoc99_scanf
- - execl
- - execlp
- - printf
- - wprintf
-- iFpA:
- - vprintf
-- iFSp:
- - _IO_file_stat
-- pFip:
- - __sysv_signal
- - signal
- - sigset
- - sysv_signal
-- pFpi:
- - backtrace_symbols
-- pFpp:
- - __realpath_chk
- - fopen
- - fopen64
- - realpath
-- vFipV:
- - err
- - errx
- - syslog
-- vFipA:
- - vsyslog
-- vFpii:
- - backtrace_symbols_fd
-- vFpup:
- - _ITM_addUserCommitAction
-- iFiip:
- - __fxstat
- - __fxstat64
-- iFiiN:
- - __fcntl
- - fcntl
- - fcntl64
-- iFipp:
- - __lxstat
- - __lxstat64
- - __sigaction
- - __xstat
- - __xstat64
- - getopt
- - register_printf_specifier
- - sigaction
-- iFipV:
- - __printf_chk
-- iFpLi:
- - mprotect
-- iFppi:
- - ftw
- - ftw64
-- iFppp:
- - __cxa_atexit
- - __cxa_thread_atexit_impl
- - __isoc99_vfscanf
- - __isoc99_vsscanf
- - __vfprintf_chk
- - __vsscanf
- - execve
-- iFppV:
- - __asprintf
- - __isoc99_fscanf
- - __isoc99_sscanf
- - asprintf
- - fprintf
- - fscanf
- - fwprintf
- - sprintf
- - sscanf
- - swscanf
-- iFppA:
- - obstack_vprintf
- - vasprintf
- - vfprintf
- - vfscanf
- - vfwprintf
- - vsprintf
- - vsscanf
- - vswscanf
-- iFpOu:
- - __open
- - open
- - open64
-- lFipV:
- - __wprintf_chk
-- lFppL:
- - readlink
-- LFppL:
- - strlcat
- - strlcpy
-- pFpip:
- - fts64_open
- - fts_open
-- pFppp:
- - tsearch
-- vFiipV:
- - __syslog_chk
-- vFiipA:
- - __vsyslog_chk
-- vFpLLp:
- - qsort
-- iFiiip:
- - epoll_ctl
-- iFiiiN:
- - semctl
-- iFipii:
- - epoll_wait
-- iFippi:
- - fstatat
- - fstatat64
-- iFippL:
- - readlinkat
-- iFpipp:
- - __vasprintf_chk
- - glob
- - glob64
-- iFpipV:
- - __asprintf_chk
- - __fprintf_chk
- - __fwprintf_chk
-- iFpipA:
- - __vfwprintf_chk
-- iFpLpp:
- - __vsnprintf_chk
-- iFpLpV:
- - __snprintf
- - snprintf
- - swprintf
-- iFpLpA:
- - __vsnprintf
- - vsnprintf
- - vswprintf
-- iFppii:
- - nftw64
-- iFppiV:
- - makecontext
-- iFpppp:
- - __register_atfork
- - __vsprintf_chk
- - scandir
- - scandir64
-- vFpLLpp:
- - qsort_r
-- iFiippi:
- - __fxstatat
- - __fxstatat64
-- iFiLLLL:
- - prctl
-- iFipiip:
- - epoll_pwait
-- iFipppp:
- - getopt_long
- - getopt_long_only
- - scandirat
-- iFpilpV:
- - __sprintf_chk
-- iFpuppp:
- - __vswprintf_chk
-- iFpLLpp:
- - _obstack_begin
-- pFpLLiN:
- - mremap
-- pFppLLp:
- - bsearch
-- pFpppLp:
- - lfind
- - lsearch
-- iFpLiLpV:
- - __snprintf_chk
- - __swprintf_chk
-- iFpppppp:
- - posix_spawn
- - posix_spawnp
-- pFpLiiil:
- - mmap
- - mmap64
-- iFpippppp:
- - __libc_start_main
-- iFppipppp:
- - clone
-wrappedlibcrypt:
-wrappedlibcups:
-wrappedlibdl:
-- iFp:
- - dlclose
-- pFv:
- - dlerror
-- iFpp:
- - _dl_find_object
- - dladdr
-- pFpi:
- - dlopen
-- pFpp:
- - dlsym
-- iFpip:
- - dlinfo
-- pFppi:
- - dlmopen
-- pFppp:
- - dlvsym
-- iFpppi:
- - dladdr1
-wrappedlibdrm:
-wrappedlibegl:
-- pFp:
- - eglGetProcAddress
-wrappedlibform:
-wrappedlibformw:
-wrappedlibfuse:
-- iFpp:
- - fuse_reply_entry
-- iFppd:
- - fuse_reply_attr
-- iFppp:
- - fuse_reply_create
-- iFpppp:
- - fuse_opt_parse
-- pFppLp:
- - fuse_lowlevel_new
-- iFippLp:
- - fuse_main_real
-- LFppLppU:
- - fuse_add_direntry
-wrappedlibgl:
-- iFi:
- - glXSwapIntervalMESA
-- pFp:
- - glGetVkProcAddrNV
- - glXGetProcAddress
- - glXGetProcAddressARB
-- vFpp:
- - glDebugMessageCallback
- - glDebugMessageCallbackAMD
- - glDebugMessageCallbackARB
- - glDebugMessageCallbackKHR
-- vFipp:
- - glProgramCallbackMESA
-wrappedlibglu:
-- vFpip:
- - gluNurbsCallback
- - gluQuadricCallback
- - gluTessCallback
-wrappedlibglx:
-- pFp:
- - glXGetProcAddress
- - glXGetProcAddressARB
-wrappedlibibus:
-- vFpippp:
- - ibus_bus_current_input_context_async
- - ibus_bus_get_global_engine_async
- - ibus_bus_list_active_engines_async
- - ibus_bus_list_engines_async
- - ibus_input_context_get_engine_async
-- vFppippp:
- - ibus_bus_create_input_context_async
- - ibus_bus_set_global_engine_async
- - ibus_config_get_values_async
-- vFpppippp:
- - ibus_config_get_value_async
-- vFpuuuippp:
- - ibus_input_context_process_key_event_async
-- vFppppippp:
- - ibus_config_set_value_async
-wrappedlibice:
-wrappedlibm:
-- UFV:
- - cacosf
- - cacoshf
- - casinf
- - casinhf
- - catanf
- - catanhf
-- fFf:
- - __acosf_finite
- - __acoshf_finite
- - __asinf_finite
- - __coshf_finite
- - __exp2f_finite
- - __expf_finite
- - __log10f_finite
- - __log2f_finite
- - __logf_finite
- - __sinhf_finite
- - __sqrtf_finite
-- dFd:
- - __acos_finite
- - __acosh_finite
- - __asin_finite
- - __cosh_finite
- - __exp2_finite
- - __exp_finite
- - __log10_finite
- - __log2_finite
- - __log_finite
- - __sinh_finite
- - __sqrt_finite
-- fFff:
- - __atan2f_finite
- - __fmodf_finite
- - __hypotf_finite
- - __powf_finite
-- dFdd:
- - __atan2_finite
- - __fmod_finite
- - __hypot_finite
- - __pow_finite
-wrappedlibncurses:
-- pFv:
- - initscr
-- iFpV:
- - printw
-- iFppA:
- - vwprintw
-- iFiipV:
- - mvprintw
-- iFpiipV:
- - mvwprintw
-wrappedlibncurses6:
-- pFv:
- - initscr
-- iFpV:
- - printw
-- iFppV:
- - wprintw
-- iFppA:
- - vwprintw
-- iFiipV:
- - mvprintw
-- iFpiipV:
- - mvwprintw
-wrappedlibncursesw:
-- pFv:
- - initscr
-- iFpV:
- - printw
-- iFppV:
- - wprintw
-- iFppA:
- - vwprintw
-- iFiipV:
- - mvprintw
-- iFpiipV:
- - mvwprintw
-wrappedlibncursesw6:
-- pFv:
- - initscr
-- iFpV:
- - printw
-- iFppA:
- - vwprintw
-- iFiipV:
- - mvprintw
-- iFpiipV:
- - mvwprintw
-wrappedlibogg:
-wrappedlibpanel:
-wrappedlibpci:
-wrappedlibpcre:
-wrappedlibpthread:
-- vFp:
- - __pthread_register_cancel
- - __pthread_unregister_cancel
- - __pthread_unwind_next
-- iFp:
- - __pthread_mutex_destroy
- - __pthread_mutex_lock
- - __pthread_mutex_trylock
- - __pthread_mutex_unlock
- - __pthread_mutexattr_destroy
- - __pthread_mutexattr_init
- - pthread_attr_destroy
- - pthread_attr_init
- - pthread_barrierattr_destroy
- - pthread_barrierattr_init
- - pthread_cond_broadcast
- - pthread_cond_destroy
- - pthread_condattr_destroy
- - pthread_condattr_init
- - pthread_getattr_default_np
- - pthread_mutex_destroy
- - pthread_mutex_lock
- - pthread_mutex_trylock
- - pthread_mutex_unlock
- - pthread_mutexattr_destroy
- - pthread_mutexattr_init
- - pthread_setattr_default_np
-- vFpi:
- - _pthread_cleanup_pop
- - _pthread_cleanup_pop_restore
-- iFLp:
- - pthread_getattr_np
-- iFpi:
- - __pthread_mutexattr_settype
- - pthread_attr_setdetachstate
- - pthread_attr_setinheritsched
- - pthread_attr_setschedpolicy
- - pthread_attr_setscope
- - pthread_barrierattr_setpshared
- - pthread_condattr_setclock
- - pthread_condattr_setpshared
- - pthread_kill
- - pthread_kill@GLIBC_2.2.5
- - pthread_mutexattr_setkind_np
- - pthread_mutexattr_setprotocol
- - pthread_mutexattr_setpshared
- - pthread_mutexattr_settype
-- iFpL:
- - pthread_attr_setguardsize
- - pthread_attr_setstacksize
-- iFpp:
- - __pthread_key_create
- - __pthread_mutex_init
- - __pthread_once
- - pthread_attr_getdetachstate
- - pthread_attr_getguardsize
- - pthread_attr_getinheritsched
- - pthread_attr_getschedparam
- - pthread_attr_getschedpolicy
- - pthread_attr_getscope
- - pthread_attr_getstackaddr
- - pthread_attr_getstacksize
- - pthread_attr_setschedparam
- - pthread_attr_setstackaddr
- - pthread_barrierattr_getpshared
- - pthread_cond_init
- - pthread_cond_wait
- - pthread_condattr_getclock
- - pthread_condattr_getpshared
- - pthread_key_create
- - pthread_mutex_init
- - pthread_mutex_timedlock
- - pthread_mutexattr_getkind_np
- - pthread_mutexattr_getprotocol
- - pthread_mutexattr_gettype
- - pthread_once
-- vFppp:
- - _pthread_cleanup_push
- - _pthread_cleanup_push_defer
-- iFpLp:
- - pthread_attr_setaffinity_np
- - pthread_getaffinity_np
- - pthread_setaffinity_np
-- iFppu:
- - pthread_barrier_init
-- iFppL:
- - pthread_attr_setstack
-- iFppp:
- - __pthread_atfork
- - pthread_atfork
- - pthread_attr_getstack
- - pthread_cond_timedwait
-- iFppip:
- - pthread_cond_clockwait
-- iFpppp:
- - pthread_create
-wrappedlibresolv:
-wrappedlibrt:
-- iFupp:
- - timer_create
-wrappedlibsm:
-- iFppp:
- - SmcRequestSaveYourselfPhase2
-- iFpipp:
- - SmcInteractRequest
-- pFppiiLpppip:
- - SmcOpenConnection
-wrappedlibsndfile:
-- iFp:
- - sf_close
-- pFpipp:
- - sf_open_virtual
-wrappedlibssl:
-- pFp:
- - SSL_get_verify_callback
-- vFpp:
- - SSL_CTX_set_client_cert_cb
- - SSL_CTX_set_default_passwd_cb
- - SSL_set_psk_client_callback
-- vFpip:
- - SSL_CTX_set_verify
- - SSL_set_verify
-- vFppp:
- - SSL_CTX_set_cert_verify_callback
- - SSL_CTX_set_next_proto_select_cb
-- lFpip:
- - SSL_CTX_callback_ctrl
- - SSL_callback_ctrl
-- iFlpppp:
- - SSL_get_ex_new_index
-wrappedlibtinfo:
-- iFpip:
- - tputs
-wrappedlibtinfo6:
-- iFpip:
- - tputs
-wrappedlibusb1:
-- iFp:
- - libusb_cancel_transfer
- - libusb_submit_transfer
-- pFi:
- - libusb_alloc_transfer
-- iFpiiiiippp:
- - libusb_hotplug_register_callback
-wrappedlibuuid:
-wrappedlibva:
-wrappedlibvadrm:
-wrappedlibvawayland:
-wrappedlibvax11:
-wrappedlibvdpau:
-wrappedlibvorbis:
-wrappedlibx11:
-- iFp:
- - XDestroyImage
- - XInitImage
-- pFp:
- - XOpenDisplay
- - XSetErrorHandler
- - XSetIOErrorHandler
-- vFpp:
- - _XDeqAsyncHandler
-- pFiV:
- - XVaCreateNestedList
-- pFpi:
- - XSynchronize
-- pFpp:
- - XSetAfterFunction
-- pFpV:
- - XCreateIC
- - XSetICValues
- - XSetIMValues
-- iFppp:
- - XAddConnectionWatch
- - XRemoveConnectionWatch
-- pFpip:
- - XESetCloseDisplay
- - XESetError
- - XESetEventToWire
- - XESetWireToEvent
-- iFpppp:
- - XCheckIfEvent
- - XIfEvent
- - XPeekIfEvent
-- iFppppp:
- - XQueryExtension
-- iFpppppp:
- - XRegisterIMInstantiateCallback
- - XUnregisterIMInstantiateCallback
-- pFppiiuuLi:
- - XGetImage
-- iFppppiiiiuu:
- - XPutImage
-- pFppuiipuuii:
- - XCreateImage
-- pFppiiuuuipii:
- - XGetSubImage
-wrappedlibx11xcb:
-wrappedlibxau:
-wrappedlibxcb:
-wrappedlibxcbdri2:
-% x my_xcb_cookie_t u
-wrappedlibxcbdri3:
-wrappedlibxcbglx:
-wrappedlibxcbicccm:
-wrappedlibxcbimage:
-wrappedlibxcbkeysyms:
-wrappedlibxcbpresent:
-wrappedlibxcbrandr:
-wrappedlibxcbrender:
-wrappedlibxcbrenderutil:
-wrappedlibxcbshape:
-wrappedlibxcbshm:
-wrappedlibxcbsync:
-wrappedlibxcbutil:
-wrappedlibxcbxfixes:
-wrappedlibxcbxinerama:
-wrappedlibxcbxkb:
-wrappedlibxcbxtest:
-wrappedlibxcomposite:
-wrappedlibxcursor:
-wrappedlibxdamage:
-wrappedlibxdmcp:
-wrappedlibxext:
-- pFp:
- - XSetExtensionErrorHandler
-- iFpppiiu:
- - XShmGetImage
-- pFppppip:
- - XextAddDisplay
-- pFppuippuu:
- - XShmCreateImage
-- iFppppiiiiuui:
- - XShmPutImage
-wrappedlibxfixes:
-wrappedlibxft:
-wrappedlibxi:
-wrappedlibxmu:
-wrappedlibxpm:
-wrappedlibxpresent:
-wrappedlibxrandr:
-wrappedlibxrender:
-wrappedlibxss:
-wrappedlibxt:
-- lFppp:
- - XtAppAddWorkProc
-- vFpuipp:
- - XtAddEventHandler
-- lFpippp:
- - XtAppAddInput
-wrappedlibxtst:
-- iFpppp:
- - XRecordEnableContext
- - XRecordEnableContextAsync
-wrappedlibxxf86vm:
-wrappedlibz:
-- iFp:
- - deflateEnd
- - inflateEnd
-- iFpi:
- - inflate
-- iFppi:
- - inflateInit_
-- iFpipi:
- - deflateInit_
- - inflateInit2_
-- iFpippi:
- - inflateBackInit_
-- iFpiiiiipi:
- - deflateInit2_
-wrappedlzma:
-- vFpp:
- - lzma_index_end
-- iFpU:
- - lzma_alone_decoder
-- iFpp:
- - lzma_alone_encoder
- - lzma_raw_decoder
- - lzma_raw_encoder
-- iFpui:
- - lzma_easy_encoder
-- iFpUi:
- - lzma_stream_decoder
-- iFppi:
- - lzma_stream_encoder
-- iFpppL:
- - lzma_properties_decode
-- iFpppppL:
- - lzma_index_buffer_decode
-- iFpupppLppL:
- - lzma_stream_buffer_decode
-wrappedmpg123:
-- iFpppp:
- - mpg123_replace_reader_handle
- - mpg123_replace_reader_handle_32
- - mpg123_replace_reader_handle_64
-wrappednotify:
-wrappednsl:
-wrappednspr4:
-wrappednss3:
-- vFp:
- - PK11_SetPasswordFunc
-- iFpp:
- - CERT_RegisterAlternateOCSPAIAInfoCallBack
-- iFpIppp:
- - CERT_PKIXVerifyCert
-wrappednssutil3:
-wrappedopenal:
-- vFv:
- - alRequestFoldbackStop
-- pFp:
- - alGetProcAddress
-- pFpp:
- - alcGetProcAddress
-- vFiiipp:
- - alRequestFoldbackStart
-wrappedpango:
-- vFpp:
- - pango_attribute_init
-wrappedpangocairo:
-wrappedpangoft2:
-wrappedplc4:
-wrappedplds4:
-wrappedpng16:
-- vFpp:
- - png_set_read_user_transform_fn
-- vFppp:
- - png_set_read_fn
-- vFpppp:
- - png_set_error_fn
- - png_set_write_fn
-- pFpppp:
- - png_create_read_struct
-- vFppppp:
- - png_set_progressive_read_fn
-- pFppppppp:
- - png_create_read_struct_2
- - png_create_write_struct_2
-wrappedpulse:
-- vFp:
- - pa_mainloop_free
- - pa_threaded_mainloop_free
-- iFp:
- - pa_signal_init
-- pFp:
- - pa_mainloop_get_api
- - pa_threaded_mainloop_get_api
-- vFpp:
- - pa_signal_set_destroy
-- pFpp:
- - pa_context_new
-- vFppp:
- - pa_context_set_event_callback
- - pa_context_set_state_callback
- - pa_context_set_subscribe_callback
- - pa_mainloop_set_poll_func
- - pa_stream_set_buffer_attr_callback
- - pa_stream_set_event_callback
- - pa_stream_set_latency_update_callback
- - pa_stream_set_moved_callback
- - pa_stream_set_overflow_callback
- - pa_stream_set_read_callback
- - pa_stream_set_started_callback
- - pa_stream_set_state_callback
- - pa_stream_set_suspended_callback
- - pa_stream_set_underflow_callback
- - pa_stream_set_write_callback
-- pFipp:
- - pa_signal_new
-- pFppp:
- - pa_context_drain
- - pa_context_exit_daemon
- - pa_context_get_card_info_list
- - pa_context_get_client_info_list
- - pa_context_get_module_info_list
- - pa_context_get_server_info
- - pa_context_get_sink_info_list
- - pa_context_get_sink_input_info_list
- - pa_context_get_source_info_list
- - pa_context_get_source_output_info_list
- - pa_context_new_with_proplist
- - pa_ext_device_restore_read_formats_all
- - pa_ext_device_restore_set_subscribe_cb
- - pa_stream_drain
- - pa_stream_flush
- - pa_stream_prebuf
- - pa_stream_trigger
- - pa_stream_update_timing_info
-- iFppip:
- - pa_context_connect
-- iFpppV:
- - pa_proplist_setf
-- pFpipp:
- - pa_ext_device_restore_subscribe
- - pa_stream_cork
-- pFpupp:
- - pa_context_get_card_info_by_index
- - pa_context_get_client_info
- - pa_context_get_sink_info_by_index
- - pa_context_get_sink_input_info
- - pa_context_get_source_info_by_index
- - pa_context_get_source_output_info
- - pa_context_subscribe
- - pa_context_unload_module
- - pa_stream_update_sample_rate
-- pFpppp:
- - pa_context_get_sink_info_by_name
- - pa_context_get_source_info_by_name
- - pa_context_proplist_remove
- - pa_context_set_default_sink
- - pa_context_set_default_source
- - pa_context_set_name
- - pa_stream_proplist_remove
- - pa_stream_set_buffer_attr
- - pa_stream_set_name
-- pFpiupp:
- - pa_ext_device_restore_read_formats
-- pFpippp:
- - pa_context_proplist_update
- - pa_stream_proplist_update
-- pFpuipp:
- - pa_context_set_sink_input_mute
- - pa_context_set_sink_mute_by_index
- - pa_context_set_source_mute_by_index
-- pFpuupp:
- - pa_context_move_sink_input_by_index
- - pa_context_move_source_output_by_index
-- pFpuppp:
- - pa_context_set_card_profile_by_index
- - pa_context_set_sink_input_volume
- - pa_context_set_sink_port_by_index
- - pa_context_set_sink_volume_by_index
- - pa_context_set_source_port_by_index
- - pa_context_set_source_volume_by_index
-- pFppppp:
- - pa_context_load_module
- - pa_context_set_sink_port_by_name
- - pa_context_set_source_volume_by_name
-- iFppLpIi:
- - pa_stream_write
-- pFpiuCppp:
- - pa_ext_device_restore_save_formats
-wrappedpulsesimple:
-wrappedsdl1:
-- vFp:
- - SDL_KillThread
- - SDL_SetEventFilter
- - SDL_UnloadObject
-- iFv:
- - SDL_Has3DNow
- - SDL_Has3DNowExt
- - SDL_HasAltiVec
- - SDL_HasMMX
- - SDL_HasMMXExt
- - SDL_HasRDTSC
- - SDL_HasSSE
- - SDL_HasSSE2
-- iFp:
- - SDL_GetWMInfo
- - SDL_RemoveTimer
-- uFp:
- - SDL_ReadBE16
- - SDL_ReadBE32
- - SDL_ReadLE16
- - SDL_ReadLE32
-- UFp:
- - SDL_ReadBE64
- - SDL_ReadLE64
-- pFv:
- - SDL_GetEventFilter
-- pFp:
- - SDL_GL_GetProcAddress
- - SDL_LoadObject
-- iFup:
- - SDL_SetTimer
-- iFpp:
- - SDL_OpenAudio
-- uFpW:
- - SDL_WriteBE16
- - SDL_WriteLE16
-- uFpu:
- - SDL_WriteBE32
- - SDL_WriteLE32
-- uFpU:
- - SDL_WriteBE64
- - SDL_WriteLE64
-- pFpi:
- - SDL_LoadBMP_RW
- - SDL_RWFromConstMem
- - SDL_RWFromFP
- - SDL_RWFromMem
-- pFpp:
- - SDL_CreateThread
- - SDL_LoadFunction
- - SDL_RWFromFile
-- iFppi:
- - SDL_SaveBMP_RW
-- pFupp:
- - SDL_AddTimer
-- pFpippp:
- - SDL_LoadWAV_RW
-wrappedsdl1image:
-- pFp:
- - IMG_LoadBMP_RW
- - IMG_LoadCUR_RW
- - IMG_LoadGIF_RW
- - IMG_LoadICO_RW
- - IMG_LoadJPG_RW
- - IMG_LoadLBM_RW
- - IMG_LoadPCX_RW
- - IMG_LoadPNG_RW
- - IMG_LoadPNM_RW
- - IMG_LoadTGA_RW
- - IMG_LoadTIF_RW
- - IMG_LoadWEBP_RW
- - IMG_LoadXCF_RW
- - IMG_LoadXPM_RW
- - IMG_LoadXV_RW
-- pFpi:
- - IMG_Load_RW
-- pFpip:
- - IMG_LoadTyped_RW
-wrappedsdl1mixer:
-- vFp:
- - Mix_ChannelFinished
- - Mix_HookMusicFinished
-- pFp:
- - Mix_LoadMUS_RW
-- vFpp:
- - Mix_HookMusic
- - Mix_SetPostMix
-- iFip:
- - Mix_UnregisterEffect
-- pFpi:
- - Mix_LoadWAV_RW
-- pFpii:
- - Mix_LoadMUSType_RW
-- iFippp:
- - Mix_RegisterEffect
-wrappedsdl1net:
-wrappedsdl1sound:
-- pFpppu:
- - Sound_NewSample
-wrappedsdl1ttf:
-- pFpii:
- - TTF_OpenFontRW
-- pFpiii:
- - TTF_OpenFontIndexRW
-wrappedsdl2:
-% G SDL_JoystickGUID UU
-- vFp:
- - SDL_UnloadObject
-- iFv:
- - SDL_Has3DNow
- - SDL_HasAVX
- - SDL_HasAVX2
- - SDL_HasAVX512F
- - SDL_HasAltiVec
- - SDL_HasMMX
- - SDL_HasNEON
- - SDL_HasRDTSC
- - SDL_HasSSE
- - SDL_HasSSE2
- - SDL_HasSSE3
- - SDL_HasSSE41
- - SDL_HasSSE42
-- iFp:
- - SDL_RWclose
- - SDL_RemoveTimer
- - SDL_SaveAllDollarTemplates
-- IFp:
- - SDL_RWtell
-- uFp:
- - SDL_ReadBE16
- - SDL_ReadBE32
- - SDL_ReadLE16
- - SDL_ReadLE32
- - SDL_ReadU8
-- UFp:
- - SDL_ReadBE64
- - SDL_ReadLE64
-- pFv:
- - SDL_GetBasePath
- - SDL_Vulkan_GetVkGetInstanceProcAddr
-- pFp:
- - SDL_GL_GetProcAddress
- - SDL_LoadObject
-- vFpp:
- - SDL_AddEventWatch
- - SDL_DelEventWatch
- - SDL_LogGetOutputFunction
- - SDL_LogSetOutputFunction
- - SDL_SetEventFilter
-- vFpV:
- - SDL_Log
-- iFip:
- - SDL_SaveDollarTemplate
-- iFWW:
- - SDL_IsJoystickNintendoSwitchPro
- - SDL_IsJoystickPS4
- - SDL_IsJoystickSteamController
- - SDL_IsJoystickXbox360
- - SDL_IsJoystickXboxOne
-- iFUU:
- - SDL_IsJoystickHIDAPI
- - SDL_IsJoystickXInput
-- iFpi:
- - SDL_GameControllerAddMappingsFromRW
-- iFpp:
- - SDL_GetEventFilter
- - SDL_OpenAudio
-- uFpW:
- - SDL_WriteBE16
- - SDL_WriteLE16
-- uFpu:
- - SDL_WriteBE32
- - SDL_WriteLE32
- - SDL_WriteU8
-- uFpU:
- - SDL_WriteBE64
- - SDL_WriteLE64
-- pFpi:
- - SDL_LoadBMP_RW
- - SDL_RWFromConstMem
- - SDL_RWFromFP
- - SDL_RWFromMem
-- pFpp:
- - SDL_LoadFunction
- - SDL_RWFromFile
-- vFipV:
- - SDL_LogCritical
- - SDL_LogDebug
- - SDL_LogError
- - SDL_LogInfo
- - SDL_LogVerbose
- - SDL_LogWarn
-- iFupu:
- - SDL_DYNAPI_entry
-- iFupp:
- - SDL_TLSSet
-- iFppi:
- - SDL_SaveBMP_RW
-- iFppV:
- - SDL_sscanf
-- IFpIi:
- - SDL_RWseek
-- pFupp:
- - SDL_AddTimer
-- pFppi:
- - SDL_LoadFile_RW
-- pFppp:
- - SDL_CreateThread
-- vFpuup:
- - SDL_qsort
-- vFGppp:
- - SDL_GetJoystickGUIDInfo
-- iFpLpp:
- - SDL_vsnprintf
-- iFpLpV:
- - SDL_snprintf
-- uFppuu:
- - SDL_RWread
- - SDL_RWwrite
-- iFpippi:
- - SDL_OpenAudioDevice
-- pFpippp:
- - SDL_LoadWAV_RW
-% vFGppp
-wrappedsdl2image:
-- pFp:
- - IMG_LoadBMP_RW
- - IMG_LoadCUR_RW
- - IMG_LoadGIF_RW
- - IMG_LoadICO_RW
- - IMG_LoadJPG_RW
- - IMG_LoadLBM_RW
- - IMG_LoadPCX_RW
- - IMG_LoadPNG_RW
- - IMG_LoadPNM_RW
- - IMG_LoadTGA_RW
- - IMG_LoadTIF_RW
- - IMG_LoadWEBP_RW
- - IMG_LoadXCF_RW
- - IMG_LoadXPM_RW
- - IMG_LoadXV_RW
-- pFpi:
- - IMG_Load_RW
-- iFppi:
- - IMG_SavePNG_RW
-- pFpip:
- - IMG_LoadTyped_RW
-- pFppi:
- - IMG_LoadTexture_RW
-- pFppip:
- - IMG_LoadTextureTyped_RW
-wrappedsdl2mixer:
-- vFp:
- - Mix_ChannelFinished
- - Mix_HookMusicFinished
-- vFpp:
- - Mix_HookMusic
- - Mix_SetPostMix
-- iFiw:
- - MinorityMix_SetPosition
-- iFip:
- - Mix_UnregisterEffect
-- pFpi:
- - Mix_LoadMUS_RW
- - Mix_LoadWAV_RW
-- pFpii:
- - Mix_LoadMUSType_RW
-- iFippp:
- - Mix_RegisterEffect
-wrappedsdl2net:
-wrappedsdl2ttf:
-- pFpii:
- - TTF_OpenFontRW
-- pFpiii:
- - TTF_OpenFontIndexRW
-wrappedsecret1:
-wrappedselinux:
-wrappedsmime3:
-- iFpp:
- - SEC_PKCS12DecoderValidateBags
-- iFppp:
- - SEC_PKCS12Encode
-- pFpppp:
- - SEC_PKCS12CreateExportContext
-- pFpppppppp:
- - SEC_PKCS12DecoderStart
-- pFppppppppppp:
- - NSS_CMSEncoder_Start
-wrappedsmpeg:
-- pFppi:
- - SMPEG_new_rwops
-- vFpppp:
- - SMPEG_setdisplay
-wrappedsmpeg2:
-- vFpppp:
- - SMPEG_setdisplay
-- pFppii:
- - SMPEG_new_rwops
-wrappedsoftokn3:
-wrappedssl3:
-wrappedtbbmalloc:
-- vFp:
- - scalable_aligned_free
-- LFp:
- - scalable_msize
-- LFpp:
- - safer_scalable_msize
-- pFLL:
- - scalable_aligned_malloc
- - scalable_calloc
-- pFpp:
- - safer_scalable_free
-- pFpLL:
- - scalable_aligned_realloc
-- pFpLp:
- - safer_scalable_realloc
-- pFpLLp:
- - safer_scalable_aligned_realloc
-wrappedtbbmallocproxy:
-- vFp:
- - _ZdaPv
- - _ZdlPv
- - __RML_close_factory
-- pFL:
- - _Znam
- - _Znwm
-- vFpp:
- - _ZdaPvRKSt9nothrow_t
- - _ZdlPvRKSt9nothrow_t
- - __TBB_call_with_my_server_info
-- pFLp:
- - _ZnamRKSt9nothrow_t
- - _ZnwmRKSt9nothrow_t
-- iFipp:
- - __TBB_internal_find_original_malloc
-- iFppi:
- - __RML_open_factory
-- iFppp:
- - __TBB_make_rml_server
-wrappedtcmallocminimal:
-- pFp:
- - mallinfo
-- iFpL:
- - munmap
-- pFpLiiii:
- - mmap
-- pFpLiiiI:
- - mmap64
-wrappedudev0:
-- vFpp:
- - udev_set_log_fn
-wrappedudev1:
-- vFpp:
- - udev_set_log_fn
-wrappedunwind:
-- iFp:
- - _ULx86_64_step
-- iFpp:
- - _ULx86_64_get_proc_info
- - _ULx86_64_init_local
-- iFpip:
- - _ULx86_64_get_reg
-wrappedutil:
-- iFpppp:
- - forkpty
-wrappedvorbisfile:
-- iFppplPPPP:
- - ov_open_callbacks
- - ov_test_callbacks
-wrappedvulkan:
-- vFpp:
- - vkDestroyDevice
- - vkDestroyInstance
- - vkGetPhysicalDeviceMemoryProperties
- - vkGetPhysicalDeviceProperties
-- pFpp:
- - vkGetDeviceProcAddr
- - vkGetInstanceProcAddr
-- vFpUp:
- - vkDestroyAccelerationStructureKHR
- - vkDestroyAccelerationStructureNV
- - vkDestroyBuffer
- - vkDestroyBufferView
- - vkDestroyCommandPool
- - vkDestroyCuFunctionNVX
- - vkDestroyCuModuleNVX
- - vkDestroyDeferredOperationKHR
- - vkDestroyDescriptorPool
- - vkDestroyDescriptorSetLayout
- - vkDestroyDescriptorUpdateTemplate
- - vkDestroyDescriptorUpdateTemplateKHR
- - vkDestroyEvent
- - vkDestroyFence
- - vkDestroyFramebuffer
- - vkDestroyImage
- - vkDestroyImageView
- - vkDestroyIndirectCommandsLayoutNV
- - vkDestroyOpticalFlowSessionNV
- - vkDestroyPipeline
- - vkDestroyPipelineCache
- - vkDestroyPipelineLayout
- - vkDestroyPrivateDataSlot
- - vkDestroyPrivateDataSlotEXT
- - vkDestroyQueryPool
- - vkDestroyRenderPass
- - vkDestroySampler
- - vkDestroySamplerYcbcrConversionKHR
- - vkDestroySemaphore
- - vkDestroyShaderModule
- - vkDestroySurfaceKHR
- - vkDestroySwapchainKHR
- - vkDestroyValidationCacheEXT
- - vkDestroyVideoSessionKHR
- - vkDestroyVideoSessionParametersKHR
-- vFppp:
- - vkDestroyDebugUtilsMessengerEXT
-- iFpUp:
- - vkFreeMemory
-- iFppp:
- - vkCreateDeferredOperationKHR
- - vkCreateInstance
- - vkDestroyDebugReportCallbackEXT
- - vkGetPhysicalDeviceDisplayPropertiesKHR
-- iFpUup:
- - vkGetDisplayPlaneCapabilitiesKHR
-- iFpppp:
- - vkAllocateMemory
- - vkCreateAccelerationStructureKHR
- - vkCreateAccelerationStructureNV
- - vkCreateBuffer
- - vkCreateBufferView
- - vkCreateCommandPool
- - vkCreateCuFunctionNVX
- - vkCreateCuModuleNVX
- - vkCreateDebugReportCallbackEXT
- - vkCreateDebugUtilsMessengerEXT
- - vkCreateDescriptorPool
- - vkCreateDescriptorSetLayout
- - vkCreateDescriptorUpdateTemplate
- - vkCreateDescriptorUpdateTemplateKHR
- - vkCreateDevice
- - vkCreateDisplayPlaneSurfaceKHR
- - vkCreateEvent
- - vkCreateFence
- - vkCreateFramebuffer
- - vkCreateHeadlessSurfaceEXT
- - vkCreateImage
- - vkCreateImageView
- - vkCreateIndirectCommandsLayoutNV
- - vkCreateOpticalFlowSessionNV
- - vkCreatePipelineCache
- - vkCreatePipelineLayout
- - vkCreatePrivateDataSlot
- - vkCreatePrivateDataSlotEXT
- - vkCreateQueryPool
- - vkCreateRenderPass
- - vkCreateRenderPass2
- - vkCreateRenderPass2KHR
- - vkCreateSampler
- - vkCreateSamplerYcbcrConversion
- - vkCreateSamplerYcbcrConversionKHR
- - vkCreateSemaphore
- - vkCreateShaderModule
- - vkCreateSwapchainKHR
- - vkCreateValidationCacheEXT
- - vkCreateVideoSessionKHR
- - vkCreateVideoSessionParametersKHR
- - vkCreateWaylandSurfaceKHR
- - vkCreateXcbSurfaceKHR
- - vkCreateXlibSurfaceKHR
- - vkRegisterDeviceEventEXT
-- vFpupup:
- - vkUpdateDescriptorSets
-- iFpuppp:
- - vkCreateSharedSwapchainsKHR
-- iFpUppp:
- - vkCreateDisplayModeKHR
- - vkRegisterDisplayEventEXT
-- iFpUuppp:
- - vkCreateComputePipelines
- - vkCreateGraphicsPipelines
- - vkCreateRayTracingPipelinesNV
-- iFpUUuppp:
- - vkCreateRayTracingPipelinesKHR
-- vFpiiiiipp:
- - vkGetPhysicalDeviceSparseImageFormatProperties
-- vFpiiiupupup:
- - vkCmdPipelineBarrier
-wrappedwaylandclient:
-wrappedwaylandcursor:
-wrappedwaylandegl:
-wrappedxinerama:
-wrappedxkbcommon:
-wrappedxkbcommonx11:
-wrappedxml2:
-- vFp:
- - xmlSetExternalEntityLoader
-- iFp:
- - xmlParseDocument
-- pFv:
- - xmlGetExternalEntityLoader
-- vFpp:
- - xmlHashFree
-- pFpp:
- - xmlHashCopy
-- vFppp:
- - xmlHashScan
- - xmlHashScanFull
- - xmlSchemaSetParserStructuredErrors
- - xmlSchemaSetValidStructuredErrors
-- iFppp:
- - xmlHashRemoveEntry
- - xmlXPathRegisterFunc
-- pFppp:
- - xmlNewCharEncodingHandler
-- vFpppp:
- - xmlSchemaSetParserErrors
- - xmlSchemaSetValidErrors
-- iFpppp:
- - xmlHashRemoveEntry2
- - xmlHashUpdateEntry
- - xmlRegisterInputCallbacks
-- pFpppi:
- - xmlParserInputBufferCreateIO
-- pFpppp:
- - xmlOutputBufferCreateIO
-- iFppppp:
- - xmlHashRemoveEntry3
- - xmlHashUpdateEntry2
-- pFppppi:
- - xmlSaveToIO
-- vFpppppp:
- - xmlHashScan3
- - xmlHashScanFull3
-- iFpppppp:
- - xmlHashUpdateEntry3
-- pFpppppi:
- - xmlCreateIOParserCtxt
-wrappedxshmfence:
-wrappedxslt:
-- vFp:
- - xsltSetLoaderFunc
-- iFppp:
- - xsltRegisterExtModuleFunction
diff --git a/src/wrapped/generated/wrappedaluredefs.h b/src/wrapped/generated/wrappedaluredefs.h
deleted file mode 100644
index 71327e1..0000000
--- a/src/wrapped/generated/wrappedaluredefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedalureDEFS_H_
-#define __wrappedalureDEFS_H_
-
-
-#endif // __wrappedalureDEFS_H_
diff --git a/src/wrapped/generated/wrappedaluretypes.h b/src/wrapped/generated/wrappedaluretypes.h
deleted file mode 100644
index affc116..0000000
--- a/src/wrapped/generated/wrappedaluretypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedalureTYPES_H_
-#define __wrappedalureTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedalureTYPES_H_
diff --git a/src/wrapped/generated/wrappedalureundefs.h b/src/wrapped/generated/wrappedalureundefs.h
deleted file mode 100644
index 2ab9a5c..0000000
--- a/src/wrapped/generated/wrappedalureundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedalureUNDEFS_H_
-#define __wrappedalureUNDEFS_H_
-
-
-#endif // __wrappedalureUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedalutdefs.h b/src/wrapped/generated/wrappedalutdefs.h
deleted file mode 100644
index 6b4fa66..0000000
--- a/src/wrapped/generated/wrappedalutdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedalutDEFS_H_
-#define __wrappedalutDEFS_H_
-
-
-#endif // __wrappedalutDEFS_H_
diff --git a/src/wrapped/generated/wrappedaluttypes.h b/src/wrapped/generated/wrappedaluttypes.h
deleted file mode 100644
index c1b133e..0000000
--- a/src/wrapped/generated/wrappedaluttypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedalutTYPES_H_
-#define __wrappedalutTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedalutTYPES_H_
diff --git a/src/wrapped/generated/wrappedalutundefs.h b/src/wrapped/generated/wrappedalutundefs.h
deleted file mode 100644
index 875034d..0000000
--- a/src/wrapped/generated/wrappedalutundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedalutUNDEFS_H_
-#define __wrappedalutUNDEFS_H_
-
-
-#endif // __wrappedalutUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedatkbridgedefs.h b/src/wrapped/generated/wrappedatkbridgedefs.h
deleted file mode 100644
index ebc2be3..0000000
--- a/src/wrapped/generated/wrappedatkbridgedefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedatkbridgeDEFS_H_
-#define __wrappedatkbridgeDEFS_H_
-
-
-#endif // __wrappedatkbridgeDEFS_H_
diff --git a/src/wrapped/generated/wrappedatkbridgetypes.h b/src/wrapped/generated/wrappedatkbridgetypes.h
deleted file mode 100644
index 781ea96..0000000
--- a/src/wrapped/generated/wrappedatkbridgetypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedatkbridgeTYPES_H_
-#define __wrappedatkbridgeTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedatkbridgeTYPES_H_
diff --git a/src/wrapped/generated/wrappedatkbridgeundefs.h b/src/wrapped/generated/wrappedatkbridgeundefs.h
deleted file mode 100644
index 0e76969..0000000
--- a/src/wrapped/generated/wrappedatkbridgeundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedatkbridgeUNDEFS_H_
-#define __wrappedatkbridgeUNDEFS_H_
-
-
-#endif // __wrappedatkbridgeUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedatkdefs.h b/src/wrapped/generated/wrappedatkdefs.h
deleted file mode 100644
index e4899ff..0000000
--- a/src/wrapped/generated/wrappedatkdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedatkDEFS_H_
-#define __wrappedatkDEFS_H_
-
-
-#endif // __wrappedatkDEFS_H_
diff --git a/src/wrapped/generated/wrappedatktypes.h b/src/wrapped/generated/wrappedatktypes.h
deleted file mode 100644
index 83c1349..0000000
--- a/src/wrapped/generated/wrappedatktypes.h
+++ /dev/null
@@ -1,23 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedatkTYPES_H_
-#define __wrappedatkTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFp_t)(void*);
-typedef uint64_t (*uFp_t)(void*);
-typedef uint64_t (*uFpp_t)(void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(atk_focus_tracker_init, vFp_t) \
- GO(atk_add_focus_tracker, uFp_t) \
- GO(atk_add_key_event_listener, uFpp_t)
-
-#endif // __wrappedatkTYPES_H_
diff --git a/src/wrapped/generated/wrappedatkundefs.h b/src/wrapped/generated/wrappedatkundefs.h
deleted file mode 100644
index cd78571..0000000
--- a/src/wrapped/generated/wrappedatkundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedatkUNDEFS_H_
-#define __wrappedatkUNDEFS_H_
-
-
-#endif // __wrappedatkUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedatomicdefs.h b/src/wrapped/generated/wrappedatomicdefs.h
deleted file mode 100644
index 492c68a..0000000
--- a/src/wrapped/generated/wrappedatomicdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedatomicDEFS_H_
-#define __wrappedatomicDEFS_H_
-
-
-#endif // __wrappedatomicDEFS_H_
diff --git a/src/wrapped/generated/wrappedatomictypes.h b/src/wrapped/generated/wrappedatomictypes.h
deleted file mode 100644
index 770bf08..0000000
--- a/src/wrapped/generated/wrappedatomictypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedatomicTYPES_H_
-#define __wrappedatomicTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedatomicTYPES_H_
diff --git a/src/wrapped/generated/wrappedatomicundefs.h b/src/wrapped/generated/wrappedatomicundefs.h
deleted file mode 100644
index b263e73..0000000
--- a/src/wrapped/generated/wrappedatomicundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedatomicUNDEFS_H_
-#define __wrappedatomicUNDEFS_H_
-
-
-#endif // __wrappedatomicUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedatspidefs.h b/src/wrapped/generated/wrappedatspidefs.h
deleted file mode 100644
index f86deee..0000000
--- a/src/wrapped/generated/wrappedatspidefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedatspiDEFS_H_
-#define __wrappedatspiDEFS_H_
-
-
-#endif // __wrappedatspiDEFS_H_
diff --git a/src/wrapped/generated/wrappedatspitypes.h b/src/wrapped/generated/wrappedatspitypes.h
deleted file mode 100644
index 7540f5e..0000000
--- a/src/wrapped/generated/wrappedatspitypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedatspiTYPES_H_
-#define __wrappedatspiTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedatspiTYPES_H_
diff --git a/src/wrapped/generated/wrappedatspiundefs.h b/src/wrapped/generated/wrappedatspiundefs.h
deleted file mode 100644
index 196d462..0000000
--- a/src/wrapped/generated/wrappedatspiundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedatspiUNDEFS_H_
-#define __wrappedatspiUNDEFS_H_
-
-
-#endif // __wrappedatspiUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedbz2defs.h b/src/wrapped/generated/wrappedbz2defs.h
deleted file mode 100644
index e4d73de..0000000
--- a/src/wrapped/generated/wrappedbz2defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedbz2DEFS_H_
-#define __wrappedbz2DEFS_H_
-
-
-#endif // __wrappedbz2DEFS_H_
diff --git a/src/wrapped/generated/wrappedbz2types.h b/src/wrapped/generated/wrappedbz2types.h
deleted file mode 100644
index 88894ca..0000000
--- a/src/wrapped/generated/wrappedbz2types.h
+++ /dev/null
@@ -1,27 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedbz2TYPES_H_
-#define __wrappedbz2TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef int64_t (*iFp_t)(void*);
-typedef int64_t (*iFpi_t)(void*, int64_t);
-typedef int64_t (*iFpii_t)(void*, int64_t, int64_t);
-typedef int64_t (*iFpiii_t)(void*, int64_t, int64_t, int64_t);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(BZ2_bzCompressEnd, iFp_t) \
- GO(BZ2_bzDecompress, iFp_t) \
- GO(BZ2_bzDecompressEnd, iFp_t) \
- GO(BZ2_bzCompress, iFpi_t) \
- GO(BZ2_bzDecompressInit, iFpii_t) \
- GO(BZ2_bzCompressInit, iFpiii_t)
-
-#endif // __wrappedbz2TYPES_H_
diff --git a/src/wrapped/generated/wrappedbz2undefs.h b/src/wrapped/generated/wrappedbz2undefs.h
deleted file mode 100644
index 95fa670..0000000
--- a/src/wrapped/generated/wrappedbz2undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedbz2UNDEFS_H_
-#define __wrappedbz2UNDEFS_H_
-
-
-#endif // __wrappedbz2UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedcairodefs.h b/src/wrapped/generated/wrappedcairodefs.h
deleted file mode 100644
index 829c5a0..0000000
--- a/src/wrapped/generated/wrappedcairodefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedcairoDEFS_H_
-#define __wrappedcairoDEFS_H_
-
-
-#endif // __wrappedcairoDEFS_H_
diff --git a/src/wrapped/generated/wrappedcairogobjectdefs.h b/src/wrapped/generated/wrappedcairogobjectdefs.h
deleted file mode 100644
index e7b2c04..0000000
--- a/src/wrapped/generated/wrappedcairogobjectdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedcairogobjectDEFS_H_
-#define __wrappedcairogobjectDEFS_H_
-
-
-#endif // __wrappedcairogobjectDEFS_H_
diff --git a/src/wrapped/generated/wrappedcairogobjecttypes.h b/src/wrapped/generated/wrappedcairogobjecttypes.h
deleted file mode 100644
index 62eb726..0000000
--- a/src/wrapped/generated/wrappedcairogobjecttypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedcairogobjectTYPES_H_
-#define __wrappedcairogobjectTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedcairogobjectTYPES_H_
diff --git a/src/wrapped/generated/wrappedcairogobjectundefs.h b/src/wrapped/generated/wrappedcairogobjectundefs.h
deleted file mode 100644
index 9367576..0000000
--- a/src/wrapped/generated/wrappedcairogobjectundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedcairogobjectUNDEFS_H_
-#define __wrappedcairogobjectUNDEFS_H_
-
-
-#endif // __wrappedcairogobjectUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedcairotypes.h b/src/wrapped/generated/wrappedcairotypes.h
deleted file mode 100644
index 46d4998..0000000
--- a/src/wrapped/generated/wrappedcairotypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedcairoTYPES_H_
-#define __wrappedcairoTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedcairoTYPES_H_
diff --git a/src/wrapped/generated/wrappedcairoundefs.h b/src/wrapped/generated/wrappedcairoundefs.h
deleted file mode 100644
index 68fbee0..0000000
--- a/src/wrapped/generated/wrappedcairoundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedcairoUNDEFS_H_
-#define __wrappedcairoUNDEFS_H_
-
-
-#endif // __wrappedcairoUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedcrashhandlerdefs.h b/src/wrapped/generated/wrappedcrashhandlerdefs.h
deleted file mode 100644
index ac62410..0000000
--- a/src/wrapped/generated/wrappedcrashhandlerdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedcrashhandlerDEFS_H_
-#define __wrappedcrashhandlerDEFS_H_
-
-
-#endif // __wrappedcrashhandlerDEFS_H_
diff --git a/src/wrapped/generated/wrappedcrashhandlertypes.h b/src/wrapped/generated/wrappedcrashhandlertypes.h
deleted file mode 100644
index 13ad761..0000000
--- a/src/wrapped/generated/wrappedcrashhandlertypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedcrashhandlerTYPES_H_
-#define __wrappedcrashhandlerTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedcrashhandlerTYPES_H_
diff --git a/src/wrapped/generated/wrappedcrashhandlerundefs.h b/src/wrapped/generated/wrappedcrashhandlerundefs.h
deleted file mode 100644
index b9170fd..0000000
--- a/src/wrapped/generated/wrappedcrashhandlerundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedcrashhandlerUNDEFS_H_
-#define __wrappedcrashhandlerUNDEFS_H_
-
-
-#endif // __wrappedcrashhandlerUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedcryptodefs.h b/src/wrapped/generated/wrappedcryptodefs.h
deleted file mode 100644
index 8c0c09c..0000000
--- a/src/wrapped/generated/wrappedcryptodefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedcryptoDEFS_H_
-#define __wrappedcryptoDEFS_H_
-
-
-#endif // __wrappedcryptoDEFS_H_
diff --git a/src/wrapped/generated/wrappedcryptotypes.h b/src/wrapped/generated/wrappedcryptotypes.h
deleted file mode 100644
index 2e4d825..0000000
--- a/src/wrapped/generated/wrappedcryptotypes.h
+++ /dev/null
@@ -1,51 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedcryptoTYPES_H_
-#define __wrappedcryptoTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFp_t)(void*);
-typedef void* (*pFp_t)(void*);
-typedef void (*vFpp_t)(void*, void*);
-typedef void* (*pFpp_t)(void*, void*);
-typedef int64_t (*iFppp_t)(void*, void*, void*);
-typedef void* (*pFpppp_t)(void*, void*, void*, void*);
-typedef int64_t (*iFpiipp_t)(void*, int64_t, int64_t, void*, void*);
-typedef int64_t (*iFpplppi_t)(void*, void*, intptr_t, void*, void*, int64_t);
-typedef int64_t (*iFppppipp_t)(void*, void*, void*, void*, int64_t, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(CRYPTO_set_id_callback, vFp_t) \
- GO(CRYPTO_set_locking_callback, vFp_t) \
- GO(sk_new, pFp_t) \
- GO(X509_STORE_CTX_set_verify_cb, vFpp_t) \
- GO(sk_pop_free, vFpp_t) \
- GO(OPENSSL_sk_pop_free, pFpp_t) \
- GO(ASN1_i2d_bio, iFppp_t) \
- GO(ASN1_d2i_bio, pFpppp_t) \
- GO(PEM_read_bio_DSAPrivateKey, pFpppp_t) \
- GO(PEM_read_bio_DSA_PUBKEY, pFpppp_t) \
- GO(PEM_read_bio_ECPrivateKey, pFpppp_t) \
- GO(PEM_read_bio_EC_PUBKEY, pFpppp_t) \
- GO(PEM_read_bio_PKCS7, pFpppp_t) \
- GO(PEM_read_bio_RSAPrivateKey, pFpppp_t) \
- GO(PEM_read_bio_RSA_PUBKEY, pFpppp_t) \
- GO(PEM_read_bio_X509, pFpppp_t) \
- GO(PEM_read_bio_X509_AUX, pFpppp_t) \
- GO(PEM_read_bio_X509_CERT_PAIR, pFpppp_t) \
- GO(PEM_read_bio_X509_CRL, pFpppp_t) \
- GO(PEM_read_bio_X509_REQ, pFpppp_t) \
- GO(ENGINE_ctrl, iFpiipp_t) \
- GO(ENGINE_ctrl_cmd, iFpplppi_t) \
- GO(PEM_write_bio_DSAPrivateKey, iFppppipp_t) \
- GO(PEM_write_bio_ECPrivateKey, iFppppipp_t) \
- GO(PEM_write_bio_RSAPrivateKey, iFppppipp_t)
-
-#endif // __wrappedcryptoTYPES_H_
diff --git a/src/wrapped/generated/wrappedcryptoundefs.h b/src/wrapped/generated/wrappedcryptoundefs.h
deleted file mode 100644
index 9cdda43..0000000
--- a/src/wrapped/generated/wrappedcryptoundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedcryptoUNDEFS_H_
-#define __wrappedcryptoUNDEFS_H_
-
-
-#endif // __wrappedcryptoUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedcurldefs.h b/src/wrapped/generated/wrappedcurldefs.h
deleted file mode 100644
index 901cde5..0000000
--- a/src/wrapped/generated/wrappedcurldefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedcurlDEFS_H_
-#define __wrappedcurlDEFS_H_
-
-
-#endif // __wrappedcurlDEFS_H_
diff --git a/src/wrapped/generated/wrappedcurltypes.h b/src/wrapped/generated/wrappedcurltypes.h
deleted file mode 100644
index 65085ef..0000000
--- a/src/wrapped/generated/wrappedcurltypes.h
+++ /dev/null
@@ -1,21 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedcurlTYPES_H_
-#define __wrappedcurlTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef int64_t (*iFpup_t)(void*, uint64_t, void*);
-typedef uint64_t (*uFpup_t)(void*, uint64_t, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(curl_multi_setopt, iFpup_t) \
- GO(curl_easy_setopt, uFpup_t)
-
-#endif // __wrappedcurlTYPES_H_
diff --git a/src/wrapped/generated/wrappedcurlundefs.h b/src/wrapped/generated/wrappedcurlundefs.h
deleted file mode 100644
index 7b4c18d..0000000
--- a/src/wrapped/generated/wrappedcurlundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedcurlUNDEFS_H_
-#define __wrappedcurlUNDEFS_H_
-
-
-#endif // __wrappedcurlUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedd3dadapter9defs.h b/src/wrapped/generated/wrappedd3dadapter9defs.h
deleted file mode 100644
index c74eeae..0000000
--- a/src/wrapped/generated/wrappedd3dadapter9defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedd3dadapter9DEFS_H_
-#define __wrappedd3dadapter9DEFS_H_
-
-
-#endif // __wrappedd3dadapter9DEFS_H_
diff --git a/src/wrapped/generated/wrappedd3dadapter9types.h b/src/wrapped/generated/wrappedd3dadapter9types.h
deleted file mode 100644
index 5d9c834..0000000
--- a/src/wrapped/generated/wrappedd3dadapter9types.h
+++ /dev/null
@@ -1,21 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedd3dadapter9TYPES_H_
-#define __wrappedd3dadapter9TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void* (*pWp_t)(void*);
-typedef int64_t (*iWip_t)(int64_t, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(D3DAdapter9GetProc, pWp_t) \
- GO(dummy_d3d, iWip_t)
-
-#endif // __wrappedd3dadapter9TYPES_H_
diff --git a/src/wrapped/generated/wrappedd3dadapter9undefs.h b/src/wrapped/generated/wrappedd3dadapter9undefs.h
deleted file mode 100644
index ebd1b42..0000000
--- a/src/wrapped/generated/wrappedd3dadapter9undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedd3dadapter9UNDEFS_H_
-#define __wrappedd3dadapter9UNDEFS_H_
-
-
-#endif // __wrappedd3dadapter9UNDEFS_H_
diff --git a/src/wrapped/generated/wrappeddbusdefs.h b/src/wrapped/generated/wrappeddbusdefs.h
deleted file mode 100644
index cf4d449..0000000
--- a/src/wrapped/generated/wrappeddbusdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappeddbusDEFS_H_
-#define __wrappeddbusDEFS_H_
-
-
-#endif // __wrappeddbusDEFS_H_
diff --git a/src/wrapped/generated/wrappeddbusglib1defs.h b/src/wrapped/generated/wrappeddbusglib1defs.h
deleted file mode 100644
index e539a73..0000000
--- a/src/wrapped/generated/wrappeddbusglib1defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappeddbusglib1DEFS_H_
-#define __wrappeddbusglib1DEFS_H_
-
-
-#endif // __wrappeddbusglib1DEFS_H_
diff --git a/src/wrapped/generated/wrappeddbusglib1types.h b/src/wrapped/generated/wrappeddbusglib1types.h
deleted file mode 100644
index ba8e639..0000000
--- a/src/wrapped/generated/wrappeddbusglib1types.h
+++ /dev/null
@@ -1,28 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappeddbusglib1TYPES_H_
-#define __wrappeddbusglib1TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFppp_t)(void*, void*, void*);
-typedef void (*vFpppp_t)(void*, void*, void*, void*);
-typedef void (*vFppppp_t)(void*, void*, void*, void*, void*);
-typedef void* (*pFpppppiV_t)(void*, void*, void*, void*, void*, int64_t, ...);
-typedef void* (*pFpppppiiV_t)(void*, void*, void*, void*, void*, int64_t, int64_t, ...);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(dbus_g_type_collection_value_iterate, vFppp_t) \
- GO(dbus_g_type_map_value_iterate, vFppp_t) \
- GO(dbus_g_proxy_disconnect_signal, vFpppp_t) \
- GO(dbus_g_proxy_connect_signal, vFppppp_t) \
- GO(dbus_g_proxy_begin_call, pFpppppiV_t) \
- GO(dbus_g_proxy_begin_call_with_timeout, pFpppppiiV_t)
-
-#endif // __wrappeddbusglib1TYPES_H_
diff --git a/src/wrapped/generated/wrappeddbusglib1undefs.h b/src/wrapped/generated/wrappeddbusglib1undefs.h
deleted file mode 100644
index d8251ee..0000000
--- a/src/wrapped/generated/wrappeddbusglib1undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappeddbusglib1UNDEFS_H_
-#define __wrappeddbusglib1UNDEFS_H_
-
-
-#endif // __wrappeddbusglib1UNDEFS_H_
diff --git a/src/wrapped/generated/wrappeddbustypes.h b/src/wrapped/generated/wrappeddbustypes.h
deleted file mode 100644
index 6c45061..0000000
--- a/src/wrapped/generated/wrappeddbustypes.h
+++ /dev/null
@@ -1,45 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappeddbusTYPES_H_
-#define __wrappeddbusTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFppp_t)(void*, void*, void*);
-typedef int64_t (*iFpiV_t)(void*, int64_t, ...);
-typedef int64_t (*iFpiA_t)(void*, int64_t, va_list);
-typedef void (*vFpppp_t)(void*, void*, void*, void*);
-typedef int64_t (*iFpipp_t)(void*, int64_t, void*, void*);
-typedef int64_t (*iFppip_t)(void*, void*, int64_t, void*);
-typedef int64_t (*iFppiA_t)(void*, void*, int64_t, va_list);
-typedef int64_t (*iFpppp_t)(void*, void*, void*, void*);
-typedef int64_t (*iFppppp_t)(void*, void*, void*, void*, void*);
-typedef int64_t (*iFpppppp_t)(void*, void*, void*, void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(dbus_connection_remove_filter, vFppp_t) \
- GO(dbus_timeout_set_data, vFppp_t) \
- GO(dbus_watch_set_data, vFppp_t) \
- GO(dbus_message_append_args, iFpiV_t) \
- GO(dbus_message_append_args_valist, iFpiA_t) \
- GO(dbus_connection_set_dispatch_status_function, vFpppp_t) \
- GO(dbus_connection_set_wakeup_main_function, vFpppp_t) \
- GO(dbus_connection_set_data, iFpipp_t) \
- GO(dbus_message_set_data, iFpipp_t) \
- GO(dbus_pending_call_set_data, iFpipp_t) \
- GO(dbus_message_get_args, iFppip_t) \
- GO(dbus_message_get_args_valist, iFppiA_t) \
- GO(dbus_connection_add_filter, iFpppp_t) \
- GO(dbus_pending_call_set_notify, iFpppp_t) \
- GO(dbus_connection_try_register_fallback, iFppppp_t) \
- GO(dbus_connection_try_register_object_path, iFppppp_t) \
- GO(dbus_connection_set_timeout_functions, iFpppppp_t) \
- GO(dbus_connection_set_watch_functions, iFpppppp_t)
-
-#endif // __wrappeddbusTYPES_H_
diff --git a/src/wrapped/generated/wrappeddbusundefs.h b/src/wrapped/generated/wrappeddbusundefs.h
deleted file mode 100644
index 903a884..0000000
--- a/src/wrapped/generated/wrappeddbusundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappeddbusUNDEFS_H_
-#define __wrappeddbusUNDEFS_H_
-
-
-#endif // __wrappeddbusUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedexpatdefs.h b/src/wrapped/generated/wrappedexpatdefs.h
deleted file mode 100644
index 948f8ef..0000000
--- a/src/wrapped/generated/wrappedexpatdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedexpatDEFS_H_
-#define __wrappedexpatDEFS_H_
-
-
-#endif // __wrappedexpatDEFS_H_
diff --git a/src/wrapped/generated/wrappedexpattypes.h b/src/wrapped/generated/wrappedexpattypes.h
deleted file mode 100644
index cf1c605..0000000
--- a/src/wrapped/generated/wrappedexpattypes.h
+++ /dev/null
@@ -1,44 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedexpatTYPES_H_
-#define __wrappedexpatTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFpp_t)(void*, void*);
-typedef void (*vFppp_t)(void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(XML_SetAttlistDeclHandler, vFpp_t) \
- GO(XML_SetCharacterDataHandler, vFpp_t) \
- GO(XML_SetCommentHandler, vFpp_t) \
- GO(XML_SetDefaultHandler, vFpp_t) \
- GO(XML_SetDefaultHandlerExpand, vFpp_t) \
- GO(XML_SetElementDeclHandler, vFpp_t) \
- GO(XML_SetEndCdataSectionHandler, vFpp_t) \
- GO(XML_SetEndDoctypeDeclHandler, vFpp_t) \
- GO(XML_SetEndElementHandler, vFpp_t) \
- GO(XML_SetEndNamespaceDeclHandler, vFpp_t) \
- GO(XML_SetEntityDeclHandler, vFpp_t) \
- GO(XML_SetExternalEntityRefHandler, vFpp_t) \
- GO(XML_SetNotStandaloneHandler, vFpp_t) \
- GO(XML_SetNotationDeclHandler, vFpp_t) \
- GO(XML_SetProcessingInstructionHandler, vFpp_t) \
- GO(XML_SetSkippedEntityHandler, vFpp_t) \
- GO(XML_SetStartCdataSectionHandler, vFpp_t) \
- GO(XML_SetStartDoctypeDeclHandler, vFpp_t) \
- GO(XML_SetStartElementHandler, vFpp_t) \
- GO(XML_SetStartNamespaceDeclHandler, vFpp_t) \
- GO(XML_SetUnparsedEntityDeclHandler, vFpp_t) \
- GO(XML_SetXmlDeclHandler, vFpp_t) \
- GO(XML_SetElementHandler, vFppp_t) \
- GO(XML_SetNamespaceDeclHandler, vFppp_t) \
- GO(XML_SetUnknownEncodingHandler, vFppp_t)
-
-#endif // __wrappedexpatTYPES_H_
diff --git a/src/wrapped/generated/wrappedexpatundefs.h b/src/wrapped/generated/wrappedexpatundefs.h
deleted file mode 100644
index aaa8100..0000000
--- a/src/wrapped/generated/wrappedexpatundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedexpatUNDEFS_H_
-#define __wrappedexpatUNDEFS_H_
-
-
-#endif // __wrappedexpatUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedfaudiodefs.h b/src/wrapped/generated/wrappedfaudiodefs.h
deleted file mode 100644
index c13a7ac..0000000
--- a/src/wrapped/generated/wrappedfaudiodefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedfaudioDEFS_H_
-#define __wrappedfaudioDEFS_H_
-
-
-#endif // __wrappedfaudioDEFS_H_
diff --git a/src/wrapped/generated/wrappedfaudiotypes.h b/src/wrapped/generated/wrappedfaudiotypes.h
deleted file mode 100644
index cba9ba5..0000000
--- a/src/wrapped/generated/wrappedfaudiotypes.h
+++ /dev/null
@@ -1,35 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedfaudioTYPES_H_
-#define __wrappedfaudioTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFpp_t)(void*, void*);
-typedef uint64_t (*uFpp_t)(void*, void*);
-typedef void (*vFppp_t)(void*, void*, void*);
-typedef uint64_t (*uFpCppp_t)(void*, uint8_t, void*, void*, void*);
-typedef uint64_t (*uFpuppp_t)(void*, uint64_t, void*, void*, void*);
-typedef uint64_t (*uFpuuppp_t)(void*, uint64_t, uint64_t, void*, void*, void*);
-typedef uint64_t (*uFpppuppp_t)(void*, void*, void*, uint64_t, void*, void*, void*);
-typedef uint64_t (*uFpppufppp_t)(void*, void*, void*, uint64_t, float, void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(FAudio_UnregisterForCallbacks, vFpp_t) \
- GO(FAudio_RegisterForCallbacks, uFpp_t) \
- GO(FAudio_SetEngineProcedureEXT, vFppp_t) \
- GO(FAudioCOMConstructWithCustomAllocatorEXT, uFpCppp_t) \
- GO(FAudioCreateReverb9WithCustomAllocatorEXT, uFpuppp_t) \
- GO(FAudioCreateReverbWithCustomAllocatorEXT, uFpuppp_t) \
- GO(FAudioCreateVolumeMeterWithCustomAllocatorEXT, uFpuppp_t) \
- GO(FAudioCreateWithCustomAllocatorEXT, uFpuuppp_t) \
- GO(FAPOFX_CreateFXWithCustomAllocatorEXT, uFpppuppp_t) \
- GO(FAudio_CreateSourceVoice, uFpppufppp_t)
-
-#endif // __wrappedfaudioTYPES_H_
diff --git a/src/wrapped/generated/wrappedfaudioundefs.h b/src/wrapped/generated/wrappedfaudioundefs.h
deleted file mode 100644
index a45064b..0000000
--- a/src/wrapped/generated/wrappedfaudioundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedfaudioUNDEFS_H_
-#define __wrappedfaudioUNDEFS_H_
-
-
-#endif // __wrappedfaudioUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedflacdefs.h b/src/wrapped/generated/wrappedflacdefs.h
deleted file mode 100644
index c3a21cf..0000000
--- a/src/wrapped/generated/wrappedflacdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedflacDEFS_H_
-#define __wrappedflacDEFS_H_
-
-
-#endif // __wrappedflacDEFS_H_
diff --git a/src/wrapped/generated/wrappedflactypes.h b/src/wrapped/generated/wrappedflactypes.h
deleted file mode 100644
index ba50844..0000000
--- a/src/wrapped/generated/wrappedflactypes.h
+++ /dev/null
@@ -1,21 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedflacTYPES_H_
-#define __wrappedflacTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef int64_t (*iFppPPPPPP_t)(void*, void*, void*, void*, void*, void*, void*, void*);
-typedef int64_t (*iFppppppppp_t)(void*, void*, void*, void*, void*, void*, void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(FLAC__metadata_chain_read_with_callbacks, iFppPPPPPP_t) \
- GO(FLAC__stream_decoder_init_stream, iFppppppppp_t)
-
-#endif // __wrappedflacTYPES_H_
diff --git a/src/wrapped/generated/wrappedflacundefs.h b/src/wrapped/generated/wrappedflacundefs.h
deleted file mode 100644
index 00f7fa0..0000000
--- a/src/wrapped/generated/wrappedflacundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedflacUNDEFS_H_
-#define __wrappedflacUNDEFS_H_
-
-
-#endif // __wrappedflacUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedfontconfigdefs.h b/src/wrapped/generated/wrappedfontconfigdefs.h
deleted file mode 100644
index df4aa4c..0000000
--- a/src/wrapped/generated/wrappedfontconfigdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedfontconfigDEFS_H_
-#define __wrappedfontconfigDEFS_H_
-
-
-#endif // __wrappedfontconfigDEFS_H_
diff --git a/src/wrapped/generated/wrappedfontconfigtypes.h b/src/wrapped/generated/wrappedfontconfigtypes.h
deleted file mode 100644
index 6d6d775..0000000
--- a/src/wrapped/generated/wrappedfontconfigtypes.h
+++ /dev/null
@@ -1,21 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedfontconfigTYPES_H_
-#define __wrappedfontconfigTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void* (*pFpV_t)(void*, ...);
-typedef void* (*pFpA_t)(void*, va_list);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(FcObjectSetBuild, pFpV_t) \
- GO(FcObjectSetVaBuild, pFpA_t)
-
-#endif // __wrappedfontconfigTYPES_H_
diff --git a/src/wrapped/generated/wrappedfontconfigundefs.h b/src/wrapped/generated/wrappedfontconfigundefs.h
deleted file mode 100644
index 8a5130b..0000000
--- a/src/wrapped/generated/wrappedfontconfigundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedfontconfigUNDEFS_H_
-#define __wrappedfontconfigUNDEFS_H_
-
-
-#endif // __wrappedfontconfigUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedfreebl3defs.h b/src/wrapped/generated/wrappedfreebl3defs.h
deleted file mode 100644
index 7e8cf7c..0000000
--- a/src/wrapped/generated/wrappedfreebl3defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedfreebl3DEFS_H_
-#define __wrappedfreebl3DEFS_H_
-
-
-#endif // __wrappedfreebl3DEFS_H_
diff --git a/src/wrapped/generated/wrappedfreebl3types.h b/src/wrapped/generated/wrappedfreebl3types.h
deleted file mode 100644
index 82592bf..0000000
--- a/src/wrapped/generated/wrappedfreebl3types.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedfreebl3TYPES_H_
-#define __wrappedfreebl3TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedfreebl3TYPES_H_
diff --git a/src/wrapped/generated/wrappedfreebl3undefs.h b/src/wrapped/generated/wrappedfreebl3undefs.h
deleted file mode 100644
index 5269c91..0000000
--- a/src/wrapped/generated/wrappedfreebl3undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedfreebl3UNDEFS_H_
-#define __wrappedfreebl3UNDEFS_H_
-
-
-#endif // __wrappedfreebl3UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedfreetypedefs.h b/src/wrapped/generated/wrappedfreetypedefs.h
deleted file mode 100644
index f88ddbc..0000000
--- a/src/wrapped/generated/wrappedfreetypedefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedfreetypeDEFS_H_
-#define __wrappedfreetypeDEFS_H_
-
-
-#endif // __wrappedfreetypeDEFS_H_
diff --git a/src/wrapped/generated/wrappedfreetypetypes.h b/src/wrapped/generated/wrappedfreetypetypes.h
deleted file mode 100644
index 2b83ce2..0000000
--- a/src/wrapped/generated/wrappedfreetypetypes.h
+++ /dev/null
@@ -1,25 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedfreetypeTYPES_H_
-#define __wrappedfreetypeTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef int64_t (*iFpp_t)(void*, void*);
-typedef int64_t (*iFppp_t)(void*, void*, void*);
-typedef int64_t (*iFpplp_t)(void*, void*, intptr_t, void*);
-typedef int64_t (*iFpuuLppp_t)(void*, uint64_t, uint64_t, uintptr_t, void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(FT_New_Library, iFpp_t) \
- GO(FT_Outline_Decompose, iFppp_t) \
- GO(FT_Open_Face, iFpplp_t) \
- GO(FTC_Manager_New, iFpuuLppp_t)
-
-#endif // __wrappedfreetypeTYPES_H_
diff --git a/src/wrapped/generated/wrappedfreetypeundefs.h b/src/wrapped/generated/wrappedfreetypeundefs.h
deleted file mode 100644
index 9184fa8..0000000
--- a/src/wrapped/generated/wrappedfreetypeundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedfreetypeUNDEFS_H_
-#define __wrappedfreetypeUNDEFS_H_
-
-
-#endif // __wrappedfreetypeUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedgbmdefs.h b/src/wrapped/generated/wrappedgbmdefs.h
deleted file mode 100644
index a1c00ad..0000000
--- a/src/wrapped/generated/wrappedgbmdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgbmDEFS_H_
-#define __wrappedgbmDEFS_H_
-
-
-#endif // __wrappedgbmDEFS_H_
diff --git a/src/wrapped/generated/wrappedgbmtypes.h b/src/wrapped/generated/wrappedgbmtypes.h
deleted file mode 100644
index a1f49a7..0000000
--- a/src/wrapped/generated/wrappedgbmtypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgbmTYPES_H_
-#define __wrappedgbmTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedgbmTYPES_H_
diff --git a/src/wrapped/generated/wrappedgbmundefs.h b/src/wrapped/generated/wrappedgbmundefs.h
deleted file mode 100644
index 24c803f..0000000
--- a/src/wrapped/generated/wrappedgbmundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgbmUNDEFS_H_
-#define __wrappedgbmUNDEFS_H_
-
-
-#endif // __wrappedgbmUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedgconf2defs.h b/src/wrapped/generated/wrappedgconf2defs.h
deleted file mode 100644
index 47d81fe..0000000
--- a/src/wrapped/generated/wrappedgconf2defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgconf2DEFS_H_
-#define __wrappedgconf2DEFS_H_
-
-
-#endif // __wrappedgconf2DEFS_H_
diff --git a/src/wrapped/generated/wrappedgconf2types.h b/src/wrapped/generated/wrappedgconf2types.h
deleted file mode 100644
index 0602265..0000000
--- a/src/wrapped/generated/wrappedgconf2types.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgconf2TYPES_H_
-#define __wrappedgconf2TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedgconf2TYPES_H_
diff --git a/src/wrapped/generated/wrappedgconf2undefs.h b/src/wrapped/generated/wrappedgconf2undefs.h
deleted file mode 100644
index d736106..0000000
--- a/src/wrapped/generated/wrappedgconf2undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgconf2UNDEFS_H_
-#define __wrappedgconf2UNDEFS_H_
-
-
-#endif // __wrappedgconf2UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedgcryptdefs.h b/src/wrapped/generated/wrappedgcryptdefs.h
deleted file mode 100644
index 3e9fbee..0000000
--- a/src/wrapped/generated/wrappedgcryptdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgcryptDEFS_H_
-#define __wrappedgcryptDEFS_H_
-
-
-#endif // __wrappedgcryptDEFS_H_
diff --git a/src/wrapped/generated/wrappedgcrypttypes.h b/src/wrapped/generated/wrappedgcrypttypes.h
deleted file mode 100644
index fec70b6..0000000
--- a/src/wrapped/generated/wrappedgcrypttypes.h
+++ /dev/null
@@ -1,19 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgcryptTYPES_H_
-#define __wrappedgcryptTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef uint64_t (*uFpppV_t)(void*, void*, void*, ...);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(gcry_sexp_build, uFpppV_t)
-
-#endif // __wrappedgcryptTYPES_H_
diff --git a/src/wrapped/generated/wrappedgcryptundefs.h b/src/wrapped/generated/wrappedgcryptundefs.h
deleted file mode 100644
index f598d13..0000000
--- a/src/wrapped/generated/wrappedgcryptundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgcryptUNDEFS_H_
-#define __wrappedgcryptUNDEFS_H_
-
-
-#endif // __wrappedgcryptUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedgdk3defs.h b/src/wrapped/generated/wrappedgdk3defs.h
deleted file mode 100644
index 36eeea3..0000000
--- a/src/wrapped/generated/wrappedgdk3defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgdk3DEFS_H_
-#define __wrappedgdk3DEFS_H_
-
-
-#endif // __wrappedgdk3DEFS_H_
diff --git a/src/wrapped/generated/wrappedgdk3types.h b/src/wrapped/generated/wrappedgdk3types.h
deleted file mode 100644
index 9d56b20..0000000
--- a/src/wrapped/generated/wrappedgdk3types.h
+++ /dev/null
@@ -1,29 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgdk3TYPES_H_
-#define __wrappedgdk3TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFpp_t)(void*, void*);
-typedef int64_t (*iFpp_t)(void*, void*);
-typedef void (*vFppp_t)(void*, void*, void*);
-typedef int64_t (*iFiipp_t)(int64_t, int64_t, void*, void*);
-typedef int64_t (*iFiippp_t)(int64_t, int64_t, void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(gdk_init, vFpp_t) \
- GO(gdk_init_check, iFpp_t) \
- GO(gdk_event_handler_set, vFppp_t) \
- GO(gdk_window_add_filter, vFppp_t) \
- GO(gdk_window_remove_filter, vFppp_t) \
- GO(gdk_input_add, iFiipp_t) \
- GO(gdk_input_add_full, iFiippp_t)
-
-#endif // __wrappedgdk3TYPES_H_
diff --git a/src/wrapped/generated/wrappedgdk3undefs.h b/src/wrapped/generated/wrappedgdk3undefs.h
deleted file mode 100644
index 67a712e..0000000
--- a/src/wrapped/generated/wrappedgdk3undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgdk3UNDEFS_H_
-#define __wrappedgdk3UNDEFS_H_
-
-
-#endif // __wrappedgdk3UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedgdkpixbuf2defs.h b/src/wrapped/generated/wrappedgdkpixbuf2defs.h
deleted file mode 100644
index c8bd3a6..0000000
--- a/src/wrapped/generated/wrappedgdkpixbuf2defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgdkpixbuf2DEFS_H_
-#define __wrappedgdkpixbuf2DEFS_H_
-
-
-#endif // __wrappedgdkpixbuf2DEFS_H_
diff --git a/src/wrapped/generated/wrappedgdkpixbuf2types.h b/src/wrapped/generated/wrappedgdkpixbuf2types.h
deleted file mode 100644
index 84e52d6..0000000
--- a/src/wrapped/generated/wrappedgdkpixbuf2types.h
+++ /dev/null
@@ -1,19 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgdkpixbuf2TYPES_H_
-#define __wrappedgdkpixbuf2TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void* (*pFpiiiiiipp_t)(void*, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(gdk_pixbuf_new_from_data, pFpiiiiiipp_t)
-
-#endif // __wrappedgdkpixbuf2TYPES_H_
diff --git a/src/wrapped/generated/wrappedgdkpixbuf2undefs.h b/src/wrapped/generated/wrappedgdkpixbuf2undefs.h
deleted file mode 100644
index e52f54f..0000000
--- a/src/wrapped/generated/wrappedgdkpixbuf2undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgdkpixbuf2UNDEFS_H_
-#define __wrappedgdkpixbuf2UNDEFS_H_
-
-
-#endif // __wrappedgdkpixbuf2UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedgdkx112defs.h b/src/wrapped/generated/wrappedgdkx112defs.h
deleted file mode 100644
index 53d18e8..0000000
--- a/src/wrapped/generated/wrappedgdkx112defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgdkx112DEFS_H_
-#define __wrappedgdkx112DEFS_H_
-
-
-#endif // __wrappedgdkx112DEFS_H_
diff --git a/src/wrapped/generated/wrappedgdkx112types.h b/src/wrapped/generated/wrappedgdkx112types.h
deleted file mode 100644
index 732c0da..0000000
--- a/src/wrapped/generated/wrappedgdkx112types.h
+++ /dev/null
@@ -1,29 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgdkx112TYPES_H_
-#define __wrappedgdkx112TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFpp_t)(void*, void*);
-typedef int64_t (*iFpp_t)(void*, void*);
-typedef void (*vFppp_t)(void*, void*, void*);
-typedef int64_t (*iFiipp_t)(int64_t, int64_t, void*, void*);
-typedef int64_t (*iFiippp_t)(int64_t, int64_t, void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(gdk_init, vFpp_t) \
- GO(gdk_init_check, iFpp_t) \
- GO(gdk_event_handler_set, vFppp_t) \
- GO(gdk_window_add_filter, vFppp_t) \
- GO(gdk_window_remove_filter, vFppp_t) \
- GO(gdk_input_add, iFiipp_t) \
- GO(gdk_input_add_full, iFiippp_t)
-
-#endif // __wrappedgdkx112TYPES_H_
diff --git a/src/wrapped/generated/wrappedgdkx112undefs.h b/src/wrapped/generated/wrappedgdkx112undefs.h
deleted file mode 100644
index 9ffe1a4..0000000
--- a/src/wrapped/generated/wrappedgdkx112undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgdkx112UNDEFS_H_
-#define __wrappedgdkx112UNDEFS_H_
-
-
-#endif // __wrappedgdkx112UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedgio2defs.h b/src/wrapped/generated/wrappedgio2defs.h
deleted file mode 100644
index 5bc8366..0000000
--- a/src/wrapped/generated/wrappedgio2defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgio2DEFS_H_
-#define __wrappedgio2DEFS_H_
-
-
-#endif // __wrappedgio2DEFS_H_
diff --git a/src/wrapped/generated/wrappedgio2types.h b/src/wrapped/generated/wrappedgio2types.h
deleted file mode 100644
index f0777a4..0000000
--- a/src/wrapped/generated/wrappedgio2types.h
+++ /dev/null
@@ -1,85 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgio2TYPES_H_
-#define __wrappedgio2TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFppp_t)(void*, void*, void*);
-typedef void (*vFippp_t)(int64_t, void*, void*, void*);
-typedef void (*vFppip_t)(void*, void*, int64_t, void*);
-typedef void (*vFpppp_t)(void*, void*, void*, void*);
-typedef uint64_t (*uFpppp_t)(void*, void*, void*, void*);
-typedef uintptr_t (*LFpppp_t)(void*, void*, void*, void*);
-typedef void* (*pFpppp_t)(void*, void*, void*, void*);
-typedef void (*vFpippp_t)(void*, int64_t, void*, void*, void*);
-typedef void (*vFppipV_t)(void*, void*, int64_t, void*, ...);
-typedef void (*vFppipA_t)(void*, void*, int64_t, void*, va_list);
-typedef void* (*pFppppV_t)(void*, void*, void*, void*, ...);
-typedef void* (*pFppApp_t)(void*, void*, va_list, void*, void*);
-typedef void (*vFpipppp_t)(void*, int64_t, void*, void*, void*, void*);
-typedef void (*vFiippppV_t)(int64_t, int64_t, void*, void*, void*, void*, ...);
-typedef void (*vFiupippp_t)(int64_t, uint64_t, void*, int64_t, void*, void*, void*);
-typedef void (*vFipAippp_t)(int64_t, void*, va_list, int64_t, void*, void*, void*);
-typedef void (*vFppipppp_t)(void*, void*, int64_t, void*, void*, void*, void*);
-typedef void (*vFpppuipV_t)(void*, void*, void*, uint64_t, int64_t, void*, ...);
-typedef uint64_t (*uFipipppp_t)(int64_t, void*, int64_t, void*, void*, void*, void*);
-typedef uint64_t (*uFppipppp_t)(void*, void*, int64_t, void*, void*, void*, void*);
-typedef uint64_t (*uFppppppp_t)(void*, void*, void*, void*, void*, void*, void*);
-typedef void* (*pFpppuipV_t)(void*, void*, void*, uint64_t, int64_t, void*, ...);
-typedef void (*vFppiipppp_t)(void*, void*, int64_t, int64_t, void*, void*, void*, void*);
-typedef void (*vFpppiippp_t)(void*, void*, void*, int64_t, int64_t, void*, void*, void*);
-typedef uint64_t (*uFipippppp_t)(int64_t, void*, int64_t, void*, void*, void*, void*, void*);
-typedef void (*vFiippppppp_t)(int64_t, int64_t, void*, void*, void*, void*, void*, void*, void*);
-typedef void (*vFpippppppp_t)(void*, int64_t, void*, void*, void*, void*, void*, void*, void*);
-typedef void (*vFpppiipppp_t)(void*, void*, void*, int64_t, int64_t, void*, void*, void*, void*);
-typedef void* (*pFiippppppp_t)(int64_t, int64_t, void*, void*, void*, void*, void*, void*, void*);
-typedef uint64_t (*uFppppppippp_t)(void*, void*, void*, void*, void*, void*, int64_t, void*, void*, void*);
-typedef void (*vFpppppppiippp_t)(void*, void*, void*, void*, void*, void*, void*, int64_t, int64_t, void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(g_simple_async_result_set_op_res_gpointer, vFppp_t) \
- GO(g_bus_get, vFippp_t) \
- GO(g_simple_async_result_run_in_thread, vFppip_t) \
- GO(g_dbus_connection_close, vFpppp_t) \
- GO(g_dbus_connection_flush, vFpppp_t) \
- GO(g_simple_async_report_gerror_in_idle, vFpppp_t) \
- GO(g_simple_async_report_take_gerror_in_idle, vFpppp_t) \
- GO(g_dbus_connection_add_filter, uFpppp_t) \
- GO(g_cancellable_connect, LFpppp_t) \
- GO(g_simple_async_result_new, pFpppp_t) \
- GO(g_simple_async_result_new_from_error, pFpppp_t) \
- GO(g_simple_async_result_new_take_error, pFpppp_t) \
- GO(g_async_initable_init_async, vFpippp_t) \
- GO(g_simple_async_result_set_error, vFppipV_t) \
- GO(g_simple_async_result_set_error_va, vFppipA_t) \
- GO(g_initable_new, pFppppV_t) \
- GO(g_initable_new_valist, pFppApp_t) \
- GO(g_dbus_connection_new_for_address, vFpipppp_t) \
- GO(g_async_initable_new_async, vFiippppV_t) \
- GO(g_async_initable_newv_async, vFiupippp_t) \
- GO(g_async_initable_new_valist_async, vFipAippp_t) \
- GO(g_dbus_connection_new, vFppipppp_t) \
- GO(g_simple_async_report_error_in_idle, vFpppuipV_t) \
- GO(g_bus_watch_name, uFipipppp_t) \
- GO(g_bus_own_name_on_connection, uFppipppp_t) \
- GO(g_bus_watch_name_on_connection, uFppipppp_t) \
- GO(g_dbus_connection_register_object, uFppppppp_t) \
- GO(g_simple_async_result_new_error, pFpppuipV_t) \
- GO(g_dbus_connection_send_message_with_reply, vFppiipppp_t) \
- GO(g_dbus_proxy_call, vFpppiippp_t) \
- GO(g_bus_own_name, uFipippppp_t) \
- GO(g_dbus_proxy_new_for_bus, vFiippppppp_t) \
- GO(g_dbus_proxy_new, vFpippppppp_t) \
- GO(g_dbus_proxy_call_with_unix_fd_list, vFpppiipppp_t) \
- GO(g_dbus_object_manager_client_new_for_bus_sync, pFiippppppp_t) \
- GO(g_dbus_connection_signal_subscribe, uFppppppippp_t) \
- GO(g_dbus_connection_call, vFpppppppiippp_t)
-
-#endif // __wrappedgio2TYPES_H_
diff --git a/src/wrapped/generated/wrappedgio2undefs.h b/src/wrapped/generated/wrappedgio2undefs.h
deleted file mode 100644
index ff2b986..0000000
--- a/src/wrapped/generated/wrappedgio2undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgio2UNDEFS_H_
-#define __wrappedgio2UNDEFS_H_
-
-
-#endif // __wrappedgio2UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedglib2defs.h b/src/wrapped/generated/wrappedglib2defs.h
deleted file mode 100644
index 8dd6f0b..0000000
--- a/src/wrapped/generated/wrappedglib2defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedglib2DEFS_H_
-#define __wrappedglib2DEFS_H_
-
-
-#endif // __wrappedglib2DEFS_H_
diff --git a/src/wrapped/generated/wrappedglib2types.h b/src/wrapped/generated/wrappedglib2types.h
deleted file mode 100644
index c4326be..0000000
--- a/src/wrapped/generated/wrappedglib2types.h
+++ /dev/null
@@ -1,174 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedglib2TYPES_H_
-#define __wrappedglib2TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFp_t)(void*);
-typedef void* (*pFp_t)(void*);
-typedef void (*vFpp_t)(void*, void*);
-typedef void (*vFpV_t)(void*, ...);
-typedef int64_t (*iFpp_t)(void*, void*);
-typedef int64_t (*iFpV_t)(void*, ...);
-typedef int64_t (*iFpA_t)(void*, va_list);
-typedef uint64_t (*uFpp_t)(void*, void*);
-typedef uintptr_t (*LFpA_t)(void*, va_list);
-typedef void* (*pFup_t)(uint64_t, void*);
-typedef void* (*pFpu_t)(void*, uint64_t);
-typedef void* (*pFpp_t)(void*, void*);
-typedef void* (*pFpV_t)(void*, ...);
-typedef void* (*pFpA_t)(void*, va_list);
-typedef void (*vFppp_t)(void*, void*, void*);
-typedef void (*vFppV_t)(void*, void*, ...);
-typedef void (*vFppA_t)(void*, void*, va_list);
-typedef int64_t (*iFppV_t)(void*, void*, ...);
-typedef int64_t (*iFppA_t)(void*, void*, va_list);
-typedef uint64_t (*uFipp_t)(int64_t, void*, void*);
-typedef uint64_t (*uFupp_t)(uint64_t, void*, void*);
-typedef uint64_t (*uFppp_t)(void*, void*, void*);
-typedef void* (*pFppp_t)(void*, void*, void*);
-typedef void* (*pFppV_t)(void*, void*, ...);
-typedef void (*vFpipV_t)(void*, int64_t, void*, ...);
-typedef void (*vFpipA_t)(void*, int64_t, void*, va_list);
-typedef void (*vFpupp_t)(void*, uint64_t, void*, void*);
-typedef void (*vFpppp_t)(void*, void*, void*, void*);
-typedef int64_t (*iFpLpV_t)(void*, uintptr_t, void*, ...);
-typedef int64_t (*iFpLpA_t)(void*, uintptr_t, void*, va_list);
-typedef uint64_t (*uFippp_t)(int64_t, void*, void*, void*);
-typedef uint64_t (*uFpipp_t)(void*, int64_t, void*, void*);
-typedef void* (*pFpipp_t)(void*, int64_t, void*, void*);
-typedef void* (*pFpipV_t)(void*, int64_t, void*, ...);
-typedef void* (*pFpipA_t)(void*, int64_t, void*, va_list);
-typedef void* (*pFpupp_t)(void*, uint64_t, void*, void*);
-typedef void* (*pFppip_t)(void*, void*, int64_t, void*);
-typedef void* (*pFpppp_t)(void*, void*, void*, void*);
-typedef void (*vFpiLpp_t)(void*, int64_t, uintptr_t, void*, void*);
-typedef void (*vFppipV_t)(void*, void*, int64_t, void*, ...);
-typedef uint64_t (*uFiippp_t)(int64_t, int64_t, void*, void*, void*);
-typedef uint64_t (*uFiuppp_t)(int64_t, uint64_t, void*, void*, void*);
-typedef void* (*pFppppp_t)(void*, void*, void*, void*, void*);
-typedef void (*vFpiiipp_t)(void*, int64_t, int64_t, int64_t, void*, void*);
-typedef int64_t (*iFpupppp_t)(void*, uint64_t, void*, void*, void*, void*);
-typedef uint64_t (*uFpiippp_t)(void*, int64_t, int64_t, void*, void*, void*);
-typedef void* (*pFppuipp_t)(void*, void*, uint64_t, int64_t, void*, void*);
-typedef void* (*pFppLiiip_t)(void*, void*, uintptr_t, int64_t, int64_t, int64_t, void*);
-typedef int64_t (*iFpppipppp_t)(void*, void*, void*, int64_t, void*, void*, void*, void*);
-typedef int64_t (*iFpppipppppp_t)(void*, void*, void*, int64_t, void*, void*, void*, void*, void*, void*);
-typedef int64_t (*iFpppippppppp_t)(void*, void*, void*, int64_t, void*, void*, void*, void*, void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(g_atexit, vFp_t) \
- GO(g_completion_new, pFp_t) \
- GO(g_main_context_get_poll_func, pFp_t) \
- GO(g_private_new, pFp_t) \
- GO(g_ptr_array_new_with_free_func, pFp_t) \
- GO(g_set_print_handler, pFp_t) \
- GO(g_set_printerr_handler, pFp_t) \
- GO(g_array_set_clear_func, vFpp_t) \
- GO(g_array_sort, vFpp_t) \
- GO(g_completion_set_compare, vFpp_t) \
- GO(g_list_free_full, vFpp_t) \
- GO(g_main_context_set_poll_func, vFpp_t) \
- GO(g_ptr_array_set_free_func, vFpp_t) \
- GO(g_ptr_array_sort, vFpp_t) \
- GO(g_slist_free_full, vFpp_t) \
- GO(g_source_set_funcs, vFpp_t) \
- GO(g_thread_foreach, vFpp_t) \
- GO(g_print, vFpV_t) \
- GO(g_printerr, vFpV_t) \
- GO(g_source_remove_by_funcs_user_data, iFpp_t) \
- GO(g_printf, iFpV_t) \
- GO(g_vprintf, iFpA_t) \
- GO(g_idle_add, uFpp_t) \
- GO(g_printf_string_upper_bound, LFpA_t) \
- GO(g_ptr_array_new_full, pFup_t) \
- GO(g_source_new, pFpu_t) \
- GO(g_hash_table_new, pFpp_t) \
- GO(g_list_sort, pFpp_t) \
- GO(g_log_set_default_handler, pFpp_t) \
- GO(g_slist_sort, pFpp_t) \
- GO(g_strjoinv, pFpp_t) \
- GO(g_variant_new_parsed_va, pFpp_t) \
- GO(g_build_filename, pFpV_t) \
- GO(g_markup_printf_escaped, pFpV_t) \
- GO(g_strconcat, pFpV_t) \
- GO(g_strdup_printf, pFpV_t) \
- GO(g_strjoin, pFpV_t) \
- GO(g_variant_new, pFpV_t) \
- GO(g_markup_vprintf_escaped, pFpA_t) \
- GO(g_strdup_vprintf, pFpA_t) \
- GO(g_array_sort_with_data, vFppp_t) \
- GO(g_hash_table_foreach, vFppp_t) \
- GO(g_list_foreach, vFppp_t) \
- GO(g_option_context_add_main_entries, vFppp_t) \
- GO(g_ptr_array_foreach, vFppp_t) \
- GO(g_ptr_array_sort_with_data, vFppp_t) \
- GO(g_static_private_set, vFppp_t) \
- GO(g_string_append_printf, vFppV_t) \
- GO(g_string_printf, vFppV_t) \
- GO(g_variant_builder_add, vFppV_t) \
- GO(g_variant_get, vFppV_t) \
- GO(g_string_append_vprintf, vFppA_t) \
- GO(g_string_vprintf, vFppA_t) \
- GO(g_fprintf, iFppV_t) \
- GO(g_sprintf, iFppV_t) \
- GO(g_vasprintf, iFppA_t) \
- GO(g_vfprintf, iFppA_t) \
- GO(g_vsprintf, iFppA_t) \
- GO(g_child_watch_add, uFipp_t) \
- GO(g_timeout_add, uFupp_t) \
- GO(g_timeout_add_seconds, uFupp_t) \
- GO(g_hash_table_foreach_remove, uFppp_t) \
- GO(g_hash_table_foreach_steal, uFppp_t) \
- GO(g_hash_table_find, pFppp_t) \
- GO(g_list_find_custom, pFppp_t) \
- GO(g_list_insert_sorted, pFppp_t) \
- GO(g_list_sort_with_data, pFppp_t) \
- GO(g_node_copy_deep, pFppp_t) \
- GO(g_queue_find_custom, pFppp_t) \
- GO(g_slist_find_custom, pFppp_t) \
- GO(g_slist_foreach, pFppp_t) \
- GO(g_slist_insert_sorted, pFppp_t) \
- GO(g_slist_sort_with_data, pFppp_t) \
- GO(g_variant_new_va, pFppp_t) \
- GO(g_build_path, pFppV_t) \
- GO(g_log, vFpipV_t) \
- GO(g_logv, vFpipA_t) \
- GO(g_datalist_id_set_data_full, vFpupp_t) \
- GO(g_source_set_callback, vFpppp_t) \
- GO(g_snprintf, iFpLpV_t) \
- GO(g_vsnprintf, iFpLpA_t) \
- GO(g_idle_add_full, uFippp_t) \
- GO(g_io_add_watch, uFpipp_t) \
- GO(g_log_set_handler, uFpipp_t) \
- GO(g_markup_parse_context_new, pFpipp_t) \
- GO(g_error_new, pFpipV_t) \
- GO(g_error_new_valist, pFpipA_t) \
- GO(g_datalist_id_dup_data, pFpupp_t) \
- GO(g_thread_create, pFppip_t) \
- GO(g_hash_table_new_full, pFpppp_t) \
- GO(g_slist_insert_sorted_with_data, pFpppp_t) \
- GO(g_thread_try_new, pFpppp_t) \
- GO(g_qsort_with_data, vFpiLpp_t) \
- GO(g_set_error, vFppipV_t) \
- GO(g_child_watch_add_full, uFiippp_t) \
- GO(g_timeout_add_full, uFiuppp_t) \
- GO(g_timeout_add_seconds_full, uFiuppp_t) \
- GO(g_option_group_new, pFppppp_t) \
- GO(g_node_traverse, vFpiiipp_t) \
- GO(g_datalist_id_replace_data, iFpupppp_t) \
- GO(g_io_add_watch_full, uFpiippp_t) \
- GO(g_variant_new_from_data, pFppuipp_t) \
- GO(g_thread_create_full, pFppLiiip_t) \
- GO(g_spawn_async, iFpppipppp_t) \
- GO(g_spawn_sync, iFpppipppppp_t) \
- GO(g_spawn_async_with_pipes, iFpppippppppp_t)
-
-#endif // __wrappedglib2TYPES_H_
diff --git a/src/wrapped/generated/wrappedglib2undefs.h b/src/wrapped/generated/wrappedglib2undefs.h
deleted file mode 100644
index a7d89fb..0000000
--- a/src/wrapped/generated/wrappedglib2undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedglib2UNDEFS_H_
-#define __wrappedglib2UNDEFS_H_
-
-
-#endif // __wrappedglib2UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedgmodule2defs.h b/src/wrapped/generated/wrappedgmodule2defs.h
deleted file mode 100644
index 6c4121d..0000000
--- a/src/wrapped/generated/wrappedgmodule2defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgmodule2DEFS_H_
-#define __wrappedgmodule2DEFS_H_
-
-
-#endif // __wrappedgmodule2DEFS_H_
diff --git a/src/wrapped/generated/wrappedgmodule2types.h b/src/wrapped/generated/wrappedgmodule2types.h
deleted file mode 100644
index a57d45f..0000000
--- a/src/wrapped/generated/wrappedgmodule2types.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgmodule2TYPES_H_
-#define __wrappedgmodule2TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedgmodule2TYPES_H_
diff --git a/src/wrapped/generated/wrappedgmodule2undefs.h b/src/wrapped/generated/wrappedgmodule2undefs.h
deleted file mode 100644
index 7b6029c..0000000
--- a/src/wrapped/generated/wrappedgmodule2undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgmodule2UNDEFS_H_
-#define __wrappedgmodule2UNDEFS_H_
-
-
-#endif // __wrappedgmodule2UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedgmpdefs.h b/src/wrapped/generated/wrappedgmpdefs.h
deleted file mode 100644
index ce10016..0000000
--- a/src/wrapped/generated/wrappedgmpdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgmpDEFS_H_
-#define __wrappedgmpDEFS_H_
-
-
-#endif // __wrappedgmpDEFS_H_
diff --git a/src/wrapped/generated/wrappedgmptypes.h b/src/wrapped/generated/wrappedgmptypes.h
deleted file mode 100644
index 90140ce..0000000
--- a/src/wrapped/generated/wrappedgmptypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgmpTYPES_H_
-#define __wrappedgmpTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedgmpTYPES_H_
diff --git a/src/wrapped/generated/wrappedgmpundefs.h b/src/wrapped/generated/wrappedgmpundefs.h
deleted file mode 100644
index 6649217..0000000
--- a/src/wrapped/generated/wrappedgmpundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgmpUNDEFS_H_
-#define __wrappedgmpUNDEFS_H_
-
-
-#endif // __wrappedgmpUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedgnutlsdefs.h b/src/wrapped/generated/wrappedgnutlsdefs.h
deleted file mode 100644
index 1803f0c..0000000
--- a/src/wrapped/generated/wrappedgnutlsdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgnutlsDEFS_H_
-#define __wrappedgnutlsDEFS_H_
-
-
-#endif // __wrappedgnutlsDEFS_H_
diff --git a/src/wrapped/generated/wrappedgnutlstypes.h b/src/wrapped/generated/wrappedgnutlstypes.h
deleted file mode 100644
index 3782135..0000000
--- a/src/wrapped/generated/wrappedgnutlstypes.h
+++ /dev/null
@@ -1,23 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgnutlsTYPES_H_
-#define __wrappedgnutlsTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFp_t)(void*);
-typedef void (*vFpp_t)(void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(gnutls_global_set_log_function, vFp_t) \
- GO(gnutls_transport_set_pull_function, vFpp_t) \
- GO(gnutls_transport_set_pull_timeout_function, vFpp_t) \
- GO(gnutls_transport_set_push_function, vFpp_t)
-
-#endif // __wrappedgnutlsTYPES_H_
diff --git a/src/wrapped/generated/wrappedgnutlsundefs.h b/src/wrapped/generated/wrappedgnutlsundefs.h
deleted file mode 100644
index c34d76b..0000000
--- a/src/wrapped/generated/wrappedgnutlsundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgnutlsUNDEFS_H_
-#define __wrappedgnutlsUNDEFS_H_
-
-
-#endif // __wrappedgnutlsUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedgobject2defs.h b/src/wrapped/generated/wrappedgobject2defs.h
deleted file mode 100644
index c9f729c..0000000
--- a/src/wrapped/generated/wrappedgobject2defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgobject2DEFS_H_
-#define __wrappedgobject2DEFS_H_
-
-
-#endif // __wrappedgobject2DEFS_H_
diff --git a/src/wrapped/generated/wrappedgobject2types.h b/src/wrapped/generated/wrappedgobject2types.h
deleted file mode 100644
index c9ec81d..0000000
--- a/src/wrapped/generated/wrappedgobject2types.h
+++ /dev/null
@@ -1,86 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgobject2TYPES_H_
-#define __wrappedgobject2TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void* (*pFL_t)(uintptr_t);
-typedef void* (*pFp_t)(void*);
-typedef void (*vFpp_t)(void*, void*);
-typedef int64_t (*iFpp_t)(void*, void*);
-typedef void* (*pFpp_t)(void*, void*);
-typedef void (*vFiip_t)(int64_t, int64_t, void*);
-typedef void (*vFLLp_t)(uintptr_t, uintptr_t, void*);
-typedef void (*vFpup_t)(void*, uint64_t, void*);
-typedef void (*vFppp_t)(void*, void*, void*);
-typedef void (*vFppV_t)(void*, void*, ...);
-typedef void (*vFppA_t)(void*, void*, va_list);
-typedef uintptr_t (*LFppp_t)(void*, void*, void*);
-typedef void* (*pFLpV_t)(uintptr_t, void*, ...);
-typedef void* (*pFLpA_t)(uintptr_t, void*, va_list);
-typedef void* (*pFppp_t)(void*, void*, void*);
-typedef void* (*pFppV_t)(void*, void*, ...);
-typedef void (*vFpuuV_t)(void*, uint64_t, uint64_t, ...);
-typedef void (*vFpupp_t)(void*, uint64_t, void*, void*);
-typedef void (*vFpupA_t)(void*, uint64_t, void*, va_list);
-typedef void (*vFpppp_t)(void*, void*, void*, void*);
-typedef uintptr_t (*LFLppi_t)(uintptr_t, void*, void*, int64_t);
-typedef uintptr_t (*LFupppp_t)(uint64_t, void*, void*, void*, void*);
-typedef uintptr_t (*LFLpppi_t)(uintptr_t, void*, void*, void*, int64_t);
-typedef uintptr_t (*LFppppi_t)(void*, void*, void*, void*, int64_t);
-typedef uintptr_t (*LFpppppu_t)(void*, void*, void*, void*, void*, uint64_t);
-typedef uint64_t (*uFpiupppp_t)(void*, int64_t, uint64_t, void*, void*, void*, void*);
-typedef uintptr_t (*LFLpLpLpi_t)(uintptr_t, void*, uintptr_t, void*, uintptr_t, void*, int64_t);
-typedef uintptr_t (*LFpiupppp_t)(void*, int64_t, uint64_t, void*, void*, void*, void*);
-typedef uint64_t (*uFpLiupppLuV_t)(void*, uintptr_t, int64_t, uint64_t, void*, void*, void*, uintptr_t, uint64_t, ...);
-typedef uint64_t (*uFpLippppLup_t)(void*, uintptr_t, int64_t, void*, void*, void*, void*, uintptr_t, uint64_t, void*);
-typedef uint64_t (*uFpLippppLuA_t)(void*, uintptr_t, int64_t, void*, void*, void*, void*, uintptr_t, uint64_t, va_list);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(g_type_value_table_peek, pFL_t) \
- GO(g_type_class_peek_parent, pFp_t) \
- GO(g_closure_set_marshal, vFpp_t) \
- GO(g_param_type_register_static, iFpp_t) \
- GO(g_value_array_sort, pFpp_t) \
- GO(g_value_register_transform_func, vFiip_t) \
- GO(g_type_add_interface_static, vFLLp_t) \
- GO(g_object_class_install_properties, vFpup_t) \
- GO(g_closure_add_finalize_notifier, vFppp_t) \
- GO(g_object_weak_ref, vFppp_t) \
- GO(g_signal_override_class_handler, vFppp_t) \
- GO(g_object_get, vFppV_t) \
- GO(g_object_set, vFppV_t) \
- GO(g_object_get_valist, vFppA_t) \
- GO(g_object_set_valist, vFppA_t) \
- GO(g_boxed_type_register_static, LFppp_t) \
- GO(g_object_new, pFLpV_t) \
- GO(g_object_new_valist, pFLpA_t) \
- GO(g_value_array_sort_with_data, pFppp_t) \
- GO(g_object_connect, pFppV_t) \
- GO(g_signal_emit, vFpuuV_t) \
- GO(g_param_spec_set_qdata_full, vFpupp_t) \
- GO(g_signal_emit_valist, vFpupA_t) \
- GO(g_object_set_data_full, vFpppp_t) \
- GO(g_object_set_qdata_full, vFpppp_t) \
- GO(g_type_register_static, LFLppi_t) \
- GO(g_signal_add_emission_hook, LFupppp_t) \
- GO(g_type_register_fundamental, LFLpppi_t) \
- GO(g_signal_connect_object, LFppppi_t) \
- GO(g_signal_connect_data, LFpppppu_t) \
- GO(g_signal_handlers_block_matched, uFpiupppp_t) \
- GO(g_signal_handlers_disconnect_matched, uFpiupppp_t) \
- GO(g_signal_handlers_unblock_matched, uFpiupppp_t) \
- GO(g_type_register_static_simple, LFLpLpLpi_t) \
- GO(g_signal_handler_find, LFpiupppp_t) \
- GO(g_signal_new, uFpLiupppLuV_t) \
- GO(g_signal_newv, uFpLippppLup_t) \
- GO(g_signal_new_valist, uFpLippppLuA_t)
-
-#endif // __wrappedgobject2TYPES_H_
diff --git a/src/wrapped/generated/wrappedgobject2undefs.h b/src/wrapped/generated/wrappedgobject2undefs.h
deleted file mode 100644
index 832bfe9..0000000
--- a/src/wrapped/generated/wrappedgobject2undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgobject2UNDEFS_H_
-#define __wrappedgobject2UNDEFS_H_
-
-
-#endif // __wrappedgobject2UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedgssapidefs.h b/src/wrapped/generated/wrappedgssapidefs.h
deleted file mode 100644
index 12dd1fe..0000000
--- a/src/wrapped/generated/wrappedgssapidefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgssapiDEFS_H_
-#define __wrappedgssapiDEFS_H_
-
-
-#endif // __wrappedgssapiDEFS_H_
diff --git a/src/wrapped/generated/wrappedgssapikrb5defs.h b/src/wrapped/generated/wrappedgssapikrb5defs.h
deleted file mode 100644
index 9a454f1..0000000
--- a/src/wrapped/generated/wrappedgssapikrb5defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgssapikrb5DEFS_H_
-#define __wrappedgssapikrb5DEFS_H_
-
-
-#endif // __wrappedgssapikrb5DEFS_H_
diff --git a/src/wrapped/generated/wrappedgssapikrb5types.h b/src/wrapped/generated/wrappedgssapikrb5types.h
deleted file mode 100644
index 9a5312f..0000000
--- a/src/wrapped/generated/wrappedgssapikrb5types.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgssapikrb5TYPES_H_
-#define __wrappedgssapikrb5TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedgssapikrb5TYPES_H_
diff --git a/src/wrapped/generated/wrappedgssapikrb5undefs.h b/src/wrapped/generated/wrappedgssapikrb5undefs.h
deleted file mode 100644
index 87b4567..0000000
--- a/src/wrapped/generated/wrappedgssapikrb5undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgssapikrb5UNDEFS_H_
-#define __wrappedgssapikrb5UNDEFS_H_
-
-
-#endif // __wrappedgssapikrb5UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedgssapitypes.h b/src/wrapped/generated/wrappedgssapitypes.h
deleted file mode 100644
index 1f8ea94..0000000
--- a/src/wrapped/generated/wrappedgssapitypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgssapiTYPES_H_
-#define __wrappedgssapiTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedgssapiTYPES_H_
diff --git a/src/wrapped/generated/wrappedgssapiundefs.h b/src/wrapped/generated/wrappedgssapiundefs.h
deleted file mode 100644
index ef782ae..0000000
--- a/src/wrapped/generated/wrappedgssapiundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgssapiUNDEFS_H_
-#define __wrappedgssapiUNDEFS_H_
-
-
-#endif // __wrappedgssapiUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedgstappdefs.h b/src/wrapped/generated/wrappedgstappdefs.h
deleted file mode 100644
index 08ff494..0000000
--- a/src/wrapped/generated/wrappedgstappdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgstappDEFS_H_
-#define __wrappedgstappDEFS_H_
-
-
-#endif // __wrappedgstappDEFS_H_
diff --git a/src/wrapped/generated/wrappedgstapptypes.h b/src/wrapped/generated/wrappedgstapptypes.h
deleted file mode 100644
index 8c77242..0000000
--- a/src/wrapped/generated/wrappedgstapptypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgstappTYPES_H_
-#define __wrappedgstappTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedgstappTYPES_H_
diff --git a/src/wrapped/generated/wrappedgstappundefs.h b/src/wrapped/generated/wrappedgstappundefs.h
deleted file mode 100644
index ead9db5..0000000
--- a/src/wrapped/generated/wrappedgstappundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgstappUNDEFS_H_
-#define __wrappedgstappUNDEFS_H_
-
-
-#endif // __wrappedgstappUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedgstaudiodefs.h b/src/wrapped/generated/wrappedgstaudiodefs.h
deleted file mode 100644
index 6678aba..0000000
--- a/src/wrapped/generated/wrappedgstaudiodefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgstaudioDEFS_H_
-#define __wrappedgstaudioDEFS_H_
-
-
-#endif // __wrappedgstaudioDEFS_H_
diff --git a/src/wrapped/generated/wrappedgstaudiotypes.h b/src/wrapped/generated/wrappedgstaudiotypes.h
deleted file mode 100644
index 4ef77ac..0000000
--- a/src/wrapped/generated/wrappedgstaudiotypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgstaudioTYPES_H_
-#define __wrappedgstaudioTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedgstaudioTYPES_H_
diff --git a/src/wrapped/generated/wrappedgstaudioundefs.h b/src/wrapped/generated/wrappedgstaudioundefs.h
deleted file mode 100644
index 91e991a..0000000
--- a/src/wrapped/generated/wrappedgstaudioundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgstaudioUNDEFS_H_
-#define __wrappedgstaudioUNDEFS_H_
-
-
-#endif // __wrappedgstaudioUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedgstbasedefs.h b/src/wrapped/generated/wrappedgstbasedefs.h
deleted file mode 100644
index 4820277..0000000
--- a/src/wrapped/generated/wrappedgstbasedefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgstbaseDEFS_H_
-#define __wrappedgstbaseDEFS_H_
-
-
-#endif // __wrappedgstbaseDEFS_H_
diff --git a/src/wrapped/generated/wrappedgstbasetypes.h b/src/wrapped/generated/wrappedgstbasetypes.h
deleted file mode 100644
index 63d7b20..0000000
--- a/src/wrapped/generated/wrappedgstbasetypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgstbaseTYPES_H_
-#define __wrappedgstbaseTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedgstbaseTYPES_H_
diff --git a/src/wrapped/generated/wrappedgstbaseundefs.h b/src/wrapped/generated/wrappedgstbaseundefs.h
deleted file mode 100644
index 1a9fd51..0000000
--- a/src/wrapped/generated/wrappedgstbaseundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgstbaseUNDEFS_H_
-#define __wrappedgstbaseUNDEFS_H_
-
-
-#endif // __wrappedgstbaseUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedgstgldefs.h b/src/wrapped/generated/wrappedgstgldefs.h
deleted file mode 100644
index 512d890..0000000
--- a/src/wrapped/generated/wrappedgstgldefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgstglDEFS_H_
-#define __wrappedgstglDEFS_H_
-
-
-#endif // __wrappedgstglDEFS_H_
diff --git a/src/wrapped/generated/wrappedgstgltypes.h b/src/wrapped/generated/wrappedgstgltypes.h
deleted file mode 100644
index a9efbe5..0000000
--- a/src/wrapped/generated/wrappedgstgltypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgstglTYPES_H_
-#define __wrappedgstglTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedgstglTYPES_H_
diff --git a/src/wrapped/generated/wrappedgstglundefs.h b/src/wrapped/generated/wrappedgstglundefs.h
deleted file mode 100644
index 0aac8ba..0000000
--- a/src/wrapped/generated/wrappedgstglundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgstglUNDEFS_H_
-#define __wrappedgstglUNDEFS_H_
-
-
-#endif // __wrappedgstglUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedgstreamerdefs.h b/src/wrapped/generated/wrappedgstreamerdefs.h
deleted file mode 100644
index dfed474..0000000
--- a/src/wrapped/generated/wrappedgstreamerdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgstreamerDEFS_H_
-#define __wrappedgstreamerDEFS_H_
-
-
-#endif // __wrappedgstreamerDEFS_H_
diff --git a/src/wrapped/generated/wrappedgstreamertypes.h b/src/wrapped/generated/wrappedgstreamertypes.h
deleted file mode 100644
index cbc8a5c..0000000
--- a/src/wrapped/generated/wrappedgstreamertypes.h
+++ /dev/null
@@ -1,42 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgstreamerTYPES_H_
-#define __wrappedgstreamerTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFppV_t)(void*, void*, ...);
-typedef void (*vFppA_t)(void*, void*, va_list);
-typedef int64_t (*iFppV_t)(void*, void*, ...);
-typedef int64_t (*iFppA_t)(void*, void*, va_list);
-typedef void* (*pFppV_t)(void*, void*, ...);
-typedef void (*vFpppp_t)(void*, void*, void*, void*);
-typedef void* (*pFiplllpp_t)(int64_t, void*, intptr_t, intptr_t, intptr_t, void*, void*);
-typedef void (*vFpippippV_t)(void*, int64_t, void*, void*, int64_t, void*, void*, ...);
-typedef void (*vFpippippA_t)(void*, int64_t, void*, void*, int64_t, void*, void*, va_list);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(gst_caps_set_simple, vFppV_t) \
- GO(gst_structure_remove_fields, vFppV_t) \
- GO(gst_caps_set_simple_valist, vFppA_t) \
- GO(gst_structure_remove_fields_valist, vFppA_t) \
- GO(gst_structure_get, iFppV_t) \
- GO(gst_structure_get_valist, iFppA_t) \
- GO(gst_structure_new, pFppV_t) \
- GO(gst_bus_set_sync_handler, vFpppp_t) \
- GO(gst_pad_set_activatemode_function_full, vFpppp_t) \
- GO(gst_pad_set_chain_function_full, vFpppp_t) \
- GO(gst_pad_set_event_function_full, vFpppp_t) \
- GO(gst_pad_set_getrange_function_full, vFpppp_t) \
- GO(gst_pad_set_query_function_full, vFpppp_t) \
- GO(gst_buffer_new_wrapped_full, pFiplllpp_t) \
- GO(gst_debug_log, vFpippippV_t) \
- GO(gst_debug_log_valist, vFpippippA_t)
-
-#endif // __wrappedgstreamerTYPES_H_
diff --git a/src/wrapped/generated/wrappedgstreamerundefs.h b/src/wrapped/generated/wrappedgstreamerundefs.h
deleted file mode 100644
index 2895e22..0000000
--- a/src/wrapped/generated/wrappedgstreamerundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgstreamerUNDEFS_H_
-#define __wrappedgstreamerUNDEFS_H_
-
-
-#endif // __wrappedgstreamerUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedgsttagdefs.h b/src/wrapped/generated/wrappedgsttagdefs.h
deleted file mode 100644
index 9d83ba8..0000000
--- a/src/wrapped/generated/wrappedgsttagdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgsttagDEFS_H_
-#define __wrappedgsttagDEFS_H_
-
-
-#endif // __wrappedgsttagDEFS_H_
diff --git a/src/wrapped/generated/wrappedgsttagtypes.h b/src/wrapped/generated/wrappedgsttagtypes.h
deleted file mode 100644
index eb1bcb4..0000000
--- a/src/wrapped/generated/wrappedgsttagtypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgsttagTYPES_H_
-#define __wrappedgsttagTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedgsttagTYPES_H_
diff --git a/src/wrapped/generated/wrappedgsttagundefs.h b/src/wrapped/generated/wrappedgsttagundefs.h
deleted file mode 100644
index e286007..0000000
--- a/src/wrapped/generated/wrappedgsttagundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgsttagUNDEFS_H_
-#define __wrappedgsttagUNDEFS_H_
-
-
-#endif // __wrappedgsttagUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedgstvideodefs.h b/src/wrapped/generated/wrappedgstvideodefs.h
deleted file mode 100644
index 6fca9a2..0000000
--- a/src/wrapped/generated/wrappedgstvideodefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgstvideoDEFS_H_
-#define __wrappedgstvideoDEFS_H_
-
-
-#endif // __wrappedgstvideoDEFS_H_
diff --git a/src/wrapped/generated/wrappedgstvideotypes.h b/src/wrapped/generated/wrappedgstvideotypes.h
deleted file mode 100644
index 5f279db..0000000
--- a/src/wrapped/generated/wrappedgstvideotypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgstvideoTYPES_H_
-#define __wrappedgstvideoTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedgstvideoTYPES_H_
diff --git a/src/wrapped/generated/wrappedgstvideoundefs.h b/src/wrapped/generated/wrappedgstvideoundefs.h
deleted file mode 100644
index 14be48e..0000000
--- a/src/wrapped/generated/wrappedgstvideoundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgstvideoUNDEFS_H_
-#define __wrappedgstvideoUNDEFS_H_
-
-
-#endif // __wrappedgstvideoUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedgthread2defs.h b/src/wrapped/generated/wrappedgthread2defs.h
deleted file mode 100644
index 7e7da9b..0000000
--- a/src/wrapped/generated/wrappedgthread2defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgthread2DEFS_H_
-#define __wrappedgthread2DEFS_H_
-
-
-#endif // __wrappedgthread2DEFS_H_
diff --git a/src/wrapped/generated/wrappedgthread2types.h b/src/wrapped/generated/wrappedgthread2types.h
deleted file mode 100644
index 42e76d1..0000000
--- a/src/wrapped/generated/wrappedgthread2types.h
+++ /dev/null
@@ -1,20 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgthread2TYPES_H_
-#define __wrappedgthread2TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFp_t)(void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(g_thread_init, vFp_t) \
- GO(g_thread_init_with_errorcheck_mutexes, vFp_t)
-
-#endif // __wrappedgthread2TYPES_H_
diff --git a/src/wrapped/generated/wrappedgthread2undefs.h b/src/wrapped/generated/wrappedgthread2undefs.h
deleted file mode 100644
index f52b279..0000000
--- a/src/wrapped/generated/wrappedgthread2undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgthread2UNDEFS_H_
-#define __wrappedgthread2UNDEFS_H_
-
-
-#endif // __wrappedgthread2UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedgtk3defs.h b/src/wrapped/generated/wrappedgtk3defs.h
deleted file mode 100644
index e237bd6..0000000
--- a/src/wrapped/generated/wrappedgtk3defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgtk3DEFS_H_
-#define __wrappedgtk3DEFS_H_
-
-
-#endif // __wrappedgtk3DEFS_H_
diff --git a/src/wrapped/generated/wrappedgtk3types.h b/src/wrapped/generated/wrappedgtk3types.h
deleted file mode 100644
index e4997e7..0000000
--- a/src/wrapped/generated/wrappedgtk3types.h
+++ /dev/null
@@ -1,79 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgtk3TYPES_H_
-#define __wrappedgtk3TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void* (*pFi_t)(int64_t);
-typedef void (*vFpp_t)(void*, void*);
-typedef void (*vFpA_t)(void*, va_list);
-typedef int64_t (*iFLp_t)(uintptr_t, void*);
-typedef int64_t (*iFpp_t)(void*, void*);
-typedef void* (*pFuV_t)(uint64_t, ...);
-typedef void (*vFpiA_t)(void*, int64_t, va_list);
-typedef void (*vFppp_t)(void*, void*, void*);
-typedef void (*vFppV_t)(void*, void*, ...);
-typedef uint64_t (*uFupp_t)(uint64_t, void*, void*);
-typedef void (*vFpppi_t)(void*, void*, void*, int64_t);
-typedef void (*vFpppp_t)(void*, void*, void*, void*);
-typedef int64_t (*iFpppp_t)(void*, void*, void*, void*);
-typedef void (*vFpippp_t)(void*, int64_t, void*, void*, void*);
-typedef void (*vFppppp_t)(void*, void*, void*, void*, void*);
-typedef int64_t (*iFppuppp_t)(void*, void*, uint64_t, void*, void*, void*);
-typedef int64_t (*iFpppppp_t)(void*, void*, void*, void*, void*, void*);
-typedef void (*vFpppppuu_t)(void*, void*, void*, void*, void*, uint64_t, uint64_t);
-typedef void* (*pFppppppi_t)(void*, void*, void*, void*, void*, void*, int64_t);
-typedef void* (*pFppppppp_t)(void*, void*, void*, void*, void*, void*, void*);
-typedef uintptr_t (*LFppppppii_t)(void*, void*, void*, void*, void*, void*, int64_t, int64_t);
-typedef void* (*pFpppppppi_t)(void*, void*, void*, void*, void*, void*, void*, int64_t);
-typedef void* (*pFpippppppp_t)(void*, int64_t, void*, void*, void*, void*, void*, void*, void*);
-typedef void* (*pFpipppppppi_t)(void*, int64_t, void*, void*, void*, void*, void*, void*, void*, int64_t);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(gtk_type_class, pFi_t) \
- GO(gtk_builder_connect_signals, vFpp_t) \
- GO(gtk_init, vFpp_t) \
- GO(gtk_style_context_get_style_valist, vFpA_t) \
- GO(gtk_type_unique, iFLp_t) \
- GO(gtk_init_check, iFpp_t) \
- GO(gtk_tree_store_new, pFuV_t) \
- GO(gtk_style_context_get_valist, vFpiA_t) \
- GO(gtk_builder_connect_signals_full, vFppp_t) \
- GO(gtk_container_forall, vFppp_t) \
- GO(gtk_container_foreach, vFppp_t) \
- GO(gtk_menu_attach_to_widget, vFppp_t) \
- GO(gtk_dialog_add_buttons, vFppV_t) \
- GO(gtk_message_dialog_format_secondary_markup, vFppV_t) \
- GO(gtk_message_dialog_format_secondary_text, vFppV_t) \
- GO(gtk_timeout_add, uFupp_t) \
- GO(gtk_enumerate_printers, vFpppi_t) \
- GO(gtk_object_set_data_full, vFpppp_t) \
- GO(gtk_print_job_send, vFpppp_t) \
- GO(gtk_stock_set_translate_func, vFpppp_t) \
- GO(gtk_tree_sortable_set_default_sort_func, vFpppp_t) \
- GO(gtk_tree_view_set_search_equal_func, vFpppp_t) \
- GO(gtk_text_iter_backward_find_char, iFpppp_t) \
- GO(gtk_text_iter_forward_find_char, iFpppp_t) \
- GO(gtk_tree_sortable_set_sort_func, vFpippp_t) \
- GO(gtk_tree_view_column_set_cell_data_func, vFppppp_t) \
- GO(gtk_clipboard_set_with_data, iFppuppp_t) \
- GO(gtk_clipboard_set_with_owner, iFppuppp_t) \
- GO(gtk_init_with_args, iFpppppp_t) \
- GO(gtk_menu_popup, vFpppppuu_t) \
- GO(gtk_toolbar_insert_stock, pFppppppi_t) \
- GO(gtk_toolbar_append_item, pFppppppp_t) \
- GO(gtk_toolbar_prepend_item, pFppppppp_t) \
- GO(gtk_signal_connect_full, LFppppppii_t) \
- GO(gtk_toolbar_insert_item, pFpppppppi_t) \
- GO(gtk_toolbar_append_element, pFpippppppp_t) \
- GO(gtk_toolbar_prepend_element, pFpippppppp_t) \
- GO(gtk_toolbar_insert_element, pFpipppppppi_t)
-
-#endif // __wrappedgtk3TYPES_H_
diff --git a/src/wrapped/generated/wrappedgtk3undefs.h b/src/wrapped/generated/wrappedgtk3undefs.h
deleted file mode 100644
index 2432182..0000000
--- a/src/wrapped/generated/wrappedgtk3undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgtk3UNDEFS_H_
-#define __wrappedgtk3UNDEFS_H_
-
-
-#endif // __wrappedgtk3UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedgtkx112defs.h b/src/wrapped/generated/wrappedgtkx112defs.h
deleted file mode 100644
index e4242ce..0000000
--- a/src/wrapped/generated/wrappedgtkx112defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgtkx112DEFS_H_
-#define __wrappedgtkx112DEFS_H_
-
-
-#endif // __wrappedgtkx112DEFS_H_
diff --git a/src/wrapped/generated/wrappedgtkx112types.h b/src/wrapped/generated/wrappedgtkx112types.h
deleted file mode 100644
index c761d31..0000000
--- a/src/wrapped/generated/wrappedgtkx112types.h
+++ /dev/null
@@ -1,102 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgtkx112TYPES_H_
-#define __wrappedgtkx112TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef float (*fFp_t)(void*);
-typedef void* (*pFi_t)(int64_t);
-typedef void (*vFpp_t)(void*, void*);
-typedef int64_t (*iFpp_t)(void*, void*);
-typedef void* (*pFiV_t)(int64_t, ...);
-typedef void* (*pFpi_t)(void*, int64_t);
-typedef void (*vFppp_t)(void*, void*, void*);
-typedef void (*vFppV_t)(void*, void*, ...);
-typedef void (*vFppA_t)(void*, void*, va_list);
-typedef uint64_t (*uFupp_t)(uint64_t, void*, void*);
-typedef void* (*pFppp_t)(void*, void*, void*);
-typedef void (*vFppiV_t)(void*, void*, int64_t, ...);
-typedef void (*vFppup_t)(void*, void*, uint64_t, void*);
-typedef void (*vFpppp_t)(void*, void*, void*, void*);
-typedef int64_t (*iFpppp_t)(void*, void*, void*, void*);
-typedef uintptr_t (*LFpppp_t)(void*, void*, void*, void*);
-typedef void (*vFpippp_t)(void*, int64_t, void*, void*, void*);
-typedef void (*vFppupp_t)(void*, void*, uint64_t, void*, void*);
-typedef void (*vFppppp_t)(void*, void*, void*, void*, void*);
-typedef void (*vFpuipuV_t)(void*, uint64_t, int64_t, void*, uint64_t, ...);
-typedef int64_t (*iFppuppp_t)(void*, void*, uint64_t, void*, void*, void*);
-typedef int64_t (*iFpppppp_t)(void*, void*, void*, void*, void*, void*);
-typedef uint64_t (*uFiipppp_t)(int64_t, int64_t, void*, void*, void*, void*);
-typedef void (*vFpppppuu_t)(void*, void*, void*, void*, void*, uint64_t, uint64_t);
-typedef void* (*pFppppppi_t)(void*, void*, void*, void*, void*, void*, int64_t);
-typedef void* (*pFppppppp_t)(void*, void*, void*, void*, void*, void*, void*);
-typedef uintptr_t (*LFppppppii_t)(void*, void*, void*, void*, void*, void*, int64_t, int64_t);
-typedef void* (*pFpppppppi_t)(void*, void*, void*, void*, void*, void*, void*, int64_t);
-typedef void* (*pFpippppppp_t)(void*, int64_t, void*, void*, void*, void*, void*, void*, void*);
-typedef void* (*pFpipppppppi_t)(void*, int64_t, void*, void*, void*, void*, void*, void*, void*, int64_t);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(gtk_spin_button_get_value_as_float, fFp_t) \
- GO(gtk_type_class, pFi_t) \
- GO(gtk_builder_connect_signals, vFpp_t) \
- GO(gtk_init, vFpp_t) \
- GO(gtk_init_check, iFpp_t) \
- GO(gtk_type_unique, iFpp_t) \
- GO(gtk_list_store_new, pFiV_t) \
- GO(gtk_tree_store_new, pFiV_t) \
- GO(gtk_type_check_object_cast, pFpi_t) \
- GO(gtk_builder_connect_signals_full, vFppp_t) \
- GO(gtk_clipboard_request_text, vFppp_t) \
- GO(gtk_container_forall, vFppp_t) \
- GO(gtk_container_foreach, vFppp_t) \
- GO(gtk_menu_attach_to_widget, vFppp_t) \
- GO(gtk_tree_model_foreach, vFppp_t) \
- GO(gtk_tree_selection_selected_foreach, vFppp_t) \
- GO(gtk_dialog_add_buttons, vFppV_t) \
- GO(gtk_list_store_set, vFppV_t) \
- GO(gtk_message_dialog_format_secondary_markup, vFppV_t) \
- GO(gtk_message_dialog_format_secondary_text, vFppV_t) \
- GO(gtk_tree_model_get, vFppV_t) \
- GO(gtk_widget_style_get, vFppV_t) \
- GO(gtk_list_store_set_valist, vFppA_t) \
- GO(gtk_tree_model_get_valist, vFppA_t) \
- GO(gtk_widget_style_get_valist, vFppA_t) \
- GO(gtk_timeout_add, uFupp_t) \
- GO(gtk_link_button_set_uri_hook, pFppp_t) \
- GO(gtk_list_store_insert_with_values, vFppiV_t) \
- GO(gtk_action_group_add_actions, vFppup_t) \
- GO(gtk_clipboard_request_contents, vFpppp_t) \
- GO(gtk_object_set_data_full, vFpppp_t) \
- GO(gtk_stock_set_translate_func, vFpppp_t) \
- GO(gtk_tree_sortable_set_default_sort_func, vFpppp_t) \
- GO(gtk_tree_view_set_search_equal_func, vFpppp_t) \
- GO(gtk_text_iter_backward_find_char, iFpppp_t) \
- GO(gtk_text_iter_forward_find_char, iFpppp_t) \
- GO(gtk_signal_connect, LFpppp_t) \
- GO(gtk_tree_sortable_set_sort_func, vFpippp_t) \
- GO(gtk_action_group_add_actions_full, vFppupp_t) \
- GO(gtk_cell_layout_set_cell_data_func, vFppppp_t) \
- GO(gtk_tree_view_column_set_cell_data_func, vFppppp_t) \
- GO(gtk_binding_entry_add_signal, vFpuipuV_t) \
- GO(gtk_clipboard_set_with_data, iFppuppp_t) \
- GO(gtk_clipboard_set_with_owner, iFppuppp_t) \
- GO(gtk_init_with_args, iFpppppp_t) \
- GO(gtk_input_add_full, uFiipppp_t) \
- GO(gtk_menu_popup, vFpppppuu_t) \
- GO(gtk_toolbar_insert_stock, pFppppppi_t) \
- GO(gtk_toolbar_append_item, pFppppppp_t) \
- GO(gtk_toolbar_prepend_item, pFppppppp_t) \
- GO(gtk_signal_connect_full, LFppppppii_t) \
- GO(gtk_toolbar_insert_item, pFpppppppi_t) \
- GO(gtk_toolbar_append_element, pFpippppppp_t) \
- GO(gtk_toolbar_prepend_element, pFpippppppp_t) \
- GO(gtk_toolbar_insert_element, pFpipppppppi_t)
-
-#endif // __wrappedgtkx112TYPES_H_
diff --git a/src/wrapped/generated/wrappedgtkx112undefs.h b/src/wrapped/generated/wrappedgtkx112undefs.h
deleted file mode 100644
index 5ec7c31..0000000
--- a/src/wrapped/generated/wrappedgtkx112undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedgtkx112UNDEFS_H_
-#define __wrappedgtkx112UNDEFS_H_
-
-
-#endif // __wrappedgtkx112UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedkrb5defs.h b/src/wrapped/generated/wrappedkrb5defs.h
deleted file mode 100644
index ee2978c..0000000
--- a/src/wrapped/generated/wrappedkrb5defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedkrb5DEFS_H_
-#define __wrappedkrb5DEFS_H_
-
-
-#endif // __wrappedkrb5DEFS_H_
diff --git a/src/wrapped/generated/wrappedkrb5types.h b/src/wrapped/generated/wrappedkrb5types.h
deleted file mode 100644
index b42ba40..0000000
--- a/src/wrapped/generated/wrappedkrb5types.h
+++ /dev/null
@@ -1,19 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedkrb5TYPES_H_
-#define __wrappedkrb5TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef int64_t (*iFppppppipp_t)(void*, void*, void*, void*, void*, void*, int64_t, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(krb5_get_init_creds_password, iFppppppipp_t)
-
-#endif // __wrappedkrb5TYPES_H_
diff --git a/src/wrapped/generated/wrappedkrb5undefs.h b/src/wrapped/generated/wrappedkrb5undefs.h
deleted file mode 100644
index 71254f0..0000000
--- a/src/wrapped/generated/wrappedkrb5undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedkrb5UNDEFS_H_
-#define __wrappedkrb5UNDEFS_H_
-
-
-#endif // __wrappedkrb5UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlberdefs.h b/src/wrapped/generated/wrappedlberdefs.h
deleted file mode 100644
index b388dc4..0000000
--- a/src/wrapped/generated/wrappedlberdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlberDEFS_H_
-#define __wrappedlberDEFS_H_
-
-
-#endif // __wrappedlberDEFS_H_
diff --git a/src/wrapped/generated/wrappedlbertypes.h b/src/wrapped/generated/wrappedlbertypes.h
deleted file mode 100644
index 8fa92fe..0000000
--- a/src/wrapped/generated/wrappedlbertypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlberTYPES_H_
-#define __wrappedlberTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlberTYPES_H_
diff --git a/src/wrapped/generated/wrappedlberundefs.h b/src/wrapped/generated/wrappedlberundefs.h
deleted file mode 100644
index c75d5ac..0000000
--- a/src/wrapped/generated/wrappedlberundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlberUNDEFS_H_
-#define __wrappedlberUNDEFS_H_
-
-
-#endif // __wrappedlberUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedldaprdefs.h b/src/wrapped/generated/wrappedldaprdefs.h
deleted file mode 100644
index 8428723..0000000
--- a/src/wrapped/generated/wrappedldaprdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedldaprDEFS_H_
-#define __wrappedldaprDEFS_H_
-
-
-#endif // __wrappedldaprDEFS_H_
diff --git a/src/wrapped/generated/wrappedldaprtypes.h b/src/wrapped/generated/wrappedldaprtypes.h
deleted file mode 100644
index 6866703..0000000
--- a/src/wrapped/generated/wrappedldaprtypes.h
+++ /dev/null
@@ -1,19 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedldaprTYPES_H_
-#define __wrappedldaprTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef int64_t (*iFpppppupp_t)(void*, void*, void*, void*, void*, uint64_t, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(ldap_sasl_interactive_bind_s, iFpppppupp_t)
-
-#endif // __wrappedldaprTYPES_H_
diff --git a/src/wrapped/generated/wrappedldaprundefs.h b/src/wrapped/generated/wrappedldaprundefs.h
deleted file mode 100644
index f827eca..0000000
--- a/src/wrapped/generated/wrappedldaprundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedldaprUNDEFS_H_
-#define __wrappedldaprUNDEFS_H_
-
-
-#endif // __wrappedldaprUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedldlinuxdefs.h b/src/wrapped/generated/wrappedldlinuxdefs.h
deleted file mode 100644
index dbaafd0..0000000
--- a/src/wrapped/generated/wrappedldlinuxdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedldlinuxDEFS_H_
-#define __wrappedldlinuxDEFS_H_
-
-
-#endif // __wrappedldlinuxDEFS_H_
diff --git a/src/wrapped/generated/wrappedldlinuxtypes.h b/src/wrapped/generated/wrappedldlinuxtypes.h
deleted file mode 100644
index 2a45c50..0000000
--- a/src/wrapped/generated/wrappedldlinuxtypes.h
+++ /dev/null
@@ -1,19 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedldlinuxTYPES_H_
-#define __wrappedldlinuxTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void* (*pFp_t)(void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(__tls_get_addr, pFp_t)
-
-#endif // __wrappedldlinuxTYPES_H_
diff --git a/src/wrapped/generated/wrappedldlinuxundefs.h b/src/wrapped/generated/wrappedldlinuxundefs.h
deleted file mode 100644
index 070cd7c..0000000
--- a/src/wrapped/generated/wrappedldlinuxundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedldlinuxUNDEFS_H_
-#define __wrappedldlinuxUNDEFS_H_
-
-
-#endif // __wrappedldlinuxUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibasounddefs.h b/src/wrapped/generated/wrappedlibasounddefs.h
deleted file mode 100644
index 3abb424..0000000
--- a/src/wrapped/generated/wrappedlibasounddefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibasoundDEFS_H_
-#define __wrappedlibasoundDEFS_H_
-
-
-#endif // __wrappedlibasoundDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibasoundtypes.h b/src/wrapped/generated/wrappedlibasoundtypes.h
deleted file mode 100644
index 3d88453..0000000
--- a/src/wrapped/generated/wrappedlibasoundtypes.h
+++ /dev/null
@@ -1,28 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibasoundTYPES_H_
-#define __wrappedlibasoundTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef int64_t (*iFp_t)(void*);
-typedef void* (*pFppp_t)(void*, void*, void*);
-typedef int64_t (*iFpipp_t)(void*, int64_t, void*, void*);
-typedef int64_t (*iFpppp_t)(void*, void*, void*, void*);
-typedef void* (*pFpipL_t)(void*, int64_t, void*, uintptr_t);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(snd_dlclose, iFp_t) \
- GO(snd_lib_error_set_handler, iFp_t) \
- GO(snd_dlsym, pFppp_t) \
- GO(snd_async_add_handler, iFpipp_t) \
- GO(snd_async_add_pcm_handler, iFpppp_t) \
- GO(snd_dlopen, pFpipL_t)
-
-#endif // __wrappedlibasoundTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibasoundundefs.h b/src/wrapped/generated/wrappedlibasoundundefs.h
deleted file mode 100644
index c83082c..0000000
--- a/src/wrapped/generated/wrappedlibasoundundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibasoundUNDEFS_H_
-#define __wrappedlibasoundUNDEFS_H_
-
-
-#endif // __wrappedlibasoundUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibcdefs.h b/src/wrapped/generated/wrappedlibcdefs.h
deleted file mode 100644
index fa027ae..0000000
--- a/src/wrapped/generated/wrappedlibcdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibcDEFS_H_
-#define __wrappedlibcDEFS_H_
-
-
-#endif // __wrappedlibcDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibcryptdefs.h b/src/wrapped/generated/wrappedlibcryptdefs.h
deleted file mode 100644
index 8f1aeed..0000000
--- a/src/wrapped/generated/wrappedlibcryptdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibcryptDEFS_H_
-#define __wrappedlibcryptDEFS_H_
-
-
-#endif // __wrappedlibcryptDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibcrypttypes.h b/src/wrapped/generated/wrappedlibcrypttypes.h
deleted file mode 100644
index faea0e8..0000000
--- a/src/wrapped/generated/wrappedlibcrypttypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibcryptTYPES_H_
-#define __wrappedlibcryptTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibcryptTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibcryptundefs.h b/src/wrapped/generated/wrappedlibcryptundefs.h
deleted file mode 100644
index baf25d3..0000000
--- a/src/wrapped/generated/wrappedlibcryptundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibcryptUNDEFS_H_
-#define __wrappedlibcryptUNDEFS_H_
-
-
-#endif // __wrappedlibcryptUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibctypes.h b/src/wrapped/generated/wrappedlibctypes.h
deleted file mode 100644
index b84e785..0000000
--- a/src/wrapped/generated/wrappedlibctypes.h
+++ /dev/null
@@ -1,268 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibcTYPES_H_
-#define __wrappedlibcTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFv_t)(void);
-typedef void (*vFi_t)(int64_t);
-typedef void (*vFp_t)(void*);
-typedef int64_t (*iFv_t)(void);
-typedef int64_t (*iFi_t)(int64_t);
-typedef int64_t (*iFp_t)(void*);
-typedef intptr_t (*lFv_t)(void);
-typedef uintptr_t (*LFL_t)(uintptr_t);
-typedef void* (*pFp_t)(void*);
-typedef void (*vFpi_t)(void*, int64_t);
-typedef void (*vFpu_t)(void*, uint64_t);
-typedef void (*vFpp_t)(void*, void*);
-typedef void (*vFpV_t)(void*, ...);
-typedef int64_t (*iFip_t)(int64_t, void*);
-typedef int64_t (*iFpi_t)(void*, int64_t);
-typedef int64_t (*iFpL_t)(void*, uintptr_t);
-typedef int64_t (*iFpp_t)(void*, void*);
-typedef int64_t (*iFpV_t)(void*, ...);
-typedef int64_t (*iFpA_t)(void*, va_list);
-typedef int64_t (*iFSp_t)(void*, void*);
-typedef void* (*pFip_t)(int64_t, void*);
-typedef void* (*pFpi_t)(void*, int64_t);
-typedef void* (*pFpp_t)(void*, void*);
-typedef void (*vFipV_t)(int64_t, void*, ...);
-typedef void (*vFipA_t)(int64_t, void*, va_list);
-typedef void (*vFpii_t)(void*, int64_t, int64_t);
-typedef void (*vFpup_t)(void*, uint64_t, void*);
-typedef int64_t (*iFiip_t)(int64_t, int64_t, void*);
-typedef int64_t (*iFiiN_t)(int64_t, int64_t, ...);
-typedef int64_t (*iFipp_t)(int64_t, void*, void*);
-typedef int64_t (*iFipV_t)(int64_t, void*, ...);
-typedef int64_t (*iFpLi_t)(void*, uintptr_t, int64_t);
-typedef int64_t (*iFppi_t)(void*, void*, int64_t);
-typedef int64_t (*iFppp_t)(void*, void*, void*);
-typedef int64_t (*iFppV_t)(void*, void*, ...);
-typedef int64_t (*iFppA_t)(void*, void*, va_list);
-typedef int64_t (*iFpOu_t)(void*, int32_t, uint64_t);
-typedef intptr_t (*lFipV_t)(int64_t, void*, ...);
-typedef intptr_t (*lFppL_t)(void*, void*, uintptr_t);
-typedef uintptr_t (*LFppL_t)(void*, void*, uintptr_t);
-typedef void* (*pFpip_t)(void*, int64_t, void*);
-typedef void* (*pFppp_t)(void*, void*, void*);
-typedef void (*vFiipV_t)(int64_t, int64_t, void*, ...);
-typedef void (*vFiipA_t)(int64_t, int64_t, void*, va_list);
-typedef void (*vFpLLp_t)(void*, uintptr_t, uintptr_t, void*);
-typedef int64_t (*iFiiip_t)(int64_t, int64_t, int64_t, void*);
-typedef int64_t (*iFiiiN_t)(int64_t, int64_t, int64_t, ...);
-typedef int64_t (*iFipii_t)(int64_t, void*, int64_t, int64_t);
-typedef int64_t (*iFippi_t)(int64_t, void*, void*, int64_t);
-typedef int64_t (*iFippL_t)(int64_t, void*, void*, uintptr_t);
-typedef int64_t (*iFpipp_t)(void*, int64_t, void*, void*);
-typedef int64_t (*iFpipV_t)(void*, int64_t, void*, ...);
-typedef int64_t (*iFpipA_t)(void*, int64_t, void*, va_list);
-typedef int64_t (*iFpLpp_t)(void*, uintptr_t, void*, void*);
-typedef int64_t (*iFpLpV_t)(void*, uintptr_t, void*, ...);
-typedef int64_t (*iFpLpA_t)(void*, uintptr_t, void*, va_list);
-typedef int64_t (*iFppii_t)(void*, void*, int64_t, int64_t);
-typedef int64_t (*iFppiV_t)(void*, void*, int64_t, ...);
-typedef int64_t (*iFpppp_t)(void*, void*, void*, void*);
-typedef void (*vFpLLpp_t)(void*, uintptr_t, uintptr_t, void*, void*);
-typedef int64_t (*iFiippi_t)(int64_t, int64_t, void*, void*, int64_t);
-typedef int64_t (*iFiLLLL_t)(int64_t, uintptr_t, uintptr_t, uintptr_t, uintptr_t);
-typedef int64_t (*iFipiip_t)(int64_t, void*, int64_t, int64_t, void*);
-typedef int64_t (*iFipppp_t)(int64_t, void*, void*, void*, void*);
-typedef int64_t (*iFpilpV_t)(void*, int64_t, intptr_t, void*, ...);
-typedef int64_t (*iFpuppp_t)(void*, uint64_t, void*, void*, void*);
-typedef int64_t (*iFpLLpp_t)(void*, uintptr_t, uintptr_t, void*, void*);
-typedef void* (*pFpLLiN_t)(void*, uintptr_t, uintptr_t, int64_t, ...);
-typedef void* (*pFppLLp_t)(void*, void*, uintptr_t, uintptr_t, void*);
-typedef void* (*pFpppLp_t)(void*, void*, void*, uintptr_t, void*);
-typedef int64_t (*iFpLiLpV_t)(void*, uintptr_t, int64_t, uintptr_t, void*, ...);
-typedef int64_t (*iFpppppp_t)(void*, void*, void*, void*, void*, void*);
-typedef void* (*pFpLiiil_t)(void*, uintptr_t, int64_t, int64_t, int64_t, intptr_t);
-typedef int64_t (*iFpippppp_t)(void*, int64_t, void*, void*, void*, void*, void*);
-typedef int64_t (*iFppipppp_t)(void*, void*, int64_t, void*, void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(_Jv_RegisterClasses, vFv_t) \
- GO(__cxa_pure_virtual, vFv_t) \
- GO(__stack_chk_fail, vFv_t) \
- GO(_exit, vFi_t) \
- GO(exit, vFi_t) \
- GO(_ITM_deregisterTMCloneTable, vFp_t) \
- GO(__cxa_finalize, vFp_t) \
- GO(fork, iFv_t) \
- GO(vfork, iFv_t) \
- GO(iopl, iFi_t) \
- GO(_setjmp, iFp_t) \
- GO(atexit, iFp_t) \
- GO(getcontext, iFp_t) \
- GO(register_printf_type, iFp_t) \
- GO(setcontext, iFp_t) \
- GO(setjmp, iFp_t) \
- GO(stime, iFp_t) \
- GO(uname, iFp_t) \
- GO(syscall, lFv_t) \
- GO(getauxval, LFL_t) \
- GO(__deregister_frame_info, pFp_t) \
- GO(mallinfo, pFp_t) \
- GO(__longjmp_chk, vFpi_t) \
- GO(_longjmp, vFpi_t) \
- GO(_obstack_newchunk, vFpi_t) \
- GO(longjmp, vFpi_t) \
- GO(siglongjmp, vFpi_t) \
- GO(_ITM_registerTMCloneTable, vFpu_t) \
- GO(__register_frame_info, vFpp_t) \
- GO(_obstack_free, vFpp_t) \
- GO(obstack_free, vFpp_t) \
- GO(tdestroy, vFpp_t) \
- GO(warn, vFpV_t) \
- GO(warnx, vFpV_t) \
- GO(fstat, iFip_t) \
- GO(fstat64, iFip_t) \
- GO(__sigsetjmp, iFpi_t) \
- GO(backtrace, iFpi_t) \
- GO(sigsetjmp, iFpi_t) \
- GO(munmap, iFpL_t) \
- GO(__vprintf_chk, iFpp_t) \
- GO(dl_iterate_phdr, iFpp_t) \
- GO(execv, iFpp_t) \
- GO(execvp, iFpp_t) \
- GO(lstat, iFpp_t) \
- GO(lstat64, iFpp_t) \
- GO(sigaltstack, iFpp_t) \
- GO(stat, iFpp_t) \
- GO(stat64, iFpp_t) \
- GO(swapcontext, iFpp_t) \
- GO(__isoc99_scanf, iFpV_t) \
- GO(execl, iFpV_t) \
- GO(execlp, iFpV_t) \
- GO(printf, iFpV_t) \
- GO(wprintf, iFpV_t) \
- GO(vprintf, iFpA_t) \
- GO(_IO_file_stat, iFSp_t) \
- GO(__sysv_signal, pFip_t) \
- GO(signal, pFip_t) \
- GO(sigset, pFip_t) \
- GO(sysv_signal, pFip_t) \
- GO(backtrace_symbols, pFpi_t) \
- GO(__realpath_chk, pFpp_t) \
- GO(fopen, pFpp_t) \
- GO(fopen64, pFpp_t) \
- GO(realpath, pFpp_t) \
- GO(err, vFipV_t) \
- GO(errx, vFipV_t) \
- GO(syslog, vFipV_t) \
- GO(vsyslog, vFipA_t) \
- GO(backtrace_symbols_fd, vFpii_t) \
- GO(_ITM_addUserCommitAction, vFpup_t) \
- GO(__fxstat, iFiip_t) \
- GO(__fxstat64, iFiip_t) \
- GO(__fcntl, iFiiN_t) \
- GO(fcntl, iFiiN_t) \
- GO(fcntl64, iFiiN_t) \
- GO(__lxstat, iFipp_t) \
- GO(__lxstat64, iFipp_t) \
- GO(__sigaction, iFipp_t) \
- GO(__xstat, iFipp_t) \
- GO(__xstat64, iFipp_t) \
- GO(getopt, iFipp_t) \
- GO(register_printf_specifier, iFipp_t) \
- GO(sigaction, iFipp_t) \
- GO(__printf_chk, iFipV_t) \
- GO(mprotect, iFpLi_t) \
- GO(ftw, iFppi_t) \
- GO(ftw64, iFppi_t) \
- GO(__cxa_atexit, iFppp_t) \
- GO(__cxa_thread_atexit_impl, iFppp_t) \
- GO(__isoc99_vfscanf, iFppp_t) \
- GO(__isoc99_vsscanf, iFppp_t) \
- GO(__vfprintf_chk, iFppp_t) \
- GO(__vsscanf, iFppp_t) \
- GO(execve, iFppp_t) \
- GO(__asprintf, iFppV_t) \
- GO(__isoc99_fscanf, iFppV_t) \
- GO(__isoc99_sscanf, iFppV_t) \
- GO(asprintf, iFppV_t) \
- GO(fprintf, iFppV_t) \
- GO(fscanf, iFppV_t) \
- GO(fwprintf, iFppV_t) \
- GO(sprintf, iFppV_t) \
- GO(sscanf, iFppV_t) \
- GO(swscanf, iFppV_t) \
- GO(obstack_vprintf, iFppA_t) \
- GO(vasprintf, iFppA_t) \
- GO(vfprintf, iFppA_t) \
- GO(vfscanf, iFppA_t) \
- GO(vfwprintf, iFppA_t) \
- GO(vsprintf, iFppA_t) \
- GO(vsscanf, iFppA_t) \
- GO(vswscanf, iFppA_t) \
- GO(__open, iFpOu_t) \
- GO(open, iFpOu_t) \
- GO(open64, iFpOu_t) \
- GO(__wprintf_chk, lFipV_t) \
- GO(readlink, lFppL_t) \
- GO(strlcat, LFppL_t) \
- GO(strlcpy, LFppL_t) \
- GO(fts64_open, pFpip_t) \
- GO(fts_open, pFpip_t) \
- GO(tsearch, pFppp_t) \
- GO(__syslog_chk, vFiipV_t) \
- GO(__vsyslog_chk, vFiipA_t) \
- GO(qsort, vFpLLp_t) \
- GO(epoll_ctl, iFiiip_t) \
- GO(semctl, iFiiiN_t) \
- GO(epoll_wait, iFipii_t) \
- GO(fstatat, iFippi_t) \
- GO(fstatat64, iFippi_t) \
- GO(readlinkat, iFippL_t) \
- GO(__vasprintf_chk, iFpipp_t) \
- GO(glob, iFpipp_t) \
- GO(glob64, iFpipp_t) \
- GO(__asprintf_chk, iFpipV_t) \
- GO(__fprintf_chk, iFpipV_t) \
- GO(__fwprintf_chk, iFpipV_t) \
- GO(__vfwprintf_chk, iFpipA_t) \
- GO(__vsnprintf_chk, iFpLpp_t) \
- GO(__snprintf, iFpLpV_t) \
- GO(snprintf, iFpLpV_t) \
- GO(swprintf, iFpLpV_t) \
- GO(__vsnprintf, iFpLpA_t) \
- GO(vsnprintf, iFpLpA_t) \
- GO(vswprintf, iFpLpA_t) \
- GO(nftw64, iFppii_t) \
- GO(makecontext, iFppiV_t) \
- GO(__register_atfork, iFpppp_t) \
- GO(__vsprintf_chk, iFpppp_t) \
- GO(scandir, iFpppp_t) \
- GO(scandir64, iFpppp_t) \
- GO(qsort_r, vFpLLpp_t) \
- GO(__fxstatat, iFiippi_t) \
- GO(__fxstatat64, iFiippi_t) \
- GO(prctl, iFiLLLL_t) \
- GO(epoll_pwait, iFipiip_t) \
- GO(getopt_long, iFipppp_t) \
- GO(getopt_long_only, iFipppp_t) \
- GO(scandirat, iFipppp_t) \
- GO(__sprintf_chk, iFpilpV_t) \
- GO(__vswprintf_chk, iFpuppp_t) \
- GO(_obstack_begin, iFpLLpp_t) \
- GO(mremap, pFpLLiN_t) \
- GO(bsearch, pFppLLp_t) \
- GO(lfind, pFpppLp_t) \
- GO(lsearch, pFpppLp_t) \
- GO(__snprintf_chk, iFpLiLpV_t) \
- GO(__swprintf_chk, iFpLiLpV_t) \
- GO(posix_spawn, iFpppppp_t) \
- GO(posix_spawnp, iFpppppp_t) \
- GO(mmap, pFpLiiil_t) \
- GO(mmap64, pFpLiiil_t) \
- GO(__libc_start_main, iFpippppp_t) \
- GO(clone, iFppipppp_t)
-
-#endif // __wrappedlibcTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibcundefs.h b/src/wrapped/generated/wrappedlibcundefs.h
deleted file mode 100644
index b1542f7..0000000
--- a/src/wrapped/generated/wrappedlibcundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibcUNDEFS_H_
-#define __wrappedlibcUNDEFS_H_
-
-
-#endif // __wrappedlibcUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibcupsdefs.h b/src/wrapped/generated/wrappedlibcupsdefs.h
deleted file mode 100644
index c769ca4..0000000
--- a/src/wrapped/generated/wrappedlibcupsdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibcupsDEFS_H_
-#define __wrappedlibcupsDEFS_H_
-
-
-#endif // __wrappedlibcupsDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibcupstypes.h b/src/wrapped/generated/wrappedlibcupstypes.h
deleted file mode 100644
index c71d911..0000000
--- a/src/wrapped/generated/wrappedlibcupstypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibcupsTYPES_H_
-#define __wrappedlibcupsTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibcupsTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibcupsundefs.h b/src/wrapped/generated/wrappedlibcupsundefs.h
deleted file mode 100644
index e427bd0..0000000
--- a/src/wrapped/generated/wrappedlibcupsundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibcupsUNDEFS_H_
-#define __wrappedlibcupsUNDEFS_H_
-
-
-#endif // __wrappedlibcupsUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibdldefs.h b/src/wrapped/generated/wrappedlibdldefs.h
deleted file mode 100644
index f535aea..0000000
--- a/src/wrapped/generated/wrappedlibdldefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibdlDEFS_H_
-#define __wrappedlibdlDEFS_H_
-
-
-#endif // __wrappedlibdlDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibdltypes.h b/src/wrapped/generated/wrappedlibdltypes.h
deleted file mode 100644
index a37fa3d..0000000
--- a/src/wrapped/generated/wrappedlibdltypes.h
+++ /dev/null
@@ -1,36 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibdlTYPES_H_
-#define __wrappedlibdlTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef int64_t (*iFp_t)(void*);
-typedef void* (*pFv_t)(void);
-typedef int64_t (*iFpp_t)(void*, void*);
-typedef void* (*pFpi_t)(void*, int64_t);
-typedef void* (*pFpp_t)(void*, void*);
-typedef int64_t (*iFpip_t)(void*, int64_t, void*);
-typedef void* (*pFppi_t)(void*, void*, int64_t);
-typedef void* (*pFppp_t)(void*, void*, void*);
-typedef int64_t (*iFpppi_t)(void*, void*, void*, int64_t);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(dlclose, iFp_t) \
- GO(dlerror, pFv_t) \
- GO(_dl_find_object, iFpp_t) \
- GO(dladdr, iFpp_t) \
- GO(dlopen, pFpi_t) \
- GO(dlsym, pFpp_t) \
- GO(dlinfo, iFpip_t) \
- GO(dlmopen, pFppi_t) \
- GO(dlvsym, pFppp_t) \
- GO(dladdr1, iFpppi_t)
-
-#endif // __wrappedlibdlTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibdlundefs.h b/src/wrapped/generated/wrappedlibdlundefs.h
deleted file mode 100644
index 18f0bce..0000000
--- a/src/wrapped/generated/wrappedlibdlundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibdlUNDEFS_H_
-#define __wrappedlibdlUNDEFS_H_
-
-
-#endif // __wrappedlibdlUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibdrmdefs.h b/src/wrapped/generated/wrappedlibdrmdefs.h
deleted file mode 100644
index b29adef..0000000
--- a/src/wrapped/generated/wrappedlibdrmdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibdrmDEFS_H_
-#define __wrappedlibdrmDEFS_H_
-
-
-#endif // __wrappedlibdrmDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibdrmtypes.h b/src/wrapped/generated/wrappedlibdrmtypes.h
deleted file mode 100644
index 63a2c40..0000000
--- a/src/wrapped/generated/wrappedlibdrmtypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibdrmTYPES_H_
-#define __wrappedlibdrmTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibdrmTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibdrmundefs.h b/src/wrapped/generated/wrappedlibdrmundefs.h
deleted file mode 100644
index d987ddf..0000000
--- a/src/wrapped/generated/wrappedlibdrmundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibdrmUNDEFS_H_
-#define __wrappedlibdrmUNDEFS_H_
-
-
-#endif // __wrappedlibdrmUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibegldefs.h b/src/wrapped/generated/wrappedlibegldefs.h
deleted file mode 100644
index 359131c..0000000
--- a/src/wrapped/generated/wrappedlibegldefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibeglDEFS_H_
-#define __wrappedlibeglDEFS_H_
-
-
-#endif // __wrappedlibeglDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibegltypes.h b/src/wrapped/generated/wrappedlibegltypes.h
deleted file mode 100644
index 8fba212..0000000
--- a/src/wrapped/generated/wrappedlibegltypes.h
+++ /dev/null
@@ -1,19 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibeglTYPES_H_
-#define __wrappedlibeglTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void* (*pFp_t)(void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(eglGetProcAddress, pFp_t)
-
-#endif // __wrappedlibeglTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibeglundefs.h b/src/wrapped/generated/wrappedlibeglundefs.h
deleted file mode 100644
index c79c549..0000000
--- a/src/wrapped/generated/wrappedlibeglundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibeglUNDEFS_H_
-#define __wrappedlibeglUNDEFS_H_
-
-
-#endif // __wrappedlibeglUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibformdefs.h b/src/wrapped/generated/wrappedlibformdefs.h
deleted file mode 100644
index 51779f9..0000000
--- a/src/wrapped/generated/wrappedlibformdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibformDEFS_H_
-#define __wrappedlibformDEFS_H_
-
-
-#endif // __wrappedlibformDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibformtypes.h b/src/wrapped/generated/wrappedlibformtypes.h
deleted file mode 100644
index c8f8fd7..0000000
--- a/src/wrapped/generated/wrappedlibformtypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibformTYPES_H_
-#define __wrappedlibformTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibformTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibformundefs.h b/src/wrapped/generated/wrappedlibformundefs.h
deleted file mode 100644
index a1dba72..0000000
--- a/src/wrapped/generated/wrappedlibformundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibformUNDEFS_H_
-#define __wrappedlibformUNDEFS_H_
-
-
-#endif // __wrappedlibformUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibformwdefs.h b/src/wrapped/generated/wrappedlibformwdefs.h
deleted file mode 100644
index f7eb889..0000000
--- a/src/wrapped/generated/wrappedlibformwdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibformwDEFS_H_
-#define __wrappedlibformwDEFS_H_
-
-
-#endif // __wrappedlibformwDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibformwtypes.h b/src/wrapped/generated/wrappedlibformwtypes.h
deleted file mode 100644
index f26cabc..0000000
--- a/src/wrapped/generated/wrappedlibformwtypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibformwTYPES_H_
-#define __wrappedlibformwTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibformwTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibformwundefs.h b/src/wrapped/generated/wrappedlibformwundefs.h
deleted file mode 100644
index 605025c..0000000
--- a/src/wrapped/generated/wrappedlibformwundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibformwUNDEFS_H_
-#define __wrappedlibformwUNDEFS_H_
-
-
-#endif // __wrappedlibformwUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibfusedefs.h b/src/wrapped/generated/wrappedlibfusedefs.h
deleted file mode 100644
index 5df78d6..0000000
--- a/src/wrapped/generated/wrappedlibfusedefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibfuseDEFS_H_
-#define __wrappedlibfuseDEFS_H_
-
-
-#endif // __wrappedlibfuseDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibfusetypes.h b/src/wrapped/generated/wrappedlibfusetypes.h
deleted file mode 100644
index 23bf251..0000000
--- a/src/wrapped/generated/wrappedlibfusetypes.h
+++ /dev/null
@@ -1,31 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibfuseTYPES_H_
-#define __wrappedlibfuseTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef int64_t (*iFpp_t)(void*, void*);
-typedef int64_t (*iFppd_t)(void*, void*, double);
-typedef int64_t (*iFppp_t)(void*, void*, void*);
-typedef int64_t (*iFpppp_t)(void*, void*, void*, void*);
-typedef void* (*pFppLp_t)(void*, void*, uintptr_t, void*);
-typedef int64_t (*iFippLp_t)(int64_t, void*, void*, uintptr_t, void*);
-typedef uintptr_t (*LFppLppU_t)(void*, void*, uintptr_t, void*, void*, uint64_t);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(fuse_reply_entry, iFpp_t) \
- GO(fuse_reply_attr, iFppd_t) \
- GO(fuse_reply_create, iFppp_t) \
- GO(fuse_opt_parse, iFpppp_t) \
- GO(fuse_lowlevel_new, pFppLp_t) \
- GO(fuse_main_real, iFippLp_t) \
- GO(fuse_add_direntry, LFppLppU_t)
-
-#endif // __wrappedlibfuseTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibfuseundefs.h b/src/wrapped/generated/wrappedlibfuseundefs.h
deleted file mode 100644
index 40fab7b..0000000
--- a/src/wrapped/generated/wrappedlibfuseundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibfuseUNDEFS_H_
-#define __wrappedlibfuseUNDEFS_H_
-
-
-#endif // __wrappedlibfuseUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibgldefs.h b/src/wrapped/generated/wrappedlibgldefs.h
deleted file mode 100644
index 808bd17..0000000
--- a/src/wrapped/generated/wrappedlibgldefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibglDEFS_H_
-#define __wrappedlibglDEFS_H_
-
-
-#endif // __wrappedlibglDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibgltypes.h b/src/wrapped/generated/wrappedlibgltypes.h
deleted file mode 100644
index 3cff305..0000000
--- a/src/wrapped/generated/wrappedlibgltypes.h
+++ /dev/null
@@ -1,30 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibglTYPES_H_
-#define __wrappedlibglTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef int64_t (*iFi_t)(int64_t);
-typedef void* (*pFp_t)(void*);
-typedef void (*vFpp_t)(void*, void*);
-typedef void (*vFipp_t)(int64_t, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(glXSwapIntervalMESA, iFi_t) \
- GO(glGetVkProcAddrNV, pFp_t) \
- GO(glXGetProcAddress, pFp_t) \
- GO(glXGetProcAddressARB, pFp_t) \
- GO(glDebugMessageCallback, vFpp_t) \
- GO(glDebugMessageCallbackAMD, vFpp_t) \
- GO(glDebugMessageCallbackARB, vFpp_t) \
- GO(glDebugMessageCallbackKHR, vFpp_t) \
- GO(glProgramCallbackMESA, vFipp_t)
-
-#endif // __wrappedlibglTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibgludefs.h b/src/wrapped/generated/wrappedlibgludefs.h
deleted file mode 100644
index 409a18d..0000000
--- a/src/wrapped/generated/wrappedlibgludefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibgluDEFS_H_
-#define __wrappedlibgluDEFS_H_
-
-
-#endif // __wrappedlibgluDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibglundefs.h b/src/wrapped/generated/wrappedlibglundefs.h
deleted file mode 100644
index 63370f0..0000000
--- a/src/wrapped/generated/wrappedlibglundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibglUNDEFS_H_
-#define __wrappedlibglUNDEFS_H_
-
-
-#endif // __wrappedlibglUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibglutypes.h b/src/wrapped/generated/wrappedlibglutypes.h
deleted file mode 100644
index 5fa4dd3..0000000
--- a/src/wrapped/generated/wrappedlibglutypes.h
+++ /dev/null
@@ -1,21 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibgluTYPES_H_
-#define __wrappedlibgluTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFpip_t)(void*, int64_t, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(gluNurbsCallback, vFpip_t) \
- GO(gluQuadricCallback, vFpip_t) \
- GO(gluTessCallback, vFpip_t)
-
-#endif // __wrappedlibgluTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibgluundefs.h b/src/wrapped/generated/wrappedlibgluundefs.h
deleted file mode 100644
index c301dcb..0000000
--- a/src/wrapped/generated/wrappedlibgluundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibgluUNDEFS_H_
-#define __wrappedlibgluUNDEFS_H_
-
-
-#endif // __wrappedlibgluUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibglxdefs.h b/src/wrapped/generated/wrappedlibglxdefs.h
deleted file mode 100644
index ec21a1f..0000000
--- a/src/wrapped/generated/wrappedlibglxdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibglxDEFS_H_
-#define __wrappedlibglxDEFS_H_
-
-
-#endif // __wrappedlibglxDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibglxtypes.h b/src/wrapped/generated/wrappedlibglxtypes.h
deleted file mode 100644
index 94a5a15..0000000
--- a/src/wrapped/generated/wrappedlibglxtypes.h
+++ /dev/null
@@ -1,20 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibglxTYPES_H_
-#define __wrappedlibglxTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void* (*pFp_t)(void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(glXGetProcAddress, pFp_t) \
- GO(glXGetProcAddressARB, pFp_t)
-
-#endif // __wrappedlibglxTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibglxundefs.h b/src/wrapped/generated/wrappedlibglxundefs.h
deleted file mode 100644
index 4113a9f..0000000
--- a/src/wrapped/generated/wrappedlibglxundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibglxUNDEFS_H_
-#define __wrappedlibglxUNDEFS_H_
-
-
-#endif // __wrappedlibglxUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibibusdefs.h b/src/wrapped/generated/wrappedlibibusdefs.h
deleted file mode 100644
index ca32b61..0000000
--- a/src/wrapped/generated/wrappedlibibusdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibibusDEFS_H_
-#define __wrappedlibibusDEFS_H_
-
-
-#endif // __wrappedlibibusDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibibustypes.h b/src/wrapped/generated/wrappedlibibustypes.h
deleted file mode 100644
index eddf0fd..0000000
--- a/src/wrapped/generated/wrappedlibibustypes.h
+++ /dev/null
@@ -1,33 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibibusTYPES_H_
-#define __wrappedlibibusTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFpippp_t)(void*, int64_t, void*, void*, void*);
-typedef void (*vFppippp_t)(void*, void*, int64_t, void*, void*, void*);
-typedef void (*vFpppippp_t)(void*, void*, void*, int64_t, void*, void*, void*);
-typedef void (*vFpuuuippp_t)(void*, uint64_t, uint64_t, uint64_t, int64_t, void*, void*, void*);
-typedef void (*vFppppippp_t)(void*, void*, void*, void*, int64_t, void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(ibus_bus_current_input_context_async, vFpippp_t) \
- GO(ibus_bus_get_global_engine_async, vFpippp_t) \
- GO(ibus_bus_list_active_engines_async, vFpippp_t) \
- GO(ibus_bus_list_engines_async, vFpippp_t) \
- GO(ibus_input_context_get_engine_async, vFpippp_t) \
- GO(ibus_bus_create_input_context_async, vFppippp_t) \
- GO(ibus_bus_set_global_engine_async, vFppippp_t) \
- GO(ibus_config_get_values_async, vFppippp_t) \
- GO(ibus_config_get_value_async, vFpppippp_t) \
- GO(ibus_input_context_process_key_event_async, vFpuuuippp_t) \
- GO(ibus_config_set_value_async, vFppppippp_t)
-
-#endif // __wrappedlibibusTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibibusundefs.h b/src/wrapped/generated/wrappedlibibusundefs.h
deleted file mode 100644
index be0fd23..0000000
--- a/src/wrapped/generated/wrappedlibibusundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibibusUNDEFS_H_
-#define __wrappedlibibusUNDEFS_H_
-
-
-#endif // __wrappedlibibusUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibicedefs.h b/src/wrapped/generated/wrappedlibicedefs.h
deleted file mode 100644
index 97706bc..0000000
--- a/src/wrapped/generated/wrappedlibicedefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibiceDEFS_H_
-#define __wrappedlibiceDEFS_H_
-
-
-#endif // __wrappedlibiceDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibicetypes.h b/src/wrapped/generated/wrappedlibicetypes.h
deleted file mode 100644
index 8957648..0000000
--- a/src/wrapped/generated/wrappedlibicetypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibiceTYPES_H_
-#define __wrappedlibiceTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibiceTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibiceundefs.h b/src/wrapped/generated/wrappedlibiceundefs.h
deleted file mode 100644
index c3c0ff6..0000000
--- a/src/wrapped/generated/wrappedlibiceundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibiceUNDEFS_H_
-#define __wrappedlibiceUNDEFS_H_
-
-
-#endif // __wrappedlibiceUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibmdefs.h b/src/wrapped/generated/wrappedlibmdefs.h
deleted file mode 100644
index 431714a..0000000
--- a/src/wrapped/generated/wrappedlibmdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibmDEFS_H_
-#define __wrappedlibmDEFS_H_
-
-
-#endif // __wrappedlibmDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibmtypes.h b/src/wrapped/generated/wrappedlibmtypes.h
deleted file mode 100644
index 139066b..0000000
--- a/src/wrapped/generated/wrappedlibmtypes.h
+++ /dev/null
@@ -1,58 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibmTYPES_H_
-#define __wrappedlibmTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef uint64_t (*UFV_t)(...);
-typedef float (*fFf_t)(float);
-typedef double (*dFd_t)(double);
-typedef float (*fFff_t)(float, float);
-typedef double (*dFdd_t)(double, double);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(cacosf, UFV_t) \
- GO(cacoshf, UFV_t) \
- GO(casinf, UFV_t) \
- GO(casinhf, UFV_t) \
- GO(catanf, UFV_t) \
- GO(catanhf, UFV_t) \
- GO(__acosf_finite, fFf_t) \
- GO(__acoshf_finite, fFf_t) \
- GO(__asinf_finite, fFf_t) \
- GO(__coshf_finite, fFf_t) \
- GO(__exp2f_finite, fFf_t) \
- GO(__expf_finite, fFf_t) \
- GO(__log10f_finite, fFf_t) \
- GO(__log2f_finite, fFf_t) \
- GO(__logf_finite, fFf_t) \
- GO(__sinhf_finite, fFf_t) \
- GO(__sqrtf_finite, fFf_t) \
- GO(__acos_finite, dFd_t) \
- GO(__acosh_finite, dFd_t) \
- GO(__asin_finite, dFd_t) \
- GO(__cosh_finite, dFd_t) \
- GO(__exp2_finite, dFd_t) \
- GO(__exp_finite, dFd_t) \
- GO(__log10_finite, dFd_t) \
- GO(__log2_finite, dFd_t) \
- GO(__log_finite, dFd_t) \
- GO(__sinh_finite, dFd_t) \
- GO(__sqrt_finite, dFd_t) \
- GO(__atan2f_finite, fFff_t) \
- GO(__fmodf_finite, fFff_t) \
- GO(__hypotf_finite, fFff_t) \
- GO(__powf_finite, fFff_t) \
- GO(__atan2_finite, dFdd_t) \
- GO(__fmod_finite, dFdd_t) \
- GO(__hypot_finite, dFdd_t) \
- GO(__pow_finite, dFdd_t)
-
-#endif // __wrappedlibmTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibmundefs.h b/src/wrapped/generated/wrappedlibmundefs.h
deleted file mode 100644
index 0727051..0000000
--- a/src/wrapped/generated/wrappedlibmundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibmUNDEFS_H_
-#define __wrappedlibmUNDEFS_H_
-
-
-#endif // __wrappedlibmUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibncurses6defs.h b/src/wrapped/generated/wrappedlibncurses6defs.h
deleted file mode 100644
index 52b9f8d..0000000
--- a/src/wrapped/generated/wrappedlibncurses6defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibncurses6DEFS_H_
-#define __wrappedlibncurses6DEFS_H_
-
-
-#endif // __wrappedlibncurses6DEFS_H_
diff --git a/src/wrapped/generated/wrappedlibncurses6types.h b/src/wrapped/generated/wrappedlibncurses6types.h
deleted file mode 100644
index 731a2ab..0000000
--- a/src/wrapped/generated/wrappedlibncurses6types.h
+++ /dev/null
@@ -1,29 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibncurses6TYPES_H_
-#define __wrappedlibncurses6TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void* (*pFv_t)(void);
-typedef int64_t (*iFpV_t)(void*, ...);
-typedef int64_t (*iFppV_t)(void*, void*, ...);
-typedef int64_t (*iFppA_t)(void*, void*, va_list);
-typedef int64_t (*iFiipV_t)(int64_t, int64_t, void*, ...);
-typedef int64_t (*iFpiipV_t)(void*, int64_t, int64_t, void*, ...);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(initscr, pFv_t) \
- GO(printw, iFpV_t) \
- GO(wprintw, iFppV_t) \
- GO(vwprintw, iFppA_t) \
- GO(mvprintw, iFiipV_t) \
- GO(mvwprintw, iFpiipV_t)
-
-#endif // __wrappedlibncurses6TYPES_H_
diff --git a/src/wrapped/generated/wrappedlibncurses6undefs.h b/src/wrapped/generated/wrappedlibncurses6undefs.h
deleted file mode 100644
index e3d2df3..0000000
--- a/src/wrapped/generated/wrappedlibncurses6undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibncurses6UNDEFS_H_
-#define __wrappedlibncurses6UNDEFS_H_
-
-
-#endif // __wrappedlibncurses6UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibncursesdefs.h b/src/wrapped/generated/wrappedlibncursesdefs.h
deleted file mode 100644
index 71e17d5..0000000
--- a/src/wrapped/generated/wrappedlibncursesdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibncursesDEFS_H_
-#define __wrappedlibncursesDEFS_H_
-
-
-#endif // __wrappedlibncursesDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibncursestypes.h b/src/wrapped/generated/wrappedlibncursestypes.h
deleted file mode 100644
index d312ace..0000000
--- a/src/wrapped/generated/wrappedlibncursestypes.h
+++ /dev/null
@@ -1,27 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibncursesTYPES_H_
-#define __wrappedlibncursesTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void* (*pFv_t)(void);
-typedef int64_t (*iFpV_t)(void*, ...);
-typedef int64_t (*iFppA_t)(void*, void*, va_list);
-typedef int64_t (*iFiipV_t)(int64_t, int64_t, void*, ...);
-typedef int64_t (*iFpiipV_t)(void*, int64_t, int64_t, void*, ...);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(initscr, pFv_t) \
- GO(printw, iFpV_t) \
- GO(vwprintw, iFppA_t) \
- GO(mvprintw, iFiipV_t) \
- GO(mvwprintw, iFpiipV_t)
-
-#endif // __wrappedlibncursesTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibncursesundefs.h b/src/wrapped/generated/wrappedlibncursesundefs.h
deleted file mode 100644
index 562f447..0000000
--- a/src/wrapped/generated/wrappedlibncursesundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibncursesUNDEFS_H_
-#define __wrappedlibncursesUNDEFS_H_
-
-
-#endif // __wrappedlibncursesUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibncursesw6defs.h b/src/wrapped/generated/wrappedlibncursesw6defs.h
deleted file mode 100644
index dd732c0..0000000
--- a/src/wrapped/generated/wrappedlibncursesw6defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibncursesw6DEFS_H_
-#define __wrappedlibncursesw6DEFS_H_
-
-
-#endif // __wrappedlibncursesw6DEFS_H_
diff --git a/src/wrapped/generated/wrappedlibncursesw6types.h b/src/wrapped/generated/wrappedlibncursesw6types.h
deleted file mode 100644
index 99ab01e..0000000
--- a/src/wrapped/generated/wrappedlibncursesw6types.h
+++ /dev/null
@@ -1,27 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibncursesw6TYPES_H_
-#define __wrappedlibncursesw6TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void* (*pFv_t)(void);
-typedef int64_t (*iFpV_t)(void*, ...);
-typedef int64_t (*iFppA_t)(void*, void*, va_list);
-typedef int64_t (*iFiipV_t)(int64_t, int64_t, void*, ...);
-typedef int64_t (*iFpiipV_t)(void*, int64_t, int64_t, void*, ...);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(initscr, pFv_t) \
- GO(printw, iFpV_t) \
- GO(vwprintw, iFppA_t) \
- GO(mvprintw, iFiipV_t) \
- GO(mvwprintw, iFpiipV_t)
-
-#endif // __wrappedlibncursesw6TYPES_H_
diff --git a/src/wrapped/generated/wrappedlibncursesw6undefs.h b/src/wrapped/generated/wrappedlibncursesw6undefs.h
deleted file mode 100644
index 2bfe842..0000000
--- a/src/wrapped/generated/wrappedlibncursesw6undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibncursesw6UNDEFS_H_
-#define __wrappedlibncursesw6UNDEFS_H_
-
-
-#endif // __wrappedlibncursesw6UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibncurseswdefs.h b/src/wrapped/generated/wrappedlibncurseswdefs.h
deleted file mode 100644
index ab1ce05..0000000
--- a/src/wrapped/generated/wrappedlibncurseswdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibncurseswDEFS_H_
-#define __wrappedlibncurseswDEFS_H_
-
-
-#endif // __wrappedlibncurseswDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibncurseswtypes.h b/src/wrapped/generated/wrappedlibncurseswtypes.h
deleted file mode 100644
index 1e9da3b..0000000
--- a/src/wrapped/generated/wrappedlibncurseswtypes.h
+++ /dev/null
@@ -1,29 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibncurseswTYPES_H_
-#define __wrappedlibncurseswTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void* (*pFv_t)(void);
-typedef int64_t (*iFpV_t)(void*, ...);
-typedef int64_t (*iFppV_t)(void*, void*, ...);
-typedef int64_t (*iFppA_t)(void*, void*, va_list);
-typedef int64_t (*iFiipV_t)(int64_t, int64_t, void*, ...);
-typedef int64_t (*iFpiipV_t)(void*, int64_t, int64_t, void*, ...);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(initscr, pFv_t) \
- GO(printw, iFpV_t) \
- GO(wprintw, iFppV_t) \
- GO(vwprintw, iFppA_t) \
- GO(mvprintw, iFiipV_t) \
- GO(mvwprintw, iFpiipV_t)
-
-#endif // __wrappedlibncurseswTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibncurseswundefs.h b/src/wrapped/generated/wrappedlibncurseswundefs.h
deleted file mode 100644
index c015142..0000000
--- a/src/wrapped/generated/wrappedlibncurseswundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibncurseswUNDEFS_H_
-#define __wrappedlibncurseswUNDEFS_H_
-
-
-#endif // __wrappedlibncurseswUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedliboggdefs.h b/src/wrapped/generated/wrappedliboggdefs.h
deleted file mode 100644
index 5fa59a2..0000000
--- a/src/wrapped/generated/wrappedliboggdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedliboggDEFS_H_
-#define __wrappedliboggDEFS_H_
-
-
-#endif // __wrappedliboggDEFS_H_
diff --git a/src/wrapped/generated/wrappedliboggtypes.h b/src/wrapped/generated/wrappedliboggtypes.h
deleted file mode 100644
index 35bfc4f..0000000
--- a/src/wrapped/generated/wrappedliboggtypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedliboggTYPES_H_
-#define __wrappedliboggTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedliboggTYPES_H_
diff --git a/src/wrapped/generated/wrappedliboggundefs.h b/src/wrapped/generated/wrappedliboggundefs.h
deleted file mode 100644
index 9432914..0000000
--- a/src/wrapped/generated/wrappedliboggundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedliboggUNDEFS_H_
-#define __wrappedliboggUNDEFS_H_
-
-
-#endif // __wrappedliboggUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibpaneldefs.h b/src/wrapped/generated/wrappedlibpaneldefs.h
deleted file mode 100644
index dad2f2b..0000000
--- a/src/wrapped/generated/wrappedlibpaneldefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibpanelDEFS_H_
-#define __wrappedlibpanelDEFS_H_
-
-
-#endif // __wrappedlibpanelDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibpaneltypes.h b/src/wrapped/generated/wrappedlibpaneltypes.h
deleted file mode 100644
index 44c2a62..0000000
--- a/src/wrapped/generated/wrappedlibpaneltypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibpanelTYPES_H_
-#define __wrappedlibpanelTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibpanelTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibpanelundefs.h b/src/wrapped/generated/wrappedlibpanelundefs.h
deleted file mode 100644
index b3cb890..0000000
--- a/src/wrapped/generated/wrappedlibpanelundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibpanelUNDEFS_H_
-#define __wrappedlibpanelUNDEFS_H_
-
-
-#endif // __wrappedlibpanelUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibpcidefs.h b/src/wrapped/generated/wrappedlibpcidefs.h
deleted file mode 100644
index 5bb7932..0000000
--- a/src/wrapped/generated/wrappedlibpcidefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibpciDEFS_H_
-#define __wrappedlibpciDEFS_H_
-
-
-#endif // __wrappedlibpciDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibpcitypes.h b/src/wrapped/generated/wrappedlibpcitypes.h
deleted file mode 100644
index 5f2e3db..0000000
--- a/src/wrapped/generated/wrappedlibpcitypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibpciTYPES_H_
-#define __wrappedlibpciTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibpciTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibpciundefs.h b/src/wrapped/generated/wrappedlibpciundefs.h
deleted file mode 100644
index 4119d2f..0000000
--- a/src/wrapped/generated/wrappedlibpciundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibpciUNDEFS_H_
-#define __wrappedlibpciUNDEFS_H_
-
-
-#endif // __wrappedlibpciUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibpcredefs.h b/src/wrapped/generated/wrappedlibpcredefs.h
deleted file mode 100644
index 2fa1409..0000000
--- a/src/wrapped/generated/wrappedlibpcredefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibpcreDEFS_H_
-#define __wrappedlibpcreDEFS_H_
-
-
-#endif // __wrappedlibpcreDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibpcretypes.h b/src/wrapped/generated/wrappedlibpcretypes.h
deleted file mode 100644
index dc704de..0000000
--- a/src/wrapped/generated/wrappedlibpcretypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibpcreTYPES_H_
-#define __wrappedlibpcreTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibpcreTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibpcreundefs.h b/src/wrapped/generated/wrappedlibpcreundefs.h
deleted file mode 100644
index 0fefa45..0000000
--- a/src/wrapped/generated/wrappedlibpcreundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibpcreUNDEFS_H_
-#define __wrappedlibpcreUNDEFS_H_
-
-
-#endif // __wrappedlibpcreUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibpthreaddefs.h b/src/wrapped/generated/wrappedlibpthreaddefs.h
deleted file mode 100644
index b42a934..0000000
--- a/src/wrapped/generated/wrappedlibpthreaddefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibpthreadDEFS_H_
-#define __wrappedlibpthreadDEFS_H_
-
-
-#endif // __wrappedlibpthreadDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibpthreadtypes.h b/src/wrapped/generated/wrappedlibpthreadtypes.h
deleted file mode 100644
index e30c74b..0000000
--- a/src/wrapped/generated/wrappedlibpthreadtypes.h
+++ /dev/null
@@ -1,113 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibpthreadTYPES_H_
-#define __wrappedlibpthreadTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFp_t)(void*);
-typedef int64_t (*iFp_t)(void*);
-typedef void (*vFpi_t)(void*, int64_t);
-typedef int64_t (*iFLp_t)(uintptr_t, void*);
-typedef int64_t (*iFpi_t)(void*, int64_t);
-typedef int64_t (*iFpL_t)(void*, uintptr_t);
-typedef int64_t (*iFpp_t)(void*, void*);
-typedef void (*vFppp_t)(void*, void*, void*);
-typedef int64_t (*iFpLp_t)(void*, uintptr_t, void*);
-typedef int64_t (*iFppu_t)(void*, void*, uint64_t);
-typedef int64_t (*iFppL_t)(void*, void*, uintptr_t);
-typedef int64_t (*iFppp_t)(void*, void*, void*);
-typedef int64_t (*iFppip_t)(void*, void*, int64_t, void*);
-typedef int64_t (*iFpppp_t)(void*, void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(__pthread_register_cancel, vFp_t) \
- GO(__pthread_unregister_cancel, vFp_t) \
- GO(__pthread_unwind_next, vFp_t) \
- GO(__pthread_mutex_destroy, iFp_t) \
- GO(__pthread_mutex_lock, iFp_t) \
- GO(__pthread_mutex_trylock, iFp_t) \
- GO(__pthread_mutex_unlock, iFp_t) \
- GO(__pthread_mutexattr_destroy, iFp_t) \
- GO(__pthread_mutexattr_init, iFp_t) \
- GO(pthread_attr_destroy, iFp_t) \
- GO(pthread_attr_init, iFp_t) \
- GO(pthread_barrierattr_destroy, iFp_t) \
- GO(pthread_barrierattr_init, iFp_t) \
- GO(pthread_cond_broadcast, iFp_t) \
- GO(pthread_cond_destroy, iFp_t) \
- GO(pthread_condattr_destroy, iFp_t) \
- GO(pthread_condattr_init, iFp_t) \
- GO(pthread_getattr_default_np, iFp_t) \
- GO(pthread_mutex_destroy, iFp_t) \
- GO(pthread_mutex_lock, iFp_t) \
- GO(pthread_mutex_trylock, iFp_t) \
- GO(pthread_mutex_unlock, iFp_t) \
- GO(pthread_mutexattr_destroy, iFp_t) \
- GO(pthread_mutexattr_init, iFp_t) \
- GO(pthread_setattr_default_np, iFp_t) \
- GO(_pthread_cleanup_pop, vFpi_t) \
- GO(_pthread_cleanup_pop_restore, vFpi_t) \
- GO(pthread_getattr_np, iFLp_t) \
- GO(__pthread_mutexattr_settype, iFpi_t) \
- GO(pthread_attr_setdetachstate, iFpi_t) \
- GO(pthread_attr_setinheritsched, iFpi_t) \
- GO(pthread_attr_setschedpolicy, iFpi_t) \
- GO(pthread_attr_setscope, iFpi_t) \
- GO(pthread_barrierattr_setpshared, iFpi_t) \
- GO(pthread_condattr_setclock, iFpi_t) \
- GO(pthread_condattr_setpshared, iFpi_t) \
- GO(pthread_kill, iFpi_t) \
- GO(pthread_kill@GLIBC_2.2.5, iFpi_t) \
- GO(pthread_mutexattr_setkind_np, iFpi_t) \
- GO(pthread_mutexattr_setprotocol, iFpi_t) \
- GO(pthread_mutexattr_setpshared, iFpi_t) \
- GO(pthread_mutexattr_settype, iFpi_t) \
- GO(pthread_attr_setguardsize, iFpL_t) \
- GO(pthread_attr_setstacksize, iFpL_t) \
- GO(__pthread_key_create, iFpp_t) \
- GO(__pthread_mutex_init, iFpp_t) \
- GO(__pthread_once, iFpp_t) \
- GO(pthread_attr_getdetachstate, iFpp_t) \
- GO(pthread_attr_getguardsize, iFpp_t) \
- GO(pthread_attr_getinheritsched, iFpp_t) \
- GO(pthread_attr_getschedparam, iFpp_t) \
- GO(pthread_attr_getschedpolicy, iFpp_t) \
- GO(pthread_attr_getscope, iFpp_t) \
- GO(pthread_attr_getstackaddr, iFpp_t) \
- GO(pthread_attr_getstacksize, iFpp_t) \
- GO(pthread_attr_setschedparam, iFpp_t) \
- GO(pthread_attr_setstackaddr, iFpp_t) \
- GO(pthread_barrierattr_getpshared, iFpp_t) \
- GO(pthread_cond_init, iFpp_t) \
- GO(pthread_cond_wait, iFpp_t) \
- GO(pthread_condattr_getclock, iFpp_t) \
- GO(pthread_condattr_getpshared, iFpp_t) \
- GO(pthread_key_create, iFpp_t) \
- GO(pthread_mutex_init, iFpp_t) \
- GO(pthread_mutex_timedlock, iFpp_t) \
- GO(pthread_mutexattr_getkind_np, iFpp_t) \
- GO(pthread_mutexattr_getprotocol, iFpp_t) \
- GO(pthread_mutexattr_gettype, iFpp_t) \
- GO(pthread_once, iFpp_t) \
- GO(_pthread_cleanup_push, vFppp_t) \
- GO(_pthread_cleanup_push_defer, vFppp_t) \
- GO(pthread_attr_setaffinity_np, iFpLp_t) \
- GO(pthread_getaffinity_np, iFpLp_t) \
- GO(pthread_setaffinity_np, iFpLp_t) \
- GO(pthread_barrier_init, iFppu_t) \
- GO(pthread_attr_setstack, iFppL_t) \
- GO(__pthread_atfork, iFppp_t) \
- GO(pthread_atfork, iFppp_t) \
- GO(pthread_attr_getstack, iFppp_t) \
- GO(pthread_cond_timedwait, iFppp_t) \
- GO(pthread_cond_clockwait, iFppip_t) \
- GO(pthread_create, iFpppp_t)
-
-#endif // __wrappedlibpthreadTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibpthreadundefs.h b/src/wrapped/generated/wrappedlibpthreadundefs.h
deleted file mode 100644
index 2a0a70b..0000000
--- a/src/wrapped/generated/wrappedlibpthreadundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibpthreadUNDEFS_H_
-#define __wrappedlibpthreadUNDEFS_H_
-
-
-#endif // __wrappedlibpthreadUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibresolvdefs.h b/src/wrapped/generated/wrappedlibresolvdefs.h
deleted file mode 100644
index 45084ef..0000000
--- a/src/wrapped/generated/wrappedlibresolvdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibresolvDEFS_H_
-#define __wrappedlibresolvDEFS_H_
-
-
-#endif // __wrappedlibresolvDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibresolvtypes.h b/src/wrapped/generated/wrappedlibresolvtypes.h
deleted file mode 100644
index ab495b1..0000000
--- a/src/wrapped/generated/wrappedlibresolvtypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibresolvTYPES_H_
-#define __wrappedlibresolvTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibresolvTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibresolvundefs.h b/src/wrapped/generated/wrappedlibresolvundefs.h
deleted file mode 100644
index d5a9907..0000000
--- a/src/wrapped/generated/wrappedlibresolvundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibresolvUNDEFS_H_
-#define __wrappedlibresolvUNDEFS_H_
-
-
-#endif // __wrappedlibresolvUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibrtdefs.h b/src/wrapped/generated/wrappedlibrtdefs.h
deleted file mode 100644
index 8923cda..0000000
--- a/src/wrapped/generated/wrappedlibrtdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibrtDEFS_H_
-#define __wrappedlibrtDEFS_H_
-
-
-#endif // __wrappedlibrtDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibrttypes.h b/src/wrapped/generated/wrappedlibrttypes.h
deleted file mode 100644
index dac0dbb..0000000
--- a/src/wrapped/generated/wrappedlibrttypes.h
+++ /dev/null
@@ -1,19 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibrtTYPES_H_
-#define __wrappedlibrtTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef int64_t (*iFupp_t)(uint64_t, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(timer_create, iFupp_t)
-
-#endif // __wrappedlibrtTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibrtundefs.h b/src/wrapped/generated/wrappedlibrtundefs.h
deleted file mode 100644
index aeac4c1..0000000
--- a/src/wrapped/generated/wrappedlibrtundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibrtUNDEFS_H_
-#define __wrappedlibrtUNDEFS_H_
-
-
-#endif // __wrappedlibrtUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibsmdefs.h b/src/wrapped/generated/wrappedlibsmdefs.h
deleted file mode 100644
index c69b311..0000000
--- a/src/wrapped/generated/wrappedlibsmdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibsmDEFS_H_
-#define __wrappedlibsmDEFS_H_
-
-
-#endif // __wrappedlibsmDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibsmtypes.h b/src/wrapped/generated/wrappedlibsmtypes.h
deleted file mode 100644
index 78c65d2..0000000
--- a/src/wrapped/generated/wrappedlibsmtypes.h
+++ /dev/null
@@ -1,23 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibsmTYPES_H_
-#define __wrappedlibsmTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef int64_t (*iFppp_t)(void*, void*, void*);
-typedef int64_t (*iFpipp_t)(void*, int64_t, void*, void*);
-typedef void* (*pFppiiLpppip_t)(void*, void*, int64_t, int64_t, uintptr_t, void*, void*, void*, int64_t, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(SmcRequestSaveYourselfPhase2, iFppp_t) \
- GO(SmcInteractRequest, iFpipp_t) \
- GO(SmcOpenConnection, pFppiiLpppip_t)
-
-#endif // __wrappedlibsmTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibsmundefs.h b/src/wrapped/generated/wrappedlibsmundefs.h
deleted file mode 100644
index 6240aa2..0000000
--- a/src/wrapped/generated/wrappedlibsmundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibsmUNDEFS_H_
-#define __wrappedlibsmUNDEFS_H_
-
-
-#endif // __wrappedlibsmUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibsndfiledefs.h b/src/wrapped/generated/wrappedlibsndfiledefs.h
deleted file mode 100644
index 6c991da..0000000
--- a/src/wrapped/generated/wrappedlibsndfiledefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibsndfileDEFS_H_
-#define __wrappedlibsndfileDEFS_H_
-
-
-#endif // __wrappedlibsndfileDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibsndfiletypes.h b/src/wrapped/generated/wrappedlibsndfiletypes.h
deleted file mode 100644
index 36708b6..0000000
--- a/src/wrapped/generated/wrappedlibsndfiletypes.h
+++ /dev/null
@@ -1,21 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibsndfileTYPES_H_
-#define __wrappedlibsndfileTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef int64_t (*iFp_t)(void*);
-typedef void* (*pFpipp_t)(void*, int64_t, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(sf_close, iFp_t) \
- GO(sf_open_virtual, pFpipp_t)
-
-#endif // __wrappedlibsndfileTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibsndfileundefs.h b/src/wrapped/generated/wrappedlibsndfileundefs.h
deleted file mode 100644
index 8e0c4e8..0000000
--- a/src/wrapped/generated/wrappedlibsndfileundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibsndfileUNDEFS_H_
-#define __wrappedlibsndfileUNDEFS_H_
-
-
-#endif // __wrappedlibsndfileUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibssldefs.h b/src/wrapped/generated/wrappedlibssldefs.h
deleted file mode 100644
index fdbc0f6..0000000
--- a/src/wrapped/generated/wrappedlibssldefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibsslDEFS_H_
-#define __wrappedlibsslDEFS_H_
-
-
-#endif // __wrappedlibsslDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibssltypes.h b/src/wrapped/generated/wrappedlibssltypes.h
deleted file mode 100644
index cc567b6..0000000
--- a/src/wrapped/generated/wrappedlibssltypes.h
+++ /dev/null
@@ -1,34 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibsslTYPES_H_
-#define __wrappedlibsslTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void* (*pFp_t)(void*);
-typedef void (*vFpp_t)(void*, void*);
-typedef void (*vFpip_t)(void*, int64_t, void*);
-typedef void (*vFppp_t)(void*, void*, void*);
-typedef intptr_t (*lFpip_t)(void*, int64_t, void*);
-typedef int64_t (*iFlpppp_t)(intptr_t, void*, void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(SSL_get_verify_callback, pFp_t) \
- GO(SSL_CTX_set_client_cert_cb, vFpp_t) \
- GO(SSL_CTX_set_default_passwd_cb, vFpp_t) \
- GO(SSL_set_psk_client_callback, vFpp_t) \
- GO(SSL_CTX_set_verify, vFpip_t) \
- GO(SSL_set_verify, vFpip_t) \
- GO(SSL_CTX_set_cert_verify_callback, vFppp_t) \
- GO(SSL_CTX_set_next_proto_select_cb, vFppp_t) \
- GO(SSL_CTX_callback_ctrl, lFpip_t) \
- GO(SSL_callback_ctrl, lFpip_t) \
- GO(SSL_get_ex_new_index, iFlpppp_t)
-
-#endif // __wrappedlibsslTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibsslundefs.h b/src/wrapped/generated/wrappedlibsslundefs.h
deleted file mode 100644
index 77eacf6..0000000
--- a/src/wrapped/generated/wrappedlibsslundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibsslUNDEFS_H_
-#define __wrappedlibsslUNDEFS_H_
-
-
-#endif // __wrappedlibsslUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibtinfo6defs.h b/src/wrapped/generated/wrappedlibtinfo6defs.h
deleted file mode 100644
index 5e08e68..0000000
--- a/src/wrapped/generated/wrappedlibtinfo6defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibtinfo6DEFS_H_
-#define __wrappedlibtinfo6DEFS_H_
-
-
-#endif // __wrappedlibtinfo6DEFS_H_
diff --git a/src/wrapped/generated/wrappedlibtinfo6types.h b/src/wrapped/generated/wrappedlibtinfo6types.h
deleted file mode 100644
index 5e8deb4..0000000
--- a/src/wrapped/generated/wrappedlibtinfo6types.h
+++ /dev/null
@@ -1,19 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibtinfo6TYPES_H_
-#define __wrappedlibtinfo6TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef int64_t (*iFpip_t)(void*, int64_t, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(tputs, iFpip_t)
-
-#endif // __wrappedlibtinfo6TYPES_H_
diff --git a/src/wrapped/generated/wrappedlibtinfo6undefs.h b/src/wrapped/generated/wrappedlibtinfo6undefs.h
deleted file mode 100644
index 7d8b2d4..0000000
--- a/src/wrapped/generated/wrappedlibtinfo6undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibtinfo6UNDEFS_H_
-#define __wrappedlibtinfo6UNDEFS_H_
-
-
-#endif // __wrappedlibtinfo6UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibtinfodefs.h b/src/wrapped/generated/wrappedlibtinfodefs.h
deleted file mode 100644
index e3365ea..0000000
--- a/src/wrapped/generated/wrappedlibtinfodefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibtinfoDEFS_H_
-#define __wrappedlibtinfoDEFS_H_
-
-
-#endif // __wrappedlibtinfoDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibtinfotypes.h b/src/wrapped/generated/wrappedlibtinfotypes.h
deleted file mode 100644
index 150844c..0000000
--- a/src/wrapped/generated/wrappedlibtinfotypes.h
+++ /dev/null
@@ -1,19 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibtinfoTYPES_H_
-#define __wrappedlibtinfoTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef int64_t (*iFpip_t)(void*, int64_t, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(tputs, iFpip_t)
-
-#endif // __wrappedlibtinfoTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibtinfoundefs.h b/src/wrapped/generated/wrappedlibtinfoundefs.h
deleted file mode 100644
index 8723191..0000000
--- a/src/wrapped/generated/wrappedlibtinfoundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibtinfoUNDEFS_H_
-#define __wrappedlibtinfoUNDEFS_H_
-
-
-#endif // __wrappedlibtinfoUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibusb1defs.h b/src/wrapped/generated/wrappedlibusb1defs.h
deleted file mode 100644
index feab427..0000000
--- a/src/wrapped/generated/wrappedlibusb1defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibusb1DEFS_H_
-#define __wrappedlibusb1DEFS_H_
-
-
-#endif // __wrappedlibusb1DEFS_H_
diff --git a/src/wrapped/generated/wrappedlibusb1types.h b/src/wrapped/generated/wrappedlibusb1types.h
deleted file mode 100644
index f457b37..0000000
--- a/src/wrapped/generated/wrappedlibusb1types.h
+++ /dev/null
@@ -1,24 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibusb1TYPES_H_
-#define __wrappedlibusb1TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef int64_t (*iFp_t)(void*);
-typedef void* (*pFi_t)(int64_t);
-typedef int64_t (*iFpiiiiippp_t)(void*, int64_t, int64_t, int64_t, int64_t, int64_t, void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(libusb_cancel_transfer, iFp_t) \
- GO(libusb_submit_transfer, iFp_t) \
- GO(libusb_alloc_transfer, pFi_t) \
- GO(libusb_hotplug_register_callback, iFpiiiiippp_t)
-
-#endif // __wrappedlibusb1TYPES_H_
diff --git a/src/wrapped/generated/wrappedlibusb1undefs.h b/src/wrapped/generated/wrappedlibusb1undefs.h
deleted file mode 100644
index e7aff70..0000000
--- a/src/wrapped/generated/wrappedlibusb1undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibusb1UNDEFS_H_
-#define __wrappedlibusb1UNDEFS_H_
-
-
-#endif // __wrappedlibusb1UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibuuiddefs.h b/src/wrapped/generated/wrappedlibuuiddefs.h
deleted file mode 100644
index ad4e26d..0000000
--- a/src/wrapped/generated/wrappedlibuuiddefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibuuidDEFS_H_
-#define __wrappedlibuuidDEFS_H_
-
-
-#endif // __wrappedlibuuidDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibuuidtypes.h b/src/wrapped/generated/wrappedlibuuidtypes.h
deleted file mode 100644
index 307901c..0000000
--- a/src/wrapped/generated/wrappedlibuuidtypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibuuidTYPES_H_
-#define __wrappedlibuuidTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibuuidTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibuuidundefs.h b/src/wrapped/generated/wrappedlibuuidundefs.h
deleted file mode 100644
index 707daca..0000000
--- a/src/wrapped/generated/wrappedlibuuidundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibuuidUNDEFS_H_
-#define __wrappedlibuuidUNDEFS_H_
-
-
-#endif // __wrappedlibuuidUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibvadefs.h b/src/wrapped/generated/wrappedlibvadefs.h
deleted file mode 100644
index 1b99f08..0000000
--- a/src/wrapped/generated/wrappedlibvadefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibvaDEFS_H_
-#define __wrappedlibvaDEFS_H_
-
-
-#endif // __wrappedlibvaDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibvadrmdefs.h b/src/wrapped/generated/wrappedlibvadrmdefs.h
deleted file mode 100644
index 7ac42f0..0000000
--- a/src/wrapped/generated/wrappedlibvadrmdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibvadrmDEFS_H_
-#define __wrappedlibvadrmDEFS_H_
-
-
-#endif // __wrappedlibvadrmDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibvadrmtypes.h b/src/wrapped/generated/wrappedlibvadrmtypes.h
deleted file mode 100644
index 8a6c5a8..0000000
--- a/src/wrapped/generated/wrappedlibvadrmtypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibvadrmTYPES_H_
-#define __wrappedlibvadrmTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibvadrmTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibvadrmundefs.h b/src/wrapped/generated/wrappedlibvadrmundefs.h
deleted file mode 100644
index 6e2e90a..0000000
--- a/src/wrapped/generated/wrappedlibvadrmundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibvadrmUNDEFS_H_
-#define __wrappedlibvadrmUNDEFS_H_
-
-
-#endif // __wrappedlibvadrmUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibvatypes.h b/src/wrapped/generated/wrappedlibvatypes.h
deleted file mode 100644
index 3eed7ca..0000000
--- a/src/wrapped/generated/wrappedlibvatypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibvaTYPES_H_
-#define __wrappedlibvaTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibvaTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibvaundefs.h b/src/wrapped/generated/wrappedlibvaundefs.h
deleted file mode 100644
index fd9a509..0000000
--- a/src/wrapped/generated/wrappedlibvaundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibvaUNDEFS_H_
-#define __wrappedlibvaUNDEFS_H_
-
-
-#endif // __wrappedlibvaUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibvawaylanddefs.h b/src/wrapped/generated/wrappedlibvawaylanddefs.h
deleted file mode 100644
index 7e0459b..0000000
--- a/src/wrapped/generated/wrappedlibvawaylanddefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibvawaylandDEFS_H_
-#define __wrappedlibvawaylandDEFS_H_
-
-
-#endif // __wrappedlibvawaylandDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibvawaylandtypes.h b/src/wrapped/generated/wrappedlibvawaylandtypes.h
deleted file mode 100644
index 98b5d00..0000000
--- a/src/wrapped/generated/wrappedlibvawaylandtypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibvawaylandTYPES_H_
-#define __wrappedlibvawaylandTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibvawaylandTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibvawaylandundefs.h b/src/wrapped/generated/wrappedlibvawaylandundefs.h
deleted file mode 100644
index 8277a2b..0000000
--- a/src/wrapped/generated/wrappedlibvawaylandundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibvawaylandUNDEFS_H_
-#define __wrappedlibvawaylandUNDEFS_H_
-
-
-#endif // __wrappedlibvawaylandUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibvax11defs.h b/src/wrapped/generated/wrappedlibvax11defs.h
deleted file mode 100644
index ada2638..0000000
--- a/src/wrapped/generated/wrappedlibvax11defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibvax11DEFS_H_
-#define __wrappedlibvax11DEFS_H_
-
-
-#endif // __wrappedlibvax11DEFS_H_
diff --git a/src/wrapped/generated/wrappedlibvax11types.h b/src/wrapped/generated/wrappedlibvax11types.h
deleted file mode 100644
index cd3cc71..0000000
--- a/src/wrapped/generated/wrappedlibvax11types.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibvax11TYPES_H_
-#define __wrappedlibvax11TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibvax11TYPES_H_
diff --git a/src/wrapped/generated/wrappedlibvax11undefs.h b/src/wrapped/generated/wrappedlibvax11undefs.h
deleted file mode 100644
index f457431..0000000
--- a/src/wrapped/generated/wrappedlibvax11undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibvax11UNDEFS_H_
-#define __wrappedlibvax11UNDEFS_H_
-
-
-#endif // __wrappedlibvax11UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibvdpaudefs.h b/src/wrapped/generated/wrappedlibvdpaudefs.h
deleted file mode 100644
index 7535705..0000000
--- a/src/wrapped/generated/wrappedlibvdpaudefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibvdpauDEFS_H_
-#define __wrappedlibvdpauDEFS_H_
-
-
-#endif // __wrappedlibvdpauDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibvdpautypes.h b/src/wrapped/generated/wrappedlibvdpautypes.h
deleted file mode 100644
index 63f6635..0000000
--- a/src/wrapped/generated/wrappedlibvdpautypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibvdpauTYPES_H_
-#define __wrappedlibvdpauTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibvdpauTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibvdpauundefs.h b/src/wrapped/generated/wrappedlibvdpauundefs.h
deleted file mode 100644
index ff5d4ea..0000000
--- a/src/wrapped/generated/wrappedlibvdpauundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibvdpauUNDEFS_H_
-#define __wrappedlibvdpauUNDEFS_H_
-
-
-#endif // __wrappedlibvdpauUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibvorbisdefs.h b/src/wrapped/generated/wrappedlibvorbisdefs.h
deleted file mode 100644
index 8afb2c3..0000000
--- a/src/wrapped/generated/wrappedlibvorbisdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibvorbisDEFS_H_
-#define __wrappedlibvorbisDEFS_H_
-
-
-#endif // __wrappedlibvorbisDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibvorbistypes.h b/src/wrapped/generated/wrappedlibvorbistypes.h
deleted file mode 100644
index 118e611..0000000
--- a/src/wrapped/generated/wrappedlibvorbistypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibvorbisTYPES_H_
-#define __wrappedlibvorbisTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibvorbisTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibvorbisundefs.h b/src/wrapped/generated/wrappedlibvorbisundefs.h
deleted file mode 100644
index b1c5bca..0000000
--- a/src/wrapped/generated/wrappedlibvorbisundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibvorbisUNDEFS_H_
-#define __wrappedlibvorbisUNDEFS_H_
-
-
-#endif // __wrappedlibvorbisUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibx11defs.h b/src/wrapped/generated/wrappedlibx11defs.h
deleted file mode 100644
index 595a4c1..0000000
--- a/src/wrapped/generated/wrappedlibx11defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibx11DEFS_H_
-#define __wrappedlibx11DEFS_H_
-
-
-#endif // __wrappedlibx11DEFS_H_
diff --git a/src/wrapped/generated/wrappedlibx11types.h b/src/wrapped/generated/wrappedlibx11types.h
deleted file mode 100644
index b7727e2..0000000
--- a/src/wrapped/generated/wrappedlibx11types.h
+++ /dev/null
@@ -1,61 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibx11TYPES_H_
-#define __wrappedlibx11TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef int64_t (*iFp_t)(void*);
-typedef void* (*pFp_t)(void*);
-typedef void (*vFpp_t)(void*, void*);
-typedef void* (*pFiV_t)(int64_t, ...);
-typedef void* (*pFpi_t)(void*, int64_t);
-typedef void* (*pFpp_t)(void*, void*);
-typedef void* (*pFpV_t)(void*, ...);
-typedef int64_t (*iFppp_t)(void*, void*, void*);
-typedef void* (*pFpip_t)(void*, int64_t, void*);
-typedef int64_t (*iFpppp_t)(void*, void*, void*, void*);
-typedef int64_t (*iFppppp_t)(void*, void*, void*, void*, void*);
-typedef int64_t (*iFpppppp_t)(void*, void*, void*, void*, void*, void*);
-typedef void* (*pFppiiuuLi_t)(void*, void*, int64_t, int64_t, uint64_t, uint64_t, uintptr_t, int64_t);
-typedef int64_t (*iFppppiiiiuu_t)(void*, void*, void*, void*, int64_t, int64_t, int64_t, int64_t, uint64_t, uint64_t);
-typedef void* (*pFppuiipuuii_t)(void*, void*, uint64_t, int64_t, int64_t, void*, uint64_t, uint64_t, int64_t, int64_t);
-typedef void* (*pFppiiuuuipii_t)(void*, void*, int64_t, int64_t, uint64_t, uint64_t, uint64_t, int64_t, void*, int64_t, int64_t);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(XDestroyImage, iFp_t) \
- GO(XInitImage, iFp_t) \
- GO(XOpenDisplay, pFp_t) \
- GO(XSetErrorHandler, pFp_t) \
- GO(XSetIOErrorHandler, pFp_t) \
- GO(_XDeqAsyncHandler, vFpp_t) \
- GO(XVaCreateNestedList, pFiV_t) \
- GO(XSynchronize, pFpi_t) \
- GO(XSetAfterFunction, pFpp_t) \
- GO(XCreateIC, pFpV_t) \
- GO(XSetICValues, pFpV_t) \
- GO(XSetIMValues, pFpV_t) \
- GO(XAddConnectionWatch, iFppp_t) \
- GO(XRemoveConnectionWatch, iFppp_t) \
- GO(XESetCloseDisplay, pFpip_t) \
- GO(XESetError, pFpip_t) \
- GO(XESetEventToWire, pFpip_t) \
- GO(XESetWireToEvent, pFpip_t) \
- GO(XCheckIfEvent, iFpppp_t) \
- GO(XIfEvent, iFpppp_t) \
- GO(XPeekIfEvent, iFpppp_t) \
- GO(XQueryExtension, iFppppp_t) \
- GO(XRegisterIMInstantiateCallback, iFpppppp_t) \
- GO(XUnregisterIMInstantiateCallback, iFpppppp_t) \
- GO(XGetImage, pFppiiuuLi_t) \
- GO(XPutImage, iFppppiiiiuu_t) \
- GO(XCreateImage, pFppuiipuuii_t) \
- GO(XGetSubImage, pFppiiuuuipii_t)
-
-#endif // __wrappedlibx11TYPES_H_
diff --git a/src/wrapped/generated/wrappedlibx11undefs.h b/src/wrapped/generated/wrappedlibx11undefs.h
deleted file mode 100644
index 7322630..0000000
--- a/src/wrapped/generated/wrappedlibx11undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibx11UNDEFS_H_
-#define __wrappedlibx11UNDEFS_H_
-
-
-#endif // __wrappedlibx11UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibx11xcbdefs.h b/src/wrapped/generated/wrappedlibx11xcbdefs.h
deleted file mode 100644
index 111925a..0000000
--- a/src/wrapped/generated/wrappedlibx11xcbdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibx11xcbDEFS_H_
-#define __wrappedlibx11xcbDEFS_H_
-
-
-#endif // __wrappedlibx11xcbDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibx11xcbtypes.h b/src/wrapped/generated/wrappedlibx11xcbtypes.h
deleted file mode 100644
index b5f3334..0000000
--- a/src/wrapped/generated/wrappedlibx11xcbtypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibx11xcbTYPES_H_
-#define __wrappedlibx11xcbTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibx11xcbTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibx11xcbundefs.h b/src/wrapped/generated/wrappedlibx11xcbundefs.h
deleted file mode 100644
index e0cab2f..0000000
--- a/src/wrapped/generated/wrappedlibx11xcbundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibx11xcbUNDEFS_H_
-#define __wrappedlibx11xcbUNDEFS_H_
-
-
-#endif // __wrappedlibx11xcbUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxaudefs.h b/src/wrapped/generated/wrappedlibxaudefs.h
deleted file mode 100644
index cd58ce8..0000000
--- a/src/wrapped/generated/wrappedlibxaudefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxauDEFS_H_
-#define __wrappedlibxauDEFS_H_
-
-
-#endif // __wrappedlibxauDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxautypes.h b/src/wrapped/generated/wrappedlibxautypes.h
deleted file mode 100644
index b40bf39..0000000
--- a/src/wrapped/generated/wrappedlibxautypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxauTYPES_H_
-#define __wrappedlibxauTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxauTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxauundefs.h b/src/wrapped/generated/wrappedlibxauundefs.h
deleted file mode 100644
index 26b2e93..0000000
--- a/src/wrapped/generated/wrappedlibxauundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxauUNDEFS_H_
-#define __wrappedlibxauUNDEFS_H_
-
-
-#endif // __wrappedlibxauUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbdefs.h b/src/wrapped/generated/wrappedlibxcbdefs.h
deleted file mode 100644
index d8f4f64..0000000
--- a/src/wrapped/generated/wrappedlibxcbdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbDEFS_H_
-#define __wrappedlibxcbDEFS_H_
-
-
-#endif // __wrappedlibxcbDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbdri2defs.h b/src/wrapped/generated/wrappedlibxcbdri2defs.h
deleted file mode 100644
index 757f285..0000000
--- a/src/wrapped/generated/wrappedlibxcbdri2defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbdri2DEFS_H_
-#define __wrappedlibxcbdri2DEFS_H_
-
-
-#endif // __wrappedlibxcbdri2DEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbdri2types.h b/src/wrapped/generated/wrappedlibxcbdri2types.h
deleted file mode 100644
index 7d4ce15..0000000
--- a/src/wrapped/generated/wrappedlibxcbdri2types.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbdri2TYPES_H_
-#define __wrappedlibxcbdri2TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxcbdri2TYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxcbdri2undefs.h b/src/wrapped/generated/wrappedlibxcbdri2undefs.h
deleted file mode 100644
index adeeae8..0000000
--- a/src/wrapped/generated/wrappedlibxcbdri2undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbdri2UNDEFS_H_
-#define __wrappedlibxcbdri2UNDEFS_H_
-
-
-#endif // __wrappedlibxcbdri2UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbdri3defs.h b/src/wrapped/generated/wrappedlibxcbdri3defs.h
deleted file mode 100644
index 5bb0728..0000000
--- a/src/wrapped/generated/wrappedlibxcbdri3defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbdri3DEFS_H_
-#define __wrappedlibxcbdri3DEFS_H_
-
-
-#endif // __wrappedlibxcbdri3DEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbdri3types.h b/src/wrapped/generated/wrappedlibxcbdri3types.h
deleted file mode 100644
index 77a36ac..0000000
--- a/src/wrapped/generated/wrappedlibxcbdri3types.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbdri3TYPES_H_
-#define __wrappedlibxcbdri3TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxcbdri3TYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxcbdri3undefs.h b/src/wrapped/generated/wrappedlibxcbdri3undefs.h
deleted file mode 100644
index adecffe..0000000
--- a/src/wrapped/generated/wrappedlibxcbdri3undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbdri3UNDEFS_H_
-#define __wrappedlibxcbdri3UNDEFS_H_
-
-
-#endif // __wrappedlibxcbdri3UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbglxdefs.h b/src/wrapped/generated/wrappedlibxcbglxdefs.h
deleted file mode 100644
index 10c84bf..0000000
--- a/src/wrapped/generated/wrappedlibxcbglxdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbglxDEFS_H_
-#define __wrappedlibxcbglxDEFS_H_
-
-
-#endif // __wrappedlibxcbglxDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbglxtypes.h b/src/wrapped/generated/wrappedlibxcbglxtypes.h
deleted file mode 100644
index cd5fc05..0000000
--- a/src/wrapped/generated/wrappedlibxcbglxtypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbglxTYPES_H_
-#define __wrappedlibxcbglxTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxcbglxTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxcbglxundefs.h b/src/wrapped/generated/wrappedlibxcbglxundefs.h
deleted file mode 100644
index ae2cea7..0000000
--- a/src/wrapped/generated/wrappedlibxcbglxundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbglxUNDEFS_H_
-#define __wrappedlibxcbglxUNDEFS_H_
-
-
-#endif // __wrappedlibxcbglxUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbicccmdefs.h b/src/wrapped/generated/wrappedlibxcbicccmdefs.h
deleted file mode 100644
index 18f8278..0000000
--- a/src/wrapped/generated/wrappedlibxcbicccmdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbicccmDEFS_H_
-#define __wrappedlibxcbicccmDEFS_H_
-
-
-#endif // __wrappedlibxcbicccmDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbicccmtypes.h b/src/wrapped/generated/wrappedlibxcbicccmtypes.h
deleted file mode 100644
index 4df41ec..0000000
--- a/src/wrapped/generated/wrappedlibxcbicccmtypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbicccmTYPES_H_
-#define __wrappedlibxcbicccmTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxcbicccmTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxcbicccmundefs.h b/src/wrapped/generated/wrappedlibxcbicccmundefs.h
deleted file mode 100644
index fe936a2..0000000
--- a/src/wrapped/generated/wrappedlibxcbicccmundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbicccmUNDEFS_H_
-#define __wrappedlibxcbicccmUNDEFS_H_
-
-
-#endif // __wrappedlibxcbicccmUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbimagedefs.h b/src/wrapped/generated/wrappedlibxcbimagedefs.h
deleted file mode 100644
index 8141bf7..0000000
--- a/src/wrapped/generated/wrappedlibxcbimagedefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbimageDEFS_H_
-#define __wrappedlibxcbimageDEFS_H_
-
-
-#endif // __wrappedlibxcbimageDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbimagetypes.h b/src/wrapped/generated/wrappedlibxcbimagetypes.h
deleted file mode 100644
index 5a68ba4..0000000
--- a/src/wrapped/generated/wrappedlibxcbimagetypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbimageTYPES_H_
-#define __wrappedlibxcbimageTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxcbimageTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxcbimageundefs.h b/src/wrapped/generated/wrappedlibxcbimageundefs.h
deleted file mode 100644
index 92eaceb..0000000
--- a/src/wrapped/generated/wrappedlibxcbimageundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbimageUNDEFS_H_
-#define __wrappedlibxcbimageUNDEFS_H_
-
-
-#endif // __wrappedlibxcbimageUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbkeysymsdefs.h b/src/wrapped/generated/wrappedlibxcbkeysymsdefs.h
deleted file mode 100644
index a4592b0..0000000
--- a/src/wrapped/generated/wrappedlibxcbkeysymsdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbkeysymsDEFS_H_
-#define __wrappedlibxcbkeysymsDEFS_H_
-
-
-#endif // __wrappedlibxcbkeysymsDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbkeysymstypes.h b/src/wrapped/generated/wrappedlibxcbkeysymstypes.h
deleted file mode 100644
index da06b3b..0000000
--- a/src/wrapped/generated/wrappedlibxcbkeysymstypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbkeysymsTYPES_H_
-#define __wrappedlibxcbkeysymsTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxcbkeysymsTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxcbkeysymsundefs.h b/src/wrapped/generated/wrappedlibxcbkeysymsundefs.h
deleted file mode 100644
index 9faa169..0000000
--- a/src/wrapped/generated/wrappedlibxcbkeysymsundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbkeysymsUNDEFS_H_
-#define __wrappedlibxcbkeysymsUNDEFS_H_
-
-
-#endif // __wrappedlibxcbkeysymsUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbpresentdefs.h b/src/wrapped/generated/wrappedlibxcbpresentdefs.h
deleted file mode 100644
index 968c1bd..0000000
--- a/src/wrapped/generated/wrappedlibxcbpresentdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbpresentDEFS_H_
-#define __wrappedlibxcbpresentDEFS_H_
-
-
-#endif // __wrappedlibxcbpresentDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbpresenttypes.h b/src/wrapped/generated/wrappedlibxcbpresenttypes.h
deleted file mode 100644
index 0a8e55e..0000000
--- a/src/wrapped/generated/wrappedlibxcbpresenttypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbpresentTYPES_H_
-#define __wrappedlibxcbpresentTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxcbpresentTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxcbpresentundefs.h b/src/wrapped/generated/wrappedlibxcbpresentundefs.h
deleted file mode 100644
index 245a4ac..0000000
--- a/src/wrapped/generated/wrappedlibxcbpresentundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbpresentUNDEFS_H_
-#define __wrappedlibxcbpresentUNDEFS_H_
-
-
-#endif // __wrappedlibxcbpresentUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbrandrdefs.h b/src/wrapped/generated/wrappedlibxcbrandrdefs.h
deleted file mode 100644
index 31f2e42..0000000
--- a/src/wrapped/generated/wrappedlibxcbrandrdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbrandrDEFS_H_
-#define __wrappedlibxcbrandrDEFS_H_
-
-
-#endif // __wrappedlibxcbrandrDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbrandrtypes.h b/src/wrapped/generated/wrappedlibxcbrandrtypes.h
deleted file mode 100644
index 54ba46d..0000000
--- a/src/wrapped/generated/wrappedlibxcbrandrtypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbrandrTYPES_H_
-#define __wrappedlibxcbrandrTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxcbrandrTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxcbrandrundefs.h b/src/wrapped/generated/wrappedlibxcbrandrundefs.h
deleted file mode 100644
index a1089bf..0000000
--- a/src/wrapped/generated/wrappedlibxcbrandrundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbrandrUNDEFS_H_
-#define __wrappedlibxcbrandrUNDEFS_H_
-
-
-#endif // __wrappedlibxcbrandrUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbrenderdefs.h b/src/wrapped/generated/wrappedlibxcbrenderdefs.h
deleted file mode 100644
index bd06b22..0000000
--- a/src/wrapped/generated/wrappedlibxcbrenderdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbrenderDEFS_H_
-#define __wrappedlibxcbrenderDEFS_H_
-
-
-#endif // __wrappedlibxcbrenderDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbrendertypes.h b/src/wrapped/generated/wrappedlibxcbrendertypes.h
deleted file mode 100644
index 3a45351..0000000
--- a/src/wrapped/generated/wrappedlibxcbrendertypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbrenderTYPES_H_
-#define __wrappedlibxcbrenderTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxcbrenderTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxcbrenderundefs.h b/src/wrapped/generated/wrappedlibxcbrenderundefs.h
deleted file mode 100644
index 00c828e..0000000
--- a/src/wrapped/generated/wrappedlibxcbrenderundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbrenderUNDEFS_H_
-#define __wrappedlibxcbrenderUNDEFS_H_
-
-
-#endif // __wrappedlibxcbrenderUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbrenderutildefs.h b/src/wrapped/generated/wrappedlibxcbrenderutildefs.h
deleted file mode 100644
index d1a4589..0000000
--- a/src/wrapped/generated/wrappedlibxcbrenderutildefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbrenderutilDEFS_H_
-#define __wrappedlibxcbrenderutilDEFS_H_
-
-
-#endif // __wrappedlibxcbrenderutilDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbrenderutiltypes.h b/src/wrapped/generated/wrappedlibxcbrenderutiltypes.h
deleted file mode 100644
index 3885fef..0000000
--- a/src/wrapped/generated/wrappedlibxcbrenderutiltypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbrenderutilTYPES_H_
-#define __wrappedlibxcbrenderutilTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxcbrenderutilTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxcbrenderutilundefs.h b/src/wrapped/generated/wrappedlibxcbrenderutilundefs.h
deleted file mode 100644
index 40c59cb..0000000
--- a/src/wrapped/generated/wrappedlibxcbrenderutilundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbrenderutilUNDEFS_H_
-#define __wrappedlibxcbrenderutilUNDEFS_H_
-
-
-#endif // __wrappedlibxcbrenderutilUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbshapedefs.h b/src/wrapped/generated/wrappedlibxcbshapedefs.h
deleted file mode 100644
index 3299067..0000000
--- a/src/wrapped/generated/wrappedlibxcbshapedefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbshapeDEFS_H_
-#define __wrappedlibxcbshapeDEFS_H_
-
-
-#endif // __wrappedlibxcbshapeDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbshapetypes.h b/src/wrapped/generated/wrappedlibxcbshapetypes.h
deleted file mode 100644
index d87dfed..0000000
--- a/src/wrapped/generated/wrappedlibxcbshapetypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbshapeTYPES_H_
-#define __wrappedlibxcbshapeTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxcbshapeTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxcbshapeundefs.h b/src/wrapped/generated/wrappedlibxcbshapeundefs.h
deleted file mode 100644
index 545ba92..0000000
--- a/src/wrapped/generated/wrappedlibxcbshapeundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbshapeUNDEFS_H_
-#define __wrappedlibxcbshapeUNDEFS_H_
-
-
-#endif // __wrappedlibxcbshapeUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbshmdefs.h b/src/wrapped/generated/wrappedlibxcbshmdefs.h
deleted file mode 100644
index 55ca547..0000000
--- a/src/wrapped/generated/wrappedlibxcbshmdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbshmDEFS_H_
-#define __wrappedlibxcbshmDEFS_H_
-
-
-#endif // __wrappedlibxcbshmDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbshmtypes.h b/src/wrapped/generated/wrappedlibxcbshmtypes.h
deleted file mode 100644
index 106eb53..0000000
--- a/src/wrapped/generated/wrappedlibxcbshmtypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbshmTYPES_H_
-#define __wrappedlibxcbshmTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxcbshmTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxcbshmundefs.h b/src/wrapped/generated/wrappedlibxcbshmundefs.h
deleted file mode 100644
index f2bf2b1..0000000
--- a/src/wrapped/generated/wrappedlibxcbshmundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbshmUNDEFS_H_
-#define __wrappedlibxcbshmUNDEFS_H_
-
-
-#endif // __wrappedlibxcbshmUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbsyncdefs.h b/src/wrapped/generated/wrappedlibxcbsyncdefs.h
deleted file mode 100644
index ab9fd82..0000000
--- a/src/wrapped/generated/wrappedlibxcbsyncdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbsyncDEFS_H_
-#define __wrappedlibxcbsyncDEFS_H_
-
-
-#endif // __wrappedlibxcbsyncDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbsynctypes.h b/src/wrapped/generated/wrappedlibxcbsynctypes.h
deleted file mode 100644
index 6fd4213..0000000
--- a/src/wrapped/generated/wrappedlibxcbsynctypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbsyncTYPES_H_
-#define __wrappedlibxcbsyncTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxcbsyncTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxcbsyncundefs.h b/src/wrapped/generated/wrappedlibxcbsyncundefs.h
deleted file mode 100644
index cf6c5a0..0000000
--- a/src/wrapped/generated/wrappedlibxcbsyncundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbsyncUNDEFS_H_
-#define __wrappedlibxcbsyncUNDEFS_H_
-
-
-#endif // __wrappedlibxcbsyncUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbtypes.h b/src/wrapped/generated/wrappedlibxcbtypes.h
deleted file mode 100644
index 2391759..0000000
--- a/src/wrapped/generated/wrappedlibxcbtypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbTYPES_H_
-#define __wrappedlibxcbTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxcbTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxcbundefs.h b/src/wrapped/generated/wrappedlibxcbundefs.h
deleted file mode 100644
index 80f5f2d..0000000
--- a/src/wrapped/generated/wrappedlibxcbundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbUNDEFS_H_
-#define __wrappedlibxcbUNDEFS_H_
-
-
-#endif // __wrappedlibxcbUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbutildefs.h b/src/wrapped/generated/wrappedlibxcbutildefs.h
deleted file mode 100644
index a770e23..0000000
--- a/src/wrapped/generated/wrappedlibxcbutildefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbutilDEFS_H_
-#define __wrappedlibxcbutilDEFS_H_
-
-
-#endif // __wrappedlibxcbutilDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbutiltypes.h b/src/wrapped/generated/wrappedlibxcbutiltypes.h
deleted file mode 100644
index f1282a4..0000000
--- a/src/wrapped/generated/wrappedlibxcbutiltypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbutilTYPES_H_
-#define __wrappedlibxcbutilTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxcbutilTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxcbutilundefs.h b/src/wrapped/generated/wrappedlibxcbutilundefs.h
deleted file mode 100644
index c5c1f61..0000000
--- a/src/wrapped/generated/wrappedlibxcbutilundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbutilUNDEFS_H_
-#define __wrappedlibxcbutilUNDEFS_H_
-
-
-#endif // __wrappedlibxcbutilUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbxfixesdefs.h b/src/wrapped/generated/wrappedlibxcbxfixesdefs.h
deleted file mode 100644
index 7753302..0000000
--- a/src/wrapped/generated/wrappedlibxcbxfixesdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbxfixesDEFS_H_
-#define __wrappedlibxcbxfixesDEFS_H_
-
-
-#endif // __wrappedlibxcbxfixesDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbxfixestypes.h b/src/wrapped/generated/wrappedlibxcbxfixestypes.h
deleted file mode 100644
index a6fdc46..0000000
--- a/src/wrapped/generated/wrappedlibxcbxfixestypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbxfixesTYPES_H_
-#define __wrappedlibxcbxfixesTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxcbxfixesTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxcbxfixesundefs.h b/src/wrapped/generated/wrappedlibxcbxfixesundefs.h
deleted file mode 100644
index 10bbf14..0000000
--- a/src/wrapped/generated/wrappedlibxcbxfixesundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbxfixesUNDEFS_H_
-#define __wrappedlibxcbxfixesUNDEFS_H_
-
-
-#endif // __wrappedlibxcbxfixesUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbxineramadefs.h b/src/wrapped/generated/wrappedlibxcbxineramadefs.h
deleted file mode 100644
index 616bd2d..0000000
--- a/src/wrapped/generated/wrappedlibxcbxineramadefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbxineramaDEFS_H_
-#define __wrappedlibxcbxineramaDEFS_H_
-
-
-#endif // __wrappedlibxcbxineramaDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbxineramatypes.h b/src/wrapped/generated/wrappedlibxcbxineramatypes.h
deleted file mode 100644
index ceb8a3c..0000000
--- a/src/wrapped/generated/wrappedlibxcbxineramatypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbxineramaTYPES_H_
-#define __wrappedlibxcbxineramaTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxcbxineramaTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxcbxineramaundefs.h b/src/wrapped/generated/wrappedlibxcbxineramaundefs.h
deleted file mode 100644
index 3045ce0..0000000
--- a/src/wrapped/generated/wrappedlibxcbxineramaundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbxineramaUNDEFS_H_
-#define __wrappedlibxcbxineramaUNDEFS_H_
-
-
-#endif // __wrappedlibxcbxineramaUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbxkbdefs.h b/src/wrapped/generated/wrappedlibxcbxkbdefs.h
deleted file mode 100644
index e8e93ac..0000000
--- a/src/wrapped/generated/wrappedlibxcbxkbdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbxkbDEFS_H_
-#define __wrappedlibxcbxkbDEFS_H_
-
-
-#endif // __wrappedlibxcbxkbDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbxkbtypes.h b/src/wrapped/generated/wrappedlibxcbxkbtypes.h
deleted file mode 100644
index a02588a..0000000
--- a/src/wrapped/generated/wrappedlibxcbxkbtypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbxkbTYPES_H_
-#define __wrappedlibxcbxkbTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxcbxkbTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxcbxkbundefs.h b/src/wrapped/generated/wrappedlibxcbxkbundefs.h
deleted file mode 100644
index 51188d0..0000000
--- a/src/wrapped/generated/wrappedlibxcbxkbundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbxkbUNDEFS_H_
-#define __wrappedlibxcbxkbUNDEFS_H_
-
-
-#endif // __wrappedlibxcbxkbUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbxtestdefs.h b/src/wrapped/generated/wrappedlibxcbxtestdefs.h
deleted file mode 100644
index b81ac60..0000000
--- a/src/wrapped/generated/wrappedlibxcbxtestdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbxtestDEFS_H_
-#define __wrappedlibxcbxtestDEFS_H_
-
-
-#endif // __wrappedlibxcbxtestDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcbxtesttypes.h b/src/wrapped/generated/wrappedlibxcbxtesttypes.h
deleted file mode 100644
index 42332f9..0000000
--- a/src/wrapped/generated/wrappedlibxcbxtesttypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbxtestTYPES_H_
-#define __wrappedlibxcbxtestTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxcbxtestTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxcbxtestundefs.h b/src/wrapped/generated/wrappedlibxcbxtestundefs.h
deleted file mode 100644
index 6b8a2e3..0000000
--- a/src/wrapped/generated/wrappedlibxcbxtestundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcbxtestUNDEFS_H_
-#define __wrappedlibxcbxtestUNDEFS_H_
-
-
-#endif // __wrappedlibxcbxtestUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcompositedefs.h b/src/wrapped/generated/wrappedlibxcompositedefs.h
deleted file mode 100644
index f0cc981..0000000
--- a/src/wrapped/generated/wrappedlibxcompositedefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcompositeDEFS_H_
-#define __wrappedlibxcompositeDEFS_H_
-
-
-#endif // __wrappedlibxcompositeDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcompositetypes.h b/src/wrapped/generated/wrappedlibxcompositetypes.h
deleted file mode 100644
index d61e7b1..0000000
--- a/src/wrapped/generated/wrappedlibxcompositetypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcompositeTYPES_H_
-#define __wrappedlibxcompositeTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxcompositeTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxcompositeundefs.h b/src/wrapped/generated/wrappedlibxcompositeundefs.h
deleted file mode 100644
index ec06e20..0000000
--- a/src/wrapped/generated/wrappedlibxcompositeundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcompositeUNDEFS_H_
-#define __wrappedlibxcompositeUNDEFS_H_
-
-
-#endif // __wrappedlibxcompositeUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcursordefs.h b/src/wrapped/generated/wrappedlibxcursordefs.h
deleted file mode 100644
index 1a5454c..0000000
--- a/src/wrapped/generated/wrappedlibxcursordefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcursorDEFS_H_
-#define __wrappedlibxcursorDEFS_H_
-
-
-#endif // __wrappedlibxcursorDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxcursortypes.h b/src/wrapped/generated/wrappedlibxcursortypes.h
deleted file mode 100644
index 33d48bf..0000000
--- a/src/wrapped/generated/wrappedlibxcursortypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcursorTYPES_H_
-#define __wrappedlibxcursorTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxcursorTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxcursorundefs.h b/src/wrapped/generated/wrappedlibxcursorundefs.h
deleted file mode 100644
index f0d337b..0000000
--- a/src/wrapped/generated/wrappedlibxcursorundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxcursorUNDEFS_H_
-#define __wrappedlibxcursorUNDEFS_H_
-
-
-#endif // __wrappedlibxcursorUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxdamagedefs.h b/src/wrapped/generated/wrappedlibxdamagedefs.h
deleted file mode 100644
index 83a1b0c..0000000
--- a/src/wrapped/generated/wrappedlibxdamagedefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxdamageDEFS_H_
-#define __wrappedlibxdamageDEFS_H_
-
-
-#endif // __wrappedlibxdamageDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxdamagetypes.h b/src/wrapped/generated/wrappedlibxdamagetypes.h
deleted file mode 100644
index 4d29791..0000000
--- a/src/wrapped/generated/wrappedlibxdamagetypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxdamageTYPES_H_
-#define __wrappedlibxdamageTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxdamageTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxdamageundefs.h b/src/wrapped/generated/wrappedlibxdamageundefs.h
deleted file mode 100644
index 1c06601..0000000
--- a/src/wrapped/generated/wrappedlibxdamageundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxdamageUNDEFS_H_
-#define __wrappedlibxdamageUNDEFS_H_
-
-
-#endif // __wrappedlibxdamageUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxdmcpdefs.h b/src/wrapped/generated/wrappedlibxdmcpdefs.h
deleted file mode 100644
index 6e50d0a..0000000
--- a/src/wrapped/generated/wrappedlibxdmcpdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxdmcpDEFS_H_
-#define __wrappedlibxdmcpDEFS_H_
-
-
-#endif // __wrappedlibxdmcpDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxdmcptypes.h b/src/wrapped/generated/wrappedlibxdmcptypes.h
deleted file mode 100644
index 3f262cd..0000000
--- a/src/wrapped/generated/wrappedlibxdmcptypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxdmcpTYPES_H_
-#define __wrappedlibxdmcpTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxdmcpTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxdmcpundefs.h b/src/wrapped/generated/wrappedlibxdmcpundefs.h
deleted file mode 100644
index 88053ab..0000000
--- a/src/wrapped/generated/wrappedlibxdmcpundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxdmcpUNDEFS_H_
-#define __wrappedlibxdmcpUNDEFS_H_
-
-
-#endif // __wrappedlibxdmcpUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxextdefs.h b/src/wrapped/generated/wrappedlibxextdefs.h
deleted file mode 100644
index 1d6d070..0000000
--- a/src/wrapped/generated/wrappedlibxextdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxextDEFS_H_
-#define __wrappedlibxextDEFS_H_
-
-
-#endif // __wrappedlibxextDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxexttypes.h b/src/wrapped/generated/wrappedlibxexttypes.h
deleted file mode 100644
index 040be7d..0000000
--- a/src/wrapped/generated/wrappedlibxexttypes.h
+++ /dev/null
@@ -1,27 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxextTYPES_H_
-#define __wrappedlibxextTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void* (*pFp_t)(void*);
-typedef int64_t (*iFpppiiu_t)(void*, void*, void*, int64_t, int64_t, uint64_t);
-typedef void* (*pFppppip_t)(void*, void*, void*, void*, int64_t, void*);
-typedef void* (*pFppuippuu_t)(void*, void*, uint64_t, int64_t, void*, void*, uint64_t, uint64_t);
-typedef int64_t (*iFppppiiiiuui_t)(void*, void*, void*, void*, int64_t, int64_t, int64_t, int64_t, uint64_t, uint64_t, int64_t);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(XSetExtensionErrorHandler, pFp_t) \
- GO(XShmGetImage, iFpppiiu_t) \
- GO(XextAddDisplay, pFppppip_t) \
- GO(XShmCreateImage, pFppuippuu_t) \
- GO(XShmPutImage, iFppppiiiiuui_t)
-
-#endif // __wrappedlibxextTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxextundefs.h b/src/wrapped/generated/wrappedlibxextundefs.h
deleted file mode 100644
index a9a38fd..0000000
--- a/src/wrapped/generated/wrappedlibxextundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxextUNDEFS_H_
-#define __wrappedlibxextUNDEFS_H_
-
-
-#endif // __wrappedlibxextUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxfixesdefs.h b/src/wrapped/generated/wrappedlibxfixesdefs.h
deleted file mode 100644
index 9ba21c7..0000000
--- a/src/wrapped/generated/wrappedlibxfixesdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxfixesDEFS_H_
-#define __wrappedlibxfixesDEFS_H_
-
-
-#endif // __wrappedlibxfixesDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxfixestypes.h b/src/wrapped/generated/wrappedlibxfixestypes.h
deleted file mode 100644
index 16df35b..0000000
--- a/src/wrapped/generated/wrappedlibxfixestypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxfixesTYPES_H_
-#define __wrappedlibxfixesTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxfixesTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxfixesundefs.h b/src/wrapped/generated/wrappedlibxfixesundefs.h
deleted file mode 100644
index 5612816..0000000
--- a/src/wrapped/generated/wrappedlibxfixesundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxfixesUNDEFS_H_
-#define __wrappedlibxfixesUNDEFS_H_
-
-
-#endif // __wrappedlibxfixesUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxftdefs.h b/src/wrapped/generated/wrappedlibxftdefs.h
deleted file mode 100644
index 95c5153..0000000
--- a/src/wrapped/generated/wrappedlibxftdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxftDEFS_H_
-#define __wrappedlibxftDEFS_H_
-
-
-#endif // __wrappedlibxftDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxfttypes.h b/src/wrapped/generated/wrappedlibxfttypes.h
deleted file mode 100644
index 1a37c3d..0000000
--- a/src/wrapped/generated/wrappedlibxfttypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxftTYPES_H_
-#define __wrappedlibxftTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxftTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxftundefs.h b/src/wrapped/generated/wrappedlibxftundefs.h
deleted file mode 100644
index d32071e..0000000
--- a/src/wrapped/generated/wrappedlibxftundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxftUNDEFS_H_
-#define __wrappedlibxftUNDEFS_H_
-
-
-#endif // __wrappedlibxftUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxidefs.h b/src/wrapped/generated/wrappedlibxidefs.h
deleted file mode 100644
index a5faea7..0000000
--- a/src/wrapped/generated/wrappedlibxidefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxiDEFS_H_
-#define __wrappedlibxiDEFS_H_
-
-
-#endif // __wrappedlibxiDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxitypes.h b/src/wrapped/generated/wrappedlibxitypes.h
deleted file mode 100644
index a39fec1..0000000
--- a/src/wrapped/generated/wrappedlibxitypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxiTYPES_H_
-#define __wrappedlibxiTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxiTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxiundefs.h b/src/wrapped/generated/wrappedlibxiundefs.h
deleted file mode 100644
index db59d0e..0000000
--- a/src/wrapped/generated/wrappedlibxiundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxiUNDEFS_H_
-#define __wrappedlibxiUNDEFS_H_
-
-
-#endif // __wrappedlibxiUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxmudefs.h b/src/wrapped/generated/wrappedlibxmudefs.h
deleted file mode 100644
index 5943882..0000000
--- a/src/wrapped/generated/wrappedlibxmudefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxmuDEFS_H_
-#define __wrappedlibxmuDEFS_H_
-
-
-#endif // __wrappedlibxmuDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxmutypes.h b/src/wrapped/generated/wrappedlibxmutypes.h
deleted file mode 100644
index 3db1b1c..0000000
--- a/src/wrapped/generated/wrappedlibxmutypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxmuTYPES_H_
-#define __wrappedlibxmuTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxmuTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxmuundefs.h b/src/wrapped/generated/wrappedlibxmuundefs.h
deleted file mode 100644
index 36edb50..0000000
--- a/src/wrapped/generated/wrappedlibxmuundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxmuUNDEFS_H_
-#define __wrappedlibxmuUNDEFS_H_
-
-
-#endif // __wrappedlibxmuUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxpmdefs.h b/src/wrapped/generated/wrappedlibxpmdefs.h
deleted file mode 100644
index 354b858..0000000
--- a/src/wrapped/generated/wrappedlibxpmdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxpmDEFS_H_
-#define __wrappedlibxpmDEFS_H_
-
-
-#endif // __wrappedlibxpmDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxpmtypes.h b/src/wrapped/generated/wrappedlibxpmtypes.h
deleted file mode 100644
index 6625fe8..0000000
--- a/src/wrapped/generated/wrappedlibxpmtypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxpmTYPES_H_
-#define __wrappedlibxpmTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxpmTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxpmundefs.h b/src/wrapped/generated/wrappedlibxpmundefs.h
deleted file mode 100644
index 4ec8a2f..0000000
--- a/src/wrapped/generated/wrappedlibxpmundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxpmUNDEFS_H_
-#define __wrappedlibxpmUNDEFS_H_
-
-
-#endif // __wrappedlibxpmUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxpresentdefs.h b/src/wrapped/generated/wrappedlibxpresentdefs.h
deleted file mode 100644
index 4ae4061..0000000
--- a/src/wrapped/generated/wrappedlibxpresentdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxpresentDEFS_H_
-#define __wrappedlibxpresentDEFS_H_
-
-
-#endif // __wrappedlibxpresentDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxpresenttypes.h b/src/wrapped/generated/wrappedlibxpresenttypes.h
deleted file mode 100644
index b74721b..0000000
--- a/src/wrapped/generated/wrappedlibxpresenttypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxpresentTYPES_H_
-#define __wrappedlibxpresentTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxpresentTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxpresentundefs.h b/src/wrapped/generated/wrappedlibxpresentundefs.h
deleted file mode 100644
index 6fb9e58..0000000
--- a/src/wrapped/generated/wrappedlibxpresentundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxpresentUNDEFS_H_
-#define __wrappedlibxpresentUNDEFS_H_
-
-
-#endif // __wrappedlibxpresentUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxrandrdefs.h b/src/wrapped/generated/wrappedlibxrandrdefs.h
deleted file mode 100644
index 4e57328..0000000
--- a/src/wrapped/generated/wrappedlibxrandrdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxrandrDEFS_H_
-#define __wrappedlibxrandrDEFS_H_
-
-
-#endif // __wrappedlibxrandrDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxrandrtypes.h b/src/wrapped/generated/wrappedlibxrandrtypes.h
deleted file mode 100644
index 17a6e31..0000000
--- a/src/wrapped/generated/wrappedlibxrandrtypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxrandrTYPES_H_
-#define __wrappedlibxrandrTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxrandrTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxrandrundefs.h b/src/wrapped/generated/wrappedlibxrandrundefs.h
deleted file mode 100644
index e105174..0000000
--- a/src/wrapped/generated/wrappedlibxrandrundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxrandrUNDEFS_H_
-#define __wrappedlibxrandrUNDEFS_H_
-
-
-#endif // __wrappedlibxrandrUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxrenderdefs.h b/src/wrapped/generated/wrappedlibxrenderdefs.h
deleted file mode 100644
index bb09b7b..0000000
--- a/src/wrapped/generated/wrappedlibxrenderdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxrenderDEFS_H_
-#define __wrappedlibxrenderDEFS_H_
-
-
-#endif // __wrappedlibxrenderDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxrendertypes.h b/src/wrapped/generated/wrappedlibxrendertypes.h
deleted file mode 100644
index edecfd2..0000000
--- a/src/wrapped/generated/wrappedlibxrendertypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxrenderTYPES_H_
-#define __wrappedlibxrenderTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxrenderTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxrenderundefs.h b/src/wrapped/generated/wrappedlibxrenderundefs.h
deleted file mode 100644
index c4f6959..0000000
--- a/src/wrapped/generated/wrappedlibxrenderundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxrenderUNDEFS_H_
-#define __wrappedlibxrenderUNDEFS_H_
-
-
-#endif // __wrappedlibxrenderUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxssdefs.h b/src/wrapped/generated/wrappedlibxssdefs.h
deleted file mode 100644
index bf69a04..0000000
--- a/src/wrapped/generated/wrappedlibxssdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxssDEFS_H_
-#define __wrappedlibxssDEFS_H_
-
-
-#endif // __wrappedlibxssDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxsstypes.h b/src/wrapped/generated/wrappedlibxsstypes.h
deleted file mode 100644
index 968f86c..0000000
--- a/src/wrapped/generated/wrappedlibxsstypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxssTYPES_H_
-#define __wrappedlibxssTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxssTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxssundefs.h b/src/wrapped/generated/wrappedlibxssundefs.h
deleted file mode 100644
index 8ec1850..0000000
--- a/src/wrapped/generated/wrappedlibxssundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxssUNDEFS_H_
-#define __wrappedlibxssUNDEFS_H_
-
-
-#endif // __wrappedlibxssUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxtdefs.h b/src/wrapped/generated/wrappedlibxtdefs.h
deleted file mode 100644
index b4512b1..0000000
--- a/src/wrapped/generated/wrappedlibxtdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxtDEFS_H_
-#define __wrappedlibxtDEFS_H_
-
-
-#endif // __wrappedlibxtDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxtstdefs.h b/src/wrapped/generated/wrappedlibxtstdefs.h
deleted file mode 100644
index 1dfeb90..0000000
--- a/src/wrapped/generated/wrappedlibxtstdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxtstDEFS_H_
-#define __wrappedlibxtstDEFS_H_
-
-
-#endif // __wrappedlibxtstDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxtsttypes.h b/src/wrapped/generated/wrappedlibxtsttypes.h
deleted file mode 100644
index ddcf507..0000000
--- a/src/wrapped/generated/wrappedlibxtsttypes.h
+++ /dev/null
@@ -1,20 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxtstTYPES_H_
-#define __wrappedlibxtstTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef int64_t (*iFpppp_t)(void*, void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(XRecordEnableContext, iFpppp_t) \
- GO(XRecordEnableContextAsync, iFpppp_t)
-
-#endif // __wrappedlibxtstTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxtstundefs.h b/src/wrapped/generated/wrappedlibxtstundefs.h
deleted file mode 100644
index bd2162a..0000000
--- a/src/wrapped/generated/wrappedlibxtstundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxtstUNDEFS_H_
-#define __wrappedlibxtstUNDEFS_H_
-
-
-#endif // __wrappedlibxtstUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxttypes.h b/src/wrapped/generated/wrappedlibxttypes.h
deleted file mode 100644
index 9611669..0000000
--- a/src/wrapped/generated/wrappedlibxttypes.h
+++ /dev/null
@@ -1,23 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxtTYPES_H_
-#define __wrappedlibxtTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef intptr_t (*lFppp_t)(void*, void*, void*);
-typedef void (*vFpuipp_t)(void*, uint64_t, int64_t, void*, void*);
-typedef intptr_t (*lFpippp_t)(void*, int64_t, void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(XtAppAddWorkProc, lFppp_t) \
- GO(XtAddEventHandler, vFpuipp_t) \
- GO(XtAppAddInput, lFpippp_t)
-
-#endif // __wrappedlibxtTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxtundefs.h b/src/wrapped/generated/wrappedlibxtundefs.h
deleted file mode 100644
index 429d0c9..0000000
--- a/src/wrapped/generated/wrappedlibxtundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxtUNDEFS_H_
-#define __wrappedlibxtUNDEFS_H_
-
-
-#endif // __wrappedlibxtUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxxf86vmdefs.h b/src/wrapped/generated/wrappedlibxxf86vmdefs.h
deleted file mode 100644
index 5225f27..0000000
--- a/src/wrapped/generated/wrappedlibxxf86vmdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxxf86vmDEFS_H_
-#define __wrappedlibxxf86vmDEFS_H_
-
-
-#endif // __wrappedlibxxf86vmDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibxxf86vmtypes.h b/src/wrapped/generated/wrappedlibxxf86vmtypes.h
deleted file mode 100644
index 77f9785..0000000
--- a/src/wrapped/generated/wrappedlibxxf86vmtypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxxf86vmTYPES_H_
-#define __wrappedlibxxf86vmTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedlibxxf86vmTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibxxf86vmundefs.h b/src/wrapped/generated/wrappedlibxxf86vmundefs.h
deleted file mode 100644
index f14626f..0000000
--- a/src/wrapped/generated/wrappedlibxxf86vmundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibxxf86vmUNDEFS_H_
-#define __wrappedlibxxf86vmUNDEFS_H_
-
-
-#endif // __wrappedlibxxf86vmUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibzdefs.h b/src/wrapped/generated/wrappedlibzdefs.h
deleted file mode 100644
index 6abd00d..0000000
--- a/src/wrapped/generated/wrappedlibzdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibzDEFS_H_
-#define __wrappedlibzDEFS_H_
-
-
-#endif // __wrappedlibzDEFS_H_
diff --git a/src/wrapped/generated/wrappedlibztypes.h b/src/wrapped/generated/wrappedlibztypes.h
deleted file mode 100644
index 2434db5..0000000
--- a/src/wrapped/generated/wrappedlibztypes.h
+++ /dev/null
@@ -1,31 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibzTYPES_H_
-#define __wrappedlibzTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef int64_t (*iFp_t)(void*);
-typedef int64_t (*iFpi_t)(void*, int64_t);
-typedef int64_t (*iFppi_t)(void*, void*, int64_t);
-typedef int64_t (*iFpipi_t)(void*, int64_t, void*, int64_t);
-typedef int64_t (*iFpippi_t)(void*, int64_t, void*, void*, int64_t);
-typedef int64_t (*iFpiiiiipi_t)(void*, int64_t, int64_t, int64_t, int64_t, int64_t, void*, int64_t);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(deflateEnd, iFp_t) \
- GO(inflateEnd, iFp_t) \
- GO(inflate, iFpi_t) \
- GO(inflateInit_, iFppi_t) \
- GO(deflateInit_, iFpipi_t) \
- GO(inflateInit2_, iFpipi_t) \
- GO(inflateBackInit_, iFpippi_t) \
- GO(deflateInit2_, iFpiiiiipi_t)
-
-#endif // __wrappedlibzTYPES_H_
diff --git a/src/wrapped/generated/wrappedlibzundefs.h b/src/wrapped/generated/wrappedlibzundefs.h
deleted file mode 100644
index c3fc830..0000000
--- a/src/wrapped/generated/wrappedlibzundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlibzUNDEFS_H_
-#define __wrappedlibzUNDEFS_H_
-
-
-#endif // __wrappedlibzUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedlzmadefs.h b/src/wrapped/generated/wrappedlzmadefs.h
deleted file mode 100644
index cdca686..0000000
--- a/src/wrapped/generated/wrappedlzmadefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlzmaDEFS_H_
-#define __wrappedlzmaDEFS_H_
-
-
-#endif // __wrappedlzmaDEFS_H_
diff --git a/src/wrapped/generated/wrappedlzmatypes.h b/src/wrapped/generated/wrappedlzmatypes.h
deleted file mode 100644
index 56279e7..0000000
--- a/src/wrapped/generated/wrappedlzmatypes.h
+++ /dev/null
@@ -1,37 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlzmaTYPES_H_
-#define __wrappedlzmaTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFpp_t)(void*, void*);
-typedef int64_t (*iFpU_t)(void*, uint64_t);
-typedef int64_t (*iFpp_t)(void*, void*);
-typedef int64_t (*iFpui_t)(void*, uint64_t, int64_t);
-typedef int64_t (*iFpUi_t)(void*, uint64_t, int64_t);
-typedef int64_t (*iFppi_t)(void*, void*, int64_t);
-typedef int64_t (*iFpppL_t)(void*, void*, void*, uintptr_t);
-typedef int64_t (*iFpppppL_t)(void*, void*, void*, void*, void*, uintptr_t);
-typedef int64_t (*iFpupppLppL_t)(void*, uint64_t, void*, void*, void*, uintptr_t, void*, void*, uintptr_t);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(lzma_index_end, vFpp_t) \
- GO(lzma_alone_decoder, iFpU_t) \
- GO(lzma_alone_encoder, iFpp_t) \
- GO(lzma_raw_decoder, iFpp_t) \
- GO(lzma_raw_encoder, iFpp_t) \
- GO(lzma_easy_encoder, iFpui_t) \
- GO(lzma_stream_decoder, iFpUi_t) \
- GO(lzma_stream_encoder, iFppi_t) \
- GO(lzma_properties_decode, iFpppL_t) \
- GO(lzma_index_buffer_decode, iFpppppL_t) \
- GO(lzma_stream_buffer_decode, iFpupppLppL_t)
-
-#endif // __wrappedlzmaTYPES_H_
diff --git a/src/wrapped/generated/wrappedlzmaundefs.h b/src/wrapped/generated/wrappedlzmaundefs.h
deleted file mode 100644
index 3604079..0000000
--- a/src/wrapped/generated/wrappedlzmaundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedlzmaUNDEFS_H_
-#define __wrappedlzmaUNDEFS_H_
-
-
-#endif // __wrappedlzmaUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedmpg123defs.h b/src/wrapped/generated/wrappedmpg123defs.h
deleted file mode 100644
index fa861f3..0000000
--- a/src/wrapped/generated/wrappedmpg123defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedmpg123DEFS_H_
-#define __wrappedmpg123DEFS_H_
-
-
-#endif // __wrappedmpg123DEFS_H_
diff --git a/src/wrapped/generated/wrappedmpg123types.h b/src/wrapped/generated/wrappedmpg123types.h
deleted file mode 100644
index 7f77190..0000000
--- a/src/wrapped/generated/wrappedmpg123types.h
+++ /dev/null
@@ -1,21 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedmpg123TYPES_H_
-#define __wrappedmpg123TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef int64_t (*iFpppp_t)(void*, void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(mpg123_replace_reader_handle, iFpppp_t) \
- GO(mpg123_replace_reader_handle_32, iFpppp_t) \
- GO(mpg123_replace_reader_handle_64, iFpppp_t)
-
-#endif // __wrappedmpg123TYPES_H_
diff --git a/src/wrapped/generated/wrappedmpg123undefs.h b/src/wrapped/generated/wrappedmpg123undefs.h
deleted file mode 100644
index 6a9d5c8..0000000
--- a/src/wrapped/generated/wrappedmpg123undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedmpg123UNDEFS_H_
-#define __wrappedmpg123UNDEFS_H_
-
-
-#endif // __wrappedmpg123UNDEFS_H_
diff --git a/src/wrapped/generated/wrappednotifydefs.h b/src/wrapped/generated/wrappednotifydefs.h
deleted file mode 100644
index 5b13c0c..0000000
--- a/src/wrapped/generated/wrappednotifydefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappednotifyDEFS_H_
-#define __wrappednotifyDEFS_H_
-
-
-#endif // __wrappednotifyDEFS_H_
diff --git a/src/wrapped/generated/wrappednotifytypes.h b/src/wrapped/generated/wrappednotifytypes.h
deleted file mode 100644
index cde92ca..0000000
--- a/src/wrapped/generated/wrappednotifytypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappednotifyTYPES_H_
-#define __wrappednotifyTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappednotifyTYPES_H_
diff --git a/src/wrapped/generated/wrappednotifyundefs.h b/src/wrapped/generated/wrappednotifyundefs.h
deleted file mode 100644
index 213f23f..0000000
--- a/src/wrapped/generated/wrappednotifyundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappednotifyUNDEFS_H_
-#define __wrappednotifyUNDEFS_H_
-
-
-#endif // __wrappednotifyUNDEFS_H_
diff --git a/src/wrapped/generated/wrappednsldefs.h b/src/wrapped/generated/wrappednsldefs.h
deleted file mode 100644
index da12d03..0000000
--- a/src/wrapped/generated/wrappednsldefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappednslDEFS_H_
-#define __wrappednslDEFS_H_
-
-
-#endif // __wrappednslDEFS_H_
diff --git a/src/wrapped/generated/wrappednsltypes.h b/src/wrapped/generated/wrappednsltypes.h
deleted file mode 100644
index 485ebf2..0000000
--- a/src/wrapped/generated/wrappednsltypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappednslTYPES_H_
-#define __wrappednslTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappednslTYPES_H_
diff --git a/src/wrapped/generated/wrappednslundefs.h b/src/wrapped/generated/wrappednslundefs.h
deleted file mode 100644
index 626f3ab..0000000
--- a/src/wrapped/generated/wrappednslundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappednslUNDEFS_H_
-#define __wrappednslUNDEFS_H_
-
-
-#endif // __wrappednslUNDEFS_H_
diff --git a/src/wrapped/generated/wrappednspr4defs.h b/src/wrapped/generated/wrappednspr4defs.h
deleted file mode 100644
index 139e910..0000000
--- a/src/wrapped/generated/wrappednspr4defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappednspr4DEFS_H_
-#define __wrappednspr4DEFS_H_
-
-
-#endif // __wrappednspr4DEFS_H_
diff --git a/src/wrapped/generated/wrappednspr4types.h b/src/wrapped/generated/wrappednspr4types.h
deleted file mode 100644
index 8716883..0000000
--- a/src/wrapped/generated/wrappednspr4types.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappednspr4TYPES_H_
-#define __wrappednspr4TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappednspr4TYPES_H_
diff --git a/src/wrapped/generated/wrappednspr4undefs.h b/src/wrapped/generated/wrappednspr4undefs.h
deleted file mode 100644
index 27e90ee..0000000
--- a/src/wrapped/generated/wrappednspr4undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappednspr4UNDEFS_H_
-#define __wrappednspr4UNDEFS_H_
-
-
-#endif // __wrappednspr4UNDEFS_H_
diff --git a/src/wrapped/generated/wrappednss3defs.h b/src/wrapped/generated/wrappednss3defs.h
deleted file mode 100644
index 219704e..0000000
--- a/src/wrapped/generated/wrappednss3defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappednss3DEFS_H_
-#define __wrappednss3DEFS_H_
-
-
-#endif // __wrappednss3DEFS_H_
diff --git a/src/wrapped/generated/wrappednss3types.h b/src/wrapped/generated/wrappednss3types.h
deleted file mode 100644
index 5681adf..0000000
--- a/src/wrapped/generated/wrappednss3types.h
+++ /dev/null
@@ -1,23 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappednss3TYPES_H_
-#define __wrappednss3TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFp_t)(void*);
-typedef int64_t (*iFpp_t)(void*, void*);
-typedef int64_t (*iFpIppp_t)(void*, int64_t, void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(PK11_SetPasswordFunc, vFp_t) \
- GO(CERT_RegisterAlternateOCSPAIAInfoCallBack, iFpp_t) \
- GO(CERT_PKIXVerifyCert, iFpIppp_t)
-
-#endif // __wrappednss3TYPES_H_
diff --git a/src/wrapped/generated/wrappednss3undefs.h b/src/wrapped/generated/wrappednss3undefs.h
deleted file mode 100644
index 0349251..0000000
--- a/src/wrapped/generated/wrappednss3undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappednss3UNDEFS_H_
-#define __wrappednss3UNDEFS_H_
-
-
-#endif // __wrappednss3UNDEFS_H_
diff --git a/src/wrapped/generated/wrappednssutil3defs.h b/src/wrapped/generated/wrappednssutil3defs.h
deleted file mode 100644
index 2d5895f..0000000
--- a/src/wrapped/generated/wrappednssutil3defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappednssutil3DEFS_H_
-#define __wrappednssutil3DEFS_H_
-
-
-#endif // __wrappednssutil3DEFS_H_
diff --git a/src/wrapped/generated/wrappednssutil3types.h b/src/wrapped/generated/wrappednssutil3types.h
deleted file mode 100644
index 1a3b2b2..0000000
--- a/src/wrapped/generated/wrappednssutil3types.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappednssutil3TYPES_H_
-#define __wrappednssutil3TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappednssutil3TYPES_H_
diff --git a/src/wrapped/generated/wrappednssutil3undefs.h b/src/wrapped/generated/wrappednssutil3undefs.h
deleted file mode 100644
index bd749c7..0000000
--- a/src/wrapped/generated/wrappednssutil3undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappednssutil3UNDEFS_H_
-#define __wrappednssutil3UNDEFS_H_
-
-
-#endif // __wrappednssutil3UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedopenaldefs.h b/src/wrapped/generated/wrappedopenaldefs.h
deleted file mode 100644
index b0e9d6a..0000000
--- a/src/wrapped/generated/wrappedopenaldefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedopenalDEFS_H_
-#define __wrappedopenalDEFS_H_
-
-
-#endif // __wrappedopenalDEFS_H_
diff --git a/src/wrapped/generated/wrappedopenaltypes.h b/src/wrapped/generated/wrappedopenaltypes.h
deleted file mode 100644
index aad636d..0000000
--- a/src/wrapped/generated/wrappedopenaltypes.h
+++ /dev/null
@@ -1,25 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedopenalTYPES_H_
-#define __wrappedopenalTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFv_t)(void);
-typedef void* (*pFp_t)(void*);
-typedef void* (*pFpp_t)(void*, void*);
-typedef void (*vFiiipp_t)(int64_t, int64_t, int64_t, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(alRequestFoldbackStop, vFv_t) \
- GO(alGetProcAddress, pFp_t) \
- GO(alcGetProcAddress, pFpp_t) \
- GO(alRequestFoldbackStart, vFiiipp_t)
-
-#endif // __wrappedopenalTYPES_H_
diff --git a/src/wrapped/generated/wrappedopenalundefs.h b/src/wrapped/generated/wrappedopenalundefs.h
deleted file mode 100644
index 0bb1d62..0000000
--- a/src/wrapped/generated/wrappedopenalundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedopenalUNDEFS_H_
-#define __wrappedopenalUNDEFS_H_
-
-
-#endif // __wrappedopenalUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedpangocairodefs.h b/src/wrapped/generated/wrappedpangocairodefs.h
deleted file mode 100644
index 13de945..0000000
--- a/src/wrapped/generated/wrappedpangocairodefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedpangocairoDEFS_H_
-#define __wrappedpangocairoDEFS_H_
-
-
-#endif // __wrappedpangocairoDEFS_H_
diff --git a/src/wrapped/generated/wrappedpangocairotypes.h b/src/wrapped/generated/wrappedpangocairotypes.h
deleted file mode 100644
index a4717c5..0000000
--- a/src/wrapped/generated/wrappedpangocairotypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedpangocairoTYPES_H_
-#define __wrappedpangocairoTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedpangocairoTYPES_H_
diff --git a/src/wrapped/generated/wrappedpangocairoundefs.h b/src/wrapped/generated/wrappedpangocairoundefs.h
deleted file mode 100644
index c63fe50..0000000
--- a/src/wrapped/generated/wrappedpangocairoundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedpangocairoUNDEFS_H_
-#define __wrappedpangocairoUNDEFS_H_
-
-
-#endif // __wrappedpangocairoUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedpangodefs.h b/src/wrapped/generated/wrappedpangodefs.h
deleted file mode 100644
index 99cb63d..0000000
--- a/src/wrapped/generated/wrappedpangodefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedpangoDEFS_H_
-#define __wrappedpangoDEFS_H_
-
-
-#endif // __wrappedpangoDEFS_H_
diff --git a/src/wrapped/generated/wrappedpangoft2defs.h b/src/wrapped/generated/wrappedpangoft2defs.h
deleted file mode 100644
index 4c01d00..0000000
--- a/src/wrapped/generated/wrappedpangoft2defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedpangoft2DEFS_H_
-#define __wrappedpangoft2DEFS_H_
-
-
-#endif // __wrappedpangoft2DEFS_H_
diff --git a/src/wrapped/generated/wrappedpangoft2types.h b/src/wrapped/generated/wrappedpangoft2types.h
deleted file mode 100644
index 80bf095..0000000
--- a/src/wrapped/generated/wrappedpangoft2types.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedpangoft2TYPES_H_
-#define __wrappedpangoft2TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedpangoft2TYPES_H_
diff --git a/src/wrapped/generated/wrappedpangoft2undefs.h b/src/wrapped/generated/wrappedpangoft2undefs.h
deleted file mode 100644
index f597e13..0000000
--- a/src/wrapped/generated/wrappedpangoft2undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedpangoft2UNDEFS_H_
-#define __wrappedpangoft2UNDEFS_H_
-
-
-#endif // __wrappedpangoft2UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedpangotypes.h b/src/wrapped/generated/wrappedpangotypes.h
deleted file mode 100644
index a2f9cd4..0000000
--- a/src/wrapped/generated/wrappedpangotypes.h
+++ /dev/null
@@ -1,19 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedpangoTYPES_H_
-#define __wrappedpangoTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFpp_t)(void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(pango_attribute_init, vFpp_t)
-
-#endif // __wrappedpangoTYPES_H_
diff --git a/src/wrapped/generated/wrappedpangoundefs.h b/src/wrapped/generated/wrappedpangoundefs.h
deleted file mode 100644
index 423e13e..0000000
--- a/src/wrapped/generated/wrappedpangoundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedpangoUNDEFS_H_
-#define __wrappedpangoUNDEFS_H_
-
-
-#endif // __wrappedpangoUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedplc4defs.h b/src/wrapped/generated/wrappedplc4defs.h
deleted file mode 100644
index b4eefec..0000000
--- a/src/wrapped/generated/wrappedplc4defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedplc4DEFS_H_
-#define __wrappedplc4DEFS_H_
-
-
-#endif // __wrappedplc4DEFS_H_
diff --git a/src/wrapped/generated/wrappedplc4types.h b/src/wrapped/generated/wrappedplc4types.h
deleted file mode 100644
index 1ee7de0..0000000
--- a/src/wrapped/generated/wrappedplc4types.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedplc4TYPES_H_
-#define __wrappedplc4TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedplc4TYPES_H_
diff --git a/src/wrapped/generated/wrappedplc4undefs.h b/src/wrapped/generated/wrappedplc4undefs.h
deleted file mode 100644
index e145f59..0000000
--- a/src/wrapped/generated/wrappedplc4undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedplc4UNDEFS_H_
-#define __wrappedplc4UNDEFS_H_
-
-
-#endif // __wrappedplc4UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedplds4defs.h b/src/wrapped/generated/wrappedplds4defs.h
deleted file mode 100644
index 288824d..0000000
--- a/src/wrapped/generated/wrappedplds4defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedplds4DEFS_H_
-#define __wrappedplds4DEFS_H_
-
-
-#endif // __wrappedplds4DEFS_H_
diff --git a/src/wrapped/generated/wrappedplds4types.h b/src/wrapped/generated/wrappedplds4types.h
deleted file mode 100644
index 617b420..0000000
--- a/src/wrapped/generated/wrappedplds4types.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedplds4TYPES_H_
-#define __wrappedplds4TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedplds4TYPES_H_
diff --git a/src/wrapped/generated/wrappedplds4undefs.h b/src/wrapped/generated/wrappedplds4undefs.h
deleted file mode 100644
index 473404e..0000000
--- a/src/wrapped/generated/wrappedplds4undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedplds4UNDEFS_H_
-#define __wrappedplds4UNDEFS_H_
-
-
-#endif // __wrappedplds4UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedpng16defs.h b/src/wrapped/generated/wrappedpng16defs.h
deleted file mode 100644
index 0caf984..0000000
--- a/src/wrapped/generated/wrappedpng16defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedpng16DEFS_H_
-#define __wrappedpng16DEFS_H_
-
-
-#endif // __wrappedpng16DEFS_H_
diff --git a/src/wrapped/generated/wrappedpng16types.h b/src/wrapped/generated/wrappedpng16types.h
deleted file mode 100644
index 84e6a2b..0000000
--- a/src/wrapped/generated/wrappedpng16types.h
+++ /dev/null
@@ -1,31 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedpng16TYPES_H_
-#define __wrappedpng16TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFpp_t)(void*, void*);
-typedef void (*vFppp_t)(void*, void*, void*);
-typedef void (*vFpppp_t)(void*, void*, void*, void*);
-typedef void* (*pFpppp_t)(void*, void*, void*, void*);
-typedef void (*vFppppp_t)(void*, void*, void*, void*, void*);
-typedef void* (*pFppppppp_t)(void*, void*, void*, void*, void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(png_set_read_user_transform_fn, vFpp_t) \
- GO(png_set_read_fn, vFppp_t) \
- GO(png_set_error_fn, vFpppp_t) \
- GO(png_set_write_fn, vFpppp_t) \
- GO(png_create_read_struct, pFpppp_t) \
- GO(png_set_progressive_read_fn, vFppppp_t) \
- GO(png_create_read_struct_2, pFppppppp_t) \
- GO(png_create_write_struct_2, pFppppppp_t)
-
-#endif // __wrappedpng16TYPES_H_
diff --git a/src/wrapped/generated/wrappedpng16undefs.h b/src/wrapped/generated/wrappedpng16undefs.h
deleted file mode 100644
index 834fcef..0000000
--- a/src/wrapped/generated/wrappedpng16undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedpng16UNDEFS_H_
-#define __wrappedpng16UNDEFS_H_
-
-
-#endif // __wrappedpng16UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedpulsedefs.h b/src/wrapped/generated/wrappedpulsedefs.h
deleted file mode 100644
index 825e57b..0000000
--- a/src/wrapped/generated/wrappedpulsedefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedpulseDEFS_H_
-#define __wrappedpulseDEFS_H_
-
-
-#endif // __wrappedpulseDEFS_H_
diff --git a/src/wrapped/generated/wrappedpulsesimpledefs.h b/src/wrapped/generated/wrappedpulsesimpledefs.h
deleted file mode 100644
index 9e8edb0..0000000
--- a/src/wrapped/generated/wrappedpulsesimpledefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedpulsesimpleDEFS_H_
-#define __wrappedpulsesimpleDEFS_H_
-
-
-#endif // __wrappedpulsesimpleDEFS_H_
diff --git a/src/wrapped/generated/wrappedpulsesimpletypes.h b/src/wrapped/generated/wrappedpulsesimpletypes.h
deleted file mode 100644
index 7b479ea..0000000
--- a/src/wrapped/generated/wrappedpulsesimpletypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedpulsesimpleTYPES_H_
-#define __wrappedpulsesimpleTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedpulsesimpleTYPES_H_
diff --git a/src/wrapped/generated/wrappedpulsesimpleundefs.h b/src/wrapped/generated/wrappedpulsesimpleundefs.h
deleted file mode 100644
index eeea66e..0000000
--- a/src/wrapped/generated/wrappedpulsesimpleundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedpulsesimpleUNDEFS_H_
-#define __wrappedpulsesimpleUNDEFS_H_
-
-
-#endif // __wrappedpulsesimpleUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedpulsetypes.h b/src/wrapped/generated/wrappedpulsetypes.h
deleted file mode 100644
index 7a56bc1..0000000
--- a/src/wrapped/generated/wrappedpulsetypes.h
+++ /dev/null
@@ -1,120 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedpulseTYPES_H_
-#define __wrappedpulseTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFp_t)(void*);
-typedef int64_t (*iFp_t)(void*);
-typedef void* (*pFp_t)(void*);
-typedef void (*vFpp_t)(void*, void*);
-typedef void* (*pFpp_t)(void*, void*);
-typedef void (*vFppp_t)(void*, void*, void*);
-typedef void* (*pFipp_t)(int64_t, void*, void*);
-typedef void* (*pFppp_t)(void*, void*, void*);
-typedef int64_t (*iFppip_t)(void*, void*, int64_t, void*);
-typedef int64_t (*iFpppV_t)(void*, void*, void*, ...);
-typedef void* (*pFpipp_t)(void*, int64_t, void*, void*);
-typedef void* (*pFpupp_t)(void*, uint64_t, void*, void*);
-typedef void* (*pFpppp_t)(void*, void*, void*, void*);
-typedef void* (*pFpiupp_t)(void*, int64_t, uint64_t, void*, void*);
-typedef void* (*pFpippp_t)(void*, int64_t, void*, void*, void*);
-typedef void* (*pFpuipp_t)(void*, uint64_t, int64_t, void*, void*);
-typedef void* (*pFpuupp_t)(void*, uint64_t, uint64_t, void*, void*);
-typedef void* (*pFpuppp_t)(void*, uint64_t, void*, void*, void*);
-typedef void* (*pFppppp_t)(void*, void*, void*, void*, void*);
-typedef int64_t (*iFppLpIi_t)(void*, void*, uintptr_t, void*, int64_t, int64_t);
-typedef void* (*pFpiuCppp_t)(void*, int64_t, uint64_t, uint8_t, void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(pa_mainloop_free, vFp_t) \
- GO(pa_threaded_mainloop_free, vFp_t) \
- GO(pa_signal_init, iFp_t) \
- GO(pa_mainloop_get_api, pFp_t) \
- GO(pa_threaded_mainloop_get_api, pFp_t) \
- GO(pa_signal_set_destroy, vFpp_t) \
- GO(pa_context_new, pFpp_t) \
- GO(pa_context_set_event_callback, vFppp_t) \
- GO(pa_context_set_state_callback, vFppp_t) \
- GO(pa_context_set_subscribe_callback, vFppp_t) \
- GO(pa_mainloop_set_poll_func, vFppp_t) \
- GO(pa_stream_set_buffer_attr_callback, vFppp_t) \
- GO(pa_stream_set_event_callback, vFppp_t) \
- GO(pa_stream_set_latency_update_callback, vFppp_t) \
- GO(pa_stream_set_moved_callback, vFppp_t) \
- GO(pa_stream_set_overflow_callback, vFppp_t) \
- GO(pa_stream_set_read_callback, vFppp_t) \
- GO(pa_stream_set_started_callback, vFppp_t) \
- GO(pa_stream_set_state_callback, vFppp_t) \
- GO(pa_stream_set_suspended_callback, vFppp_t) \
- GO(pa_stream_set_underflow_callback, vFppp_t) \
- GO(pa_stream_set_write_callback, vFppp_t) \
- GO(pa_signal_new, pFipp_t) \
- GO(pa_context_drain, pFppp_t) \
- GO(pa_context_exit_daemon, pFppp_t) \
- GO(pa_context_get_card_info_list, pFppp_t) \
- GO(pa_context_get_client_info_list, pFppp_t) \
- GO(pa_context_get_module_info_list, pFppp_t) \
- GO(pa_context_get_server_info, pFppp_t) \
- GO(pa_context_get_sink_info_list, pFppp_t) \
- GO(pa_context_get_sink_input_info_list, pFppp_t) \
- GO(pa_context_get_source_info_list, pFppp_t) \
- GO(pa_context_get_source_output_info_list, pFppp_t) \
- GO(pa_context_new_with_proplist, pFppp_t) \
- GO(pa_ext_device_restore_read_formats_all, pFppp_t) \
- GO(pa_ext_device_restore_set_subscribe_cb, pFppp_t) \
- GO(pa_stream_drain, pFppp_t) \
- GO(pa_stream_flush, pFppp_t) \
- GO(pa_stream_prebuf, pFppp_t) \
- GO(pa_stream_trigger, pFppp_t) \
- GO(pa_stream_update_timing_info, pFppp_t) \
- GO(pa_context_connect, iFppip_t) \
- GO(pa_proplist_setf, iFpppV_t) \
- GO(pa_ext_device_restore_subscribe, pFpipp_t) \
- GO(pa_stream_cork, pFpipp_t) \
- GO(pa_context_get_card_info_by_index, pFpupp_t) \
- GO(pa_context_get_client_info, pFpupp_t) \
- GO(pa_context_get_sink_info_by_index, pFpupp_t) \
- GO(pa_context_get_sink_input_info, pFpupp_t) \
- GO(pa_context_get_source_info_by_index, pFpupp_t) \
- GO(pa_context_get_source_output_info, pFpupp_t) \
- GO(pa_context_subscribe, pFpupp_t) \
- GO(pa_context_unload_module, pFpupp_t) \
- GO(pa_stream_update_sample_rate, pFpupp_t) \
- GO(pa_context_get_sink_info_by_name, pFpppp_t) \
- GO(pa_context_get_source_info_by_name, pFpppp_t) \
- GO(pa_context_proplist_remove, pFpppp_t) \
- GO(pa_context_set_default_sink, pFpppp_t) \
- GO(pa_context_set_default_source, pFpppp_t) \
- GO(pa_context_set_name, pFpppp_t) \
- GO(pa_stream_proplist_remove, pFpppp_t) \
- GO(pa_stream_set_buffer_attr, pFpppp_t) \
- GO(pa_stream_set_name, pFpppp_t) \
- GO(pa_ext_device_restore_read_formats, pFpiupp_t) \
- GO(pa_context_proplist_update, pFpippp_t) \
- GO(pa_stream_proplist_update, pFpippp_t) \
- GO(pa_context_set_sink_input_mute, pFpuipp_t) \
- GO(pa_context_set_sink_mute_by_index, pFpuipp_t) \
- GO(pa_context_set_source_mute_by_index, pFpuipp_t) \
- GO(pa_context_move_sink_input_by_index, pFpuupp_t) \
- GO(pa_context_move_source_output_by_index, pFpuupp_t) \
- GO(pa_context_set_card_profile_by_index, pFpuppp_t) \
- GO(pa_context_set_sink_input_volume, pFpuppp_t) \
- GO(pa_context_set_sink_port_by_index, pFpuppp_t) \
- GO(pa_context_set_sink_volume_by_index, pFpuppp_t) \
- GO(pa_context_set_source_port_by_index, pFpuppp_t) \
- GO(pa_context_set_source_volume_by_index, pFpuppp_t) \
- GO(pa_context_load_module, pFppppp_t) \
- GO(pa_context_set_sink_port_by_name, pFppppp_t) \
- GO(pa_context_set_source_volume_by_name, pFppppp_t) \
- GO(pa_stream_write, iFppLpIi_t) \
- GO(pa_ext_device_restore_save_formats, pFpiuCppp_t)
-
-#endif // __wrappedpulseTYPES_H_
diff --git a/src/wrapped/generated/wrappedpulseundefs.h b/src/wrapped/generated/wrappedpulseundefs.h
deleted file mode 100644
index 7685924..0000000
--- a/src/wrapped/generated/wrappedpulseundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedpulseUNDEFS_H_
-#define __wrappedpulseUNDEFS_H_
-
-
-#endif // __wrappedpulseUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedsdl1defs.h b/src/wrapped/generated/wrappedsdl1defs.h
deleted file mode 100644
index 8172b88..0000000
--- a/src/wrapped/generated/wrappedsdl1defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl1DEFS_H_
-#define __wrappedsdl1DEFS_H_
-
-
-#endif // __wrappedsdl1DEFS_H_
diff --git a/src/wrapped/generated/wrappedsdl1imagedefs.h b/src/wrapped/generated/wrappedsdl1imagedefs.h
deleted file mode 100644
index 39eaa03..0000000
--- a/src/wrapped/generated/wrappedsdl1imagedefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl1imageDEFS_H_
-#define __wrappedsdl1imageDEFS_H_
-
-
-#endif // __wrappedsdl1imageDEFS_H_
diff --git a/src/wrapped/generated/wrappedsdl1imagetypes.h b/src/wrapped/generated/wrappedsdl1imagetypes.h
deleted file mode 100644
index 0291696..0000000
--- a/src/wrapped/generated/wrappedsdl1imagetypes.h
+++ /dev/null
@@ -1,37 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl1imageTYPES_H_
-#define __wrappedsdl1imageTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void* (*pFp_t)(void*);
-typedef void* (*pFpi_t)(void*, int64_t);
-typedef void* (*pFpip_t)(void*, int64_t, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(IMG_LoadBMP_RW, pFp_t) \
- GO(IMG_LoadCUR_RW, pFp_t) \
- GO(IMG_LoadGIF_RW, pFp_t) \
- GO(IMG_LoadICO_RW, pFp_t) \
- GO(IMG_LoadJPG_RW, pFp_t) \
- GO(IMG_LoadLBM_RW, pFp_t) \
- GO(IMG_LoadPCX_RW, pFp_t) \
- GO(IMG_LoadPNG_RW, pFp_t) \
- GO(IMG_LoadPNM_RW, pFp_t) \
- GO(IMG_LoadTGA_RW, pFp_t) \
- GO(IMG_LoadTIF_RW, pFp_t) \
- GO(IMG_LoadWEBP_RW, pFp_t) \
- GO(IMG_LoadXCF_RW, pFp_t) \
- GO(IMG_LoadXPM_RW, pFp_t) \
- GO(IMG_LoadXV_RW, pFp_t) \
- GO(IMG_Load_RW, pFpi_t) \
- GO(IMG_LoadTyped_RW, pFpip_t)
-
-#endif // __wrappedsdl1imageTYPES_H_
diff --git a/src/wrapped/generated/wrappedsdl1imageundefs.h b/src/wrapped/generated/wrappedsdl1imageundefs.h
deleted file mode 100644
index 84eb9d3..0000000
--- a/src/wrapped/generated/wrappedsdl1imageundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl1imageUNDEFS_H_
-#define __wrappedsdl1imageUNDEFS_H_
-
-
-#endif // __wrappedsdl1imageUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedsdl1mixerdefs.h b/src/wrapped/generated/wrappedsdl1mixerdefs.h
deleted file mode 100644
index 5852b89..0000000
--- a/src/wrapped/generated/wrappedsdl1mixerdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl1mixerDEFS_H_
-#define __wrappedsdl1mixerDEFS_H_
-
-
-#endif // __wrappedsdl1mixerDEFS_H_
diff --git a/src/wrapped/generated/wrappedsdl1mixertypes.h b/src/wrapped/generated/wrappedsdl1mixertypes.h
deleted file mode 100644
index e9fac81..0000000
--- a/src/wrapped/generated/wrappedsdl1mixertypes.h
+++ /dev/null
@@ -1,33 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl1mixerTYPES_H_
-#define __wrappedsdl1mixerTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFp_t)(void*);
-typedef void* (*pFp_t)(void*);
-typedef void (*vFpp_t)(void*, void*);
-typedef int64_t (*iFip_t)(int64_t, void*);
-typedef void* (*pFpi_t)(void*, int64_t);
-typedef void* (*pFpii_t)(void*, int64_t, int64_t);
-typedef int64_t (*iFippp_t)(int64_t, void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(Mix_ChannelFinished, vFp_t) \
- GO(Mix_HookMusicFinished, vFp_t) \
- GO(Mix_LoadMUS_RW, pFp_t) \
- GO(Mix_HookMusic, vFpp_t) \
- GO(Mix_SetPostMix, vFpp_t) \
- GO(Mix_UnregisterEffect, iFip_t) \
- GO(Mix_LoadWAV_RW, pFpi_t) \
- GO(Mix_LoadMUSType_RW, pFpii_t) \
- GO(Mix_RegisterEffect, iFippp_t)
-
-#endif // __wrappedsdl1mixerTYPES_H_
diff --git a/src/wrapped/generated/wrappedsdl1mixerundefs.h b/src/wrapped/generated/wrappedsdl1mixerundefs.h
deleted file mode 100644
index a0e00e3..0000000
--- a/src/wrapped/generated/wrappedsdl1mixerundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl1mixerUNDEFS_H_
-#define __wrappedsdl1mixerUNDEFS_H_
-
-
-#endif // __wrappedsdl1mixerUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedsdl1netdefs.h b/src/wrapped/generated/wrappedsdl1netdefs.h
deleted file mode 100644
index 241208b..0000000
--- a/src/wrapped/generated/wrappedsdl1netdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl1netDEFS_H_
-#define __wrappedsdl1netDEFS_H_
-
-
-#endif // __wrappedsdl1netDEFS_H_
diff --git a/src/wrapped/generated/wrappedsdl1nettypes.h b/src/wrapped/generated/wrappedsdl1nettypes.h
deleted file mode 100644
index 6385e0d..0000000
--- a/src/wrapped/generated/wrappedsdl1nettypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl1netTYPES_H_
-#define __wrappedsdl1netTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedsdl1netTYPES_H_
diff --git a/src/wrapped/generated/wrappedsdl1netundefs.h b/src/wrapped/generated/wrappedsdl1netundefs.h
deleted file mode 100644
index ccb8d80..0000000
--- a/src/wrapped/generated/wrappedsdl1netundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl1netUNDEFS_H_
-#define __wrappedsdl1netUNDEFS_H_
-
-
-#endif // __wrappedsdl1netUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedsdl1sounddefs.h b/src/wrapped/generated/wrappedsdl1sounddefs.h
deleted file mode 100644
index 651b825..0000000
--- a/src/wrapped/generated/wrappedsdl1sounddefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl1soundDEFS_H_
-#define __wrappedsdl1soundDEFS_H_
-
-
-#endif // __wrappedsdl1soundDEFS_H_
diff --git a/src/wrapped/generated/wrappedsdl1soundtypes.h b/src/wrapped/generated/wrappedsdl1soundtypes.h
deleted file mode 100644
index 49368e5..0000000
--- a/src/wrapped/generated/wrappedsdl1soundtypes.h
+++ /dev/null
@@ -1,19 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl1soundTYPES_H_
-#define __wrappedsdl1soundTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void* (*pFpppu_t)(void*, void*, void*, uint64_t);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(Sound_NewSample, pFpppu_t)
-
-#endif // __wrappedsdl1soundTYPES_H_
diff --git a/src/wrapped/generated/wrappedsdl1soundundefs.h b/src/wrapped/generated/wrappedsdl1soundundefs.h
deleted file mode 100644
index 5d9353f..0000000
--- a/src/wrapped/generated/wrappedsdl1soundundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl1soundUNDEFS_H_
-#define __wrappedsdl1soundUNDEFS_H_
-
-
-#endif // __wrappedsdl1soundUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedsdl1ttfdefs.h b/src/wrapped/generated/wrappedsdl1ttfdefs.h
deleted file mode 100644
index f6e179e..0000000
--- a/src/wrapped/generated/wrappedsdl1ttfdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl1ttfDEFS_H_
-#define __wrappedsdl1ttfDEFS_H_
-
-
-#endif // __wrappedsdl1ttfDEFS_H_
diff --git a/src/wrapped/generated/wrappedsdl1ttftypes.h b/src/wrapped/generated/wrappedsdl1ttftypes.h
deleted file mode 100644
index 9844efc..0000000
--- a/src/wrapped/generated/wrappedsdl1ttftypes.h
+++ /dev/null
@@ -1,21 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl1ttfTYPES_H_
-#define __wrappedsdl1ttfTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void* (*pFpii_t)(void*, int64_t, int64_t);
-typedef void* (*pFpiii_t)(void*, int64_t, int64_t, int64_t);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(TTF_OpenFontRW, pFpii_t) \
- GO(TTF_OpenFontIndexRW, pFpiii_t)
-
-#endif // __wrappedsdl1ttfTYPES_H_
diff --git a/src/wrapped/generated/wrappedsdl1ttfundefs.h b/src/wrapped/generated/wrappedsdl1ttfundefs.h
deleted file mode 100644
index a0abb62..0000000
--- a/src/wrapped/generated/wrappedsdl1ttfundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl1ttfUNDEFS_H_
-#define __wrappedsdl1ttfUNDEFS_H_
-
-
-#endif // __wrappedsdl1ttfUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedsdl1types.h b/src/wrapped/generated/wrappedsdl1types.h
deleted file mode 100644
index aa08b37..0000000
--- a/src/wrapped/generated/wrappedsdl1types.h
+++ /dev/null
@@ -1,74 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl1TYPES_H_
-#define __wrappedsdl1TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFp_t)(void*);
-typedef int64_t (*iFv_t)(void);
-typedef int64_t (*iFp_t)(void*);
-typedef uint64_t (*uFp_t)(void*);
-typedef uint64_t (*UFp_t)(void*);
-typedef void* (*pFv_t)(void);
-typedef void* (*pFp_t)(void*);
-typedef int64_t (*iFup_t)(uint64_t, void*);
-typedef int64_t (*iFpp_t)(void*, void*);
-typedef uint64_t (*uFpW_t)(void*, uint16_t);
-typedef uint64_t (*uFpu_t)(void*, uint64_t);
-typedef uint64_t (*uFpU_t)(void*, uint64_t);
-typedef void* (*pFpi_t)(void*, int64_t);
-typedef void* (*pFpp_t)(void*, void*);
-typedef int64_t (*iFppi_t)(void*, void*, int64_t);
-typedef void* (*pFupp_t)(uint64_t, void*, void*);
-typedef void* (*pFpippp_t)(void*, int64_t, void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(SDL_KillThread, vFp_t) \
- GO(SDL_SetEventFilter, vFp_t) \
- GO(SDL_UnloadObject, vFp_t) \
- GO(SDL_Has3DNow, iFv_t) \
- GO(SDL_Has3DNowExt, iFv_t) \
- GO(SDL_HasAltiVec, iFv_t) \
- GO(SDL_HasMMX, iFv_t) \
- GO(SDL_HasMMXExt, iFv_t) \
- GO(SDL_HasRDTSC, iFv_t) \
- GO(SDL_HasSSE, iFv_t) \
- GO(SDL_HasSSE2, iFv_t) \
- GO(SDL_GetWMInfo, iFp_t) \
- GO(SDL_RemoveTimer, iFp_t) \
- GO(SDL_ReadBE16, uFp_t) \
- GO(SDL_ReadBE32, uFp_t) \
- GO(SDL_ReadLE16, uFp_t) \
- GO(SDL_ReadLE32, uFp_t) \
- GO(SDL_ReadBE64, UFp_t) \
- GO(SDL_ReadLE64, UFp_t) \
- GO(SDL_GetEventFilter, pFv_t) \
- GO(SDL_GL_GetProcAddress, pFp_t) \
- GO(SDL_LoadObject, pFp_t) \
- GO(SDL_SetTimer, iFup_t) \
- GO(SDL_OpenAudio, iFpp_t) \
- GO(SDL_WriteBE16, uFpW_t) \
- GO(SDL_WriteLE16, uFpW_t) \
- GO(SDL_WriteBE32, uFpu_t) \
- GO(SDL_WriteLE32, uFpu_t) \
- GO(SDL_WriteBE64, uFpU_t) \
- GO(SDL_WriteLE64, uFpU_t) \
- GO(SDL_LoadBMP_RW, pFpi_t) \
- GO(SDL_RWFromConstMem, pFpi_t) \
- GO(SDL_RWFromFP, pFpi_t) \
- GO(SDL_RWFromMem, pFpi_t) \
- GO(SDL_CreateThread, pFpp_t) \
- GO(SDL_LoadFunction, pFpp_t) \
- GO(SDL_RWFromFile, pFpp_t) \
- GO(SDL_SaveBMP_RW, iFppi_t) \
- GO(SDL_AddTimer, pFupp_t) \
- GO(SDL_LoadWAV_RW, pFpippp_t)
-
-#endif // __wrappedsdl1TYPES_H_
diff --git a/src/wrapped/generated/wrappedsdl1undefs.h b/src/wrapped/generated/wrappedsdl1undefs.h
deleted file mode 100644
index f3a9337..0000000
--- a/src/wrapped/generated/wrappedsdl1undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl1UNDEFS_H_
-#define __wrappedsdl1UNDEFS_H_
-
-
-#endif // __wrappedsdl1UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedsdl2defs.h b/src/wrapped/generated/wrappedsdl2defs.h
deleted file mode 100644
index 38bd79e..0000000
--- a/src/wrapped/generated/wrappedsdl2defs.h
+++ /dev/null
@@ -1,9 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl2DEFS_H_
-#define __wrappedsdl2DEFS_H_
-
-#define vFGppp vFUUppp
-
-#endif // __wrappedsdl2DEFS_H_
diff --git a/src/wrapped/generated/wrappedsdl2imagedefs.h b/src/wrapped/generated/wrappedsdl2imagedefs.h
deleted file mode 100644
index 6632ca4..0000000
--- a/src/wrapped/generated/wrappedsdl2imagedefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl2imageDEFS_H_
-#define __wrappedsdl2imageDEFS_H_
-
-
-#endif // __wrappedsdl2imageDEFS_H_
diff --git a/src/wrapped/generated/wrappedsdl2imagetypes.h b/src/wrapped/generated/wrappedsdl2imagetypes.h
deleted file mode 100644
index 5cef008..0000000
--- a/src/wrapped/generated/wrappedsdl2imagetypes.h
+++ /dev/null
@@ -1,43 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl2imageTYPES_H_
-#define __wrappedsdl2imageTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void* (*pFp_t)(void*);
-typedef void* (*pFpi_t)(void*, int64_t);
-typedef int64_t (*iFppi_t)(void*, void*, int64_t);
-typedef void* (*pFpip_t)(void*, int64_t, void*);
-typedef void* (*pFppi_t)(void*, void*, int64_t);
-typedef void* (*pFppip_t)(void*, void*, int64_t, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(IMG_LoadBMP_RW, pFp_t) \
- GO(IMG_LoadCUR_RW, pFp_t) \
- GO(IMG_LoadGIF_RW, pFp_t) \
- GO(IMG_LoadICO_RW, pFp_t) \
- GO(IMG_LoadJPG_RW, pFp_t) \
- GO(IMG_LoadLBM_RW, pFp_t) \
- GO(IMG_LoadPCX_RW, pFp_t) \
- GO(IMG_LoadPNG_RW, pFp_t) \
- GO(IMG_LoadPNM_RW, pFp_t) \
- GO(IMG_LoadTGA_RW, pFp_t) \
- GO(IMG_LoadTIF_RW, pFp_t) \
- GO(IMG_LoadWEBP_RW, pFp_t) \
- GO(IMG_LoadXCF_RW, pFp_t) \
- GO(IMG_LoadXPM_RW, pFp_t) \
- GO(IMG_LoadXV_RW, pFp_t) \
- GO(IMG_Load_RW, pFpi_t) \
- GO(IMG_SavePNG_RW, iFppi_t) \
- GO(IMG_LoadTyped_RW, pFpip_t) \
- GO(IMG_LoadTexture_RW, pFppi_t) \
- GO(IMG_LoadTextureTyped_RW, pFppip_t)
-
-#endif // __wrappedsdl2imageTYPES_H_
diff --git a/src/wrapped/generated/wrappedsdl2imageundefs.h b/src/wrapped/generated/wrappedsdl2imageundefs.h
deleted file mode 100644
index 8737d52..0000000
--- a/src/wrapped/generated/wrappedsdl2imageundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl2imageUNDEFS_H_
-#define __wrappedsdl2imageUNDEFS_H_
-
-
-#endif // __wrappedsdl2imageUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedsdl2mixerdefs.h b/src/wrapped/generated/wrappedsdl2mixerdefs.h
deleted file mode 100644
index 820c587..0000000
--- a/src/wrapped/generated/wrappedsdl2mixerdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl2mixerDEFS_H_
-#define __wrappedsdl2mixerDEFS_H_
-
-
-#endif // __wrappedsdl2mixerDEFS_H_
diff --git a/src/wrapped/generated/wrappedsdl2mixertypes.h b/src/wrapped/generated/wrappedsdl2mixertypes.h
deleted file mode 100644
index 8d08099..0000000
--- a/src/wrapped/generated/wrappedsdl2mixertypes.h
+++ /dev/null
@@ -1,34 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl2mixerTYPES_H_
-#define __wrappedsdl2mixerTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFp_t)(void*);
-typedef void (*vFpp_t)(void*, void*);
-typedef int64_t (*iFiw_t)(int64_t, int16_t);
-typedef int64_t (*iFip_t)(int64_t, void*);
-typedef void* (*pFpi_t)(void*, int64_t);
-typedef void* (*pFpii_t)(void*, int64_t, int64_t);
-typedef int64_t (*iFippp_t)(int64_t, void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(Mix_ChannelFinished, vFp_t) \
- GO(Mix_HookMusicFinished, vFp_t) \
- GO(Mix_HookMusic, vFpp_t) \
- GO(Mix_SetPostMix, vFpp_t) \
- GO(MinorityMix_SetPosition, iFiw_t) \
- GO(Mix_UnregisterEffect, iFip_t) \
- GO(Mix_LoadMUS_RW, pFpi_t) \
- GO(Mix_LoadWAV_RW, pFpi_t) \
- GO(Mix_LoadMUSType_RW, pFpii_t) \
- GO(Mix_RegisterEffect, iFippp_t)
-
-#endif // __wrappedsdl2mixerTYPES_H_
diff --git a/src/wrapped/generated/wrappedsdl2mixerundefs.h b/src/wrapped/generated/wrappedsdl2mixerundefs.h
deleted file mode 100644
index 6a6f880..0000000
--- a/src/wrapped/generated/wrappedsdl2mixerundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl2mixerUNDEFS_H_
-#define __wrappedsdl2mixerUNDEFS_H_
-
-
-#endif // __wrappedsdl2mixerUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedsdl2netdefs.h b/src/wrapped/generated/wrappedsdl2netdefs.h
deleted file mode 100644
index 5168ca3..0000000
--- a/src/wrapped/generated/wrappedsdl2netdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl2netDEFS_H_
-#define __wrappedsdl2netDEFS_H_
-
-
-#endif // __wrappedsdl2netDEFS_H_
diff --git a/src/wrapped/generated/wrappedsdl2nettypes.h b/src/wrapped/generated/wrappedsdl2nettypes.h
deleted file mode 100644
index 4b91b54..0000000
--- a/src/wrapped/generated/wrappedsdl2nettypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl2netTYPES_H_
-#define __wrappedsdl2netTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedsdl2netTYPES_H_
diff --git a/src/wrapped/generated/wrappedsdl2netundefs.h b/src/wrapped/generated/wrappedsdl2netundefs.h
deleted file mode 100644
index a80b1ef..0000000
--- a/src/wrapped/generated/wrappedsdl2netundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl2netUNDEFS_H_
-#define __wrappedsdl2netUNDEFS_H_
-
-
-#endif // __wrappedsdl2netUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedsdl2ttfdefs.h b/src/wrapped/generated/wrappedsdl2ttfdefs.h
deleted file mode 100644
index f65e128..0000000
--- a/src/wrapped/generated/wrappedsdl2ttfdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl2ttfDEFS_H_
-#define __wrappedsdl2ttfDEFS_H_
-
-
-#endif // __wrappedsdl2ttfDEFS_H_
diff --git a/src/wrapped/generated/wrappedsdl2ttftypes.h b/src/wrapped/generated/wrappedsdl2ttftypes.h
deleted file mode 100644
index 126d4f6..0000000
--- a/src/wrapped/generated/wrappedsdl2ttftypes.h
+++ /dev/null
@@ -1,21 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl2ttfTYPES_H_
-#define __wrappedsdl2ttfTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void* (*pFpii_t)(void*, int64_t, int64_t);
-typedef void* (*pFpiii_t)(void*, int64_t, int64_t, int64_t);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(TTF_OpenFontRW, pFpii_t) \
- GO(TTF_OpenFontIndexRW, pFpiii_t)
-
-#endif // __wrappedsdl2ttfTYPES_H_
diff --git a/src/wrapped/generated/wrappedsdl2ttfundefs.h b/src/wrapped/generated/wrappedsdl2ttfundefs.h
deleted file mode 100644
index fa32c59..0000000
--- a/src/wrapped/generated/wrappedsdl2ttfundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl2ttfUNDEFS_H_
-#define __wrappedsdl2ttfUNDEFS_H_
-
-
-#endif // __wrappedsdl2ttfUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedsdl2types.h b/src/wrapped/generated/wrappedsdl2types.h
deleted file mode 100644
index a34f41c..0000000
--- a/src/wrapped/generated/wrappedsdl2types.h
+++ /dev/null
@@ -1,134 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl2TYPES_H_
-#define __wrappedsdl2TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFp_t)(void*);
-typedef int64_t (*iFv_t)(void);
-typedef int64_t (*iFp_t)(void*);
-typedef int64_t (*IFp_t)(void*);
-typedef uint64_t (*uFp_t)(void*);
-typedef uint64_t (*UFp_t)(void*);
-typedef void* (*pFv_t)(void);
-typedef void* (*pFp_t)(void*);
-typedef void (*vFpp_t)(void*, void*);
-typedef void (*vFpV_t)(void*, ...);
-typedef int64_t (*iFip_t)(int64_t, void*);
-typedef int64_t (*iFWW_t)(uint16_t, uint16_t);
-typedef int64_t (*iFUU_t)(uint64_t, uint64_t);
-typedef int64_t (*iFpi_t)(void*, int64_t);
-typedef int64_t (*iFpp_t)(void*, void*);
-typedef uint64_t (*uFpW_t)(void*, uint16_t);
-typedef uint64_t (*uFpu_t)(void*, uint64_t);
-typedef uint64_t (*uFpU_t)(void*, uint64_t);
-typedef void* (*pFpi_t)(void*, int64_t);
-typedef void* (*pFpp_t)(void*, void*);
-typedef void (*vFipV_t)(int64_t, void*, ...);
-typedef int64_t (*iFupu_t)(uint64_t, void*, uint64_t);
-typedef int64_t (*iFupp_t)(uint64_t, void*, void*);
-typedef int64_t (*iFppi_t)(void*, void*, int64_t);
-typedef int64_t (*iFppV_t)(void*, void*, ...);
-typedef int64_t (*IFpIi_t)(void*, int64_t, int64_t);
-typedef void* (*pFupp_t)(uint64_t, void*, void*);
-typedef void* (*pFppi_t)(void*, void*, int64_t);
-typedef void* (*pFppp_t)(void*, void*, void*);
-typedef void (*vFpuup_t)(void*, uint64_t, uint64_t, void*);
-typedef void (*vFGppp_t)(SDL_JoystickGUID, void*, void*, void*);
-typedef int64_t (*iFpLpp_t)(void*, uintptr_t, void*, void*);
-typedef int64_t (*iFpLpV_t)(void*, uintptr_t, void*, ...);
-typedef uint64_t (*uFppuu_t)(void*, void*, uint64_t, uint64_t);
-typedef int64_t (*iFpippi_t)(void*, int64_t, void*, void*, int64_t);
-typedef void* (*pFpippp_t)(void*, int64_t, void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(SDL_UnloadObject, vFp_t) \
- GO(SDL_Has3DNow, iFv_t) \
- GO(SDL_HasAVX, iFv_t) \
- GO(SDL_HasAVX2, iFv_t) \
- GO(SDL_HasAVX512F, iFv_t) \
- GO(SDL_HasAltiVec, iFv_t) \
- GO(SDL_HasMMX, iFv_t) \
- GO(SDL_HasNEON, iFv_t) \
- GO(SDL_HasRDTSC, iFv_t) \
- GO(SDL_HasSSE, iFv_t) \
- GO(SDL_HasSSE2, iFv_t) \
- GO(SDL_HasSSE3, iFv_t) \
- GO(SDL_HasSSE41, iFv_t) \
- GO(SDL_HasSSE42, iFv_t) \
- GO(SDL_RWclose, iFp_t) \
- GO(SDL_RemoveTimer, iFp_t) \
- GO(SDL_SaveAllDollarTemplates, iFp_t) \
- GO(SDL_RWtell, IFp_t) \
- GO(SDL_ReadBE16, uFp_t) \
- GO(SDL_ReadBE32, uFp_t) \
- GO(SDL_ReadLE16, uFp_t) \
- GO(SDL_ReadLE32, uFp_t) \
- GO(SDL_ReadU8, uFp_t) \
- GO(SDL_ReadBE64, UFp_t) \
- GO(SDL_ReadLE64, UFp_t) \
- GO(SDL_GetBasePath, pFv_t) \
- GO(SDL_Vulkan_GetVkGetInstanceProcAddr, pFv_t) \
- GO(SDL_GL_GetProcAddress, pFp_t) \
- GO(SDL_LoadObject, pFp_t) \
- GO(SDL_AddEventWatch, vFpp_t) \
- GO(SDL_DelEventWatch, vFpp_t) \
- GO(SDL_LogGetOutputFunction, vFpp_t) \
- GO(SDL_LogSetOutputFunction, vFpp_t) \
- GO(SDL_SetEventFilter, vFpp_t) \
- GO(SDL_Log, vFpV_t) \
- GO(SDL_SaveDollarTemplate, iFip_t) \
- GO(SDL_IsJoystickNintendoSwitchPro, iFWW_t) \
- GO(SDL_IsJoystickPS4, iFWW_t) \
- GO(SDL_IsJoystickSteamController, iFWW_t) \
- GO(SDL_IsJoystickXbox360, iFWW_t) \
- GO(SDL_IsJoystickXboxOne, iFWW_t) \
- GO(SDL_IsJoystickHIDAPI, iFUU_t) \
- GO(SDL_IsJoystickXInput, iFUU_t) \
- GO(SDL_GameControllerAddMappingsFromRW, iFpi_t) \
- GO(SDL_GetEventFilter, iFpp_t) \
- GO(SDL_OpenAudio, iFpp_t) \
- GO(SDL_WriteBE16, uFpW_t) \
- GO(SDL_WriteLE16, uFpW_t) \
- GO(SDL_WriteBE32, uFpu_t) \
- GO(SDL_WriteLE32, uFpu_t) \
- GO(SDL_WriteU8, uFpu_t) \
- GO(SDL_WriteBE64, uFpU_t) \
- GO(SDL_WriteLE64, uFpU_t) \
- GO(SDL_LoadBMP_RW, pFpi_t) \
- GO(SDL_RWFromConstMem, pFpi_t) \
- GO(SDL_RWFromFP, pFpi_t) \
- GO(SDL_RWFromMem, pFpi_t) \
- GO(SDL_LoadFunction, pFpp_t) \
- GO(SDL_RWFromFile, pFpp_t) \
- GO(SDL_LogCritical, vFipV_t) \
- GO(SDL_LogDebug, vFipV_t) \
- GO(SDL_LogError, vFipV_t) \
- GO(SDL_LogInfo, vFipV_t) \
- GO(SDL_LogVerbose, vFipV_t) \
- GO(SDL_LogWarn, vFipV_t) \
- GO(SDL_DYNAPI_entry, iFupu_t) \
- GO(SDL_TLSSet, iFupp_t) \
- GO(SDL_SaveBMP_RW, iFppi_t) \
- GO(SDL_sscanf, iFppV_t) \
- GO(SDL_RWseek, IFpIi_t) \
- GO(SDL_AddTimer, pFupp_t) \
- GO(SDL_LoadFile_RW, pFppi_t) \
- GO(SDL_CreateThread, pFppp_t) \
- GO(SDL_qsort, vFpuup_t) \
- GO(SDL_GetJoystickGUIDInfo, vFGppp_t) \
- GO(SDL_vsnprintf, iFpLpp_t) \
- GO(SDL_snprintf, iFpLpV_t) \
- GO(SDL_RWread, uFppuu_t) \
- GO(SDL_RWwrite, uFppuu_t) \
- GO(SDL_OpenAudioDevice, iFpippi_t) \
- GO(SDL_LoadWAV_RW, pFpippp_t)
-
-#endif // __wrappedsdl2TYPES_H_
diff --git a/src/wrapped/generated/wrappedsdl2undefs.h b/src/wrapped/generated/wrappedsdl2undefs.h
deleted file mode 100644
index f4d754d..0000000
--- a/src/wrapped/generated/wrappedsdl2undefs.h
+++ /dev/null
@@ -1,9 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsdl2UNDEFS_H_
-#define __wrappedsdl2UNDEFS_H_
-
-#undef vFGppp
-
-#endif // __wrappedsdl2UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedsecret1defs.h b/src/wrapped/generated/wrappedsecret1defs.h
deleted file mode 100644
index 34f3b2b..0000000
--- a/src/wrapped/generated/wrappedsecret1defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsecret1DEFS_H_
-#define __wrappedsecret1DEFS_H_
-
-
-#endif // __wrappedsecret1DEFS_H_
diff --git a/src/wrapped/generated/wrappedsecret1types.h b/src/wrapped/generated/wrappedsecret1types.h
deleted file mode 100644
index 9516e1f..0000000
--- a/src/wrapped/generated/wrappedsecret1types.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsecret1TYPES_H_
-#define __wrappedsecret1TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedsecret1TYPES_H_
diff --git a/src/wrapped/generated/wrappedsecret1undefs.h b/src/wrapped/generated/wrappedsecret1undefs.h
deleted file mode 100644
index d855e90..0000000
--- a/src/wrapped/generated/wrappedsecret1undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsecret1UNDEFS_H_
-#define __wrappedsecret1UNDEFS_H_
-
-
-#endif // __wrappedsecret1UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedselinuxdefs.h b/src/wrapped/generated/wrappedselinuxdefs.h
deleted file mode 100644
index c6fbb60..0000000
--- a/src/wrapped/generated/wrappedselinuxdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedselinuxDEFS_H_
-#define __wrappedselinuxDEFS_H_
-
-
-#endif // __wrappedselinuxDEFS_H_
diff --git a/src/wrapped/generated/wrappedselinuxtypes.h b/src/wrapped/generated/wrappedselinuxtypes.h
deleted file mode 100644
index d9e9d19..0000000
--- a/src/wrapped/generated/wrappedselinuxtypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedselinuxTYPES_H_
-#define __wrappedselinuxTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedselinuxTYPES_H_
diff --git a/src/wrapped/generated/wrappedselinuxundefs.h b/src/wrapped/generated/wrappedselinuxundefs.h
deleted file mode 100644
index b990e82..0000000
--- a/src/wrapped/generated/wrappedselinuxundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedselinuxUNDEFS_H_
-#define __wrappedselinuxUNDEFS_H_
-
-
-#endif // __wrappedselinuxUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedsmime3defs.h b/src/wrapped/generated/wrappedsmime3defs.h
deleted file mode 100644
index f406b3b..0000000
--- a/src/wrapped/generated/wrappedsmime3defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsmime3DEFS_H_
-#define __wrappedsmime3DEFS_H_
-
-
-#endif // __wrappedsmime3DEFS_H_
diff --git a/src/wrapped/generated/wrappedsmime3types.h b/src/wrapped/generated/wrappedsmime3types.h
deleted file mode 100644
index f1c61bd..0000000
--- a/src/wrapped/generated/wrappedsmime3types.h
+++ /dev/null
@@ -1,27 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsmime3TYPES_H_
-#define __wrappedsmime3TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef int64_t (*iFpp_t)(void*, void*);
-typedef int64_t (*iFppp_t)(void*, void*, void*);
-typedef void* (*pFpppp_t)(void*, void*, void*, void*);
-typedef void* (*pFpppppppp_t)(void*, void*, void*, void*, void*, void*, void*, void*);
-typedef void* (*pFppppppppppp_t)(void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(SEC_PKCS12DecoderValidateBags, iFpp_t) \
- GO(SEC_PKCS12Encode, iFppp_t) \
- GO(SEC_PKCS12CreateExportContext, pFpppp_t) \
- GO(SEC_PKCS12DecoderStart, pFpppppppp_t) \
- GO(NSS_CMSEncoder_Start, pFppppppppppp_t)
-
-#endif // __wrappedsmime3TYPES_H_
diff --git a/src/wrapped/generated/wrappedsmime3undefs.h b/src/wrapped/generated/wrappedsmime3undefs.h
deleted file mode 100644
index 752e4c6..0000000
--- a/src/wrapped/generated/wrappedsmime3undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsmime3UNDEFS_H_
-#define __wrappedsmime3UNDEFS_H_
-
-
-#endif // __wrappedsmime3UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedsmpeg2defs.h b/src/wrapped/generated/wrappedsmpeg2defs.h
deleted file mode 100644
index 45dfc21..0000000
--- a/src/wrapped/generated/wrappedsmpeg2defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsmpeg2DEFS_H_
-#define __wrappedsmpeg2DEFS_H_
-
-
-#endif // __wrappedsmpeg2DEFS_H_
diff --git a/src/wrapped/generated/wrappedsmpeg2types.h b/src/wrapped/generated/wrappedsmpeg2types.h
deleted file mode 100644
index faac1b2..0000000
--- a/src/wrapped/generated/wrappedsmpeg2types.h
+++ /dev/null
@@ -1,21 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsmpeg2TYPES_H_
-#define __wrappedsmpeg2TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFpppp_t)(void*, void*, void*, void*);
-typedef void* (*pFppii_t)(void*, void*, int64_t, int64_t);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(SMPEG_setdisplay, vFpppp_t) \
- GO(SMPEG_new_rwops, pFppii_t)
-
-#endif // __wrappedsmpeg2TYPES_H_
diff --git a/src/wrapped/generated/wrappedsmpeg2undefs.h b/src/wrapped/generated/wrappedsmpeg2undefs.h
deleted file mode 100644
index 1d8cd1a..0000000
--- a/src/wrapped/generated/wrappedsmpeg2undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsmpeg2UNDEFS_H_
-#define __wrappedsmpeg2UNDEFS_H_
-
-
-#endif // __wrappedsmpeg2UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedsmpegdefs.h b/src/wrapped/generated/wrappedsmpegdefs.h
deleted file mode 100644
index 9ad78b7..0000000
--- a/src/wrapped/generated/wrappedsmpegdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsmpegDEFS_H_
-#define __wrappedsmpegDEFS_H_
-
-
-#endif // __wrappedsmpegDEFS_H_
diff --git a/src/wrapped/generated/wrappedsmpegtypes.h b/src/wrapped/generated/wrappedsmpegtypes.h
deleted file mode 100644
index fabc779..0000000
--- a/src/wrapped/generated/wrappedsmpegtypes.h
+++ /dev/null
@@ -1,21 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsmpegTYPES_H_
-#define __wrappedsmpegTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void* (*pFppi_t)(void*, void*, int64_t);
-typedef void (*vFpppp_t)(void*, void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(SMPEG_new_rwops, pFppi_t) \
- GO(SMPEG_setdisplay, vFpppp_t)
-
-#endif // __wrappedsmpegTYPES_H_
diff --git a/src/wrapped/generated/wrappedsmpegundefs.h b/src/wrapped/generated/wrappedsmpegundefs.h
deleted file mode 100644
index b2eb516..0000000
--- a/src/wrapped/generated/wrappedsmpegundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsmpegUNDEFS_H_
-#define __wrappedsmpegUNDEFS_H_
-
-
-#endif // __wrappedsmpegUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedsoftokn3defs.h b/src/wrapped/generated/wrappedsoftokn3defs.h
deleted file mode 100644
index 91f9d9d..0000000
--- a/src/wrapped/generated/wrappedsoftokn3defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsoftokn3DEFS_H_
-#define __wrappedsoftokn3DEFS_H_
-
-
-#endif // __wrappedsoftokn3DEFS_H_
diff --git a/src/wrapped/generated/wrappedsoftokn3types.h b/src/wrapped/generated/wrappedsoftokn3types.h
deleted file mode 100644
index b5391b9..0000000
--- a/src/wrapped/generated/wrappedsoftokn3types.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsoftokn3TYPES_H_
-#define __wrappedsoftokn3TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedsoftokn3TYPES_H_
diff --git a/src/wrapped/generated/wrappedsoftokn3undefs.h b/src/wrapped/generated/wrappedsoftokn3undefs.h
deleted file mode 100644
index 6e04229..0000000
--- a/src/wrapped/generated/wrappedsoftokn3undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedsoftokn3UNDEFS_H_
-#define __wrappedsoftokn3UNDEFS_H_
-
-
-#endif // __wrappedsoftokn3UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedssl3defs.h b/src/wrapped/generated/wrappedssl3defs.h
deleted file mode 100644
index 748b156..0000000
--- a/src/wrapped/generated/wrappedssl3defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedssl3DEFS_H_
-#define __wrappedssl3DEFS_H_
-
-
-#endif // __wrappedssl3DEFS_H_
diff --git a/src/wrapped/generated/wrappedssl3types.h b/src/wrapped/generated/wrappedssl3types.h
deleted file mode 100644
index 5ce3f08..0000000
--- a/src/wrapped/generated/wrappedssl3types.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedssl3TYPES_H_
-#define __wrappedssl3TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedssl3TYPES_H_
diff --git a/src/wrapped/generated/wrappedssl3undefs.h b/src/wrapped/generated/wrappedssl3undefs.h
deleted file mode 100644
index 7f49df6..0000000
--- a/src/wrapped/generated/wrappedssl3undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedssl3UNDEFS_H_
-#define __wrappedssl3UNDEFS_H_
-
-
-#endif // __wrappedssl3UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedtbbmallocdefs.h b/src/wrapped/generated/wrappedtbbmallocdefs.h
deleted file mode 100644
index e8824d7..0000000
--- a/src/wrapped/generated/wrappedtbbmallocdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedtbbmallocDEFS_H_
-#define __wrappedtbbmallocDEFS_H_
-
-
-#endif // __wrappedtbbmallocDEFS_H_
diff --git a/src/wrapped/generated/wrappedtbbmallocproxydefs.h b/src/wrapped/generated/wrappedtbbmallocproxydefs.h
deleted file mode 100644
index 102e0dd..0000000
--- a/src/wrapped/generated/wrappedtbbmallocproxydefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedtbbmallocproxyDEFS_H_
-#define __wrappedtbbmallocproxyDEFS_H_
-
-
-#endif // __wrappedtbbmallocproxyDEFS_H_
diff --git a/src/wrapped/generated/wrappedtbbmallocproxytypes.h b/src/wrapped/generated/wrappedtbbmallocproxytypes.h
deleted file mode 100644
index 8cdcf36..0000000
--- a/src/wrapped/generated/wrappedtbbmallocproxytypes.h
+++ /dev/null
@@ -1,37 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedtbbmallocproxyTYPES_H_
-#define __wrappedtbbmallocproxyTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFp_t)(void*);
-typedef void* (*pFL_t)(uintptr_t);
-typedef void (*vFpp_t)(void*, void*);
-typedef void* (*pFLp_t)(uintptr_t, void*);
-typedef int64_t (*iFipp_t)(int64_t, void*, void*);
-typedef int64_t (*iFppi_t)(void*, void*, int64_t);
-typedef int64_t (*iFppp_t)(void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(_ZdaPv, vFp_t) \
- GO(_ZdlPv, vFp_t) \
- GO(__RML_close_factory, vFp_t) \
- GO(_Znam, pFL_t) \
- GO(_Znwm, pFL_t) \
- GO(_ZdaPvRKSt9nothrow_t, vFpp_t) \
- GO(_ZdlPvRKSt9nothrow_t, vFpp_t) \
- GO(__TBB_call_with_my_server_info, vFpp_t) \
- GO(_ZnamRKSt9nothrow_t, pFLp_t) \
- GO(_ZnwmRKSt9nothrow_t, pFLp_t) \
- GO(__TBB_internal_find_original_malloc, iFipp_t) \
- GO(__RML_open_factory, iFppi_t) \
- GO(__TBB_make_rml_server, iFppp_t)
-
-#endif // __wrappedtbbmallocproxyTYPES_H_
diff --git a/src/wrapped/generated/wrappedtbbmallocproxyundefs.h b/src/wrapped/generated/wrappedtbbmallocproxyundefs.h
deleted file mode 100644
index 9f6f1d8..0000000
--- a/src/wrapped/generated/wrappedtbbmallocproxyundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedtbbmallocproxyUNDEFS_H_
-#define __wrappedtbbmallocproxyUNDEFS_H_
-
-
-#endif // __wrappedtbbmallocproxyUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedtbbmalloctypes.h b/src/wrapped/generated/wrappedtbbmalloctypes.h
deleted file mode 100644
index b4af958..0000000
--- a/src/wrapped/generated/wrappedtbbmalloctypes.h
+++ /dev/null
@@ -1,34 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedtbbmallocTYPES_H_
-#define __wrappedtbbmallocTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFp_t)(void*);
-typedef uintptr_t (*LFp_t)(void*);
-typedef uintptr_t (*LFpp_t)(void*, void*);
-typedef void* (*pFLL_t)(uintptr_t, uintptr_t);
-typedef void* (*pFpp_t)(void*, void*);
-typedef void* (*pFpLL_t)(void*, uintptr_t, uintptr_t);
-typedef void* (*pFpLp_t)(void*, uintptr_t, void*);
-typedef void* (*pFpLLp_t)(void*, uintptr_t, uintptr_t, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(scalable_aligned_free, vFp_t) \
- GO(scalable_msize, LFp_t) \
- GO(safer_scalable_msize, LFpp_t) \
- GO(scalable_aligned_malloc, pFLL_t) \
- GO(scalable_calloc, pFLL_t) \
- GO(safer_scalable_free, pFpp_t) \
- GO(scalable_aligned_realloc, pFpLL_t) \
- GO(safer_scalable_realloc, pFpLp_t) \
- GO(safer_scalable_aligned_realloc, pFpLLp_t)
-
-#endif // __wrappedtbbmallocTYPES_H_
diff --git a/src/wrapped/generated/wrappedtbbmallocundefs.h b/src/wrapped/generated/wrappedtbbmallocundefs.h
deleted file mode 100644
index e150336..0000000
--- a/src/wrapped/generated/wrappedtbbmallocundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedtbbmallocUNDEFS_H_
-#define __wrappedtbbmallocUNDEFS_H_
-
-
-#endif // __wrappedtbbmallocUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedtcmallocminimaldefs.h b/src/wrapped/generated/wrappedtcmallocminimaldefs.h
deleted file mode 100644
index 36f35e1..0000000
--- a/src/wrapped/generated/wrappedtcmallocminimaldefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedtcmallocminimalDEFS_H_
-#define __wrappedtcmallocminimalDEFS_H_
-
-
-#endif // __wrappedtcmallocminimalDEFS_H_
diff --git a/src/wrapped/generated/wrappedtcmallocminimaltypes.h b/src/wrapped/generated/wrappedtcmallocminimaltypes.h
deleted file mode 100644
index 29629c7..0000000
--- a/src/wrapped/generated/wrappedtcmallocminimaltypes.h
+++ /dev/null
@@ -1,25 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedtcmallocminimalTYPES_H_
-#define __wrappedtcmallocminimalTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void* (*pFp_t)(void*);
-typedef int64_t (*iFpL_t)(void*, uintptr_t);
-typedef void* (*pFpLiiii_t)(void*, uintptr_t, int64_t, int64_t, int64_t, int64_t);
-typedef void* (*pFpLiiiI_t)(void*, uintptr_t, int64_t, int64_t, int64_t, int64_t);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(mallinfo, pFp_t) \
- GO(munmap, iFpL_t) \
- GO(mmap, pFpLiiii_t) \
- GO(mmap64, pFpLiiiI_t)
-
-#endif // __wrappedtcmallocminimalTYPES_H_
diff --git a/src/wrapped/generated/wrappedtcmallocminimalundefs.h b/src/wrapped/generated/wrappedtcmallocminimalundefs.h
deleted file mode 100644
index 00f2d98..0000000
--- a/src/wrapped/generated/wrappedtcmallocminimalundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedtcmallocminimalUNDEFS_H_
-#define __wrappedtcmallocminimalUNDEFS_H_
-
-
-#endif // __wrappedtcmallocminimalUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedudev0defs.h b/src/wrapped/generated/wrappedudev0defs.h
deleted file mode 100644
index ad75b5a..0000000
--- a/src/wrapped/generated/wrappedudev0defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedudev0DEFS_H_
-#define __wrappedudev0DEFS_H_
-
-
-#endif // __wrappedudev0DEFS_H_
diff --git a/src/wrapped/generated/wrappedudev0types.h b/src/wrapped/generated/wrappedudev0types.h
deleted file mode 100644
index 6ecaad5..0000000
--- a/src/wrapped/generated/wrappedudev0types.h
+++ /dev/null
@@ -1,19 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedudev0TYPES_H_
-#define __wrappedudev0TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFpp_t)(void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(udev_set_log_fn, vFpp_t)
-
-#endif // __wrappedudev0TYPES_H_
diff --git a/src/wrapped/generated/wrappedudev0undefs.h b/src/wrapped/generated/wrappedudev0undefs.h
deleted file mode 100644
index fdddd67..0000000
--- a/src/wrapped/generated/wrappedudev0undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedudev0UNDEFS_H_
-#define __wrappedudev0UNDEFS_H_
-
-
-#endif // __wrappedudev0UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedudev1defs.h b/src/wrapped/generated/wrappedudev1defs.h
deleted file mode 100644
index f1fcbe8..0000000
--- a/src/wrapped/generated/wrappedudev1defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedudev1DEFS_H_
-#define __wrappedudev1DEFS_H_
-
-
-#endif // __wrappedudev1DEFS_H_
diff --git a/src/wrapped/generated/wrappedudev1types.h b/src/wrapped/generated/wrappedudev1types.h
deleted file mode 100644
index caebde9..0000000
--- a/src/wrapped/generated/wrappedudev1types.h
+++ /dev/null
@@ -1,19 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedudev1TYPES_H_
-#define __wrappedudev1TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFpp_t)(void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(udev_set_log_fn, vFpp_t)
-
-#endif // __wrappedudev1TYPES_H_
diff --git a/src/wrapped/generated/wrappedudev1undefs.h b/src/wrapped/generated/wrappedudev1undefs.h
deleted file mode 100644
index 432efc0..0000000
--- a/src/wrapped/generated/wrappedudev1undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedudev1UNDEFS_H_
-#define __wrappedudev1UNDEFS_H_
-
-
-#endif // __wrappedudev1UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedunwinddefs.h b/src/wrapped/generated/wrappedunwinddefs.h
deleted file mode 100644
index f17201d..0000000
--- a/src/wrapped/generated/wrappedunwinddefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedunwindDEFS_H_
-#define __wrappedunwindDEFS_H_
-
-
-#endif // __wrappedunwindDEFS_H_
diff --git a/src/wrapped/generated/wrappedunwindtypes.h b/src/wrapped/generated/wrappedunwindtypes.h
deleted file mode 100644
index f67a0c8..0000000
--- a/src/wrapped/generated/wrappedunwindtypes.h
+++ /dev/null
@@ -1,24 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedunwindTYPES_H_
-#define __wrappedunwindTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef int64_t (*iFp_t)(void*);
-typedef int64_t (*iFpp_t)(void*, void*);
-typedef int64_t (*iFpip_t)(void*, int64_t, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(_ULx86_64_step, iFp_t) \
- GO(_ULx86_64_get_proc_info, iFpp_t) \
- GO(_ULx86_64_init_local, iFpp_t) \
- GO(_ULx86_64_get_reg, iFpip_t)
-
-#endif // __wrappedunwindTYPES_H_
diff --git a/src/wrapped/generated/wrappedunwindundefs.h b/src/wrapped/generated/wrappedunwindundefs.h
deleted file mode 100644
index e63b3cc..0000000
--- a/src/wrapped/generated/wrappedunwindundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedunwindUNDEFS_H_
-#define __wrappedunwindUNDEFS_H_
-
-
-#endif // __wrappedunwindUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedutildefs.h b/src/wrapped/generated/wrappedutildefs.h
deleted file mode 100644
index aed9b4f..0000000
--- a/src/wrapped/generated/wrappedutildefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedutilDEFS_H_
-#define __wrappedutilDEFS_H_
-
-
-#endif // __wrappedutilDEFS_H_
diff --git a/src/wrapped/generated/wrappedutiltypes.h b/src/wrapped/generated/wrappedutiltypes.h
deleted file mode 100644
index 29daac5..0000000
--- a/src/wrapped/generated/wrappedutiltypes.h
+++ /dev/null
@@ -1,19 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedutilTYPES_H_
-#define __wrappedutilTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef int64_t (*iFpppp_t)(void*, void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(forkpty, iFpppp_t)
-
-#endif // __wrappedutilTYPES_H_
diff --git a/src/wrapped/generated/wrappedutilundefs.h b/src/wrapped/generated/wrappedutilundefs.h
deleted file mode 100644
index 7a6ade6..0000000
--- a/src/wrapped/generated/wrappedutilundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedutilUNDEFS_H_
-#define __wrappedutilUNDEFS_H_
-
-
-#endif // __wrappedutilUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedvorbisfiledefs.h b/src/wrapped/generated/wrappedvorbisfiledefs.h
deleted file mode 100644
index 8087ee9..0000000
--- a/src/wrapped/generated/wrappedvorbisfiledefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedvorbisfileDEFS_H_
-#define __wrappedvorbisfileDEFS_H_
-
-
-#endif // __wrappedvorbisfileDEFS_H_
diff --git a/src/wrapped/generated/wrappedvorbisfiletypes.h b/src/wrapped/generated/wrappedvorbisfiletypes.h
deleted file mode 100644
index 5ac27b5..0000000
--- a/src/wrapped/generated/wrappedvorbisfiletypes.h
+++ /dev/null
@@ -1,20 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedvorbisfileTYPES_H_
-#define __wrappedvorbisfileTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef int64_t (*iFppplPPPP_t)(void*, void*, void*, intptr_t, void*, void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(ov_open_callbacks, iFppplPPPP_t) \
- GO(ov_test_callbacks, iFppplPPPP_t)
-
-#endif // __wrappedvorbisfileTYPES_H_
diff --git a/src/wrapped/generated/wrappedvorbisfileundefs.h b/src/wrapped/generated/wrappedvorbisfileundefs.h
deleted file mode 100644
index 7d2eb75..0000000
--- a/src/wrapped/generated/wrappedvorbisfileundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedvorbisfileUNDEFS_H_
-#define __wrappedvorbisfileUNDEFS_H_
-
-
-#endif // __wrappedvorbisfileUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedvulkandefs.h b/src/wrapped/generated/wrappedvulkandefs.h
deleted file mode 100644
index c5f1fde..0000000
--- a/src/wrapped/generated/wrappedvulkandefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedvulkanDEFS_H_
-#define __wrappedvulkanDEFS_H_
-
-
-#endif // __wrappedvulkanDEFS_H_
diff --git a/src/wrapped/generated/wrappedvulkantypes.h b/src/wrapped/generated/wrappedvulkantypes.h
deleted file mode 100644
index 5dfd704..0000000
--- a/src/wrapped/generated/wrappedvulkantypes.h
+++ /dev/null
@@ -1,135 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedvulkanTYPES_H_
-#define __wrappedvulkanTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFpp_t)(void*, void*);
-typedef void* (*pFpp_t)(void*, void*);
-typedef void (*vFpUp_t)(void*, uint64_t, void*);
-typedef void (*vFppp_t)(void*, void*, void*);
-typedef int64_t (*iFpUp_t)(void*, uint64_t, void*);
-typedef int64_t (*iFppp_t)(void*, void*, void*);
-typedef int64_t (*iFpUup_t)(void*, uint64_t, uint64_t, void*);
-typedef int64_t (*iFpppp_t)(void*, void*, void*, void*);
-typedef void (*vFpupup_t)(void*, uint64_t, void*, uint64_t, void*);
-typedef int64_t (*iFpuppp_t)(void*, uint64_t, void*, void*, void*);
-typedef int64_t (*iFpUppp_t)(void*, uint64_t, void*, void*, void*);
-typedef int64_t (*iFpUuppp_t)(void*, uint64_t, uint64_t, void*, void*, void*);
-typedef int64_t (*iFpUUuppp_t)(void*, uint64_t, uint64_t, uint64_t, void*, void*, void*);
-typedef void (*vFpiiiiipp_t)(void*, int64_t, int64_t, int64_t, int64_t, int64_t, void*, void*);
-typedef void (*vFpiiiupupup_t)(void*, int64_t, int64_t, int64_t, uint64_t, void*, uint64_t, void*, uint64_t, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(vkDestroyDevice, vFpp_t) \
- GO(vkDestroyInstance, vFpp_t) \
- GO(vkGetPhysicalDeviceMemoryProperties, vFpp_t) \
- GO(vkGetPhysicalDeviceProperties, vFpp_t) \
- GO(vkGetDeviceProcAddr, pFpp_t) \
- GO(vkGetInstanceProcAddr, pFpp_t) \
- GO(vkDestroyAccelerationStructureKHR, vFpUp_t) \
- GO(vkDestroyAccelerationStructureNV, vFpUp_t) \
- GO(vkDestroyBuffer, vFpUp_t) \
- GO(vkDestroyBufferView, vFpUp_t) \
- GO(vkDestroyCommandPool, vFpUp_t) \
- GO(vkDestroyCuFunctionNVX, vFpUp_t) \
- GO(vkDestroyCuModuleNVX, vFpUp_t) \
- GO(vkDestroyDeferredOperationKHR, vFpUp_t) \
- GO(vkDestroyDescriptorPool, vFpUp_t) \
- GO(vkDestroyDescriptorSetLayout, vFpUp_t) \
- GO(vkDestroyDescriptorUpdateTemplate, vFpUp_t) \
- GO(vkDestroyDescriptorUpdateTemplateKHR, vFpUp_t) \
- GO(vkDestroyEvent, vFpUp_t) \
- GO(vkDestroyFence, vFpUp_t) \
- GO(vkDestroyFramebuffer, vFpUp_t) \
- GO(vkDestroyImage, vFpUp_t) \
- GO(vkDestroyImageView, vFpUp_t) \
- GO(vkDestroyIndirectCommandsLayoutNV, vFpUp_t) \
- GO(vkDestroyOpticalFlowSessionNV, vFpUp_t) \
- GO(vkDestroyPipeline, vFpUp_t) \
- GO(vkDestroyPipelineCache, vFpUp_t) \
- GO(vkDestroyPipelineLayout, vFpUp_t) \
- GO(vkDestroyPrivateDataSlot, vFpUp_t) \
- GO(vkDestroyPrivateDataSlotEXT, vFpUp_t) \
- GO(vkDestroyQueryPool, vFpUp_t) \
- GO(vkDestroyRenderPass, vFpUp_t) \
- GO(vkDestroySampler, vFpUp_t) \
- GO(vkDestroySamplerYcbcrConversionKHR, vFpUp_t) \
- GO(vkDestroySemaphore, vFpUp_t) \
- GO(vkDestroyShaderModule, vFpUp_t) \
- GO(vkDestroySurfaceKHR, vFpUp_t) \
- GO(vkDestroySwapchainKHR, vFpUp_t) \
- GO(vkDestroyValidationCacheEXT, vFpUp_t) \
- GO(vkDestroyVideoSessionKHR, vFpUp_t) \
- GO(vkDestroyVideoSessionParametersKHR, vFpUp_t) \
- GO(vkDestroyDebugUtilsMessengerEXT, vFppp_t) \
- GO(vkFreeMemory, iFpUp_t) \
- GO(vkCreateDeferredOperationKHR, iFppp_t) \
- GO(vkCreateInstance, iFppp_t) \
- GO(vkDestroyDebugReportCallbackEXT, iFppp_t) \
- GO(vkGetPhysicalDeviceDisplayPropertiesKHR, iFppp_t) \
- GO(vkGetDisplayPlaneCapabilitiesKHR, iFpUup_t) \
- GO(vkAllocateMemory, iFpppp_t) \
- GO(vkCreateAccelerationStructureKHR, iFpppp_t) \
- GO(vkCreateAccelerationStructureNV, iFpppp_t) \
- GO(vkCreateBuffer, iFpppp_t) \
- GO(vkCreateBufferView, iFpppp_t) \
- GO(vkCreateCommandPool, iFpppp_t) \
- GO(vkCreateCuFunctionNVX, iFpppp_t) \
- GO(vkCreateCuModuleNVX, iFpppp_t) \
- GO(vkCreateDebugReportCallbackEXT, iFpppp_t) \
- GO(vkCreateDebugUtilsMessengerEXT, iFpppp_t) \
- GO(vkCreateDescriptorPool, iFpppp_t) \
- GO(vkCreateDescriptorSetLayout, iFpppp_t) \
- GO(vkCreateDescriptorUpdateTemplate, iFpppp_t) \
- GO(vkCreateDescriptorUpdateTemplateKHR, iFpppp_t) \
- GO(vkCreateDevice, iFpppp_t) \
- GO(vkCreateDisplayPlaneSurfaceKHR, iFpppp_t) \
- GO(vkCreateEvent, iFpppp_t) \
- GO(vkCreateFence, iFpppp_t) \
- GO(vkCreateFramebuffer, iFpppp_t) \
- GO(vkCreateHeadlessSurfaceEXT, iFpppp_t) \
- GO(vkCreateImage, iFpppp_t) \
- GO(vkCreateImageView, iFpppp_t) \
- GO(vkCreateIndirectCommandsLayoutNV, iFpppp_t) \
- GO(vkCreateOpticalFlowSessionNV, iFpppp_t) \
- GO(vkCreatePipelineCache, iFpppp_t) \
- GO(vkCreatePipelineLayout, iFpppp_t) \
- GO(vkCreatePrivateDataSlot, iFpppp_t) \
- GO(vkCreatePrivateDataSlotEXT, iFpppp_t) \
- GO(vkCreateQueryPool, iFpppp_t) \
- GO(vkCreateRenderPass, iFpppp_t) \
- GO(vkCreateRenderPass2, iFpppp_t) \
- GO(vkCreateRenderPass2KHR, iFpppp_t) \
- GO(vkCreateSampler, iFpppp_t) \
- GO(vkCreateSamplerYcbcrConversion, iFpppp_t) \
- GO(vkCreateSamplerYcbcrConversionKHR, iFpppp_t) \
- GO(vkCreateSemaphore, iFpppp_t) \
- GO(vkCreateShaderModule, iFpppp_t) \
- GO(vkCreateSwapchainKHR, iFpppp_t) \
- GO(vkCreateValidationCacheEXT, iFpppp_t) \
- GO(vkCreateVideoSessionKHR, iFpppp_t) \
- GO(vkCreateVideoSessionParametersKHR, iFpppp_t) \
- GO(vkCreateWaylandSurfaceKHR, iFpppp_t) \
- GO(vkCreateXcbSurfaceKHR, iFpppp_t) \
- GO(vkCreateXlibSurfaceKHR, iFpppp_t) \
- GO(vkRegisterDeviceEventEXT, iFpppp_t) \
- GO(vkUpdateDescriptorSets, vFpupup_t) \
- GO(vkCreateSharedSwapchainsKHR, iFpuppp_t) \
- GO(vkCreateDisplayModeKHR, iFpUppp_t) \
- GO(vkRegisterDisplayEventEXT, iFpUppp_t) \
- GO(vkCreateComputePipelines, iFpUuppp_t) \
- GO(vkCreateGraphicsPipelines, iFpUuppp_t) \
- GO(vkCreateRayTracingPipelinesNV, iFpUuppp_t) \
- GO(vkCreateRayTracingPipelinesKHR, iFpUUuppp_t) \
- GO(vkGetPhysicalDeviceSparseImageFormatProperties, vFpiiiiipp_t) \
- GO(vkCmdPipelineBarrier, vFpiiiupupup_t)
-
-#endif // __wrappedvulkanTYPES_H_
diff --git a/src/wrapped/generated/wrappedvulkanundefs.h b/src/wrapped/generated/wrappedvulkanundefs.h
deleted file mode 100644
index 801e45c..0000000
--- a/src/wrapped/generated/wrappedvulkanundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedvulkanUNDEFS_H_
-#define __wrappedvulkanUNDEFS_H_
-
-
-#endif // __wrappedvulkanUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedwaylandclientdefs.h b/src/wrapped/generated/wrappedwaylandclientdefs.h
deleted file mode 100644
index c3dc9d4..0000000
--- a/src/wrapped/generated/wrappedwaylandclientdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedwaylandclientDEFS_H_
-#define __wrappedwaylandclientDEFS_H_
-
-
-#endif // __wrappedwaylandclientDEFS_H_
diff --git a/src/wrapped/generated/wrappedwaylandclienttypes.h b/src/wrapped/generated/wrappedwaylandclienttypes.h
deleted file mode 100644
index 73955fc..0000000
--- a/src/wrapped/generated/wrappedwaylandclienttypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedwaylandclientTYPES_H_
-#define __wrappedwaylandclientTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedwaylandclientTYPES_H_
diff --git a/src/wrapped/generated/wrappedwaylandclientundefs.h b/src/wrapped/generated/wrappedwaylandclientundefs.h
deleted file mode 100644
index ad6daca..0000000
--- a/src/wrapped/generated/wrappedwaylandclientundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedwaylandclientUNDEFS_H_
-#define __wrappedwaylandclientUNDEFS_H_
-
-
-#endif // __wrappedwaylandclientUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedwaylandcursordefs.h b/src/wrapped/generated/wrappedwaylandcursordefs.h
deleted file mode 100644
index 49984bc..0000000
--- a/src/wrapped/generated/wrappedwaylandcursordefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedwaylandcursorDEFS_H_
-#define __wrappedwaylandcursorDEFS_H_
-
-
-#endif // __wrappedwaylandcursorDEFS_H_
diff --git a/src/wrapped/generated/wrappedwaylandcursortypes.h b/src/wrapped/generated/wrappedwaylandcursortypes.h
deleted file mode 100644
index ac4922e..0000000
--- a/src/wrapped/generated/wrappedwaylandcursortypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedwaylandcursorTYPES_H_
-#define __wrappedwaylandcursorTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedwaylandcursorTYPES_H_
diff --git a/src/wrapped/generated/wrappedwaylandcursorundefs.h b/src/wrapped/generated/wrappedwaylandcursorundefs.h
deleted file mode 100644
index dd2a2e6..0000000
--- a/src/wrapped/generated/wrappedwaylandcursorundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedwaylandcursorUNDEFS_H_
-#define __wrappedwaylandcursorUNDEFS_H_
-
-
-#endif // __wrappedwaylandcursorUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedwaylandegldefs.h b/src/wrapped/generated/wrappedwaylandegldefs.h
deleted file mode 100644
index a405c29..0000000
--- a/src/wrapped/generated/wrappedwaylandegldefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedwaylandeglDEFS_H_
-#define __wrappedwaylandeglDEFS_H_
-
-
-#endif // __wrappedwaylandeglDEFS_H_
diff --git a/src/wrapped/generated/wrappedwaylandegltypes.h b/src/wrapped/generated/wrappedwaylandegltypes.h
deleted file mode 100644
index 2414c88..0000000
--- a/src/wrapped/generated/wrappedwaylandegltypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedwaylandeglTYPES_H_
-#define __wrappedwaylandeglTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedwaylandeglTYPES_H_
diff --git a/src/wrapped/generated/wrappedwaylandeglundefs.h b/src/wrapped/generated/wrappedwaylandeglundefs.h
deleted file mode 100644
index 816d557..0000000
--- a/src/wrapped/generated/wrappedwaylandeglundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedwaylandeglUNDEFS_H_
-#define __wrappedwaylandeglUNDEFS_H_
-
-
-#endif // __wrappedwaylandeglUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedxineramadefs.h b/src/wrapped/generated/wrappedxineramadefs.h
deleted file mode 100644
index f63517d..0000000
--- a/src/wrapped/generated/wrappedxineramadefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedxineramaDEFS_H_
-#define __wrappedxineramaDEFS_H_
-
-
-#endif // __wrappedxineramaDEFS_H_
diff --git a/src/wrapped/generated/wrappedxineramatypes.h b/src/wrapped/generated/wrappedxineramatypes.h
deleted file mode 100644
index ce546b9..0000000
--- a/src/wrapped/generated/wrappedxineramatypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedxineramaTYPES_H_
-#define __wrappedxineramaTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedxineramaTYPES_H_
diff --git a/src/wrapped/generated/wrappedxineramaundefs.h b/src/wrapped/generated/wrappedxineramaundefs.h
deleted file mode 100644
index c54bf76..0000000
--- a/src/wrapped/generated/wrappedxineramaundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedxineramaUNDEFS_H_
-#define __wrappedxineramaUNDEFS_H_
-
-
-#endif // __wrappedxineramaUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedxkbcommondefs.h b/src/wrapped/generated/wrappedxkbcommondefs.h
deleted file mode 100644
index 282d81f..0000000
--- a/src/wrapped/generated/wrappedxkbcommondefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedxkbcommonDEFS_H_
-#define __wrappedxkbcommonDEFS_H_
-
-
-#endif // __wrappedxkbcommonDEFS_H_
diff --git a/src/wrapped/generated/wrappedxkbcommontypes.h b/src/wrapped/generated/wrappedxkbcommontypes.h
deleted file mode 100644
index 94ab629..0000000
--- a/src/wrapped/generated/wrappedxkbcommontypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedxkbcommonTYPES_H_
-#define __wrappedxkbcommonTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedxkbcommonTYPES_H_
diff --git a/src/wrapped/generated/wrappedxkbcommonundefs.h b/src/wrapped/generated/wrappedxkbcommonundefs.h
deleted file mode 100644
index 9c3ee38..0000000
--- a/src/wrapped/generated/wrappedxkbcommonundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedxkbcommonUNDEFS_H_
-#define __wrappedxkbcommonUNDEFS_H_
-
-
-#endif // __wrappedxkbcommonUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedxkbcommonx11defs.h b/src/wrapped/generated/wrappedxkbcommonx11defs.h
deleted file mode 100644
index 79648b0..0000000
--- a/src/wrapped/generated/wrappedxkbcommonx11defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedxkbcommonx11DEFS_H_
-#define __wrappedxkbcommonx11DEFS_H_
-
-
-#endif // __wrappedxkbcommonx11DEFS_H_
diff --git a/src/wrapped/generated/wrappedxkbcommonx11types.h b/src/wrapped/generated/wrappedxkbcommonx11types.h
deleted file mode 100644
index 7387729..0000000
--- a/src/wrapped/generated/wrappedxkbcommonx11types.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedxkbcommonx11TYPES_H_
-#define __wrappedxkbcommonx11TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedxkbcommonx11TYPES_H_
diff --git a/src/wrapped/generated/wrappedxkbcommonx11undefs.h b/src/wrapped/generated/wrappedxkbcommonx11undefs.h
deleted file mode 100644
index 83513ae..0000000
--- a/src/wrapped/generated/wrappedxkbcommonx11undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedxkbcommonx11UNDEFS_H_
-#define __wrappedxkbcommonx11UNDEFS_H_
-
-
-#endif // __wrappedxkbcommonx11UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedxml2defs.h b/src/wrapped/generated/wrappedxml2defs.h
deleted file mode 100644
index c02ed09..0000000
--- a/src/wrapped/generated/wrappedxml2defs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedxml2DEFS_H_
-#define __wrappedxml2DEFS_H_
-
-
-#endif // __wrappedxml2DEFS_H_
diff --git a/src/wrapped/generated/wrappedxml2types.h b/src/wrapped/generated/wrappedxml2types.h
deleted file mode 100644
index 64fafa0..0000000
--- a/src/wrapped/generated/wrappedxml2types.h
+++ /dev/null
@@ -1,60 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedxml2TYPES_H_
-#define __wrappedxml2TYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFp_t)(void*);
-typedef int64_t (*iFp_t)(void*);
-typedef void* (*pFv_t)(void);
-typedef void (*vFpp_t)(void*, void*);
-typedef void* (*pFpp_t)(void*, void*);
-typedef void (*vFppp_t)(void*, void*, void*);
-typedef int64_t (*iFppp_t)(void*, void*, void*);
-typedef void* (*pFppp_t)(void*, void*, void*);
-typedef void (*vFpppp_t)(void*, void*, void*, void*);
-typedef int64_t (*iFpppp_t)(void*, void*, void*, void*);
-typedef void* (*pFpppi_t)(void*, void*, void*, int64_t);
-typedef void* (*pFpppp_t)(void*, void*, void*, void*);
-typedef int64_t (*iFppppp_t)(void*, void*, void*, void*, void*);
-typedef void* (*pFppppi_t)(void*, void*, void*, void*, int64_t);
-typedef void (*vFpppppp_t)(void*, void*, void*, void*, void*, void*);
-typedef int64_t (*iFpppppp_t)(void*, void*, void*, void*, void*, void*);
-typedef void* (*pFpppppi_t)(void*, void*, void*, void*, void*, int64_t);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(xmlSetExternalEntityLoader, vFp_t) \
- GO(xmlParseDocument, iFp_t) \
- GO(xmlGetExternalEntityLoader, pFv_t) \
- GO(xmlHashFree, vFpp_t) \
- GO(xmlHashCopy, pFpp_t) \
- GO(xmlHashScan, vFppp_t) \
- GO(xmlHashScanFull, vFppp_t) \
- GO(xmlSchemaSetParserStructuredErrors, vFppp_t) \
- GO(xmlSchemaSetValidStructuredErrors, vFppp_t) \
- GO(xmlHashRemoveEntry, iFppp_t) \
- GO(xmlXPathRegisterFunc, iFppp_t) \
- GO(xmlNewCharEncodingHandler, pFppp_t) \
- GO(xmlSchemaSetParserErrors, vFpppp_t) \
- GO(xmlSchemaSetValidErrors, vFpppp_t) \
- GO(xmlHashRemoveEntry2, iFpppp_t) \
- GO(xmlHashUpdateEntry, iFpppp_t) \
- GO(xmlRegisterInputCallbacks, iFpppp_t) \
- GO(xmlParserInputBufferCreateIO, pFpppi_t) \
- GO(xmlOutputBufferCreateIO, pFpppp_t) \
- GO(xmlHashRemoveEntry3, iFppppp_t) \
- GO(xmlHashUpdateEntry2, iFppppp_t) \
- GO(xmlSaveToIO, pFppppi_t) \
- GO(xmlHashScan3, vFpppppp_t) \
- GO(xmlHashScanFull3, vFpppppp_t) \
- GO(xmlHashUpdateEntry3, iFpppppp_t) \
- GO(xmlCreateIOParserCtxt, pFpppppi_t)
-
-#endif // __wrappedxml2TYPES_H_
diff --git a/src/wrapped/generated/wrappedxml2undefs.h b/src/wrapped/generated/wrappedxml2undefs.h
deleted file mode 100644
index 9938f1c..0000000
--- a/src/wrapped/generated/wrappedxml2undefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedxml2UNDEFS_H_
-#define __wrappedxml2UNDEFS_H_
-
-
-#endif // __wrappedxml2UNDEFS_H_
diff --git a/src/wrapped/generated/wrappedxshmfencedefs.h b/src/wrapped/generated/wrappedxshmfencedefs.h
deleted file mode 100644
index 7e60156..0000000
--- a/src/wrapped/generated/wrappedxshmfencedefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedxshmfenceDEFS_H_
-#define __wrappedxshmfenceDEFS_H_
-
-
-#endif // __wrappedxshmfenceDEFS_H_
diff --git a/src/wrapped/generated/wrappedxshmfencetypes.h b/src/wrapped/generated/wrappedxshmfencetypes.h
deleted file mode 100644
index c2b66a6..0000000
--- a/src/wrapped/generated/wrappedxshmfencetypes.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedxshmfenceTYPES_H_
-#define __wrappedxshmfenceTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-
-#define SUPER() ADDED_FUNCTIONS()
-
-#endif // __wrappedxshmfenceTYPES_H_
diff --git a/src/wrapped/generated/wrappedxshmfenceundefs.h b/src/wrapped/generated/wrappedxshmfenceundefs.h
deleted file mode 100644
index 2d63eb6..0000000
--- a/src/wrapped/generated/wrappedxshmfenceundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedxshmfenceUNDEFS_H_
-#define __wrappedxshmfenceUNDEFS_H_
-
-
-#endif // __wrappedxshmfenceUNDEFS_H_
diff --git a/src/wrapped/generated/wrappedxsltdefs.h b/src/wrapped/generated/wrappedxsltdefs.h
deleted file mode 100644
index 334d105..0000000
--- a/src/wrapped/generated/wrappedxsltdefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedxsltDEFS_H_
-#define __wrappedxsltDEFS_H_
-
-
-#endif // __wrappedxsltDEFS_H_
diff --git a/src/wrapped/generated/wrappedxslttypes.h b/src/wrapped/generated/wrappedxslttypes.h
deleted file mode 100644
index ff1a025..0000000
--- a/src/wrapped/generated/wrappedxslttypes.h
+++ /dev/null
@@ -1,21 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedxsltTYPES_H_
-#define __wrappedxsltTYPES_H_
-
-#ifndef LIBNAME
-#error You should only #include this file inside a wrapped*.c file
-#endif
-#ifndef ADDED_FUNCTIONS
-#define ADDED_FUNCTIONS()
-#endif
-
-typedef void (*vFp_t)(void*);
-typedef int64_t (*iFppp_t)(void*, void*, void*);
-
-#define SUPER() ADDED_FUNCTIONS() \
- GO(xsltSetLoaderFunc, vFp_t) \
- GO(xsltRegisterExtModuleFunction, iFppp_t)
-
-#endif // __wrappedxsltTYPES_H_
diff --git a/src/wrapped/generated/wrappedxsltundefs.h b/src/wrapped/generated/wrappedxsltundefs.h
deleted file mode 100644
index 06842c2..0000000
--- a/src/wrapped/generated/wrappedxsltundefs.h
+++ /dev/null
@@ -1,8 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __wrappedxsltUNDEFS_H_
-#define __wrappedxsltUNDEFS_H_
-
-
-#endif // __wrappedxsltUNDEFS_H_
diff --git a/src/wrapped/generated/wrapper.c b/src/wrapped/generated/wrapper.c
deleted file mode 100644
index fe1526e..0000000
--- a/src/wrapped/generated/wrapper.c
+++ /dev/null
@@ -1,6224 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#include <stdio.h>
-#include <stdlib.h>
-#include <stdint.h>
-
-#include "wrapper.h"
-#include "emu/x64emu_private.h"
-#include "emu/x87emu_private.h"
-#include "regs.h"
-#include "x64emu.h"
-
-extern void* my__IO_2_1_stdin_ ;
-extern void* my__IO_2_1_stdout_;
-extern void* my__IO_2_1_stderr_;
-
-static void* io_convert(void* v)
-{
- if(!v)
- return v;
- if(v == my__IO_2_1_stdin_)
- return stdin;
- if(v == my__IO_2_1_stdout_)
- return stdout;
- if(v == my__IO_2_1_stderr_)
- return stderr;
- return v;
-}
-
-#define ST0val ST0.d
-
-int of_convert(int);
-
-typedef void (*vFE_t)(x64emu_t*);
-typedef void (*vFv_t)(void);
-typedef void (*vFi_t)(int64_t);
-typedef void (*vFu_t)(uint64_t);
-typedef void (*vFU_t)(uint64_t);
-typedef void (*vFf_t)(float);
-typedef void (*vFd_t)(double);
-typedef void (*vFl_t)(intptr_t);
-typedef void (*vFL_t)(uintptr_t);
-typedef void (*vFp_t)(void*);
-typedef void (*vFS_t)(void*);
-typedef int8_t (*cFv_t)(void);
-typedef int8_t (*cFi_t)(int64_t);
-typedef int8_t (*cFu_t)(uint64_t);
-typedef int8_t (*cFf_t)(float);
-typedef int8_t (*cFp_t)(void*);
-typedef int16_t (*wFp_t)(void*);
-typedef int64_t (*iFE_t)(x64emu_t*);
-typedef int64_t (*iFv_t)(void);
-typedef int64_t (*iFw_t)(int16_t);
-typedef int64_t (*iFi_t)(int64_t);
-typedef int64_t (*iFI_t)(int64_t);
-typedef int64_t (*iFC_t)(uint8_t);
-typedef int64_t (*iFW_t)(uint16_t);
-typedef int64_t (*iFu_t)(uint64_t);
-typedef int64_t (*iFU_t)(uint64_t);
-typedef int64_t (*iFf_t)(float);
-typedef int64_t (*iFd_t)(double);
-typedef int64_t (*iFD_t)(long double);
-typedef int64_t (*iFl_t)(intptr_t);
-typedef int64_t (*iFL_t)(uintptr_t);
-typedef int64_t (*iFp_t)(void*);
-typedef int64_t (*iFO_t)(int32_t);
-typedef int64_t (*iFS_t)(void*);
-typedef int64_t (*IFv_t)(void);
-typedef int64_t (*IFi_t)(int64_t);
-typedef int64_t (*IFI_t)(int64_t);
-typedef int64_t (*IFf_t)(float);
-typedef int64_t (*IFd_t)(double);
-typedef int64_t (*IFp_t)(void*);
-typedef uint8_t (*CFC_t)(uint8_t);
-typedef uint8_t (*CFp_t)(void*);
-typedef uint16_t (*WFi_t)(int64_t);
-typedef uint16_t (*WFW_t)(uint16_t);
-typedef uint16_t (*WFp_t)(void*);
-typedef uint64_t (*uFv_t)(void);
-typedef uint64_t (*uFi_t)(int64_t);
-typedef uint64_t (*uFu_t)(uint64_t);
-typedef uint64_t (*uFd_t)(double);
-typedef uint64_t (*uFl_t)(intptr_t);
-typedef uint64_t (*uFL_t)(uintptr_t);
-typedef uint64_t (*uFp_t)(void*);
-typedef uint64_t (*UFv_t)(void);
-typedef uint64_t (*UFu_t)(uint64_t);
-typedef uint64_t (*UFp_t)(void*);
-typedef uint64_t (*UFV_t)(void*);
-typedef float (*fFi_t)(int64_t);
-typedef float (*fFf_t)(float);
-typedef float (*fFp_t)(void*);
-typedef double (*dFv_t)(void);
-typedef double (*dFi_t)(int64_t);
-typedef double (*dFu_t)(uint64_t);
-typedef double (*dFd_t)(double);
-typedef double (*dFp_t)(void*);
-typedef intptr_t (*lFE_t)(x64emu_t*);
-typedef intptr_t (*lFv_t)(void);
-typedef intptr_t (*lFi_t)(int64_t);
-typedef intptr_t (*lFu_t)(uint64_t);
-typedef intptr_t (*lFl_t)(intptr_t);
-typedef intptr_t (*lFp_t)(void*);
-typedef uintptr_t (*LFv_t)(void);
-typedef uintptr_t (*LFu_t)(uint64_t);
-typedef uintptr_t (*LFL_t)(uintptr_t);
-typedef uintptr_t (*LFp_t)(void*);
-typedef void* (*pFE_t)(x64emu_t*);
-typedef void* (*pFv_t)(void);
-typedef void* (*pFw_t)(int16_t);
-typedef void* (*pFi_t)(int64_t);
-typedef void* (*pFI_t)(int64_t);
-typedef void* (*pFC_t)(uint8_t);
-typedef void* (*pFW_t)(uint16_t);
-typedef void* (*pFu_t)(uint64_t);
-typedef void* (*pFU_t)(uint64_t);
-typedef void* (*pFd_t)(double);
-typedef void* (*pFl_t)(intptr_t);
-typedef void* (*pFL_t)(uintptr_t);
-typedef void* (*pFp_t)(void*);
-typedef void* (*pFV_t)(void*);
-typedef unsigned __int128 (*HFi_t)(int64_t);
-typedef unsigned __int128 (*HFp_t)(void*);
-typedef void (*vWp_t)(void*);
-typedef int64_t (*iWp_t)(void*);
-typedef uint64_t (*uWp_t)(void*);
-typedef float (*fWp_t)(void*);
-typedef void (*vFEi_t)(x64emu_t*, int64_t);
-typedef void (*vFEp_t)(x64emu_t*, void*);
-typedef void (*vFii_t)(int64_t, int64_t);
-typedef void (*vFiI_t)(int64_t, int64_t);
-typedef void (*vFiu_t)(int64_t, uint64_t);
-typedef void (*vFiU_t)(int64_t, uint64_t);
-typedef void (*vFif_t)(int64_t, float);
-typedef void (*vFid_t)(int64_t, double);
-typedef void (*vFip_t)(int64_t, void*);
-typedef void (*vFWW_t)(uint16_t, uint16_t);
-typedef void (*vFWp_t)(uint16_t, void*);
-typedef void (*vFui_t)(uint64_t, int64_t);
-typedef void (*vFuu_t)(uint64_t, uint64_t);
-typedef void (*vFuU_t)(uint64_t, uint64_t);
-typedef void (*vFuf_t)(uint64_t, float);
-typedef void (*vFud_t)(uint64_t, double);
-typedef void (*vFul_t)(uint64_t, intptr_t);
-typedef void (*vFup_t)(uint64_t, void*);
-typedef void (*vFUi_t)(uint64_t, int64_t);
-typedef void (*vFfi_t)(float, int64_t);
-typedef void (*vFff_t)(float, float);
-typedef void (*vFfp_t)(float, void*);
-typedef void (*vFdd_t)(double, double);
-typedef void (*vFlp_t)(intptr_t, void*);
-typedef void (*vFLL_t)(uintptr_t, uintptr_t);
-typedef void (*vFLp_t)(uintptr_t, void*);
-typedef void (*vFpc_t)(void*, int8_t);
-typedef void (*vFpi_t)(void*, int64_t);
-typedef void (*vFpI_t)(void*, int64_t);
-typedef void (*vFpC_t)(void*, uint8_t);
-typedef void (*vFpW_t)(void*, uint16_t);
-typedef void (*vFpu_t)(void*, uint64_t);
-typedef void (*vFpU_t)(void*, uint64_t);
-typedef void (*vFpf_t)(void*, float);
-typedef void (*vFpd_t)(void*, double);
-typedef void (*vFpl_t)(void*, intptr_t);
-typedef void (*vFpL_t)(void*, uintptr_t);
-typedef void (*vFpp_t)(void*, void*);
-typedef void (*vFpS_t)(void*, void*);
-typedef void (*vFSi_t)(void*, int64_t);
-typedef int8_t (*cFpp_t)(void*, void*);
-typedef int64_t (*iFEi_t)(x64emu_t*, int64_t);
-typedef int64_t (*iFEp_t)(x64emu_t*, void*);
-typedef int64_t (*iFwp_t)(int16_t, void*);
-typedef int64_t (*iFii_t)(int64_t, int64_t);
-typedef int64_t (*iFiu_t)(int64_t, uint64_t);
-typedef int64_t (*iFil_t)(int64_t, intptr_t);
-typedef int64_t (*iFiL_t)(int64_t, uintptr_t);
-typedef int64_t (*iFip_t)(int64_t, void*);
-typedef int64_t (*iFiS_t)(int64_t, void*);
-typedef int64_t (*iFIi_t)(int64_t, int64_t);
-typedef int64_t (*iFui_t)(uint64_t, int64_t);
-typedef int64_t (*iFuu_t)(uint64_t, uint64_t);
-typedef int64_t (*iFuU_t)(uint64_t, uint64_t);
-typedef int64_t (*iFuL_t)(uint64_t, uintptr_t);
-typedef int64_t (*iFup_t)(uint64_t, void*);
-typedef int64_t (*iFUp_t)(uint64_t, void*);
-typedef int64_t (*iFli_t)(intptr_t, int64_t);
-typedef int64_t (*iFlp_t)(intptr_t, void*);
-typedef int64_t (*iFLu_t)(uintptr_t, uint64_t);
-typedef int64_t (*iFLL_t)(uintptr_t, uintptr_t);
-typedef int64_t (*iFLp_t)(uintptr_t, void*);
-typedef int64_t (*iFpw_t)(void*, int16_t);
-typedef int64_t (*iFpi_t)(void*, int64_t);
-typedef int64_t (*iFpI_t)(void*, int64_t);
-typedef int64_t (*iFpC_t)(void*, uint8_t);
-typedef int64_t (*iFpW_t)(void*, uint16_t);
-typedef int64_t (*iFpu_t)(void*, uint64_t);
-typedef int64_t (*iFpU_t)(void*, uint64_t);
-typedef int64_t (*iFpf_t)(void*, float);
-typedef int64_t (*iFpd_t)(void*, double);
-typedef int64_t (*iFpl_t)(void*, intptr_t);
-typedef int64_t (*iFpL_t)(void*, uintptr_t);
-typedef int64_t (*iFpp_t)(void*, void*);
-typedef int64_t (*iFpO_t)(void*, int32_t);
-typedef int64_t (*iFSi_t)(void*, int64_t);
-typedef int64_t (*IFEp_t)(x64emu_t*, void*);
-typedef int64_t (*IFII_t)(int64_t, int64_t);
-typedef int64_t (*IFpi_t)(void*, int64_t);
-typedef int64_t (*IFpu_t)(void*, uint64_t);
-typedef int64_t (*IFpd_t)(void*, double);
-typedef uint8_t (*CFip_t)(int64_t, void*);
-typedef uint8_t (*CFui_t)(uint64_t, int64_t);
-typedef uint8_t (*CFpi_t)(void*, int64_t);
-typedef uint8_t (*CFpu_t)(void*, uint64_t);
-typedef uint8_t (*CFpp_t)(void*, void*);
-typedef uint16_t (*WFpp_t)(void*, void*);
-typedef uint64_t (*uFEp_t)(x64emu_t*, void*);
-typedef uint64_t (*uFii_t)(int64_t, int64_t);
-typedef uint64_t (*uFiu_t)(int64_t, uint64_t);
-typedef uint64_t (*uFip_t)(int64_t, void*);
-typedef uint64_t (*uFui_t)(uint64_t, int64_t);
-typedef uint64_t (*uFuu_t)(uint64_t, uint64_t);
-typedef uint64_t (*uFup_t)(uint64_t, void*);
-typedef uint64_t (*uFUp_t)(uint64_t, void*);
-typedef uint64_t (*uFpw_t)(void*, int16_t);
-typedef uint64_t (*uFpi_t)(void*, int64_t);
-typedef uint64_t (*uFpu_t)(void*, uint64_t);
-typedef uint64_t (*uFpU_t)(void*, uint64_t);
-typedef uint64_t (*uFpf_t)(void*, float);
-typedef uint64_t (*uFpL_t)(void*, uintptr_t);
-typedef uint64_t (*uFpp_t)(void*, void*);
-typedef uint64_t (*UFEp_t)(x64emu_t*, void*);
-typedef uint64_t (*UFuu_t)(uint64_t, uint64_t);
-typedef uint64_t (*UFUp_t)(uint64_t, void*);
-typedef uint64_t (*UFpi_t)(void*, int64_t);
-typedef uint64_t (*UFpp_t)(void*, void*);
-typedef float (*fFEp_t)(x64emu_t*, void*);
-typedef float (*fFif_t)(int64_t, float);
-typedef float (*fFfi_t)(float, int64_t);
-typedef float (*fFff_t)(float, float);
-typedef float (*fFfD_t)(float, long double);
-typedef float (*fFfl_t)(float, intptr_t);
-typedef float (*fFfp_t)(float, void*);
-typedef float (*fFpp_t)(void*, void*);
-typedef double (*dFid_t)(int64_t, double);
-typedef double (*dFdi_t)(double, int64_t);
-typedef double (*dFdd_t)(double, double);
-typedef double (*dFdD_t)(double, long double);
-typedef double (*dFdl_t)(double, intptr_t);
-typedef double (*dFdp_t)(double, void*);
-typedef double (*dFll_t)(intptr_t, intptr_t);
-typedef double (*dFpi_t)(void*, int64_t);
-typedef double (*dFpd_t)(void*, double);
-typedef double (*dFpp_t)(void*, void*);
-typedef long double (*DFDi_t)(long double, int64_t);
-typedef long double (*DFDD_t)(long double, long double);
-typedef long double (*DFDp_t)(long double, void*);
-typedef long double (*DFpp_t)(void*, void*);
-typedef intptr_t (*lFii_t)(int64_t, int64_t);
-typedef intptr_t (*lFll_t)(intptr_t, intptr_t);
-typedef intptr_t (*lFpi_t)(void*, int64_t);
-typedef intptr_t (*lFpl_t)(void*, intptr_t);
-typedef intptr_t (*lFpp_t)(void*, void*);
-typedef uintptr_t (*LFEL_t)(x64emu_t*, uintptr_t);
-typedef uintptr_t (*LFii_t)(int64_t, int64_t);
-typedef uintptr_t (*LFuu_t)(uint64_t, uint64_t);
-typedef uintptr_t (*LFLi_t)(uintptr_t, int64_t);
-typedef uintptr_t (*LFLL_t)(uintptr_t, uintptr_t);
-typedef uintptr_t (*LFpi_t)(void*, int64_t);
-typedef uintptr_t (*LFpL_t)(void*, uintptr_t);
-typedef uintptr_t (*LFpp_t)(void*, void*);
-typedef void* (*pFEi_t)(x64emu_t*, int64_t);
-typedef void* (*pFEL_t)(x64emu_t*, uintptr_t);
-typedef void* (*pFEp_t)(x64emu_t*, void*);
-typedef void* (*pFii_t)(int64_t, int64_t);
-typedef void* (*pFiI_t)(int64_t, int64_t);
-typedef void* (*pFiu_t)(int64_t, uint64_t);
-typedef void* (*pFip_t)(int64_t, void*);
-typedef void* (*pFiV_t)(int64_t, void*);
-typedef void* (*pFII_t)(int64_t, int64_t);
-typedef void* (*pFui_t)(uint64_t, int64_t);
-typedef void* (*pFuC_t)(uint64_t, uint8_t);
-typedef void* (*pFuu_t)(uint64_t, uint64_t);
-typedef void* (*pFup_t)(uint64_t, void*);
-typedef void* (*pFUi_t)(uint64_t, int64_t);
-typedef void* (*pFUU_t)(uint64_t, uint64_t);
-typedef void* (*pFdi_t)(double, int64_t);
-typedef void* (*pFdd_t)(double, double);
-typedef void* (*pFlp_t)(intptr_t, void*);
-typedef void* (*pFLu_t)(uintptr_t, uint64_t);
-typedef void* (*pFLL_t)(uintptr_t, uintptr_t);
-typedef void* (*pFLp_t)(uintptr_t, void*);
-typedef void* (*pFpi_t)(void*, int64_t);
-typedef void* (*pFpC_t)(void*, uint8_t);
-typedef void* (*pFpu_t)(void*, uint64_t);
-typedef void* (*pFpU_t)(void*, uint64_t);
-typedef void* (*pFpd_t)(void*, double);
-typedef void* (*pFpl_t)(void*, intptr_t);
-typedef void* (*pFpL_t)(void*, uintptr_t);
-typedef void* (*pFpp_t)(void*, void*);
-typedef void* (*pFpV_t)(void*, void*);
-typedef void* (*pFSi_t)(void*, int64_t);
-typedef unsigned __int128 (*HFII_t)(int64_t, int64_t);
-typedef unsigned __int128 (*HFll_t)(intptr_t, intptr_t);
-typedef unsigned __int128 (*HFpi_t)(void*, int64_t);
-typedef int64_t (*iWpi_t)(void*, int64_t);
-typedef int64_t (*iWpu_t)(void*, uint64_t);
-typedef int64_t (*iWpf_t)(void*, float);
-typedef int64_t (*iWpp_t)(void*, void*);
-typedef uint64_t (*uWpu_t)(void*, uint64_t);
-typedef void* (*pWEp_t)(x64emu_t*, void*);
-typedef void* (*pWpu_t)(void*, uint64_t);
-typedef void (*vFEpi_t)(x64emu_t*, void*, int64_t);
-typedef void (*vFEpu_t)(x64emu_t*, void*, uint64_t);
-typedef void (*vFEpp_t)(x64emu_t*, void*, void*);
-typedef void (*vFEpV_t)(x64emu_t*, void*, void*);
-typedef void (*vFEpA_t)(x64emu_t*, void*, void*);
-typedef void (*vFiii_t)(int64_t, int64_t, int64_t);
-typedef void (*vFiiu_t)(int64_t, int64_t, uint64_t);
-typedef void (*vFiif_t)(int64_t, int64_t, float);
-typedef void (*vFiip_t)(int64_t, int64_t, void*);
-typedef void (*vFiII_t)(int64_t, int64_t, int64_t);
-typedef void (*vFiui_t)(int64_t, uint64_t, int64_t);
-typedef void (*vFiuu_t)(int64_t, uint64_t, uint64_t);
-typedef void (*vFiuU_t)(int64_t, uint64_t, uint64_t);
-typedef void (*vFiup_t)(int64_t, uint64_t, void*);
-typedef void (*vFiUU_t)(int64_t, uint64_t, uint64_t);
-typedef void (*vFiff_t)(int64_t, float, float);
-typedef void (*vFidd_t)(int64_t, double, double);
-typedef void (*vFill_t)(int64_t, intptr_t, intptr_t);
-typedef void (*vFilp_t)(int64_t, intptr_t, void*);
-typedef void (*vFipi_t)(int64_t, void*, int64_t);
-typedef void (*vFipu_t)(int64_t, void*, uint64_t);
-typedef void (*vFipp_t)(int64_t, void*, void*);
-typedef void (*vFuii_t)(uint64_t, int64_t, int64_t);
-typedef void (*vFuiI_t)(uint64_t, int64_t, int64_t);
-typedef void (*vFuiu_t)(uint64_t, int64_t, uint64_t);
-typedef void (*vFuiU_t)(uint64_t, int64_t, uint64_t);
-typedef void (*vFuif_t)(uint64_t, int64_t, float);
-typedef void (*vFuid_t)(uint64_t, int64_t, double);
-typedef void (*vFuip_t)(uint64_t, int64_t, void*);
-typedef void (*vFuui_t)(uint64_t, uint64_t, int64_t);
-typedef void (*vFuuu_t)(uint64_t, uint64_t, uint64_t);
-typedef void (*vFuuU_t)(uint64_t, uint64_t, uint64_t);
-typedef void (*vFuuf_t)(uint64_t, uint64_t, float);
-typedef void (*vFuud_t)(uint64_t, uint64_t, double);
-typedef void (*vFuup_t)(uint64_t, uint64_t, void*);
-typedef void (*vFuff_t)(uint64_t, float, float);
-typedef void (*vFufp_t)(uint64_t, float, void*);
-typedef void (*vFudd_t)(uint64_t, double, double);
-typedef void (*vFull_t)(uint64_t, intptr_t, intptr_t);
-typedef void (*vFulp_t)(uint64_t, intptr_t, void*);
-typedef void (*vFuLp_t)(uint64_t, uintptr_t, void*);
-typedef void (*vFupu_t)(uint64_t, void*, uint64_t);
-typedef void (*vFupp_t)(uint64_t, void*, void*);
-typedef void (*vFfff_t)(float, float, float);
-typedef void (*vFfpp_t)(float, void*, void*);
-typedef void (*vFddd_t)(double, double, double);
-typedef void (*vFdpp_t)(double, void*, void*);
-typedef void (*vFlip_t)(intptr_t, int64_t, void*);
-typedef void (*vFlll_t)(intptr_t, intptr_t, intptr_t);
-typedef void (*vFllp_t)(intptr_t, intptr_t, void*);
-typedef void (*vFlpp_t)(intptr_t, void*, void*);
-typedef void (*vFLup_t)(uintptr_t, uint64_t, void*);
-typedef void (*vFLpL_t)(uintptr_t, void*, uintptr_t);
-typedef void (*vFLpp_t)(uintptr_t, void*, void*);
-typedef void (*vFpii_t)(void*, int64_t, int64_t);
-typedef void (*vFpiI_t)(void*, int64_t, int64_t);
-typedef void (*vFpiC_t)(void*, int64_t, uint8_t);
-typedef void (*vFpiu_t)(void*, int64_t, uint64_t);
-typedef void (*vFpif_t)(void*, int64_t, float);
-typedef void (*vFpid_t)(void*, int64_t, double);
-typedef void (*vFpip_t)(void*, int64_t, void*);
-typedef void (*vFpui_t)(void*, uint64_t, int64_t);
-typedef void (*vFpuI_t)(void*, uint64_t, int64_t);
-typedef void (*vFpuW_t)(void*, uint64_t, uint16_t);
-typedef void (*vFpuu_t)(void*, uint64_t, uint64_t);
-typedef void (*vFpuU_t)(void*, uint64_t, uint64_t);
-typedef void (*vFpup_t)(void*, uint64_t, void*);
-typedef void (*vFpUi_t)(void*, uint64_t, int64_t);
-typedef void (*vFpUu_t)(void*, uint64_t, uint64_t);
-typedef void (*vFpUU_t)(void*, uint64_t, uint64_t);
-typedef void (*vFpUf_t)(void*, uint64_t, float);
-typedef void (*vFpUp_t)(void*, uint64_t, void*);
-typedef void (*vFpff_t)(void*, float, float);
-typedef void (*vFpdd_t)(void*, double, double);
-typedef void (*vFpll_t)(void*, intptr_t, intptr_t);
-typedef void (*vFplp_t)(void*, intptr_t, void*);
-typedef void (*vFpLi_t)(void*, uintptr_t, int64_t);
-typedef void (*vFpLu_t)(void*, uintptr_t, uint64_t);
-typedef void (*vFpLL_t)(void*, uintptr_t, uintptr_t);
-typedef void (*vFpLp_t)(void*, uintptr_t, void*);
-typedef void (*vFppi_t)(void*, void*, int64_t);
-typedef void (*vFppu_t)(void*, void*, uint64_t);
-typedef void (*vFppU_t)(void*, void*, uint64_t);
-typedef void (*vFppd_t)(void*, void*, double);
-typedef void (*vFppl_t)(void*, void*, intptr_t);
-typedef void (*vFppL_t)(void*, void*, uintptr_t);
-typedef void (*vFppp_t)(void*, void*, void*);
-typedef int64_t (*iFEiw_t)(x64emu_t*, int64_t, int16_t);
-typedef int64_t (*iFEip_t)(x64emu_t*, int64_t, void*);
-typedef int64_t (*iFEWW_t)(x64emu_t*, uint16_t, uint16_t);
-typedef int64_t (*iFEup_t)(x64emu_t*, uint64_t, void*);
-typedef int64_t (*iFEUU_t)(x64emu_t*, uint64_t, uint64_t);
-typedef int64_t (*iFELp_t)(x64emu_t*, uintptr_t, void*);
-typedef int64_t (*iFEpi_t)(x64emu_t*, void*, int64_t);
-typedef int64_t (*iFEpU_t)(x64emu_t*, void*, uint64_t);
-typedef int64_t (*iFEpL_t)(x64emu_t*, void*, uintptr_t);
-typedef int64_t (*iFEpp_t)(x64emu_t*, void*, void*);
-typedef int64_t (*iFEpV_t)(x64emu_t*, void*, void*);
-typedef int64_t (*iFEpA_t)(x64emu_t*, void*, void*);
-typedef int64_t (*iFESp_t)(x64emu_t*, void*, void*);
-typedef int64_t (*iFwww_t)(int16_t, int16_t, int16_t);
-typedef int64_t (*iFwpp_t)(int16_t, void*, void*);
-typedef int64_t (*iFiwC_t)(int64_t, int16_t, uint8_t);
-typedef int64_t (*iFiii_t)(int64_t, int64_t, int64_t);
-typedef int64_t (*iFiiu_t)(int64_t, int64_t, uint64_t);
-typedef int64_t (*iFiil_t)(int64_t, int64_t, intptr_t);
-typedef int64_t (*iFiip_t)(int64_t, int64_t, void*);
-typedef int64_t (*iFiiO_t)(int64_t, int64_t, int32_t);
-typedef int64_t (*iFiuu_t)(int64_t, uint64_t, uint64_t);
-typedef int64_t (*iFill_t)(int64_t, intptr_t, intptr_t);
-typedef int64_t (*iFiLi_t)(int64_t, uintptr_t, int64_t);
-typedef int64_t (*iFiLp_t)(int64_t, uintptr_t, void*);
-typedef int64_t (*iFiLN_t)(int64_t, uintptr_t, ...);
-typedef int64_t (*iFipi_t)(int64_t, void*, int64_t);
-typedef int64_t (*iFipu_t)(int64_t, void*, uint64_t);
-typedef int64_t (*iFipL_t)(int64_t, void*, uintptr_t);
-typedef int64_t (*iFipp_t)(int64_t, void*, void*);
-typedef int64_t (*iFipO_t)(int64_t, void*, int32_t);
-typedef int64_t (*iFCiW_t)(uint8_t, int64_t, uint16_t);
-typedef int64_t (*iFuwp_t)(uint64_t, int16_t, void*);
-typedef int64_t (*iFuip_t)(uint64_t, int64_t, void*);
-typedef int64_t (*iFuui_t)(uint64_t, uint64_t, int64_t);
-typedef int64_t (*iFuuu_t)(uint64_t, uint64_t, uint64_t);
-typedef int64_t (*iFuup_t)(uint64_t, uint64_t, void*);
-typedef int64_t (*iFuUu_t)(uint64_t, uint64_t, uint64_t);
-typedef int64_t (*iFuff_t)(uint64_t, float, float);
-typedef int64_t (*iFuLL_t)(uint64_t, uintptr_t, uintptr_t);
-typedef int64_t (*iFuLp_t)(uint64_t, uintptr_t, void*);
-typedef int64_t (*iFupL_t)(uint64_t, void*, uintptr_t);
-typedef int64_t (*iFupp_t)(uint64_t, void*, void*);
-typedef int64_t (*iFfff_t)(float, float, float);
-typedef int64_t (*iFlip_t)(intptr_t, int64_t, void*);
-typedef int64_t (*iFLip_t)(uintptr_t, int64_t, void*);
-typedef int64_t (*iFLLi_t)(uintptr_t, uintptr_t, int64_t);
-typedef int64_t (*iFLpp_t)(uintptr_t, void*, void*);
-typedef int64_t (*iFpwp_t)(void*, int16_t, void*);
-typedef int64_t (*iFpii_t)(void*, int64_t, int64_t);
-typedef int64_t (*iFpiI_t)(void*, int64_t, int64_t);
-typedef int64_t (*iFpiu_t)(void*, int64_t, uint64_t);
-typedef int64_t (*iFpiU_t)(void*, int64_t, uint64_t);
-typedef int64_t (*iFpiL_t)(void*, int64_t, uintptr_t);
-typedef int64_t (*iFpip_t)(void*, int64_t, void*);
-typedef int64_t (*iFpIi_t)(void*, int64_t, int64_t);
-typedef int64_t (*iFpII_t)(void*, int64_t, int64_t);
-typedef int64_t (*iFpCp_t)(void*, uint8_t, void*);
-typedef int64_t (*iFpui_t)(void*, uint64_t, int64_t);
-typedef int64_t (*iFpuu_t)(void*, uint64_t, uint64_t);
-typedef int64_t (*iFpuU_t)(void*, uint64_t, uint64_t);
-typedef int64_t (*iFpuL_t)(void*, uint64_t, uintptr_t);
-typedef int64_t (*iFpup_t)(void*, uint64_t, void*);
-typedef int64_t (*iFpUi_t)(void*, uint64_t, int64_t);
-typedef int64_t (*iFpUu_t)(void*, uint64_t, uint64_t);
-typedef int64_t (*iFpUU_t)(void*, uint64_t, uint64_t);
-typedef int64_t (*iFpUp_t)(void*, uint64_t, void*);
-typedef int64_t (*iFpfu_t)(void*, float, uint64_t);
-typedef int64_t (*iFpff_t)(void*, float, float);
-typedef int64_t (*iFpdd_t)(void*, double, double);
-typedef int64_t (*iFpli_t)(void*, intptr_t, int64_t);
-typedef int64_t (*iFpll_t)(void*, intptr_t, intptr_t);
-typedef int64_t (*iFplp_t)(void*, intptr_t, void*);
-typedef int64_t (*iFpLi_t)(void*, uintptr_t, int64_t);
-typedef int64_t (*iFpLu_t)(void*, uintptr_t, uint64_t);
-typedef int64_t (*iFpLL_t)(void*, uintptr_t, uintptr_t);
-typedef int64_t (*iFpLp_t)(void*, uintptr_t, void*);
-typedef int64_t (*iFppi_t)(void*, void*, int64_t);
-typedef int64_t (*iFppI_t)(void*, void*, int64_t);
-typedef int64_t (*iFppC_t)(void*, void*, uint8_t);
-typedef int64_t (*iFppW_t)(void*, void*, uint16_t);
-typedef int64_t (*iFppu_t)(void*, void*, uint64_t);
-typedef int64_t (*iFppU_t)(void*, void*, uint64_t);
-typedef int64_t (*iFppd_t)(void*, void*, double);
-typedef int64_t (*iFppl_t)(void*, void*, intptr_t);
-typedef int64_t (*iFppL_t)(void*, void*, uintptr_t);
-typedef int64_t (*iFppp_t)(void*, void*, void*);
-typedef int64_t (*iFpOu_t)(void*, int32_t, uint64_t);
-typedef int64_t (*iFpOM_t)(void*, int32_t, ...);
-typedef int64_t (*iFSpL_t)(void*, void*, uintptr_t);
-typedef int64_t (*IFiIi_t)(int64_t, int64_t, int64_t);
-typedef int64_t (*IFpIi_t)(void*, int64_t, int64_t);
-typedef int64_t (*IFppi_t)(void*, void*, int64_t);
-typedef int64_t (*IFppI_t)(void*, void*, int64_t);
-typedef int64_t (*IFppu_t)(void*, void*, uint64_t);
-typedef int64_t (*IFSIi_t)(void*, int64_t, int64_t);
-typedef uint64_t (*uFEpW_t)(x64emu_t*, void*, uint16_t);
-typedef uint64_t (*uFEpu_t)(x64emu_t*, void*, uint64_t);
-typedef uint64_t (*uFEpU_t)(x64emu_t*, void*, uint64_t);
-typedef uint64_t (*uFEpp_t)(x64emu_t*, void*, void*);
-typedef uint64_t (*uFipu_t)(int64_t, void*, uint64_t);
-typedef uint64_t (*uFuip_t)(uint64_t, int64_t, void*);
-typedef uint64_t (*uFuuu_t)(uint64_t, uint64_t, uint64_t);
-typedef uint64_t (*uFuup_t)(uint64_t, uint64_t, void*);
-typedef uint64_t (*uFufp_t)(uint64_t, float, void*);
-typedef uint64_t (*uFupu_t)(uint64_t, void*, uint64_t);
-typedef uint64_t (*uFupp_t)(uint64_t, void*, void*);
-typedef uint64_t (*uFpii_t)(void*, int64_t, int64_t);
-typedef uint64_t (*uFpip_t)(void*, int64_t, void*);
-typedef uint64_t (*uFpCi_t)(void*, uint8_t, int64_t);
-typedef uint64_t (*uFpWi_t)(void*, uint16_t, int64_t);
-typedef uint64_t (*uFpWu_t)(void*, uint16_t, uint64_t);
-typedef uint64_t (*uFpWf_t)(void*, uint16_t, float);
-typedef uint64_t (*uFpWp_t)(void*, uint16_t, void*);
-typedef uint64_t (*uFpui_t)(void*, uint64_t, int64_t);
-typedef uint64_t (*uFpuC_t)(void*, uint64_t, uint8_t);
-typedef uint64_t (*uFpuu_t)(void*, uint64_t, uint64_t);
-typedef uint64_t (*uFpup_t)(void*, uint64_t, void*);
-typedef uint64_t (*uFpfu_t)(void*, float, uint64_t);
-typedef uint64_t (*uFpLp_t)(void*, uintptr_t, void*);
-typedef uint64_t (*uFppi_t)(void*, void*, int64_t);
-typedef uint64_t (*uFppu_t)(void*, void*, uint64_t);
-typedef uint64_t (*uFppp_t)(void*, void*, void*);
-typedef uint64_t (*UFUUU_t)(uint64_t, uint64_t, uint64_t);
-typedef uint64_t (*UFpiU_t)(void*, int64_t, uint64_t);
-typedef uint64_t (*UFppi_t)(void*, void*, int64_t);
-typedef uint64_t (*UFppu_t)(void*, void*, uint64_t);
-typedef float (*fFull_t)(uint64_t, intptr_t, intptr_t);
-typedef float (*fFfff_t)(float, float, float);
-typedef float (*fFffp_t)(float, float, void*);
-typedef float (*fFppi_t)(void*, void*, int64_t);
-typedef float (*fFppL_t)(void*, void*, uintptr_t);
-typedef float (*fFppp_t)(void*, void*, void*);
-typedef double (*dFddd_t)(double, double, double);
-typedef double (*dFddp_t)(double, double, void*);
-typedef double (*dFpdd_t)(void*, double, double);
-typedef double (*dFppi_t)(void*, void*, int64_t);
-typedef double (*dFppp_t)(void*, void*, void*);
-typedef long double (*DFppi_t)(void*, void*, int64_t);
-typedef long double (*DFppp_t)(void*, void*, void*);
-typedef intptr_t (*lFili_t)(int64_t, intptr_t, int64_t);
-typedef intptr_t (*lFilL_t)(int64_t, intptr_t, uintptr_t);
-typedef intptr_t (*lFipi_t)(int64_t, void*, int64_t);
-typedef intptr_t (*lFipL_t)(int64_t, void*, uintptr_t);
-typedef intptr_t (*lFlll_t)(intptr_t, intptr_t, intptr_t);
-typedef intptr_t (*lFpli_t)(void*, intptr_t, int64_t);
-typedef intptr_t (*lFpLu_t)(void*, uintptr_t, uint64_t);
-typedef intptr_t (*lFpLp_t)(void*, uintptr_t, void*);
-typedef intptr_t (*lFppi_t)(void*, void*, int64_t);
-typedef intptr_t (*lFppL_t)(void*, void*, uintptr_t);
-typedef intptr_t (*lFppp_t)(void*, void*, void*);
-typedef intptr_t (*lFSpl_t)(void*, void*, intptr_t);
-typedef uintptr_t (*LFEpA_t)(x64emu_t*, void*, void*);
-typedef uintptr_t (*LFipL_t)(int64_t, void*, uintptr_t);
-typedef uintptr_t (*LFLLl_t)(uintptr_t, uintptr_t, intptr_t);
-typedef uintptr_t (*LFLpu_t)(uintptr_t, void*, uint64_t);
-typedef uintptr_t (*LFLpL_t)(uintptr_t, void*, uintptr_t);
-typedef uintptr_t (*LFpii_t)(void*, int64_t, int64_t);
-typedef uintptr_t (*LFpip_t)(void*, int64_t, void*);
-typedef uintptr_t (*LFpLi_t)(void*, uintptr_t, int64_t);
-typedef uintptr_t (*LFpLp_t)(void*, uintptr_t, void*);
-typedef uintptr_t (*LFppi_t)(void*, void*, int64_t);
-typedef uintptr_t (*LFppL_t)(void*, void*, uintptr_t);
-typedef uintptr_t (*LFppp_t)(void*, void*, void*);
-typedef uintptr_t (*LFSpL_t)(void*, void*, uintptr_t);
-typedef void* (*pFEip_t)(x64emu_t*, int64_t, void*);
-typedef void* (*pFEiV_t)(x64emu_t*, int64_t, void*);
-typedef void* (*pFEup_t)(x64emu_t*, uint64_t, void*);
-typedef void* (*pFEuV_t)(x64emu_t*, uint64_t, void*);
-typedef void* (*pFEpi_t)(x64emu_t*, void*, int64_t);
-typedef void* (*pFEpu_t)(x64emu_t*, void*, uint64_t);
-typedef void* (*pFEpp_t)(x64emu_t*, void*, void*);
-typedef void* (*pFEpV_t)(x64emu_t*, void*, void*);
-typedef void* (*pFEpA_t)(x64emu_t*, void*, void*);
-typedef void* (*pFiii_t)(int64_t, int64_t, int64_t);
-typedef void* (*pFiiu_t)(int64_t, int64_t, uint64_t);
-typedef void* (*pFiip_t)(int64_t, int64_t, void*);
-typedef void* (*pFiIi_t)(int64_t, int64_t, int64_t);
-typedef void* (*pFiIp_t)(int64_t, int64_t, void*);
-typedef void* (*pFipi_t)(int64_t, void*, int64_t);
-typedef void* (*pFipL_t)(int64_t, void*, uintptr_t);
-typedef void* (*pFipp_t)(int64_t, void*, void*);
-typedef void* (*pFIpi_t)(int64_t, void*, int64_t);
-typedef void* (*pFCiW_t)(uint8_t, int64_t, uint16_t);
-typedef void* (*pFWWW_t)(uint16_t, uint16_t, uint16_t);
-typedef void* (*pFuii_t)(uint64_t, int64_t, int64_t);
-typedef void* (*pFuui_t)(uint64_t, uint64_t, int64_t);
-typedef void* (*pFuuu_t)(uint64_t, uint64_t, uint64_t);
-typedef void* (*pFupi_t)(uint64_t, void*, int64_t);
-typedef void* (*pFupL_t)(uint64_t, void*, uintptr_t);
-typedef void* (*pFUpi_t)(uint64_t, void*, int64_t);
-typedef void* (*pFdip_t)(double, int64_t, void*);
-typedef void* (*pFdUU_t)(double, uint64_t, uint64_t);
-typedef void* (*pFddd_t)(double, double, double);
-typedef void* (*pFDip_t)(long double, int64_t, void*);
-typedef void* (*pFLup_t)(uintptr_t, uint64_t, void*);
-typedef void* (*pFLLp_t)(uintptr_t, uintptr_t, void*);
-typedef void* (*pFpii_t)(void*, int64_t, int64_t);
-typedef void* (*pFpiu_t)(void*, int64_t, uint64_t);
-typedef void* (*pFpid_t)(void*, int64_t, double);
-typedef void* (*pFpil_t)(void*, int64_t, intptr_t);
-typedef void* (*pFpiL_t)(void*, int64_t, uintptr_t);
-typedef void* (*pFpip_t)(void*, int64_t, void*);
-typedef void* (*pFpCC_t)(void*, uint8_t, uint8_t);
-typedef void* (*pFpCu_t)(void*, uint8_t, uint64_t);
-typedef void* (*pFpWW_t)(void*, uint16_t, uint16_t);
-typedef void* (*pFpui_t)(void*, uint64_t, int64_t);
-typedef void* (*pFpuu_t)(void*, uint64_t, uint64_t);
-typedef void* (*pFpuL_t)(void*, uint64_t, uintptr_t);
-typedef void* (*pFpup_t)(void*, uint64_t, void*);
-typedef void* (*pFpUi_t)(void*, uint64_t, int64_t);
-typedef void* (*pFpUp_t)(void*, uint64_t, void*);
-typedef void* (*pFpdu_t)(void*, double, uint64_t);
-typedef void* (*pFplC_t)(void*, intptr_t, uint8_t);
-typedef void* (*pFplu_t)(void*, intptr_t, uint64_t);
-typedef void* (*pFpll_t)(void*, intptr_t, intptr_t);
-typedef void* (*pFplp_t)(void*, intptr_t, void*);
-typedef void* (*pFpLu_t)(void*, uintptr_t, uint64_t);
-typedef void* (*pFpLL_t)(void*, uintptr_t, uintptr_t);
-typedef void* (*pFpLp_t)(void*, uintptr_t, void*);
-typedef void* (*pFppi_t)(void*, void*, int64_t);
-typedef void* (*pFppI_t)(void*, void*, int64_t);
-typedef void* (*pFppC_t)(void*, void*, uint8_t);
-typedef void* (*pFppu_t)(void*, void*, uint64_t);
-typedef void* (*pFppU_t)(void*, void*, uint64_t);
-typedef void* (*pFppf_t)(void*, void*, float);
-typedef void* (*pFppl_t)(void*, void*, intptr_t);
-typedef void* (*pFppL_t)(void*, void*, uintptr_t);
-typedef void* (*pFppp_t)(void*, void*, void*);
-typedef void* (*pFpOM_t)(void*, int32_t, ...);
-typedef void* (*pFSpl_t)(void*, void*, intptr_t);
-typedef void (*vWpup_t)(void*, uint64_t, void*);
-typedef int64_t (*iWEip_t)(x64emu_t*, int64_t, void*);
-typedef int64_t (*iWEpp_t)(x64emu_t*, void*, void*);
-typedef int64_t (*iWpiu_t)(void*, int64_t, uint64_t);
-typedef int64_t (*iWpip_t)(void*, int64_t, void*);
-typedef int64_t (*iWpui_t)(void*, uint64_t, int64_t);
-typedef int64_t (*iWpuu_t)(void*, uint64_t, uint64_t);
-typedef int64_t (*iWpup_t)(void*, uint64_t, void*);
-typedef int64_t (*iWppu_t)(void*, void*, uint64_t);
-typedef int64_t (*iWppp_t)(void*, void*, void*);
-typedef uint64_t (*uWpui_t)(void*, uint64_t, int64_t);
-typedef uint64_t (*uWpup_t)(void*, uint64_t, void*);
-typedef void (*vFEiip_t)(x64emu_t*, int64_t, int64_t, void*);
-typedef void (*vFEipp_t)(x64emu_t*, int64_t, void*, void*);
-typedef void (*vFEipV_t)(x64emu_t*, int64_t, void*, void*);
-typedef void (*vFEipA_t)(x64emu_t*, int64_t, void*, void*);
-typedef void (*vFELLp_t)(x64emu_t*, uintptr_t, uintptr_t, void*);
-typedef void (*vFEpii_t)(x64emu_t*, void*, int64_t, int64_t);
-typedef void (*vFEpip_t)(x64emu_t*, void*, int64_t, void*);
-typedef void (*vFEpiA_t)(x64emu_t*, void*, int64_t, void*);
-typedef void (*vFEpup_t)(x64emu_t*, void*, uint64_t, void*);
-typedef void (*vFEpUp_t)(x64emu_t*, void*, uint64_t, void*);
-typedef void (*vFEppp_t)(x64emu_t*, void*, void*, void*);
-typedef void (*vFEppV_t)(x64emu_t*, void*, void*, void*);
-typedef void (*vFEppA_t)(x64emu_t*, void*, void*, void*);
-typedef void (*vFiiii_t)(int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFiiip_t)(int64_t, int64_t, int64_t, void*);
-typedef void (*vFiill_t)(int64_t, int64_t, intptr_t, intptr_t);
-typedef void (*vFiIII_t)(int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFiuiu_t)(int64_t, uint64_t, int64_t, uint64_t);
-typedef void (*vFiuip_t)(int64_t, uint64_t, int64_t, void*);
-typedef void (*vFiuuu_t)(int64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFiuup_t)(int64_t, uint64_t, uint64_t, void*);
-typedef void (*vFiulp_t)(int64_t, uint64_t, intptr_t, void*);
-typedef void (*vFiupu_t)(int64_t, uint64_t, void*, uint64_t);
-typedef void (*vFiupV_t)(int64_t, uint64_t, void*, void*);
-typedef void (*vFiUUU_t)(int64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFifff_t)(int64_t, float, float, float);
-typedef void (*vFiddd_t)(int64_t, double, double, double);
-typedef void (*vFilil_t)(int64_t, intptr_t, int64_t, intptr_t);
-typedef void (*vFilip_t)(int64_t, intptr_t, int64_t, void*);
-typedef void (*vFiluU_t)(int64_t, intptr_t, uint64_t, uint64_t);
-typedef void (*vFilpu_t)(int64_t, intptr_t, void*, uint64_t);
-typedef void (*vFilpp_t)(int64_t, intptr_t, void*, void*);
-typedef void (*vFipii_t)(int64_t, void*, int64_t, int64_t);
-typedef void (*vFipup_t)(int64_t, void*, uint64_t, void*);
-typedef void (*vFipll_t)(int64_t, void*, intptr_t, intptr_t);
-typedef void (*vFippi_t)(int64_t, void*, void*, int64_t);
-typedef void (*vFippu_t)(int64_t, void*, void*, uint64_t);
-typedef void (*vFippp_t)(int64_t, void*, void*, void*);
-typedef void (*vFuiii_t)(uint64_t, int64_t, int64_t, int64_t);
-typedef void (*vFuiiu_t)(uint64_t, int64_t, int64_t, uint64_t);
-typedef void (*vFuiip_t)(uint64_t, int64_t, int64_t, void*);
-typedef void (*vFuiII_t)(uint64_t, int64_t, int64_t, int64_t);
-typedef void (*vFuiui_t)(uint64_t, int64_t, uint64_t, int64_t);
-typedef void (*vFuiuu_t)(uint64_t, int64_t, uint64_t, uint64_t);
-typedef void (*vFuiup_t)(uint64_t, int64_t, uint64_t, void*);
-typedef void (*vFuiUU_t)(uint64_t, int64_t, uint64_t, uint64_t);
-typedef void (*vFuifi_t)(uint64_t, int64_t, float, int64_t);
-typedef void (*vFuiff_t)(uint64_t, int64_t, float, float);
-typedef void (*vFuidd_t)(uint64_t, int64_t, double, double);
-typedef void (*vFuill_t)(uint64_t, int64_t, intptr_t, intptr_t);
-typedef void (*vFuilp_t)(uint64_t, int64_t, intptr_t, void*);
-typedef void (*vFuipi_t)(uint64_t, int64_t, void*, int64_t);
-typedef void (*vFuipu_t)(uint64_t, int64_t, void*, uint64_t);
-typedef void (*vFuipp_t)(uint64_t, int64_t, void*, void*);
-typedef void (*vFuuii_t)(uint64_t, uint64_t, int64_t, int64_t);
-typedef void (*vFuuiu_t)(uint64_t, uint64_t, int64_t, uint64_t);
-typedef void (*vFuuil_t)(uint64_t, uint64_t, int64_t, intptr_t);
-typedef void (*vFuuip_t)(uint64_t, uint64_t, int64_t, void*);
-typedef void (*vFuuui_t)(uint64_t, uint64_t, uint64_t, int64_t);
-typedef void (*vFuuuu_t)(uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFuuuf_t)(uint64_t, uint64_t, uint64_t, float);
-typedef void (*vFuuud_t)(uint64_t, uint64_t, uint64_t, double);
-typedef void (*vFuuup_t)(uint64_t, uint64_t, uint64_t, void*);
-typedef void (*vFuulp_t)(uint64_t, uint64_t, intptr_t, void*);
-typedef void (*vFuupi_t)(uint64_t, uint64_t, void*, int64_t);
-typedef void (*vFuupp_t)(uint64_t, uint64_t, void*, void*);
-typedef void (*vFuUii_t)(uint64_t, uint64_t, int64_t, int64_t);
-typedef void (*vFuUip_t)(uint64_t, uint64_t, int64_t, void*);
-typedef void (*vFufff_t)(uint64_t, float, float, float);
-typedef void (*vFuddd_t)(uint64_t, double, double, double);
-typedef void (*vFulil_t)(uint64_t, intptr_t, int64_t, intptr_t);
-typedef void (*vFulip_t)(uint64_t, intptr_t, int64_t, void*);
-typedef void (*vFuluU_t)(uint64_t, intptr_t, uint64_t, uint64_t);
-typedef void (*vFullp_t)(uint64_t, intptr_t, intptr_t, void*);
-typedef void (*vFulpi_t)(uint64_t, intptr_t, void*, int64_t);
-typedef void (*vFulpu_t)(uint64_t, intptr_t, void*, uint64_t);
-typedef void (*vFulpp_t)(uint64_t, intptr_t, void*, void*);
-typedef void (*vFupii_t)(uint64_t, void*, int64_t, int64_t);
-typedef void (*vFuppi_t)(uint64_t, void*, void*, int64_t);
-typedef void (*vFUUpi_t)(uint64_t, uint64_t, void*, int64_t);
-typedef void (*vFffff_t)(float, float, float, float);
-typedef void (*vFdddd_t)(double, double, double, double);
-typedef void (*vFllll_t)(intptr_t, intptr_t, intptr_t, intptr_t);
-typedef void (*vFpiii_t)(void*, int64_t, int64_t, int64_t);
-typedef void (*vFpiiu_t)(void*, int64_t, int64_t, uint64_t);
-typedef void (*vFpiip_t)(void*, int64_t, int64_t, void*);
-typedef void (*vFpiuu_t)(void*, int64_t, uint64_t, uint64_t);
-typedef void (*vFpiuL_t)(void*, int64_t, uint64_t, uintptr_t);
-typedef void (*vFpiup_t)(void*, int64_t, uint64_t, void*);
-typedef void (*vFpiUu_t)(void*, int64_t, uint64_t, uint64_t);
-typedef void (*vFpiUU_t)(void*, int64_t, uint64_t, uint64_t);
-typedef void (*vFpifi_t)(void*, int64_t, float, int64_t);
-typedef void (*vFpipi_t)(void*, int64_t, void*, int64_t);
-typedef void (*vFpipp_t)(void*, int64_t, void*, void*);
-typedef void (*vFpIdi_t)(void*, int64_t, double, int64_t);
-typedef void (*vFpCiW_t)(void*, uint8_t, int64_t, uint16_t);
-typedef void (*vFpuip_t)(void*, uint64_t, int64_t, void*);
-typedef void (*vFpuui_t)(void*, uint64_t, uint64_t, int64_t);
-typedef void (*vFpuuu_t)(void*, uint64_t, uint64_t, uint64_t);
-typedef void (*vFpuup_t)(void*, uint64_t, uint64_t, void*);
-typedef void (*vFpudd_t)(void*, uint64_t, double, double);
-typedef void (*vFpupp_t)(void*, uint64_t, void*, void*);
-typedef void (*vFpUui_t)(void*, uint64_t, uint64_t, int64_t);
-typedef void (*vFpUuu_t)(void*, uint64_t, uint64_t, uint64_t);
-typedef void (*vFpUup_t)(void*, uint64_t, uint64_t, void*);
-typedef void (*vFpUUi_t)(void*, uint64_t, uint64_t, int64_t);
-typedef void (*vFpUUu_t)(void*, uint64_t, uint64_t, uint64_t);
-typedef void (*vFpUUp_t)(void*, uint64_t, uint64_t, void*);
-typedef void (*vFpUpp_t)(void*, uint64_t, void*, void*);
-typedef void (*vFpfff_t)(void*, float, float, float);
-typedef void (*vFpdii_t)(void*, double, int64_t, int64_t);
-typedef void (*vFpdip_t)(void*, double, int64_t, void*);
-typedef void (*vFpddi_t)(void*, double, double, int64_t);
-typedef void (*vFpddd_t)(void*, double, double, double);
-typedef void (*vFplpp_t)(void*, intptr_t, void*, void*);
-typedef void (*vFpLLL_t)(void*, uintptr_t, uintptr_t, uintptr_t);
-typedef void (*vFppii_t)(void*, void*, int64_t, int64_t);
-typedef void (*vFppiu_t)(void*, void*, int64_t, uint64_t);
-typedef void (*vFppid_t)(void*, void*, int64_t, double);
-typedef void (*vFppil_t)(void*, void*, int64_t, intptr_t);
-typedef void (*vFppiL_t)(void*, void*, int64_t, uintptr_t);
-typedef void (*vFppip_t)(void*, void*, int64_t, void*);
-typedef void (*vFppui_t)(void*, void*, uint64_t, int64_t);
-typedef void (*vFppuu_t)(void*, void*, uint64_t, uint64_t);
-typedef void (*vFppup_t)(void*, void*, uint64_t, void*);
-typedef void (*vFppfi_t)(void*, void*, float, int64_t);
-typedef void (*vFppdu_t)(void*, void*, double, uint64_t);
-typedef void (*vFppdd_t)(void*, void*, double, double);
-typedef void (*vFppdp_t)(void*, void*, double, void*);
-typedef void (*vFpplp_t)(void*, void*, intptr_t, void*);
-typedef void (*vFppLp_t)(void*, void*, uintptr_t, void*);
-typedef void (*vFpppi_t)(void*, void*, void*, int64_t);
-typedef void (*vFpppI_t)(void*, void*, void*, int64_t);
-typedef void (*vFpppu_t)(void*, void*, void*, uint64_t);
-typedef void (*vFpppU_t)(void*, void*, void*, uint64_t);
-typedef void (*vFpppd_t)(void*, void*, void*, double);
-typedef void (*vFpppL_t)(void*, void*, void*, uintptr_t);
-typedef void (*vFpppp_t)(void*, void*, void*, void*);
-typedef int8_t (*cFpiii_t)(void*, int64_t, int64_t, int64_t);
-typedef int64_t (*iFEiip_t)(x64emu_t*, int64_t, int64_t, void*);
-typedef int64_t (*iFEiiN_t)(x64emu_t*, int64_t, int64_t, ...);
-typedef int64_t (*iFEipp_t)(x64emu_t*, int64_t, void*, void*);
-typedef int64_t (*iFEipV_t)(x64emu_t*, int64_t, void*, void*);
-typedef int64_t (*iFEupu_t)(x64emu_t*, uint64_t, void*, uint64_t);
-typedef int64_t (*iFEupp_t)(x64emu_t*, uint64_t, void*, void*);
-typedef int64_t (*iFEpii_t)(x64emu_t*, void*, int64_t, int64_t);
-typedef int64_t (*iFEpip_t)(x64emu_t*, void*, int64_t, void*);
-typedef int64_t (*iFEpiV_t)(x64emu_t*, void*, int64_t, void*);
-typedef int64_t (*iFEpiA_t)(x64emu_t*, void*, int64_t, void*);
-typedef int64_t (*iFEpui_t)(x64emu_t*, void*, uint64_t, int64_t);
-typedef int64_t (*iFEpup_t)(x64emu_t*, void*, uint64_t, void*);
-typedef int64_t (*iFEpUi_t)(x64emu_t*, void*, uint64_t, int64_t);
-typedef int64_t (*iFEpUp_t)(x64emu_t*, void*, uint64_t, void*);
-typedef int64_t (*iFEpLi_t)(x64emu_t*, void*, uintptr_t, int64_t);
-typedef int64_t (*iFEpLp_t)(x64emu_t*, void*, uintptr_t, void*);
-typedef int64_t (*iFEppi_t)(x64emu_t*, void*, void*, int64_t);
-typedef int64_t (*iFEppd_t)(x64emu_t*, void*, void*, double);
-typedef int64_t (*iFEppL_t)(x64emu_t*, void*, void*, uintptr_t);
-typedef int64_t (*iFEppp_t)(x64emu_t*, void*, void*, void*);
-typedef int64_t (*iFEppV_t)(x64emu_t*, void*, void*, void*);
-typedef int64_t (*iFEppA_t)(x64emu_t*, void*, void*, void*);
-typedef int64_t (*iFEpOu_t)(x64emu_t*, void*, int32_t, uint64_t);
-typedef int64_t (*iFwwww_t)(int16_t, int16_t, int16_t, int16_t);
-typedef int64_t (*iFwppp_t)(int16_t, void*, void*, void*);
-typedef int64_t (*iFiiii_t)(int64_t, int64_t, int64_t, int64_t);
-typedef int64_t (*iFiiiu_t)(int64_t, int64_t, int64_t, uint64_t);
-typedef int64_t (*iFiiip_t)(int64_t, int64_t, int64_t, void*);
-typedef int64_t (*iFiiiN_t)(int64_t, int64_t, int64_t, ...);
-typedef int64_t (*iFiiui_t)(int64_t, int64_t, uint64_t, int64_t);
-typedef int64_t (*iFiiup_t)(int64_t, int64_t, uint64_t, void*);
-typedef int64_t (*iFiill_t)(int64_t, int64_t, intptr_t, intptr_t);
-typedef int64_t (*iFiipi_t)(int64_t, int64_t, void*, int64_t);
-typedef int64_t (*iFiipp_t)(int64_t, int64_t, void*, void*);
-typedef int64_t (*iFiuwp_t)(int64_t, uint64_t, int16_t, void*);
-typedef int64_t (*iFiuii_t)(int64_t, uint64_t, int64_t, int64_t);
-typedef int64_t (*iFiuup_t)(int64_t, uint64_t, uint64_t, void*);
-typedef int64_t (*iFiupp_t)(int64_t, uint64_t, void*, void*);
-typedef int64_t (*iFilli_t)(int64_t, intptr_t, intptr_t, int64_t);
-typedef int64_t (*iFillu_t)(int64_t, intptr_t, intptr_t, uint64_t);
-typedef int64_t (*iFipii_t)(int64_t, void*, int64_t, int64_t);
-typedef int64_t (*iFipip_t)(int64_t, void*, int64_t, void*);
-typedef int64_t (*iFipui_t)(int64_t, void*, uint64_t, int64_t);
-typedef int64_t (*iFipuu_t)(int64_t, void*, uint64_t, uint64_t);
-typedef int64_t (*iFipup_t)(int64_t, void*, uint64_t, void*);
-typedef int64_t (*iFipLi_t)(int64_t, void*, uintptr_t, int64_t);
-typedef int64_t (*iFipLu_t)(int64_t, void*, uintptr_t, uint64_t);
-typedef int64_t (*iFipLp_t)(int64_t, void*, uintptr_t, void*);
-typedef int64_t (*iFippi_t)(int64_t, void*, void*, int64_t);
-typedef int64_t (*iFippu_t)(int64_t, void*, void*, uint64_t);
-typedef int64_t (*iFippL_t)(int64_t, void*, void*, uintptr_t);
-typedef int64_t (*iFippp_t)(int64_t, void*, void*, void*);
-typedef int64_t (*iFipON_t)(int64_t, void*, int32_t, ...);
-typedef int64_t (*iFuipu_t)(uint64_t, int64_t, void*, uint64_t);
-typedef int64_t (*iFuipp_t)(uint64_t, int64_t, void*, void*);
-typedef int64_t (*iFuuff_t)(uint64_t, uint64_t, float, float);
-typedef int64_t (*iFuupi_t)(uint64_t, uint64_t, void*, int64_t);
-typedef int64_t (*iFupLp_t)(uint64_t, void*, uintptr_t, void*);
-typedef int64_t (*iFuppi_t)(uint64_t, void*, void*, int64_t);
-typedef int64_t (*iFuppp_t)(uint64_t, void*, void*, void*);
-typedef int64_t (*iFLLiW_t)(uintptr_t, uintptr_t, int64_t, uint16_t);
-typedef int64_t (*iFpwww_t)(void*, int16_t, int16_t, int16_t);
-typedef int64_t (*iFpwpp_t)(void*, int16_t, void*, void*);
-typedef int64_t (*iFpiii_t)(void*, int64_t, int64_t, int64_t);
-typedef int64_t (*iFpiiI_t)(void*, int64_t, int64_t, int64_t);
-typedef int64_t (*iFpiiu_t)(void*, int64_t, int64_t, uint64_t);
-typedef int64_t (*iFpiid_t)(void*, int64_t, int64_t, double);
-typedef int64_t (*iFpiiL_t)(void*, int64_t, int64_t, uintptr_t);
-typedef int64_t (*iFpiip_t)(void*, int64_t, int64_t, void*);
-typedef int64_t (*iFpiuu_t)(void*, int64_t, uint64_t, uint64_t);
-typedef int64_t (*iFpiuL_t)(void*, int64_t, uint64_t, uintptr_t);
-typedef int64_t (*iFpiup_t)(void*, int64_t, uint64_t, void*);
-typedef int64_t (*iFpiUp_t)(void*, int64_t, uint64_t, void*);
-typedef int64_t (*iFpild_t)(void*, int64_t, intptr_t, double);
-typedef int64_t (*iFpipi_t)(void*, int64_t, void*, int64_t);
-typedef int64_t (*iFpipC_t)(void*, int64_t, void*, uint8_t);
-typedef int64_t (*iFpipu_t)(void*, int64_t, void*, uint64_t);
-typedef int64_t (*iFpipL_t)(void*, int64_t, void*, uintptr_t);
-typedef int64_t (*iFpipp_t)(void*, int64_t, void*, void*);
-typedef int64_t (*iFpipV_t)(void*, int64_t, void*, void*);
-typedef int64_t (*iFpIip_t)(void*, int64_t, int64_t, void*);
-typedef int64_t (*iFpCCC_t)(void*, uint8_t, uint8_t, uint8_t);
-typedef int64_t (*iFpCpi_t)(void*, uint8_t, void*, int64_t);
-typedef int64_t (*iFpWWu_t)(void*, uint16_t, uint16_t, uint64_t);
-typedef int64_t (*iFpuwp_t)(void*, uint64_t, int16_t, void*);
-typedef int64_t (*iFpuiL_t)(void*, uint64_t, int64_t, uintptr_t);
-typedef int64_t (*iFpuip_t)(void*, uint64_t, int64_t, void*);
-typedef int64_t (*iFpuui_t)(void*, uint64_t, uint64_t, int64_t);
-typedef int64_t (*iFpuuu_t)(void*, uint64_t, uint64_t, uint64_t);
-typedef int64_t (*iFpuup_t)(void*, uint64_t, uint64_t, void*);
-typedef int64_t (*iFpuUp_t)(void*, uint64_t, uint64_t, void*);
-typedef int64_t (*iFpuLL_t)(void*, uint64_t, uintptr_t, uintptr_t);
-typedef int64_t (*iFpuLp_t)(void*, uint64_t, uintptr_t, void*);
-typedef int64_t (*iFpupi_t)(void*, uint64_t, void*, int64_t);
-typedef int64_t (*iFpupu_t)(void*, uint64_t, void*, uint64_t);
-typedef int64_t (*iFpupU_t)(void*, uint64_t, void*, uint64_t);
-typedef int64_t (*iFpupL_t)(void*, uint64_t, void*, uintptr_t);
-typedef int64_t (*iFpupp_t)(void*, uint64_t, void*, void*);
-typedef int64_t (*iFpupV_t)(void*, uint64_t, void*, void*);
-typedef int64_t (*iFpUup_t)(void*, uint64_t, uint64_t, void*);
-typedef int64_t (*iFpUUU_t)(void*, uint64_t, uint64_t, uint64_t);
-typedef int64_t (*iFpULp_t)(void*, uint64_t, uintptr_t, void*);
-typedef int64_t (*iFpUpp_t)(void*, uint64_t, void*, void*);
-typedef int64_t (*iFplii_t)(void*, intptr_t, int64_t, int64_t);
-typedef int64_t (*iFplip_t)(void*, intptr_t, int64_t, void*);
-typedef int64_t (*iFpLii_t)(void*, uintptr_t, int64_t, int64_t);
-typedef int64_t (*iFpLip_t)(void*, uintptr_t, int64_t, void*);
-typedef int64_t (*iFpLLu_t)(void*, uintptr_t, uintptr_t, uint64_t);
-typedef int64_t (*iFpLpi_t)(void*, uintptr_t, void*, int64_t);
-typedef int64_t (*iFpLpf_t)(void*, uintptr_t, void*, float);
-typedef int64_t (*iFpLpd_t)(void*, uintptr_t, void*, double);
-typedef int64_t (*iFpLpD_t)(void*, uintptr_t, void*, long double);
-typedef int64_t (*iFpLpL_t)(void*, uintptr_t, void*, uintptr_t);
-typedef int64_t (*iFpLpp_t)(void*, uintptr_t, void*, void*);
-typedef int64_t (*iFppii_t)(void*, void*, int64_t, int64_t);
-typedef int64_t (*iFppiu_t)(void*, void*, int64_t, uint64_t);
-typedef int64_t (*iFppiU_t)(void*, void*, int64_t, uint64_t);
-typedef int64_t (*iFppiL_t)(void*, void*, int64_t, uintptr_t);
-typedef int64_t (*iFppip_t)(void*, void*, int64_t, void*);
-typedef int64_t (*iFppIL_t)(void*, void*, int64_t, uintptr_t);
-typedef int64_t (*iFppCC_t)(void*, void*, uint8_t, uint8_t);
-typedef int64_t (*iFppuw_t)(void*, void*, uint64_t, int16_t);
-typedef int64_t (*iFppui_t)(void*, void*, uint64_t, int64_t);
-typedef int64_t (*iFppuu_t)(void*, void*, uint64_t, uint64_t);
-typedef int64_t (*iFppup_t)(void*, void*, uint64_t, void*);
-typedef int64_t (*iFppdp_t)(void*, void*, double, void*);
-typedef int64_t (*iFppll_t)(void*, void*, intptr_t, intptr_t);
-typedef int64_t (*iFpplp_t)(void*, void*, intptr_t, void*);
-typedef int64_t (*iFppLi_t)(void*, void*, uintptr_t, int64_t);
-typedef int64_t (*iFppLL_t)(void*, void*, uintptr_t, uintptr_t);
-typedef int64_t (*iFppLp_t)(void*, void*, uintptr_t, void*);
-typedef int64_t (*iFpppi_t)(void*, void*, void*, int64_t);
-typedef int64_t (*iFpppC_t)(void*, void*, void*, uint8_t);
-typedef int64_t (*iFpppu_t)(void*, void*, void*, uint64_t);
-typedef int64_t (*iFpppU_t)(void*, void*, void*, uint64_t);
-typedef int64_t (*iFpppL_t)(void*, void*, void*, uintptr_t);
-typedef int64_t (*iFpppp_t)(void*, void*, void*, void*);
-typedef int64_t (*IFEpIi_t)(x64emu_t*, void*, int64_t, int64_t);
-typedef int64_t (*IFpIip_t)(void*, int64_t, int64_t, void*);
-typedef int64_t (*IFppii_t)(void*, void*, int64_t, int64_t);
-typedef int64_t (*IFppip_t)(void*, void*, int64_t, void*);
-typedef int64_t (*IFpppp_t)(void*, void*, void*, void*);
-typedef int64_t (*IFSIii_t)(void*, int64_t, int64_t, int64_t);
-typedef uint8_t (*CFpupp_t)(void*, uint64_t, void*, void*);
-typedef uint64_t (*uFEipp_t)(x64emu_t*, int64_t, void*, void*);
-typedef uint64_t (*uFEupp_t)(x64emu_t*, uint64_t, void*, void*);
-typedef uint64_t (*uFEpup_t)(x64emu_t*, void*, uint64_t, void*);
-typedef uint64_t (*uFEppp_t)(x64emu_t*, void*, void*, void*);
-typedef uint64_t (*uFifff_t)(int64_t, float, float, float);
-typedef uint64_t (*uFuuuu_t)(uint64_t, uint64_t, uint64_t, uint64_t);
-typedef uint64_t (*uFpiip_t)(void*, int64_t, int64_t, void*);
-typedef uint64_t (*uFpipu_t)(void*, int64_t, void*, uint64_t);
-typedef uint64_t (*uFpipp_t)(void*, int64_t, void*, void*);
-typedef uint64_t (*uFpCCC_t)(void*, uint8_t, uint8_t, uint8_t);
-typedef uint64_t (*uFpuip_t)(void*, uint64_t, int64_t, void*);
-typedef uint64_t (*uFpuuu_t)(void*, uint64_t, uint64_t, uint64_t);
-typedef uint64_t (*uFpuup_t)(void*, uint64_t, uint64_t, void*);
-typedef uint64_t (*uFpupu_t)(void*, uint64_t, void*, uint64_t);
-typedef uint64_t (*uFppiu_t)(void*, void*, int64_t, uint64_t);
-typedef uint64_t (*uFppLp_t)(void*, void*, uintptr_t, void*);
-typedef uint64_t (*uFpppi_t)(void*, void*, void*, int64_t);
-typedef uint64_t (*uFpppu_t)(void*, void*, void*, uint64_t);
-typedef uint64_t (*uFpppp_t)(void*, void*, void*, void*);
-typedef uint64_t (*UFpipp_t)(void*, int64_t, void*, void*);
-typedef uint64_t (*UFpUui_t)(void*, uint64_t, uint64_t, int64_t);
-typedef uint64_t (*UFppii_t)(void*, void*, int64_t, int64_t);
-typedef uint64_t (*UFppip_t)(void*, void*, int64_t, void*);
-typedef uint64_t (*UFpppp_t)(void*, void*, void*, void*);
-typedef double (*dFpppp_t)(void*, void*, void*, void*);
-typedef intptr_t (*lFEipV_t)(x64emu_t*, int64_t, void*, void*);
-typedef intptr_t (*lFEpip_t)(x64emu_t*, void*, int64_t, void*);
-typedef intptr_t (*lFEppL_t)(x64emu_t*, void*, void*, uintptr_t);
-typedef intptr_t (*lFEppp_t)(x64emu_t*, void*, void*, void*);
-typedef intptr_t (*lFiiLu_t)(int64_t, int64_t, uintptr_t, uint64_t);
-typedef intptr_t (*lFiipL_t)(int64_t, int64_t, void*, uintptr_t);
-typedef intptr_t (*lFipil_t)(int64_t, void*, int64_t, intptr_t);
-typedef intptr_t (*lFipLi_t)(int64_t, void*, uintptr_t, int64_t);
-typedef intptr_t (*lFipLI_t)(int64_t, void*, uintptr_t, int64_t);
-typedef intptr_t (*lFipLu_t)(int64_t, void*, uintptr_t, uint64_t);
-typedef intptr_t (*lFipLl_t)(int64_t, void*, uintptr_t, intptr_t);
-typedef intptr_t (*lFipLL_t)(int64_t, void*, uintptr_t, uintptr_t);
-typedef intptr_t (*lFipLp_t)(int64_t, void*, uintptr_t, void*);
-typedef intptr_t (*lFippL_t)(int64_t, void*, void*, uintptr_t);
-typedef intptr_t (*lFuipp_t)(uint64_t, int64_t, void*, void*);
-typedef intptr_t (*lFpili_t)(void*, int64_t, intptr_t, int64_t);
-typedef intptr_t (*lFpilp_t)(void*, int64_t, intptr_t, void*);
-typedef intptr_t (*lFppii_t)(void*, void*, int64_t, int64_t);
-typedef intptr_t (*lFppip_t)(void*, void*, int64_t, void*);
-typedef intptr_t (*lFpppL_t)(void*, void*, void*, uintptr_t);
-typedef uintptr_t (*LFEppL_t)(x64emu_t*, void*, void*, uintptr_t);
-typedef uintptr_t (*LFEppp_t)(x64emu_t*, void*, void*, void*);
-typedef uintptr_t (*LFippL_t)(int64_t, void*, void*, uintptr_t);
-typedef uintptr_t (*LFippp_t)(int64_t, void*, void*, void*);
-typedef uintptr_t (*LFpuuu_t)(void*, uint64_t, uint64_t, uint64_t);
-typedef uintptr_t (*LFpLCL_t)(void*, uintptr_t, uint8_t, uintptr_t);
-typedef uintptr_t (*LFpLLp_t)(void*, uintptr_t, uintptr_t, void*);
-typedef uintptr_t (*LFpLpL_t)(void*, uintptr_t, void*, uintptr_t);
-typedef uintptr_t (*LFpLpp_t)(void*, uintptr_t, void*, void*);
-typedef uintptr_t (*LFppii_t)(void*, void*, int64_t, int64_t);
-typedef uintptr_t (*LFppip_t)(void*, void*, int64_t, void*);
-typedef uintptr_t (*LFppLL_t)(void*, void*, uintptr_t, uintptr_t);
-typedef uintptr_t (*LFppLp_t)(void*, void*, uintptr_t, void*);
-typedef uintptr_t (*LFpppi_t)(void*, void*, void*, int64_t);
-typedef uintptr_t (*LFpppp_t)(void*, void*, void*, void*);
-typedef void* (*pFEipp_t)(x64emu_t*, int64_t, void*, void*);
-typedef void* (*pFEupp_t)(x64emu_t*, uint64_t, void*, void*);
-typedef void* (*pFELpV_t)(x64emu_t*, uintptr_t, void*, void*);
-typedef void* (*pFELpA_t)(x64emu_t*, uintptr_t, void*, void*);
-typedef void* (*pFEpii_t)(x64emu_t*, void*, int64_t, int64_t);
-typedef void* (*pFEpip_t)(x64emu_t*, void*, int64_t, void*);
-typedef void* (*pFEppi_t)(x64emu_t*, void*, void*, int64_t);
-typedef void* (*pFEppp_t)(x64emu_t*, void*, void*, void*);
-typedef void* (*pFEppV_t)(x64emu_t*, void*, void*, void*);
-typedef void* (*pFiiii_t)(int64_t, int64_t, int64_t, int64_t);
-typedef void* (*pFiiiu_t)(int64_t, int64_t, int64_t, uint64_t);
-typedef void* (*pFiiuu_t)(int64_t, int64_t, uint64_t, uint64_t);
-typedef void* (*pFiiup_t)(int64_t, int64_t, uint64_t, void*);
-typedef void* (*pFiipi_t)(int64_t, int64_t, void*, int64_t);
-typedef void* (*pFiipp_t)(int64_t, int64_t, void*, void*);
-typedef void* (*pFiIIi_t)(int64_t, int64_t, int64_t, int64_t);
-typedef void* (*pFillu_t)(int64_t, intptr_t, intptr_t, uint64_t);
-typedef void* (*pFipii_t)(int64_t, void*, int64_t, int64_t);
-typedef void* (*pFipip_t)(int64_t, void*, int64_t, void*);
-typedef void* (*pFippi_t)(int64_t, void*, void*, int64_t);
-typedef void* (*pFippu_t)(int64_t, void*, void*, uint64_t);
-typedef void* (*pFuiii_t)(uint64_t, int64_t, int64_t, int64_t);
-typedef void* (*pFuuii_t)(uint64_t, uint64_t, int64_t, int64_t);
-typedef void* (*pFulli_t)(uint64_t, intptr_t, intptr_t, int64_t);
-typedef void* (*pFullu_t)(uint64_t, intptr_t, intptr_t, uint64_t);
-typedef void* (*pFffff_t)(float, float, float, float);
-typedef void* (*pFdipp_t)(double, int64_t, void*, void*);
-typedef void* (*pFdddd_t)(double, double, double, double);
-typedef void* (*pFDipp_t)(long double, int64_t, void*, void*);
-typedef void* (*pFlfff_t)(intptr_t, float, float, float);
-typedef void* (*pFLiip_t)(uintptr_t, int64_t, int64_t, void*);
-typedef void* (*pFpiii_t)(void*, int64_t, int64_t, int64_t);
-typedef void* (*pFpiip_t)(void*, int64_t, int64_t, void*);
-typedef void* (*pFpiuu_t)(void*, int64_t, uint64_t, uint64_t);
-typedef void* (*pFpiLL_t)(void*, int64_t, uintptr_t, uintptr_t);
-typedef void* (*pFpipi_t)(void*, int64_t, void*, int64_t);
-typedef void* (*pFpipd_t)(void*, int64_t, void*, double);
-typedef void* (*pFpipp_t)(void*, int64_t, void*, void*);
-typedef void* (*pFpCWp_t)(void*, uint8_t, uint16_t, void*);
-typedef void* (*pFpCuW_t)(void*, uint8_t, uint64_t, uint16_t);
-typedef void* (*pFpCuu_t)(void*, uint8_t, uint64_t, uint64_t);
-typedef void* (*pFpuii_t)(void*, uint64_t, int64_t, int64_t);
-typedef void* (*pFpuip_t)(void*, uint64_t, int64_t, void*);
-typedef void* (*pFpuWp_t)(void*, uint64_t, uint16_t, void*);
-typedef void* (*pFpuuC_t)(void*, uint64_t, uint64_t, uint8_t);
-typedef void* (*pFpuuu_t)(void*, uint64_t, uint64_t, uint64_t);
-typedef void* (*pFpuup_t)(void*, uint64_t, uint64_t, void*);
-typedef void* (*pFpupi_t)(void*, uint64_t, void*, int64_t);
-typedef void* (*pFpupu_t)(void*, uint64_t, void*, uint64_t);
-typedef void* (*pFpdIU_t)(void*, double, int64_t, uint64_t);
-typedef void* (*pFplpl_t)(void*, intptr_t, void*, intptr_t);
-typedef void* (*pFplpp_t)(void*, intptr_t, void*, void*);
-typedef void* (*pFpLip_t)(void*, uintptr_t, int64_t, void*);
-typedef void* (*pFpLLp_t)(void*, uintptr_t, uintptr_t, void*);
-typedef void* (*pFpLpL_t)(void*, uintptr_t, void*, uintptr_t);
-typedef void* (*pFppii_t)(void*, void*, int64_t, int64_t);
-typedef void* (*pFppiu_t)(void*, void*, int64_t, uint64_t);
-typedef void* (*pFppiL_t)(void*, void*, int64_t, uintptr_t);
-typedef void* (*pFppip_t)(void*, void*, int64_t, void*);
-typedef void* (*pFppWW_t)(void*, void*, uint16_t, uint16_t);
-typedef void* (*pFppuW_t)(void*, void*, uint64_t, uint16_t);
-typedef void* (*pFppuu_t)(void*, void*, uint64_t, uint64_t);
-typedef void* (*pFppuL_t)(void*, void*, uint64_t, uintptr_t);
-typedef void* (*pFppup_t)(void*, void*, uint64_t, void*);
-typedef void* (*pFppUU_t)(void*, void*, uint64_t, uint64_t);
-typedef void* (*pFppdd_t)(void*, void*, double, double);
-typedef void* (*pFppll_t)(void*, void*, intptr_t, intptr_t);
-typedef void* (*pFppLL_t)(void*, void*, uintptr_t, uintptr_t);
-typedef void* (*pFppLp_t)(void*, void*, uintptr_t, void*);
-typedef void* (*pFpppi_t)(void*, void*, void*, int64_t);
-typedef void* (*pFpppu_t)(void*, void*, void*, uint64_t);
-typedef void* (*pFpppU_t)(void*, void*, void*, uint64_t);
-typedef void* (*pFpppL_t)(void*, void*, void*, uintptr_t);
-typedef void* (*pFpppp_t)(void*, void*, void*, void*);
-typedef void* (*pFSppi_t)(void*, void*, void*, int64_t);
-typedef void (*vWpiiu_t)(void*, int64_t, int64_t, uint64_t);
-typedef void (*vWpuup_t)(void*, uint64_t, uint64_t, void*);
-typedef int64_t (*iWEpip_t)(x64emu_t*, void*, int64_t, void*);
-typedef int64_t (*iWEpup_t)(x64emu_t*, void*, uint64_t, void*);
-typedef int64_t (*iWEppu_t)(x64emu_t*, void*, void*, uint64_t);
-typedef int64_t (*iWEppp_t)(x64emu_t*, void*, void*, void*);
-typedef int64_t (*iWpiii_t)(void*, int64_t, int64_t, int64_t);
-typedef int64_t (*iWpiuu_t)(void*, int64_t, uint64_t, uint64_t);
-typedef int64_t (*iWpuiu_t)(void*, uint64_t, int64_t, uint64_t);
-typedef int64_t (*iWpuip_t)(void*, uint64_t, int64_t, void*);
-typedef int64_t (*iWpuup_t)(void*, uint64_t, uint64_t, void*);
-typedef int64_t (*iWpupu_t)(void*, uint64_t, void*, uint64_t);
-typedef int64_t (*iWpupp_t)(void*, uint64_t, void*, void*);
-typedef int64_t (*iWppuu_t)(void*, void*, uint64_t, uint64_t);
-typedef int64_t (*iWpppu_t)(void*, void*, void*, uint64_t);
-typedef int64_t (*iWpppp_t)(void*, void*, void*, void*);
-typedef void (*vFEiipV_t)(x64emu_t*, int64_t, int64_t, void*, void*);
-typedef void (*vFEiipA_t)(x64emu_t*, int64_t, int64_t, void*, void*);
-typedef void (*vFEippp_t)(x64emu_t*, int64_t, void*, void*, void*);
-typedef void (*vFEpipV_t)(x64emu_t*, void*, int64_t, void*, void*);
-typedef void (*vFEpipA_t)(x64emu_t*, void*, int64_t, void*, void*);
-typedef void (*vFEpuup_t)(x64emu_t*, void*, uint64_t, uint64_t, void*);
-typedef void (*vFEpuuV_t)(x64emu_t*, void*, uint64_t, uint64_t, void*);
-typedef void (*vFEpupp_t)(x64emu_t*, void*, uint64_t, void*, void*);
-typedef void (*vFEpupA_t)(x64emu_t*, void*, uint64_t, void*, void*);
-typedef void (*vFEpLLp_t)(x64emu_t*, void*, uintptr_t, uintptr_t, void*);
-typedef void (*vFEppip_t)(x64emu_t*, void*, void*, int64_t, void*);
-typedef void (*vFEppiV_t)(x64emu_t*, void*, void*, int64_t, void*);
-typedef void (*vFEppup_t)(x64emu_t*, void*, void*, uint64_t, void*);
-typedef void (*vFEpppi_t)(x64emu_t*, void*, void*, void*, int64_t);
-typedef void (*vFEpppp_t)(x64emu_t*, void*, void*, void*, void*);
-typedef void (*vFiiiii_t)(int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFiiiiu_t)(int64_t, int64_t, int64_t, int64_t, uint64_t);
-typedef void (*vFiiipi_t)(int64_t, int64_t, int64_t, void*, int64_t);
-typedef void (*vFiiuii_t)(int64_t, int64_t, uint64_t, int64_t, int64_t);
-typedef void (*vFiiuup_t)(int64_t, int64_t, uint64_t, uint64_t, void*);
-typedef void (*vFiillu_t)(int64_t, int64_t, intptr_t, intptr_t, uint64_t);
-typedef void (*vFiilll_t)(int64_t, int64_t, intptr_t, intptr_t, intptr_t);
-typedef void (*vFiipii_t)(int64_t, int64_t, void*, int64_t, int64_t);
-typedef void (*vFiipll_t)(int64_t, int64_t, void*, intptr_t, intptr_t);
-typedef void (*vFiIIII_t)(int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFiuiip_t)(int64_t, uint64_t, int64_t, int64_t, void*);
-typedef void (*vFiuipi_t)(int64_t, uint64_t, int64_t, void*, int64_t);
-typedef void (*vFiuuuu_t)(int64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFiulpp_t)(int64_t, uint64_t, intptr_t, void*, void*);
-typedef void (*vFiuppu_t)(int64_t, uint64_t, void*, void*, uint64_t);
-typedef void (*vFiUUUU_t)(int64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFiffff_t)(int64_t, float, float, float, float);
-typedef void (*vFidddd_t)(int64_t, double, double, double, double);
-typedef void (*vFilill_t)(int64_t, intptr_t, int64_t, intptr_t, intptr_t);
-typedef void (*vFilipi_t)(int64_t, intptr_t, int64_t, void*, int64_t);
-typedef void (*vFilipl_t)(int64_t, intptr_t, int64_t, void*, intptr_t);
-typedef void (*vFillpu_t)(int64_t, intptr_t, intptr_t, void*, uint64_t);
-typedef void (*vFipipu_t)(int64_t, void*, int64_t, void*, uint64_t);
-typedef void (*vFipipp_t)(int64_t, void*, int64_t, void*, void*);
-typedef void (*vFipupi_t)(int64_t, void*, uint64_t, void*, int64_t);
-typedef void (*vFiplli_t)(int64_t, void*, intptr_t, intptr_t, int64_t);
-typedef void (*vFiplll_t)(int64_t, void*, intptr_t, intptr_t, intptr_t);
-typedef void (*vFuiiii_t)(uint64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFuiiiu_t)(uint64_t, int64_t, int64_t, int64_t, uint64_t);
-typedef void (*vFuiiip_t)(uint64_t, int64_t, int64_t, int64_t, void*);
-typedef void (*vFuiifi_t)(uint64_t, int64_t, int64_t, float, int64_t);
-typedef void (*vFuiill_t)(uint64_t, int64_t, int64_t, intptr_t, intptr_t);
-typedef void (*vFuiilp_t)(uint64_t, int64_t, int64_t, intptr_t, void*);
-typedef void (*vFuiIII_t)(uint64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFuiuii_t)(uint64_t, int64_t, uint64_t, int64_t, int64_t);
-typedef void (*vFuiuiu_t)(uint64_t, int64_t, uint64_t, int64_t, uint64_t);
-typedef void (*vFuiuip_t)(uint64_t, int64_t, uint64_t, int64_t, void*);
-typedef void (*vFuiuuu_t)(uint64_t, int64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFuiuup_t)(uint64_t, int64_t, uint64_t, uint64_t, void*);
-typedef void (*vFuiull_t)(uint64_t, int64_t, uint64_t, intptr_t, intptr_t);
-typedef void (*vFuiupi_t)(uint64_t, int64_t, uint64_t, void*, int64_t);
-typedef void (*vFuiUUU_t)(uint64_t, int64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFuifff_t)(uint64_t, int64_t, float, float, float);
-typedef void (*vFuiddd_t)(uint64_t, int64_t, double, double, double);
-typedef void (*vFuipii_t)(uint64_t, int64_t, void*, int64_t, int64_t);
-typedef void (*vFuipip_t)(uint64_t, int64_t, void*, int64_t, void*);
-typedef void (*vFuipup_t)(uint64_t, int64_t, void*, uint64_t, void*);
-typedef void (*vFuippp_t)(uint64_t, int64_t, void*, void*, void*);
-typedef void (*vFuuiii_t)(uint64_t, uint64_t, int64_t, int64_t, int64_t);
-typedef void (*vFuuiiu_t)(uint64_t, uint64_t, int64_t, int64_t, uint64_t);
-typedef void (*vFuuiui_t)(uint64_t, uint64_t, int64_t, uint64_t, int64_t);
-typedef void (*vFuuiuu_t)(uint64_t, uint64_t, int64_t, uint64_t, uint64_t);
-typedef void (*vFuuiup_t)(uint64_t, uint64_t, int64_t, uint64_t, void*);
-typedef void (*vFuuipi_t)(uint64_t, uint64_t, int64_t, void*, int64_t);
-typedef void (*vFuuipu_t)(uint64_t, uint64_t, int64_t, void*, uint64_t);
-typedef void (*vFuuipp_t)(uint64_t, uint64_t, int64_t, void*, void*);
-typedef void (*vFuuuii_t)(uint64_t, uint64_t, uint64_t, int64_t, int64_t);
-typedef void (*vFuuuiu_t)(uint64_t, uint64_t, uint64_t, int64_t, uint64_t);
-typedef void (*vFuuuip_t)(uint64_t, uint64_t, uint64_t, int64_t, void*);
-typedef void (*vFuuuui_t)(uint64_t, uint64_t, uint64_t, uint64_t, int64_t);
-typedef void (*vFuuuuu_t)(uint64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFuuuup_t)(uint64_t, uint64_t, uint64_t, uint64_t, void*);
-typedef void (*vFuuull_t)(uint64_t, uint64_t, uint64_t, intptr_t, intptr_t);
-typedef void (*vFuuulp_t)(uint64_t, uint64_t, uint64_t, intptr_t, void*);
-typedef void (*vFuulll_t)(uint64_t, uint64_t, intptr_t, intptr_t, intptr_t);
-typedef void (*vFuullp_t)(uint64_t, uint64_t, intptr_t, intptr_t, void*);
-typedef void (*vFuulpp_t)(uint64_t, uint64_t, intptr_t, void*, void*);
-typedef void (*vFuupii_t)(uint64_t, uint64_t, void*, int64_t, int64_t);
-typedef void (*vFuffff_t)(uint64_t, float, float, float, float);
-typedef void (*vFudddd_t)(uint64_t, double, double, double, double);
-typedef void (*vFulill_t)(uint64_t, intptr_t, int64_t, intptr_t, intptr_t);
-typedef void (*vFullip_t)(uint64_t, intptr_t, intptr_t, int64_t, void*);
-typedef void (*vFullpp_t)(uint64_t, intptr_t, intptr_t, void*, void*);
-typedef void (*vFupupi_t)(uint64_t, void*, uint64_t, void*, int64_t);
-typedef void (*vFuppip_t)(uint64_t, void*, void*, int64_t, void*);
-typedef void (*vFupppp_t)(uint64_t, void*, void*, void*, void*);
-typedef void (*vFUUppp_t)(uint64_t, uint64_t, void*, void*, void*);
-typedef void (*vFfffff_t)(float, float, float, float, float);
-typedef void (*vFddddp_t)(double, double, double, double, void*);
-typedef void (*vFpiiii_t)(void*, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFpiiiI_t)(void*, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFpiiiu_t)(void*, int64_t, int64_t, int64_t, uint64_t);
-typedef void (*vFpiiip_t)(void*, int64_t, int64_t, int64_t, void*);
-typedef void (*vFpiiII_t)(void*, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFpiiff_t)(void*, int64_t, int64_t, float, float);
-typedef void (*vFpiipp_t)(void*, int64_t, int64_t, void*, void*);
-typedef void (*vFpiIiI_t)(void*, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFpiIII_t)(void*, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFpiUUp_t)(void*, int64_t, uint64_t, uint64_t, void*);
-typedef void (*vFpilpp_t)(void*, int64_t, intptr_t, void*, void*);
-typedef void (*vFpipii_t)(void*, int64_t, void*, int64_t, int64_t);
-typedef void (*vFpipiu_t)(void*, int64_t, void*, int64_t, uint64_t);
-typedef void (*vFpuiip_t)(void*, uint64_t, int64_t, int64_t, void*);
-typedef void (*vFpuipp_t)(void*, uint64_t, int64_t, void*, void*);
-typedef void (*vFpuuuu_t)(void*, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFpuuup_t)(void*, uint64_t, uint64_t, uint64_t, void*);
-typedef void (*vFpuupp_t)(void*, uint64_t, uint64_t, void*, void*);
-typedef void (*vFpuUUu_t)(void*, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFpuddd_t)(void*, uint64_t, double, double, double);
-typedef void (*vFpupup_t)(void*, uint64_t, void*, uint64_t, void*);
-typedef void (*vFpUuiu_t)(void*, uint64_t, uint64_t, int64_t, uint64_t);
-typedef void (*vFpUUuu_t)(void*, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFpUUup_t)(void*, uint64_t, uint64_t, uint64_t, void*);
-typedef void (*vFpUUUu_t)(void*, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFpUUUp_t)(void*, uint64_t, uint64_t, uint64_t, void*);
-typedef void (*vFpUppp_t)(void*, uint64_t, void*, void*, void*);
-typedef void (*vFpffff_t)(void*, float, float, float, float);
-typedef void (*vFpdiII_t)(void*, double, int64_t, int64_t, int64_t);
-typedef void (*vFpddii_t)(void*, double, double, int64_t, int64_t);
-typedef void (*vFpdddd_t)(void*, double, double, double, double);
-typedef void (*vFpddpp_t)(void*, double, double, void*, void*);
-typedef void (*vFpliil_t)(void*, intptr_t, int64_t, int64_t, intptr_t);
-typedef void (*vFplppp_t)(void*, intptr_t, void*, void*, void*);
-typedef void (*vFpLLpp_t)(void*, uintptr_t, uintptr_t, void*, void*);
-typedef void (*vFppiii_t)(void*, void*, int64_t, int64_t, int64_t);
-typedef void (*vFppiiu_t)(void*, void*, int64_t, int64_t, uint64_t);
-typedef void (*vFppiip_t)(void*, void*, int64_t, int64_t, void*);
-typedef void (*vFppiup_t)(void*, void*, int64_t, uint64_t, void*);
-typedef void (*vFppiff_t)(void*, void*, int64_t, float, float);
-typedef void (*vFppipi_t)(void*, void*, int64_t, void*, int64_t);
-typedef void (*vFppipp_t)(void*, void*, int64_t, void*, void*);
-typedef void (*vFppWui_t)(void*, void*, uint16_t, uint64_t, int64_t);
-typedef void (*vFppuui_t)(void*, void*, uint64_t, uint64_t, int64_t);
-typedef void (*vFppuuu_t)(void*, void*, uint64_t, uint64_t, uint64_t);
-typedef void (*vFppuup_t)(void*, void*, uint64_t, uint64_t, void*);
-typedef void (*vFppupi_t)(void*, void*, uint64_t, void*, int64_t);
-typedef void (*vFppupp_t)(void*, void*, uint64_t, void*, void*);
-typedef void (*vFppddp_t)(void*, void*, double, double, void*);
-typedef void (*vFpppii_t)(void*, void*, void*, int64_t, int64_t);
-typedef void (*vFpppip_t)(void*, void*, void*, int64_t, void*);
-typedef void (*vFpppuu_t)(void*, void*, void*, uint64_t, uint64_t);
-typedef void (*vFpppup_t)(void*, void*, void*, uint64_t, void*);
-typedef void (*vFpppdd_t)(void*, void*, void*, double, double);
-typedef void (*vFppppi_t)(void*, void*, void*, void*, int64_t);
-typedef void (*vFppppu_t)(void*, void*, void*, void*, uint64_t);
-typedef void (*vFppppL_t)(void*, void*, void*, void*, uintptr_t);
-typedef void (*vFppppp_t)(void*, void*, void*, void*, void*);
-typedef int64_t (*iFEiipp_t)(x64emu_t*, int64_t, int64_t, void*, void*);
-typedef int64_t (*iFEiipV_t)(x64emu_t*, int64_t, int64_t, void*, void*);
-typedef int64_t (*iFEippi_t)(x64emu_t*, int64_t, void*, void*, int64_t);
-typedef int64_t (*iFEippL_t)(x64emu_t*, int64_t, void*, void*, uintptr_t);
-typedef int64_t (*iFEippp_t)(x64emu_t*, int64_t, void*, void*, void*);
-typedef int64_t (*iFEpiii_t)(x64emu_t*, void*, int64_t, int64_t, int64_t);
-typedef int64_t (*iFEpipi_t)(x64emu_t*, void*, int64_t, void*, int64_t);
-typedef int64_t (*iFEpipp_t)(x64emu_t*, void*, int64_t, void*, void*);
-typedef int64_t (*iFEpipV_t)(x64emu_t*, void*, int64_t, void*, void*);
-typedef int64_t (*iFEpipA_t)(x64emu_t*, void*, int64_t, void*, void*);
-typedef int64_t (*iFEpUup_t)(x64emu_t*, void*, uint64_t, uint64_t, void*);
-typedef int64_t (*iFEpLpp_t)(x64emu_t*, void*, uintptr_t, void*, void*);
-typedef int64_t (*iFEpLpV_t)(x64emu_t*, void*, uintptr_t, void*, void*);
-typedef int64_t (*iFEpLpA_t)(x64emu_t*, void*, uintptr_t, void*, void*);
-typedef int64_t (*iFEppii_t)(x64emu_t*, void*, void*, int64_t, int64_t);
-typedef int64_t (*iFEppip_t)(x64emu_t*, void*, void*, int64_t, void*);
-typedef int64_t (*iFEppiV_t)(x64emu_t*, void*, void*, int64_t, void*);
-typedef int64_t (*iFEppiA_t)(x64emu_t*, void*, void*, int64_t, void*);
-typedef int64_t (*iFEpplp_t)(x64emu_t*, void*, void*, intptr_t, void*);
-typedef int64_t (*iFEpppi_t)(x64emu_t*, void*, void*, void*, int64_t);
-typedef int64_t (*iFEpppL_t)(x64emu_t*, void*, void*, void*, uintptr_t);
-typedef int64_t (*iFEpppp_t)(x64emu_t*, void*, void*, void*, void*);
-typedef int64_t (*iFEpppV_t)(x64emu_t*, void*, void*, void*, void*);
-typedef int64_t (*iFiiipu_t)(int64_t, int64_t, int64_t, void*, uint64_t);
-typedef int64_t (*iFiiipp_t)(int64_t, int64_t, int64_t, void*, void*);
-typedef int64_t (*iFiiupp_t)(int64_t, int64_t, uint64_t, void*, void*);
-typedef int64_t (*iFiipup_t)(int64_t, int64_t, void*, uint64_t, void*);
-typedef int64_t (*iFiuLip_t)(int64_t, uint64_t, uintptr_t, int64_t, void*);
-typedef int64_t (*iFipiii_t)(int64_t, void*, int64_t, int64_t, int64_t);
-typedef int64_t (*iFipiup_t)(int64_t, void*, int64_t, uint64_t, void*);
-typedef int64_t (*iFipipi_t)(int64_t, void*, int64_t, void*, int64_t);
-typedef int64_t (*iFipipu_t)(int64_t, void*, int64_t, void*, uint64_t);
-typedef int64_t (*iFipuip_t)(int64_t, void*, uint64_t, int64_t, void*);
-typedef int64_t (*iFipuui_t)(int64_t, void*, uint64_t, uint64_t, int64_t);
-typedef int64_t (*iFipLup_t)(int64_t, void*, uintptr_t, uint64_t, void*);
-typedef int64_t (*iFippip_t)(int64_t, void*, void*, int64_t, void*);
-typedef int64_t (*iFippLi_t)(int64_t, void*, void*, uintptr_t, int64_t);
-typedef int64_t (*iFippLp_t)(int64_t, void*, void*, uintptr_t, void*);
-typedef int64_t (*iFipppi_t)(int64_t, void*, void*, void*, int64_t);
-typedef int64_t (*iFipppp_t)(int64_t, void*, void*, void*, void*);
-typedef int64_t (*iFuppLp_t)(uint64_t, void*, void*, uintptr_t, void*);
-typedef int64_t (*iFpwwww_t)(void*, int16_t, int16_t, int16_t, int16_t);
-typedef int64_t (*iFpwppp_t)(void*, int16_t, void*, void*, void*);
-typedef int64_t (*iFpiiii_t)(void*, int64_t, int64_t, int64_t, int64_t);
-typedef int64_t (*iFpiiiu_t)(void*, int64_t, int64_t, int64_t, uint64_t);
-typedef int64_t (*iFpiiiL_t)(void*, int64_t, int64_t, int64_t, uintptr_t);
-typedef int64_t (*iFpiiip_t)(void*, int64_t, int64_t, int64_t, void*);
-typedef int64_t (*iFpiiui_t)(void*, int64_t, int64_t, uint64_t, int64_t);
-typedef int64_t (*iFpiiuu_t)(void*, int64_t, int64_t, uint64_t, uint64_t);
-typedef int64_t (*iFpiipi_t)(void*, int64_t, int64_t, void*, int64_t);
-typedef int64_t (*iFpiipp_t)(void*, int64_t, int64_t, void*, void*);
-typedef int64_t (*iFpiIip_t)(void*, int64_t, int64_t, int64_t, void*);
-typedef int64_t (*iFpiuwp_t)(void*, int64_t, uint64_t, int16_t, void*);
-typedef int64_t (*iFpiUUU_t)(void*, int64_t, uint64_t, uint64_t, uint64_t);
-typedef int64_t (*iFpipii_t)(void*, int64_t, void*, int64_t, int64_t);
-typedef int64_t (*iFpipiu_t)(void*, int64_t, void*, int64_t, uint64_t);
-typedef int64_t (*iFpipiL_t)(void*, int64_t, void*, int64_t, uintptr_t);
-typedef int64_t (*iFpipip_t)(void*, int64_t, void*, int64_t, void*);
-typedef int64_t (*iFpippi_t)(void*, int64_t, void*, void*, int64_t);
-typedef int64_t (*iFpippW_t)(void*, int64_t, void*, void*, uint16_t);
-typedef int64_t (*iFpippp_t)(void*, int64_t, void*, void*, void*);
-typedef int64_t (*iFpCCCC_t)(void*, uint8_t, uint8_t, uint8_t, uint8_t);
-typedef int64_t (*iFpuill_t)(void*, uint64_t, int64_t, intptr_t, intptr_t);
-typedef int64_t (*iFpuipi_t)(void*, uint64_t, int64_t, void*, int64_t);
-typedef int64_t (*iFpuuip_t)(void*, uint64_t, uint64_t, int64_t, void*);
-typedef int64_t (*iFpuuui_t)(void*, uint64_t, uint64_t, uint64_t, int64_t);
-typedef int64_t (*iFpuuup_t)(void*, uint64_t, uint64_t, uint64_t, void*);
-typedef int64_t (*iFpuuLL_t)(void*, uint64_t, uint64_t, uintptr_t, uintptr_t);
-typedef int64_t (*iFpuupp_t)(void*, uint64_t, uint64_t, void*, void*);
-typedef int64_t (*iFpupiU_t)(void*, uint64_t, void*, int64_t, uint64_t);
-typedef int64_t (*iFpupup_t)(void*, uint64_t, void*, uint64_t, void*);
-typedef int64_t (*iFpuppp_t)(void*, uint64_t, void*, void*, void*);
-typedef int64_t (*iFpUiUi_t)(void*, uint64_t, int64_t, uint64_t, int64_t);
-typedef int64_t (*iFpUupp_t)(void*, uint64_t, uint64_t, void*, void*);
-typedef int64_t (*iFplluu_t)(void*, intptr_t, intptr_t, uint64_t, uint64_t);
-typedef int64_t (*iFpLiLi_t)(void*, uintptr_t, int64_t, uintptr_t, int64_t);
-typedef int64_t (*iFpLlpp_t)(void*, uintptr_t, intptr_t, void*, void*);
-typedef int64_t (*iFpLLpp_t)(void*, uintptr_t, uintptr_t, void*, void*);
-typedef int64_t (*iFpLppi_t)(void*, uintptr_t, void*, void*, int64_t);
-typedef int64_t (*iFppiiu_t)(void*, void*, int64_t, int64_t, uint64_t);
-typedef int64_t (*iFppiip_t)(void*, void*, int64_t, int64_t, void*);
-typedef int64_t (*iFppiup_t)(void*, void*, int64_t, uint64_t, void*);
-typedef int64_t (*iFppiLi_t)(void*, void*, int64_t, uintptr_t, int64_t);
-typedef int64_t (*iFppiLL_t)(void*, void*, int64_t, uintptr_t, uintptr_t);
-typedef int64_t (*iFppipi_t)(void*, void*, int64_t, void*, int64_t);
-typedef int64_t (*iFppipp_t)(void*, void*, int64_t, void*, void*);
-typedef int64_t (*iFppuwp_t)(void*, void*, uint64_t, int16_t, void*);
-typedef int64_t (*iFppuip_t)(void*, void*, uint64_t, int64_t, void*);
-typedef int64_t (*iFppuup_t)(void*, void*, uint64_t, uint64_t, void*);
-typedef int64_t (*iFppupi_t)(void*, void*, uint64_t, void*, int64_t);
-typedef int64_t (*iFppupp_t)(void*, void*, uint64_t, void*, void*);
-typedef int64_t (*iFppllp_t)(void*, void*, intptr_t, intptr_t, void*);
-typedef int64_t (*iFpplpp_t)(void*, void*, intptr_t, void*, void*);
-typedef int64_t (*iFppLip_t)(void*, void*, uintptr_t, int64_t, void*);
-typedef int64_t (*iFppLpi_t)(void*, void*, uintptr_t, void*, int64_t);
-typedef int64_t (*iFppLpL_t)(void*, void*, uintptr_t, void*, uintptr_t);
-typedef int64_t (*iFppLpp_t)(void*, void*, uintptr_t, void*, void*);
-typedef int64_t (*iFpppii_t)(void*, void*, void*, int64_t, int64_t);
-typedef int64_t (*iFpppiL_t)(void*, void*, void*, int64_t, uintptr_t);
-typedef int64_t (*iFpppip_t)(void*, void*, void*, int64_t, void*);
-typedef int64_t (*iFpppui_t)(void*, void*, void*, uint64_t, int64_t);
-typedef int64_t (*iFpppUi_t)(void*, void*, void*, uint64_t, int64_t);
-typedef int64_t (*iFpppLi_t)(void*, void*, void*, uintptr_t, int64_t);
-typedef int64_t (*iFpppLp_t)(void*, void*, void*, uintptr_t, void*);
-typedef int64_t (*iFppppi_t)(void*, void*, void*, void*, int64_t);
-typedef int64_t (*iFppppL_t)(void*, void*, void*, void*, uintptr_t);
-typedef int64_t (*iFppppp_t)(void*, void*, void*, void*, void*);
-typedef int64_t (*IFppIII_t)(void*, void*, int64_t, int64_t, int64_t);
-typedef uint64_t (*uFEippp_t)(x64emu_t*, int64_t, void*, void*, void*);
-typedef uint64_t (*uFEpipp_t)(x64emu_t*, void*, int64_t, void*, void*);
-typedef uint64_t (*uFEppuu_t)(x64emu_t*, void*, void*, uint64_t, uint64_t);
-typedef uint64_t (*uFEpppp_t)(x64emu_t*, void*, void*, void*, void*);
-typedef uint64_t (*uFEpppV_t)(x64emu_t*, void*, void*, void*, void*);
-typedef uint64_t (*uFiuuuu_t)(int64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef uint64_t (*uFipipp_t)(int64_t, void*, int64_t, void*, void*);
-typedef uint64_t (*uFipLpp_t)(int64_t, void*, uintptr_t, void*, void*);
-typedef uint64_t (*uFuiiiu_t)(uint64_t, int64_t, int64_t, int64_t, uint64_t);
-typedef uint64_t (*uFpCCCC_t)(void*, uint8_t, uint8_t, uint8_t, uint8_t);
-typedef uint64_t (*uFpWuip_t)(void*, uint16_t, uint64_t, int64_t, void*);
-typedef uint64_t (*uFpuuuu_t)(void*, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef uint64_t (*uFpupuu_t)(void*, uint64_t, void*, uint64_t, uint64_t);
-typedef uint64_t (*uFppiip_t)(void*, void*, int64_t, int64_t, void*);
-typedef uint64_t (*uFppipp_t)(void*, void*, int64_t, void*, void*);
-typedef uint64_t (*uFppuup_t)(void*, void*, uint64_t, uint64_t, void*);
-typedef uint64_t (*uFppupp_t)(void*, void*, uint64_t, void*, void*);
-typedef uint64_t (*uFpplip_t)(void*, void*, intptr_t, int64_t, void*);
-typedef uint64_t (*uFppLpp_t)(void*, void*, uintptr_t, void*, void*);
-typedef uint64_t (*uFppppu_t)(void*, void*, void*, void*, uint64_t);
-typedef uint64_t (*uFppppp_t)(void*, void*, void*, void*, void*);
-typedef uint64_t (*UFuiiii_t)(uint64_t, int64_t, int64_t, int64_t, int64_t);
-typedef intptr_t (*lFipili_t)(int64_t, void*, int64_t, intptr_t, int64_t);
-typedef intptr_t (*lFipLli_t)(int64_t, void*, uintptr_t, intptr_t, int64_t);
-typedef intptr_t (*lFipLlL_t)(int64_t, void*, uintptr_t, intptr_t, uintptr_t);
-typedef intptr_t (*lFipLLi_t)(int64_t, void*, uintptr_t, uintptr_t, int64_t);
-typedef intptr_t (*lFipLpp_t)(int64_t, void*, uintptr_t, void*, void*);
-typedef uintptr_t (*LFELppi_t)(x64emu_t*, uintptr_t, void*, void*, int64_t);
-typedef uintptr_t (*LFEpppp_t)(x64emu_t*, void*, void*, void*, void*);
-typedef uintptr_t (*LFpuipp_t)(void*, uint64_t, int64_t, void*, void*);
-typedef uintptr_t (*LFpuppi_t)(void*, uint64_t, void*, void*, int64_t);
-typedef uintptr_t (*LFpLLLp_t)(void*, uintptr_t, uintptr_t, uintptr_t, void*);
-typedef uintptr_t (*LFpLppL_t)(void*, uintptr_t, void*, void*, uintptr_t);
-typedef uintptr_t (*LFpLppp_t)(void*, uintptr_t, void*, void*, void*);
-typedef uintptr_t (*LFppLLp_t)(void*, void*, uintptr_t, uintptr_t, void*);
-typedef uintptr_t (*LFpppii_t)(void*, void*, void*, int64_t, int64_t);
-typedef uintptr_t (*LFppppp_t)(void*, void*, void*, void*, void*);
-typedef void* (*pFEpiii_t)(x64emu_t*, void*, int64_t, int64_t, int64_t);
-typedef void* (*pFEpipL_t)(x64emu_t*, void*, int64_t, void*, uintptr_t);
-typedef void* (*pFEpipp_t)(x64emu_t*, void*, int64_t, void*, void*);
-typedef void* (*pFEpipV_t)(x64emu_t*, void*, int64_t, void*, void*);
-typedef void* (*pFEpipA_t)(x64emu_t*, void*, int64_t, void*, void*);
-typedef void* (*pFEpupp_t)(x64emu_t*, void*, uint64_t, void*, void*);
-typedef void* (*pFEppii_t)(x64emu_t*, void*, void*, int64_t, int64_t);
-typedef void* (*pFEppip_t)(x64emu_t*, void*, void*, int64_t, void*);
-typedef void* (*pFEppLp_t)(x64emu_t*, void*, void*, uintptr_t, void*);
-typedef void* (*pFEpppi_t)(x64emu_t*, void*, void*, void*, int64_t);
-typedef void* (*pFEpppu_t)(x64emu_t*, void*, void*, void*, uint64_t);
-typedef void* (*pFEpppp_t)(x64emu_t*, void*, void*, void*, void*);
-typedef void* (*pFiiiii_t)(int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void* (*pFiiipL_t)(int64_t, int64_t, int64_t, void*, uintptr_t);
-typedef void* (*pFipipL_t)(int64_t, void*, int64_t, void*, uintptr_t);
-typedef void* (*pFipppu_t)(int64_t, void*, void*, void*, uint64_t);
-typedef void* (*pFuiiiu_t)(uint64_t, int64_t, int64_t, int64_t, uint64_t);
-typedef void* (*pFuiipp_t)(uint64_t, int64_t, int64_t, void*, void*);
-typedef void* (*pFpiiii_t)(void*, int64_t, int64_t, int64_t, int64_t);
-typedef void* (*pFpiiip_t)(void*, int64_t, int64_t, int64_t, void*);
-typedef void* (*pFpiiuu_t)(void*, int64_t, int64_t, uint64_t, uint64_t);
-typedef void* (*pFpiipi_t)(void*, int64_t, int64_t, void*, int64_t);
-typedef void* (*pFpiipp_t)(void*, int64_t, int64_t, void*, void*);
-typedef void* (*pFpiCCC_t)(void*, int64_t, uint8_t, uint8_t, uint8_t);
-typedef void* (*pFpiuuu_t)(void*, int64_t, uint64_t, uint64_t, uint64_t);
-typedef void* (*pFpippi_t)(void*, int64_t, void*, void*, int64_t);
-typedef void* (*pFpippp_t)(void*, int64_t, void*, void*, void*);
-typedef void* (*pFpCpup_t)(void*, uint8_t, void*, uint64_t, void*);
-typedef void* (*pFpCppp_t)(void*, uint8_t, void*, void*, void*);
-typedef void* (*pFpuiii_t)(void*, uint64_t, int64_t, int64_t, int64_t);
-typedef void* (*pFpuiip_t)(void*, uint64_t, int64_t, int64_t, void*);
-typedef void* (*pFpuWWW_t)(void*, uint64_t, uint16_t, uint16_t, uint16_t);
-typedef void* (*pFpuuip_t)(void*, uint64_t, uint64_t, int64_t, void*);
-typedef void* (*pFpuuWW_t)(void*, uint64_t, uint64_t, uint16_t, uint16_t);
-typedef void* (*pFpuuuu_t)(void*, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void* (*pFpuuup_t)(void*, uint64_t, uint64_t, uint64_t, void*);
-typedef void* (*pFpuppp_t)(void*, uint64_t, void*, void*, void*);
-typedef void* (*pFpUdii_t)(void*, uint64_t, double, int64_t, int64_t);
-typedef void* (*pFpdddd_t)(void*, double, double, double, double);
-typedef void* (*pFplppp_t)(void*, intptr_t, void*, void*, void*);
-typedef void* (*pFppiii_t)(void*, void*, int64_t, int64_t, int64_t);
-typedef void* (*pFppiip_t)(void*, void*, int64_t, int64_t, void*);
-typedef void* (*pFppiup_t)(void*, void*, int64_t, uint64_t, void*);
-typedef void* (*pFppipi_t)(void*, void*, int64_t, void*, int64_t);
-typedef void* (*pFppipp_t)(void*, void*, int64_t, void*, void*);
-typedef void* (*pFppuuu_t)(void*, void*, uint64_t, uint64_t, uint64_t);
-typedef void* (*pFppuup_t)(void*, void*, uint64_t, uint64_t, void*);
-typedef void* (*pFppddi_t)(void*, void*, double, double, int64_t);
-typedef void* (*pFppLii_t)(void*, void*, uintptr_t, int64_t, int64_t);
-typedef void* (*pFppLLp_t)(void*, void*, uintptr_t, uintptr_t, void*);
-typedef void* (*pFpppii_t)(void*, void*, void*, int64_t, int64_t);
-typedef void* (*pFpppip_t)(void*, void*, void*, int64_t, void*);
-typedef void* (*pFpppIi_t)(void*, void*, void*, int64_t, int64_t);
-typedef void* (*pFpppui_t)(void*, void*, void*, uint64_t, int64_t);
-typedef void* (*pFpppuu_t)(void*, void*, void*, uint64_t, uint64_t);
-typedef void* (*pFpppup_t)(void*, void*, void*, uint64_t, void*);
-typedef void* (*pFpppLi_t)(void*, void*, void*, uintptr_t, int64_t);
-typedef void* (*pFppppi_t)(void*, void*, void*, void*, int64_t);
-typedef void* (*pFppppu_t)(void*, void*, void*, void*, uint64_t);
-typedef void* (*pFppppp_t)(void*, void*, void*, void*, void*);
-typedef int64_t (*iWEpiup_t)(x64emu_t*, void*, int64_t, uint64_t, void*);
-typedef int64_t (*iWEpipp_t)(x64emu_t*, void*, int64_t, void*, void*);
-typedef int64_t (*iWpiiii_t)(void*, int64_t, int64_t, int64_t, int64_t);
-typedef int64_t (*iWpiupu_t)(void*, int64_t, uint64_t, void*, uint64_t);
-typedef int64_t (*iWpuiii_t)(void*, uint64_t, int64_t, int64_t, int64_t);
-typedef int64_t (*iWpuiup_t)(void*, uint64_t, int64_t, uint64_t, void*);
-typedef int64_t (*iWpuupu_t)(void*, uint64_t, uint64_t, void*, uint64_t);
-typedef int64_t (*iWpuupp_t)(void*, uint64_t, uint64_t, void*, void*);
-typedef int64_t (*iWpupuu_t)(void*, uint64_t, void*, uint64_t, uint64_t);
-typedef int64_t (*iWpupup_t)(void*, uint64_t, void*, uint64_t, void*);
-typedef int64_t (*iWpuppu_t)(void*, uint64_t, void*, void*, uint64_t);
-typedef int64_t (*iWpuppp_t)(void*, uint64_t, void*, void*, void*);
-typedef int64_t (*iWpppuu_t)(void*, void*, void*, uint64_t, uint64_t);
-typedef int64_t (*iWpppup_t)(void*, void*, void*, uint64_t, void*);
-typedef int64_t (*iWppppp_t)(void*, void*, void*, void*, void*);
-typedef void (*vFEiiipp_t)(x64emu_t*, int64_t, int64_t, int64_t, void*, void*);
-typedef void (*vFEpiLpp_t)(x64emu_t*, void*, int64_t, uintptr_t, void*, void*);
-typedef void (*vFEpippp_t)(x64emu_t*, void*, int64_t, void*, void*, void*);
-typedef void (*vFEpuipp_t)(x64emu_t*, void*, uint64_t, int64_t, void*, void*);
-typedef void (*vFEpupup_t)(x64emu_t*, void*, uint64_t, void*, uint64_t, void*);
-typedef void (*vFEpLLpp_t)(x64emu_t*, void*, uintptr_t, uintptr_t, void*, void*);
-typedef void (*vFEppipV_t)(x64emu_t*, void*, void*, int64_t, void*, void*);
-typedef void (*vFEppipA_t)(x64emu_t*, void*, void*, int64_t, void*, void*);
-typedef void (*vFEppupp_t)(x64emu_t*, void*, void*, uint64_t, void*, void*);
-typedef void (*vFEppppp_t)(x64emu_t*, void*, void*, void*, void*, void*);
-typedef void (*vFiiiiii_t)(int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFiiiuil_t)(int64_t, int64_t, int64_t, uint64_t, int64_t, intptr_t);
-typedef void (*vFiiilpi_t)(int64_t, int64_t, int64_t, intptr_t, void*, int64_t);
-typedef void (*vFiiuiil_t)(int64_t, int64_t, uint64_t, int64_t, int64_t, intptr_t);
-typedef void (*vFiiuilp_t)(int64_t, int64_t, uint64_t, int64_t, intptr_t, void*);
-typedef void (*vFiiuulp_t)(int64_t, int64_t, uint64_t, uint64_t, intptr_t, void*);
-typedef void (*vFiililp_t)(int64_t, int64_t, intptr_t, int64_t, intptr_t, void*);
-typedef void (*vFiiplli_t)(int64_t, int64_t, void*, intptr_t, intptr_t, int64_t);
-typedef void (*vFiiplll_t)(int64_t, int64_t, void*, intptr_t, intptr_t, intptr_t);
-typedef void (*vFiuippp_t)(int64_t, uint64_t, int64_t, void*, void*, void*);
-typedef void (*vFiffiff_t)(int64_t, float, float, int64_t, float, float);
-typedef void (*vFiddidd_t)(int64_t, double, double, int64_t, double, double);
-typedef void (*vFililuU_t)(int64_t, intptr_t, int64_t, intptr_t, uint64_t, uint64_t);
-typedef void (*vFililll_t)(int64_t, intptr_t, int64_t, intptr_t, intptr_t, intptr_t);
-typedef void (*vFilipli_t)(int64_t, intptr_t, int64_t, void*, intptr_t, int64_t);
-typedef void (*vFiliplu_t)(int64_t, intptr_t, int64_t, void*, intptr_t, uint64_t);
-typedef void (*vFillill_t)(int64_t, intptr_t, intptr_t, int64_t, intptr_t, intptr_t);
-typedef void (*vFipiplp_t)(int64_t, void*, int64_t, void*, intptr_t, void*);
-typedef void (*vFipllli_t)(int64_t, void*, intptr_t, intptr_t, intptr_t, int64_t);
-typedef void (*vFuiiiii_t)(uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFuiiiil_t)(uint64_t, int64_t, int64_t, int64_t, int64_t, intptr_t);
-typedef void (*vFuiiiip_t)(uint64_t, int64_t, int64_t, int64_t, int64_t, void*);
-typedef void (*vFuiiilp_t)(uint64_t, int64_t, int64_t, int64_t, intptr_t, void*);
-typedef void (*vFuiiuii_t)(uint64_t, int64_t, int64_t, uint64_t, int64_t, int64_t);
-typedef void (*vFuiiuup_t)(uint64_t, int64_t, int64_t, uint64_t, uint64_t, void*);
-typedef void (*vFuiIIII_t)(uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFuiuiii_t)(uint64_t, int64_t, uint64_t, int64_t, int64_t, int64_t);
-typedef void (*vFuiuiil_t)(uint64_t, int64_t, uint64_t, int64_t, int64_t, intptr_t);
-typedef void (*vFuiuiip_t)(uint64_t, int64_t, uint64_t, int64_t, int64_t, void*);
-typedef void (*vFuiuiuu_t)(uint64_t, int64_t, uint64_t, int64_t, uint64_t, uint64_t);
-typedef void (*vFuiuuip_t)(uint64_t, int64_t, uint64_t, uint64_t, int64_t, void*);
-typedef void (*vFuiuuuu_t)(uint64_t, int64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFuiuulp_t)(uint64_t, int64_t, uint64_t, uint64_t, intptr_t, void*);
-typedef void (*vFuiupii_t)(uint64_t, int64_t, uint64_t, void*, int64_t, int64_t);
-typedef void (*vFuiupiu_t)(uint64_t, int64_t, uint64_t, void*, int64_t, uint64_t);
-typedef void (*vFuiUUUU_t)(uint64_t, int64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFuiffff_t)(uint64_t, int64_t, float, float, float, float);
-typedef void (*vFuidddd_t)(uint64_t, int64_t, double, double, double, double);
-typedef void (*vFuuiiii_t)(uint64_t, uint64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFuuiiiu_t)(uint64_t, uint64_t, int64_t, int64_t, int64_t, uint64_t);
-typedef void (*vFuuiuii_t)(uint64_t, uint64_t, int64_t, uint64_t, int64_t, int64_t);
-typedef void (*vFuuiuiu_t)(uint64_t, uint64_t, int64_t, uint64_t, int64_t, uint64_t);
-typedef void (*vFuuiuup_t)(uint64_t, uint64_t, int64_t, uint64_t, uint64_t, void*);
-typedef void (*vFuuuiup_t)(uint64_t, uint64_t, uint64_t, int64_t, uint64_t, void*);
-typedef void (*vFuuuipi_t)(uint64_t, uint64_t, uint64_t, int64_t, void*, int64_t);
-typedef void (*vFuuuipp_t)(uint64_t, uint64_t, uint64_t, int64_t, void*, void*);
-typedef void (*vFuuuuii_t)(uint64_t, uint64_t, uint64_t, uint64_t, int64_t, int64_t);
-typedef void (*vFuuuuip_t)(uint64_t, uint64_t, uint64_t, uint64_t, int64_t, void*);
-typedef void (*vFuuuuuu_t)(uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFuuuuff_t)(uint64_t, uint64_t, uint64_t, uint64_t, float, float);
-typedef void (*vFuuuppi_t)(uint64_t, uint64_t, uint64_t, void*, void*, int64_t);
-typedef void (*vFuuuppp_t)(uint64_t, uint64_t, uint64_t, void*, void*, void*);
-typedef void (*vFuuffff_t)(uint64_t, uint64_t, float, float, float, float);
-typedef void (*vFuudddd_t)(uint64_t, uint64_t, double, double, double, double);
-typedef void (*vFuulppp_t)(uint64_t, uint64_t, intptr_t, void*, void*, void*);
-typedef void (*vFuupupp_t)(uint64_t, uint64_t, void*, uint64_t, void*, void*);
-typedef void (*vFuffiip_t)(uint64_t, float, float, int64_t, int64_t, void*);
-typedef void (*vFufffff_t)(uint64_t, float, float, float, float, float);
-typedef void (*vFuddiip_t)(uint64_t, double, double, int64_t, int64_t, void*);
-typedef void (*vFuliluU_t)(uint64_t, intptr_t, int64_t, intptr_t, uint64_t, uint64_t);
-typedef void (*vFulilli_t)(uint64_t, intptr_t, int64_t, intptr_t, intptr_t, int64_t);
-typedef void (*vFulilll_t)(uint64_t, intptr_t, int64_t, intptr_t, intptr_t, intptr_t);
-typedef void (*vFullill_t)(uint64_t, intptr_t, intptr_t, int64_t, intptr_t, intptr_t);
-typedef void (*vFulplup_t)(uint64_t, intptr_t, void*, intptr_t, uint64_t, void*);
-typedef void (*vFupupip_t)(uint64_t, void*, uint64_t, void*, int64_t, void*);
-typedef void (*vFuppppu_t)(uint64_t, void*, void*, void*, void*, uint64_t);
-typedef void (*vFuppppp_t)(uint64_t, void*, void*, void*, void*, void*);
-typedef void (*vFffffff_t)(float, float, float, float, float, float);
-typedef void (*vFdddddd_t)(double, double, double, double, double, double);
-typedef void (*vFpiiiii_t)(void*, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFpiiipp_t)(void*, int64_t, int64_t, int64_t, void*, void*);
-typedef void (*vFpiiuuu_t)(void*, int64_t, int64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFpiippp_t)(void*, int64_t, int64_t, void*, void*, void*);
-typedef void (*vFpiUuup_t)(void*, int64_t, uint64_t, uint64_t, uint64_t, void*);
-typedef void (*vFpipipV_t)(void*, int64_t, void*, int64_t, void*, void*);
-typedef void (*vFpipppi_t)(void*, int64_t, void*, void*, void*, int64_t);
-typedef void (*vFpipppp_t)(void*, int64_t, void*, void*, void*, void*);
-typedef void (*vFpuiiii_t)(void*, uint64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFpuiiiu_t)(void*, uint64_t, int64_t, int64_t, int64_t, uint64_t);
-typedef void (*vFpuiipp_t)(void*, uint64_t, int64_t, int64_t, void*, void*);
-typedef void (*vFpuuuiu_t)(void*, uint64_t, uint64_t, uint64_t, int64_t, uint64_t);
-typedef void (*vFpuuppp_t)(void*, uint64_t, uint64_t, void*, void*, void*);
-typedef void (*vFpudddd_t)(void*, uint64_t, double, double, double, double);
-typedef void (*vFpupiUu_t)(void*, uint64_t, void*, int64_t, uint64_t, uint64_t);
-typedef void (*vFpupuuu_t)(void*, uint64_t, void*, uint64_t, uint64_t, uint64_t);
-typedef void (*vFpupppp_t)(void*, uint64_t, void*, void*, void*, void*);
-typedef void (*vFpUiuup_t)(void*, uint64_t, int64_t, uint64_t, uint64_t, void*);
-typedef void (*vFpUiUup_t)(void*, uint64_t, int64_t, uint64_t, uint64_t, void*);
-typedef void (*vFpUipup_t)(void*, uint64_t, int64_t, void*, uint64_t, void*);
-typedef void (*vFpUUiup_t)(void*, uint64_t, uint64_t, int64_t, uint64_t, void*);
-typedef void (*vFpdddii_t)(void*, double, double, double, int64_t, int64_t);
-typedef void (*vFpddddd_t)(void*, double, double, double, double, double);
-typedef void (*vFpddddp_t)(void*, double, double, double, double, void*);
-typedef void (*vFppiiii_t)(void*, void*, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFppiiip_t)(void*, void*, int64_t, int64_t, int64_t, void*);
-typedef void (*vFppiiui_t)(void*, void*, int64_t, int64_t, uint64_t, int64_t);
-typedef void (*vFppiipi_t)(void*, void*, int64_t, int64_t, void*, int64_t);
-typedef void (*vFppiipp_t)(void*, void*, int64_t, int64_t, void*, void*);
-typedef void (*vFppilpp_t)(void*, void*, int64_t, intptr_t, void*, void*);
-typedef void (*vFppippi_t)(void*, void*, int64_t, void*, void*, int64_t);
-typedef void (*vFppippp_t)(void*, void*, int64_t, void*, void*, void*);
-typedef void (*vFppuuuu_t)(void*, void*, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFppuUUU_t)(void*, void*, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFppupii_t)(void*, void*, uint64_t, void*, int64_t, int64_t);
-typedef void (*vFppuppp_t)(void*, void*, uint64_t, void*, void*, void*);
-typedef void (*vFppdidd_t)(void*, void*, double, int64_t, double, double);
-typedef void (*vFppdddd_t)(void*, void*, double, double, double, double);
-typedef void (*vFpplppi_t)(void*, void*, intptr_t, void*, void*, int64_t);
-typedef void (*vFpplppp_t)(void*, void*, intptr_t, void*, void*, void*);
-typedef void (*vFppLppi_t)(void*, void*, uintptr_t, void*, void*, int64_t);
-typedef void (*vFppLppp_t)(void*, void*, uintptr_t, void*, void*, void*);
-typedef void (*vFpppiii_t)(void*, void*, void*, int64_t, int64_t, int64_t);
-typedef void (*vFpppiip_t)(void*, void*, void*, int64_t, int64_t, void*);
-typedef void (*vFpppiff_t)(void*, void*, void*, int64_t, float, float);
-typedef void (*vFpppipu_t)(void*, void*, void*, int64_t, void*, uint64_t);
-typedef void (*vFpppuii_t)(void*, void*, void*, uint64_t, int64_t, int64_t);
-typedef void (*vFppppii_t)(void*, void*, void*, void*, int64_t, int64_t);
-typedef void (*vFpppppi_t)(void*, void*, void*, void*, void*, int64_t);
-typedef void (*vFpppppu_t)(void*, void*, void*, void*, void*, uint64_t);
-typedef void (*vFpppppU_t)(void*, void*, void*, void*, void*, uint64_t);
-typedef void (*vFpppppL_t)(void*, void*, void*, void*, void*, uintptr_t);
-typedef void (*vFpppppp_t)(void*, void*, void*, void*, void*, void*);
-typedef int8_t (*cFppLppi_t)(void*, void*, uintptr_t, void*, void*, int64_t);
-typedef int64_t (*iFEiippi_t)(x64emu_t*, int64_t, int64_t, void*, void*, int64_t);
-typedef int64_t (*iFEiippp_t)(x64emu_t*, int64_t, int64_t, void*, void*, void*);
-typedef int64_t (*iFEiLLLL_t)(x64emu_t*, int64_t, uintptr_t, uintptr_t, uintptr_t, uintptr_t);
-typedef int64_t (*iFEippLp_t)(x64emu_t*, int64_t, void*, void*, uintptr_t, void*);
-typedef int64_t (*iFElpppp_t)(x64emu_t*, intptr_t, void*, void*, void*, void*);
-typedef int64_t (*iFEpiipp_t)(x64emu_t*, void*, int64_t, int64_t, void*, void*);
-typedef int64_t (*iFEpiipV_t)(x64emu_t*, void*, int64_t, int64_t, void*, void*);
-typedef int64_t (*iFEpilpV_t)(x64emu_t*, void*, int64_t, intptr_t, void*, void*);
-typedef int64_t (*iFEpippi_t)(x64emu_t*, void*, int64_t, void*, void*, int64_t);
-typedef int64_t (*iFEpIppp_t)(x64emu_t*, void*, int64_t, void*, void*, void*);
-typedef int64_t (*iFEpuppp_t)(x64emu_t*, void*, uint64_t, void*, void*, void*);
-typedef int64_t (*iFEpUppp_t)(x64emu_t*, void*, uint64_t, void*, void*, void*);
-typedef int64_t (*iFEppppp_t)(x64emu_t*, void*, void*, void*, void*, void*);
-typedef int64_t (*iFiiiiii_t)(int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef int64_t (*iFiiiiip_t)(int64_t, int64_t, int64_t, int64_t, int64_t, void*);
-typedef int64_t (*iFiiiuwp_t)(int64_t, int64_t, int64_t, uint64_t, int16_t, void*);
-typedef int64_t (*iFiuiipi_t)(int64_t, uint64_t, int64_t, int64_t, void*, int64_t);
-typedef int64_t (*iFipiipi_t)(int64_t, void*, int64_t, int64_t, void*, int64_t);
-typedef int64_t (*iFipipip_t)(int64_t, void*, int64_t, void*, int64_t, void*);
-typedef int64_t (*iFipippp_t)(int64_t, void*, int64_t, void*, void*, void*);
-typedef int64_t (*iFipuufp_t)(int64_t, void*, uint64_t, uint64_t, float, void*);
-typedef int64_t (*iFipupup_t)(int64_t, void*, uint64_t, void*, uint64_t, void*);
-typedef int64_t (*iFipuppp_t)(int64_t, void*, uint64_t, void*, void*, void*);
-typedef int64_t (*iFipppLp_t)(int64_t, void*, void*, void*, uintptr_t, void*);
-typedef int64_t (*iFippppp_t)(int64_t, void*, void*, void*, void*, void*);
-typedef int64_t (*iFuppppp_t)(uint64_t, void*, void*, void*, void*, void*);
-typedef int64_t (*iFdipppL_t)(double, int64_t, void*, void*, void*, uintptr_t);
-typedef int64_t (*iFDipppL_t)(long double, int64_t, void*, void*, void*, uintptr_t);
-typedef int64_t (*iFlpippp_t)(intptr_t, void*, int64_t, void*, void*, void*);
-typedef int64_t (*iFLppipp_t)(uintptr_t, void*, void*, int64_t, void*, void*);
-typedef int64_t (*iFpiiiii_t)(void*, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef int64_t (*iFpiiiip_t)(void*, int64_t, int64_t, int64_t, int64_t, void*);
-typedef int64_t (*iFpiiipp_t)(void*, int64_t, int64_t, int64_t, void*, void*);
-typedef int64_t (*iFpiipip_t)(void*, int64_t, int64_t, void*, int64_t, void*);
-typedef int64_t (*iFpiippu_t)(void*, int64_t, int64_t, void*, void*, uint64_t);
-typedef int64_t (*iFpiippp_t)(void*, int64_t, int64_t, void*, void*, void*);
-typedef int64_t (*iFpiuuup_t)(void*, int64_t, uint64_t, uint64_t, uint64_t, void*);
-typedef int64_t (*iFpiuupp_t)(void*, int64_t, uint64_t, uint64_t, void*, void*);
-typedef int64_t (*iFpiUUpp_t)(void*, int64_t, uint64_t, uint64_t, void*, void*);
-typedef int64_t (*iFpipipi_t)(void*, int64_t, void*, int64_t, void*, int64_t);
-typedef int64_t (*iFpippip_t)(void*, int64_t, void*, void*, int64_t, void*);
-typedef int64_t (*iFpipppL_t)(void*, int64_t, void*, void*, void*, uintptr_t);
-typedef int64_t (*iFpipppp_t)(void*, int64_t, void*, void*, void*, void*);
-typedef int64_t (*iFpCpipu_t)(void*, uint8_t, void*, int64_t, void*, uint64_t);
-typedef int64_t (*iFpWpppp_t)(void*, uint16_t, void*, void*, void*, void*);
-typedef int64_t (*iFpuiCpp_t)(void*, uint64_t, int64_t, uint8_t, void*, void*);
-typedef int64_t (*iFpuippp_t)(void*, uint64_t, int64_t, void*, void*, void*);
-typedef int64_t (*iFpupuui_t)(void*, uint64_t, void*, uint64_t, uint64_t, int64_t);
-typedef int64_t (*iFpUuuLp_t)(void*, uint64_t, uint64_t, uint64_t, uintptr_t, void*);
-typedef int64_t (*iFpUuupp_t)(void*, uint64_t, uint64_t, uint64_t, void*, void*);
-typedef int64_t (*iFpUUUip_t)(void*, uint64_t, uint64_t, uint64_t, int64_t, void*);
-typedef int64_t (*iFpUUUUp_t)(void*, uint64_t, uint64_t, uint64_t, uint64_t, void*);
-typedef int64_t (*iFpLLppp_t)(void*, uintptr_t, uintptr_t, void*, void*, void*);
-typedef int64_t (*iFppiiii_t)(void*, void*, int64_t, int64_t, int64_t, int64_t);
-typedef int64_t (*iFppiiip_t)(void*, void*, int64_t, int64_t, int64_t, void*);
-typedef int64_t (*iFppiiuu_t)(void*, void*, int64_t, int64_t, uint64_t, uint64_t);
-typedef int64_t (*iFppiipi_t)(void*, void*, int64_t, int64_t, void*, int64_t);
-typedef int64_t (*iFppiipp_t)(void*, void*, int64_t, int64_t, void*, void*);
-typedef int64_t (*iFppipii_t)(void*, void*, int64_t, void*, int64_t, int64_t);
-typedef int64_t (*iFppipiL_t)(void*, void*, int64_t, void*, int64_t, uintptr_t);
-typedef int64_t (*iFppipip_t)(void*, void*, int64_t, void*, int64_t, void*);
-typedef int64_t (*iFppIipp_t)(void*, void*, int64_t, int64_t, void*, void*);
-typedef int64_t (*iFppIppp_t)(void*, void*, int64_t, void*, void*, void*);
-typedef int64_t (*iFppuiii_t)(void*, void*, uint64_t, int64_t, int64_t, int64_t);
-typedef int64_t (*iFppuiiL_t)(void*, void*, uint64_t, int64_t, int64_t, uintptr_t);
-typedef int64_t (*iFppuipp_t)(void*, void*, uint64_t, int64_t, void*, void*);
-typedef int64_t (*iFppuIII_t)(void*, void*, uint64_t, int64_t, int64_t, int64_t);
-typedef int64_t (*iFppuupp_t)(void*, void*, uint64_t, uint64_t, void*, void*);
-typedef int64_t (*iFppupip_t)(void*, void*, uint64_t, void*, int64_t, void*);
-typedef int64_t (*iFppuppp_t)(void*, void*, uint64_t, void*, void*, void*);
-typedef int64_t (*iFppUipp_t)(void*, void*, uint64_t, int64_t, void*, void*);
-typedef int64_t (*iFppUUup_t)(void*, void*, uint64_t, uint64_t, uint64_t, void*);
-typedef int64_t (*iFppdidd_t)(void*, void*, double, int64_t, double, double);
-typedef int64_t (*iFpplppi_t)(void*, void*, intptr_t, void*, void*, int64_t);
-typedef int64_t (*iFppLupp_t)(void*, void*, uintptr_t, uint64_t, void*, void*);
-typedef int64_t (*iFppLpLp_t)(void*, void*, uintptr_t, void*, uintptr_t, void*);
-typedef int64_t (*iFpppiuu_t)(void*, void*, void*, int64_t, uint64_t, uint64_t);
-typedef int64_t (*iFpppipi_t)(void*, void*, void*, int64_t, void*, int64_t);
-typedef int64_t (*iFpppipp_t)(void*, void*, void*, int64_t, void*, void*);
-typedef int64_t (*iFpppuii_t)(void*, void*, void*, uint64_t, int64_t, int64_t);
-typedef int64_t (*iFpppupu_t)(void*, void*, void*, uint64_t, void*, uint64_t);
-typedef int64_t (*iFpppLpp_t)(void*, void*, void*, uintptr_t, void*, void*);
-typedef int64_t (*iFppppii_t)(void*, void*, void*, void*, int64_t, int64_t);
-typedef int64_t (*iFppppiu_t)(void*, void*, void*, void*, int64_t, uint64_t);
-typedef int64_t (*iFppppip_t)(void*, void*, void*, void*, int64_t, void*);
-typedef int64_t (*iFppppup_t)(void*, void*, void*, void*, uint64_t, void*);
-typedef int64_t (*iFpppppi_t)(void*, void*, void*, void*, void*, int64_t);
-typedef int64_t (*iFpppppL_t)(void*, void*, void*, void*, void*, uintptr_t);
-typedef int64_t (*iFpppppp_t)(void*, void*, void*, void*, void*, void*);
-typedef uint64_t (*uFEiippp_t)(x64emu_t*, int64_t, int64_t, void*, void*, void*);
-typedef uint64_t (*uFEiuppp_t)(x64emu_t*, int64_t, uint64_t, void*, void*, void*);
-typedef uint64_t (*uFEpCppp_t)(x64emu_t*, void*, uint8_t, void*, void*, void*);
-typedef uint64_t (*uFEpuppp_t)(x64emu_t*, void*, uint64_t, void*, void*, void*);
-typedef uint64_t (*uFpippup_t)(void*, int64_t, void*, void*, uint64_t, void*);
-typedef uint64_t (*uFpWuwCp_t)(void*, uint16_t, uint64_t, int16_t, uint8_t, void*);
-typedef uint64_t (*uFpWuipp_t)(void*, uint16_t, uint64_t, int64_t, void*, void*);
-typedef uint64_t (*uFpWuuCp_t)(void*, uint16_t, uint64_t, uint64_t, uint8_t, void*);
-typedef uint64_t (*uFpuippp_t)(void*, uint64_t, int64_t, void*, void*, void*);
-typedef uint64_t (*uFppippp_t)(void*, void*, int64_t, void*, void*, void*);
-typedef uint64_t (*uFppuuup_t)(void*, void*, uint64_t, uint64_t, uint64_t, void*);
-typedef uint64_t (*uFppuupu_t)(void*, void*, uint64_t, uint64_t, void*, uint64_t);
-typedef uint64_t (*uFpppppi_t)(void*, void*, void*, void*, void*, int64_t);
-typedef uint64_t (*uFpppppp_t)(void*, void*, void*, void*, void*, void*);
-typedef uint64_t (*UFpippup_t)(void*, int64_t, void*, void*, uint64_t, void*);
-typedef intptr_t (*lFEpippp_t)(x64emu_t*, void*, int64_t, void*, void*, void*);
-typedef intptr_t (*lFipipLu_t)(int64_t, void*, int64_t, void*, uintptr_t, uint64_t);
-typedef intptr_t (*lFipLipu_t)(int64_t, void*, uintptr_t, int64_t, void*, uint64_t);
-typedef intptr_t (*lFipLipp_t)(int64_t, void*, uintptr_t, int64_t, void*, void*);
-typedef intptr_t (*lFipLpLL_t)(int64_t, void*, uintptr_t, void*, uintptr_t, uintptr_t);
-typedef uintptr_t (*LFEupppp_t)(x64emu_t*, uint64_t, void*, void*, void*, void*);
-typedef uintptr_t (*LFELpppi_t)(x64emu_t*, uintptr_t, void*, void*, void*, int64_t);
-typedef uintptr_t (*LFEppppi_t)(x64emu_t*, void*, void*, void*, void*, int64_t);
-typedef uintptr_t (*LFpipipi_t)(void*, int64_t, void*, int64_t, void*, int64_t);
-typedef uintptr_t (*LFpLippp_t)(void*, uintptr_t, int64_t, void*, void*, void*);
-typedef uintptr_t (*LFSpLiip_t)(void*, void*, uintptr_t, int64_t, int64_t, void*);
-typedef void* (*pFEpiupp_t)(x64emu_t*, void*, int64_t, uint64_t, void*, void*);
-typedef void* (*pFEpippp_t)(x64emu_t*, void*, int64_t, void*, void*, void*);
-typedef void* (*pFEpuipp_t)(x64emu_t*, void*, uint64_t, int64_t, void*, void*);
-typedef void* (*pFEpuupp_t)(x64emu_t*, void*, uint64_t, uint64_t, void*, void*);
-typedef void* (*pFEpuppp_t)(x64emu_t*, void*, uint64_t, void*, void*, void*);
-typedef void* (*pFEpLLiN_t)(x64emu_t*, void*, uintptr_t, uintptr_t, int64_t, ...);
-typedef void* (*pFEppLLp_t)(x64emu_t*, void*, void*, uintptr_t, uintptr_t, void*);
-typedef void* (*pFEpppLp_t)(x64emu_t*, void*, void*, void*, uintptr_t, void*);
-typedef void* (*pFEppppi_t)(x64emu_t*, void*, void*, void*, void*, int64_t);
-typedef void* (*pFEppppp_t)(x64emu_t*, void*, void*, void*, void*, void*);
-typedef void* (*pFEppppV_t)(x64emu_t*, void*, void*, void*, void*, void*);
-typedef void* (*pFEppApp_t)(x64emu_t*, void*, void*, void*, void*, void*);
-typedef void* (*pFiiiiii_t)(int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void* (*pFiCiiCi_t)(int64_t, uint8_t, int64_t, int64_t, uint8_t, int64_t);
-typedef void* (*pFdddddd_t)(double, double, double, double, double, double);
-typedef void* (*pFpiiiiu_t)(void*, int64_t, int64_t, int64_t, int64_t, uint64_t);
-typedef void* (*pFpiiCCC_t)(void*, int64_t, int64_t, uint8_t, uint8_t, uint8_t);
-typedef void* (*pFpiUUUU_t)(void*, int64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void* (*pFpippip_t)(void*, int64_t, void*, void*, int64_t, void*);
-typedef void* (*pFpipppp_t)(void*, int64_t, void*, void*, void*, void*);
-typedef void* (*pFpCuuCC_t)(void*, uint8_t, uint64_t, uint64_t, uint8_t, uint8_t);
-typedef void* (*pFpCuuWW_t)(void*, uint8_t, uint64_t, uint64_t, uint16_t, uint16_t);
-typedef void* (*pFpCuuup_t)(void*, uint8_t, uint64_t, uint64_t, uint64_t, void*);
-typedef void* (*pFpuuwwu_t)(void*, uint64_t, uint64_t, int16_t, int16_t, uint64_t);
-typedef void* (*pFpuuuuu_t)(void*, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void* (*pFpuuupu_t)(void*, uint64_t, uint64_t, uint64_t, void*, uint64_t);
-typedef void* (*pFpuuUUU_t)(void*, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void* (*pFplpppp_t)(void*, intptr_t, void*, void*, void*, void*);
-typedef void* (*pFppiiii_t)(void*, void*, int64_t, int64_t, int64_t, int64_t);
-typedef void* (*pFppiipp_t)(void*, void*, int64_t, int64_t, void*, void*);
-typedef void* (*pFppiCCC_t)(void*, void*, int64_t, uint8_t, uint8_t, uint8_t);
-typedef void* (*pFppippi_t)(void*, void*, int64_t, void*, void*, int64_t);
-typedef void* (*pFppippp_t)(void*, void*, int64_t, void*, void*, void*);
-typedef void* (*pFpppiii_t)(void*, void*, void*, int64_t, int64_t, int64_t);
-typedef void* (*pFpppiui_t)(void*, void*, void*, int64_t, uint64_t, int64_t);
-typedef void* (*pFpppiup_t)(void*, void*, void*, int64_t, uint64_t, void*);
-typedef void* (*pFpppupp_t)(void*, void*, void*, uint64_t, void*, void*);
-typedef void* (*pFppppii_t)(void*, void*, void*, void*, int64_t, int64_t);
-typedef void* (*pFppppWW_t)(void*, void*, void*, void*, uint16_t, uint16_t);
-typedef void* (*pFpppppi_t)(void*, void*, void*, void*, void*, int64_t);
-typedef void* (*pFpppppu_t)(void*, void*, void*, void*, void*, uint64_t);
-typedef void* (*pFpppppp_t)(void*, void*, void*, void*, void*, void*);
-typedef void* (*pFSpiiii_t)(void*, void*, int64_t, int64_t, int64_t, int64_t);
-typedef int64_t (*iWEpuuip_t)(x64emu_t*, void*, uint64_t, uint64_t, int64_t, void*);
-typedef int64_t (*iWEppppp_t)(x64emu_t*, void*, void*, void*, void*, void*);
-typedef int64_t (*iWpiiiip_t)(void*, int64_t, int64_t, int64_t, int64_t, void*);
-typedef int64_t (*iWpiiuii_t)(void*, int64_t, int64_t, uint64_t, int64_t, int64_t);
-typedef int64_t (*iWpiuppu_t)(void*, int64_t, uint64_t, void*, void*, uint64_t);
-typedef int64_t (*iWpuiiii_t)(void*, uint64_t, int64_t, int64_t, int64_t, int64_t);
-typedef int64_t (*iWpppppi_t)(void*, void*, void*, void*, void*, int64_t);
-typedef int64_t (*iWpppppu_t)(void*, void*, void*, void*, void*, uint64_t);
-typedef void (*vFEpiiipp_t)(x64emu_t*, void*, int64_t, int64_t, int64_t, void*, void*);
-typedef void (*vFEpipppp_t)(x64emu_t*, void*, int64_t, void*, void*, void*, void*);
-typedef void (*vFEpuipuV_t)(x64emu_t*, void*, uint64_t, int64_t, void*, uint64_t, void*);
-typedef void (*vFEppippp_t)(x64emu_t*, void*, void*, int64_t, void*, void*, void*);
-typedef void (*vFEpppppp_t)(x64emu_t*, void*, void*, void*, void*, void*, void*);
-typedef void (*vFiiiiiip_t)(int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, void*);
-typedef void (*vFiiiiuup_t)(int64_t, int64_t, int64_t, int64_t, uint64_t, uint64_t, void*);
-typedef void (*vFiiuilil_t)(int64_t, int64_t, uint64_t, int64_t, intptr_t, int64_t, intptr_t);
-typedef void (*vFiiffffp_t)(int64_t, int64_t, float, float, float, float, void*);
-typedef void (*vFiipllli_t)(int64_t, int64_t, void*, intptr_t, intptr_t, intptr_t, int64_t);
-typedef void (*vFiuulipi_t)(int64_t, uint64_t, uint64_t, intptr_t, int64_t, void*, int64_t);
-typedef void (*vFililluU_t)(int64_t, intptr_t, int64_t, intptr_t, intptr_t, uint64_t, uint64_t);
-typedef void (*vFilipliu_t)(int64_t, intptr_t, int64_t, void*, intptr_t, int64_t, uint64_t);
-typedef void (*vFilulipi_t)(int64_t, intptr_t, uint64_t, intptr_t, int64_t, void*, int64_t);
-typedef void (*vFuiiiiii_t)(uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFuiiiuip_t)(uint64_t, int64_t, int64_t, int64_t, uint64_t, int64_t, void*);
-typedef void (*vFuiiiuup_t)(uint64_t, int64_t, int64_t, int64_t, uint64_t, uint64_t, void*);
-typedef void (*vFuiiliip_t)(uint64_t, int64_t, int64_t, intptr_t, int64_t, int64_t, void*);
-typedef void (*vFuiililp_t)(uint64_t, int64_t, int64_t, intptr_t, int64_t, intptr_t, void*);
-typedef void (*vFuiuiiii_t)(uint64_t, int64_t, uint64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFuiuiiip_t)(uint64_t, int64_t, uint64_t, int64_t, int64_t, int64_t, void*);
-typedef void (*vFuiuiiuu_t)(uint64_t, int64_t, uint64_t, int64_t, int64_t, uint64_t, uint64_t);
-typedef void (*vFuiupiiu_t)(uint64_t, int64_t, uint64_t, void*, int64_t, int64_t, uint64_t);
-typedef void (*vFuilliip_t)(uint64_t, int64_t, intptr_t, intptr_t, int64_t, int64_t, void*);
-typedef void (*vFuipiiii_t)(uint64_t, int64_t, void*, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFuipffff_t)(uint64_t, int64_t, void*, float, float, float, float);
-typedef void (*vFuipdddd_t)(uint64_t, int64_t, void*, double, double, double, double);
-typedef void (*vFuuiiiii_t)(uint64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFuuiiiip_t)(uint64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, void*);
-typedef void (*vFuuiiiui_t)(uint64_t, uint64_t, int64_t, int64_t, int64_t, uint64_t, int64_t);
-typedef void (*vFuuiiiuu_t)(uint64_t, uint64_t, int64_t, int64_t, int64_t, uint64_t, uint64_t);
-typedef void (*vFuuiiuup_t)(uint64_t, uint64_t, int64_t, int64_t, uint64_t, uint64_t, void*);
-typedef void (*vFuuiuiii_t)(uint64_t, uint64_t, int64_t, uint64_t, int64_t, int64_t, int64_t);
-typedef void (*vFuuipppp_t)(uint64_t, uint64_t, int64_t, void*, void*, void*, void*);
-typedef void (*vFuuuiiii_t)(uint64_t, uint64_t, uint64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFuuuiiip_t)(uint64_t, uint64_t, uint64_t, int64_t, int64_t, int64_t, void*);
-typedef void (*vFuuuiuii_t)(uint64_t, uint64_t, uint64_t, int64_t, uint64_t, int64_t, int64_t);
-typedef void (*vFuuuiupi_t)(uint64_t, uint64_t, uint64_t, int64_t, uint64_t, void*, int64_t);
-typedef void (*vFuuuuiip_t)(uint64_t, uint64_t, uint64_t, uint64_t, int64_t, int64_t, void*);
-typedef void (*vFuuuuuuu_t)(uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFuuuufff_t)(uint64_t, uint64_t, uint64_t, uint64_t, float, float, float);
-typedef void (*vFuuuulll_t)(uint64_t, uint64_t, uint64_t, uint64_t, intptr_t, intptr_t, intptr_t);
-typedef void (*vFuuuffff_t)(uint64_t, uint64_t, uint64_t, float, float, float, float);
-typedef void (*vFuuudddd_t)(uint64_t, uint64_t, uint64_t, double, double, double, double);
-typedef void (*vFuuffiip_t)(uint64_t, uint64_t, float, float, int64_t, int64_t, void*);
-typedef void (*vFuuddiip_t)(uint64_t, uint64_t, double, double, int64_t, int64_t, void*);
-typedef void (*vFuuppppu_t)(uint64_t, uint64_t, void*, void*, void*, void*, uint64_t);
-typedef void (*vFuuppppp_t)(uint64_t, uint64_t, void*, void*, void*, void*, void*);
-typedef void (*vFuffffff_t)(uint64_t, float, float, float, float, float, float);
-typedef void (*vFudddddd_t)(uint64_t, double, double, double, double, double, double);
-typedef void (*vFulilluU_t)(uint64_t, intptr_t, int64_t, intptr_t, intptr_t, uint64_t, uint64_t);
-typedef void (*vFulillli_t)(uint64_t, intptr_t, int64_t, intptr_t, intptr_t, intptr_t, int64_t);
-typedef void (*vFulipulp_t)(uint64_t, intptr_t, int64_t, void*, uint64_t, intptr_t, void*);
-typedef void (*vFulpiill_t)(uint64_t, intptr_t, void*, int64_t, int64_t, intptr_t, intptr_t);
-typedef void (*vFlipuiip_t)(intptr_t, int64_t, void*, uint64_t, int64_t, int64_t, void*);
-typedef void (*vFlliiiip_t)(intptr_t, intptr_t, int64_t, int64_t, int64_t, int64_t, void*);
-typedef void (*vFpiiiipp_t)(void*, int64_t, int64_t, int64_t, int64_t, void*, void*);
-typedef void (*vFpiiliip_t)(void*, int64_t, int64_t, intptr_t, int64_t, int64_t, void*);
-typedef void (*vFpiipCpp_t)(void*, int64_t, int64_t, void*, uint8_t, void*, void*);
-typedef void (*vFpiipppp_t)(void*, int64_t, int64_t, void*, void*, void*, void*);
-typedef void (*vFpipipii_t)(void*, int64_t, void*, int64_t, void*, int64_t, int64_t);
-typedef void (*vFpipppii_t)(void*, int64_t, void*, void*, void*, int64_t, int64_t);
-typedef void (*vFpuuuuuu_t)(void*, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFpuuUUuu_t)(void*, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFpuupppp_t)(void*, uint64_t, uint64_t, void*, void*, void*, void*);
-typedef void (*vFpupuuup_t)(void*, uint64_t, void*, uint64_t, uint64_t, uint64_t, void*);
-typedef void (*vFpUiUiup_t)(void*, uint64_t, int64_t, uint64_t, int64_t, uint64_t, void*);
-typedef void (*vFpUUUUuu_t)(void*, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFpddiidd_t)(void*, double, double, int64_t, int64_t, double, double);
-typedef void (*vFpdddddd_t)(void*, double, double, double, double, double, double);
-typedef void (*vFpLiLiLp_t)(void*, uintptr_t, int64_t, uintptr_t, int64_t, uintptr_t, void*);
-typedef void (*vFppiiiii_t)(void*, void*, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFppiiiip_t)(void*, void*, int64_t, int64_t, int64_t, int64_t, void*);
-typedef void (*vFppiiipi_t)(void*, void*, int64_t, int64_t, int64_t, void*, int64_t);
-typedef void (*vFppiipii_t)(void*, void*, int64_t, int64_t, void*, int64_t, int64_t);
-typedef void (*vFppiipuu_t)(void*, void*, int64_t, int64_t, void*, uint64_t, uint64_t);
-typedef void (*vFppiippp_t)(void*, void*, int64_t, int64_t, void*, void*, void*);
-typedef void (*vFppilppi_t)(void*, void*, int64_t, intptr_t, void*, void*, int64_t);
-typedef void (*vFppiLiLp_t)(void*, void*, int64_t, uintptr_t, int64_t, uintptr_t, void*);
-typedef void (*vFppipiip_t)(void*, void*, int64_t, void*, int64_t, int64_t, void*);
-typedef void (*vFppipipp_t)(void*, void*, int64_t, void*, int64_t, void*, void*);
-typedef void (*vFppipppp_t)(void*, void*, int64_t, void*, void*, void*, void*);
-typedef void (*vFppddddi_t)(void*, void*, double, double, double, double, int64_t);
-typedef void (*vFppddpii_t)(void*, void*, double, double, void*, int64_t, int64_t);
-typedef void (*vFppLpppi_t)(void*, void*, uintptr_t, void*, void*, void*, int64_t);
-typedef void (*vFppLpppp_t)(void*, void*, uintptr_t, void*, void*, void*, void*);
-typedef void (*vFpppiiii_t)(void*, void*, void*, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFpppiipi_t)(void*, void*, void*, int64_t, int64_t, void*, int64_t);
-typedef void (*vFpppiipp_t)(void*, void*, void*, int64_t, int64_t, void*, void*);
-typedef void (*vFpppippi_t)(void*, void*, void*, int64_t, void*, void*, int64_t);
-typedef void (*vFpppuuuu_t)(void*, void*, void*, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFppppiii_t)(void*, void*, void*, void*, int64_t, int64_t, int64_t);
-typedef void (*vFppppiip_t)(void*, void*, void*, void*, int64_t, int64_t, void*);
-typedef void (*vFppppipi_t)(void*, void*, void*, void*, int64_t, void*, int64_t);
-typedef void (*vFpppppip_t)(void*, void*, void*, void*, void*, int64_t, void*);
-typedef void (*vFppppppi_t)(void*, void*, void*, void*, void*, void*, int64_t);
-typedef void (*vFppppppp_t)(void*, void*, void*, void*, void*, void*, void*);
-typedef int64_t (*iFEpupppp_t)(x64emu_t*, void*, uint64_t, void*, void*, void*, void*);
-typedef int64_t (*iFEpUuppp_t)(x64emu_t*, void*, uint64_t, uint64_t, void*, void*, void*);
-typedef int64_t (*iFEpLiLpV_t)(x64emu_t*, void*, uintptr_t, int64_t, uintptr_t, void*, void*);
-typedef int64_t (*iFEppuppp_t)(x64emu_t*, void*, void*, uint64_t, void*, void*, void*);
-typedef int64_t (*iFEppLpIi_t)(x64emu_t*, void*, void*, uintptr_t, void*, int64_t, int64_t);
-typedef int64_t (*iFEpppiiu_t)(x64emu_t*, void*, void*, void*, int64_t, int64_t, uint64_t);
-typedef int64_t (*iFEpppppL_t)(x64emu_t*, void*, void*, void*, void*, void*, uintptr_t);
-typedef int64_t (*iFEpppppp_t)(x64emu_t*, void*, void*, void*, void*, void*, void*);
-typedef int64_t (*iFiiiiiip_t)(int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, void*);
-typedef int64_t (*iFpiiiiii_t)(void*, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef int64_t (*iFpiiiiip_t)(void*, int64_t, int64_t, int64_t, int64_t, int64_t, void*);
-typedef int64_t (*iFpiiiuwp_t)(void*, int64_t, int64_t, int64_t, uint64_t, int16_t, void*);
-typedef int64_t (*iFpiiuuiu_t)(void*, int64_t, int64_t, uint64_t, uint64_t, int64_t, uint64_t);
-typedef int64_t (*iFpiipppp_t)(void*, int64_t, int64_t, void*, void*, void*, void*);
-typedef int64_t (*iFpiuiipp_t)(void*, int64_t, uint64_t, int64_t, int64_t, void*, void*);
-typedef int64_t (*iFpiupiii_t)(void*, int64_t, uint64_t, void*, int64_t, int64_t, int64_t);
-typedef int64_t (*iFpiupppp_t)(void*, int64_t, uint64_t, void*, void*, void*, void*);
-typedef int64_t (*iFpipipip_t)(void*, int64_t, void*, int64_t, void*, int64_t, void*);
-typedef int64_t (*iFpipippp_t)(void*, int64_t, void*, int64_t, void*, void*, void*);
-typedef int64_t (*iFpippLpp_t)(void*, int64_t, void*, void*, uintptr_t, void*, void*);
-typedef int64_t (*iFpippppW_t)(void*, int64_t, void*, void*, void*, void*, uint16_t);
-typedef int64_t (*iFpippppp_t)(void*, int64_t, void*, void*, void*, void*, void*);
-typedef int64_t (*iFpIIpppp_t)(void*, int64_t, int64_t, void*, void*, void*, void*);
-typedef int64_t (*iFpWppppW_t)(void*, uint16_t, void*, void*, void*, void*, uint16_t);
-typedef int64_t (*iFpuiCuCp_t)(void*, uint64_t, int64_t, uint8_t, uint64_t, uint8_t, void*);
-typedef int64_t (*iFpuiuupp_t)(void*, uint64_t, int64_t, uint64_t, uint64_t, void*, void*);
-typedef int64_t (*iFpuuiuui_t)(void*, uint64_t, uint64_t, int64_t, uint64_t, uint64_t, int64_t);
-typedef int64_t (*iFpuupppp_t)(void*, uint64_t, uint64_t, void*, void*, void*, void*);
-typedef int64_t (*iFpupiLpL_t)(void*, uint64_t, void*, int64_t, uintptr_t, void*, uintptr_t);
-typedef int64_t (*iFpupuuui_t)(void*, uint64_t, void*, uint64_t, uint64_t, uint64_t, int64_t);
-typedef int64_t (*iFpupupui_t)(void*, uint64_t, void*, uint64_t, void*, uint64_t, int64_t);
-typedef int64_t (*iFpuppppp_t)(void*, uint64_t, void*, void*, void*, void*, void*);
-typedef int64_t (*iFpLipipi_t)(void*, uintptr_t, int64_t, void*, int64_t, void*, int64_t);
-typedef int64_t (*iFppiiiip_t)(void*, void*, int64_t, int64_t, int64_t, int64_t, void*);
-typedef int64_t (*iFppiiuui_t)(void*, void*, int64_t, int64_t, uint64_t, uint64_t, int64_t);
-typedef int64_t (*iFppiiuup_t)(void*, void*, int64_t, int64_t, uint64_t, uint64_t, void*);
-typedef int64_t (*iFppiipii_t)(void*, void*, int64_t, int64_t, void*, int64_t, int64_t);
-typedef int64_t (*iFppiipiL_t)(void*, void*, int64_t, int64_t, void*, int64_t, uintptr_t);
-typedef int64_t (*iFppiuppi_t)(void*, void*, int64_t, uint64_t, void*, void*, int64_t);
-typedef int64_t (*iFppipiii_t)(void*, void*, int64_t, void*, int64_t, int64_t, int64_t);
-typedef int64_t (*iFppipiip_t)(void*, void*, int64_t, void*, int64_t, int64_t, void*);
-typedef int64_t (*iFppipipi_t)(void*, void*, int64_t, void*, int64_t, void*, int64_t);
-typedef int64_t (*iFppipipp_t)(void*, void*, int64_t, void*, int64_t, void*, void*);
-typedef int64_t (*iFppippip_t)(void*, void*, int64_t, void*, void*, int64_t, void*);
-typedef int64_t (*iFppipppi_t)(void*, void*, int64_t, void*, void*, void*, int64_t);
-typedef int64_t (*iFppipppp_t)(void*, void*, int64_t, void*, void*, void*, void*);
-typedef int64_t (*iFppuipiL_t)(void*, void*, uint64_t, int64_t, void*, int64_t, uintptr_t);
-typedef int64_t (*iFppLiipp_t)(void*, void*, uintptr_t, int64_t, int64_t, void*, void*);
-typedef int64_t (*iFpppiiii_t)(void*, void*, void*, int64_t, int64_t, int64_t, int64_t);
-typedef int64_t (*iFpppiiuu_t)(void*, void*, void*, int64_t, int64_t, uint64_t, uint64_t);
-typedef int64_t (*iFpppiiup_t)(void*, void*, void*, int64_t, int64_t, uint64_t, void*);
-typedef int64_t (*iFpppiipi_t)(void*, void*, void*, int64_t, int64_t, void*, int64_t);
-typedef int64_t (*iFpppiuwu_t)(void*, void*, void*, int64_t, uint64_t, int16_t, uint64_t);
-typedef int64_t (*iFpppippi_t)(void*, void*, void*, int64_t, void*, void*, int64_t);
-typedef int64_t (*iFpppippp_t)(void*, void*, void*, int64_t, void*, void*, void*);
-typedef int64_t (*iFpppuiii_t)(void*, void*, void*, uint64_t, int64_t, int64_t, int64_t);
-typedef int64_t (*iFppppiii_t)(void*, void*, void*, void*, int64_t, int64_t, int64_t);
-typedef int64_t (*iFppppipp_t)(void*, void*, void*, void*, int64_t, void*, void*);
-typedef int64_t (*iFppppdpi_t)(void*, void*, void*, void*, double, void*, int64_t);
-typedef int64_t (*iFpppppip_t)(void*, void*, void*, void*, void*, int64_t, void*);
-typedef int64_t (*iFpppppup_t)(void*, void*, void*, void*, void*, uint64_t, void*);
-typedef int64_t (*iFppppppi_t)(void*, void*, void*, void*, void*, void*, int64_t);
-typedef int64_t (*iFppppppp_t)(void*, void*, void*, void*, void*, void*, void*);
-typedef uint64_t (*uFEiipppp_t)(x64emu_t*, int64_t, int64_t, void*, void*, void*, void*);
-typedef uint64_t (*uFEpiippp_t)(x64emu_t*, void*, int64_t, int64_t, void*, void*, void*);
-typedef uint64_t (*uFEpuuppp_t)(x64emu_t*, void*, uint64_t, uint64_t, void*, void*, void*);
-typedef uint64_t (*uFuippppp_t)(uint64_t, int64_t, void*, void*, void*, void*, void*);
-typedef uint64_t (*uFppiuppp_t)(void*, void*, int64_t, uint64_t, void*, void*, void*);
-typedef uint64_t (*uFppuuuup_t)(void*, void*, uint64_t, uint64_t, uint64_t, uint64_t, void*);
-typedef uintptr_t (*LFEppLppU_t)(x64emu_t*, void*, void*, uintptr_t, void*, void*, uint64_t);
-typedef uintptr_t (*LFEpppppu_t)(x64emu_t*, void*, void*, void*, void*, void*, uint64_t);
-typedef void* (*pFEpLiiii_t)(x64emu_t*, void*, uintptr_t, int64_t, int64_t, int64_t, int64_t);
-typedef void* (*pFEpLiiiI_t)(x64emu_t*, void*, uintptr_t, int64_t, int64_t, int64_t, int64_t);
-typedef void* (*pFEpLiiil_t)(x64emu_t*, void*, uintptr_t, int64_t, int64_t, int64_t, intptr_t);
-typedef void* (*pFEppuipp_t)(x64emu_t*, void*, void*, uint64_t, int64_t, void*, void*);
-typedef void* (*pFEppppip_t)(x64emu_t*, void*, void*, void*, void*, int64_t, void*);
-typedef void* (*pFEpppppi_t)(x64emu_t*, void*, void*, void*, void*, void*, int64_t);
-typedef void* (*pFifffppp_t)(int64_t, float, float, float, void*, void*, void*);
-typedef void* (*pFuupupup_t)(uint64_t, uint64_t, void*, uint64_t, void*, uint64_t, void*);
-typedef void* (*pFdiiiIiI_t)(double, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void* (*pFpiiUdii_t)(void*, int64_t, int64_t, uint64_t, double, int64_t, int64_t);
-typedef void* (*pFpCuwwWW_t)(void*, uint8_t, uint64_t, int16_t, int16_t, uint16_t, uint16_t);
-typedef void* (*pFpCuWCCC_t)(void*, uint8_t, uint64_t, uint16_t, uint8_t, uint8_t, uint8_t);
-typedef void* (*pFpCuuwwp_t)(void*, uint8_t, uint64_t, uint64_t, int16_t, int16_t, void*);
-typedef void* (*pFpCuuuuu_t)(void*, uint8_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void* (*pFpCpWWup_t)(void*, uint8_t, void*, uint16_t, uint16_t, uint64_t, void*);
-typedef void* (*pFpuuuwwu_t)(void*, uint64_t, uint64_t, uint64_t, int16_t, int16_t, uint64_t);
-typedef void* (*pFpuupwwC_t)(void*, uint64_t, uint64_t, void*, int16_t, int16_t, uint8_t);
-typedef void* (*pFplppppp_t)(void*, intptr_t, void*, void*, void*, void*, void*);
-typedef void* (*pFpLppiip_t)(void*, uintptr_t, void*, void*, int64_t, int64_t, void*);
-typedef void* (*pFppiiipp_t)(void*, void*, int64_t, int64_t, int64_t, void*, void*);
-typedef void* (*pFppiiCCC_t)(void*, void*, int64_t, int64_t, uint8_t, uint8_t, uint8_t);
-typedef void* (*pFppiippp_t)(void*, void*, int64_t, int64_t, void*, void*, void*);
-typedef void* (*pFppipipp_t)(void*, void*, int64_t, void*, int64_t, void*, void*);
-typedef void* (*pFppipLpp_t)(void*, void*, int64_t, void*, uintptr_t, void*, void*);
-typedef void* (*pFppuuppp_t)(void*, void*, uint64_t, uint64_t, void*, void*, void*);
-typedef void* (*pFppLiiip_t)(void*, void*, uintptr_t, int64_t, int64_t, int64_t, void*);
-typedef void* (*pFppLipip_t)(void*, void*, uintptr_t, int64_t, void*, int64_t, void*);
-typedef void* (*pFpppccci_t)(void*, void*, void*, int8_t, int8_t, int8_t, int64_t);
-typedef void* (*pFpppiiii_t)(void*, void*, void*, int64_t, int64_t, int64_t, int64_t);
-typedef void* (*pFpppiipp_t)(void*, void*, void*, int64_t, int64_t, void*, void*);
-typedef void* (*pFpppIIIi_t)(void*, void*, void*, int64_t, int64_t, int64_t, int64_t);
-typedef void* (*pFpppCCCi_t)(void*, void*, void*, uint8_t, uint8_t, uint8_t, int64_t);
-typedef void* (*pFpppuuui_t)(void*, void*, void*, uint64_t, uint64_t, uint64_t, int64_t);
-typedef void* (*pFpppuupp_t)(void*, void*, void*, uint64_t, uint64_t, void*, void*);
-typedef void* (*pFpppUUUi_t)(void*, void*, void*, uint64_t, uint64_t, uint64_t, int64_t);
-typedef void* (*pFpppfffi_t)(void*, void*, void*, float, float, float, int64_t);
-typedef void* (*pFpppdddi_t)(void*, void*, void*, double, double, double, int64_t);
-typedef void* (*pFpppllli_t)(void*, void*, void*, intptr_t, intptr_t, intptr_t, int64_t);
-typedef void* (*pFpppLLLi_t)(void*, void*, void*, uintptr_t, uintptr_t, uintptr_t, int64_t);
-typedef void* (*pFppppuuu_t)(void*, void*, void*, void*, uint64_t, uint64_t, uint64_t);
-typedef void* (*pFpppppuu_t)(void*, void*, void*, void*, void*, uint64_t, uint64_t);
-typedef void* (*pFppppppi_t)(void*, void*, void*, void*, void*, void*, int64_t);
-typedef void* (*pFppppppp_t)(void*, void*, void*, void*, void*, void*, void*);
-typedef int64_t (*iWpiiuuuu_t)(void*, int64_t, int64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef int64_t (*iWpuiiiip_t)(void*, uint64_t, int64_t, int64_t, int64_t, int64_t, void*);
-typedef int64_t (*iWpuiiuii_t)(void*, uint64_t, int64_t, int64_t, uint64_t, int64_t, int64_t);
-typedef int64_t (*iWpuipupp_t)(void*, uint64_t, int64_t, void*, uint64_t, void*, void*);
-typedef int64_t (*iWpuuuppu_t)(void*, uint64_t, uint64_t, uint64_t, void*, void*, uint64_t);
-typedef int64_t (*iWpupuufu_t)(void*, uint64_t, void*, uint64_t, uint64_t, float, uint64_t);
-typedef int64_t (*iWpppuppp_t)(void*, void*, void*, uint64_t, void*, void*, void*);
-typedef void (*vFEiippppV_t)(x64emu_t*, int64_t, int64_t, void*, void*, void*, void*, void*);
-typedef void (*vFEiupippp_t)(x64emu_t*, int64_t, uint64_t, void*, int64_t, void*, void*, void*);
-typedef void (*vFEipAippp_t)(x64emu_t*, int64_t, void*, void*, int64_t, void*, void*, void*);
-typedef void (*vFEppipppp_t)(x64emu_t*, void*, void*, int64_t, void*, void*, void*, void*);
-typedef void (*vFEpppippp_t)(x64emu_t*, void*, void*, void*, int64_t, void*, void*, void*);
-typedef void (*vFEpppuipV_t)(x64emu_t*, void*, void*, void*, uint64_t, int64_t, void*, void*);
-typedef void (*vFEpppppuu_t)(x64emu_t*, void*, void*, void*, void*, void*, uint64_t, uint64_t);
-typedef void (*vFiiiiuuip_t)(int64_t, int64_t, int64_t, int64_t, uint64_t, uint64_t, int64_t, void*);
-typedef void (*vFiilliilp_t)(int64_t, int64_t, intptr_t, intptr_t, int64_t, int64_t, intptr_t, void*);
-typedef void (*vFililliuU_t)(int64_t, intptr_t, int64_t, intptr_t, intptr_t, int64_t, uint64_t, uint64_t);
-typedef void (*vFilillluU_t)(int64_t, intptr_t, int64_t, intptr_t, intptr_t, intptr_t, uint64_t, uint64_t);
-typedef void (*vFilipufip_t)(int64_t, intptr_t, int64_t, void*, uint64_t, float, int64_t, void*);
-typedef void (*vFuiiiiiii_t)(uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFuiiiiill_t)(uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, intptr_t, intptr_t);
-typedef void (*vFuiiiiuup_t)(uint64_t, int64_t, int64_t, int64_t, int64_t, uint64_t, uint64_t, void*);
-typedef void (*vFuiuiiiii_t)(uint64_t, int64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFuiuiiiip_t)(uint64_t, int64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, void*);
-typedef void (*vFuiuiuuuu_t)(uint64_t, int64_t, uint64_t, int64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFuiulplpp_t)(uint64_t, int64_t, uint64_t, intptr_t, void*, intptr_t, void*, void*);
-typedef void (*vFuipuliuf_t)(uint64_t, int64_t, void*, uint64_t, intptr_t, int64_t, uint64_t, float);
-typedef void (*vFuuiiiiii_t)(uint64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFuuiiiuip_t)(uint64_t, uint64_t, int64_t, int64_t, int64_t, uint64_t, int64_t, void*);
-typedef void (*vFuuiiiuup_t)(uint64_t, uint64_t, int64_t, int64_t, int64_t, uint64_t, uint64_t, void*);
-typedef void (*vFuuiiuupp_t)(uint64_t, uint64_t, int64_t, int64_t, uint64_t, uint64_t, void*, void*);
-typedef void (*vFuuiuiiii_t)(uint64_t, uint64_t, int64_t, uint64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFuuiuiiip_t)(uint64_t, uint64_t, int64_t, uint64_t, int64_t, int64_t, int64_t, void*);
-typedef void (*vFuuuiiiii_t)(uint64_t, uint64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFuuuiuiii_t)(uint64_t, uint64_t, uint64_t, int64_t, uint64_t, int64_t, int64_t, int64_t);
-typedef void (*vFuuuipipp_t)(uint64_t, uint64_t, uint64_t, int64_t, void*, int64_t, void*, void*);
-typedef void (*vFuuuuuuuu_t)(uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFuuuuufff_t)(uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, float, float, float);
-typedef void (*vFuuufffff_t)(uint64_t, uint64_t, uint64_t, float, float, float, float, float);
-typedef void (*vFulilliuU_t)(uint64_t, intptr_t, int64_t, intptr_t, intptr_t, int64_t, uint64_t, uint64_t);
-typedef void (*vFulillluU_t)(uint64_t, intptr_t, int64_t, intptr_t, intptr_t, intptr_t, uint64_t, uint64_t);
-typedef void (*vFulllplip_t)(uint64_t, intptr_t, intptr_t, intptr_t, void*, intptr_t, int64_t, void*);
-typedef void (*vFffffffff_t)(float, float, float, float, float, float, float, float);
-typedef void (*vFlipuiuip_t)(intptr_t, int64_t, void*, uint64_t, int64_t, uint64_t, int64_t, void*);
-typedef void (*vFpiiiiiii_t)(void*, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFpiiiipii_t)(void*, int64_t, int64_t, int64_t, int64_t, void*, int64_t, int64_t);
-typedef void (*vFpiiULipp_t)(void*, int64_t, int64_t, uint64_t, uintptr_t, int64_t, void*, void*);
-typedef void (*vFpiUuupup_t)(void*, int64_t, uint64_t, uint64_t, uint64_t, void*, uint64_t, void*);
-typedef void (*vFpippiiuu_t)(void*, int64_t, void*, void*, int64_t, int64_t, uint64_t, uint64_t);
-typedef void (*vFpippiipi_t)(void*, int64_t, void*, void*, int64_t, int64_t, void*, int64_t);
-typedef void (*vFpuppLLLL_t)(void*, uint64_t, void*, void*, uintptr_t, uintptr_t, uintptr_t, uintptr_t);
-typedef void (*vFpUiUiupi_t)(void*, uint64_t, int64_t, uint64_t, int64_t, uint64_t, void*, int64_t);
-typedef void (*vFpUuuUUUi_t)(void*, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, int64_t);
-typedef void (*vFppiiiiii_t)(void*, void*, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFppiiipii_t)(void*, void*, int64_t, int64_t, int64_t, void*, int64_t, int64_t);
-typedef void (*vFppipipii_t)(void*, void*, int64_t, void*, int64_t, void*, int64_t, int64_t);
-typedef void (*vFppipppui_t)(void*, void*, int64_t, void*, void*, void*, uint64_t, int64_t);
-typedef void (*vFppippppi_t)(void*, void*, int64_t, void*, void*, void*, void*, int64_t);
-typedef void (*vFppippppp_t)(void*, void*, int64_t, void*, void*, void*, void*, void*);
-typedef void (*vFpplppppi_t)(void*, void*, intptr_t, void*, void*, void*, void*, int64_t);
-typedef void (*vFpplppppp_t)(void*, void*, intptr_t, void*, void*, void*, void*, void*);
-typedef void (*vFppppiipi_t)(void*, void*, void*, void*, int64_t, int64_t, void*, int64_t);
-typedef void (*vFpppppuuu_t)(void*, void*, void*, void*, void*, uint64_t, uint64_t, uint64_t);
-typedef void (*vFpppppppp_t)(void*, void*, void*, void*, void*, void*, void*, void*);
-typedef int64_t (*iFEpippppp_t)(x64emu_t*, void*, int64_t, void*, void*, void*, void*, void*);
-typedef int64_t (*iFEpuuLppp_t)(x64emu_t*, void*, uint64_t, uint64_t, uintptr_t, void*, void*, void*);
-typedef int64_t (*iFEpUUuppp_t)(x64emu_t*, void*, uint64_t, uint64_t, uint64_t, void*, void*, void*);
-typedef int64_t (*iFEppipppp_t)(x64emu_t*, void*, void*, int64_t, void*, void*, void*, void*);
-typedef int64_t (*iFEppppipp_t)(x64emu_t*, void*, void*, void*, void*, int64_t, void*, void*);
-typedef int64_t (*iFiiiiiiip_t)(int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, void*);
-typedef int64_t (*iFiiupiupi_t)(int64_t, int64_t, uint64_t, void*, int64_t, uint64_t, void*, int64_t);
-typedef int64_t (*iFipippppp_t)(int64_t, void*, int64_t, void*, void*, void*, void*, void*);
-typedef int64_t (*iFuipuuluf_t)(uint64_t, int64_t, void*, uint64_t, uint64_t, intptr_t, uint64_t, float);
-typedef int64_t (*iFuuuuuuuu_t)(uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef int64_t (*iFullfpppp_t)(uint64_t, intptr_t, intptr_t, float, void*, void*, void*, void*);
-typedef int64_t (*iFpippuuii_t)(void*, int64_t, void*, void*, uint64_t, uint64_t, int64_t, int64_t);
-typedef int64_t (*iFpCCWWpWu_t)(void*, uint8_t, uint8_t, uint16_t, uint16_t, void*, uint16_t, uint64_t);
-typedef int64_t (*iFpWCuWCuu_t)(void*, uint16_t, uint8_t, uint64_t, uint16_t, uint8_t, uint64_t, uint64_t);
-typedef int64_t (*iFpWWipppp_t)(void*, uint16_t, uint16_t, int64_t, void*, void*, void*, void*);
-typedef int64_t (*iFpuiipppp_t)(void*, uint64_t, int64_t, int64_t, void*, void*, void*, void*);
-typedef int64_t (*iFpuippLpp_t)(void*, uint64_t, int64_t, void*, void*, uintptr_t, void*, void*);
-typedef int64_t (*iFpuuiiiii_t)(void*, uint64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef int64_t (*iFpuuupupu_t)(void*, uint64_t, uint64_t, uint64_t, void*, uint64_t, void*, uint64_t);
-typedef int64_t (*iFpupppWWu_t)(void*, uint64_t, void*, void*, void*, uint16_t, uint16_t, uint64_t);
-typedef int64_t (*iFpupppppp_t)(void*, uint64_t, void*, void*, void*, void*, void*, void*);
-typedef int64_t (*iFpUuuLpUi_t)(void*, uint64_t, uint64_t, uint64_t, uintptr_t, void*, uint64_t, int64_t);
-typedef int64_t (*iFpdiiiIiI_t)(void*, double, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef int64_t (*iFpLpipppp_t)(void*, uintptr_t, void*, int64_t, void*, void*, void*, void*);
-typedef int64_t (*iFppiiiiiu_t)(void*, void*, int64_t, int64_t, int64_t, int64_t, int64_t, uint64_t);
-typedef int64_t (*iFppiiipip_t)(void*, void*, int64_t, int64_t, int64_t, void*, int64_t, void*);
-typedef int64_t (*iFppIIIppp_t)(void*, void*, int64_t, int64_t, int64_t, void*, void*, void*);
-typedef int64_t (*iFpppiiipi_t)(void*, void*, void*, int64_t, int64_t, int64_t, void*, int64_t);
-typedef int64_t (*iFpppiippp_t)(void*, void*, void*, int64_t, int64_t, void*, void*, void*);
-typedef int64_t (*iFpppipipi_t)(void*, void*, void*, int64_t, void*, int64_t, void*, int64_t);
-typedef int64_t (*iFppppiipi_t)(void*, void*, void*, void*, int64_t, int64_t, void*, int64_t);
-typedef int64_t (*iFppppippp_t)(void*, void*, void*, void*, int64_t, void*, void*, void*);
-typedef int64_t (*iFppppppii_t)(void*, void*, void*, void*, void*, void*, int64_t, int64_t);
-typedef int64_t (*iFpppppppi_t)(void*, void*, void*, void*, void*, void*, void*, int64_t);
-typedef int64_t (*iFpppppppp_t)(void*, void*, void*, void*, void*, void*, void*, void*);
-typedef uint64_t (*uFEipipppp_t)(x64emu_t*, int64_t, void*, int64_t, void*, void*, void*, void*);
-typedef uint64_t (*uFEpiupppp_t)(x64emu_t*, void*, int64_t, uint64_t, void*, void*, void*, void*);
-typedef uint64_t (*uFEppipppp_t)(x64emu_t*, void*, void*, int64_t, void*, void*, void*, void*);
-typedef uint64_t (*uFEpppuppp_t)(x64emu_t*, void*, void*, void*, uint64_t, void*, void*, void*);
-typedef uint64_t (*uFEppppppp_t)(x64emu_t*, void*, void*, void*, void*, void*, void*, void*);
-typedef uint64_t (*uFuipppppp_t)(uint64_t, int64_t, void*, void*, void*, void*, void*, void*);
-typedef uint64_t (*uFulpppppp_t)(uint64_t, intptr_t, void*, void*, void*, void*, void*, void*);
-typedef uint64_t (*uFpupuuuCp_t)(void*, uint64_t, void*, uint64_t, uint64_t, uint64_t, uint8_t, void*);
-typedef uint64_t (*uFppuuuupp_t)(void*, void*, uint64_t, uint64_t, uint64_t, uint64_t, void*, void*);
-typedef uint64_t (*uFppuuuppi_t)(void*, void*, uint64_t, uint64_t, uint64_t, void*, void*, int64_t);
-typedef uint64_t (*uFppuppppp_t)(void*, void*, uint64_t, void*, void*, void*, void*, void*);
-typedef uintptr_t (*LFELpLpLpi_t)(x64emu_t*, uintptr_t, void*, uintptr_t, void*, uintptr_t, void*, int64_t);
-typedef uintptr_t (*LFEpiupppp_t)(x64emu_t*, void*, int64_t, uint64_t, void*, void*, void*, void*);
-typedef void* (*pFEiplllpp_t)(x64emu_t*, int64_t, void*, intptr_t, intptr_t, intptr_t, void*, void*);
-typedef void* (*pFEpiuCppp_t)(x64emu_t*, void*, int64_t, uint64_t, uint8_t, void*, void*, void*);
-typedef void* (*pFEppLiiip_t)(x64emu_t*, void*, void*, uintptr_t, int64_t, int64_t, int64_t, void*);
-typedef void* (*pFEpppuipV_t)(x64emu_t*, void*, void*, void*, uint64_t, int64_t, void*, void*);
-typedef void* (*pFEpppppiV_t)(x64emu_t*, void*, void*, void*, void*, void*, int64_t, void*);
-typedef void* (*pFEppppppi_t)(x64emu_t*, void*, void*, void*, void*, void*, void*, int64_t);
-typedef void* (*pFEppppppp_t)(x64emu_t*, void*, void*, void*, void*, void*, void*, void*);
-typedef void* (*pFiipppppp_t)(int64_t, int64_t, void*, void*, void*, void*, void*, void*);
-typedef void* (*pFuiiiuuuu_t)(uint64_t, int64_t, int64_t, int64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void* (*pFuupupipp_t)(uint64_t, uint64_t, void*, uint64_t, void*, int64_t, void*, void*);
-typedef void* (*pFpiiiiiuu_t)(void*, int64_t, int64_t, int64_t, int64_t, int64_t, uint64_t, uint64_t);
-typedef void* (*pFpiUdiiUi_t)(void*, int64_t, uint64_t, double, int64_t, int64_t, uint64_t, int64_t);
-typedef void* (*pFpipiiiip_t)(void*, int64_t, void*, int64_t, int64_t, int64_t, int64_t, void*);
-typedef void* (*pFpipppppp_t)(void*, int64_t, void*, void*, void*, void*, void*, void*);
-typedef void* (*pFpCCuuwwC_t)(void*, uint8_t, uint8_t, uint64_t, uint64_t, int16_t, int16_t, uint8_t);
-typedef void* (*pFpCuwwWWu_t)(void*, uint8_t, uint64_t, int16_t, int16_t, uint16_t, uint16_t, uint64_t);
-typedef void* (*pFpCuuuCup_t)(void*, uint8_t, uint64_t, uint64_t, uint64_t, uint8_t, uint64_t, void*);
-typedef void* (*pFpWWiCpup_t)(void*, uint16_t, uint16_t, int64_t, uint8_t, void*, uint64_t, void*);
-typedef void* (*pFpuuWWCuu_t)(void*, uint64_t, uint64_t, uint16_t, uint16_t, uint8_t, uint64_t, uint64_t);
-typedef void* (*pFpuuuuupp_t)(void*, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, void*, void*);
-typedef void* (*pFpuuuupup_t)(void*, uint64_t, uint64_t, uint64_t, uint64_t, void*, uint64_t, void*);
-typedef void* (*pFpuuupwwp_t)(void*, uint64_t, uint64_t, uint64_t, void*, int16_t, int16_t, void*);
-typedef void* (*pFpdwwWWui_t)(void*, double, int16_t, int16_t, uint16_t, uint16_t, uint64_t, int64_t);
-typedef void* (*pFplpppppp_t)(void*, intptr_t, void*, void*, void*, void*, void*, void*);
-typedef void* (*pFppiiiiii_t)(void*, void*, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void* (*pFpppuuLLu_t)(void*, void*, void*, uint64_t, uint64_t, uintptr_t, uintptr_t, uint64_t);
-typedef void* (*pFpppppupp_t)(void*, void*, void*, void*, void*, uint64_t, void*, void*);
-typedef int64_t (*iWEpuuiipp_t)(x64emu_t*, void*, uint64_t, uint64_t, int64_t, int64_t, void*, void*);
-typedef int64_t (*iWEpuuuipp_t)(x64emu_t*, void*, uint64_t, uint64_t, uint64_t, int64_t, void*, void*);
-typedef int64_t (*iWpuipuppp_t)(void*, uint64_t, int64_t, void*, uint64_t, void*, void*, void*);
-typedef void (*vFEpiiiiipp_t)(x64emu_t*, void*, int64_t, int64_t, int64_t, int64_t, int64_t, void*, void*);
-typedef void (*vFEpippippV_t)(x64emu_t*, void*, int64_t, void*, void*, int64_t, void*, void*, void*);
-typedef void (*vFEpippippA_t)(x64emu_t*, void*, int64_t, void*, void*, int64_t, void*, void*, void*);
-typedef void (*vFEpuuuippp_t)(x64emu_t*, void*, uint64_t, uint64_t, uint64_t, int64_t, void*, void*, void*);
-typedef void (*vFEppiipppp_t)(x64emu_t*, void*, void*, int64_t, int64_t, void*, void*, void*, void*);
-typedef void (*vFEpppiippp_t)(x64emu_t*, void*, void*, void*, int64_t, int64_t, void*, void*, void*);
-typedef void (*vFEppppippp_t)(x64emu_t*, void*, void*, void*, void*, int64_t, void*, void*, void*);
-typedef void (*vFiiiiiiiii_t)(int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFiiiiiiill_t)(int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, intptr_t, intptr_t);
-typedef void (*vFiiiiillli_t)(int64_t, int64_t, int64_t, int64_t, int64_t, intptr_t, intptr_t, intptr_t, int64_t);
-typedef void (*vFiiilllilp_t)(int64_t, int64_t, int64_t, intptr_t, intptr_t, intptr_t, int64_t, intptr_t, void*);
-typedef void (*vFilillliuU_t)(int64_t, intptr_t, int64_t, intptr_t, intptr_t, intptr_t, int64_t, uint64_t, uint64_t);
-typedef void (*vFuiiiiiiii_t)(uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFuiiiiiuip_t)(uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, uint64_t, int64_t, void*);
-typedef void (*vFuiiiiiuup_t)(uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, uint64_t, uint64_t, void*);
-typedef void (*vFuiiiillli_t)(uint64_t, int64_t, int64_t, int64_t, int64_t, intptr_t, intptr_t, intptr_t, int64_t);
-typedef void (*vFuiiilliip_t)(uint64_t, int64_t, int64_t, int64_t, intptr_t, intptr_t, int64_t, int64_t, void*);
-typedef void (*vFuiiillilp_t)(uint64_t, int64_t, int64_t, int64_t, intptr_t, intptr_t, int64_t, intptr_t, void*);
-typedef void (*vFuiuiiiiip_t)(uint64_t, int64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, void*);
-typedef void (*vFuuiiiiiii_t)(uint64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFuuiuiiiii_t)(uint64_t, uint64_t, int64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFuuiuiiiip_t)(uint64_t, uint64_t, int64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, void*);
-typedef void (*vFuuiuiiuup_t)(uint64_t, uint64_t, int64_t, uint64_t, int64_t, int64_t, uint64_t, uint64_t, void*);
-typedef void (*vFuuuiiiiip_t)(uint64_t, uint64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, void*);
-typedef void (*vFuuuuuuuuu_t)(uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFuffffffff_t)(uint64_t, float, float, float, float, float, float, float, float);
-typedef void (*vFulillliuU_t)(uint64_t, intptr_t, int64_t, intptr_t, intptr_t, intptr_t, int64_t, uint64_t, uint64_t);
-typedef void (*vFffuuuufff_t)(float, float, uint64_t, uint64_t, uint64_t, uint64_t, float, float, float);
-typedef void (*vFddddddddd_t)(double, double, double, double, double, double, double, double, double);
-typedef void (*vFlipuiuiip_t)(intptr_t, int64_t, void*, uint64_t, int64_t, uint64_t, int64_t, int64_t, void*);
-typedef void (*vFpipiuiipp_t)(void*, int64_t, void*, int64_t, uint64_t, int64_t, int64_t, void*, void*);
-typedef void (*vFpipippppi_t)(void*, int64_t, void*, int64_t, void*, void*, void*, void*, int64_t);
-typedef void (*vFpipppiipi_t)(void*, int64_t, void*, void*, void*, int64_t, int64_t, void*, int64_t);
-typedef void (*vFppiiiiiii_t)(void*, void*, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFppiiiiipi_t)(void*, void*, int64_t, int64_t, int64_t, int64_t, int64_t, void*, int64_t);
-typedef void (*vFppiiipiii_t)(void*, void*, int64_t, int64_t, int64_t, void*, int64_t, int64_t, int64_t);
-typedef void (*vFppiipiiii_t)(void*, void*, int64_t, int64_t, void*, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFppipppiii_t)(void*, void*, int64_t, void*, void*, void*, int64_t, int64_t, int64_t);
-typedef void (*vFppipppiip_t)(void*, void*, int64_t, void*, void*, void*, int64_t, int64_t, void*);
-typedef void (*vFppuuiiiii_t)(void*, void*, uint64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFppUUiUUUU_t)(void*, void*, uint64_t, uint64_t, int64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFppddddidd_t)(void*, void*, double, double, double, double, int64_t, double, double);
-typedef void (*vFpplpppppi_t)(void*, void*, intptr_t, void*, void*, void*, void*, void*, int64_t);
-typedef void (*vFpppiiiiii_t)(void*, void*, void*, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFppppipiip_t)(void*, void*, void*, void*, int64_t, void*, int64_t, int64_t, void*);
-typedef void (*vFpppppippp_t)(void*, void*, void*, void*, void*, int64_t, void*, void*, void*);
-typedef int64_t (*iFEpiiiiipi_t)(x64emu_t*, void*, int64_t, int64_t, int64_t, int64_t, int64_t, void*, int64_t);
-typedef int64_t (*iFEpppipppp_t)(x64emu_t*, void*, void*, void*, int64_t, void*, void*, void*, void*);
-typedef int64_t (*iFEppplPPPP_t)(x64emu_t*, void*, void*, void*, intptr_t, void*, void*, void*, void*);
-typedef int64_t (*iFEpppppupp_t)(x64emu_t*, void*, void*, void*, void*, void*, uint64_t, void*, void*);
-typedef int64_t (*iFEppPPPPPP_t)(x64emu_t*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef int64_t (*iFiiiiiiiip_t)(int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, void*);
-typedef int64_t (*iFiiiipiiip_t)(int64_t, int64_t, int64_t, int64_t, void*, int64_t, int64_t, int64_t, void*);
-typedef int64_t (*iFipiipippi_t)(int64_t, void*, int64_t, int64_t, void*, int64_t, void*, void*, int64_t);
-typedef int64_t (*iFuilpluluf_t)(uint64_t, int64_t, intptr_t, void*, intptr_t, uint64_t, intptr_t, uint64_t, float);
-typedef int64_t (*iFdddpppppp_t)(double, double, double, void*, void*, void*, void*, void*, void*);
-typedef int64_t (*iFpipLpiiip_t)(void*, int64_t, void*, uintptr_t, void*, int64_t, int64_t, int64_t, void*);
-typedef int64_t (*iFpuuuuuuuu_t)(void*, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef int64_t (*iFpdiiiUiUp_t)(void*, double, int64_t, int64_t, int64_t, uint64_t, int64_t, uint64_t, void*);
-typedef int64_t (*iFppiiiiiii_t)(void*, void*, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef int64_t (*iFppiuiippL_t)(void*, void*, int64_t, uint64_t, int64_t, int64_t, void*, void*, uintptr_t);
-typedef int64_t (*iFppLpiippp_t)(void*, void*, uintptr_t, void*, int64_t, int64_t, void*, void*, void*);
-typedef int64_t (*iFpppiiipip_t)(void*, void*, void*, int64_t, int64_t, int64_t, void*, int64_t, void*);
-typedef int64_t (*iFpppiiuuii_t)(void*, void*, void*, int64_t, int64_t, uint64_t, uint64_t, int64_t, int64_t);
-typedef int64_t (*iFpppiipiiu_t)(void*, void*, void*, int64_t, int64_t, void*, int64_t, int64_t, uint64_t);
-typedef int64_t (*iFppppiiupp_t)(void*, void*, void*, void*, int64_t, int64_t, uint64_t, void*, void*);
-typedef int64_t (*iFppppppppu_t)(void*, void*, void*, void*, void*, void*, void*, void*, uint64_t);
-typedef int64_t (*iFppppppppp_t)(void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef uint64_t (*uFEipippppp_t)(x64emu_t*, int64_t, void*, int64_t, void*, void*, void*, void*, void*);
-typedef uint64_t (*uFEpppufppp_t)(x64emu_t*, void*, void*, void*, uint64_t, float, void*, void*, void*);
-typedef uint64_t (*uFppppppppp_t)(void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef uintptr_t (*LFEppppppii_t)(x64emu_t*, void*, void*, void*, void*, void*, void*, int64_t, int64_t);
-typedef void* (*pFEppiiuuLi_t)(x64emu_t*, void*, void*, int64_t, int64_t, uint64_t, uint64_t, uintptr_t, int64_t);
-typedef void* (*pFEppuippuu_t)(x64emu_t*, void*, void*, uint64_t, int64_t, void*, void*, uint64_t, uint64_t);
-typedef void* (*pFEpppppiiV_t)(x64emu_t*, void*, void*, void*, void*, void*, int64_t, int64_t, void*);
-typedef void* (*pFEpppppppi_t)(x64emu_t*, void*, void*, void*, void*, void*, void*, void*, int64_t);
-typedef void* (*pFEpppppppp_t)(x64emu_t*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef void* (*pFpiiiiuuuu_t)(void*, int64_t, int64_t, int64_t, int64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void* (*pFpCuWCCuuu_t)(void*, uint8_t, uint64_t, uint16_t, uint8_t, uint8_t, uint64_t, uint64_t, uint64_t);
-typedef void* (*pFpuuwwWWww_t)(void*, uint64_t, uint64_t, int16_t, int16_t, uint16_t, uint16_t, int16_t, int16_t);
-typedef void* (*pFpupuuuuup_t)(void*, uint64_t, void*, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, void*);
-typedef void* (*pFppiiiiiip_t)(void*, void*, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, void*);
-typedef void* (*pFppiiuuuLL_t)(void*, void*, int64_t, int64_t, uint64_t, uint64_t, uint64_t, uintptr_t, uintptr_t);
-typedef void* (*pFppipppppp_t)(void*, void*, int64_t, void*, void*, void*, void*, void*, void*);
-typedef void* (*pFpppiiiiii_t)(void*, void*, void*, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void* (*pFpppiipppp_t)(void*, void*, void*, int64_t, int64_t, void*, void*, void*, void*);
-typedef void* (*pFpppWWWWWp_t)(void*, void*, void*, uint16_t, uint16_t, uint16_t, uint16_t, uint16_t, void*);
-typedef void* (*pFpppppiipp_t)(void*, void*, void*, void*, void*, int64_t, int64_t, void*, void*);
-typedef void* (*pFpppppuuCC_t)(void*, void*, void*, void*, void*, uint64_t, uint64_t, uint8_t, uint8_t);
-typedef int64_t (*iWEpuuiippu_t)(x64emu_t*, void*, uint64_t, uint64_t, int64_t, int64_t, void*, void*, uint64_t);
-typedef int64_t (*iWEpuuuiipp_t)(x64emu_t*, void*, uint64_t, uint64_t, uint64_t, int64_t, int64_t, void*, void*);
-typedef int64_t (*iWpiuuupipu_t)(void*, int64_t, uint64_t, uint64_t, uint64_t, void*, int64_t, void*, uint64_t);
-typedef int64_t (*iWpuiuuipip_t)(void*, uint64_t, int64_t, uint64_t, uint64_t, int64_t, void*, int64_t, void*);
-typedef int64_t (*iWppppupiii_t)(void*, void*, void*, void*, uint64_t, void*, int64_t, int64_t, int64_t);
-typedef void (*vFEiippppppp_t)(x64emu_t*, int64_t, int64_t, void*, void*, void*, void*, void*, void*, void*);
-typedef void (*vFEpippppppp_t)(x64emu_t*, void*, int64_t, void*, void*, void*, void*, void*, void*, void*);
-typedef void (*vFEpppiipppp_t)(x64emu_t*, void*, void*, void*, int64_t, int64_t, void*, void*, void*, void*);
-typedef void (*vFiiiiiiiiii_t)(int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFiiiiiiiiiu_t)(int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, uint64_t);
-typedef void (*vFiiiiiiiiui_t)(int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, uint64_t, int64_t);
-typedef void (*vFiiillliiip_t)(int64_t, int64_t, int64_t, intptr_t, intptr_t, intptr_t, int64_t, int64_t, int64_t, void*);
-typedef void (*vFuiiiiiiiii_t)(uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFuiiiiiiill_t)(uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, intptr_t, intptr_t);
-typedef void (*vFuiiiiiiuup_t)(uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, uint64_t, uint64_t, void*);
-typedef void (*vFuiiiillllp_t)(uint64_t, int64_t, int64_t, int64_t, int64_t, intptr_t, intptr_t, intptr_t, intptr_t, void*);
-typedef void (*vFuiuiiiiuup_t)(uint64_t, int64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, uint64_t, uint64_t, void*);
-typedef void (*vFuipulipiuf_t)(uint64_t, int64_t, void*, uint64_t, intptr_t, int64_t, void*, int64_t, uint64_t, float);
-typedef void (*vFuuiiiiiiii_t)(uint64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFuuiiiiiuip_t)(uint64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, uint64_t, int64_t, void*);
-typedef void (*vFuuiiiiiuup_t)(uint64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, uint64_t, uint64_t, void*);
-typedef void (*vFuuiuiiiiip_t)(uint64_t, uint64_t, int64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, void*);
-typedef void (*vFuuiuiiiuup_t)(uint64_t, uint64_t, int64_t, uint64_t, int64_t, int64_t, int64_t, uint64_t, uint64_t, void*);
-typedef void (*vFuuuuuuuiii_t)(uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, int64_t, int64_t, int64_t);
-typedef void (*vFuuuuuuuuuu_t)(uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFuffiiffiip_t)(uint64_t, float, float, int64_t, int64_t, float, float, int64_t, int64_t, void*);
-typedef void (*vFuddiiddiip_t)(uint64_t, double, double, int64_t, int64_t, double, double, int64_t, int64_t, void*);
-typedef void (*vFffffffffff_t)(float, float, float, float, float, float, float, float, float, float);
-typedef void (*vFpipippppip_t)(void*, int64_t, void*, int64_t, void*, void*, void*, void*, int64_t, void*);
-typedef void (*vFppiiiiiiii_t)(void*, void*, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFppiiiiipip_t)(void*, void*, int64_t, int64_t, int64_t, int64_t, int64_t, void*, int64_t, void*);
-typedef void (*vFppiipppiip_t)(void*, void*, int64_t, int64_t, void*, void*, void*, int64_t, int64_t, void*);
-typedef void (*vFppiippppii_t)(void*, void*, int64_t, int64_t, void*, void*, void*, void*, int64_t, int64_t);
-typedef void (*vFppipppiiii_t)(void*, void*, int64_t, void*, void*, void*, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFppuuuuiiuu_t)(void*, void*, uint64_t, uint64_t, uint64_t, uint64_t, int64_t, int64_t, uint64_t, uint64_t);
-typedef void (*vFppdddddddd_t)(void*, void*, double, double, double, double, double, double, double, double);
-typedef void (*vFpppppppppp_t)(void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef int64_t (*iFEpiiiiippp_t)(x64emu_t*, void*, int64_t, int64_t, int64_t, int64_t, int64_t, void*, void*, void*);
-typedef int64_t (*iFEpupppLppL_t)(x64emu_t*, void*, uint64_t, void*, void*, void*, uintptr_t, void*, void*, uintptr_t);
-typedef int64_t (*iFEppppppipp_t)(x64emu_t*, void*, void*, void*, void*, void*, void*, int64_t, void*, void*);
-typedef int64_t (*iFEppppppppp_t)(x64emu_t*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef int64_t (*iFiiiiiiiiip_t)(int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, void*);
-typedef int64_t (*iFpiipiiipip_t)(void*, int64_t, int64_t, void*, int64_t, int64_t, int64_t, void*, int64_t, void*);
-typedef int64_t (*iFpippddiidd_t)(void*, int64_t, void*, void*, double, double, int64_t, int64_t, double, double);
-typedef int64_t (*iFpCuWCCCCup_t)(void*, uint8_t, uint64_t, uint16_t, uint8_t, uint8_t, uint8_t, uint8_t, uint64_t, void*);
-typedef int64_t (*iFpuupiuiipp_t)(void*, uint64_t, uint64_t, void*, int64_t, uint64_t, int64_t, int64_t, void*, void*);
-typedef int64_t (*iFpddpippppp_t)(void*, double, double, void*, int64_t, void*, void*, void*, void*, void*);
-typedef int64_t (*iFppuuiiiiii_t)(void*, void*, uint64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef int64_t (*iFppuuiiuupi_t)(void*, void*, uint64_t, uint64_t, int64_t, int64_t, uint64_t, uint64_t, void*, int64_t);
-typedef int64_t (*iFpppiiipipi_t)(void*, void*, void*, int64_t, int64_t, int64_t, void*, int64_t, void*, int64_t);
-typedef int64_t (*iFpppLLipppp_t)(void*, void*, void*, uintptr_t, uintptr_t, int64_t, void*, void*, void*, void*);
-typedef int64_t (*iFppppiiuuii_t)(void*, void*, void*, void*, int64_t, int64_t, uint64_t, uint64_t, int64_t, int64_t);
-typedef int64_t (*iFpppppppipi_t)(void*, void*, void*, void*, void*, void*, void*, int64_t, void*, int64_t);
-typedef uint64_t (*uFpppppppppp_t)(void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef void* (*pFEiippppppp_t)(x64emu_t*, int64_t, int64_t, void*, void*, void*, void*, void*, void*, void*);
-typedef void* (*pFEpiiiiiipp_t)(x64emu_t*, void*, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, void*, void*);
-typedef void* (*pFEpippppppp_t)(x64emu_t*, void*, int64_t, void*, void*, void*, void*, void*, void*, void*);
-typedef void* (*pFpCuWCCuuCW_t)(void*, uint8_t, uint64_t, uint16_t, uint8_t, uint8_t, uint64_t, uint64_t, uint8_t, uint16_t);
-typedef void* (*pFpuwwWWuCuu_t)(void*, uint64_t, int16_t, int16_t, uint16_t, uint16_t, uint64_t, uint8_t, uint64_t, uint64_t);
-typedef void* (*pFpuuuwwwwWW_t)(void*, uint64_t, uint64_t, uint64_t, int16_t, int16_t, int16_t, int16_t, uint16_t, uint16_t);
-typedef void* (*pFpuuuWWWCCi_t)(void*, uint64_t, uint64_t, uint64_t, uint16_t, uint16_t, uint16_t, uint8_t, uint8_t, int64_t);
-typedef void* (*pFplllllllll_t)(void*, intptr_t, intptr_t, intptr_t, intptr_t, intptr_t, intptr_t, intptr_t, intptr_t, intptr_t);
-typedef void* (*pFppuiipuuii_t)(void*, void*, uint64_t, int64_t, int64_t, void*, uint64_t, uint64_t, int64_t, int64_t);
-typedef void* (*pFpppppppppp_t)(void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef int64_t (*iWEpuipupppp_t)(x64emu_t*, void*, uint64_t, int64_t, void*, uint64_t, void*, void*, void*, void*);
-typedef int64_t (*iWEpuuiiuipp_t)(x64emu_t*, void*, uint64_t, uint64_t, int64_t, int64_t, uint64_t, int64_t, void*, void*);
-typedef int64_t (*iWEpuuuuiipp_t)(x64emu_t*, void*, uint64_t, uint64_t, uint64_t, uint64_t, int64_t, int64_t, void*, void*);
-typedef void (*vFEpiiiupupup_t)(x64emu_t*, void*, int64_t, int64_t, int64_t, uint64_t, void*, uint64_t, void*, uint64_t, void*);
-typedef void (*vFiiiiillliip_t)(int64_t, int64_t, int64_t, int64_t, int64_t, intptr_t, intptr_t, intptr_t, int64_t, int64_t, void*);
-typedef void (*vFiiiiilllilp_t)(int64_t, int64_t, int64_t, int64_t, int64_t, intptr_t, intptr_t, intptr_t, int64_t, intptr_t, void*);
-typedef void (*vFuiiiiiiiiip_t)(uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, void*);
-typedef void (*vFuiiiiiiiuip_t)(uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, uint64_t, int64_t, void*);
-typedef void (*vFuiiiiiiiuup_t)(uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, uint64_t, uint64_t, void*);
-typedef void (*vFuiiiillliip_t)(uint64_t, int64_t, int64_t, int64_t, int64_t, intptr_t, intptr_t, intptr_t, int64_t, int64_t, void*);
-typedef void (*vFuiiiilllilp_t)(uint64_t, int64_t, int64_t, int64_t, int64_t, intptr_t, intptr_t, intptr_t, int64_t, intptr_t, void*);
-typedef void (*vFuiuiiiiiuup_t)(uint64_t, int64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, uint64_t, uint64_t, void*);
-typedef void (*vFuuiuiiiiuup_t)(uint64_t, uint64_t, int64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, uint64_t, uint64_t, void*);
-typedef void (*vFuuuuuuuuuuu_t)(uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFuuupupppppp_t)(uint64_t, uint64_t, uint64_t, void*, uint64_t, void*, void*, void*, void*, void*, void*);
-typedef void (*vFuuffiiffiip_t)(uint64_t, uint64_t, float, float, int64_t, int64_t, float, float, int64_t, int64_t, void*);
-typedef void (*vFuufffffffff_t)(uint64_t, uint64_t, float, float, float, float, float, float, float, float, float);
-typedef void (*vFuuddiiddiip_t)(uint64_t, uint64_t, double, double, int64_t, int64_t, double, double, int64_t, int64_t, void*);
-typedef void (*vFuffffffffff_t)(uint64_t, float, float, float, float, float, float, float, float, float, float);
-typedef void (*vFUufffffffff_t)(uint64_t, uint64_t, float, float, float, float, float, float, float, float, float);
-typedef void (*vFpipipiipiii_t)(void*, int64_t, void*, int64_t, void*, int64_t, int64_t, void*, int64_t, int64_t, int64_t);
-typedef void (*vFpipppiiiipi_t)(void*, int64_t, void*, void*, void*, int64_t, int64_t, int64_t, int64_t, void*, int64_t);
-typedef void (*vFpupiiupupup_t)(void*, uint64_t, void*, int64_t, int64_t, uint64_t, void*, uint64_t, void*, uint64_t, void*);
-typedef void (*vFppiiiiiiiii_t)(void*, void*, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFppiiiiipiii_t)(void*, void*, int64_t, int64_t, int64_t, int64_t, int64_t, void*, int64_t, int64_t, int64_t);
-typedef void (*vFppiiiiddddi_t)(void*, void*, int64_t, int64_t, int64_t, int64_t, double, double, double, double, int64_t);
-typedef void (*vFppiipppiiii_t)(void*, void*, int64_t, int64_t, void*, void*, void*, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFppipppiiiii_t)(void*, void*, int64_t, void*, void*, void*, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFppipppuiiii_t)(void*, void*, int64_t, void*, void*, void*, uint64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFppppppppppp_t)(void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef int64_t (*iFEpppipppppp_t)(x64emu_t*, void*, void*, void*, int64_t, void*, void*, void*, void*, void*, void*);
-typedef int64_t (*iFEppppiiiiuu_t)(x64emu_t*, void*, void*, void*, void*, int64_t, int64_t, int64_t, int64_t, uint64_t, uint64_t);
-typedef int64_t (*iFiiiiiiiiiip_t)(int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, void*);
-typedef int64_t (*iFpiippiiipip_t)(void*, int64_t, int64_t, void*, void*, int64_t, int64_t, int64_t, void*, int64_t, void*);
-typedef int64_t (*iFppippipppip_t)(void*, void*, int64_t, void*, void*, int64_t, void*, void*, void*, int64_t, void*);
-typedef int64_t (*iFpppiiuuiiuu_t)(void*, void*, void*, int64_t, int64_t, uint64_t, uint64_t, int64_t, int64_t, uint64_t, uint64_t);
-typedef int64_t (*iFppppiiuuiiL_t)(void*, void*, void*, void*, int64_t, int64_t, uint64_t, uint64_t, int64_t, int64_t, uintptr_t);
-typedef uint64_t (*uFEpLiupppLuV_t)(x64emu_t*, void*, uintptr_t, int64_t, uint64_t, void*, void*, void*, uintptr_t, uint64_t, void*);
-typedef uint64_t (*uFEpLippppLup_t)(x64emu_t*, void*, uintptr_t, int64_t, void*, void*, void*, void*, uintptr_t, uint64_t, void*);
-typedef uint64_t (*uFEpLippppLuA_t)(x64emu_t*, void*, uintptr_t, int64_t, void*, void*, void*, void*, uintptr_t, uint64_t, void*);
-typedef uint64_t (*uFEppppppippp_t)(x64emu_t*, void*, void*, void*, void*, void*, void*, int64_t, void*, void*, void*);
-typedef uint64_t (*uFppppppppppp_t)(void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef void* (*pFEpipppppppi_t)(x64emu_t*, void*, int64_t, void*, void*, void*, void*, void*, void*, void*, int64_t);
-typedef void* (*pFEppiiLpppip_t)(x64emu_t*, void*, void*, int64_t, int64_t, uintptr_t, void*, void*, void*, int64_t, void*);
-typedef void* (*pFEppuiipuuii_t)(x64emu_t*, void*, void*, uint64_t, int64_t, int64_t, void*, uint64_t, uint64_t, int64_t, int64_t);
-typedef void* (*pFpppppppiipp_t)(void*, void*, void*, void*, void*, void*, void*, int64_t, int64_t, void*, void*);
-typedef void* (*pFppppppppppp_t)(void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef int64_t (*iWEpuipuppppp_t)(x64emu_t*, void*, uint64_t, int64_t, void*, uint64_t, void*, void*, void*, void*, void*);
-typedef int64_t (*iWEpuuiiuippu_t)(x64emu_t*, void*, uint64_t, uint64_t, int64_t, int64_t, uint64_t, int64_t, void*, void*, uint64_t);
-typedef int64_t (*iWEpuuuuuiipp_t)(x64emu_t*, void*, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, int64_t, int64_t, void*, void*);
-typedef void (*vFuiiiillliilp_t)(uint64_t, int64_t, int64_t, int64_t, int64_t, intptr_t, intptr_t, intptr_t, int64_t, int64_t, intptr_t, void*);
-typedef void (*vFuuiiiiiiiiui_t)(uint64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, uint64_t, int64_t);
-typedef void (*vFuuiiiiiiiuip_t)(uint64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, uint64_t, int64_t, void*);
-typedef void (*vFuuiiiiiiiuup_t)(uint64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, uint64_t, uint64_t, void*);
-typedef void (*vFuuuuuuuuuuuu_t)(uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFffffffffffff_t)(float, float, float, float, float, float, float, float, float, float, float, float);
-typedef void (*vFpipppiiiipii_t)(void*, int64_t, void*, void*, void*, int64_t, int64_t, int64_t, int64_t, void*, int64_t, int64_t);
-typedef void (*vFpippppiiiipi_t)(void*, int64_t, void*, void*, void*, void*, int64_t, int64_t, int64_t, int64_t, void*, int64_t);
-typedef void (*vFppiiiiddddii_t)(void*, void*, int64_t, int64_t, int64_t, int64_t, double, double, double, double, int64_t, int64_t);
-typedef void (*vFppiiuuuiupup_t)(void*, void*, int64_t, int64_t, uint64_t, uint64_t, uint64_t, int64_t, uint64_t, void*, uint64_t, void*);
-typedef void (*vFppiipppiiiii_t)(void*, void*, int64_t, int64_t, void*, void*, void*, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFpppiiiiiiiii_t)(void*, void*, void*, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFpppppppppppp_t)(void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef int64_t (*iFEpppippppppp_t)(x64emu_t*, void*, void*, void*, int64_t, void*, void*, void*, void*, void*, void*, void*);
-typedef int64_t (*iFEppppiiiiuui_t)(x64emu_t*, void*, void*, void*, void*, int64_t, int64_t, int64_t, int64_t, uint64_t, uint64_t, int64_t);
-typedef int64_t (*iFpipllipppppp_t)(void*, int64_t, void*, intptr_t, intptr_t, int64_t, void*, void*, void*, void*, void*, void*);
-typedef int64_t (*iFpipppppppppp_t)(void*, int64_t, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef int64_t (*iFpCCCWCWCCCWp_t)(void*, uint8_t, uint8_t, uint8_t, uint16_t, uint8_t, uint16_t, uint8_t, uint8_t, uint8_t, uint16_t, void*);
-typedef int64_t (*iFpppllipppppp_t)(void*, void*, void*, intptr_t, intptr_t, int64_t, void*, void*, void*, void*, void*, void*);
-typedef int64_t (*iFpppppppppppp_t)(void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef void* (*pFEppiiuuuipii_t)(x64emu_t*, void*, void*, int64_t, int64_t, uint64_t, uint64_t, uint64_t, int64_t, void*, int64_t, int64_t);
-typedef void* (*pFEppppppppppp_t)(x64emu_t*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef void* (*pFWWiCCCCiipup_t)(uint16_t, uint16_t, int64_t, uint8_t, uint8_t, uint8_t, uint8_t, int64_t, int64_t, void*, uint64_t, void*);
-typedef void* (*pFpCuuWWwwCCup_t)(void*, uint8_t, uint64_t, uint64_t, uint16_t, uint16_t, int16_t, int16_t, uint8_t, uint8_t, uint64_t, void*);
-typedef void* (*pFpuuuWWWWWWWW_t)(void*, uint64_t, uint64_t, uint64_t, uint16_t, uint16_t, uint16_t, uint16_t, uint16_t, uint16_t, uint16_t, uint16_t);
-typedef void* (*pFppiiuuuiupLp_t)(void*, void*, int64_t, int64_t, uint64_t, uint64_t, uint64_t, int64_t, uint64_t, void*, uintptr_t, void*);
-typedef void* (*pFpppppppppppp_t)(void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef void (*vFEpppppppiippp_t)(x64emu_t*, void*, void*, void*, void*, void*, void*, void*, int64_t, int64_t, void*, void*, void*);
-typedef void (*vFuiiiiiiiiiuup_t)(uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, uint64_t, uint64_t, void*);
-typedef void (*vFuuuuuuuuuuuuu_t)(uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFuffffffffffff_t)(uint64_t, float, float, float, float, float, float, float, float, float, float, float, float);
-typedef void (*vFpipppiiiiiiuu_t)(void*, int64_t, void*, void*, void*, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, uint64_t, uint64_t);
-typedef void (*vFpippppppppppp_t)(void*, int64_t, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef void (*vFppiiiiiiiiiii_t)(void*, void*, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFppiipppiiiiii_t)(void*, void*, int64_t, int64_t, void*, void*, void*, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFppppppppppppp_t)(void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef int64_t (*iFddddpppddpppp_t)(double, double, double, double, void*, void*, void*, double, double, void*, void*, void*, void*);
-typedef int64_t (*iFpippuuuiipppp_t)(void*, int64_t, void*, void*, uint64_t, uint64_t, uint64_t, int64_t, int64_t, void*, void*, void*, void*);
-typedef int64_t (*iFpupiiiipppppp_t)(void*, uint64_t, void*, int64_t, int64_t, int64_t, int64_t, void*, void*, void*, void*, void*, void*);
-typedef uint64_t (*uFppppuuupppppp_t)(void*, void*, void*, void*, uint64_t, uint64_t, uint64_t, void*, void*, void*, void*, void*, void*);
-typedef void* (*pFpCuuwwWWWWuup_t)(void*, uint8_t, uint64_t, uint64_t, int16_t, int16_t, uint16_t, uint16_t, uint16_t, uint16_t, uint64_t, uint64_t, void*);
-typedef void* (*pFpuupppwwwwWWC_t)(void*, uint64_t, uint64_t, void*, void*, void*, int16_t, int16_t, int16_t, int16_t, uint16_t, uint16_t, uint8_t);
-typedef void* (*pFppppppppppppp_t)(void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef void (*vFuffiiffiiffiip_t)(uint64_t, float, float, int64_t, int64_t, float, float, int64_t, int64_t, float, float, int64_t, int64_t, void*);
-typedef void (*vFuddiiddiiddiip_t)(uint64_t, double, double, int64_t, int64_t, double, double, int64_t, int64_t, double, double, int64_t, int64_t, void*);
-typedef void (*vFppiipppiiiiiii_t)(void*, void*, int64_t, int64_t, void*, void*, void*, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef int64_t (*iFpipppppppppppp_t)(void*, int64_t, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef int64_t (*iFpppwwWWwwWWpuu_t)(void*, void*, void*, int16_t, int16_t, uint16_t, uint16_t, int16_t, int16_t, uint16_t, uint16_t, void*, uint64_t, uint64_t);
-typedef void* (*pFppCpppwwwwwwWW_t)(void*, void*, uint8_t, void*, void*, void*, int16_t, int16_t, int16_t, int16_t, int16_t, int16_t, uint16_t, uint16_t);
-typedef void (*vFuiiiiiuiiiiilll_t)(uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, intptr_t, intptr_t, intptr_t);
-typedef void (*vFuuiiiiuuiiiiiii_t)(uint64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, uint64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFfffffffffffffff_t)(float, float, float, float, float, float, float, float, float, float, float, float, float, float, float);
-typedef void (*vFpUUUUUUUUUUUuuu_t)(void*, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t);
-typedef void (*vFpppippppppppppp_t)(void*, void*, void*, int64_t, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef void (*vFppppppppppppppp_t)(void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef void* (*pFpuiippppppppppp_t)(void*, uint64_t, int64_t, int64_t, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef void* (*pFppipppppppppppp_t)(void*, void*, int64_t, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef void* (*pFppppppppppppppp_t)(void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef void (*vFpppppppppppppppp_t)(void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef int64_t (*iFpppppppppppppppp_t)(void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef void* (*pFpuuWWWWWWwwCCCuu_t)(void*, uint64_t, uint64_t, uint16_t, uint16_t, uint16_t, uint16_t, uint16_t, uint16_t, int16_t, int16_t, uint8_t, uint8_t, uint8_t, uint64_t, uint64_t);
-typedef void* (*pFppipipipipipipip_t)(void*, void*, int64_t, void*, int64_t, void*, int64_t, void*, int64_t, void*, int64_t, void*, int64_t, void*, int64_t, void*);
-typedef void* (*pFpppppppppppppppp_t)(void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef void (*vFuuuiiiiiuiiiiilll_t)(uint64_t, uint64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, intptr_t, intptr_t, intptr_t);
-typedef void (*vFppiiiiddddiiiiiuu_t)(void*, void*, int64_t, int64_t, int64_t, int64_t, double, double, double, double, int64_t, int64_t, int64_t, int64_t, int64_t, uint64_t, uint64_t);
-typedef void (*vFpppuppiipppuUUUpi_t)(void*, void*, void*, uint64_t, void*, void*, int64_t, int64_t, void*, void*, void*, uint64_t, uint64_t, uint64_t, uint64_t, void*, int64_t);
-typedef void* (*pFpuuuuuwwuuuuUUUup_t)(void*, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, int16_t, int16_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, uint64_t, void*);
-typedef void* (*pFppippipipipipipip_t)(void*, void*, int64_t, void*, void*, int64_t, void*, int64_t, void*, int64_t, void*, int64_t, void*, int64_t, void*, int64_t, void*);
-typedef void (*vFppuiiiiipuiiiiiiii_t)(void*, void*, uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, void*, uint64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void (*vFpppipppppppppppppp_t)(void*, void*, void*, int64_t, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef int64_t (*iFpppppppppppppppppp_t)(void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef uintptr_t (*LFpppppppppppppppppp_t)(void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef void* (*pFippppppppppppppppp_t)(int64_t, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef void (*vFpiiiiiiiiiiiiiiiiii_t)(void*, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t, int64_t);
-typedef void* (*pFiiiippppppppppppppp_t)(int64_t, int64_t, int64_t, int64_t, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef void* (*pFpippppppppppppppppp_t)(void*, int64_t, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef void* (*pFpppWWCCpCpCpCWpCpCpC_t)(void*, void*, void*, uint16_t, uint16_t, uint8_t, uint8_t, void*, uint8_t, void*, uint8_t, void*, uint8_t, uint16_t, void*, uint8_t, void*, uint8_t, void*, uint8_t);
-typedef int64_t (*iFpppppppppppppppppppppp_t)(void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef void (*vFpppppppppppppppppppppppp_t)(void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-typedef int64_t (*iFpppppppppppppppppppppppppppppppppp_t)(void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*, void*);
-
-#if defined(HAVE_LD80BITS)
-typedef int64_t (*IFD_t)(long double);
-typedef long double (*DFD_t)(long double);
-typedef void (*vFppippDDC_t)(void*, void*, int64_t, void*, void*, long double, long double, uint8_t);
-#endif
-
-#if !defined(HAVE_LD80BITS)
-typedef int64_t (*IFK_t)(double);
-typedef double (*KFK_t)(double);
-typedef double (*KFKK_t)(double, double);
-typedef double (*KFKp_t)(double, void*);
-typedef void (*vFppippKKC_t)(void*, void*, int64_t, void*, void*, double, double, uint8_t);
-#endif
-
-#if defined(NOALIGN)
-typedef int64_t (*iFipiip_t)(int64_t, void*, int64_t, int64_t, void*);
-#endif
-
-#if !defined(NOALIGN)
-typedef int64_t (*iFEppu_t)(x64emu_t*, void*, void*, uint64_t);
-typedef int64_t (*iFEiiip_t)(x64emu_t*, int64_t, int64_t, int64_t, void*);
-typedef int64_t (*iFEipii_t)(x64emu_t*, int64_t, void*, int64_t, int64_t);
-typedef int64_t (*iFEipiip_t)(x64emu_t*, int64_t, void*, int64_t, int64_t, void*);
-#endif
-
-void vFE(x64emu_t *emu, uintptr_t fcn) { vFE_t fn = (vFE_t)fcn; fn(emu); }
-void vFv(x64emu_t *emu, uintptr_t fcn) { vFv_t fn = (vFv_t)fcn; fn(); (void)emu; }
-void vFi(x64emu_t *emu, uintptr_t fcn) { vFi_t fn = (vFi_t)fcn; fn((int64_t)R_RDI); }
-void vFu(x64emu_t *emu, uintptr_t fcn) { vFu_t fn = (vFu_t)fcn; fn((uint64_t)R_RDI); }
-void vFU(x64emu_t *emu, uintptr_t fcn) { vFU_t fn = (vFU_t)fcn; fn((uint64_t)R_RDI); }
-void vFf(x64emu_t *emu, uintptr_t fcn) { vFf_t fn = (vFf_t)fcn; fn(emu->xmm[0].f[0]); }
-void vFd(x64emu_t *emu, uintptr_t fcn) { vFd_t fn = (vFd_t)fcn; fn(emu->xmm[0].d[0]); }
-void vFl(x64emu_t *emu, uintptr_t fcn) { vFl_t fn = (vFl_t)fcn; fn((intptr_t)R_RDI); }
-void vFL(x64emu_t *emu, uintptr_t fcn) { vFL_t fn = (vFL_t)fcn; fn((uintptr_t)R_RDI); }
-void vFp(x64emu_t *emu, uintptr_t fcn) { vFp_t fn = (vFp_t)fcn; fn((void*)R_RDI); }
-void vFS(x64emu_t *emu, uintptr_t fcn) { vFS_t fn = (vFS_t)fcn; fn(io_convert((void*)R_RDI)); }
-void cFv(x64emu_t *emu, uintptr_t fcn) { cFv_t fn = (cFv_t)fcn; R_RAX=fn(); }
-void cFi(x64emu_t *emu, uintptr_t fcn) { cFi_t fn = (cFi_t)fcn; R_RAX=fn((int64_t)R_RDI); }
-void cFu(x64emu_t *emu, uintptr_t fcn) { cFu_t fn = (cFu_t)fcn; R_RAX=fn((uint64_t)R_RDI); }
-void cFf(x64emu_t *emu, uintptr_t fcn) { cFf_t fn = (cFf_t)fcn; R_RAX=fn(emu->xmm[0].f[0]); }
-void cFp(x64emu_t *emu, uintptr_t fcn) { cFp_t fn = (cFp_t)fcn; R_RAX=fn((void*)R_RDI); }
-void wFp(x64emu_t *emu, uintptr_t fcn) { wFp_t fn = (wFp_t)fcn; R_RAX=fn((void*)R_RDI); }
-void iFE(x64emu_t *emu, uintptr_t fcn) { iFE_t fn = (iFE_t)fcn; R_RAX=(int64_t)fn(emu); }
-void iFv(x64emu_t *emu, uintptr_t fcn) { iFv_t fn = (iFv_t)fcn; R_RAX=(int64_t)fn(); }
-void iFw(x64emu_t *emu, uintptr_t fcn) { iFw_t fn = (iFw_t)fcn; R_RAX=(int64_t)fn((int16_t)R_RDI); }
-void iFi(x64emu_t *emu, uintptr_t fcn) { iFi_t fn = (iFi_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI); }
-void iFI(x64emu_t *emu, uintptr_t fcn) { iFI_t fn = (iFI_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI); }
-void iFC(x64emu_t *emu, uintptr_t fcn) { iFC_t fn = (iFC_t)fcn; R_RAX=(int64_t)fn((uint8_t)R_RDI); }
-void iFW(x64emu_t *emu, uintptr_t fcn) { iFW_t fn = (iFW_t)fcn; R_RAX=(int64_t)fn((uint16_t)R_RDI); }
-void iFu(x64emu_t *emu, uintptr_t fcn) { iFu_t fn = (iFu_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI); }
-void iFU(x64emu_t *emu, uintptr_t fcn) { iFU_t fn = (iFU_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI); }
-void iFf(x64emu_t *emu, uintptr_t fcn) { iFf_t fn = (iFf_t)fcn; R_RAX=(int64_t)fn(emu->xmm[0].f[0]); }
-void iFd(x64emu_t *emu, uintptr_t fcn) { iFd_t fn = (iFd_t)fcn; R_RAX=(int64_t)fn(emu->xmm[0].d[0]); }
-void iFD(x64emu_t *emu, uintptr_t fcn) { iFD_t fn = (iFD_t)fcn; R_RAX=(int64_t)fn(LD2localLD((void*)(R_RSP + 8))); }
-void iFl(x64emu_t *emu, uintptr_t fcn) { iFl_t fn = (iFl_t)fcn; R_RAX=(int64_t)fn((intptr_t)R_RDI); }
-void iFL(x64emu_t *emu, uintptr_t fcn) { iFL_t fn = (iFL_t)fcn; R_RAX=(int64_t)fn((uintptr_t)R_RDI); }
-void iFp(x64emu_t *emu, uintptr_t fcn) { iFp_t fn = (iFp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI); }
-void iFO(x64emu_t *emu, uintptr_t fcn) { iFO_t fn = (iFO_t)fcn; R_RAX=(int64_t)fn(of_convert((int32_t)R_RDI)); }
-void iFS(x64emu_t *emu, uintptr_t fcn) { iFS_t fn = (iFS_t)fcn; R_RAX=(int64_t)fn(io_convert((void*)R_RDI)); }
-void IFv(x64emu_t *emu, uintptr_t fcn) { IFv_t fn = (IFv_t)fcn; R_RAX=(int64_t)fn(); }
-void IFi(x64emu_t *emu, uintptr_t fcn) { IFi_t fn = (IFi_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI); }
-void IFI(x64emu_t *emu, uintptr_t fcn) { IFI_t fn = (IFI_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI); }
-void IFf(x64emu_t *emu, uintptr_t fcn) { IFf_t fn = (IFf_t)fcn; R_RAX=(int64_t)fn(emu->xmm[0].f[0]); }
-void IFd(x64emu_t *emu, uintptr_t fcn) { IFd_t fn = (IFd_t)fcn; R_RAX=(int64_t)fn(emu->xmm[0].d[0]); }
-void IFp(x64emu_t *emu, uintptr_t fcn) { IFp_t fn = (IFp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI); }
-void CFC(x64emu_t *emu, uintptr_t fcn) { CFC_t fn = (CFC_t)fcn; R_RAX=(unsigned char)fn((uint8_t)R_RDI); }
-void CFp(x64emu_t *emu, uintptr_t fcn) { CFp_t fn = (CFp_t)fcn; R_RAX=(unsigned char)fn((void*)R_RDI); }
-void WFi(x64emu_t *emu, uintptr_t fcn) { WFi_t fn = (WFi_t)fcn; R_RAX=(unsigned short)fn((int64_t)R_RDI); }
-void WFW(x64emu_t *emu, uintptr_t fcn) { WFW_t fn = (WFW_t)fcn; R_RAX=(unsigned short)fn((uint16_t)R_RDI); }
-void WFp(x64emu_t *emu, uintptr_t fcn) { WFp_t fn = (WFp_t)fcn; R_RAX=(unsigned short)fn((void*)R_RDI); }
-void uFv(x64emu_t *emu, uintptr_t fcn) { uFv_t fn = (uFv_t)fcn; R_RAX=(uint64_t)fn(); }
-void uFi(x64emu_t *emu, uintptr_t fcn) { uFi_t fn = (uFi_t)fcn; R_RAX=(uint64_t)fn((int64_t)R_RDI); }
-void uFu(x64emu_t *emu, uintptr_t fcn) { uFu_t fn = (uFu_t)fcn; R_RAX=(uint64_t)fn((uint64_t)R_RDI); }
-void uFd(x64emu_t *emu, uintptr_t fcn) { uFd_t fn = (uFd_t)fcn; R_RAX=(uint64_t)fn(emu->xmm[0].d[0]); }
-void uFl(x64emu_t *emu, uintptr_t fcn) { uFl_t fn = (uFl_t)fcn; R_RAX=(uint64_t)fn((intptr_t)R_RDI); }
-void uFL(x64emu_t *emu, uintptr_t fcn) { uFL_t fn = (uFL_t)fcn; R_RAX=(uint64_t)fn((uintptr_t)R_RDI); }
-void uFp(x64emu_t *emu, uintptr_t fcn) { uFp_t fn = (uFp_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI); }
-void UFv(x64emu_t *emu, uintptr_t fcn) { UFv_t fn = (UFv_t)fcn; R_RAX=fn(); }
-void UFu(x64emu_t *emu, uintptr_t fcn) { UFu_t fn = (UFu_t)fcn; R_RAX=fn((uint64_t)R_RDI); }
-void UFp(x64emu_t *emu, uintptr_t fcn) { UFp_t fn = (UFp_t)fcn; R_RAX=fn((void*)R_RDI); }
-void UFV(x64emu_t *emu, uintptr_t fcn) { UFV_t fn = (UFV_t)fcn; R_RAX=fn((void*)(R_RSP + 8)); }
-void fFi(x64emu_t *emu, uintptr_t fcn) { fFi_t fn = (fFi_t)fcn; emu->xmm[0].f[0]=fn((int64_t)R_RDI); }
-void fFf(x64emu_t *emu, uintptr_t fcn) { fFf_t fn = (fFf_t)fcn; emu->xmm[0].f[0]=fn(emu->xmm[0].f[0]); }
-void fFp(x64emu_t *emu, uintptr_t fcn) { fFp_t fn = (fFp_t)fcn; emu->xmm[0].f[0]=fn((void*)R_RDI); }
-void dFv(x64emu_t *emu, uintptr_t fcn) { dFv_t fn = (dFv_t)fcn; emu->xmm[0].d[0]=fn(); }
-void dFi(x64emu_t *emu, uintptr_t fcn) { dFi_t fn = (dFi_t)fcn; emu->xmm[0].d[0]=fn((int64_t)R_RDI); }
-void dFu(x64emu_t *emu, uintptr_t fcn) { dFu_t fn = (dFu_t)fcn; emu->xmm[0].d[0]=fn((uint64_t)R_RDI); }
-void dFd(x64emu_t *emu, uintptr_t fcn) { dFd_t fn = (dFd_t)fcn; emu->xmm[0].d[0]=fn(emu->xmm[0].d[0]); }
-void dFp(x64emu_t *emu, uintptr_t fcn) { dFp_t fn = (dFp_t)fcn; emu->xmm[0].d[0]=fn((void*)R_RDI); }
-void lFE(x64emu_t *emu, uintptr_t fcn) { lFE_t fn = (lFE_t)fcn; R_RAX=(intptr_t)fn(emu); }
-void lFv(x64emu_t *emu, uintptr_t fcn) { lFv_t fn = (lFv_t)fcn; R_RAX=(intptr_t)fn(); }
-void lFi(x64emu_t *emu, uintptr_t fcn) { lFi_t fn = (lFi_t)fcn; R_RAX=(intptr_t)fn((int64_t)R_RDI); }
-void lFu(x64emu_t *emu, uintptr_t fcn) { lFu_t fn = (lFu_t)fcn; R_RAX=(intptr_t)fn((uint64_t)R_RDI); }
-void lFl(x64emu_t *emu, uintptr_t fcn) { lFl_t fn = (lFl_t)fcn; R_RAX=(intptr_t)fn((intptr_t)R_RDI); }
-void lFp(x64emu_t *emu, uintptr_t fcn) { lFp_t fn = (lFp_t)fcn; R_RAX=(intptr_t)fn((void*)R_RDI); }
-void LFv(x64emu_t *emu, uintptr_t fcn) { LFv_t fn = (LFv_t)fcn; R_RAX=(uintptr_t)fn(); }
-void LFu(x64emu_t *emu, uintptr_t fcn) { LFu_t fn = (LFu_t)fcn; R_RAX=(uintptr_t)fn((uint64_t)R_RDI); }
-void LFL(x64emu_t *emu, uintptr_t fcn) { LFL_t fn = (LFL_t)fcn; R_RAX=(uintptr_t)fn((uintptr_t)R_RDI); }
-void LFp(x64emu_t *emu, uintptr_t fcn) { LFp_t fn = (LFp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI); }
-void pFE(x64emu_t *emu, uintptr_t fcn) { pFE_t fn = (pFE_t)fcn; R_RAX=(uintptr_t)fn(emu); }
-void pFv(x64emu_t *emu, uintptr_t fcn) { pFv_t fn = (pFv_t)fcn; R_RAX=(uintptr_t)fn(); }
-void pFw(x64emu_t *emu, uintptr_t fcn) { pFw_t fn = (pFw_t)fcn; R_RAX=(uintptr_t)fn((int16_t)R_RDI); }
-void pFi(x64emu_t *emu, uintptr_t fcn) { pFi_t fn = (pFi_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI); }
-void pFI(x64emu_t *emu, uintptr_t fcn) { pFI_t fn = (pFI_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI); }
-void pFC(x64emu_t *emu, uintptr_t fcn) { pFC_t fn = (pFC_t)fcn; R_RAX=(uintptr_t)fn((uint8_t)R_RDI); }
-void pFW(x64emu_t *emu, uintptr_t fcn) { pFW_t fn = (pFW_t)fcn; R_RAX=(uintptr_t)fn((uint16_t)R_RDI); }
-void pFu(x64emu_t *emu, uintptr_t fcn) { pFu_t fn = (pFu_t)fcn; R_RAX=(uintptr_t)fn((uint64_t)R_RDI); }
-void pFU(x64emu_t *emu, uintptr_t fcn) { pFU_t fn = (pFU_t)fcn; R_RAX=(uintptr_t)fn((uint64_t)R_RDI); }
-void pFd(x64emu_t *emu, uintptr_t fcn) { pFd_t fn = (pFd_t)fcn; R_RAX=(uintptr_t)fn(emu->xmm[0].d[0]); }
-void pFl(x64emu_t *emu, uintptr_t fcn) { pFl_t fn = (pFl_t)fcn; R_RAX=(uintptr_t)fn((intptr_t)R_RDI); }
-void pFL(x64emu_t *emu, uintptr_t fcn) { pFL_t fn = (pFL_t)fcn; R_RAX=(uintptr_t)fn((uintptr_t)R_RDI); }
-void pFp(x64emu_t *emu, uintptr_t fcn) { pFp_t fn = (pFp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI); }
-void pFV(x64emu_t *emu, uintptr_t fcn) { pFV_t fn = (pFV_t)fcn; R_RAX=(uintptr_t)fn((void*)(R_RSP + 8)); }
-void HFi(x64emu_t *emu, uintptr_t fcn) { HFi_t fn = (HFi_t)fcn; unsigned __int128 u128 = fn((int64_t)R_RDI); R_RAX=(u128&0xFFFFFFFFFFFFFFFFL); R_RDX=(u128>>64)&0xFFFFFFFFFFFFFFFFL; }
-void HFp(x64emu_t *emu, uintptr_t fcn) { HFp_t fn = (HFp_t)fcn; unsigned __int128 u128 = fn((void*)R_RDI); R_RAX=(u128&0xFFFFFFFFFFFFFFFFL); R_RDX=(u128>>64)&0xFFFFFFFFFFFFFFFFL; }
-void vWp(x64emu_t *emu, uintptr_t fcn) { vWp_t fn = (vWp_t)fcn; fn((void*)R_RCX); }
-void iWp(x64emu_t *emu, uintptr_t fcn) { iWp_t fn = (iWp_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX); }
-void uWp(x64emu_t *emu, uintptr_t fcn) { uWp_t fn = (uWp_t)fcn; R_RAX=(uint64_t)fn((void*)R_RCX); }
-void fWp(x64emu_t *emu, uintptr_t fcn) { fWp_t fn = (fWp_t)fcn; emu->xmm[0].f[0]=fn((void*)R_RCX); }
-void vFEi(x64emu_t *emu, uintptr_t fcn) { vFEi_t fn = (vFEi_t)fcn; fn(emu, (int64_t)R_RDI); }
-void vFEp(x64emu_t *emu, uintptr_t fcn) { vFEp_t fn = (vFEp_t)fcn; fn(emu, (void*)R_RDI); }
-void vFii(x64emu_t *emu, uintptr_t fcn) { vFii_t fn = (vFii_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI); }
-void vFiI(x64emu_t *emu, uintptr_t fcn) { vFiI_t fn = (vFiI_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI); }
-void vFiu(x64emu_t *emu, uintptr_t fcn) { vFiu_t fn = (vFiu_t)fcn; fn((int64_t)R_RDI, (uint64_t)R_RSI); }
-void vFiU(x64emu_t *emu, uintptr_t fcn) { vFiU_t fn = (vFiU_t)fcn; fn((int64_t)R_RDI, (uint64_t)R_RSI); }
-void vFif(x64emu_t *emu, uintptr_t fcn) { vFif_t fn = (vFif_t)fcn; fn((int64_t)R_RDI, emu->xmm[0].f[0]); }
-void vFid(x64emu_t *emu, uintptr_t fcn) { vFid_t fn = (vFid_t)fcn; fn((int64_t)R_RDI, emu->xmm[0].d[0]); }
-void vFip(x64emu_t *emu, uintptr_t fcn) { vFip_t fn = (vFip_t)fcn; fn((int64_t)R_RDI, (void*)R_RSI); }
-void vFWW(x64emu_t *emu, uintptr_t fcn) { vFWW_t fn = (vFWW_t)fcn; fn((uint16_t)R_RDI, (uint16_t)R_RSI); }
-void vFWp(x64emu_t *emu, uintptr_t fcn) { vFWp_t fn = (vFWp_t)fcn; fn((uint16_t)R_RDI, (void*)R_RSI); }
-void vFui(x64emu_t *emu, uintptr_t fcn) { vFui_t fn = (vFui_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI); }
-void vFuu(x64emu_t *emu, uintptr_t fcn) { vFuu_t fn = (vFuu_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI); }
-void vFuU(x64emu_t *emu, uintptr_t fcn) { vFuU_t fn = (vFuU_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI); }
-void vFuf(x64emu_t *emu, uintptr_t fcn) { vFuf_t fn = (vFuf_t)fcn; fn((uint64_t)R_RDI, emu->xmm[0].f[0]); }
-void vFud(x64emu_t *emu, uintptr_t fcn) { vFud_t fn = (vFud_t)fcn; fn((uint64_t)R_RDI, emu->xmm[0].d[0]); }
-void vFul(x64emu_t *emu, uintptr_t fcn) { vFul_t fn = (vFul_t)fcn; fn((uint64_t)R_RDI, (intptr_t)R_RSI); }
-void vFup(x64emu_t *emu, uintptr_t fcn) { vFup_t fn = (vFup_t)fcn; fn((uint64_t)R_RDI, (void*)R_RSI); }
-void vFUi(x64emu_t *emu, uintptr_t fcn) { vFUi_t fn = (vFUi_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI); }
-void vFfi(x64emu_t *emu, uintptr_t fcn) { vFfi_t fn = (vFfi_t)fcn; fn(emu->xmm[0].f[0], (int64_t)R_RDI); }
-void vFff(x64emu_t *emu, uintptr_t fcn) { vFff_t fn = (vFff_t)fcn; fn(emu->xmm[0].f[0], emu->xmm[1].f[0]); }
-void vFfp(x64emu_t *emu, uintptr_t fcn) { vFfp_t fn = (vFfp_t)fcn; fn(emu->xmm[0].f[0], (void*)R_RDI); }
-void vFdd(x64emu_t *emu, uintptr_t fcn) { vFdd_t fn = (vFdd_t)fcn; fn(emu->xmm[0].d[0], emu->xmm[1].d[0]); }
-void vFlp(x64emu_t *emu, uintptr_t fcn) { vFlp_t fn = (vFlp_t)fcn; fn((intptr_t)R_RDI, (void*)R_RSI); }
-void vFLL(x64emu_t *emu, uintptr_t fcn) { vFLL_t fn = (vFLL_t)fcn; fn((uintptr_t)R_RDI, (uintptr_t)R_RSI); }
-void vFLp(x64emu_t *emu, uintptr_t fcn) { vFLp_t fn = (vFLp_t)fcn; fn((uintptr_t)R_RDI, (void*)R_RSI); }
-void vFpc(x64emu_t *emu, uintptr_t fcn) { vFpc_t fn = (vFpc_t)fcn; fn((void*)R_RDI, (int8_t)R_RSI); }
-void vFpi(x64emu_t *emu, uintptr_t fcn) { vFpi_t fn = (vFpi_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI); }
-void vFpI(x64emu_t *emu, uintptr_t fcn) { vFpI_t fn = (vFpI_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI); }
-void vFpC(x64emu_t *emu, uintptr_t fcn) { vFpC_t fn = (vFpC_t)fcn; fn((void*)R_RDI, (uint8_t)R_RSI); }
-void vFpW(x64emu_t *emu, uintptr_t fcn) { vFpW_t fn = (vFpW_t)fcn; fn((void*)R_RDI, (uint16_t)R_RSI); }
-void vFpu(x64emu_t *emu, uintptr_t fcn) { vFpu_t fn = (vFpu_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI); }
-void vFpU(x64emu_t *emu, uintptr_t fcn) { vFpU_t fn = (vFpU_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI); }
-void vFpf(x64emu_t *emu, uintptr_t fcn) { vFpf_t fn = (vFpf_t)fcn; fn((void*)R_RDI, emu->xmm[0].f[0]); }
-void vFpd(x64emu_t *emu, uintptr_t fcn) { vFpd_t fn = (vFpd_t)fcn; fn((void*)R_RDI, emu->xmm[0].d[0]); }
-void vFpl(x64emu_t *emu, uintptr_t fcn) { vFpl_t fn = (vFpl_t)fcn; fn((void*)R_RDI, (intptr_t)R_RSI); }
-void vFpL(x64emu_t *emu, uintptr_t fcn) { vFpL_t fn = (vFpL_t)fcn; fn((void*)R_RDI, (uintptr_t)R_RSI); }
-void vFpp(x64emu_t *emu, uintptr_t fcn) { vFpp_t fn = (vFpp_t)fcn; fn((void*)R_RDI, (void*)R_RSI); }
-void vFpS(x64emu_t *emu, uintptr_t fcn) { vFpS_t fn = (vFpS_t)fcn; fn((void*)R_RDI, io_convert((void*)R_RSI)); }
-void vFSi(x64emu_t *emu, uintptr_t fcn) { vFSi_t fn = (vFSi_t)fcn; fn(io_convert((void*)R_RDI), (int64_t)R_RSI); }
-void cFpp(x64emu_t *emu, uintptr_t fcn) { cFpp_t fn = (cFpp_t)fcn; R_RAX=fn((void*)R_RDI, (void*)R_RSI); }
-void iFEi(x64emu_t *emu, uintptr_t fcn) { iFEi_t fn = (iFEi_t)fcn; R_RAX=(int64_t)fn(emu, (int64_t)R_RDI); }
-void iFEp(x64emu_t *emu, uintptr_t fcn) { iFEp_t fn = (iFEp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI); }
-void iFwp(x64emu_t *emu, uintptr_t fcn) { iFwp_t fn = (iFwp_t)fcn; R_RAX=(int64_t)fn((int16_t)R_RDI, (void*)R_RSI); }
-void iFii(x64emu_t *emu, uintptr_t fcn) { iFii_t fn = (iFii_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI); }
-void iFiu(x64emu_t *emu, uintptr_t fcn) { iFiu_t fn = (iFiu_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (uint64_t)R_RSI); }
-void iFil(x64emu_t *emu, uintptr_t fcn) { iFil_t fn = (iFil_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (intptr_t)R_RSI); }
-void iFiL(x64emu_t *emu, uintptr_t fcn) { iFiL_t fn = (iFiL_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (uintptr_t)R_RSI); }
-void iFip(x64emu_t *emu, uintptr_t fcn) { iFip_t fn = (iFip_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI); }
-void iFiS(x64emu_t *emu, uintptr_t fcn) { iFiS_t fn = (iFiS_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, io_convert((void*)R_RSI)); }
-void iFIi(x64emu_t *emu, uintptr_t fcn) { iFIi_t fn = (iFIi_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI); }
-void iFui(x64emu_t *emu, uintptr_t fcn) { iFui_t fn = (iFui_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (int64_t)R_RSI); }
-void iFuu(x64emu_t *emu, uintptr_t fcn) { iFuu_t fn = (iFuu_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (uint64_t)R_RSI); }
-void iFuU(x64emu_t *emu, uintptr_t fcn) { iFuU_t fn = (iFuU_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (uint64_t)R_RSI); }
-void iFuL(x64emu_t *emu, uintptr_t fcn) { iFuL_t fn = (iFuL_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (uintptr_t)R_RSI); }
-void iFup(x64emu_t *emu, uintptr_t fcn) { iFup_t fn = (iFup_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (void*)R_RSI); }
-void iFUp(x64emu_t *emu, uintptr_t fcn) { iFUp_t fn = (iFUp_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (void*)R_RSI); }
-void iFli(x64emu_t *emu, uintptr_t fcn) { iFli_t fn = (iFli_t)fcn; R_RAX=(int64_t)fn((intptr_t)R_RDI, (int64_t)R_RSI); }
-void iFlp(x64emu_t *emu, uintptr_t fcn) { iFlp_t fn = (iFlp_t)fcn; R_RAX=(int64_t)fn((intptr_t)R_RDI, (void*)R_RSI); }
-void iFLu(x64emu_t *emu, uintptr_t fcn) { iFLu_t fn = (iFLu_t)fcn; R_RAX=(int64_t)fn((uintptr_t)R_RDI, (uint64_t)R_RSI); }
-void iFLL(x64emu_t *emu, uintptr_t fcn) { iFLL_t fn = (iFLL_t)fcn; R_RAX=(int64_t)fn((uintptr_t)R_RDI, (uintptr_t)R_RSI); }
-void iFLp(x64emu_t *emu, uintptr_t fcn) { iFLp_t fn = (iFLp_t)fcn; R_RAX=(int64_t)fn((uintptr_t)R_RDI, (void*)R_RSI); }
-void iFpw(x64emu_t *emu, uintptr_t fcn) { iFpw_t fn = (iFpw_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int16_t)R_RSI); }
-void iFpi(x64emu_t *emu, uintptr_t fcn) { iFpi_t fn = (iFpi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI); }
-void iFpI(x64emu_t *emu, uintptr_t fcn) { iFpI_t fn = (iFpI_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI); }
-void iFpC(x64emu_t *emu, uintptr_t fcn) { iFpC_t fn = (iFpC_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint8_t)R_RSI); }
-void iFpW(x64emu_t *emu, uintptr_t fcn) { iFpW_t fn = (iFpW_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint16_t)R_RSI); }
-void iFpu(x64emu_t *emu, uintptr_t fcn) { iFpu_t fn = (iFpu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI); }
-void iFpU(x64emu_t *emu, uintptr_t fcn) { iFpU_t fn = (iFpU_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI); }
-void iFpf(x64emu_t *emu, uintptr_t fcn) { iFpf_t fn = (iFpf_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, emu->xmm[0].f[0]); }
-void iFpd(x64emu_t *emu, uintptr_t fcn) { iFpd_t fn = (iFpd_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, emu->xmm[0].d[0]); }
-void iFpl(x64emu_t *emu, uintptr_t fcn) { iFpl_t fn = (iFpl_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (intptr_t)R_RSI); }
-void iFpL(x64emu_t *emu, uintptr_t fcn) { iFpL_t fn = (iFpL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uintptr_t)R_RSI); }
-void iFpp(x64emu_t *emu, uintptr_t fcn) { iFpp_t fn = (iFpp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI); }
-void iFpO(x64emu_t *emu, uintptr_t fcn) { iFpO_t fn = (iFpO_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, of_convert((int32_t)R_RSI)); }
-void iFSi(x64emu_t *emu, uintptr_t fcn) { iFSi_t fn = (iFSi_t)fcn; R_RAX=(int64_t)fn(io_convert((void*)R_RDI), (int64_t)R_RSI); }
-void IFEp(x64emu_t *emu, uintptr_t fcn) { IFEp_t fn = (IFEp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI); }
-void IFII(x64emu_t *emu, uintptr_t fcn) { IFII_t fn = (IFII_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI); }
-void IFpi(x64emu_t *emu, uintptr_t fcn) { IFpi_t fn = (IFpi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI); }
-void IFpu(x64emu_t *emu, uintptr_t fcn) { IFpu_t fn = (IFpu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI); }
-void IFpd(x64emu_t *emu, uintptr_t fcn) { IFpd_t fn = (IFpd_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, emu->xmm[0].d[0]); }
-void CFip(x64emu_t *emu, uintptr_t fcn) { CFip_t fn = (CFip_t)fcn; R_RAX=(unsigned char)fn((int64_t)R_RDI, (void*)R_RSI); }
-void CFui(x64emu_t *emu, uintptr_t fcn) { CFui_t fn = (CFui_t)fcn; R_RAX=(unsigned char)fn((uint64_t)R_RDI, (int64_t)R_RSI); }
-void CFpi(x64emu_t *emu, uintptr_t fcn) { CFpi_t fn = (CFpi_t)fcn; R_RAX=(unsigned char)fn((void*)R_RDI, (int64_t)R_RSI); }
-void CFpu(x64emu_t *emu, uintptr_t fcn) { CFpu_t fn = (CFpu_t)fcn; R_RAX=(unsigned char)fn((void*)R_RDI, (uint64_t)R_RSI); }
-void CFpp(x64emu_t *emu, uintptr_t fcn) { CFpp_t fn = (CFpp_t)fcn; R_RAX=(unsigned char)fn((void*)R_RDI, (void*)R_RSI); }
-void WFpp(x64emu_t *emu, uintptr_t fcn) { WFpp_t fn = (WFpp_t)fcn; R_RAX=(unsigned short)fn((void*)R_RDI, (void*)R_RSI); }
-void uFEp(x64emu_t *emu, uintptr_t fcn) { uFEp_t fn = (uFEp_t)fcn; R_RAX=(uint64_t)fn(emu, (void*)R_RDI); }
-void uFii(x64emu_t *emu, uintptr_t fcn) { uFii_t fn = (uFii_t)fcn; R_RAX=(uint64_t)fn((int64_t)R_RDI, (int64_t)R_RSI); }
-void uFiu(x64emu_t *emu, uintptr_t fcn) { uFiu_t fn = (uFiu_t)fcn; R_RAX=(uint64_t)fn((int64_t)R_RDI, (uint64_t)R_RSI); }
-void uFip(x64emu_t *emu, uintptr_t fcn) { uFip_t fn = (uFip_t)fcn; R_RAX=(uint64_t)fn((int64_t)R_RDI, (void*)R_RSI); }
-void uFui(x64emu_t *emu, uintptr_t fcn) { uFui_t fn = (uFui_t)fcn; R_RAX=(uint64_t)fn((uint64_t)R_RDI, (int64_t)R_RSI); }
-void uFuu(x64emu_t *emu, uintptr_t fcn) { uFuu_t fn = (uFuu_t)fcn; R_RAX=(uint64_t)fn((uint64_t)R_RDI, (uint64_t)R_RSI); }
-void uFup(x64emu_t *emu, uintptr_t fcn) { uFup_t fn = (uFup_t)fcn; R_RAX=(uint64_t)fn((uint64_t)R_RDI, (void*)R_RSI); }
-void uFUp(x64emu_t *emu, uintptr_t fcn) { uFUp_t fn = (uFUp_t)fcn; R_RAX=(uint64_t)fn((uint64_t)R_RDI, (void*)R_RSI); }
-void uFpw(x64emu_t *emu, uintptr_t fcn) { uFpw_t fn = (uFpw_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (int16_t)R_RSI); }
-void uFpi(x64emu_t *emu, uintptr_t fcn) { uFpi_t fn = (uFpi_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (int64_t)R_RSI); }
-void uFpu(x64emu_t *emu, uintptr_t fcn) { uFpu_t fn = (uFpu_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (uint64_t)R_RSI); }
-void uFpU(x64emu_t *emu, uintptr_t fcn) { uFpU_t fn = (uFpU_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (uint64_t)R_RSI); }
-void uFpf(x64emu_t *emu, uintptr_t fcn) { uFpf_t fn = (uFpf_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, emu->xmm[0].f[0]); }
-void uFpL(x64emu_t *emu, uintptr_t fcn) { uFpL_t fn = (uFpL_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (uintptr_t)R_RSI); }
-void uFpp(x64emu_t *emu, uintptr_t fcn) { uFpp_t fn = (uFpp_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI); }
-void UFEp(x64emu_t *emu, uintptr_t fcn) { UFEp_t fn = (UFEp_t)fcn; R_RAX=fn(emu, (void*)R_RDI); }
-void UFuu(x64emu_t *emu, uintptr_t fcn) { UFuu_t fn = (UFuu_t)fcn; R_RAX=fn((uint64_t)R_RDI, (uint64_t)R_RSI); }
-void UFUp(x64emu_t *emu, uintptr_t fcn) { UFUp_t fn = (UFUp_t)fcn; R_RAX=fn((uint64_t)R_RDI, (void*)R_RSI); }
-void UFpi(x64emu_t *emu, uintptr_t fcn) { UFpi_t fn = (UFpi_t)fcn; R_RAX=fn((void*)R_RDI, (int64_t)R_RSI); }
-void UFpp(x64emu_t *emu, uintptr_t fcn) { UFpp_t fn = (UFpp_t)fcn; R_RAX=fn((void*)R_RDI, (void*)R_RSI); }
-void fFEp(x64emu_t *emu, uintptr_t fcn) { fFEp_t fn = (fFEp_t)fcn; emu->xmm[0].f[0]=fn(emu, (void*)R_RDI); }
-void fFif(x64emu_t *emu, uintptr_t fcn) { fFif_t fn = (fFif_t)fcn; emu->xmm[0].f[0]=fn((int64_t)R_RDI, emu->xmm[0].f[0]); }
-void fFfi(x64emu_t *emu, uintptr_t fcn) { fFfi_t fn = (fFfi_t)fcn; emu->xmm[0].f[0]=fn(emu->xmm[0].f[0], (int64_t)R_RDI); }
-void fFff(x64emu_t *emu, uintptr_t fcn) { fFff_t fn = (fFff_t)fcn; emu->xmm[0].f[0]=fn(emu->xmm[0].f[0], emu->xmm[1].f[0]); }
-void fFfD(x64emu_t *emu, uintptr_t fcn) { fFfD_t fn = (fFfD_t)fcn; emu->xmm[0].f[0]=fn(emu->xmm[0].f[0], LD2localLD((void*)(R_RSP + 8))); }
-void fFfl(x64emu_t *emu, uintptr_t fcn) { fFfl_t fn = (fFfl_t)fcn; emu->xmm[0].f[0]=fn(emu->xmm[0].f[0], (intptr_t)R_RDI); }
-void fFfp(x64emu_t *emu, uintptr_t fcn) { fFfp_t fn = (fFfp_t)fcn; emu->xmm[0].f[0]=fn(emu->xmm[0].f[0], (void*)R_RDI); }
-void fFpp(x64emu_t *emu, uintptr_t fcn) { fFpp_t fn = (fFpp_t)fcn; emu->xmm[0].f[0]=fn((void*)R_RDI, (void*)R_RSI); }
-void dFid(x64emu_t *emu, uintptr_t fcn) { dFid_t fn = (dFid_t)fcn; emu->xmm[0].d[0]=fn((int64_t)R_RDI, emu->xmm[0].d[0]); }
-void dFdi(x64emu_t *emu, uintptr_t fcn) { dFdi_t fn = (dFdi_t)fcn; emu->xmm[0].d[0]=fn(emu->xmm[0].d[0], (int64_t)R_RDI); }
-void dFdd(x64emu_t *emu, uintptr_t fcn) { dFdd_t fn = (dFdd_t)fcn; emu->xmm[0].d[0]=fn(emu->xmm[0].d[0], emu->xmm[1].d[0]); }
-void dFdD(x64emu_t *emu, uintptr_t fcn) { dFdD_t fn = (dFdD_t)fcn; emu->xmm[0].d[0]=fn(emu->xmm[0].d[0], LD2localLD((void*)(R_RSP + 8))); }
-void dFdl(x64emu_t *emu, uintptr_t fcn) { dFdl_t fn = (dFdl_t)fcn; emu->xmm[0].d[0]=fn(emu->xmm[0].d[0], (intptr_t)R_RDI); }
-void dFdp(x64emu_t *emu, uintptr_t fcn) { dFdp_t fn = (dFdp_t)fcn; emu->xmm[0].d[0]=fn(emu->xmm[0].d[0], (void*)R_RDI); }
-void dFll(x64emu_t *emu, uintptr_t fcn) { dFll_t fn = (dFll_t)fcn; emu->xmm[0].d[0]=fn((intptr_t)R_RDI, (intptr_t)R_RSI); }
-void dFpi(x64emu_t *emu, uintptr_t fcn) { dFpi_t fn = (dFpi_t)fcn; emu->xmm[0].d[0]=fn((void*)R_RDI, (int64_t)R_RSI); }
-void dFpd(x64emu_t *emu, uintptr_t fcn) { dFpd_t fn = (dFpd_t)fcn; emu->xmm[0].d[0]=fn((void*)R_RDI, emu->xmm[0].d[0]); }
-void dFpp(x64emu_t *emu, uintptr_t fcn) { dFpp_t fn = (dFpp_t)fcn; emu->xmm[0].d[0]=fn((void*)R_RDI, (void*)R_RSI); }
-void DFDi(x64emu_t *emu, uintptr_t fcn) { DFDi_t fn = (DFDi_t)fcn; long double ld=fn(LD2localLD((void*)(R_RSP + 8)), (int64_t)R_RDI); fpu_do_push(emu); ST0val = ld; }
-void DFDD(x64emu_t *emu, uintptr_t fcn) { DFDD_t fn = (DFDD_t)fcn; long double ld=fn(LD2localLD((void*)(R_RSP + 8)), LD2localLD((void*)(R_RSP + 24))); fpu_do_push(emu); ST0val = ld; }
-void DFDp(x64emu_t *emu, uintptr_t fcn) { DFDp_t fn = (DFDp_t)fcn; long double ld=fn(LD2localLD((void*)(R_RSP + 8)), (void*)R_RDI); fpu_do_push(emu); ST0val = ld; }
-void DFpp(x64emu_t *emu, uintptr_t fcn) { DFpp_t fn = (DFpp_t)fcn; long double ld=fn((void*)R_RDI, (void*)R_RSI); fpu_do_push(emu); ST0val = ld; }
-void lFii(x64emu_t *emu, uintptr_t fcn) { lFii_t fn = (lFii_t)fcn; R_RAX=(intptr_t)fn((int64_t)R_RDI, (int64_t)R_RSI); }
-void lFll(x64emu_t *emu, uintptr_t fcn) { lFll_t fn = (lFll_t)fcn; R_RAX=(intptr_t)fn((intptr_t)R_RDI, (intptr_t)R_RSI); }
-void lFpi(x64emu_t *emu, uintptr_t fcn) { lFpi_t fn = (lFpi_t)fcn; R_RAX=(intptr_t)fn((void*)R_RDI, (int64_t)R_RSI); }
-void lFpl(x64emu_t *emu, uintptr_t fcn) { lFpl_t fn = (lFpl_t)fcn; R_RAX=(intptr_t)fn((void*)R_RDI, (intptr_t)R_RSI); }
-void lFpp(x64emu_t *emu, uintptr_t fcn) { lFpp_t fn = (lFpp_t)fcn; R_RAX=(intptr_t)fn((void*)R_RDI, (void*)R_RSI); }
-void LFEL(x64emu_t *emu, uintptr_t fcn) { LFEL_t fn = (LFEL_t)fcn; R_RAX=(uintptr_t)fn(emu, (uintptr_t)R_RDI); }
-void LFii(x64emu_t *emu, uintptr_t fcn) { LFii_t fn = (LFii_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (int64_t)R_RSI); }
-void LFuu(x64emu_t *emu, uintptr_t fcn) { LFuu_t fn = (LFuu_t)fcn; R_RAX=(uintptr_t)fn((uint64_t)R_RDI, (uint64_t)R_RSI); }
-void LFLi(x64emu_t *emu, uintptr_t fcn) { LFLi_t fn = (LFLi_t)fcn; R_RAX=(uintptr_t)fn((uintptr_t)R_RDI, (int64_t)R_RSI); }
-void LFLL(x64emu_t *emu, uintptr_t fcn) { LFLL_t fn = (LFLL_t)fcn; R_RAX=(uintptr_t)fn((uintptr_t)R_RDI, (uintptr_t)R_RSI); }
-void LFpi(x64emu_t *emu, uintptr_t fcn) { LFpi_t fn = (LFpi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI); }
-void LFpL(x64emu_t *emu, uintptr_t fcn) { LFpL_t fn = (LFpL_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uintptr_t)R_RSI); }
-void LFpp(x64emu_t *emu, uintptr_t fcn) { LFpp_t fn = (LFpp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI); }
-void pFEi(x64emu_t *emu, uintptr_t fcn) { pFEi_t fn = (pFEi_t)fcn; R_RAX=(uintptr_t)fn(emu, (int64_t)R_RDI); }
-void pFEL(x64emu_t *emu, uintptr_t fcn) { pFEL_t fn = (pFEL_t)fcn; R_RAX=(uintptr_t)fn(emu, (uintptr_t)R_RDI); }
-void pFEp(x64emu_t *emu, uintptr_t fcn) { pFEp_t fn = (pFEp_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI); }
-void pFii(x64emu_t *emu, uintptr_t fcn) { pFii_t fn = (pFii_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (int64_t)R_RSI); }
-void pFiI(x64emu_t *emu, uintptr_t fcn) { pFiI_t fn = (pFiI_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (int64_t)R_RSI); }
-void pFiu(x64emu_t *emu, uintptr_t fcn) { pFiu_t fn = (pFiu_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (uint64_t)R_RSI); }
-void pFip(x64emu_t *emu, uintptr_t fcn) { pFip_t fn = (pFip_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (void*)R_RSI); }
-void pFiV(x64emu_t *emu, uintptr_t fcn) { pFiV_t fn = (pFiV_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (void*)(R_RSP + 8)); }
-void pFII(x64emu_t *emu, uintptr_t fcn) { pFII_t fn = (pFII_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (int64_t)R_RSI); }
-void pFui(x64emu_t *emu, uintptr_t fcn) { pFui_t fn = (pFui_t)fcn; R_RAX=(uintptr_t)fn((uint64_t)R_RDI, (int64_t)R_RSI); }
-void pFuC(x64emu_t *emu, uintptr_t fcn) { pFuC_t fn = (pFuC_t)fcn; R_RAX=(uintptr_t)fn((uint64_t)R_RDI, (uint8_t)R_RSI); }
-void pFuu(x64emu_t *emu, uintptr_t fcn) { pFuu_t fn = (pFuu_t)fcn; R_RAX=(uintptr_t)fn((uint64_t)R_RDI, (uint64_t)R_RSI); }
-void pFup(x64emu_t *emu, uintptr_t fcn) { pFup_t fn = (pFup_t)fcn; R_RAX=(uintptr_t)fn((uint64_t)R_RDI, (void*)R_RSI); }
-void pFUi(x64emu_t *emu, uintptr_t fcn) { pFUi_t fn = (pFUi_t)fcn; R_RAX=(uintptr_t)fn((uint64_t)R_RDI, (int64_t)R_RSI); }
-void pFUU(x64emu_t *emu, uintptr_t fcn) { pFUU_t fn = (pFUU_t)fcn; R_RAX=(uintptr_t)fn((uint64_t)R_RDI, (uint64_t)R_RSI); }
-void pFdi(x64emu_t *emu, uintptr_t fcn) { pFdi_t fn = (pFdi_t)fcn; R_RAX=(uintptr_t)fn(emu->xmm[0].d[0], (int64_t)R_RDI); }
-void pFdd(x64emu_t *emu, uintptr_t fcn) { pFdd_t fn = (pFdd_t)fcn; R_RAX=(uintptr_t)fn(emu->xmm[0].d[0], emu->xmm[1].d[0]); }
-void pFlp(x64emu_t *emu, uintptr_t fcn) { pFlp_t fn = (pFlp_t)fcn; R_RAX=(uintptr_t)fn((intptr_t)R_RDI, (void*)R_RSI); }
-void pFLu(x64emu_t *emu, uintptr_t fcn) { pFLu_t fn = (pFLu_t)fcn; R_RAX=(uintptr_t)fn((uintptr_t)R_RDI, (uint64_t)R_RSI); }
-void pFLL(x64emu_t *emu, uintptr_t fcn) { pFLL_t fn = (pFLL_t)fcn; R_RAX=(uintptr_t)fn((uintptr_t)R_RDI, (uintptr_t)R_RSI); }
-void pFLp(x64emu_t *emu, uintptr_t fcn) { pFLp_t fn = (pFLp_t)fcn; R_RAX=(uintptr_t)fn((uintptr_t)R_RDI, (void*)R_RSI); }
-void pFpi(x64emu_t *emu, uintptr_t fcn) { pFpi_t fn = (pFpi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI); }
-void pFpC(x64emu_t *emu, uintptr_t fcn) { pFpC_t fn = (pFpC_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint8_t)R_RSI); }
-void pFpu(x64emu_t *emu, uintptr_t fcn) { pFpu_t fn = (pFpu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI); }
-void pFpU(x64emu_t *emu, uintptr_t fcn) { pFpU_t fn = (pFpU_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI); }
-void pFpd(x64emu_t *emu, uintptr_t fcn) { pFpd_t fn = (pFpd_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, emu->xmm[0].d[0]); }
-void pFpl(x64emu_t *emu, uintptr_t fcn) { pFpl_t fn = (pFpl_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (intptr_t)R_RSI); }
-void pFpL(x64emu_t *emu, uintptr_t fcn) { pFpL_t fn = (pFpL_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uintptr_t)R_RSI); }
-void pFpp(x64emu_t *emu, uintptr_t fcn) { pFpp_t fn = (pFpp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI); }
-void pFpV(x64emu_t *emu, uintptr_t fcn) { pFpV_t fn = (pFpV_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)(R_RSP + 8)); }
-void pFSi(x64emu_t *emu, uintptr_t fcn) { pFSi_t fn = (pFSi_t)fcn; R_RAX=(uintptr_t)fn(io_convert((void*)R_RDI), (int64_t)R_RSI); }
-void HFII(x64emu_t *emu, uintptr_t fcn) { HFII_t fn = (HFII_t)fcn; unsigned __int128 u128 = fn((int64_t)R_RDI, (int64_t)R_RSI); R_RAX=(u128&0xFFFFFFFFFFFFFFFFL); R_RDX=(u128>>64)&0xFFFFFFFFFFFFFFFFL; }
-void HFll(x64emu_t *emu, uintptr_t fcn) { HFll_t fn = (HFll_t)fcn; unsigned __int128 u128 = fn((intptr_t)R_RDI, (intptr_t)R_RSI); R_RAX=(u128&0xFFFFFFFFFFFFFFFFL); R_RDX=(u128>>64)&0xFFFFFFFFFFFFFFFFL; }
-void HFpi(x64emu_t *emu, uintptr_t fcn) { HFpi_t fn = (HFpi_t)fcn; unsigned __int128 u128 = fn((void*)R_RDI, (int64_t)R_RSI); R_RAX=(u128&0xFFFFFFFFFFFFFFFFL); R_RDX=(u128>>64)&0xFFFFFFFFFFFFFFFFL; }
-void iWpi(x64emu_t *emu, uintptr_t fcn) { iWpi_t fn = (iWpi_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (int64_t)R_RDX); }
-void iWpu(x64emu_t *emu, uintptr_t fcn) { iWpu_t fn = (iWpu_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (uint64_t)R_RDX); }
-void iWpf(x64emu_t *emu, uintptr_t fcn) { iWpf_t fn = (iWpf_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, emu->xmm[1].f[0]); }
-void iWpp(x64emu_t *emu, uintptr_t fcn) { iWpp_t fn = (iWpp_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (void*)R_RDX); }
-void uWpu(x64emu_t *emu, uintptr_t fcn) { uWpu_t fn = (uWpu_t)fcn; R_RAX=(uint64_t)fn((void*)R_RCX, (uint64_t)R_RDX); }
-void pWEp(x64emu_t *emu, uintptr_t fcn) { pWEp_t fn = (pWEp_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RCX); }
-void pWpu(x64emu_t *emu, uintptr_t fcn) { pWpu_t fn = (pWpu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RCX, (uint64_t)R_RDX); }
-void vFEpi(x64emu_t *emu, uintptr_t fcn) { vFEpi_t fn = (vFEpi_t)fcn; fn(emu, (void*)R_RDI, (int64_t)R_RSI); }
-void vFEpu(x64emu_t *emu, uintptr_t fcn) { vFEpu_t fn = (vFEpu_t)fcn; fn(emu, (void*)R_RDI, (uint64_t)R_RSI); }
-void vFEpp(x64emu_t *emu, uintptr_t fcn) { vFEpp_t fn = (vFEpp_t)fcn; fn(emu, (void*)R_RDI, (void*)R_RSI); }
-void vFEpV(x64emu_t *emu, uintptr_t fcn) { vFEpV_t fn = (vFEpV_t)fcn; fn(emu, (void*)R_RDI, (void*)(R_RSP + 8)); }
-void vFEpA(x64emu_t *emu, uintptr_t fcn) { vFEpA_t fn = (vFEpA_t)fcn; fn(emu, (void*)R_RDI, (void*)R_RSI); }
-void vFiii(x64emu_t *emu, uintptr_t fcn) { vFiii_t fn = (vFiii_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX); }
-void vFiiu(x64emu_t *emu, uintptr_t fcn) { vFiiu_t fn = (vFiiu_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX); }
-void vFiif(x64emu_t *emu, uintptr_t fcn) { vFiif_t fn = (vFiif_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, emu->xmm[0].f[0]); }
-void vFiip(x64emu_t *emu, uintptr_t fcn) { vFiip_t fn = (vFiip_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX); }
-void vFiII(x64emu_t *emu, uintptr_t fcn) { vFiII_t fn = (vFiII_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX); }
-void vFiui(x64emu_t *emu, uintptr_t fcn) { vFiui_t fn = (vFiui_t)fcn; fn((int64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX); }
-void vFiuu(x64emu_t *emu, uintptr_t fcn) { vFiuu_t fn = (vFiuu_t)fcn; fn((int64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX); }
-void vFiuU(x64emu_t *emu, uintptr_t fcn) { vFiuU_t fn = (vFiuU_t)fcn; fn((int64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX); }
-void vFiup(x64emu_t *emu, uintptr_t fcn) { vFiup_t fn = (vFiup_t)fcn; fn((int64_t)R_RDI, (uint64_t)R_RSI, (void*)R_RDX); }
-void vFiUU(x64emu_t *emu, uintptr_t fcn) { vFiUU_t fn = (vFiUU_t)fcn; fn((int64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX); }
-void vFiff(x64emu_t *emu, uintptr_t fcn) { vFiff_t fn = (vFiff_t)fcn; fn((int64_t)R_RDI, emu->xmm[0].f[0], emu->xmm[1].f[0]); }
-void vFidd(x64emu_t *emu, uintptr_t fcn) { vFidd_t fn = (vFidd_t)fcn; fn((int64_t)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0]); }
-void vFill(x64emu_t *emu, uintptr_t fcn) { vFill_t fn = (vFill_t)fcn; fn((int64_t)R_RDI, (intptr_t)R_RSI, (intptr_t)R_RDX); }
-void vFilp(x64emu_t *emu, uintptr_t fcn) { vFilp_t fn = (vFilp_t)fcn; fn((int64_t)R_RDI, (intptr_t)R_RSI, (void*)R_RDX); }
-void vFipi(x64emu_t *emu, uintptr_t fcn) { vFipi_t fn = (vFipi_t)fcn; fn((int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX); }
-void vFipu(x64emu_t *emu, uintptr_t fcn) { vFipu_t fn = (vFipu_t)fcn; fn((int64_t)R_RDI, (void*)R_RSI, (uint64_t)R_RDX); }
-void vFipp(x64emu_t *emu, uintptr_t fcn) { vFipp_t fn = (vFipp_t)fcn; fn((int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void vFuii(x64emu_t *emu, uintptr_t fcn) { vFuii_t fn = (vFuii_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX); }
-void vFuiI(x64emu_t *emu, uintptr_t fcn) { vFuiI_t fn = (vFuiI_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX); }
-void vFuiu(x64emu_t *emu, uintptr_t fcn) { vFuiu_t fn = (vFuiu_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX); }
-void vFuiU(x64emu_t *emu, uintptr_t fcn) { vFuiU_t fn = (vFuiU_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX); }
-void vFuif(x64emu_t *emu, uintptr_t fcn) { vFuif_t fn = (vFuif_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, emu->xmm[0].f[0]); }
-void vFuid(x64emu_t *emu, uintptr_t fcn) { vFuid_t fn = (vFuid_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, emu->xmm[0].d[0]); }
-void vFuip(x64emu_t *emu, uintptr_t fcn) { vFuip_t fn = (vFuip_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX); }
-void vFuui(x64emu_t *emu, uintptr_t fcn) { vFuui_t fn = (vFuui_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX); }
-void vFuuu(x64emu_t *emu, uintptr_t fcn) { vFuuu_t fn = (vFuuu_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX); }
-void vFuuU(x64emu_t *emu, uintptr_t fcn) { vFuuU_t fn = (vFuuU_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX); }
-void vFuuf(x64emu_t *emu, uintptr_t fcn) { vFuuf_t fn = (vFuuf_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, emu->xmm[0].f[0]); }
-void vFuud(x64emu_t *emu, uintptr_t fcn) { vFuud_t fn = (vFuud_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, emu->xmm[0].d[0]); }
-void vFuup(x64emu_t *emu, uintptr_t fcn) { vFuup_t fn = (vFuup_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (void*)R_RDX); }
-void vFuff(x64emu_t *emu, uintptr_t fcn) { vFuff_t fn = (vFuff_t)fcn; fn((uint64_t)R_RDI, emu->xmm[0].f[0], emu->xmm[1].f[0]); }
-void vFufp(x64emu_t *emu, uintptr_t fcn) { vFufp_t fn = (vFufp_t)fcn; fn((uint64_t)R_RDI, emu->xmm[0].f[0], (void*)R_RSI); }
-void vFudd(x64emu_t *emu, uintptr_t fcn) { vFudd_t fn = (vFudd_t)fcn; fn((uint64_t)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0]); }
-void vFull(x64emu_t *emu, uintptr_t fcn) { vFull_t fn = (vFull_t)fcn; fn((uint64_t)R_RDI, (intptr_t)R_RSI, (intptr_t)R_RDX); }
-void vFulp(x64emu_t *emu, uintptr_t fcn) { vFulp_t fn = (vFulp_t)fcn; fn((uint64_t)R_RDI, (intptr_t)R_RSI, (void*)R_RDX); }
-void vFuLp(x64emu_t *emu, uintptr_t fcn) { vFuLp_t fn = (vFuLp_t)fcn; fn((uint64_t)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX); }
-void vFupu(x64emu_t *emu, uintptr_t fcn) { vFupu_t fn = (vFupu_t)fcn; fn((uint64_t)R_RDI, (void*)R_RSI, (uint64_t)R_RDX); }
-void vFupp(x64emu_t *emu, uintptr_t fcn) { vFupp_t fn = (vFupp_t)fcn; fn((uint64_t)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void vFfff(x64emu_t *emu, uintptr_t fcn) { vFfff_t fn = (vFfff_t)fcn; fn(emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0]); }
-void vFfpp(x64emu_t *emu, uintptr_t fcn) { vFfpp_t fn = (vFfpp_t)fcn; fn(emu->xmm[0].f[0], (void*)R_RDI, (void*)R_RSI); }
-void vFddd(x64emu_t *emu, uintptr_t fcn) { vFddd_t fn = (vFddd_t)fcn; fn(emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0]); }
-void vFdpp(x64emu_t *emu, uintptr_t fcn) { vFdpp_t fn = (vFdpp_t)fcn; fn(emu->xmm[0].d[0], (void*)R_RDI, (void*)R_RSI); }
-void vFlip(x64emu_t *emu, uintptr_t fcn) { vFlip_t fn = (vFlip_t)fcn; fn((intptr_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX); }
-void vFlll(x64emu_t *emu, uintptr_t fcn) { vFlll_t fn = (vFlll_t)fcn; fn((intptr_t)R_RDI, (intptr_t)R_RSI, (intptr_t)R_RDX); }
-void vFllp(x64emu_t *emu, uintptr_t fcn) { vFllp_t fn = (vFllp_t)fcn; fn((intptr_t)R_RDI, (intptr_t)R_RSI, (void*)R_RDX); }
-void vFlpp(x64emu_t *emu, uintptr_t fcn) { vFlpp_t fn = (vFlpp_t)fcn; fn((intptr_t)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void vFLup(x64emu_t *emu, uintptr_t fcn) { vFLup_t fn = (vFLup_t)fcn; fn((uintptr_t)R_RDI, (uint64_t)R_RSI, (void*)R_RDX); }
-void vFLpL(x64emu_t *emu, uintptr_t fcn) { vFLpL_t fn = (vFLpL_t)fcn; fn((uintptr_t)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX); }
-void vFLpp(x64emu_t *emu, uintptr_t fcn) { vFLpp_t fn = (vFLpp_t)fcn; fn((uintptr_t)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void vFpii(x64emu_t *emu, uintptr_t fcn) { vFpii_t fn = (vFpii_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX); }
-void vFpiI(x64emu_t *emu, uintptr_t fcn) { vFpiI_t fn = (vFpiI_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX); }
-void vFpiC(x64emu_t *emu, uintptr_t fcn) { vFpiC_t fn = (vFpiC_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (uint8_t)R_RDX); }
-void vFpiu(x64emu_t *emu, uintptr_t fcn) { vFpiu_t fn = (vFpiu_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX); }
-void vFpif(x64emu_t *emu, uintptr_t fcn) { vFpif_t fn = (vFpif_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, emu->xmm[0].f[0]); }
-void vFpid(x64emu_t *emu, uintptr_t fcn) { vFpid_t fn = (vFpid_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, emu->xmm[0].d[0]); }
-void vFpip(x64emu_t *emu, uintptr_t fcn) { vFpip_t fn = (vFpip_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX); }
-void vFpui(x64emu_t *emu, uintptr_t fcn) { vFpui_t fn = (vFpui_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX); }
-void vFpuI(x64emu_t *emu, uintptr_t fcn) { vFpuI_t fn = (vFpuI_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX); }
-void vFpuW(x64emu_t *emu, uintptr_t fcn) { vFpuW_t fn = (vFpuW_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint16_t)R_RDX); }
-void vFpuu(x64emu_t *emu, uintptr_t fcn) { vFpuu_t fn = (vFpuu_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX); }
-void vFpuU(x64emu_t *emu, uintptr_t fcn) { vFpuU_t fn = (vFpuU_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX); }
-void vFpup(x64emu_t *emu, uintptr_t fcn) { vFpup_t fn = (vFpup_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX); }
-void vFpUi(x64emu_t *emu, uintptr_t fcn) { vFpUi_t fn = (vFpUi_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX); }
-void vFpUu(x64emu_t *emu, uintptr_t fcn) { vFpUu_t fn = (vFpUu_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX); }
-void vFpUU(x64emu_t *emu, uintptr_t fcn) { vFpUU_t fn = (vFpUU_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX); }
-void vFpUf(x64emu_t *emu, uintptr_t fcn) { vFpUf_t fn = (vFpUf_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, emu->xmm[0].f[0]); }
-void vFpUp(x64emu_t *emu, uintptr_t fcn) { vFpUp_t fn = (vFpUp_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX); }
-void vFpff(x64emu_t *emu, uintptr_t fcn) { vFpff_t fn = (vFpff_t)fcn; fn((void*)R_RDI, emu->xmm[0].f[0], emu->xmm[1].f[0]); }
-void vFpdd(x64emu_t *emu, uintptr_t fcn) { vFpdd_t fn = (vFpdd_t)fcn; fn((void*)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0]); }
-void vFpll(x64emu_t *emu, uintptr_t fcn) { vFpll_t fn = (vFpll_t)fcn; fn((void*)R_RDI, (intptr_t)R_RSI, (intptr_t)R_RDX); }
-void vFplp(x64emu_t *emu, uintptr_t fcn) { vFplp_t fn = (vFplp_t)fcn; fn((void*)R_RDI, (intptr_t)R_RSI, (void*)R_RDX); }
-void vFpLi(x64emu_t *emu, uintptr_t fcn) { vFpLi_t fn = (vFpLi_t)fcn; fn((void*)R_RDI, (uintptr_t)R_RSI, (int64_t)R_RDX); }
-void vFpLu(x64emu_t *emu, uintptr_t fcn) { vFpLu_t fn = (vFpLu_t)fcn; fn((void*)R_RDI, (uintptr_t)R_RSI, (uint64_t)R_RDX); }
-void vFpLL(x64emu_t *emu, uintptr_t fcn) { vFpLL_t fn = (vFpLL_t)fcn; fn((void*)R_RDI, (uintptr_t)R_RSI, (uintptr_t)R_RDX); }
-void vFpLp(x64emu_t *emu, uintptr_t fcn) { vFpLp_t fn = (vFpLp_t)fcn; fn((void*)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX); }
-void vFppi(x64emu_t *emu, uintptr_t fcn) { vFppi_t fn = (vFppi_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX); }
-void vFppu(x64emu_t *emu, uintptr_t fcn) { vFppu_t fn = (vFppu_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX); }
-void vFppU(x64emu_t *emu, uintptr_t fcn) { vFppU_t fn = (vFppU_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX); }
-void vFppd(x64emu_t *emu, uintptr_t fcn) { vFppd_t fn = (vFppd_t)fcn; fn((void*)R_RDI, (void*)R_RSI, emu->xmm[0].d[0]); }
-void vFppl(x64emu_t *emu, uintptr_t fcn) { vFppl_t fn = (vFppl_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (intptr_t)R_RDX); }
-void vFppL(x64emu_t *emu, uintptr_t fcn) { vFppL_t fn = (vFppL_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX); }
-void vFppp(x64emu_t *emu, uintptr_t fcn) { vFppp_t fn = (vFppp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void iFEiw(x64emu_t *emu, uintptr_t fcn) { iFEiw_t fn = (iFEiw_t)fcn; R_RAX=(int64_t)fn(emu, (int64_t)R_RDI, (int16_t)R_RSI); }
-void iFEip(x64emu_t *emu, uintptr_t fcn) { iFEip_t fn = (iFEip_t)fcn; R_RAX=(int64_t)fn(emu, (int64_t)R_RDI, (void*)R_RSI); }
-void iFEWW(x64emu_t *emu, uintptr_t fcn) { iFEWW_t fn = (iFEWW_t)fcn; R_RAX=(int64_t)fn(emu, (uint16_t)R_RDI, (uint16_t)R_RSI); }
-void iFEup(x64emu_t *emu, uintptr_t fcn) { iFEup_t fn = (iFEup_t)fcn; R_RAX=(int64_t)fn(emu, (uint64_t)R_RDI, (void*)R_RSI); }
-void iFEUU(x64emu_t *emu, uintptr_t fcn) { iFEUU_t fn = (iFEUU_t)fcn; R_RAX=(int64_t)fn(emu, (uint64_t)R_RDI, (uint64_t)R_RSI); }
-void iFELp(x64emu_t *emu, uintptr_t fcn) { iFELp_t fn = (iFELp_t)fcn; R_RAX=(int64_t)fn(emu, (uintptr_t)R_RDI, (void*)R_RSI); }
-void iFEpi(x64emu_t *emu, uintptr_t fcn) { iFEpi_t fn = (iFEpi_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI); }
-void iFEpU(x64emu_t *emu, uintptr_t fcn) { iFEpU_t fn = (iFEpU_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (uint64_t)R_RSI); }
-void iFEpL(x64emu_t *emu, uintptr_t fcn) { iFEpL_t fn = (iFEpL_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (uintptr_t)R_RSI); }
-void iFEpp(x64emu_t *emu, uintptr_t fcn) { iFEpp_t fn = (iFEpp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI); }
-void iFEpV(x64emu_t *emu, uintptr_t fcn) { iFEpV_t fn = (iFEpV_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)(R_RSP + 8)); }
-void iFEpA(x64emu_t *emu, uintptr_t fcn) { iFEpA_t fn = (iFEpA_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI); }
-void iFESp(x64emu_t *emu, uintptr_t fcn) { iFESp_t fn = (iFESp_t)fcn; R_RAX=(int64_t)fn(emu, io_convert((void*)R_RDI), (void*)R_RSI); }
-void iFwww(x64emu_t *emu, uintptr_t fcn) { iFwww_t fn = (iFwww_t)fcn; R_RAX=(int64_t)fn((int16_t)R_RDI, (int16_t)R_RSI, (int16_t)R_RDX); }
-void iFwpp(x64emu_t *emu, uintptr_t fcn) { iFwpp_t fn = (iFwpp_t)fcn; R_RAX=(int64_t)fn((int16_t)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void iFiwC(x64emu_t *emu, uintptr_t fcn) { iFiwC_t fn = (iFiwC_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int16_t)R_RSI, (uint8_t)R_RDX); }
-void iFiii(x64emu_t *emu, uintptr_t fcn) { iFiii_t fn = (iFiii_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX); }
-void iFiiu(x64emu_t *emu, uintptr_t fcn) { iFiiu_t fn = (iFiiu_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX); }
-void iFiil(x64emu_t *emu, uintptr_t fcn) { iFiil_t fn = (iFiil_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (intptr_t)R_RDX); }
-void iFiip(x64emu_t *emu, uintptr_t fcn) { iFiip_t fn = (iFiip_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX); }
-void iFiiO(x64emu_t *emu, uintptr_t fcn) { iFiiO_t fn = (iFiiO_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, of_convert((int32_t)R_RDX)); }
-void iFiuu(x64emu_t *emu, uintptr_t fcn) { iFiuu_t fn = (iFiuu_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX); }
-void iFill(x64emu_t *emu, uintptr_t fcn) { iFill_t fn = (iFill_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (intptr_t)R_RSI, (intptr_t)R_RDX); }
-void iFiLi(x64emu_t *emu, uintptr_t fcn) { iFiLi_t fn = (iFiLi_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (uintptr_t)R_RSI, (int64_t)R_RDX); }
-void iFiLp(x64emu_t *emu, uintptr_t fcn) { iFiLp_t fn = (iFiLp_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX); }
-void iFiLN(x64emu_t *emu, uintptr_t fcn) { iFiLN_t fn = (iFiLN_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX); }
-void iFipi(x64emu_t *emu, uintptr_t fcn) { iFipi_t fn = (iFipi_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX); }
-void iFipu(x64emu_t *emu, uintptr_t fcn) { iFipu_t fn = (iFipu_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (uint64_t)R_RDX); }
-void iFipL(x64emu_t *emu, uintptr_t fcn) { iFipL_t fn = (iFipL_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX); }
-void iFipp(x64emu_t *emu, uintptr_t fcn) { iFipp_t fn = (iFipp_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void iFipO(x64emu_t *emu, uintptr_t fcn) { iFipO_t fn = (iFipO_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, of_convert((int32_t)R_RDX)); }
-void iFCiW(x64emu_t *emu, uintptr_t fcn) { iFCiW_t fn = (iFCiW_t)fcn; R_RAX=(int64_t)fn((uint8_t)R_RDI, (int64_t)R_RSI, (uint16_t)R_RDX); }
-void iFuwp(x64emu_t *emu, uintptr_t fcn) { iFuwp_t fn = (iFuwp_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (int16_t)R_RSI, (void*)R_RDX); }
-void iFuip(x64emu_t *emu, uintptr_t fcn) { iFuip_t fn = (iFuip_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX); }
-void iFuui(x64emu_t *emu, uintptr_t fcn) { iFuui_t fn = (iFuui_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX); }
-void iFuuu(x64emu_t *emu, uintptr_t fcn) { iFuuu_t fn = (iFuuu_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX); }
-void iFuup(x64emu_t *emu, uintptr_t fcn) { iFuup_t fn = (iFuup_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (uint64_t)R_RSI, (void*)R_RDX); }
-void iFuUu(x64emu_t *emu, uintptr_t fcn) { iFuUu_t fn = (iFuUu_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX); }
-void iFuff(x64emu_t *emu, uintptr_t fcn) { iFuff_t fn = (iFuff_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, emu->xmm[0].f[0], emu->xmm[1].f[0]); }
-void iFuLL(x64emu_t *emu, uintptr_t fcn) { iFuLL_t fn = (iFuLL_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (uintptr_t)R_RSI, (uintptr_t)R_RDX); }
-void iFuLp(x64emu_t *emu, uintptr_t fcn) { iFuLp_t fn = (iFuLp_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX); }
-void iFupL(x64emu_t *emu, uintptr_t fcn) { iFupL_t fn = (iFupL_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX); }
-void iFupp(x64emu_t *emu, uintptr_t fcn) { iFupp_t fn = (iFupp_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void iFfff(x64emu_t *emu, uintptr_t fcn) { iFfff_t fn = (iFfff_t)fcn; R_RAX=(int64_t)fn(emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0]); }
-void iFlip(x64emu_t *emu, uintptr_t fcn) { iFlip_t fn = (iFlip_t)fcn; R_RAX=(int64_t)fn((intptr_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX); }
-void iFLip(x64emu_t *emu, uintptr_t fcn) { iFLip_t fn = (iFLip_t)fcn; R_RAX=(int64_t)fn((uintptr_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX); }
-void iFLLi(x64emu_t *emu, uintptr_t fcn) { iFLLi_t fn = (iFLLi_t)fcn; R_RAX=(int64_t)fn((uintptr_t)R_RDI, (uintptr_t)R_RSI, (int64_t)R_RDX); }
-void iFLpp(x64emu_t *emu, uintptr_t fcn) { iFLpp_t fn = (iFLpp_t)fcn; R_RAX=(int64_t)fn((uintptr_t)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void iFpwp(x64emu_t *emu, uintptr_t fcn) { iFpwp_t fn = (iFpwp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int16_t)R_RSI, (void*)R_RDX); }
-void iFpii(x64emu_t *emu, uintptr_t fcn) { iFpii_t fn = (iFpii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX); }
-void iFpiI(x64emu_t *emu, uintptr_t fcn) { iFpiI_t fn = (iFpiI_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX); }
-void iFpiu(x64emu_t *emu, uintptr_t fcn) { iFpiu_t fn = (iFpiu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX); }
-void iFpiU(x64emu_t *emu, uintptr_t fcn) { iFpiU_t fn = (iFpiU_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX); }
-void iFpiL(x64emu_t *emu, uintptr_t fcn) { iFpiL_t fn = (iFpiL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (uintptr_t)R_RDX); }
-void iFpip(x64emu_t *emu, uintptr_t fcn) { iFpip_t fn = (iFpip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX); }
-void iFpIi(x64emu_t *emu, uintptr_t fcn) { iFpIi_t fn = (iFpIi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX); }
-void iFpII(x64emu_t *emu, uintptr_t fcn) { iFpII_t fn = (iFpII_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX); }
-void iFpCp(x64emu_t *emu, uintptr_t fcn) { iFpCp_t fn = (iFpCp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint8_t)R_RSI, (void*)R_RDX); }
-void iFpui(x64emu_t *emu, uintptr_t fcn) { iFpui_t fn = (iFpui_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX); }
-void iFpuu(x64emu_t *emu, uintptr_t fcn) { iFpuu_t fn = (iFpuu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX); }
-void iFpuU(x64emu_t *emu, uintptr_t fcn) { iFpuU_t fn = (iFpuU_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX); }
-void iFpuL(x64emu_t *emu, uintptr_t fcn) { iFpuL_t fn = (iFpuL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uintptr_t)R_RDX); }
-void iFpup(x64emu_t *emu, uintptr_t fcn) { iFpup_t fn = (iFpup_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX); }
-void iFpUi(x64emu_t *emu, uintptr_t fcn) { iFpUi_t fn = (iFpUi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX); }
-void iFpUu(x64emu_t *emu, uintptr_t fcn) { iFpUu_t fn = (iFpUu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX); }
-void iFpUU(x64emu_t *emu, uintptr_t fcn) { iFpUU_t fn = (iFpUU_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX); }
-void iFpUp(x64emu_t *emu, uintptr_t fcn) { iFpUp_t fn = (iFpUp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX); }
-void iFpfu(x64emu_t *emu, uintptr_t fcn) { iFpfu_t fn = (iFpfu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, emu->xmm[0].f[0], (uint64_t)R_RSI); }
-void iFpff(x64emu_t *emu, uintptr_t fcn) { iFpff_t fn = (iFpff_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, emu->xmm[0].f[0], emu->xmm[1].f[0]); }
-void iFpdd(x64emu_t *emu, uintptr_t fcn) { iFpdd_t fn = (iFpdd_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0]); }
-void iFpli(x64emu_t *emu, uintptr_t fcn) { iFpli_t fn = (iFpli_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX); }
-void iFpll(x64emu_t *emu, uintptr_t fcn) { iFpll_t fn = (iFpll_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (intptr_t)R_RSI, (intptr_t)R_RDX); }
-void iFplp(x64emu_t *emu, uintptr_t fcn) { iFplp_t fn = (iFplp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (intptr_t)R_RSI, (void*)R_RDX); }
-void iFpLi(x64emu_t *emu, uintptr_t fcn) { iFpLi_t fn = (iFpLi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (int64_t)R_RDX); }
-void iFpLu(x64emu_t *emu, uintptr_t fcn) { iFpLu_t fn = (iFpLu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (uint64_t)R_RDX); }
-void iFpLL(x64emu_t *emu, uintptr_t fcn) { iFpLL_t fn = (iFpLL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (uintptr_t)R_RDX); }
-void iFpLp(x64emu_t *emu, uintptr_t fcn) { iFpLp_t fn = (iFpLp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX); }
-void iFppi(x64emu_t *emu, uintptr_t fcn) { iFppi_t fn = (iFppi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX); }
-void iFppI(x64emu_t *emu, uintptr_t fcn) { iFppI_t fn = (iFppI_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX); }
-void iFppC(x64emu_t *emu, uintptr_t fcn) { iFppC_t fn = (iFppC_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uint8_t)R_RDX); }
-void iFppW(x64emu_t *emu, uintptr_t fcn) { iFppW_t fn = (iFppW_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uint16_t)R_RDX); }
-void iFppu(x64emu_t *emu, uintptr_t fcn) { iFppu_t fn = (iFppu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX); }
-void iFppU(x64emu_t *emu, uintptr_t fcn) { iFppU_t fn = (iFppU_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX); }
-void iFppd(x64emu_t *emu, uintptr_t fcn) { iFppd_t fn = (iFppd_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, emu->xmm[0].d[0]); }
-void iFppl(x64emu_t *emu, uintptr_t fcn) { iFppl_t fn = (iFppl_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (intptr_t)R_RDX); }
-void iFppL(x64emu_t *emu, uintptr_t fcn) { iFppL_t fn = (iFppL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX); }
-void iFppp(x64emu_t *emu, uintptr_t fcn) { iFppp_t fn = (iFppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void iFpOu(x64emu_t *emu, uintptr_t fcn) { iFpOu_t fn = (iFpOu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, of_convert((int32_t)R_RSI), (uint64_t)R_RDX); }
-void iFpOM(x64emu_t *emu, uintptr_t fcn) { iFpOM_t fn = (iFpOM_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, of_convert((int32_t)R_RSI), (void*)R_RDX, (void*)R_RCX); }
-void iFSpL(x64emu_t *emu, uintptr_t fcn) { iFSpL_t fn = (iFSpL_t)fcn; R_RAX=(int64_t)fn(io_convert((void*)R_RDI), (void*)R_RSI, (uintptr_t)R_RDX); }
-void IFiIi(x64emu_t *emu, uintptr_t fcn) { IFiIi_t fn = (IFiIi_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX); }
-void IFpIi(x64emu_t *emu, uintptr_t fcn) { IFpIi_t fn = (IFpIi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX); }
-void IFppi(x64emu_t *emu, uintptr_t fcn) { IFppi_t fn = (IFppi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX); }
-void IFppI(x64emu_t *emu, uintptr_t fcn) { IFppI_t fn = (IFppI_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX); }
-void IFppu(x64emu_t *emu, uintptr_t fcn) { IFppu_t fn = (IFppu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX); }
-void IFSIi(x64emu_t *emu, uintptr_t fcn) { IFSIi_t fn = (IFSIi_t)fcn; R_RAX=(int64_t)fn(io_convert((void*)R_RDI), (int64_t)R_RSI, (int64_t)R_RDX); }
-void uFEpW(x64emu_t *emu, uintptr_t fcn) { uFEpW_t fn = (uFEpW_t)fcn; R_RAX=(uint64_t)fn(emu, (void*)R_RDI, (uint16_t)R_RSI); }
-void uFEpu(x64emu_t *emu, uintptr_t fcn) { uFEpu_t fn = (uFEpu_t)fcn; R_RAX=(uint64_t)fn(emu, (void*)R_RDI, (uint64_t)R_RSI); }
-void uFEpU(x64emu_t *emu, uintptr_t fcn) { uFEpU_t fn = (uFEpU_t)fcn; R_RAX=(uint64_t)fn(emu, (void*)R_RDI, (uint64_t)R_RSI); }
-void uFEpp(x64emu_t *emu, uintptr_t fcn) { uFEpp_t fn = (uFEpp_t)fcn; R_RAX=(uint64_t)fn(emu, (void*)R_RDI, (void*)R_RSI); }
-void uFipu(x64emu_t *emu, uintptr_t fcn) { uFipu_t fn = (uFipu_t)fcn; R_RAX=(uint64_t)fn((int64_t)R_RDI, (void*)R_RSI, (uint64_t)R_RDX); }
-void uFuip(x64emu_t *emu, uintptr_t fcn) { uFuip_t fn = (uFuip_t)fcn; R_RAX=(uint64_t)fn((uint64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX); }
-void uFuuu(x64emu_t *emu, uintptr_t fcn) { uFuuu_t fn = (uFuuu_t)fcn; R_RAX=(uint64_t)fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX); }
-void uFuup(x64emu_t *emu, uintptr_t fcn) { uFuup_t fn = (uFuup_t)fcn; R_RAX=(uint64_t)fn((uint64_t)R_RDI, (uint64_t)R_RSI, (void*)R_RDX); }
-void uFufp(x64emu_t *emu, uintptr_t fcn) { uFufp_t fn = (uFufp_t)fcn; R_RAX=(uint64_t)fn((uint64_t)R_RDI, emu->xmm[0].f[0], (void*)R_RSI); }
-void uFupu(x64emu_t *emu, uintptr_t fcn) { uFupu_t fn = (uFupu_t)fcn; R_RAX=(uint64_t)fn((uint64_t)R_RDI, (void*)R_RSI, (uint64_t)R_RDX); }
-void uFupp(x64emu_t *emu, uintptr_t fcn) { uFupp_t fn = (uFupp_t)fcn; R_RAX=(uint64_t)fn((uint64_t)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void uFpii(x64emu_t *emu, uintptr_t fcn) { uFpii_t fn = (uFpii_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX); }
-void uFpip(x64emu_t *emu, uintptr_t fcn) { uFpip_t fn = (uFpip_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX); }
-void uFpCi(x64emu_t *emu, uintptr_t fcn) { uFpCi_t fn = (uFpCi_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (uint8_t)R_RSI, (int64_t)R_RDX); }
-void uFpWi(x64emu_t *emu, uintptr_t fcn) { uFpWi_t fn = (uFpWi_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (uint16_t)R_RSI, (int64_t)R_RDX); }
-void uFpWu(x64emu_t *emu, uintptr_t fcn) { uFpWu_t fn = (uFpWu_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (uint16_t)R_RSI, (uint64_t)R_RDX); }
-void uFpWf(x64emu_t *emu, uintptr_t fcn) { uFpWf_t fn = (uFpWf_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (uint16_t)R_RSI, emu->xmm[0].f[0]); }
-void uFpWp(x64emu_t *emu, uintptr_t fcn) { uFpWp_t fn = (uFpWp_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (uint16_t)R_RSI, (void*)R_RDX); }
-void uFpui(x64emu_t *emu, uintptr_t fcn) { uFpui_t fn = (uFpui_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX); }
-void uFpuC(x64emu_t *emu, uintptr_t fcn) { uFpuC_t fn = (uFpuC_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint8_t)R_RDX); }
-void uFpuu(x64emu_t *emu, uintptr_t fcn) { uFpuu_t fn = (uFpuu_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX); }
-void uFpup(x64emu_t *emu, uintptr_t fcn) { uFpup_t fn = (uFpup_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX); }
-void uFpfu(x64emu_t *emu, uintptr_t fcn) { uFpfu_t fn = (uFpfu_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, emu->xmm[0].f[0], (uint64_t)R_RSI); }
-void uFpLp(x64emu_t *emu, uintptr_t fcn) { uFpLp_t fn = (uFpLp_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX); }
-void uFppi(x64emu_t *emu, uintptr_t fcn) { uFppi_t fn = (uFppi_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX); }
-void uFppu(x64emu_t *emu, uintptr_t fcn) { uFppu_t fn = (uFppu_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX); }
-void uFppp(x64emu_t *emu, uintptr_t fcn) { uFppp_t fn = (uFppp_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void UFUUU(x64emu_t *emu, uintptr_t fcn) { UFUUU_t fn = (UFUUU_t)fcn; R_RAX=fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX); }
-void UFpiU(x64emu_t *emu, uintptr_t fcn) { UFpiU_t fn = (UFpiU_t)fcn; R_RAX=fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX); }
-void UFppi(x64emu_t *emu, uintptr_t fcn) { UFppi_t fn = (UFppi_t)fcn; R_RAX=fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX); }
-void UFppu(x64emu_t *emu, uintptr_t fcn) { UFppu_t fn = (UFppu_t)fcn; R_RAX=fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX); }
-void fFull(x64emu_t *emu, uintptr_t fcn) { fFull_t fn = (fFull_t)fcn; emu->xmm[0].f[0]=fn((uint64_t)R_RDI, (intptr_t)R_RSI, (intptr_t)R_RDX); }
-void fFfff(x64emu_t *emu, uintptr_t fcn) { fFfff_t fn = (fFfff_t)fcn; emu->xmm[0].f[0]=fn(emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0]); }
-void fFffp(x64emu_t *emu, uintptr_t fcn) { fFffp_t fn = (fFffp_t)fcn; emu->xmm[0].f[0]=fn(emu->xmm[0].f[0], emu->xmm[1].f[0], (void*)R_RDI); }
-void fFppi(x64emu_t *emu, uintptr_t fcn) { fFppi_t fn = (fFppi_t)fcn; emu->xmm[0].f[0]=fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX); }
-void fFppL(x64emu_t *emu, uintptr_t fcn) { fFppL_t fn = (fFppL_t)fcn; emu->xmm[0].f[0]=fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX); }
-void fFppp(x64emu_t *emu, uintptr_t fcn) { fFppp_t fn = (fFppp_t)fcn; emu->xmm[0].f[0]=fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void dFddd(x64emu_t *emu, uintptr_t fcn) { dFddd_t fn = (dFddd_t)fcn; emu->xmm[0].d[0]=fn(emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0]); }
-void dFddp(x64emu_t *emu, uintptr_t fcn) { dFddp_t fn = (dFddp_t)fcn; emu->xmm[0].d[0]=fn(emu->xmm[0].d[0], emu->xmm[1].d[0], (void*)R_RDI); }
-void dFpdd(x64emu_t *emu, uintptr_t fcn) { dFpdd_t fn = (dFpdd_t)fcn; emu->xmm[0].d[0]=fn((void*)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0]); }
-void dFppi(x64emu_t *emu, uintptr_t fcn) { dFppi_t fn = (dFppi_t)fcn; emu->xmm[0].d[0]=fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX); }
-void dFppp(x64emu_t *emu, uintptr_t fcn) { dFppp_t fn = (dFppp_t)fcn; emu->xmm[0].d[0]=fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void DFppi(x64emu_t *emu, uintptr_t fcn) { DFppi_t fn = (DFppi_t)fcn; long double ld=fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX); fpu_do_push(emu); ST0val = ld; }
-void DFppp(x64emu_t *emu, uintptr_t fcn) { DFppp_t fn = (DFppp_t)fcn; long double ld=fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX); fpu_do_push(emu); ST0val = ld; }
-void lFili(x64emu_t *emu, uintptr_t fcn) { lFili_t fn = (lFili_t)fcn; R_RAX=(intptr_t)fn((int64_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX); }
-void lFilL(x64emu_t *emu, uintptr_t fcn) { lFilL_t fn = (lFilL_t)fcn; R_RAX=(intptr_t)fn((int64_t)R_RDI, (intptr_t)R_RSI, (uintptr_t)R_RDX); }
-void lFipi(x64emu_t *emu, uintptr_t fcn) { lFipi_t fn = (lFipi_t)fcn; R_RAX=(intptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX); }
-void lFipL(x64emu_t *emu, uintptr_t fcn) { lFipL_t fn = (lFipL_t)fcn; R_RAX=(intptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX); }
-void lFlll(x64emu_t *emu, uintptr_t fcn) { lFlll_t fn = (lFlll_t)fcn; R_RAX=(intptr_t)fn((intptr_t)R_RDI, (intptr_t)R_RSI, (intptr_t)R_RDX); }
-void lFpli(x64emu_t *emu, uintptr_t fcn) { lFpli_t fn = (lFpli_t)fcn; R_RAX=(intptr_t)fn((void*)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX); }
-void lFpLu(x64emu_t *emu, uintptr_t fcn) { lFpLu_t fn = (lFpLu_t)fcn; R_RAX=(intptr_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (uint64_t)R_RDX); }
-void lFpLp(x64emu_t *emu, uintptr_t fcn) { lFpLp_t fn = (lFpLp_t)fcn; R_RAX=(intptr_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX); }
-void lFppi(x64emu_t *emu, uintptr_t fcn) { lFppi_t fn = (lFppi_t)fcn; R_RAX=(intptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX); }
-void lFppL(x64emu_t *emu, uintptr_t fcn) { lFppL_t fn = (lFppL_t)fcn; R_RAX=(intptr_t)fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX); }
-void lFppp(x64emu_t *emu, uintptr_t fcn) { lFppp_t fn = (lFppp_t)fcn; R_RAX=(intptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void lFSpl(x64emu_t *emu, uintptr_t fcn) { lFSpl_t fn = (lFSpl_t)fcn; R_RAX=(intptr_t)fn(io_convert((void*)R_RDI), (void*)R_RSI, (intptr_t)R_RDX); }
-void LFEpA(x64emu_t *emu, uintptr_t fcn) { LFEpA_t fn = (LFEpA_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI); }
-void LFipL(x64emu_t *emu, uintptr_t fcn) { LFipL_t fn = (LFipL_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX); }
-void LFLLl(x64emu_t *emu, uintptr_t fcn) { LFLLl_t fn = (LFLLl_t)fcn; R_RAX=(uintptr_t)fn((uintptr_t)R_RDI, (uintptr_t)R_RSI, (intptr_t)R_RDX); }
-void LFLpu(x64emu_t *emu, uintptr_t fcn) { LFLpu_t fn = (LFLpu_t)fcn; R_RAX=(uintptr_t)fn((uintptr_t)R_RDI, (void*)R_RSI, (uint64_t)R_RDX); }
-void LFLpL(x64emu_t *emu, uintptr_t fcn) { LFLpL_t fn = (LFLpL_t)fcn; R_RAX=(uintptr_t)fn((uintptr_t)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX); }
-void LFpii(x64emu_t *emu, uintptr_t fcn) { LFpii_t fn = (LFpii_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX); }
-void LFpip(x64emu_t *emu, uintptr_t fcn) { LFpip_t fn = (LFpip_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX); }
-void LFpLi(x64emu_t *emu, uintptr_t fcn) { LFpLi_t fn = (LFpLi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (int64_t)R_RDX); }
-void LFpLp(x64emu_t *emu, uintptr_t fcn) { LFpLp_t fn = (LFpLp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX); }
-void LFppi(x64emu_t *emu, uintptr_t fcn) { LFppi_t fn = (LFppi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX); }
-void LFppL(x64emu_t *emu, uintptr_t fcn) { LFppL_t fn = (LFppL_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX); }
-void LFppp(x64emu_t *emu, uintptr_t fcn) { LFppp_t fn = (LFppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void LFSpL(x64emu_t *emu, uintptr_t fcn) { LFSpL_t fn = (LFSpL_t)fcn; R_RAX=(uintptr_t)fn(io_convert((void*)R_RDI), (void*)R_RSI, (uintptr_t)R_RDX); }
-void pFEip(x64emu_t *emu, uintptr_t fcn) { pFEip_t fn = (pFEip_t)fcn; R_RAX=(uintptr_t)fn(emu, (int64_t)R_RDI, (void*)R_RSI); }
-void pFEiV(x64emu_t *emu, uintptr_t fcn) { pFEiV_t fn = (pFEiV_t)fcn; R_RAX=(uintptr_t)fn(emu, (int64_t)R_RDI, (void*)(R_RSP + 8)); }
-void pFEup(x64emu_t *emu, uintptr_t fcn) { pFEup_t fn = (pFEup_t)fcn; R_RAX=(uintptr_t)fn(emu, (uint64_t)R_RDI, (void*)R_RSI); }
-void pFEuV(x64emu_t *emu, uintptr_t fcn) { pFEuV_t fn = (pFEuV_t)fcn; R_RAX=(uintptr_t)fn(emu, (uint64_t)R_RDI, (void*)(R_RSP + 8)); }
-void pFEpi(x64emu_t *emu, uintptr_t fcn) { pFEpi_t fn = (pFEpi_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI); }
-void pFEpu(x64emu_t *emu, uintptr_t fcn) { pFEpu_t fn = (pFEpu_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (uint64_t)R_RSI); }
-void pFEpp(x64emu_t *emu, uintptr_t fcn) { pFEpp_t fn = (pFEpp_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI); }
-void pFEpV(x64emu_t *emu, uintptr_t fcn) { pFEpV_t fn = (pFEpV_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)(R_RSP + 8)); }
-void pFEpA(x64emu_t *emu, uintptr_t fcn) { pFEpA_t fn = (pFEpA_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI); }
-void pFiii(x64emu_t *emu, uintptr_t fcn) { pFiii_t fn = (pFiii_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX); }
-void pFiiu(x64emu_t *emu, uintptr_t fcn) { pFiiu_t fn = (pFiiu_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX); }
-void pFiip(x64emu_t *emu, uintptr_t fcn) { pFiip_t fn = (pFiip_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX); }
-void pFiIi(x64emu_t *emu, uintptr_t fcn) { pFiIi_t fn = (pFiIi_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX); }
-void pFiIp(x64emu_t *emu, uintptr_t fcn) { pFiIp_t fn = (pFiIp_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX); }
-void pFipi(x64emu_t *emu, uintptr_t fcn) { pFipi_t fn = (pFipi_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX); }
-void pFipL(x64emu_t *emu, uintptr_t fcn) { pFipL_t fn = (pFipL_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX); }
-void pFipp(x64emu_t *emu, uintptr_t fcn) { pFipp_t fn = (pFipp_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void pFIpi(x64emu_t *emu, uintptr_t fcn) { pFIpi_t fn = (pFIpi_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX); }
-void pFCiW(x64emu_t *emu, uintptr_t fcn) { pFCiW_t fn = (pFCiW_t)fcn; R_RAX=(uintptr_t)fn((uint8_t)R_RDI, (int64_t)R_RSI, (uint16_t)R_RDX); }
-void pFWWW(x64emu_t *emu, uintptr_t fcn) { pFWWW_t fn = (pFWWW_t)fcn; R_RAX=(uintptr_t)fn((uint16_t)R_RDI, (uint16_t)R_RSI, (uint16_t)R_RDX); }
-void pFuii(x64emu_t *emu, uintptr_t fcn) { pFuii_t fn = (pFuii_t)fcn; R_RAX=(uintptr_t)fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX); }
-void pFuui(x64emu_t *emu, uintptr_t fcn) { pFuui_t fn = (pFuui_t)fcn; R_RAX=(uintptr_t)fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX); }
-void pFuuu(x64emu_t *emu, uintptr_t fcn) { pFuuu_t fn = (pFuuu_t)fcn; R_RAX=(uintptr_t)fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX); }
-void pFupi(x64emu_t *emu, uintptr_t fcn) { pFupi_t fn = (pFupi_t)fcn; R_RAX=(uintptr_t)fn((uint64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX); }
-void pFupL(x64emu_t *emu, uintptr_t fcn) { pFupL_t fn = (pFupL_t)fcn; R_RAX=(uintptr_t)fn((uint64_t)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX); }
-void pFUpi(x64emu_t *emu, uintptr_t fcn) { pFUpi_t fn = (pFUpi_t)fcn; R_RAX=(uintptr_t)fn((uint64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX); }
-void pFdip(x64emu_t *emu, uintptr_t fcn) { pFdip_t fn = (pFdip_t)fcn; R_RAX=(uintptr_t)fn(emu->xmm[0].d[0], (int64_t)R_RDI, (void*)R_RSI); }
-void pFdUU(x64emu_t *emu, uintptr_t fcn) { pFdUU_t fn = (pFdUU_t)fcn; R_RAX=(uintptr_t)fn(emu->xmm[0].d[0], (uint64_t)R_RDI, (uint64_t)R_RSI); }
-void pFddd(x64emu_t *emu, uintptr_t fcn) { pFddd_t fn = (pFddd_t)fcn; R_RAX=(uintptr_t)fn(emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0]); }
-void pFDip(x64emu_t *emu, uintptr_t fcn) { pFDip_t fn = (pFDip_t)fcn; R_RAX=(uintptr_t)fn(LD2localLD((void*)(R_RSP + 8)), (int64_t)R_RDI, (void*)R_RSI); }
-void pFLup(x64emu_t *emu, uintptr_t fcn) { pFLup_t fn = (pFLup_t)fcn; R_RAX=(uintptr_t)fn((uintptr_t)R_RDI, (uint64_t)R_RSI, (void*)R_RDX); }
-void pFLLp(x64emu_t *emu, uintptr_t fcn) { pFLLp_t fn = (pFLLp_t)fcn; R_RAX=(uintptr_t)fn((uintptr_t)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX); }
-void pFpii(x64emu_t *emu, uintptr_t fcn) { pFpii_t fn = (pFpii_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX); }
-void pFpiu(x64emu_t *emu, uintptr_t fcn) { pFpiu_t fn = (pFpiu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX); }
-void pFpid(x64emu_t *emu, uintptr_t fcn) { pFpid_t fn = (pFpid_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, emu->xmm[0].d[0]); }
-void pFpil(x64emu_t *emu, uintptr_t fcn) { pFpil_t fn = (pFpil_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (intptr_t)R_RDX); }
-void pFpiL(x64emu_t *emu, uintptr_t fcn) { pFpiL_t fn = (pFpiL_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (uintptr_t)R_RDX); }
-void pFpip(x64emu_t *emu, uintptr_t fcn) { pFpip_t fn = (pFpip_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX); }
-void pFpCC(x64emu_t *emu, uintptr_t fcn) { pFpCC_t fn = (pFpCC_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint8_t)R_RSI, (uint8_t)R_RDX); }
-void pFpCu(x64emu_t *emu, uintptr_t fcn) { pFpCu_t fn = (pFpCu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint8_t)R_RSI, (uint64_t)R_RDX); }
-void pFpWW(x64emu_t *emu, uintptr_t fcn) { pFpWW_t fn = (pFpWW_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint16_t)R_RSI, (uint16_t)R_RDX); }
-void pFpui(x64emu_t *emu, uintptr_t fcn) { pFpui_t fn = (pFpui_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX); }
-void pFpuu(x64emu_t *emu, uintptr_t fcn) { pFpuu_t fn = (pFpuu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX); }
-void pFpuL(x64emu_t *emu, uintptr_t fcn) { pFpuL_t fn = (pFpuL_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uintptr_t)R_RDX); }
-void pFpup(x64emu_t *emu, uintptr_t fcn) { pFpup_t fn = (pFpup_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX); }
-void pFpUi(x64emu_t *emu, uintptr_t fcn) { pFpUi_t fn = (pFpUi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX); }
-void pFpUp(x64emu_t *emu, uintptr_t fcn) { pFpUp_t fn = (pFpUp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX); }
-void pFpdu(x64emu_t *emu, uintptr_t fcn) { pFpdu_t fn = (pFpdu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, emu->xmm[0].d[0], (uint64_t)R_RSI); }
-void pFplC(x64emu_t *emu, uintptr_t fcn) { pFplC_t fn = (pFplC_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (intptr_t)R_RSI, (uint8_t)R_RDX); }
-void pFplu(x64emu_t *emu, uintptr_t fcn) { pFplu_t fn = (pFplu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (intptr_t)R_RSI, (uint64_t)R_RDX); }
-void pFpll(x64emu_t *emu, uintptr_t fcn) { pFpll_t fn = (pFpll_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (intptr_t)R_RSI, (intptr_t)R_RDX); }
-void pFplp(x64emu_t *emu, uintptr_t fcn) { pFplp_t fn = (pFplp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (intptr_t)R_RSI, (void*)R_RDX); }
-void pFpLu(x64emu_t *emu, uintptr_t fcn) { pFpLu_t fn = (pFpLu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (uint64_t)R_RDX); }
-void pFpLL(x64emu_t *emu, uintptr_t fcn) { pFpLL_t fn = (pFpLL_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (uintptr_t)R_RDX); }
-void pFpLp(x64emu_t *emu, uintptr_t fcn) { pFpLp_t fn = (pFpLp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX); }
-void pFppi(x64emu_t *emu, uintptr_t fcn) { pFppi_t fn = (pFppi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX); }
-void pFppI(x64emu_t *emu, uintptr_t fcn) { pFppI_t fn = (pFppI_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX); }
-void pFppC(x64emu_t *emu, uintptr_t fcn) { pFppC_t fn = (pFppC_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (uint8_t)R_RDX); }
-void pFppu(x64emu_t *emu, uintptr_t fcn) { pFppu_t fn = (pFppu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX); }
-void pFppU(x64emu_t *emu, uintptr_t fcn) { pFppU_t fn = (pFppU_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX); }
-void pFppf(x64emu_t *emu, uintptr_t fcn) { pFppf_t fn = (pFppf_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, emu->xmm[0].f[0]); }
-void pFppl(x64emu_t *emu, uintptr_t fcn) { pFppl_t fn = (pFppl_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (intptr_t)R_RDX); }
-void pFppL(x64emu_t *emu, uintptr_t fcn) { pFppL_t fn = (pFppL_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX); }
-void pFppp(x64emu_t *emu, uintptr_t fcn) { pFppp_t fn = (pFppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void pFpOM(x64emu_t *emu, uintptr_t fcn) { pFpOM_t fn = (pFpOM_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, of_convert((int32_t)R_RSI), (void*)R_RDX, (void*)R_RCX); }
-void pFSpl(x64emu_t *emu, uintptr_t fcn) { pFSpl_t fn = (pFSpl_t)fcn; R_RAX=(uintptr_t)fn(io_convert((void*)R_RDI), (void*)R_RSI, (intptr_t)R_RDX); }
-void vWpup(x64emu_t *emu, uintptr_t fcn) { vWpup_t fn = (vWpup_t)fcn; fn((void*)R_RCX, (uint64_t)R_RDX, (void*)R_R8); }
-void iWEip(x64emu_t *emu, uintptr_t fcn) { iWEip_t fn = (iWEip_t)fcn; R_RAX=(int64_t)fn(emu, (int64_t)R_RCX, (void*)R_RDX); }
-void iWEpp(x64emu_t *emu, uintptr_t fcn) { iWEpp_t fn = (iWEpp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RCX, (void*)R_RDX); }
-void iWpiu(x64emu_t *emu, uintptr_t fcn) { iWpiu_t fn = (iWpiu_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (int64_t)R_RDX, (uint64_t)R_R8); }
-void iWpip(x64emu_t *emu, uintptr_t fcn) { iWpip_t fn = (iWpip_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (int64_t)R_RDX, (void*)R_R8); }
-void iWpui(x64emu_t *emu, uintptr_t fcn) { iWpui_t fn = (iWpui_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (uint64_t)R_RDX, (int64_t)R_R8); }
-void iWpuu(x64emu_t *emu, uintptr_t fcn) { iWpuu_t fn = (iWpuu_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (uint64_t)R_RDX, (uint64_t)R_R8); }
-void iWpup(x64emu_t *emu, uintptr_t fcn) { iWpup_t fn = (iWpup_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (uint64_t)R_RDX, (void*)R_R8); }
-void iWppu(x64emu_t *emu, uintptr_t fcn) { iWppu_t fn = (iWppu_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (void*)R_RDX, (uint64_t)R_R8); }
-void iWppp(x64emu_t *emu, uintptr_t fcn) { iWppp_t fn = (iWppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (void*)R_RDX, (void*)R_R8); }
-void uWpui(x64emu_t *emu, uintptr_t fcn) { uWpui_t fn = (uWpui_t)fcn; R_RAX=(uint64_t)fn((void*)R_RCX, (uint64_t)R_RDX, (int64_t)R_R8); }
-void uWpup(x64emu_t *emu, uintptr_t fcn) { uWpup_t fn = (uWpup_t)fcn; R_RAX=(uint64_t)fn((void*)R_RCX, (uint64_t)R_RDX, (void*)R_R8); }
-void vFEiip(x64emu_t *emu, uintptr_t fcn) { vFEiip_t fn = (vFEiip_t)fcn; fn(emu, (int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX); }
-void vFEipp(x64emu_t *emu, uintptr_t fcn) { vFEipp_t fn = (vFEipp_t)fcn; fn(emu, (int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void vFEipV(x64emu_t *emu, uintptr_t fcn) { vFEipV_t fn = (vFEipV_t)fcn; fn(emu, (int64_t)R_RDI, (void*)R_RSI, (void*)(R_RSP + 8)); }
-void vFEipA(x64emu_t *emu, uintptr_t fcn) { vFEipA_t fn = (vFEipA_t)fcn; fn(emu, (int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void vFELLp(x64emu_t *emu, uintptr_t fcn) { vFELLp_t fn = (vFELLp_t)fcn; fn(emu, (uintptr_t)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX); }
-void vFEpii(x64emu_t *emu, uintptr_t fcn) { vFEpii_t fn = (vFEpii_t)fcn; fn(emu, (void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX); }
-void vFEpip(x64emu_t *emu, uintptr_t fcn) { vFEpip_t fn = (vFEpip_t)fcn; fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX); }
-void vFEpiA(x64emu_t *emu, uintptr_t fcn) { vFEpiA_t fn = (vFEpiA_t)fcn; fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX); }
-void vFEpup(x64emu_t *emu, uintptr_t fcn) { vFEpup_t fn = (vFEpup_t)fcn; fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX); }
-void vFEpUp(x64emu_t *emu, uintptr_t fcn) { vFEpUp_t fn = (vFEpUp_t)fcn; fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX); }
-void vFEppp(x64emu_t *emu, uintptr_t fcn) { vFEppp_t fn = (vFEppp_t)fcn; fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void vFEppV(x64emu_t *emu, uintptr_t fcn) { vFEppV_t fn = (vFEppV_t)fcn; fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)(R_RSP + 8)); }
-void vFEppA(x64emu_t *emu, uintptr_t fcn) { vFEppA_t fn = (vFEppA_t)fcn; fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void vFiiii(x64emu_t *emu, uintptr_t fcn) { vFiiii_t fn = (vFiiii_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void vFiiip(x64emu_t *emu, uintptr_t fcn) { vFiiip_t fn = (vFiiip_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void vFiill(x64emu_t *emu, uintptr_t fcn) { vFiill_t fn = (vFiill_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (intptr_t)R_RDX, (intptr_t)R_RCX); }
-void vFiIII(x64emu_t *emu, uintptr_t fcn) { vFiIII_t fn = (vFiIII_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void vFiuiu(x64emu_t *emu, uintptr_t fcn) { vFiuiu_t fn = (vFiuiu_t)fcn; fn((int64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX); }
-void vFiuip(x64emu_t *emu, uintptr_t fcn) { vFiuip_t fn = (vFiuip_t)fcn; fn((int64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void vFiuuu(x64emu_t *emu, uintptr_t fcn) { vFiuuu_t fn = (vFiuuu_t)fcn; fn((int64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void vFiuup(x64emu_t *emu, uintptr_t fcn) { vFiuup_t fn = (vFiuup_t)fcn; fn((int64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX); }
-void vFiulp(x64emu_t *emu, uintptr_t fcn) { vFiulp_t fn = (vFiulp_t)fcn; fn((int64_t)R_RDI, (uint64_t)R_RSI, (intptr_t)R_RDX, (void*)R_RCX); }
-void vFiupu(x64emu_t *emu, uintptr_t fcn) { vFiupu_t fn = (vFiupu_t)fcn; fn((int64_t)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX); }
-void vFiupV(x64emu_t *emu, uintptr_t fcn) { vFiupV_t fn = (vFiupV_t)fcn; fn((int64_t)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)(R_RSP + 8)); }
-void vFiUUU(x64emu_t *emu, uintptr_t fcn) { vFiUUU_t fn = (vFiUUU_t)fcn; fn((int64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void vFifff(x64emu_t *emu, uintptr_t fcn) { vFifff_t fn = (vFifff_t)fcn; fn((int64_t)R_RDI, emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0]); }
-void vFiddd(x64emu_t *emu, uintptr_t fcn) { vFiddd_t fn = (vFiddd_t)fcn; fn((int64_t)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0]); }
-void vFilil(x64emu_t *emu, uintptr_t fcn) { vFilil_t fn = (vFilil_t)fcn; fn((int64_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX); }
-void vFilip(x64emu_t *emu, uintptr_t fcn) { vFilip_t fn = (vFilip_t)fcn; fn((int64_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void vFiluU(x64emu_t *emu, uintptr_t fcn) { vFiluU_t fn = (vFiluU_t)fcn; fn((int64_t)R_RDI, (intptr_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void vFilpu(x64emu_t *emu, uintptr_t fcn) { vFilpu_t fn = (vFilpu_t)fcn; fn((int64_t)R_RDI, (intptr_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX); }
-void vFilpp(x64emu_t *emu, uintptr_t fcn) { vFilpp_t fn = (vFilpp_t)fcn; fn((int64_t)R_RDI, (intptr_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void vFipii(x64emu_t *emu, uintptr_t fcn) { vFipii_t fn = (vFipii_t)fcn; fn((int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void vFipup(x64emu_t *emu, uintptr_t fcn) { vFipup_t fn = (vFipup_t)fcn; fn((int64_t)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (void*)R_RCX); }
-void vFipll(x64emu_t *emu, uintptr_t fcn) { vFipll_t fn = (vFipll_t)fcn; fn((int64_t)R_RDI, (void*)R_RSI, (intptr_t)R_RDX, (intptr_t)R_RCX); }
-void vFippi(x64emu_t *emu, uintptr_t fcn) { vFippi_t fn = (vFippi_t)fcn; fn((int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void vFippu(x64emu_t *emu, uintptr_t fcn) { vFippu_t fn = (vFippu_t)fcn; fn((int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX); }
-void vFippp(x64emu_t *emu, uintptr_t fcn) { vFippp_t fn = (vFippp_t)fcn; fn((int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void vFuiii(x64emu_t *emu, uintptr_t fcn) { vFuiii_t fn = (vFuiii_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void vFuiiu(x64emu_t *emu, uintptr_t fcn) { vFuiiu_t fn = (vFuiiu_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX); }
-void vFuiip(x64emu_t *emu, uintptr_t fcn) { vFuiip_t fn = (vFuiip_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void vFuiII(x64emu_t *emu, uintptr_t fcn) { vFuiII_t fn = (vFuiII_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void vFuiui(x64emu_t *emu, uintptr_t fcn) { vFuiui_t fn = (vFuiui_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX); }
-void vFuiuu(x64emu_t *emu, uintptr_t fcn) { vFuiuu_t fn = (vFuiuu_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void vFuiup(x64emu_t *emu, uintptr_t fcn) { vFuiup_t fn = (vFuiup_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX); }
-void vFuiUU(x64emu_t *emu, uintptr_t fcn) { vFuiUU_t fn = (vFuiUU_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void vFuifi(x64emu_t *emu, uintptr_t fcn) { vFuifi_t fn = (vFuifi_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, emu->xmm[0].f[0], (int64_t)R_RDX); }
-void vFuiff(x64emu_t *emu, uintptr_t fcn) { vFuiff_t fn = (vFuiff_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, emu->xmm[0].f[0], emu->xmm[1].f[0]); }
-void vFuidd(x64emu_t *emu, uintptr_t fcn) { vFuidd_t fn = (vFuidd_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, emu->xmm[0].d[0], emu->xmm[1].d[0]); }
-void vFuill(x64emu_t *emu, uintptr_t fcn) { vFuill_t fn = (vFuill_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (intptr_t)R_RDX, (intptr_t)R_RCX); }
-void vFuilp(x64emu_t *emu, uintptr_t fcn) { vFuilp_t fn = (vFuilp_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (intptr_t)R_RDX, (void*)R_RCX); }
-void vFuipi(x64emu_t *emu, uintptr_t fcn) { vFuipi_t fn = (vFuipi_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void vFuipu(x64emu_t *emu, uintptr_t fcn) { vFuipu_t fn = (vFuipu_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX); }
-void vFuipp(x64emu_t *emu, uintptr_t fcn) { vFuipp_t fn = (vFuipp_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void vFuuii(x64emu_t *emu, uintptr_t fcn) { vFuuii_t fn = (vFuuii_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void vFuuiu(x64emu_t *emu, uintptr_t fcn) { vFuuiu_t fn = (vFuuiu_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX); }
-void vFuuil(x64emu_t *emu, uintptr_t fcn) { vFuuil_t fn = (vFuuil_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX); }
-void vFuuip(x64emu_t *emu, uintptr_t fcn) { vFuuip_t fn = (vFuuip_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void vFuuui(x64emu_t *emu, uintptr_t fcn) { vFuuui_t fn = (vFuuui_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX); }
-void vFuuuu(x64emu_t *emu, uintptr_t fcn) { vFuuuu_t fn = (vFuuuu_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void vFuuuf(x64emu_t *emu, uintptr_t fcn) { vFuuuf_t fn = (vFuuuf_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, emu->xmm[0].f[0]); }
-void vFuuud(x64emu_t *emu, uintptr_t fcn) { vFuuud_t fn = (vFuuud_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, emu->xmm[0].d[0]); }
-void vFuuup(x64emu_t *emu, uintptr_t fcn) { vFuuup_t fn = (vFuuup_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX); }
-void vFuulp(x64emu_t *emu, uintptr_t fcn) { vFuulp_t fn = (vFuulp_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (intptr_t)R_RDX, (void*)R_RCX); }
-void vFuupi(x64emu_t *emu, uintptr_t fcn) { vFuupi_t fn = (vFuupi_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void vFuupp(x64emu_t *emu, uintptr_t fcn) { vFuupp_t fn = (vFuupp_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void vFuUii(x64emu_t *emu, uintptr_t fcn) { vFuUii_t fn = (vFuUii_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void vFuUip(x64emu_t *emu, uintptr_t fcn) { vFuUip_t fn = (vFuUip_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void vFufff(x64emu_t *emu, uintptr_t fcn) { vFufff_t fn = (vFufff_t)fcn; fn((uint64_t)R_RDI, emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0]); }
-void vFuddd(x64emu_t *emu, uintptr_t fcn) { vFuddd_t fn = (vFuddd_t)fcn; fn((uint64_t)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0]); }
-void vFulil(x64emu_t *emu, uintptr_t fcn) { vFulil_t fn = (vFulil_t)fcn; fn((uint64_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX); }
-void vFulip(x64emu_t *emu, uintptr_t fcn) { vFulip_t fn = (vFulip_t)fcn; fn((uint64_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void vFuluU(x64emu_t *emu, uintptr_t fcn) { vFuluU_t fn = (vFuluU_t)fcn; fn((uint64_t)R_RDI, (intptr_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void vFullp(x64emu_t *emu, uintptr_t fcn) { vFullp_t fn = (vFullp_t)fcn; fn((uint64_t)R_RDI, (intptr_t)R_RSI, (intptr_t)R_RDX, (void*)R_RCX); }
-void vFulpi(x64emu_t *emu, uintptr_t fcn) { vFulpi_t fn = (vFulpi_t)fcn; fn((uint64_t)R_RDI, (intptr_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void vFulpu(x64emu_t *emu, uintptr_t fcn) { vFulpu_t fn = (vFulpu_t)fcn; fn((uint64_t)R_RDI, (intptr_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX); }
-void vFulpp(x64emu_t *emu, uintptr_t fcn) { vFulpp_t fn = (vFulpp_t)fcn; fn((uint64_t)R_RDI, (intptr_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void vFupii(x64emu_t *emu, uintptr_t fcn) { vFupii_t fn = (vFupii_t)fcn; fn((uint64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void vFuppi(x64emu_t *emu, uintptr_t fcn) { vFuppi_t fn = (vFuppi_t)fcn; fn((uint64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void vFUUpi(x64emu_t *emu, uintptr_t fcn) { vFUUpi_t fn = (vFUUpi_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void vFffff(x64emu_t *emu, uintptr_t fcn) { vFffff_t fn = (vFffff_t)fcn; fn(emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0], emu->xmm[3].f[0]); }
-void vFdddd(x64emu_t *emu, uintptr_t fcn) { vFdddd_t fn = (vFdddd_t)fcn; fn(emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0]); }
-void vFllll(x64emu_t *emu, uintptr_t fcn) { vFllll_t fn = (vFllll_t)fcn; fn((intptr_t)R_RDI, (intptr_t)R_RSI, (intptr_t)R_RDX, (intptr_t)R_RCX); }
-void vFpiii(x64emu_t *emu, uintptr_t fcn) { vFpiii_t fn = (vFpiii_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void vFpiiu(x64emu_t *emu, uintptr_t fcn) { vFpiiu_t fn = (vFpiiu_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX); }
-void vFpiip(x64emu_t *emu, uintptr_t fcn) { vFpiip_t fn = (vFpiip_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void vFpiuu(x64emu_t *emu, uintptr_t fcn) { vFpiuu_t fn = (vFpiuu_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void vFpiuL(x64emu_t *emu, uintptr_t fcn) { vFpiuL_t fn = (vFpiuL_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uintptr_t)R_RCX); }
-void vFpiup(x64emu_t *emu, uintptr_t fcn) { vFpiup_t fn = (vFpiup_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX); }
-void vFpiUu(x64emu_t *emu, uintptr_t fcn) { vFpiUu_t fn = (vFpiUu_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void vFpiUU(x64emu_t *emu, uintptr_t fcn) { vFpiUU_t fn = (vFpiUU_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void vFpifi(x64emu_t *emu, uintptr_t fcn) { vFpifi_t fn = (vFpifi_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, emu->xmm[0].f[0], (int64_t)R_RDX); }
-void vFpipi(x64emu_t *emu, uintptr_t fcn) { vFpipi_t fn = (vFpipi_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void vFpipp(x64emu_t *emu, uintptr_t fcn) { vFpipp_t fn = (vFpipp_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void vFpIdi(x64emu_t *emu, uintptr_t fcn) { vFpIdi_t fn = (vFpIdi_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, emu->xmm[0].d[0], (int64_t)R_RDX); }
-void vFpCiW(x64emu_t *emu, uintptr_t fcn) { vFpCiW_t fn = (vFpCiW_t)fcn; fn((void*)R_RDI, (uint8_t)R_RSI, (int64_t)R_RDX, (uint16_t)R_RCX); }
-void vFpuip(x64emu_t *emu, uintptr_t fcn) { vFpuip_t fn = (vFpuip_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void vFpuui(x64emu_t *emu, uintptr_t fcn) { vFpuui_t fn = (vFpuui_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX); }
-void vFpuuu(x64emu_t *emu, uintptr_t fcn) { vFpuuu_t fn = (vFpuuu_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void vFpuup(x64emu_t *emu, uintptr_t fcn) { vFpuup_t fn = (vFpuup_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX); }
-void vFpudd(x64emu_t *emu, uintptr_t fcn) { vFpudd_t fn = (vFpudd_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, emu->xmm[0].d[0], emu->xmm[1].d[0]); }
-void vFpupp(x64emu_t *emu, uintptr_t fcn) { vFpupp_t fn = (vFpupp_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void vFpUui(x64emu_t *emu, uintptr_t fcn) { vFpUui_t fn = (vFpUui_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX); }
-void vFpUuu(x64emu_t *emu, uintptr_t fcn) { vFpUuu_t fn = (vFpUuu_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void vFpUup(x64emu_t *emu, uintptr_t fcn) { vFpUup_t fn = (vFpUup_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX); }
-void vFpUUi(x64emu_t *emu, uintptr_t fcn) { vFpUUi_t fn = (vFpUUi_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX); }
-void vFpUUu(x64emu_t *emu, uintptr_t fcn) { vFpUUu_t fn = (vFpUUu_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void vFpUUp(x64emu_t *emu, uintptr_t fcn) { vFpUUp_t fn = (vFpUUp_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX); }
-void vFpUpp(x64emu_t *emu, uintptr_t fcn) { vFpUpp_t fn = (vFpUpp_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void vFpfff(x64emu_t *emu, uintptr_t fcn) { vFpfff_t fn = (vFpfff_t)fcn; fn((void*)R_RDI, emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0]); }
-void vFpdii(x64emu_t *emu, uintptr_t fcn) { vFpdii_t fn = (vFpdii_t)fcn; fn((void*)R_RDI, emu->xmm[0].d[0], (int64_t)R_RSI, (int64_t)R_RDX); }
-void vFpdip(x64emu_t *emu, uintptr_t fcn) { vFpdip_t fn = (vFpdip_t)fcn; fn((void*)R_RDI, emu->xmm[0].d[0], (int64_t)R_RSI, (void*)R_RDX); }
-void vFpddi(x64emu_t *emu, uintptr_t fcn) { vFpddi_t fn = (vFpddi_t)fcn; fn((void*)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0], (int64_t)R_RSI); }
-void vFpddd(x64emu_t *emu, uintptr_t fcn) { vFpddd_t fn = (vFpddd_t)fcn; fn((void*)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0]); }
-void vFplpp(x64emu_t *emu, uintptr_t fcn) { vFplpp_t fn = (vFplpp_t)fcn; fn((void*)R_RDI, (intptr_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void vFpLLL(x64emu_t *emu, uintptr_t fcn) { vFpLLL_t fn = (vFpLLL_t)fcn; fn((void*)R_RDI, (uintptr_t)R_RSI, (uintptr_t)R_RDX, (uintptr_t)R_RCX); }
-void vFppii(x64emu_t *emu, uintptr_t fcn) { vFppii_t fn = (vFppii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void vFppiu(x64emu_t *emu, uintptr_t fcn) { vFppiu_t fn = (vFppiu_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX); }
-void vFppid(x64emu_t *emu, uintptr_t fcn) { vFppid_t fn = (vFppid_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, emu->xmm[0].d[0]); }
-void vFppil(x64emu_t *emu, uintptr_t fcn) { vFppil_t fn = (vFppil_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX); }
-void vFppiL(x64emu_t *emu, uintptr_t fcn) { vFppiL_t fn = (vFppiL_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (uintptr_t)R_RCX); }
-void vFppip(x64emu_t *emu, uintptr_t fcn) { vFppip_t fn = (vFppip_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void vFppui(x64emu_t *emu, uintptr_t fcn) { vFppui_t fn = (vFppui_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX); }
-void vFppuu(x64emu_t *emu, uintptr_t fcn) { vFppuu_t fn = (vFppuu_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void vFppup(x64emu_t *emu, uintptr_t fcn) { vFppup_t fn = (vFppup_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (void*)R_RCX); }
-void vFppfi(x64emu_t *emu, uintptr_t fcn) { vFppfi_t fn = (vFppfi_t)fcn; fn((void*)R_RDI, (void*)R_RSI, emu->xmm[0].f[0], (int64_t)R_RDX); }
-void vFppdu(x64emu_t *emu, uintptr_t fcn) { vFppdu_t fn = (vFppdu_t)fcn; fn((void*)R_RDI, (void*)R_RSI, emu->xmm[0].d[0], (uint64_t)R_RDX); }
-void vFppdd(x64emu_t *emu, uintptr_t fcn) { vFppdd_t fn = (vFppdd_t)fcn; fn((void*)R_RDI, (void*)R_RSI, emu->xmm[0].d[0], emu->xmm[1].d[0]); }
-void vFppdp(x64emu_t *emu, uintptr_t fcn) { vFppdp_t fn = (vFppdp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, emu->xmm[0].d[0], (void*)R_RDX); }
-void vFpplp(x64emu_t *emu, uintptr_t fcn) { vFpplp_t fn = (vFpplp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (intptr_t)R_RDX, (void*)R_RCX); }
-void vFppLp(x64emu_t *emu, uintptr_t fcn) { vFppLp_t fn = (vFppLp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX); }
-void vFpppi(x64emu_t *emu, uintptr_t fcn) { vFpppi_t fn = (vFpppi_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void vFpppI(x64emu_t *emu, uintptr_t fcn) { vFpppI_t fn = (vFpppI_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void vFpppu(x64emu_t *emu, uintptr_t fcn) { vFpppu_t fn = (vFpppu_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX); }
-void vFpppU(x64emu_t *emu, uintptr_t fcn) { vFpppU_t fn = (vFpppU_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX); }
-void vFpppd(x64emu_t *emu, uintptr_t fcn) { vFpppd_t fn = (vFpppd_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, emu->xmm[0].d[0]); }
-void vFpppL(x64emu_t *emu, uintptr_t fcn) { vFpppL_t fn = (vFpppL_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uintptr_t)R_RCX); }
-void vFpppp(x64emu_t *emu, uintptr_t fcn) { vFpppp_t fn = (vFpppp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void cFpiii(x64emu_t *emu, uintptr_t fcn) { cFpiii_t fn = (cFpiii_t)fcn; R_RAX=fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void iFEiip(x64emu_t *emu, uintptr_t fcn) { iFEiip_t fn = (iFEiip_t)fcn; R_RAX=(int64_t)fn(emu, (int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX); }
-void iFEiiN(x64emu_t *emu, uintptr_t fcn) { iFEiiN_t fn = (iFEiiN_t)fcn; R_RAX=(int64_t)fn(emu, (int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX); }
-void iFEipp(x64emu_t *emu, uintptr_t fcn) { iFEipp_t fn = (iFEipp_t)fcn; R_RAX=(int64_t)fn(emu, (int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void iFEipV(x64emu_t *emu, uintptr_t fcn) { iFEipV_t fn = (iFEipV_t)fcn; R_RAX=(int64_t)fn(emu, (int64_t)R_RDI, (void*)R_RSI, (void*)(R_RSP + 8)); }
-void iFEupu(x64emu_t *emu, uintptr_t fcn) { iFEupu_t fn = (iFEupu_t)fcn; R_RAX=(int64_t)fn(emu, (uint64_t)R_RDI, (void*)R_RSI, (uint64_t)R_RDX); }
-void iFEupp(x64emu_t *emu, uintptr_t fcn) { iFEupp_t fn = (iFEupp_t)fcn; R_RAX=(int64_t)fn(emu, (uint64_t)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void iFEpii(x64emu_t *emu, uintptr_t fcn) { iFEpii_t fn = (iFEpii_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX); }
-void iFEpip(x64emu_t *emu, uintptr_t fcn) { iFEpip_t fn = (iFEpip_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX); }
-void iFEpiV(x64emu_t *emu, uintptr_t fcn) { iFEpiV_t fn = (iFEpiV_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)(R_RSP + 8)); }
-void iFEpiA(x64emu_t *emu, uintptr_t fcn) { iFEpiA_t fn = (iFEpiA_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX); }
-void iFEpui(x64emu_t *emu, uintptr_t fcn) { iFEpui_t fn = (iFEpui_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX); }
-void iFEpup(x64emu_t *emu, uintptr_t fcn) { iFEpup_t fn = (iFEpup_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX); }
-void iFEpUi(x64emu_t *emu, uintptr_t fcn) { iFEpUi_t fn = (iFEpUi_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX); }
-void iFEpUp(x64emu_t *emu, uintptr_t fcn) { iFEpUp_t fn = (iFEpUp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX); }
-void iFEpLi(x64emu_t *emu, uintptr_t fcn) { iFEpLi_t fn = (iFEpLi_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (uintptr_t)R_RSI, (int64_t)R_RDX); }
-void iFEpLp(x64emu_t *emu, uintptr_t fcn) { iFEpLp_t fn = (iFEpLp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX); }
-void iFEppi(x64emu_t *emu, uintptr_t fcn) { iFEppi_t fn = (iFEppi_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX); }
-void iFEppd(x64emu_t *emu, uintptr_t fcn) { iFEppd_t fn = (iFEppd_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, emu->xmm[0].d[0]); }
-void iFEppL(x64emu_t *emu, uintptr_t fcn) { iFEppL_t fn = (iFEppL_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX); }
-void iFEppp(x64emu_t *emu, uintptr_t fcn) { iFEppp_t fn = (iFEppp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void iFEppV(x64emu_t *emu, uintptr_t fcn) { iFEppV_t fn = (iFEppV_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)(R_RSP + 8)); }
-void iFEppA(x64emu_t *emu, uintptr_t fcn) { iFEppA_t fn = (iFEppA_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void iFEpOu(x64emu_t *emu, uintptr_t fcn) { iFEpOu_t fn = (iFEpOu_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, of_convert((int32_t)R_RSI), (uint64_t)R_RDX); }
-void iFwwww(x64emu_t *emu, uintptr_t fcn) { iFwwww_t fn = (iFwwww_t)fcn; R_RAX=(int64_t)fn((int16_t)R_RDI, (int16_t)R_RSI, (int16_t)R_RDX, (int16_t)R_RCX); }
-void iFwppp(x64emu_t *emu, uintptr_t fcn) { iFwppp_t fn = (iFwppp_t)fcn; R_RAX=(int64_t)fn((int16_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void iFiiii(x64emu_t *emu, uintptr_t fcn) { iFiiii_t fn = (iFiiii_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void iFiiiu(x64emu_t *emu, uintptr_t fcn) { iFiiiu_t fn = (iFiiiu_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX); }
-void iFiiip(x64emu_t *emu, uintptr_t fcn) { iFiiip_t fn = (iFiiip_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void iFiiiN(x64emu_t *emu, uintptr_t fcn) { iFiiiN_t fn = (iFiiiN_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void iFiiui(x64emu_t *emu, uintptr_t fcn) { iFiiui_t fn = (iFiiui_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX); }
-void iFiiup(x64emu_t *emu, uintptr_t fcn) { iFiiup_t fn = (iFiiup_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX); }
-void iFiill(x64emu_t *emu, uintptr_t fcn) { iFiill_t fn = (iFiill_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (intptr_t)R_RDX, (intptr_t)R_RCX); }
-void iFiipi(x64emu_t *emu, uintptr_t fcn) { iFiipi_t fn = (iFiipi_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void iFiipp(x64emu_t *emu, uintptr_t fcn) { iFiipp_t fn = (iFiipp_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void iFiuwp(x64emu_t *emu, uintptr_t fcn) { iFiuwp_t fn = (iFiuwp_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (uint64_t)R_RSI, (int16_t)R_RDX, (void*)R_RCX); }
-void iFiuii(x64emu_t *emu, uintptr_t fcn) { iFiuii_t fn = (iFiuii_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void iFiuup(x64emu_t *emu, uintptr_t fcn) { iFiuup_t fn = (iFiuup_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX); }
-void iFiupp(x64emu_t *emu, uintptr_t fcn) { iFiupp_t fn = (iFiupp_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void iFilli(x64emu_t *emu, uintptr_t fcn) { iFilli_t fn = (iFilli_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (intptr_t)R_RSI, (intptr_t)R_RDX, (int64_t)R_RCX); }
-void iFillu(x64emu_t *emu, uintptr_t fcn) { iFillu_t fn = (iFillu_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (intptr_t)R_RSI, (intptr_t)R_RDX, (uint64_t)R_RCX); }
-void iFipii(x64emu_t *emu, uintptr_t fcn) { iFipii_t fn = (iFipii_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void iFipip(x64emu_t *emu, uintptr_t fcn) { iFipip_t fn = (iFipip_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void iFipui(x64emu_t *emu, uintptr_t fcn) { iFipui_t fn = (iFipui_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX); }
-void iFipuu(x64emu_t *emu, uintptr_t fcn) { iFipuu_t fn = (iFipuu_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void iFipup(x64emu_t *emu, uintptr_t fcn) { iFipup_t fn = (iFipup_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (void*)R_RCX); }
-void iFipLi(x64emu_t *emu, uintptr_t fcn) { iFipLi_t fn = (iFipLi_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (int64_t)R_RCX); }
-void iFipLu(x64emu_t *emu, uintptr_t fcn) { iFipLu_t fn = (iFipLu_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (uint64_t)R_RCX); }
-void iFipLp(x64emu_t *emu, uintptr_t fcn) { iFipLp_t fn = (iFipLp_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX); }
-void iFippi(x64emu_t *emu, uintptr_t fcn) { iFippi_t fn = (iFippi_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void iFippu(x64emu_t *emu, uintptr_t fcn) { iFippu_t fn = (iFippu_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX); }
-void iFippL(x64emu_t *emu, uintptr_t fcn) { iFippL_t fn = (iFippL_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (uintptr_t)R_RCX); }
-void iFippp(x64emu_t *emu, uintptr_t fcn) { iFippp_t fn = (iFippp_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void iFipON(x64emu_t *emu, uintptr_t fcn) { iFipON_t fn = (iFipON_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, of_convert((int32_t)R_RDX), (void*)R_RCX); }
-void iFuipu(x64emu_t *emu, uintptr_t fcn) { iFuipu_t fn = (iFuipu_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX); }
-void iFuipp(x64emu_t *emu, uintptr_t fcn) { iFuipp_t fn = (iFuipp_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void iFuuff(x64emu_t *emu, uintptr_t fcn) { iFuuff_t fn = (iFuuff_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (uint64_t)R_RSI, emu->xmm[0].f[0], emu->xmm[1].f[0]); }
-void iFuupi(x64emu_t *emu, uintptr_t fcn) { iFuupi_t fn = (iFuupi_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void iFupLp(x64emu_t *emu, uintptr_t fcn) { iFupLp_t fn = (iFupLp_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX); }
-void iFuppi(x64emu_t *emu, uintptr_t fcn) { iFuppi_t fn = (iFuppi_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void iFuppp(x64emu_t *emu, uintptr_t fcn) { iFuppp_t fn = (iFuppp_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void iFLLiW(x64emu_t *emu, uintptr_t fcn) { iFLLiW_t fn = (iFLLiW_t)fcn; R_RAX=(int64_t)fn((uintptr_t)R_RDI, (uintptr_t)R_RSI, (int64_t)R_RDX, (uint16_t)R_RCX); }
-void iFpwww(x64emu_t *emu, uintptr_t fcn) { iFpwww_t fn = (iFpwww_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int16_t)R_RSI, (int16_t)R_RDX, (int16_t)R_RCX); }
-void iFpwpp(x64emu_t *emu, uintptr_t fcn) { iFpwpp_t fn = (iFpwpp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int16_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void iFpiii(x64emu_t *emu, uintptr_t fcn) { iFpiii_t fn = (iFpiii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void iFpiiI(x64emu_t *emu, uintptr_t fcn) { iFpiiI_t fn = (iFpiiI_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void iFpiiu(x64emu_t *emu, uintptr_t fcn) { iFpiiu_t fn = (iFpiiu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX); }
-void iFpiid(x64emu_t *emu, uintptr_t fcn) { iFpiid_t fn = (iFpiid_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, emu->xmm[0].d[0]); }
-void iFpiiL(x64emu_t *emu, uintptr_t fcn) { iFpiiL_t fn = (iFpiiL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (uintptr_t)R_RCX); }
-void iFpiip(x64emu_t *emu, uintptr_t fcn) { iFpiip_t fn = (iFpiip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void iFpiuu(x64emu_t *emu, uintptr_t fcn) { iFpiuu_t fn = (iFpiuu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void iFpiuL(x64emu_t *emu, uintptr_t fcn) { iFpiuL_t fn = (iFpiuL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uintptr_t)R_RCX); }
-void iFpiup(x64emu_t *emu, uintptr_t fcn) { iFpiup_t fn = (iFpiup_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX); }
-void iFpiUp(x64emu_t *emu, uintptr_t fcn) { iFpiUp_t fn = (iFpiUp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX); }
-void iFpild(x64emu_t *emu, uintptr_t fcn) { iFpild_t fn = (iFpild_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (intptr_t)R_RDX, emu->xmm[0].d[0]); }
-void iFpipi(x64emu_t *emu, uintptr_t fcn) { iFpipi_t fn = (iFpipi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void iFpipC(x64emu_t *emu, uintptr_t fcn) { iFpipC_t fn = (iFpipC_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (uint8_t)R_RCX); }
-void iFpipu(x64emu_t *emu, uintptr_t fcn) { iFpipu_t fn = (iFpipu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX); }
-void iFpipL(x64emu_t *emu, uintptr_t fcn) { iFpipL_t fn = (iFpipL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (uintptr_t)R_RCX); }
-void iFpipp(x64emu_t *emu, uintptr_t fcn) { iFpipp_t fn = (iFpipp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void iFpipV(x64emu_t *emu, uintptr_t fcn) { iFpipV_t fn = (iFpipV_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)(R_RSP + 8)); }
-void iFpIip(x64emu_t *emu, uintptr_t fcn) { iFpIip_t fn = (iFpIip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void iFpCCC(x64emu_t *emu, uintptr_t fcn) { iFpCCC_t fn = (iFpCCC_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint8_t)R_RSI, (uint8_t)R_RDX, (uint8_t)R_RCX); }
-void iFpCpi(x64emu_t *emu, uintptr_t fcn) { iFpCpi_t fn = (iFpCpi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint8_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void iFpWWu(x64emu_t *emu, uintptr_t fcn) { iFpWWu_t fn = (iFpWWu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint16_t)R_RSI, (uint16_t)R_RDX, (uint64_t)R_RCX); }
-void iFpuwp(x64emu_t *emu, uintptr_t fcn) { iFpuwp_t fn = (iFpuwp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (int16_t)R_RDX, (void*)R_RCX); }
-void iFpuiL(x64emu_t *emu, uintptr_t fcn) { iFpuiL_t fn = (iFpuiL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (uintptr_t)R_RCX); }
-void iFpuip(x64emu_t *emu, uintptr_t fcn) { iFpuip_t fn = (iFpuip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void iFpuui(x64emu_t *emu, uintptr_t fcn) { iFpuui_t fn = (iFpuui_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX); }
-void iFpuuu(x64emu_t *emu, uintptr_t fcn) { iFpuuu_t fn = (iFpuuu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void iFpuup(x64emu_t *emu, uintptr_t fcn) { iFpuup_t fn = (iFpuup_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX); }
-void iFpuUp(x64emu_t *emu, uintptr_t fcn) { iFpuUp_t fn = (iFpuUp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX); }
-void iFpuLL(x64emu_t *emu, uintptr_t fcn) { iFpuLL_t fn = (iFpuLL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uintptr_t)R_RDX, (uintptr_t)R_RCX); }
-void iFpuLp(x64emu_t *emu, uintptr_t fcn) { iFpuLp_t fn = (iFpuLp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX); }
-void iFpupi(x64emu_t *emu, uintptr_t fcn) { iFpupi_t fn = (iFpupi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void iFpupu(x64emu_t *emu, uintptr_t fcn) { iFpupu_t fn = (iFpupu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX); }
-void iFpupU(x64emu_t *emu, uintptr_t fcn) { iFpupU_t fn = (iFpupU_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX); }
-void iFpupL(x64emu_t *emu, uintptr_t fcn) { iFpupL_t fn = (iFpupL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (uintptr_t)R_RCX); }
-void iFpupp(x64emu_t *emu, uintptr_t fcn) { iFpupp_t fn = (iFpupp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void iFpupV(x64emu_t *emu, uintptr_t fcn) { iFpupV_t fn = (iFpupV_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)(R_RSP + 8)); }
-void iFpUup(x64emu_t *emu, uintptr_t fcn) { iFpUup_t fn = (iFpUup_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX); }
-void iFpUUU(x64emu_t *emu, uintptr_t fcn) { iFpUUU_t fn = (iFpUUU_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void iFpULp(x64emu_t *emu, uintptr_t fcn) { iFpULp_t fn = (iFpULp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX); }
-void iFpUpp(x64emu_t *emu, uintptr_t fcn) { iFpUpp_t fn = (iFpUpp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void iFplii(x64emu_t *emu, uintptr_t fcn) { iFplii_t fn = (iFplii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void iFplip(x64emu_t *emu, uintptr_t fcn) { iFplip_t fn = (iFplip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void iFpLii(x64emu_t *emu, uintptr_t fcn) { iFpLii_t fn = (iFpLii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void iFpLip(x64emu_t *emu, uintptr_t fcn) { iFpLip_t fn = (iFpLip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void iFpLLu(x64emu_t *emu, uintptr_t fcn) { iFpLLu_t fn = (iFpLLu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (uintptr_t)R_RDX, (uint64_t)R_RCX); }
-void iFpLpi(x64emu_t *emu, uintptr_t fcn) { iFpLpi_t fn = (iFpLpi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void iFpLpf(x64emu_t *emu, uintptr_t fcn) { iFpLpf_t fn = (iFpLpf_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX, emu->xmm[0].f[0]); }
-void iFpLpd(x64emu_t *emu, uintptr_t fcn) { iFpLpd_t fn = (iFpLpd_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX, emu->xmm[0].d[0]); }
-void iFpLpD(x64emu_t *emu, uintptr_t fcn) { iFpLpD_t fn = (iFpLpD_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX, LD2localLD((void*)(R_RSP + 8))); }
-void iFpLpL(x64emu_t *emu, uintptr_t fcn) { iFpLpL_t fn = (iFpLpL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX, (uintptr_t)R_RCX); }
-void iFpLpp(x64emu_t *emu, uintptr_t fcn) { iFpLpp_t fn = (iFpLpp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void iFppii(x64emu_t *emu, uintptr_t fcn) { iFppii_t fn = (iFppii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void iFppiu(x64emu_t *emu, uintptr_t fcn) { iFppiu_t fn = (iFppiu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX); }
-void iFppiU(x64emu_t *emu, uintptr_t fcn) { iFppiU_t fn = (iFppiU_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX); }
-void iFppiL(x64emu_t *emu, uintptr_t fcn) { iFppiL_t fn = (iFppiL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (uintptr_t)R_RCX); }
-void iFppip(x64emu_t *emu, uintptr_t fcn) { iFppip_t fn = (iFppip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void iFppIL(x64emu_t *emu, uintptr_t fcn) { iFppIL_t fn = (iFppIL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (uintptr_t)R_RCX); }
-void iFppCC(x64emu_t *emu, uintptr_t fcn) { iFppCC_t fn = (iFppCC_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uint8_t)R_RDX, (uint8_t)R_RCX); }
-void iFppuw(x64emu_t *emu, uintptr_t fcn) { iFppuw_t fn = (iFppuw_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (int16_t)R_RCX); }
-void iFppui(x64emu_t *emu, uintptr_t fcn) { iFppui_t fn = (iFppui_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX); }
-void iFppuu(x64emu_t *emu, uintptr_t fcn) { iFppuu_t fn = (iFppuu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void iFppup(x64emu_t *emu, uintptr_t fcn) { iFppup_t fn = (iFppup_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (void*)R_RCX); }
-void iFppdp(x64emu_t *emu, uintptr_t fcn) { iFppdp_t fn = (iFppdp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, emu->xmm[0].d[0], (void*)R_RDX); }
-void iFppll(x64emu_t *emu, uintptr_t fcn) { iFppll_t fn = (iFppll_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (intptr_t)R_RDX, (intptr_t)R_RCX); }
-void iFpplp(x64emu_t *emu, uintptr_t fcn) { iFpplp_t fn = (iFpplp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (intptr_t)R_RDX, (void*)R_RCX); }
-void iFppLi(x64emu_t *emu, uintptr_t fcn) { iFppLi_t fn = (iFppLi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (int64_t)R_RCX); }
-void iFppLL(x64emu_t *emu, uintptr_t fcn) { iFppLL_t fn = (iFppLL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (uintptr_t)R_RCX); }
-void iFppLp(x64emu_t *emu, uintptr_t fcn) { iFppLp_t fn = (iFppLp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX); }
-void iFpppi(x64emu_t *emu, uintptr_t fcn) { iFpppi_t fn = (iFpppi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void iFpppC(x64emu_t *emu, uintptr_t fcn) { iFpppC_t fn = (iFpppC_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint8_t)R_RCX); }
-void iFpppu(x64emu_t *emu, uintptr_t fcn) { iFpppu_t fn = (iFpppu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX); }
-void iFpppU(x64emu_t *emu, uintptr_t fcn) { iFpppU_t fn = (iFpppU_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX); }
-void iFpppL(x64emu_t *emu, uintptr_t fcn) { iFpppL_t fn = (iFpppL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uintptr_t)R_RCX); }
-void iFpppp(x64emu_t *emu, uintptr_t fcn) { iFpppp_t fn = (iFpppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void IFEpIi(x64emu_t *emu, uintptr_t fcn) { IFEpIi_t fn = (IFEpIi_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX); }
-void IFpIip(x64emu_t *emu, uintptr_t fcn) { IFpIip_t fn = (IFpIip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void IFppii(x64emu_t *emu, uintptr_t fcn) { IFppii_t fn = (IFppii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void IFppip(x64emu_t *emu, uintptr_t fcn) { IFppip_t fn = (IFppip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void IFpppp(x64emu_t *emu, uintptr_t fcn) { IFpppp_t fn = (IFpppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void IFSIii(x64emu_t *emu, uintptr_t fcn) { IFSIii_t fn = (IFSIii_t)fcn; R_RAX=(int64_t)fn(io_convert((void*)R_RDI), (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void CFpupp(x64emu_t *emu, uintptr_t fcn) { CFpupp_t fn = (CFpupp_t)fcn; R_RAX=(unsigned char)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void uFEipp(x64emu_t *emu, uintptr_t fcn) { uFEipp_t fn = (uFEipp_t)fcn; R_RAX=(uint64_t)fn(emu, (int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void uFEupp(x64emu_t *emu, uintptr_t fcn) { uFEupp_t fn = (uFEupp_t)fcn; R_RAX=(uint64_t)fn(emu, (uint64_t)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void uFEpup(x64emu_t *emu, uintptr_t fcn) { uFEpup_t fn = (uFEpup_t)fcn; R_RAX=(uint64_t)fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX); }
-void uFEppp(x64emu_t *emu, uintptr_t fcn) { uFEppp_t fn = (uFEppp_t)fcn; R_RAX=(uint64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void uFifff(x64emu_t *emu, uintptr_t fcn) { uFifff_t fn = (uFifff_t)fcn; R_RAX=(uint64_t)fn((int64_t)R_RDI, emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0]); }
-void uFuuuu(x64emu_t *emu, uintptr_t fcn) { uFuuuu_t fn = (uFuuuu_t)fcn; R_RAX=(uint64_t)fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void uFpiip(x64emu_t *emu, uintptr_t fcn) { uFpiip_t fn = (uFpiip_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void uFpipu(x64emu_t *emu, uintptr_t fcn) { uFpipu_t fn = (uFpipu_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX); }
-void uFpipp(x64emu_t *emu, uintptr_t fcn) { uFpipp_t fn = (uFpipp_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void uFpCCC(x64emu_t *emu, uintptr_t fcn) { uFpCCC_t fn = (uFpCCC_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (uint8_t)R_RSI, (uint8_t)R_RDX, (uint8_t)R_RCX); }
-void uFpuip(x64emu_t *emu, uintptr_t fcn) { uFpuip_t fn = (uFpuip_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void uFpuuu(x64emu_t *emu, uintptr_t fcn) { uFpuuu_t fn = (uFpuuu_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void uFpuup(x64emu_t *emu, uintptr_t fcn) { uFpuup_t fn = (uFpuup_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX); }
-void uFpupu(x64emu_t *emu, uintptr_t fcn) { uFpupu_t fn = (uFpupu_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX); }
-void uFppiu(x64emu_t *emu, uintptr_t fcn) { uFppiu_t fn = (uFppiu_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX); }
-void uFppLp(x64emu_t *emu, uintptr_t fcn) { uFppLp_t fn = (uFppLp_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX); }
-void uFpppi(x64emu_t *emu, uintptr_t fcn) { uFpppi_t fn = (uFpppi_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void uFpppu(x64emu_t *emu, uintptr_t fcn) { uFpppu_t fn = (uFpppu_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX); }
-void uFpppp(x64emu_t *emu, uintptr_t fcn) { uFpppp_t fn = (uFpppp_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void UFpipp(x64emu_t *emu, uintptr_t fcn) { UFpipp_t fn = (UFpipp_t)fcn; R_RAX=fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void UFpUui(x64emu_t *emu, uintptr_t fcn) { UFpUui_t fn = (UFpUui_t)fcn; R_RAX=fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX); }
-void UFppii(x64emu_t *emu, uintptr_t fcn) { UFppii_t fn = (UFppii_t)fcn; R_RAX=fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void UFppip(x64emu_t *emu, uintptr_t fcn) { UFppip_t fn = (UFppip_t)fcn; R_RAX=fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void UFpppp(x64emu_t *emu, uintptr_t fcn) { UFpppp_t fn = (UFpppp_t)fcn; R_RAX=fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void dFpppp(x64emu_t *emu, uintptr_t fcn) { dFpppp_t fn = (dFpppp_t)fcn; emu->xmm[0].d[0]=fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void lFEipV(x64emu_t *emu, uintptr_t fcn) { lFEipV_t fn = (lFEipV_t)fcn; R_RAX=(intptr_t)fn(emu, (int64_t)R_RDI, (void*)R_RSI, (void*)(R_RSP + 8)); }
-void lFEpip(x64emu_t *emu, uintptr_t fcn) { lFEpip_t fn = (lFEpip_t)fcn; R_RAX=(intptr_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX); }
-void lFEppL(x64emu_t *emu, uintptr_t fcn) { lFEppL_t fn = (lFEppL_t)fcn; R_RAX=(intptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX); }
-void lFEppp(x64emu_t *emu, uintptr_t fcn) { lFEppp_t fn = (lFEppp_t)fcn; R_RAX=(intptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void lFiiLu(x64emu_t *emu, uintptr_t fcn) { lFiiLu_t fn = (lFiiLu_t)fcn; R_RAX=(intptr_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (uintptr_t)R_RDX, (uint64_t)R_RCX); }
-void lFiipL(x64emu_t *emu, uintptr_t fcn) { lFiipL_t fn = (lFiipL_t)fcn; R_RAX=(intptr_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (uintptr_t)R_RCX); }
-void lFipil(x64emu_t *emu, uintptr_t fcn) { lFipil_t fn = (lFipil_t)fcn; R_RAX=(intptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX); }
-void lFipLi(x64emu_t *emu, uintptr_t fcn) { lFipLi_t fn = (lFipLi_t)fcn; R_RAX=(intptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (int64_t)R_RCX); }
-void lFipLI(x64emu_t *emu, uintptr_t fcn) { lFipLI_t fn = (lFipLI_t)fcn; R_RAX=(intptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (int64_t)R_RCX); }
-void lFipLu(x64emu_t *emu, uintptr_t fcn) { lFipLu_t fn = (lFipLu_t)fcn; R_RAX=(intptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (uint64_t)R_RCX); }
-void lFipLl(x64emu_t *emu, uintptr_t fcn) { lFipLl_t fn = (lFipLl_t)fcn; R_RAX=(intptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (intptr_t)R_RCX); }
-void lFipLL(x64emu_t *emu, uintptr_t fcn) { lFipLL_t fn = (lFipLL_t)fcn; R_RAX=(intptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (uintptr_t)R_RCX); }
-void lFipLp(x64emu_t *emu, uintptr_t fcn) { lFipLp_t fn = (lFipLp_t)fcn; R_RAX=(intptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX); }
-void lFippL(x64emu_t *emu, uintptr_t fcn) { lFippL_t fn = (lFippL_t)fcn; R_RAX=(intptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (uintptr_t)R_RCX); }
-void lFuipp(x64emu_t *emu, uintptr_t fcn) { lFuipp_t fn = (lFuipp_t)fcn; R_RAX=(intptr_t)fn((uint64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void lFpili(x64emu_t *emu, uintptr_t fcn) { lFpili_t fn = (lFpili_t)fcn; R_RAX=(intptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (intptr_t)R_RDX, (int64_t)R_RCX); }
-void lFpilp(x64emu_t *emu, uintptr_t fcn) { lFpilp_t fn = (lFpilp_t)fcn; R_RAX=(intptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (intptr_t)R_RDX, (void*)R_RCX); }
-void lFppii(x64emu_t *emu, uintptr_t fcn) { lFppii_t fn = (lFppii_t)fcn; R_RAX=(intptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void lFppip(x64emu_t *emu, uintptr_t fcn) { lFppip_t fn = (lFppip_t)fcn; R_RAX=(intptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void lFpppL(x64emu_t *emu, uintptr_t fcn) { lFpppL_t fn = (lFpppL_t)fcn; R_RAX=(intptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uintptr_t)R_RCX); }
-void LFEppL(x64emu_t *emu, uintptr_t fcn) { LFEppL_t fn = (LFEppL_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX); }
-void LFEppp(x64emu_t *emu, uintptr_t fcn) { LFEppp_t fn = (LFEppp_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void LFippL(x64emu_t *emu, uintptr_t fcn) { LFippL_t fn = (LFippL_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (uintptr_t)R_RCX); }
-void LFippp(x64emu_t *emu, uintptr_t fcn) { LFippp_t fn = (LFippp_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void LFpuuu(x64emu_t *emu, uintptr_t fcn) { LFpuuu_t fn = (LFpuuu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void LFpLCL(x64emu_t *emu, uintptr_t fcn) { LFpLCL_t fn = (LFpLCL_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (uint8_t)R_RDX, (uintptr_t)R_RCX); }
-void LFpLLp(x64emu_t *emu, uintptr_t fcn) { LFpLLp_t fn = (LFpLLp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX); }
-void LFpLpL(x64emu_t *emu, uintptr_t fcn) { LFpLpL_t fn = (LFpLpL_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX, (uintptr_t)R_RCX); }
-void LFpLpp(x64emu_t *emu, uintptr_t fcn) { LFpLpp_t fn = (LFpLpp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void LFppii(x64emu_t *emu, uintptr_t fcn) { LFppii_t fn = (LFppii_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void LFppip(x64emu_t *emu, uintptr_t fcn) { LFppip_t fn = (LFppip_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void LFppLL(x64emu_t *emu, uintptr_t fcn) { LFppLL_t fn = (LFppLL_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (uintptr_t)R_RCX); }
-void LFppLp(x64emu_t *emu, uintptr_t fcn) { LFppLp_t fn = (LFppLp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX); }
-void LFpppi(x64emu_t *emu, uintptr_t fcn) { LFpppi_t fn = (LFpppi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void LFpppp(x64emu_t *emu, uintptr_t fcn) { LFpppp_t fn = (LFpppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void pFEipp(x64emu_t *emu, uintptr_t fcn) { pFEipp_t fn = (pFEipp_t)fcn; R_RAX=(uintptr_t)fn(emu, (int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void pFEupp(x64emu_t *emu, uintptr_t fcn) { pFEupp_t fn = (pFEupp_t)fcn; R_RAX=(uintptr_t)fn(emu, (uint64_t)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void pFELpV(x64emu_t *emu, uintptr_t fcn) { pFELpV_t fn = (pFELpV_t)fcn; R_RAX=(uintptr_t)fn(emu, (uintptr_t)R_RDI, (void*)R_RSI, (void*)(R_RSP + 8)); }
-void pFELpA(x64emu_t *emu, uintptr_t fcn) { pFELpA_t fn = (pFELpA_t)fcn; R_RAX=(uintptr_t)fn(emu, (uintptr_t)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void pFEpii(x64emu_t *emu, uintptr_t fcn) { pFEpii_t fn = (pFEpii_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX); }
-void pFEpip(x64emu_t *emu, uintptr_t fcn) { pFEpip_t fn = (pFEpip_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX); }
-void pFEppi(x64emu_t *emu, uintptr_t fcn) { pFEppi_t fn = (pFEppi_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX); }
-void pFEppp(x64emu_t *emu, uintptr_t fcn) { pFEppp_t fn = (pFEppp_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void pFEppV(x64emu_t *emu, uintptr_t fcn) { pFEppV_t fn = (pFEppV_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)(R_RSP + 8)); }
-void pFiiii(x64emu_t *emu, uintptr_t fcn) { pFiiii_t fn = (pFiiii_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void pFiiiu(x64emu_t *emu, uintptr_t fcn) { pFiiiu_t fn = (pFiiiu_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX); }
-void pFiiuu(x64emu_t *emu, uintptr_t fcn) { pFiiuu_t fn = (pFiiuu_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void pFiiup(x64emu_t *emu, uintptr_t fcn) { pFiiup_t fn = (pFiiup_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX); }
-void pFiipi(x64emu_t *emu, uintptr_t fcn) { pFiipi_t fn = (pFiipi_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void pFiipp(x64emu_t *emu, uintptr_t fcn) { pFiipp_t fn = (pFiipp_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void pFiIIi(x64emu_t *emu, uintptr_t fcn) { pFiIIi_t fn = (pFiIIi_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void pFillu(x64emu_t *emu, uintptr_t fcn) { pFillu_t fn = (pFillu_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (intptr_t)R_RSI, (intptr_t)R_RDX, (uint64_t)R_RCX); }
-void pFipii(x64emu_t *emu, uintptr_t fcn) { pFipii_t fn = (pFipii_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void pFipip(x64emu_t *emu, uintptr_t fcn) { pFipip_t fn = (pFipip_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void pFippi(x64emu_t *emu, uintptr_t fcn) { pFippi_t fn = (pFippi_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void pFippu(x64emu_t *emu, uintptr_t fcn) { pFippu_t fn = (pFippu_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX); }
-void pFuiii(x64emu_t *emu, uintptr_t fcn) { pFuiii_t fn = (pFuiii_t)fcn; R_RAX=(uintptr_t)fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void pFuuii(x64emu_t *emu, uintptr_t fcn) { pFuuii_t fn = (pFuuii_t)fcn; R_RAX=(uintptr_t)fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void pFulli(x64emu_t *emu, uintptr_t fcn) { pFulli_t fn = (pFulli_t)fcn; R_RAX=(uintptr_t)fn((uint64_t)R_RDI, (intptr_t)R_RSI, (intptr_t)R_RDX, (int64_t)R_RCX); }
-void pFullu(x64emu_t *emu, uintptr_t fcn) { pFullu_t fn = (pFullu_t)fcn; R_RAX=(uintptr_t)fn((uint64_t)R_RDI, (intptr_t)R_RSI, (intptr_t)R_RDX, (uint64_t)R_RCX); }
-void pFffff(x64emu_t *emu, uintptr_t fcn) { pFffff_t fn = (pFffff_t)fcn; R_RAX=(uintptr_t)fn(emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0], emu->xmm[3].f[0]); }
-void pFdipp(x64emu_t *emu, uintptr_t fcn) { pFdipp_t fn = (pFdipp_t)fcn; R_RAX=(uintptr_t)fn(emu->xmm[0].d[0], (int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void pFdddd(x64emu_t *emu, uintptr_t fcn) { pFdddd_t fn = (pFdddd_t)fcn; R_RAX=(uintptr_t)fn(emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0]); }
-void pFDipp(x64emu_t *emu, uintptr_t fcn) { pFDipp_t fn = (pFDipp_t)fcn; R_RAX=(uintptr_t)fn(LD2localLD((void*)(R_RSP + 8)), (int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX); }
-void pFlfff(x64emu_t *emu, uintptr_t fcn) { pFlfff_t fn = (pFlfff_t)fcn; R_RAX=(uintptr_t)fn((intptr_t)R_RDI, emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0]); }
-void pFLiip(x64emu_t *emu, uintptr_t fcn) { pFLiip_t fn = (pFLiip_t)fcn; R_RAX=(uintptr_t)fn((uintptr_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void pFpiii(x64emu_t *emu, uintptr_t fcn) { pFpiii_t fn = (pFpiii_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void pFpiip(x64emu_t *emu, uintptr_t fcn) { pFpiip_t fn = (pFpiip_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void pFpiuu(x64emu_t *emu, uintptr_t fcn) { pFpiuu_t fn = (pFpiuu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void pFpiLL(x64emu_t *emu, uintptr_t fcn) { pFpiLL_t fn = (pFpiLL_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (uintptr_t)R_RDX, (uintptr_t)R_RCX); }
-void pFpipi(x64emu_t *emu, uintptr_t fcn) { pFpipi_t fn = (pFpipi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void pFpipd(x64emu_t *emu, uintptr_t fcn) { pFpipd_t fn = (pFpipd_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, emu->xmm[0].d[0]); }
-void pFpipp(x64emu_t *emu, uintptr_t fcn) { pFpipp_t fn = (pFpipp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void pFpCWp(x64emu_t *emu, uintptr_t fcn) { pFpCWp_t fn = (pFpCWp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint8_t)R_RSI, (uint16_t)R_RDX, (void*)R_RCX); }
-void pFpCuW(x64emu_t *emu, uintptr_t fcn) { pFpCuW_t fn = (pFpCuW_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint8_t)R_RSI, (uint64_t)R_RDX, (uint16_t)R_RCX); }
-void pFpCuu(x64emu_t *emu, uintptr_t fcn) { pFpCuu_t fn = (pFpCuu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint8_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void pFpuii(x64emu_t *emu, uintptr_t fcn) { pFpuii_t fn = (pFpuii_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void pFpuip(x64emu_t *emu, uintptr_t fcn) { pFpuip_t fn = (pFpuip_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void pFpuWp(x64emu_t *emu, uintptr_t fcn) { pFpuWp_t fn = (pFpuWp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint16_t)R_RDX, (void*)R_RCX); }
-void pFpuuC(x64emu_t *emu, uintptr_t fcn) { pFpuuC_t fn = (pFpuuC_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint8_t)R_RCX); }
-void pFpuuu(x64emu_t *emu, uintptr_t fcn) { pFpuuu_t fn = (pFpuuu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void pFpuup(x64emu_t *emu, uintptr_t fcn) { pFpuup_t fn = (pFpuup_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX); }
-void pFpupi(x64emu_t *emu, uintptr_t fcn) { pFpupi_t fn = (pFpupi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void pFpupu(x64emu_t *emu, uintptr_t fcn) { pFpupu_t fn = (pFpupu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX); }
-void pFpdIU(x64emu_t *emu, uintptr_t fcn) { pFpdIU_t fn = (pFpdIU_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, emu->xmm[0].d[0], (int64_t)R_RSI, (uint64_t)R_RDX); }
-void pFplpl(x64emu_t *emu, uintptr_t fcn) { pFplpl_t fn = (pFplpl_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (intptr_t)R_RSI, (void*)R_RDX, (intptr_t)R_RCX); }
-void pFplpp(x64emu_t *emu, uintptr_t fcn) { pFplpp_t fn = (pFplpp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (intptr_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void pFpLip(x64emu_t *emu, uintptr_t fcn) { pFpLip_t fn = (pFpLip_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void pFpLLp(x64emu_t *emu, uintptr_t fcn) { pFpLLp_t fn = (pFpLLp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX); }
-void pFpLpL(x64emu_t *emu, uintptr_t fcn) { pFpLpL_t fn = (pFpLpL_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX, (uintptr_t)R_RCX); }
-void pFppii(x64emu_t *emu, uintptr_t fcn) { pFppii_t fn = (pFppii_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void pFppiu(x64emu_t *emu, uintptr_t fcn) { pFppiu_t fn = (pFppiu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX); }
-void pFppiL(x64emu_t *emu, uintptr_t fcn) { pFppiL_t fn = (pFppiL_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (uintptr_t)R_RCX); }
-void pFppip(x64emu_t *emu, uintptr_t fcn) { pFppip_t fn = (pFppip_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void pFppWW(x64emu_t *emu, uintptr_t fcn) { pFppWW_t fn = (pFppWW_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (uint16_t)R_RDX, (uint16_t)R_RCX); }
-void pFppuW(x64emu_t *emu, uintptr_t fcn) { pFppuW_t fn = (pFppuW_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint16_t)R_RCX); }
-void pFppuu(x64emu_t *emu, uintptr_t fcn) { pFppuu_t fn = (pFppuu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void pFppuL(x64emu_t *emu, uintptr_t fcn) { pFppuL_t fn = (pFppuL_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uintptr_t)R_RCX); }
-void pFppup(x64emu_t *emu, uintptr_t fcn) { pFppup_t fn = (pFppup_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (void*)R_RCX); }
-void pFppUU(x64emu_t *emu, uintptr_t fcn) { pFppUU_t fn = (pFppUU_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void pFppdd(x64emu_t *emu, uintptr_t fcn) { pFppdd_t fn = (pFppdd_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, emu->xmm[0].d[0], emu->xmm[1].d[0]); }
-void pFppll(x64emu_t *emu, uintptr_t fcn) { pFppll_t fn = (pFppll_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (intptr_t)R_RDX, (intptr_t)R_RCX); }
-void pFppLL(x64emu_t *emu, uintptr_t fcn) { pFppLL_t fn = (pFppLL_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (uintptr_t)R_RCX); }
-void pFppLp(x64emu_t *emu, uintptr_t fcn) { pFppLp_t fn = (pFppLp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX); }
-void pFpppi(x64emu_t *emu, uintptr_t fcn) { pFpppi_t fn = (pFpppi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void pFpppu(x64emu_t *emu, uintptr_t fcn) { pFpppu_t fn = (pFpppu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX); }
-void pFpppU(x64emu_t *emu, uintptr_t fcn) { pFpppU_t fn = (pFpppU_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX); }
-void pFpppL(x64emu_t *emu, uintptr_t fcn) { pFpppL_t fn = (pFpppL_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uintptr_t)R_RCX); }
-void pFpppp(x64emu_t *emu, uintptr_t fcn) { pFpppp_t fn = (pFpppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void pFSppi(x64emu_t *emu, uintptr_t fcn) { pFSppi_t fn = (pFSppi_t)fcn; R_RAX=(uintptr_t)fn(io_convert((void*)R_RDI), (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void vWpiiu(x64emu_t *emu, uintptr_t fcn) { vWpiiu_t fn = (vWpiiu_t)fcn; fn((void*)R_RCX, (int64_t)R_RDX, (int64_t)R_R8, (uint64_t)R_R9); }
-void vWpuup(x64emu_t *emu, uintptr_t fcn) { vWpuup_t fn = (vWpuup_t)fcn; fn((void*)R_RCX, (uint64_t)R_RDX, (uint64_t)R_R8, (void*)R_R9); }
-void iWEpip(x64emu_t *emu, uintptr_t fcn) { iWEpip_t fn = (iWEpip_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RCX, (int64_t)R_RDX, (void*)R_R8); }
-void iWEpup(x64emu_t *emu, uintptr_t fcn) { iWEpup_t fn = (iWEpup_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RCX, (uint64_t)R_RDX, (void*)R_R8); }
-void iWEppu(x64emu_t *emu, uintptr_t fcn) { iWEppu_t fn = (iWEppu_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RCX, (void*)R_RDX, (uint64_t)R_R8); }
-void iWEppp(x64emu_t *emu, uintptr_t fcn) { iWEppp_t fn = (iWEppp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RCX, (void*)R_RDX, (void*)R_R8); }
-void iWpiii(x64emu_t *emu, uintptr_t fcn) { iWpiii_t fn = (iWpiii_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (int64_t)R_RDX, (int64_t)R_R8, (int64_t)R_R9); }
-void iWpiuu(x64emu_t *emu, uintptr_t fcn) { iWpiuu_t fn = (iWpiuu_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (int64_t)R_RDX, (uint64_t)R_R8, (uint64_t)R_R9); }
-void iWpuiu(x64emu_t *emu, uintptr_t fcn) { iWpuiu_t fn = (iWpuiu_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (uint64_t)R_RDX, (int64_t)R_R8, (uint64_t)R_R9); }
-void iWpuip(x64emu_t *emu, uintptr_t fcn) { iWpuip_t fn = (iWpuip_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (uint64_t)R_RDX, (int64_t)R_R8, (void*)R_R9); }
-void iWpuup(x64emu_t *emu, uintptr_t fcn) { iWpuup_t fn = (iWpuup_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (uint64_t)R_RDX, (uint64_t)R_R8, (void*)R_R9); }
-void iWpupu(x64emu_t *emu, uintptr_t fcn) { iWpupu_t fn = (iWpupu_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (uint64_t)R_RDX, (void*)R_R8, (uint64_t)R_R9); }
-void iWpupp(x64emu_t *emu, uintptr_t fcn) { iWpupp_t fn = (iWpupp_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (uint64_t)R_RDX, (void*)R_R8, (void*)R_R9); }
-void iWppuu(x64emu_t *emu, uintptr_t fcn) { iWppuu_t fn = (iWppuu_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (void*)R_RDX, (uint64_t)R_R8, (uint64_t)R_R9); }
-void iWpppu(x64emu_t *emu, uintptr_t fcn) { iWpppu_t fn = (iWpppu_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (void*)R_RDX, (void*)R_R8, (uint64_t)R_R9); }
-void iWpppp(x64emu_t *emu, uintptr_t fcn) { iWpppp_t fn = (iWpppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (void*)R_RDX, (void*)R_R8, (void*)R_R9); }
-void vFEiipV(x64emu_t *emu, uintptr_t fcn) { vFEiipV_t fn = (vFEiipV_t)fcn; fn(emu, (int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)(R_RSP + 8)); }
-void vFEiipA(x64emu_t *emu, uintptr_t fcn) { vFEiipA_t fn = (vFEiipA_t)fcn; fn(emu, (int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void vFEippp(x64emu_t *emu, uintptr_t fcn) { vFEippp_t fn = (vFEippp_t)fcn; fn(emu, (int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void vFEpipV(x64emu_t *emu, uintptr_t fcn) { vFEpipV_t fn = (vFEpipV_t)fcn; fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)(R_RSP + 8)); }
-void vFEpipA(x64emu_t *emu, uintptr_t fcn) { vFEpipA_t fn = (vFEpipA_t)fcn; fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void vFEpuup(x64emu_t *emu, uintptr_t fcn) { vFEpuup_t fn = (vFEpuup_t)fcn; fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX); }
-void vFEpuuV(x64emu_t *emu, uintptr_t fcn) { vFEpuuV_t fn = (vFEpuuV_t)fcn; fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)(R_RSP + 8)); }
-void vFEpupp(x64emu_t *emu, uintptr_t fcn) { vFEpupp_t fn = (vFEpupp_t)fcn; fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void vFEpupA(x64emu_t *emu, uintptr_t fcn) { vFEpupA_t fn = (vFEpupA_t)fcn; fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void vFEpLLp(x64emu_t *emu, uintptr_t fcn) { vFEpLLp_t fn = (vFEpLLp_t)fcn; fn(emu, (void*)R_RDI, (uintptr_t)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX); }
-void vFEppip(x64emu_t *emu, uintptr_t fcn) { vFEppip_t fn = (vFEppip_t)fcn; fn(emu, (void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void vFEppiV(x64emu_t *emu, uintptr_t fcn) { vFEppiV_t fn = (vFEppiV_t)fcn; fn(emu, (void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)(R_RSP + 8)); }
-void vFEppup(x64emu_t *emu, uintptr_t fcn) { vFEppup_t fn = (vFEppup_t)fcn; fn(emu, (void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (void*)R_RCX); }
-void vFEpppi(x64emu_t *emu, uintptr_t fcn) { vFEpppi_t fn = (vFEpppi_t)fcn; fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void vFEpppp(x64emu_t *emu, uintptr_t fcn) { vFEpppp_t fn = (vFEpppp_t)fcn; fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void vFiiiii(x64emu_t *emu, uintptr_t fcn) { vFiiiii_t fn = (vFiiiii_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void vFiiiiu(x64emu_t *emu, uintptr_t fcn) { vFiiiiu_t fn = (vFiiiiu_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8); }
-void vFiiipi(x64emu_t *emu, uintptr_t fcn) { vFiiipi_t fn = (vFiiipi_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void vFiiuii(x64emu_t *emu, uintptr_t fcn) { vFiiuii_t fn = (vFiiuii_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void vFiiuup(x64emu_t *emu, uintptr_t fcn) { vFiiuup_t fn = (vFiiuup_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8); }
-void vFiillu(x64emu_t *emu, uintptr_t fcn) { vFiillu_t fn = (vFiillu_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (intptr_t)R_RDX, (intptr_t)R_RCX, (uint64_t)R_R8); }
-void vFiilll(x64emu_t *emu, uintptr_t fcn) { vFiilll_t fn = (vFiilll_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (intptr_t)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8); }
-void vFiipii(x64emu_t *emu, uintptr_t fcn) { vFiipii_t fn = (vFiipii_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void vFiipll(x64emu_t *emu, uintptr_t fcn) { vFiipll_t fn = (vFiipll_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8); }
-void vFiIIII(x64emu_t *emu, uintptr_t fcn) { vFiIIII_t fn = (vFiIIII_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void vFiuiip(x64emu_t *emu, uintptr_t fcn) { vFiuiip_t fn = (vFiuiip_t)fcn; fn((int64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void vFiuipi(x64emu_t *emu, uintptr_t fcn) { vFiuipi_t fn = (vFiuipi_t)fcn; fn((int64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void vFiuuuu(x64emu_t *emu, uintptr_t fcn) { vFiuuuu_t fn = (vFiuuuu_t)fcn; fn((int64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8); }
-void vFiulpp(x64emu_t *emu, uintptr_t fcn) { vFiulpp_t fn = (vFiulpp_t)fcn; fn((int64_t)R_RDI, (uint64_t)R_RSI, (intptr_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void vFiuppu(x64emu_t *emu, uintptr_t fcn) { vFiuppu_t fn = (vFiuppu_t)fcn; fn((int64_t)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (uint64_t)R_R8); }
-void vFiUUUU(x64emu_t *emu, uintptr_t fcn) { vFiUUUU_t fn = (vFiUUUU_t)fcn; fn((int64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8); }
-void vFiffff(x64emu_t *emu, uintptr_t fcn) { vFiffff_t fn = (vFiffff_t)fcn; fn((int64_t)R_RDI, emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0], emu->xmm[3].f[0]); }
-void vFidddd(x64emu_t *emu, uintptr_t fcn) { vFidddd_t fn = (vFidddd_t)fcn; fn((int64_t)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0]); }
-void vFilill(x64emu_t *emu, uintptr_t fcn) { vFilill_t fn = (vFilill_t)fcn; fn((int64_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8); }
-void vFilipi(x64emu_t *emu, uintptr_t fcn) { vFilipi_t fn = (vFilipi_t)fcn; fn((int64_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void vFilipl(x64emu_t *emu, uintptr_t fcn) { vFilipl_t fn = (vFilipl_t)fcn; fn((int64_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (intptr_t)R_R8); }
-void vFillpu(x64emu_t *emu, uintptr_t fcn) { vFillpu_t fn = (vFillpu_t)fcn; fn((int64_t)R_RDI, (intptr_t)R_RSI, (intptr_t)R_RDX, (void*)R_RCX, (uint64_t)R_R8); }
-void vFipipu(x64emu_t *emu, uintptr_t fcn) { vFipipu_t fn = (vFipipu_t)fcn; fn((int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (uint64_t)R_R8); }
-void vFipipp(x64emu_t *emu, uintptr_t fcn) { vFipipp_t fn = (vFipipp_t)fcn; fn((int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void vFipupi(x64emu_t *emu, uintptr_t fcn) { vFipupi_t fn = (vFipupi_t)fcn; fn((int64_t)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void vFiplli(x64emu_t *emu, uintptr_t fcn) { vFiplli_t fn = (vFiplli_t)fcn; fn((int64_t)R_RDI, (void*)R_RSI, (intptr_t)R_RDX, (intptr_t)R_RCX, (int64_t)R_R8); }
-void vFiplll(x64emu_t *emu, uintptr_t fcn) { vFiplll_t fn = (vFiplll_t)fcn; fn((int64_t)R_RDI, (void*)R_RSI, (intptr_t)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8); }
-void vFuiiii(x64emu_t *emu, uintptr_t fcn) { vFuiiii_t fn = (vFuiiii_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void vFuiiiu(x64emu_t *emu, uintptr_t fcn) { vFuiiiu_t fn = (vFuiiiu_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8); }
-void vFuiiip(x64emu_t *emu, uintptr_t fcn) { vFuiiip_t fn = (vFuiiip_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void vFuiifi(x64emu_t *emu, uintptr_t fcn) { vFuiifi_t fn = (vFuiifi_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, emu->xmm[0].f[0], (int64_t)R_RCX); }
-void vFuiill(x64emu_t *emu, uintptr_t fcn) { vFuiill_t fn = (vFuiill_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8); }
-void vFuiilp(x64emu_t *emu, uintptr_t fcn) { vFuiilp_t fn = (vFuiilp_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX, (void*)R_R8); }
-void vFuiIII(x64emu_t *emu, uintptr_t fcn) { vFuiIII_t fn = (vFuiIII_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void vFuiuii(x64emu_t *emu, uintptr_t fcn) { vFuiuii_t fn = (vFuiuii_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void vFuiuiu(x64emu_t *emu, uintptr_t fcn) { vFuiuiu_t fn = (vFuiuiu_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8); }
-void vFuiuip(x64emu_t *emu, uintptr_t fcn) { vFuiuip_t fn = (vFuiuip_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void vFuiuuu(x64emu_t *emu, uintptr_t fcn) { vFuiuuu_t fn = (vFuiuuu_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8); }
-void vFuiuup(x64emu_t *emu, uintptr_t fcn) { vFuiuup_t fn = (vFuiuup_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8); }
-void vFuiull(x64emu_t *emu, uintptr_t fcn) { vFuiull_t fn = (vFuiull_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8); }
-void vFuiupi(x64emu_t *emu, uintptr_t fcn) { vFuiupi_t fn = (vFuiupi_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void vFuiUUU(x64emu_t *emu, uintptr_t fcn) { vFuiUUU_t fn = (vFuiUUU_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8); }
-void vFuifff(x64emu_t *emu, uintptr_t fcn) { vFuifff_t fn = (vFuifff_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0]); }
-void vFuiddd(x64emu_t *emu, uintptr_t fcn) { vFuiddd_t fn = (vFuiddd_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0]); }
-void vFuipii(x64emu_t *emu, uintptr_t fcn) { vFuipii_t fn = (vFuipii_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void vFuipip(x64emu_t *emu, uintptr_t fcn) { vFuipip_t fn = (vFuipip_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void vFuipup(x64emu_t *emu, uintptr_t fcn) { vFuipup_t fn = (vFuipup_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (void*)R_R8); }
-void vFuippp(x64emu_t *emu, uintptr_t fcn) { vFuippp_t fn = (vFuippp_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void vFuuiii(x64emu_t *emu, uintptr_t fcn) { vFuuiii_t fn = (vFuuiii_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void vFuuiiu(x64emu_t *emu, uintptr_t fcn) { vFuuiiu_t fn = (vFuuiiu_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8); }
-void vFuuiui(x64emu_t *emu, uintptr_t fcn) { vFuuiui_t fn = (vFuuiui_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8); }
-void vFuuiuu(x64emu_t *emu, uintptr_t fcn) { vFuuiuu_t fn = (vFuuiuu_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8); }
-void vFuuiup(x64emu_t *emu, uintptr_t fcn) { vFuuiup_t fn = (vFuuiup_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8); }
-void vFuuipi(x64emu_t *emu, uintptr_t fcn) { vFuuipi_t fn = (vFuuipi_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void vFuuipu(x64emu_t *emu, uintptr_t fcn) { vFuuipu_t fn = (vFuuipu_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (uint64_t)R_R8); }
-void vFuuipp(x64emu_t *emu, uintptr_t fcn) { vFuuipp_t fn = (vFuuipp_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void vFuuuii(x64emu_t *emu, uintptr_t fcn) { vFuuuii_t fn = (vFuuuii_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void vFuuuiu(x64emu_t *emu, uintptr_t fcn) { vFuuuiu_t fn = (vFuuuiu_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8); }
-void vFuuuip(x64emu_t *emu, uintptr_t fcn) { vFuuuip_t fn = (vFuuuip_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void vFuuuui(x64emu_t *emu, uintptr_t fcn) { vFuuuui_t fn = (vFuuuui_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8); }
-void vFuuuuu(x64emu_t *emu, uintptr_t fcn) { vFuuuuu_t fn = (vFuuuuu_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8); }
-void vFuuuup(x64emu_t *emu, uintptr_t fcn) { vFuuuup_t fn = (vFuuuup_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8); }
-void vFuuull(x64emu_t *emu, uintptr_t fcn) { vFuuull_t fn = (vFuuull_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8); }
-void vFuuulp(x64emu_t *emu, uintptr_t fcn) { vFuuulp_t fn = (vFuuulp_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (intptr_t)R_RCX, (void*)R_R8); }
-void vFuulll(x64emu_t *emu, uintptr_t fcn) { vFuulll_t fn = (vFuulll_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (intptr_t)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8); }
-void vFuullp(x64emu_t *emu, uintptr_t fcn) { vFuullp_t fn = (vFuullp_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (intptr_t)R_RDX, (intptr_t)R_RCX, (void*)R_R8); }
-void vFuulpp(x64emu_t *emu, uintptr_t fcn) { vFuulpp_t fn = (vFuulpp_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (intptr_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void vFuupii(x64emu_t *emu, uintptr_t fcn) { vFuupii_t fn = (vFuupii_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void vFuffff(x64emu_t *emu, uintptr_t fcn) { vFuffff_t fn = (vFuffff_t)fcn; fn((uint64_t)R_RDI, emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0], emu->xmm[3].f[0]); }
-void vFudddd(x64emu_t *emu, uintptr_t fcn) { vFudddd_t fn = (vFudddd_t)fcn; fn((uint64_t)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0]); }
-void vFulill(x64emu_t *emu, uintptr_t fcn) { vFulill_t fn = (vFulill_t)fcn; fn((uint64_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8); }
-void vFullip(x64emu_t *emu, uintptr_t fcn) { vFullip_t fn = (vFullip_t)fcn; fn((uint64_t)R_RDI, (intptr_t)R_RSI, (intptr_t)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void vFullpp(x64emu_t *emu, uintptr_t fcn) { vFullpp_t fn = (vFullpp_t)fcn; fn((uint64_t)R_RDI, (intptr_t)R_RSI, (intptr_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void vFupupi(x64emu_t *emu, uintptr_t fcn) { vFupupi_t fn = (vFupupi_t)fcn; fn((uint64_t)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void vFuppip(x64emu_t *emu, uintptr_t fcn) { vFuppip_t fn = (vFuppip_t)fcn; fn((uint64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void vFupppp(x64emu_t *emu, uintptr_t fcn) { vFupppp_t fn = (vFupppp_t)fcn; fn((uint64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void vFUUppp(x64emu_t *emu, uintptr_t fcn) { vFUUppp_t fn = (vFUUppp_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void vFfffff(x64emu_t *emu, uintptr_t fcn) { vFfffff_t fn = (vFfffff_t)fcn; fn(emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0], emu->xmm[3].f[0], emu->xmm[4].f[0]); }
-void vFddddp(x64emu_t *emu, uintptr_t fcn) { vFddddp_t fn = (vFddddp_t)fcn; fn(emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0], (void*)R_RDI); }
-void vFpiiii(x64emu_t *emu, uintptr_t fcn) { vFpiiii_t fn = (vFpiiii_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void vFpiiiI(x64emu_t *emu, uintptr_t fcn) { vFpiiiI_t fn = (vFpiiiI_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void vFpiiiu(x64emu_t *emu, uintptr_t fcn) { vFpiiiu_t fn = (vFpiiiu_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8); }
-void vFpiiip(x64emu_t *emu, uintptr_t fcn) { vFpiiip_t fn = (vFpiiip_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void vFpiiII(x64emu_t *emu, uintptr_t fcn) { vFpiiII_t fn = (vFpiiII_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void vFpiiff(x64emu_t *emu, uintptr_t fcn) { vFpiiff_t fn = (vFpiiff_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, emu->xmm[0].f[0], emu->xmm[1].f[0]); }
-void vFpiipp(x64emu_t *emu, uintptr_t fcn) { vFpiipp_t fn = (vFpiipp_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void vFpiIiI(x64emu_t *emu, uintptr_t fcn) { vFpiIiI_t fn = (vFpiIiI_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void vFpiIII(x64emu_t *emu, uintptr_t fcn) { vFpiIII_t fn = (vFpiIII_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void vFpiUUp(x64emu_t *emu, uintptr_t fcn) { vFpiUUp_t fn = (vFpiUUp_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8); }
-void vFpilpp(x64emu_t *emu, uintptr_t fcn) { vFpilpp_t fn = (vFpilpp_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (intptr_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void vFpipii(x64emu_t *emu, uintptr_t fcn) { vFpipii_t fn = (vFpipii_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void vFpipiu(x64emu_t *emu, uintptr_t fcn) { vFpipiu_t fn = (vFpipiu_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8); }
-void vFpuiip(x64emu_t *emu, uintptr_t fcn) { vFpuiip_t fn = (vFpuiip_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void vFpuipp(x64emu_t *emu, uintptr_t fcn) { vFpuipp_t fn = (vFpuipp_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void vFpuuuu(x64emu_t *emu, uintptr_t fcn) { vFpuuuu_t fn = (vFpuuuu_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8); }
-void vFpuuup(x64emu_t *emu, uintptr_t fcn) { vFpuuup_t fn = (vFpuuup_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8); }
-void vFpuupp(x64emu_t *emu, uintptr_t fcn) { vFpuupp_t fn = (vFpuupp_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void vFpuUUu(x64emu_t *emu, uintptr_t fcn) { vFpuUUu_t fn = (vFpuUUu_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8); }
-void vFpuddd(x64emu_t *emu, uintptr_t fcn) { vFpuddd_t fn = (vFpuddd_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0]); }
-void vFpupup(x64emu_t *emu, uintptr_t fcn) { vFpupup_t fn = (vFpupup_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (void*)R_R8); }
-void vFpUuiu(x64emu_t *emu, uintptr_t fcn) { vFpUuiu_t fn = (vFpUuiu_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8); }
-void vFpUUuu(x64emu_t *emu, uintptr_t fcn) { vFpUUuu_t fn = (vFpUUuu_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8); }
-void vFpUUup(x64emu_t *emu, uintptr_t fcn) { vFpUUup_t fn = (vFpUUup_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8); }
-void vFpUUUu(x64emu_t *emu, uintptr_t fcn) { vFpUUUu_t fn = (vFpUUUu_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8); }
-void vFpUUUp(x64emu_t *emu, uintptr_t fcn) { vFpUUUp_t fn = (vFpUUUp_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8); }
-void vFpUppp(x64emu_t *emu, uintptr_t fcn) { vFpUppp_t fn = (vFpUppp_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void vFpffff(x64emu_t *emu, uintptr_t fcn) { vFpffff_t fn = (vFpffff_t)fcn; fn((void*)R_RDI, emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0], emu->xmm[3].f[0]); }
-void vFpdiII(x64emu_t *emu, uintptr_t fcn) { vFpdiII_t fn = (vFpdiII_t)fcn; fn((void*)R_RDI, emu->xmm[0].d[0], (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void vFpddii(x64emu_t *emu, uintptr_t fcn) { vFpddii_t fn = (vFpddii_t)fcn; fn((void*)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0], (int64_t)R_RSI, (int64_t)R_RDX); }
-void vFpdddd(x64emu_t *emu, uintptr_t fcn) { vFpdddd_t fn = (vFpdddd_t)fcn; fn((void*)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0]); }
-void vFpddpp(x64emu_t *emu, uintptr_t fcn) { vFpddpp_t fn = (vFpddpp_t)fcn; fn((void*)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0], (void*)R_RSI, (void*)R_RDX); }
-void vFpliil(x64emu_t *emu, uintptr_t fcn) { vFpliil_t fn = (vFpliil_t)fcn; fn((void*)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (intptr_t)R_R8); }
-void vFplppp(x64emu_t *emu, uintptr_t fcn) { vFplppp_t fn = (vFplppp_t)fcn; fn((void*)R_RDI, (intptr_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void vFpLLpp(x64emu_t *emu, uintptr_t fcn) { vFpLLpp_t fn = (vFpLLpp_t)fcn; fn((void*)R_RDI, (uintptr_t)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void vFppiii(x64emu_t *emu, uintptr_t fcn) { vFppiii_t fn = (vFppiii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void vFppiiu(x64emu_t *emu, uintptr_t fcn) { vFppiiu_t fn = (vFppiiu_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8); }
-void vFppiip(x64emu_t *emu, uintptr_t fcn) { vFppiip_t fn = (vFppiip_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void vFppiup(x64emu_t *emu, uintptr_t fcn) { vFppiup_t fn = (vFppiup_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8); }
-void vFppiff(x64emu_t *emu, uintptr_t fcn) { vFppiff_t fn = (vFppiff_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, emu->xmm[0].f[0], emu->xmm[1].f[0]); }
-void vFppipi(x64emu_t *emu, uintptr_t fcn) { vFppipi_t fn = (vFppipi_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void vFppipp(x64emu_t *emu, uintptr_t fcn) { vFppipp_t fn = (vFppipp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void vFppWui(x64emu_t *emu, uintptr_t fcn) { vFppWui_t fn = (vFppWui_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (uint16_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8); }
-void vFppuui(x64emu_t *emu, uintptr_t fcn) { vFppuui_t fn = (vFppuui_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8); }
-void vFppuuu(x64emu_t *emu, uintptr_t fcn) { vFppuuu_t fn = (vFppuuu_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8); }
-void vFppuup(x64emu_t *emu, uintptr_t fcn) { vFppuup_t fn = (vFppuup_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8); }
-void vFppupi(x64emu_t *emu, uintptr_t fcn) { vFppupi_t fn = (vFppupi_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void vFppupp(x64emu_t *emu, uintptr_t fcn) { vFppupp_t fn = (vFppupp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void vFppddp(x64emu_t *emu, uintptr_t fcn) { vFppddp_t fn = (vFppddp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, emu->xmm[0].d[0], emu->xmm[1].d[0], (void*)R_RDX); }
-void vFpppii(x64emu_t *emu, uintptr_t fcn) { vFpppii_t fn = (vFpppii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void vFpppip(x64emu_t *emu, uintptr_t fcn) { vFpppip_t fn = (vFpppip_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void vFpppuu(x64emu_t *emu, uintptr_t fcn) { vFpppuu_t fn = (vFpppuu_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8); }
-void vFpppup(x64emu_t *emu, uintptr_t fcn) { vFpppup_t fn = (vFpppup_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (void*)R_R8); }
-void vFpppdd(x64emu_t *emu, uintptr_t fcn) { vFpppdd_t fn = (vFpppdd_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, emu->xmm[0].d[0], emu->xmm[1].d[0]); }
-void vFppppi(x64emu_t *emu, uintptr_t fcn) { vFppppi_t fn = (vFppppi_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void vFppppu(x64emu_t *emu, uintptr_t fcn) { vFppppu_t fn = (vFppppu_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (uint64_t)R_R8); }
-void vFppppL(x64emu_t *emu, uintptr_t fcn) { vFppppL_t fn = (vFppppL_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (uintptr_t)R_R8); }
-void vFppppp(x64emu_t *emu, uintptr_t fcn) { vFppppp_t fn = (vFppppp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void iFEiipp(x64emu_t *emu, uintptr_t fcn) { iFEiipp_t fn = (iFEiipp_t)fcn; R_RAX=(int64_t)fn(emu, (int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void iFEiipV(x64emu_t *emu, uintptr_t fcn) { iFEiipV_t fn = (iFEiipV_t)fcn; R_RAX=(int64_t)fn(emu, (int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)(R_RSP + 8)); }
-void iFEippi(x64emu_t *emu, uintptr_t fcn) { iFEippi_t fn = (iFEippi_t)fcn; R_RAX=(int64_t)fn(emu, (int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void iFEippL(x64emu_t *emu, uintptr_t fcn) { iFEippL_t fn = (iFEippL_t)fcn; R_RAX=(int64_t)fn(emu, (int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (uintptr_t)R_RCX); }
-void iFEippp(x64emu_t *emu, uintptr_t fcn) { iFEippp_t fn = (iFEippp_t)fcn; R_RAX=(int64_t)fn(emu, (int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void iFEpiii(x64emu_t *emu, uintptr_t fcn) { iFEpiii_t fn = (iFEpiii_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void iFEpipi(x64emu_t *emu, uintptr_t fcn) { iFEpipi_t fn = (iFEpipi_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void iFEpipp(x64emu_t *emu, uintptr_t fcn) { iFEpipp_t fn = (iFEpipp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void iFEpipV(x64emu_t *emu, uintptr_t fcn) { iFEpipV_t fn = (iFEpipV_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)(R_RSP + 8)); }
-void iFEpipA(x64emu_t *emu, uintptr_t fcn) { iFEpipA_t fn = (iFEpipA_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void iFEpUup(x64emu_t *emu, uintptr_t fcn) { iFEpUup_t fn = (iFEpUup_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX); }
-void iFEpLpp(x64emu_t *emu, uintptr_t fcn) { iFEpLpp_t fn = (iFEpLpp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void iFEpLpV(x64emu_t *emu, uintptr_t fcn) { iFEpLpV_t fn = (iFEpLpV_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX, (void*)(R_RSP + 8)); }
-void iFEpLpA(x64emu_t *emu, uintptr_t fcn) { iFEpLpA_t fn = (iFEpLpA_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void iFEppii(x64emu_t *emu, uintptr_t fcn) { iFEppii_t fn = (iFEppii_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void iFEppip(x64emu_t *emu, uintptr_t fcn) { iFEppip_t fn = (iFEppip_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void iFEppiV(x64emu_t *emu, uintptr_t fcn) { iFEppiV_t fn = (iFEppiV_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)(R_RSP + 8)); }
-void iFEppiA(x64emu_t *emu, uintptr_t fcn) { iFEppiA_t fn = (iFEppiA_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void iFEpplp(x64emu_t *emu, uintptr_t fcn) { iFEpplp_t fn = (iFEpplp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (intptr_t)R_RDX, (void*)R_RCX); }
-void iFEpppi(x64emu_t *emu, uintptr_t fcn) { iFEpppi_t fn = (iFEpppi_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void iFEpppL(x64emu_t *emu, uintptr_t fcn) { iFEpppL_t fn = (iFEpppL_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uintptr_t)R_RCX); }
-void iFEpppp(x64emu_t *emu, uintptr_t fcn) { iFEpppp_t fn = (iFEpppp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void iFEpppV(x64emu_t *emu, uintptr_t fcn) { iFEpppV_t fn = (iFEpppV_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)(R_RSP + 8)); }
-void iFiiipu(x64emu_t *emu, uintptr_t fcn) { iFiiipu_t fn = (iFiiipu_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (uint64_t)R_R8); }
-void iFiiipp(x64emu_t *emu, uintptr_t fcn) { iFiiipp_t fn = (iFiiipp_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void iFiiupp(x64emu_t *emu, uintptr_t fcn) { iFiiupp_t fn = (iFiiupp_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void iFiipup(x64emu_t *emu, uintptr_t fcn) { iFiipup_t fn = (iFiipup_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (void*)R_R8); }
-void iFiuLip(x64emu_t *emu, uintptr_t fcn) { iFiuLip_t fn = (iFiuLip_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (uint64_t)R_RSI, (uintptr_t)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void iFipiii(x64emu_t *emu, uintptr_t fcn) { iFipiii_t fn = (iFipiii_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void iFipiup(x64emu_t *emu, uintptr_t fcn) { iFipiup_t fn = (iFipiup_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8); }
-void iFipipi(x64emu_t *emu, uintptr_t fcn) { iFipipi_t fn = (iFipipi_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void iFipipu(x64emu_t *emu, uintptr_t fcn) { iFipipu_t fn = (iFipipu_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (uint64_t)R_R8); }
-void iFipuip(x64emu_t *emu, uintptr_t fcn) { iFipuip_t fn = (iFipuip_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void iFipuui(x64emu_t *emu, uintptr_t fcn) { iFipuui_t fn = (iFipuui_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8); }
-void iFipLup(x64emu_t *emu, uintptr_t fcn) { iFipLup_t fn = (iFipLup_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8); }
-void iFippip(x64emu_t *emu, uintptr_t fcn) { iFippip_t fn = (iFippip_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void iFippLi(x64emu_t *emu, uintptr_t fcn) { iFippLi_t fn = (iFippLi_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (uintptr_t)R_RCX, (int64_t)R_R8); }
-void iFippLp(x64emu_t *emu, uintptr_t fcn) { iFippLp_t fn = (iFippLp_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (uintptr_t)R_RCX, (void*)R_R8); }
-void iFipppi(x64emu_t *emu, uintptr_t fcn) { iFipppi_t fn = (iFipppi_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void iFipppp(x64emu_t *emu, uintptr_t fcn) { iFipppp_t fn = (iFipppp_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void iFuppLp(x64emu_t *emu, uintptr_t fcn) { iFuppLp_t fn = (iFuppLp_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (uintptr_t)R_RCX, (void*)R_R8); }
-void iFpwwww(x64emu_t *emu, uintptr_t fcn) { iFpwwww_t fn = (iFpwwww_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int16_t)R_RSI, (int16_t)R_RDX, (int16_t)R_RCX, (int16_t)R_R8); }
-void iFpwppp(x64emu_t *emu, uintptr_t fcn) { iFpwppp_t fn = (iFpwppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int16_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void iFpiiii(x64emu_t *emu, uintptr_t fcn) { iFpiiii_t fn = (iFpiiii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void iFpiiiu(x64emu_t *emu, uintptr_t fcn) { iFpiiiu_t fn = (iFpiiiu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8); }
-void iFpiiiL(x64emu_t *emu, uintptr_t fcn) { iFpiiiL_t fn = (iFpiiiL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uintptr_t)R_R8); }
-void iFpiiip(x64emu_t *emu, uintptr_t fcn) { iFpiiip_t fn = (iFpiiip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void iFpiiui(x64emu_t *emu, uintptr_t fcn) { iFpiiui_t fn = (iFpiiui_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8); }
-void iFpiiuu(x64emu_t *emu, uintptr_t fcn) { iFpiiuu_t fn = (iFpiiuu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8); }
-void iFpiipi(x64emu_t *emu, uintptr_t fcn) { iFpiipi_t fn = (iFpiipi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void iFpiipp(x64emu_t *emu, uintptr_t fcn) { iFpiipp_t fn = (iFpiipp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void iFpiIip(x64emu_t *emu, uintptr_t fcn) { iFpiIip_t fn = (iFpiIip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void iFpiuwp(x64emu_t *emu, uintptr_t fcn) { iFpiuwp_t fn = (iFpiuwp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (int16_t)R_RCX, (void*)R_R8); }
-void iFpiUUU(x64emu_t *emu, uintptr_t fcn) { iFpiUUU_t fn = (iFpiUUU_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8); }
-void iFpipii(x64emu_t *emu, uintptr_t fcn) { iFpipii_t fn = (iFpipii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void iFpipiu(x64emu_t *emu, uintptr_t fcn) { iFpipiu_t fn = (iFpipiu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8); }
-void iFpipiL(x64emu_t *emu, uintptr_t fcn) { iFpipiL_t fn = (iFpipiL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (uintptr_t)R_R8); }
-void iFpipip(x64emu_t *emu, uintptr_t fcn) { iFpipip_t fn = (iFpipip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void iFpippi(x64emu_t *emu, uintptr_t fcn) { iFpippi_t fn = (iFpippi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void iFpippW(x64emu_t *emu, uintptr_t fcn) { iFpippW_t fn = (iFpippW_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (uint16_t)R_R8); }
-void iFpippp(x64emu_t *emu, uintptr_t fcn) { iFpippp_t fn = (iFpippp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void iFpCCCC(x64emu_t *emu, uintptr_t fcn) { iFpCCCC_t fn = (iFpCCCC_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint8_t)R_RSI, (uint8_t)R_RDX, (uint8_t)R_RCX, (uint8_t)R_R8); }
-void iFpuill(x64emu_t *emu, uintptr_t fcn) { iFpuill_t fn = (iFpuill_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8); }
-void iFpuipi(x64emu_t *emu, uintptr_t fcn) { iFpuipi_t fn = (iFpuipi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void iFpuuip(x64emu_t *emu, uintptr_t fcn) { iFpuuip_t fn = (iFpuuip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void iFpuuui(x64emu_t *emu, uintptr_t fcn) { iFpuuui_t fn = (iFpuuui_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8); }
-void iFpuuup(x64emu_t *emu, uintptr_t fcn) { iFpuuup_t fn = (iFpuuup_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8); }
-void iFpuuLL(x64emu_t *emu, uintptr_t fcn) { iFpuuLL_t fn = (iFpuuLL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uintptr_t)R_RCX, (uintptr_t)R_R8); }
-void iFpuupp(x64emu_t *emu, uintptr_t fcn) { iFpuupp_t fn = (iFpuupp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void iFpupiU(x64emu_t *emu, uintptr_t fcn) { iFpupiU_t fn = (iFpupiU_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8); }
-void iFpupup(x64emu_t *emu, uintptr_t fcn) { iFpupup_t fn = (iFpupup_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (void*)R_R8); }
-void iFpuppp(x64emu_t *emu, uintptr_t fcn) { iFpuppp_t fn = (iFpuppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void iFpUiUi(x64emu_t *emu, uintptr_t fcn) { iFpUiUi_t fn = (iFpUiUi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8); }
-void iFpUupp(x64emu_t *emu, uintptr_t fcn) { iFpUupp_t fn = (iFpUupp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void iFplluu(x64emu_t *emu, uintptr_t fcn) { iFplluu_t fn = (iFplluu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (intptr_t)R_RSI, (intptr_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8); }
-void iFpLiLi(x64emu_t *emu, uintptr_t fcn) { iFpLiLi_t fn = (iFpLiLi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (int64_t)R_RDX, (uintptr_t)R_RCX, (int64_t)R_R8); }
-void iFpLlpp(x64emu_t *emu, uintptr_t fcn) { iFpLlpp_t fn = (iFpLlpp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (intptr_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void iFpLLpp(x64emu_t *emu, uintptr_t fcn) { iFpLLpp_t fn = (iFpLLpp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void iFpLppi(x64emu_t *emu, uintptr_t fcn) { iFpLppi_t fn = (iFpLppi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void iFppiiu(x64emu_t *emu, uintptr_t fcn) { iFppiiu_t fn = (iFppiiu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8); }
-void iFppiip(x64emu_t *emu, uintptr_t fcn) { iFppiip_t fn = (iFppiip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void iFppiup(x64emu_t *emu, uintptr_t fcn) { iFppiup_t fn = (iFppiup_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8); }
-void iFppiLi(x64emu_t *emu, uintptr_t fcn) { iFppiLi_t fn = (iFppiLi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (uintptr_t)R_RCX, (int64_t)R_R8); }
-void iFppiLL(x64emu_t *emu, uintptr_t fcn) { iFppiLL_t fn = (iFppiLL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (uintptr_t)R_RCX, (uintptr_t)R_R8); }
-void iFppipi(x64emu_t *emu, uintptr_t fcn) { iFppipi_t fn = (iFppipi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void iFppipp(x64emu_t *emu, uintptr_t fcn) { iFppipp_t fn = (iFppipp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void iFppuwp(x64emu_t *emu, uintptr_t fcn) { iFppuwp_t fn = (iFppuwp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (int16_t)R_RCX, (void*)R_R8); }
-void iFppuip(x64emu_t *emu, uintptr_t fcn) { iFppuip_t fn = (iFppuip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void iFppuup(x64emu_t *emu, uintptr_t fcn) { iFppuup_t fn = (iFppuup_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8); }
-void iFppupi(x64emu_t *emu, uintptr_t fcn) { iFppupi_t fn = (iFppupi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void iFppupp(x64emu_t *emu, uintptr_t fcn) { iFppupp_t fn = (iFppupp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void iFppllp(x64emu_t *emu, uintptr_t fcn) { iFppllp_t fn = (iFppllp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (intptr_t)R_RDX, (intptr_t)R_RCX, (void*)R_R8); }
-void iFpplpp(x64emu_t *emu, uintptr_t fcn) { iFpplpp_t fn = (iFpplpp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (intptr_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void iFppLip(x64emu_t *emu, uintptr_t fcn) { iFppLip_t fn = (iFppLip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void iFppLpi(x64emu_t *emu, uintptr_t fcn) { iFppLpi_t fn = (iFppLpi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void iFppLpL(x64emu_t *emu, uintptr_t fcn) { iFppLpL_t fn = (iFppLpL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX, (uintptr_t)R_R8); }
-void iFppLpp(x64emu_t *emu, uintptr_t fcn) { iFppLpp_t fn = (iFppLpp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void iFpppii(x64emu_t *emu, uintptr_t fcn) { iFpppii_t fn = (iFpppii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void iFpppiL(x64emu_t *emu, uintptr_t fcn) { iFpppiL_t fn = (iFpppiL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (uintptr_t)R_R8); }
-void iFpppip(x64emu_t *emu, uintptr_t fcn) { iFpppip_t fn = (iFpppip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void iFpppui(x64emu_t *emu, uintptr_t fcn) { iFpppui_t fn = (iFpppui_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8); }
-void iFpppUi(x64emu_t *emu, uintptr_t fcn) { iFpppUi_t fn = (iFpppUi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8); }
-void iFpppLi(x64emu_t *emu, uintptr_t fcn) { iFpppLi_t fn = (iFpppLi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uintptr_t)R_RCX, (int64_t)R_R8); }
-void iFpppLp(x64emu_t *emu, uintptr_t fcn) { iFpppLp_t fn = (iFpppLp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uintptr_t)R_RCX, (void*)R_R8); }
-void iFppppi(x64emu_t *emu, uintptr_t fcn) { iFppppi_t fn = (iFppppi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void iFppppL(x64emu_t *emu, uintptr_t fcn) { iFppppL_t fn = (iFppppL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (uintptr_t)R_R8); }
-void iFppppp(x64emu_t *emu, uintptr_t fcn) { iFppppp_t fn = (iFppppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void IFppIII(x64emu_t *emu, uintptr_t fcn) { IFppIII_t fn = (IFppIII_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void uFEippp(x64emu_t *emu, uintptr_t fcn) { uFEippp_t fn = (uFEippp_t)fcn; R_RAX=(uint64_t)fn(emu, (int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void uFEpipp(x64emu_t *emu, uintptr_t fcn) { uFEpipp_t fn = (uFEpipp_t)fcn; R_RAX=(uint64_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void uFEppuu(x64emu_t *emu, uintptr_t fcn) { uFEppuu_t fn = (uFEppuu_t)fcn; R_RAX=(uint64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX); }
-void uFEpppp(x64emu_t *emu, uintptr_t fcn) { uFEpppp_t fn = (uFEpppp_t)fcn; R_RAX=(uint64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void uFEpppV(x64emu_t *emu, uintptr_t fcn) { uFEpppV_t fn = (uFEpppV_t)fcn; R_RAX=(uint64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)(R_RSP + 8)); }
-void uFiuuuu(x64emu_t *emu, uintptr_t fcn) { uFiuuuu_t fn = (uFiuuuu_t)fcn; R_RAX=(uint64_t)fn((int64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8); }
-void uFipipp(x64emu_t *emu, uintptr_t fcn) { uFipipp_t fn = (uFipipp_t)fcn; R_RAX=(uint64_t)fn((int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void uFipLpp(x64emu_t *emu, uintptr_t fcn) { uFipLpp_t fn = (uFipLpp_t)fcn; R_RAX=(uint64_t)fn((int64_t)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void uFuiiiu(x64emu_t *emu, uintptr_t fcn) { uFuiiiu_t fn = (uFuiiiu_t)fcn; R_RAX=(uint64_t)fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8); }
-void uFpCCCC(x64emu_t *emu, uintptr_t fcn) { uFpCCCC_t fn = (uFpCCCC_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (uint8_t)R_RSI, (uint8_t)R_RDX, (uint8_t)R_RCX, (uint8_t)R_R8); }
-void uFpWuip(x64emu_t *emu, uintptr_t fcn) { uFpWuip_t fn = (uFpWuip_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (uint16_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void uFpuuuu(x64emu_t *emu, uintptr_t fcn) { uFpuuuu_t fn = (uFpuuuu_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8); }
-void uFpupuu(x64emu_t *emu, uintptr_t fcn) { uFpupuu_t fn = (uFpupuu_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8); }
-void uFppiip(x64emu_t *emu, uintptr_t fcn) { uFppiip_t fn = (uFppiip_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void uFppipp(x64emu_t *emu, uintptr_t fcn) { uFppipp_t fn = (uFppipp_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void uFppuup(x64emu_t *emu, uintptr_t fcn) { uFppuup_t fn = (uFppuup_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8); }
-void uFppupp(x64emu_t *emu, uintptr_t fcn) { uFppupp_t fn = (uFppupp_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void uFpplip(x64emu_t *emu, uintptr_t fcn) { uFpplip_t fn = (uFpplip_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (intptr_t)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void uFppLpp(x64emu_t *emu, uintptr_t fcn) { uFppLpp_t fn = (uFppLpp_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void uFppppu(x64emu_t *emu, uintptr_t fcn) { uFppppu_t fn = (uFppppu_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (uint64_t)R_R8); }
-void uFppppp(x64emu_t *emu, uintptr_t fcn) { uFppppp_t fn = (uFppppp_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void UFuiiii(x64emu_t *emu, uintptr_t fcn) { UFuiiii_t fn = (UFuiiii_t)fcn; R_RAX=fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void lFipili(x64emu_t *emu, uintptr_t fcn) { lFipili_t fn = (lFipili_t)fcn; R_RAX=(intptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX, (int64_t)R_R8); }
-void lFipLli(x64emu_t *emu, uintptr_t fcn) { lFipLli_t fn = (lFipLli_t)fcn; R_RAX=(intptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (intptr_t)R_RCX, (int64_t)R_R8); }
-void lFipLlL(x64emu_t *emu, uintptr_t fcn) { lFipLlL_t fn = (lFipLlL_t)fcn; R_RAX=(intptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (intptr_t)R_RCX, (uintptr_t)R_R8); }
-void lFipLLi(x64emu_t *emu, uintptr_t fcn) { lFipLLi_t fn = (lFipLLi_t)fcn; R_RAX=(intptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (uintptr_t)R_RCX, (int64_t)R_R8); }
-void lFipLpp(x64emu_t *emu, uintptr_t fcn) { lFipLpp_t fn = (lFipLpp_t)fcn; R_RAX=(intptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void LFELppi(x64emu_t *emu, uintptr_t fcn) { LFELppi_t fn = (LFELppi_t)fcn; R_RAX=(uintptr_t)fn(emu, (uintptr_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void LFEpppp(x64emu_t *emu, uintptr_t fcn) { LFEpppp_t fn = (LFEpppp_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void LFpuipp(x64emu_t *emu, uintptr_t fcn) { LFpuipp_t fn = (LFpuipp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void LFpuppi(x64emu_t *emu, uintptr_t fcn) { LFpuppi_t fn = (LFpuppi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void LFpLLLp(x64emu_t *emu, uintptr_t fcn) { LFpLLLp_t fn = (LFpLLLp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (uintptr_t)R_RDX, (uintptr_t)R_RCX, (void*)R_R8); }
-void LFpLppL(x64emu_t *emu, uintptr_t fcn) { LFpLppL_t fn = (LFpLppL_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (uintptr_t)R_R8); }
-void LFpLppp(x64emu_t *emu, uintptr_t fcn) { LFpLppp_t fn = (LFpLppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void LFppLLp(x64emu_t *emu, uintptr_t fcn) { LFppLLp_t fn = (LFppLLp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (uintptr_t)R_RCX, (void*)R_R8); }
-void LFpppii(x64emu_t *emu, uintptr_t fcn) { LFpppii_t fn = (LFpppii_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void LFppppp(x64emu_t *emu, uintptr_t fcn) { LFppppp_t fn = (LFppppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void pFEpiii(x64emu_t *emu, uintptr_t fcn) { pFEpiii_t fn = (pFEpiii_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void pFEpipL(x64emu_t *emu, uintptr_t fcn) { pFEpipL_t fn = (pFEpipL_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (uintptr_t)R_RCX); }
-void pFEpipp(x64emu_t *emu, uintptr_t fcn) { pFEpipp_t fn = (pFEpipp_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void pFEpipV(x64emu_t *emu, uintptr_t fcn) { pFEpipV_t fn = (pFEpipV_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)(R_RSP + 8)); }
-void pFEpipA(x64emu_t *emu, uintptr_t fcn) { pFEpipA_t fn = (pFEpipA_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void pFEpupp(x64emu_t *emu, uintptr_t fcn) { pFEpupp_t fn = (pFEpupp_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void pFEppii(x64emu_t *emu, uintptr_t fcn) { pFEppii_t fn = (pFEppii_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void pFEppip(x64emu_t *emu, uintptr_t fcn) { pFEppip_t fn = (pFEppip_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void pFEppLp(x64emu_t *emu, uintptr_t fcn) { pFEppLp_t fn = (pFEppLp_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX); }
-void pFEpppi(x64emu_t *emu, uintptr_t fcn) { pFEpppi_t fn = (pFEpppi_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX); }
-void pFEpppu(x64emu_t *emu, uintptr_t fcn) { pFEpppu_t fn = (pFEpppu_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX); }
-void pFEpppp(x64emu_t *emu, uintptr_t fcn) { pFEpppp_t fn = (pFEpppp_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void pFiiiii(x64emu_t *emu, uintptr_t fcn) { pFiiiii_t fn = (pFiiiii_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void pFiiipL(x64emu_t *emu, uintptr_t fcn) { pFiiipL_t fn = (pFiiipL_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (uintptr_t)R_R8); }
-void pFipipL(x64emu_t *emu, uintptr_t fcn) { pFipipL_t fn = (pFipipL_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (uintptr_t)R_R8); }
-void pFipppu(x64emu_t *emu, uintptr_t fcn) { pFipppu_t fn = (pFipppu_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (uint64_t)R_R8); }
-void pFuiiiu(x64emu_t *emu, uintptr_t fcn) { pFuiiiu_t fn = (pFuiiiu_t)fcn; R_RAX=(uintptr_t)fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8); }
-void pFuiipp(x64emu_t *emu, uintptr_t fcn) { pFuiipp_t fn = (pFuiipp_t)fcn; R_RAX=(uintptr_t)fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void pFpiiii(x64emu_t *emu, uintptr_t fcn) { pFpiiii_t fn = (pFpiiii_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void pFpiiip(x64emu_t *emu, uintptr_t fcn) { pFpiiip_t fn = (pFpiiip_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void pFpiiuu(x64emu_t *emu, uintptr_t fcn) { pFpiiuu_t fn = (pFpiiuu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8); }
-void pFpiipi(x64emu_t *emu, uintptr_t fcn) { pFpiipi_t fn = (pFpiipi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void pFpiipp(x64emu_t *emu, uintptr_t fcn) { pFpiipp_t fn = (pFpiipp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void pFpiCCC(x64emu_t *emu, uintptr_t fcn) { pFpiCCC_t fn = (pFpiCCC_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (uint8_t)R_RDX, (uint8_t)R_RCX, (uint8_t)R_R8); }
-void pFpiuuu(x64emu_t *emu, uintptr_t fcn) { pFpiuuu_t fn = (pFpiuuu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8); }
-void pFpippi(x64emu_t *emu, uintptr_t fcn) { pFpippi_t fn = (pFpippi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void pFpippp(x64emu_t *emu, uintptr_t fcn) { pFpippp_t fn = (pFpippp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void pFpCpup(x64emu_t *emu, uintptr_t fcn) { pFpCpup_t fn = (pFpCpup_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint8_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (void*)R_R8); }
-void pFpCppp(x64emu_t *emu, uintptr_t fcn) { pFpCppp_t fn = (pFpCppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint8_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void pFpuiii(x64emu_t *emu, uintptr_t fcn) { pFpuiii_t fn = (pFpuiii_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void pFpuiip(x64emu_t *emu, uintptr_t fcn) { pFpuiip_t fn = (pFpuiip_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void pFpuWWW(x64emu_t *emu, uintptr_t fcn) { pFpuWWW_t fn = (pFpuWWW_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint16_t)R_RDX, (uint16_t)R_RCX, (uint16_t)R_R8); }
-void pFpuuip(x64emu_t *emu, uintptr_t fcn) { pFpuuip_t fn = (pFpuuip_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void pFpuuWW(x64emu_t *emu, uintptr_t fcn) { pFpuuWW_t fn = (pFpuuWW_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint16_t)R_RCX, (uint16_t)R_R8); }
-void pFpuuuu(x64emu_t *emu, uintptr_t fcn) { pFpuuuu_t fn = (pFpuuuu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8); }
-void pFpuuup(x64emu_t *emu, uintptr_t fcn) { pFpuuup_t fn = (pFpuuup_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8); }
-void pFpuppp(x64emu_t *emu, uintptr_t fcn) { pFpuppp_t fn = (pFpuppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void pFpUdii(x64emu_t *emu, uintptr_t fcn) { pFpUdii_t fn = (pFpUdii_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, emu->xmm[0].d[0], (int64_t)R_RDX, (int64_t)R_RCX); }
-void pFpdddd(x64emu_t *emu, uintptr_t fcn) { pFpdddd_t fn = (pFpdddd_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0]); }
-void pFplppp(x64emu_t *emu, uintptr_t fcn) { pFplppp_t fn = (pFplppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (intptr_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void pFppiii(x64emu_t *emu, uintptr_t fcn) { pFppiii_t fn = (pFppiii_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void pFppiip(x64emu_t *emu, uintptr_t fcn) { pFppiip_t fn = (pFppiip_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void pFppiup(x64emu_t *emu, uintptr_t fcn) { pFppiup_t fn = (pFppiup_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8); }
-void pFppipi(x64emu_t *emu, uintptr_t fcn) { pFppipi_t fn = (pFppipi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void pFppipp(x64emu_t *emu, uintptr_t fcn) { pFppipp_t fn = (pFppipp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void pFppuuu(x64emu_t *emu, uintptr_t fcn) { pFppuuu_t fn = (pFppuuu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8); }
-void pFppuup(x64emu_t *emu, uintptr_t fcn) { pFppuup_t fn = (pFppuup_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8); }
-void pFppddi(x64emu_t *emu, uintptr_t fcn) { pFppddi_t fn = (pFppddi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, emu->xmm[0].d[0], emu->xmm[1].d[0], (int64_t)R_RDX); }
-void pFppLii(x64emu_t *emu, uintptr_t fcn) { pFppLii_t fn = (pFppLii_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void pFppLLp(x64emu_t *emu, uintptr_t fcn) { pFppLLp_t fn = (pFppLLp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (uintptr_t)R_RCX, (void*)R_R8); }
-void pFpppii(x64emu_t *emu, uintptr_t fcn) { pFpppii_t fn = (pFpppii_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void pFpppip(x64emu_t *emu, uintptr_t fcn) { pFpppip_t fn = (pFpppip_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void pFpppIi(x64emu_t *emu, uintptr_t fcn) { pFpppIi_t fn = (pFpppIi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void pFpppui(x64emu_t *emu, uintptr_t fcn) { pFpppui_t fn = (pFpppui_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8); }
-void pFpppuu(x64emu_t *emu, uintptr_t fcn) { pFpppuu_t fn = (pFpppuu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8); }
-void pFpppup(x64emu_t *emu, uintptr_t fcn) { pFpppup_t fn = (pFpppup_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (void*)R_R8); }
-void pFpppLi(x64emu_t *emu, uintptr_t fcn) { pFpppLi_t fn = (pFpppLi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uintptr_t)R_RCX, (int64_t)R_R8); }
-void pFppppi(x64emu_t *emu, uintptr_t fcn) { pFppppi_t fn = (pFppppi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void pFppppu(x64emu_t *emu, uintptr_t fcn) { pFppppu_t fn = (pFppppu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (uint64_t)R_R8); }
-void pFppppp(x64emu_t *emu, uintptr_t fcn) { pFppppp_t fn = (pFppppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void iWEpiup(x64emu_t *emu, uintptr_t fcn) { iWEpiup_t fn = (iWEpiup_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RCX, (int64_t)R_RDX, (uint64_t)R_R8, (void*)R_R9); }
-void iWEpipp(x64emu_t *emu, uintptr_t fcn) { iWEpipp_t fn = (iWEpipp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RCX, (int64_t)R_RDX, (void*)R_R8, (void*)R_R9); }
-void iWpiiii(x64emu_t *emu, uintptr_t fcn) { iWpiiii_t fn = (iWpiiii_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (int64_t)R_RDX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 40)); }
-void iWpiupu(x64emu_t *emu, uintptr_t fcn) { iWpiupu_t fn = (iWpiupu_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (int64_t)R_RDX, (uint64_t)R_R8, (void*)R_R9, *(uint64_t*)(R_RSP + 40)); }
-void iWpuiii(x64emu_t *emu, uintptr_t fcn) { iWpuiii_t fn = (iWpuiii_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (uint64_t)R_RDX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 40)); }
-void iWpuiup(x64emu_t *emu, uintptr_t fcn) { iWpuiup_t fn = (iWpuiup_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (uint64_t)R_RDX, (int64_t)R_R8, (uint64_t)R_R9, *(void**)(R_RSP + 40)); }
-void iWpuupu(x64emu_t *emu, uintptr_t fcn) { iWpuupu_t fn = (iWpuupu_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (uint64_t)R_RDX, (uint64_t)R_R8, (void*)R_R9, *(uint64_t*)(R_RSP + 40)); }
-void iWpuupp(x64emu_t *emu, uintptr_t fcn) { iWpuupp_t fn = (iWpuupp_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (uint64_t)R_RDX, (uint64_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 40)); }
-void iWpupuu(x64emu_t *emu, uintptr_t fcn) { iWpupuu_t fn = (iWpupuu_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (uint64_t)R_RDX, (void*)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 40)); }
-void iWpupup(x64emu_t *emu, uintptr_t fcn) { iWpupup_t fn = (iWpupup_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (uint64_t)R_RDX, (void*)R_R8, (uint64_t)R_R9, *(void**)(R_RSP + 40)); }
-void iWpuppu(x64emu_t *emu, uintptr_t fcn) { iWpuppu_t fn = (iWpuppu_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (uint64_t)R_RDX, (void*)R_R8, (void*)R_R9, *(uint64_t*)(R_RSP + 40)); }
-void iWpuppp(x64emu_t *emu, uintptr_t fcn) { iWpuppp_t fn = (iWpuppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (uint64_t)R_RDX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 40)); }
-void iWpppuu(x64emu_t *emu, uintptr_t fcn) { iWpppuu_t fn = (iWpppuu_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (void*)R_RDX, (void*)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 40)); }
-void iWpppup(x64emu_t *emu, uintptr_t fcn) { iWpppup_t fn = (iWpppup_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (void*)R_RDX, (void*)R_R8, (uint64_t)R_R9, *(void**)(R_RSP + 40)); }
-void iWppppp(x64emu_t *emu, uintptr_t fcn) { iWppppp_t fn = (iWppppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (void*)R_RDX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 40)); }
-void vFEiiipp(x64emu_t *emu, uintptr_t fcn) { vFEiiipp_t fn = (vFEiiipp_t)fcn; fn(emu, (int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void vFEpiLpp(x64emu_t *emu, uintptr_t fcn) { vFEpiLpp_t fn = (vFEpiLpp_t)fcn; fn(emu, (void*)R_RDI, (int64_t)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void vFEpippp(x64emu_t *emu, uintptr_t fcn) { vFEpippp_t fn = (vFEpippp_t)fcn; fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void vFEpuipp(x64emu_t *emu, uintptr_t fcn) { vFEpuipp_t fn = (vFEpuipp_t)fcn; fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void vFEpupup(x64emu_t *emu, uintptr_t fcn) { vFEpupup_t fn = (vFEpupup_t)fcn; fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (void*)R_R8); }
-void vFEpLLpp(x64emu_t *emu, uintptr_t fcn) { vFEpLLpp_t fn = (vFEpLLpp_t)fcn; fn(emu, (void*)R_RDI, (uintptr_t)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void vFEppipV(x64emu_t *emu, uintptr_t fcn) { vFEppipV_t fn = (vFEppipV_t)fcn; fn(emu, (void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)(R_RSP + 8)); }
-void vFEppipA(x64emu_t *emu, uintptr_t fcn) { vFEppipA_t fn = (vFEppipA_t)fcn; fn(emu, (void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void vFEppupp(x64emu_t *emu, uintptr_t fcn) { vFEppupp_t fn = (vFEppupp_t)fcn; fn(emu, (void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void vFEppppp(x64emu_t *emu, uintptr_t fcn) { vFEppppp_t fn = (vFEppppp_t)fcn; fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void vFiiiiii(x64emu_t *emu, uintptr_t fcn) { vFiiiiii_t fn = (vFiiiiii_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void vFiiiuil(x64emu_t *emu, uintptr_t fcn) { vFiiiuil_t fn = (vFiiiuil_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (intptr_t)R_R9); }
-void vFiiilpi(x64emu_t *emu, uintptr_t fcn) { vFiiilpi_t fn = (vFiiilpi_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX, (void*)R_R8, (int64_t)R_R9); }
-void vFiiuiil(x64emu_t *emu, uintptr_t fcn) { vFiiuiil_t fn = (vFiiuiil_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (intptr_t)R_R9); }
-void vFiiuilp(x64emu_t *emu, uintptr_t fcn) { vFiiuilp_t fn = (vFiiuilp_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (intptr_t)R_R8, (void*)R_R9); }
-void vFiiuulp(x64emu_t *emu, uintptr_t fcn) { vFiiuulp_t fn = (vFiiuulp_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (intptr_t)R_R8, (void*)R_R9); }
-void vFiililp(x64emu_t *emu, uintptr_t fcn) { vFiililp_t fn = (vFiililp_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (intptr_t)R_RDX, (int64_t)R_RCX, (intptr_t)R_R8, (void*)R_R9); }
-void vFiiplli(x64emu_t *emu, uintptr_t fcn) { vFiiplli_t fn = (vFiiplli_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8, (int64_t)R_R9); }
-void vFiiplll(x64emu_t *emu, uintptr_t fcn) { vFiiplll_t fn = (vFiiplll_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8, (intptr_t)R_R9); }
-void vFiuippp(x64emu_t *emu, uintptr_t fcn) { vFiuippp_t fn = (vFiuippp_t)fcn; fn((int64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void vFiffiff(x64emu_t *emu, uintptr_t fcn) { vFiffiff_t fn = (vFiffiff_t)fcn; fn((int64_t)R_RDI, emu->xmm[0].f[0], emu->xmm[1].f[0], (int64_t)R_RSI, emu->xmm[2].f[0], emu->xmm[3].f[0]); }
-void vFiddidd(x64emu_t *emu, uintptr_t fcn) { vFiddidd_t fn = (vFiddidd_t)fcn; fn((int64_t)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0], (int64_t)R_RSI, emu->xmm[2].d[0], emu->xmm[3].d[0]); }
-void vFililuU(x64emu_t *emu, uintptr_t fcn) { vFililuU_t fn = (vFililuU_t)fcn; fn((int64_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9); }
-void vFililll(x64emu_t *emu, uintptr_t fcn) { vFililll_t fn = (vFililll_t)fcn; fn((int64_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8, (intptr_t)R_R9); }
-void vFilipli(x64emu_t *emu, uintptr_t fcn) { vFilipli_t fn = (vFilipli_t)fcn; fn((int64_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (intptr_t)R_R8, (int64_t)R_R9); }
-void vFiliplu(x64emu_t *emu, uintptr_t fcn) { vFiliplu_t fn = (vFiliplu_t)fcn; fn((int64_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (intptr_t)R_R8, (uint64_t)R_R9); }
-void vFillill(x64emu_t *emu, uintptr_t fcn) { vFillill_t fn = (vFillill_t)fcn; fn((int64_t)R_RDI, (intptr_t)R_RSI, (intptr_t)R_RDX, (int64_t)R_RCX, (intptr_t)R_R8, (intptr_t)R_R9); }
-void vFipiplp(x64emu_t *emu, uintptr_t fcn) { vFipiplp_t fn = (vFipiplp_t)fcn; fn((int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (intptr_t)R_R8, (void*)R_R9); }
-void vFipllli(x64emu_t *emu, uintptr_t fcn) { vFipllli_t fn = (vFipllli_t)fcn; fn((int64_t)R_RDI, (void*)R_RSI, (intptr_t)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8, (int64_t)R_R9); }
-void vFuiiiii(x64emu_t *emu, uintptr_t fcn) { vFuiiiii_t fn = (vFuiiiii_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void vFuiiiil(x64emu_t *emu, uintptr_t fcn) { vFuiiiil_t fn = (vFuiiiil_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (intptr_t)R_R9); }
-void vFuiiiip(x64emu_t *emu, uintptr_t fcn) { vFuiiiip_t fn = (vFuiiiip_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9); }
-void vFuiiilp(x64emu_t *emu, uintptr_t fcn) { vFuiiilp_t fn = (vFuiiilp_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (intptr_t)R_R8, (void*)R_R9); }
-void vFuiiuii(x64emu_t *emu, uintptr_t fcn) { vFuiiuii_t fn = (vFuiiuii_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void vFuiiuup(x64emu_t *emu, uintptr_t fcn) { vFuiiuup_t fn = (vFuiiuup_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (void*)R_R9); }
-void vFuiIIII(x64emu_t *emu, uintptr_t fcn) { vFuiIIII_t fn = (vFuiIIII_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void vFuiuiii(x64emu_t *emu, uintptr_t fcn) { vFuiuiii_t fn = (vFuiuiii_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void vFuiuiil(x64emu_t *emu, uintptr_t fcn) { vFuiuiil_t fn = (vFuiuiil_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (intptr_t)R_R9); }
-void vFuiuiip(x64emu_t *emu, uintptr_t fcn) { vFuiuiip_t fn = (vFuiuiip_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9); }
-void vFuiuiuu(x64emu_t *emu, uintptr_t fcn) { vFuiuiuu_t fn = (vFuiuiuu_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9); }
-void vFuiuuip(x64emu_t *emu, uintptr_t fcn) { vFuiuuip_t fn = (vFuiuuip_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (void*)R_R9); }
-void vFuiuuuu(x64emu_t *emu, uintptr_t fcn) { vFuiuuuu_t fn = (vFuiuuuu_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9); }
-void vFuiuulp(x64emu_t *emu, uintptr_t fcn) { vFuiuulp_t fn = (vFuiuulp_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (intptr_t)R_R8, (void*)R_R9); }
-void vFuiupii(x64emu_t *emu, uintptr_t fcn) { vFuiupii_t fn = (vFuiupii_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void vFuiupiu(x64emu_t *emu, uintptr_t fcn) { vFuiupiu_t fn = (vFuiupiu_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8, (uint64_t)R_R9); }
-void vFuiUUUU(x64emu_t *emu, uintptr_t fcn) { vFuiUUUU_t fn = (vFuiUUUU_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9); }
-void vFuiffff(x64emu_t *emu, uintptr_t fcn) { vFuiffff_t fn = (vFuiffff_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0], emu->xmm[3].f[0]); }
-void vFuidddd(x64emu_t *emu, uintptr_t fcn) { vFuidddd_t fn = (vFuidddd_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0]); }
-void vFuuiiii(x64emu_t *emu, uintptr_t fcn) { vFuuiiii_t fn = (vFuuiiii_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void vFuuiiiu(x64emu_t *emu, uintptr_t fcn) { vFuuiiiu_t fn = (vFuuiiiu_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (uint64_t)R_R9); }
-void vFuuiuii(x64emu_t *emu, uintptr_t fcn) { vFuuiuii_t fn = (vFuuiuii_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void vFuuiuiu(x64emu_t *emu, uintptr_t fcn) { vFuuiuiu_t fn = (vFuuiuiu_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (uint64_t)R_R9); }
-void vFuuiuup(x64emu_t *emu, uintptr_t fcn) { vFuuiuup_t fn = (vFuuiuup_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (void*)R_R9); }
-void vFuuuiup(x64emu_t *emu, uintptr_t fcn) { vFuuuiup_t fn = (vFuuuiup_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (void*)R_R9); }
-void vFuuuipi(x64emu_t *emu, uintptr_t fcn) { vFuuuipi_t fn = (vFuuuipi_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (int64_t)R_R9); }
-void vFuuuipp(x64emu_t *emu, uintptr_t fcn) { vFuuuipp_t fn = (vFuuuipp_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9); }
-void vFuuuuii(x64emu_t *emu, uintptr_t fcn) { vFuuuuii_t fn = (vFuuuuii_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void vFuuuuip(x64emu_t *emu, uintptr_t fcn) { vFuuuuip_t fn = (vFuuuuip_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (void*)R_R9); }
-void vFuuuuuu(x64emu_t *emu, uintptr_t fcn) { vFuuuuuu_t fn = (vFuuuuuu_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9); }
-void vFuuuuff(x64emu_t *emu, uintptr_t fcn) { vFuuuuff_t fn = (vFuuuuff_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, emu->xmm[0].f[0], emu->xmm[1].f[0]); }
-void vFuuuppi(x64emu_t *emu, uintptr_t fcn) { vFuuuppi_t fn = (vFuuuppi_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (int64_t)R_R9); }
-void vFuuuppp(x64emu_t *emu, uintptr_t fcn) { vFuuuppp_t fn = (vFuuuppp_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void vFuuffff(x64emu_t *emu, uintptr_t fcn) { vFuuffff_t fn = (vFuuffff_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0], emu->xmm[3].f[0]); }
-void vFuudddd(x64emu_t *emu, uintptr_t fcn) { vFuudddd_t fn = (vFuudddd_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0]); }
-void vFuulppp(x64emu_t *emu, uintptr_t fcn) { vFuulppp_t fn = (vFuulppp_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (intptr_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void vFuupupp(x64emu_t *emu, uintptr_t fcn) { vFuupupp_t fn = (vFuupupp_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (void*)R_R8, (void*)R_R9); }
-void vFuffiip(x64emu_t *emu, uintptr_t fcn) { vFuffiip_t fn = (vFuffiip_t)fcn; fn((uint64_t)R_RDI, emu->xmm[0].f[0], emu->xmm[1].f[0], (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void vFufffff(x64emu_t *emu, uintptr_t fcn) { vFufffff_t fn = (vFufffff_t)fcn; fn((uint64_t)R_RDI, emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0], emu->xmm[3].f[0], emu->xmm[4].f[0]); }
-void vFuddiip(x64emu_t *emu, uintptr_t fcn) { vFuddiip_t fn = (vFuddiip_t)fcn; fn((uint64_t)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0], (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void vFuliluU(x64emu_t *emu, uintptr_t fcn) { vFuliluU_t fn = (vFuliluU_t)fcn; fn((uint64_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9); }
-void vFulilli(x64emu_t *emu, uintptr_t fcn) { vFulilli_t fn = (vFulilli_t)fcn; fn((uint64_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8, (int64_t)R_R9); }
-void vFulilll(x64emu_t *emu, uintptr_t fcn) { vFulilll_t fn = (vFulilll_t)fcn; fn((uint64_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8, (intptr_t)R_R9); }
-void vFullill(x64emu_t *emu, uintptr_t fcn) { vFullill_t fn = (vFullill_t)fcn; fn((uint64_t)R_RDI, (intptr_t)R_RSI, (intptr_t)R_RDX, (int64_t)R_RCX, (intptr_t)R_R8, (intptr_t)R_R9); }
-void vFulplup(x64emu_t *emu, uintptr_t fcn) { vFulplup_t fn = (vFulplup_t)fcn; fn((uint64_t)R_RDI, (intptr_t)R_RSI, (void*)R_RDX, (intptr_t)R_RCX, (uint64_t)R_R8, (void*)R_R9); }
-void vFupupip(x64emu_t *emu, uintptr_t fcn) { vFupupip_t fn = (vFupupip_t)fcn; fn((uint64_t)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8, (void*)R_R9); }
-void vFuppppu(x64emu_t *emu, uintptr_t fcn) { vFuppppu_t fn = (vFuppppu_t)fcn; fn((uint64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (uint64_t)R_R9); }
-void vFuppppp(x64emu_t *emu, uintptr_t fcn) { vFuppppp_t fn = (vFuppppp_t)fcn; fn((uint64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void vFffffff(x64emu_t *emu, uintptr_t fcn) { vFffffff_t fn = (vFffffff_t)fcn; fn(emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0], emu->xmm[3].f[0], emu->xmm[4].f[0], emu->xmm[5].f[0]); }
-void vFdddddd(x64emu_t *emu, uintptr_t fcn) { vFdddddd_t fn = (vFdddddd_t)fcn; fn(emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0], emu->xmm[4].d[0], emu->xmm[5].d[0]); }
-void vFpiiiii(x64emu_t *emu, uintptr_t fcn) { vFpiiiii_t fn = (vFpiiiii_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void vFpiiipp(x64emu_t *emu, uintptr_t fcn) { vFpiiipp_t fn = (vFpiiipp_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9); }
-void vFpiiuuu(x64emu_t *emu, uintptr_t fcn) { vFpiiuuu_t fn = (vFpiiuuu_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9); }
-void vFpiippp(x64emu_t *emu, uintptr_t fcn) { vFpiippp_t fn = (vFpiippp_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void vFpiUuup(x64emu_t *emu, uintptr_t fcn) { vFpiUuup_t fn = (vFpiUuup_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (void*)R_R9); }
-void vFpipipV(x64emu_t *emu, uintptr_t fcn) { vFpipipV_t fn = (vFpipipV_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)(R_RSP + 8)); }
-void vFpipppi(x64emu_t *emu, uintptr_t fcn) { vFpipppi_t fn = (vFpipppi_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (int64_t)R_R9); }
-void vFpipppp(x64emu_t *emu, uintptr_t fcn) { vFpipppp_t fn = (vFpipppp_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void vFpuiiii(x64emu_t *emu, uintptr_t fcn) { vFpuiiii_t fn = (vFpuiiii_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void vFpuiiiu(x64emu_t *emu, uintptr_t fcn) { vFpuiiiu_t fn = (vFpuiiiu_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (uint64_t)R_R9); }
-void vFpuiipp(x64emu_t *emu, uintptr_t fcn) { vFpuiipp_t fn = (vFpuiipp_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9); }
-void vFpuuuiu(x64emu_t *emu, uintptr_t fcn) { vFpuuuiu_t fn = (vFpuuuiu_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (uint64_t)R_R9); }
-void vFpuuppp(x64emu_t *emu, uintptr_t fcn) { vFpuuppp_t fn = (vFpuuppp_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void vFpudddd(x64emu_t *emu, uintptr_t fcn) { vFpudddd_t fn = (vFpudddd_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0]); }
-void vFpupiUu(x64emu_t *emu, uintptr_t fcn) { vFpupiUu_t fn = (vFpupiUu_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9); }
-void vFpupuuu(x64emu_t *emu, uintptr_t fcn) { vFpupuuu_t fn = (vFpupuuu_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9); }
-void vFpupppp(x64emu_t *emu, uintptr_t fcn) { vFpupppp_t fn = (vFpupppp_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void vFpUiuup(x64emu_t *emu, uintptr_t fcn) { vFpUiuup_t fn = (vFpUiuup_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (void*)R_R9); }
-void vFpUiUup(x64emu_t *emu, uintptr_t fcn) { vFpUiUup_t fn = (vFpUiUup_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (void*)R_R9); }
-void vFpUipup(x64emu_t *emu, uintptr_t fcn) { vFpUipup_t fn = (vFpUipup_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (uint64_t)R_R8, (void*)R_R9); }
-void vFpUUiup(x64emu_t *emu, uintptr_t fcn) { vFpUUiup_t fn = (vFpUUiup_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (void*)R_R9); }
-void vFpdddii(x64emu_t *emu, uintptr_t fcn) { vFpdddii_t fn = (vFpdddii_t)fcn; fn((void*)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], (int64_t)R_RSI, (int64_t)R_RDX); }
-void vFpddddd(x64emu_t *emu, uintptr_t fcn) { vFpddddd_t fn = (vFpddddd_t)fcn; fn((void*)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0], emu->xmm[4].d[0]); }
-void vFpddddp(x64emu_t *emu, uintptr_t fcn) { vFpddddp_t fn = (vFpddddp_t)fcn; fn((void*)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0], (void*)R_RSI); }
-void vFppiiii(x64emu_t *emu, uintptr_t fcn) { vFppiiii_t fn = (vFppiiii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void vFppiiip(x64emu_t *emu, uintptr_t fcn) { vFppiiip_t fn = (vFppiiip_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9); }
-void vFppiiui(x64emu_t *emu, uintptr_t fcn) { vFppiiui_t fn = (vFppiiui_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (int64_t)R_R9); }
-void vFppiipi(x64emu_t *emu, uintptr_t fcn) { vFppiipi_t fn = (vFppiipi_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (int64_t)R_R9); }
-void vFppiipp(x64emu_t *emu, uintptr_t fcn) { vFppiipp_t fn = (vFppiipp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9); }
-void vFppilpp(x64emu_t *emu, uintptr_t fcn) { vFppilpp_t fn = (vFppilpp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX, (void*)R_R8, (void*)R_R9); }
-void vFppippi(x64emu_t *emu, uintptr_t fcn) { vFppippi_t fn = (vFppippi_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (int64_t)R_R9); }
-void vFppippp(x64emu_t *emu, uintptr_t fcn) { vFppippp_t fn = (vFppippp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void vFppuuuu(x64emu_t *emu, uintptr_t fcn) { vFppuuuu_t fn = (vFppuuuu_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9); }
-void vFppuUUU(x64emu_t *emu, uintptr_t fcn) { vFppuUUU_t fn = (vFppuUUU_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9); }
-void vFppupii(x64emu_t *emu, uintptr_t fcn) { vFppupii_t fn = (vFppupii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void vFppuppp(x64emu_t *emu, uintptr_t fcn) { vFppuppp_t fn = (vFppuppp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void vFppdidd(x64emu_t *emu, uintptr_t fcn) { vFppdidd_t fn = (vFppdidd_t)fcn; fn((void*)R_RDI, (void*)R_RSI, emu->xmm[0].d[0], (int64_t)R_RDX, emu->xmm[1].d[0], emu->xmm[2].d[0]); }
-void vFppdddd(x64emu_t *emu, uintptr_t fcn) { vFppdddd_t fn = (vFppdddd_t)fcn; fn((void*)R_RDI, (void*)R_RSI, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0]); }
-void vFpplppi(x64emu_t *emu, uintptr_t fcn) { vFpplppi_t fn = (vFpplppi_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (intptr_t)R_RDX, (void*)R_RCX, (void*)R_R8, (int64_t)R_R9); }
-void vFpplppp(x64emu_t *emu, uintptr_t fcn) { vFpplppp_t fn = (vFpplppp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (intptr_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void vFppLppi(x64emu_t *emu, uintptr_t fcn) { vFppLppi_t fn = (vFppLppi_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX, (void*)R_R8, (int64_t)R_R9); }
-void vFppLppp(x64emu_t *emu, uintptr_t fcn) { vFppLppp_t fn = (vFppLppp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void vFpppiii(x64emu_t *emu, uintptr_t fcn) { vFpppiii_t fn = (vFpppiii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void vFpppiip(x64emu_t *emu, uintptr_t fcn) { vFpppiip_t fn = (vFpppiip_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9); }
-void vFpppiff(x64emu_t *emu, uintptr_t fcn) { vFpppiff_t fn = (vFpppiff_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, emu->xmm[0].f[0], emu->xmm[1].f[0]); }
-void vFpppipu(x64emu_t *emu, uintptr_t fcn) { vFpppipu_t fn = (vFpppipu_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8, (uint64_t)R_R9); }
-void vFpppuii(x64emu_t *emu, uintptr_t fcn) { vFpppuii_t fn = (vFpppuii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void vFppppii(x64emu_t *emu, uintptr_t fcn) { vFppppii_t fn = (vFppppii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void vFpppppi(x64emu_t *emu, uintptr_t fcn) { vFpppppi_t fn = (vFpppppi_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (int64_t)R_R9); }
-void vFpppppu(x64emu_t *emu, uintptr_t fcn) { vFpppppu_t fn = (vFpppppu_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (uint64_t)R_R9); }
-void vFpppppU(x64emu_t *emu, uintptr_t fcn) { vFpppppU_t fn = (vFpppppU_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (uint64_t)R_R9); }
-void vFpppppL(x64emu_t *emu, uintptr_t fcn) { vFpppppL_t fn = (vFpppppL_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (uintptr_t)R_R9); }
-void vFpppppp(x64emu_t *emu, uintptr_t fcn) { vFpppppp_t fn = (vFpppppp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void cFppLppi(x64emu_t *emu, uintptr_t fcn) { cFppLppi_t fn = (cFppLppi_t)fcn; R_RAX=fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX, (void*)R_R8, (int64_t)R_R9); }
-void iFEiippi(x64emu_t *emu, uintptr_t fcn) { iFEiippi_t fn = (iFEiippi_t)fcn; R_RAX=(int64_t)fn(emu, (int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void iFEiippp(x64emu_t *emu, uintptr_t fcn) { iFEiippp_t fn = (iFEiippp_t)fcn; R_RAX=(int64_t)fn(emu, (int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void iFEiLLLL(x64emu_t *emu, uintptr_t fcn) { iFEiLLLL_t fn = (iFEiLLLL_t)fcn; R_RAX=(int64_t)fn(emu, (int64_t)R_RDI, (uintptr_t)R_RSI, (uintptr_t)R_RDX, (uintptr_t)R_RCX, (uintptr_t)R_R8); }
-void iFEippLp(x64emu_t *emu, uintptr_t fcn) { iFEippLp_t fn = (iFEippLp_t)fcn; R_RAX=(int64_t)fn(emu, (int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (uintptr_t)R_RCX, (void*)R_R8); }
-void iFElpppp(x64emu_t *emu, uintptr_t fcn) { iFElpppp_t fn = (iFElpppp_t)fcn; R_RAX=(int64_t)fn(emu, (intptr_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void iFEpiipp(x64emu_t *emu, uintptr_t fcn) { iFEpiipp_t fn = (iFEpiipp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void iFEpiipV(x64emu_t *emu, uintptr_t fcn) { iFEpiipV_t fn = (iFEpiipV_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)(R_RSP + 8)); }
-void iFEpilpV(x64emu_t *emu, uintptr_t fcn) { iFEpilpV_t fn = (iFEpilpV_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (intptr_t)R_RDX, (void*)R_RCX, (void*)(R_RSP + 8)); }
-void iFEpippi(x64emu_t *emu, uintptr_t fcn) { iFEpippi_t fn = (iFEpippi_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void iFEpIppp(x64emu_t *emu, uintptr_t fcn) { iFEpIppp_t fn = (iFEpIppp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void iFEpuppp(x64emu_t *emu, uintptr_t fcn) { iFEpuppp_t fn = (iFEpuppp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void iFEpUppp(x64emu_t *emu, uintptr_t fcn) { iFEpUppp_t fn = (iFEpUppp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void iFEppppp(x64emu_t *emu, uintptr_t fcn) { iFEppppp_t fn = (iFEppppp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void iFiiiiii(x64emu_t *emu, uintptr_t fcn) { iFiiiiii_t fn = (iFiiiiii_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void iFiiiiip(x64emu_t *emu, uintptr_t fcn) { iFiiiiip_t fn = (iFiiiiip_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9); }
-void iFiiiuwp(x64emu_t *emu, uintptr_t fcn) { iFiiiuwp_t fn = (iFiiiuwp_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (int16_t)R_R8, (void*)R_R9); }
-void iFiuiipi(x64emu_t *emu, uintptr_t fcn) { iFiuiipi_t fn = (iFiuiipi_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (int64_t)R_R9); }
-void iFipiipi(x64emu_t *emu, uintptr_t fcn) { iFipiipi_t fn = (iFipiipi_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (int64_t)R_R9); }
-void iFipipip(x64emu_t *emu, uintptr_t fcn) { iFipipip_t fn = (iFipipip_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8, (void*)R_R9); }
-void iFipippp(x64emu_t *emu, uintptr_t fcn) { iFipippp_t fn = (iFipippp_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFipuufp(x64emu_t *emu, uintptr_t fcn) { iFipuufp_t fn = (iFipuufp_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, emu->xmm[0].f[0], (void*)R_R8); }
-void iFipupup(x64emu_t *emu, uintptr_t fcn) { iFipupup_t fn = (iFipupup_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (uint64_t)R_R8, (void*)R_R9); }
-void iFipuppp(x64emu_t *emu, uintptr_t fcn) { iFipuppp_t fn = (iFipuppp_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFipppLp(x64emu_t *emu, uintptr_t fcn) { iFipppLp_t fn = (iFipppLp_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (uintptr_t)R_R8, (void*)R_R9); }
-void iFippppp(x64emu_t *emu, uintptr_t fcn) { iFippppp_t fn = (iFippppp_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFuppppp(x64emu_t *emu, uintptr_t fcn) { iFuppppp_t fn = (iFuppppp_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFdipppL(x64emu_t *emu, uintptr_t fcn) { iFdipppL_t fn = (iFdipppL_t)fcn; R_RAX=(int64_t)fn(emu->xmm[0].d[0], (int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (uintptr_t)R_R8); }
-void iFDipppL(x64emu_t *emu, uintptr_t fcn) { iFDipppL_t fn = (iFDipppL_t)fcn; R_RAX=(int64_t)fn(LD2localLD((void*)(R_RSP + 8)), (int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (uintptr_t)R_R8); }
-void iFlpippp(x64emu_t *emu, uintptr_t fcn) { iFlpippp_t fn = (iFlpippp_t)fcn; R_RAX=(int64_t)fn((intptr_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFLppipp(x64emu_t *emu, uintptr_t fcn) { iFLppipp_t fn = (iFLppipp_t)fcn; R_RAX=(int64_t)fn((uintptr_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFpiiiii(x64emu_t *emu, uintptr_t fcn) { iFpiiiii_t fn = (iFpiiiii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void iFpiiiip(x64emu_t *emu, uintptr_t fcn) { iFpiiiip_t fn = (iFpiiiip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9); }
-void iFpiiipp(x64emu_t *emu, uintptr_t fcn) { iFpiiipp_t fn = (iFpiiipp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFpiipip(x64emu_t *emu, uintptr_t fcn) { iFpiipip_t fn = (iFpiipip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8, (void*)R_R9); }
-void iFpiippu(x64emu_t *emu, uintptr_t fcn) { iFpiippu_t fn = (iFpiippu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (uint64_t)R_R9); }
-void iFpiippp(x64emu_t *emu, uintptr_t fcn) { iFpiippp_t fn = (iFpiippp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFpiuuup(x64emu_t *emu, uintptr_t fcn) { iFpiuuup_t fn = (iFpiuuup_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (void*)R_R9); }
-void iFpiuupp(x64emu_t *emu, uintptr_t fcn) { iFpiuupp_t fn = (iFpiuupp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFpiUUpp(x64emu_t *emu, uintptr_t fcn) { iFpiUUpp_t fn = (iFpiUUpp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFpipipi(x64emu_t *emu, uintptr_t fcn) { iFpipipi_t fn = (iFpipipi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8, (int64_t)R_R9); }
-void iFpippip(x64emu_t *emu, uintptr_t fcn) { iFpippip_t fn = (iFpippip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (void*)R_R9); }
-void iFpipppL(x64emu_t *emu, uintptr_t fcn) { iFpipppL_t fn = (iFpipppL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (uintptr_t)R_R9); }
-void iFpipppp(x64emu_t *emu, uintptr_t fcn) { iFpipppp_t fn = (iFpipppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFpCpipu(x64emu_t *emu, uintptr_t fcn) { iFpCpipu_t fn = (iFpCpipu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint8_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8, (uint64_t)R_R9); }
-void iFpWpppp(x64emu_t *emu, uintptr_t fcn) { iFpWpppp_t fn = (iFpWpppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint16_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFpuiCpp(x64emu_t *emu, uintptr_t fcn) { iFpuiCpp_t fn = (iFpuiCpp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (uint8_t)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFpuippp(x64emu_t *emu, uintptr_t fcn) { iFpuippp_t fn = (iFpuippp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFpupuui(x64emu_t *emu, uintptr_t fcn) { iFpupuui_t fn = (iFpupuui_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (int64_t)R_R9); }
-void iFpUuuLp(x64emu_t *emu, uintptr_t fcn) { iFpUuuLp_t fn = (iFpUuuLp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uintptr_t)R_R8, (void*)R_R9); }
-void iFpUuupp(x64emu_t *emu, uintptr_t fcn) { iFpUuupp_t fn = (iFpUuupp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFpUUUip(x64emu_t *emu, uintptr_t fcn) { iFpUUUip_t fn = (iFpUUUip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (void*)R_R9); }
-void iFpUUUUp(x64emu_t *emu, uintptr_t fcn) { iFpUUUUp_t fn = (iFpUUUUp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (void*)R_R9); }
-void iFpLLppp(x64emu_t *emu, uintptr_t fcn) { iFpLLppp_t fn = (iFpLLppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFppiiii(x64emu_t *emu, uintptr_t fcn) { iFppiiii_t fn = (iFppiiii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void iFppiiip(x64emu_t *emu, uintptr_t fcn) { iFppiiip_t fn = (iFppiiip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9); }
-void iFppiiuu(x64emu_t *emu, uintptr_t fcn) { iFppiiuu_t fn = (iFppiiuu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9); }
-void iFppiipi(x64emu_t *emu, uintptr_t fcn) { iFppiipi_t fn = (iFppiipi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (int64_t)R_R9); }
-void iFppiipp(x64emu_t *emu, uintptr_t fcn) { iFppiipp_t fn = (iFppiipp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFppipii(x64emu_t *emu, uintptr_t fcn) { iFppipii_t fn = (iFppipii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void iFppipiL(x64emu_t *emu, uintptr_t fcn) { iFppipiL_t fn = (iFppipiL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8, (uintptr_t)R_R9); }
-void iFppipip(x64emu_t *emu, uintptr_t fcn) { iFppipip_t fn = (iFppipip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8, (void*)R_R9); }
-void iFppIipp(x64emu_t *emu, uintptr_t fcn) { iFppIipp_t fn = (iFppIipp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFppIppp(x64emu_t *emu, uintptr_t fcn) { iFppIppp_t fn = (iFppIppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFppuiii(x64emu_t *emu, uintptr_t fcn) { iFppuiii_t fn = (iFppuiii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void iFppuiiL(x64emu_t *emu, uintptr_t fcn) { iFppuiiL_t fn = (iFppuiiL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (uintptr_t)R_R9); }
-void iFppuipp(x64emu_t *emu, uintptr_t fcn) { iFppuipp_t fn = (iFppuipp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFppuIII(x64emu_t *emu, uintptr_t fcn) { iFppuIII_t fn = (iFppuIII_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void iFppuupp(x64emu_t *emu, uintptr_t fcn) { iFppuupp_t fn = (iFppuupp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFppupip(x64emu_t *emu, uintptr_t fcn) { iFppupip_t fn = (iFppupip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8, (void*)R_R9); }
-void iFppuppp(x64emu_t *emu, uintptr_t fcn) { iFppuppp_t fn = (iFppuppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFppUipp(x64emu_t *emu, uintptr_t fcn) { iFppUipp_t fn = (iFppUipp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFppUUup(x64emu_t *emu, uintptr_t fcn) { iFppUUup_t fn = (iFppUUup_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (void*)R_R9); }
-void iFppdidd(x64emu_t *emu, uintptr_t fcn) { iFppdidd_t fn = (iFppdidd_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, emu->xmm[0].d[0], (int64_t)R_RDX, emu->xmm[1].d[0], emu->xmm[2].d[0]); }
-void iFpplppi(x64emu_t *emu, uintptr_t fcn) { iFpplppi_t fn = (iFpplppi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (intptr_t)R_RDX, (void*)R_RCX, (void*)R_R8, (int64_t)R_R9); }
-void iFppLupp(x64emu_t *emu, uintptr_t fcn) { iFppLupp_t fn = (iFppLupp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFppLpLp(x64emu_t *emu, uintptr_t fcn) { iFppLpLp_t fn = (iFppLpLp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX, (uintptr_t)R_R8, (void*)R_R9); }
-void iFpppiuu(x64emu_t *emu, uintptr_t fcn) { iFpppiuu_t fn = (iFpppiuu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9); }
-void iFpppipi(x64emu_t *emu, uintptr_t fcn) { iFpppipi_t fn = (iFpppipi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8, (int64_t)R_R9); }
-void iFpppipp(x64emu_t *emu, uintptr_t fcn) { iFpppipp_t fn = (iFpppipp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFpppuii(x64emu_t *emu, uintptr_t fcn) { iFpppuii_t fn = (iFpppuii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void iFpppupu(x64emu_t *emu, uintptr_t fcn) { iFpppupu_t fn = (iFpppupu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (void*)R_R8, (uint64_t)R_R9); }
-void iFpppLpp(x64emu_t *emu, uintptr_t fcn) { iFpppLpp_t fn = (iFpppLpp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uintptr_t)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFppppii(x64emu_t *emu, uintptr_t fcn) { iFppppii_t fn = (iFppppii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void iFppppiu(x64emu_t *emu, uintptr_t fcn) { iFppppiu_t fn = (iFppppiu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (uint64_t)R_R9); }
-void iFppppip(x64emu_t *emu, uintptr_t fcn) { iFppppip_t fn = (iFppppip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (void*)R_R9); }
-void iFppppup(x64emu_t *emu, uintptr_t fcn) { iFppppup_t fn = (iFppppup_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (uint64_t)R_R8, (void*)R_R9); }
-void iFpppppi(x64emu_t *emu, uintptr_t fcn) { iFpppppi_t fn = (iFpppppi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (int64_t)R_R9); }
-void iFpppppL(x64emu_t *emu, uintptr_t fcn) { iFpppppL_t fn = (iFpppppL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (uintptr_t)R_R9); }
-void iFpppppp(x64emu_t *emu, uintptr_t fcn) { iFpppppp_t fn = (iFpppppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void uFEiippp(x64emu_t *emu, uintptr_t fcn) { uFEiippp_t fn = (uFEiippp_t)fcn; R_RAX=(uint64_t)fn(emu, (int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void uFEiuppp(x64emu_t *emu, uintptr_t fcn) { uFEiuppp_t fn = (uFEiuppp_t)fcn; R_RAX=(uint64_t)fn(emu, (int64_t)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void uFEpCppp(x64emu_t *emu, uintptr_t fcn) { uFEpCppp_t fn = (uFEpCppp_t)fcn; R_RAX=(uint64_t)fn(emu, (void*)R_RDI, (uint8_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void uFEpuppp(x64emu_t *emu, uintptr_t fcn) { uFEpuppp_t fn = (uFEpuppp_t)fcn; R_RAX=(uint64_t)fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void uFpippup(x64emu_t *emu, uintptr_t fcn) { uFpippup_t fn = (uFpippup_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (uint64_t)R_R8, (void*)R_R9); }
-void uFpWuwCp(x64emu_t *emu, uintptr_t fcn) { uFpWuwCp_t fn = (uFpWuwCp_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (uint16_t)R_RSI, (uint64_t)R_RDX, (int16_t)R_RCX, (uint8_t)R_R8, (void*)R_R9); }
-void uFpWuipp(x64emu_t *emu, uintptr_t fcn) { uFpWuipp_t fn = (uFpWuipp_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (uint16_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9); }
-void uFpWuuCp(x64emu_t *emu, uintptr_t fcn) { uFpWuuCp_t fn = (uFpWuuCp_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (uint16_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint8_t)R_R8, (void*)R_R9); }
-void uFpuippp(x64emu_t *emu, uintptr_t fcn) { uFpuippp_t fn = (uFpuippp_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void uFppippp(x64emu_t *emu, uintptr_t fcn) { uFppippp_t fn = (uFppippp_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void uFppuuup(x64emu_t *emu, uintptr_t fcn) { uFppuuup_t fn = (uFppuuup_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (void*)R_R9); }
-void uFppuupu(x64emu_t *emu, uintptr_t fcn) { uFppuupu_t fn = (uFppuupu_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8, (uint64_t)R_R9); }
-void uFpppppi(x64emu_t *emu, uintptr_t fcn) { uFpppppi_t fn = (uFpppppi_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (int64_t)R_R9); }
-void uFpppppp(x64emu_t *emu, uintptr_t fcn) { uFpppppp_t fn = (uFpppppp_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void UFpippup(x64emu_t *emu, uintptr_t fcn) { UFpippup_t fn = (UFpippup_t)fcn; R_RAX=fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (uint64_t)R_R8, (void*)R_R9); }
-void lFEpippp(x64emu_t *emu, uintptr_t fcn) { lFEpippp_t fn = (lFEpippp_t)fcn; R_RAX=(intptr_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void lFipipLu(x64emu_t *emu, uintptr_t fcn) { lFipipLu_t fn = (lFipipLu_t)fcn; R_RAX=(intptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (uintptr_t)R_R8, (uint64_t)R_R9); }
-void lFipLipu(x64emu_t *emu, uintptr_t fcn) { lFipLipu_t fn = (lFipLipu_t)fcn; R_RAX=(intptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (uint64_t)R_R9); }
-void lFipLipp(x64emu_t *emu, uintptr_t fcn) { lFipLipp_t fn = (lFipLipp_t)fcn; R_RAX=(intptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9); }
-void lFipLpLL(x64emu_t *emu, uintptr_t fcn) { lFipLpLL_t fn = (lFipLpLL_t)fcn; R_RAX=(intptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX, (uintptr_t)R_R8, (uintptr_t)R_R9); }
-void LFEupppp(x64emu_t *emu, uintptr_t fcn) { LFEupppp_t fn = (LFEupppp_t)fcn; R_RAX=(uintptr_t)fn(emu, (uint64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void LFELpppi(x64emu_t *emu, uintptr_t fcn) { LFELpppi_t fn = (LFELpppi_t)fcn; R_RAX=(uintptr_t)fn(emu, (uintptr_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void LFEppppi(x64emu_t *emu, uintptr_t fcn) { LFEppppi_t fn = (LFEppppi_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void LFpipipi(x64emu_t *emu, uintptr_t fcn) { LFpipipi_t fn = (LFpipipi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8, (int64_t)R_R9); }
-void LFpLippp(x64emu_t *emu, uintptr_t fcn) { LFpLippp_t fn = (LFpLippp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void LFSpLiip(x64emu_t *emu, uintptr_t fcn) { LFSpLiip_t fn = (LFSpLiip_t)fcn; R_RAX=(uintptr_t)fn(io_convert((void*)R_RDI), (void*)R_RSI, (uintptr_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9); }
-void pFEpiupp(x64emu_t *emu, uintptr_t fcn) { pFEpiupp_t fn = (pFEpiupp_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void pFEpippp(x64emu_t *emu, uintptr_t fcn) { pFEpippp_t fn = (pFEpippp_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void pFEpuipp(x64emu_t *emu, uintptr_t fcn) { pFEpuipp_t fn = (pFEpuipp_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void pFEpuupp(x64emu_t *emu, uintptr_t fcn) { pFEpuupp_t fn = (pFEpuupp_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void pFEpuppp(x64emu_t *emu, uintptr_t fcn) { pFEpuppp_t fn = (pFEpuppp_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void pFEpLLiN(x64emu_t *emu, uintptr_t fcn) { pFEpLLiN_t fn = (pFEpLLiN_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (uintptr_t)R_RSI, (uintptr_t)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void pFEppLLp(x64emu_t *emu, uintptr_t fcn) { pFEppLLp_t fn = (pFEppLLp_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (uintptr_t)R_RCX, (void*)R_R8); }
-void pFEpppLp(x64emu_t *emu, uintptr_t fcn) { pFEpppLp_t fn = (pFEpppLp_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uintptr_t)R_RCX, (void*)R_R8); }
-void pFEppppi(x64emu_t *emu, uintptr_t fcn) { pFEppppi_t fn = (pFEppppi_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8); }
-void pFEppppp(x64emu_t *emu, uintptr_t fcn) { pFEppppp_t fn = (pFEppppp_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void pFEppppV(x64emu_t *emu, uintptr_t fcn) { pFEppppV_t fn = (pFEppppV_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)(R_RSP + 8)); }
-void pFEppApp(x64emu_t *emu, uintptr_t fcn) { pFEppApp_t fn = (pFEppApp_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8); }
-void pFiiiiii(x64emu_t *emu, uintptr_t fcn) { pFiiiiii_t fn = (pFiiiiii_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void pFiCiiCi(x64emu_t *emu, uintptr_t fcn) { pFiCiiCi_t fn = (pFiCiiCi_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (uint8_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint8_t)R_R8, (int64_t)R_R9); }
-void pFdddddd(x64emu_t *emu, uintptr_t fcn) { pFdddddd_t fn = (pFdddddd_t)fcn; R_RAX=(uintptr_t)fn(emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0], emu->xmm[4].d[0], emu->xmm[5].d[0]); }
-void pFpiiiiu(x64emu_t *emu, uintptr_t fcn) { pFpiiiiu_t fn = (pFpiiiiu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (uint64_t)R_R9); }
-void pFpiiCCC(x64emu_t *emu, uintptr_t fcn) { pFpiiCCC_t fn = (pFpiiCCC_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (uint8_t)R_RCX, (uint8_t)R_R8, (uint8_t)R_R9); }
-void pFpiUUUU(x64emu_t *emu, uintptr_t fcn) { pFpiUUUU_t fn = (pFpiUUUU_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9); }
-void pFpippip(x64emu_t *emu, uintptr_t fcn) { pFpippip_t fn = (pFpippip_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (void*)R_R9); }
-void pFpipppp(x64emu_t *emu, uintptr_t fcn) { pFpipppp_t fn = (pFpipppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void pFpCuuCC(x64emu_t *emu, uintptr_t fcn) { pFpCuuCC_t fn = (pFpCuuCC_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint8_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint8_t)R_R8, (uint8_t)R_R9); }
-void pFpCuuWW(x64emu_t *emu, uintptr_t fcn) { pFpCuuWW_t fn = (pFpCuuWW_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint8_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint16_t)R_R8, (uint16_t)R_R9); }
-void pFpCuuup(x64emu_t *emu, uintptr_t fcn) { pFpCuuup_t fn = (pFpCuuup_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint8_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (void*)R_R9); }
-void pFpuuwwu(x64emu_t *emu, uintptr_t fcn) { pFpuuwwu_t fn = (pFpuuwwu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int16_t)R_RCX, (int16_t)R_R8, (uint64_t)R_R9); }
-void pFpuuuuu(x64emu_t *emu, uintptr_t fcn) { pFpuuuuu_t fn = (pFpuuuuu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9); }
-void pFpuuupu(x64emu_t *emu, uintptr_t fcn) { pFpuuupu_t fn = (pFpuuupu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8, (uint64_t)R_R9); }
-void pFpuuUUU(x64emu_t *emu, uintptr_t fcn) { pFpuuUUU_t fn = (pFpuuUUU_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9); }
-void pFplpppp(x64emu_t *emu, uintptr_t fcn) { pFplpppp_t fn = (pFplpppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (intptr_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void pFppiiii(x64emu_t *emu, uintptr_t fcn) { pFppiiii_t fn = (pFppiiii_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void pFppiipp(x64emu_t *emu, uintptr_t fcn) { pFppiipp_t fn = (pFppiipp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9); }
-void pFppiCCC(x64emu_t *emu, uintptr_t fcn) { pFppiCCC_t fn = (pFppiCCC_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (uint8_t)R_RCX, (uint8_t)R_R8, (uint8_t)R_R9); }
-void pFppippi(x64emu_t *emu, uintptr_t fcn) { pFppippi_t fn = (pFppippi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (int64_t)R_R9); }
-void pFppippp(x64emu_t *emu, uintptr_t fcn) { pFppippp_t fn = (pFppippp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void pFpppiii(x64emu_t *emu, uintptr_t fcn) { pFpppiii_t fn = (pFpppiii_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void pFpppiui(x64emu_t *emu, uintptr_t fcn) { pFpppiui_t fn = (pFpppiui_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (int64_t)R_R9); }
-void pFpppiup(x64emu_t *emu, uintptr_t fcn) { pFpppiup_t fn = (pFpppiup_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (void*)R_R9); }
-void pFpppupp(x64emu_t *emu, uintptr_t fcn) { pFpppupp_t fn = (pFpppupp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (void*)R_R8, (void*)R_R9); }
-void pFppppii(x64emu_t *emu, uintptr_t fcn) { pFppppii_t fn = (pFppppii_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void pFppppWW(x64emu_t *emu, uintptr_t fcn) { pFppppWW_t fn = (pFppppWW_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (uint16_t)R_R8, (uint16_t)R_R9); }
-void pFpppppi(x64emu_t *emu, uintptr_t fcn) { pFpppppi_t fn = (pFpppppi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (int64_t)R_R9); }
-void pFpppppu(x64emu_t *emu, uintptr_t fcn) { pFpppppu_t fn = (pFpppppu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (uint64_t)R_R9); }
-void pFpppppp(x64emu_t *emu, uintptr_t fcn) { pFpppppp_t fn = (pFpppppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void pFSpiiii(x64emu_t *emu, uintptr_t fcn) { pFSpiiii_t fn = (pFSpiiii_t)fcn; R_RAX=(uintptr_t)fn(io_convert((void*)R_RDI), (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void iWEpuuip(x64emu_t *emu, uintptr_t fcn) { iWEpuuip_t fn = (iWEpuuip_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RCX, (uint64_t)R_RDX, (uint64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 40)); }
-void iWEppppp(x64emu_t *emu, uintptr_t fcn) { iWEppppp_t fn = (iWEppppp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RCX, (void*)R_RDX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 40)); }
-void iWpiiiip(x64emu_t *emu, uintptr_t fcn) { iWpiiiip_t fn = (iWpiiiip_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (int64_t)R_RDX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 40), *(void**)(R_RSP + 48)); }
-void iWpiiuii(x64emu_t *emu, uintptr_t fcn) { iWpiiuii_t fn = (iWpiiuii_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (int64_t)R_RDX, (int64_t)R_R8, (uint64_t)R_R9, *(int64_t*)(R_RSP + 40), *(int64_t*)(R_RSP + 48)); }
-void iWpiuppu(x64emu_t *emu, uintptr_t fcn) { iWpiuppu_t fn = (iWpiuppu_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (int64_t)R_RDX, (uint64_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 40), *(uint64_t*)(R_RSP + 48)); }
-void iWpuiiii(x64emu_t *emu, uintptr_t fcn) { iWpuiiii_t fn = (iWpuiiii_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (uint64_t)R_RDX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 40), *(int64_t*)(R_RSP + 48)); }
-void iWpppppi(x64emu_t *emu, uintptr_t fcn) { iWpppppi_t fn = (iWpppppi_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (void*)R_RDX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 40), *(int64_t*)(R_RSP + 48)); }
-void iWpppppu(x64emu_t *emu, uintptr_t fcn) { iWpppppu_t fn = (iWpppppu_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (void*)R_RDX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 40), *(uint64_t*)(R_RSP + 48)); }
-void vFEpiiipp(x64emu_t *emu, uintptr_t fcn) { vFEpiiipp_t fn = (vFEpiiipp_t)fcn; fn(emu, (void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9); }
-void vFEpipppp(x64emu_t *emu, uintptr_t fcn) { vFEpipppp_t fn = (vFEpipppp_t)fcn; fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void vFEpuipuV(x64emu_t *emu, uintptr_t fcn) { vFEpuipuV_t fn = (vFEpuipuV_t)fcn; fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (uint64_t)R_R8, (void*)(R_RSP + 8)); }
-void vFEppippp(x64emu_t *emu, uintptr_t fcn) { vFEppippp_t fn = (vFEppippp_t)fcn; fn(emu, (void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void vFEpppppp(x64emu_t *emu, uintptr_t fcn) { vFEpppppp_t fn = (vFEpppppp_t)fcn; fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void vFiiiiiip(x64emu_t *emu, uintptr_t fcn) { vFiiiiiip_t fn = (vFiiiiiip_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void vFiiiiuup(x64emu_t *emu, uintptr_t fcn) { vFiiiiuup_t fn = (vFiiiiuup_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(void**)(R_RSP + 8)); }
-void vFiiuilil(x64emu_t *emu, uintptr_t fcn) { vFiiuilil_t fn = (vFiiuilil_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (intptr_t)R_R8, (int64_t)R_R9, *(intptr_t*)(R_RSP + 8)); }
-void vFiiffffp(x64emu_t *emu, uintptr_t fcn) { vFiiffffp_t fn = (vFiiffffp_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0], emu->xmm[3].f[0], (void*)R_RDX); }
-void vFiipllli(x64emu_t *emu, uintptr_t fcn) { vFiipllli_t fn = (vFiipllli_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8, (intptr_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void vFiuulipi(x64emu_t *emu, uintptr_t fcn) { vFiuulipi_t fn = (vFiuulipi_t)fcn; fn((int64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (intptr_t)R_RCX, (int64_t)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8)); }
-void vFililluU(x64emu_t *emu, uintptr_t fcn) { vFililluU_t fn = (vFililluU_t)fcn; fn((int64_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8)); }
-void vFilipliu(x64emu_t *emu, uintptr_t fcn) { vFilipliu_t fn = (vFilipliu_t)fcn; fn((int64_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (intptr_t)R_R8, (int64_t)R_R9, *(uint64_t*)(R_RSP + 8)); }
-void vFilulipi(x64emu_t *emu, uintptr_t fcn) { vFilulipi_t fn = (vFilulipi_t)fcn; fn((int64_t)R_RDI, (intptr_t)R_RSI, (uint64_t)R_RDX, (intptr_t)R_RCX, (int64_t)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8)); }
-void vFuiiiiii(x64emu_t *emu, uintptr_t fcn) { vFuiiiiii_t fn = (vFuiiiiii_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void vFuiiiuip(x64emu_t *emu, uintptr_t fcn) { vFuiiiuip_t fn = (vFuiiiuip_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void vFuiiiuup(x64emu_t *emu, uintptr_t fcn) { vFuiiiuup_t fn = (vFuiiiuup_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(void**)(R_RSP + 8)); }
-void vFuiiliip(x64emu_t *emu, uintptr_t fcn) { vFuiiliip_t fn = (vFuiiliip_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void vFuiililp(x64emu_t *emu, uintptr_t fcn) { vFuiililp_t fn = (vFuiililp_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX, (int64_t)R_R8, (intptr_t)R_R9, *(void**)(R_RSP + 8)); }
-void vFuiuiiii(x64emu_t *emu, uintptr_t fcn) { vFuiuiiii_t fn = (vFuiuiiii_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void vFuiuiiip(x64emu_t *emu, uintptr_t fcn) { vFuiuiiip_t fn = (vFuiuiiip_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void vFuiuiiuu(x64emu_t *emu, uintptr_t fcn) { vFuiuiiuu_t fn = (vFuiuiiuu_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8)); }
-void vFuiupiiu(x64emu_t *emu, uintptr_t fcn) { vFuiupiiu_t fn = (vFuiupiiu_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(uint64_t*)(R_RSP + 8)); }
-void vFuilliip(x64emu_t *emu, uintptr_t fcn) { vFuilliip_t fn = (vFuilliip_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (intptr_t)R_RDX, (intptr_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void vFuipiiii(x64emu_t *emu, uintptr_t fcn) { vFuipiiii_t fn = (vFuipiiii_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void vFuipffff(x64emu_t *emu, uintptr_t fcn) { vFuipffff_t fn = (vFuipffff_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0], emu->xmm[3].f[0]); }
-void vFuipdddd(x64emu_t *emu, uintptr_t fcn) { vFuipdddd_t fn = (vFuipdddd_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0]); }
-void vFuuiiiii(x64emu_t *emu, uintptr_t fcn) { vFuuiiiii_t fn = (vFuuiiiii_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void vFuuiiiip(x64emu_t *emu, uintptr_t fcn) { vFuuiiiip_t fn = (vFuuiiiip_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void vFuuiiiui(x64emu_t *emu, uintptr_t fcn) { vFuuiiiui_t fn = (vFuuiiiui_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (uint64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void vFuuiiiuu(x64emu_t *emu, uintptr_t fcn) { vFuuiiiuu_t fn = (vFuuiiiuu_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8)); }
-void vFuuiiuup(x64emu_t *emu, uintptr_t fcn) { vFuuiiuup_t fn = (vFuuiiuup_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(void**)(R_RSP + 8)); }
-void vFuuiuiii(x64emu_t *emu, uintptr_t fcn) { vFuuiuiii_t fn = (vFuuiuiii_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void vFuuipppp(x64emu_t *emu, uintptr_t fcn) { vFuuipppp_t fn = (vFuuipppp_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void vFuuuiiii(x64emu_t *emu, uintptr_t fcn) { vFuuuiiii_t fn = (vFuuuiiii_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void vFuuuiiip(x64emu_t *emu, uintptr_t fcn) { vFuuuiiip_t fn = (vFuuuiiip_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void vFuuuiuii(x64emu_t *emu, uintptr_t fcn) { vFuuuiuii_t fn = (vFuuuiuii_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void vFuuuiupi(x64emu_t *emu, uintptr_t fcn) { vFuuuiupi_t fn = (vFuuuiupi_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8)); }
-void vFuuuuiip(x64emu_t *emu, uintptr_t fcn) { vFuuuuiip_t fn = (vFuuuuiip_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void vFuuuuuuu(x64emu_t *emu, uintptr_t fcn) { vFuuuuuuu_t fn = (vFuuuuuuu_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8)); }
-void vFuuuufff(x64emu_t *emu, uintptr_t fcn) { vFuuuufff_t fn = (vFuuuufff_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0]); }
-void vFuuuulll(x64emu_t *emu, uintptr_t fcn) { vFuuuulll_t fn = (vFuuuulll_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (intptr_t)R_R8, (intptr_t)R_R9, *(intptr_t*)(R_RSP + 8)); }
-void vFuuuffff(x64emu_t *emu, uintptr_t fcn) { vFuuuffff_t fn = (vFuuuffff_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0], emu->xmm[3].f[0]); }
-void vFuuudddd(x64emu_t *emu, uintptr_t fcn) { vFuuudddd_t fn = (vFuuudddd_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0]); }
-void vFuuffiip(x64emu_t *emu, uintptr_t fcn) { vFuuffiip_t fn = (vFuuffiip_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, emu->xmm[0].f[0], emu->xmm[1].f[0], (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void vFuuddiip(x64emu_t *emu, uintptr_t fcn) { vFuuddiip_t fn = (vFuuddiip_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, emu->xmm[0].d[0], emu->xmm[1].d[0], (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-void vFuuppppu(x64emu_t *emu, uintptr_t fcn) { vFuuppppu_t fn = (vFuuppppu_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(uint64_t*)(R_RSP + 8)); }
-void vFuuppppp(x64emu_t *emu, uintptr_t fcn) { vFuuppppp_t fn = (vFuuppppp_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void vFuffffff(x64emu_t *emu, uintptr_t fcn) { vFuffffff_t fn = (vFuffffff_t)fcn; fn((uint64_t)R_RDI, emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0], emu->xmm[3].f[0], emu->xmm[4].f[0], emu->xmm[5].f[0]); }
-void vFudddddd(x64emu_t *emu, uintptr_t fcn) { vFudddddd_t fn = (vFudddddd_t)fcn; fn((uint64_t)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0], emu->xmm[4].d[0], emu->xmm[5].d[0]); }
-void vFulilluU(x64emu_t *emu, uintptr_t fcn) { vFulilluU_t fn = (vFulilluU_t)fcn; fn((uint64_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8)); }
-void vFulillli(x64emu_t *emu, uintptr_t fcn) { vFulillli_t fn = (vFulillli_t)fcn; fn((uint64_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8, (intptr_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void vFulipulp(x64emu_t *emu, uintptr_t fcn) { vFulipulp_t fn = (vFulipulp_t)fcn; fn((uint64_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (uint64_t)R_R8, (intptr_t)R_R9, *(void**)(R_RSP + 8)); }
-void vFulpiill(x64emu_t *emu, uintptr_t fcn) { vFulpiill_t fn = (vFulpiill_t)fcn; fn((uint64_t)R_RDI, (intptr_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (intptr_t)R_R9, *(intptr_t*)(R_RSP + 8)); }
-void vFlipuiip(x64emu_t *emu, uintptr_t fcn) { vFlipuiip_t fn = (vFlipuiip_t)fcn; fn((intptr_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void vFlliiiip(x64emu_t *emu, uintptr_t fcn) { vFlliiiip_t fn = (vFlliiiip_t)fcn; fn((intptr_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void vFpiiiipp(x64emu_t *emu, uintptr_t fcn) { vFpiiiipp_t fn = (vFpiiiipp_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void vFpiiliip(x64emu_t *emu, uintptr_t fcn) { vFpiiliip_t fn = (vFpiiliip_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void vFpiipCpp(x64emu_t *emu, uintptr_t fcn) { vFpiipCpp_t fn = (vFpiipCpp_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (uint8_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void vFpiipppp(x64emu_t *emu, uintptr_t fcn) { vFpiipppp_t fn = (vFpiipppp_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void vFpipipii(x64emu_t *emu, uintptr_t fcn) { vFpipipii_t fn = (vFpipipii_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void vFpipppii(x64emu_t *emu, uintptr_t fcn) { vFpipppii_t fn = (vFpipppii_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void vFpuuuuuu(x64emu_t *emu, uintptr_t fcn) { vFpuuuuuu_t fn = (vFpuuuuuu_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8)); }
-void vFpuuUUuu(x64emu_t *emu, uintptr_t fcn) { vFpuuUUuu_t fn = (vFpuuUUuu_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8)); }
-void vFpuupppp(x64emu_t *emu, uintptr_t fcn) { vFpuupppp_t fn = (vFpuupppp_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void vFpupuuup(x64emu_t *emu, uintptr_t fcn) { vFpupuuup_t fn = (vFpupuuup_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(void**)(R_RSP + 8)); }
-void vFpUiUiup(x64emu_t *emu, uintptr_t fcn) { vFpUiUiup_t fn = (vFpUiUiup_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (uint64_t)R_R9, *(void**)(R_RSP + 8)); }
-void vFpUUUUuu(x64emu_t *emu, uintptr_t fcn) { vFpUUUUuu_t fn = (vFpUUUUuu_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8)); }
-void vFpddiidd(x64emu_t *emu, uintptr_t fcn) { vFpddiidd_t fn = (vFpddiidd_t)fcn; fn((void*)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0], (int64_t)R_RSI, (int64_t)R_RDX, emu->xmm[2].d[0], emu->xmm[3].d[0]); }
-void vFpdddddd(x64emu_t *emu, uintptr_t fcn) { vFpdddddd_t fn = (vFpdddddd_t)fcn; fn((void*)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0], emu->xmm[4].d[0], emu->xmm[5].d[0]); }
-void vFpLiLiLp(x64emu_t *emu, uintptr_t fcn) { vFpLiLiLp_t fn = (vFpLiLiLp_t)fcn; fn((void*)R_RDI, (uintptr_t)R_RSI, (int64_t)R_RDX, (uintptr_t)R_RCX, (int64_t)R_R8, (uintptr_t)R_R9, *(void**)(R_RSP + 8)); }
-void vFppiiiii(x64emu_t *emu, uintptr_t fcn) { vFppiiiii_t fn = (vFppiiiii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void vFppiiiip(x64emu_t *emu, uintptr_t fcn) { vFppiiiip_t fn = (vFppiiiip_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void vFppiiipi(x64emu_t *emu, uintptr_t fcn) { vFppiiipi_t fn = (vFppiiipi_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8)); }
-void vFppiipii(x64emu_t *emu, uintptr_t fcn) { vFppiipii_t fn = (vFppiipii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void vFppiipuu(x64emu_t *emu, uintptr_t fcn) { vFppiipuu_t fn = (vFppiipuu_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8)); }
-void vFppiippp(x64emu_t *emu, uintptr_t fcn) { vFppiippp_t fn = (vFppiippp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void vFppilppi(x64emu_t *emu, uintptr_t fcn) { vFppilppi_t fn = (vFppilppi_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX, (void*)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8)); }
-void vFppiLiLp(x64emu_t *emu, uintptr_t fcn) { vFppiLiLp_t fn = (vFppiLiLp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (uintptr_t)R_RCX, (int64_t)R_R8, (uintptr_t)R_R9, *(void**)(R_RSP + 8)); }
-void vFppipiip(x64emu_t *emu, uintptr_t fcn) { vFppipiip_t fn = (vFppipiip_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void vFppipipp(x64emu_t *emu, uintptr_t fcn) { vFppipipp_t fn = (vFppipipp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void vFppipppp(x64emu_t *emu, uintptr_t fcn) { vFppipppp_t fn = (vFppipppp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void vFppddddi(x64emu_t *emu, uintptr_t fcn) { vFppddddi_t fn = (vFppddddi_t)fcn; fn((void*)R_RDI, (void*)R_RSI, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0], (int64_t)R_RDX); }
-void vFppddpii(x64emu_t *emu, uintptr_t fcn) { vFppddpii_t fn = (vFppddpii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, emu->xmm[0].d[0], emu->xmm[1].d[0], (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8); }
-void vFppLpppi(x64emu_t *emu, uintptr_t fcn) { vFppLpppi_t fn = (vFppLpppi_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8)); }
-void vFppLpppp(x64emu_t *emu, uintptr_t fcn) { vFppLpppp_t fn = (vFppLpppp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void vFpppiiii(x64emu_t *emu, uintptr_t fcn) { vFpppiiii_t fn = (vFpppiiii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void vFpppiipi(x64emu_t *emu, uintptr_t fcn) { vFpppiipi_t fn = (vFpppiipi_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8)); }
-void vFpppiipp(x64emu_t *emu, uintptr_t fcn) { vFpppiipp_t fn = (vFpppiipp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void vFpppippi(x64emu_t *emu, uintptr_t fcn) { vFpppippi_t fn = (vFpppippi_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8)); }
-void vFpppuuuu(x64emu_t *emu, uintptr_t fcn) { vFpppuuuu_t fn = (vFpppuuuu_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8)); }
-void vFppppiii(x64emu_t *emu, uintptr_t fcn) { vFppppiii_t fn = (vFppppiii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void vFppppiip(x64emu_t *emu, uintptr_t fcn) { vFppppiip_t fn = (vFppppiip_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void vFppppipi(x64emu_t *emu, uintptr_t fcn) { vFppppipi_t fn = (vFppppipi_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8)); }
-void vFpppppip(x64emu_t *emu, uintptr_t fcn) { vFpppppip_t fn = (vFpppppip_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void vFppppppi(x64emu_t *emu, uintptr_t fcn) { vFppppppi_t fn = (vFppppppi_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8)); }
-void vFppppppp(x64emu_t *emu, uintptr_t fcn) { vFppppppp_t fn = (vFppppppp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void iFEpupppp(x64emu_t *emu, uintptr_t fcn) { iFEpupppp_t fn = (iFEpupppp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFEpUuppp(x64emu_t *emu, uintptr_t fcn) { iFEpUuppp_t fn = (iFEpUuppp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFEpLiLpV(x64emu_t *emu, uintptr_t fcn) { iFEpLiLpV_t fn = (iFEpLiLpV_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (uintptr_t)R_RSI, (int64_t)R_RDX, (uintptr_t)R_RCX, (void*)R_R8, (void*)(R_RSP + 8)); }
-void iFEppuppp(x64emu_t *emu, uintptr_t fcn) { iFEppuppp_t fn = (iFEppuppp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFEppLpIi(x64emu_t *emu, uintptr_t fcn) { iFEppLpIi_t fn = (iFEppLpIi_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void iFEpppiiu(x64emu_t *emu, uintptr_t fcn) { iFEpppiiu_t fn = (iFEpppiiu_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (uint64_t)R_R9); }
-void iFEpppppL(x64emu_t *emu, uintptr_t fcn) { iFEpppppL_t fn = (iFEpppppL_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (uintptr_t)R_R9); }
-void iFEpppppp(x64emu_t *emu, uintptr_t fcn) { iFEpppppp_t fn = (iFEpppppp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFiiiiiip(x64emu_t *emu, uintptr_t fcn) { iFiiiiiip_t fn = (iFiiiiiip_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void iFpiiiiii(x64emu_t *emu, uintptr_t fcn) { iFpiiiiii_t fn = (iFpiiiiii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void iFpiiiiip(x64emu_t *emu, uintptr_t fcn) { iFpiiiiip_t fn = (iFpiiiiip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void iFpiiiuwp(x64emu_t *emu, uintptr_t fcn) { iFpiiiuwp_t fn = (iFpiiiuwp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (int16_t)R_R9, *(void**)(R_RSP + 8)); }
-void iFpiiuuiu(x64emu_t *emu, uintptr_t fcn) { iFpiiuuiu_t fn = (iFpiiuuiu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (int64_t)R_R9, *(uint64_t*)(R_RSP + 8)); }
-void iFpiipppp(x64emu_t *emu, uintptr_t fcn) { iFpiipppp_t fn = (iFpiipppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void iFpiuiipp(x64emu_t *emu, uintptr_t fcn) { iFpiuiipp_t fn = (iFpiuiipp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void iFpiupiii(x64emu_t *emu, uintptr_t fcn) { iFpiupiii_t fn = (iFpiupiii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void iFpiupppp(x64emu_t *emu, uintptr_t fcn) { iFpiupppp_t fn = (iFpiupppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void iFpipipip(x64emu_t *emu, uintptr_t fcn) { iFpipipip_t fn = (iFpipipip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void iFpipippp(x64emu_t *emu, uintptr_t fcn) { iFpipippp_t fn = (iFpipippp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void iFpippLpp(x64emu_t *emu, uintptr_t fcn) { iFpippLpp_t fn = (iFpippLpp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (uintptr_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void iFpippppW(x64emu_t *emu, uintptr_t fcn) { iFpippppW_t fn = (iFpippppW_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(uint16_t*)(R_RSP + 8)); }
-void iFpippppp(x64emu_t *emu, uintptr_t fcn) { iFpippppp_t fn = (iFpippppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void iFpIIpppp(x64emu_t *emu, uintptr_t fcn) { iFpIIpppp_t fn = (iFpIIpppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void iFpWppppW(x64emu_t *emu, uintptr_t fcn) { iFpWppppW_t fn = (iFpWppppW_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint16_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(uint16_t*)(R_RSP + 8)); }
-void iFpuiCuCp(x64emu_t *emu, uintptr_t fcn) { iFpuiCuCp_t fn = (iFpuiCuCp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (uint8_t)R_RCX, (uint64_t)R_R8, (uint8_t)R_R9, *(void**)(R_RSP + 8)); }
-void iFpuiuupp(x64emu_t *emu, uintptr_t fcn) { iFpuiuupp_t fn = (iFpuiuupp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void iFpuuiuui(x64emu_t *emu, uintptr_t fcn) { iFpuuiuui_t fn = (iFpuuiuui_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void iFpuupppp(x64emu_t *emu, uintptr_t fcn) { iFpuupppp_t fn = (iFpuupppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void iFpupiLpL(x64emu_t *emu, uintptr_t fcn) { iFpupiLpL_t fn = (iFpupiLpL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (uintptr_t)R_R8, (void*)R_R9, *(uintptr_t*)(R_RSP + 8)); }
-void iFpupuuui(x64emu_t *emu, uintptr_t fcn) { iFpupuuui_t fn = (iFpupuuui_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void iFpupupui(x64emu_t *emu, uintptr_t fcn) { iFpupupui_t fn = (iFpupupui_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (void*)R_R8, (uint64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void iFpuppppp(x64emu_t *emu, uintptr_t fcn) { iFpuppppp_t fn = (iFpuppppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void iFpLipipi(x64emu_t *emu, uintptr_t fcn) { iFpLipipi_t fn = (iFpLipipi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8)); }
-void iFppiiiip(x64emu_t *emu, uintptr_t fcn) { iFppiiiip_t fn = (iFppiiiip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void iFppiiuui(x64emu_t *emu, uintptr_t fcn) { iFppiiuui_t fn = (iFppiiuui_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void iFppiiuup(x64emu_t *emu, uintptr_t fcn) { iFppiiuup_t fn = (iFppiiuup_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(void**)(R_RSP + 8)); }
-void iFppiipii(x64emu_t *emu, uintptr_t fcn) { iFppiipii_t fn = (iFppiipii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void iFppiipiL(x64emu_t *emu, uintptr_t fcn) { iFppiipiL_t fn = (iFppiipiL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (int64_t)R_R9, *(uintptr_t*)(R_RSP + 8)); }
-void iFppiuppi(x64emu_t *emu, uintptr_t fcn) { iFppiuppi_t fn = (iFppiuppi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8)); }
-void iFppipiii(x64emu_t *emu, uintptr_t fcn) { iFppipiii_t fn = (iFppipiii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void iFppipiip(x64emu_t *emu, uintptr_t fcn) { iFppipiip_t fn = (iFppipiip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void iFppipipi(x64emu_t *emu, uintptr_t fcn) { iFppipipi_t fn = (iFppipipi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8)); }
-void iFppipipp(x64emu_t *emu, uintptr_t fcn) { iFppipipp_t fn = (iFppipipp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void iFppippip(x64emu_t *emu, uintptr_t fcn) { iFppippip_t fn = (iFppippip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void iFppipppi(x64emu_t *emu, uintptr_t fcn) { iFppipppi_t fn = (iFppipppi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8)); }
-void iFppipppp(x64emu_t *emu, uintptr_t fcn) { iFppipppp_t fn = (iFppipppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void iFppuipiL(x64emu_t *emu, uintptr_t fcn) { iFppuipiL_t fn = (iFppuipiL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (int64_t)R_R9, *(uintptr_t*)(R_RSP + 8)); }
-void iFppLiipp(x64emu_t *emu, uintptr_t fcn) { iFppLiipp_t fn = (iFppLiipp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void iFpppiiii(x64emu_t *emu, uintptr_t fcn) { iFpppiiii_t fn = (iFpppiiii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void iFpppiiuu(x64emu_t *emu, uintptr_t fcn) { iFpppiiuu_t fn = (iFpppiiuu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8)); }
-void iFpppiiup(x64emu_t *emu, uintptr_t fcn) { iFpppiiup_t fn = (iFpppiiup_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (uint64_t)R_R9, *(void**)(R_RSP + 8)); }
-void iFpppiipi(x64emu_t *emu, uintptr_t fcn) { iFpppiipi_t fn = (iFpppiipi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8)); }
-void iFpppiuwu(x64emu_t *emu, uintptr_t fcn) { iFpppiuwu_t fn = (iFpppiuwu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (int16_t)R_R9, *(uint64_t*)(R_RSP + 8)); }
-void iFpppippi(x64emu_t *emu, uintptr_t fcn) { iFpppippi_t fn = (iFpppippi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8)); }
-void iFpppippp(x64emu_t *emu, uintptr_t fcn) { iFpppippp_t fn = (iFpppippp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void iFpppuiii(x64emu_t *emu, uintptr_t fcn) { iFpppuiii_t fn = (iFpppuiii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void iFppppiii(x64emu_t *emu, uintptr_t fcn) { iFppppiii_t fn = (iFppppiii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void iFppppipp(x64emu_t *emu, uintptr_t fcn) { iFppppipp_t fn = (iFppppipp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void iFppppdpi(x64emu_t *emu, uintptr_t fcn) { iFppppdpi_t fn = (iFppppdpi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, emu->xmm[0].d[0], (void*)R_R8, (int64_t)R_R9); }
-void iFpppppip(x64emu_t *emu, uintptr_t fcn) { iFpppppip_t fn = (iFpppppip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void iFpppppup(x64emu_t *emu, uintptr_t fcn) { iFpppppup_t fn = (iFpppppup_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (uint64_t)R_R9, *(void**)(R_RSP + 8)); }
-void iFppppppi(x64emu_t *emu, uintptr_t fcn) { iFppppppi_t fn = (iFppppppi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8)); }
-void iFppppppp(x64emu_t *emu, uintptr_t fcn) { iFppppppp_t fn = (iFppppppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void uFEiipppp(x64emu_t *emu, uintptr_t fcn) { uFEiipppp_t fn = (uFEiipppp_t)fcn; R_RAX=(uint64_t)fn(emu, (int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void uFEpiippp(x64emu_t *emu, uintptr_t fcn) { uFEpiippp_t fn = (uFEpiippp_t)fcn; R_RAX=(uint64_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void uFEpuuppp(x64emu_t *emu, uintptr_t fcn) { uFEpuuppp_t fn = (uFEpuuppp_t)fcn; R_RAX=(uint64_t)fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void uFuippppp(x64emu_t *emu, uintptr_t fcn) { uFuippppp_t fn = (uFuippppp_t)fcn; R_RAX=(uint64_t)fn((uint64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void uFppiuppp(x64emu_t *emu, uintptr_t fcn) { uFppiuppp_t fn = (uFppiuppp_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void uFppuuuup(x64emu_t *emu, uintptr_t fcn) { uFppuuuup_t fn = (uFppuuuup_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(void**)(R_RSP + 8)); }
-void LFEppLppU(x64emu_t *emu, uintptr_t fcn) { LFEppLppU_t fn = (LFEppLppU_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX, (void*)R_R8, (uint64_t)R_R9); }
-void LFEpppppu(x64emu_t *emu, uintptr_t fcn) { LFEpppppu_t fn = (LFEpppppu_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (uint64_t)R_R9); }
-void pFEpLiiii(x64emu_t *emu, uintptr_t fcn) { pFEpLiiii_t fn = (pFEpLiiii_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (uintptr_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void pFEpLiiiI(x64emu_t *emu, uintptr_t fcn) { pFEpLiiiI_t fn = (pFEpLiiiI_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (uintptr_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void pFEpLiiil(x64emu_t *emu, uintptr_t fcn) { pFEpLiiil_t fn = (pFEpLiiil_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (uintptr_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (intptr_t)R_R9); }
-void pFEppuipp(x64emu_t *emu, uintptr_t fcn) { pFEppuipp_t fn = (pFEppuipp_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9); }
-void pFEppppip(x64emu_t *emu, uintptr_t fcn) { pFEppppip_t fn = (pFEppppip_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (void*)R_R9); }
-void pFEpppppi(x64emu_t *emu, uintptr_t fcn) { pFEpppppi_t fn = (pFEpppppi_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (int64_t)R_R9); }
-void pFifffppp(x64emu_t *emu, uintptr_t fcn) { pFifffppp_t fn = (pFifffppp_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0], (void*)R_RSI, (void*)R_RDX, (void*)R_RCX); }
-void pFuupupup(x64emu_t *emu, uintptr_t fcn) { pFuupupup_t fn = (pFuupupup_t)fcn; R_RAX=(uintptr_t)fn((uint64_t)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (void*)R_R8, (uint64_t)R_R9, *(void**)(R_RSP + 8)); }
-void pFdiiiIiI(x64emu_t *emu, uintptr_t fcn) { pFdiiiIiI_t fn = (pFdiiiIiI_t)fcn; R_RAX=(uintptr_t)fn(emu->xmm[0].d[0], (int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9); }
-void pFpiiUdii(x64emu_t *emu, uintptr_t fcn) { pFpiiUdii_t fn = (pFpiiUdii_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, emu->xmm[0].d[0], (int64_t)R_R8, (int64_t)R_R9); }
-void pFpCuwwWW(x64emu_t *emu, uintptr_t fcn) { pFpCuwwWW_t fn = (pFpCuwwWW_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint8_t)R_RSI, (uint64_t)R_RDX, (int16_t)R_RCX, (int16_t)R_R8, (uint16_t)R_R9, *(uint16_t*)(R_RSP + 8)); }
-void pFpCuWCCC(x64emu_t *emu, uintptr_t fcn) { pFpCuWCCC_t fn = (pFpCuWCCC_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint8_t)R_RSI, (uint64_t)R_RDX, (uint16_t)R_RCX, (uint8_t)R_R8, (uint8_t)R_R9, *(uint8_t*)(R_RSP + 8)); }
-void pFpCuuwwp(x64emu_t *emu, uintptr_t fcn) { pFpCuuwwp_t fn = (pFpCuuwwp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint8_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (int16_t)R_R8, (int16_t)R_R9, *(void**)(R_RSP + 8)); }
-void pFpCuuuuu(x64emu_t *emu, uintptr_t fcn) { pFpCuuuuu_t fn = (pFpCuuuuu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint8_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8)); }
-void pFpCpWWup(x64emu_t *emu, uintptr_t fcn) { pFpCpWWup_t fn = (pFpCpWWup_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint8_t)R_RSI, (void*)R_RDX, (uint16_t)R_RCX, (uint16_t)R_R8, (uint64_t)R_R9, *(void**)(R_RSP + 8)); }
-void pFpuuuwwu(x64emu_t *emu, uintptr_t fcn) { pFpuuuwwu_t fn = (pFpuuuwwu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (int16_t)R_R8, (int16_t)R_R9, *(uint64_t*)(R_RSP + 8)); }
-void pFpuupwwC(x64emu_t *emu, uintptr_t fcn) { pFpuupwwC_t fn = (pFpuupwwC_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (int16_t)R_R8, (int16_t)R_R9, *(uint8_t*)(R_RSP + 8)); }
-void pFplppppp(x64emu_t *emu, uintptr_t fcn) { pFplppppp_t fn = (pFplppppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (intptr_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void pFpLppiip(x64emu_t *emu, uintptr_t fcn) { pFpLppiip_t fn = (pFpLppiip_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void pFppiiipp(x64emu_t *emu, uintptr_t fcn) { pFppiiipp_t fn = (pFppiiipp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void pFppiiCCC(x64emu_t *emu, uintptr_t fcn) { pFppiiCCC_t fn = (pFppiiCCC_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint8_t)R_R8, (uint8_t)R_R9, *(uint8_t*)(R_RSP + 8)); }
-void pFppiippp(x64emu_t *emu, uintptr_t fcn) { pFppiippp_t fn = (pFppiippp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void pFppipipp(x64emu_t *emu, uintptr_t fcn) { pFppipipp_t fn = (pFppipipp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void pFppipLpp(x64emu_t *emu, uintptr_t fcn) { pFppipLpp_t fn = (pFppipLpp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (uintptr_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void pFppuuppp(x64emu_t *emu, uintptr_t fcn) { pFppuuppp_t fn = (pFppuuppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void pFppLiiip(x64emu_t *emu, uintptr_t fcn) { pFppLiiip_t fn = (pFppLiiip_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void pFppLipip(x64emu_t *emu, uintptr_t fcn) { pFppLipip_t fn = (pFppLipip_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void pFpppccci(x64emu_t *emu, uintptr_t fcn) { pFpppccci_t fn = (pFpppccci_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int8_t)R_RCX, (int8_t)R_R8, (int8_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void pFpppiiii(x64emu_t *emu, uintptr_t fcn) { pFpppiiii_t fn = (pFpppiiii_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void pFpppiipp(x64emu_t *emu, uintptr_t fcn) { pFpppiipp_t fn = (pFpppiipp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void pFpppIIIi(x64emu_t *emu, uintptr_t fcn) { pFpppIIIi_t fn = (pFpppIIIi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void pFpppCCCi(x64emu_t *emu, uintptr_t fcn) { pFpppCCCi_t fn = (pFpppCCCi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint8_t)R_RCX, (uint8_t)R_R8, (uint8_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void pFpppuuui(x64emu_t *emu, uintptr_t fcn) { pFpppuuui_t fn = (pFpppuuui_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void pFpppuupp(x64emu_t *emu, uintptr_t fcn) { pFpppuupp_t fn = (pFpppuupp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void pFpppUUUi(x64emu_t *emu, uintptr_t fcn) { pFpppUUUi_t fn = (pFpppUUUi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void pFpppfffi(x64emu_t *emu, uintptr_t fcn) { pFpppfffi_t fn = (pFpppfffi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0], (int64_t)R_RCX); }
-void pFpppdddi(x64emu_t *emu, uintptr_t fcn) { pFpppdddi_t fn = (pFpppdddi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], (int64_t)R_RCX); }
-void pFpppllli(x64emu_t *emu, uintptr_t fcn) { pFpppllli_t fn = (pFpppllli_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8, (intptr_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void pFpppLLLi(x64emu_t *emu, uintptr_t fcn) { pFpppLLLi_t fn = (pFpppLLLi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uintptr_t)R_RCX, (uintptr_t)R_R8, (uintptr_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void pFppppuuu(x64emu_t *emu, uintptr_t fcn) { pFppppuuu_t fn = (pFppppuuu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8)); }
-void pFpppppuu(x64emu_t *emu, uintptr_t fcn) { pFpppppuu_t fn = (pFpppppuu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8)); }
-void pFppppppi(x64emu_t *emu, uintptr_t fcn) { pFppppppi_t fn = (pFppppppi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8)); }
-void pFppppppp(x64emu_t *emu, uintptr_t fcn) { pFppppppp_t fn = (pFppppppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void iWpiiuuuu(x64emu_t *emu, uintptr_t fcn) { iWpiiuuuu_t fn = (iWpiiuuuu_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (int64_t)R_RDX, (int64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 40), *(uint64_t*)(R_RSP + 48), *(uint64_t*)(R_RSP + 56)); }
-void iWpuiiiip(x64emu_t *emu, uintptr_t fcn) { iWpuiiiip_t fn = (iWpuiiiip_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (uint64_t)R_RDX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 40), *(int64_t*)(R_RSP + 48), *(void**)(R_RSP + 56)); }
-void iWpuiiuii(x64emu_t *emu, uintptr_t fcn) { iWpuiiuii_t fn = (iWpuiiuii_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (uint64_t)R_RDX, (int64_t)R_R8, (int64_t)R_R9, *(uint64_t*)(R_RSP + 40), *(int64_t*)(R_RSP + 48), *(int64_t*)(R_RSP + 56)); }
-void iWpuipupp(x64emu_t *emu, uintptr_t fcn) { iWpuipupp_t fn = (iWpuipupp_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (uint64_t)R_RDX, (int64_t)R_R8, (void*)R_R9, *(uint64_t*)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56)); }
-void iWpuuuppu(x64emu_t *emu, uintptr_t fcn) { iWpuuuppu_t fn = (iWpuuuppu_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (uint64_t)R_RDX, (uint64_t)R_R8, (uint64_t)R_R9, *(void**)(R_RSP + 40), *(void**)(R_RSP + 48), *(uint64_t*)(R_RSP + 56)); }
-void iWpupuufu(x64emu_t *emu, uintptr_t fcn) { iWpupuufu_t fn = (iWpupuufu_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (uint64_t)R_RDX, (void*)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 40), *(float*)(R_RSP + 48), *(uint64_t*)(R_RSP + 56)); }
-void iWpppuppp(x64emu_t *emu, uintptr_t fcn) { iWpppuppp_t fn = (iWpppuppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (void*)R_RDX, (void*)R_R8, (uint64_t)R_R9, *(void**)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56)); }
-void vFEiippppV(x64emu_t *emu, uintptr_t fcn) { vFEiippppV_t fn = (vFEiippppV_t)fcn; fn(emu, (int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, (void*)(R_RSP + 8)); }
-void vFEiupippp(x64emu_t *emu, uintptr_t fcn) { vFEiupippp_t fn = (vFEiupippp_t)fcn; fn(emu, (int64_t)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void vFEipAippp(x64emu_t *emu, uintptr_t fcn) { vFEipAippp_t fn = (vFEipAippp_t)fcn; fn(emu, (int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void vFEppipppp(x64emu_t *emu, uintptr_t fcn) { vFEppipppp_t fn = (vFEppipppp_t)fcn; fn(emu, (void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void vFEpppippp(x64emu_t *emu, uintptr_t fcn) { vFEpppippp_t fn = (vFEpppippp_t)fcn; fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void vFEpppuipV(x64emu_t *emu, uintptr_t fcn) { vFEpppuipV_t fn = (vFEpppuipV_t)fcn; fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (void*)R_R9, (void*)(R_RSP + 8)); }
-void vFEpppppuu(x64emu_t *emu, uintptr_t fcn) { vFEpppppuu_t fn = (vFEpppppuu_t)fcn; fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8)); }
-void vFiiiiuuip(x64emu_t *emu, uintptr_t fcn) { vFiiiiuuip_t fn = (vFiiiiuuip_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(int64_t*)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void vFiilliilp(x64emu_t *emu, uintptr_t fcn) { vFiilliilp_t fn = (vFiilliilp_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (intptr_t)R_RDX, (intptr_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(intptr_t*)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void vFililliuU(x64emu_t *emu, uintptr_t fcn) { vFililliuU_t fn = (vFililliuU_t)fcn; fn((int64_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8, (int64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16)); }
-void vFilillluU(x64emu_t *emu, uintptr_t fcn) { vFilillluU_t fn = (vFilillluU_t)fcn; fn((int64_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8, (intptr_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16)); }
-void vFilipufip(x64emu_t *emu, uintptr_t fcn) { vFilipufip_t fn = (vFilipufip_t)fcn; fn((int64_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (uint64_t)R_R8, emu->xmm[0].f[0], (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void vFuiiiiiii(x64emu_t *emu, uintptr_t fcn) { vFuiiiiiii_t fn = (vFuiiiiiii_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void vFuiiiiill(x64emu_t *emu, uintptr_t fcn) { vFuiiiiill_t fn = (vFuiiiiill_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(intptr_t*)(R_RSP + 8), *(intptr_t*)(R_RSP + 16)); }
-void vFuiiiiuup(x64emu_t *emu, uintptr_t fcn) { vFuiiiiuup_t fn = (vFuiiiiuup_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void vFuiuiiiii(x64emu_t *emu, uintptr_t fcn) { vFuiuiiiii_t fn = (vFuiuiiiii_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void vFuiuiiiip(x64emu_t *emu, uintptr_t fcn) { vFuiuiiiip_t fn = (vFuiuiiiip_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void vFuiuiuuuu(x64emu_t *emu, uintptr_t fcn) { vFuiuiuuuu_t fn = (vFuiuiuuuu_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16)); }
-void vFuiulplpp(x64emu_t *emu, uintptr_t fcn) { vFuiulplpp_t fn = (vFuiulplpp_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (intptr_t)R_RCX, (void*)R_R8, (intptr_t)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void vFuipuliuf(x64emu_t *emu, uintptr_t fcn) { vFuipuliuf_t fn = (vFuipuliuf_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (intptr_t)R_R8, (int64_t)R_R9, *(uint64_t*)(R_RSP + 8), emu->xmm[0].f[0]); }
-void vFuuiiiiii(x64emu_t *emu, uintptr_t fcn) { vFuuiiiiii_t fn = (vFuuiiiiii_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void vFuuiiiuip(x64emu_t *emu, uintptr_t fcn) { vFuuiiiuip_t fn = (vFuuiiiuip_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (uint64_t)R_R9, *(int64_t*)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void vFuuiiiuup(x64emu_t *emu, uintptr_t fcn) { vFuuiiiuup_t fn = (vFuuiiiuup_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void vFuuiiuupp(x64emu_t *emu, uintptr_t fcn) { vFuuiiuupp_t fn = (vFuuiiuupp_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void vFuuiuiiii(x64emu_t *emu, uintptr_t fcn) { vFuuiuiiii_t fn = (vFuuiuiiii_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void vFuuiuiiip(x64emu_t *emu, uintptr_t fcn) { vFuuiuiiip_t fn = (vFuuiuiiip_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void vFuuuiiiii(x64emu_t *emu, uintptr_t fcn) { vFuuuiiiii_t fn = (vFuuuiiiii_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void vFuuuiuiii(x64emu_t *emu, uintptr_t fcn) { vFuuuiuiii_t fn = (vFuuuiuiii_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void vFuuuipipp(x64emu_t *emu, uintptr_t fcn) { vFuuuipipp_t fn = (vFuuuipipp_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void vFuuuuuuuu(x64emu_t *emu, uintptr_t fcn) { vFuuuuuuuu_t fn = (vFuuuuuuuu_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16)); }
-void vFuuuuufff(x64emu_t *emu, uintptr_t fcn) { vFuuuuufff_t fn = (vFuuuuufff_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0]); }
-void vFuuufffff(x64emu_t *emu, uintptr_t fcn) { vFuuufffff_t fn = (vFuuufffff_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0], emu->xmm[3].f[0], emu->xmm[4].f[0]); }
-void vFulilliuU(x64emu_t *emu, uintptr_t fcn) { vFulilliuU_t fn = (vFulilliuU_t)fcn; fn((uint64_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8, (int64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16)); }
-void vFulillluU(x64emu_t *emu, uintptr_t fcn) { vFulillluU_t fn = (vFulillluU_t)fcn; fn((uint64_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8, (intptr_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16)); }
-void vFulllplip(x64emu_t *emu, uintptr_t fcn) { vFulllplip_t fn = (vFulllplip_t)fcn; fn((uint64_t)R_RDI, (intptr_t)R_RSI, (intptr_t)R_RDX, (intptr_t)R_RCX, (void*)R_R8, (intptr_t)R_R9, *(int64_t*)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void vFffffffff(x64emu_t *emu, uintptr_t fcn) { vFffffffff_t fn = (vFffffffff_t)fcn; fn(emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0], emu->xmm[3].f[0], emu->xmm[4].f[0], emu->xmm[5].f[0], emu->xmm[6].f[0], emu->xmm[7].f[0]); }
-void vFlipuiuip(x64emu_t *emu, uintptr_t fcn) { vFlipuiuip_t fn = (vFlipuiuip_t)fcn; fn((intptr_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (uint64_t)R_R9, *(int64_t*)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void vFpiiiiiii(x64emu_t *emu, uintptr_t fcn) { vFpiiiiiii_t fn = (vFpiiiiiii_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void vFpiiiipii(x64emu_t *emu, uintptr_t fcn) { vFpiiiipii_t fn = (vFpiiiipii_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void vFpiiULipp(x64emu_t *emu, uintptr_t fcn) { vFpiiULipp_t fn = (vFpiiULipp_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (uintptr_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void vFpiUuupup(x64emu_t *emu, uintptr_t fcn) { vFpiUuupup_t fn = (vFpiUuupup_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (void*)R_R9, *(uint64_t*)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void vFpippiiuu(x64emu_t *emu, uintptr_t fcn) { vFpippiiuu_t fn = (vFpippiiuu_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16)); }
-void vFpippiipi(x64emu_t *emu, uintptr_t fcn) { vFpippiipi_t fn = (vFpippiipi_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void vFpuppLLLL(x64emu_t *emu, uintptr_t fcn) { vFpuppLLLL_t fn = (vFpuppLLLL_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (uintptr_t)R_R8, (uintptr_t)R_R9, *(uintptr_t*)(R_RSP + 8), *(uintptr_t*)(R_RSP + 16)); }
-void vFpUiUiupi(x64emu_t *emu, uintptr_t fcn) { vFpUiUiupi_t fn = (vFpUiUiupi_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (uint64_t)R_R9, *(void**)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void vFpUuuUUUi(x64emu_t *emu, uintptr_t fcn) { vFpUuuUUUi_t fn = (vFpUuuUUUi_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void vFppiiiiii(x64emu_t *emu, uintptr_t fcn) { vFppiiiiii_t fn = (vFppiiiiii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void vFppiiipii(x64emu_t *emu, uintptr_t fcn) { vFppiiipii_t fn = (vFppiiipii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void vFppipipii(x64emu_t *emu, uintptr_t fcn) { vFppipipii_t fn = (vFppipipii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void vFppipppui(x64emu_t *emu, uintptr_t fcn) { vFppipppui_t fn = (vFppipppui_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(uint64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void vFppippppi(x64emu_t *emu, uintptr_t fcn) { vFppippppi_t fn = (vFppippppi_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void vFppippppp(x64emu_t *emu, uintptr_t fcn) { vFppippppp_t fn = (vFppippppp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void vFpplppppi(x64emu_t *emu, uintptr_t fcn) { vFpplppppi_t fn = (vFpplppppi_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (intptr_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void vFpplppppp(x64emu_t *emu, uintptr_t fcn) { vFpplppppp_t fn = (vFpplppppp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (intptr_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void vFppppiipi(x64emu_t *emu, uintptr_t fcn) { vFppppiipi_t fn = (vFppppiipi_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void vFpppppuuu(x64emu_t *emu, uintptr_t fcn) { vFpppppuuu_t fn = (vFpppppuuu_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16)); }
-void vFpppppppp(x64emu_t *emu, uintptr_t fcn) { vFpppppppp_t fn = (vFpppppppp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void iFEpippppp(x64emu_t *emu, uintptr_t fcn) { iFEpippppp_t fn = (iFEpippppp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void iFEpuuLppp(x64emu_t *emu, uintptr_t fcn) { iFEpuuLppp_t fn = (iFEpuuLppp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uintptr_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void iFEpUUuppp(x64emu_t *emu, uintptr_t fcn) { iFEpUUuppp_t fn = (iFEpUUuppp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void iFEppipppp(x64emu_t *emu, uintptr_t fcn) { iFEppipppp_t fn = (iFEppipppp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void iFEppppipp(x64emu_t *emu, uintptr_t fcn) { iFEppppipp_t fn = (iFEppppipp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void iFiiiiiiip(x64emu_t *emu, uintptr_t fcn) { iFiiiiiiip_t fn = (iFiiiiiiip_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void iFiiupiupi(x64emu_t *emu, uintptr_t fcn) { iFiiupiupi_t fn = (iFiiupiupi_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8, (uint64_t)R_R9, *(void**)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void iFipippppp(x64emu_t *emu, uintptr_t fcn) { iFipippppp_t fn = (iFipippppp_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void iFuipuuluf(x64emu_t *emu, uintptr_t fcn) { iFuipuuluf_t fn = (iFuipuuluf_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (intptr_t)R_R9, *(uint64_t*)(R_RSP + 8), emu->xmm[0].f[0]); }
-void iFuuuuuuuu(x64emu_t *emu, uintptr_t fcn) { iFuuuuuuuu_t fn = (iFuuuuuuuu_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16)); }
-void iFullfpppp(x64emu_t *emu, uintptr_t fcn) { iFullfpppp_t fn = (iFullfpppp_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (intptr_t)R_RSI, (intptr_t)R_RDX, emu->xmm[0].f[0], (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void iFpippuuii(x64emu_t *emu, uintptr_t fcn) { iFpippuuii_t fn = (iFpippuuii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void iFpCCWWpWu(x64emu_t *emu, uintptr_t fcn) { iFpCCWWpWu_t fn = (iFpCCWWpWu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint8_t)R_RSI, (uint8_t)R_RDX, (uint16_t)R_RCX, (uint16_t)R_R8, (void*)R_R9, *(uint16_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16)); }
-void iFpWCuWCuu(x64emu_t *emu, uintptr_t fcn) { iFpWCuWCuu_t fn = (iFpWCuWCuu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint16_t)R_RSI, (uint8_t)R_RDX, (uint64_t)R_RCX, (uint16_t)R_R8, (uint8_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16)); }
-void iFpWWipppp(x64emu_t *emu, uintptr_t fcn) { iFpWWipppp_t fn = (iFpWWipppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint16_t)R_RSI, (uint16_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void iFpuiipppp(x64emu_t *emu, uintptr_t fcn) { iFpuiipppp_t fn = (iFpuiipppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void iFpuippLpp(x64emu_t *emu, uintptr_t fcn) { iFpuippLpp_t fn = (iFpuippLpp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (uintptr_t)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void iFpuuiiiii(x64emu_t *emu, uintptr_t fcn) { iFpuuiiiii_t fn = (iFpuuiiiii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void iFpuuupupu(x64emu_t *emu, uintptr_t fcn) { iFpuuupupu_t fn = (iFpuuupupu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8, (uint64_t)R_R9, *(void**)(R_RSP + 8), *(uint64_t*)(R_RSP + 16)); }
-void iFpupppWWu(x64emu_t *emu, uintptr_t fcn) { iFpupppWWu_t fn = (iFpupppWWu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (uint16_t)R_R9, *(uint16_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16)); }
-void iFpupppppp(x64emu_t *emu, uintptr_t fcn) { iFpupppppp_t fn = (iFpupppppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void iFpUuuLpUi(x64emu_t *emu, uintptr_t fcn) { iFpUuuLpUi_t fn = (iFpUuuLpUi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uintptr_t)R_R8, (void*)R_R9, *(uint64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void iFpdiiiIiI(x64emu_t *emu, uintptr_t fcn) { iFpdiiiIiI_t fn = (iFpdiiiIiI_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, emu->xmm[0].d[0], (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void iFpLpipppp(x64emu_t *emu, uintptr_t fcn) { iFpLpipppp_t fn = (iFpLpipppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uintptr_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void iFppiiiiiu(x64emu_t *emu, uintptr_t fcn) { iFppiiiiiu_t fn = (iFppiiiiiu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16)); }
-void iFppiiipip(x64emu_t *emu, uintptr_t fcn) { iFppiiipip_t fn = (iFppiiipip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void iFppIIIppp(x64emu_t *emu, uintptr_t fcn) { iFppIIIppp_t fn = (iFppIIIppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void iFpppiiipi(x64emu_t *emu, uintptr_t fcn) { iFpppiiipi_t fn = (iFpppiiipi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void iFpppiippp(x64emu_t *emu, uintptr_t fcn) { iFpppiippp_t fn = (iFpppiippp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void iFpppipipi(x64emu_t *emu, uintptr_t fcn) { iFpppipipi_t fn = (iFpppipipi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void iFppppiipi(x64emu_t *emu, uintptr_t fcn) { iFppppiipi_t fn = (iFppppiipi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void iFppppippp(x64emu_t *emu, uintptr_t fcn) { iFppppippp_t fn = (iFppppippp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void iFppppppii(x64emu_t *emu, uintptr_t fcn) { iFppppppii_t fn = (iFppppppii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void iFpppppppi(x64emu_t *emu, uintptr_t fcn) { iFpppppppi_t fn = (iFpppppppi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void iFpppppppp(x64emu_t *emu, uintptr_t fcn) { iFpppppppp_t fn = (iFpppppppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void uFEipipppp(x64emu_t *emu, uintptr_t fcn) { uFEipipppp_t fn = (uFEipipppp_t)fcn; R_RAX=(uint64_t)fn(emu, (int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void uFEpiupppp(x64emu_t *emu, uintptr_t fcn) { uFEpiupppp_t fn = (uFEpiupppp_t)fcn; R_RAX=(uint64_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void uFEppipppp(x64emu_t *emu, uintptr_t fcn) { uFEppipppp_t fn = (uFEppipppp_t)fcn; R_RAX=(uint64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void uFEpppuppp(x64emu_t *emu, uintptr_t fcn) { uFEpppuppp_t fn = (uFEpppuppp_t)fcn; R_RAX=(uint64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void uFEppppppp(x64emu_t *emu, uintptr_t fcn) { uFEppppppp_t fn = (uFEppppppp_t)fcn; R_RAX=(uint64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void uFuipppppp(x64emu_t *emu, uintptr_t fcn) { uFuipppppp_t fn = (uFuipppppp_t)fcn; R_RAX=(uint64_t)fn((uint64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void uFulpppppp(x64emu_t *emu, uintptr_t fcn) { uFulpppppp_t fn = (uFulpppppp_t)fcn; R_RAX=(uint64_t)fn((uint64_t)R_RDI, (intptr_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void uFpupuuuCp(x64emu_t *emu, uintptr_t fcn) { uFpupuuuCp_t fn = (uFpupuuuCp_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint8_t*)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void uFppuuuupp(x64emu_t *emu, uintptr_t fcn) { uFppuuuupp_t fn = (uFppuuuupp_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void uFppuuuppi(x64emu_t *emu, uintptr_t fcn) { uFppuuuppi_t fn = (uFppuuuppi_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void uFppuppppp(x64emu_t *emu, uintptr_t fcn) { uFppuppppp_t fn = (uFppuppppp_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void LFELpLpLpi(x64emu_t *emu, uintptr_t fcn) { LFELpLpLpi_t fn = (LFELpLpLpi_t)fcn; R_RAX=(uintptr_t)fn(emu, (uintptr_t)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX, (uintptr_t)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8)); }
-void LFEpiupppp(x64emu_t *emu, uintptr_t fcn) { LFEpiupppp_t fn = (LFEpiupppp_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void pFEiplllpp(x64emu_t *emu, uintptr_t fcn) { pFEiplllpp_t fn = (pFEiplllpp_t)fcn; R_RAX=(uintptr_t)fn(emu, (int64_t)R_RDI, (void*)R_RSI, (intptr_t)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void pFEpiuCppp(x64emu_t *emu, uintptr_t fcn) { pFEpiuCppp_t fn = (pFEpiuCppp_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (uint8_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void pFEppLiiip(x64emu_t *emu, uintptr_t fcn) { pFEppLiiip_t fn = (pFEppLiiip_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void pFEpppuipV(x64emu_t *emu, uintptr_t fcn) { pFEpppuipV_t fn = (pFEpppuipV_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (void*)R_R9, (void*)(R_RSP + 8)); }
-void pFEpppppiV(x64emu_t *emu, uintptr_t fcn) { pFEpppppiV_t fn = (pFEpppppiV_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (int64_t)R_R9, (void*)(R_RSP + 8)); }
-void pFEppppppi(x64emu_t *emu, uintptr_t fcn) { pFEppppppi_t fn = (pFEppppppi_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8)); }
-void pFEppppppp(x64emu_t *emu, uintptr_t fcn) { pFEppppppp_t fn = (pFEppppppp_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void pFiipppppp(x64emu_t *emu, uintptr_t fcn) { pFiipppppp_t fn = (pFiipppppp_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void pFuiiiuuuu(x64emu_t *emu, uintptr_t fcn) { pFuiiiuuuu_t fn = (pFuiiiuuuu_t)fcn; R_RAX=(uintptr_t)fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16)); }
-void pFuupupipp(x64emu_t *emu, uintptr_t fcn) { pFuupupipp_t fn = (pFuupupipp_t)fcn; R_RAX=(uintptr_t)fn((uint64_t)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (void*)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void pFpiiiiiuu(x64emu_t *emu, uintptr_t fcn) { pFpiiiiiuu_t fn = (pFpiiiiiuu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16)); }
-void pFpiUdiiUi(x64emu_t *emu, uintptr_t fcn) { pFpiUdiiUi_t fn = (pFpiUdiiUi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, emu->xmm[0].d[0], (int64_t)R_RCX, (int64_t)R_R8, (uint64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void pFpipiiiip(x64emu_t *emu, uintptr_t fcn) { pFpipiiiip_t fn = (pFpipiiiip_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void pFpipppppp(x64emu_t *emu, uintptr_t fcn) { pFpipppppp_t fn = (pFpipppppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void pFpCCuuwwC(x64emu_t *emu, uintptr_t fcn) { pFpCCuuwwC_t fn = (pFpCCuuwwC_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint8_t)R_RSI, (uint8_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (int16_t)R_R9, *(int16_t*)(R_RSP + 8), *(uint8_t*)(R_RSP + 16)); }
-void pFpCuwwWWu(x64emu_t *emu, uintptr_t fcn) { pFpCuwwWWu_t fn = (pFpCuwwWWu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint8_t)R_RSI, (uint64_t)R_RDX, (int16_t)R_RCX, (int16_t)R_R8, (uint16_t)R_R9, *(uint16_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16)); }
-void pFpCuuuCup(x64emu_t *emu, uintptr_t fcn) { pFpCuuuCup_t fn = (pFpCuuuCup_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint8_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint8_t)R_R9, *(uint64_t*)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void pFpWWiCpup(x64emu_t *emu, uintptr_t fcn) { pFpWWiCpup_t fn = (pFpWWiCpup_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint16_t)R_RSI, (uint16_t)R_RDX, (int64_t)R_RCX, (uint8_t)R_R8, (void*)R_R9, *(uint64_t*)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void pFpuuWWCuu(x64emu_t *emu, uintptr_t fcn) { pFpuuWWCuu_t fn = (pFpuuWWCuu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint16_t)R_RCX, (uint16_t)R_R8, (uint8_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16)); }
-void pFpuuuuupp(x64emu_t *emu, uintptr_t fcn) { pFpuuuuupp_t fn = (pFpuuuuupp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void pFpuuuupup(x64emu_t *emu, uintptr_t fcn) { pFpuuuupup_t fn = (pFpuuuupup_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (void*)R_R9, *(uint64_t*)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void pFpuuupwwp(x64emu_t *emu, uintptr_t fcn) { pFpuuupwwp_t fn = (pFpuuupwwp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8, (int16_t)R_R9, *(int16_t*)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void pFpdwwWWui(x64emu_t *emu, uintptr_t fcn) { pFpdwwWWui_t fn = (pFpdwwWWui_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, emu->xmm[0].d[0], (int16_t)R_RSI, (int16_t)R_RDX, (uint16_t)R_RCX, (uint16_t)R_R8, (uint64_t)R_R9, *(int64_t*)(R_RSP + 8)); }
-void pFplpppppp(x64emu_t *emu, uintptr_t fcn) { pFplpppppp_t fn = (pFplpppppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (intptr_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void pFppiiiiii(x64emu_t *emu, uintptr_t fcn) { pFppiiiiii_t fn = (pFppiiiiii_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void pFpppuuLLu(x64emu_t *emu, uintptr_t fcn) { pFpppuuLLu_t fn = (pFpppuuLLu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uintptr_t)R_R9, *(uintptr_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16)); }
-void pFpppppupp(x64emu_t *emu, uintptr_t fcn) { pFpppppupp_t fn = (pFpppppupp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (uint64_t)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void iWEpuuiipp(x64emu_t *emu, uintptr_t fcn) { iWEpuuiipp_t fn = (iWEpuuiipp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RCX, (uint64_t)R_RDX, (uint64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56)); }
-void iWEpuuuipp(x64emu_t *emu, uintptr_t fcn) { iWEpuuuipp_t fn = (iWEpuuuipp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RCX, (uint64_t)R_RDX, (uint64_t)R_R8, (uint64_t)R_R9, *(int64_t*)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56)); }
-void iWpuipuppp(x64emu_t *emu, uintptr_t fcn) { iWpuipuppp_t fn = (iWpuipuppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (uint64_t)R_RDX, (int64_t)R_R8, (void*)R_R9, *(uint64_t*)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56), *(void**)(R_RSP + 64)); }
-void vFEpiiiiipp(x64emu_t *emu, uintptr_t fcn) { vFEpiiiiipp_t fn = (vFEpiiiiipp_t)fcn; fn(emu, (void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void vFEpippippV(x64emu_t *emu, uintptr_t fcn) { vFEpippippV_t fn = (vFEpippippV_t)fcn; fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), (void*)(R_RSP + 16)); }
-void vFEpippippA(x64emu_t *emu, uintptr_t fcn) { vFEpippippA_t fn = (vFEpippippA_t)fcn; fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void vFEpuuuippp(x64emu_t *emu, uintptr_t fcn) { vFEpuuuippp_t fn = (vFEpuuuippp_t)fcn; fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void vFEppiipppp(x64emu_t *emu, uintptr_t fcn) { vFEppiipppp_t fn = (vFEppiipppp_t)fcn; fn(emu, (void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void vFEpppiippp(x64emu_t *emu, uintptr_t fcn) { vFEpppiippp_t fn = (vFEpppiippp_t)fcn; fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void vFEppppippp(x64emu_t *emu, uintptr_t fcn) { vFEppppippp_t fn = (vFEppppippp_t)fcn; fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void vFiiiiiiiii(x64emu_t *emu, uintptr_t fcn) { vFiiiiiiiii_t fn = (vFiiiiiiiii_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24)); }
-void vFiiiiiiill(x64emu_t *emu, uintptr_t fcn) { vFiiiiiiill_t fn = (vFiiiiiiill_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(intptr_t*)(R_RSP + 16), *(intptr_t*)(R_RSP + 24)); }
-void vFiiiiillli(x64emu_t *emu, uintptr_t fcn) { vFiiiiillli_t fn = (vFiiiiillli_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (intptr_t)R_R9, *(intptr_t*)(R_RSP + 8), *(intptr_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24)); }
-void vFiiilllilp(x64emu_t *emu, uintptr_t fcn) { vFiiilllilp_t fn = (vFiiilllilp_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8, (intptr_t)R_R9, *(int64_t*)(R_RSP + 8), *(intptr_t*)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void vFilillliuU(x64emu_t *emu, uintptr_t fcn) { vFilillliuU_t fn = (vFilillliuU_t)fcn; fn((int64_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8, (intptr_t)R_R9, *(int64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24)); }
-void vFuiiiiiiii(x64emu_t *emu, uintptr_t fcn) { vFuiiiiiiii_t fn = (vFuiiiiiiii_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24)); }
-void vFuiiiiiuip(x64emu_t *emu, uintptr_t fcn) { vFuiiiiiuip_t fn = (vFuiiiiiuip_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void vFuiiiiiuup(x64emu_t *emu, uintptr_t fcn) { vFuiiiiiuup_t fn = (vFuiiiiiuup_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void vFuiiiillli(x64emu_t *emu, uintptr_t fcn) { vFuiiiillli_t fn = (vFuiiiillli_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (intptr_t)R_R9, *(intptr_t*)(R_RSP + 8), *(intptr_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24)); }
-void vFuiiilliip(x64emu_t *emu, uintptr_t fcn) { vFuiiilliip_t fn = (vFuiiilliip_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (intptr_t)R_R8, (intptr_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void vFuiiillilp(x64emu_t *emu, uintptr_t fcn) { vFuiiillilp_t fn = (vFuiiillilp_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (intptr_t)R_R8, (intptr_t)R_R9, *(int64_t*)(R_RSP + 8), *(intptr_t*)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void vFuiuiiiiip(x64emu_t *emu, uintptr_t fcn) { vFuiuiiiiip_t fn = (vFuiuiiiiip_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void vFuuiiiiiii(x64emu_t *emu, uintptr_t fcn) { vFuuiiiiiii_t fn = (vFuuiiiiiii_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24)); }
-void vFuuiuiiiii(x64emu_t *emu, uintptr_t fcn) { vFuuiuiiiii_t fn = (vFuuiuiiiii_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24)); }
-void vFuuiuiiiip(x64emu_t *emu, uintptr_t fcn) { vFuuiuiiiip_t fn = (vFuuiuiiiip_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void vFuuiuiiuup(x64emu_t *emu, uintptr_t fcn) { vFuuiuiiuup_t fn = (vFuuiuiiuup_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void vFuuuiiiiip(x64emu_t *emu, uintptr_t fcn) { vFuuuiiiiip_t fn = (vFuuuiiiiip_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void vFuuuuuuuuu(x64emu_t *emu, uintptr_t fcn) { vFuuuuuuuuu_t fn = (vFuuuuuuuuu_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24)); }
-void vFuffffffff(x64emu_t *emu, uintptr_t fcn) { vFuffffffff_t fn = (vFuffffffff_t)fcn; fn((uint64_t)R_RDI, emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0], emu->xmm[3].f[0], emu->xmm[4].f[0], emu->xmm[5].f[0], emu->xmm[6].f[0], emu->xmm[7].f[0]); }
-void vFulillliuU(x64emu_t *emu, uintptr_t fcn) { vFulillliuU_t fn = (vFulillliuU_t)fcn; fn((uint64_t)R_RDI, (intptr_t)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8, (intptr_t)R_R9, *(int64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24)); }
-void vFffuuuufff(x64emu_t *emu, uintptr_t fcn) { vFffuuuufff_t fn = (vFffuuuufff_t)fcn; fn(emu->xmm[0].f[0], emu->xmm[1].f[0], (uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, emu->xmm[2].f[0], emu->xmm[3].f[0], emu->xmm[4].f[0]); }
-void vFddddddddd(x64emu_t *emu, uintptr_t fcn) { vFddddddddd_t fn = (vFddddddddd_t)fcn; fn(emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0], emu->xmm[4].d[0], emu->xmm[5].d[0], emu->xmm[6].d[0], emu->xmm[7].d[0], *(double*)(R_RSP + 8)); }
-void vFlipuiuiip(x64emu_t *emu, uintptr_t fcn) { vFlipuiuiip_t fn = (vFlipuiuiip_t)fcn; fn((intptr_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (uint64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void vFpipiuiipp(x64emu_t *emu, uintptr_t fcn) { vFpipiuiipp_t fn = (vFpipiuiipp_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void vFpipippppi(x64emu_t *emu, uintptr_t fcn) { vFpipippppi_t fn = (vFpipippppi_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(int64_t*)(R_RSP + 24)); }
-void vFpipppiipi(x64emu_t *emu, uintptr_t fcn) { vFpipppiipi_t fn = (vFpipppiipi_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(void**)(R_RSP + 16), *(int64_t*)(R_RSP + 24)); }
-void vFppiiiiiii(x64emu_t *emu, uintptr_t fcn) { vFppiiiiiii_t fn = (vFppiiiiiii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24)); }
-void vFppiiiiipi(x64emu_t *emu, uintptr_t fcn) { vFppiiiiipi_t fn = (vFppiiiiipi_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(void**)(R_RSP + 16), *(int64_t*)(R_RSP + 24)); }
-void vFppiiipiii(x64emu_t *emu, uintptr_t fcn) { vFppiiipiii_t fn = (vFppiiipiii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24)); }
-void vFppiipiiii(x64emu_t *emu, uintptr_t fcn) { vFppiipiiii_t fn = (vFppiipiiii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24)); }
-void vFppipppiii(x64emu_t *emu, uintptr_t fcn) { vFppipppiii_t fn = (vFppipppiii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24)); }
-void vFppipppiip(x64emu_t *emu, uintptr_t fcn) { vFppipppiip_t fn = (vFppipppiip_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void vFppuuiiiii(x64emu_t *emu, uintptr_t fcn) { vFppuuiiiii_t fn = (vFppuuiiiii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24)); }
-void vFppUUiUUUU(x64emu_t *emu, uintptr_t fcn) { vFppUUiUUUU_t fn = (vFppUUiUUUU_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24)); }
-void vFppddddidd(x64emu_t *emu, uintptr_t fcn) { vFppddddidd_t fn = (vFppddddidd_t)fcn; fn((void*)R_RDI, (void*)R_RSI, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0], (int64_t)R_RDX, emu->xmm[4].d[0], emu->xmm[5].d[0]); }
-void vFpplpppppi(x64emu_t *emu, uintptr_t fcn) { vFpplpppppi_t fn = (vFpplpppppi_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (intptr_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(int64_t*)(R_RSP + 24)); }
-void vFpppiiiiii(x64emu_t *emu, uintptr_t fcn) { vFpppiiiiii_t fn = (vFpppiiiiii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24)); }
-void vFppppipiip(x64emu_t *emu, uintptr_t fcn) { vFppppipiip_t fn = (vFppppipiip_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void vFpppppippp(x64emu_t *emu, uintptr_t fcn) { vFpppppippp_t fn = (vFpppppippp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void iFEpiiiiipi(x64emu_t *emu, uintptr_t fcn) { iFEpiiiiipi_t fn = (iFEpiiiiipi_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void iFEpppipppp(x64emu_t *emu, uintptr_t fcn) { iFEpppipppp_t fn = (iFEpppipppp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void iFEppplPPPP(x64emu_t *emu, uintptr_t fcn) { iFEppplPPPP_t fn = (iFEppplPPPP_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (intptr_t)R_RCX, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32)); }
-void iFEpppppupp(x64emu_t *emu, uintptr_t fcn) { iFEpppppupp_t fn = (iFEpppppupp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (uint64_t)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void iFEppPPPPPP(x64emu_t *emu, uintptr_t fcn) { iFEppPPPPPP_t fn = (iFEppPPPPPP_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48)); }
-void iFiiiiiiiip(x64emu_t *emu, uintptr_t fcn) { iFiiiiiiiip_t fn = (iFiiiiiiiip_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void iFiiiipiiip(x64emu_t *emu, uintptr_t fcn) { iFiiiipiiip_t fn = (iFiiiipiiip_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void iFipiipippi(x64emu_t *emu, uintptr_t fcn) { iFipiipippi_t fn = (iFipiipippi_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(int64_t*)(R_RSP + 24)); }
-void iFuilpluluf(x64emu_t *emu, uintptr_t fcn) { iFuilpluluf_t fn = (iFuilpluluf_t)fcn; R_RAX=(int64_t)fn((uint64_t)R_RDI, (int64_t)R_RSI, (intptr_t)R_RDX, (void*)R_RCX, (intptr_t)R_R8, (uint64_t)R_R9, *(intptr_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), emu->xmm[0].f[0]); }
-void iFdddpppppp(x64emu_t *emu, uintptr_t fcn) { iFdddpppppp_t fn = (iFdddpppppp_t)fcn; R_RAX=(int64_t)fn(emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFpipLpiiip(x64emu_t *emu, uintptr_t fcn) { iFpipLpiiip_t fn = (iFpipLpiiip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (uintptr_t)R_RCX, (void*)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void iFpuuuuuuuu(x64emu_t *emu, uintptr_t fcn) { iFpuuuuuuuu_t fn = (iFpuuuuuuuu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24)); }
-void iFpdiiiUiUp(x64emu_t *emu, uintptr_t fcn) { iFpdiiiUiUp_t fn = (iFpdiiiUiUp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, emu->xmm[0].d[0], (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (int64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void iFppiiiiiii(x64emu_t *emu, uintptr_t fcn) { iFppiiiiiii_t fn = (iFppiiiiiii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24)); }
-void iFppiuiippL(x64emu_t *emu, uintptr_t fcn) { iFppiuiippL_t fn = (iFppiuiippL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(uintptr_t*)(R_RSP + 24)); }
-void iFppLpiippp(x64emu_t *emu, uintptr_t fcn) { iFppLpiippp_t fn = (iFppLpiippp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uintptr_t)R_RDX, (void*)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void iFpppiiipip(x64emu_t *emu, uintptr_t fcn) { iFpppiiipip_t fn = (iFpppiiipip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void iFpppiiuuii(x64emu_t *emu, uintptr_t fcn) { iFpppiiuuii_t fn = (iFpppiiuuii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24)); }
-void iFpppiipiiu(x64emu_t *emu, uintptr_t fcn) { iFpppiipiiu_t fn = (iFpppiipiiu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24)); }
-void iFppppiiupp(x64emu_t *emu, uintptr_t fcn) { iFppppiiupp_t fn = (iFppppiiupp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void iFppppppppu(x64emu_t *emu, uintptr_t fcn) { iFppppppppu_t fn = (iFppppppppu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(uint64_t*)(R_RSP + 24)); }
-void iFppppppppp(x64emu_t *emu, uintptr_t fcn) { iFppppppppp_t fn = (iFppppppppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void uFEipippppp(x64emu_t *emu, uintptr_t fcn) { uFEipippppp_t fn = (uFEipippppp_t)fcn; R_RAX=(uint64_t)fn(emu, (int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void uFEpppufppp(x64emu_t *emu, uintptr_t fcn) { uFEpppufppp_t fn = (uFEpppufppp_t)fcn; R_RAX=(uint64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, emu->xmm[0].f[0], (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void uFppppppppp(x64emu_t *emu, uintptr_t fcn) { uFppppppppp_t fn = (uFppppppppp_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void LFEppppppii(x64emu_t *emu, uintptr_t fcn) { LFEppppppii_t fn = (LFEppppppii_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void pFEppiiuuLi(x64emu_t *emu, uintptr_t fcn) { pFEppiiuuLi_t fn = (pFEppiiuuLi_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uintptr_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void pFEppuippuu(x64emu_t *emu, uintptr_t fcn) { pFEppuippuu_t fn = (pFEppuippuu_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16)); }
-void pFEpppppiiV(x64emu_t *emu, uintptr_t fcn) { pFEpppppiiV_t fn = (pFEpppppiiV_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), (void*)(R_RSP + 16)); }
-void pFEpppppppi(x64emu_t *emu, uintptr_t fcn) { pFEpppppppi_t fn = (pFEpppppppi_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void pFEpppppppp(x64emu_t *emu, uintptr_t fcn) { pFEpppppppp_t fn = (pFEpppppppp_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void pFpiiiiuuuu(x64emu_t *emu, uintptr_t fcn) { pFpiiiiuuuu_t fn = (pFpiiiiuuuu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24)); }
-void pFpCuWCCuuu(x64emu_t *emu, uintptr_t fcn) { pFpCuWCCuuu_t fn = (pFpCuWCCuuu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint8_t)R_RSI, (uint64_t)R_RDX, (uint16_t)R_RCX, (uint8_t)R_R8, (uint8_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24)); }
-void pFpuuwwWWww(x64emu_t *emu, uintptr_t fcn) { pFpuuwwWWww_t fn = (pFpuuwwWWww_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int16_t)R_RCX, (int16_t)R_R8, (uint16_t)R_R9, *(uint16_t*)(R_RSP + 8), *(int16_t*)(R_RSP + 16), *(int16_t*)(R_RSP + 24)); }
-void pFpupuuuuup(x64emu_t *emu, uintptr_t fcn) { pFpupuuuuup_t fn = (pFpupuuuuup_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void pFppiiiiiip(x64emu_t *emu, uintptr_t fcn) { pFppiiiiiip_t fn = (pFppiiiiiip_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void pFppiiuuuLL(x64emu_t *emu, uintptr_t fcn) { pFppiiuuuLL_t fn = (pFppiiuuuLL_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uintptr_t*)(R_RSP + 16), *(uintptr_t*)(R_RSP + 24)); }
-void pFppipppppp(x64emu_t *emu, uintptr_t fcn) { pFppipppppp_t fn = (pFppipppppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void pFpppiiiiii(x64emu_t *emu, uintptr_t fcn) { pFpppiiiiii_t fn = (pFpppiiiiii_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24)); }
-void pFpppiipppp(x64emu_t *emu, uintptr_t fcn) { pFpppiipppp_t fn = (pFpppiipppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void pFpppWWWWWp(x64emu_t *emu, uintptr_t fcn) { pFpppWWWWWp_t fn = (pFpppWWWWWp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint16_t)R_RCX, (uint16_t)R_R8, (uint16_t)R_R9, *(uint16_t*)(R_RSP + 8), *(uint16_t*)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void pFpppppiipp(x64emu_t *emu, uintptr_t fcn) { pFpppppiipp_t fn = (pFpppppiipp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void pFpppppuuCC(x64emu_t *emu, uintptr_t fcn) { pFpppppuuCC_t fn = (pFpppppuuCC_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint8_t*)(R_RSP + 16), *(uint8_t*)(R_RSP + 24)); }
-void iWEpuuiippu(x64emu_t *emu, uintptr_t fcn) { iWEpuuiippu_t fn = (iWEpuuiippu_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RCX, (uint64_t)R_RDX, (uint64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56), *(uint64_t*)(R_RSP + 64)); }
-void iWEpuuuiipp(x64emu_t *emu, uintptr_t fcn) { iWEpuuuiipp_t fn = (iWEpuuuiipp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RCX, (uint64_t)R_RDX, (uint64_t)R_R8, (uint64_t)R_R9, *(int64_t*)(R_RSP + 40), *(int64_t*)(R_RSP + 48), *(void**)(R_RSP + 56), *(void**)(R_RSP + 64)); }
-void iWpiuuupipu(x64emu_t *emu, uintptr_t fcn) { iWpiuuupipu_t fn = (iWpiuuupipu_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (int64_t)R_RDX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 40), *(void**)(R_RSP + 48), *(int64_t*)(R_RSP + 56), *(void**)(R_RSP + 64), *(uint64_t*)(R_RSP + 72)); }
-void iWpuiuuipip(x64emu_t *emu, uintptr_t fcn) { iWpuiuuipip_t fn = (iWpuiuuipip_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (uint64_t)R_RDX, (int64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 40), *(int64_t*)(R_RSP + 48), *(void**)(R_RSP + 56), *(int64_t*)(R_RSP + 64), *(void**)(R_RSP + 72)); }
-void iWppppupiii(x64emu_t *emu, uintptr_t fcn) { iWppppupiii_t fn = (iWppppupiii_t)fcn; R_RAX=(int64_t)fn((void*)R_RCX, (void*)R_RDX, (void*)R_R8, (void*)R_R9, *(uint64_t*)(R_RSP + 40), *(void**)(R_RSP + 48), *(int64_t*)(R_RSP + 56), *(int64_t*)(R_RSP + 64), *(int64_t*)(R_RSP + 72)); }
-void vFEiippppppp(x64emu_t *emu, uintptr_t fcn) { vFEiippppppp_t fn = (vFEiippppppp_t)fcn; fn(emu, (int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void vFEpippppppp(x64emu_t *emu, uintptr_t fcn) { vFEpippppppp_t fn = (vFEpippppppp_t)fcn; fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void vFEpppiipppp(x64emu_t *emu, uintptr_t fcn) { vFEpppiipppp_t fn = (vFEpppiipppp_t)fcn; fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void vFiiiiiiiiii(x64emu_t *emu, uintptr_t fcn) { vFiiiiiiiiii_t fn = (vFiiiiiiiiii_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32)); }
-void vFiiiiiiiiiu(x64emu_t *emu, uintptr_t fcn) { vFiiiiiiiiiu_t fn = (vFiiiiiiiiiu_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(uint64_t*)(R_RSP + 32)); }
-void vFiiiiiiiiui(x64emu_t *emu, uintptr_t fcn) { vFiiiiiiiiui_t fn = (vFiiiiiiiiui_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32)); }
-void vFiiillliiip(x64emu_t *emu, uintptr_t fcn) { vFiiillliiip_t fn = (vFiiillliiip_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8, (intptr_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(void**)(R_RSP + 32)); }
-void vFuiiiiiiiii(x64emu_t *emu, uintptr_t fcn) { vFuiiiiiiiii_t fn = (vFuiiiiiiiii_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32)); }
-void vFuiiiiiiill(x64emu_t *emu, uintptr_t fcn) { vFuiiiiiiill_t fn = (vFuiiiiiiill_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(intptr_t*)(R_RSP + 24), *(intptr_t*)(R_RSP + 32)); }
-void vFuiiiiiiuup(x64emu_t *emu, uintptr_t fcn) { vFuiiiiiiuup_t fn = (vFuiiiiiiuup_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24), *(void**)(R_RSP + 32)); }
-void vFuiiiillllp(x64emu_t *emu, uintptr_t fcn) { vFuiiiillllp_t fn = (vFuiiiillllp_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (intptr_t)R_R9, *(intptr_t*)(R_RSP + 8), *(intptr_t*)(R_RSP + 16), *(intptr_t*)(R_RSP + 24), *(void**)(R_RSP + 32)); }
-void vFuiuiiiiuup(x64emu_t *emu, uintptr_t fcn) { vFuiuiiiiuup_t fn = (vFuiuiiiiuup_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24), *(void**)(R_RSP + 32)); }
-void vFuipulipiuf(x64emu_t *emu, uintptr_t fcn) { vFuipulipiuf_t fn = (vFuipulipiuf_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (intptr_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24), emu->xmm[0].f[0]); }
-void vFuuiiiiiiii(x64emu_t *emu, uintptr_t fcn) { vFuuiiiiiiii_t fn = (vFuuiiiiiiii_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32)); }
-void vFuuiiiiiuip(x64emu_t *emu, uintptr_t fcn) { vFuuiiiiiuip_t fn = (vFuuiiiiiuip_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(void**)(R_RSP + 32)); }
-void vFuuiiiiiuup(x64emu_t *emu, uintptr_t fcn) { vFuuiiiiiuup_t fn = (vFuuiiiiiuup_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24), *(void**)(R_RSP + 32)); }
-void vFuuiuiiiiip(x64emu_t *emu, uintptr_t fcn) { vFuuiuiiiiip_t fn = (vFuuiuiiiiip_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(void**)(R_RSP + 32)); }
-void vFuuiuiiiuup(x64emu_t *emu, uintptr_t fcn) { vFuuiuiiiuup_t fn = (vFuuiuiiiuup_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24), *(void**)(R_RSP + 32)); }
-void vFuuuuuuuiii(x64emu_t *emu, uintptr_t fcn) { vFuuuuuuuiii_t fn = (vFuuuuuuuiii_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32)); }
-void vFuuuuuuuuuu(x64emu_t *emu, uintptr_t fcn) { vFuuuuuuuuuu_t fn = (vFuuuuuuuuuu_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24), *(uint64_t*)(R_RSP + 32)); }
-void vFuffiiffiip(x64emu_t *emu, uintptr_t fcn) { vFuffiiffiip_t fn = (vFuffiiffiip_t)fcn; fn((uint64_t)R_RDI, emu->xmm[0].f[0], emu->xmm[1].f[0], (int64_t)R_RSI, (int64_t)R_RDX, emu->xmm[2].f[0], emu->xmm[3].f[0], (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9); }
-void vFuddiiddiip(x64emu_t *emu, uintptr_t fcn) { vFuddiiddiip_t fn = (vFuddiiddiip_t)fcn; fn((uint64_t)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0], (int64_t)R_RSI, (int64_t)R_RDX, emu->xmm[2].d[0], emu->xmm[3].d[0], (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9); }
-void vFffffffffff(x64emu_t *emu, uintptr_t fcn) { vFffffffffff_t fn = (vFffffffffff_t)fcn; fn(emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0], emu->xmm[3].f[0], emu->xmm[4].f[0], emu->xmm[5].f[0], emu->xmm[6].f[0], emu->xmm[7].f[0], *(float*)(R_RSP + 8), *(float*)(R_RSP + 16)); }
-void vFpipippppip(x64emu_t *emu, uintptr_t fcn) { vFpipippppip_t fn = (vFpipippppip_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(void**)(R_RSP + 32)); }
-void vFppiiiiiiii(x64emu_t *emu, uintptr_t fcn) { vFppiiiiiiii_t fn = (vFppiiiiiiii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32)); }
-void vFppiiiiipip(x64emu_t *emu, uintptr_t fcn) { vFppiiiiipip_t fn = (vFppiiiiipip_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(void**)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(void**)(R_RSP + 32)); }
-void vFppiipppiip(x64emu_t *emu, uintptr_t fcn) { vFppiipppiip_t fn = (vFppiipppiip_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(void**)(R_RSP + 32)); }
-void vFppiippppii(x64emu_t *emu, uintptr_t fcn) { vFppiippppii_t fn = (vFppiippppii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32)); }
-void vFppipppiiii(x64emu_t *emu, uintptr_t fcn) { vFppipppiiii_t fn = (vFppipppiiii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32)); }
-void vFppuuuuiiuu(x64emu_t *emu, uintptr_t fcn) { vFppuuuuiiuu_t fn = (vFppuuuuiiuu_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24), *(uint64_t*)(R_RSP + 32)); }
-void vFppdddddddd(x64emu_t *emu, uintptr_t fcn) { vFppdddddddd_t fn = (vFppdddddddd_t)fcn; fn((void*)R_RDI, (void*)R_RSI, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0], emu->xmm[4].d[0], emu->xmm[5].d[0], emu->xmm[6].d[0], emu->xmm[7].d[0]); }
-void vFpppppppppp(x64emu_t *emu, uintptr_t fcn) { vFpppppppppp_t fn = (vFpppppppppp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32)); }
-void iFEpiiiiippp(x64emu_t *emu, uintptr_t fcn) { iFEpiiiiippp_t fn = (iFEpiiiiippp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void iFEpupppLppL(x64emu_t *emu, uintptr_t fcn) { iFEpupppLppL_t fn = (iFEpupppLppL_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (uintptr_t)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(uintptr_t*)(R_RSP + 24)); }
-void iFEppppppipp(x64emu_t *emu, uintptr_t fcn) { iFEppppppipp_t fn = (iFEppppppipp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void iFEppppppppp(x64emu_t *emu, uintptr_t fcn) { iFEppppppppp_t fn = (iFEppppppppp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void iFiiiiiiiiip(x64emu_t *emu, uintptr_t fcn) { iFiiiiiiiiip_t fn = (iFiiiiiiiiip_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(void**)(R_RSP + 32)); }
-void iFpiipiiipip(x64emu_t *emu, uintptr_t fcn) { iFpiipiiipip_t fn = (iFpiipiiipip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(void**)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(void**)(R_RSP + 32)); }
-void iFpippddiidd(x64emu_t *emu, uintptr_t fcn) { iFpippddiidd_t fn = (iFpippddiidd_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, emu->xmm[0].d[0], emu->xmm[1].d[0], (int64_t)R_R8, (int64_t)R_R9, emu->xmm[2].d[0], emu->xmm[3].d[0]); }
-void iFpCuWCCCCup(x64emu_t *emu, uintptr_t fcn) { iFpCuWCCCCup_t fn = (iFpCuWCCCCup_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint8_t)R_RSI, (uint64_t)R_RDX, (uint16_t)R_RCX, (uint8_t)R_R8, (uint8_t)R_R9, *(uint8_t*)(R_RSP + 8), *(uint8_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24), *(void**)(R_RSP + 32)); }
-void iFpuupiuiipp(x64emu_t *emu, uintptr_t fcn) { iFpuupiuiipp_t fn = (iFpuupiuiipp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8, (uint64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32)); }
-void iFpddpippppp(x64emu_t *emu, uintptr_t fcn) { iFpddpippppp_t fn = (iFpddpippppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0], (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void iFppuuiiiiii(x64emu_t *emu, uintptr_t fcn) { iFppuuiiiiii_t fn = (iFppuuiiiiii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32)); }
-void iFppuuiiuupi(x64emu_t *emu, uintptr_t fcn) { iFppuuiiuupi_t fn = (iFppuuiiuupi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), *(void**)(R_RSP + 24), *(int64_t*)(R_RSP + 32)); }
-void iFpppiiipipi(x64emu_t *emu, uintptr_t fcn) { iFpppiiipipi_t fn = (iFpppiiipipi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(void**)(R_RSP + 24), *(int64_t*)(R_RSP + 32)); }
-void iFpppLLipppp(x64emu_t *emu, uintptr_t fcn) { iFpppLLipppp_t fn = (iFpppLLipppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uintptr_t)R_RCX, (uintptr_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32)); }
-void iFppppiiuuii(x64emu_t *emu, uintptr_t fcn) { iFppppiiuuii_t fn = (iFppppiiuuii_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32)); }
-void iFpppppppipi(x64emu_t *emu, uintptr_t fcn) { iFpppppppipi_t fn = (iFpppppppipi_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(void**)(R_RSP + 24), *(int64_t*)(R_RSP + 32)); }
-void uFpppppppppp(x64emu_t *emu, uintptr_t fcn) { uFpppppppppp_t fn = (uFpppppppppp_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32)); }
-void pFEiippppppp(x64emu_t *emu, uintptr_t fcn) { pFEiippppppp_t fn = (pFEiippppppp_t)fcn; R_RAX=(uintptr_t)fn(emu, (int64_t)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void pFEpiiiiiipp(x64emu_t *emu, uintptr_t fcn) { pFEpiiiiiipp_t fn = (pFEpiiiiiipp_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void pFEpippppppp(x64emu_t *emu, uintptr_t fcn) { pFEpippppppp_t fn = (pFEpippppppp_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24)); }
-void pFpCuWCCuuCW(x64emu_t *emu, uintptr_t fcn) { pFpCuWCCuuCW_t fn = (pFpCuWCCuuCW_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint8_t)R_RSI, (uint64_t)R_RDX, (uint16_t)R_RCX, (uint8_t)R_R8, (uint8_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), *(uint8_t*)(R_RSP + 24), *(uint16_t*)(R_RSP + 32)); }
-void pFpuwwWWuCuu(x64emu_t *emu, uintptr_t fcn) { pFpuwwWWuCuu_t fn = (pFpuwwWWuCuu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (int16_t)R_RDX, (int16_t)R_RCX, (uint16_t)R_R8, (uint16_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint8_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24), *(uint64_t*)(R_RSP + 32)); }
-void pFpuuuwwwwWW(x64emu_t *emu, uintptr_t fcn) { pFpuuuwwwwWW_t fn = (pFpuuuwwwwWW_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (int16_t)R_R8, (int16_t)R_R9, *(int16_t*)(R_RSP + 8), *(int16_t*)(R_RSP + 16), *(uint16_t*)(R_RSP + 24), *(uint16_t*)(R_RSP + 32)); }
-void pFpuuuWWWCCi(x64emu_t *emu, uintptr_t fcn) { pFpuuuWWWCCi_t fn = (pFpuuuWWWCCi_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint16_t)R_R8, (uint16_t)R_R9, *(uint16_t*)(R_RSP + 8), *(uint8_t*)(R_RSP + 16), *(uint8_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32)); }
-void pFplllllllll(x64emu_t *emu, uintptr_t fcn) { pFplllllllll_t fn = (pFplllllllll_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (intptr_t)R_RSI, (intptr_t)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8, (intptr_t)R_R9, *(intptr_t*)(R_RSP + 8), *(intptr_t*)(R_RSP + 16), *(intptr_t*)(R_RSP + 24), *(intptr_t*)(R_RSP + 32)); }
-void pFppuiipuuii(x64emu_t *emu, uintptr_t fcn) { pFppuiipuuii_t fn = (pFppuiipuuii_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32)); }
-void pFpppppppppp(x64emu_t *emu, uintptr_t fcn) { pFpppppppppp_t fn = (pFpppppppppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32)); }
-void iWEpuipupppp(x64emu_t *emu, uintptr_t fcn) { iWEpuipupppp_t fn = (iWEpuipupppp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RCX, (uint64_t)R_RDX, (int64_t)R_R8, (void*)R_R9, *(uint64_t*)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56), *(void**)(R_RSP + 64), *(void**)(R_RSP + 72)); }
-void iWEpuuiiuipp(x64emu_t *emu, uintptr_t fcn) { iWEpuuiiuipp_t fn = (iWEpuuiiuipp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RCX, (uint64_t)R_RDX, (uint64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 40), *(uint64_t*)(R_RSP + 48), *(int64_t*)(R_RSP + 56), *(void**)(R_RSP + 64), *(void**)(R_RSP + 72)); }
-void iWEpuuuuiipp(x64emu_t *emu, uintptr_t fcn) { iWEpuuuuiipp_t fn = (iWEpuuuuiipp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RCX, (uint64_t)R_RDX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 40), *(int64_t*)(R_RSP + 48), *(int64_t*)(R_RSP + 56), *(void**)(R_RSP + 64), *(void**)(R_RSP + 72)); }
-void vFEpiiiupupup(x64emu_t *emu, uintptr_t fcn) { vFEpiiiupupup_t fn = (vFEpiiiupupup_t)fcn; fn(emu, (void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (void*)R_R9, *(uint64_t*)(R_RSP + 8), *(void**)(R_RSP + 16), *(uint64_t*)(R_RSP + 24), *(void**)(R_RSP + 32)); }
-void vFiiiiillliip(x64emu_t *emu, uintptr_t fcn) { vFiiiiillliip_t fn = (vFiiiiillliip_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (intptr_t)R_R9, *(intptr_t*)(R_RSP + 8), *(intptr_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(void**)(R_RSP + 40)); }
-void vFiiiiilllilp(x64emu_t *emu, uintptr_t fcn) { vFiiiiilllilp_t fn = (vFiiiiilllilp_t)fcn; fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (intptr_t)R_R9, *(intptr_t*)(R_RSP + 8), *(intptr_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(intptr_t*)(R_RSP + 32), *(void**)(R_RSP + 40)); }
-void vFuiiiiiiiiip(x64emu_t *emu, uintptr_t fcn) { vFuiiiiiiiiip_t fn = (vFuiiiiiiiiip_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(void**)(R_RSP + 40)); }
-void vFuiiiiiiiuip(x64emu_t *emu, uintptr_t fcn) { vFuiiiiiiiuip_t fn = (vFuiiiiiiiuip_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(void**)(R_RSP + 40)); }
-void vFuiiiiiiiuup(x64emu_t *emu, uintptr_t fcn) { vFuiiiiiiiuup_t fn = (vFuiiiiiiiuup_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24), *(uint64_t*)(R_RSP + 32), *(void**)(R_RSP + 40)); }
-void vFuiiiillliip(x64emu_t *emu, uintptr_t fcn) { vFuiiiillliip_t fn = (vFuiiiillliip_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (intptr_t)R_R9, *(intptr_t*)(R_RSP + 8), *(intptr_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(void**)(R_RSP + 40)); }
-void vFuiiiilllilp(x64emu_t *emu, uintptr_t fcn) { vFuiiiilllilp_t fn = (vFuiiiilllilp_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (intptr_t)R_R9, *(intptr_t*)(R_RSP + 8), *(intptr_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(intptr_t*)(R_RSP + 32), *(void**)(R_RSP + 40)); }
-void vFuiuiiiiiuup(x64emu_t *emu, uintptr_t fcn) { vFuiuiiiiiuup_t fn = (vFuiuiiiiiuup_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24), *(uint64_t*)(R_RSP + 32), *(void**)(R_RSP + 40)); }
-void vFuuiuiiiiuup(x64emu_t *emu, uintptr_t fcn) { vFuuiuiiiiuup_t fn = (vFuuiuiiiiuup_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24), *(uint64_t*)(R_RSP + 32), *(void**)(R_RSP + 40)); }
-void vFuuuuuuuuuuu(x64emu_t *emu, uintptr_t fcn) { vFuuuuuuuuuuu_t fn = (vFuuuuuuuuuuu_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24), *(uint64_t*)(R_RSP + 32), *(uint64_t*)(R_RSP + 40)); }
-void vFuuupupppppp(x64emu_t *emu, uintptr_t fcn) { vFuuupupppppp_t fn = (vFuuupupppppp_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (uint64_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40)); }
-void vFuuffiiffiip(x64emu_t *emu, uintptr_t fcn) { vFuuffiiffiip_t fn = (vFuuffiiffiip_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, emu->xmm[0].f[0], emu->xmm[1].f[0], (int64_t)R_RDX, (int64_t)R_RCX, emu->xmm[2].f[0], emu->xmm[3].f[0], (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void vFuufffffffff(x64emu_t *emu, uintptr_t fcn) { vFuufffffffff_t fn = (vFuufffffffff_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0], emu->xmm[3].f[0], emu->xmm[4].f[0], emu->xmm[5].f[0], emu->xmm[6].f[0], emu->xmm[7].f[0], *(float*)(R_RSP + 8)); }
-void vFuuddiiddiip(x64emu_t *emu, uintptr_t fcn) { vFuuddiiddiip_t fn = (vFuuddiiddiip_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, emu->xmm[0].d[0], emu->xmm[1].d[0], (int64_t)R_RDX, (int64_t)R_RCX, emu->xmm[2].d[0], emu->xmm[3].d[0], (int64_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8)); }
-void vFuffffffffff(x64emu_t *emu, uintptr_t fcn) { vFuffffffffff_t fn = (vFuffffffffff_t)fcn; fn((uint64_t)R_RDI, emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0], emu->xmm[3].f[0], emu->xmm[4].f[0], emu->xmm[5].f[0], emu->xmm[6].f[0], emu->xmm[7].f[0], *(float*)(R_RSP + 8), *(float*)(R_RSP + 16)); }
-void vFUufffffffff(x64emu_t *emu, uintptr_t fcn) { vFUufffffffff_t fn = (vFUufffffffff_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0], emu->xmm[3].f[0], emu->xmm[4].f[0], emu->xmm[5].f[0], emu->xmm[6].f[0], emu->xmm[7].f[0], *(float*)(R_RSP + 8)); }
-void vFpipipiipiii(x64emu_t *emu, uintptr_t fcn) { vFpipipiipiii_t fn = (vFpipipiipiii_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(void**)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(int64_t*)(R_RSP + 40)); }
-void vFpipppiiiipi(x64emu_t *emu, uintptr_t fcn) { vFpipppiiiipi_t fn = (vFpipppiiiipi_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(void**)(R_RSP + 32), *(int64_t*)(R_RSP + 40)); }
-void vFpupiiupupup(x64emu_t *emu, uintptr_t fcn) { vFpupiiupupup_t fn = (vFpupiiupupup_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (uint64_t)R_R9, *(void**)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), *(void**)(R_RSP + 24), *(uint64_t*)(R_RSP + 32), *(void**)(R_RSP + 40)); }
-void vFppiiiiiiiii(x64emu_t *emu, uintptr_t fcn) { vFppiiiiiiiii_t fn = (vFppiiiiiiiii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(int64_t*)(R_RSP + 40)); }
-void vFppiiiiipiii(x64emu_t *emu, uintptr_t fcn) { vFppiiiiipiii_t fn = (vFppiiiiipiii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(void**)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(int64_t*)(R_RSP + 40)); }
-void vFppiiiiddddi(x64emu_t *emu, uintptr_t fcn) { vFppiiiiddddi_t fn = (vFppiiiiddddi_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0], *(int64_t*)(R_RSP + 8)); }
-void vFppiipppiiii(x64emu_t *emu, uintptr_t fcn) { vFppiipppiiii_t fn = (vFppiipppiiii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(int64_t*)(R_RSP + 40)); }
-void vFppipppiiiii(x64emu_t *emu, uintptr_t fcn) { vFppipppiiiii_t fn = (vFppipppiiiii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(int64_t*)(R_RSP + 40)); }
-void vFppipppuiiii(x64emu_t *emu, uintptr_t fcn) { vFppipppuiiii_t fn = (vFppipppuiiii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(uint64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(int64_t*)(R_RSP + 40)); }
-void vFppppppppppp(x64emu_t *emu, uintptr_t fcn) { vFppppppppppp_t fn = (vFppppppppppp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40)); }
-void iFEpppipppppp(x64emu_t *emu, uintptr_t fcn) { iFEpppipppppp_t fn = (iFEpppipppppp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32)); }
-void iFEppppiiiiuu(x64emu_t *emu, uintptr_t fcn) { iFEppppiiiiuu_t fn = (iFEppppiiiiuu_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24), *(uint64_t*)(R_RSP + 32)); }
-void iFiiiiiiiiiip(x64emu_t *emu, uintptr_t fcn) { iFiiiiiiiiiip_t fn = (iFiiiiiiiiiip_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(void**)(R_RSP + 40)); }
-void iFpiippiiipip(x64emu_t *emu, uintptr_t fcn) { iFpiippiiipip_t fn = (iFpiippiiipip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(void**)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(void**)(R_RSP + 40)); }
-void iFppippipppip(x64emu_t *emu, uintptr_t fcn) { iFppippipppip_t fn = (iFppippipppip_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(void**)(R_RSP + 40)); }
-void iFpppiiuuiiuu(x64emu_t *emu, uintptr_t fcn) { iFpppiiuuiiuu_t fn = (iFpppiiuuiiuu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(uint64_t*)(R_RSP + 32), *(uint64_t*)(R_RSP + 40)); }
-void iFppppiiuuiiL(x64emu_t *emu, uintptr_t fcn) { iFppppiiuuiiL_t fn = (iFppppiiuuiiL_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(uintptr_t*)(R_RSP + 40)); }
-void uFEpLiupppLuV(x64emu_t *emu, uintptr_t fcn) { uFEpLiupppLuV_t fn = (uFEpLiupppLuV_t)fcn; R_RAX=(uint64_t)fn(emu, (void*)R_RDI, (uintptr_t)R_RSI, (int64_t)R_RDX, (uint64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(uintptr_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24), (void*)(R_RSP + 32)); }
-void uFEpLippppLup(x64emu_t *emu, uintptr_t fcn) { uFEpLippppLup_t fn = (uFEpLippppLup_t)fcn; R_RAX=(uint64_t)fn(emu, (void*)R_RDI, (uintptr_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(uintptr_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24), *(void**)(R_RSP + 32)); }
-void uFEpLippppLuA(x64emu_t *emu, uintptr_t fcn) { uFEpLippppLuA_t fn = (uFEpLippppLuA_t)fcn; R_RAX=(uint64_t)fn(emu, (void*)R_RDI, (uintptr_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(uintptr_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24), *(void**)(R_RSP + 32)); }
-void uFEppppppippp(x64emu_t *emu, uintptr_t fcn) { uFEppppppippp_t fn = (uFEppppppippp_t)fcn; R_RAX=(uint64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32)); }
-void uFppppppppppp(x64emu_t *emu, uintptr_t fcn) { uFppppppppppp_t fn = (uFppppppppppp_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40)); }
-void pFEpipppppppi(x64emu_t *emu, uintptr_t fcn) { pFEpipppppppi_t fn = (pFEpipppppppi_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(int64_t*)(R_RSP + 32)); }
-void pFEppiiLpppip(x64emu_t *emu, uintptr_t fcn) { pFEppiiLpppip_t fn = (pFEppiiLpppip_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uintptr_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(void**)(R_RSP + 32)); }
-void pFEppuiipuuii(x64emu_t *emu, uintptr_t fcn) { pFEppuiipuuii_t fn = (pFEppuiipuuii_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (void*)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32)); }
-void pFpppppppiipp(x64emu_t *emu, uintptr_t fcn) { pFpppppppiipp_t fn = (pFpppppppiipp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40)); }
-void pFppppppppppp(x64emu_t *emu, uintptr_t fcn) { pFppppppppppp_t fn = (pFppppppppppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40)); }
-void iWEpuipuppppp(x64emu_t *emu, uintptr_t fcn) { iWEpuipuppppp_t fn = (iWEpuipuppppp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RCX, (uint64_t)R_RDX, (int64_t)R_R8, (void*)R_R9, *(uint64_t*)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56), *(void**)(R_RSP + 64), *(void**)(R_RSP + 72), *(void**)(R_RSP + 80)); }
-void iWEpuuiiuippu(x64emu_t *emu, uintptr_t fcn) { iWEpuuiiuippu_t fn = (iWEpuuiiuippu_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RCX, (uint64_t)R_RDX, (uint64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 40), *(uint64_t*)(R_RSP + 48), *(int64_t*)(R_RSP + 56), *(void**)(R_RSP + 64), *(void**)(R_RSP + 72), *(uint64_t*)(R_RSP + 80)); }
-void iWEpuuuuuiipp(x64emu_t *emu, uintptr_t fcn) { iWEpuuuuuiipp_t fn = (iWEpuuuuuiipp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RCX, (uint64_t)R_RDX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 40), *(uint64_t*)(R_RSP + 48), *(int64_t*)(R_RSP + 56), *(int64_t*)(R_RSP + 64), *(void**)(R_RSP + 72), *(void**)(R_RSP + 80)); }
-void vFuiiiillliilp(x64emu_t *emu, uintptr_t fcn) { vFuiiiillliilp_t fn = (vFuiiiillliilp_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (intptr_t)R_R9, *(intptr_t*)(R_RSP + 8), *(intptr_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(intptr_t*)(R_RSP + 40), *(void**)(R_RSP + 48)); }
-void vFuuiiiiiiiiui(x64emu_t *emu, uintptr_t fcn) { vFuuiiiiiiiiui_t fn = (vFuuiiiiiiiiui_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(uint64_t*)(R_RSP + 40), *(int64_t*)(R_RSP + 48)); }
-void vFuuiiiiiiiuip(x64emu_t *emu, uintptr_t fcn) { vFuuiiiiiiiuip_t fn = (vFuuiiiiiiiuip_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(uint64_t*)(R_RSP + 32), *(int64_t*)(R_RSP + 40), *(void**)(R_RSP + 48)); }
-void vFuuiiiiiiiuup(x64emu_t *emu, uintptr_t fcn) { vFuuiiiiiiiuup_t fn = (vFuuiiiiiiiuup_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(uint64_t*)(R_RSP + 32), *(uint64_t*)(R_RSP + 40), *(void**)(R_RSP + 48)); }
-void vFuuuuuuuuuuuu(x64emu_t *emu, uintptr_t fcn) { vFuuuuuuuuuuuu_t fn = (vFuuuuuuuuuuuu_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24), *(uint64_t*)(R_RSP + 32), *(uint64_t*)(R_RSP + 40), *(uint64_t*)(R_RSP + 48)); }
-void vFffffffffffff(x64emu_t *emu, uintptr_t fcn) { vFffffffffffff_t fn = (vFffffffffffff_t)fcn; fn(emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0], emu->xmm[3].f[0], emu->xmm[4].f[0], emu->xmm[5].f[0], emu->xmm[6].f[0], emu->xmm[7].f[0], *(float*)(R_RSP + 8), *(float*)(R_RSP + 16), *(float*)(R_RSP + 24), *(float*)(R_RSP + 32)); }
-void vFpipppiiiipii(x64emu_t *emu, uintptr_t fcn) { vFpipppiiiipii_t fn = (vFpipppiiiipii_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(void**)(R_RSP + 32), *(int64_t*)(R_RSP + 40), *(int64_t*)(R_RSP + 48)); }
-void vFpippppiiiipi(x64emu_t *emu, uintptr_t fcn) { vFpippppiiiipi_t fn = (vFpippppiiiipi_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(void**)(R_RSP + 40), *(int64_t*)(R_RSP + 48)); }
-void vFppiiiiddddii(x64emu_t *emu, uintptr_t fcn) { vFppiiiiddddii_t fn = (vFppiiiiddddii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0], *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16)); }
-void vFppiiuuuiupup(x64emu_t *emu, uintptr_t fcn) { vFppiiuuuiupup_t fn = (vFppiiuuuiupup_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24), *(void**)(R_RSP + 32), *(uint64_t*)(R_RSP + 40), *(void**)(R_RSP + 48)); }
-void vFppiipppiiiii(x64emu_t *emu, uintptr_t fcn) { vFppiipppiiiii_t fn = (vFppiipppiiiii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(int64_t*)(R_RSP + 40), *(int64_t*)(R_RSP + 48)); }
-void vFpppiiiiiiiii(x64emu_t *emu, uintptr_t fcn) { vFpppiiiiiiiii_t fn = (vFpppiiiiiiiii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(int64_t*)(R_RSP + 40), *(int64_t*)(R_RSP + 48)); }
-void vFpppppppppppp(x64emu_t *emu, uintptr_t fcn) { vFpppppppppppp_t fn = (vFpppppppppppp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48)); }
-void iFEpppippppppp(x64emu_t *emu, uintptr_t fcn) { iFEpppippppppp_t fn = (iFEpppippppppp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40)); }
-void iFEppppiiiiuui(x64emu_t *emu, uintptr_t fcn) { iFEppppiiiiuui_t fn = (iFEppppiiiiuui_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24), *(uint64_t*)(R_RSP + 32), *(int64_t*)(R_RSP + 40)); }
-void iFpipllipppppp(x64emu_t *emu, uintptr_t fcn) { iFpipllipppppp_t fn = (iFpipllipppppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48)); }
-void iFpipppppppppp(x64emu_t *emu, uintptr_t fcn) { iFpipppppppppp_t fn = (iFpipppppppppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48)); }
-void iFpCCCWCWCCCWp(x64emu_t *emu, uintptr_t fcn) { iFpCCCWCWCCCWp_t fn = (iFpCCCWCWCCCWp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint8_t)R_RSI, (uint8_t)R_RDX, (uint8_t)R_RCX, (uint16_t)R_R8, (uint8_t)R_R9, *(uint16_t*)(R_RSP + 8), *(uint8_t*)(R_RSP + 16), *(uint8_t*)(R_RSP + 24), *(uint8_t*)(R_RSP + 32), *(uint16_t*)(R_RSP + 40), *(void**)(R_RSP + 48)); }
-void iFpppllipppppp(x64emu_t *emu, uintptr_t fcn) { iFpppllipppppp_t fn = (iFpppllipppppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (intptr_t)R_RCX, (intptr_t)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48)); }
-void iFpppppppppppp(x64emu_t *emu, uintptr_t fcn) { iFpppppppppppp_t fn = (iFpppppppppppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48)); }
-void pFEppiiuuuipii(x64emu_t *emu, uintptr_t fcn) { pFEppiiuuuipii_t fn = (pFEppiiuuuipii_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(void**)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(int64_t*)(R_RSP + 40)); }
-void pFEppppppppppp(x64emu_t *emu, uintptr_t fcn) { pFEppppppppppp_t fn = (pFEppppppppppp_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40)); }
-void pFWWiCCCCiipup(x64emu_t *emu, uintptr_t fcn) { pFWWiCCCCiipup_t fn = (pFWWiCCCCiipup_t)fcn; R_RAX=(uintptr_t)fn((uint16_t)R_RDI, (uint16_t)R_RSI, (int64_t)R_RDX, (uint8_t)R_RCX, (uint8_t)R_R8, (uint8_t)R_R9, *(uint8_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(void**)(R_RSP + 32), *(uint64_t*)(R_RSP + 40), *(void**)(R_RSP + 48)); }
-void pFpCuuWWwwCCup(x64emu_t *emu, uintptr_t fcn) { pFpCuuWWwwCCup_t fn = (pFpCuuWWwwCCup_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint8_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint16_t)R_R8, (uint16_t)R_R9, *(int16_t*)(R_RSP + 8), *(int16_t*)(R_RSP + 16), *(uint8_t*)(R_RSP + 24), *(uint8_t*)(R_RSP + 32), *(uint64_t*)(R_RSP + 40), *(void**)(R_RSP + 48)); }
-void pFpuuuWWWWWWWW(x64emu_t *emu, uintptr_t fcn) { pFpuuuWWWWWWWW_t fn = (pFpuuuWWWWWWWW_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint16_t)R_R8, (uint16_t)R_R9, *(uint16_t*)(R_RSP + 8), *(uint16_t*)(R_RSP + 16), *(uint16_t*)(R_RSP + 24), *(uint16_t*)(R_RSP + 32), *(uint16_t*)(R_RSP + 40), *(uint16_t*)(R_RSP + 48)); }
-void pFppiiuuuiupLp(x64emu_t *emu, uintptr_t fcn) { pFppiiuuuiupLp_t fn = (pFppiiuuuiupLp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24), *(void**)(R_RSP + 32), *(uintptr_t*)(R_RSP + 40), *(void**)(R_RSP + 48)); }
-void pFpppppppppppp(x64emu_t *emu, uintptr_t fcn) { pFpppppppppppp_t fn = (pFpppppppppppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48)); }
-void vFEpppppppiippp(x64emu_t *emu, uintptr_t fcn) { vFEpppppppiippp_t fn = (vFEpppppppiippp_t)fcn; fn(emu, (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48)); }
-void vFuiiiiiiiiiuup(x64emu_t *emu, uintptr_t fcn) { vFuiiiiiiiiiuup_t fn = (vFuiiiiiiiiiuup_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(uint64_t*)(R_RSP + 40), *(uint64_t*)(R_RSP + 48), *(void**)(R_RSP + 56)); }
-void vFuuuuuuuuuuuuu(x64emu_t *emu, uintptr_t fcn) { vFuuuuuuuuuuuuu_t fn = (vFuuuuuuuuuuuuu_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24), *(uint64_t*)(R_RSP + 32), *(uint64_t*)(R_RSP + 40), *(uint64_t*)(R_RSP + 48), *(uint64_t*)(R_RSP + 56)); }
-void vFuffffffffffff(x64emu_t *emu, uintptr_t fcn) { vFuffffffffffff_t fn = (vFuffffffffffff_t)fcn; fn((uint64_t)R_RDI, emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0], emu->xmm[3].f[0], emu->xmm[4].f[0], emu->xmm[5].f[0], emu->xmm[6].f[0], emu->xmm[7].f[0], *(float*)(R_RSP + 8), *(float*)(R_RSP + 16), *(float*)(R_RSP + 24), *(float*)(R_RSP + 32)); }
-void vFpipppiiiiiiuu(x64emu_t *emu, uintptr_t fcn) { vFpipppiiiiiiuu_t fn = (vFpipppiiiiiiuu_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(int64_t*)(R_RSP + 40), *(uint64_t*)(R_RSP + 48), *(uint64_t*)(R_RSP + 56)); }
-void vFpippppppppppp(x64emu_t *emu, uintptr_t fcn) { vFpippppppppppp_t fn = (vFpippppppppppp_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56)); }
-void vFppiiiiiiiiiii(x64emu_t *emu, uintptr_t fcn) { vFppiiiiiiiiiii_t fn = (vFppiiiiiiiiiii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(int64_t*)(R_RSP + 40), *(int64_t*)(R_RSP + 48), *(int64_t*)(R_RSP + 56)); }
-void vFppiipppiiiiii(x64emu_t *emu, uintptr_t fcn) { vFppiipppiiiiii_t fn = (vFppiipppiiiiii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(int64_t*)(R_RSP + 40), *(int64_t*)(R_RSP + 48), *(int64_t*)(R_RSP + 56)); }
-void vFppppppppppppp(x64emu_t *emu, uintptr_t fcn) { vFppppppppppppp_t fn = (vFppppppppppppp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56)); }
-void iFddddpppddpppp(x64emu_t *emu, uintptr_t fcn) { iFddddpppddpppp_t fn = (iFddddpppddpppp_t)fcn; R_RAX=(int64_t)fn(emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0], (void*)R_RDI, (void*)R_RSI, (void*)R_RDX, emu->xmm[4].d[0], emu->xmm[5].d[0], (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-void iFpippuuuiipppp(x64emu_t *emu, uintptr_t fcn) { iFpippuuuiipppp_t fn = (iFpippuuuiipppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56)); }
-void iFpupiiiipppppp(x64emu_t *emu, uintptr_t fcn) { iFpupiiiipppppp_t fn = (iFpupiiiipppppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (uint64_t)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56)); }
-void uFppppuuupppppp(x64emu_t *emu, uintptr_t fcn) { uFppppuuupppppp_t fn = (uFppppuuupppppp_t)fcn; R_RAX=(uint64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56)); }
-void pFpCuuwwWWWWuup(x64emu_t *emu, uintptr_t fcn) { pFpCuuwwWWWWuup_t fn = (pFpCuuwwWWWWuup_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint8_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (int16_t)R_R8, (int16_t)R_R9, *(uint16_t*)(R_RSP + 8), *(uint16_t*)(R_RSP + 16), *(uint16_t*)(R_RSP + 24), *(uint16_t*)(R_RSP + 32), *(uint64_t*)(R_RSP + 40), *(uint64_t*)(R_RSP + 48), *(void**)(R_RSP + 56)); }
-void pFpuupppwwwwWWC(x64emu_t *emu, uintptr_t fcn) { pFpuupppwwwwWWC_t fn = (pFpuupppwwwwWWC_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(int16_t*)(R_RSP + 8), *(int16_t*)(R_RSP + 16), *(int16_t*)(R_RSP + 24), *(int16_t*)(R_RSP + 32), *(uint16_t*)(R_RSP + 40), *(uint16_t*)(R_RSP + 48), *(uint8_t*)(R_RSP + 56)); }
-void pFppppppppppppp(x64emu_t *emu, uintptr_t fcn) { pFppppppppppppp_t fn = (pFppppppppppppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56)); }
-void vFuffiiffiiffiip(x64emu_t *emu, uintptr_t fcn) { vFuffiiffiiffiip_t fn = (vFuffiiffiiffiip_t)fcn; fn((uint64_t)R_RDI, emu->xmm[0].f[0], emu->xmm[1].f[0], (int64_t)R_RSI, (int64_t)R_RDX, emu->xmm[2].f[0], emu->xmm[3].f[0], (int64_t)R_RCX, (int64_t)R_R8, emu->xmm[4].f[0], emu->xmm[5].f[0], (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void vFuddiiddiiddiip(x64emu_t *emu, uintptr_t fcn) { vFuddiiddiiddiip_t fn = (vFuddiiddiiddiip_t)fcn; fn((uint64_t)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0], (int64_t)R_RSI, (int64_t)R_RDX, emu->xmm[2].d[0], emu->xmm[3].d[0], (int64_t)R_RCX, (int64_t)R_R8, emu->xmm[4].d[0], emu->xmm[5].d[0], (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(void**)(R_RSP + 16)); }
-void vFppiipppiiiiiii(x64emu_t *emu, uintptr_t fcn) { vFppiipppiiiiiii_t fn = (vFppiipppiiiiiii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(int64_t*)(R_RSP + 40), *(int64_t*)(R_RSP + 48), *(int64_t*)(R_RSP + 56), *(int64_t*)(R_RSP + 64)); }
-void iFpipppppppppppp(x64emu_t *emu, uintptr_t fcn) { iFpipppppppppppp_t fn = (iFpipppppppppppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56), *(void**)(R_RSP + 64)); }
-void iFpppwwWWwwWWpuu(x64emu_t *emu, uintptr_t fcn) { iFpppwwWWwwWWpuu_t fn = (iFpppwwWWwwWWpuu_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int16_t)R_RCX, (int16_t)R_R8, (uint16_t)R_R9, *(uint16_t*)(R_RSP + 8), *(int16_t*)(R_RSP + 16), *(int16_t*)(R_RSP + 24), *(uint16_t*)(R_RSP + 32), *(uint16_t*)(R_RSP + 40), *(void**)(R_RSP + 48), *(uint64_t*)(R_RSP + 56), *(uint64_t*)(R_RSP + 64)); }
-void pFppCpppwwwwwwWW(x64emu_t *emu, uintptr_t fcn) { pFppCpppwwwwwwWW_t fn = (pFppCpppwwwwwwWW_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (uint8_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(int16_t*)(R_RSP + 8), *(int16_t*)(R_RSP + 16), *(int16_t*)(R_RSP + 24), *(int16_t*)(R_RSP + 32), *(int16_t*)(R_RSP + 40), *(int16_t*)(R_RSP + 48), *(uint16_t*)(R_RSP + 56), *(uint16_t*)(R_RSP + 64)); }
-void vFuiiiiiuiiiiilll(x64emu_t *emu, uintptr_t fcn) { vFuiiiiiuiiiiilll_t fn = (vFuiiiiiuiiiiilll_t)fcn; fn((uint64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(int64_t*)(R_RSP + 40), *(int64_t*)(R_RSP + 48), *(intptr_t*)(R_RSP + 56), *(intptr_t*)(R_RSP + 64), *(intptr_t*)(R_RSP + 72)); }
-void vFuuiiiiuuiiiiiii(x64emu_t *emu, uintptr_t fcn) { vFuuiiiiuuiiiiiii_t fn = (vFuuiiiiuuiiiiiii_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(int64_t*)(R_RSP + 40), *(int64_t*)(R_RSP + 48), *(int64_t*)(R_RSP + 56), *(int64_t*)(R_RSP + 64), *(int64_t*)(R_RSP + 72)); }
-void vFfffffffffffffff(x64emu_t *emu, uintptr_t fcn) { vFfffffffffffffff_t fn = (vFfffffffffffffff_t)fcn; fn(emu->xmm[0].f[0], emu->xmm[1].f[0], emu->xmm[2].f[0], emu->xmm[3].f[0], emu->xmm[4].f[0], emu->xmm[5].f[0], emu->xmm[6].f[0], emu->xmm[7].f[0], *(float*)(R_RSP + 8), *(float*)(R_RSP + 16), *(float*)(R_RSP + 24), *(float*)(R_RSP + 32), *(float*)(R_RSP + 40), *(float*)(R_RSP + 48), *(float*)(R_RSP + 56)); }
-void vFpUUUUUUUUUUUuuu(x64emu_t *emu, uintptr_t fcn) { vFpUUUUUUUUUUUuuu_t fn = (vFpUUUUUUUUUUUuuu_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(uint64_t*)(R_RSP + 8), *(uint64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24), *(uint64_t*)(R_RSP + 32), *(uint64_t*)(R_RSP + 40), *(uint64_t*)(R_RSP + 48), *(uint64_t*)(R_RSP + 56), *(uint64_t*)(R_RSP + 64), *(uint64_t*)(R_RSP + 72)); }
-void vFpppippppppppppp(x64emu_t *emu, uintptr_t fcn) { vFpppippppppppppp_t fn = (vFpppippppppppppp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56), *(void**)(R_RSP + 64), *(void**)(R_RSP + 72)); }
-void vFppppppppppppppp(x64emu_t *emu, uintptr_t fcn) { vFppppppppppppppp_t fn = (vFppppppppppppppp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56), *(void**)(R_RSP + 64), *(void**)(R_RSP + 72)); }
-void pFpuiippppppppppp(x64emu_t *emu, uintptr_t fcn) { pFpuiippppppppppp_t fn = (pFpuiippppppppppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56), *(void**)(R_RSP + 64), *(void**)(R_RSP + 72)); }
-void pFppipppppppppppp(x64emu_t *emu, uintptr_t fcn) { pFppipppppppppppp_t fn = (pFppipppppppppppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56), *(void**)(R_RSP + 64), *(void**)(R_RSP + 72)); }
-void pFppppppppppppppp(x64emu_t *emu, uintptr_t fcn) { pFppppppppppppppp_t fn = (pFppppppppppppppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56), *(void**)(R_RSP + 64), *(void**)(R_RSP + 72)); }
-void vFpppppppppppppppp(x64emu_t *emu, uintptr_t fcn) { vFpppppppppppppppp_t fn = (vFpppppppppppppppp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56), *(void**)(R_RSP + 64), *(void**)(R_RSP + 72), *(void**)(R_RSP + 80)); }
-void iFpppppppppppppppp(x64emu_t *emu, uintptr_t fcn) { iFpppppppppppppppp_t fn = (iFpppppppppppppppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56), *(void**)(R_RSP + 64), *(void**)(R_RSP + 72), *(void**)(R_RSP + 80)); }
-void pFpuuWWWWWWwwCCCuu(x64emu_t *emu, uintptr_t fcn) { pFpuuWWWWWWwwCCCuu_t fn = (pFpuuWWWWWWwwCCCuu_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint16_t)R_RCX, (uint16_t)R_R8, (uint16_t)R_R9, *(uint16_t*)(R_RSP + 8), *(uint16_t*)(R_RSP + 16), *(uint16_t*)(R_RSP + 24), *(int16_t*)(R_RSP + 32), *(int16_t*)(R_RSP + 40), *(uint8_t*)(R_RSP + 48), *(uint8_t*)(R_RSP + 56), *(uint8_t*)(R_RSP + 64), *(uint64_t*)(R_RSP + 72), *(uint64_t*)(R_RSP + 80)); }
-void pFppipipipipipipip(x64emu_t *emu, uintptr_t fcn) { pFppipipipipipipip_t fn = (pFppipipipipipipip_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (int64_t)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8), *(void**)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(void**)(R_RSP + 32), *(int64_t*)(R_RSP + 40), *(void**)(R_RSP + 48), *(int64_t*)(R_RSP + 56), *(void**)(R_RSP + 64), *(int64_t*)(R_RSP + 72), *(void**)(R_RSP + 80)); }
-void pFpppppppppppppppp(x64emu_t *emu, uintptr_t fcn) { pFpppppppppppppppp_t fn = (pFpppppppppppppppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56), *(void**)(R_RSP + 64), *(void**)(R_RSP + 72), *(void**)(R_RSP + 80)); }
-void vFuuuiiiiiuiiiiilll(x64emu_t *emu, uintptr_t fcn) { vFuuuiiiiiuiiiiilll_t fn = (vFuuuiiiiiuiiiiilll_t)fcn; fn((uint64_t)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(int64_t*)(R_RSP + 40), *(int64_t*)(R_RSP + 48), *(int64_t*)(R_RSP + 56), *(int64_t*)(R_RSP + 64), *(intptr_t*)(R_RSP + 72), *(intptr_t*)(R_RSP + 80), *(intptr_t*)(R_RSP + 88)); }
-void vFppiiiiddddiiiiiuu(x64emu_t *emu, uintptr_t fcn) { vFppiiiiddddiiiiiuu_t fn = (vFppiiiiddddiiiiiuu_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0], *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(int64_t*)(R_RSP + 40), *(uint64_t*)(R_RSP + 48), *(uint64_t*)(R_RSP + 56)); }
-void vFpppuppiipppuUUUpi(x64emu_t *emu, uintptr_t fcn) { vFpppuppiipppuUUUpi_t fn = (vFpppuppiipppuUUUpi_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(uint64_t*)(R_RSP + 48), *(uint64_t*)(R_RSP + 56), *(uint64_t*)(R_RSP + 64), *(uint64_t*)(R_RSP + 72), *(void**)(R_RSP + 80), *(int64_t*)(R_RSP + 88)); }
-void pFpuuuuuwwuuuuUUUup(x64emu_t *emu, uintptr_t fcn) { pFpuuuuuwwuuuuUUUup_t fn = (pFpuuuuuwwuuuuUUUup_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint64_t)R_R9, *(int16_t*)(R_RSP + 8), *(int16_t*)(R_RSP + 16), *(uint64_t*)(R_RSP + 24), *(uint64_t*)(R_RSP + 32), *(uint64_t*)(R_RSP + 40), *(uint64_t*)(R_RSP + 48), *(uint64_t*)(R_RSP + 56), *(uint64_t*)(R_RSP + 64), *(uint64_t*)(R_RSP + 72), *(uint64_t*)(R_RSP + 80), *(void**)(R_RSP + 88)); }
-void pFppippipipipipipip(x64emu_t *emu, uintptr_t fcn) { pFppippipipipipipip_t fn = (pFppippipipipipipip_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, (int64_t)R_R9, *(void**)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(void**)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(void**)(R_RSP + 40), *(int64_t*)(R_RSP + 48), *(void**)(R_RSP + 56), *(int64_t*)(R_RSP + 64), *(void**)(R_RSP + 72), *(int64_t*)(R_RSP + 80), *(void**)(R_RSP + 88)); }
-void vFppuiiiiipuiiiiiiii(x64emu_t *emu, uintptr_t fcn) { vFppuiiiiipuiiiiiiii_t fn = (vFppuiiiiipuiiiiiiii_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(void**)(R_RSP + 24), *(uint64_t*)(R_RSP + 32), *(int64_t*)(R_RSP + 40), *(int64_t*)(R_RSP + 48), *(int64_t*)(R_RSP + 56), *(int64_t*)(R_RSP + 64), *(int64_t*)(R_RSP + 72), *(int64_t*)(R_RSP + 80), *(int64_t*)(R_RSP + 88), *(int64_t*)(R_RSP + 96)); }
-void vFpppipppppppppppppp(x64emu_t *emu, uintptr_t fcn) { vFpppipppppppppppppp_t fn = (vFpppipppppppppppppp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56), *(void**)(R_RSP + 64), *(void**)(R_RSP + 72), *(void**)(R_RSP + 80), *(void**)(R_RSP + 88), *(void**)(R_RSP + 96)); }
-void iFpppppppppppppppppp(x64emu_t *emu, uintptr_t fcn) { iFpppppppppppppppppp_t fn = (iFpppppppppppppppppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56), *(void**)(R_RSP + 64), *(void**)(R_RSP + 72), *(void**)(R_RSP + 80), *(void**)(R_RSP + 88), *(void**)(R_RSP + 96)); }
-void LFpppppppppppppppppp(x64emu_t *emu, uintptr_t fcn) { LFpppppppppppppppppp_t fn = (LFpppppppppppppppppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56), *(void**)(R_RSP + 64), *(void**)(R_RSP + 72), *(void**)(R_RSP + 80), *(void**)(R_RSP + 88), *(void**)(R_RSP + 96)); }
-void pFippppppppppppppppp(x64emu_t *emu, uintptr_t fcn) { pFippppppppppppppppp_t fn = (pFippppppppppppppppp_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56), *(void**)(R_RSP + 64), *(void**)(R_RSP + 72), *(void**)(R_RSP + 80), *(void**)(R_RSP + 88), *(void**)(R_RSP + 96)); }
-void vFpiiiiiiiiiiiiiiiiii(x64emu_t *emu, uintptr_t fcn) { vFpiiiiiiiiiiiiiiiiii_t fn = (vFpiiiiiiiiiiiiiiiiii_t)fcn; fn((void*)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (int64_t)R_R8, (int64_t)R_R9, *(int64_t*)(R_RSP + 8), *(int64_t*)(R_RSP + 16), *(int64_t*)(R_RSP + 24), *(int64_t*)(R_RSP + 32), *(int64_t*)(R_RSP + 40), *(int64_t*)(R_RSP + 48), *(int64_t*)(R_RSP + 56), *(int64_t*)(R_RSP + 64), *(int64_t*)(R_RSP + 72), *(int64_t*)(R_RSP + 80), *(int64_t*)(R_RSP + 88), *(int64_t*)(R_RSP + 96), *(int64_t*)(R_RSP + 104)); }
-void pFiiiippppppppppppppp(x64emu_t *emu, uintptr_t fcn) { pFiiiippppppppppppppp_t fn = (pFiiiippppppppppppppp_t)fcn; R_RAX=(uintptr_t)fn((int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56), *(void**)(R_RSP + 64), *(void**)(R_RSP + 72), *(void**)(R_RSP + 80), *(void**)(R_RSP + 88), *(void**)(R_RSP + 96), *(void**)(R_RSP + 104)); }
-void pFpippppppppppppppppp(x64emu_t *emu, uintptr_t fcn) { pFpippppppppppppppppp_t fn = (pFpippppppppppppppppp_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (int64_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56), *(void**)(R_RSP + 64), *(void**)(R_RSP + 72), *(void**)(R_RSP + 80), *(void**)(R_RSP + 88), *(void**)(R_RSP + 96), *(void**)(R_RSP + 104)); }
-void pFpppWWCCpCpCpCWpCpCpC(x64emu_t *emu, uintptr_t fcn) { pFpppWWCCpCpCpCWpCpCpC_t fn = (pFpppWWCCpCpCpCWpCpCpC_t)fcn; R_RAX=(uintptr_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (uint16_t)R_RCX, (uint16_t)R_R8, (uint8_t)R_R9, *(uint8_t*)(R_RSP + 8), *(void**)(R_RSP + 16), *(uint8_t*)(R_RSP + 24), *(void**)(R_RSP + 32), *(uint8_t*)(R_RSP + 40), *(void**)(R_RSP + 48), *(uint8_t*)(R_RSP + 56), *(uint16_t*)(R_RSP + 64), *(void**)(R_RSP + 72), *(uint8_t*)(R_RSP + 80), *(void**)(R_RSP + 88), *(uint8_t*)(R_RSP + 96), *(void**)(R_RSP + 104), *(uint8_t*)(R_RSP + 112)); }
-void iFpppppppppppppppppppppp(x64emu_t *emu, uintptr_t fcn) { iFpppppppppppppppppppppp_t fn = (iFpppppppppppppppppppppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56), *(void**)(R_RSP + 64), *(void**)(R_RSP + 72), *(void**)(R_RSP + 80), *(void**)(R_RSP + 88), *(void**)(R_RSP + 96), *(void**)(R_RSP + 104), *(void**)(R_RSP + 112), *(void**)(R_RSP + 120), *(void**)(R_RSP + 128)); }
-void vFpppppppppppppppppppppppp(x64emu_t *emu, uintptr_t fcn) { vFpppppppppppppppppppppppp_t fn = (vFpppppppppppppppppppppppp_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56), *(void**)(R_RSP + 64), *(void**)(R_RSP + 72), *(void**)(R_RSP + 80), *(void**)(R_RSP + 88), *(void**)(R_RSP + 96), *(void**)(R_RSP + 104), *(void**)(R_RSP + 112), *(void**)(R_RSP + 120), *(void**)(R_RSP + 128), *(void**)(R_RSP + 136), *(void**)(R_RSP + 144)); }
-void iFpppppppppppppppppppppppppppppppppp(x64emu_t *emu, uintptr_t fcn) { iFpppppppppppppppppppppppppppppppppp_t fn = (iFpppppppppppppppppppppppppppppppppp_t)fcn; R_RAX=(int64_t)fn((void*)R_RDI, (void*)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8), *(void**)(R_RSP + 16), *(void**)(R_RSP + 24), *(void**)(R_RSP + 32), *(void**)(R_RSP + 40), *(void**)(R_RSP + 48), *(void**)(R_RSP + 56), *(void**)(R_RSP + 64), *(void**)(R_RSP + 72), *(void**)(R_RSP + 80), *(void**)(R_RSP + 88), *(void**)(R_RSP + 96), *(void**)(R_RSP + 104), *(void**)(R_RSP + 112), *(void**)(R_RSP + 120), *(void**)(R_RSP + 128), *(void**)(R_RSP + 136), *(void**)(R_RSP + 144), *(void**)(R_RSP + 152), *(void**)(R_RSP + 160), *(void**)(R_RSP + 168), *(void**)(R_RSP + 176), *(void**)(R_RSP + 184), *(void**)(R_RSP + 192), *(void**)(R_RSP + 200), *(void**)(R_RSP + 208), *(void**)(R_RSP + 216), *(void**)(R_RSP + 224)); }
-
-#if defined(HAVE_LD80BITS)
-void IFD(x64emu_t *emu, uintptr_t fcn) { IFD_t fn = (IFD_t)fcn; R_RAX=(int64_t)fn(LD2localLD((void*)(R_RSP + 8))); }
-void DFD(x64emu_t *emu, uintptr_t fcn) { DFD_t fn = (DFD_t)fcn; long double ld=fn(LD2localLD((void*)(R_RSP + 8))); fpu_do_push(emu); ST0val = ld; }
-void vFppippDDC(x64emu_t *emu, uintptr_t fcn) { vFppippDDC_t fn = (vFppippDDC_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, LD2localLD((void*)(R_RSP + 8)), LD2localLD((void*)(R_RSP + 24)), (uint8_t)R_R9); }
-#endif
-
-#if !defined(HAVE_LD80BITS)
-void IFK(x64emu_t *emu, uintptr_t fcn) { IFK_t fn = (IFK_t)fcn; R_RAX=(int64_t)fn(FromLD((void*)(R_RSP + 8))); }
-void KFK(x64emu_t *emu, uintptr_t fcn) { KFK_t fn = (KFK_t)fcn; double db=fn(FromLD((void*)(R_RSP + 8))); fpu_do_push(emu); ST0val = db; }
-void KFKK(x64emu_t *emu, uintptr_t fcn) { KFKK_t fn = (KFKK_t)fcn; double db=fn(FromLD((void*)(R_RSP + 8)), FromLD((void*)(R_RSP + 24))); fpu_do_push(emu); ST0val = db; }
-void KFKp(x64emu_t *emu, uintptr_t fcn) { KFKp_t fn = (KFKp_t)fcn; double db=fn(FromLD((void*)(R_RSP + 8)), (void*)R_RDI); fpu_do_push(emu); ST0val = db; }
-void vFppippKKC(x64emu_t *emu, uintptr_t fcn) { vFppippKKC_t fn = (vFppippKKC_t)fcn; fn((void*)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (void*)R_RCX, (void*)R_R8, FromLD((void*)(R_RSP + 8)), FromLD((void*)(R_RSP + 24)), (uint8_t)R_R9); }
-#endif
-
-#if defined(NOALIGN)
-void iFipiip(x64emu_t *emu, uintptr_t fcn) { iFipiip_t fn = (iFipiip_t)fcn; R_RAX=(int64_t)fn((int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-#endif
-
-#if !defined(NOALIGN)
-void iFEppu(x64emu_t *emu, uintptr_t fcn) { iFEppu_t fn = (iFEppu_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RSI, (uint64_t)R_RDX); }
-void iFEiiip(x64emu_t *emu, uintptr_t fcn) { iFEiiip_t fn = (iFEiiip_t)fcn; R_RAX=(int64_t)fn(emu, (int64_t)R_RDI, (int64_t)R_RSI, (int64_t)R_RDX, (void*)R_RCX); }
-void iFEipii(x64emu_t *emu, uintptr_t fcn) { iFEipii_t fn = (iFEipii_t)fcn; R_RAX=(int64_t)fn(emu, (int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX); }
-void iFEipiip(x64emu_t *emu, uintptr_t fcn) { iFEipiip_t fn = (iFEipiip_t)fcn; R_RAX=(int64_t)fn(emu, (int64_t)R_RDI, (void*)R_RSI, (int64_t)R_RDX, (int64_t)R_RCX, (void*)R_R8); }
-#endif
-
-void vFEv(x64emu_t *emu, uintptr_t fcn) { vFE_t fn = (vFE_t)fcn; fn(emu); }
-void iFEv(x64emu_t *emu, uintptr_t fcn) { iFE_t fn = (iFE_t)fcn; R_RAX=(int64_t)fn(emu); }
-void lFEv(x64emu_t *emu, uintptr_t fcn) { lFE_t fn = (lFE_t)fcn; R_RAX=(intptr_t)fn(emu); }
-void pFEv(x64emu_t *emu, uintptr_t fcn) { pFE_t fn = (pFE_t)fcn; R_RAX=(uintptr_t)fn(emu); }
-void iFEvpp(x64emu_t *emu, uintptr_t fcn) { iFEpp_t fn = (iFEpp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RSI, (void*)R_RDX); }
-void pFEppv(x64emu_t *emu, uintptr_t fcn) { pFEpp_t fn = (pFEpp_t)fcn; R_RAX=(uintptr_t)fn(emu, (void*)R_RDI, (void*)R_RSI); }
-void iFEpvpp(x64emu_t *emu, uintptr_t fcn) { iFEppp_t fn = (iFEppp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RDX, (void*)R_RCX); }
-void iFEpvvppp(x64emu_t *emu, uintptr_t fcn) { iFEpppp_t fn = (iFEpppp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (void*)R_RCX, (void*)R_R8, (void*)R_R9); }
-void iFEpLvvpp(x64emu_t *emu, uintptr_t fcn) { iFEpLpp_t fn = (iFEpLpp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (uintptr_t)R_RSI, (void*)R_R8, (void*)R_R9); }
-void iFEpuvvppp(x64emu_t *emu, uintptr_t fcn) { iFEpuppp_t fn = (iFEpuppp_t)fcn; R_RAX=(int64_t)fn(emu, (void*)R_RDI, (uint64_t)R_RSI, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); }
-
-int isSimpleWrapper(wrapper_t fun) {
- if (fun == &vFv) return 1;
- if (fun == &vFi) return 1;
- if (fun == &vFu) return 1;
- if (fun == &vFU) return 1;
- if (fun == &vFf) return 2;
- if (fun == &vFd) return 2;
- if (fun == &vFl) return 1;
- if (fun == &vFL) return 1;
- if (fun == &vFp) return 1;
- if (fun == &cFv) return 1;
- if (fun == &cFi) return 1;
- if (fun == &cFu) return 1;
- if (fun == &cFf) return 2;
- if (fun == &cFp) return 1;
- if (fun == &wFp) return 1;
- if (fun == &iFv) return 1;
- if (fun == &iFw) return 1;
- if (fun == &iFi) return 1;
- if (fun == &iFI) return 1;
- if (fun == &iFC) return 1;
- if (fun == &iFW) return 1;
- if (fun == &iFu) return 1;
- if (fun == &iFU) return 1;
- if (fun == &iFf) return 2;
- if (fun == &iFd) return 2;
- if (fun == &iFl) return 1;
- if (fun == &iFL) return 1;
- if (fun == &iFp) return 1;
- if (fun == &IFv) return 1;
- if (fun == &IFi) return 1;
- if (fun == &IFI) return 1;
- if (fun == &IFf) return 2;
- if (fun == &IFd) return 2;
- if (fun == &IFp) return 1;
- if (fun == &CFC) return 1;
- if (fun == &CFp) return 1;
- if (fun == &WFi) return 1;
- if (fun == &WFW) return 1;
- if (fun == &WFp) return 1;
- if (fun == &uFv) return 1;
- if (fun == &uFi) return 1;
- if (fun == &uFu) return 1;
- if (fun == &uFd) return 2;
- if (fun == &uFl) return 1;
- if (fun == &uFL) return 1;
- if (fun == &uFp) return 1;
- if (fun == &UFv) return 1;
- if (fun == &UFu) return 1;
- if (fun == &UFp) return 1;
- if (fun == &fFi) return -1;
- if (fun == &fFf) return -2;
- if (fun == &fFp) return -1;
- if (fun == &dFv) return -1;
- if (fun == &dFi) return -1;
- if (fun == &dFu) return -1;
- if (fun == &dFd) return -2;
- if (fun == &dFp) return -1;
- if (fun == &lFv) return 1;
- if (fun == &lFi) return 1;
- if (fun == &lFu) return 1;
- if (fun == &lFl) return 1;
- if (fun == &lFp) return 1;
- if (fun == &LFv) return 1;
- if (fun == &LFu) return 1;
- if (fun == &LFL) return 1;
- if (fun == &LFp) return 1;
- if (fun == &pFv) return 1;
- if (fun == &pFw) return 1;
- if (fun == &pFi) return 1;
- if (fun == &pFI) return 1;
- if (fun == &pFC) return 1;
- if (fun == &pFW) return 1;
- if (fun == &pFu) return 1;
- if (fun == &pFU) return 1;
- if (fun == &pFd) return 2;
- if (fun == &pFl) return 1;
- if (fun == &pFL) return 1;
- if (fun == &pFp) return 1;
- if (fun == &vFii) return 1;
- if (fun == &vFiI) return 1;
- if (fun == &vFiu) return 1;
- if (fun == &vFiU) return 1;
- if (fun == &vFif) return 2;
- if (fun == &vFid) return 2;
- if (fun == &vFip) return 1;
- if (fun == &vFWW) return 1;
- if (fun == &vFWp) return 1;
- if (fun == &vFui) return 1;
- if (fun == &vFuu) return 1;
- if (fun == &vFuU) return 1;
- if (fun == &vFuf) return 2;
- if (fun == &vFud) return 2;
- if (fun == &vFul) return 1;
- if (fun == &vFup) return 1;
- if (fun == &vFUi) return 1;
- if (fun == &vFfi) return 2;
- if (fun == &vFff) return 3;
- if (fun == &vFfp) return 2;
- if (fun == &vFdd) return 3;
- if (fun == &vFlp) return 1;
- if (fun == &vFLL) return 1;
- if (fun == &vFLp) return 1;
- if (fun == &vFpc) return 1;
- if (fun == &vFpi) return 1;
- if (fun == &vFpI) return 1;
- if (fun == &vFpC) return 1;
- if (fun == &vFpW) return 1;
- if (fun == &vFpu) return 1;
- if (fun == &vFpU) return 1;
- if (fun == &vFpf) return 2;
- if (fun == &vFpd) return 2;
- if (fun == &vFpl) return 1;
- if (fun == &vFpL) return 1;
- if (fun == &vFpp) return 1;
- if (fun == &cFpp) return 1;
- if (fun == &iFwp) return 1;
- if (fun == &iFii) return 1;
- if (fun == &iFiu) return 1;
- if (fun == &iFil) return 1;
- if (fun == &iFiL) return 1;
- if (fun == &iFip) return 1;
- if (fun == &iFIi) return 1;
- if (fun == &iFui) return 1;
- if (fun == &iFuu) return 1;
- if (fun == &iFuU) return 1;
- if (fun == &iFuL) return 1;
- if (fun == &iFup) return 1;
- if (fun == &iFUp) return 1;
- if (fun == &iFli) return 1;
- if (fun == &iFlp) return 1;
- if (fun == &iFLu) return 1;
- if (fun == &iFLL) return 1;
- if (fun == &iFLp) return 1;
- if (fun == &iFpw) return 1;
- if (fun == &iFpi) return 1;
- if (fun == &iFpI) return 1;
- if (fun == &iFpC) return 1;
- if (fun == &iFpW) return 1;
- if (fun == &iFpu) return 1;
- if (fun == &iFpU) return 1;
- if (fun == &iFpf) return 2;
- if (fun == &iFpd) return 2;
- if (fun == &iFpl) return 1;
- if (fun == &iFpL) return 1;
- if (fun == &iFpp) return 1;
- if (fun == &IFII) return 1;
- if (fun == &IFpi) return 1;
- if (fun == &IFpu) return 1;
- if (fun == &IFpd) return 2;
- if (fun == &CFip) return 1;
- if (fun == &CFui) return 1;
- if (fun == &CFpi) return 1;
- if (fun == &CFpu) return 1;
- if (fun == &CFpp) return 1;
- if (fun == &WFpp) return 1;
- if (fun == &uFii) return 1;
- if (fun == &uFiu) return 1;
- if (fun == &uFip) return 1;
- if (fun == &uFui) return 1;
- if (fun == &uFuu) return 1;
- if (fun == &uFup) return 1;
- if (fun == &uFUp) return 1;
- if (fun == &uFpw) return 1;
- if (fun == &uFpi) return 1;
- if (fun == &uFpu) return 1;
- if (fun == &uFpU) return 1;
- if (fun == &uFpf) return 2;
- if (fun == &uFpL) return 1;
- if (fun == &uFpp) return 1;
- if (fun == &UFuu) return 1;
- if (fun == &UFUp) return 1;
- if (fun == &UFpi) return 1;
- if (fun == &UFpp) return 1;
- if (fun == &fFif) return -2;
- if (fun == &fFfi) return -2;
- if (fun == &fFff) return -3;
- if (fun == &fFfl) return -2;
- if (fun == &fFfp) return -2;
- if (fun == &fFpp) return -1;
- if (fun == &dFid) return -2;
- if (fun == &dFdi) return -2;
- if (fun == &dFdd) return -3;
- if (fun == &dFdl) return -2;
- if (fun == &dFdp) return -2;
- if (fun == &dFll) return -1;
- if (fun == &dFpi) return -1;
- if (fun == &dFpd) return -2;
- if (fun == &dFpp) return -1;
- if (fun == &lFii) return 1;
- if (fun == &lFll) return 1;
- if (fun == &lFpi) return 1;
- if (fun == &lFpl) return 1;
- if (fun == &lFpp) return 1;
- if (fun == &LFii) return 1;
- if (fun == &LFuu) return 1;
- if (fun == &LFLi) return 1;
- if (fun == &LFLL) return 1;
- if (fun == &LFpi) return 1;
- if (fun == &LFpL) return 1;
- if (fun == &LFpp) return 1;
- if (fun == &pFii) return 1;
- if (fun == &pFiI) return 1;
- if (fun == &pFiu) return 1;
- if (fun == &pFip) return 1;
- if (fun == &pFII) return 1;
- if (fun == &pFui) return 1;
- if (fun == &pFuC) return 1;
- if (fun == &pFuu) return 1;
- if (fun == &pFup) return 1;
- if (fun == &pFUi) return 1;
- if (fun == &pFUU) return 1;
- if (fun == &pFdi) return 2;
- if (fun == &pFdd) return 3;
- if (fun == &pFlp) return 1;
- if (fun == &pFLu) return 1;
- if (fun == &pFLL) return 1;
- if (fun == &pFLp) return 1;
- if (fun == &pFpi) return 1;
- if (fun == &pFpC) return 1;
- if (fun == &pFpu) return 1;
- if (fun == &pFpU) return 1;
- if (fun == &pFpd) return 2;
- if (fun == &pFpl) return 1;
- if (fun == &pFpL) return 1;
- if (fun == &pFpp) return 1;
- if (fun == &vFiii) return 1;
- if (fun == &vFiiu) return 1;
- if (fun == &vFiif) return 2;
- if (fun == &vFiip) return 1;
- if (fun == &vFiII) return 1;
- if (fun == &vFiui) return 1;
- if (fun == &vFiuu) return 1;
- if (fun == &vFiuU) return 1;
- if (fun == &vFiup) return 1;
- if (fun == &vFiUU) return 1;
- if (fun == &vFiff) return 3;
- if (fun == &vFidd) return 3;
- if (fun == &vFill) return 1;
- if (fun == &vFilp) return 1;
- if (fun == &vFipi) return 1;
- if (fun == &vFipu) return 1;
- if (fun == &vFipp) return 1;
- if (fun == &vFuii) return 1;
- if (fun == &vFuiI) return 1;
- if (fun == &vFuiu) return 1;
- if (fun == &vFuiU) return 1;
- if (fun == &vFuif) return 2;
- if (fun == &vFuid) return 2;
- if (fun == &vFuip) return 1;
- if (fun == &vFuui) return 1;
- if (fun == &vFuuu) return 1;
- if (fun == &vFuuU) return 1;
- if (fun == &vFuuf) return 2;
- if (fun == &vFuud) return 2;
- if (fun == &vFuup) return 1;
- if (fun == &vFuff) return 3;
- if (fun == &vFufp) return 2;
- if (fun == &vFudd) return 3;
- if (fun == &vFull) return 1;
- if (fun == &vFulp) return 1;
- if (fun == &vFuLp) return 1;
- if (fun == &vFupu) return 1;
- if (fun == &vFupp) return 1;
- if (fun == &vFfff) return 4;
- if (fun == &vFfpp) return 2;
- if (fun == &vFddd) return 4;
- if (fun == &vFdpp) return 2;
- if (fun == &vFlip) return 1;
- if (fun == &vFlll) return 1;
- if (fun == &vFllp) return 1;
- if (fun == &vFlpp) return 1;
- if (fun == &vFLup) return 1;
- if (fun == &vFLpL) return 1;
- if (fun == &vFLpp) return 1;
- if (fun == &vFpii) return 1;
- if (fun == &vFpiI) return 1;
- if (fun == &vFpiC) return 1;
- if (fun == &vFpiu) return 1;
- if (fun == &vFpif) return 2;
- if (fun == &vFpid) return 2;
- if (fun == &vFpip) return 1;
- if (fun == &vFpui) return 1;
- if (fun == &vFpuI) return 1;
- if (fun == &vFpuW) return 1;
- if (fun == &vFpuu) return 1;
- if (fun == &vFpuU) return 1;
- if (fun == &vFpup) return 1;
- if (fun == &vFpUi) return 1;
- if (fun == &vFpUu) return 1;
- if (fun == &vFpUU) return 1;
- if (fun == &vFpUf) return 2;
- if (fun == &vFpUp) return 1;
- if (fun == &vFpff) return 3;
- if (fun == &vFpdd) return 3;
- if (fun == &vFpll) return 1;
- if (fun == &vFplp) return 1;
- if (fun == &vFpLi) return 1;
- if (fun == &vFpLu) return 1;
- if (fun == &vFpLL) return 1;
- if (fun == &vFpLp) return 1;
- if (fun == &vFppi) return 1;
- if (fun == &vFppu) return 1;
- if (fun == &vFppU) return 1;
- if (fun == &vFppd) return 2;
- if (fun == &vFppl) return 1;
- if (fun == &vFppL) return 1;
- if (fun == &vFppp) return 1;
- if (fun == &iFwww) return 1;
- if (fun == &iFwpp) return 1;
- if (fun == &iFiwC) return 1;
- if (fun == &iFiii) return 1;
- if (fun == &iFiiu) return 1;
- if (fun == &iFiil) return 1;
- if (fun == &iFiip) return 1;
- if (fun == &iFiuu) return 1;
- if (fun == &iFill) return 1;
- if (fun == &iFiLi) return 1;
- if (fun == &iFiLp) return 1;
- if (fun == &iFipi) return 1;
- if (fun == &iFipu) return 1;
- if (fun == &iFipL) return 1;
- if (fun == &iFipp) return 1;
- if (fun == &iFCiW) return 1;
- if (fun == &iFuwp) return 1;
- if (fun == &iFuip) return 1;
- if (fun == &iFuui) return 1;
- if (fun == &iFuuu) return 1;
- if (fun == &iFuup) return 1;
- if (fun == &iFuUu) return 1;
- if (fun == &iFuff) return 3;
- if (fun == &iFuLL) return 1;
- if (fun == &iFuLp) return 1;
- if (fun == &iFupL) return 1;
- if (fun == &iFupp) return 1;
- if (fun == &iFfff) return 4;
- if (fun == &iFlip) return 1;
- if (fun == &iFLip) return 1;
- if (fun == &iFLLi) return 1;
- if (fun == &iFLpp) return 1;
- if (fun == &iFpwp) return 1;
- if (fun == &iFpii) return 1;
- if (fun == &iFpiI) return 1;
- if (fun == &iFpiu) return 1;
- if (fun == &iFpiU) return 1;
- if (fun == &iFpiL) return 1;
- if (fun == &iFpip) return 1;
- if (fun == &iFpIi) return 1;
- if (fun == &iFpII) return 1;
- if (fun == &iFpCp) return 1;
- if (fun == &iFpui) return 1;
- if (fun == &iFpuu) return 1;
- if (fun == &iFpuU) return 1;
- if (fun == &iFpuL) return 1;
- if (fun == &iFpup) return 1;
- if (fun == &iFpUi) return 1;
- if (fun == &iFpUu) return 1;
- if (fun == &iFpUU) return 1;
- if (fun == &iFpUp) return 1;
- if (fun == &iFpfu) return 2;
- if (fun == &iFpff) return 3;
- if (fun == &iFpdd) return 3;
- if (fun == &iFpli) return 1;
- if (fun == &iFpll) return 1;
- if (fun == &iFplp) return 1;
- if (fun == &iFpLi) return 1;
- if (fun == &iFpLu) return 1;
- if (fun == &iFpLL) return 1;
- if (fun == &iFpLp) return 1;
- if (fun == &iFppi) return 1;
- if (fun == &iFppI) return 1;
- if (fun == &iFppC) return 1;
- if (fun == &iFppW) return 1;
- if (fun == &iFppu) return 1;
- if (fun == &iFppU) return 1;
- if (fun == &iFppd) return 2;
- if (fun == &iFppl) return 1;
- if (fun == &iFppL) return 1;
- if (fun == &iFppp) return 1;
- if (fun == &IFiIi) return 1;
- if (fun == &IFpIi) return 1;
- if (fun == &IFppi) return 1;
- if (fun == &IFppI) return 1;
- if (fun == &IFppu) return 1;
- if (fun == &uFipu) return 1;
- if (fun == &uFuip) return 1;
- if (fun == &uFuuu) return 1;
- if (fun == &uFuup) return 1;
- if (fun == &uFufp) return 2;
- if (fun == &uFupu) return 1;
- if (fun == &uFupp) return 1;
- if (fun == &uFpii) return 1;
- if (fun == &uFpip) return 1;
- if (fun == &uFpCi) return 1;
- if (fun == &uFpWi) return 1;
- if (fun == &uFpWu) return 1;
- if (fun == &uFpWf) return 2;
- if (fun == &uFpWp) return 1;
- if (fun == &uFpui) return 1;
- if (fun == &uFpuC) return 1;
- if (fun == &uFpuu) return 1;
- if (fun == &uFpup) return 1;
- if (fun == &uFpfu) return 2;
- if (fun == &uFpLp) return 1;
- if (fun == &uFppi) return 1;
- if (fun == &uFppu) return 1;
- if (fun == &uFppp) return 1;
- if (fun == &UFUUU) return 1;
- if (fun == &UFpiU) return 1;
- if (fun == &UFppi) return 1;
- if (fun == &UFppu) return 1;
- if (fun == &fFull) return -1;
- if (fun == &fFfff) return -4;
- if (fun == &fFffp) return -3;
- if (fun == &fFppi) return -1;
- if (fun == &fFppL) return -1;
- if (fun == &fFppp) return -1;
- if (fun == &dFddd) return -4;
- if (fun == &dFddp) return -3;
- if (fun == &dFpdd) return -3;
- if (fun == &dFppi) return -1;
- if (fun == &dFppp) return -1;
- if (fun == &lFili) return 1;
- if (fun == &lFilL) return 1;
- if (fun == &lFipi) return 1;
- if (fun == &lFipL) return 1;
- if (fun == &lFlll) return 1;
- if (fun == &lFpli) return 1;
- if (fun == &lFpLu) return 1;
- if (fun == &lFpLp) return 1;
- if (fun == &lFppi) return 1;
- if (fun == &lFppL) return 1;
- if (fun == &lFppp) return 1;
- if (fun == &LFipL) return 1;
- if (fun == &LFLLl) return 1;
- if (fun == &LFLpu) return 1;
- if (fun == &LFLpL) return 1;
- if (fun == &LFpii) return 1;
- if (fun == &LFpip) return 1;
- if (fun == &LFpLi) return 1;
- if (fun == &LFpLp) return 1;
- if (fun == &LFppi) return 1;
- if (fun == &LFppL) return 1;
- if (fun == &LFppp) return 1;
- if (fun == &pFiii) return 1;
- if (fun == &pFiiu) return 1;
- if (fun == &pFiip) return 1;
- if (fun == &pFiIi) return 1;
- if (fun == &pFiIp) return 1;
- if (fun == &pFipi) return 1;
- if (fun == &pFipL) return 1;
- if (fun == &pFipp) return 1;
- if (fun == &pFIpi) return 1;
- if (fun == &pFCiW) return 1;
- if (fun == &pFWWW) return 1;
- if (fun == &pFuii) return 1;
- if (fun == &pFuui) return 1;
- if (fun == &pFuuu) return 1;
- if (fun == &pFupi) return 1;
- if (fun == &pFupL) return 1;
- if (fun == &pFUpi) return 1;
- if (fun == &pFdip) return 2;
- if (fun == &pFdUU) return 2;
- if (fun == &pFddd) return 4;
- if (fun == &pFLup) return 1;
- if (fun == &pFLLp) return 1;
- if (fun == &pFpii) return 1;
- if (fun == &pFpiu) return 1;
- if (fun == &pFpid) return 2;
- if (fun == &pFpil) return 1;
- if (fun == &pFpiL) return 1;
- if (fun == &pFpip) return 1;
- if (fun == &pFpCC) return 1;
- if (fun == &pFpCu) return 1;
- if (fun == &pFpWW) return 1;
- if (fun == &pFpui) return 1;
- if (fun == &pFpuu) return 1;
- if (fun == &pFpuL) return 1;
- if (fun == &pFpup) return 1;
- if (fun == &pFpUi) return 1;
- if (fun == &pFpUp) return 1;
- if (fun == &pFpdu) return 2;
- if (fun == &pFplC) return 1;
- if (fun == &pFplu) return 1;
- if (fun == &pFpll) return 1;
- if (fun == &pFplp) return 1;
- if (fun == &pFpLu) return 1;
- if (fun == &pFpLL) return 1;
- if (fun == &pFpLp) return 1;
- if (fun == &pFppi) return 1;
- if (fun == &pFppI) return 1;
- if (fun == &pFppC) return 1;
- if (fun == &pFppu) return 1;
- if (fun == &pFppU) return 1;
- if (fun == &pFppf) return 2;
- if (fun == &pFppl) return 1;
- if (fun == &pFppL) return 1;
- if (fun == &pFppp) return 1;
- if (fun == &vFiiii) return 1;
- if (fun == &vFiiip) return 1;
- if (fun == &vFiill) return 1;
- if (fun == &vFiIII) return 1;
- if (fun == &vFiuiu) return 1;
- if (fun == &vFiuip) return 1;
- if (fun == &vFiuuu) return 1;
- if (fun == &vFiuup) return 1;
- if (fun == &vFiulp) return 1;
- if (fun == &vFiupu) return 1;
- if (fun == &vFiUUU) return 1;
- if (fun == &vFifff) return 4;
- if (fun == &vFiddd) return 4;
- if (fun == &vFilil) return 1;
- if (fun == &vFilip) return 1;
- if (fun == &vFiluU) return 1;
- if (fun == &vFilpu) return 1;
- if (fun == &vFilpp) return 1;
- if (fun == &vFipii) return 1;
- if (fun == &vFipup) return 1;
- if (fun == &vFipll) return 1;
- if (fun == &vFippi) return 1;
- if (fun == &vFippu) return 1;
- if (fun == &vFippp) return 1;
- if (fun == &vFuiii) return 1;
- if (fun == &vFuiiu) return 1;
- if (fun == &vFuiip) return 1;
- if (fun == &vFuiII) return 1;
- if (fun == &vFuiui) return 1;
- if (fun == &vFuiuu) return 1;
- if (fun == &vFuiup) return 1;
- if (fun == &vFuiUU) return 1;
- if (fun == &vFuifi) return 2;
- if (fun == &vFuiff) return 3;
- if (fun == &vFuidd) return 3;
- if (fun == &vFuill) return 1;
- if (fun == &vFuilp) return 1;
- if (fun == &vFuipi) return 1;
- if (fun == &vFuipu) return 1;
- if (fun == &vFuipp) return 1;
- if (fun == &vFuuii) return 1;
- if (fun == &vFuuiu) return 1;
- if (fun == &vFuuil) return 1;
- if (fun == &vFuuip) return 1;
- if (fun == &vFuuui) return 1;
- if (fun == &vFuuuu) return 1;
- if (fun == &vFuuuf) return 2;
- if (fun == &vFuuud) return 2;
- if (fun == &vFuuup) return 1;
- if (fun == &vFuulp) return 1;
- if (fun == &vFuupi) return 1;
- if (fun == &vFuupp) return 1;
- if (fun == &vFuUii) return 1;
- if (fun == &vFuUip) return 1;
- if (fun == &vFufff) return 4;
- if (fun == &vFuddd) return 4;
- if (fun == &vFulil) return 1;
- if (fun == &vFulip) return 1;
- if (fun == &vFuluU) return 1;
- if (fun == &vFullp) return 1;
- if (fun == &vFulpi) return 1;
- if (fun == &vFulpu) return 1;
- if (fun == &vFulpp) return 1;
- if (fun == &vFupii) return 1;
- if (fun == &vFuppi) return 1;
- if (fun == &vFUUpi) return 1;
- if (fun == &vFffff) return 5;
- if (fun == &vFdddd) return 5;
- if (fun == &vFllll) return 1;
- if (fun == &vFpiii) return 1;
- if (fun == &vFpiiu) return 1;
- if (fun == &vFpiip) return 1;
- if (fun == &vFpiuu) return 1;
- if (fun == &vFpiuL) return 1;
- if (fun == &vFpiup) return 1;
- if (fun == &vFpiUu) return 1;
- if (fun == &vFpiUU) return 1;
- if (fun == &vFpifi) return 2;
- if (fun == &vFpipi) return 1;
- if (fun == &vFpipp) return 1;
- if (fun == &vFpIdi) return 2;
- if (fun == &vFpCiW) return 1;
- if (fun == &vFpuip) return 1;
- if (fun == &vFpuui) return 1;
- if (fun == &vFpuuu) return 1;
- if (fun == &vFpuup) return 1;
- if (fun == &vFpudd) return 3;
- if (fun == &vFpupp) return 1;
- if (fun == &vFpUui) return 1;
- if (fun == &vFpUuu) return 1;
- if (fun == &vFpUup) return 1;
- if (fun == &vFpUUi) return 1;
- if (fun == &vFpUUu) return 1;
- if (fun == &vFpUUp) return 1;
- if (fun == &vFpUpp) return 1;
- if (fun == &vFpfff) return 4;
- if (fun == &vFpdii) return 2;
- if (fun == &vFpdip) return 2;
- if (fun == &vFpddi) return 3;
- if (fun == &vFpddd) return 4;
- if (fun == &vFplpp) return 1;
- if (fun == &vFpLLL) return 1;
- if (fun == &vFppii) return 1;
- if (fun == &vFppiu) return 1;
- if (fun == &vFppid) return 2;
- if (fun == &vFppil) return 1;
- if (fun == &vFppiL) return 1;
- if (fun == &vFppip) return 1;
- if (fun == &vFppui) return 1;
- if (fun == &vFppuu) return 1;
- if (fun == &vFppup) return 1;
- if (fun == &vFppfi) return 2;
- if (fun == &vFppdu) return 2;
- if (fun == &vFppdd) return 3;
- if (fun == &vFppdp) return 2;
- if (fun == &vFpplp) return 1;
- if (fun == &vFppLp) return 1;
- if (fun == &vFpppi) return 1;
- if (fun == &vFpppI) return 1;
- if (fun == &vFpppu) return 1;
- if (fun == &vFpppU) return 1;
- if (fun == &vFpppd) return 2;
- if (fun == &vFpppL) return 1;
- if (fun == &vFpppp) return 1;
- if (fun == &cFpiii) return 1;
- if (fun == &iFwwww) return 1;
- if (fun == &iFwppp) return 1;
- if (fun == &iFiiii) return 1;
- if (fun == &iFiiiu) return 1;
- if (fun == &iFiiip) return 1;
- if (fun == &iFiiui) return 1;
- if (fun == &iFiiup) return 1;
- if (fun == &iFiill) return 1;
- if (fun == &iFiipi) return 1;
- if (fun == &iFiipp) return 1;
- if (fun == &iFiuwp) return 1;
- if (fun == &iFiuii) return 1;
- if (fun == &iFiuup) return 1;
- if (fun == &iFiupp) return 1;
- if (fun == &iFilli) return 1;
- if (fun == &iFillu) return 1;
- if (fun == &iFipii) return 1;
- if (fun == &iFipip) return 1;
- if (fun == &iFipui) return 1;
- if (fun == &iFipuu) return 1;
- if (fun == &iFipup) return 1;
- if (fun == &iFipLi) return 1;
- if (fun == &iFipLu) return 1;
- if (fun == &iFipLp) return 1;
- if (fun == &iFippi) return 1;
- if (fun == &iFippu) return 1;
- if (fun == &iFippL) return 1;
- if (fun == &iFippp) return 1;
- if (fun == &iFuipu) return 1;
- if (fun == &iFuipp) return 1;
- if (fun == &iFuuff) return 3;
- if (fun == &iFuupi) return 1;
- if (fun == &iFupLp) return 1;
- if (fun == &iFuppi) return 1;
- if (fun == &iFuppp) return 1;
- if (fun == &iFLLiW) return 1;
- if (fun == &iFpwww) return 1;
- if (fun == &iFpwpp) return 1;
- if (fun == &iFpiii) return 1;
- if (fun == &iFpiiI) return 1;
- if (fun == &iFpiiu) return 1;
- if (fun == &iFpiid) return 2;
- if (fun == &iFpiiL) return 1;
- if (fun == &iFpiip) return 1;
- if (fun == &iFpiuu) return 1;
- if (fun == &iFpiuL) return 1;
- if (fun == &iFpiup) return 1;
- if (fun == &iFpiUp) return 1;
- if (fun == &iFpild) return 2;
- if (fun == &iFpipi) return 1;
- if (fun == &iFpipC) return 1;
- if (fun == &iFpipu) return 1;
- if (fun == &iFpipL) return 1;
- if (fun == &iFpipp) return 1;
- if (fun == &iFpIip) return 1;
- if (fun == &iFpCCC) return 1;
- if (fun == &iFpCpi) return 1;
- if (fun == &iFpWWu) return 1;
- if (fun == &iFpuwp) return 1;
- if (fun == &iFpuiL) return 1;
- if (fun == &iFpuip) return 1;
- if (fun == &iFpuui) return 1;
- if (fun == &iFpuuu) return 1;
- if (fun == &iFpuup) return 1;
- if (fun == &iFpuUp) return 1;
- if (fun == &iFpuLL) return 1;
- if (fun == &iFpuLp) return 1;
- if (fun == &iFpupi) return 1;
- if (fun == &iFpupu) return 1;
- if (fun == &iFpupU) return 1;
- if (fun == &iFpupL) return 1;
- if (fun == &iFpupp) return 1;
- if (fun == &iFpUup) return 1;
- if (fun == &iFpUUU) return 1;
- if (fun == &iFpULp) return 1;
- if (fun == &iFpUpp) return 1;
- if (fun == &iFplii) return 1;
- if (fun == &iFplip) return 1;
- if (fun == &iFpLii) return 1;
- if (fun == &iFpLip) return 1;
- if (fun == &iFpLLu) return 1;
- if (fun == &iFpLpi) return 1;
- if (fun == &iFpLpf) return 2;
- if (fun == &iFpLpd) return 2;
- if (fun == &iFpLpL) return 1;
- if (fun == &iFpLpp) return 1;
- if (fun == &iFppii) return 1;
- if (fun == &iFppiu) return 1;
- if (fun == &iFppiU) return 1;
- if (fun == &iFppiL) return 1;
- if (fun == &iFppip) return 1;
- if (fun == &iFppIL) return 1;
- if (fun == &iFppCC) return 1;
- if (fun == &iFppuw) return 1;
- if (fun == &iFppui) return 1;
- if (fun == &iFppuu) return 1;
- if (fun == &iFppup) return 1;
- if (fun == &iFppdp) return 2;
- if (fun == &iFppll) return 1;
- if (fun == &iFpplp) return 1;
- if (fun == &iFppLi) return 1;
- if (fun == &iFppLL) return 1;
- if (fun == &iFppLp) return 1;
- if (fun == &iFpppi) return 1;
- if (fun == &iFpppC) return 1;
- if (fun == &iFpppu) return 1;
- if (fun == &iFpppU) return 1;
- if (fun == &iFpppL) return 1;
- if (fun == &iFpppp) return 1;
- if (fun == &IFpIip) return 1;
- if (fun == &IFppii) return 1;
- if (fun == &IFppip) return 1;
- if (fun == &IFpppp) return 1;
- if (fun == &CFpupp) return 1;
- if (fun == &uFifff) return 4;
- if (fun == &uFuuuu) return 1;
- if (fun == &uFpiip) return 1;
- if (fun == &uFpipu) return 1;
- if (fun == &uFpipp) return 1;
- if (fun == &uFpCCC) return 1;
- if (fun == &uFpuip) return 1;
- if (fun == &uFpuuu) return 1;
- if (fun == &uFpuup) return 1;
- if (fun == &uFpupu) return 1;
- if (fun == &uFppiu) return 1;
- if (fun == &uFppLp) return 1;
- if (fun == &uFpppi) return 1;
- if (fun == &uFpppu) return 1;
- if (fun == &uFpppp) return 1;
- if (fun == &UFpipp) return 1;
- if (fun == &UFpUui) return 1;
- if (fun == &UFppii) return 1;
- if (fun == &UFppip) return 1;
- if (fun == &UFpppp) return 1;
- if (fun == &dFpppp) return -1;
- if (fun == &lFiiLu) return 1;
- if (fun == &lFiipL) return 1;
- if (fun == &lFipil) return 1;
- if (fun == &lFipLi) return 1;
- if (fun == &lFipLI) return 1;
- if (fun == &lFipLu) return 1;
- if (fun == &lFipLl) return 1;
- if (fun == &lFipLL) return 1;
- if (fun == &lFipLp) return 1;
- if (fun == &lFippL) return 1;
- if (fun == &lFuipp) return 1;
- if (fun == &lFpili) return 1;
- if (fun == &lFpilp) return 1;
- if (fun == &lFppii) return 1;
- if (fun == &lFppip) return 1;
- if (fun == &lFpppL) return 1;
- if (fun == &LFippL) return 1;
- if (fun == &LFippp) return 1;
- if (fun == &LFpuuu) return 1;
- if (fun == &LFpLCL) return 1;
- if (fun == &LFpLLp) return 1;
- if (fun == &LFpLpL) return 1;
- if (fun == &LFpLpp) return 1;
- if (fun == &LFppii) return 1;
- if (fun == &LFppip) return 1;
- if (fun == &LFppLL) return 1;
- if (fun == &LFppLp) return 1;
- if (fun == &LFpppi) return 1;
- if (fun == &LFpppp) return 1;
- if (fun == &pFiiii) return 1;
- if (fun == &pFiiiu) return 1;
- if (fun == &pFiiuu) return 1;
- if (fun == &pFiiup) return 1;
- if (fun == &pFiipi) return 1;
- if (fun == &pFiipp) return 1;
- if (fun == &pFiIIi) return 1;
- if (fun == &pFillu) return 1;
- if (fun == &pFipii) return 1;
- if (fun == &pFipip) return 1;
- if (fun == &pFippi) return 1;
- if (fun == &pFippu) return 1;
- if (fun == &pFuiii) return 1;
- if (fun == &pFuuii) return 1;
- if (fun == &pFulli) return 1;
- if (fun == &pFullu) return 1;
- if (fun == &pFffff) return 5;
- if (fun == &pFdipp) return 2;
- if (fun == &pFdddd) return 5;
- if (fun == &pFlfff) return 4;
- if (fun == &pFLiip) return 1;
- if (fun == &pFpiii) return 1;
- if (fun == &pFpiip) return 1;
- if (fun == &pFpiuu) return 1;
- if (fun == &pFpiLL) return 1;
- if (fun == &pFpipi) return 1;
- if (fun == &pFpipd) return 2;
- if (fun == &pFpipp) return 1;
- if (fun == &pFpCWp) return 1;
- if (fun == &pFpCuW) return 1;
- if (fun == &pFpCuu) return 1;
- if (fun == &pFpuii) return 1;
- if (fun == &pFpuip) return 1;
- if (fun == &pFpuWp) return 1;
- if (fun == &pFpuuC) return 1;
- if (fun == &pFpuuu) return 1;
- if (fun == &pFpuup) return 1;
- if (fun == &pFpupi) return 1;
- if (fun == &pFpupu) return 1;
- if (fun == &pFpdIU) return 2;
- if (fun == &pFplpl) return 1;
- if (fun == &pFplpp) return 1;
- if (fun == &pFpLip) return 1;
- if (fun == &pFpLLp) return 1;
- if (fun == &pFpLpL) return 1;
- if (fun == &pFppii) return 1;
- if (fun == &pFppiu) return 1;
- if (fun == &pFppiL) return 1;
- if (fun == &pFppip) return 1;
- if (fun == &pFppWW) return 1;
- if (fun == &pFppuW) return 1;
- if (fun == &pFppuu) return 1;
- if (fun == &pFppuL) return 1;
- if (fun == &pFppup) return 1;
- if (fun == &pFppUU) return 1;
- if (fun == &pFppdd) return 3;
- if (fun == &pFppll) return 1;
- if (fun == &pFppLL) return 1;
- if (fun == &pFppLp) return 1;
- if (fun == &pFpppi) return 1;
- if (fun == &pFpppu) return 1;
- if (fun == &pFpppU) return 1;
- if (fun == &pFpppL) return 1;
- if (fun == &pFpppp) return 1;
- if (fun == &vFiiiii) return 1;
- if (fun == &vFiiiiu) return 1;
- if (fun == &vFiiipi) return 1;
- if (fun == &vFiiuii) return 1;
- if (fun == &vFiiuup) return 1;
- if (fun == &vFiillu) return 1;
- if (fun == &vFiilll) return 1;
- if (fun == &vFiipii) return 1;
- if (fun == &vFiipll) return 1;
- if (fun == &vFiIIII) return 1;
- if (fun == &vFiuiip) return 1;
- if (fun == &vFiuipi) return 1;
- if (fun == &vFiuuuu) return 1;
- if (fun == &vFiulpp) return 1;
- if (fun == &vFiuppu) return 1;
- if (fun == &vFiUUUU) return 1;
- if (fun == &vFiffff) return 5;
- if (fun == &vFidddd) return 5;
- if (fun == &vFilill) return 1;
- if (fun == &vFilipi) return 1;
- if (fun == &vFilipl) return 1;
- if (fun == &vFillpu) return 1;
- if (fun == &vFipipu) return 1;
- if (fun == &vFipipp) return 1;
- if (fun == &vFipupi) return 1;
- if (fun == &vFiplli) return 1;
- if (fun == &vFiplll) return 1;
- if (fun == &vFuiiii) return 1;
- if (fun == &vFuiiiu) return 1;
- if (fun == &vFuiiip) return 1;
- if (fun == &vFuiifi) return 2;
- if (fun == &vFuiill) return 1;
- if (fun == &vFuiilp) return 1;
- if (fun == &vFuiIII) return 1;
- if (fun == &vFuiuii) return 1;
- if (fun == &vFuiuiu) return 1;
- if (fun == &vFuiuip) return 1;
- if (fun == &vFuiuuu) return 1;
- if (fun == &vFuiuup) return 1;
- if (fun == &vFuiull) return 1;
- if (fun == &vFuiupi) return 1;
- if (fun == &vFuiUUU) return 1;
- if (fun == &vFuifff) return 4;
- if (fun == &vFuiddd) return 4;
- if (fun == &vFuipii) return 1;
- if (fun == &vFuipip) return 1;
- if (fun == &vFuipup) return 1;
- if (fun == &vFuippp) return 1;
- if (fun == &vFuuiii) return 1;
- if (fun == &vFuuiiu) return 1;
- if (fun == &vFuuiui) return 1;
- if (fun == &vFuuiuu) return 1;
- if (fun == &vFuuiup) return 1;
- if (fun == &vFuuipi) return 1;
- if (fun == &vFuuipu) return 1;
- if (fun == &vFuuipp) return 1;
- if (fun == &vFuuuii) return 1;
- if (fun == &vFuuuiu) return 1;
- if (fun == &vFuuuip) return 1;
- if (fun == &vFuuuui) return 1;
- if (fun == &vFuuuuu) return 1;
- if (fun == &vFuuuup) return 1;
- if (fun == &vFuuull) return 1;
- if (fun == &vFuuulp) return 1;
- if (fun == &vFuulll) return 1;
- if (fun == &vFuullp) return 1;
- if (fun == &vFuulpp) return 1;
- if (fun == &vFuupii) return 1;
- if (fun == &vFuffff) return 5;
- if (fun == &vFudddd) return 5;
- if (fun == &vFulill) return 1;
- if (fun == &vFullip) return 1;
- if (fun == &vFullpp) return 1;
- if (fun == &vFupupi) return 1;
- if (fun == &vFuppip) return 1;
- if (fun == &vFupppp) return 1;
- if (fun == &vFUUppp) return 1;
- if (fun == &vFfffff) return 6;
- if (fun == &vFddddp) return 5;
- if (fun == &vFpiiii) return 1;
- if (fun == &vFpiiiI) return 1;
- if (fun == &vFpiiiu) return 1;
- if (fun == &vFpiiip) return 1;
- if (fun == &vFpiiII) return 1;
- if (fun == &vFpiiff) return 3;
- if (fun == &vFpiipp) return 1;
- if (fun == &vFpiIiI) return 1;
- if (fun == &vFpiIII) return 1;
- if (fun == &vFpiUUp) return 1;
- if (fun == &vFpilpp) return 1;
- if (fun == &vFpipii) return 1;
- if (fun == &vFpipiu) return 1;
- if (fun == &vFpuiip) return 1;
- if (fun == &vFpuipp) return 1;
- if (fun == &vFpuuuu) return 1;
- if (fun == &vFpuuup) return 1;
- if (fun == &vFpuupp) return 1;
- if (fun == &vFpuUUu) return 1;
- if (fun == &vFpuddd) return 4;
- if (fun == &vFpupup) return 1;
- if (fun == &vFpUuiu) return 1;
- if (fun == &vFpUUuu) return 1;
- if (fun == &vFpUUup) return 1;
- if (fun == &vFpUUUu) return 1;
- if (fun == &vFpUUUp) return 1;
- if (fun == &vFpUppp) return 1;
- if (fun == &vFpffff) return 5;
- if (fun == &vFpdiII) return 2;
- if (fun == &vFpddii) return 3;
- if (fun == &vFpdddd) return 5;
- if (fun == &vFpddpp) return 3;
- if (fun == &vFpliil) return 1;
- if (fun == &vFplppp) return 1;
- if (fun == &vFpLLpp) return 1;
- if (fun == &vFppiii) return 1;
- if (fun == &vFppiiu) return 1;
- if (fun == &vFppiip) return 1;
- if (fun == &vFppiup) return 1;
- if (fun == &vFppiff) return 3;
- if (fun == &vFppipi) return 1;
- if (fun == &vFppipp) return 1;
- if (fun == &vFppWui) return 1;
- if (fun == &vFppuui) return 1;
- if (fun == &vFppuuu) return 1;
- if (fun == &vFppuup) return 1;
- if (fun == &vFppupi) return 1;
- if (fun == &vFppupp) return 1;
- if (fun == &vFppddp) return 3;
- if (fun == &vFpppii) return 1;
- if (fun == &vFpppip) return 1;
- if (fun == &vFpppuu) return 1;
- if (fun == &vFpppup) return 1;
- if (fun == &vFpppdd) return 3;
- if (fun == &vFppppi) return 1;
- if (fun == &vFppppu) return 1;
- if (fun == &vFppppL) return 1;
- if (fun == &vFppppp) return 1;
- if (fun == &iFiiipu) return 1;
- if (fun == &iFiiipp) return 1;
- if (fun == &iFiiupp) return 1;
- if (fun == &iFiipup) return 1;
- if (fun == &iFiuLip) return 1;
- if (fun == &iFipiii) return 1;
- if (fun == &iFipiup) return 1;
- if (fun == &iFipipi) return 1;
- if (fun == &iFipipu) return 1;
- if (fun == &iFipuip) return 1;
- if (fun == &iFipuui) return 1;
- if (fun == &iFipLup) return 1;
- if (fun == &iFippip) return 1;
- if (fun == &iFippLi) return 1;
- if (fun == &iFippLp) return 1;
- if (fun == &iFipppi) return 1;
- if (fun == &iFipppp) return 1;
- if (fun == &iFuppLp) return 1;
- if (fun == &iFpwwww) return 1;
- if (fun == &iFpwppp) return 1;
- if (fun == &iFpiiii) return 1;
- if (fun == &iFpiiiu) return 1;
- if (fun == &iFpiiiL) return 1;
- if (fun == &iFpiiip) return 1;
- if (fun == &iFpiiui) return 1;
- if (fun == &iFpiiuu) return 1;
- if (fun == &iFpiipi) return 1;
- if (fun == &iFpiipp) return 1;
- if (fun == &iFpiIip) return 1;
- if (fun == &iFpiuwp) return 1;
- if (fun == &iFpiUUU) return 1;
- if (fun == &iFpipii) return 1;
- if (fun == &iFpipiu) return 1;
- if (fun == &iFpipiL) return 1;
- if (fun == &iFpipip) return 1;
- if (fun == &iFpippi) return 1;
- if (fun == &iFpippW) return 1;
- if (fun == &iFpippp) return 1;
- if (fun == &iFpCCCC) return 1;
- if (fun == &iFpuill) return 1;
- if (fun == &iFpuipi) return 1;
- if (fun == &iFpuuip) return 1;
- if (fun == &iFpuuui) return 1;
- if (fun == &iFpuuup) return 1;
- if (fun == &iFpuuLL) return 1;
- if (fun == &iFpuupp) return 1;
- if (fun == &iFpupiU) return 1;
- if (fun == &iFpupup) return 1;
- if (fun == &iFpuppp) return 1;
- if (fun == &iFpUiUi) return 1;
- if (fun == &iFpUupp) return 1;
- if (fun == &iFplluu) return 1;
- if (fun == &iFpLiLi) return 1;
- if (fun == &iFpLlpp) return 1;
- if (fun == &iFpLLpp) return 1;
- if (fun == &iFpLppi) return 1;
- if (fun == &iFppiiu) return 1;
- if (fun == &iFppiip) return 1;
- if (fun == &iFppiup) return 1;
- if (fun == &iFppiLi) return 1;
- if (fun == &iFppiLL) return 1;
- if (fun == &iFppipi) return 1;
- if (fun == &iFppipp) return 1;
- if (fun == &iFppuwp) return 1;
- if (fun == &iFppuip) return 1;
- if (fun == &iFppuup) return 1;
- if (fun == &iFppupi) return 1;
- if (fun == &iFppupp) return 1;
- if (fun == &iFppllp) return 1;
- if (fun == &iFpplpp) return 1;
- if (fun == &iFppLip) return 1;
- if (fun == &iFppLpi) return 1;
- if (fun == &iFppLpL) return 1;
- if (fun == &iFppLpp) return 1;
- if (fun == &iFpppii) return 1;
- if (fun == &iFpppiL) return 1;
- if (fun == &iFpppip) return 1;
- if (fun == &iFpppui) return 1;
- if (fun == &iFpppUi) return 1;
- if (fun == &iFpppLi) return 1;
- if (fun == &iFpppLp) return 1;
- if (fun == &iFppppi) return 1;
- if (fun == &iFppppL) return 1;
- if (fun == &iFppppp) return 1;
- if (fun == &IFppIII) return 1;
- if (fun == &uFiuuuu) return 1;
- if (fun == &uFipipp) return 1;
- if (fun == &uFipLpp) return 1;
- if (fun == &uFuiiiu) return 1;
- if (fun == &uFpCCCC) return 1;
- if (fun == &uFpWuip) return 1;
- if (fun == &uFpuuuu) return 1;
- if (fun == &uFpupuu) return 1;
- if (fun == &uFppiip) return 1;
- if (fun == &uFppipp) return 1;
- if (fun == &uFppuup) return 1;
- if (fun == &uFppupp) return 1;
- if (fun == &uFpplip) return 1;
- if (fun == &uFppLpp) return 1;
- if (fun == &uFppppu) return 1;
- if (fun == &uFppppp) return 1;
- if (fun == &UFuiiii) return 1;
- if (fun == &lFipili) return 1;
- if (fun == &lFipLli) return 1;
- if (fun == &lFipLlL) return 1;
- if (fun == &lFipLLi) return 1;
- if (fun == &lFipLpp) return 1;
- if (fun == &LFpuipp) return 1;
- if (fun == &LFpuppi) return 1;
- if (fun == &LFpLLLp) return 1;
- if (fun == &LFpLppL) return 1;
- if (fun == &LFpLppp) return 1;
- if (fun == &LFppLLp) return 1;
- if (fun == &LFpppii) return 1;
- if (fun == &LFppppp) return 1;
- if (fun == &pFiiiii) return 1;
- if (fun == &pFiiipL) return 1;
- if (fun == &pFipipL) return 1;
- if (fun == &pFipppu) return 1;
- if (fun == &pFuiiiu) return 1;
- if (fun == &pFuiipp) return 1;
- if (fun == &pFpiiii) return 1;
- if (fun == &pFpiiip) return 1;
- if (fun == &pFpiiuu) return 1;
- if (fun == &pFpiipi) return 1;
- if (fun == &pFpiipp) return 1;
- if (fun == &pFpiCCC) return 1;
- if (fun == &pFpiuuu) return 1;
- if (fun == &pFpippi) return 1;
- if (fun == &pFpippp) return 1;
- if (fun == &pFpCpup) return 1;
- if (fun == &pFpCppp) return 1;
- if (fun == &pFpuiii) return 1;
- if (fun == &pFpuiip) return 1;
- if (fun == &pFpuWWW) return 1;
- if (fun == &pFpuuip) return 1;
- if (fun == &pFpuuWW) return 1;
- if (fun == &pFpuuuu) return 1;
- if (fun == &pFpuuup) return 1;
- if (fun == &pFpuppp) return 1;
- if (fun == &pFpUdii) return 2;
- if (fun == &pFpdddd) return 5;
- if (fun == &pFplppp) return 1;
- if (fun == &pFppiii) return 1;
- if (fun == &pFppiip) return 1;
- if (fun == &pFppiup) return 1;
- if (fun == &pFppipi) return 1;
- if (fun == &pFppipp) return 1;
- if (fun == &pFppuuu) return 1;
- if (fun == &pFppuup) return 1;
- if (fun == &pFppddi) return 3;
- if (fun == &pFppLii) return 1;
- if (fun == &pFppLLp) return 1;
- if (fun == &pFpppii) return 1;
- if (fun == &pFpppip) return 1;
- if (fun == &pFpppIi) return 1;
- if (fun == &pFpppui) return 1;
- if (fun == &pFpppuu) return 1;
- if (fun == &pFpppup) return 1;
- if (fun == &pFpppLi) return 1;
- if (fun == &pFppppi) return 1;
- if (fun == &pFppppu) return 1;
- if (fun == &pFppppp) return 1;
- if (fun == &vFiiiiii) return 1;
- if (fun == &vFiiiuil) return 1;
- if (fun == &vFiiilpi) return 1;
- if (fun == &vFiiuiil) return 1;
- if (fun == &vFiiuilp) return 1;
- if (fun == &vFiiuulp) return 1;
- if (fun == &vFiililp) return 1;
- if (fun == &vFiiplli) return 1;
- if (fun == &vFiiplll) return 1;
- if (fun == &vFiuippp) return 1;
- if (fun == &vFiffiff) return 5;
- if (fun == &vFiddidd) return 5;
- if (fun == &vFililuU) return 1;
- if (fun == &vFililll) return 1;
- if (fun == &vFilipli) return 1;
- if (fun == &vFiliplu) return 1;
- if (fun == &vFillill) return 1;
- if (fun == &vFipiplp) return 1;
- if (fun == &vFipllli) return 1;
- if (fun == &vFuiiiii) return 1;
- if (fun == &vFuiiiil) return 1;
- if (fun == &vFuiiiip) return 1;
- if (fun == &vFuiiilp) return 1;
- if (fun == &vFuiiuii) return 1;
- if (fun == &vFuiiuup) return 1;
- if (fun == &vFuiIIII) return 1;
- if (fun == &vFuiuiii) return 1;
- if (fun == &vFuiuiil) return 1;
- if (fun == &vFuiuiip) return 1;
- if (fun == &vFuiuiuu) return 1;
- if (fun == &vFuiuuip) return 1;
- if (fun == &vFuiuuuu) return 1;
- if (fun == &vFuiuulp) return 1;
- if (fun == &vFuiupii) return 1;
- if (fun == &vFuiupiu) return 1;
- if (fun == &vFuiUUUU) return 1;
- if (fun == &vFuiffff) return 5;
- if (fun == &vFuidddd) return 5;
- if (fun == &vFuuiiii) return 1;
- if (fun == &vFuuiiiu) return 1;
- if (fun == &vFuuiuii) return 1;
- if (fun == &vFuuiuiu) return 1;
- if (fun == &vFuuiuup) return 1;
- if (fun == &vFuuuiup) return 1;
- if (fun == &vFuuuipi) return 1;
- if (fun == &vFuuuipp) return 1;
- if (fun == &vFuuuuii) return 1;
- if (fun == &vFuuuuip) return 1;
- if (fun == &vFuuuuuu) return 1;
- if (fun == &vFuuuuff) return 3;
- if (fun == &vFuuuppi) return 1;
- if (fun == &vFuuuppp) return 1;
- if (fun == &vFuuffff) return 5;
- if (fun == &vFuudddd) return 5;
- if (fun == &vFuulppp) return 1;
- if (fun == &vFuupupp) return 1;
- if (fun == &vFuffiip) return 3;
- if (fun == &vFufffff) return 6;
- if (fun == &vFuddiip) return 3;
- if (fun == &vFuliluU) return 1;
- if (fun == &vFulilli) return 1;
- if (fun == &vFulilll) return 1;
- if (fun == &vFullill) return 1;
- if (fun == &vFulplup) return 1;
- if (fun == &vFupupip) return 1;
- if (fun == &vFuppppu) return 1;
- if (fun == &vFuppppp) return 1;
- if (fun == &vFffffff) return 7;
- if (fun == &vFdddddd) return 7;
- if (fun == &vFpiiiii) return 1;
- if (fun == &vFpiiipp) return 1;
- if (fun == &vFpiiuuu) return 1;
- if (fun == &vFpiippp) return 1;
- if (fun == &vFpiUuup) return 1;
- if (fun == &vFpipppi) return 1;
- if (fun == &vFpipppp) return 1;
- if (fun == &vFpuiiii) return 1;
- if (fun == &vFpuiiiu) return 1;
- if (fun == &vFpuiipp) return 1;
- if (fun == &vFpuuuiu) return 1;
- if (fun == &vFpuuppp) return 1;
- if (fun == &vFpudddd) return 5;
- if (fun == &vFpupiUu) return 1;
- if (fun == &vFpupuuu) return 1;
- if (fun == &vFpupppp) return 1;
- if (fun == &vFpUiuup) return 1;
- if (fun == &vFpUiUup) return 1;
- if (fun == &vFpUipup) return 1;
- if (fun == &vFpUUiup) return 1;
- if (fun == &vFpdddii) return 4;
- if (fun == &vFpddddd) return 6;
- if (fun == &vFpddddp) return 5;
- if (fun == &vFppiiii) return 1;
- if (fun == &vFppiiip) return 1;
- if (fun == &vFppiiui) return 1;
- if (fun == &vFppiipi) return 1;
- if (fun == &vFppiipp) return 1;
- if (fun == &vFppilpp) return 1;
- if (fun == &vFppippi) return 1;
- if (fun == &vFppippp) return 1;
- if (fun == &vFppuuuu) return 1;
- if (fun == &vFppuUUU) return 1;
- if (fun == &vFppupii) return 1;
- if (fun == &vFppuppp) return 1;
- if (fun == &vFppdidd) return 4;
- if (fun == &vFppdddd) return 5;
- if (fun == &vFpplppi) return 1;
- if (fun == &vFpplppp) return 1;
- if (fun == &vFppLppi) return 1;
- if (fun == &vFppLppp) return 1;
- if (fun == &vFpppiii) return 1;
- if (fun == &vFpppiip) return 1;
- if (fun == &vFpppiff) return 3;
- if (fun == &vFpppipu) return 1;
- if (fun == &vFpppuii) return 1;
- if (fun == &vFppppii) return 1;
- if (fun == &vFpppppi) return 1;
- if (fun == &vFpppppu) return 1;
- if (fun == &vFpppppU) return 1;
- if (fun == &vFpppppL) return 1;
- if (fun == &vFpppppp) return 1;
- if (fun == &cFppLppi) return 1;
- if (fun == &iFiiiiii) return 1;
- if (fun == &iFiiiiip) return 1;
- if (fun == &iFiiiuwp) return 1;
- if (fun == &iFiuiipi) return 1;
- if (fun == &iFipiipi) return 1;
- if (fun == &iFipipip) return 1;
- if (fun == &iFipippp) return 1;
- if (fun == &iFipuufp) return 2;
- if (fun == &iFipupup) return 1;
- if (fun == &iFipuppp) return 1;
- if (fun == &iFipppLp) return 1;
- if (fun == &iFippppp) return 1;
- if (fun == &iFuppppp) return 1;
- if (fun == &iFdipppL) return 2;
- if (fun == &iFlpippp) return 1;
- if (fun == &iFLppipp) return 1;
- if (fun == &iFpiiiii) return 1;
- if (fun == &iFpiiiip) return 1;
- if (fun == &iFpiiipp) return 1;
- if (fun == &iFpiipip) return 1;
- if (fun == &iFpiippu) return 1;
- if (fun == &iFpiippp) return 1;
- if (fun == &iFpiuuup) return 1;
- if (fun == &iFpiuupp) return 1;
- if (fun == &iFpiUUpp) return 1;
- if (fun == &iFpipipi) return 1;
- if (fun == &iFpippip) return 1;
- if (fun == &iFpipppL) return 1;
- if (fun == &iFpipppp) return 1;
- if (fun == &iFpCpipu) return 1;
- if (fun == &iFpWpppp) return 1;
- if (fun == &iFpuiCpp) return 1;
- if (fun == &iFpuippp) return 1;
- if (fun == &iFpupuui) return 1;
- if (fun == &iFpUuuLp) return 1;
- if (fun == &iFpUuupp) return 1;
- if (fun == &iFpUUUip) return 1;
- if (fun == &iFpUUUUp) return 1;
- if (fun == &iFpLLppp) return 1;
- if (fun == &iFppiiii) return 1;
- if (fun == &iFppiiip) return 1;
- if (fun == &iFppiiuu) return 1;
- if (fun == &iFppiipi) return 1;
- if (fun == &iFppiipp) return 1;
- if (fun == &iFppipii) return 1;
- if (fun == &iFppipiL) return 1;
- if (fun == &iFppipip) return 1;
- if (fun == &iFppIipp) return 1;
- if (fun == &iFppIppp) return 1;
- if (fun == &iFppuiii) return 1;
- if (fun == &iFppuiiL) return 1;
- if (fun == &iFppuipp) return 1;
- if (fun == &iFppuIII) return 1;
- if (fun == &iFppuupp) return 1;
- if (fun == &iFppupip) return 1;
- if (fun == &iFppuppp) return 1;
- if (fun == &iFppUipp) return 1;
- if (fun == &iFppUUup) return 1;
- if (fun == &iFppdidd) return 4;
- if (fun == &iFpplppi) return 1;
- if (fun == &iFppLupp) return 1;
- if (fun == &iFppLpLp) return 1;
- if (fun == &iFpppiuu) return 1;
- if (fun == &iFpppipi) return 1;
- if (fun == &iFpppipp) return 1;
- if (fun == &iFpppuii) return 1;
- if (fun == &iFpppupu) return 1;
- if (fun == &iFpppLpp) return 1;
- if (fun == &iFppppii) return 1;
- if (fun == &iFppppiu) return 1;
- if (fun == &iFppppip) return 1;
- if (fun == &iFppppup) return 1;
- if (fun == &iFpppppi) return 1;
- if (fun == &iFpppppL) return 1;
- if (fun == &iFpppppp) return 1;
- if (fun == &uFpippup) return 1;
- if (fun == &uFpWuwCp) return 1;
- if (fun == &uFpWuipp) return 1;
- if (fun == &uFpWuuCp) return 1;
- if (fun == &uFpuippp) return 1;
- if (fun == &uFppippp) return 1;
- if (fun == &uFppuuup) return 1;
- if (fun == &uFppuupu) return 1;
- if (fun == &uFpppppi) return 1;
- if (fun == &uFpppppp) return 1;
- if (fun == &UFpippup) return 1;
- if (fun == &lFipipLu) return 1;
- if (fun == &lFipLipu) return 1;
- if (fun == &lFipLipp) return 1;
- if (fun == &lFipLpLL) return 1;
- if (fun == &LFpipipi) return 1;
- if (fun == &LFpLippp) return 1;
- if (fun == &pFiiiiii) return 1;
- if (fun == &pFiCiiCi) return 1;
- if (fun == &pFdddddd) return 7;
- if (fun == &pFpiiiiu) return 1;
- if (fun == &pFpiiCCC) return 1;
- if (fun == &pFpiUUUU) return 1;
- if (fun == &pFpippip) return 1;
- if (fun == &pFpipppp) return 1;
- if (fun == &pFpCuuCC) return 1;
- if (fun == &pFpCuuWW) return 1;
- if (fun == &pFpCuuup) return 1;
- if (fun == &pFpuuwwu) return 1;
- if (fun == &pFpuuuuu) return 1;
- if (fun == &pFpuuupu) return 1;
- if (fun == &pFpuuUUU) return 1;
- if (fun == &pFplpppp) return 1;
- if (fun == &pFppiiii) return 1;
- if (fun == &pFppiipp) return 1;
- if (fun == &pFppiCCC) return 1;
- if (fun == &pFppippi) return 1;
- if (fun == &pFppippp) return 1;
- if (fun == &pFpppiii) return 1;
- if (fun == &pFpppiui) return 1;
- if (fun == &pFpppiup) return 1;
- if (fun == &pFpppupp) return 1;
- if (fun == &pFppppii) return 1;
- if (fun == &pFppppWW) return 1;
- if (fun == &pFpppppi) return 1;
- if (fun == &pFpppppu) return 1;
- if (fun == &pFpppppp) return 1;
- if (fun == &vFiiffffp) return 5;
- if (fun == &vFuipffff) return 5;
- if (fun == &vFuipdddd) return 5;
- if (fun == &vFuuuufff) return 4;
- if (fun == &vFuuuffff) return 5;
- if (fun == &vFuuudddd) return 5;
- if (fun == &vFuuffiip) return 3;
- if (fun == &vFuuddiip) return 3;
- if (fun == &vFuffffff) return 7;
- if (fun == &vFudddddd) return 7;
- if (fun == &vFpddiidd) return 5;
- if (fun == &vFpdddddd) return 7;
- if (fun == &vFppddddi) return 5;
- if (fun == &vFppddpii) return 3;
- if (fun == &iFppppdpi) return 2;
- if (fun == &pFifffppp) return 4;
- if (fun == &pFdiiiIiI) return 2;
- if (fun == &pFpiiUdii) return 2;
- if (fun == &pFpppfffi) return 4;
- if (fun == &pFpppdddi) return 4;
- if (fun == &vFuuuuufff) return 4;
- if (fun == &vFuuufffff) return 6;
- if (fun == &vFffffffff) return 9;
- if (fun == &vFuffffffff) return 9;
- if (fun == &vFffuuuufff) return 6;
- if (fun == &vFppddddidd) return 7;
- if (fun == &iFdddpppppp) return 4;
- if (fun == &vFuffiiffiip) return 5;
- if (fun == &vFuddiiddiip) return 5;
- if (fun == &vFppdddddddd) return 9;
- if (fun == &iFpippddiidd) return 5;
-#if defined(NOALIGN)
- if (fun == &iFipiip) return 1;
-#endif
- return 0;
-}
diff --git a/src/wrapped/generated/wrapper.h b/src/wrapped/generated/wrapper.h
deleted file mode 100644
index f0d487b..0000000
--- a/src/wrapped/generated/wrapper.h
+++ /dev/null
@@ -1,2421 +0,0 @@
-/*******************************************************************
- * File automatically generated by rebuild_wrappers.py (v2.2.0.16) *
- *******************************************************************/
-#ifndef __WRAPPER_H_
-#define __WRAPPER_H_
-#include <stdint.h>
-#include <string.h>
-
-typedef struct x64emu_s x64emu_t;
-
-// the generic wrapper pointer functions
-typedef void (*wrapper_t)(x64emu_t* emu, uintptr_t fnc);
-
-// list of defined wrapper
-// E = current x86emu struct
-// v = void
-// C = unsigned byte c = char
-// W = unsigned short w = short
-// u = uint32, i = int32
-// U = uint64, I = int64
-// L = unsigned long, l = signed long (long is an int with the size of a pointer)
-// H = Huge 128bits value/struct
-// p = pointer, P = void* on the stack
-// f = float, d = double, D = long double, K = fake long double
-// V = vaargs
-// O = libc O_ flags bitfield
-// o = stdout
-// S = _IO_2_1_stdXXX_ pointer (or FILE*)
-// N = ... automatically sending 1 arg
-// M = ... automatically sending 2 args
-// A = va_list
-// 0 = constant 0, 1 = constant 1
-
-void vFE(x64emu_t *emu, uintptr_t fnc);
-void vFv(x64emu_t *emu, uintptr_t fnc);
-void vFi(x64emu_t *emu, uintptr_t fnc);
-void vFu(x64emu_t *emu, uintptr_t fnc);
-void vFU(x64emu_t *emu, uintptr_t fnc);
-void vFf(x64emu_t *emu, uintptr_t fnc);
-void vFd(x64emu_t *emu, uintptr_t fnc);
-void vFl(x64emu_t *emu, uintptr_t fnc);
-void vFL(x64emu_t *emu, uintptr_t fnc);
-void vFp(x64emu_t *emu, uintptr_t fnc);
-void vFS(x64emu_t *emu, uintptr_t fnc);
-void cFv(x64emu_t *emu, uintptr_t fnc);
-void cFi(x64emu_t *emu, uintptr_t fnc);
-void cFu(x64emu_t *emu, uintptr_t fnc);
-void cFf(x64emu_t *emu, uintptr_t fnc);
-void cFp(x64emu_t *emu, uintptr_t fnc);
-void wFp(x64emu_t *emu, uintptr_t fnc);
-void iFE(x64emu_t *emu, uintptr_t fnc);
-void iFv(x64emu_t *emu, uintptr_t fnc);
-void iFw(x64emu_t *emu, uintptr_t fnc);
-void iFi(x64emu_t *emu, uintptr_t fnc);
-void iFI(x64emu_t *emu, uintptr_t fnc);
-void iFC(x64emu_t *emu, uintptr_t fnc);
-void iFW(x64emu_t *emu, uintptr_t fnc);
-void iFu(x64emu_t *emu, uintptr_t fnc);
-void iFU(x64emu_t *emu, uintptr_t fnc);
-void iFf(x64emu_t *emu, uintptr_t fnc);
-void iFd(x64emu_t *emu, uintptr_t fnc);
-void iFD(x64emu_t *emu, uintptr_t fnc);
-void iFl(x64emu_t *emu, uintptr_t fnc);
-void iFL(x64emu_t *emu, uintptr_t fnc);
-void iFp(x64emu_t *emu, uintptr_t fnc);
-void iFO(x64emu_t *emu, uintptr_t fnc);
-void iFS(x64emu_t *emu, uintptr_t fnc);
-void IFv(x64emu_t *emu, uintptr_t fnc);
-void IFi(x64emu_t *emu, uintptr_t fnc);
-void IFI(x64emu_t *emu, uintptr_t fnc);
-void IFf(x64emu_t *emu, uintptr_t fnc);
-void IFd(x64emu_t *emu, uintptr_t fnc);
-void IFp(x64emu_t *emu, uintptr_t fnc);
-void CFC(x64emu_t *emu, uintptr_t fnc);
-void CFp(x64emu_t *emu, uintptr_t fnc);
-void WFi(x64emu_t *emu, uintptr_t fnc);
-void WFW(x64emu_t *emu, uintptr_t fnc);
-void WFp(x64emu_t *emu, uintptr_t fnc);
-void uFv(x64emu_t *emu, uintptr_t fnc);
-void uFi(x64emu_t *emu, uintptr_t fnc);
-void uFu(x64emu_t *emu, uintptr_t fnc);
-void uFd(x64emu_t *emu, uintptr_t fnc);
-void uFl(x64emu_t *emu, uintptr_t fnc);
-void uFL(x64emu_t *emu, uintptr_t fnc);
-void uFp(x64emu_t *emu, uintptr_t fnc);
-void UFv(x64emu_t *emu, uintptr_t fnc);
-void UFu(x64emu_t *emu, uintptr_t fnc);
-void UFp(x64emu_t *emu, uintptr_t fnc);
-void UFV(x64emu_t *emu, uintptr_t fnc);
-void fFi(x64emu_t *emu, uintptr_t fnc);
-void fFf(x64emu_t *emu, uintptr_t fnc);
-void fFp(x64emu_t *emu, uintptr_t fnc);
-void dFv(x64emu_t *emu, uintptr_t fnc);
-void dFi(x64emu_t *emu, uintptr_t fnc);
-void dFu(x64emu_t *emu, uintptr_t fnc);
-void dFd(x64emu_t *emu, uintptr_t fnc);
-void dFp(x64emu_t *emu, uintptr_t fnc);
-void lFE(x64emu_t *emu, uintptr_t fnc);
-void lFv(x64emu_t *emu, uintptr_t fnc);
-void lFi(x64emu_t *emu, uintptr_t fnc);
-void lFu(x64emu_t *emu, uintptr_t fnc);
-void lFl(x64emu_t *emu, uintptr_t fnc);
-void lFp(x64emu_t *emu, uintptr_t fnc);
-void LFv(x64emu_t *emu, uintptr_t fnc);
-void LFu(x64emu_t *emu, uintptr_t fnc);
-void LFL(x64emu_t *emu, uintptr_t fnc);
-void LFp(x64emu_t *emu, uintptr_t fnc);
-void pFE(x64emu_t *emu, uintptr_t fnc);
-void pFv(x64emu_t *emu, uintptr_t fnc);
-void pFw(x64emu_t *emu, uintptr_t fnc);
-void pFi(x64emu_t *emu, uintptr_t fnc);
-void pFI(x64emu_t *emu, uintptr_t fnc);
-void pFC(x64emu_t *emu, uintptr_t fnc);
-void pFW(x64emu_t *emu, uintptr_t fnc);
-void pFu(x64emu_t *emu, uintptr_t fnc);
-void pFU(x64emu_t *emu, uintptr_t fnc);
-void pFd(x64emu_t *emu, uintptr_t fnc);
-void pFl(x64emu_t *emu, uintptr_t fnc);
-void pFL(x64emu_t *emu, uintptr_t fnc);
-void pFp(x64emu_t *emu, uintptr_t fnc);
-void pFV(x64emu_t *emu, uintptr_t fnc);
-void HFi(x64emu_t *emu, uintptr_t fnc);
-void HFp(x64emu_t *emu, uintptr_t fnc);
-void vWp(x64emu_t *emu, uintptr_t fnc);
-void iWp(x64emu_t *emu, uintptr_t fnc);
-void uWp(x64emu_t *emu, uintptr_t fnc);
-void fWp(x64emu_t *emu, uintptr_t fnc);
-void vFEi(x64emu_t *emu, uintptr_t fnc);
-void vFEp(x64emu_t *emu, uintptr_t fnc);
-void vFii(x64emu_t *emu, uintptr_t fnc);
-void vFiI(x64emu_t *emu, uintptr_t fnc);
-void vFiu(x64emu_t *emu, uintptr_t fnc);
-void vFiU(x64emu_t *emu, uintptr_t fnc);
-void vFif(x64emu_t *emu, uintptr_t fnc);
-void vFid(x64emu_t *emu, uintptr_t fnc);
-void vFip(x64emu_t *emu, uintptr_t fnc);
-void vFWW(x64emu_t *emu, uintptr_t fnc);
-void vFWp(x64emu_t *emu, uintptr_t fnc);
-void vFui(x64emu_t *emu, uintptr_t fnc);
-void vFuu(x64emu_t *emu, uintptr_t fnc);
-void vFuU(x64emu_t *emu, uintptr_t fnc);
-void vFuf(x64emu_t *emu, uintptr_t fnc);
-void vFud(x64emu_t *emu, uintptr_t fnc);
-void vFul(x64emu_t *emu, uintptr_t fnc);
-void vFup(x64emu_t *emu, uintptr_t fnc);
-void vFUi(x64emu_t *emu, uintptr_t fnc);
-void vFfi(x64emu_t *emu, uintptr_t fnc);
-void vFff(x64emu_t *emu, uintptr_t fnc);
-void vFfp(x64emu_t *emu, uintptr_t fnc);
-void vFdd(x64emu_t *emu, uintptr_t fnc);
-void vFlp(x64emu_t *emu, uintptr_t fnc);
-void vFLL(x64emu_t *emu, uintptr_t fnc);
-void vFLp(x64emu_t *emu, uintptr_t fnc);
-void vFpc(x64emu_t *emu, uintptr_t fnc);
-void vFpi(x64emu_t *emu, uintptr_t fnc);
-void vFpI(x64emu_t *emu, uintptr_t fnc);
-void vFpC(x64emu_t *emu, uintptr_t fnc);
-void vFpW(x64emu_t *emu, uintptr_t fnc);
-void vFpu(x64emu_t *emu, uintptr_t fnc);
-void vFpU(x64emu_t *emu, uintptr_t fnc);
-void vFpf(x64emu_t *emu, uintptr_t fnc);
-void vFpd(x64emu_t *emu, uintptr_t fnc);
-void vFpl(x64emu_t *emu, uintptr_t fnc);
-void vFpL(x64emu_t *emu, uintptr_t fnc);
-void vFpp(x64emu_t *emu, uintptr_t fnc);
-void vFpS(x64emu_t *emu, uintptr_t fnc);
-void vFSi(x64emu_t *emu, uintptr_t fnc);
-void cFpp(x64emu_t *emu, uintptr_t fnc);
-void iFEi(x64emu_t *emu, uintptr_t fnc);
-void iFEp(x64emu_t *emu, uintptr_t fnc);
-void iFwp(x64emu_t *emu, uintptr_t fnc);
-void iFii(x64emu_t *emu, uintptr_t fnc);
-void iFiu(x64emu_t *emu, uintptr_t fnc);
-void iFil(x64emu_t *emu, uintptr_t fnc);
-void iFiL(x64emu_t *emu, uintptr_t fnc);
-void iFip(x64emu_t *emu, uintptr_t fnc);
-void iFiS(x64emu_t *emu, uintptr_t fnc);
-void iFIi(x64emu_t *emu, uintptr_t fnc);
-void iFui(x64emu_t *emu, uintptr_t fnc);
-void iFuu(x64emu_t *emu, uintptr_t fnc);
-void iFuU(x64emu_t *emu, uintptr_t fnc);
-void iFuL(x64emu_t *emu, uintptr_t fnc);
-void iFup(x64emu_t *emu, uintptr_t fnc);
-void iFUp(x64emu_t *emu, uintptr_t fnc);
-void iFli(x64emu_t *emu, uintptr_t fnc);
-void iFlp(x64emu_t *emu, uintptr_t fnc);
-void iFLu(x64emu_t *emu, uintptr_t fnc);
-void iFLL(x64emu_t *emu, uintptr_t fnc);
-void iFLp(x64emu_t *emu, uintptr_t fnc);
-void iFpw(x64emu_t *emu, uintptr_t fnc);
-void iFpi(x64emu_t *emu, uintptr_t fnc);
-void iFpI(x64emu_t *emu, uintptr_t fnc);
-void iFpC(x64emu_t *emu, uintptr_t fnc);
-void iFpW(x64emu_t *emu, uintptr_t fnc);
-void iFpu(x64emu_t *emu, uintptr_t fnc);
-void iFpU(x64emu_t *emu, uintptr_t fnc);
-void iFpf(x64emu_t *emu, uintptr_t fnc);
-void iFpd(x64emu_t *emu, uintptr_t fnc);
-void iFpl(x64emu_t *emu, uintptr_t fnc);
-void iFpL(x64emu_t *emu, uintptr_t fnc);
-void iFpp(x64emu_t *emu, uintptr_t fnc);
-void iFpO(x64emu_t *emu, uintptr_t fnc);
-void iFSi(x64emu_t *emu, uintptr_t fnc);
-void IFEp(x64emu_t *emu, uintptr_t fnc);
-void IFII(x64emu_t *emu, uintptr_t fnc);
-void IFpi(x64emu_t *emu, uintptr_t fnc);
-void IFpu(x64emu_t *emu, uintptr_t fnc);
-void IFpd(x64emu_t *emu, uintptr_t fnc);
-void CFip(x64emu_t *emu, uintptr_t fnc);
-void CFui(x64emu_t *emu, uintptr_t fnc);
-void CFpi(x64emu_t *emu, uintptr_t fnc);
-void CFpu(x64emu_t *emu, uintptr_t fnc);
-void CFpp(x64emu_t *emu, uintptr_t fnc);
-void WFpp(x64emu_t *emu, uintptr_t fnc);
-void uFEp(x64emu_t *emu, uintptr_t fnc);
-void uFii(x64emu_t *emu, uintptr_t fnc);
-void uFiu(x64emu_t *emu, uintptr_t fnc);
-void uFip(x64emu_t *emu, uintptr_t fnc);
-void uFui(x64emu_t *emu, uintptr_t fnc);
-void uFuu(x64emu_t *emu, uintptr_t fnc);
-void uFup(x64emu_t *emu, uintptr_t fnc);
-void uFUp(x64emu_t *emu, uintptr_t fnc);
-void uFpw(x64emu_t *emu, uintptr_t fnc);
-void uFpi(x64emu_t *emu, uintptr_t fnc);
-void uFpu(x64emu_t *emu, uintptr_t fnc);
-void uFpU(x64emu_t *emu, uintptr_t fnc);
-void uFpf(x64emu_t *emu, uintptr_t fnc);
-void uFpL(x64emu_t *emu, uintptr_t fnc);
-void uFpp(x64emu_t *emu, uintptr_t fnc);
-void UFEp(x64emu_t *emu, uintptr_t fnc);
-void UFuu(x64emu_t *emu, uintptr_t fnc);
-void UFUp(x64emu_t *emu, uintptr_t fnc);
-void UFpi(x64emu_t *emu, uintptr_t fnc);
-void UFpp(x64emu_t *emu, uintptr_t fnc);
-void fFEp(x64emu_t *emu, uintptr_t fnc);
-void fFif(x64emu_t *emu, uintptr_t fnc);
-void fFfi(x64emu_t *emu, uintptr_t fnc);
-void fFff(x64emu_t *emu, uintptr_t fnc);
-void fFfD(x64emu_t *emu, uintptr_t fnc);
-void fFfl(x64emu_t *emu, uintptr_t fnc);
-void fFfp(x64emu_t *emu, uintptr_t fnc);
-void fFpp(x64emu_t *emu, uintptr_t fnc);
-void dFid(x64emu_t *emu, uintptr_t fnc);
-void dFdi(x64emu_t *emu, uintptr_t fnc);
-void dFdd(x64emu_t *emu, uintptr_t fnc);
-void dFdD(x64emu_t *emu, uintptr_t fnc);
-void dFdl(x64emu_t *emu, uintptr_t fnc);
-void dFdp(x64emu_t *emu, uintptr_t fnc);
-void dFll(x64emu_t *emu, uintptr_t fnc);
-void dFpi(x64emu_t *emu, uintptr_t fnc);
-void dFpd(x64emu_t *emu, uintptr_t fnc);
-void dFpp(x64emu_t *emu, uintptr_t fnc);
-void DFDi(x64emu_t *emu, uintptr_t fnc);
-void DFDD(x64emu_t *emu, uintptr_t fnc);
-void DFDp(x64emu_t *emu, uintptr_t fnc);
-void DFpp(x64emu_t *emu, uintptr_t fnc);
-void lFii(x64emu_t *emu, uintptr_t fnc);
-void lFll(x64emu_t *emu, uintptr_t fnc);
-void lFpi(x64emu_t *emu, uintptr_t fnc);
-void lFpl(x64emu_t *emu, uintptr_t fnc);
-void lFpp(x64emu_t *emu, uintptr_t fnc);
-void LFEL(x64emu_t *emu, uintptr_t fnc);
-void LFii(x64emu_t *emu, uintptr_t fnc);
-void LFuu(x64emu_t *emu, uintptr_t fnc);
-void LFLi(x64emu_t *emu, uintptr_t fnc);
-void LFLL(x64emu_t *emu, uintptr_t fnc);
-void LFpi(x64emu_t *emu, uintptr_t fnc);
-void LFpL(x64emu_t *emu, uintptr_t fnc);
-void LFpp(x64emu_t *emu, uintptr_t fnc);
-void pFEi(x64emu_t *emu, uintptr_t fnc);
-void pFEL(x64emu_t *emu, uintptr_t fnc);
-void pFEp(x64emu_t *emu, uintptr_t fnc);
-void pFii(x64emu_t *emu, uintptr_t fnc);
-void pFiI(x64emu_t *emu, uintptr_t fnc);
-void pFiu(x64emu_t *emu, uintptr_t fnc);
-void pFip(x64emu_t *emu, uintptr_t fnc);
-void pFiV(x64emu_t *emu, uintptr_t fnc);
-void pFII(x64emu_t *emu, uintptr_t fnc);
-void pFui(x64emu_t *emu, uintptr_t fnc);
-void pFuC(x64emu_t *emu, uintptr_t fnc);
-void pFuu(x64emu_t *emu, uintptr_t fnc);
-void pFup(x64emu_t *emu, uintptr_t fnc);
-void pFUi(x64emu_t *emu, uintptr_t fnc);
-void pFUU(x64emu_t *emu, uintptr_t fnc);
-void pFdi(x64emu_t *emu, uintptr_t fnc);
-void pFdd(x64emu_t *emu, uintptr_t fnc);
-void pFlp(x64emu_t *emu, uintptr_t fnc);
-void pFLu(x64emu_t *emu, uintptr_t fnc);
-void pFLL(x64emu_t *emu, uintptr_t fnc);
-void pFLp(x64emu_t *emu, uintptr_t fnc);
-void pFpi(x64emu_t *emu, uintptr_t fnc);
-void pFpC(x64emu_t *emu, uintptr_t fnc);
-void pFpu(x64emu_t *emu, uintptr_t fnc);
-void pFpU(x64emu_t *emu, uintptr_t fnc);
-void pFpd(x64emu_t *emu, uintptr_t fnc);
-void pFpl(x64emu_t *emu, uintptr_t fnc);
-void pFpL(x64emu_t *emu, uintptr_t fnc);
-void pFpp(x64emu_t *emu, uintptr_t fnc);
-void pFpV(x64emu_t *emu, uintptr_t fnc);
-void pFSi(x64emu_t *emu, uintptr_t fnc);
-void HFII(x64emu_t *emu, uintptr_t fnc);
-void HFll(x64emu_t *emu, uintptr_t fnc);
-void HFpi(x64emu_t *emu, uintptr_t fnc);
-void iWpi(x64emu_t *emu, uintptr_t fnc);
-void iWpu(x64emu_t *emu, uintptr_t fnc);
-void iWpf(x64emu_t *emu, uintptr_t fnc);
-void iWpp(x64emu_t *emu, uintptr_t fnc);
-void uWpu(x64emu_t *emu, uintptr_t fnc);
-void pWEp(x64emu_t *emu, uintptr_t fnc);
-void pWpu(x64emu_t *emu, uintptr_t fnc);
-void vFEpi(x64emu_t *emu, uintptr_t fnc);
-void vFEpu(x64emu_t *emu, uintptr_t fnc);
-void vFEpp(x64emu_t *emu, uintptr_t fnc);
-void vFEpV(x64emu_t *emu, uintptr_t fnc);
-void vFEpA(x64emu_t *emu, uintptr_t fnc);
-void vFiii(x64emu_t *emu, uintptr_t fnc);
-void vFiiu(x64emu_t *emu, uintptr_t fnc);
-void vFiif(x64emu_t *emu, uintptr_t fnc);
-void vFiip(x64emu_t *emu, uintptr_t fnc);
-void vFiII(x64emu_t *emu, uintptr_t fnc);
-void vFiui(x64emu_t *emu, uintptr_t fnc);
-void vFiuu(x64emu_t *emu, uintptr_t fnc);
-void vFiuU(x64emu_t *emu, uintptr_t fnc);
-void vFiup(x64emu_t *emu, uintptr_t fnc);
-void vFiUU(x64emu_t *emu, uintptr_t fnc);
-void vFiff(x64emu_t *emu, uintptr_t fnc);
-void vFidd(x64emu_t *emu, uintptr_t fnc);
-void vFill(x64emu_t *emu, uintptr_t fnc);
-void vFilp(x64emu_t *emu, uintptr_t fnc);
-void vFipi(x64emu_t *emu, uintptr_t fnc);
-void vFipu(x64emu_t *emu, uintptr_t fnc);
-void vFipp(x64emu_t *emu, uintptr_t fnc);
-void vFuii(x64emu_t *emu, uintptr_t fnc);
-void vFuiI(x64emu_t *emu, uintptr_t fnc);
-void vFuiu(x64emu_t *emu, uintptr_t fnc);
-void vFuiU(x64emu_t *emu, uintptr_t fnc);
-void vFuif(x64emu_t *emu, uintptr_t fnc);
-void vFuid(x64emu_t *emu, uintptr_t fnc);
-void vFuip(x64emu_t *emu, uintptr_t fnc);
-void vFuui(x64emu_t *emu, uintptr_t fnc);
-void vFuuu(x64emu_t *emu, uintptr_t fnc);
-void vFuuU(x64emu_t *emu, uintptr_t fnc);
-void vFuuf(x64emu_t *emu, uintptr_t fnc);
-void vFuud(x64emu_t *emu, uintptr_t fnc);
-void vFuup(x64emu_t *emu, uintptr_t fnc);
-void vFuff(x64emu_t *emu, uintptr_t fnc);
-void vFufp(x64emu_t *emu, uintptr_t fnc);
-void vFudd(x64emu_t *emu, uintptr_t fnc);
-void vFull(x64emu_t *emu, uintptr_t fnc);
-void vFulp(x64emu_t *emu, uintptr_t fnc);
-void vFuLp(x64emu_t *emu, uintptr_t fnc);
-void vFupu(x64emu_t *emu, uintptr_t fnc);
-void vFupp(x64emu_t *emu, uintptr_t fnc);
-void vFfff(x64emu_t *emu, uintptr_t fnc);
-void vFfpp(x64emu_t *emu, uintptr_t fnc);
-void vFddd(x64emu_t *emu, uintptr_t fnc);
-void vFdpp(x64emu_t *emu, uintptr_t fnc);
-void vFlip(x64emu_t *emu, uintptr_t fnc);
-void vFlll(x64emu_t *emu, uintptr_t fnc);
-void vFllp(x64emu_t *emu, uintptr_t fnc);
-void vFlpp(x64emu_t *emu, uintptr_t fnc);
-void vFLup(x64emu_t *emu, uintptr_t fnc);
-void vFLpL(x64emu_t *emu, uintptr_t fnc);
-void vFLpp(x64emu_t *emu, uintptr_t fnc);
-void vFpii(x64emu_t *emu, uintptr_t fnc);
-void vFpiI(x64emu_t *emu, uintptr_t fnc);
-void vFpiC(x64emu_t *emu, uintptr_t fnc);
-void vFpiu(x64emu_t *emu, uintptr_t fnc);
-void vFpif(x64emu_t *emu, uintptr_t fnc);
-void vFpid(x64emu_t *emu, uintptr_t fnc);
-void vFpip(x64emu_t *emu, uintptr_t fnc);
-void vFpui(x64emu_t *emu, uintptr_t fnc);
-void vFpuI(x64emu_t *emu, uintptr_t fnc);
-void vFpuW(x64emu_t *emu, uintptr_t fnc);
-void vFpuu(x64emu_t *emu, uintptr_t fnc);
-void vFpuU(x64emu_t *emu, uintptr_t fnc);
-void vFpup(x64emu_t *emu, uintptr_t fnc);
-void vFpUi(x64emu_t *emu, uintptr_t fnc);
-void vFpUu(x64emu_t *emu, uintptr_t fnc);
-void vFpUU(x64emu_t *emu, uintptr_t fnc);
-void vFpUf(x64emu_t *emu, uintptr_t fnc);
-void vFpUp(x64emu_t *emu, uintptr_t fnc);
-void vFpff(x64emu_t *emu, uintptr_t fnc);
-void vFpdd(x64emu_t *emu, uintptr_t fnc);
-void vFpll(x64emu_t *emu, uintptr_t fnc);
-void vFplp(x64emu_t *emu, uintptr_t fnc);
-void vFpLi(x64emu_t *emu, uintptr_t fnc);
-void vFpLu(x64emu_t *emu, uintptr_t fnc);
-void vFpLL(x64emu_t *emu, uintptr_t fnc);
-void vFpLp(x64emu_t *emu, uintptr_t fnc);
-void vFppi(x64emu_t *emu, uintptr_t fnc);
-void vFppu(x64emu_t *emu, uintptr_t fnc);
-void vFppU(x64emu_t *emu, uintptr_t fnc);
-void vFppd(x64emu_t *emu, uintptr_t fnc);
-void vFppl(x64emu_t *emu, uintptr_t fnc);
-void vFppL(x64emu_t *emu, uintptr_t fnc);
-void vFppp(x64emu_t *emu, uintptr_t fnc);
-void iFEiw(x64emu_t *emu, uintptr_t fnc);
-void iFEip(x64emu_t *emu, uintptr_t fnc);
-void iFEWW(x64emu_t *emu, uintptr_t fnc);
-void iFEup(x64emu_t *emu, uintptr_t fnc);
-void iFEUU(x64emu_t *emu, uintptr_t fnc);
-void iFELp(x64emu_t *emu, uintptr_t fnc);
-void iFEpi(x64emu_t *emu, uintptr_t fnc);
-void iFEpU(x64emu_t *emu, uintptr_t fnc);
-void iFEpL(x64emu_t *emu, uintptr_t fnc);
-void iFEpp(x64emu_t *emu, uintptr_t fnc);
-void iFEpV(x64emu_t *emu, uintptr_t fnc);
-void iFEpA(x64emu_t *emu, uintptr_t fnc);
-void iFESp(x64emu_t *emu, uintptr_t fnc);
-void iFwww(x64emu_t *emu, uintptr_t fnc);
-void iFwpp(x64emu_t *emu, uintptr_t fnc);
-void iFiwC(x64emu_t *emu, uintptr_t fnc);
-void iFiii(x64emu_t *emu, uintptr_t fnc);
-void iFiiu(x64emu_t *emu, uintptr_t fnc);
-void iFiil(x64emu_t *emu, uintptr_t fnc);
-void iFiip(x64emu_t *emu, uintptr_t fnc);
-void iFiiO(x64emu_t *emu, uintptr_t fnc);
-void iFiuu(x64emu_t *emu, uintptr_t fnc);
-void iFill(x64emu_t *emu, uintptr_t fnc);
-void iFiLi(x64emu_t *emu, uintptr_t fnc);
-void iFiLp(x64emu_t *emu, uintptr_t fnc);
-void iFiLN(x64emu_t *emu, uintptr_t fnc);
-void iFipi(x64emu_t *emu, uintptr_t fnc);
-void iFipu(x64emu_t *emu, uintptr_t fnc);
-void iFipL(x64emu_t *emu, uintptr_t fnc);
-void iFipp(x64emu_t *emu, uintptr_t fnc);
-void iFipO(x64emu_t *emu, uintptr_t fnc);
-void iFCiW(x64emu_t *emu, uintptr_t fnc);
-void iFuwp(x64emu_t *emu, uintptr_t fnc);
-void iFuip(x64emu_t *emu, uintptr_t fnc);
-void iFuui(x64emu_t *emu, uintptr_t fnc);
-void iFuuu(x64emu_t *emu, uintptr_t fnc);
-void iFuup(x64emu_t *emu, uintptr_t fnc);
-void iFuUu(x64emu_t *emu, uintptr_t fnc);
-void iFuff(x64emu_t *emu, uintptr_t fnc);
-void iFuLL(x64emu_t *emu, uintptr_t fnc);
-void iFuLp(x64emu_t *emu, uintptr_t fnc);
-void iFupL(x64emu_t *emu, uintptr_t fnc);
-void iFupp(x64emu_t *emu, uintptr_t fnc);
-void iFfff(x64emu_t *emu, uintptr_t fnc);
-void iFlip(x64emu_t *emu, uintptr_t fnc);
-void iFLip(x64emu_t *emu, uintptr_t fnc);
-void iFLLi(x64emu_t *emu, uintptr_t fnc);
-void iFLpp(x64emu_t *emu, uintptr_t fnc);
-void iFpwp(x64emu_t *emu, uintptr_t fnc);
-void iFpii(x64emu_t *emu, uintptr_t fnc);
-void iFpiI(x64emu_t *emu, uintptr_t fnc);
-void iFpiu(x64emu_t *emu, uintptr_t fnc);
-void iFpiU(x64emu_t *emu, uintptr_t fnc);
-void iFpiL(x64emu_t *emu, uintptr_t fnc);
-void iFpip(x64emu_t *emu, uintptr_t fnc);
-void iFpIi(x64emu_t *emu, uintptr_t fnc);
-void iFpII(x64emu_t *emu, uintptr_t fnc);
-void iFpCp(x64emu_t *emu, uintptr_t fnc);
-void iFpui(x64emu_t *emu, uintptr_t fnc);
-void iFpuu(x64emu_t *emu, uintptr_t fnc);
-void iFpuU(x64emu_t *emu, uintptr_t fnc);
-void iFpuL(x64emu_t *emu, uintptr_t fnc);
-void iFpup(x64emu_t *emu, uintptr_t fnc);
-void iFpUi(x64emu_t *emu, uintptr_t fnc);
-void iFpUu(x64emu_t *emu, uintptr_t fnc);
-void iFpUU(x64emu_t *emu, uintptr_t fnc);
-void iFpUp(x64emu_t *emu, uintptr_t fnc);
-void iFpfu(x64emu_t *emu, uintptr_t fnc);
-void iFpff(x64emu_t *emu, uintptr_t fnc);
-void iFpdd(x64emu_t *emu, uintptr_t fnc);
-void iFpli(x64emu_t *emu, uintptr_t fnc);
-void iFpll(x64emu_t *emu, uintptr_t fnc);
-void iFplp(x64emu_t *emu, uintptr_t fnc);
-void iFpLi(x64emu_t *emu, uintptr_t fnc);
-void iFpLu(x64emu_t *emu, uintptr_t fnc);
-void iFpLL(x64emu_t *emu, uintptr_t fnc);
-void iFpLp(x64emu_t *emu, uintptr_t fnc);
-void iFppi(x64emu_t *emu, uintptr_t fnc);
-void iFppI(x64emu_t *emu, uintptr_t fnc);
-void iFppC(x64emu_t *emu, uintptr_t fnc);
-void iFppW(x64emu_t *emu, uintptr_t fnc);
-void iFppu(x64emu_t *emu, uintptr_t fnc);
-void iFppU(x64emu_t *emu, uintptr_t fnc);
-void iFppd(x64emu_t *emu, uintptr_t fnc);
-void iFppl(x64emu_t *emu, uintptr_t fnc);
-void iFppL(x64emu_t *emu, uintptr_t fnc);
-void iFppp(x64emu_t *emu, uintptr_t fnc);
-void iFpOu(x64emu_t *emu, uintptr_t fnc);
-void iFpOM(x64emu_t *emu, uintptr_t fnc);
-void iFSpL(x64emu_t *emu, uintptr_t fnc);
-void IFiIi(x64emu_t *emu, uintptr_t fnc);
-void IFpIi(x64emu_t *emu, uintptr_t fnc);
-void IFppi(x64emu_t *emu, uintptr_t fnc);
-void IFppI(x64emu_t *emu, uintptr_t fnc);
-void IFppu(x64emu_t *emu, uintptr_t fnc);
-void IFSIi(x64emu_t *emu, uintptr_t fnc);
-void uFEpW(x64emu_t *emu, uintptr_t fnc);
-void uFEpu(x64emu_t *emu, uintptr_t fnc);
-void uFEpU(x64emu_t *emu, uintptr_t fnc);
-void uFEpp(x64emu_t *emu, uintptr_t fnc);
-void uFipu(x64emu_t *emu, uintptr_t fnc);
-void uFuip(x64emu_t *emu, uintptr_t fnc);
-void uFuuu(x64emu_t *emu, uintptr_t fnc);
-void uFuup(x64emu_t *emu, uintptr_t fnc);
-void uFufp(x64emu_t *emu, uintptr_t fnc);
-void uFupu(x64emu_t *emu, uintptr_t fnc);
-void uFupp(x64emu_t *emu, uintptr_t fnc);
-void uFpii(x64emu_t *emu, uintptr_t fnc);
-void uFpip(x64emu_t *emu, uintptr_t fnc);
-void uFpCi(x64emu_t *emu, uintptr_t fnc);
-void uFpWi(x64emu_t *emu, uintptr_t fnc);
-void uFpWu(x64emu_t *emu, uintptr_t fnc);
-void uFpWf(x64emu_t *emu, uintptr_t fnc);
-void uFpWp(x64emu_t *emu, uintptr_t fnc);
-void uFpui(x64emu_t *emu, uintptr_t fnc);
-void uFpuC(x64emu_t *emu, uintptr_t fnc);
-void uFpuu(x64emu_t *emu, uintptr_t fnc);
-void uFpup(x64emu_t *emu, uintptr_t fnc);
-void uFpfu(x64emu_t *emu, uintptr_t fnc);
-void uFpLp(x64emu_t *emu, uintptr_t fnc);
-void uFppi(x64emu_t *emu, uintptr_t fnc);
-void uFppu(x64emu_t *emu, uintptr_t fnc);
-void uFppp(x64emu_t *emu, uintptr_t fnc);
-void UFUUU(x64emu_t *emu, uintptr_t fnc);
-void UFpiU(x64emu_t *emu, uintptr_t fnc);
-void UFppi(x64emu_t *emu, uintptr_t fnc);
-void UFppu(x64emu_t *emu, uintptr_t fnc);
-void fFull(x64emu_t *emu, uintptr_t fnc);
-void fFfff(x64emu_t *emu, uintptr_t fnc);
-void fFffp(x64emu_t *emu, uintptr_t fnc);
-void fFppi(x64emu_t *emu, uintptr_t fnc);
-void fFppL(x64emu_t *emu, uintptr_t fnc);
-void fFppp(x64emu_t *emu, uintptr_t fnc);
-void dFddd(x64emu_t *emu, uintptr_t fnc);
-void dFddp(x64emu_t *emu, uintptr_t fnc);
-void dFpdd(x64emu_t *emu, uintptr_t fnc);
-void dFppi(x64emu_t *emu, uintptr_t fnc);
-void dFppp(x64emu_t *emu, uintptr_t fnc);
-void DFppi(x64emu_t *emu, uintptr_t fnc);
-void DFppp(x64emu_t *emu, uintptr_t fnc);
-void lFili(x64emu_t *emu, uintptr_t fnc);
-void lFilL(x64emu_t *emu, uintptr_t fnc);
-void lFipi(x64emu_t *emu, uintptr_t fnc);
-void lFipL(x64emu_t *emu, uintptr_t fnc);
-void lFlll(x64emu_t *emu, uintptr_t fnc);
-void lFpli(x64emu_t *emu, uintptr_t fnc);
-void lFpLu(x64emu_t *emu, uintptr_t fnc);
-void lFpLp(x64emu_t *emu, uintptr_t fnc);
-void lFppi(x64emu_t *emu, uintptr_t fnc);
-void lFppL(x64emu_t *emu, uintptr_t fnc);
-void lFppp(x64emu_t *emu, uintptr_t fnc);
-void lFSpl(x64emu_t *emu, uintptr_t fnc);
-void LFEpA(x64emu_t *emu, uintptr_t fnc);
-void LFipL(x64emu_t *emu, uintptr_t fnc);
-void LFLLl(x64emu_t *emu, uintptr_t fnc);
-void LFLpu(x64emu_t *emu, uintptr_t fnc);
-void LFLpL(x64emu_t *emu, uintptr_t fnc);
-void LFpii(x64emu_t *emu, uintptr_t fnc);
-void LFpip(x64emu_t *emu, uintptr_t fnc);
-void LFpLi(x64emu_t *emu, uintptr_t fnc);
-void LFpLp(x64emu_t *emu, uintptr_t fnc);
-void LFppi(x64emu_t *emu, uintptr_t fnc);
-void LFppL(x64emu_t *emu, uintptr_t fnc);
-void LFppp(x64emu_t *emu, uintptr_t fnc);
-void LFSpL(x64emu_t *emu, uintptr_t fnc);
-void pFEip(x64emu_t *emu, uintptr_t fnc);
-void pFEiV(x64emu_t *emu, uintptr_t fnc);
-void pFEup(x64emu_t *emu, uintptr_t fnc);
-void pFEuV(x64emu_t *emu, uintptr_t fnc);
-void pFEpi(x64emu_t *emu, uintptr_t fnc);
-void pFEpu(x64emu_t *emu, uintptr_t fnc);
-void pFEpp(x64emu_t *emu, uintptr_t fnc);
-void pFEpV(x64emu_t *emu, uintptr_t fnc);
-void pFEpA(x64emu_t *emu, uintptr_t fnc);
-void pFiii(x64emu_t *emu, uintptr_t fnc);
-void pFiiu(x64emu_t *emu, uintptr_t fnc);
-void pFiip(x64emu_t *emu, uintptr_t fnc);
-void pFiIi(x64emu_t *emu, uintptr_t fnc);
-void pFiIp(x64emu_t *emu, uintptr_t fnc);
-void pFipi(x64emu_t *emu, uintptr_t fnc);
-void pFipL(x64emu_t *emu, uintptr_t fnc);
-void pFipp(x64emu_t *emu, uintptr_t fnc);
-void pFIpi(x64emu_t *emu, uintptr_t fnc);
-void pFCiW(x64emu_t *emu, uintptr_t fnc);
-void pFWWW(x64emu_t *emu, uintptr_t fnc);
-void pFuii(x64emu_t *emu, uintptr_t fnc);
-void pFuui(x64emu_t *emu, uintptr_t fnc);
-void pFuuu(x64emu_t *emu, uintptr_t fnc);
-void pFupi(x64emu_t *emu, uintptr_t fnc);
-void pFupL(x64emu_t *emu, uintptr_t fnc);
-void pFUpi(x64emu_t *emu, uintptr_t fnc);
-void pFdip(x64emu_t *emu, uintptr_t fnc);
-void pFdUU(x64emu_t *emu, uintptr_t fnc);
-void pFddd(x64emu_t *emu, uintptr_t fnc);
-void pFDip(x64emu_t *emu, uintptr_t fnc);
-void pFLup(x64emu_t *emu, uintptr_t fnc);
-void pFLLp(x64emu_t *emu, uintptr_t fnc);
-void pFpii(x64emu_t *emu, uintptr_t fnc);
-void pFpiu(x64emu_t *emu, uintptr_t fnc);
-void pFpid(x64emu_t *emu, uintptr_t fnc);
-void pFpil(x64emu_t *emu, uintptr_t fnc);
-void pFpiL(x64emu_t *emu, uintptr_t fnc);
-void pFpip(x64emu_t *emu, uintptr_t fnc);
-void pFpCC(x64emu_t *emu, uintptr_t fnc);
-void pFpCu(x64emu_t *emu, uintptr_t fnc);
-void pFpWW(x64emu_t *emu, uintptr_t fnc);
-void pFpui(x64emu_t *emu, uintptr_t fnc);
-void pFpuu(x64emu_t *emu, uintptr_t fnc);
-void pFpuL(x64emu_t *emu, uintptr_t fnc);
-void pFpup(x64emu_t *emu, uintptr_t fnc);
-void pFpUi(x64emu_t *emu, uintptr_t fnc);
-void pFpUp(x64emu_t *emu, uintptr_t fnc);
-void pFpdu(x64emu_t *emu, uintptr_t fnc);
-void pFplC(x64emu_t *emu, uintptr_t fnc);
-void pFplu(x64emu_t *emu, uintptr_t fnc);
-void pFpll(x64emu_t *emu, uintptr_t fnc);
-void pFplp(x64emu_t *emu, uintptr_t fnc);
-void pFpLu(x64emu_t *emu, uintptr_t fnc);
-void pFpLL(x64emu_t *emu, uintptr_t fnc);
-void pFpLp(x64emu_t *emu, uintptr_t fnc);
-void pFppi(x64emu_t *emu, uintptr_t fnc);
-void pFppI(x64emu_t *emu, uintptr_t fnc);
-void pFppC(x64emu_t *emu, uintptr_t fnc);
-void pFppu(x64emu_t *emu, uintptr_t fnc);
-void pFppU(x64emu_t *emu, uintptr_t fnc);
-void pFppf(x64emu_t *emu, uintptr_t fnc);
-void pFppl(x64emu_t *emu, uintptr_t fnc);
-void pFppL(x64emu_t *emu, uintptr_t fnc);
-void pFppp(x64emu_t *emu, uintptr_t fnc);
-void pFpOM(x64emu_t *emu, uintptr_t fnc);
-void pFSpl(x64emu_t *emu, uintptr_t fnc);
-void vWpup(x64emu_t *emu, uintptr_t fnc);
-void iWEip(x64emu_t *emu, uintptr_t fnc);
-void iWEpp(x64emu_t *emu, uintptr_t fnc);
-void iWpiu(x64emu_t *emu, uintptr_t fnc);
-void iWpip(x64emu_t *emu, uintptr_t fnc);
-void iWpui(x64emu_t *emu, uintptr_t fnc);
-void iWpuu(x64emu_t *emu, uintptr_t fnc);
-void iWpup(x64emu_t *emu, uintptr_t fnc);
-void iWppu(x64emu_t *emu, uintptr_t fnc);
-void iWppp(x64emu_t *emu, uintptr_t fnc);
-void uWpui(x64emu_t *emu, uintptr_t fnc);
-void uWpup(x64emu_t *emu, uintptr_t fnc);
-void vFEiip(x64emu_t *emu, uintptr_t fnc);
-void vFEipp(x64emu_t *emu, uintptr_t fnc);
-void vFEipV(x64emu_t *emu, uintptr_t fnc);
-void vFEipA(x64emu_t *emu, uintptr_t fnc);
-void vFELLp(x64emu_t *emu, uintptr_t fnc);
-void vFEpii(x64emu_t *emu, uintptr_t fnc);
-void vFEpip(x64emu_t *emu, uintptr_t fnc);
-void vFEpiA(x64emu_t *emu, uintptr_t fnc);
-void vFEpup(x64emu_t *emu, uintptr_t fnc);
-void vFEpUp(x64emu_t *emu, uintptr_t fnc);
-void vFEppp(x64emu_t *emu, uintptr_t fnc);
-void vFEppV(x64emu_t *emu, uintptr_t fnc);
-void vFEppA(x64emu_t *emu, uintptr_t fnc);
-void vFiiii(x64emu_t *emu, uintptr_t fnc);
-void vFiiip(x64emu_t *emu, uintptr_t fnc);
-void vFiill(x64emu_t *emu, uintptr_t fnc);
-void vFiIII(x64emu_t *emu, uintptr_t fnc);
-void vFiuiu(x64emu_t *emu, uintptr_t fnc);
-void vFiuip(x64emu_t *emu, uintptr_t fnc);
-void vFiuuu(x64emu_t *emu, uintptr_t fnc);
-void vFiuup(x64emu_t *emu, uintptr_t fnc);
-void vFiulp(x64emu_t *emu, uintptr_t fnc);
-void vFiupu(x64emu_t *emu, uintptr_t fnc);
-void vFiupV(x64emu_t *emu, uintptr_t fnc);
-void vFiUUU(x64emu_t *emu, uintptr_t fnc);
-void vFifff(x64emu_t *emu, uintptr_t fnc);
-void vFiddd(x64emu_t *emu, uintptr_t fnc);
-void vFilil(x64emu_t *emu, uintptr_t fnc);
-void vFilip(x64emu_t *emu, uintptr_t fnc);
-void vFiluU(x64emu_t *emu, uintptr_t fnc);
-void vFilpu(x64emu_t *emu, uintptr_t fnc);
-void vFilpp(x64emu_t *emu, uintptr_t fnc);
-void vFipii(x64emu_t *emu, uintptr_t fnc);
-void vFipup(x64emu_t *emu, uintptr_t fnc);
-void vFipll(x64emu_t *emu, uintptr_t fnc);
-void vFippi(x64emu_t *emu, uintptr_t fnc);
-void vFippu(x64emu_t *emu, uintptr_t fnc);
-void vFippp(x64emu_t *emu, uintptr_t fnc);
-void vFuiii(x64emu_t *emu, uintptr_t fnc);
-void vFuiiu(x64emu_t *emu, uintptr_t fnc);
-void vFuiip(x64emu_t *emu, uintptr_t fnc);
-void vFuiII(x64emu_t *emu, uintptr_t fnc);
-void vFuiui(x64emu_t *emu, uintptr_t fnc);
-void vFuiuu(x64emu_t *emu, uintptr_t fnc);
-void vFuiup(x64emu_t *emu, uintptr_t fnc);
-void vFuiUU(x64emu_t *emu, uintptr_t fnc);
-void vFuifi(x64emu_t *emu, uintptr_t fnc);
-void vFuiff(x64emu_t *emu, uintptr_t fnc);
-void vFuidd(x64emu_t *emu, uintptr_t fnc);
-void vFuill(x64emu_t *emu, uintptr_t fnc);
-void vFuilp(x64emu_t *emu, uintptr_t fnc);
-void vFuipi(x64emu_t *emu, uintptr_t fnc);
-void vFuipu(x64emu_t *emu, uintptr_t fnc);
-void vFuipp(x64emu_t *emu, uintptr_t fnc);
-void vFuuii(x64emu_t *emu, uintptr_t fnc);
-void vFuuiu(x64emu_t *emu, uintptr_t fnc);
-void vFuuil(x64emu_t *emu, uintptr_t fnc);
-void vFuuip(x64emu_t *emu, uintptr_t fnc);
-void vFuuui(x64emu_t *emu, uintptr_t fnc);
-void vFuuuu(x64emu_t *emu, uintptr_t fnc);
-void vFuuuf(x64emu_t *emu, uintptr_t fnc);
-void vFuuud(x64emu_t *emu, uintptr_t fnc);
-void vFuuup(x64emu_t *emu, uintptr_t fnc);
-void vFuulp(x64emu_t *emu, uintptr_t fnc);
-void vFuupi(x64emu_t *emu, uintptr_t fnc);
-void vFuupp(x64emu_t *emu, uintptr_t fnc);
-void vFuUii(x64emu_t *emu, uintptr_t fnc);
-void vFuUip(x64emu_t *emu, uintptr_t fnc);
-void vFufff(x64emu_t *emu, uintptr_t fnc);
-void vFuddd(x64emu_t *emu, uintptr_t fnc);
-void vFulil(x64emu_t *emu, uintptr_t fnc);
-void vFulip(x64emu_t *emu, uintptr_t fnc);
-void vFuluU(x64emu_t *emu, uintptr_t fnc);
-void vFullp(x64emu_t *emu, uintptr_t fnc);
-void vFulpi(x64emu_t *emu, uintptr_t fnc);
-void vFulpu(x64emu_t *emu, uintptr_t fnc);
-void vFulpp(x64emu_t *emu, uintptr_t fnc);
-void vFupii(x64emu_t *emu, uintptr_t fnc);
-void vFuppi(x64emu_t *emu, uintptr_t fnc);
-void vFUUpi(x64emu_t *emu, uintptr_t fnc);
-void vFffff(x64emu_t *emu, uintptr_t fnc);
-void vFdddd(x64emu_t *emu, uintptr_t fnc);
-void vFllll(x64emu_t *emu, uintptr_t fnc);
-void vFpiii(x64emu_t *emu, uintptr_t fnc);
-void vFpiiu(x64emu_t *emu, uintptr_t fnc);
-void vFpiip(x64emu_t *emu, uintptr_t fnc);
-void vFpiuu(x64emu_t *emu, uintptr_t fnc);
-void vFpiuL(x64emu_t *emu, uintptr_t fnc);
-void vFpiup(x64emu_t *emu, uintptr_t fnc);
-void vFpiUu(x64emu_t *emu, uintptr_t fnc);
-void vFpiUU(x64emu_t *emu, uintptr_t fnc);
-void vFpifi(x64emu_t *emu, uintptr_t fnc);
-void vFpipi(x64emu_t *emu, uintptr_t fnc);
-void vFpipp(x64emu_t *emu, uintptr_t fnc);
-void vFpIdi(x64emu_t *emu, uintptr_t fnc);
-void vFpCiW(x64emu_t *emu, uintptr_t fnc);
-void vFpuip(x64emu_t *emu, uintptr_t fnc);
-void vFpuui(x64emu_t *emu, uintptr_t fnc);
-void vFpuuu(x64emu_t *emu, uintptr_t fnc);
-void vFpuup(x64emu_t *emu, uintptr_t fnc);
-void vFpudd(x64emu_t *emu, uintptr_t fnc);
-void vFpupp(x64emu_t *emu, uintptr_t fnc);
-void vFpUui(x64emu_t *emu, uintptr_t fnc);
-void vFpUuu(x64emu_t *emu, uintptr_t fnc);
-void vFpUup(x64emu_t *emu, uintptr_t fnc);
-void vFpUUi(x64emu_t *emu, uintptr_t fnc);
-void vFpUUu(x64emu_t *emu, uintptr_t fnc);
-void vFpUUp(x64emu_t *emu, uintptr_t fnc);
-void vFpUpp(x64emu_t *emu, uintptr_t fnc);
-void vFpfff(x64emu_t *emu, uintptr_t fnc);
-void vFpdii(x64emu_t *emu, uintptr_t fnc);
-void vFpdip(x64emu_t *emu, uintptr_t fnc);
-void vFpddi(x64emu_t *emu, uintptr_t fnc);
-void vFpddd(x64emu_t *emu, uintptr_t fnc);
-void vFplpp(x64emu_t *emu, uintptr_t fnc);
-void vFpLLL(x64emu_t *emu, uintptr_t fnc);
-void vFppii(x64emu_t *emu, uintptr_t fnc);
-void vFppiu(x64emu_t *emu, uintptr_t fnc);
-void vFppid(x64emu_t *emu, uintptr_t fnc);
-void vFppil(x64emu_t *emu, uintptr_t fnc);
-void vFppiL(x64emu_t *emu, uintptr_t fnc);
-void vFppip(x64emu_t *emu, uintptr_t fnc);
-void vFppui(x64emu_t *emu, uintptr_t fnc);
-void vFppuu(x64emu_t *emu, uintptr_t fnc);
-void vFppup(x64emu_t *emu, uintptr_t fnc);
-void vFppfi(x64emu_t *emu, uintptr_t fnc);
-void vFppdu(x64emu_t *emu, uintptr_t fnc);
-void vFppdd(x64emu_t *emu, uintptr_t fnc);
-void vFppdp(x64emu_t *emu, uintptr_t fnc);
-void vFpplp(x64emu_t *emu, uintptr_t fnc);
-void vFppLp(x64emu_t *emu, uintptr_t fnc);
-void vFpppi(x64emu_t *emu, uintptr_t fnc);
-void vFpppI(x64emu_t *emu, uintptr_t fnc);
-void vFpppu(x64emu_t *emu, uintptr_t fnc);
-void vFpppU(x64emu_t *emu, uintptr_t fnc);
-void vFpppd(x64emu_t *emu, uintptr_t fnc);
-void vFpppL(x64emu_t *emu, uintptr_t fnc);
-void vFpppp(x64emu_t *emu, uintptr_t fnc);
-void cFpiii(x64emu_t *emu, uintptr_t fnc);
-void iFEiip(x64emu_t *emu, uintptr_t fnc);
-void iFEiiN(x64emu_t *emu, uintptr_t fnc);
-void iFEipp(x64emu_t *emu, uintptr_t fnc);
-void iFEipV(x64emu_t *emu, uintptr_t fnc);
-void iFEupu(x64emu_t *emu, uintptr_t fnc);
-void iFEupp(x64emu_t *emu, uintptr_t fnc);
-void iFEpii(x64emu_t *emu, uintptr_t fnc);
-void iFEpip(x64emu_t *emu, uintptr_t fnc);
-void iFEpiV(x64emu_t *emu, uintptr_t fnc);
-void iFEpiA(x64emu_t *emu, uintptr_t fnc);
-void iFEpui(x64emu_t *emu, uintptr_t fnc);
-void iFEpup(x64emu_t *emu, uintptr_t fnc);
-void iFEpUi(x64emu_t *emu, uintptr_t fnc);
-void iFEpUp(x64emu_t *emu, uintptr_t fnc);
-void iFEpLi(x64emu_t *emu, uintptr_t fnc);
-void iFEpLp(x64emu_t *emu, uintptr_t fnc);
-void iFEppi(x64emu_t *emu, uintptr_t fnc);
-void iFEppd(x64emu_t *emu, uintptr_t fnc);
-void iFEppL(x64emu_t *emu, uintptr_t fnc);
-void iFEppp(x64emu_t *emu, uintptr_t fnc);
-void iFEppV(x64emu_t *emu, uintptr_t fnc);
-void iFEppA(x64emu_t *emu, uintptr_t fnc);
-void iFEpOu(x64emu_t *emu, uintptr_t fnc);
-void iFwwww(x64emu_t *emu, uintptr_t fnc);
-void iFwppp(x64emu_t *emu, uintptr_t fnc);
-void iFiiii(x64emu_t *emu, uintptr_t fnc);
-void iFiiiu(x64emu_t *emu, uintptr_t fnc);
-void iFiiip(x64emu_t *emu, uintptr_t fnc);
-void iFiiiN(x64emu_t *emu, uintptr_t fnc);
-void iFiiui(x64emu_t *emu, uintptr_t fnc);
-void iFiiup(x64emu_t *emu, uintptr_t fnc);
-void iFiill(x64emu_t *emu, uintptr_t fnc);
-void iFiipi(x64emu_t *emu, uintptr_t fnc);
-void iFiipp(x64emu_t *emu, uintptr_t fnc);
-void iFiuwp(x64emu_t *emu, uintptr_t fnc);
-void iFiuii(x64emu_t *emu, uintptr_t fnc);
-void iFiuup(x64emu_t *emu, uintptr_t fnc);
-void iFiupp(x64emu_t *emu, uintptr_t fnc);
-void iFilli(x64emu_t *emu, uintptr_t fnc);
-void iFillu(x64emu_t *emu, uintptr_t fnc);
-void iFipii(x64emu_t *emu, uintptr_t fnc);
-void iFipip(x64emu_t *emu, uintptr_t fnc);
-void iFipui(x64emu_t *emu, uintptr_t fnc);
-void iFipuu(x64emu_t *emu, uintptr_t fnc);
-void iFipup(x64emu_t *emu, uintptr_t fnc);
-void iFipLi(x64emu_t *emu, uintptr_t fnc);
-void iFipLu(x64emu_t *emu, uintptr_t fnc);
-void iFipLp(x64emu_t *emu, uintptr_t fnc);
-void iFippi(x64emu_t *emu, uintptr_t fnc);
-void iFippu(x64emu_t *emu, uintptr_t fnc);
-void iFippL(x64emu_t *emu, uintptr_t fnc);
-void iFippp(x64emu_t *emu, uintptr_t fnc);
-void iFipON(x64emu_t *emu, uintptr_t fnc);
-void iFuipu(x64emu_t *emu, uintptr_t fnc);
-void iFuipp(x64emu_t *emu, uintptr_t fnc);
-void iFuuff(x64emu_t *emu, uintptr_t fnc);
-void iFuupi(x64emu_t *emu, uintptr_t fnc);
-void iFupLp(x64emu_t *emu, uintptr_t fnc);
-void iFuppi(x64emu_t *emu, uintptr_t fnc);
-void iFuppp(x64emu_t *emu, uintptr_t fnc);
-void iFLLiW(x64emu_t *emu, uintptr_t fnc);
-void iFpwww(x64emu_t *emu, uintptr_t fnc);
-void iFpwpp(x64emu_t *emu, uintptr_t fnc);
-void iFpiii(x64emu_t *emu, uintptr_t fnc);
-void iFpiiI(x64emu_t *emu, uintptr_t fnc);
-void iFpiiu(x64emu_t *emu, uintptr_t fnc);
-void iFpiid(x64emu_t *emu, uintptr_t fnc);
-void iFpiiL(x64emu_t *emu, uintptr_t fnc);
-void iFpiip(x64emu_t *emu, uintptr_t fnc);
-void iFpiuu(x64emu_t *emu, uintptr_t fnc);
-void iFpiuL(x64emu_t *emu, uintptr_t fnc);
-void iFpiup(x64emu_t *emu, uintptr_t fnc);
-void iFpiUp(x64emu_t *emu, uintptr_t fnc);
-void iFpild(x64emu_t *emu, uintptr_t fnc);
-void iFpipi(x64emu_t *emu, uintptr_t fnc);
-void iFpipC(x64emu_t *emu, uintptr_t fnc);
-void iFpipu(x64emu_t *emu, uintptr_t fnc);
-void iFpipL(x64emu_t *emu, uintptr_t fnc);
-void iFpipp(x64emu_t *emu, uintptr_t fnc);
-void iFpipV(x64emu_t *emu, uintptr_t fnc);
-void iFpIip(x64emu_t *emu, uintptr_t fnc);
-void iFpCCC(x64emu_t *emu, uintptr_t fnc);
-void iFpCpi(x64emu_t *emu, uintptr_t fnc);
-void iFpWWu(x64emu_t *emu, uintptr_t fnc);
-void iFpuwp(x64emu_t *emu, uintptr_t fnc);
-void iFpuiL(x64emu_t *emu, uintptr_t fnc);
-void iFpuip(x64emu_t *emu, uintptr_t fnc);
-void iFpuui(x64emu_t *emu, uintptr_t fnc);
-void iFpuuu(x64emu_t *emu, uintptr_t fnc);
-void iFpuup(x64emu_t *emu, uintptr_t fnc);
-void iFpuUp(x64emu_t *emu, uintptr_t fnc);
-void iFpuLL(x64emu_t *emu, uintptr_t fnc);
-void iFpuLp(x64emu_t *emu, uintptr_t fnc);
-void iFpupi(x64emu_t *emu, uintptr_t fnc);
-void iFpupu(x64emu_t *emu, uintptr_t fnc);
-void iFpupU(x64emu_t *emu, uintptr_t fnc);
-void iFpupL(x64emu_t *emu, uintptr_t fnc);
-void iFpupp(x64emu_t *emu, uintptr_t fnc);
-void iFpupV(x64emu_t *emu, uintptr_t fnc);
-void iFpUup(x64emu_t *emu, uintptr_t fnc);
-void iFpUUU(x64emu_t *emu, uintptr_t fnc);
-void iFpULp(x64emu_t *emu, uintptr_t fnc);
-void iFpUpp(x64emu_t *emu, uintptr_t fnc);
-void iFplii(x64emu_t *emu, uintptr_t fnc);
-void iFplip(x64emu_t *emu, uintptr_t fnc);
-void iFpLii(x64emu_t *emu, uintptr_t fnc);
-void iFpLip(x64emu_t *emu, uintptr_t fnc);
-void iFpLLu(x64emu_t *emu, uintptr_t fnc);
-void iFpLpi(x64emu_t *emu, uintptr_t fnc);
-void iFpLpf(x64emu_t *emu, uintptr_t fnc);
-void iFpLpd(x64emu_t *emu, uintptr_t fnc);
-void iFpLpD(x64emu_t *emu, uintptr_t fnc);
-void iFpLpL(x64emu_t *emu, uintptr_t fnc);
-void iFpLpp(x64emu_t *emu, uintptr_t fnc);
-void iFppii(x64emu_t *emu, uintptr_t fnc);
-void iFppiu(x64emu_t *emu, uintptr_t fnc);
-void iFppiU(x64emu_t *emu, uintptr_t fnc);
-void iFppiL(x64emu_t *emu, uintptr_t fnc);
-void iFppip(x64emu_t *emu, uintptr_t fnc);
-void iFppIL(x64emu_t *emu, uintptr_t fnc);
-void iFppCC(x64emu_t *emu, uintptr_t fnc);
-void iFppuw(x64emu_t *emu, uintptr_t fnc);
-void iFppui(x64emu_t *emu, uintptr_t fnc);
-void iFppuu(x64emu_t *emu, uintptr_t fnc);
-void iFppup(x64emu_t *emu, uintptr_t fnc);
-void iFppdp(x64emu_t *emu, uintptr_t fnc);
-void iFppll(x64emu_t *emu, uintptr_t fnc);
-void iFpplp(x64emu_t *emu, uintptr_t fnc);
-void iFppLi(x64emu_t *emu, uintptr_t fnc);
-void iFppLL(x64emu_t *emu, uintptr_t fnc);
-void iFppLp(x64emu_t *emu, uintptr_t fnc);
-void iFpppi(x64emu_t *emu, uintptr_t fnc);
-void iFpppC(x64emu_t *emu, uintptr_t fnc);
-void iFpppu(x64emu_t *emu, uintptr_t fnc);
-void iFpppU(x64emu_t *emu, uintptr_t fnc);
-void iFpppL(x64emu_t *emu, uintptr_t fnc);
-void iFpppp(x64emu_t *emu, uintptr_t fnc);
-void IFEpIi(x64emu_t *emu, uintptr_t fnc);
-void IFpIip(x64emu_t *emu, uintptr_t fnc);
-void IFppii(x64emu_t *emu, uintptr_t fnc);
-void IFppip(x64emu_t *emu, uintptr_t fnc);
-void IFpppp(x64emu_t *emu, uintptr_t fnc);
-void IFSIii(x64emu_t *emu, uintptr_t fnc);
-void CFpupp(x64emu_t *emu, uintptr_t fnc);
-void uFEipp(x64emu_t *emu, uintptr_t fnc);
-void uFEupp(x64emu_t *emu, uintptr_t fnc);
-void uFEpup(x64emu_t *emu, uintptr_t fnc);
-void uFEppp(x64emu_t *emu, uintptr_t fnc);
-void uFifff(x64emu_t *emu, uintptr_t fnc);
-void uFuuuu(x64emu_t *emu, uintptr_t fnc);
-void uFpiip(x64emu_t *emu, uintptr_t fnc);
-void uFpipu(x64emu_t *emu, uintptr_t fnc);
-void uFpipp(x64emu_t *emu, uintptr_t fnc);
-void uFpCCC(x64emu_t *emu, uintptr_t fnc);
-void uFpuip(x64emu_t *emu, uintptr_t fnc);
-void uFpuuu(x64emu_t *emu, uintptr_t fnc);
-void uFpuup(x64emu_t *emu, uintptr_t fnc);
-void uFpupu(x64emu_t *emu, uintptr_t fnc);
-void uFppiu(x64emu_t *emu, uintptr_t fnc);
-void uFppLp(x64emu_t *emu, uintptr_t fnc);
-void uFpppi(x64emu_t *emu, uintptr_t fnc);
-void uFpppu(x64emu_t *emu, uintptr_t fnc);
-void uFpppp(x64emu_t *emu, uintptr_t fnc);
-void UFpipp(x64emu_t *emu, uintptr_t fnc);
-void UFpUui(x64emu_t *emu, uintptr_t fnc);
-void UFppii(x64emu_t *emu, uintptr_t fnc);
-void UFppip(x64emu_t *emu, uintptr_t fnc);
-void UFpppp(x64emu_t *emu, uintptr_t fnc);
-void dFpppp(x64emu_t *emu, uintptr_t fnc);
-void lFEipV(x64emu_t *emu, uintptr_t fnc);
-void lFEpip(x64emu_t *emu, uintptr_t fnc);
-void lFEppL(x64emu_t *emu, uintptr_t fnc);
-void lFEppp(x64emu_t *emu, uintptr_t fnc);
-void lFiiLu(x64emu_t *emu, uintptr_t fnc);
-void lFiipL(x64emu_t *emu, uintptr_t fnc);
-void lFipil(x64emu_t *emu, uintptr_t fnc);
-void lFipLi(x64emu_t *emu, uintptr_t fnc);
-void lFipLI(x64emu_t *emu, uintptr_t fnc);
-void lFipLu(x64emu_t *emu, uintptr_t fnc);
-void lFipLl(x64emu_t *emu, uintptr_t fnc);
-void lFipLL(x64emu_t *emu, uintptr_t fnc);
-void lFipLp(x64emu_t *emu, uintptr_t fnc);
-void lFippL(x64emu_t *emu, uintptr_t fnc);
-void lFuipp(x64emu_t *emu, uintptr_t fnc);
-void lFpili(x64emu_t *emu, uintptr_t fnc);
-void lFpilp(x64emu_t *emu, uintptr_t fnc);
-void lFppii(x64emu_t *emu, uintptr_t fnc);
-void lFppip(x64emu_t *emu, uintptr_t fnc);
-void lFpppL(x64emu_t *emu, uintptr_t fnc);
-void LFEppL(x64emu_t *emu, uintptr_t fnc);
-void LFEppp(x64emu_t *emu, uintptr_t fnc);
-void LFippL(x64emu_t *emu, uintptr_t fnc);
-void LFippp(x64emu_t *emu, uintptr_t fnc);
-void LFpuuu(x64emu_t *emu, uintptr_t fnc);
-void LFpLCL(x64emu_t *emu, uintptr_t fnc);
-void LFpLLp(x64emu_t *emu, uintptr_t fnc);
-void LFpLpL(x64emu_t *emu, uintptr_t fnc);
-void LFpLpp(x64emu_t *emu, uintptr_t fnc);
-void LFppii(x64emu_t *emu, uintptr_t fnc);
-void LFppip(x64emu_t *emu, uintptr_t fnc);
-void LFppLL(x64emu_t *emu, uintptr_t fnc);
-void LFppLp(x64emu_t *emu, uintptr_t fnc);
-void LFpppi(x64emu_t *emu, uintptr_t fnc);
-void LFpppp(x64emu_t *emu, uintptr_t fnc);
-void pFEipp(x64emu_t *emu, uintptr_t fnc);
-void pFEupp(x64emu_t *emu, uintptr_t fnc);
-void pFELpV(x64emu_t *emu, uintptr_t fnc);
-void pFELpA(x64emu_t *emu, uintptr_t fnc);
-void pFEpii(x64emu_t *emu, uintptr_t fnc);
-void pFEpip(x64emu_t *emu, uintptr_t fnc);
-void pFEppi(x64emu_t *emu, uintptr_t fnc);
-void pFEppp(x64emu_t *emu, uintptr_t fnc);
-void pFEppV(x64emu_t *emu, uintptr_t fnc);
-void pFiiii(x64emu_t *emu, uintptr_t fnc);
-void pFiiiu(x64emu_t *emu, uintptr_t fnc);
-void pFiiuu(x64emu_t *emu, uintptr_t fnc);
-void pFiiup(x64emu_t *emu, uintptr_t fnc);
-void pFiipi(x64emu_t *emu, uintptr_t fnc);
-void pFiipp(x64emu_t *emu, uintptr_t fnc);
-void pFiIIi(x64emu_t *emu, uintptr_t fnc);
-void pFillu(x64emu_t *emu, uintptr_t fnc);
-void pFipii(x64emu_t *emu, uintptr_t fnc);
-void pFipip(x64emu_t *emu, uintptr_t fnc);
-void pFippi(x64emu_t *emu, uintptr_t fnc);
-void pFippu(x64emu_t *emu, uintptr_t fnc);
-void pFuiii(x64emu_t *emu, uintptr_t fnc);
-void pFuuii(x64emu_t *emu, uintptr_t fnc);
-void pFulli(x64emu_t *emu, uintptr_t fnc);
-void pFullu(x64emu_t *emu, uintptr_t fnc);
-void pFffff(x64emu_t *emu, uintptr_t fnc);
-void pFdipp(x64emu_t *emu, uintptr_t fnc);
-void pFdddd(x64emu_t *emu, uintptr_t fnc);
-void pFDipp(x64emu_t *emu, uintptr_t fnc);
-void pFlfff(x64emu_t *emu, uintptr_t fnc);
-void pFLiip(x64emu_t *emu, uintptr_t fnc);
-void pFpiii(x64emu_t *emu, uintptr_t fnc);
-void pFpiip(x64emu_t *emu, uintptr_t fnc);
-void pFpiuu(x64emu_t *emu, uintptr_t fnc);
-void pFpiLL(x64emu_t *emu, uintptr_t fnc);
-void pFpipi(x64emu_t *emu, uintptr_t fnc);
-void pFpipd(x64emu_t *emu, uintptr_t fnc);
-void pFpipp(x64emu_t *emu, uintptr_t fnc);
-void pFpCWp(x64emu_t *emu, uintptr_t fnc);
-void pFpCuW(x64emu_t *emu, uintptr_t fnc);
-void pFpCuu(x64emu_t *emu, uintptr_t fnc);
-void pFpuii(x64emu_t *emu, uintptr_t fnc);
-void pFpuip(x64emu_t *emu, uintptr_t fnc);
-void pFpuWp(x64emu_t *emu, uintptr_t fnc);
-void pFpuuC(x64emu_t *emu, uintptr_t fnc);
-void pFpuuu(x64emu_t *emu, uintptr_t fnc);
-void pFpuup(x64emu_t *emu, uintptr_t fnc);
-void pFpupi(x64emu_t *emu, uintptr_t fnc);
-void pFpupu(x64emu_t *emu, uintptr_t fnc);
-void pFpdIU(x64emu_t *emu, uintptr_t fnc);
-void pFplpl(x64emu_t *emu, uintptr_t fnc);
-void pFplpp(x64emu_t *emu, uintptr_t fnc);
-void pFpLip(x64emu_t *emu, uintptr_t fnc);
-void pFpLLp(x64emu_t *emu, uintptr_t fnc);
-void pFpLpL(x64emu_t *emu, uintptr_t fnc);
-void pFppii(x64emu_t *emu, uintptr_t fnc);
-void pFppiu(x64emu_t *emu, uintptr_t fnc);
-void pFppiL(x64emu_t *emu, uintptr_t fnc);
-void pFppip(x64emu_t *emu, uintptr_t fnc);
-void pFppWW(x64emu_t *emu, uintptr_t fnc);
-void pFppuW(x64emu_t *emu, uintptr_t fnc);
-void pFppuu(x64emu_t *emu, uintptr_t fnc);
-void pFppuL(x64emu_t *emu, uintptr_t fnc);
-void pFppup(x64emu_t *emu, uintptr_t fnc);
-void pFppUU(x64emu_t *emu, uintptr_t fnc);
-void pFppdd(x64emu_t *emu, uintptr_t fnc);
-void pFppll(x64emu_t *emu, uintptr_t fnc);
-void pFppLL(x64emu_t *emu, uintptr_t fnc);
-void pFppLp(x64emu_t *emu, uintptr_t fnc);
-void pFpppi(x64emu_t *emu, uintptr_t fnc);
-void pFpppu(x64emu_t *emu, uintptr_t fnc);
-void pFpppU(x64emu_t *emu, uintptr_t fnc);
-void pFpppL(x64emu_t *emu, uintptr_t fnc);
-void pFpppp(x64emu_t *emu, uintptr_t fnc);
-void pFSppi(x64emu_t *emu, uintptr_t fnc);
-void vWpiiu(x64emu_t *emu, uintptr_t fnc);
-void vWpuup(x64emu_t *emu, uintptr_t fnc);
-void iWEpip(x64emu_t *emu, uintptr_t fnc);
-void iWEpup(x64emu_t *emu, uintptr_t fnc);
-void iWEppu(x64emu_t *emu, uintptr_t fnc);
-void iWEppp(x64emu_t *emu, uintptr_t fnc);
-void iWpiii(x64emu_t *emu, uintptr_t fnc);
-void iWpiuu(x64emu_t *emu, uintptr_t fnc);
-void iWpuiu(x64emu_t *emu, uintptr_t fnc);
-void iWpuip(x64emu_t *emu, uintptr_t fnc);
-void iWpuup(x64emu_t *emu, uintptr_t fnc);
-void iWpupu(x64emu_t *emu, uintptr_t fnc);
-void iWpupp(x64emu_t *emu, uintptr_t fnc);
-void iWppuu(x64emu_t *emu, uintptr_t fnc);
-void iWpppu(x64emu_t *emu, uintptr_t fnc);
-void iWpppp(x64emu_t *emu, uintptr_t fnc);
-void vFEiipV(x64emu_t *emu, uintptr_t fnc);
-void vFEiipA(x64emu_t *emu, uintptr_t fnc);
-void vFEippp(x64emu_t *emu, uintptr_t fnc);
-void vFEpipV(x64emu_t *emu, uintptr_t fnc);
-void vFEpipA(x64emu_t *emu, uintptr_t fnc);
-void vFEpuup(x64emu_t *emu, uintptr_t fnc);
-void vFEpuuV(x64emu_t *emu, uintptr_t fnc);
-void vFEpupp(x64emu_t *emu, uintptr_t fnc);
-void vFEpupA(x64emu_t *emu, uintptr_t fnc);
-void vFEpLLp(x64emu_t *emu, uintptr_t fnc);
-void vFEppip(x64emu_t *emu, uintptr_t fnc);
-void vFEppiV(x64emu_t *emu, uintptr_t fnc);
-void vFEppup(x64emu_t *emu, uintptr_t fnc);
-void vFEpppi(x64emu_t *emu, uintptr_t fnc);
-void vFEpppp(x64emu_t *emu, uintptr_t fnc);
-void vFiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFiiiiu(x64emu_t *emu, uintptr_t fnc);
-void vFiiipi(x64emu_t *emu, uintptr_t fnc);
-void vFiiuii(x64emu_t *emu, uintptr_t fnc);
-void vFiiuup(x64emu_t *emu, uintptr_t fnc);
-void vFiillu(x64emu_t *emu, uintptr_t fnc);
-void vFiilll(x64emu_t *emu, uintptr_t fnc);
-void vFiipii(x64emu_t *emu, uintptr_t fnc);
-void vFiipll(x64emu_t *emu, uintptr_t fnc);
-void vFiIIII(x64emu_t *emu, uintptr_t fnc);
-void vFiuiip(x64emu_t *emu, uintptr_t fnc);
-void vFiuipi(x64emu_t *emu, uintptr_t fnc);
-void vFiuuuu(x64emu_t *emu, uintptr_t fnc);
-void vFiulpp(x64emu_t *emu, uintptr_t fnc);
-void vFiuppu(x64emu_t *emu, uintptr_t fnc);
-void vFiUUUU(x64emu_t *emu, uintptr_t fnc);
-void vFiffff(x64emu_t *emu, uintptr_t fnc);
-void vFidddd(x64emu_t *emu, uintptr_t fnc);
-void vFilill(x64emu_t *emu, uintptr_t fnc);
-void vFilipi(x64emu_t *emu, uintptr_t fnc);
-void vFilipl(x64emu_t *emu, uintptr_t fnc);
-void vFillpu(x64emu_t *emu, uintptr_t fnc);
-void vFipipu(x64emu_t *emu, uintptr_t fnc);
-void vFipipp(x64emu_t *emu, uintptr_t fnc);
-void vFipupi(x64emu_t *emu, uintptr_t fnc);
-void vFiplli(x64emu_t *emu, uintptr_t fnc);
-void vFiplll(x64emu_t *emu, uintptr_t fnc);
-void vFuiiii(x64emu_t *emu, uintptr_t fnc);
-void vFuiiiu(x64emu_t *emu, uintptr_t fnc);
-void vFuiiip(x64emu_t *emu, uintptr_t fnc);
-void vFuiifi(x64emu_t *emu, uintptr_t fnc);
-void vFuiill(x64emu_t *emu, uintptr_t fnc);
-void vFuiilp(x64emu_t *emu, uintptr_t fnc);
-void vFuiIII(x64emu_t *emu, uintptr_t fnc);
-void vFuiuii(x64emu_t *emu, uintptr_t fnc);
-void vFuiuiu(x64emu_t *emu, uintptr_t fnc);
-void vFuiuip(x64emu_t *emu, uintptr_t fnc);
-void vFuiuuu(x64emu_t *emu, uintptr_t fnc);
-void vFuiuup(x64emu_t *emu, uintptr_t fnc);
-void vFuiull(x64emu_t *emu, uintptr_t fnc);
-void vFuiupi(x64emu_t *emu, uintptr_t fnc);
-void vFuiUUU(x64emu_t *emu, uintptr_t fnc);
-void vFuifff(x64emu_t *emu, uintptr_t fnc);
-void vFuiddd(x64emu_t *emu, uintptr_t fnc);
-void vFuipii(x64emu_t *emu, uintptr_t fnc);
-void vFuipip(x64emu_t *emu, uintptr_t fnc);
-void vFuipup(x64emu_t *emu, uintptr_t fnc);
-void vFuippp(x64emu_t *emu, uintptr_t fnc);
-void vFuuiii(x64emu_t *emu, uintptr_t fnc);
-void vFuuiiu(x64emu_t *emu, uintptr_t fnc);
-void vFuuiui(x64emu_t *emu, uintptr_t fnc);
-void vFuuiuu(x64emu_t *emu, uintptr_t fnc);
-void vFuuiup(x64emu_t *emu, uintptr_t fnc);
-void vFuuipi(x64emu_t *emu, uintptr_t fnc);
-void vFuuipu(x64emu_t *emu, uintptr_t fnc);
-void vFuuipp(x64emu_t *emu, uintptr_t fnc);
-void vFuuuii(x64emu_t *emu, uintptr_t fnc);
-void vFuuuiu(x64emu_t *emu, uintptr_t fnc);
-void vFuuuip(x64emu_t *emu, uintptr_t fnc);
-void vFuuuui(x64emu_t *emu, uintptr_t fnc);
-void vFuuuuu(x64emu_t *emu, uintptr_t fnc);
-void vFuuuup(x64emu_t *emu, uintptr_t fnc);
-void vFuuull(x64emu_t *emu, uintptr_t fnc);
-void vFuuulp(x64emu_t *emu, uintptr_t fnc);
-void vFuulll(x64emu_t *emu, uintptr_t fnc);
-void vFuullp(x64emu_t *emu, uintptr_t fnc);
-void vFuulpp(x64emu_t *emu, uintptr_t fnc);
-void vFuupii(x64emu_t *emu, uintptr_t fnc);
-void vFuffff(x64emu_t *emu, uintptr_t fnc);
-void vFudddd(x64emu_t *emu, uintptr_t fnc);
-void vFulill(x64emu_t *emu, uintptr_t fnc);
-void vFullip(x64emu_t *emu, uintptr_t fnc);
-void vFullpp(x64emu_t *emu, uintptr_t fnc);
-void vFupupi(x64emu_t *emu, uintptr_t fnc);
-void vFuppip(x64emu_t *emu, uintptr_t fnc);
-void vFupppp(x64emu_t *emu, uintptr_t fnc);
-void vFUUppp(x64emu_t *emu, uintptr_t fnc);
-void vFfffff(x64emu_t *emu, uintptr_t fnc);
-void vFddddp(x64emu_t *emu, uintptr_t fnc);
-void vFpiiii(x64emu_t *emu, uintptr_t fnc);
-void vFpiiiI(x64emu_t *emu, uintptr_t fnc);
-void vFpiiiu(x64emu_t *emu, uintptr_t fnc);
-void vFpiiip(x64emu_t *emu, uintptr_t fnc);
-void vFpiiII(x64emu_t *emu, uintptr_t fnc);
-void vFpiiff(x64emu_t *emu, uintptr_t fnc);
-void vFpiipp(x64emu_t *emu, uintptr_t fnc);
-void vFpiIiI(x64emu_t *emu, uintptr_t fnc);
-void vFpiIII(x64emu_t *emu, uintptr_t fnc);
-void vFpiUUp(x64emu_t *emu, uintptr_t fnc);
-void vFpilpp(x64emu_t *emu, uintptr_t fnc);
-void vFpipii(x64emu_t *emu, uintptr_t fnc);
-void vFpipiu(x64emu_t *emu, uintptr_t fnc);
-void vFpuiip(x64emu_t *emu, uintptr_t fnc);
-void vFpuipp(x64emu_t *emu, uintptr_t fnc);
-void vFpuuuu(x64emu_t *emu, uintptr_t fnc);
-void vFpuuup(x64emu_t *emu, uintptr_t fnc);
-void vFpuupp(x64emu_t *emu, uintptr_t fnc);
-void vFpuUUu(x64emu_t *emu, uintptr_t fnc);
-void vFpuddd(x64emu_t *emu, uintptr_t fnc);
-void vFpupup(x64emu_t *emu, uintptr_t fnc);
-void vFpUuiu(x64emu_t *emu, uintptr_t fnc);
-void vFpUUuu(x64emu_t *emu, uintptr_t fnc);
-void vFpUUup(x64emu_t *emu, uintptr_t fnc);
-void vFpUUUu(x64emu_t *emu, uintptr_t fnc);
-void vFpUUUp(x64emu_t *emu, uintptr_t fnc);
-void vFpUppp(x64emu_t *emu, uintptr_t fnc);
-void vFpffff(x64emu_t *emu, uintptr_t fnc);
-void vFpdiII(x64emu_t *emu, uintptr_t fnc);
-void vFpddii(x64emu_t *emu, uintptr_t fnc);
-void vFpdddd(x64emu_t *emu, uintptr_t fnc);
-void vFpddpp(x64emu_t *emu, uintptr_t fnc);
-void vFpliil(x64emu_t *emu, uintptr_t fnc);
-void vFplppp(x64emu_t *emu, uintptr_t fnc);
-void vFpLLpp(x64emu_t *emu, uintptr_t fnc);
-void vFppiii(x64emu_t *emu, uintptr_t fnc);
-void vFppiiu(x64emu_t *emu, uintptr_t fnc);
-void vFppiip(x64emu_t *emu, uintptr_t fnc);
-void vFppiup(x64emu_t *emu, uintptr_t fnc);
-void vFppiff(x64emu_t *emu, uintptr_t fnc);
-void vFppipi(x64emu_t *emu, uintptr_t fnc);
-void vFppipp(x64emu_t *emu, uintptr_t fnc);
-void vFppWui(x64emu_t *emu, uintptr_t fnc);
-void vFppuui(x64emu_t *emu, uintptr_t fnc);
-void vFppuuu(x64emu_t *emu, uintptr_t fnc);
-void vFppuup(x64emu_t *emu, uintptr_t fnc);
-void vFppupi(x64emu_t *emu, uintptr_t fnc);
-void vFppupp(x64emu_t *emu, uintptr_t fnc);
-void vFppddp(x64emu_t *emu, uintptr_t fnc);
-void vFpppii(x64emu_t *emu, uintptr_t fnc);
-void vFpppip(x64emu_t *emu, uintptr_t fnc);
-void vFpppuu(x64emu_t *emu, uintptr_t fnc);
-void vFpppup(x64emu_t *emu, uintptr_t fnc);
-void vFpppdd(x64emu_t *emu, uintptr_t fnc);
-void vFppppi(x64emu_t *emu, uintptr_t fnc);
-void vFppppu(x64emu_t *emu, uintptr_t fnc);
-void vFppppL(x64emu_t *emu, uintptr_t fnc);
-void vFppppp(x64emu_t *emu, uintptr_t fnc);
-void iFEiipp(x64emu_t *emu, uintptr_t fnc);
-void iFEiipV(x64emu_t *emu, uintptr_t fnc);
-void iFEippi(x64emu_t *emu, uintptr_t fnc);
-void iFEippL(x64emu_t *emu, uintptr_t fnc);
-void iFEippp(x64emu_t *emu, uintptr_t fnc);
-void iFEpiii(x64emu_t *emu, uintptr_t fnc);
-void iFEpipi(x64emu_t *emu, uintptr_t fnc);
-void iFEpipp(x64emu_t *emu, uintptr_t fnc);
-void iFEpipV(x64emu_t *emu, uintptr_t fnc);
-void iFEpipA(x64emu_t *emu, uintptr_t fnc);
-void iFEpUup(x64emu_t *emu, uintptr_t fnc);
-void iFEpLpp(x64emu_t *emu, uintptr_t fnc);
-void iFEpLpV(x64emu_t *emu, uintptr_t fnc);
-void iFEpLpA(x64emu_t *emu, uintptr_t fnc);
-void iFEppii(x64emu_t *emu, uintptr_t fnc);
-void iFEppip(x64emu_t *emu, uintptr_t fnc);
-void iFEppiV(x64emu_t *emu, uintptr_t fnc);
-void iFEppiA(x64emu_t *emu, uintptr_t fnc);
-void iFEpplp(x64emu_t *emu, uintptr_t fnc);
-void iFEpppi(x64emu_t *emu, uintptr_t fnc);
-void iFEpppL(x64emu_t *emu, uintptr_t fnc);
-void iFEpppp(x64emu_t *emu, uintptr_t fnc);
-void iFEpppV(x64emu_t *emu, uintptr_t fnc);
-void iFiiipu(x64emu_t *emu, uintptr_t fnc);
-void iFiiipp(x64emu_t *emu, uintptr_t fnc);
-void iFiiupp(x64emu_t *emu, uintptr_t fnc);
-void iFiipup(x64emu_t *emu, uintptr_t fnc);
-void iFiuLip(x64emu_t *emu, uintptr_t fnc);
-void iFipiii(x64emu_t *emu, uintptr_t fnc);
-void iFipiup(x64emu_t *emu, uintptr_t fnc);
-void iFipipi(x64emu_t *emu, uintptr_t fnc);
-void iFipipu(x64emu_t *emu, uintptr_t fnc);
-void iFipuip(x64emu_t *emu, uintptr_t fnc);
-void iFipuui(x64emu_t *emu, uintptr_t fnc);
-void iFipLup(x64emu_t *emu, uintptr_t fnc);
-void iFippip(x64emu_t *emu, uintptr_t fnc);
-void iFippLi(x64emu_t *emu, uintptr_t fnc);
-void iFippLp(x64emu_t *emu, uintptr_t fnc);
-void iFipppi(x64emu_t *emu, uintptr_t fnc);
-void iFipppp(x64emu_t *emu, uintptr_t fnc);
-void iFuppLp(x64emu_t *emu, uintptr_t fnc);
-void iFpwwww(x64emu_t *emu, uintptr_t fnc);
-void iFpwppp(x64emu_t *emu, uintptr_t fnc);
-void iFpiiii(x64emu_t *emu, uintptr_t fnc);
-void iFpiiiu(x64emu_t *emu, uintptr_t fnc);
-void iFpiiiL(x64emu_t *emu, uintptr_t fnc);
-void iFpiiip(x64emu_t *emu, uintptr_t fnc);
-void iFpiiui(x64emu_t *emu, uintptr_t fnc);
-void iFpiiuu(x64emu_t *emu, uintptr_t fnc);
-void iFpiipi(x64emu_t *emu, uintptr_t fnc);
-void iFpiipp(x64emu_t *emu, uintptr_t fnc);
-void iFpiIip(x64emu_t *emu, uintptr_t fnc);
-void iFpiuwp(x64emu_t *emu, uintptr_t fnc);
-void iFpiUUU(x64emu_t *emu, uintptr_t fnc);
-void iFpipii(x64emu_t *emu, uintptr_t fnc);
-void iFpipiu(x64emu_t *emu, uintptr_t fnc);
-void iFpipiL(x64emu_t *emu, uintptr_t fnc);
-void iFpipip(x64emu_t *emu, uintptr_t fnc);
-void iFpippi(x64emu_t *emu, uintptr_t fnc);
-void iFpippW(x64emu_t *emu, uintptr_t fnc);
-void iFpippp(x64emu_t *emu, uintptr_t fnc);
-void iFpCCCC(x64emu_t *emu, uintptr_t fnc);
-void iFpuill(x64emu_t *emu, uintptr_t fnc);
-void iFpuipi(x64emu_t *emu, uintptr_t fnc);
-void iFpuuip(x64emu_t *emu, uintptr_t fnc);
-void iFpuuui(x64emu_t *emu, uintptr_t fnc);
-void iFpuuup(x64emu_t *emu, uintptr_t fnc);
-void iFpuuLL(x64emu_t *emu, uintptr_t fnc);
-void iFpuupp(x64emu_t *emu, uintptr_t fnc);
-void iFpupiU(x64emu_t *emu, uintptr_t fnc);
-void iFpupup(x64emu_t *emu, uintptr_t fnc);
-void iFpuppp(x64emu_t *emu, uintptr_t fnc);
-void iFpUiUi(x64emu_t *emu, uintptr_t fnc);
-void iFpUupp(x64emu_t *emu, uintptr_t fnc);
-void iFplluu(x64emu_t *emu, uintptr_t fnc);
-void iFpLiLi(x64emu_t *emu, uintptr_t fnc);
-void iFpLlpp(x64emu_t *emu, uintptr_t fnc);
-void iFpLLpp(x64emu_t *emu, uintptr_t fnc);
-void iFpLppi(x64emu_t *emu, uintptr_t fnc);
-void iFppiiu(x64emu_t *emu, uintptr_t fnc);
-void iFppiip(x64emu_t *emu, uintptr_t fnc);
-void iFppiup(x64emu_t *emu, uintptr_t fnc);
-void iFppiLi(x64emu_t *emu, uintptr_t fnc);
-void iFppiLL(x64emu_t *emu, uintptr_t fnc);
-void iFppipi(x64emu_t *emu, uintptr_t fnc);
-void iFppipp(x64emu_t *emu, uintptr_t fnc);
-void iFppuwp(x64emu_t *emu, uintptr_t fnc);
-void iFppuip(x64emu_t *emu, uintptr_t fnc);
-void iFppuup(x64emu_t *emu, uintptr_t fnc);
-void iFppupi(x64emu_t *emu, uintptr_t fnc);
-void iFppupp(x64emu_t *emu, uintptr_t fnc);
-void iFppllp(x64emu_t *emu, uintptr_t fnc);
-void iFpplpp(x64emu_t *emu, uintptr_t fnc);
-void iFppLip(x64emu_t *emu, uintptr_t fnc);
-void iFppLpi(x64emu_t *emu, uintptr_t fnc);
-void iFppLpL(x64emu_t *emu, uintptr_t fnc);
-void iFppLpp(x64emu_t *emu, uintptr_t fnc);
-void iFpppii(x64emu_t *emu, uintptr_t fnc);
-void iFpppiL(x64emu_t *emu, uintptr_t fnc);
-void iFpppip(x64emu_t *emu, uintptr_t fnc);
-void iFpppui(x64emu_t *emu, uintptr_t fnc);
-void iFpppUi(x64emu_t *emu, uintptr_t fnc);
-void iFpppLi(x64emu_t *emu, uintptr_t fnc);
-void iFpppLp(x64emu_t *emu, uintptr_t fnc);
-void iFppppi(x64emu_t *emu, uintptr_t fnc);
-void iFppppL(x64emu_t *emu, uintptr_t fnc);
-void iFppppp(x64emu_t *emu, uintptr_t fnc);
-void IFppIII(x64emu_t *emu, uintptr_t fnc);
-void uFEippp(x64emu_t *emu, uintptr_t fnc);
-void uFEpipp(x64emu_t *emu, uintptr_t fnc);
-void uFEppuu(x64emu_t *emu, uintptr_t fnc);
-void uFEpppp(x64emu_t *emu, uintptr_t fnc);
-void uFEpppV(x64emu_t *emu, uintptr_t fnc);
-void uFiuuuu(x64emu_t *emu, uintptr_t fnc);
-void uFipipp(x64emu_t *emu, uintptr_t fnc);
-void uFipLpp(x64emu_t *emu, uintptr_t fnc);
-void uFuiiiu(x64emu_t *emu, uintptr_t fnc);
-void uFpCCCC(x64emu_t *emu, uintptr_t fnc);
-void uFpWuip(x64emu_t *emu, uintptr_t fnc);
-void uFpuuuu(x64emu_t *emu, uintptr_t fnc);
-void uFpupuu(x64emu_t *emu, uintptr_t fnc);
-void uFppiip(x64emu_t *emu, uintptr_t fnc);
-void uFppipp(x64emu_t *emu, uintptr_t fnc);
-void uFppuup(x64emu_t *emu, uintptr_t fnc);
-void uFppupp(x64emu_t *emu, uintptr_t fnc);
-void uFpplip(x64emu_t *emu, uintptr_t fnc);
-void uFppLpp(x64emu_t *emu, uintptr_t fnc);
-void uFppppu(x64emu_t *emu, uintptr_t fnc);
-void uFppppp(x64emu_t *emu, uintptr_t fnc);
-void UFuiiii(x64emu_t *emu, uintptr_t fnc);
-void lFipili(x64emu_t *emu, uintptr_t fnc);
-void lFipLli(x64emu_t *emu, uintptr_t fnc);
-void lFipLlL(x64emu_t *emu, uintptr_t fnc);
-void lFipLLi(x64emu_t *emu, uintptr_t fnc);
-void lFipLpp(x64emu_t *emu, uintptr_t fnc);
-void LFELppi(x64emu_t *emu, uintptr_t fnc);
-void LFEpppp(x64emu_t *emu, uintptr_t fnc);
-void LFpuipp(x64emu_t *emu, uintptr_t fnc);
-void LFpuppi(x64emu_t *emu, uintptr_t fnc);
-void LFpLLLp(x64emu_t *emu, uintptr_t fnc);
-void LFpLppL(x64emu_t *emu, uintptr_t fnc);
-void LFpLppp(x64emu_t *emu, uintptr_t fnc);
-void LFppLLp(x64emu_t *emu, uintptr_t fnc);
-void LFpppii(x64emu_t *emu, uintptr_t fnc);
-void LFppppp(x64emu_t *emu, uintptr_t fnc);
-void pFEpiii(x64emu_t *emu, uintptr_t fnc);
-void pFEpipL(x64emu_t *emu, uintptr_t fnc);
-void pFEpipp(x64emu_t *emu, uintptr_t fnc);
-void pFEpipV(x64emu_t *emu, uintptr_t fnc);
-void pFEpipA(x64emu_t *emu, uintptr_t fnc);
-void pFEpupp(x64emu_t *emu, uintptr_t fnc);
-void pFEppii(x64emu_t *emu, uintptr_t fnc);
-void pFEppip(x64emu_t *emu, uintptr_t fnc);
-void pFEppLp(x64emu_t *emu, uintptr_t fnc);
-void pFEpppi(x64emu_t *emu, uintptr_t fnc);
-void pFEpppu(x64emu_t *emu, uintptr_t fnc);
-void pFEpppp(x64emu_t *emu, uintptr_t fnc);
-void pFiiiii(x64emu_t *emu, uintptr_t fnc);
-void pFiiipL(x64emu_t *emu, uintptr_t fnc);
-void pFipipL(x64emu_t *emu, uintptr_t fnc);
-void pFipppu(x64emu_t *emu, uintptr_t fnc);
-void pFuiiiu(x64emu_t *emu, uintptr_t fnc);
-void pFuiipp(x64emu_t *emu, uintptr_t fnc);
-void pFpiiii(x64emu_t *emu, uintptr_t fnc);
-void pFpiiip(x64emu_t *emu, uintptr_t fnc);
-void pFpiiuu(x64emu_t *emu, uintptr_t fnc);
-void pFpiipi(x64emu_t *emu, uintptr_t fnc);
-void pFpiipp(x64emu_t *emu, uintptr_t fnc);
-void pFpiCCC(x64emu_t *emu, uintptr_t fnc);
-void pFpiuuu(x64emu_t *emu, uintptr_t fnc);
-void pFpippi(x64emu_t *emu, uintptr_t fnc);
-void pFpippp(x64emu_t *emu, uintptr_t fnc);
-void pFpCpup(x64emu_t *emu, uintptr_t fnc);
-void pFpCppp(x64emu_t *emu, uintptr_t fnc);
-void pFpuiii(x64emu_t *emu, uintptr_t fnc);
-void pFpuiip(x64emu_t *emu, uintptr_t fnc);
-void pFpuWWW(x64emu_t *emu, uintptr_t fnc);
-void pFpuuip(x64emu_t *emu, uintptr_t fnc);
-void pFpuuWW(x64emu_t *emu, uintptr_t fnc);
-void pFpuuuu(x64emu_t *emu, uintptr_t fnc);
-void pFpuuup(x64emu_t *emu, uintptr_t fnc);
-void pFpuppp(x64emu_t *emu, uintptr_t fnc);
-void pFpUdii(x64emu_t *emu, uintptr_t fnc);
-void pFpdddd(x64emu_t *emu, uintptr_t fnc);
-void pFplppp(x64emu_t *emu, uintptr_t fnc);
-void pFppiii(x64emu_t *emu, uintptr_t fnc);
-void pFppiip(x64emu_t *emu, uintptr_t fnc);
-void pFppiup(x64emu_t *emu, uintptr_t fnc);
-void pFppipi(x64emu_t *emu, uintptr_t fnc);
-void pFppipp(x64emu_t *emu, uintptr_t fnc);
-void pFppuuu(x64emu_t *emu, uintptr_t fnc);
-void pFppuup(x64emu_t *emu, uintptr_t fnc);
-void pFppddi(x64emu_t *emu, uintptr_t fnc);
-void pFppLii(x64emu_t *emu, uintptr_t fnc);
-void pFppLLp(x64emu_t *emu, uintptr_t fnc);
-void pFpppii(x64emu_t *emu, uintptr_t fnc);
-void pFpppip(x64emu_t *emu, uintptr_t fnc);
-void pFpppIi(x64emu_t *emu, uintptr_t fnc);
-void pFpppui(x64emu_t *emu, uintptr_t fnc);
-void pFpppuu(x64emu_t *emu, uintptr_t fnc);
-void pFpppup(x64emu_t *emu, uintptr_t fnc);
-void pFpppLi(x64emu_t *emu, uintptr_t fnc);
-void pFppppi(x64emu_t *emu, uintptr_t fnc);
-void pFppppu(x64emu_t *emu, uintptr_t fnc);
-void pFppppp(x64emu_t *emu, uintptr_t fnc);
-void iWEpiup(x64emu_t *emu, uintptr_t fnc);
-void iWEpipp(x64emu_t *emu, uintptr_t fnc);
-void iWpiiii(x64emu_t *emu, uintptr_t fnc);
-void iWpiupu(x64emu_t *emu, uintptr_t fnc);
-void iWpuiii(x64emu_t *emu, uintptr_t fnc);
-void iWpuiup(x64emu_t *emu, uintptr_t fnc);
-void iWpuupu(x64emu_t *emu, uintptr_t fnc);
-void iWpuupp(x64emu_t *emu, uintptr_t fnc);
-void iWpupuu(x64emu_t *emu, uintptr_t fnc);
-void iWpupup(x64emu_t *emu, uintptr_t fnc);
-void iWpuppu(x64emu_t *emu, uintptr_t fnc);
-void iWpuppp(x64emu_t *emu, uintptr_t fnc);
-void iWpppuu(x64emu_t *emu, uintptr_t fnc);
-void iWpppup(x64emu_t *emu, uintptr_t fnc);
-void iWppppp(x64emu_t *emu, uintptr_t fnc);
-void vFEiiipp(x64emu_t *emu, uintptr_t fnc);
-void vFEpiLpp(x64emu_t *emu, uintptr_t fnc);
-void vFEpippp(x64emu_t *emu, uintptr_t fnc);
-void vFEpuipp(x64emu_t *emu, uintptr_t fnc);
-void vFEpupup(x64emu_t *emu, uintptr_t fnc);
-void vFEpLLpp(x64emu_t *emu, uintptr_t fnc);
-void vFEppipV(x64emu_t *emu, uintptr_t fnc);
-void vFEppipA(x64emu_t *emu, uintptr_t fnc);
-void vFEppupp(x64emu_t *emu, uintptr_t fnc);
-void vFEppppp(x64emu_t *emu, uintptr_t fnc);
-void vFiiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFiiiuil(x64emu_t *emu, uintptr_t fnc);
-void vFiiilpi(x64emu_t *emu, uintptr_t fnc);
-void vFiiuiil(x64emu_t *emu, uintptr_t fnc);
-void vFiiuilp(x64emu_t *emu, uintptr_t fnc);
-void vFiiuulp(x64emu_t *emu, uintptr_t fnc);
-void vFiililp(x64emu_t *emu, uintptr_t fnc);
-void vFiiplli(x64emu_t *emu, uintptr_t fnc);
-void vFiiplll(x64emu_t *emu, uintptr_t fnc);
-void vFiuippp(x64emu_t *emu, uintptr_t fnc);
-void vFiffiff(x64emu_t *emu, uintptr_t fnc);
-void vFiddidd(x64emu_t *emu, uintptr_t fnc);
-void vFililuU(x64emu_t *emu, uintptr_t fnc);
-void vFililll(x64emu_t *emu, uintptr_t fnc);
-void vFilipli(x64emu_t *emu, uintptr_t fnc);
-void vFiliplu(x64emu_t *emu, uintptr_t fnc);
-void vFillill(x64emu_t *emu, uintptr_t fnc);
-void vFipiplp(x64emu_t *emu, uintptr_t fnc);
-void vFipllli(x64emu_t *emu, uintptr_t fnc);
-void vFuiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFuiiiil(x64emu_t *emu, uintptr_t fnc);
-void vFuiiiip(x64emu_t *emu, uintptr_t fnc);
-void vFuiiilp(x64emu_t *emu, uintptr_t fnc);
-void vFuiiuii(x64emu_t *emu, uintptr_t fnc);
-void vFuiiuup(x64emu_t *emu, uintptr_t fnc);
-void vFuiIIII(x64emu_t *emu, uintptr_t fnc);
-void vFuiuiii(x64emu_t *emu, uintptr_t fnc);
-void vFuiuiil(x64emu_t *emu, uintptr_t fnc);
-void vFuiuiip(x64emu_t *emu, uintptr_t fnc);
-void vFuiuiuu(x64emu_t *emu, uintptr_t fnc);
-void vFuiuuip(x64emu_t *emu, uintptr_t fnc);
-void vFuiuuuu(x64emu_t *emu, uintptr_t fnc);
-void vFuiuulp(x64emu_t *emu, uintptr_t fnc);
-void vFuiupii(x64emu_t *emu, uintptr_t fnc);
-void vFuiupiu(x64emu_t *emu, uintptr_t fnc);
-void vFuiUUUU(x64emu_t *emu, uintptr_t fnc);
-void vFuiffff(x64emu_t *emu, uintptr_t fnc);
-void vFuidddd(x64emu_t *emu, uintptr_t fnc);
-void vFuuiiii(x64emu_t *emu, uintptr_t fnc);
-void vFuuiiiu(x64emu_t *emu, uintptr_t fnc);
-void vFuuiuii(x64emu_t *emu, uintptr_t fnc);
-void vFuuiuiu(x64emu_t *emu, uintptr_t fnc);
-void vFuuiuup(x64emu_t *emu, uintptr_t fnc);
-void vFuuuiup(x64emu_t *emu, uintptr_t fnc);
-void vFuuuipi(x64emu_t *emu, uintptr_t fnc);
-void vFuuuipp(x64emu_t *emu, uintptr_t fnc);
-void vFuuuuii(x64emu_t *emu, uintptr_t fnc);
-void vFuuuuip(x64emu_t *emu, uintptr_t fnc);
-void vFuuuuuu(x64emu_t *emu, uintptr_t fnc);
-void vFuuuuff(x64emu_t *emu, uintptr_t fnc);
-void vFuuuppi(x64emu_t *emu, uintptr_t fnc);
-void vFuuuppp(x64emu_t *emu, uintptr_t fnc);
-void vFuuffff(x64emu_t *emu, uintptr_t fnc);
-void vFuudddd(x64emu_t *emu, uintptr_t fnc);
-void vFuulppp(x64emu_t *emu, uintptr_t fnc);
-void vFuupupp(x64emu_t *emu, uintptr_t fnc);
-void vFuffiip(x64emu_t *emu, uintptr_t fnc);
-void vFufffff(x64emu_t *emu, uintptr_t fnc);
-void vFuddiip(x64emu_t *emu, uintptr_t fnc);
-void vFuliluU(x64emu_t *emu, uintptr_t fnc);
-void vFulilli(x64emu_t *emu, uintptr_t fnc);
-void vFulilll(x64emu_t *emu, uintptr_t fnc);
-void vFullill(x64emu_t *emu, uintptr_t fnc);
-void vFulplup(x64emu_t *emu, uintptr_t fnc);
-void vFupupip(x64emu_t *emu, uintptr_t fnc);
-void vFuppppu(x64emu_t *emu, uintptr_t fnc);
-void vFuppppp(x64emu_t *emu, uintptr_t fnc);
-void vFffffff(x64emu_t *emu, uintptr_t fnc);
-void vFdddddd(x64emu_t *emu, uintptr_t fnc);
-void vFpiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFpiiipp(x64emu_t *emu, uintptr_t fnc);
-void vFpiiuuu(x64emu_t *emu, uintptr_t fnc);
-void vFpiippp(x64emu_t *emu, uintptr_t fnc);
-void vFpiUuup(x64emu_t *emu, uintptr_t fnc);
-void vFpipipV(x64emu_t *emu, uintptr_t fnc);
-void vFpipppi(x64emu_t *emu, uintptr_t fnc);
-void vFpipppp(x64emu_t *emu, uintptr_t fnc);
-void vFpuiiii(x64emu_t *emu, uintptr_t fnc);
-void vFpuiiiu(x64emu_t *emu, uintptr_t fnc);
-void vFpuiipp(x64emu_t *emu, uintptr_t fnc);
-void vFpuuuiu(x64emu_t *emu, uintptr_t fnc);
-void vFpuuppp(x64emu_t *emu, uintptr_t fnc);
-void vFpudddd(x64emu_t *emu, uintptr_t fnc);
-void vFpupiUu(x64emu_t *emu, uintptr_t fnc);
-void vFpupuuu(x64emu_t *emu, uintptr_t fnc);
-void vFpupppp(x64emu_t *emu, uintptr_t fnc);
-void vFpUiuup(x64emu_t *emu, uintptr_t fnc);
-void vFpUiUup(x64emu_t *emu, uintptr_t fnc);
-void vFpUipup(x64emu_t *emu, uintptr_t fnc);
-void vFpUUiup(x64emu_t *emu, uintptr_t fnc);
-void vFpdddii(x64emu_t *emu, uintptr_t fnc);
-void vFpddddd(x64emu_t *emu, uintptr_t fnc);
-void vFpddddp(x64emu_t *emu, uintptr_t fnc);
-void vFppiiii(x64emu_t *emu, uintptr_t fnc);
-void vFppiiip(x64emu_t *emu, uintptr_t fnc);
-void vFppiiui(x64emu_t *emu, uintptr_t fnc);
-void vFppiipi(x64emu_t *emu, uintptr_t fnc);
-void vFppiipp(x64emu_t *emu, uintptr_t fnc);
-void vFppilpp(x64emu_t *emu, uintptr_t fnc);
-void vFppippi(x64emu_t *emu, uintptr_t fnc);
-void vFppippp(x64emu_t *emu, uintptr_t fnc);
-void vFppuuuu(x64emu_t *emu, uintptr_t fnc);
-void vFppuUUU(x64emu_t *emu, uintptr_t fnc);
-void vFppupii(x64emu_t *emu, uintptr_t fnc);
-void vFppuppp(x64emu_t *emu, uintptr_t fnc);
-void vFppdidd(x64emu_t *emu, uintptr_t fnc);
-void vFppdddd(x64emu_t *emu, uintptr_t fnc);
-void vFpplppi(x64emu_t *emu, uintptr_t fnc);
-void vFpplppp(x64emu_t *emu, uintptr_t fnc);
-void vFppLppi(x64emu_t *emu, uintptr_t fnc);
-void vFppLppp(x64emu_t *emu, uintptr_t fnc);
-void vFpppiii(x64emu_t *emu, uintptr_t fnc);
-void vFpppiip(x64emu_t *emu, uintptr_t fnc);
-void vFpppiff(x64emu_t *emu, uintptr_t fnc);
-void vFpppipu(x64emu_t *emu, uintptr_t fnc);
-void vFpppuii(x64emu_t *emu, uintptr_t fnc);
-void vFppppii(x64emu_t *emu, uintptr_t fnc);
-void vFpppppi(x64emu_t *emu, uintptr_t fnc);
-void vFpppppu(x64emu_t *emu, uintptr_t fnc);
-void vFpppppU(x64emu_t *emu, uintptr_t fnc);
-void vFpppppL(x64emu_t *emu, uintptr_t fnc);
-void vFpppppp(x64emu_t *emu, uintptr_t fnc);
-void cFppLppi(x64emu_t *emu, uintptr_t fnc);
-void iFEiippi(x64emu_t *emu, uintptr_t fnc);
-void iFEiippp(x64emu_t *emu, uintptr_t fnc);
-void iFEiLLLL(x64emu_t *emu, uintptr_t fnc);
-void iFEippLp(x64emu_t *emu, uintptr_t fnc);
-void iFElpppp(x64emu_t *emu, uintptr_t fnc);
-void iFEpiipp(x64emu_t *emu, uintptr_t fnc);
-void iFEpiipV(x64emu_t *emu, uintptr_t fnc);
-void iFEpilpV(x64emu_t *emu, uintptr_t fnc);
-void iFEpippi(x64emu_t *emu, uintptr_t fnc);
-void iFEpIppp(x64emu_t *emu, uintptr_t fnc);
-void iFEpuppp(x64emu_t *emu, uintptr_t fnc);
-void iFEpUppp(x64emu_t *emu, uintptr_t fnc);
-void iFEppppp(x64emu_t *emu, uintptr_t fnc);
-void iFiiiiii(x64emu_t *emu, uintptr_t fnc);
-void iFiiiiip(x64emu_t *emu, uintptr_t fnc);
-void iFiiiuwp(x64emu_t *emu, uintptr_t fnc);
-void iFiuiipi(x64emu_t *emu, uintptr_t fnc);
-void iFipiipi(x64emu_t *emu, uintptr_t fnc);
-void iFipipip(x64emu_t *emu, uintptr_t fnc);
-void iFipippp(x64emu_t *emu, uintptr_t fnc);
-void iFipuufp(x64emu_t *emu, uintptr_t fnc);
-void iFipupup(x64emu_t *emu, uintptr_t fnc);
-void iFipuppp(x64emu_t *emu, uintptr_t fnc);
-void iFipppLp(x64emu_t *emu, uintptr_t fnc);
-void iFippppp(x64emu_t *emu, uintptr_t fnc);
-void iFuppppp(x64emu_t *emu, uintptr_t fnc);
-void iFdipppL(x64emu_t *emu, uintptr_t fnc);
-void iFDipppL(x64emu_t *emu, uintptr_t fnc);
-void iFlpippp(x64emu_t *emu, uintptr_t fnc);
-void iFLppipp(x64emu_t *emu, uintptr_t fnc);
-void iFpiiiii(x64emu_t *emu, uintptr_t fnc);
-void iFpiiiip(x64emu_t *emu, uintptr_t fnc);
-void iFpiiipp(x64emu_t *emu, uintptr_t fnc);
-void iFpiipip(x64emu_t *emu, uintptr_t fnc);
-void iFpiippu(x64emu_t *emu, uintptr_t fnc);
-void iFpiippp(x64emu_t *emu, uintptr_t fnc);
-void iFpiuuup(x64emu_t *emu, uintptr_t fnc);
-void iFpiuupp(x64emu_t *emu, uintptr_t fnc);
-void iFpiUUpp(x64emu_t *emu, uintptr_t fnc);
-void iFpipipi(x64emu_t *emu, uintptr_t fnc);
-void iFpippip(x64emu_t *emu, uintptr_t fnc);
-void iFpipppL(x64emu_t *emu, uintptr_t fnc);
-void iFpipppp(x64emu_t *emu, uintptr_t fnc);
-void iFpCpipu(x64emu_t *emu, uintptr_t fnc);
-void iFpWpppp(x64emu_t *emu, uintptr_t fnc);
-void iFpuiCpp(x64emu_t *emu, uintptr_t fnc);
-void iFpuippp(x64emu_t *emu, uintptr_t fnc);
-void iFpupuui(x64emu_t *emu, uintptr_t fnc);
-void iFpUuuLp(x64emu_t *emu, uintptr_t fnc);
-void iFpUuupp(x64emu_t *emu, uintptr_t fnc);
-void iFpUUUip(x64emu_t *emu, uintptr_t fnc);
-void iFpUUUUp(x64emu_t *emu, uintptr_t fnc);
-void iFpLLppp(x64emu_t *emu, uintptr_t fnc);
-void iFppiiii(x64emu_t *emu, uintptr_t fnc);
-void iFppiiip(x64emu_t *emu, uintptr_t fnc);
-void iFppiiuu(x64emu_t *emu, uintptr_t fnc);
-void iFppiipi(x64emu_t *emu, uintptr_t fnc);
-void iFppiipp(x64emu_t *emu, uintptr_t fnc);
-void iFppipii(x64emu_t *emu, uintptr_t fnc);
-void iFppipiL(x64emu_t *emu, uintptr_t fnc);
-void iFppipip(x64emu_t *emu, uintptr_t fnc);
-void iFppIipp(x64emu_t *emu, uintptr_t fnc);
-void iFppIppp(x64emu_t *emu, uintptr_t fnc);
-void iFppuiii(x64emu_t *emu, uintptr_t fnc);
-void iFppuiiL(x64emu_t *emu, uintptr_t fnc);
-void iFppuipp(x64emu_t *emu, uintptr_t fnc);
-void iFppuIII(x64emu_t *emu, uintptr_t fnc);
-void iFppuupp(x64emu_t *emu, uintptr_t fnc);
-void iFppupip(x64emu_t *emu, uintptr_t fnc);
-void iFppuppp(x64emu_t *emu, uintptr_t fnc);
-void iFppUipp(x64emu_t *emu, uintptr_t fnc);
-void iFppUUup(x64emu_t *emu, uintptr_t fnc);
-void iFppdidd(x64emu_t *emu, uintptr_t fnc);
-void iFpplppi(x64emu_t *emu, uintptr_t fnc);
-void iFppLupp(x64emu_t *emu, uintptr_t fnc);
-void iFppLpLp(x64emu_t *emu, uintptr_t fnc);
-void iFpppiuu(x64emu_t *emu, uintptr_t fnc);
-void iFpppipi(x64emu_t *emu, uintptr_t fnc);
-void iFpppipp(x64emu_t *emu, uintptr_t fnc);
-void iFpppuii(x64emu_t *emu, uintptr_t fnc);
-void iFpppupu(x64emu_t *emu, uintptr_t fnc);
-void iFpppLpp(x64emu_t *emu, uintptr_t fnc);
-void iFppppii(x64emu_t *emu, uintptr_t fnc);
-void iFppppiu(x64emu_t *emu, uintptr_t fnc);
-void iFppppip(x64emu_t *emu, uintptr_t fnc);
-void iFppppup(x64emu_t *emu, uintptr_t fnc);
-void iFpppppi(x64emu_t *emu, uintptr_t fnc);
-void iFpppppL(x64emu_t *emu, uintptr_t fnc);
-void iFpppppp(x64emu_t *emu, uintptr_t fnc);
-void uFEiippp(x64emu_t *emu, uintptr_t fnc);
-void uFEiuppp(x64emu_t *emu, uintptr_t fnc);
-void uFEpCppp(x64emu_t *emu, uintptr_t fnc);
-void uFEpuppp(x64emu_t *emu, uintptr_t fnc);
-void uFpippup(x64emu_t *emu, uintptr_t fnc);
-void uFpWuwCp(x64emu_t *emu, uintptr_t fnc);
-void uFpWuipp(x64emu_t *emu, uintptr_t fnc);
-void uFpWuuCp(x64emu_t *emu, uintptr_t fnc);
-void uFpuippp(x64emu_t *emu, uintptr_t fnc);
-void uFppippp(x64emu_t *emu, uintptr_t fnc);
-void uFppuuup(x64emu_t *emu, uintptr_t fnc);
-void uFppuupu(x64emu_t *emu, uintptr_t fnc);
-void uFpppppi(x64emu_t *emu, uintptr_t fnc);
-void uFpppppp(x64emu_t *emu, uintptr_t fnc);
-void UFpippup(x64emu_t *emu, uintptr_t fnc);
-void lFEpippp(x64emu_t *emu, uintptr_t fnc);
-void lFipipLu(x64emu_t *emu, uintptr_t fnc);
-void lFipLipu(x64emu_t *emu, uintptr_t fnc);
-void lFipLipp(x64emu_t *emu, uintptr_t fnc);
-void lFipLpLL(x64emu_t *emu, uintptr_t fnc);
-void LFEupppp(x64emu_t *emu, uintptr_t fnc);
-void LFELpppi(x64emu_t *emu, uintptr_t fnc);
-void LFEppppi(x64emu_t *emu, uintptr_t fnc);
-void LFpipipi(x64emu_t *emu, uintptr_t fnc);
-void LFpLippp(x64emu_t *emu, uintptr_t fnc);
-void LFSpLiip(x64emu_t *emu, uintptr_t fnc);
-void pFEpiupp(x64emu_t *emu, uintptr_t fnc);
-void pFEpippp(x64emu_t *emu, uintptr_t fnc);
-void pFEpuipp(x64emu_t *emu, uintptr_t fnc);
-void pFEpuupp(x64emu_t *emu, uintptr_t fnc);
-void pFEpuppp(x64emu_t *emu, uintptr_t fnc);
-void pFEpLLiN(x64emu_t *emu, uintptr_t fnc);
-void pFEppLLp(x64emu_t *emu, uintptr_t fnc);
-void pFEpppLp(x64emu_t *emu, uintptr_t fnc);
-void pFEppppi(x64emu_t *emu, uintptr_t fnc);
-void pFEppppp(x64emu_t *emu, uintptr_t fnc);
-void pFEppppV(x64emu_t *emu, uintptr_t fnc);
-void pFEppApp(x64emu_t *emu, uintptr_t fnc);
-void pFiiiiii(x64emu_t *emu, uintptr_t fnc);
-void pFiCiiCi(x64emu_t *emu, uintptr_t fnc);
-void pFdddddd(x64emu_t *emu, uintptr_t fnc);
-void pFpiiiiu(x64emu_t *emu, uintptr_t fnc);
-void pFpiiCCC(x64emu_t *emu, uintptr_t fnc);
-void pFpiUUUU(x64emu_t *emu, uintptr_t fnc);
-void pFpippip(x64emu_t *emu, uintptr_t fnc);
-void pFpipppp(x64emu_t *emu, uintptr_t fnc);
-void pFpCuuCC(x64emu_t *emu, uintptr_t fnc);
-void pFpCuuWW(x64emu_t *emu, uintptr_t fnc);
-void pFpCuuup(x64emu_t *emu, uintptr_t fnc);
-void pFpuuwwu(x64emu_t *emu, uintptr_t fnc);
-void pFpuuuuu(x64emu_t *emu, uintptr_t fnc);
-void pFpuuupu(x64emu_t *emu, uintptr_t fnc);
-void pFpuuUUU(x64emu_t *emu, uintptr_t fnc);
-void pFplpppp(x64emu_t *emu, uintptr_t fnc);
-void pFppiiii(x64emu_t *emu, uintptr_t fnc);
-void pFppiipp(x64emu_t *emu, uintptr_t fnc);
-void pFppiCCC(x64emu_t *emu, uintptr_t fnc);
-void pFppippi(x64emu_t *emu, uintptr_t fnc);
-void pFppippp(x64emu_t *emu, uintptr_t fnc);
-void pFpppiii(x64emu_t *emu, uintptr_t fnc);
-void pFpppiui(x64emu_t *emu, uintptr_t fnc);
-void pFpppiup(x64emu_t *emu, uintptr_t fnc);
-void pFpppupp(x64emu_t *emu, uintptr_t fnc);
-void pFppppii(x64emu_t *emu, uintptr_t fnc);
-void pFppppWW(x64emu_t *emu, uintptr_t fnc);
-void pFpppppi(x64emu_t *emu, uintptr_t fnc);
-void pFpppppu(x64emu_t *emu, uintptr_t fnc);
-void pFpppppp(x64emu_t *emu, uintptr_t fnc);
-void pFSpiiii(x64emu_t *emu, uintptr_t fnc);
-void iWEpuuip(x64emu_t *emu, uintptr_t fnc);
-void iWEppppp(x64emu_t *emu, uintptr_t fnc);
-void iWpiiiip(x64emu_t *emu, uintptr_t fnc);
-void iWpiiuii(x64emu_t *emu, uintptr_t fnc);
-void iWpiuppu(x64emu_t *emu, uintptr_t fnc);
-void iWpuiiii(x64emu_t *emu, uintptr_t fnc);
-void iWpppppi(x64emu_t *emu, uintptr_t fnc);
-void iWpppppu(x64emu_t *emu, uintptr_t fnc);
-void vFEpiiipp(x64emu_t *emu, uintptr_t fnc);
-void vFEpipppp(x64emu_t *emu, uintptr_t fnc);
-void vFEpuipuV(x64emu_t *emu, uintptr_t fnc);
-void vFEppippp(x64emu_t *emu, uintptr_t fnc);
-void vFEpppppp(x64emu_t *emu, uintptr_t fnc);
-void vFiiiiiip(x64emu_t *emu, uintptr_t fnc);
-void vFiiiiuup(x64emu_t *emu, uintptr_t fnc);
-void vFiiuilil(x64emu_t *emu, uintptr_t fnc);
-void vFiiffffp(x64emu_t *emu, uintptr_t fnc);
-void vFiipllli(x64emu_t *emu, uintptr_t fnc);
-void vFiuulipi(x64emu_t *emu, uintptr_t fnc);
-void vFililluU(x64emu_t *emu, uintptr_t fnc);
-void vFilipliu(x64emu_t *emu, uintptr_t fnc);
-void vFilulipi(x64emu_t *emu, uintptr_t fnc);
-void vFuiiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFuiiiuip(x64emu_t *emu, uintptr_t fnc);
-void vFuiiiuup(x64emu_t *emu, uintptr_t fnc);
-void vFuiiliip(x64emu_t *emu, uintptr_t fnc);
-void vFuiililp(x64emu_t *emu, uintptr_t fnc);
-void vFuiuiiii(x64emu_t *emu, uintptr_t fnc);
-void vFuiuiiip(x64emu_t *emu, uintptr_t fnc);
-void vFuiuiiuu(x64emu_t *emu, uintptr_t fnc);
-void vFuiupiiu(x64emu_t *emu, uintptr_t fnc);
-void vFuilliip(x64emu_t *emu, uintptr_t fnc);
-void vFuipiiii(x64emu_t *emu, uintptr_t fnc);
-void vFuipffff(x64emu_t *emu, uintptr_t fnc);
-void vFuipdddd(x64emu_t *emu, uintptr_t fnc);
-void vFuuiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFuuiiiip(x64emu_t *emu, uintptr_t fnc);
-void vFuuiiiui(x64emu_t *emu, uintptr_t fnc);
-void vFuuiiiuu(x64emu_t *emu, uintptr_t fnc);
-void vFuuiiuup(x64emu_t *emu, uintptr_t fnc);
-void vFuuiuiii(x64emu_t *emu, uintptr_t fnc);
-void vFuuipppp(x64emu_t *emu, uintptr_t fnc);
-void vFuuuiiii(x64emu_t *emu, uintptr_t fnc);
-void vFuuuiiip(x64emu_t *emu, uintptr_t fnc);
-void vFuuuiuii(x64emu_t *emu, uintptr_t fnc);
-void vFuuuiupi(x64emu_t *emu, uintptr_t fnc);
-void vFuuuuiip(x64emu_t *emu, uintptr_t fnc);
-void vFuuuuuuu(x64emu_t *emu, uintptr_t fnc);
-void vFuuuufff(x64emu_t *emu, uintptr_t fnc);
-void vFuuuulll(x64emu_t *emu, uintptr_t fnc);
-void vFuuuffff(x64emu_t *emu, uintptr_t fnc);
-void vFuuudddd(x64emu_t *emu, uintptr_t fnc);
-void vFuuffiip(x64emu_t *emu, uintptr_t fnc);
-void vFuuddiip(x64emu_t *emu, uintptr_t fnc);
-void vFuuppppu(x64emu_t *emu, uintptr_t fnc);
-void vFuuppppp(x64emu_t *emu, uintptr_t fnc);
-void vFuffffff(x64emu_t *emu, uintptr_t fnc);
-void vFudddddd(x64emu_t *emu, uintptr_t fnc);
-void vFulilluU(x64emu_t *emu, uintptr_t fnc);
-void vFulillli(x64emu_t *emu, uintptr_t fnc);
-void vFulipulp(x64emu_t *emu, uintptr_t fnc);
-void vFulpiill(x64emu_t *emu, uintptr_t fnc);
-void vFlipuiip(x64emu_t *emu, uintptr_t fnc);
-void vFlliiiip(x64emu_t *emu, uintptr_t fnc);
-void vFpiiiipp(x64emu_t *emu, uintptr_t fnc);
-void vFpiiliip(x64emu_t *emu, uintptr_t fnc);
-void vFpiipCpp(x64emu_t *emu, uintptr_t fnc);
-void vFpiipppp(x64emu_t *emu, uintptr_t fnc);
-void vFpipipii(x64emu_t *emu, uintptr_t fnc);
-void vFpipppii(x64emu_t *emu, uintptr_t fnc);
-void vFpuuuuuu(x64emu_t *emu, uintptr_t fnc);
-void vFpuuUUuu(x64emu_t *emu, uintptr_t fnc);
-void vFpuupppp(x64emu_t *emu, uintptr_t fnc);
-void vFpupuuup(x64emu_t *emu, uintptr_t fnc);
-void vFpUiUiup(x64emu_t *emu, uintptr_t fnc);
-void vFpUUUUuu(x64emu_t *emu, uintptr_t fnc);
-void vFpddiidd(x64emu_t *emu, uintptr_t fnc);
-void vFpdddddd(x64emu_t *emu, uintptr_t fnc);
-void vFpLiLiLp(x64emu_t *emu, uintptr_t fnc);
-void vFppiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFppiiiip(x64emu_t *emu, uintptr_t fnc);
-void vFppiiipi(x64emu_t *emu, uintptr_t fnc);
-void vFppiipii(x64emu_t *emu, uintptr_t fnc);
-void vFppiipuu(x64emu_t *emu, uintptr_t fnc);
-void vFppiippp(x64emu_t *emu, uintptr_t fnc);
-void vFppilppi(x64emu_t *emu, uintptr_t fnc);
-void vFppiLiLp(x64emu_t *emu, uintptr_t fnc);
-void vFppipiip(x64emu_t *emu, uintptr_t fnc);
-void vFppipipp(x64emu_t *emu, uintptr_t fnc);
-void vFppipppp(x64emu_t *emu, uintptr_t fnc);
-void vFppddddi(x64emu_t *emu, uintptr_t fnc);
-void vFppddpii(x64emu_t *emu, uintptr_t fnc);
-void vFppLpppi(x64emu_t *emu, uintptr_t fnc);
-void vFppLpppp(x64emu_t *emu, uintptr_t fnc);
-void vFpppiiii(x64emu_t *emu, uintptr_t fnc);
-void vFpppiipi(x64emu_t *emu, uintptr_t fnc);
-void vFpppiipp(x64emu_t *emu, uintptr_t fnc);
-void vFpppippi(x64emu_t *emu, uintptr_t fnc);
-void vFpppuuuu(x64emu_t *emu, uintptr_t fnc);
-void vFppppiii(x64emu_t *emu, uintptr_t fnc);
-void vFppppiip(x64emu_t *emu, uintptr_t fnc);
-void vFppppipi(x64emu_t *emu, uintptr_t fnc);
-void vFpppppip(x64emu_t *emu, uintptr_t fnc);
-void vFppppppi(x64emu_t *emu, uintptr_t fnc);
-void vFppppppp(x64emu_t *emu, uintptr_t fnc);
-void iFEpupppp(x64emu_t *emu, uintptr_t fnc);
-void iFEpUuppp(x64emu_t *emu, uintptr_t fnc);
-void iFEpLiLpV(x64emu_t *emu, uintptr_t fnc);
-void iFEppuppp(x64emu_t *emu, uintptr_t fnc);
-void iFEppLpIi(x64emu_t *emu, uintptr_t fnc);
-void iFEpppiiu(x64emu_t *emu, uintptr_t fnc);
-void iFEpppppL(x64emu_t *emu, uintptr_t fnc);
-void iFEpppppp(x64emu_t *emu, uintptr_t fnc);
-void iFiiiiiip(x64emu_t *emu, uintptr_t fnc);
-void iFpiiiiii(x64emu_t *emu, uintptr_t fnc);
-void iFpiiiiip(x64emu_t *emu, uintptr_t fnc);
-void iFpiiiuwp(x64emu_t *emu, uintptr_t fnc);
-void iFpiiuuiu(x64emu_t *emu, uintptr_t fnc);
-void iFpiipppp(x64emu_t *emu, uintptr_t fnc);
-void iFpiuiipp(x64emu_t *emu, uintptr_t fnc);
-void iFpiupiii(x64emu_t *emu, uintptr_t fnc);
-void iFpiupppp(x64emu_t *emu, uintptr_t fnc);
-void iFpipipip(x64emu_t *emu, uintptr_t fnc);
-void iFpipippp(x64emu_t *emu, uintptr_t fnc);
-void iFpippLpp(x64emu_t *emu, uintptr_t fnc);
-void iFpippppW(x64emu_t *emu, uintptr_t fnc);
-void iFpippppp(x64emu_t *emu, uintptr_t fnc);
-void iFpIIpppp(x64emu_t *emu, uintptr_t fnc);
-void iFpWppppW(x64emu_t *emu, uintptr_t fnc);
-void iFpuiCuCp(x64emu_t *emu, uintptr_t fnc);
-void iFpuiuupp(x64emu_t *emu, uintptr_t fnc);
-void iFpuuiuui(x64emu_t *emu, uintptr_t fnc);
-void iFpuupppp(x64emu_t *emu, uintptr_t fnc);
-void iFpupiLpL(x64emu_t *emu, uintptr_t fnc);
-void iFpupuuui(x64emu_t *emu, uintptr_t fnc);
-void iFpupupui(x64emu_t *emu, uintptr_t fnc);
-void iFpuppppp(x64emu_t *emu, uintptr_t fnc);
-void iFpLipipi(x64emu_t *emu, uintptr_t fnc);
-void iFppiiiip(x64emu_t *emu, uintptr_t fnc);
-void iFppiiuui(x64emu_t *emu, uintptr_t fnc);
-void iFppiiuup(x64emu_t *emu, uintptr_t fnc);
-void iFppiipii(x64emu_t *emu, uintptr_t fnc);
-void iFppiipiL(x64emu_t *emu, uintptr_t fnc);
-void iFppiuppi(x64emu_t *emu, uintptr_t fnc);
-void iFppipiii(x64emu_t *emu, uintptr_t fnc);
-void iFppipiip(x64emu_t *emu, uintptr_t fnc);
-void iFppipipi(x64emu_t *emu, uintptr_t fnc);
-void iFppipipp(x64emu_t *emu, uintptr_t fnc);
-void iFppippip(x64emu_t *emu, uintptr_t fnc);
-void iFppipppi(x64emu_t *emu, uintptr_t fnc);
-void iFppipppp(x64emu_t *emu, uintptr_t fnc);
-void iFppuipiL(x64emu_t *emu, uintptr_t fnc);
-void iFppLiipp(x64emu_t *emu, uintptr_t fnc);
-void iFpppiiii(x64emu_t *emu, uintptr_t fnc);
-void iFpppiiuu(x64emu_t *emu, uintptr_t fnc);
-void iFpppiiup(x64emu_t *emu, uintptr_t fnc);
-void iFpppiipi(x64emu_t *emu, uintptr_t fnc);
-void iFpppiuwu(x64emu_t *emu, uintptr_t fnc);
-void iFpppippi(x64emu_t *emu, uintptr_t fnc);
-void iFpppippp(x64emu_t *emu, uintptr_t fnc);
-void iFpppuiii(x64emu_t *emu, uintptr_t fnc);
-void iFppppiii(x64emu_t *emu, uintptr_t fnc);
-void iFppppipp(x64emu_t *emu, uintptr_t fnc);
-void iFppppdpi(x64emu_t *emu, uintptr_t fnc);
-void iFpppppip(x64emu_t *emu, uintptr_t fnc);
-void iFpppppup(x64emu_t *emu, uintptr_t fnc);
-void iFppppppi(x64emu_t *emu, uintptr_t fnc);
-void iFppppppp(x64emu_t *emu, uintptr_t fnc);
-void uFEiipppp(x64emu_t *emu, uintptr_t fnc);
-void uFEpiippp(x64emu_t *emu, uintptr_t fnc);
-void uFEpuuppp(x64emu_t *emu, uintptr_t fnc);
-void uFuippppp(x64emu_t *emu, uintptr_t fnc);
-void uFppiuppp(x64emu_t *emu, uintptr_t fnc);
-void uFppuuuup(x64emu_t *emu, uintptr_t fnc);
-void LFEppLppU(x64emu_t *emu, uintptr_t fnc);
-void LFEpppppu(x64emu_t *emu, uintptr_t fnc);
-void pFEpLiiii(x64emu_t *emu, uintptr_t fnc);
-void pFEpLiiiI(x64emu_t *emu, uintptr_t fnc);
-void pFEpLiiil(x64emu_t *emu, uintptr_t fnc);
-void pFEppuipp(x64emu_t *emu, uintptr_t fnc);
-void pFEppppip(x64emu_t *emu, uintptr_t fnc);
-void pFEpppppi(x64emu_t *emu, uintptr_t fnc);
-void pFifffppp(x64emu_t *emu, uintptr_t fnc);
-void pFuupupup(x64emu_t *emu, uintptr_t fnc);
-void pFdiiiIiI(x64emu_t *emu, uintptr_t fnc);
-void pFpiiUdii(x64emu_t *emu, uintptr_t fnc);
-void pFpCuwwWW(x64emu_t *emu, uintptr_t fnc);
-void pFpCuWCCC(x64emu_t *emu, uintptr_t fnc);
-void pFpCuuwwp(x64emu_t *emu, uintptr_t fnc);
-void pFpCuuuuu(x64emu_t *emu, uintptr_t fnc);
-void pFpCpWWup(x64emu_t *emu, uintptr_t fnc);
-void pFpuuuwwu(x64emu_t *emu, uintptr_t fnc);
-void pFpuupwwC(x64emu_t *emu, uintptr_t fnc);
-void pFplppppp(x64emu_t *emu, uintptr_t fnc);
-void pFpLppiip(x64emu_t *emu, uintptr_t fnc);
-void pFppiiipp(x64emu_t *emu, uintptr_t fnc);
-void pFppiiCCC(x64emu_t *emu, uintptr_t fnc);
-void pFppiippp(x64emu_t *emu, uintptr_t fnc);
-void pFppipipp(x64emu_t *emu, uintptr_t fnc);
-void pFppipLpp(x64emu_t *emu, uintptr_t fnc);
-void pFppuuppp(x64emu_t *emu, uintptr_t fnc);
-void pFppLiiip(x64emu_t *emu, uintptr_t fnc);
-void pFppLipip(x64emu_t *emu, uintptr_t fnc);
-void pFpppccci(x64emu_t *emu, uintptr_t fnc);
-void pFpppiiii(x64emu_t *emu, uintptr_t fnc);
-void pFpppiipp(x64emu_t *emu, uintptr_t fnc);
-void pFpppIIIi(x64emu_t *emu, uintptr_t fnc);
-void pFpppCCCi(x64emu_t *emu, uintptr_t fnc);
-void pFpppuuui(x64emu_t *emu, uintptr_t fnc);
-void pFpppuupp(x64emu_t *emu, uintptr_t fnc);
-void pFpppUUUi(x64emu_t *emu, uintptr_t fnc);
-void pFpppfffi(x64emu_t *emu, uintptr_t fnc);
-void pFpppdddi(x64emu_t *emu, uintptr_t fnc);
-void pFpppllli(x64emu_t *emu, uintptr_t fnc);
-void pFpppLLLi(x64emu_t *emu, uintptr_t fnc);
-void pFppppuuu(x64emu_t *emu, uintptr_t fnc);
-void pFpppppuu(x64emu_t *emu, uintptr_t fnc);
-void pFppppppi(x64emu_t *emu, uintptr_t fnc);
-void pFppppppp(x64emu_t *emu, uintptr_t fnc);
-void iWpiiuuuu(x64emu_t *emu, uintptr_t fnc);
-void iWpuiiiip(x64emu_t *emu, uintptr_t fnc);
-void iWpuiiuii(x64emu_t *emu, uintptr_t fnc);
-void iWpuipupp(x64emu_t *emu, uintptr_t fnc);
-void iWpuuuppu(x64emu_t *emu, uintptr_t fnc);
-void iWpupuufu(x64emu_t *emu, uintptr_t fnc);
-void iWpppuppp(x64emu_t *emu, uintptr_t fnc);
-void vFEiippppV(x64emu_t *emu, uintptr_t fnc);
-void vFEiupippp(x64emu_t *emu, uintptr_t fnc);
-void vFEipAippp(x64emu_t *emu, uintptr_t fnc);
-void vFEppipppp(x64emu_t *emu, uintptr_t fnc);
-void vFEpppippp(x64emu_t *emu, uintptr_t fnc);
-void vFEpppuipV(x64emu_t *emu, uintptr_t fnc);
-void vFEpppppuu(x64emu_t *emu, uintptr_t fnc);
-void vFiiiiuuip(x64emu_t *emu, uintptr_t fnc);
-void vFiilliilp(x64emu_t *emu, uintptr_t fnc);
-void vFililliuU(x64emu_t *emu, uintptr_t fnc);
-void vFilillluU(x64emu_t *emu, uintptr_t fnc);
-void vFilipufip(x64emu_t *emu, uintptr_t fnc);
-void vFuiiiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFuiiiiill(x64emu_t *emu, uintptr_t fnc);
-void vFuiiiiuup(x64emu_t *emu, uintptr_t fnc);
-void vFuiuiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFuiuiiiip(x64emu_t *emu, uintptr_t fnc);
-void vFuiuiuuuu(x64emu_t *emu, uintptr_t fnc);
-void vFuiulplpp(x64emu_t *emu, uintptr_t fnc);
-void vFuipuliuf(x64emu_t *emu, uintptr_t fnc);
-void vFuuiiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFuuiiiuip(x64emu_t *emu, uintptr_t fnc);
-void vFuuiiiuup(x64emu_t *emu, uintptr_t fnc);
-void vFuuiiuupp(x64emu_t *emu, uintptr_t fnc);
-void vFuuiuiiii(x64emu_t *emu, uintptr_t fnc);
-void vFuuiuiiip(x64emu_t *emu, uintptr_t fnc);
-void vFuuuiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFuuuiuiii(x64emu_t *emu, uintptr_t fnc);
-void vFuuuipipp(x64emu_t *emu, uintptr_t fnc);
-void vFuuuuuuuu(x64emu_t *emu, uintptr_t fnc);
-void vFuuuuufff(x64emu_t *emu, uintptr_t fnc);
-void vFuuufffff(x64emu_t *emu, uintptr_t fnc);
-void vFulilliuU(x64emu_t *emu, uintptr_t fnc);
-void vFulillluU(x64emu_t *emu, uintptr_t fnc);
-void vFulllplip(x64emu_t *emu, uintptr_t fnc);
-void vFffffffff(x64emu_t *emu, uintptr_t fnc);
-void vFlipuiuip(x64emu_t *emu, uintptr_t fnc);
-void vFpiiiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFpiiiipii(x64emu_t *emu, uintptr_t fnc);
-void vFpiiULipp(x64emu_t *emu, uintptr_t fnc);
-void vFpiUuupup(x64emu_t *emu, uintptr_t fnc);
-void vFpippiiuu(x64emu_t *emu, uintptr_t fnc);
-void vFpippiipi(x64emu_t *emu, uintptr_t fnc);
-void vFpuppLLLL(x64emu_t *emu, uintptr_t fnc);
-void vFpUiUiupi(x64emu_t *emu, uintptr_t fnc);
-void vFpUuuUUUi(x64emu_t *emu, uintptr_t fnc);
-void vFppiiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFppiiipii(x64emu_t *emu, uintptr_t fnc);
-void vFppipipii(x64emu_t *emu, uintptr_t fnc);
-void vFppipppui(x64emu_t *emu, uintptr_t fnc);
-void vFppippppi(x64emu_t *emu, uintptr_t fnc);
-void vFppippppp(x64emu_t *emu, uintptr_t fnc);
-void vFpplppppi(x64emu_t *emu, uintptr_t fnc);
-void vFpplppppp(x64emu_t *emu, uintptr_t fnc);
-void vFppppiipi(x64emu_t *emu, uintptr_t fnc);
-void vFpppppuuu(x64emu_t *emu, uintptr_t fnc);
-void vFpppppppp(x64emu_t *emu, uintptr_t fnc);
-void iFEpippppp(x64emu_t *emu, uintptr_t fnc);
-void iFEpuuLppp(x64emu_t *emu, uintptr_t fnc);
-void iFEpUUuppp(x64emu_t *emu, uintptr_t fnc);
-void iFEppipppp(x64emu_t *emu, uintptr_t fnc);
-void iFEppppipp(x64emu_t *emu, uintptr_t fnc);
-void iFiiiiiiip(x64emu_t *emu, uintptr_t fnc);
-void iFiiupiupi(x64emu_t *emu, uintptr_t fnc);
-void iFipippppp(x64emu_t *emu, uintptr_t fnc);
-void iFuipuuluf(x64emu_t *emu, uintptr_t fnc);
-void iFuuuuuuuu(x64emu_t *emu, uintptr_t fnc);
-void iFullfpppp(x64emu_t *emu, uintptr_t fnc);
-void iFpippuuii(x64emu_t *emu, uintptr_t fnc);
-void iFpCCWWpWu(x64emu_t *emu, uintptr_t fnc);
-void iFpWCuWCuu(x64emu_t *emu, uintptr_t fnc);
-void iFpWWipppp(x64emu_t *emu, uintptr_t fnc);
-void iFpuiipppp(x64emu_t *emu, uintptr_t fnc);
-void iFpuippLpp(x64emu_t *emu, uintptr_t fnc);
-void iFpuuiiiii(x64emu_t *emu, uintptr_t fnc);
-void iFpuuupupu(x64emu_t *emu, uintptr_t fnc);
-void iFpupppWWu(x64emu_t *emu, uintptr_t fnc);
-void iFpupppppp(x64emu_t *emu, uintptr_t fnc);
-void iFpUuuLpUi(x64emu_t *emu, uintptr_t fnc);
-void iFpdiiiIiI(x64emu_t *emu, uintptr_t fnc);
-void iFpLpipppp(x64emu_t *emu, uintptr_t fnc);
-void iFppiiiiiu(x64emu_t *emu, uintptr_t fnc);
-void iFppiiipip(x64emu_t *emu, uintptr_t fnc);
-void iFppIIIppp(x64emu_t *emu, uintptr_t fnc);
-void iFpppiiipi(x64emu_t *emu, uintptr_t fnc);
-void iFpppiippp(x64emu_t *emu, uintptr_t fnc);
-void iFpppipipi(x64emu_t *emu, uintptr_t fnc);
-void iFppppiipi(x64emu_t *emu, uintptr_t fnc);
-void iFppppippp(x64emu_t *emu, uintptr_t fnc);
-void iFppppppii(x64emu_t *emu, uintptr_t fnc);
-void iFpppppppi(x64emu_t *emu, uintptr_t fnc);
-void iFpppppppp(x64emu_t *emu, uintptr_t fnc);
-void uFEipipppp(x64emu_t *emu, uintptr_t fnc);
-void uFEpiupppp(x64emu_t *emu, uintptr_t fnc);
-void uFEppipppp(x64emu_t *emu, uintptr_t fnc);
-void uFEpppuppp(x64emu_t *emu, uintptr_t fnc);
-void uFEppppppp(x64emu_t *emu, uintptr_t fnc);
-void uFuipppppp(x64emu_t *emu, uintptr_t fnc);
-void uFulpppppp(x64emu_t *emu, uintptr_t fnc);
-void uFpupuuuCp(x64emu_t *emu, uintptr_t fnc);
-void uFppuuuupp(x64emu_t *emu, uintptr_t fnc);
-void uFppuuuppi(x64emu_t *emu, uintptr_t fnc);
-void uFppuppppp(x64emu_t *emu, uintptr_t fnc);
-void LFELpLpLpi(x64emu_t *emu, uintptr_t fnc);
-void LFEpiupppp(x64emu_t *emu, uintptr_t fnc);
-void pFEiplllpp(x64emu_t *emu, uintptr_t fnc);
-void pFEpiuCppp(x64emu_t *emu, uintptr_t fnc);
-void pFEppLiiip(x64emu_t *emu, uintptr_t fnc);
-void pFEpppuipV(x64emu_t *emu, uintptr_t fnc);
-void pFEpppppiV(x64emu_t *emu, uintptr_t fnc);
-void pFEppppppi(x64emu_t *emu, uintptr_t fnc);
-void pFEppppppp(x64emu_t *emu, uintptr_t fnc);
-void pFiipppppp(x64emu_t *emu, uintptr_t fnc);
-void pFuiiiuuuu(x64emu_t *emu, uintptr_t fnc);
-void pFuupupipp(x64emu_t *emu, uintptr_t fnc);
-void pFpiiiiiuu(x64emu_t *emu, uintptr_t fnc);
-void pFpiUdiiUi(x64emu_t *emu, uintptr_t fnc);
-void pFpipiiiip(x64emu_t *emu, uintptr_t fnc);
-void pFpipppppp(x64emu_t *emu, uintptr_t fnc);
-void pFpCCuuwwC(x64emu_t *emu, uintptr_t fnc);
-void pFpCuwwWWu(x64emu_t *emu, uintptr_t fnc);
-void pFpCuuuCup(x64emu_t *emu, uintptr_t fnc);
-void pFpWWiCpup(x64emu_t *emu, uintptr_t fnc);
-void pFpuuWWCuu(x64emu_t *emu, uintptr_t fnc);
-void pFpuuuuupp(x64emu_t *emu, uintptr_t fnc);
-void pFpuuuupup(x64emu_t *emu, uintptr_t fnc);
-void pFpuuupwwp(x64emu_t *emu, uintptr_t fnc);
-void pFpdwwWWui(x64emu_t *emu, uintptr_t fnc);
-void pFplpppppp(x64emu_t *emu, uintptr_t fnc);
-void pFppiiiiii(x64emu_t *emu, uintptr_t fnc);
-void pFpppuuLLu(x64emu_t *emu, uintptr_t fnc);
-void pFpppppupp(x64emu_t *emu, uintptr_t fnc);
-void iWEpuuiipp(x64emu_t *emu, uintptr_t fnc);
-void iWEpuuuipp(x64emu_t *emu, uintptr_t fnc);
-void iWpuipuppp(x64emu_t *emu, uintptr_t fnc);
-void vFEpiiiiipp(x64emu_t *emu, uintptr_t fnc);
-void vFEpippippV(x64emu_t *emu, uintptr_t fnc);
-void vFEpippippA(x64emu_t *emu, uintptr_t fnc);
-void vFEpuuuippp(x64emu_t *emu, uintptr_t fnc);
-void vFEppiipppp(x64emu_t *emu, uintptr_t fnc);
-void vFEpppiippp(x64emu_t *emu, uintptr_t fnc);
-void vFEppppippp(x64emu_t *emu, uintptr_t fnc);
-void vFiiiiiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFiiiiiiill(x64emu_t *emu, uintptr_t fnc);
-void vFiiiiillli(x64emu_t *emu, uintptr_t fnc);
-void vFiiilllilp(x64emu_t *emu, uintptr_t fnc);
-void vFilillliuU(x64emu_t *emu, uintptr_t fnc);
-void vFuiiiiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFuiiiiiuip(x64emu_t *emu, uintptr_t fnc);
-void vFuiiiiiuup(x64emu_t *emu, uintptr_t fnc);
-void vFuiiiillli(x64emu_t *emu, uintptr_t fnc);
-void vFuiiilliip(x64emu_t *emu, uintptr_t fnc);
-void vFuiiillilp(x64emu_t *emu, uintptr_t fnc);
-void vFuiuiiiiip(x64emu_t *emu, uintptr_t fnc);
-void vFuuiiiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFuuiuiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFuuiuiiiip(x64emu_t *emu, uintptr_t fnc);
-void vFuuiuiiuup(x64emu_t *emu, uintptr_t fnc);
-void vFuuuiiiiip(x64emu_t *emu, uintptr_t fnc);
-void vFuuuuuuuuu(x64emu_t *emu, uintptr_t fnc);
-void vFuffffffff(x64emu_t *emu, uintptr_t fnc);
-void vFulillliuU(x64emu_t *emu, uintptr_t fnc);
-void vFffuuuufff(x64emu_t *emu, uintptr_t fnc);
-void vFddddddddd(x64emu_t *emu, uintptr_t fnc);
-void vFlipuiuiip(x64emu_t *emu, uintptr_t fnc);
-void vFpipiuiipp(x64emu_t *emu, uintptr_t fnc);
-void vFpipippppi(x64emu_t *emu, uintptr_t fnc);
-void vFpipppiipi(x64emu_t *emu, uintptr_t fnc);
-void vFppiiiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFppiiiiipi(x64emu_t *emu, uintptr_t fnc);
-void vFppiiipiii(x64emu_t *emu, uintptr_t fnc);
-void vFppiipiiii(x64emu_t *emu, uintptr_t fnc);
-void vFppipppiii(x64emu_t *emu, uintptr_t fnc);
-void vFppipppiip(x64emu_t *emu, uintptr_t fnc);
-void vFppuuiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFppUUiUUUU(x64emu_t *emu, uintptr_t fnc);
-void vFppddddidd(x64emu_t *emu, uintptr_t fnc);
-void vFpplpppppi(x64emu_t *emu, uintptr_t fnc);
-void vFpppiiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFppppipiip(x64emu_t *emu, uintptr_t fnc);
-void vFpppppippp(x64emu_t *emu, uintptr_t fnc);
-void iFEpiiiiipi(x64emu_t *emu, uintptr_t fnc);
-void iFEpppipppp(x64emu_t *emu, uintptr_t fnc);
-void iFEppplPPPP(x64emu_t *emu, uintptr_t fnc);
-void iFEpppppupp(x64emu_t *emu, uintptr_t fnc);
-void iFEppPPPPPP(x64emu_t *emu, uintptr_t fnc);
-void iFiiiiiiiip(x64emu_t *emu, uintptr_t fnc);
-void iFiiiipiiip(x64emu_t *emu, uintptr_t fnc);
-void iFipiipippi(x64emu_t *emu, uintptr_t fnc);
-void iFuilpluluf(x64emu_t *emu, uintptr_t fnc);
-void iFdddpppppp(x64emu_t *emu, uintptr_t fnc);
-void iFpipLpiiip(x64emu_t *emu, uintptr_t fnc);
-void iFpuuuuuuuu(x64emu_t *emu, uintptr_t fnc);
-void iFpdiiiUiUp(x64emu_t *emu, uintptr_t fnc);
-void iFppiiiiiii(x64emu_t *emu, uintptr_t fnc);
-void iFppiuiippL(x64emu_t *emu, uintptr_t fnc);
-void iFppLpiippp(x64emu_t *emu, uintptr_t fnc);
-void iFpppiiipip(x64emu_t *emu, uintptr_t fnc);
-void iFpppiiuuii(x64emu_t *emu, uintptr_t fnc);
-void iFpppiipiiu(x64emu_t *emu, uintptr_t fnc);
-void iFppppiiupp(x64emu_t *emu, uintptr_t fnc);
-void iFppppppppu(x64emu_t *emu, uintptr_t fnc);
-void iFppppppppp(x64emu_t *emu, uintptr_t fnc);
-void uFEipippppp(x64emu_t *emu, uintptr_t fnc);
-void uFEpppufppp(x64emu_t *emu, uintptr_t fnc);
-void uFppppppppp(x64emu_t *emu, uintptr_t fnc);
-void LFEppppppii(x64emu_t *emu, uintptr_t fnc);
-void pFEppiiuuLi(x64emu_t *emu, uintptr_t fnc);
-void pFEppuippuu(x64emu_t *emu, uintptr_t fnc);
-void pFEpppppiiV(x64emu_t *emu, uintptr_t fnc);
-void pFEpppppppi(x64emu_t *emu, uintptr_t fnc);
-void pFEpppppppp(x64emu_t *emu, uintptr_t fnc);
-void pFpiiiiuuuu(x64emu_t *emu, uintptr_t fnc);
-void pFpCuWCCuuu(x64emu_t *emu, uintptr_t fnc);
-void pFpuuwwWWww(x64emu_t *emu, uintptr_t fnc);
-void pFpupuuuuup(x64emu_t *emu, uintptr_t fnc);
-void pFppiiiiiip(x64emu_t *emu, uintptr_t fnc);
-void pFppiiuuuLL(x64emu_t *emu, uintptr_t fnc);
-void pFppipppppp(x64emu_t *emu, uintptr_t fnc);
-void pFpppiiiiii(x64emu_t *emu, uintptr_t fnc);
-void pFpppiipppp(x64emu_t *emu, uintptr_t fnc);
-void pFpppWWWWWp(x64emu_t *emu, uintptr_t fnc);
-void pFpppppiipp(x64emu_t *emu, uintptr_t fnc);
-void pFpppppuuCC(x64emu_t *emu, uintptr_t fnc);
-void iWEpuuiippu(x64emu_t *emu, uintptr_t fnc);
-void iWEpuuuiipp(x64emu_t *emu, uintptr_t fnc);
-void iWpiuuupipu(x64emu_t *emu, uintptr_t fnc);
-void iWpuiuuipip(x64emu_t *emu, uintptr_t fnc);
-void iWppppupiii(x64emu_t *emu, uintptr_t fnc);
-void vFEiippppppp(x64emu_t *emu, uintptr_t fnc);
-void vFEpippppppp(x64emu_t *emu, uintptr_t fnc);
-void vFEpppiipppp(x64emu_t *emu, uintptr_t fnc);
-void vFiiiiiiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFiiiiiiiiiu(x64emu_t *emu, uintptr_t fnc);
-void vFiiiiiiiiui(x64emu_t *emu, uintptr_t fnc);
-void vFiiillliiip(x64emu_t *emu, uintptr_t fnc);
-void vFuiiiiiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFuiiiiiiill(x64emu_t *emu, uintptr_t fnc);
-void vFuiiiiiiuup(x64emu_t *emu, uintptr_t fnc);
-void vFuiiiillllp(x64emu_t *emu, uintptr_t fnc);
-void vFuiuiiiiuup(x64emu_t *emu, uintptr_t fnc);
-void vFuipulipiuf(x64emu_t *emu, uintptr_t fnc);
-void vFuuiiiiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFuuiiiiiuip(x64emu_t *emu, uintptr_t fnc);
-void vFuuiiiiiuup(x64emu_t *emu, uintptr_t fnc);
-void vFuuiuiiiiip(x64emu_t *emu, uintptr_t fnc);
-void vFuuiuiiiuup(x64emu_t *emu, uintptr_t fnc);
-void vFuuuuuuuiii(x64emu_t *emu, uintptr_t fnc);
-void vFuuuuuuuuuu(x64emu_t *emu, uintptr_t fnc);
-void vFuffiiffiip(x64emu_t *emu, uintptr_t fnc);
-void vFuddiiddiip(x64emu_t *emu, uintptr_t fnc);
-void vFffffffffff(x64emu_t *emu, uintptr_t fnc);
-void vFpipippppip(x64emu_t *emu, uintptr_t fnc);
-void vFppiiiiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFppiiiiipip(x64emu_t *emu, uintptr_t fnc);
-void vFppiipppiip(x64emu_t *emu, uintptr_t fnc);
-void vFppiippppii(x64emu_t *emu, uintptr_t fnc);
-void vFppipppiiii(x64emu_t *emu, uintptr_t fnc);
-void vFppuuuuiiuu(x64emu_t *emu, uintptr_t fnc);
-void vFppdddddddd(x64emu_t *emu, uintptr_t fnc);
-void vFpppppppppp(x64emu_t *emu, uintptr_t fnc);
-void iFEpiiiiippp(x64emu_t *emu, uintptr_t fnc);
-void iFEpupppLppL(x64emu_t *emu, uintptr_t fnc);
-void iFEppppppipp(x64emu_t *emu, uintptr_t fnc);
-void iFEppppppppp(x64emu_t *emu, uintptr_t fnc);
-void iFiiiiiiiiip(x64emu_t *emu, uintptr_t fnc);
-void iFpiipiiipip(x64emu_t *emu, uintptr_t fnc);
-void iFpippddiidd(x64emu_t *emu, uintptr_t fnc);
-void iFpCuWCCCCup(x64emu_t *emu, uintptr_t fnc);
-void iFpuupiuiipp(x64emu_t *emu, uintptr_t fnc);
-void iFpddpippppp(x64emu_t *emu, uintptr_t fnc);
-void iFppuuiiiiii(x64emu_t *emu, uintptr_t fnc);
-void iFppuuiiuupi(x64emu_t *emu, uintptr_t fnc);
-void iFpppiiipipi(x64emu_t *emu, uintptr_t fnc);
-void iFpppLLipppp(x64emu_t *emu, uintptr_t fnc);
-void iFppppiiuuii(x64emu_t *emu, uintptr_t fnc);
-void iFpppppppipi(x64emu_t *emu, uintptr_t fnc);
-void uFpppppppppp(x64emu_t *emu, uintptr_t fnc);
-void pFEiippppppp(x64emu_t *emu, uintptr_t fnc);
-void pFEpiiiiiipp(x64emu_t *emu, uintptr_t fnc);
-void pFEpippppppp(x64emu_t *emu, uintptr_t fnc);
-void pFpCuWCCuuCW(x64emu_t *emu, uintptr_t fnc);
-void pFpuwwWWuCuu(x64emu_t *emu, uintptr_t fnc);
-void pFpuuuwwwwWW(x64emu_t *emu, uintptr_t fnc);
-void pFpuuuWWWCCi(x64emu_t *emu, uintptr_t fnc);
-void pFplllllllll(x64emu_t *emu, uintptr_t fnc);
-void pFppuiipuuii(x64emu_t *emu, uintptr_t fnc);
-void pFpppppppppp(x64emu_t *emu, uintptr_t fnc);
-void iWEpuipupppp(x64emu_t *emu, uintptr_t fnc);
-void iWEpuuiiuipp(x64emu_t *emu, uintptr_t fnc);
-void iWEpuuuuiipp(x64emu_t *emu, uintptr_t fnc);
-void vFEpiiiupupup(x64emu_t *emu, uintptr_t fnc);
-void vFiiiiillliip(x64emu_t *emu, uintptr_t fnc);
-void vFiiiiilllilp(x64emu_t *emu, uintptr_t fnc);
-void vFuiiiiiiiiip(x64emu_t *emu, uintptr_t fnc);
-void vFuiiiiiiiuip(x64emu_t *emu, uintptr_t fnc);
-void vFuiiiiiiiuup(x64emu_t *emu, uintptr_t fnc);
-void vFuiiiillliip(x64emu_t *emu, uintptr_t fnc);
-void vFuiiiilllilp(x64emu_t *emu, uintptr_t fnc);
-void vFuiuiiiiiuup(x64emu_t *emu, uintptr_t fnc);
-void vFuuiuiiiiuup(x64emu_t *emu, uintptr_t fnc);
-void vFuuuuuuuuuuu(x64emu_t *emu, uintptr_t fnc);
-void vFuuupupppppp(x64emu_t *emu, uintptr_t fnc);
-void vFuuffiiffiip(x64emu_t *emu, uintptr_t fnc);
-void vFuufffffffff(x64emu_t *emu, uintptr_t fnc);
-void vFuuddiiddiip(x64emu_t *emu, uintptr_t fnc);
-void vFuffffffffff(x64emu_t *emu, uintptr_t fnc);
-void vFUufffffffff(x64emu_t *emu, uintptr_t fnc);
-void vFpipipiipiii(x64emu_t *emu, uintptr_t fnc);
-void vFpipppiiiipi(x64emu_t *emu, uintptr_t fnc);
-void vFpupiiupupup(x64emu_t *emu, uintptr_t fnc);
-void vFppiiiiiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFppiiiiipiii(x64emu_t *emu, uintptr_t fnc);
-void vFppiiiiddddi(x64emu_t *emu, uintptr_t fnc);
-void vFppiipppiiii(x64emu_t *emu, uintptr_t fnc);
-void vFppipppiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFppipppuiiii(x64emu_t *emu, uintptr_t fnc);
-void vFppppppppppp(x64emu_t *emu, uintptr_t fnc);
-void iFEpppipppppp(x64emu_t *emu, uintptr_t fnc);
-void iFEppppiiiiuu(x64emu_t *emu, uintptr_t fnc);
-void iFiiiiiiiiiip(x64emu_t *emu, uintptr_t fnc);
-void iFpiippiiipip(x64emu_t *emu, uintptr_t fnc);
-void iFppippipppip(x64emu_t *emu, uintptr_t fnc);
-void iFpppiiuuiiuu(x64emu_t *emu, uintptr_t fnc);
-void iFppppiiuuiiL(x64emu_t *emu, uintptr_t fnc);
-void uFEpLiupppLuV(x64emu_t *emu, uintptr_t fnc);
-void uFEpLippppLup(x64emu_t *emu, uintptr_t fnc);
-void uFEpLippppLuA(x64emu_t *emu, uintptr_t fnc);
-void uFEppppppippp(x64emu_t *emu, uintptr_t fnc);
-void uFppppppppppp(x64emu_t *emu, uintptr_t fnc);
-void pFEpipppppppi(x64emu_t *emu, uintptr_t fnc);
-void pFEppiiLpppip(x64emu_t *emu, uintptr_t fnc);
-void pFEppuiipuuii(x64emu_t *emu, uintptr_t fnc);
-void pFpppppppiipp(x64emu_t *emu, uintptr_t fnc);
-void pFppppppppppp(x64emu_t *emu, uintptr_t fnc);
-void iWEpuipuppppp(x64emu_t *emu, uintptr_t fnc);
-void iWEpuuiiuippu(x64emu_t *emu, uintptr_t fnc);
-void iWEpuuuuuiipp(x64emu_t *emu, uintptr_t fnc);
-void vFuiiiillliilp(x64emu_t *emu, uintptr_t fnc);
-void vFuuiiiiiiiiui(x64emu_t *emu, uintptr_t fnc);
-void vFuuiiiiiiiuip(x64emu_t *emu, uintptr_t fnc);
-void vFuuiiiiiiiuup(x64emu_t *emu, uintptr_t fnc);
-void vFuuuuuuuuuuuu(x64emu_t *emu, uintptr_t fnc);
-void vFffffffffffff(x64emu_t *emu, uintptr_t fnc);
-void vFpipppiiiipii(x64emu_t *emu, uintptr_t fnc);
-void vFpippppiiiipi(x64emu_t *emu, uintptr_t fnc);
-void vFppiiiiddddii(x64emu_t *emu, uintptr_t fnc);
-void vFppiiuuuiupup(x64emu_t *emu, uintptr_t fnc);
-void vFppiipppiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFpppiiiiiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFpppppppppppp(x64emu_t *emu, uintptr_t fnc);
-void iFEpppippppppp(x64emu_t *emu, uintptr_t fnc);
-void iFEppppiiiiuui(x64emu_t *emu, uintptr_t fnc);
-void iFpipllipppppp(x64emu_t *emu, uintptr_t fnc);
-void iFpipppppppppp(x64emu_t *emu, uintptr_t fnc);
-void iFpCCCWCWCCCWp(x64emu_t *emu, uintptr_t fnc);
-void iFpppllipppppp(x64emu_t *emu, uintptr_t fnc);
-void iFpppppppppppp(x64emu_t *emu, uintptr_t fnc);
-void pFEppiiuuuipii(x64emu_t *emu, uintptr_t fnc);
-void pFEppppppppppp(x64emu_t *emu, uintptr_t fnc);
-void pFWWiCCCCiipup(x64emu_t *emu, uintptr_t fnc);
-void pFpCuuWWwwCCup(x64emu_t *emu, uintptr_t fnc);
-void pFpuuuWWWWWWWW(x64emu_t *emu, uintptr_t fnc);
-void pFppiiuuuiupLp(x64emu_t *emu, uintptr_t fnc);
-void pFpppppppppppp(x64emu_t *emu, uintptr_t fnc);
-void vFEpppppppiippp(x64emu_t *emu, uintptr_t fnc);
-void vFuiiiiiiiiiuup(x64emu_t *emu, uintptr_t fnc);
-void vFuuuuuuuuuuuuu(x64emu_t *emu, uintptr_t fnc);
-void vFuffffffffffff(x64emu_t *emu, uintptr_t fnc);
-void vFpipppiiiiiiuu(x64emu_t *emu, uintptr_t fnc);
-void vFpippppppppppp(x64emu_t *emu, uintptr_t fnc);
-void vFppiiiiiiiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFppiipppiiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFppppppppppppp(x64emu_t *emu, uintptr_t fnc);
-void iFddddpppddpppp(x64emu_t *emu, uintptr_t fnc);
-void iFpippuuuiipppp(x64emu_t *emu, uintptr_t fnc);
-void iFpupiiiipppppp(x64emu_t *emu, uintptr_t fnc);
-void uFppppuuupppppp(x64emu_t *emu, uintptr_t fnc);
-void pFpCuuwwWWWWuup(x64emu_t *emu, uintptr_t fnc);
-void pFpuupppwwwwWWC(x64emu_t *emu, uintptr_t fnc);
-void pFppppppppppppp(x64emu_t *emu, uintptr_t fnc);
-void vFuffiiffiiffiip(x64emu_t *emu, uintptr_t fnc);
-void vFuddiiddiiddiip(x64emu_t *emu, uintptr_t fnc);
-void vFppiipppiiiiiii(x64emu_t *emu, uintptr_t fnc);
-void iFpipppppppppppp(x64emu_t *emu, uintptr_t fnc);
-void iFpppwwWWwwWWpuu(x64emu_t *emu, uintptr_t fnc);
-void pFppCpppwwwwwwWW(x64emu_t *emu, uintptr_t fnc);
-void vFuiiiiiuiiiiilll(x64emu_t *emu, uintptr_t fnc);
-void vFuuiiiiuuiiiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFfffffffffffffff(x64emu_t *emu, uintptr_t fnc);
-void vFpUUUUUUUUUUUuuu(x64emu_t *emu, uintptr_t fnc);
-void vFpppippppppppppp(x64emu_t *emu, uintptr_t fnc);
-void vFppppppppppppppp(x64emu_t *emu, uintptr_t fnc);
-void pFpuiippppppppppp(x64emu_t *emu, uintptr_t fnc);
-void pFppipppppppppppp(x64emu_t *emu, uintptr_t fnc);
-void pFppppppppppppppp(x64emu_t *emu, uintptr_t fnc);
-void vFpppppppppppppppp(x64emu_t *emu, uintptr_t fnc);
-void iFpppppppppppppppp(x64emu_t *emu, uintptr_t fnc);
-void pFpuuWWWWWWwwCCCuu(x64emu_t *emu, uintptr_t fnc);
-void pFppipipipipipipip(x64emu_t *emu, uintptr_t fnc);
-void pFpppppppppppppppp(x64emu_t *emu, uintptr_t fnc);
-void vFuuuiiiiiuiiiiilll(x64emu_t *emu, uintptr_t fnc);
-void vFppiiiiddddiiiiiuu(x64emu_t *emu, uintptr_t fnc);
-void vFpppuppiipppuUUUpi(x64emu_t *emu, uintptr_t fnc);
-void pFpuuuuuwwuuuuUUUup(x64emu_t *emu, uintptr_t fnc);
-void pFppippipipipipipip(x64emu_t *emu, uintptr_t fnc);
-void vFppuiiiiipuiiiiiiii(x64emu_t *emu, uintptr_t fnc);
-void vFpppipppppppppppppp(x64emu_t *emu, uintptr_t fnc);
-void iFpppppppppppppppppp(x64emu_t *emu, uintptr_t fnc);
-void LFpppppppppppppppppp(x64emu_t *emu, uintptr_t fnc);
-void pFippppppppppppppppp(x64emu_t *emu, uintptr_t fnc);
-void vFpiiiiiiiiiiiiiiiiii(x64emu_t *emu, uintptr_t fnc);
-void pFiiiippppppppppppppp(x64emu_t *emu, uintptr_t fnc);
-void pFpippppppppppppppppp(x64emu_t *emu, uintptr_t fnc);
-void pFpppWWCCpCpCpCWpCpCpC(x64emu_t *emu, uintptr_t fnc);
-void iFpppppppppppppppppppppp(x64emu_t *emu, uintptr_t fnc);
-void vFpppppppppppppppppppppppp(x64emu_t *emu, uintptr_t fnc);
-void iFpppppppppppppppppppppppppppppppppp(x64emu_t *emu, uintptr_t fnc);
-
-#if defined(HAVE_LD80BITS)
-void IFD(x64emu_t *emu, uintptr_t fnc);
-void DFD(x64emu_t *emu, uintptr_t fnc);
-void vFppippDDC(x64emu_t *emu, uintptr_t fnc);
-#endif
-
-#if !defined(HAVE_LD80BITS)
-void IFK(x64emu_t *emu, uintptr_t fnc);
-void KFK(x64emu_t *emu, uintptr_t fnc);
-void KFKK(x64emu_t *emu, uintptr_t fnc);
-void KFKp(x64emu_t *emu, uintptr_t fnc);
-void vFppippKKC(x64emu_t *emu, uintptr_t fnc);
-#endif
-
-#if defined(NOALIGN)
-void iFipiip(x64emu_t *emu, uintptr_t fnc);
-#endif
-
-#if !defined(NOALIGN)
-void iFEppu(x64emu_t *emu, uintptr_t fnc);
-void iFEiiip(x64emu_t *emu, uintptr_t fnc);
-void iFEipii(x64emu_t *emu, uintptr_t fnc);
-void iFEipiip(x64emu_t *emu, uintptr_t fnc);
-#endif
-
-void vFEv(x64emu_t *emu, uintptr_t fnc);
-void iFEv(x64emu_t *emu, uintptr_t fnc);
-void lFEv(x64emu_t *emu, uintptr_t fnc);
-void pFEv(x64emu_t *emu, uintptr_t fnc);
-void iFEvpp(x64emu_t *emu, uintptr_t fnc);
-void pFEppv(x64emu_t *emu, uintptr_t fnc);
-void iFEpvpp(x64emu_t *emu, uintptr_t fnc);
-void iFEpvvppp(x64emu_t *emu, uintptr_t fnc);
-void iFEpLvvpp(x64emu_t *emu, uintptr_t fnc);
-void iFEpuvvppp(x64emu_t *emu, uintptr_t fnc);
-
-int isSimpleWrapper(wrapper_t fun);
-
-#endif // __WRAPPER_H_
diff --git a/src/wrapped/wrappedalure.c b/src/wrapped/wrappedalure.c
index 6491903..6491903 100755..100644
--- a/src/wrapped/wrappedalure.c
+++ b/src/wrapped/wrappedalure.c
diff --git a/src/wrapped/wrappedalure_private.h b/src/wrapped/wrappedalure_private.h
index bda31cb..bda31cb 100755..100644
--- a/src/wrapped/wrappedalure_private.h
+++ b/src/wrapped/wrappedalure_private.h
diff --git a/src/wrapped/wrappedalut.c b/src/wrapped/wrappedalut.c
index a74eaa7..a74eaa7 100755..100644
--- a/src/wrapped/wrappedalut.c
+++ b/src/wrapped/wrappedalut.c
diff --git a/src/wrapped/wrappedalut_private.h b/src/wrapped/wrappedalut_private.h
index 04b403d..04b403d 100755..100644
--- a/src/wrapped/wrappedalut_private.h
+++ b/src/wrapped/wrappedalut_private.h
diff --git a/src/wrapped/wrappedatk.c b/src/wrapped/wrappedatk.c
index f785817..773212d 100755..100644
--- a/src/wrapped/wrappedatk.c
+++ b/src/wrapped/wrappedatk.c
@@ -44,7 +44,7 @@ GO(4)
static uintptr_t my_AtkEventListenerInit_fct_##A = 0; \
static void my_AtkEventListenerInit_##A() \
{ \
- RunFunction(my_context, my_AtkEventListenerInit_fct_##A, 0); \
+ RunFunctionFmt(my_AtkEventListenerInit_fct_##A, ""); \
}
SUPER()
#undef GO
@@ -66,7 +66,7 @@ static void* find_AtkEventListenerInit_Fct(void* fct)
static uintptr_t my_AtkEventListener_fct_##A = 0; \
static void my_AtkEventListener_##A(void* a) \
{ \
- RunFunction(my_context, my_AtkEventListener_fct_##A, 1, a); \
+ RunFunctionFmt(my_AtkEventListener_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -88,7 +88,7 @@ static void* find_AtkEventListener_Fct(void* fct)
static uintptr_t my_AtkKeySnoopFunc_fct_##A = 0; \
static int my_AtkKeySnoopFunc_##A(void* a, void* b) \
{ \
- return (int)RunFunction(my_context, my_AtkKeySnoopFunc_fct_##A, 2, a, b); \
+ return (int)RunFunctionFmt(my_AtkKeySnoopFunc_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -105,6 +105,28 @@ static void* find_AtkKeySnoopFunc_Fct(void* fct)
printf_log(LOG_NONE, "Warning, no more slot for atk AtkKeySnoopFunc callback\n");
return NULL;
}
+// GSignalEmissionHook ...
+#define GO(A) \
+static uintptr_t my_GSignalEmissionHook_fct_##A = 0; \
+static int my_GSignalEmissionHook_##A(void* a, uint32_t b, void* c, void* d) \
+{ \
+ return (int)RunFunctionFmt(my_GSignalEmissionHook_fct_##A, "pupp", a, b, c, d); \
+}
+SUPER()
+#undef GO
+static void* find_GSignalEmissionHook_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_GSignalEmissionHook_fct_##A == (uintptr_t)fct) return my_GSignalEmissionHook_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_GSignalEmissionHook_fct_##A == 0) {my_GSignalEmissionHook_fct_##A = (uintptr_t)fct; return my_GSignalEmissionHook_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for atk GSignalEmissionHook callback\n");
+ return NULL;
+}
#undef SUPER
@@ -123,6 +145,11 @@ EXPORT uint32_t my_atk_add_key_event_listener(x64emu_t* emu, void* f, void* p)
return my->atk_add_key_event_listener(find_AtkEventListener_Fct(f), p);
}
+EXPORT uint32_t my_atk_add_global_event_listener(x64emu_t* emu, void* f, void* p)
+{
+ return my->atk_add_global_event_listener(find_GSignalEmissionHook_Fct(f), p);
+}
+
#define PRE_INIT \
if(box64_nogtk) \
return -1;
diff --git a/src/wrapped/wrappedatk_private.h b/src/wrapped/wrappedatk_private.h
index 6bfd50e..ec08108 100755..100644
--- a/src/wrapped/wrappedatk_private.h
+++ b/src/wrapped/wrappedatk_private.h
@@ -9,49 +9,49 @@ GO(atk_action_get_localized_name, pFpi)
GO(atk_action_get_n_actions, iFp)
GO(atk_action_get_name, pFpi)
GO(atk_action_get_type, LFv)
-GO(atk_action_set_description, pFpi)
+GO(atk_action_set_description, iFpip)
GOM(atk_add_focus_tracker, uFEp)
-//GOM(atk_add_global_event_listener, uFEpp)
+GOM(atk_add_global_event_listener, uFEpp)
GOM(atk_add_key_event_listener, uFEpp)
-//GO(atk_attribute_set_free,
+GO(atk_attribute_set_free, vFp)
//GOM(atk_component_add_focus_handler, uFpp)
GO(atk_component_contains, iFpiii)
GO(atk_component_get_alpha, dFp)
-GO(atk_component_get_extents, vFpppppi)
-GO(atk_component_get_layer, iFp)
+GO(atk_component_get_extents, vFpppppu)
+GO(atk_component_get_layer, uFp)
GO(atk_component_get_mdi_zorder, iFp)
-GO(atk_component_get_position, vFpppi)
+GO(atk_component_get_position, vFpppu)
GO(atk_component_get_size, vFppp)
GO(atk_component_get_type, LFv)
GO(atk_component_grab_focus, iFp)
-GO(atk_component_ref_accessible_at_point, pFpiii)
+GO(atk_component_ref_accessible_at_point, pFpiiu)
GO(atk_component_remove_focus_handler, vFpu)
-GO(atk_component_scroll_to_point, iFpiii)
-GO(atk_component_set_extents, iFpiiiii)
-GO(atk_component_set_position, iFpiii)
+GO(atk_component_scroll_to_point, iFpuii)
+GO(atk_component_set_extents, iFpiiiiu)
+GO(atk_component_set_position, iFpiiu)
GO(atk_component_set_size, iFpii)
GO(atk_coord_type_get_type, LFv)
-//GO(atk_document_get_attributes,
-//GO(atk_document_get_attribute_value,
-//GO(atk_document_get_document,
+GO(atk_document_get_attributes, pFp)
+GO(atk_document_get_attribute_value, pFpp)
+GO(atk_document_get_document, pFp)
//GO(atk_document_get_document_type,
-//GO(atk_document_get_locale,
+GO(atk_document_get_locale, pFp)
GO(atk_document_get_type, LFv)
-//GO(atk_document_set_attribute_value,
+GO(atk_document_set_attribute_value, iFppp)
//GO(atk_editable_text_copy_text,
//GO(atk_editable_text_cut_text,
-//GO(atk_editable_text_delete_text,
-//GO(atk_editable_text_get_type,
-//GO(atk_editable_text_insert_text,
-//GO(atk_editable_text_paste_text,
-//GO(atk_editable_text_set_run_attributes,
-//GO(atk_editable_text_set_text_contents,
+GO(atk_editable_text_delete_text, vFpii)
+GO(atk_editable_text_get_type, LFv)
+GO(atk_editable_text_insert_text, vFppip)
+GO(atk_editable_text_paste_text, vFpi)
+GO(atk_editable_text_set_run_attributes, iFppii)
+GO(atk_editable_text_set_text_contents, vFpp)
GOM(atk_focus_tracker_init, vFEp)
GO(atk_focus_tracker_notify, vFp)
//GO(atk_get_binary_age,
GO(atk_get_default_registry, pFv)
GO(atk_get_focus_object, pFv)
-//GO(atk_get_interface_age,
+GO(atk_get_interface_age, uFv)
//GO(atk_get_major_version,
//GO(atk_get_micro_version,
//GO(atk_get_minor_version,
@@ -60,30 +60,30 @@ GO(atk_get_toolkit_name, pFv)
GO(atk_get_toolkit_version, pFv)
GO(atk_get_version, pFv)
//GO(atk_gobject_accessible_for_object,
-//GO(atk_gobject_accessible_get_object,
+GO(atk_gobject_accessible_get_object, pFp)
//GO(atk_gobject_accessible_get_type,
//GO(atk_hyperlink_get_end_index,
-//GO(atk_hyperlink_get_n_anchors,
-//GO(atk_hyperlink_get_object,
-//GO(atk_hyperlink_get_start_index,
-//GO(atk_hyperlink_get_type,
-//GO(atk_hyperlink_get_uri,
-//GO(atk_hyperlink_impl_get_hyperlink,
+GO(atk_hyperlink_get_n_anchors, iFp)
+GO(atk_hyperlink_get_object, pFpi)
+GO(atk_hyperlink_get_start_index, iFp)
+GO(atk_hyperlink_get_type, LFv)
+GO(atk_hyperlink_get_uri, pFpi)
+GO(atk_hyperlink_impl_get_hyperlink, pFp)
GO(atk_hyperlink_impl_get_type, LFv)
//GO(atk_hyperlink_is_inline,
-//GO(atk_hyperlink_is_selected_link,
+GO(atk_hyperlink_is_selected_link, iFp)
//GO(atk_hyperlink_is_valid,
//GO(atk_hyperlink_state_flags_get_type,
-//GO(atk_hypertext_get_link,
-//GO(atk_hypertext_get_link_index,
-//GO(atk_hypertext_get_n_links,
+GO(atk_hypertext_get_link, pFpi)
+GO(atk_hypertext_get_link_index, iFpi)
+GO(atk_hypertext_get_n_links, iFp)
GO(atk_hypertext_get_type, LFv)
//GO(atk_image_get_image_description,
-//GO(atk_image_get_image_locale,
-//GO(atk_image_get_image_position,
-//GO(atk_image_get_image_size,
+GO(atk_image_get_image_locale, pFp)
+GO(atk_image_get_image_position, vFpppu)
+GO(atk_image_get_image_size, vFppp)
GO(atk_image_get_type, LFv)
-//GO(atk_image_set_image_description,
+GO(atk_image_set_image_description, iFpp)
GO(atk_implementor_get_type, LFv)
GO(atk_implementor_ref_accessible, pFp)
GO(atk_key_event_type_get_type, LFv)
@@ -98,73 +98,73 @@ GO(atk_misc_threads_enter, vFp)
GO(atk_misc_threads_leave, vFp)
DATA(atk_misc_instance, sizeof(void*))
//GO(atk_no_op_object_factory_get_type,
-//GO(atk_no_op_object_factory_new,
+GO(atk_no_op_object_factory_new, pFv)
GO(atk_no_op_object_get_type, LFv)
-//GO(atk_no_op_object_new,
+GO(atk_no_op_object_new, pFp)
GO(atk_object_add_relationship, iFpip)
//GOM(atk_object_connect_property_change_handler, uFEpp)
-//GO(atk_object_factory_create_accessible,
-GO(atk_object_factory_get_accessible_type, iFp)
+GO(atk_object_factory_create_accessible, pFpp)
+GO(atk_object_factory_get_accessible_type, LFp)
GO(atk_object_factory_get_type, LFv)
//GO(atk_object_factory_invalidate,
GO(atk_object_get_attributes, pFp)
GO(atk_object_get_description, pFp)
GO(atk_object_get_index_in_parent, iFp)
-GO(atk_object_get_layer, iFp)
+GO(atk_object_get_layer, uFp)
GO(atk_object_get_mdi_zorder, iFp)
GO(atk_object_get_n_accessible_children, iFp)
GO(atk_object_get_name, pFp)
GO(atk_object_get_object_locale, pFp)
GO(atk_object_get_parent, pFp)
-GO(atk_object_get_role, iFp)
+GO(atk_object_get_role, uFp)
GO(atk_object_get_type, LFv)
GO(atk_object_initialize, vFpp)
-GO(atk_object_notify_state_change, vFpii)
+GO(atk_object_notify_state_change, vFpLi)
GO(atk_object_ref_accessible_child, pFpi)
GO(atk_object_ref_relation_set, pFp)
GO(atk_object_ref_state_set, pFp)
GO(atk_object_remove_property_change_handler, vFpu)
-GO(atk_object_remove_relationship, iFpip)
+GO(atk_object_remove_relationship, iFpup)
GO(atk_object_set_description, vFpp)
GO(atk_object_set_name, vFpp)
GO(atk_object_set_parent, vFpp)
-GO(atk_object_set_role, vFpi)
-//GO(atk_plug_get_id,
+GO(atk_object_set_role, vFpu)
+GO(atk_plug_get_id, pFp)
//GO(atk_plug_get_type,
//GO(atk_plug_new,
//GO(atk_rectangle_get_type,
-GO(atk_registry_get_factory, pFpi)
-GO(atk_registry_get_factory_type, iFpi)
+GO(atk_registry_get_factory, pFpL)
+GO(atk_registry_get_factory_type, LFpL)
//GO(atk_registry_get_type,
-GO(atk_registry_set_factory_type, vFpii)
-//GO(atk_relation_add_target,
-//GO(atk_relation_get_relation_type,
-//GO(atk_relation_get_target,
+GO(atk_registry_set_factory_type, vFpLL)
+GO(atk_relation_add_target, vFpp)
+GO(atk_relation_get_relation_type, uFp)
+GO(atk_relation_get_target, pFp)
//GO(atk_relation_get_type,
-//GO(atk_relation_new,
-//GO(atk_relation_remove_target,
-//GO(atk_relation_set_add,
-//GO(atk_relation_set_add_relation_by_type,
-//GO(atk_relation_set_contains,
-//GO(atk_relation_set_contains_target,
-//GO(atk_relation_set_get_n_relations,
-//GO(atk_relation_set_get_relation,
-//GO(atk_relation_set_get_relation_by_type,
+GO(atk_relation_new, pFpiu)
+GO(atk_relation_remove_target, iFpp)
+GO(atk_relation_set_add, vFpp)
+GO(atk_relation_set_add_relation_by_type, vFpup)
+GO(atk_relation_set_contains, iFpu)
+GO(atk_relation_set_contains_target, iFpup)
+GO(atk_relation_set_get_n_relations, iFp)
+GO(atk_relation_set_get_relation, pFpi)
+GO(atk_relation_set_get_relation_by_type, pFpu)
//GO(atk_relation_set_get_type,
-//GO(atk_relation_set_new,
+GO(atk_relation_set_new, pFv)
//GO(atk_relation_set_remove,
-//GO(atk_relation_type_for_name,
-//GO(atk_relation_type_get_name,
-//GO(atk_relation_type_get_type,
+GO(atk_relation_type_for_name, uFp)
+GO(atk_relation_type_get_name, pFu)
+GO(atk_relation_type_get_type, LFv)
//GO(atk_relation_type_register,
GO(atk_remove_focus_tracker, vFu)
GO(atk_remove_global_event_listener, vFu)
GO(atk_remove_key_event_listener, vFu)
GO(atk_role_for_name, iFp)
-GO(atk_role_get_localized_name, pFp)
+GO(atk_role_get_localized_name, pFu)
GO(atk_role_get_name, pFp)
GO(atk_role_get_type, LFv)
-GO(atk_role_register, iFp)
+GO(atk_role_register, uFp)
GO(atk_selection_add_selection, iFpi)
GO(atk_selection_clear_selection, iFp)
GO(atk_selection_get_selection_count, iFp)
@@ -173,96 +173,96 @@ GO(atk_selection_is_child_selected, iFpi)
GO(atk_selection_ref_selection, pFpi)
GO(atk_selection_remove_selection, iFpi)
GO(atk_selection_select_all_selection, iFp)
-//GO(atk_socket_embed,
-//GO(atk_socket_get_type,
-//GO(atk_socket_is_occupied,
-//GO(atk_socket_new,
-//GO(atk_state_set_add_state,
-//GO(atk_state_set_add_states,
+GO(atk_socket_embed, vFpp)
+GO(atk_socket_get_type, iFv)
+GO(atk_socket_is_occupied, iFp)
+GO(atk_socket_new, pFv)
+GO(atk_state_set_add_state, iFpi)
+GO(atk_state_set_add_states, vFppi)
//GO(atk_state_set_and_sets,
//GO(atk_state_set_clear_states,
-//GO(atk_state_set_contains_state,
-//GO(atk_state_set_contains_states,
+GO(atk_state_set_contains_state, iFpi)
+GO(atk_state_set_contains_states, iFppi)
//GO(atk_state_set_get_type,
-//GO(atk_state_set_is_empty,
-//GO(atk_state_set_new,
+GO(atk_state_set_is_empty, iFp)
+GO(atk_state_set_new, pFv)
//GO(atk_state_set_or_sets,
-//GO(atk_state_set_remove_state,
-//GO(atk_state_set_xor_sets,
-//GO(atk_state_type_for_name,
-//GO(atk_state_type_get_name,
-//GO(atk_state_type_get_type,
+GO(atk_state_set_remove_state, iFpu)
+GO(atk_state_set_xor_sets, pFpp)
+GO(atk_state_type_for_name, uFp)
+GO(atk_state_type_get_name, pFu)
+GO(atk_state_type_get_type, LFv)
//GO(atk_state_type_register,
-//GO(atk_streamable_content_get_mime_type,
-//GO(atk_streamable_content_get_n_mime_types,
+GO(atk_streamable_content_get_mime_type, pFpi)
+GO(atk_streamable_content_get_n_mime_types, iFp)
//GO(atk_streamable_content_get_stream,
//GO(atk_streamable_content_get_type,
-//GO(atk_streamable_content_get_uri,
+GO(atk_streamable_content_get_uri, pFpp)
//GO(atk_table_add_column_selection,
//GO(atk_table_add_row_selection,
-//GO(atk_table_get_caption,
+GO(atk_table_get_caption, pFp)
//GO(atk_table_get_column_at_index,
-//GO(atk_table_get_column_description,
-//GO(atk_table_get_column_extent_at,
+GO(atk_table_get_column_description, pFpi)
+GO(atk_table_get_column_extent_at, iFpii)
//GO(atk_table_get_column_header,
//GO(atk_table_get_index_at,
-//GO(atk_table_get_n_columns,
-//GO(atk_table_get_n_rows,
-//GO(atk_table_get_row_at_index,
-//GO(atk_table_get_row_description,
-//GO(atk_table_get_row_extent_at,
-//GO(atk_table_get_row_header,
+GO(atk_table_get_n_columns, iFp)
+GO(atk_table_get_n_rows, iFp)
+GO(atk_table_get_row_at_index, iFpi)
+GO(atk_table_get_row_description, pFpi)
+GO(atk_table_get_row_extent_at, iFpii)
+GO(atk_table_get_row_header, pFpi)
//GO(atk_table_get_selected_columns,
-//GO(atk_table_get_selected_rows,
-//GO(atk_table_get_summary,
-//GO(atk_table_get_type,
+GO(atk_table_get_selected_rows, iFpp)
+GO(atk_table_get_summary, pFp)
+GO(atk_table_get_type, LFv)
//GO(atk_table_is_column_selected,
//GO(atk_table_is_row_selected,
-//GO(atk_table_is_selected,
-//GO(atk_table_ref_at,
-//GO(atk_table_remove_column_selection,
+GO(atk_table_is_selected, iFpii)
+GO(atk_table_ref_at, pFpii)
+GO(atk_table_remove_column_selection, iFpi)
//GO(atk_table_remove_row_selection,
//GO(atk_table_set_caption,
//GO(atk_table_set_column_description,
//GO(atk_table_set_column_header,
-//GO(atk_table_set_row_description,
-//GO(atk_table_set_row_header,
-//GO(atk_table_set_summary,
-//GO(atk_text_add_selection,
-//GO(atk_text_attribute_for_name,
-//GO(atk_text_attribute_get_name,
+GO(atk_table_set_row_description, vFpip)
+GO(atk_table_set_row_header, vFpip)
+GO(atk_table_set_summary, vFpp)
+GO(atk_text_add_selection, iFpii)
+GO(atk_text_attribute_for_name, uFp)
+GO(atk_text_attribute_get_name, pFu)
//GO(atk_text_attribute_get_type,
-//GO(atk_text_attribute_get_value,
+GO(atk_text_attribute_get_value, pFui)
//GO(atk_text_attribute_register,
//GO(atk_text_boundary_get_type,
//GO(atk_text_clip_type_get_type,
-//GO(atk_text_free_ranges,
-//GO(atk_text_get_bounded_ranges,
-//GO(atk_text_get_caret_offset,
-//GO(atk_text_get_character_at_offset,
-//GO(atk_text_get_character_count,
-//GO(atk_text_get_character_extents,
-//GO(atk_text_get_default_attributes,
-//GO(atk_text_get_n_selections,
-//GO(atk_text_get_offset_at_point,
-//GO(atk_text_get_range_extents,
-//GO(atk_text_get_run_attributes,
-//GO(atk_text_get_selection,
-//GO(atk_text_get_text,
+GO(atk_text_free_ranges, vFp)
+GO(atk_text_get_bounded_ranges, pFppuuu)
+GO(atk_text_get_caret_offset, iFp)
+GO(atk_text_get_character_at_offset, uFpi)
+GO(atk_text_get_character_count, iFp)
+GO(atk_text_get_character_extents, vFpippppu)
+GO(atk_text_get_default_attributes, pFp)
+GO(atk_text_get_n_selections, iFp)
+GO(atk_text_get_offset_at_point, iFpiiu)
+GO(atk_text_get_range_extents, vFpiiup)
+GO(atk_text_get_run_attributes, pFpipp)
+GO(atk_text_get_selection, pFpipp)
+GO(atk_text_get_text, pFpii)
//GO(atk_text_get_text_after_offset,
//GO(atk_text_get_text_at_offset,
-//GO(atk_text_get_text_before_offset,
+GO(atk_text_get_text_before_offset, pFpiupp)
GO(atk_text_get_type, LFv)
GO(atk_text_range_get_type, LFv)
//GO(atk_text_remove_selection,
-GO(atk_text_scroll_substring_to_point, iFpiiiii)
-//GO(atk_text_set_caret_offset,
-//GO(atk_text_set_selection,
+GO(atk_text_scroll_substring_to_point, iFpiiuii)
+GO(atk_text_set_caret_offset, iFpi)
+GO(atk_text_set_selection, iFpiii)
GO(atk_util_get_type, LFv)
-//GO(atk_value_get_current_value,
-//GO(atk_value_get_maximum_value,
-//GO(atk_value_get_minimum_increment,
-//GO(atk_value_get_minimum_value,
+GO(atk_value_get_current_value, vFpp)
+GO(atk_value_get_maximum_value, vFpp)
+GO(atk_value_get_minimum_increment, vFpp)
+GO(atk_value_get_minimum_value, vFpp)
GO(atk_value_get_type, LFv)
-//GO(atk_value_set_current_value,
+GO(atk_value_set_current_value, iFpp)
GO(atk_window_get_type, LFv)
diff --git a/src/wrapped/wrappedatkbridge.c b/src/wrapped/wrappedatkbridge.c
index 88198fa..88198fa 100755..100644
--- a/src/wrapped/wrappedatkbridge.c
+++ b/src/wrapped/wrappedatkbridge.c
diff --git a/src/wrapped/wrappedatkbridge_private.h b/src/wrapped/wrappedatkbridge_private.h
index f77ca36..f77ca36 100755..100644
--- a/src/wrapped/wrappedatkbridge_private.h
+++ b/src/wrapped/wrappedatkbridge_private.h
diff --git a/src/wrapped/wrappedatomic_private.h b/src/wrapped/wrappedatomic_private.h
index 3c7a258..f98dea6 100644
--- a/src/wrapped/wrappedatomic_private.h
+++ b/src/wrapped/wrappedatomic_private.h
@@ -18,7 +18,7 @@ GO(__atomic_compare_exchange, iFpii)
//GO(__atomic_compare_exchange_2,
//GO(__atomic_compare_exchange_4,
//GO(__atomic_compare_exchange_8,
-//GO(__atomic_exchange,
+GO(__atomic_exchange, vFpppi)
//GO(__atomic_exchange_1,
//GO(__atomic_exchange_16,
//GO(__atomic_exchange_2,
@@ -59,8 +59,8 @@ GO(__atomic_compare_exchange, iFpii)
//GO(atomic_flag_clear_explicit,
//GO(atomic_flag_test_and_set,
//GO(atomic_flag_test_and_set_explicit,
-//GO(__atomic_is_lock_free,
-//GO(__atomic_load,
+GO(__atomic_is_lock_free, iFLp)
+GO(__atomic_load, vFppi)
//GO(__atomic_load_1,
//GO(__atomic_load_16,
//GO(__atomic_load_2,
@@ -77,7 +77,7 @@ GO(__atomic_compare_exchange, iFpii)
//GO(__atomic_or_fetch_4,
//GO(__atomic_or_fetch_8,
//GO(atomic_signal_fence,
-//GO(__atomic_store,
+GO(__atomic_store, vFppi)
//GO(__atomic_store_1,
//GO(__atomic_store_16,
//GO(__atomic_store_2,
diff --git a/src/wrapped/wrappedatspi.c b/src/wrapped/wrappedatspi.c
index 9bd6e5c..ee1bd0d 100755..100644
--- a/src/wrapped/wrappedatspi.c
+++ b/src/wrapped/wrappedatspi.c
@@ -11,12 +11,90 @@
#include "bridge.h"
#include "librarian/library_private.h"
#include "x64emu.h"
+#include "emu/x64emu_private.h"
+#include "callback.h"
+#include "librarian.h"
+#include "box64context.h"
+#include "emu/x64emu_private.h"
+#include "myalign.h"
+#include "gtkclass.h"
const char* atspiName = "libatspi.so.0";
#define LIBNAME atspi
+#define ADDED_FUNCTIONS() \
+
+#include "generated/wrappedatspitypes.h"
+
+#include "wrappercallback.h"
+
+#define SUPER() \
+GO(0) \
+GO(1) \
+GO(2) \
+GO(3) \
+GO(4)
+
+// GDestroyNotify ...
+#define GO(A) \
+static uintptr_t my_GDestroyNotify_fct_##A = 0; \
+static void my_GDestroyNotify_##A(void* a) \
+{ \
+ RunFunctionFmt(my_GDestroyNotify_fct_##A, "p", a); \
+}
+SUPER()
+#undef GO
+static void* find_GDestroyNotify_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_GDestroyNotify_fct_##A == (uintptr_t)fct) return my_GDestroyNotify_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_GDestroyNotify_fct_##A == 0) {my_GDestroyNotify_fct_##A = (uintptr_t)fct; return my_GDestroyNotify_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for atspi GDestroyNotify callback\n");
+ return NULL;
+}
+// AtspiEventListenerCB ...
+#define GO(A) \
+static uintptr_t my_AtspiEventListenerCB_fct_##A = 0; \
+static void my_AtspiEventListenerCB_##A(void* a, void* b) \
+{ \
+ RunFunctionFmt(my_AtspiEventListenerCB_fct_##A, "pp", a, b); \
+}
+SUPER()
+#undef GO
+static void* find_AtspiEventListenerCB_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_AtspiEventListenerCB_fct_##A == (uintptr_t)fct) return my_AtspiEventListenerCB_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_AtspiEventListenerCB_fct_##A == 0) {my_AtspiEventListenerCB_fct_##A = (uintptr_t)fct; return my_AtspiEventListenerCB_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for atspi AtspiEventListenerCB callback\n");
+ return NULL;
+}
+
+#undef SUPER
+
+EXPORT void* my_atspi_event_listener_new(x64emu_t* emu, void* f, void* data, void* d)
+{
+ return my->atspi_event_listener_new(find_AtspiEventListenerCB_Fct(f), data, find_GDestroyNotify_Fct(d));
+}
+
#define PRE_INIT \
if(box64_nogtk) \
return -1;
+#define CUSTOM_INIT \
+ getMy(lib);
+
+#define CUSTOM_FINI \
+ freeMy();
+
#include "wrappedlib_init.h"
diff --git a/src/wrapped/wrappedatspi_private.h b/src/wrapped/wrappedatspi_private.h
index 42115eb..b332893 100755..100644
--- a/src/wrapped/wrappedatspi_private.h
+++ b/src/wrapped/wrappedatspi_private.h
@@ -7,18 +7,18 @@
//GO(atspi_accessible_get_accessible_id,
//GO(atspi_accessible_get_action,
//GO(atspi_accessible_get_action_iface,
-//GO(atspi_accessible_get_application,
+GO(atspi_accessible_get_application, pFpp)
//GO(atspi_accessible_get_atspi_version,
-//GO(atspi_accessible_get_attributes,
+GO(atspi_accessible_get_attributes, pFpp)
//GO(atspi_accessible_get_attributes_as_array,
//GO(_atspi_accessible_get_cache_mask,
-//GO(atspi_accessible_get_child_at_index,
-//GO(atspi_accessible_get_child_count,
+GO(atspi_accessible_get_child_at_index, pFpip)
+GO(atspi_accessible_get_child_count, iFpp)
//GO(atspi_accessible_get_collection,
//GO(atspi_accessible_get_collection_iface,
//GO(atspi_accessible_get_component,
//GO(atspi_accessible_get_component_iface,
-//GO(atspi_accessible_get_description,
+GO(atspi_accessible_get_description, pFpp)
//GO(atspi_accessible_get_document,
//GO(atspi_accessible_get_document_iface,
//GO(atspi_accessible_get_editable_text,
@@ -30,18 +30,18 @@
//GO(atspi_accessible_get_image,
//GO(atspi_accessible_get_image_iface,
//GO(atspi_accessible_get_index_in_parent,
-//GO(atspi_accessible_get_interfaces,
+GO(atspi_accessible_get_interfaces, pFp)
//GO(atspi_accessible_get_localized_role_name,
-//GO(atspi_accessible_get_name,
+GO(atspi_accessible_get_name, pFpp)
//GO(atspi_accessible_get_object_locale,
-//GO(atspi_accessible_get_parent,
-//GO(atspi_accessible_get_process_id,
-//GO(atspi_accessible_get_relation_set,
-//GO(atspi_accessible_get_role,
-//GO(atspi_accessible_get_role_name,
+GO(atspi_accessible_get_parent, pFpp)
+GO(atspi_accessible_get_process_id, uFpp)
+GO(atspi_accessible_get_relation_set, pFpp)
+GO(atspi_accessible_get_role, iFpp)
+GO(atspi_accessible_get_role_name, pFpp)
//GO(atspi_accessible_get_selection,
//GO(atspi_accessible_get_selection_iface,
-//GO(atspi_accessible_get_state_set,
+GO(atspi_accessible_get_state_set, pFpp)
//GO(atspi_accessible_get_table,
//GO(atspi_accessible_get_table_cell,
//GO(atspi_accessible_get_table_iface,
@@ -158,14 +158,14 @@
//GO(atspi_editable_text_paste_text,
//GO(atspi_editable_text_set_text_contents,
//GO(_atspi_error_quark,
-//GO(atspi_event_get_type,
-//GO(atspi_event_listener_deregister,
+GO(atspi_event_get_type, LFv)
+GO(atspi_event_listener_deregister, iFppp)
//GO(atspi_event_listener_deregister_from_callback,
//GO(atspi_event_listener_deregister_no_data,
//GO(atspi_event_listener_get_type,
-//GO(atspi_event_listener_new,
+GOM(atspi_event_listener_new, pFppp)
//GO(atspi_event_listener_new_simple,
-//GO(atspi_event_listener_register,
+GO(atspi_event_listener_register, iFppp)
//GO(atspi_event_listener_register_from_callback,
//GO(atspi_event_listener_register_from_callback_full,
//GO(atspi_event_listener_register_full,
@@ -178,7 +178,7 @@
//GO(atspi_generate_mouse_event,
//GO(atspi_get_a11y_bus,
//GO(_atspi_get_allow_sync,
-//GO(atspi_get_desktop,
+GO(atspi_get_desktop, pFi)
//GO(atspi_get_desktop_count,
//GO(atspi_get_desktop_list,
//GO(_atspi_get_iface_num,
@@ -202,7 +202,7 @@
//GO(atspi_image_get_image_position,
//GO(atspi_image_get_image_size,
//GO(atspi_image_get_type,
-//GO(atspi_init,
+GO(atspi_init, iFv)
//DATA(atspi_interface_accessible,
//DATA(atspi_interface_action,
//DATA(atspi_interface_application,
@@ -258,9 +258,9 @@
//GO(_atspi_ref_accessible,
//GO(atspi_register_device_event_listener,
//GO(atspi_register_keystroke_listener,
-//GO(atspi_relation_get_n_targets,
-//GO(atspi_relation_get_relation_type,
-//GO(atspi_relation_get_target,
+GO(atspi_relation_get_n_targets, iFp)
+GO(atspi_relation_get_relation_type, iFp)
+GO(atspi_relation_get_target, pFpi)
//GO(atspi_relation_get_type,
//GO(_atspi_relation_new_from_iter,
//GO(atspi_relation_type_get_type,
@@ -288,7 +288,7 @@
//GO(atspi_state_set_compare,
//GO(atspi_state_set_contains,
//GO(atspi_state_set_equals,
-//GO(atspi_state_set_get_states,
+GO(atspi_state_set_get_states, pFp)
//GO(atspi_state_set_get_type,
//GO(atspi_state_set_is_empty,
//GO(atspi_state_set_new,
diff --git a/src/wrapped/wrappedbz2.c b/src/wrapped/wrappedbz2.c
index e3ff920..8503398 100755..100644
--- a/src/wrapped/wrappedbz2.c
+++ b/src/wrapped/wrappedbz2.c
@@ -37,7 +37,7 @@ GO(4)
static uintptr_t my_alloc_fct_##A = 0; \
static void* my_alloc_##A(void* opaque, int m, int n) \
{ \
- return (void*)RunFunction(my_context, my_alloc_fct_##A, 3, opaque, m, n); \
+ return (void*)RunFunctionFmt(my_alloc_fct_##A, "pii", opaque, m, n); \
}
SUPER()
#undef GO
@@ -69,7 +69,7 @@ static void* reverse_alloc_Fct(void* fct)
static uintptr_t my_free_fct_##A = 0; \
static void my_free_##A(void* opaque, void* p) \
{ \
- RunFunction(my_context, my_free_fct_##A, 2, opaque, p); \
+ RunFunctionFmt(my_free_fct_##A, "pp", opaque, p); \
}
SUPER()
#undef GO
diff --git a/src/wrapped/wrappedbz2_private.h b/src/wrapped/wrappedbz2_private.h
index f05e42f..f05e42f 100755..100644
--- a/src/wrapped/wrappedbz2_private.h
+++ b/src/wrapped/wrappedbz2_private.h
diff --git a/src/wrapped/wrappedcairo.c b/src/wrapped/wrappedcairo.c
index a910e72..a910e72 100755..100644
--- a/src/wrapped/wrappedcairo.c
+++ b/src/wrapped/wrappedcairo.c
diff --git a/src/wrapped/wrappedcairo_private.h b/src/wrapped/wrappedcairo_private.h
index 7e484d1..4a92a41 100755..100644
--- a/src/wrapped/wrappedcairo_private.h
+++ b/src/wrapped/wrappedcairo_private.h
@@ -15,9 +15,9 @@ GO(cairo_copy_path, pFp)
GO(cairo_copy_path_flat, pFp)
GO(cairo_create, pFp)
GO(cairo_curve_to, vFpdddddd)
-//GO(cairo_debug_reset_static_data,
+GO(cairo_debug_reset_static_data, vFv)
GO(cairo_destroy, vFp)
-GO(cairo_device_acquire, iFp)
+GO(cairo_device_acquire, uFp)
GO(cairo_device_destroy, vFp)
GO(cairo_device_finish, vFp)
GO(cairo_device_flush, vFp)
@@ -43,26 +43,26 @@ GO(cairo_fill_preserve, vFp)
GO(cairo_font_extents, vFpp)
GO(cairo_font_face_destroy, vFp)
GO(cairo_font_face_get_reference_count, uFp)
-GO(cairo_font_face_get_type, iFp)
+GO(cairo_font_face_get_type, uFp)
GO(cairo_font_face_get_user_data, pFpp)
GO(cairo_font_face_reference, pFp)
//GOM(cairo_font_face_set_user_data, iFpppp)
-GO(cairo_font_face_status, iFp)
+GO(cairo_font_face_status, uFp)
GO(cairo_font_options_copy, pFp)
GO(cairo_font_options_create, pFv)
GO(cairo_font_options_destroy, vFp)
GO(cairo_font_options_equal, iFpp)
-GO(cairo_font_options_get_antialias, iFp)
-GO(cairo_font_options_get_hint_metrics, iFp)
-GO(cairo_font_options_get_hint_style, iFp)
-GO(cairo_font_options_get_subpixel_order, iFp)
+GO(cairo_font_options_get_antialias, uFp)
+GO(cairo_font_options_get_hint_metrics, uFp)
+GO(cairo_font_options_get_hint_style, uFp)
+GO(cairo_font_options_get_subpixel_order, uFp)
GO(cairo_font_options_hash, LFp)
GO(cairo_font_options_merge, vFpp)
-GO(cairo_font_options_set_antialias, vFpi)
-GO(cairo_font_options_set_hint_metrics, vFpi)
-GO(cairo_font_options_set_hint_style, vFpi)
-GO(cairo_font_options_set_subpixel_order, vFpi)
-GO(cairo_font_options_status, iFp)
+GO(cairo_font_options_set_antialias, vFpu)
+GO(cairo_font_options_set_hint_metrics, vFpu)
+GO(cairo_font_options_set_hint_style, vFpu)
+GO(cairo_font_options_set_subpixel_order, vFpu)
+GO(cairo_font_options_status, uFp)
GO(cairo_format_stride_for_width, iFii)
GO(cairo_ft_font_face_create_for_ft_face, pFpi)
GO(cairo_ft_font_face_create_for_pattern, pFp)
@@ -72,21 +72,21 @@ GO(cairo_ft_font_face_unset_synthesize, vFpu)
GO(cairo_ft_font_options_substitute, vFpp)
GO(cairo_ft_scaled_font_lock_face, pFp)
GO(cairo_ft_scaled_font_unlock_face, vFp)
-GO(cairo_get_antialias, iFp)
+GO(cairo_get_antialias, uFp)
GO(cairo_get_current_point, vFppp)
GO(cairo_get_dash, vFppp)
GO(cairo_get_dash_count, iFp)
-GO(cairo_get_fill_rule, iFp)
+GO(cairo_get_fill_rule, uFp)
GO(cairo_get_font_face, pFp)
GO(cairo_get_font_matrix, vFpp)
GO(cairo_get_font_options, vFpp)
GO(cairo_get_group_target, pFp)
-GO(cairo_get_line_cap, iFp)
-GO(cairo_get_line_join, iFp)
+GO(cairo_get_line_cap, uFp)
+GO(cairo_get_line_join, uFp)
GO(cairo_get_line_width, dFp)
GO(cairo_get_matrix, vFpp)
GO(cairo_get_miter_limit, dFp)
-GO(cairo_get_operator, iFp)
+GO(cairo_get_operator, uFp)
GO(cairo_get_reference_count, uFp)
GO(cairo_get_scaled_font, pFp)
GO(cairo_get_source, pFp)
@@ -101,7 +101,7 @@ GO(cairo_has_current_point, iFp)
GO(cairo_identity_matrix, vFp)
GO(cairo_image_surface_create, pFiii)
GO(cairo_image_surface_create_for_data, pFpiiii)
-//GO(cairo_image_surface_create_from_png,
+GO(cairo_image_surface_create_from_png, pFp)
//GO(cairo_image_surface_create_from_png_stream,
GO(cairo_image_surface_get_data, pFp)
GO(cairo_image_surface_get_format, iFp)
@@ -119,7 +119,7 @@ GO(cairo_matrix_init_identity, vFp)
GO(cairo_matrix_init_rotate, vFpd)
GO(cairo_matrix_init_scale, vFpdd)
GO(cairo_matrix_init_translate, vFpdd)
-GO(cairo_matrix_invert, iFp)
+GO(cairo_matrix_invert, uFp)
GO(cairo_matrix_multiply, vFppp)
GO(cairo_matrix_rotate, vFpd)
GO(cairo_matrix_scale, vFpdd)
@@ -129,9 +129,9 @@ GO(cairo_matrix_translate, vFpdd)
GO(cairo_mesh_pattern_begin_patch, vFp)
GO(cairo_mesh_pattern_curve_to, vFpdddddd)
GO(cairo_mesh_pattern_end_patch, vFp)
-GO(cairo_mesh_pattern_get_control_point, iFpuupp)
-GO(cairo_mesh_pattern_get_corner_color_rgba, iFpuupppp)
-GO(cairo_mesh_pattern_get_patch_count, iFpp)
+GO(cairo_mesh_pattern_get_control_point, uFpuupp)
+GO(cairo_mesh_pattern_get_corner_color_rgba, uFpuupppp)
+GO(cairo_mesh_pattern_get_patch_count, uFpp)
GO(cairo_mesh_pattern_get_path, pFpu)
GO(cairo_mesh_pattern_line_to, vFpdd)
GO(cairo_mesh_pattern_move_to, vFpdd)
@@ -151,67 +151,67 @@ GO(cairo_pattern_create_for_surface, pFp)
GO(cairo_pattern_create_linear, pFdddd)
GO(cairo_pattern_create_mesh, pFv)
GO(cairo_pattern_create_radial, pFdddddd)
-//GO(cairo_pattern_create_raster_source,
+GO(cairo_pattern_create_raster_source, pFpuii)
GO(cairo_pattern_create_rgb, pFddd)
GO(cairo_pattern_create_rgba, pFdddd)
GO(cairo_pattern_destroy, vFp)
-GO(cairo_pattern_get_color_stop_count, iFpp)
-GO(cairo_pattern_get_color_stop_rgba, iFpippppp)
-GO(cairo_pattern_get_extend, iFp)
-GO(cairo_pattern_get_filter, iFp)
-GO(cairo_pattern_get_linear_points, iFppppp)
+GO(cairo_pattern_get_color_stop_count, uFpp)
+GO(cairo_pattern_get_color_stop_rgba, uFpippppp)
+GO(cairo_pattern_get_extend, uFp)
+GO(cairo_pattern_get_filter, uFp)
+GO(cairo_pattern_get_linear_points, uFppppp)
GO(cairo_pattern_get_matrix, vFpp)
-GO(cairo_pattern_get_radial_circles, iFppppppp)
+GO(cairo_pattern_get_radial_circles, uFppppppp)
GO(cairo_pattern_get_reference_count, uFp)
GO(cairo_pattern_get_rgba, iFppppp)
-GO(cairo_pattern_get_surface, iFpp)
-GO(cairo_pattern_get_type, iFp)
+GO(cairo_pattern_get_surface, uFpp)
+GO(cairo_pattern_get_type, uFp)
GO(cairo_pattern_get_user_data, pFpp)
GO(cairo_pattern_reference, pFp)
-GO(cairo_pattern_set_extend, vFpi)
-GO(cairo_pattern_set_filter, vFpi)
+GO(cairo_pattern_set_extend, vFpu)
+GO(cairo_pattern_set_filter, vFpu)
GO(cairo_pattern_set_matrix, vFpp)
//GOM(cairo_pattern_set_user_data, iFEpppp)
-GO(cairo_pattern_status, iFp)
-//GO(cairo_pdf_get_versions,
-//GO(cairo_pdf_surface_create,
+GO(cairo_pattern_status, uFp)
+GO(cairo_pdf_get_versions, vFpp)
+GO(cairo_pdf_surface_create, pFpdd)
//GO(cairo_pdf_surface_create_for_stream,
-//GO(cairo_pdf_surface_restrict_to_version,
-//GO(cairo_pdf_surface_set_size,
-//GO(cairo_pdf_version_to_string,
+GO(cairo_pdf_surface_restrict_to_version, vFpu)
+GO(cairo_pdf_surface_set_size, vFpdd)
+GO(cairo_pdf_version_to_string, pFu)
GO(cairo_pop_group, pFp)
GO(cairo_pop_group_to_source, vFp)
-//GO(cairo_ps_get_levels,
-//GO(cairo_ps_level_to_string,
-//GO(cairo_ps_surface_create,
+GO(cairo_ps_get_levels, vFpp)
+GO(cairo_ps_level_to_string, pFu)
+GO(cairo_ps_surface_create, pFpdd)
//GO(cairo_ps_surface_create_for_stream,
-//GO(cairo_ps_surface_dsc_begin_page_setup,
+GO(cairo_ps_surface_dsc_begin_page_setup, vFp)
//GO(cairo_ps_surface_dsc_begin_setup,
-//GO(cairo_ps_surface_dsc_comment,
-//GO(cairo_ps_surface_get_eps,
-//GO(cairo_ps_surface_restrict_to_level,
-//GO(cairo_ps_surface_set_eps,
-//GO(cairo_ps_surface_set_size,
+GO(cairo_ps_surface_dsc_comment, vFpp)
+GO(cairo_ps_surface_get_eps, iFp)
+GO(cairo_ps_surface_restrict_to_level, vFpu)
+GO(cairo_ps_surface_set_eps, vFpi)
+GO(cairo_ps_surface_set_size, vFpdd)
GO(cairo_push_group, vFp)
-GO(cairo_push_group_with_content, vFpi)
-//GO(cairo_raster_source_pattern_get_acquire,
-//GO(cairo_raster_source_pattern_get_callback_data,
-//GO(cairo_raster_source_pattern_get_copy,
-//GO(cairo_raster_source_pattern_get_finish,
-//GO(cairo_raster_source_pattern_get_snapshot,
+GO(cairo_push_group_with_content, vFpu)
+GO(cairo_raster_source_pattern_get_acquire, vFppp)
+GO(cairo_raster_source_pattern_get_callback_data, pFp)
+GO(cairo_raster_source_pattern_get_copy, pFp)
+GO(cairo_raster_source_pattern_get_finish, pFp)
+GO(cairo_raster_source_pattern_get_snapshot, pFp)
//GO(cairo_raster_source_pattern_set_acquire,
-//GO(cairo_raster_source_pattern_set_callback_data,
+GO(cairo_raster_source_pattern_set_callback_data, vFpp)
//GO(cairo_raster_source_pattern_set_copy,
//GO(cairo_raster_source_pattern_set_finish,
//GO(cairo_raster_source_pattern_set_snapshot,
-//GO(cairo_recording_surface_create,
-//GO(cairo_recording_surface_get_extents,
-//GO(cairo_recording_surface_ink_extents,
+GO(cairo_recording_surface_create, pFup)
+GO(cairo_recording_surface_get_extents, iFpp)
+GO(cairo_recording_surface_ink_extents, vFppppp)
GO(cairo_rectangle, vFpdddd)
GO(cairo_rectangle_list_destroy, vFp)
GO(cairo_reference, pFp)
GO(cairo_region_contains_point, iFpii)
-GO(cairo_region_contains_rectangle, iFpp)
+GO(cairo_region_contains_rectangle, uFpp)
GO(cairo_region_copy, pFp)
GO(cairo_region_create, pFv)
GO(cairo_region_create_rectangle, pFp)
@@ -225,14 +225,14 @@ GO(cairo_region_intersect_rectangle, iFpp)
GO(cairo_region_is_empty, iFp)
GO(cairo_region_num_rectangles, iFp)
GO(cairo_region_reference, pFp)
-GO(cairo_region_status, iFp)
+GO(cairo_region_status, uFp)
GO(cairo_region_subtract, iFpp)
GO(cairo_region_subtract_rectangle, iFpp)
GO(cairo_region_translate, vFpii)
GO(cairo_region_union, iFpp)
GO(cairo_region_union_rectangle, iFpp)
-GO(cairo_region_xor, iFpp)
-GO(cairo_region_xor_rectangle, iFpp)
+GO(cairo_region_xor, uFpp)
+GO(cairo_region_xor_rectangle, uFpp)
GO(cairo_rel_curve_to, vFpdddddd)
GO(cairo_rel_line_to, vFpdd)
GO(cairo_rel_move_to, vFpdd)
@@ -250,36 +250,36 @@ GO(cairo_scaled_font_get_font_matrix, vFpp)
GO(cairo_scaled_font_get_font_options, vFpp)
GO(cairo_scaled_font_get_reference_count, uFp)
GO(cairo_scaled_font_get_scale_matrix, vFpp)
-GO(cairo_scaled_font_get_type, iFp)
+GO(cairo_scaled_font_get_type, uFp)
GO(cairo_scaled_font_get_user_data, pFpp)
GO(cairo_scaled_font_glyph_extents, vFppip)
GO(cairo_scaled_font_reference, pFp)
//GOM(cairo_scaled_font_set_user_data, iFEpppp)
-GO(cairo_scaled_font_status, iFp)
+GO(cairo_scaled_font_status, uFp)
GO(cairo_scaled_font_text_extents, vFppp)
-GO(cairo_scaled_font_text_to_glyphs, iFpddpippppp)
-//GO(cairo_script_create,
+GO(cairo_scaled_font_text_to_glyphs, uFpddpippppp)
+GO(cairo_script_create, pFp)
//GO(cairo_script_create_for_stream,
-//GO(cairo_script_from_recording_surface,
-//GO(cairo_script_get_mode,
-//GO(cairo_script_set_mode,
-//GO(cairo_script_surface_create,
-//GO(cairo_script_surface_create_for_target,
-//GO(cairo_script_write_comment,
-GO(cairo_select_font_face, vFppii)
-GO(cairo_set_antialias, vFpi)
+GO(cairo_script_from_recording_surface, uFpp)
+GO(cairo_script_get_mode, uFp)
+GO(cairo_script_set_mode, vFpu)
+GO(cairo_script_surface_create, pFpudd)
+GO(cairo_script_surface_create_for_target, pFpp)
+GO(cairo_script_write_comment, vFppi)
+GO(cairo_select_font_face, vFppuu)
+GO(cairo_set_antialias, vFpu)
GO(cairo_set_dash, vFppid)
-GO(cairo_set_fill_rule, vFpi)
+GO(cairo_set_fill_rule, vFpu)
GO(cairo_set_font_face, vFpp)
GO(cairo_set_font_matrix, vFpp)
GO(cairo_set_font_options, vFpp)
GO(cairo_set_font_size, vFpd)
-GO(cairo_set_line_cap, vFpi)
-GO(cairo_set_line_join, vFpi)
+GO(cairo_set_line_cap, vFpu)
+GO(cairo_set_line_join, vFpu)
GO(cairo_set_line_width, vFpd)
GO(cairo_set_matrix, vFpp)
GO(cairo_set_miter_limit, vFpd)
-GO(cairo_set_operator, vFpi)
+GO(cairo_set_operator, vFpu)
GO(cairo_set_scaled_font, vFpp)
GO(cairo_set_source, vFpp)
GO(cairo_set_source_rgb, vFpddd)
@@ -290,21 +290,21 @@ GO(cairo_set_tolerance, vFpd)
GO(cairo_show_glyphs, vFppi)
GO(cairo_show_page, vFp)
GO(cairo_show_text, vFpp)
-GO(cairo_show_text_glyphs, vFppipipii)
-GO(cairo_status, iFp)
-//GO(cairo_status_to_string,
+GO(cairo_show_text_glyphs, vFppipipiu)
+GO(cairo_status, uFp)
+GO(cairo_status_to_string, pFu)
GO(cairo_stroke, vFp)
GO(cairo_stroke_extents, vFppppp)
GO(cairo_stroke_preserve, vFp)
GO(cairo_surface_copy_page, vFp)
GO(cairo_surface_create_for_rectangle, pFpdddd)
-//GO(cairo_surface_create_observer,
-GO(cairo_surface_create_similar, pFppii)
-GO(cairo_surface_create_similar_image, pFppii)
+GO(cairo_surface_create_observer, pFpu)
+GO(cairo_surface_create_similar, pFpuii)
+GO(cairo_surface_create_similar_image, pFpiii)
GO(cairo_surface_destroy, vFp)
GO(cairo_surface_finish, vFp)
GO(cairo_surface_flush, vFp)
-GO(cairo_surface_get_content, pFp)
+GO(cairo_surface_get_content, uFp)
GO(cairo_surface_get_device, pFp)
GO(cairo_surface_get_device_offset, vFppp)
GO(cairo_surface_get_device_scale, vFpp)
@@ -312,7 +312,7 @@ GO(cairo_surface_get_fallback_resolution, vFppp)
GO(cairo_surface_get_font_options, vFpp)
GO(cairo_surface_get_mime_data, vFpppp)
GO(cairo_surface_get_reference_count, uFp)
-GO(cairo_surface_get_type, iFp)
+GO(cairo_surface_get_type, uFp)
GO(cairo_surface_get_user_data, pFpp)
GO(cairo_surface_has_show_text_glyphs, iFp)
GO(cairo_surface_map_to_image, pFpp)
@@ -325,7 +325,7 @@ GO(cairo_surface_mark_dirty_rectangle, vFpiiii)
//GO(cairo_surface_observer_add_mask_callback,
//GO(cairo_surface_observer_add_paint_callback,
//GO(cairo_surface_observer_add_stroke_callback,
-//GO(cairo_surface_observer_elapsed,
+GO(cairo_surface_observer_elapsed, dFp)
//GO(cairo_surface_observer_print,
GO(cairo_surface_reference, pFp)
GO(cairo_surface_set_device_offset, vFpdd)
@@ -334,65 +334,65 @@ GO(cairo_surface_set_fallback_resolution, vFpdd)
//GOM(cairo_surface_set_mime_data, iFEpppLpp)
//GOM(cairo_surface_set_user_data, iFEpppp)
GO(cairo_surface_show_page, vFp)
-GO(cairo_surface_status, iFp)
+GO(cairo_surface_status, uFp)
GO(cairo_surface_supports_mime_type, iFpp)
GO(cairo_surface_unmap_image, vFpp)
-//GO(cairo_surface_write_to_png,
+GO(cairo_surface_write_to_png, uFpp)
//GO(cairo_surface_write_to_png_stream,
-//GO(cairo_svg_get_versions,
-//GO(cairo_svg_surface_create,
+GO(cairo_svg_get_versions, vFpp)
+GO(cairo_svg_surface_create, pFpdd)
//GO(cairo_svg_surface_create_for_stream,
-//GO(cairo_svg_surface_restrict_to_version,
-//GO(cairo_svg_version_to_string,
+GO(cairo_svg_surface_restrict_to_version, vFpu)
+GO(cairo_svg_version_to_string, pFu)
GO(cairo_text_cluster_allocate, pFi)
GO(cairo_text_cluster_free, vFp)
GO(cairo_text_extents, vFppp)
GO(cairo_text_path, vFpp)
-GO(cairo_toy_font_face_create, pFpii)
+GO(cairo_toy_font_face_create, pFpuu)
GO(cairo_toy_font_face_get_family, pFp)
-GO(cairo_toy_font_face_get_slant, iFp)
-GO(cairo_toy_font_face_get_weight, iFp)
+GO(cairo_toy_font_face_get_slant, uFp)
+GO(cairo_toy_font_face_get_weight, uFp)
GO(cairo_transform, vFpp)
GO(cairo_translate, vFpdd)
-//GO(cairo_user_font_face_create,
-//GO(cairo_user_font_face_get_init_func,
-//GO(cairo_user_font_face_get_render_glyph_func,
-//GO(cairo_user_font_face_get_text_to_glyphs_func,
-//GO(cairo_user_font_face_get_unicode_to_glyph_func,
+GO(cairo_user_font_face_create, pFv)
+GO(cairo_user_font_face_get_init_func, pFp)
+GO(cairo_user_font_face_get_render_glyph_func, pFp)
+GO(cairo_user_font_face_get_text_to_glyphs_func, pFp)
+GO(cairo_user_font_face_get_unicode_to_glyph_func, pFp)
//GO(cairo_user_font_face_set_init_func,
//GO(cairo_user_font_face_set_render_glyph_func,
//GO(cairo_user_font_face_set_text_to_glyphs_func,
//GO(cairo_user_font_face_set_unicode_to_glyph_func,
GO(cairo_user_to_device, vFppp)
GO(cairo_user_to_device_distance, vFppp)
-//GO(cairo_version,
-//GO(cairo_version_string,
-//GO(cairo_xcb_device_debug_cap_xrender_version,
+GO(cairo_version, iFv)
+GO(cairo_version_string, pFv)
+GO(cairo_xcb_device_debug_cap_xrender_version, vFpii)
//GO(cairo_xcb_device_debug_cap_xshm_version,
-//GO(cairo_xcb_device_debug_get_precision,
-//GO(cairo_xcb_device_debug_set_precision,
-//GO(cairo_xcb_device_get_connection,
-//GO(cairo_xcb_surface_create,
-//GO(cairo_xcb_surface_create_for_bitmap,
-//GO(cairo_xcb_surface_create_with_xrender_format,
-//GO(cairo_xcb_surface_set_drawable,
-//GO(cairo_xcb_surface_set_size,
-//GO(cairo_xlib_device_debug_cap_xrender_version,
-//GO(cairo_xlib_device_debug_get_precision,
-//GO(cairo_xlib_device_debug_set_precision,
+GO(cairo_xcb_device_debug_get_precision, iFp)
+GO(cairo_xcb_device_debug_set_precision, vFpi)
+GO(cairo_xcb_device_get_connection, pFp)
+GO(cairo_xcb_surface_create, pFpupii)
+GO(cairo_xcb_surface_create_for_bitmap, pFppuii)
+GO(cairo_xcb_surface_create_with_xrender_format, pFppupii)
+GO(cairo_xcb_surface_set_drawable, vFpuii)
+GO(cairo_xcb_surface_set_size, vFpii)
+GO(cairo_xlib_device_debug_cap_xrender_version, vFpii)
+GO(cairo_xlib_device_debug_get_precision, iFp)
+GO(cairo_xlib_device_debug_set_precision, vFpi)
//GO(cairo_xlib_surface_create,
-//GO(cairo_xlib_surface_create_for_bitmap,
-//GO(cairo_xlib_surface_create_with_xrender_format,
+GO(cairo_xlib_surface_create_for_bitmap, pFpLpii)
+GO(cairo_xlib_surface_create_with_xrender_format, pFpLppii)
//GO(cairo_xlib_surface_get_depth,
-//GO(cairo_xlib_surface_get_display,
-//GO(cairo_xlib_surface_get_drawable,
-//GO(cairo_xlib_surface_get_height,
-//GO(cairo_xlib_surface_get_screen,
+GO(cairo_xlib_surface_get_display, pFp)
+GO(cairo_xlib_surface_get_drawable, LFp)
+GO(cairo_xlib_surface_get_height, iFp)
+GO(cairo_xlib_surface_get_screen, pFp)
//GO(cairo_xlib_surface_get_visual,
//GO(cairo_xlib_surface_get_width,
-//GO(cairo_xlib_surface_get_xrender_format,
-//GO(cairo_xlib_surface_set_drawable,
-//GO(cairo_xlib_surface_set_size,
+GO(cairo_xlib_surface_get_xrender_format, pFp)
+GO(cairo_xlib_surface_set_drawable, vFpLii)
+GO(cairo_xlib_surface_set_size, vFpii)
//GO(cairo_xml_create,
//GO(cairo_xml_create_for_stream,
//GO(cairo_xml_for_recording_surface,
diff --git a/src/wrapped/wrappedcairogobject_private.h b/src/wrapped/wrappedcairogobject_private.h
index 57894ae..3224588 100644
--- a/src/wrapped/wrappedcairogobject_private.h
+++ b/src/wrapped/wrappedcairogobject_private.h
@@ -2,36 +2,36 @@
#error meh!
#endif
-GO(cairo_gobject_antialias_get_type, lFv)
-GO(cairo_gobject_content_get_type, lFv)
-GO(cairo_gobject_context_get_type, lFv)
-GO(cairo_gobject_device_get_type, lFv)
-GO(cairo_gobject_device_type_get_type, lFv)
-GO(cairo_gobject_extend_get_type, lFv)
-GO(cairo_gobject_fill_rule_get_type, lFv)
-GO(cairo_gobject_filter_get_type, lFv)
-GO(cairo_gobject_font_face_get_type, lFv)
-GO(cairo_gobject_font_options_get_type, lFv)
-GO(cairo_gobject_font_slant_get_type, lFv)
-GO(cairo_gobject_font_type_get_type, lFv)
-GO(cairo_gobject_font_weight_get_type, lFv)
-GO(cairo_gobject_format_get_type, lFv)
-GO(cairo_gobject_hint_metrics_get_type, lFv)
-GO(cairo_gobject_hint_style_get_type, lFv)
-GO(cairo_gobject_line_cap_get_type, lFv)
-GO(cairo_gobject_line_join_get_type, lFv)
-GO(cairo_gobject_matrix_get_type, lFv)
-GO(cairo_gobject_operator_get_type, lFv)
-GO(cairo_gobject_path_data_type_get_type, lFv)
-GO(cairo_gobject_pattern_get_type, lFv)
-GO(cairo_gobject_pattern_type_get_type, lFv)
-GO(cairo_gobject_rectangle_get_type, lFv)
-GO(cairo_gobject_rectangle_int_get_type, lFv)
-GO(cairo_gobject_region_get_type, lFv)
-GO(cairo_gobject_region_overlap_get_type, lFv)
-GO(cairo_gobject_scaled_font_get_type, lFv)
-GO(cairo_gobject_status_get_type, lFv)
-GO(cairo_gobject_subpixel_order_get_type, lFv)
-GO(cairo_gobject_surface_get_type, lFv)
-GO(cairo_gobject_surface_type_get_type, lFv)
-GO(cairo_gobject_text_cluster_flags_get_type, lFv)
+GO(cairo_gobject_antialias_get_type, LFv)
+GO(cairo_gobject_content_get_type, LFv)
+GO(cairo_gobject_context_get_type, LFv)
+GO(cairo_gobject_device_get_type, LFv)
+GO(cairo_gobject_device_type_get_type, LFv)
+GO(cairo_gobject_extend_get_type, LFv)
+GO(cairo_gobject_fill_rule_get_type, LFv)
+GO(cairo_gobject_filter_get_type, LFv)
+GO(cairo_gobject_font_face_get_type, LFv)
+GO(cairo_gobject_font_options_get_type, LFv)
+GO(cairo_gobject_font_slant_get_type, LFv)
+GO(cairo_gobject_font_type_get_type, LFv)
+GO(cairo_gobject_font_weight_get_type, LFv)
+GO(cairo_gobject_format_get_type, LFv)
+GO(cairo_gobject_hint_metrics_get_type, LFv)
+GO(cairo_gobject_hint_style_get_type, LFv)
+GO(cairo_gobject_line_cap_get_type, LFv)
+GO(cairo_gobject_line_join_get_type, LFv)
+GO(cairo_gobject_matrix_get_type, LFv)
+GO(cairo_gobject_operator_get_type, LFv)
+GO(cairo_gobject_path_data_type_get_type, LFv)
+GO(cairo_gobject_pattern_get_type, LFv)
+GO(cairo_gobject_pattern_type_get_type, LFv)
+GO(cairo_gobject_rectangle_get_type, LFv)
+GO(cairo_gobject_rectangle_int_get_type, LFv)
+GO(cairo_gobject_region_get_type, LFv)
+GO(cairo_gobject_region_overlap_get_type, LFv)
+GO(cairo_gobject_scaled_font_get_type, LFv)
+GO(cairo_gobject_status_get_type, LFv)
+GO(cairo_gobject_subpixel_order_get_type, LFv)
+GO(cairo_gobject_surface_get_type, LFv)
+GO(cairo_gobject_surface_type_get_type, LFv)
+GO(cairo_gobject_text_cluster_flags_get_type, LFv)
diff --git a/src/wrapped/wrappedcap.c b/src/wrapped/wrappedcap.c
new file mode 100644
index 0000000..a7a3686
--- /dev/null
+++ b/src/wrapped/wrappedcap.c
@@ -0,0 +1,18 @@
+#define _GNU_SOURCE /* See feature_test_macros(7) */
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <dlfcn.h>
+
+#include "wrappedlibs.h"
+
+#include "wrapper.h"
+#include "bridge.h"
+#include "librarian/library_private.h"
+#include "x64emu.h"
+
+const char* capName = "libcap.so.2";
+#define LIBNAME cap
+
+#include "wrappedlib_init.h"
+
diff --git a/src/wrapped/wrappedcap_private.h b/src/wrapped/wrappedcap_private.h
new file mode 100644
index 0000000..c523ad6
--- /dev/null
+++ b/src/wrapped/wrappedcap_private.h
@@ -0,0 +1,62 @@
+#if !(defined(GO) && defined(GOM) && defined(GO2) && defined(DATA))
+#error Meh....
+#endif
+
+//GO(cap_clear,
+//GO(cap_clear_flag,
+//GO(cap_compare,
+//GO(cap_copy_ext,
+//GO(cap_copy_int,
+//GO(cap_drop_bound,
+//GO(cap_dup,
+//GO(cap_free,
+//GO(cap_from_name,
+//GO(cap_from_text,
+//GO(cap_get_ambient,
+//GO(cap_get_bound,
+//GO(cap_get_fd,
+//GO(cap_get_file,
+//GO(cap_get_flag,
+//GO(cap_get_mode,
+//GO(cap_get_nsowner,
+//GO(capgetp,
+//GO(cap_get_pid,
+//GO(cap_get_proc,
+//GO(cap_get_secbits,
+//GO(cap_iab_fill,
+//GO(cap_iab_from_text,
+//GO(cap_iab_get_proc,
+//GO(cap_iab_get_vector,
+//GO(cap_iab_init,
+//GO(cap_iab_set_proc,
+//GO(cap_iab_set_vector,
+//GO(cap_iab_to_text,
+//GO(cap_init,
+//GO(cap_launch,
+//GO(cap_launcher_callback,
+//GO(cap_launcher_set_chroot,
+//GO(cap_launcher_setgroups,
+//GO(cap_launcher_set_iab,
+//GO(cap_launcher_set_mode,
+//GO(cap_launcher_setuid,
+//GO(cap_max_bits,
+//GO(cap_mode_name,
+//GO(cap_new_launcher,
+//GO(cap_reset_ambient,
+//GO(cap_set_ambient,
+//GO(cap_set_fd,
+//GO(cap_set_file,
+//GO(cap_set_flag,
+//GO(cap_setgroups,
+//GO(cap_set_mode,
+//GO(cap_set_nsowner,
+//GO(capsetp,
+//GO(cap_set_proc,
+//GO(cap_set_secbits,
+//GO(cap_set_syscall,
+//GO(cap_setuid,
+//GO(cap_size,
+//GO(cap_to_name,
+//GO(cap_to_text,
+//GO(_libcap_strdup,
+//GOW(psx_load_syscalls,
diff --git a/src/wrapped/wrappedcrashhandler.c b/src/wrapped/wrappedcrashhandler.c
index fe0840b..fe0840b 100755..100644
--- a/src/wrapped/wrappedcrashhandler.c
+++ b/src/wrapped/wrappedcrashhandler.c
diff --git a/src/wrapped/wrappedcrashhandler_private.h b/src/wrapped/wrappedcrashhandler_private.h
index 52ed57d..52ed57d 100755..100644
--- a/src/wrapped/wrappedcrashhandler_private.h
+++ b/src/wrapped/wrappedcrashhandler_private.h
diff --git a/src/wrapped/wrappedcrypto.c b/src/wrapped/wrappedcrypto.c
index 21941bb..d768555 100755..100644
--- a/src/wrapped/wrappedcrypto.c
+++ b/src/wrapped/wrappedcrypto.c
@@ -35,12 +35,180 @@ GO(2) \
GO(3) \
GO(4)
+// BIO_meth_set_write
+#define GO(A) \
+static uintptr_t my_BIO_meth_set_write_fct_##A = 0; \
+static int my_BIO_meth_set_write_##A(void* a, void* b, int c) \
+{ \
+ return (int)RunFunctionFmt(my_BIO_meth_set_write_fct_##A, "ppi", a, b, c); \
+}
+SUPER()
+#undef GO
+static void* find_BIO_meth_set_write_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my_BIO_meth_set_write_fct_##A == (uintptr_t)fct) return my_BIO_meth_set_write_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_BIO_meth_set_write_fct_##A == 0) {my_BIO_meth_set_write_fct_##A = (uintptr_t)fct; return my_BIO_meth_set_write_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libcrypto BIO_meth_set_write callback\n");
+ return NULL;
+}
+
+// BIO_meth_set_read
+#define GO(A) \
+static uintptr_t my_BIO_meth_set_read_fct_##A = 0; \
+static int my_BIO_meth_set_read_##A(void* a, void* b, int c)\
+{ \
+ return (int)RunFunctionFmt(my_BIO_meth_set_read_fct_##A, "ppi", a, b, c); \
+}
+SUPER()
+#undef GO
+static void* find_BIO_meth_set_read_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my_BIO_meth_set_read_fct_##A == (uintptr_t)fct) return my_BIO_meth_set_read_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_BIO_meth_set_read_fct_##A == 0) {my_BIO_meth_set_read_fct_##A = (uintptr_t)fct; return my_BIO_meth_set_read_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libcrypto BIO_meth_set_read callback\n");
+ return NULL;
+}
+
+// BIO_meth_set_puts
+#define GO(A) \
+static uintptr_t my_BIO_meth_set_puts_fct_##A = 0; \
+static int my_BIO_meth_set_puts_##A(void* a, void* b) \
+{ \
+ return (int)RunFunctionFmt(my_BIO_meth_set_puts_fct_##A, "pp", a, b); \
+}
+SUPER()
+#undef GO
+static void* find_BIO_meth_set_puts_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my_BIO_meth_set_puts_fct_##A == (uintptr_t)fct) return my_BIO_meth_set_puts_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_BIO_meth_set_puts_fct_##A == 0) {my_BIO_meth_set_puts_fct_##A = (uintptr_t)fct; return my_BIO_meth_set_puts_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libcrypto BIO_meth_set_puts callback\n");
+ return NULL;
+}
+
+// BIO_meth_set_gets
+#define GO(A) \
+static uintptr_t my_BIO_meth_set_gets_fct_##A = 0; \
+static int my_BIO_meth_set_gets_##A(void* a, void* b, int c)\
+{ \
+ return (int)RunFunctionFmt(my_BIO_meth_set_gets_fct_##A, "ppi", a, b, c); \
+}
+SUPER()
+#undef GO
+static void* find_BIO_meth_set_gets_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my_BIO_meth_set_gets_fct_##A == (uintptr_t)fct) return my_BIO_meth_set_gets_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_BIO_meth_set_gets_fct_##A == 0) {my_BIO_meth_set_gets_fct_##A = (uintptr_t)fct; return my_BIO_meth_set_gets_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libcrypto BIO_meth_set_gets callback\n");
+ return NULL;
+}
+
+// BIO_meth_set_ctrl
+#define GO(A) \
+static uintptr_t my_BIO_meth_set_ctrl_fct_##A = 0; \
+static long my_BIO_meth_set_ctrl_##A(void* a, int b, long c, void* d) \
+{ \
+ return (long)RunFunctionFmt(my_BIO_meth_set_ctrl_fct_##A, "pilp", a, b, c, d); \
+}
+SUPER()
+#undef GO
+static void* find_BIO_meth_set_ctrl_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my_BIO_meth_set_ctrl_fct_##A == (uintptr_t)fct) return my_BIO_meth_set_ctrl_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_BIO_meth_set_ctrl_fct_##A == 0) {my_BIO_meth_set_ctrl_fct_##A = (uintptr_t)fct; return my_BIO_meth_set_ctrl_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libcrypto BIO_meth_set_ctrl callback\n");
+ return NULL;
+}
+
+// BIO_meth_set_create
+#define GO(A) \
+static uintptr_t my_BIO_meth_set_create_fct_##A = 0;\
+static int my_BIO_meth_set_create_##A(void* a) \
+{ \
+ return (int)RunFunctionFmt(my_BIO_meth_set_create_fct_##A, "p", a); \
+}
+SUPER()
+#undef GO
+static void* find_BIO_meth_set_create_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my_BIO_meth_set_create_fct_##A == (uintptr_t)fct) return my_BIO_meth_set_create_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_BIO_meth_set_create_fct_##A == 0) {my_BIO_meth_set_create_fct_##A = (uintptr_t)fct; return my_BIO_meth_set_create_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libcrypto BIO_meth_set_create callback\n");
+ return NULL;
+}
+
+// BIO_meth_set_destroy
+#define GO(A) \
+static uintptr_t my_BIO_meth_set_destroy_fct_##A = 0; \
+static int my_BIO_meth_set_destroy_##A(void* a) \
+{ \
+ return (int)RunFunctionFmt(my_BIO_meth_set_destroy_fct_##A, "p", a);\
+}
+SUPER()
+#undef GO
+static void* find_BIO_meth_set_destroy_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my_BIO_meth_set_destroy_fct_##A == (uintptr_t)fct) return my_BIO_meth_set_destroy_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_BIO_meth_set_destroy_fct_##A == 0) {my_BIO_meth_set_destroy_fct_##A = (uintptr_t)fct; return my_BIO_meth_set_destroy_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libcrypto BIO_meth_set_destroy callback\n");
+ return NULL;
+}
+
// ENGINE_ctrl_cb
#define GO(A) \
-static uintptr_t my_ENGINE_ctrl_cb_fct_##A = 0; \
-static void my_ENGINE_ctrl_cb_##A() \
-{ \
- RunFunction(my_context, my_ENGINE_ctrl_cb_fct_##A, 0); \
+static uintptr_t my_ENGINE_ctrl_cb_fct_##A = 0; \
+static void my_ENGINE_ctrl_cb_##A() \
+{ \
+ RunFunctionFmt(my_ENGINE_ctrl_cb_fct_##A, ""); \
}
SUPER()
#undef GO
@@ -64,7 +232,7 @@ static void* find_ENGINE_ctrl_cb_Fct(void* fct)
static uintptr_t my_cmp_fnc_fct_##A = 0; \
static int my_cmp_fnc_##A(void* a, void* b) \
{ \
- return (int)RunFunction(my_context, my_cmp_fnc_fct_##A, 2, a, b); \
+ return (int)RunFunctionFmt(my_cmp_fnc_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -88,7 +256,7 @@ static void* find_cmp_fnc_Fct(void* fct)
static uintptr_t my_free_fnc_fct_##A = 0; \
static void my_free_fnc_##A(void* p) \
{ \
- RunFunction(my_context, my_free_fnc_fct_##A, 1, p); \
+ RunFunctionFmt(my_free_fnc_fct_##A, "p", p); \
}
SUPER()
#undef GO
@@ -112,7 +280,7 @@ static void* find_free_fnc_Fct(void* fct)
static uintptr_t my_id_func_fct_##A = 0; \
static unsigned long my_id_func_##A() \
{ \
- return (unsigned long)RunFunction(my_context, my_id_func_fct_##A, 0); \
+ return (unsigned long)RunFunctionFmt(my_id_func_fct_##A, ""); \
}
SUPER()
#undef GO
@@ -136,7 +304,7 @@ static void* find_id_func_Fct(void* fct)
static uintptr_t my_lock_func_fct_##A = 0; \
static void my_lock_func_##A(int mode, int n, void* f, int l) \
{ \
- RunFunction(my_context, my_lock_func_fct_##A, 4, mode, n, f, l); \
+ RunFunctionFmt(my_lock_func_fct_##A, "iipi", mode, n, f, l); \
}
SUPER()
#undef GO
@@ -160,7 +328,7 @@ static void* find_lock_func_Fct(void* fct)
static uintptr_t my_passphrase_fct_##A = 0; \
static int my_passphrase_##A(void* buff, int size, int rw, void* u) \
{ \
- return (int)RunFunction(my_context, my_passphrase_fct_##A, 4, buff, size, rw, u); \
+ return (int)RunFunctionFmt(my_passphrase_fct_##A, "piip", buff, size, rw, u); \
}
SUPER()
#undef GO
@@ -184,7 +352,7 @@ static void* find_passphrase_Fct(void* fct)
static uintptr_t my_xnew_fct_##A = 0; \
static void* my_xnew_##A() \
{ \
- return (void*)RunFunction(my_context, my_xnew_fct_##A, 0); \
+ return (void*)RunFunctionFmt(my_xnew_fct_##A, ""); \
}
SUPER()
#undef GO
@@ -208,7 +376,7 @@ static void* find_xnew_Fct(void* fct)
static uintptr_t my_d2i_fct_##A = 0; \
static void* my_d2i_##A() \
{ \
- return (void*)RunFunction(my_context, my_d2i_fct_##A, 0); \
+ return (void*)RunFunctionFmt(my_d2i_fct_##A, ""); \
}
SUPER()
#undef GO
@@ -232,7 +400,7 @@ static void* find_d2i_Fct(void* fct)
static uintptr_t my_i2d_fct_##A = 0; \
static int my_i2d_##A() \
{ \
- return (int)RunFunction(my_context, my_i2d_fct_##A, 0); \
+ return (int)RunFunctionFmt(my_i2d_fct_##A, ""); \
}
SUPER()
#undef GO
@@ -256,7 +424,7 @@ static void* find_i2d_Fct(void* fct)
static uintptr_t my_pem_password_cb_fct_##A = 0; \
static int my_pem_password_cb_##A(void* a, int b, int c, void* d) \
{ \
- return (int)RunFunction(my_context, my_pem_password_cb_fct_##A, 4, a, b, c, d); \
+ return (int)RunFunctionFmt(my_pem_password_cb_fct_##A, "piip", a, b, c, d); \
}
SUPER()
#undef GO
@@ -275,12 +443,37 @@ static void* find_pem_password_cb_Fct(void* fct)
return NULL;
}
+// ctx_verify_cb
+#define GO(A) \
+static uintptr_t my_ctx_verify_cb_fct_##A = 0; \
+static int my_ctx_verify_cb_##A(int a, void* b) \
+{ \
+ return (int)RunFunctionFmt(my_ctx_verify_cb_fct_##A, "ip", a, b); \
+}
+SUPER()
+#undef GO
+static void* find_ctx_verify_cb_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my_ctx_verify_cb_fct_##A == (uintptr_t)fct) return my_ctx_verify_cb_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_ctx_verify_cb_fct_##A == 0) {my_ctx_verify_cb_fct_##A = (uintptr_t)fct; return my_ctx_verify_cb_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libcrypto ctx_verify_cb callback\n");
+ return NULL;
+}
+
+
// verify_cb
#define GO(A) \
static uintptr_t my_verify_cb_fct_##A = 0; \
static int my_verify_cb_##A(int a, void* b) \
{ \
- return (int)RunFunction(my_context, my_verify_cb_fct_##A, 2, a, b); \
+ return (int)RunFunctionFmt(my_verify_cb_fct_##A, "ip", a, b); \
}
SUPER()
#undef GO
@@ -301,6 +494,42 @@ static void* find_verify_cb_Fct(void* fct)
#undef SUPER
+EXPORT int32_t my_BIO_meth_set_write(x64emu_t* emu, void* biom, void* cb)
+{
+ (void)emu;
+ return my->BIO_meth_set_write(biom, find_BIO_meth_set_write_Fct(cb));
+}
+EXPORT int32_t my_BIO_meth_set_read(x64emu_t* emu, void* biom, void* cb)
+{
+ (void)emu;
+ return my->BIO_meth_set_read(biom, find_BIO_meth_set_read_Fct(cb));
+}
+EXPORT int32_t my_BIO_meth_set_puts(x64emu_t* emu, void* biom, void* cb)
+{
+ (void)emu;
+ return my->BIO_meth_set_puts(biom, find_BIO_meth_set_puts_Fct(cb));
+}
+EXPORT int32_t my_BIO_meth_set_gets(x64emu_t* emu, void* biom, void* cb)
+{
+ (void)emu;
+ return my->BIO_meth_set_gets(biom, find_BIO_meth_set_gets_Fct(cb));
+}
+EXPORT int32_t my_BIO_meth_set_ctrl(x64emu_t* emu, void* biom, void* cb)
+{
+ (void)emu;
+ return my->BIO_meth_set_ctrl(biom, find_BIO_meth_set_ctrl_Fct(cb));
+}
+EXPORT int32_t my_BIO_meth_set_create(x64emu_t* emu, void* biom, void* cb)
+{
+ (void)emu;
+ return my->BIO_meth_set_create(biom, find_BIO_meth_set_create_Fct(cb));
+}
+EXPORT int32_t my_BIO_meth_set_destroy(x64emu_t* emu, void* biom, void* cb)
+{
+ (void)emu;
+ return my->BIO_meth_set_destroy(biom, find_BIO_meth_set_destroy_Fct(cb));
+}
+
EXPORT int32_t my_ENGINE_ctrl(x64emu_t* emu, void* e, int32_t cmd, int32_t i, void* p, void* f)
{
(void)emu;
@@ -373,6 +602,13 @@ EXPORT int my_PEM_write_bio_RSAPrivateKey(x64emu_t* emu, void* bp, void* x, void
return my->PEM_write_bio_RSAPrivateKey(bp, x, e, str, len, find_passphrase_Fct(cb), u);
}
+
+EXPORT int my_PEM_write_bio_PrivateKey(x64emu_t* emu, void* bp, void* x, void* e, void* str, int len, void* cb, void* u)
+{
+ (void)emu;
+ return my->PEM_write_bio_PrivateKey(bp, x, e, str, len, find_passphrase_Fct(cb), u);
+}
+
EXPORT int my_PEM_write_bio_ECPrivateKey(x64emu_t* emu, void* bp, void* x, void* e, void* str, int len, void* cb, void* u)
{
(void)emu;
@@ -409,6 +645,25 @@ EXPORT void* my_PEM_read_bio_PKCS7(x64emu_t* emu, void* bp, void* x, void* cb, v
return my->PEM_read_bio_PKCS7(bp, x, find_pem_password_cb_Fct(cb), u);
}
+EXPORT void* my_PEM_read_bio_PrivateKey(x64emu_t* emu, void* bp, void* x, void* cb, void* u)
+{
+ (void)emu;
+ return my->PEM_read_bio_PrivateKey(bp, x, find_pem_password_cb_Fct(cb), u);
+}
+
+
+EXPORT void* my_PEM_read_bio_PUBKEY(x64emu_t* emu, void* bp, void* x, void* cb, void* u)
+{
+ (void)emu;
+ return my->PEM_read_bio_PUBKEY(bp, x, find_pem_password_cb_Fct(cb), u);
+}
+
+EXPORT void* my_PEM_read_bio_DHparams(x64emu_t* emu, void* bp, void* x, void* cb, void* u)
+{
+ (void)emu;
+ return my->PEM_read_bio_DHparams(bp, x, find_pem_password_cb_Fct(cb), u);
+}
+
EXPORT void* my_PEM_read_bio_X509(x64emu_t* emu, void* bp, void* x, void* cb, void* u)
{
(void)emu;
@@ -442,7 +697,14 @@ EXPORT void* my_PEM_read_bio_X509_CERT_PAIR(x64emu_t* emu, void* bp, void* x, vo
EXPORT void my_X509_STORE_CTX_set_verify_cb(x64emu_t* emu, void* ctx, void* cb)
{
(void)emu;
- my->X509_STORE_CTX_set_verify_cb(ctx, find_verify_cb_Fct(cb));
+ my->X509_STORE_CTX_set_verify_cb(ctx, find_ctx_verify_cb_Fct(cb));
+}
+
+
+EXPORT void my_X509_STORE_set_verify_cb(x64emu_t* emu, void* ctx, void* cb)
+{
+ (void)emu;
+ my->X509_STORE_set_verify_cb(ctx, find_verify_cb_Fct(cb));
}
EXPORT void my_OPENSSL_sk_pop_free(x64emu_t* emu, void* s, void* cb)
diff --git a/src/wrapped/wrappedcrypto3.c b/src/wrapped/wrappedcrypto3.c
new file mode 100644
index 0000000..a6317af
--- /dev/null
+++ b/src/wrapped/wrappedcrypto3.c
@@ -0,0 +1,466 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#define _GNU_SOURCE /* See feature_test_macros(7) */
+#include <dlfcn.h>
+
+#include "wrappedlibs.h"
+
+#include "debug.h"
+#include "wrapper.h"
+#include "bridge.h"
+#include "librarian/library_private.h"
+#include "x64emu.h"
+#include "emu/x64emu_private.h"
+#include "callback.h"
+#include "librarian.h"
+#include "box64context.h"
+#include "emu/x64emu_private.h"
+#include "callback.h"
+#include "myalign.h"
+
+const char* crypto3Name = "libcrypto.so.3";
+#define LIBNAME crypto3
+
+#include "generated/wrappedcrypto3types.h"
+
+#include "wrappercallback.h"
+
+// utility functions
+#define SUPER() \
+GO(0) \
+GO(1) \
+GO(2) \
+GO(3) \
+GO(4)
+
+// ENGINE_ctrl_cb
+#define GO(A) \
+static uintptr_t my3_ENGINE_ctrl_cb_fct_##A = 0; \
+static void my3_ENGINE_ctrl_cb_##A() \
+{ \
+ RunFunctionFmt(my3_ENGINE_ctrl_cb_fct_##A, ""); \
+}
+SUPER()
+#undef GO
+static void* find_ENGINE_ctrl_cb_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my3_ENGINE_ctrl_cb_fct_##A == (uintptr_t)fct) return my3_ENGINE_ctrl_cb_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my3_ENGINE_ctrl_cb_fct_##A == 0) {my3_ENGINE_ctrl_cb_fct_##A = (uintptr_t)fct; return my3_ENGINE_ctrl_cb_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libcrypto ENGINE_ctrl_cb callback\n");
+ return NULL;
+}
+
+// cmp_fnc
+#define GO(A) \
+static uintptr_t my3_cmp_fnc_fct_##A = 0; \
+static int my3_cmp_fnc_##A(void* a, void* b) \
+{ \
+ return (int)RunFunctionFmt(my3_cmp_fnc_fct_##A, "pp", a, b); \
+}
+SUPER()
+#undef GO
+static void* find_cmp_fnc_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my3_cmp_fnc_fct_##A == (uintptr_t)fct) return my3_cmp_fnc_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my3_cmp_fnc_fct_##A == 0) {my3_cmp_fnc_fct_##A = (uintptr_t)fct; return my3_cmp_fnc_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libcrypto cmp_fnc callback\n");
+ return NULL;
+}
+
+// free_fnc
+#define GO(A) \
+static uintptr_t my3_free_fnc_fct_##A = 0; \
+static void my3_free_fnc_##A(void* p) \
+{ \
+ RunFunctionFmt(my3_free_fnc_fct_##A, "p", p); \
+}
+SUPER()
+#undef GO
+static void* find_free_fnc_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my3_free_fnc_fct_##A == (uintptr_t)fct) return my3_free_fnc_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my3_free_fnc_fct_##A == 0) {my3_free_fnc_fct_##A = (uintptr_t)fct; return my3_free_fnc_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libcrypto free_fnc callback\n");
+ return NULL;
+}
+
+// id_func
+#define GO(A) \
+static uintptr_t my3_id_func_fct_##A = 0; \
+static unsigned long my3_id_func_##A() \
+{ \
+ return (unsigned long)RunFunctionFmt(my3_id_func_fct_##A, ""); \
+}
+SUPER()
+#undef GO
+static void* find_id_func_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my3_id_func_fct_##A == (uintptr_t)fct) return my3_id_func_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my3_id_func_fct_##A == 0) {my3_id_func_fct_##A = (uintptr_t)fct; return my3_id_func_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libcrypto id_func callback\n");
+ return NULL;
+}
+
+// lock_func
+#define GO(A) \
+static uintptr_t my3_lock_func_fct_##A = 0; \
+static void my3_lock_func_##A(int mode, int n, void* f, int l) \
+{ \
+ RunFunctionFmt(my3_lock_func_fct_##A, "iipi", mode, n, f, l); \
+}
+SUPER()
+#undef GO
+static void* find_lock_func_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my3_lock_func_fct_##A == (uintptr_t)fct) return my3_lock_func_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my3_lock_func_fct_##A == 0) {my3_lock_func_fct_##A = (uintptr_t)fct; return my3_lock_func_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libcrypto lock_func callback\n");
+ return NULL;
+}
+
+// passphrase
+#define GO(A) \
+static uintptr_t my3_passphrase_fct_##A = 0; \
+static int my3_passphrase_##A(void* buff, int size, int rw, void* u) \
+{ \
+ return (int)RunFunctionFmt(my3_passphrase_fct_##A, "piip", buff, size, rw, u); \
+}
+SUPER()
+#undef GO
+static void* find_passphrase_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my3_passphrase_fct_##A == (uintptr_t)fct) return my3_passphrase_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my3_passphrase_fct_##A == 0) {my3_passphrase_fct_##A = (uintptr_t)fct; return my3_passphrase_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libcrypto passphrase callback\n");
+ return NULL;
+}
+
+// xnew
+#define GO(A) \
+static uintptr_t my3_xnew_fct_##A = 0; \
+static void* my3_xnew_##A() \
+{ \
+ return (void*)RunFunctionFmt(my3_xnew_fct_##A, ""); \
+}
+SUPER()
+#undef GO
+static void* find_xnew_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my3_xnew_fct_##A == (uintptr_t)fct) return my3_xnew_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my3_xnew_fct_##A == 0) {my3_xnew_fct_##A = (uintptr_t)fct; return my3_xnew_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libcrypto xnew callback\n");
+ return NULL;
+}
+
+// d2i
+#define GO(A) \
+static uintptr_t my3_d2i_fct_##A = 0; \
+static void* my3_d2i_##A() \
+{ \
+ return (void*)RunFunctionFmt(my3_d2i_fct_##A, ""); \
+}
+SUPER()
+#undef GO
+static void* find_d2i_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my3_d2i_fct_##A == (uintptr_t)fct) return my3_d2i_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my3_d2i_fct_##A == 0) {my3_d2i_fct_##A = (uintptr_t)fct; return my3_d2i_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libcrypto d2i callback\n");
+ return NULL;
+}
+
+// i2d
+#define GO(A) \
+static uintptr_t my3_i2d_fct_##A = 0; \
+static int my3_i2d_##A() \
+{ \
+ return (int)RunFunctionFmt(my3_i2d_fct_##A, ""); \
+}
+SUPER()
+#undef GO
+static void* find_i2d_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my3_i2d_fct_##A == (uintptr_t)fct) return my3_i2d_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my3_i2d_fct_##A == 0) {my3_i2d_fct_##A = (uintptr_t)fct; return my3_i2d_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libcrypto i2d callback\n");
+ return NULL;
+}
+
+// pem_password_cb
+#define GO(A) \
+static uintptr_t my3_pem_password_cb_fct_##A = 0; \
+static int my3_pem_password_cb_##A(void* a, int b, int c, void* d) \
+{ \
+ return (int)RunFunctionFmt(my3_pem_password_cb_fct_##A, "piip", a, b, c, d); \
+}
+SUPER()
+#undef GO
+static void* find_pem_password_cb_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my3_pem_password_cb_fct_##A == (uintptr_t)fct) return my3_pem_password_cb_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my3_pem_password_cb_fct_##A == 0) {my3_pem_password_cb_fct_##A = (uintptr_t)fct; return my3_pem_password_cb_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libcrypto pem_password_cb callback\n");
+ return NULL;
+}
+
+// verify_cb
+#define GO(A) \
+static uintptr_t my3_verify_cb_fct_##A = 0; \
+static int my3_verify_cb_##A(int a, void* b) \
+{ \
+ return (int)RunFunctionFmt(my3_verify_cb_fct_##A, "ip", a, b); \
+}
+SUPER()
+#undef GO
+static void* find_verify_cb_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my3_verify_cb_fct_##A == (uintptr_t)fct) return my3_verify_cb_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my3_verify_cb_fct_##A == 0) {my3_verify_cb_fct_##A = (uintptr_t)fct; return my3_verify_cb_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libcrypto verify_cb callback\n");
+ return NULL;
+}
+
+#undef SUPER
+
+EXPORT int32_t my3_ENGINE_ctrl(x64emu_t* emu, void* e, int32_t cmd, int32_t i, void* p, void* f)
+{
+ (void)emu;
+ return my->ENGINE_ctrl(e, cmd, i, p, find_ENGINE_ctrl_cb_Fct(f));
+}
+
+EXPORT int32_t my3_ENGINE_ctrl_cmd(x64emu_t* emu, void* e, void* cmd, long i, void* p, void* f, int optional)
+{
+ (void)emu;
+ return my->ENGINE_ctrl_cmd(e, cmd, i, p, find_ENGINE_ctrl_cb_Fct(f), optional);
+}
+
+EXPORT void my3_CRYPTO_set_id_callback(x64emu_t* emu, void* cb)
+{
+ (void)emu;
+ my->CRYPTO_set_id_callback(find_id_func_Fct(cb));
+}
+
+EXPORT void my3_CRYPTO_set_locking_callback(x64emu_t* emu, void* cb)
+{
+ (void)emu;
+ my->CRYPTO_set_locking_callback(find_lock_func_Fct(cb));
+}
+
+EXPORT void my3_PEM_read_bio_DSAPrivateKey(x64emu_t* emu, void* bp, void* x, void* cb, void* u)
+{
+ (void)emu;
+ my->PEM_read_bio_DSAPrivateKey(bp, x, find_passphrase_Fct(cb), u);
+}
+
+EXPORT void my3_PEM_read_bio_DSA_PUBKEY(x64emu_t* emu, void* bp, void* x, void* cb, void* u)
+{
+ (void)emu;
+ my->PEM_read_bio_DSA_PUBKEY(bp, x, find_passphrase_Fct(cb), u);
+}
+
+EXPORT void my3_PEM_read_bio_RSAPrivateKey(x64emu_t* emu, void* bp, void* x, void* cb, void* u)
+{
+ (void)emu;
+ my->PEM_read_bio_RSAPrivateKey(bp, x, find_passphrase_Fct(cb), u);
+}
+
+EXPORT void my3_PEM_read_bio_RSA_PUBKEY(x64emu_t* emu, void* bp, void* x, void* cb, void* u)
+{
+ (void)emu;
+ my->PEM_read_bio_RSA_PUBKEY(bp, x, find_passphrase_Fct(cb), u);
+}
+
+EXPORT void my3_PEM_read_bio_ECPrivateKey(x64emu_t* emu, void* bp, void* x, void* cb, void* u)
+{
+ (void)emu;
+ my->PEM_read_bio_ECPrivateKey(bp, x, find_passphrase_Fct(cb), u);
+}
+
+EXPORT void my3_PEM_read_bio_EC_PUBKEY(x64emu_t* emu, void* bp, void* x, void* cb, void* u)
+{
+ (void)emu;
+ my->PEM_read_bio_EC_PUBKEY(bp, x, find_passphrase_Fct(cb), u);
+}
+
+EXPORT int my3_PEM_write_bio_DSAPrivateKey(x64emu_t* emu, void* bp, void* x, void* e, void* str, int len, void* cb, void* u)
+{
+ (void)emu;
+ return my->PEM_write_bio_DSAPrivateKey(bp, x, e, str, len, find_passphrase_Fct(cb), u);
+}
+
+EXPORT int my3_PEM_write_bio_RSAPrivateKey(x64emu_t* emu, void* bp, void* x, void* e, void* str, int len, void* cb, void* u)
+{
+ (void)emu;
+ return my->PEM_write_bio_RSAPrivateKey(bp, x, e, str, len, find_passphrase_Fct(cb), u);
+}
+
+EXPORT int my3_PEM_write_bio_ECPrivateKey(x64emu_t* emu, void* bp, void* x, void* e, void* str, int len, void* cb, void* u)
+{
+ (void)emu;
+ return my->PEM_write_bio_ECPrivateKey(bp, x, e, str, len, find_passphrase_Fct(cb), u);
+}
+
+EXPORT void* my3_ASN1_d2i_bio(x64emu_t* emu, void* xnew, void* d2i, void* bp, void* x)
+{
+ (void)emu;
+ return my->ASN1_d2i_bio(find_xnew_Fct(xnew), find_d2i_Fct(d2i), bp, x);
+}
+
+EXPORT int my3_ASN1_i2d_bio(x64emu_t* emu, void* i2d, void* bp, void* x)
+{
+ (void)emu;
+ return my->ASN1_i2d_bio(find_i2d_Fct(i2d), bp, x);
+}
+
+EXPORT void* my3_PEM_read_bio_PKCS7(x64emu_t* emu, void* bp, void* x, void* cb, void* u)
+{
+ (void)emu;
+ return my->PEM_read_bio_PKCS7(bp, x, find_pem_password_cb_Fct(cb), u);
+}
+
+EXPORT void* my3_PEM_read_bio_X509(x64emu_t* emu, void* bp, void* x, void* cb, void* u)
+{
+ (void)emu;
+ return my->PEM_read_bio_X509(bp, x, find_pem_password_cb_Fct(cb), u);
+}
+
+EXPORT void* my3_PEM_read_bio_X509_AUX(x64emu_t* emu, void* bp, void* x, void* cb, void* u)
+{
+ (void)emu;
+ return my->PEM_read_bio_X509_AUX(bp, x, find_pem_password_cb_Fct(cb), u);
+}
+
+EXPORT void* my3_PEM_read_bio_X509_CRL(x64emu_t* emu, void* bp, void* x, void* cb, void* u)
+{
+ (void)emu;
+ return my->PEM_read_bio_X509_CRL(bp, x, find_pem_password_cb_Fct(cb), u);
+}
+
+EXPORT void* my3_PEM_read_bio_X509_REQ(x64emu_t* emu, void* bp, void* x, void* cb, void* u)
+{
+ (void)emu;
+ return my->PEM_read_bio_X509_REQ(bp, x, find_pem_password_cb_Fct(cb), u);
+}
+
+EXPORT void* my3_PEM_read_bio_X509_CERT_PAIR(x64emu_t* emu, void* bp, void* x, void* cb, void* u)
+{
+ (void)emu;
+ return my->PEM_read_bio_X509_CERT_PAIR(bp, x, find_pem_password_cb_Fct(cb), u);
+}
+
+EXPORT void my3_X509_STORE_CTX_set_verify_cb(x64emu_t* emu, void* ctx, void* cb)
+{
+ (void)emu;
+ my->X509_STORE_CTX_set_verify_cb(ctx, find_verify_cb_Fct(cb));
+}
+
+EXPORT void my3_OPENSSL_sk_pop_free(x64emu_t* emu, void* s, void* cb)
+{
+ (void)emu;
+ my->OPENSSL_sk_pop_free(s, find_free_fnc_Fct(cb));
+}
+
+EXPORT void my3_ERR_set_error(x64emu_t* emu, int lib, int reason, void* fmt, uintptr_t* b)
+{
+ myStackAlign(emu, (const char*)fmt, b, emu->scratch, R_EAX, 3);
+ PREPARE_VALIST;
+ my->ERR_vset_error(lib, reason, fmt, VARARGS);
+}
+EXPORT void my3_ERR_vset_error(x64emu_t* emu, int lib, int reason, void* fmt, x64_va_list_t b)
+{
+ #ifdef CONVERT_VALIST
+ CONVERT_VALIST(b);
+ #else
+ myStackAlignValist(emu, (const char*)fmt, emu->scratch, b);
+ PREPARE_VALIST;
+ #endif
+ my->ERR_vset_error(lib, reason, fmt, VARARGS);
+}
+
+
+#define CUSTOM_INIT \
+ SETALT(my3_); \
+ getMy(lib);
+
+#define CUSTOM_FINI \
+ freeMy();
+
+#include "wrappedlib_init.h"
diff --git a/src/wrapped/wrappedcrypto3_private.h b/src/wrapped/wrappedcrypto3_private.h
new file mode 100644
index 0000000..40a0c18
--- /dev/null
+++ b/src/wrapped/wrappedcrypto3_private.h
@@ -0,0 +1,3893 @@
+#if !(defined(GO) && defined(GOM) && defined(GO2) && defined(DATA))
+#error meh!
+#endif
+
+GO(a2d_ASN1_OBJECT, iFpipi)
+GO(a2i_ASN1_ENUMERATED, iFpppi)
+GO(a2i_ASN1_INTEGER, iFpppi)
+GO(a2i_ASN1_STRING, iFpppi)
+//GO(a2i_GENERAL_NAME,
+//GO(a2i_ipadd,
+//GO(a2i_IPADDRESS,
+//GO(a2i_IPADDRESS_NC,
+//GO(ACCESS_DESCRIPTION_free,
+//GO(ACCESS_DESCRIPTION_new,
+GO(AES_bi_ige_encrypt, vFppLpppi)
+GO(AES_cbc_encrypt, vFppLppi)
+GO(AES_cfb128_encrypt, vFppLpppi)
+GO(AES_cfb1_encrypt, vFppLpppi)
+GO(AES_cfb8_encrypt, vFppLpppi)
+GO(AES_ctr128_encrypt, vFppLpppp)
+GO(AES_decrypt, vFppp)
+GO(AES_ecb_encrypt, vFpppi)
+GO(AES_encrypt, vFppp)
+GO(AES_ige_encrypt, vFppLppi)
+GO(AES_ofb128_encrypt, vFppLppp)
+GO(AES_options, pFv)
+GO(AES_set_decrypt_key, iFpip)
+//GO(AES_set_enc2dec_key,
+GO(AES_set_encrypt_key, iFpip)
+GO(AES_unwrap_key, iFppppu)
+//GO(aes_v8_cbc_encrypt,
+//GO(aes_v8_ctr32_encrypt_blocks,
+//GO(aes_v8_decrypt,
+//GO(aes_v8_encrypt,
+//GO(aes_v8_set_decrypt_key,
+//GO(aes_v8_set_encrypt_key,
+GO(AES_wrap_key, iFppppi)
+//GO(_armv7_neon_probe,
+//GO(_armv7_tick,
+//GO(_armv8_aes_probe,
+//GO(_armv8_pmull_probe,
+//GO(_armv8_sha1_probe,
+//GO(_armv8_sha256_probe,
+//GO(asn1_add_error,
+//GO(ASN1_add_oid_module,
+GO(ASN1_BIT_STRING_check, iFppi)
+GO(ASN1_BIT_STRING_free, vFp)
+GO(ASN1_BIT_STRING_get_bit, iFpi)
+GO(ASN1_BIT_STRING_name_print, iFpppi)
+GO(ASN1_BIT_STRING_new, pFv)
+GO(ASN1_BIT_STRING_num_asc, iFpp)
+GO(ASN1_BIT_STRING_set, iFppi)
+GO(ASN1_BIT_STRING_set_asc, iFppip)
+GO(ASN1_BIT_STRING_set_bit, iFpii)
+GO(ASN1_BMPSTRING_free, vFp)
+GO(ASN1_BMPSTRING_new, pFv)
+GO(ASN1_bn_print, iFppppi)
+GO(ASN1_check_infinite_end, iFpl)
+GO(ASN1_const_check_infinite_end, iFpl)
+//GO(asn1_const_Finish,
+GOM(ASN1_d2i_bio, pFEpppp)
+//GO(ASN1_d2i_fp,
+//GO(ASN1_digest,
+//GO(asn1_do_adb,
+//GO(asn1_do_lock,
+//GO(ASN1_dup,
+//GO(asn1_enc_free,
+//GO(asn1_enc_init,
+//GO(asn1_enc_restore,
+//GO(asn1_enc_save,
+GO(ASN1_ENUMERATED_free, vFp)
+GO(ASN1_ENUMERATED_get, lFp)
+GO(ASN1_ENUMERATED_new, pFv)
+GO(ASN1_ENUMERATED_set, iFpl)
+GO(ASN1_ENUMERATED_to_BN, pFpp)
+//GO(asn1_ex_c2i,
+//GO(asn1_ex_i2c,
+//GO(asn1_Finish,
+GO(ASN1_GENERALIZEDTIME_adj, pFplil)
+GO(ASN1_GENERALIZEDTIME_check, iFp)
+GO(ASN1_GENERALIZEDTIME_free, vFp)
+GO(ASN1_GENERALIZEDTIME_new, pFv)
+GO(ASN1_GENERALIZEDTIME_print, iFpp)
+GO(ASN1_GENERALIZEDTIME_set, pFpl)
+GO(ASN1_GENERALIZEDTIME_set_string, iFpp)
+//GO(asn1_generalizedtime_to_tm,
+GO(ASN1_GENERALSTRING_free, vFp)
+GO(ASN1_GENERALSTRING_new, pFv)
+GO(ASN1_generate_nconf, pFpp)
+GO(ASN1_generate_v3, pFpp)
+//GO(asn1_get_choice_selector,
+//GO(asn1_get_field_ptr,
+GO(ASN1_get_object, iFppppl)
+//GO(asn1_GetSequence,
+GOM(ASN1_i2d_bio, iFEppp)
+//GO(ASN1_i2d_fp,
+GO(ASN1_IA5STRING_free, vFp)
+GO(ASN1_IA5STRING_new, pFv)
+GO(ASN1_INTEGER_cmp, iFpp)
+GO(ASN1_INTEGER_dup, pFp)
+GO(ASN1_INTEGER_free, vFp)
+GO(ASN1_INTEGER_get, lFp)
+GO(ASN1_INTEGER_new, pFv)
+GO(ASN1_INTEGER_set, iFpl)
+GO(ASN1_INTEGER_to_BN, pFpp)
+GO(ASN1_item_d2i, pFpplp)
+GO(ASN1_item_d2i_bio, pFppp)
+GO(ASN1_item_d2i_fp, pFppp)
+//GO(ASN1_item_digest,
+GO(ASN1_item_dup, pFpp)
+//GO(ASN1_item_ex_d2i,
+//GO(ASN1_item_ex_free,
+//GO(ASN1_item_ex_i2d,
+//GO(ASN1_item_ex_new,
+GO(ASN1_item_free, vFpp)
+//GO(ASN1_item_i2d,
+GO(ASN1_item_i2d_bio, iFppp)
+GO(ASN1_item_i2d_fp, iFppp)
+GO(ASN1_item_ndef_i2d, iFppp)
+GO(ASN1_item_new, pFp)
+GO(ASN1_item_pack, pFppp)
+GO(ASN1_item_print, iFppipp)
+//GO(ASN1_item_sign,
+//GO(ASN1_item_sign_ctx,
+GO(ASN1_item_unpack, pFpp)
+//GO(ASN1_item_verify,
+GO(ASN1_mbstring_copy, iFppiiL)
+GO(ASN1_mbstring_ncopy, iFppiiLll)
+GO(ASN1_NULL_free, vFp)
+GO(ASN1_NULL_new, pFv)
+GO(ASN1_OBJECT_create, pFipipp)
+GO(ASN1_OBJECT_free, vFp)
+GO(ASN1_OBJECT_new, pFv)
+GO(ASN1_object_size, iFiii)
+GO(ASN1_OCTET_STRING_cmp, iFpp)
+GO(ASN1_OCTET_STRING_dup, pFp)
+GO(ASN1_OCTET_STRING_free, vFp)
+GO(ASN1_OCTET_STRING_new, pFv)
+GO(ASN1_OCTET_STRING_set, iFppi)
+//GO(ASN1_pack_string,
+GO(ASN1_parse, iFppli)
+GO(ASN1_parse_dump, iFpplii)
+GO(ASN1_PCTX_free, vFp)
+//GO(ASN1_PCTX_get_cert_flags,
+//GO(ASN1_PCTX_get_flags,
+//GO(ASN1_PCTX_get_nm_flags,
+//GO(ASN1_PCTX_get_oid_flags,
+GO(ASN1_PCTX_get_str_flags, LFp)
+GO(ASN1_PCTX_new, pFv)
+//GO(ASN1_PCTX_set_cert_flags,
+//GO(ASN1_PCTX_set_flags,
+//GO(ASN1_PCTX_set_nm_flags,
+//GO(ASN1_PCTX_set_oid_flags,
+GO(ASN1_PCTX_set_str_flags, vFpL)
+//GO(ASN1_primitive_free,
+//GO(ASN1_primitive_new,
+//GO(ASN1_PRINTABLE_free,
+//GO(ASN1_PRINTABLE_new,
+GO(ASN1_PRINTABLESTRING_free, vFp)
+GO(ASN1_PRINTABLESTRING_new, pFv)
+GO(ASN1_PRINTABLE_type, iFpi)
+GO(ASN1_put_eoc, iFp)
+GO(ASN1_put_object, vFpiiii)
+//GO(ASN1_seq_pack,
+//GO(ASN1_seq_unpack,
+//GO(asn1_set_choice_selector,
+//GO(ASN1_sign,
+//GO(ASN1_STRING_clear_free,
+GO(ASN1_STRING_cmp, iFpp)
+GO(ASN1_STRING_copy, iFpp)
+GO(ASN1_STRING_data, pFp)
+GO(ASN1_STRING_dup, pFp)
+GO(ASN1_STRING_free, vFp)
+GO(ASN1_STRING_get_default_mask, LFv)
+GO(ASN1_STRING_length, iFp)
+GO(ASN1_STRING_length_set, vFpi)
+//GO(ASN1_STRING_new,
+GO(ASN1_STRING_print, iFpp)
+GO(ASN1_STRING_print_ex, iFppL)
+GO(ASN1_STRING_print_ex_fp, iFppL)
+GO(ASN1_STRING_set, iFppi)
+GO(ASN1_STRING_set0, vFppi)
+GO(ASN1_STRING_set_by_NID, pFppiii)
+GO(ASN1_STRING_set_default_mask, vFL)
+GO(ASN1_STRING_set_default_mask_asc, iFp)
+GO(ASN1_STRING_TABLE_add, iFillLL)
+//GO(ASN1_STRING_TABLE_cleanup,
+GO(ASN1_STRING_TABLE_get, pFi)
+GO(ASN1_STRING_to_UTF8, iFpp)
+GO(ASN1_STRING_type, iFp)
+GO(ASN1_STRING_type_new, pFi)
+GO(ASN1_T61STRING_free, vFp)
+GO(ASN1_T61STRING_new, pFv)
+GO(ASN1_tag2bit, LFi)
+GO(ASN1_tag2str, pFi)
+//GO(ASN1_template_d2i,
+//GO(ASN1_template_free,
+//GO(ASN1_template_i2d,
+//GO(ASN1_template_new,
+//GO(asn1_template_print_ctx,
+GO(ASN1_TIME_adj, pFplil)
+GO(ASN1_TIME_check, iFp)
+GO(ASN1_TIME_diff, iFpppp)
+GO(ASN1_TIME_free, vFp)
+GO(ASN1_TIME_new, pFv)
+GO(ASN1_TIME_print, iFpp)
+GO(ASN1_TIME_set, pFpl)
+//GO(ASN1_TIME_set_string,
+GO(ASN1_TIME_to_generalizedtime, pFpp)
+GO(ASN1_TYPE_cmp, iFpp)
+GO(ASN1_TYPE_free, vFp)
+GO(ASN1_TYPE_get, iFp)
+GO(ASN1_TYPE_get_int_octetstring, iFpppi)
+GO(ASN1_TYPE_get_octetstring, iFppi)
+GO(ASN1_TYPE_new, pFv)
+GO(ASN1_TYPE_set, vFpip)
+GO(ASN1_TYPE_set1, iFpip)
+GO(ASN1_TYPE_set_int_octetstring, iFplpi)
+GO(ASN1_TYPE_set_octetstring, iFppi)
+GO(ASN1_UNIVERSALSTRING_free, vFp)
+GO(ASN1_UNIVERSALSTRING_new, pFv)
+GO(ASN1_UNIVERSALSTRING_to_string, iFp)
+//GO(ASN1_unpack_string,
+GO(ASN1_UTCTIME_adj, pFplil)
+GO(ASN1_UTCTIME_check, iFp)
+GO(ASN1_UTCTIME_cmp_time_t, iFpl)
+GO(ASN1_UTCTIME_free, vFp)
+GO(ASN1_UTCTIME_new, pFv)
+GO(ASN1_UTCTIME_print, iFpp)
+GO(ASN1_UTCTIME_set, pFpl)
+GO(ASN1_UTCTIME_set_string, iFpp)
+//GO(asn1_utctime_to_tm,
+GO(ASN1_UTF8STRING_free, vFp)
+GO(ASN1_UTF8STRING_new, pFv)
+//GO(ASN1_verify,
+GO(ASN1_VISIBLESTRING_free, vFp)
+GO(ASN1_VISIBLESTRING_new, pFv)
+//GO(AUTHORITY_INFO_ACCESS_free,
+//GO(AUTHORITY_INFO_ACCESS_new,
+GO(AUTHORITY_KEYID_free, vFp)
+GO(AUTHORITY_KEYID_new, pFv)
+//GO(b2i_PrivateKey,
+//GO(b2i_PrivateKey_bio,
+//GO(b2i_PublicKey,
+//GO(b2i_PublicKey_bio,
+//GO(b2i_PVK_bio,
+GO(BASIC_CONSTRAINTS_free, vFp)
+GO(BASIC_CONSTRAINTS_new, pFv)
+GO(BF_cbc_encrypt, vFpplppi)
+GO(BF_cfb64_encrypt, vFpplpppi)
+GO(BF_decrypt, vFpp)
+GO(BF_ecb_encrypt, vFpppi)
+//GO(BF_encrypt,
+GO(BF_ofb64_encrypt, vFpplppp)
+GO(BF_options, pFv)
+GO(BF_set_key, vFpip)
+GO(BIO_accept, iFip)
+//GO(BIO_asn1_get_prefix,
+GO(BIO_asn1_get_suffix, iFppp)
+//GO(BIO_asn1_set_prefix,
+//GO(BIO_asn1_set_suffix,
+//GO(BIO_callback_ctrl,
+//GO(BIO_clear_flags,
+//GO(BIO_CONNECT_free,
+//GO(BIO_CONNECT_new,
+GO(BIO_copy_next_retry, vFp)
+GO(BIO_ctrl, lFpilp)
+GO(BIO_ctrl_get_read_request, LFp)
+//GO(BIO_ctrl_get_write_guarantee,
+GO(BIO_ctrl_pending, LFp)
+//GO(BIO_ctrl_reset_read_request,
+GO(BIO_ctrl_wpending, LFp)
+GO(BIO_debug_callback, lFpipill)
+//GO(BIO_dgram_non_fatal_error,
+GO(BIO_dump, iFppi)
+//GO(BIO_dump_cb,
+GO(BIO_dump_fp, iFppi)
+GO(BIO_dump_indent, iFppii)
+//GO(BIO_dump_indent_cb,
+GO(BIO_dump_indent_fp, iFppii)
+GO(BIO_dup_chain, pFp)
+GO(BIO_eof, iFp)
+GO(BIO_f_asn1, pFv)
+//GO(BIO_f_base64,
+//GO(BIO_f_buffer,
+//GO(BIO_f_cipher,
+//GO(BIO_fd_non_fatal_error,
+//GO(BIO_fd_should_retry,
+GO(BIO_flush, iFp)
+GO(BIO_find_type, pFpi)
+//GO(BIO_f_md,
+//GO(BIO_f_nbio_test,
+//GO(BIO_f_null,
+GO(BIO_free, iFp)
+GO(BIO_free_all, vFp)
+//GO(BIO_f_reliable,
+//GO(BIO_f_zlib,
+GO(BIO_get_accept_socket, iFpi)
+GO(BIO_get_callback, pFp)
+GO(BIO_get_callback_arg, pFp)
+GO(BIO_get_close, iFp)
+GO(BIO_get_ex_data, pFpi)
+//GO(BIO_get_ex_new_index,
+GO(BIO_gethostbyname, pFp)
+GO(BIO_get_host_ip, iFpp)
+GO(BIO_get_port, iFpp)
+GO(BIO_get_retry_BIO, pFpp)
+GO(BIO_get_retry_reason, iFp)
+GO(BIO_gets, iFppi)
+GO(BIO_hex_string, iFpiipi)
+//GO(BIO_indent,
+GO(BIO_int_ctrl, lFpili)
+GO(BIO_method_name, pFp)
+GO(BIO_method_type, iFp)
+GO(BIO_new, pFp)
+GO(BIO_new_accept, pFp)
+GO(BIO_new_bio_pair, iFpLpL)
+//GO(BIO_new_CMS,
+//GO(BIO_new_connect,
+//GO(BIO_new_dgram,
+GO(BIO_new_fd, pFii)
+GO(BIO_new_file, pFpp)
+GO(BIO_new_fp, pFpi)
+GO(BIO_new_mem_buf, pFpi)
+GO(BIO_new_NDEF, pFppp)
+//GO(BIO_new_PKCS7,
+//GO(BIO_new_socket,
+//GO(BIO_next,
+//GO(BIO_nread,
+//GO(BIO_nread0,
+//GO(BIO_number_read,
+GO(BIO_number_written, LFp)
+GO(BIO_nwrite, iFppi)
+GO(BIO_nwrite0, iFpp)
+GO(BIO_pending, iFp)
+//GO(BIO_pop,
+//GO(BIO_printf,
+GO(BIO_ptr_ctrl, pFpil)
+GO(BIO_push, pFpp)
+GO(BIO_puts, iFpp)
+GO(BIO_read, iFppi)
+GO(BIO_reset, iFp)
+//GO(BIO_s_accept,
+//GO(BIO_s_bio,
+//GO(BIO_s_connect,
+GO(BIO_s_datagram, pFv)
+GO(BIO_seek, iFpi)
+GO(BIO_set, iFpp)
+//GO(BIO_set_callback,
+GO(BIO_set_callback_arg, vFpp)
+GO(BIO_set_close, iFpl)
+//GO(BIO_set_cipher,
+GO(BIO_set_ex_data, iFpip)
+//GO(BIO_set_flags,
+GO(BIO_set_tcp_ndelay, iFii)
+//GO(BIO_s_fd,
+//GO(BIO_s_file,
+//GO(BIO_s_log,
+GO(BIO_s_mem, pFv)
+//GO(BIO_snprintf,
+//GO(BIO_s_null,
+//GO(BIO_sock_cleanup,
+//GO(BIO_sock_error,
+GO(BIO_socket_ioctl, iFilp)
+//GO(BIO_socket_nbio,
+GO(BIO_sock_init, iFv)
+//GO(BIO_sock_non_fatal_error,
+//GO(BIO_sock_should_retry,
+//GO(BIO_s_socket,
+GO(BIO_tell, iFp)
+GO(BIO_test_flags, iFpi)
+GO(BIO_up_ref, iFp)
+GO(BIO_vfree, vFp)
+//GO(BIO_vprintf,
+//GO(BIO_vsnprintf,
+GO(BIO_wpending, iFp)
+GO(BIO_write, iFppi)
+GO(BN_add, iFppp)
+//GO(bn_add_part_words,
+GO(BN_add_word, iFpu)
+//GO(bn_add_words,
+GO(BN_asc2bn, iFpp)
+GO(BN_bin2bn, pFpip)
+//GO(BN_BLINDING_convert,
+GO(BN_BLINDING_convert_ex, iFpppp)
+//GO(BN_BLINDING_create_param,
+//GO(BN_BLINDING_free,
+GO(BN_BLINDING_get_flags, LFp)
+//GO(BN_BLINDING_get_thread_id,
+GO(BN_BLINDING_invert, iFppp)
+GO(BN_BLINDING_invert_ex, iFpppp)
+GO(BN_BLINDING_new, pFppp)
+GO(BN_BLINDING_set_flags, vFpL)
+//GO(BN_BLINDING_set_thread_id,
+//GO(BN_BLINDING_thread_id,
+GO(BN_BLINDING_update, iFpp)
+GO(BN_bn2bin, iFpp)
+GO(BN_bn2dec, pFp)
+GO(BN_bn2hex, pFp)
+GO(BN_bn2mpi, iFpp)
+GO(BN_bntest_rand, iFpiii)
+GO(BN_clear, vFp)
+GO(BN_clear_bit, iFpi)
+GO(BN_clear_free, vFp)
+GO(BN_cmp, iFpp)
+//GO(bn_cmp_part_words,
+//GO(bn_cmp_words,
+GO(BN_consttime_swap, vFLppi)
+GO(BN_copy, pFpp)
+GO(BN_CTX_end, vFp)
+GO(BN_CTX_free, vFp)
+GO(BN_CTX_get, pFp)
+GO(BN_CTX_init, vFp)
+GO(BN_CTX_new, pFv)
+//GO(BN_CTX_start,
+GO(BN_dec2bn, iFpp)
+GO(BN_div, iFppppp)
+GO(BN_div_recp, iFppppp)
+GO(BN_div_word, LFpL)
+//GO(bn_div_words,
+GO(BN_dup, pFp)
+//GO(bn_dup_expand,
+GO(BN_exp, iFpppp)
+//GO(bn_expand2,
+GO(BN_free, vFp)
+GO(BN_from_montgomery, iFpppp)
+GO(BN_gcd, iFpppp)
+GO(BN_GENCB_call, iFpii)
+//GO(BN_generate_prime, pFpiippBp) //callback previous last argument...
+GO(BN_generate_prime_ex, iFpiippp)
+//GO(BN_get0_nist_prime_192,
+//GO(BN_get0_nist_prime_224,
+//GO(BN_get0_nist_prime_256,
+//GO(BN_get0_nist_prime_384,
+GO(BN_get0_nist_prime_521, pFv)
+GO(BN_get_params, iFi)
+GO(BN_get_word, LFp)
+//GO(BN_GF2m_add,
+GO(BN_GF2m_arr2poly, iFpp)
+GO(BN_GF2m_mod, iFppp)
+GO(BN_GF2m_mod_arr, iFppp)
+//GO(BN_GF2m_mod_div,
+//GO(BN_GF2m_mod_div_arr,
+GO(BN_GF2m_mod_exp, iFppppp)
+GO(BN_GF2m_mod_exp_arr, iFppppp)
+//GO(BN_GF2m_mod_inv,
+//GO(BN_GF2m_mod_inv_arr,
+//GO(BN_GF2m_mod_mul,
+//GO(BN_GF2m_mod_mul_arr,
+//GO(BN_GF2m_mod_solve_quad,
+GO(BN_GF2m_mod_solve_quad_arr, iFpppp)
+//GO(BN_GF2m_mod_sqr,
+//GO(BN_GF2m_mod_sqr_arr,
+//GO(BN_GF2m_mod_sqrt,
+//GO(BN_GF2m_mod_sqrt_arr,
+//GO(bn_GF2m_mul_2x2,
+GO(BN_GF2m_poly2arr, iFppi)
+GO(BN_hex2bn, iFpp)
+//GO(BN_init,
+GO(BN_is_bit_set, iFpi)
+//GO(BN_is_prime, iFpiBpp) // third argument is a callback
+GO(BN_is_prime_ex, iFpipp)
+//GO(BN_is_prime_fasttest,
+GO(BN_is_prime_fasttest_ex, iFpipip)
+GO(BN_is_zero, iFp)
+GO(BN_kronecker, iFppp)
+GO(BN_lshift, iFppi)
+GO(BN_lshift1, iFpp)
+GO(BN_mask_bits, iFpi)
+GO(BN_mod_add, iFppppp)
+//GO(BN_mod_add_quick,
+GO(BN_mod_exp, iFppppp)
+GO(BN_mod_exp2_mont, iFpppppppp)
+//GO(BN_mod_exp_mont,
+GO(BN_mod_exp_mont_consttime, iFpppppp)
+GO(BN_mod_exp_mont_word, iFpLpppp)
+//GO(BN_mod_exp_recp,
+//GO(BN_mod_exp_simple,
+GO(BN_mod_inverse, pFpppp)
+GO(BN_mod_lshift, iFppipp)
+//GO(BN_mod_lshift1,
+//GO(BN_mod_lshift1_quick,
+GO(BN_mod_lshift_quick, iFppip)
+GO(BN_mod_mul, iFppppp)
+GO(BN_mod_mul_montgomery, iFppppp)
+GO(BN_mod_mul_reciprocal, iFppppp)
+GO(BN_mod_sqr, iFpppp)
+GO(BN_mod_sqrt, pFpppp)
+GO(BN_mod_sub, iFppppp)
+GO(BN_mod_sub_quick, iFpppp)
+GO(BN_mod_word, LFpL)
+GO(BN_MONT_CTX_copy, pFpp)
+GO(BN_MONT_CTX_free, vFp)
+//GO(BN_MONT_CTX_init,
+GO(BN_MONT_CTX_new, pFv)
+GO(BN_MONT_CTX_set, iFppp)
+GO(BN_MONT_CTX_set_locked, pFpppp)
+GO(BN_mpi2bn, pFpip)
+GO(BN_mul, iFpppp)
+//GO(bn_mul_add_words,
+//GO(bn_mul_comba4,
+//GO(bn_mul_comba8,
+//GO(bn_mul_high,
+//GO(bn_mul_low_normal,
+//GO(bn_mul_low_recursive,
+//GO(bn_mul_mont,
+//GO(bn_mul_normal,
+//GO(bn_mul_part_recursive,
+//GO(bn_mul_recursive,
+GO(BN_mul_word, iFpu)
+//GO(bn_mul_words,
+GO(BN_new, pFv)
+//GO(BN_nist_mod_192,
+//GO(BN_nist_mod_224,
+//GO(BN_nist_mod_256,
+//GO(BN_nist_mod_384,
+GO(BN_nist_mod_521, iFpppp)
+GO(BN_nnmod, iFpppp)
+GO(BN_num_bits, iFp)
+GO(BN_num_bits_word, iFL)
+GO(BN_one, iFp)
+GO(BN_options, pFv)
+GO(BN_print, iFpp)
+GO(BN_print_fp, iFpp)
+GO(BN_pseudo_rand, iFpiii)
+GO(BN_pseudo_rand_range, iFpp)
+GO(BN_rand, iFpiii)
+//GO(BN_rand_range,
+GO(BN_reciprocal, iFppip)
+GO(BN_RECP_CTX_free, vFp)
+//GO(BN_RECP_CTX_init,
+GO(BN_RECP_CTX_new, pFv)
+GO(BN_RECP_CTX_set, iFppp)
+GO(BN_rshift, iFppi)
+GO(BN_rshift1, iFpp)
+GO(BN_set_bit, iFpi)
+GO(BN_set_negative, vFpi)
+GO(BN_set_params, vFiiii)
+GO(BN_set_word, iFpL)
+GO(BN_sqr, iFppp)
+//GO(bn_sqr_comba4,
+//GO(bn_sqr_comba8,
+//GO(bn_sqr_normal,
+//GO(bn_sqr_recursive,
+//GO(bn_sqr_words,
+GO(BN_sub, iFppp)
+//GO(bn_sub_part_words,
+GO(BN_sub_word, iFpu)
+//GO(bn_sub_words,
+GO(BN_swap, vFpp)
+GO(BN_to_ASN1_ENUMERATED, pFpp)
+GO(BN_to_ASN1_INTEGER, pFpp)
+//GO(BN_uadd,
+GO(BN_ucmp, iFpp)
+//GO(BN_usub,
+GO(BN_value_one, pFv)
+GO(BN_X931_derive_prime_ex, iFppppppppp)
+GO(BN_X931_generate_prime_ex, iFppppppppp)
+GO(BN_X931_generate_Xpq, iFppip)
+GO(BN_zero, vFp)
+//GO(bsaes_cbc_encrypt,
+//GO(bsaes_ctr32_encrypt_blocks,
+//GO(bsaes_xts_decrypt,
+//GO(bsaes_xts_encrypt,
+//GO(BUF_memdup,
+//GO(BUF_MEM_free,
+//GO(BUF_MEM_grow,
+//GO(BUF_MEM_grow_clean,
+//GO(BUF_MEM_new,
+//GO(BUF_reverse,
+//GO(BUF_strdup,
+//GO(BUF_strlcat,
+//GO(BUF_strlcpy,
+//GO(BUF_strndup,
+//GO(BUF_strnlen,
+//GO(c2i_ASN1_BIT_STRING,
+//GO(c2i_ASN1_INTEGER,
+//GO(c2i_ASN1_OBJECT,
+//GO(Camellia_cbc_encrypt,
+//GO(Camellia_cfb128_encrypt,
+//GO(Camellia_cfb1_encrypt,
+//GO(Camellia_cfb8_encrypt,
+//GO(Camellia_ctr128_encrypt,
+//GO(Camellia_decrypt,
+//GO(Camellia_DecryptBlock,
+//GO(Camellia_DecryptBlock_Rounds,
+//GO(Camellia_ecb_encrypt,
+//GO(Camellia_Ekeygen,
+//GO(Camellia_encrypt,
+//GO(Camellia_EncryptBlock,
+//GO(Camellia_EncryptBlock_Rounds,
+//GO(Camellia_ofb128_encrypt,
+//GO(Camellia_set_key,
+//GO(CAST_cbc_encrypt,
+//GO(CAST_cfb64_encrypt,
+//GO(CAST_decrypt,
+//GO(CAST_ecb_encrypt,
+//GO(CAST_encrypt,
+//GO(CAST_ofb64_encrypt,
+//GO(CAST_set_key,
+//GO(CERTIFICATEPOLICIES_free,
+//GO(CERTIFICATEPOLICIES_new,
+//GO(check_defer,
+//GO(CMAC_CTX_cleanup,
+//GO(CMAC_CTX_copy,
+//GO(CMAC_CTX_free,
+//GO(CMAC_CTX_get0_cipher_ctx,
+//GO(CMAC_CTX_new,
+//GO(CMAC_Final,
+//GO(CMAC_Init,
+//GO(CMAC_resume,
+//GO(CMAC_Update,
+//GO(CMS_add0_cert,
+//GO(CMS_add0_CertificateChoices,
+//GO(CMS_add0_crl,
+//GO(CMS_add0_recipient_key,
+//GO(CMS_add0_recipient_password,
+//GO(CMS_add0_RevocationInfoChoice,
+//GO(CMS_add1_cert,
+//GO(CMS_add1_crl,
+//GO(CMS_add1_ReceiptRequest,
+//GO(CMS_add1_recipient_cert,
+//GO(CMS_add1_signer,
+//GO(CMS_add_simple_smimecap,
+//GO(CMS_add_smimecap,
+//GO(CMS_add_standard_smimecap,
+//GO(CMS_compress,
+//GO(cms_CompressedData_create,
+//GO(cms_CompressedData_init_bio,
+//GO(cms_content_bio,
+//GO(CMS_ContentInfo_free,
+//GO(CMS_ContentInfo_new,
+//GO(CMS_ContentInfo_print_ctx,
+//GO(CMS_data,
+//GO(cms_Data_create,
+//GO(CMS_data_create,
+//GO(CMS_dataFinal,
+//GO(CMS_dataInit,
+//GO(CMS_decrypt,
+//GO(CMS_decrypt_set1_key,
+//GO(CMS_decrypt_set1_password,
+//GO(CMS_decrypt_set1_pkey,
+//GO(cms_DigestAlgorithm_find_ctx,
+//GO(cms_DigestAlgorithm_init_bio,
+//GO(cms_DigestAlgorithm_set,
+//GO(CMS_digest_create,
+//GO(cms_DigestedData_create,
+//GO(cms_DigestedData_do_final,
+//GO(cms_DigestedData_init_bio,
+//GO(CMS_digest_verify,
+//GO(cms_encode_Receipt,
+//GO(CMS_encrypt,
+//GO(cms_EncryptedContent_init,
+//GO(cms_EncryptedContent_init_bio,
+//GO(CMS_EncryptedData_decrypt,
+//GO(CMS_EncryptedData_encrypt,
+//GO(cms_EncryptedData_init_bio,
+//GO(CMS_EncryptedData_set1_key,
+//GO(cms_env_asn1_ctrl,
+//GO(CMS_EnvelopedData_create,
+//GO(cms_EnvelopedData_init_bio,
+//GO(CMS_final,
+//GO(CMS_get0_content,
+//GO(CMS_get0_eContentType,
+//GO(cms_get0_enveloped,
+//GO(CMS_get0_RecipientInfos,
+//GO(CMS_get0_SignerInfos,
+//GO(CMS_get0_signers,
+//GO(CMS_get0_type,
+//GO(CMS_get1_certs,
+//GO(CMS_get1_crls,
+//GO(CMS_get1_ReceiptRequest,
+//GO(cms_ias_cert_cmp,
+//GO(CMS_is_detached,
+//GO(cms_keyid_cert_cmp,
+//GO(cms_msgSigDigest_add1,
+//GO(cms_pkey_get_ri_type,
+//GO(CMS_ReceiptRequest_create0,
+//GO(CMS_ReceiptRequest_free,
+//GO(CMS_ReceiptRequest_get0_values,
+//GO(CMS_ReceiptRequest_new,
+//GO(cms_Receipt_verify,
+//GO(CMS_RecipientEncryptedKey_cert_cmp,
+//GO(CMS_RecipientEncryptedKey_get0_id,
+//GO(CMS_RecipientInfo_decrypt,
+//GO(CMS_RecipientInfo_encrypt,
+//GO(CMS_RecipientInfo_get0_pkey_ctx,
+//GO(CMS_RecipientInfo_kari_decrypt,
+//GO(cms_RecipientInfo_kari_encrypt,
+//GO(CMS_RecipientInfo_kari_get0_alg,
+//GO(CMS_RecipientInfo_kari_get0_ctx,
+//GO(CMS_RecipientInfo_kari_get0_orig_id,
+//GO(CMS_RecipientInfo_kari_get0_reks,
+//GO(cms_RecipientInfo_kari_init,
+//GO(CMS_RecipientInfo_kari_orig_id_cmp,
+//GO(CMS_RecipientInfo_kari_set0_pkey,
+//GO(CMS_RecipientInfo_kekri_get0_id,
+//GO(CMS_RecipientInfo_kekri_id_cmp,
+//GO(CMS_RecipientInfo_ktri_cert_cmp,
+//GO(CMS_RecipientInfo_ktri_get0_algs,
+//GO(CMS_RecipientInfo_ktri_get0_signer_id,
+//GO(cms_RecipientInfo_pwri_crypt,
+//GO(CMS_RecipientInfo_set0_key,
+//GO(CMS_RecipientInfo_set0_password,
+//GO(CMS_RecipientInfo_set0_pkey,
+//GO(CMS_RecipientInfo_type,
+//GO(CMS_set1_eContentType,
+//GO(cms_set1_ias,
+//GO(cms_set1_keyid,
+//GO(cms_set1_SignerIdentifier,
+//GO(CMS_set1_signers_certs,
+//GO(CMS_set_detached,
+//GO(CMS_SharedInfo_encode,
+//GO(CMS_sign,
+//GO(CMS_signed_add1_attr,
+//GO(CMS_signed_add1_attr_by_NID,
+//GO(CMS_signed_add1_attr_by_OBJ,
+//GO(CMS_signed_add1_attr_by_txt,
+//GO(cms_SignedData_final,
+//GO(CMS_SignedData_init,
+//GO(cms_SignedData_init_bio,
+//GO(CMS_signed_delete_attr,
+//GO(CMS_signed_get0_data_by_OBJ,
+//GO(CMS_signed_get_attr,
+//GO(CMS_signed_get_attr_by_NID,
+//GO(CMS_signed_get_attr_by_OBJ,
+//GO(CMS_signed_get_attr_count,
+//GO(cms_SignerIdentifier_cert_cmp,
+//GO(cms_SignerIdentifier_get0_signer_id,
+//GO(CMS_SignerInfo_cert_cmp,
+//GO(CMS_SignerInfo_get0_algs,
+//GO(CMS_SignerInfo_get0_md_ctx,
+//GO(CMS_SignerInfo_get0_pkey_ctx,
+//GO(CMS_SignerInfo_get0_signature,
+//GO(CMS_SignerInfo_get0_signer_id,
+//GO(CMS_SignerInfo_set1_signer_cert,
+//GO(CMS_SignerInfo_sign,
+//GO(CMS_SignerInfo_verify,
+//GO(CMS_SignerInfo_verify_content,
+//GO(CMS_sign_receipt,
+//GO(CMS_stream,
+//GO(CMS_uncompress,
+//GO(CMS_unsigned_add1_attr,
+//GO(CMS_unsigned_add1_attr_by_NID,
+//GO(CMS_unsigned_add1_attr_by_OBJ,
+//GO(CMS_unsigned_add1_attr_by_txt,
+//GO(CMS_unsigned_delete_attr,
+//GO(CMS_unsigned_get0_data_by_OBJ,
+//GO(CMS_unsigned_get_attr,
+//GO(CMS_unsigned_get_attr_by_NID,
+//GO(CMS_unsigned_get_attr_by_OBJ,
+//GO(CMS_unsigned_get_attr_count,
+//GO(CMS_verify,
+//GO(CMS_verify_receipt,
+//GO(COMP_compress_block,
+//GO(COMP_CTX_free,
+//GO(COMP_CTX_new,
+//GO(COMP_expand_block,
+//GO(COMP_rle,
+//GO(COMP_zlib,
+//GO(COMP_zlib_cleanup,
+//GO(_CONF_add_string,
+//GO(CONF_dump_bio,
+//GO(CONF_dump_fp,
+//GO(CONF_free,
+//GO(_CONF_free_data,
+//GO(CONF_get1_default_config_file,
+//GO(CONF_get_number,
+//GO(_CONF_get_section,
+//GO(CONF_get_section,
+//GO(_CONF_get_section_values,
+//GO(_CONF_get_string,
+//GO(CONF_get_string,
+//GO(CONF_imodule_get_flags,
+//GO(CONF_imodule_get_module,
+//GO(CONF_imodule_get_name,
+//GO(CONF_imodule_get_usr_data,
+//GO(CONF_imodule_get_value,
+//GO(CONF_imodule_set_flags,
+//GO(CONF_imodule_set_usr_data,
+//GO(CONF_load,
+//GO(CONF_load_bio,
+//GO(CONF_load_fp,
+//GO(CONF_module_add,
+//GO(CONF_module_get_usr_data,
+//GO(CONF_module_set_usr_data,
+//GO(CONF_modules_finish,
+//GO(CONF_modules_free,
+//GO(CONF_modules_load,
+//GO(CONF_modules_load_file,
+GO(CONF_modules_unload, vFi)
+//GO(_CONF_new_data,
+//GO(_CONF_new_section,
+//GO(CONF_parse_list,
+//GO(CONF_set_default_method,
+//GO(CONF_set_nconf,
+//GO(CRL_DIST_POINTS_free,
+//GO(CRL_DIST_POINTS_new,
+//GO(CRYPTO_128_unwrap,
+//GO(CRYPTO_128_wrap,
+GO(CRYPTO_add_lock, iFpiipi)
+//GO(CRYPTO_cbc128_decrypt,
+//GO(CRYPTO_cbc128_encrypt,
+//GO(CRYPTO_ccm128_aad,
+//GO(CRYPTO_ccm128_decrypt,
+//GO(CRYPTO_ccm128_decrypt_ccm64,
+//GO(CRYPTO_ccm128_encrypt,
+//GO(CRYPTO_ccm128_encrypt_ccm64,
+//GO(CRYPTO_ccm128_init,
+//GO(CRYPTO_ccm128_setiv,
+//GO(CRYPTO_ccm128_tag,
+//GO(CRYPTO_cfb128_1_encrypt,
+//GO(CRYPTO_cfb128_8_encrypt,
+//GO(CRYPTO_cfb128_encrypt,
+GO(CRYPTO_cleanup_all_ex_data, vFv)
+//GO(CRYPTO_ctr128_encrypt,
+//GO(CRYPTO_ctr128_encrypt_ctr32,
+//GO(CRYPTO_cts128_decrypt,
+//GO(CRYPTO_cts128_decrypt_block,
+//GO(CRYPTO_cts128_encrypt,
+//GO(CRYPTO_cts128_encrypt_block,
+//GO(CRYPTO_dbg_free,
+//GO(CRYPTO_dbg_get_options,
+//GO(CRYPTO_dbg_malloc,
+//GO(CRYPTO_dbg_realloc,
+//GO(CRYPTO_dbg_set_options,
+//GO(CRYPTO_destroy_dynlockid,
+GO(CRYPTO_dup_ex_data, iFipp)
+//GO(CRYPTO_ex_data_new_class,
+GO(CRYPTO_free, vFppi)
+GO(CRYPTO_free_ex_data, vFipp)
+//GO(CRYPTO_free_locked,
+//GO(CRYPTO_gcm128_aad,
+//GO(CRYPTO_gcm128_decrypt,
+//GO(CRYPTO_gcm128_decrypt_ctr32,
+//GO(CRYPTO_gcm128_encrypt,
+//GO(CRYPTO_gcm128_encrypt_ctr32,
+//GO(CRYPTO_gcm128_finish,
+//GO(CRYPTO_gcm128_init,
+//GO(CRYPTO_gcm128_new,
+//GO(CRYPTO_gcm128_release,
+//GO(CRYPTO_gcm128_setiv,
+//GO(CRYPTO_gcm128_tag,
+//GO(CRYPTO_get_add_lock_callback,
+//GO(CRYPTO_get_dynlock_create_callback,
+//GO(CRYPTO_get_dynlock_destroy_callback,
+//GO(CRYPTO_get_dynlock_lock_callback,
+//GO(CRYPTO_get_dynlock_value,
+GO(CRYPTO_get_ex_data, pFpi)
+//GO(CRYPTO_get_ex_data_implementation,
+//GO(CRYPTO_get_ex_new_index,
+//GO(CRYPTO_get_id_callback,
+//GO(CRYPTO_get_locked_mem_ex_functions,
+//GO(CRYPTO_get_locked_mem_functions,
+//GO(CRYPTO_get_locking_callback,
+//GO(CRYPTO_get_lock_name,
+//GO(CRYPTO_get_mem_debug_functions,
+//GO(CRYPTO_get_mem_debug_options,
+//GO(CRYPTO_get_mem_ex_functions,
+GO(CRYPTO_get_mem_functions, vFppp)
+//GO(CRYPTO_get_new_dynlockid,
+//GO(CRYPTO_get_new_lockid,
+//GO(CRYPTO_is_mem_check_on,
+//GO(CRYPTO_lock,
+GO(CRYPTO_malloc, pFupi)
+//GO(CRYPTO_malloc_locked,
+GO(CRYPTO_memcmp, iFppL)
+//GO(CRYPTO_mem_ctrl,
+//GO(CRYPTO_mem_leaks,
+//GO(CRYPTO_mem_leaks_cb,
+//GO(CRYPTO_mem_leaks_fp,
+GO(CRYPTO_new_ex_data, iFipp)
+//GO(CRYPTO_nistcts128_decrypt,
+//GO(CRYPTO_nistcts128_decrypt_block,
+//GO(CRYPTO_nistcts128_encrypt,
+//GO(CRYPTO_nistcts128_encrypt_block,
+GO(CRYPTO_num_locks, iFv)
+//GO(CRYPTO_ofb128_encrypt,
+//GO(CRYPTO_pop_info,
+//GO(CRYPTO_push_info_,
+GO(CRYPTO_realloc, pFpLpi)
+//GO(CRYPTO_realloc_clean,
+//GO(CRYPTO_remalloc,
+//GO(CRYPTO_remove_all_info,
+//GO(CRYPTO_set_add_lock_callback,
+//GO(CRYPTO_set_dynlock_create_callback,
+//GO(CRYPTO_set_dynlock_destroy_callback,
+//GO(CRYPTO_set_dynlock_lock_callback,
+GO(CRYPTO_set_ex_data, iFpip)
+//GO(CRYPTO_set_ex_data_implementation,
+GOM(CRYPTO_set_id_callback, vFEp)
+//GO(CRYPTO_set_locked_mem_ex_functions,
+//GO(CRYPTO_set_locked_mem_functions,
+GOM(CRYPTO_set_locking_callback, vFEp)
+//GO(CRYPTO_set_mem_debug_functions,
+//GO(CRYPTO_set_mem_debug_options,
+//GO(CRYPTO_set_mem_ex_functions,
+//GO(CRYPTO_set_mem_functions,
+GO(CRYPTO_strdup, pFppi)
+//GO(CRYPTO_thread_id,
+//GO(CRYPTO_THREADID_cmp,
+//GO(CRYPTO_THREADID_cpy,
+//GO(CRYPTO_THREADID_current,
+//GO(CRYPTO_THREADID_get_callback,
+//GO(CRYPTO_THREADID_hash,
+//GO(CRYPTO_THREADID_set_callback,
+//GO(CRYPTO_THREADID_set_numeric,
+//GO(CRYPTO_THREADID_set_pointer,
+//GO(CRYPTO_xts128_encrypt,
+//GO(d2i_ACCESS_DESCRIPTION,
+GO(d2i_ASN1_BIT_STRING, pFppl)
+GO(d2i_ASN1_BMPSTRING, pFppl)
+//GO(d2i_ASN1_BOOLEAN,
+//GO(d2i_ASN1_bytes,
+GO(d2i_ASN1_ENUMERATED, pFppl)
+GO(d2i_ASN1_GENERALIZEDTIME, pFppl)
+GO(d2i_ASN1_GENERALSTRING, pFppl)
+GO(d2i_ASN1_IA5STRING, pFppl)
+//GO(d2i_ASN1_INTEGER,
+GO(d2i_ASN1_NULL, pFppl)
+GO(d2i_ASN1_OBJECT, pFppl)
+GO(d2i_ASN1_OCTET_STRING, pFppl)
+//GO(d2i_ASN1_PRINTABLE,
+GO(d2i_ASN1_PRINTABLESTRING, pFppl)
+//GO(d2i_ASN1_SEQUENCE_ANY,
+//GO(d2i_ASN1_SET,
+GO(d2i_ASN1_SET_ANY, pFppl)
+GO(d2i_ASN1_T61STRING, pFppl)
+GO(d2i_ASN1_TIME, pFppl)
+GO(d2i_ASN1_TYPE, pFppl)
+//GO(d2i_ASN1_type_bytes,
+GO(d2i_ASN1_UINTEGER, pFppl)
+GO(d2i_ASN1_UNIVERSALSTRING, pFppl)
+GO(d2i_ASN1_UTCTIME, pFppl)
+GO(d2i_ASN1_UTF8STRING, pFppl)
+GO(d2i_ASN1_VISIBLESTRING, pFppl)
+//GO(d2i_AUTHORITY_INFO_ACCESS,
+//GO(d2i_AUTHORITY_KEYID,
+GO(d2i_AutoPrivateKey, pFppl)
+GO(d2i_BASIC_CONSTRAINTS, pFppl)
+//GO(d2i_CERTIFICATEPOLICIES,
+//GO(d2i_CMS_bio,
+//GO(d2i_CMS_ContentInfo,
+//GO(d2i_CMS_ReceiptRequest,
+//GO(d2i_CRL_DIST_POINTS,
+GO(d2i_DHparams, pFppl)
+//GO(d2i_DHxparams,
+//GO(d2i_DIRECTORYSTRING,
+GO(d2i_DISPLAYTEXT, pFppl)
+//GO(d2i_DIST_POINT,
+//GO(d2i_DIST_POINT_NAME,
+//GO(d2i_DSAparams,
+GO(d2i_DSAPrivateKey, pFppl)
+GO(d2i_DSAPrivateKey_bio, pFpp)
+GO(d2i_DSAPrivateKey_fp, pFpp)
+GO(d2i_DSA_PUBKEY, pFppl)
+GO(d2i_DSA_PUBKEY_bio, pFpp)
+GO(d2i_DSA_PUBKEY_fp, pFpp)
+//GO(d2i_DSAPublicKey,
+//GO(d2i_DSA_SIG,
+//GO(d2i_ECDSA_SIG,
+//GO(d2i_ECParameters,
+//GO(d2i_ECPKParameters,
+//GO(d2i_ECPKPARAMETERS,
+//GO(d2i_ECPrivateKey,
+GO(d2i_EC_PRIVATEKEY, pFppl)
+GO(d2i_ECPrivateKey_bio, pFpp)
+GO(d2i_ECPrivateKey_fp, pFpp)
+GO(d2i_EC_PUBKEY, pFppl)
+GO(d2i_EC_PUBKEY_bio, pFpp)
+GO(d2i_EC_PUBKEY_fp, pFpp)
+//GO(d2i_EDIPARTYNAME,
+//GO(d2i_ESS_CERT_ID,
+//GO(d2i_ESS_ISSUER_SERIAL,
+//GO(d2i_ESS_SIGNING_CERT,
+GO(d2i_EXTENDED_KEY_USAGE, pFppl)
+//GO(d2i_GENERAL_NAME,
+//GO(d2i_GENERAL_NAMES,
+//GO(d2i_int_dhx,
+//GO(d2i_ISSUING_DIST_POINT,
+//GO(d2i_KRB5_APREQ,
+//GO(d2i_KRB5_APREQBODY,
+//GO(d2i_KRB5_AUTHDATA,
+//GO(d2i_KRB5_AUTHENT,
+//GO(d2i_KRB5_AUTHENTBODY,
+//GO(d2i_KRB5_CHECKSUM,
+//GO(d2i_KRB5_ENCDATA,
+//GO(d2i_KRB5_ENCKEY,
+//GO(d2i_KRB5_PRINCNAME,
+//GO(d2i_KRB5_TICKET,
+//GO(d2i_KRB5_TKTBODY,
+//GO(d2i_NETSCAPE_CERT_SEQUENCE,
+//GO(d2i_NETSCAPE_ENCRYPTED_PKEY,
+//GO(d2i_NETSCAPE_PKEY,
+//GO(d2i_Netscape_RSA,
+//GO(d2i_NETSCAPE_SPKAC,
+//GO(d2i_NETSCAPE_SPKI,
+//GO(d2i_NETSCAPE_X509,
+//GO(d2i_NOTICEREF,
+//GO(d2i_OCSP_BASICRESP,
+//GO(d2i_OCSP_CERTID,
+//GO(d2i_OCSP_CERTSTATUS,
+//GO(d2i_OCSP_CRLID,
+//GO(d2i_OCSP_ONEREQ,
+//GO(d2i_OCSP_REQINFO,
+//GO(d2i_OCSP_REQUEST,
+//GO(d2i_OCSP_RESPBYTES,
+//GO(d2i_OCSP_RESPDATA,
+//GO(d2i_OCSP_RESPID,
+GO(d2i_OCSP_RESPONSE, pFppl)
+//GO(d2i_OCSP_REVOKEDINFO,
+//GO(d2i_OCSP_SERVICELOC,
+//GO(d2i_OCSP_SIGNATURE,
+//GO(d2i_OCSP_SINGLERESP,
+//GO(d2i_OTHERNAME,
+//GO(d2i_PBE2PARAM,
+//GO(d2i_PBEPARAM,
+//GO(d2i_PBKDF2PARAM,
+GO(d2i_PKCS12, pFppl)
+//GO(d2i_PKCS12_BAGS,
+GO(d2i_PKCS12_bio, pFpp)
+GO(d2i_PKCS12_fp, pFpp)
+//GO(d2i_PKCS12_MAC_DATA,
+//GO(d2i_PKCS12_SAFEBAG,
+GO(d2i_PKCS7, pFppl)
+GO(d2i_PKCS7_bio, pFpp)
+//GO(d2i_PKCS7_DIGEST,
+//GO(d2i_PKCS7_ENC_CONTENT,
+//GO(d2i_PKCS7_ENCRYPT,
+//GO(d2i_PKCS7_ENVELOPE,
+GO(d2i_PKCS7_fp, pFpp)
+//GO(d2i_PKCS7_ISSUER_AND_SERIAL,
+//GO(d2i_PKCS7_RECIP_INFO,
+//GO(d2i_PKCS7_SIGNED,
+//GO(d2i_PKCS7_SIGN_ENVELOPE,
+//GO(d2i_PKCS7_SIGNER_INFO,
+GO(d2i_PKCS8_bio, pFpp)
+GO(d2i_PKCS8_fp, pFpp)
+GO(d2i_PKCS8PrivateKey_bio, pFpp)
+GO(d2i_PKCS8PrivateKey_fp, pFpp)
+GO(d2i_PKCS8_PRIV_KEY_INFO, pFppl)
+GO(d2i_PKCS8_PRIV_KEY_INFO_bio, pFpp)
+GO(d2i_PKCS8_PRIV_KEY_INFO_fp, pFpp)
+//GO(d2i_PKEY_USAGE_PERIOD,
+//GO(d2i_POLICYINFO,
+//GO(d2i_POLICYQUALINFO,
+GO(d2i_PrivateKey, pFppl)
+GO(d2i_PrivateKey_bio, pFpp)
+GO(d2i_PrivateKey_fp, pFpp)
+//GO(d2i_PROXY_CERT_INFO_EXTENSION,
+//GO(d2i_PROXY_POLICY,
+GO(d2i_PUBKEY, pFppl)
+GO(d2i_PUBKEY_bio, pFpp)
+GO(d2i_PUBKEY_fp, pFpp)
+//GO(d2i_PublicKey,
+//GO(d2i_RSA_NET,
+//GO(d2i_RSA_OAEP_PARAMS,
+GO(d2i_RSAPrivateKey, pFppl)
+GO(d2i_RSAPrivateKey_bio, pFpp)
+GO(d2i_RSAPrivateKey_fp, pFpp)
+//GO(d2i_RSA_PSS_PARAMS,
+GO(d2i_RSA_PUBKEY, pFppl)
+GO(d2i_RSA_PUBKEY_bio, pFpp)
+GO(d2i_RSA_PUBKEY_fp, pFpp)
+GO(d2i_RSAPublicKey, pFppl)
+GO(d2i_RSAPublicKey_bio, pFpp)
+GO(d2i_RSAPublicKey_fp, pFpp)
+//GO(d2i_SXNET,
+//GO(d2i_SXNETID,
+//GO(d2i_TS_ACCURACY,
+GO(d2i_TS_MSG_IMPRINT, pFppl)
+GO(d2i_TS_MSG_IMPRINT_bio, pFpp)
+GO(d2i_TS_MSG_IMPRINT_fp, pFpp)
+GO(d2i_TS_REQ, pFppl)
+GO(d2i_TS_REQ_bio, pFpp)
+GO(d2i_TS_REQ_fp, pFpp)
+GO(d2i_TS_RESP, pFppl)
+GO(d2i_TS_RESP_bio, pFpp)
+GO(d2i_TS_RESP_fp, pFpp)
+//GO(d2i_TS_STATUS_INFO,
+GO(d2i_TS_TST_INFO, pFppl)
+GO(d2i_TS_TST_INFO_bio, pFpp)
+GO(d2i_TS_TST_INFO_fp, pFpp)
+//GO(d2i_USERNOTICE,
+GO(d2i_X509, pFppl)
+//GO(d2i_X509_ALGOR,
+//GO(d2i_X509_ALGORS,
+//GO(d2i_X509_ATTRIBUTE,
+//GO(d2i_X509_AUX,
+GO(d2i_X509_bio, pFpp)
+//GO(d2i_X509_CERT_AUX,
+//GO(d2i_X509_CERT_PAIR,
+//GO(d2i_X509_CINF,
+GO(d2i_X509_CRL, pFppl)
+GO(d2i_X509_CRL_bio, pFpp)
+GO(d2i_X509_CRL_fp, pFpp)
+//GO(d2i_X509_CRL_INFO,
+//GO(d2i_X509_EXTENSION,
+//GO(d2i_X509_EXTENSIONS,
+GO(d2i_X509_fp, pFppl)
+GO(d2i_X509_NAME, pFppl)
+//GO(d2i_X509_NAME_ENTRY,
+//GO(d2i_X509_PKEY,
+//GO(d2i_X509_PUBKEY,
+GO(d2i_X509_REQ, pFppl)
+GO(d2i_X509_REQ_bio, pFpp)
+GO(d2i_X509_REQ_fp, pFpp)
+//GO(d2i_X509_REQ_INFO,
+//GO(d2i_X509_REVOKED,
+//GO(d2i_X509_SIG,
+//GO(d2i_X509_VAL,
+GO(DES_cbc_cksum, uFppipp)
+GO(DES_cbc_encrypt, vFppippi)
+GO(DES_cfb64_encrypt, vFppippppi)
+GO(DES_cfb_encrypt, vFppilppi)
+//GO(DES_check_key_parity,
+//GO(_des_crypt,
+GO(DES_crypt, pFpp)
+//GO(DES_decrypt3,
+GO(DES_ecb3_encrypt, vFpppppi)
+GO(DES_ecb_encrypt, vFpppi)
+GO(DES_ede3_cbc_encrypt, vFppippppi)
+//GO(DES_ede3_cbcm_encrypt,
+GO(DES_ede3_cfb64_encrypt, vFpplpppppi)
+//GO(DES_ede3_cfb_encrypt,
+GO(DES_ede3_ofb64_encrypt, vFpplppppp)
+//GO(DES_enc_read,
+//GO(DES_encrypt1,
+//GO(DES_encrypt2,
+//GO(DES_encrypt3,
+//GO(DES_enc_write,
+GO(DES_fcrypt, pFppp)
+GO(DES_is_weak_key, iFp)
+GO(DES_key_sched, iFpp)
+GO(DES_ncbc_encrypt, vFpplppi)
+GO(DES_ofb64_encrypt, vFpplppp)
+GO(DES_ofb_encrypt, vFppilpp)
+//GO(DES_options,
+GO(DES_pcbc_encrypt, vFppippi)
+GO(DES_quad_cksum, uFpplip)
+GO(DES_random_key, vFp)
+//GO(DES_read_2passwords,
+//GO(DES_read_password,
+GO(DES_set_key, iFpp)
+GO(DES_set_key_checked, iFpp)
+GO(DES_set_key_unchecked, iFpp)
+GO(DES_set_odd_parity, vFp)
+GO(DES_string_to_2keys, vFppp)
+GO(DES_string_to_key, vFpp)
+GO(DES_xcbc_encrypt, vFpplppppi)
+//GO(DH_check,
+//GO(DH_check_pub_key,
+//GO(DH_compute_key,
+//GO(DH_compute_key_padded,
+GO(DH_free, vFp)
+//GO(DH_generate_key,
+//GO(DH_generate_parameters,
+//GO(DH_generate_parameters_ex,
+//GO(DH_get_1024_160,
+//GO(DH_get_2048_224,
+//GO(DH_get_2048_256,
+//GO(DH_get_default_method,
+//GO(DH_get_ex_data,
+//GO(DH_get_ex_new_index,
+//GO(DH_KDF_X9_42,
+GO(DH_new, pFv)
+//GO(DH_new_method,
+//GO(DH_OpenSSL,
+//GO(DHparams_dup,
+//GO(DHparams_print,
+//GO(DHparams_print_fp,
+//GO(DH_set_default_method,
+//GO(DH_set_ex_data,
+//GO(DH_set_method,
+//GO(DH_size,
+//GO(DH_up_ref,
+//GO(DIRECTORYSTRING_free,
+//GO(DIRECTORYSTRING_new,
+GO(DISPLAYTEXT_free, vFp)
+GO(DISPLAYTEXT_new, pFv)
+//GO(DIST_POINT_free,
+//GO(DIST_POINT_NAME_free,
+//GO(DIST_POINT_NAME_new,
+//GO(DIST_POINT_new,
+//GO(DIST_POINT_set_dpname,
+//GO(dsa_builtin_paramgen,
+//GO(dsa_builtin_paramgen2,
+//GO(DSA_do_sign,
+//GO(DSA_do_verify,
+//GO(DSA_dup_DH,
+GO(DSA_free, vFp)
+GO(DSA_generate_key, iFp)
+//GO(DSA_generate_parameters,
+GO(DSA_generate_parameters_ex, iFpipippp)
+GO(DSA_get0_key, vFppp)
+GO(DSA_get0_pqg, vFpppp)
+//GO(DSA_get_default_method,
+//GO(DSA_get_ex_data,
+//GO(DSA_get_ex_new_index,
+GO(DSA_get_method, pFp)
+GO(DSA_new, pFv)
+//GO(DSA_new_method,
+GO(DSA_OpenSSL, pFv)
+//GO(dsa_paramgen_check_g,
+GO(DSA_set0_key, iFppp)
+GO(DSA_set0_pqg, iFppp)
+//GO(DSAparams_dup,
+//GO(DSAparams_print,
+//GO(DSAparams_print_fp,
+//GO(DSA_print,
+//GO(DSA_print_fp,
+//GO(DSA_set_default_method,
+//GO(DSA_set_ex_data,
+//GO(DSA_set_method,
+//GO(DSA_SIG_free,
+GO(DSA_sign, iFipippp)
+//GO(DSA_SIG_new,
+//GO(DSA_sign_setup,
+GO(DSA_size, iFp)
+GO(DSA_up_ref, iFp)
+GO(DSA_verify, iFipipip)
+//GO(DSO_bind_func,
+//GO(DSO_bind_var,
+//GO(DSO_convert_filename,
+//GO(DSO_ctrl,
+//GO(DSO_flags,
+//GO(DSO_free,
+//GO(DSO_get_default_method,
+//GO(DSO_get_filename,
+//GO(DSO_get_loaded_filename,
+//GO(DSO_get_method,
+//GO(DSO_global_lookup,
+//GO(DSO_load,
+//GO(DSO_merge,
+//GO(DSO_METHOD_beos,
+//GO(DSO_METHOD_dl,
+//GO(DSO_METHOD_dlfcn,
+//GO(DSO_METHOD_null,
+//GO(DSO_METHOD_openssl,
+//GO(DSO_METHOD_vms,
+//GO(DSO_METHOD_win32,
+//GO(DSO_new,
+//GO(DSO_new_method,
+//GO(DSO_pathbyaddr,
+//GO(DSO_set_default_method,
+//GO(DSO_set_filename,
+//GO(DSO_set_method,
+//GO(DSO_set_name_converter,
+//GO(DSO_up_ref,
+GO(EC_curve_nid2nist, pFi)
+GO(EC_curve_nist2nid, iFp)
+//GO(ecdh_check,
+//GO(ECDH_compute_key,
+//GO(ECDH_get_default_method,
+//GO(ECDH_get_ex_data,
+//GO(ECDH_get_ex_new_index,
+//GO(ECDH_KDF_X9_62,
+//GO(ECDH_OpenSSL,
+//GO(ECDH_set_default_method,
+//GO(ECDH_set_ex_data,
+//GO(ECDH_set_method,
+//GO(ecdsa_check,
+//GO(ECDSA_do_sign,
+GO(ECDSA_do_sign_ex, pFpippp)
+GO(ECDSA_do_verify, iFpipp)
+//GO(ECDSA_get_default_method,
+//GO(ECDSA_get_ex_data,
+//GO(ECDSA_get_ex_new_index,
+//GO(ECDSA_METHOD_free,
+//GO(ECDSA_METHOD_get_app_data,
+//GO(ECDSA_METHOD_new,
+//GO(ECDSA_METHOD_set_app_data,
+//GO(ECDSA_METHOD_set_flags,
+//GO(ECDSA_METHOD_set_name,
+//GO(ECDSA_METHOD_set_sign,
+//GO(ECDSA_METHOD_set_sign_setup,
+//GO(ECDSA_METHOD_set_verify,
+//GO(ECDSA_OpenSSL,
+//GO(ECDSA_set_default_method,
+//GO(ECDSA_set_ex_data,
+//GO(ECDSA_set_method,
+GO(ECDSA_SIG_free, vFp)
+GO(ECDSA_sign, iFipippp)
+GO(ECDSA_SIG_get0, vFppp)
+GO(ECDSA_SIG_new, pFv)
+GO(ECDSA_SIG_set0, iFppp)
+GO(ECDSA_sign_ex, iFipippppp)
+GO(ECDSA_sign_setup, iFpppp)
+GO(ECDSA_size, iFp)
+GO(ECDSA_verify, iFipipip)
+//GO(EC_EX_DATA_clear_free_all_data,
+//GO(EC_EX_DATA_clear_free_data,
+//GO(EC_EX_DATA_free_all_data,
+//GO(EC_EX_DATA_free_data,
+//GO(EC_EX_DATA_get_data,
+//GO(EC_EX_DATA_set_data,
+GO(EC_get_builtin_curves, LFpL)
+//GO(ec_GF2m_have_precompute_mult,
+//GO(ec_GF2m_precompute_mult,
+//GO(ec_GF2m_simple_add,
+//GO(ec_GF2m_simple_cmp,
+//GO(ec_GF2m_simple_dbl,
+//GO(ec_GF2m_simple_field_div,
+//GO(ec_GF2m_simple_field_mul,
+//GO(ec_GF2m_simple_field_sqr,
+//GO(ec_GF2m_simple_group_check_discriminant,
+//GO(ec_GF2m_simple_group_clear_finish,
+//GO(ec_GF2m_simple_group_copy,
+//GO(ec_GF2m_simple_group_finish,
+//GO(ec_GF2m_simple_group_get_curve,
+//GO(ec_GF2m_simple_group_get_degree,
+//GO(ec_GF2m_simple_group_init,
+//GO(ec_GF2m_simple_group_set_curve,
+//GO(ec_GF2m_simple_invert,
+//GO(ec_GF2m_simple_is_at_infinity,
+//GO(ec_GF2m_simple_is_on_curve,
+//GO(ec_GF2m_simple_make_affine,
+GO(EC_GF2m_simple_method, pFv)
+//GO(ec_GF2m_simple_mul,
+//GO(ec_GF2m_simple_oct2point,
+//GO(ec_GF2m_simple_point2oct,
+//GO(ec_GF2m_simple_point_clear_finish,
+//GO(ec_GF2m_simple_point_copy,
+//GO(ec_GF2m_simple_point_finish,
+//GO(ec_GF2m_simple_point_get_affine_coordinates,
+//GO(ec_GF2m_simple_point_init,
+//GO(ec_GF2m_simple_point_set_affine_coordinates,
+//GO(ec_GF2m_simple_point_set_to_infinity,
+//GO(ec_GF2m_simple_points_make_affine,
+//GO(ec_GF2m_simple_set_compressed_coordinates,
+//GO(ec_GFp_mont_field_decode,
+//GO(ec_GFp_mont_field_encode,
+//GO(ec_GFp_mont_field_mul,
+//GO(ec_GFp_mont_field_set_to_one,
+//GO(ec_GFp_mont_field_sqr,
+//GO(ec_GFp_mont_group_clear_finish,
+//GO(ec_GFp_mont_group_copy,
+//GO(ec_GFp_mont_group_finish,
+//GO(ec_GFp_mont_group_init,
+//GO(ec_GFp_mont_group_set_curve,
+GO(EC_GFp_mont_method, pFv)
+//GO(ec_GFp_nist_field_mul,
+//GO(ec_GFp_nist_field_sqr,
+//GO(ec_GFp_nist_group_copy,
+//GO(ec_GFp_nist_group_set_curve,
+GO(EC_GFp_nist_method, pFv)
+GO(EC_GFp_nistp224_method, pFv)
+GO(EC_GFp_nistp256_method, pFv)
+GO(EC_GFp_nistp521_method, pFv)
+//GO(ec_GFp_simple_add,
+//GO(ec_GFp_simple_cmp,
+//GO(ec_GFp_simple_dbl,
+//GO(ec_GFp_simple_field_mul,
+//GO(ec_GFp_simple_field_sqr,
+//GO(ec_GFp_simple_get_Jprojective_coordinates_GFp,
+//GO(ec_GFp_simple_group_check_discriminant,
+//GO(ec_GFp_simple_group_clear_finish,
+//GO(ec_GFp_simple_group_copy,
+//GO(ec_GFp_simple_group_finish,
+//GO(ec_GFp_simple_group_get_curve,
+//GO(ec_GFp_simple_group_get_degree,
+//GO(ec_GFp_simple_group_init,
+//GO(ec_GFp_simple_group_set_curve,
+//GO(ec_GFp_simple_invert,
+//GO(ec_GFp_simple_is_at_infinity,
+//GO(ec_GFp_simple_is_on_curve,
+//GO(ec_GFp_simple_make_affine,
+GO(EC_GFp_simple_method, pFv)
+//GO(ec_GFp_simple_oct2point,
+//GO(ec_GFp_simple_point2oct,
+//GO(ec_GFp_simple_point_clear_finish,
+//GO(ec_GFp_simple_point_copy,
+//GO(ec_GFp_simple_point_finish,
+//GO(ec_GFp_simple_point_get_affine_coordinates,
+//GO(ec_GFp_simple_point_init,
+//GO(ec_GFp_simple_point_set_affine_coordinates,
+//GO(ec_GFp_simple_point_set_to_infinity,
+//GO(ec_GFp_simple_points_make_affine,
+//GO(ec_GFp_simple_set_compressed_coordinates,
+//GO(ec_GFp_simple_set_Jprojective_coordinates_GFp,
+GO(EC_GROUP_check, iFpp)
+GO(EC_GROUP_check_discriminant, iFpp)
+GO(EC_GROUP_clear_free, vFp)
+//GO(EC_GROUP_cmp,
+//GO(EC_GROUP_copy,
+//GO(EC_GROUP_dup,
+GO(EC_GROUP_free, vFp)
+GO(EC_GROUP_get0_generator, pFp)
+GO(EC_GROUP_get0_seed, pFp)
+//GO(EC_GROUP_get_asn1_flag,
+//GO(EC_GROUP_get_basis_type,
+GO(EC_GROUP_get_cofactor, iFppp)
+GO(EC_GROUP_get_curve_GF2m, iFppppp)
+GO(EC_GROUP_get_curve_GFp, iFppppp)
+GO(EC_GROUP_get_curve_name, iFp)
+GO(EC_GROUP_get_degree, iFp)
+GO(EC_GROUP_get_ecparameters, pFpp)
+GO(EC_GROUP_get_ecpkparameters, pFpp)
+//GO(EC_GROUP_get_mont_data,
+GO(EC_GROUP_get_order, iFppp)
+//GO(EC_GROUP_get_pentanomial_basis,
+//GO(EC_GROUP_get_point_conversion_form,
+GO(EC_GROUP_get_seed_len, LFp)
+//GO(EC_GROUP_get_trinomial_basis,
+//GO(EC_GROUP_have_precompute_mult,
+GO(EC_GROUP_method_of, pFp)
+GO(EC_GROUP_new, pFp)
+GO(EC_GROUP_new_by_curve_name, pFi)
+GO(EC_GROUP_new_curve_GF2m, pFpppp)
+GO(EC_GROUP_new_curve_GFp, pFpppp)
+GO(EC_GROUP_new_from_ecparameters, pFp)
+GO(EC_GROUP_new_from_ecpkparameters, pFp)
+GO(EC_GROUP_precompute_mult, iFpp)
+//GO(EC_GROUP_set_asn1_flag,
+GO(EC_GROUP_set_curve_GF2m, iFppppp)
+GO(EC_GROUP_set_curve_GFp, iFppppp)
+//GO(EC_GROUP_set_curve_name,
+GO(EC_GROUP_set_generator, iFpppp)
+//GO(EC_GROUP_set_point_conversion_form,
+GO(EC_GROUP_set_seed, LFppL)
+GO(EC_KEY_check_key, iFp)
+//GO(EC_KEY_clear_flags,
+//GO(EC_KEY_copy,
+GO(EC_KEY_dup, pFp)
+GO(EC_KEY_free, vFp)
+GO(EC_KEY_generate_key, iFp)
+GO(EC_KEY_get0_group, pFp)
+GO(EC_KEY_get0_private_key, pFp)
+GO(EC_KEY_get0_public_key, pFp)
+//GO(EC_KEY_get_conv_form,
+//GO(EC_KEY_get_enc_flags,
+//GO(EC_KEY_get_flags,
+//GO(EC_KEY_get_key_method_data,
+//GO(EC_KEY_insert_key_method_data,
+GO(EC_KEY_new, pFv)
+GO(EC_KEY_new_by_curve_name, pFi)
+//GO(EC_KEY_precompute_mult,
+//GO(EC_KEY_print,
+//GO(EC_KEY_print_fp,
+GO(EC_KEY_set_asn1_flag, vFpi)
+//GO(EC_KEY_set_conv_form,
+//GO(EC_KEY_set_enc_flags,
+//GO(EC_KEY_set_flags,
+GO(EC_KEY_set_group, iFpp)
+GO(EC_KEY_set_private_key, iFpp)
+GO(EC_KEY_set_public_key, iFpp)
+GO(EC_KEY_set_public_key_affine_coordinates, iFppp)
+GO(EC_KEY_up_ref, iFp)
+GO(EC_METHOD_get_field_type, iFp)
+//GO(ECPARAMETERS_free,
+//GO(ECPARAMETERS_new,
+//GO(ECParameters_print,
+//GO(ECParameters_print_fp,
+//GO(ECPKPARAMETERS_free,
+//GO(ECPKPARAMETERS_new,
+//GO(ECPKParameters_print,
+//GO(ECPKParameters_print_fp,
+//GO(EC_POINT_add,
+//GO(EC_POINT_bn2point,
+GO(EC_POINT_clear_free, vFp)
+//GO(EC_POINT_cmp,
+GO(EC_POINT_copy, iFpp)
+//GO(EC_POINT_dbl,
+GO(EC_POINT_dup, pFpp)
+GO(EC_POINT_free, vFp)
+GO(EC_POINT_get_affine_coordinates, iFppppp)
+GO(EC_POINT_get_affine_coordinates_GF2m, iFppppp)
+GO(EC_POINT_get_affine_coordinates_GFp, iFppppp)
+GO(EC_POINT_get_Jprojective_coordinates_GFp, iFpppppp)
+//GO(EC_POINT_hex2point,
+//GO(EC_POINT_invert,
+//GO(EC_POINT_is_at_infinity,
+//GO(EC_POINT_is_on_curve,
+//GO(EC_POINT_make_affine,
+GO(EC_POINT_method_of, pFp)
+GO(EC_POINT_mul, iFpppppp)
+GO(EC_POINT_new, pFp)
+//GO(EC_POINT_oct2point,
+//GO(EC_POINT_point2buf,
+//GO(EC_POINT_point2bn,
+//GO(EC_POINT_point2hex,
+//GO(EC_POINT_point2oct,
+GO(EC_POINT_set_affine_coordinates, iFppppp)
+GO(EC_POINT_set_affine_coordinates_GF2m, iFppppp)
+GO(EC_POINT_set_affine_coordinates_GFp, iFppppp)
+GO(EC_POINT_set_compressed_coordinates, iFpppip)
+GO(EC_POINT_set_compressed_coordinates_GF2m, iFpppip)
+GO(EC_POINT_set_compressed_coordinates_GFp, iFpppip)
+GO(EC_POINT_set_Jprojective_coordinates_GFp, iFpppppp)
+GO(EC_POINT_set_to_infinity, iFpp)
+//GO(EC_POINTs_make_affine,
+//GO(EC_POINTs_mul,
+//GO(ec_precompute_mont_data,
+//GO(EC_PRIVATEKEY_free,
+//GO(EC_PRIVATEKEY_new,
+//GO(ec_wNAF_have_precompute_mult,
+//GO(ec_wNAF_mul,
+//GO(ec_wNAF_precompute_mult,
+//GO(EDIPARTYNAME_free,
+//GO(EDIPARTYNAME_new,
+GO(ENGINE_add, iFp)
+//GO(ENGINE_add_conf_module,
+GO(ENGINE_by_id, pFp)
+GO(ENGINE_cleanup, vFv)
+//GO(engine_cleanup_add_first,
+//GO(engine_cleanup_add_last,
+GO(ENGINE_cmd_is_executable, iFpi)
+GOM(ENGINE_ctrl, iFEpiipp)
+GOM(ENGINE_ctrl_cmd, iFpplppi)
+GO(ENGINE_ctrl_cmd_string, iFpppi)
+GO(ENGINE_finish, iFp)
+GO(ENGINE_free, iFp)
+//GO(engine_free_util,
+//GO(ENGINE_get_cipher,
+GO(ENGINE_get_cipher_engine, pFi)
+//GOM(ENGINE_get_ciphers, pFEp)
+//GOM(ENGINE_get_cmd_defns, pFEp)
+//GOM(ENGINE_get_ctrl_function, pFEp)
+GO(ENGINE_get_default_DH, pFv)
+GO(ENGINE_get_default_DSA, pFv)
+GO(ENGINE_get_default_ECDH, pFv)
+GO(ENGINE_get_default_ECDSA, pFv)
+GO(ENGINE_get_default_RAND, pFv)
+GO(ENGINE_get_default_RSA, pFv)
+//GOM(ENGINE_get_destroy_function, pFEp)
+GO(ENGINE_get_DH, pFp)
+//GOM(ENGINE_get_digest, pFEp)
+GO(ENGINE_get_digest_engine, pFi)
+//GO(ENGINE_get_digests,
+GO(ENGINE_get_DSA, pFp)
+GO(ENGINE_get_ECDH, pFp)
+GO(ENGINE_get_ECDSA, pFp)
+//GO(ENGINE_get_ex_data,
+//GO(ENGINE_get_ex_new_index,
+//GOM(ENGINE_get_finish_function, pFEp)
+GO(ENGINE_get_first, iFp)
+GO(ENGINE_get_flags, iFp)
+GO(ENGINE_get_id, pFp)
+//GOM(ENGINE_get_init_function, pFEp)
+GO(ENGINE_get_last, pFv)
+//GOM(ENGINE_get_load_privkey_function, pFEp)
+//GOM(ENGINE_get_load_pubkey_function, pFEp)
+GO(ENGINE_get_name, pFp)
+GO(ENGINE_get_next, pFp)
+//GO(ENGINE_get_pkey_asn1_meth,
+//GO(ENGINE_get_pkey_asn1_meth_engine,
+//GO(ENGINE_get_pkey_asn1_meths,
+//GO(ENGINE_get_pkey_asn1_meth_str,
+//GO(ENGINE_get_pkey_meth,
+//GO(ENGINE_get_pkey_meth_engine,
+//GO(ENGINE_get_pkey_meths,
+GO(ENGINE_get_prev, pFp)
+GO(ENGINE_get_RAND, pFp)
+GO(ENGINE_get_RSA, pFp)
+//GO(ENGINE_get_ssl_client_cert_function,
+//GO(ENGINE_get_static_state,
+//GO(ENGINE_get_STORE,
+GO(ENGINE_get_table_flags, uFv)
+GO(ENGINE_init, iFp)
+GO(ENGINE_load_builtin_engines, vFv)
+//GO(ENGINE_load_cryptodev,
+//GO(ENGINE_load_dynamic,
+//GO(ENGINE_load_openssl,
+GO(ENGINE_load_private_key, pFpppp)
+GO(ENGINE_load_public_key, pFpppp)
+//GO(ENGINE_load_rdrand,
+//GO(ENGINE_load_ssl_client_cert,
+GO(ENGINE_new, pFv)
+//GO(ENGINE_pkey_asn1_find_str,
+//GO(engine_pkey_asn1_meths_free,
+//GO(engine_pkey_meths_free,
+GO(ENGINE_register_all_ciphers, vFv)
+GO(ENGINE_register_all_complete, iFv)
+GO(ENGINE_register_all_DH, vFv)
+GO(ENGINE_register_all_digests, vFv)
+GO(ENGINE_register_all_DSA, vFv)
+GO(ENGINE_register_all_ECDH, vFv)
+GO(ENGINE_register_all_ECDSA, vFv)
+//GO(ENGINE_register_all_pkey_asn1_meths,
+//GO(ENGINE_register_all_pkey_meths,
+GO(ENGINE_register_all_RAND, vFv)
+GO(ENGINE_register_all_RSA, vFv)
+//GO(ENGINE_register_all_STORE,
+GO(ENGINE_register_ciphers, iFp)
+GO(ENGINE_register_complete, iFp)
+GO(ENGINE_register_DH, iFp)
+GO(ENGINE_register_digests, iFp)
+GO(ENGINE_register_DSA, iFp)
+GO(ENGINE_register_ECDH, iFp)
+GO(ENGINE_register_ECDSA, iFp)
+//GO(ENGINE_register_pkey_asn1_meths,
+//GO(ENGINE_register_pkey_meths,
+GO(ENGINE_register_RAND, iFp)
+GO(ENGINE_register_RSA, iFp)
+//GO(ENGINE_register_STORE,
+GO(ENGINE_remove, iFp)
+//GO(engine_set_all_null,
+//GOM(ENGINE_set_ciphers, iFEpp) //typedef int (*ENGINE_CIPHERS_PTR)(ENGINE *e, const EVP_CIPHER **impl, const int **nids, int nid)
+//GOM(ENGINE_set_cmd_defns, iFEpp)
+//GO(ENGINE_set_ctrl_function,
+GO(ENGINE_set_default, iFpu)
+GO(ENGINE_set_default_ciphers, iFp)
+GO(ENGINE_set_default_DH, iFp)
+GO(ENGINE_set_default_digests, iFp)
+GO(ENGINE_set_default_DSA, iFp)
+GO(ENGINE_set_default_ECDH, iFp)
+GO(ENGINE_set_default_ECDSA, iFp)
+//GO(ENGINE_set_default_pkey_asn1_meths,
+//GO(ENGINE_set_default_pkey_meths,
+GO(ENGINE_set_default_RAND, iFp)
+GO(ENGINE_set_default_RSA, iFp)
+GO(ENGINE_set_default_string, iFpp)
+//GOM(ENGINE_set_destroy_function, iFEpp)
+//GO(ENGINE_set_DH,
+//GOM(ENGINE_set_digests, iFEpp)
+GO(ENGINE_set_DSA, iFpp)
+GO(ENGINE_set_ECDH, iFpp)
+GO(ENGINE_set_ECDSA, iFpp)
+//GO(ENGINE_set_ex_data,
+//GOM(ENGINE_set_finish_function, iFEpp)
+GO(ENGINE_set_flags, iFpi)
+GO(ENGINE_set_id, iFpp)
+//GOM(ENGINE_set_init_function, iFEpp)
+//GOM(ENGINE_set_load_privkey_function, iFEpp)
+//GOM(ENGINE_set_load_pubkey_function, iFEpp)
+//GOM(ENGINE_set_load_ssl_client_cert_function,
+GO(ENGINE_set_name, iFpp)
+//GO(ENGINE_set_pkey_asn1_meths,
+//GO(ENGINE_set_pkey_meths,
+GO(ENGINE_set_RAND, iFpp)
+GO(ENGINE_set_RSA, iFpp)
+//GO(ENGINE_set_STORE,
+GO(ENGINE_set_table_flags, vFu)
+//GO(engine_table_cleanup,
+//GO(engine_table_doall,
+//GO(engine_table_register,
+//GO(engine_table_select,
+//GO(engine_table_unregister,
+//GO(engine_unlocked_finish,
+//GO(engine_unlocked_init,
+GO(ENGINE_unregister_ciphers, vFp)
+GO(ENGINE_unregister_DH, vFp)
+GO(ENGINE_unregister_digests, vFp)
+GO(ENGINE_unregister_DSA, vFp)
+GO(ENGINE_unregister_ECDH, vFp)
+GO(ENGINE_unregister_ECDSA, vFp)
+//GO(ENGINE_unregister_pkey_asn1_meths,
+//GO(ENGINE_unregister_pkey_meths,
+GO(ENGINE_unregister_RAND, vFp)
+GO(ENGINE_unregister_RSA, vFp)
+//GO(ENGINE_unregister_STORE,
+GO(ENGINE_up_ref, iFp)
+//GO(ERR_add_error_data,
+//GO(ERR_add_error_vdata,
+GO(ERR_clear_error, vFv)
+GO(ERR_error_string, pFup)
+GO(ERR_error_string_n, vFupu)
+GO(ERR_free_strings, vFv)
+GO(ERR_func_error_string, pFu)
+GO(ERR_get_error, LFv)
+GO(ERR_get_error_line, LFpp)
+GO(ERR_get_error_line_data, LFpppp)
+//GO(ERR_get_err_state_table,
+//GO(ERR_get_implementation,
+//GO(ERR_get_next_error_library,
+//GO(ERR_get_state,
+//GO(ERR_get_string_table,
+GO(ERR_lib_error_string, pFu)
+//GO(ERR_load_ASN1_strings,
+//GO(ERR_load_BIO_strings,
+//GO(ERR_load_BN_strings,
+//GO(ERR_load_BUF_strings,
+//GO(ERR_load_CMS_strings,
+//GO(ERR_load_COMP_strings,
+//GO(ERR_load_CONF_strings,
+GO(ERR_load_crypto_strings, vFv)
+GO(ERR_load_CRYPTO_strings, vFv)
+//GO(ERR_load_DH_strings,
+//GO(ERR_load_DSA_strings,
+//GO(ERR_load_DSO_strings,
+//GO(ERR_load_ECDH_strings,
+//GO(ERR_load_ECDSA_strings,
+//GO(ERR_load_EC_strings,
+//GO(ERR_load_ENGINE_strings,
+//GO(ERR_load_ERR_strings,
+GO(ERR_load_EVP_strings, vFv)
+//GO(ERR_load_OBJ_strings,
+//GO(ERR_load_OCSP_strings,
+//GO(ERR_load_PEM_strings,
+//GO(ERR_load_PKCS12_strings,
+GO(ERR_load_PKCS7_strings, vFv)
+//GO(ERR_load_RAND_strings,
+//GO(ERR_load_RSA_strings,
+//GO(ERR_load_strings,
+//GO(ERR_load_TS_strings,
+//GO(ERR_load_UI_strings,
+//GO(ERR_load_X509_strings,
+//GO(ERR_load_X509V3_strings,
+GO(ERR_new, vFv)
+GO(ERR_peek_error, LFv)
+GO(ERR_peek_error_line, LFpp)
+GO(ERR_peek_error_line_data, LFpppp)
+GO(ERR_peek_last_error, LFv)
+GO(ERR_peek_last_error_line, LFpp)
+GO(ERR_peek_last_error_line_data, LFpppp)
+//GO(ERR_pop_to_mark,
+//GO(ERR_print_errors,
+//GO(ERR_print_errors_cb,
+//GO(ERR_print_errors_fp,
+GO(ERR_put_error, vFiiipi)
+GO(ERR_reason_error_string, pFu)
+//GO(ERR_release_err_state_table,
+//GO(ERR_remove_state,
+GO(ERR_remove_thread_state, vFp)
+GO(ERR_set_debug, vFpip)
+GOM(ERR_set_error, vFEiipV)
+GOM(ERR_vset_error, vFEiipA)
+//GO(ERR_set_error_data,
+//GO(ERR_set_implementation,
+//GO(ERR_set_mark,
+//GO(ERR_unload_strings,
+//GO(ESS_CERT_ID_dup,
+//GO(ESS_CERT_ID_free,
+//GO(ESS_CERT_ID_new,
+//GO(ESS_ISSUER_SERIAL_dup,
+//GO(ESS_ISSUER_SERIAL_free,
+//GO(ESS_ISSUER_SERIAL_new,
+//GO(ESS_SIGNING_CERT_dup,
+//GO(ESS_SIGNING_CERT_free,
+//GO(ESS_SIGNING_CERT_new,
+//GO(EVP_add_alg_module,
+//GO(EVP_add_cipher,
+//GO(EVP_add_digest,
+GO(EVP_aes_128_cbc, pFv)
+GO(EVP_aes_128_cbc_hmac_sha1, pFv)
+GO(EVP_aes_128_cbc_hmac_sha256, pFv)
+GO(EVP_aes_128_ccm, pFv)
+GO(EVP_aes_128_cfb, pFv)
+GO(EVP_aes_128_cfb1, pFv)
+GO(EVP_aes_128_cfb128, pFv)
+GO(EVP_aes_128_cfb8, pFv)
+GO(EVP_aes_128_ctr, pFv)
+GO(EVP_aes_128_ecb, pFv)
+GO(EVP_aes_128_gcm, pFv)
+GO(EVP_aes_128_ofb, pFv)
+GO(EVP_aes_128_wrap, pFv)
+GO(EVP_aes_128_xts, pFv)
+GO(EVP_aes_192_cbc, pFv)
+GO(EVP_aes_192_ccm, pFv)
+GO(EVP_aes_192_cfb, pFv)
+GO(EVP_aes_192_cfb1, pFv)
+GO(EVP_aes_192_cfb128, pFv)
+GO(EVP_aes_192_cfb8, pFv)
+GO(EVP_aes_192_ctr, pFv)
+GO(EVP_aes_192_ecb, pFv)
+GO(EVP_aes_192_gcm, pFv)
+GO(EVP_aes_192_ofb, pFv)
+GO(EVP_aes_192_wrap, pFv)
+GO(EVP_aes_256_cbc, pFv)
+GO(EVP_aes_256_cbc_hmac_sha1, pFv)
+GO(EVP_aes_256_cbc_hmac_sha256, pFv)
+GO(EVP_aes_256_ccm, pFv)
+GO(EVP_aes_256_cfb, pFv)
+GO(EVP_aes_256_cfb1, pFv)
+GO(EVP_aes_256_cfb128, pFv)
+GO(EVP_aes_256_cfb8, pFv)
+GO(EVP_aes_256_ctr, pFv)
+GO(EVP_aes_256_ecb, pFv)
+GO(EVP_aes_256_gcm, pFv)
+//GO(EVP_aes_256_ofb,
+//GO(EVP_aes_256_wrap,
+//GO(EVP_aes_256_xts,
+//GO(EVP_bf_cbc,
+//GO(EVP_bf_cfb,
+//GO(EVP_bf_cfb64,
+//GO(EVP_bf_ecb,
+//GO(EVP_bf_ofb,
+//GO(EVP_BytesToKey,
+//GO(EVP_camellia_128_cbc,
+//GO(EVP_camellia_128_cfb1,
+//GO(EVP_camellia_128_cfb128,
+//GO(EVP_camellia_128_cfb8,
+//GO(EVP_camellia_128_ecb,
+//GO(EVP_camellia_128_ofb,
+//GO(EVP_camellia_192_cbc,
+//GO(EVP_camellia_192_cfb1,
+//GO(EVP_camellia_192_cfb128,
+//GO(EVP_camellia_192_cfb8,
+//GO(EVP_camellia_192_ecb,
+//GO(EVP_camellia_192_ofb,
+//GO(EVP_camellia_256_cbc,
+//GO(EVP_camellia_256_cfb1,
+//GO(EVP_camellia_256_cfb128,
+//GO(EVP_camellia_256_cfb8,
+//GO(EVP_camellia_256_ecb,
+//GO(EVP_camellia_256_ofb,
+//GO(EVP_cast5_cbc,
+//GO(EVP_cast5_cfb,
+//GO(EVP_cast5_cfb64,
+//GO(EVP_cast5_ecb,
+//GO(EVP_cast5_ofb,
+GO(EVP_chacha20, pFv)
+GO(EVP_chacha20_poly1305, pFv)
+//GO(EVP_Cipher,
+GO(EVP_CIPHER_asn1_to_param, iFpp)
+//GO(EVP_CIPHER_block_size,
+//GO(EVP_CIPHER_CTX_block_size,
+//GO(EVP_CIPHER_CTX_cipher,
+GO(EVP_CIPHER_CTX_cleanup, iFp)
+//GO(EVP_CIPHER_CTX_clear_flags,
+//GO(EVP_CIPHER_CTX_copy,
+GO(EVP_CIPHER_CTX_ctrl, iFpiip)
+//GO(EVP_CIPHER_CTX_flags,
+GO(EVP_CIPHER_CTX_free, vFp)
+//GO(EVP_CIPHER_CTX_get_app_data,
+GO(EVP_CIPHER_CTX_get_original_iv, iFppL)
+GO(EVP_CIPHER_CTX_get_updated_iv, iFppL)
+GO(EVP_CIPHER_CTX_init, vFp)
+//GO(EVP_CIPHER_CTX_iv_length,
+//GO(EVP_CIPHER_CTX_key_length,
+GO(EVP_CIPHER_CTX_new, pFv)
+//GO(EVP_CIPHER_CTX_nid,
+//GO(EVP_CIPHER_CTX_rand_key,
+GO(EVP_CIPHER_CTX_reset, iFp)
+//GO(EVP_CIPHER_CTX_set_app_data,
+//GO(EVP_CIPHER_CTX_set_flags,
+GO(EVP_CIPHER_CTX_set_key_length, iFpi)
+GO(EVP_CIPHER_CTX_set_padding, iFpi)
+//GO(EVP_CIPHER_CTX_test_flags,
+//GO(EVP_CIPHER_do_all,
+//GO(EVP_CIPHER_do_all_sorted,
+GO(EVP_CipherFinal, iFppp)
+GO(EVP_CipherFinal_ex, iFppp)
+//GO(EVP_CIPHER_flags,
+//GO(EVP_CIPHER_get_asn1_iv,
+GO(EVP_CipherInit, iFppppi)
+GO(EVP_CipherInit_ex, iFpppppi)
+//GO(EVP_CIPHER_iv_length,
+//GO(EVP_CIPHER_key_length,
+//GO(EVP_CIPHER_nid,
+GO(EVP_CIPHER_param_to_asn1, iFpp)
+//GO(EVP_CIPHER_set_asn1_iv,
+GO(EVP_CIPHER_type, iFp)
+GO(EVP_CipherUpdate, iFppppi)
+GO(EVP_cleanup, vFv)
+//GO(EVP_DecodeBlock,
+//GO(EVP_DecodeFinal,
+//GO(EVP_DecodeInit,
+//GO(EVP_DecodeUpdate,
+GO(EVP_DecryptFinal, iFppp)
+GO(EVP_DecryptFinal_ex, iFppp)
+GO(EVP_DecryptInit, iFpppp)
+GO(EVP_DecryptInit_ex, iFppppp)
+GO(EVP_DecryptUpdate, iFppppi)
+GO(EVP_des_cbc, pFv)
+GO(EVP_des_cfb, pFv)
+GO(EVP_des_cfb1, pFv)
+GO(EVP_des_cfb64, pFv)
+GO(EVP_des_cfb8, pFv)
+GO(EVP_des_ecb, pFv)
+GO(EVP_des_ede, pFv)
+GO(EVP_des_ede3, pFv)
+GO(EVP_des_ede3_cbc, pFv)
+GO(EVP_des_ede3_cfb, pFv)
+GO(EVP_des_ede3_cfb1, pFv)
+GO(EVP_des_ede3_cfb64, pFv)
+GO(EVP_des_ede3_cfb8, pFv)
+GO(EVP_des_ede3_ecb, pFv)
+GO(EVP_des_ede3_ofb, pFv)
+GO(EVP_des_ede3_wrap, pFv)
+GO(EVP_des_ede_cbc, pFv)
+GO(EVP_des_ede_cfb, pFv)
+GO(EVP_des_ede_cfb64, pFv)
+GO(EVP_des_ede_ecb, pFv)
+GO(EVP_des_ede_ofb, pFv)
+//GO(EVP_des_ofb,
+//GO(EVP_desx_cbc,
+//GO(EVP_Digest,
+//GO(EVP_DigestFinal,
+GO(EVP_DigestFinal_ex, iFppp)
+GO(EVP_DigestInit, iFpp)
+GO(EVP_DigestInit_ex, iFppp)
+GO(EVP_DigestSignFinal, iFppp)
+//GO(EVP_DigestSignInit,
+GO(EVP_DigestUpdate, iFppL)
+//GO(EVP_DigestVerifyFinal,
+//GO(EVP_DigestVerifyInit,
+//GO(EVP_dss,
+//GO(EVP_dss1,
+//GO(EVP_ecdsa,
+//GO(EVP_enc_null,
+//GO(EVP_EncodeBlock,
+//GO(EVP_EncodeFinal,
+//GO(EVP_EncodeInit,
+//GO(EVP_EncodeUpdate,
+GO(EVP_EncryptFinal, iFppp)
+GO(EVP_EncryptFinal_ex, iFppp)
+GO(EVP_EncryptInit, iFpppp)
+GO(EVP_EncryptInit_ex, iFppppp)
+GO(EVP_EncryptUpdate, iFppppi)
+GO(EVP_get_cipherbyname, pFp)
+GO(EVP_get_digestbyname, pFp)
+//GO(EVP_get_pw_prompt,
+//GO(EVP_idea_cbc,
+//GO(EVP_idea_cfb,
+//GO(EVP_idea_cfb64,
+//GO(EVP_idea_ecb,
+//GO(EVP_idea_ofb,
+GO(EVP_md4, pFv)
+GO(EVP_md5, pFv)
+GO(EVP_MD_block_size, iFp)
+//GO(EVP_mdc2,
+GO(EVP_MD_CTX_cleanup, iFp)
+GO(EVP_MD_CTX_clear_flags, vFpi)
+GO(EVP_MD_CTX_copy, iFpp)
+GO(EVP_MD_CTX_copy_ex, iFpp)
+GO(EVP_MD_CTX_create, pFv)
+GO(EVP_MD_CTX_ctrl, vFpiip)
+GO(EVP_MD_CTX_destroy, vFp)
+GO(EVP_MD_CTX_free, vFp)
+//GO(EVP_MD_CTX_init,
+GO(EVP_MD_CTX_md, pFp)
+GO(EVP_MD_CTX_new, pFv)
+GO(EVP_MD_CTX_reset, iFp)
+GO(EVP_MD_CTX_set_flags, vFpi)
+//GO(EVP_MD_CTX_test_flags,
+//GO(EVP_MD_do_all,
+//GO(EVP_MD_do_all_sorted,
+//GO(EVP_MD_flags,
+GO(EVP_MD_get_size, iFp)
+GO(EVP_md_null, pFv)
+GO(EVP_MD_pkey_type, iFp)
+GO(EVP_MD_type, iFp)
+//GO(EVP_OpenFinal,
+//GO(EVP_OpenInit,
+//GO(EVP_PBE_alg_add,
+//GO(EVP_PBE_alg_add_type,
+//GO(EVP_PBE_CipherInit,
+//GO(EVP_PBE_cleanup,
+//GO(EVP_PBE_find,
+GO(EVP_PKCS82PKEY, pFp)
+GO(EVP_PKCS82PKEY_ex, pFppp)
+GO(EVP_PKEY2PKCS8, pFp)
+//GO(EVP_PKEY2PKCS8_broken,
+//GO(EVP_PKEY_add1_attr,
+//GO(EVP_PKEY_add1_attr_by_NID,
+//GO(EVP_PKEY_add1_attr_by_OBJ,
+//GO(EVP_PKEY_add1_attr_by_txt,
+//GO(EVP_PKEY_asn1_add0,
+//GO(EVP_PKEY_asn1_add_alias,
+//GO(EVP_PKEY_asn1_copy,
+//GO(EVP_PKEY_asn1_find,
+//GO(EVP_PKEY_asn1_find_str,
+//GO(EVP_PKEY_asn1_free,
+//GO(EVP_PKEY_asn1_get0,
+//GO(EVP_PKEY_asn1_get0_info,
+//GO(EVP_PKEY_asn1_get_count,
+//GO(EVP_PKEY_asn1_new,
+//GO(EVP_PKEY_asn1_set_ctrl,
+//GO(EVP_PKEY_asn1_set_free,
+//GO(EVP_PKEY_asn1_set_item,
+//GO(EVP_PKEY_asn1_set_param,
+//GO(EVP_PKEY_asn1_set_private,
+//GO(EVP_PKEY_asn1_set_public,
+GO(EVP_PKEY_assign, iFpip)
+//GO(EVP_PKEY_base_id,
+//GO(EVP_PKEY_bits,
+GO(EVP_PKEY_cmp, iFpp)
+GO(EVP_PKEY_cmp_parameters, iFpp)
+GO(EVP_PKEY_copy_parameters, iFpp)
+GO(EVP_PKEY_CTX_ctrl, iFpiiiip)
+GO(EVP_PKEY_CTX_ctrl_str, iFppp)
+GO(EVP_PKEY_CTX_dup, pFp)
+GO(EVP_PKEY_CTX_free, vFp)
+GO(EVP_PKEY_CTX_get0_peerkey, pFp)
+GO(EVP_PKEY_CTX_get0_pkey, pFp)
+GO(EVP_PKEY_CTX_get_app_data, pFp)
+//GO(EVP_PKEY_CTX_get_cb,
+//GO(EVP_PKEY_CTX_get_data,
+GO(EVP_PKEY_CTX_get_keygen_info, iFpi)
+//GO(EVP_PKEY_CTX_get_operation,
+GO(EVP_PKEY_CTX_new, pFpp)
+GO(EVP_PKEY_CTX_new_id, pFip)
+//GO(EVP_PKEY_CTX_set0_keygen_info,
+GO(EVP_PKEY_CTX_set_app_data, vFpp)
+//GO(EVP_PKEY_CTX_set_cb,
+//GO(EVP_PKEY_CTX_set_data,
+GO(EVP_PKEY_CTX_set_rsa_keygen_bits, iFpi)
+GO(EVP_PKEY_CTX_set_rsa_oaep_md, iFpp)
+GO(EVP_PKEY_CTX_set_rsa_padding, iFpi)
+GO(EVP_PKEY_CTX_set_rsa_pss_saltlen, iFpi)
+GO(EVP_PKEY_CTX_set_signature_md, iFpp)
+GO(EVP_PKEY_check, iFp)
+GO(EVP_PKEY_decrypt, iFppppL)
+GO(EVP_PKEY_decrypt_init, iFp)
+//GO(EVP_PKEY_decrypt_old,
+//GO(EVP_PKEY_delete_attr,
+GO(EVP_PKEY_derive, iFppp)
+GO(EVP_PKEY_derive_init, iFp)
+GO(EVP_PKEY_derive_set_peer, iFppi)
+GO(EVP_PKEY_encrypt, iFppppL)
+GO(EVP_PKEY_encrypt_init, iFp)
+//GO(EVP_PKEY_encrypt_old,
+GO(EVP_PKEY_free, vFp)
+//GO(EVP_PKEY_get0,
+//GO(EVP_PKEY_get0_asn1,
+GO(EVP_PKEY_get0_RSA, pFp)
+//GO(EVP_PKEY_get1_DH,
+GO(EVP_PKEY_get1_DSA, pFp)
+GO(EVP_PKEY_get1_EC_KEY, pFp)
+GO(EVP_PKEY_get1_RSA, pFp)
+//GO(EVP_PKEY_get_attr,
+//GO(EVP_PKEY_get_attr_by_NID,
+//GO(EVP_PKEY_get_attr_by_OBJ,
+//GO(EVP_PKEY_get_attr_count,
+GO(EVP_PKEY_get_base_id, iFp)
+//GO(EVP_PKEY_get_default_digest_nid,
+GO(EVP_PKEY_get_size, iFp)
+//GO(EVP_PKEY_id,
+GO(EVP_PKEY_keygen, iFpp)
+GO(EVP_PKEY_keygen_init, iFp)
+//GO(EVP_PKEY_meth_add0,
+//GO(EVP_PKEY_meth_copy,
+//GO(EVP_PKEY_meth_find,
+//GO(EVP_PKEY_meth_free,
+//GO(EVP_PKEY_meth_get0_info,
+//GO(EVP_PKEY_meth_new,
+//GO(EVP_PKEY_meth_set_cleanup,
+//GO(EVP_PKEY_meth_set_copy,
+//GO(EVP_PKEY_meth_set_ctrl,
+//GO(EVP_PKEY_meth_set_decrypt,
+//GO(EVP_PKEY_meth_set_derive,
+//GO(EVP_PKEY_meth_set_encrypt,
+//GO(EVP_PKEY_meth_set_init,
+//GO(EVP_PKEY_meth_set_keygen,
+//GO(EVP_PKEY_meth_set_paramgen,
+//GO(EVP_PKEY_meth_set_sign,
+//GO(EVP_PKEY_meth_set_signctx,
+//GO(EVP_PKEY_meth_set_verify,
+//GO(EVP_PKEY_meth_set_verifyctx,
+//GO(EVP_PKEY_meth_set_verify_recover,
+GO(EVP_PKEY_missing_parameters, iFp)
+GO(EVP_PKEY_new, pFv)
+GO(EVP_PKEY_new_mac_key, pFippi)
+GO(EVP_PKEY_paramgen, iFpp)
+GO(EVP_PKEY_paramgen_init, iFp)
+//GO(EVP_PKEY_print_params,
+//GO(EVP_PKEY_print_private,
+//GO(EVP_PKEY_print_public,
+GO(EVP_PKEY_public_check, iFp)
+//GO(EVP_PKEY_save_parameters,
+//GO(EVP_PKEY_set1_DH,
+GO(EVP_PKEY_set1_DSA, iFpp)
+GO(EVP_PKEY_set1_EC_KEY, iFpp)
+GO(EVP_PKEY_set1_RSA, iFpp)
+//GO(evp_pkey_set_cb_translate,
+//GO(EVP_PKEY_set_type,
+//GO(EVP_PKEY_set_type_str,
+GO(EVP_PKEY_sign, iFppppp)
+GO(EVP_PKEY_sign_init, iFp)
+//GO(EVP_PKEY_size,
+GO(EVP_PKEY_type, iFi)
+GO(EVP_PKEY_up_ref, iFp)
+GO(EVP_PKEY_verify, iFppLpL)
+GO(EVP_PKEY_verify_init, iFp)
+//GO(EVP_PKEY_verify_recover,
+//GO(EVP_PKEY_verify_recover_init,
+GO(EVP_rc2_40_cbc, pFv)
+GO(EVP_rc2_64_cbc, pFv)
+GO(EVP_rc2_cbc, pFv)
+GO(EVP_rc2_cfb, pFv)
+GO(EVP_rc2_cfb64, pFv)
+GO(EVP_rc2_ecb, pFv)
+GO(EVP_rc2_ofb, pFv)
+//GO(EVP_rc4,
+//GO(EVP_rc4_40,
+//GO(EVP_rc4_hmac_md5,
+//GO(EVP_read_pw_string,
+//GO(EVP_read_pw_string_min,
+//GO(EVP_ripemd160,
+//GO(EVP_SealFinal,
+//GO(EVP_SealInit,
+//GO(EVP_seed_cbc,
+//GO(EVP_seed_cfb128,
+//GO(EVP_seed_ecb,
+//GO(EVP_seed_ofb,
+//GO(EVP_set_pw_prompt,
+GO(EVP_sha, pFV)
+GO(EVP_sha1, pFv)
+GO(EVP_sha224, pFv)
+GO(EVP_sha256, pFv)
+GO(EVP_sha384, pFv)
+GO(EVP_sha512, pFv)
+//GO(EVP_SignFinal,
+GO(EVP_VerifyFinal, iFppup)
+GO(EVP_VerifyInit, iFpp) // 1.1.0+
+GO(EVP_VerifyInit_ex, iFppp) // 1.1.0+
+GO(EVP_VerifyUpdate, iFppu) // 1.1.0+
+//GO(EVP_whirlpool,
+GO(EXTENDED_KEY_USAGE_free, vFp)
+//GO(EXTENDED_KEY_USAGE_new,
+//GO(fcrypt_body,
+//GO(_fini,
+//GO(FIPS_mode,
+//GO(FIPS_mode_set,
+//GO(gcm_ghash_4bit,
+//GO(gcm_ghash_neon,
+//GO(gcm_ghash_v8,
+//GO(gcm_gmult_4bit,
+//GO(gcm_gmult_neon,
+//GO(gcm_gmult_v8,
+//GO(gcm_init_neon,
+//GO(gcm_init_v8,
+//GO(GENERAL_NAME_cmp,
+GO(GENERAL_NAME_dup, pFp)
+GO(GENERAL_NAME_free, vFp)
+//GO(GENERAL_NAME_get0_otherName,
+//GO(GENERAL_NAME_get0_value,
+GO(GENERAL_NAME_new, pFv)
+//GO(GENERAL_NAME_print,
+//GO(GENERAL_NAME_set0_othername,
+//GO(GENERAL_NAME_set0_value,
+GO(GENERAL_NAMES_free, vFp)
+GO(GENERAL_NAMES_new, pFv)
+GO(GENERAL_SUBTREE_free, vFp)
+GO(GENERAL_SUBTREE_new, pFv)
+//GO(get_rfc2409_prime_1024,
+//GO(get_rfc2409_prime_768,
+//GO(get_rfc3526_prime_1536,
+//GO(get_rfc3526_prime_2048,
+//GO(get_rfc3526_prime_3072,
+//GO(get_rfc3526_prime_4096,
+//GO(get_rfc3526_prime_6144,
+//GO(get_rfc3526_prime_8192,
+//GO(hex_to_string,
+GO(HMAC, pFppipLpp)
+GO(HMAC_CTX_cleanup, vFp)
+GO(HMAC_CTX_copy, iFpp)
+GO(HMAC_CTX_free, vFp)
+GO(HMAC_CTX_init, vFp)
+GO(HMAC_CTX_new, pFv)
+GO(HMAC_CTX_set_flags, vFpL)
+GO(HMAC_Final, iFppp)
+GO(HMAC_Init, iFppip)
+GO(HMAC_Init_ex, iFppipp)
+GO(HMAC_Update, iFppi)
+//GO(i2a_ACCESS_DESCRIPTION,
+GO(i2a_ASN1_ENUMERATED, iFpp)
+GO(i2a_ASN1_INTEGER, iFpp)
+GO(i2a_ASN1_OBJECT, iFpp)
+GO(i2a_ASN1_STRING, iFppi)
+//GO(i2b_PrivateKey_bio,
+//GO(i2b_PublicKey_bio,
+//GO(i2b_PVK_bio,
+//GO(i2c_ASN1_BIT_STRING,
+//GO(i2c_ASN1_INTEGER,
+//GO(i2d_ACCESS_DESCRIPTION,
+GO(i2d_ASN1_bio_stream, iFpppip)
+GO(i2d_ASN1_BIT_STRING, iFpp)
+GO(i2d_ASN1_BMPSTRING, iFpp)
+//GO(i2d_ASN1_BOOLEAN,
+//GO(i2d_ASN1_bytes,
+GO(i2d_ASN1_ENUMERATED, iFpp)
+GO(i2d_ASN1_GENERALIZEDTIME, iFpp)
+GO(i2d_ASN1_GENERALSTRING, iFpp)
+GO(i2d_ASN1_IA5STRING, iFpp)
+GO(i2d_ASN1_INTEGER, iFpp)
+GO(i2d_ASN1_NULL, iFpp)
+GO(i2d_ASN1_OBJECT, iFpp)
+GO(i2d_ASN1_OCTET_STRING, iFpp)
+//GO(i2d_ASN1_PRINTABLE,
+GO(i2d_ASN1_PRINTABLESTRING, iFpp)
+//GO(i2d_ASN1_SEQUENCE_ANY,
+//GO(i2d_ASN1_SET,
+GO(i2d_ASN1_SET_ANY, iFpp)
+GO(i2d_ASN1_T61STRING, iFpp)
+GO(i2d_ASN1_TIME, iFpp)
+GO(i2d_ASN1_TYPE, iFpp)
+GO(i2d_ASN1_UNIVERSALSTRING, iFpp)
+GO(i2d_ASN1_UTCTIME, iFpp)
+GO(i2d_ASN1_UTF8STRING, iFpp)
+GO(i2d_ASN1_VISIBLESTRING, iFpp)
+//GO(i2d_AUTHORITY_INFO_ACCESS,
+//GO(i2d_AUTHORITY_KEYID,
+//GO(i2d_BASIC_CONSTRAINTS,
+//GO(i2d_CERTIFICATEPOLICIES,
+GO(i2d_CMS_bio, iFpp)
+//GO(i2d_CMS_bio_stream,
+//GO(i2d_CMS_ContentInfo,
+//GO(i2d_CMS_ReceiptRequest,
+//GO(i2d_CRL_DIST_POINTS,
+GO(i2d_DHparams, iFpp)
+//GO(i2d_DHxparams,
+//GO(i2d_DIRECTORYSTRING,
+GO(i2d_DISPLAYTEXT, iFpp)
+//GO(i2d_DIST_POINT,
+//GO(i2d_DIST_POINT_NAME,
+//GO(i2d_DSAparams,
+GO(i2d_DSAPrivateKey, iFpp)
+GO(i2d_DSAPrivateKey_bio, iFpp)
+GO(i2d_DSAPrivateKey_fp, iFpp)
+GO(i2d_DSA_PUBKEY, iFpp)
+GO(i2d_DSA_PUBKEY_bio, iFpp)
+GO(i2d_DSA_PUBKEY_fp, iFpp)
+//GO(i2d_DSAPublicKey,
+//GO(i2d_DSA_SIG,
+//GO(i2d_ECDSA_SIG,
+//GO(i2d_ECParameters,
+//GO(i2d_ECPKParameters,
+//GO(i2d_ECPKPARAMETERS,
+GO(i2d_ECPrivateKey, iFpp)
+//GO(i2d_EC_PRIVATEKEY,
+GO(i2d_ECPrivateKey_bio, iFpp)
+GO(i2d_ECPrivateKey_fp, iFpp)
+GO(i2d_EC_PUBKEY, iFpp)
+GO(i2d_EC_PUBKEY_bio, iFpp)
+GO(i2d_EC_PUBKEY_fp, iFpp)
+GO(i2d_EDIPARTYNAME, iFpp)
+GO(i2d_ESS_CERT_ID, iFpp)
+GO(i2d_ESS_ISSUER_SERIAL, iFpp)
+GO(i2d_ESS_SIGNING_CERT, iFpp)
+GO(i2d_EXTENDED_KEY_USAGE, iFpp)
+GO(i2d_GENERAL_NAME, iFpp)
+GO(i2d_GENERAL_NAMES, iFpp)
+//GO(i2d_int_dhx,
+GO(i2d_ISSUING_DIST_POINT, iFpp)
+GO(i2d_KRB5_APREQ, iFpp)
+GO(i2d_KRB5_APREQBODY, iFpp)
+GO(i2d_KRB5_AUTHDATA, iFpp)
+GO(i2d_KRB5_AUTHENT, iFpp)
+GO(i2d_KRB5_AUTHENTBODY, iFpp)
+GO(i2d_KRB5_CHECKSUM, iFpp)
+GO(i2d_KRB5_ENCDATA, iFpp)
+GO(i2d_KRB5_ENCKEY, iFpp)
+GO(i2d_KRB5_PRINCNAME, iFpp)
+GO(i2d_KRB5_TICKET, iFpp)
+GO(i2d_KRB5_TKTBODY, iFpp)
+GO(i2d_NETSCAPE_CERT_SEQUENCE, iFpp)
+GO(i2d_NETSCAPE_ENCRYPTED_PKEY, iFpp)
+GO(i2d_NETSCAPE_PKEY, iFpp)
+GO(i2d_Netscape_RSA, iFpp)
+GO(i2d_NETSCAPE_SPKAC, iFpp)
+GO(i2d_NETSCAPE_SPKI, iFpp)
+GO(i2d_NETSCAPE_X509, iFpp)
+GO(i2d_NOTICEREF, iFpp)
+GO(i2d_OCSP_BASICRESP, iFpp)
+GO(i2d_OCSP_CERTID, iFpp)
+GO(i2d_OCSP_CERTSTATUS, iFpp)
+GO(i2d_OCSP_CRLID, iFpp)
+GO(i2d_OCSP_ONEREQ, iFpp)
+GO(i2d_OCSP_REQINFO, iFpp)
+GO(i2d_OCSP_REQUEST, iFpp)
+GO(i2d_OCSP_RESPBYTES, iFpp)
+GO(i2d_OCSP_RESPDATA, iFpp)
+GO(i2d_OCSP_RESPID, iFpp)
+GO(i2d_OCSP_RESPONSE, iFpp)
+GO(i2d_OCSP_REVOKEDINFO, iFpp)
+GO(i2d_OCSP_SERVICELOC, iFpp)
+GO(i2d_OCSP_SIGNATURE, iFpp)
+GO(i2d_OCSP_SINGLERESP, iFpp)
+GO(i2d_OTHERNAME, iFpp)
+GO(i2d_PBE2PARAM, iFpp)
+GO(i2d_PBEPARAM, iFpp)
+GO(i2d_PBKDF2PARAM, iFpp)
+GO(i2d_PKCS12, iFpp)
+GO(i2d_PKCS12_BAGS, iFpp)
+GO(i2d_PKCS12_bio, iFpp)
+GO(i2d_PKCS12_fp, iFpp)
+GO(i2d_PKCS12_MAC_DATA, iFpp)
+GO(i2d_PKCS12_SAFEBAG, iFpp)
+GO(i2d_PKCS7, iFpp)
+GO(i2d_PKCS7_bio, iFpp)
+GO(i2d_PKCS7_bio_stream, iFpppi)
+GO(i2d_PKCS7_DIGEST, iFpp)
+GO(i2d_PKCS7_ENC_CONTENT, iFpp)
+GO(i2d_PKCS7_ENCRYPT, iFpp)
+GO(i2d_PKCS7_ENVELOPE, iFpp)
+GO(i2d_PKCS7_fp, iFpp)
+GO(i2d_PKCS7_ISSUER_AND_SERIAL, iFpp)
+GO(i2d_PKCS7_NDEF, iFpp)
+GO(i2d_PKCS7_RECIP_INFO, iFpp)
+GO(i2d_PKCS7_SIGNED, iFpp)
+GO(i2d_PKCS7_SIGN_ENVELOPE, iFpp)
+GO(i2d_PKCS7_SIGNER_INFO, iFpp)
+GO(i2d_PKCS8_bio, iFpp)
+GO(i2d_PKCS8_fp, iFpp)
+GO(i2d_PKCS8PrivateKey_bio, iFpp)
+GO(i2d_PKCS8PrivateKey_fp, iFpp)
+GO(i2d_PKCS8PrivateKeyInfo_bio, iFpp)
+GO(i2d_PKCS8PrivateKeyInfo_fp, iFpp)
+GO(i2d_PKCS8PrivateKey_nid_bio, iFpp)
+GO(i2d_PKCS8PrivateKey_nid_fp, iFpp)
+GO(i2d_PKCS8_PRIV_KEY_INFO, iFpp)
+GO(i2d_PKCS8_PRIV_KEY_INFO_bio, iFpp)
+GO(i2d_PKCS8_PRIV_KEY_INFO_fp, iFpp)
+GO(i2d_PKEY_USAGE_PERIOD, iFpp)
+GO(i2d_POLICYINFO, iFpp)
+GO(i2d_POLICYQUALINFO, iFpp)
+GO(i2d_PrivateKey, iFpp)
+GO(i2d_PrivateKey_bio, iFpp)
+GO(i2d_PrivateKey_fp, iFpp)
+GO(i2d_PROXY_CERT_INFO_EXTENSION, iFpp)
+GO(i2d_PROXY_POLICY, iFpp)
+GO(i2d_PUBKEY, iFpp)
+GO(i2d_PUBKEY_bio, iFpp)
+GO(i2d_PUBKEY_fp, iFpp)
+//GO(i2d_PublicKey,
+//GO(i2d_re_X509_tbs,
+GO(i2d_RSA_NET, iFpp)
+GO(i2d_RSA_OAEP_PARAMS, iFpp)
+GO(i2d_RSAPrivateKey, iFpp)
+GO(i2d_RSAPrivateKey_bio, iFpp)
+GO(i2d_RSAPrivateKey_fp, iFpp)
+GO(i2d_RSA_PSS_PARAMS, iFpp)
+GO(i2d_RSA_PUBKEY, iFpp)
+GO(i2d_RSA_PUBKEY_bio, iFpp)
+GO(i2d_RSA_PUBKEY_fp, iFpp)
+GO(i2d_RSAPublicKey, iFpp)
+GO(i2d_RSAPublicKey_bio, iFpp)
+GO(i2d_RSAPublicKey_fp, iFpp)
+GO(i2d_SXNET, iFpp)
+GO(i2d_SXNETID, iFpp)
+GO(i2d_TS_ACCURACY, iFpp)
+GO(i2d_TS_MSG_IMPRINT, iFpp)
+GO(i2d_TS_MSG_IMPRINT_bio, iFpp)
+GO(i2d_TS_MSG_IMPRINT_fp, iFpp)
+GO(i2d_TS_REQ, iFpp)
+GO(i2d_TS_REQ_bio, iFpp)
+GO(i2d_TS_REQ_fp, iFpp)
+GO(i2d_TS_RESP, iFpp)
+GO(i2d_TS_RESP_bio, iFpp)
+GO(i2d_TS_RESP_fp, iFpp)
+GO(i2d_TS_STATUS_INFO, iFpp)
+GO(i2d_TS_TST_INFO, iFpp)
+GO(i2d_TS_TST_INFO_bio, iFpp)
+GO(i2d_TS_TST_INFO_fp, iFpp)
+GO(i2d_USERNOTICE, iFpp)
+GO(i2d_X509, iFpp)
+GO(i2d_X509_ALGOR, iFpp)
+GO(i2d_X509_ALGORS, iFpp)
+GO(i2d_X509_ATTRIBUTE, iFpp)
+GO(i2d_X509_AUX, iFpp)
+GO(i2d_X509_bio, iFpp)
+GO(i2d_X509_CERT_AUX, iFpp)
+GO(i2d_X509_CERT_PAIR, iFpp)
+GO(i2d_X509_CINF, iFpp)
+GO(i2d_X509_CRL, iFpp)
+GO(i2d_X509_CRL_bio, iFpp)
+GO(i2d_X509_CRL_fp, iFpp)
+GO(i2d_X509_CRL_INFO, iFpp)
+GO(i2d_X509_EXTENSION, iFpp)
+GO(i2d_X509_EXTENSIONS, iFpp)
+GO(i2d_X509_fp, iFpp)
+GO(i2d_X509_NAME, iFpp)
+GO(i2d_X509_NAME_ENTRY, iFpp)
+GO(i2d_X509_PKEY, iFpp)
+GO(i2d_X509_PUBKEY, iFpp)
+GO(i2d_X509_REQ, iFpp)
+GO(i2d_X509_REQ_bio, iFpp)
+GO(i2d_X509_REQ_fp, iFpp)
+GO(i2d_X509_REQ_INFO, iFpp)
+GO(i2d_X509_REVOKED, iFpp)
+GO(i2d_X509_SIG, iFpp)
+GO(i2d_X509_VAL, iFpp)
+//GO(i2o_ECPublicKey,
+//GO(i2s_ASN1_ENUMERATED,
+//GO(i2s_ASN1_ENUMERATED_TABLE,
+//GO(i2s_ASN1_INTEGER,
+//GO(i2s_ASN1_OCTET_STRING,
+GO(i2t_ASN1_OBJECT, iFpip)
+//GO(i2v_ASN1_BIT_STRING,
+//GO(i2v_GENERAL_NAME,
+//GO(i2v_GENERAL_NAMES,
+//GO(idea_cbc_encrypt,
+//GO(idea_cfb64_encrypt,
+//GO(idea_ecb_encrypt,
+//GO(idea_encrypt,
+//GO(idea_ofb64_encrypt,
+//GO(idea_options,
+//GO(idea_set_decrypt_key,
+//GO(idea_set_encrypt_key,
+//GO(_init,
+//GO(int_rsa_verify,
+//GO(ISSUING_DIST_POINT_free,
+//GO(ISSUING_DIST_POINT_new,
+//GO(KRB5_APREQBODY_free,
+//GO(KRB5_APREQBODY_new,
+//GO(KRB5_APREQ_free,
+//GO(KRB5_APREQ_new,
+//GO(KRB5_AUTHDATA_free,
+//GO(KRB5_AUTHDATA_new,
+//GO(KRB5_AUTHENTBODY_free,
+//GO(KRB5_AUTHENTBODY_new,
+//GO(KRB5_AUTHENT_free,
+//GO(KRB5_AUTHENT_new,
+//GO(KRB5_CHECKSUM_free,
+//GO(KRB5_CHECKSUM_new,
+//GO(KRB5_ENCDATA_free,
+//GO(KRB5_ENCDATA_new,
+//GO(KRB5_ENCKEY_free,
+//GO(KRB5_ENCKEY_new,
+//GO(KRB5_PRINCNAME_free,
+//GO(KRB5_PRINCNAME_new,
+//GO(KRB5_TICKET_free,
+//GO(KRB5_TICKET_new,
+//GO(KRB5_TKTBODY_free,
+//GO(KRB5_TKTBODY_new,
+//GO(level_add_node,
+//GO(level_find_node,
+//GO(lh_delete,
+//GO(lh_doall,
+//GO(lh_doall_arg,
+//GO(lh_free,
+//GO(lh_insert,
+//GO(lh_new,
+//GO(lh_node_stats,
+//GO(lh_node_stats_bio,
+//GO(lh_node_usage_stats,
+//GO(lh_node_usage_stats_bio,
+//GO(lh_num_items,
+//GO(lh_retrieve,
+//GO(lh_stats,
+//GO(lh_stats_bio,
+//GO(lh_strhash,
+//GO(MD4,
+//GO(md4_block_data_order,
+GO(MD4_Final, iFpp)
+GO(MD4_Init, iFp)
+//GO(MD4_Transform,
+GO(MD4_Update, iFppu)
+GO(MD5, pFpLp)
+//GO(md5_block_data_order,
+GO(MD5_Final, iFpp)
+GO(MD5_Init, iFp)
+GO(MD5_Transform, vFpp)
+GO(MD5_Update, iFppu)
+//GO(MDC2,
+//GO(MDC2_Final,
+//GO(MDC2_Init,
+//GO(MDC2_Update,
+//GO(name_cmp,
+//GO(NAME_CONSTRAINTS_check,
+//GO(NAME_CONSTRAINTS_free,
+//GO(NAME_CONSTRAINTS_new,
+//GO(NCONF_default,
+//GO(NCONF_dump_bio,
+//GO(NCONF_dump_fp,
+//GO(NCONF_free,
+//GO(NCONF_free_data,
+//GO(NCONF_get_number_e,
+//GO(NCONF_get_section,
+//GO(NCONF_get_string,
+//GO(NCONF_load,
+//GO(NCONF_load_bio,
+//GO(NCONF_load_fp,
+//GO(NCONF_new,
+//GO(NCONF_WIN32,
+//GO(NETSCAPE_CERT_SEQUENCE_free,
+//GO(NETSCAPE_CERT_SEQUENCE_new,
+//GO(NETSCAPE_ENCRYPTED_PKEY_free,
+//GO(NETSCAPE_ENCRYPTED_PKEY_new,
+//GO(NETSCAPE_PKEY_free,
+//GO(NETSCAPE_PKEY_new,
+//GO(NETSCAPE_SPKAC_free,
+//GO(NETSCAPE_SPKAC_new,
+//GO(NETSCAPE_SPKI_b64_decode,
+//GO(NETSCAPE_SPKI_b64_encode,
+//GO(NETSCAPE_SPKI_free,
+//GO(NETSCAPE_SPKI_get_pubkey,
+//GO(NETSCAPE_SPKI_new,
+//GO(NETSCAPE_SPKI_print,
+//GO(NETSCAPE_SPKI_set_pubkey,
+//GO(NETSCAPE_SPKI_sign,
+//GO(NETSCAPE_SPKI_verify,
+GO(NETSCAPE_X509_free, vFp)
+GO(NETSCAPE_X509_new, pFv)
+//GO(NOTICEREF_free,
+//GO(NOTICEREF_new,
+//GO(o2i_ECPublicKey,
+//GO(OBJ_add_object,
+//GO(OBJ_add_sigid,
+//GO(OBJ_bsearch_,
+//GO(OBJ_bsearch_ex_,
+GO(OBJ_cleanup, vFv)
+GO(OBJ_cmp, iFpp)
+GO(OBJ_create, iFppp)
+//GO(OBJ_create_objects,
+GO(OBJ_dup, pFp)
+//GO(OBJ_find_sigid_algs,
+//GO(OBJ_find_sigid_by_algs,
+GO(OBJ_ln2nid, iFp)
+//GO(OBJ_NAME_add,
+//GO(OBJ_NAME_cleanup,
+//GO(OBJ_NAME_do_all,
+//GO(OBJ_NAME_do_all_sorted,
+//GO(OBJ_NAME_get,
+//GO(OBJ_NAME_init,
+//GO(OBJ_NAME_new_index,
+//GO(OBJ_NAME_remove,
+//GO(OBJ_new_nid,
+GO(OBJ_nid2ln, pFi)
+GO(OBJ_nid2obj, pFi)
+GO(OBJ_nid2sn, pFi)
+GO(OBJ_obj2nid, iFp)
+GO(OBJ_obj2txt, iFpipi)
+//GO(OBJ_sigid_free,
+GO(OBJ_sn2nid, iFp)
+GO(OBJ_txt2nid, iFp)
+GO(OBJ_txt2obj, pFpi)
+//GO(OCSP_accept_responses_new,
+//GO(OCSP_archive_cutoff_new,
+//GO(OCSP_basic_add1_cert,
+//GO(OCSP_basic_add1_nonce,
+//GO(OCSP_basic_add1_status,
+//GO(OCSP_BASICRESP_add1_ext_i2d,
+//GO(OCSP_BASICRESP_add_ext,
+//GO(OCSP_BASICRESP_delete_ext,
+GO(OCSP_BASICRESP_free, vFp)
+//GO(OCSP_BASICRESP_get1_ext_d2i,
+//GO(OCSP_BASICRESP_get_ext,
+//GO(OCSP_BASICRESP_get_ext_by_critical,
+//GO(OCSP_BASICRESP_get_ext_by_NID,
+//GO(OCSP_BASICRESP_get_ext_by_OBJ,
+//GO(OCSP_BASICRESP_get_ext_count,
+//GO(OCSP_BASICRESP_new,
+//GO(OCSP_basic_sign,
+GO(OCSP_basic_verify, iFpppL)
+//GO(OCSP_CERTID_dup,
+GO(OCSP_CERTID_free, vFp)
+//GO(OCSP_cert_id_new,
+//GO(OCSP_CERTID_new,
+//GO(OCSP_CERTSTATUS_free,
+//GO(OCSP_CERTSTATUS_new,
+//GO(OCSP_cert_status_str,
+GO(OCSP_cert_to_id, pFppp)
+GO(OCSP_check_nonce, iFpp)
+//GO(OCSP_check_validity,
+//GO(OCSP_copy_nonce,
+//GO(OCSP_CRLID_free,
+//GO(OCSP_crlID_new,
+//GO(OCSP_CRLID_new,
+//GO(OCSP_crl_reason_str,
+//GO(OCSP_id_cmp,
+//GO(OCSP_id_get0_info,
+//GO(OCSP_id_issuer_cmp,
+//GO(OCSP_ONEREQ_add1_ext_i2d,
+//GO(OCSP_ONEREQ_add_ext,
+//GO(OCSP_ONEREQ_delete_ext,
+//GO(OCSP_ONEREQ_free,
+//GO(OCSP_onereq_get0_id,
+//GO(OCSP_ONEREQ_get1_ext_d2i,
+//GO(OCSP_ONEREQ_get_ext,
+//GO(OCSP_ONEREQ_get_ext_by_critical,
+//GO(OCSP_ONEREQ_get_ext_by_NID,
+//GO(OCSP_ONEREQ_get_ext_by_OBJ,
+//GO(OCSP_ONEREQ_get_ext_count,
+//GO(OCSP_ONEREQ_new,
+//GO(OCSP_parse_url,
+//GO(OCSP_REQ_CTX_add1_header,
+//GO(OCSP_REQ_CTX_free,
+//GO(OCSP_REQ_CTX_get0_mem_bio,
+//GO(OCSP_REQ_CTX_http,
+//GO(OCSP_REQ_CTX_i2d,
+//GO(OCSP_REQ_CTX_nbio,
+//GO(OCSP_REQ_CTX_nbio_d2i,
+//GO(OCSP_REQ_CTX_new,
+//GO(OCSP_REQ_CTX_set1_req,
+//GO(OCSP_REQINFO_free,
+//GO(OCSP_REQINFO_new,
+GO(OCSP_request_add0_id, pFpp)
+//GO(OCSP_request_add1_cert,
+//GO(OCSP_REQUEST_add1_ext_i2d,
+GO(OCSP_request_add1_nonce, iFppi)
+//GO(OCSP_REQUEST_add_ext,
+//GO(OCSP_REQUEST_delete_ext,
+GO(OCSP_REQUEST_free, vFp)
+//GO(OCSP_REQUEST_get1_ext_d2i,
+//GO(OCSP_REQUEST_get_ext,
+//GO(OCSP_REQUEST_get_ext_by_critical,
+//GO(OCSP_REQUEST_get_ext_by_NID,
+//GO(OCSP_REQUEST_get_ext_by_OBJ,
+//GO(OCSP_REQUEST_get_ext_count,
+//GO(OCSP_request_is_signed,
+GO(OCSP_REQUEST_new, pFv)
+//GO(OCSP_request_onereq_count,
+//GO(OCSP_request_onereq_get0,
+//GO(OCSP_REQUEST_print,
+//GO(OCSP_request_set1_name,
+//GO(OCSP_request_sign,
+//GO(OCSP_request_verify,
+//GO(OCSP_RESPBYTES_free,
+//GO(OCSP_RESPBYTES_new,
+//GO(OCSP_resp_count,
+//GO(OCSP_RESPDATA_free,
+//GO(OCSP_RESPDATA_new,
+//GO(OCSP_resp_find,
+GO(OCSP_resp_find_status, iFppppppp)
+//GO(OCSP_resp_get0,
+//GO(OCSP_RESPID_free,
+//GO(OCSP_RESPID_new,
+//GO(OCSP_response_create,
+GO(OCSP_RESPONSE_free, vFp)
+GO(OCSP_response_get1_basic, pFp)
+GO(OCSP_RESPONSE_new, pFv)
+//GO(OCSP_RESPONSE_print,
+//GO(OCSP_response_status,
+//GO(OCSP_response_status_str,
+//GO(OCSP_REVOKEDINFO_free,
+//GO(OCSP_REVOKEDINFO_new,
+//GO(OCSP_sendreq_bio,
+//GO(OCSP_sendreq_nbio,
+//GO(OCSP_sendreq_new,
+//GO(OCSP_SERVICELOC_free,
+//GO(OCSP_SERVICELOC_new,
+//GO(OCSP_set_max_response_length,
+//GO(OCSP_SIGNATURE_free,
+//GO(OCSP_SIGNATURE_new,
+//GO(OCSP_single_get0_status,
+//GO(OCSP_SINGLERESP_add1_ext_i2d,
+//GO(OCSP_SINGLERESP_add_ext,
+//GO(OCSP_SINGLERESP_delete_ext,
+//GO(OCSP_SINGLERESP_free,
+//GO(OCSP_SINGLERESP_get1_ext_d2i,
+//GO(OCSP_SINGLERESP_get_ext,
+//GO(OCSP_SINGLERESP_get_ext_by_critical,
+//GO(OCSP_SINGLERESP_get_ext_by_NID,
+//GO(OCSP_SINGLERESP_get_ext_by_OBJ,
+//GO(OCSP_SINGLERESP_get_ext_count,
+//GO(OCSP_SINGLERESP_new,
+//GO(OCSP_url_svcloc_new,
+GO(OPENSSL_add_all_algorithms_conf, vFv)
+GO(OPENSSL_add_all_algorithms_noconf, vFv)
+GO(OpenSSL_add_all_ciphers, vFv)
+//GO(OpenSSL_add_all_digests,
+//GO(OPENSSL_asc2uni,
+//GO(OPENSSL_atomic_add,
+GO(OPENSSL_cleanse, vFpL)
+GO(OPENSSL_config, vFp)
+//GO(OPENSSL_cpuid_setup,
+//GO(OpenSSLDie,
+//GO(OPENSSL_DIR_end,
+//GO(OPENSSL_DIR_read,
+GO(OPENSSL_gmtime, pFpp)
+GO(OPENSSL_gmtime_adj, iFpil)
+GO(OPENSSL_gmtime_diff, iFpppp)
+//GO(OPENSSL_ia32cap_loc,
+//GO(OPENSSL_init,
+GO(OPENSSL_init_crypto, iFLp)
+//GO(OPENSSL_instrument_bus,
+//GO(OPENSSL_instrument_bus2,
+//GO(OPENSSL_isservice,
+//GO(OPENSSL_issetugid,
+//GO(OPENSSL_load_builtin_modules,
+//GO(OPENSSL_memcmp,
+GO(OPENSSL_no_config, vFv)
+//GO(OPENSSL_rdtsc,
+GO(OPENSSL_sk_free, vFp) //1.1+
+GO(OPENSSL_sk_new_null, pFv) //1.1+
+GO(OPENSSL_sk_num, iFp) //1.1+
+GO(OPENSSL_sk_pop, pFp) //1.1+
+GOM(OPENSSL_sk_pop_free, pFEpp) //1.1+
+GO(OPENSSL_sk_push, iFpp) //1.1+
+GO(OPENSSL_sk_value, pFpi) //1.1+
+//GO(OPENSSL_showfatal,
+//GO(OPENSSL_stderr,
+GO(OPENSSL_strcasecmp, iFpp)
+GO(OPENSSL_strncasecmp, iFppL)
+//GO(OPENSSL_uni2asc,
+//GO(OPENSSL_wipe_cpu,
+GO(OpenSSL_version_num, LFv)
+//GO(_ossl_096_des_random_seed,
+//GO(_ossl_old_crypt,
+//GO(_ossl_old_des_cbc_cksum,
+//GO(_ossl_old_des_cbc_encrypt,
+//GO(_ossl_old_des_cfb64_encrypt,
+//GO(_ossl_old_des_cfb_encrypt,
+//GO(_ossl_old_des_crypt,
+//GO(_ossl_old_des_decrypt3,
+//GO(_ossl_old_des_ecb3_encrypt,
+//GO(_ossl_old_des_ecb_encrypt,
+//GO(_ossl_old_des_ede3_cbc_encrypt,
+//GO(_ossl_old_des_ede3_cfb64_encrypt,
+//GO(_ossl_old_des_ede3_ofb64_encrypt,
+//GO(_ossl_old_des_enc_read,
+//GO(_ossl_old_des_encrypt,
+//GO(_ossl_old_des_encrypt2,
+//GO(_ossl_old_des_encrypt3,
+//GO(_ossl_old_des_enc_write,
+//GO(_ossl_old_des_fcrypt,
+//GO(_ossl_old_des_is_weak_key,
+//GO(_ossl_old_des_key_sched,
+//GO(_ossl_old_des_ncbc_encrypt,
+//GO(_ossl_old_des_ofb64_encrypt,
+//GO(_ossl_old_des_ofb_encrypt,
+//GO(_ossl_old_des_options,
+//GO(_ossl_old_des_pcbc_encrypt,
+//GO(_ossl_old_des_quad_cksum,
+//GO(_ossl_old_des_random_key,
+//GO(_ossl_old_des_random_seed,
+//GO(_ossl_old_des_read_2passwords,
+//GO(_ossl_old_des_read_password,
+//GO(_ossl_old_des_read_pw,
+//GO(_ossl_old_des_read_pw_string,
+//GO(_ossl_old_des_set_key,
+//GO(_ossl_old_des_set_odd_parity,
+//GO(_ossl_old_des_string_to_2keys,
+//GO(_ossl_old_des_string_to_key,
+//GO(_ossl_old_des_xcbc_encrypt,
+GO(OSSL_PROVIDER_try_load, pFppi)
+//GO(OTHERNAME_cmp,
+//GO(OTHERNAME_free,
+//GO(OTHERNAME_new,
+//GO(PBE2PARAM_free,
+//GO(PBE2PARAM_new,
+//GO(PBEPARAM_free,
+//GO(PBEPARAM_new,
+//GO(PBKDF2PARAM_free,
+//GO(PBKDF2PARAM_new,
+//GO(PEM_ASN1_read,
+//GO(PEM_ASN1_read_bio,
+//GO(PEM_ASN1_write,
+//GO(PEM_ASN1_write_bio,
+//GO(PEM_bytes_read_bio,
+//GO(pem_check_suffix,
+//GO(PEM_def_callback,
+//GO(PEM_dek_info,
+//GO(PEM_do_header,
+//GO(PEM_get_EVP_CIPHER_INFO,
+//GO(PEM_proc_type,
+//GO(PEM_read,
+//GO(PEM_read_bio,
+//GO(PEM_read_bio_CMS,
+//GO(PEM_read_bio_DHparams,
+//GO(PEM_read_bio_DSAparams,
+GOM(PEM_read_bio_DSAPrivateKey, pFEpppp)
+GOM(PEM_read_bio_DSA_PUBKEY, pFEpppp)
+//GO(PEM_read_bio_ECPKParameters,
+GOM(PEM_read_bio_ECPrivateKey, pFEpppp)
+GOM(PEM_read_bio_EC_PUBKEY, pFEpppp)
+//GO(PEM_read_bio_NETSCAPE_CERT_SEQUENCE,
+//GO(PEM_read_bio_Parameters,
+GOM(PEM_read_bio_PKCS7, pFEpppp)
+//GO(PEM_read_bio_PKCS8,
+//GO(PEM_read_bio_PKCS8_PRIV_KEY_INFO,
+//GO(PEM_read_bio_PrivateKey,
+//GO(PEM_read_bio_PUBKEY,
+GOM(PEM_read_bio_RSAPrivateKey, pFEpppp)
+GOM(PEM_read_bio_RSA_PUBKEY, pFEpppp)
+//GO(PEM_read_bio_RSAPublicKey,
+GOM(PEM_read_bio_X509, pFEpppp)
+GOM(PEM_read_bio_X509_AUX, pFEpppp)
+GOM(PEM_read_bio_X509_CERT_PAIR, pFEpppp)
+GOM(PEM_read_bio_X509_CRL, pFEpppp)
+GOM(PEM_read_bio_X509_REQ, pFEpppp)
+//GO(PEM_read_CMS,
+//GO(PEM_read_DHparams,
+//GO(PEM_read_DSAparams,
+//GO(PEM_read_DSAPrivateKey,
+//GO(PEM_read_DSA_PUBKEY,
+//GO(PEM_read_ECPKParameters,
+//GO(PEM_read_ECPrivateKey,
+//GO(PEM_read_EC_PUBKEY,
+//GO(PEM_read_NETSCAPE_CERT_SEQUENCE,
+//GO(PEM_read_PKCS7,
+//GO(PEM_read_PKCS8,
+//GO(PEM_read_PKCS8_PRIV_KEY_INFO,
+//GO(PEM_read_PrivateKey,
+//GO(PEM_read_PUBKEY,
+//GO(PEM_read_RSAPrivateKey,
+//GO(PEM_read_RSA_PUBKEY,
+//GO(PEM_read_RSAPublicKey,
+GO(PEM_read_X509, pFpppp)
+GO(PEM_read_X509_AUX, pFpppp)
+//GO(PEM_read_X509_CERT_PAIR,
+//GO(PEM_read_X509_CRL,
+//GO(PEM_read_X509_REQ,
+//GO(PEM_SealFinal,
+//GO(PEM_SealInit,
+//GO(PEM_SealUpdate,
+//GO(PEM_SignFinal,
+//GO(PEM_SignInit,
+//GO(PEM_SignUpdate,
+//GO(PEM_write,
+//GO(PEM_write_bio,
+GO(PEM_write_bio_ASN1_stream, iFpppipp)
+//GO(PEM_write_bio_CMS,
+//GO(PEM_write_bio_CMS_stream,
+//GO(PEM_write_bio_DHparams,
+//GO(PEM_write_bio_DHxparams,
+//GO(PEM_write_bio_DSAparams,
+GOM(PEM_write_bio_DSAPrivateKey, iFEppppipp)
+GO(PEM_write_bio_DSA_PUBKEY, iFpp)
+//GO(PEM_write_bio_ECPKParameters,
+GOM(PEM_write_bio_ECPrivateKey, iFEppppipp)
+GO(PEM_write_bio_EC_PUBKEY, iFpp)
+//GO(PEM_write_bio_NETSCAPE_CERT_SEQUENCE,
+//GO(PEM_write_bio_Parameters,
+//GO(PEM_write_bio_PKCS7,
+//GO(PEM_write_bio_PKCS7_stream,
+//GO(PEM_write_bio_PKCS8,
+//GO(PEM_write_bio_PKCS8PrivateKey,
+//GO(PEM_write_bio_PKCS8PrivateKey_nid,
+//GO(PEM_write_bio_PKCS8_PRIV_KEY_INFO,
+//GO(PEM_write_bio_PrivateKey,
+//GO(PEM_write_bio_PUBKEY,
+GOM(PEM_write_bio_RSAPrivateKey, iFEppppipp)
+GO(PEM_write_bio_RSA_PUBKEY, iFpp)
+//GO(PEM_write_bio_RSAPublicKey,
+GO(PEM_write_bio_X509, iFpp)
+GO(PEM_write_bio_X509_AUX, iFpp)
+//GO(PEM_write_bio_X509_CERT_PAIR,
+GO(PEM_write_bio_X509_CRL, iFpp)
+GO(PEM_write_bio_X509_REQ, iFpp)
+//GO(PEM_write_bio_X509_REQ_NEW,
+//GO(PEM_write_CMS,
+//GO(PEM_write_DHparams,
+//GO(PEM_write_DHxparams,
+//GO(PEM_write_DSAparams,
+//GO(PEM_write_DSAPrivateKey,
+//GO(PEM_write_DSA_PUBKEY,
+//GO(PEM_write_ECPKParameters,
+//GO(PEM_write_ECPrivateKey,
+//GO(PEM_write_EC_PUBKEY,
+//GO(PEM_write_NETSCAPE_CERT_SEQUENCE,
+//GO(PEM_write_PKCS7,
+//GO(PEM_write_PKCS8,
+//GO(PEM_write_PKCS8PrivateKey,
+//GO(PEM_write_PKCS8PrivateKey_nid,
+//GO(PEM_write_PKCS8_PRIV_KEY_INFO,
+//GO(PEM_write_PrivateKey,
+//GO(PEM_write_PUBKEY,
+//GO(PEM_write_RSAPrivateKey,
+//GO(PEM_write_RSA_PUBKEY,
+//GO(PEM_write_RSAPublicKey,
+//GO(PEM_write_X509,
+//GO(PEM_write_X509_AUX,
+//GO(PEM_write_X509_CERT_PAIR,
+//GO(PEM_write_X509_CRL,
+//GO(PEM_write_X509_REQ,
+//GO(PEM_write_X509_REQ_NEW,
+//GO(PEM_X509_INFO_read,
+//GO(PEM_X509_INFO_read_bio,
+//GO(PEM_X509_INFO_write_bio,
+//GO(pitem_free,
+//GO(pitem_new,
+//GO(PKCS12_add_cert,
+//GO(PKCS12_add_CSPName_asc,
+//GO(PKCS12_add_friendlyname_asc,
+//GO(PKCS12_add_friendlyname_uni,
+//GO(PKCS12_add_key,
+//GO(PKCS12_add_localkeyid,
+//GO(PKCS12_add_safe,
+//GO(PKCS12_add_safes,
+//GO(PKCS12_BAGS_free,
+//GO(PKCS12_BAGS_new,
+//GO(PKCS12_certbag2x509,
+//GO(PKCS12_certbag2x509crl,
+GO(PKCS12_create, pFppppp)
+//GO(PKCS12_decrypt_skey,
+GO(PKCS12_free, vFp)
+//GO(PKCS12_gen_mac,
+//GO(PKCS12_get_attr_gen,
+//GO(PKCS12_get_friendlyname,
+//GO(PKCS12_init,
+//GO(PKCS12_item_decrypt_d2i,
+//GO(PKCS12_item_i2d_encrypt,
+//GO(PKCS12_item_pack_safebag,
+//GO(PKCS12_key_gen_asc,
+//GO(PKCS12_key_gen_uni,
+//GO(PKCS12_MAC_DATA_free,
+//GO(PKCS12_MAC_DATA_new,
+//GO(PKCS12_MAKE_KEYBAG,
+//GO(PKCS12_MAKE_SHKEYBAG,
+GO(PKCS12_new, pFv)
+//GO(PKCS12_newpass,
+//GO(PKCS12_pack_authsafes,
+//GO(PKCS12_pack_p7data,
+//GO(PKCS12_pack_p7encdata,
+GO(PKCS12_parse, iFppppp)
+GO(PKCS12_PBE_add, vFv)
+//GO(PKCS12_pbe_crypt,
+GO(PKCS12_PBE_keyivgen, iFppipppi)
+//GO(PKCS12_SAFEBAG_free,
+//GO(PKCS12_SAFEBAG_new,
+//GO(PKCS12_set_mac,
+//GO(PKCS12_setup_mac,
+//GO(PKCS12_unpack_authsafes,
+//GO(PKCS12_unpack_p7data,
+//GO(PKCS12_unpack_p7encdata,
+//GO(PKCS12_verify_mac,
+//GO(PKCS12_x5092certbag,
+//GO(PKCS12_x509crl2certbag,
+//GO(PKCS1_MGF1,
+//GO(PKCS5_pbe2_set,
+//GO(PKCS5_pbe2_set_iv,
+//GO(PKCS5_PBE_add,
+//GO(PKCS5_PBE_keyivgen,
+//GO(PKCS5_pbe_set,
+//GO(PKCS5_pbe_set0_algor,
+GO(PKCS5_PBKDF2_HMAC, iFpipiipip)
+GO(PKCS5_PBKDF2_HMAC_SHA1, iFpipiiip)
+//GO(PKCS5_pbkdf2_set,
+//GO(PKCS5_v2_PBE_keyivgen,
+//GO(PKCS5_v2_PBKDF2_keyivgen,
+//GO(PKCS7_add0_attrib_signing_time,
+//GO(PKCS7_add1_attrib_digest,
+//GO(PKCS7_add_attrib_content_type,
+//GO(PKCS7_add_attrib_smimecap,
+//GO(PKCS7_add_attribute,
+//GO(PKCS7_add_certificate,
+//GO(PKCS7_add_crl,
+//GO(PKCS7_add_recipient,
+//GO(PKCS7_add_recipient_info,
+//GO(PKCS7_add_signature,
+//GO(PKCS7_add_signed_attribute,
+//GO(PKCS7_add_signer,
+//GO(PKCS7_cert_from_signer_info,
+//GO(PKCS7_content_new,
+//GO(PKCS7_ctrl,
+//GO(PKCS7_dataDecode,
+//GO(PKCS7_dataFinal,
+//GO(PKCS7_dataInit,
+//GO(PKCS7_dataVerify,
+//GO(PKCS7_decrypt,
+//GO(PKCS7_DIGEST_free,
+//GO(PKCS7_digest_from_attributes,
+//GO(PKCS7_DIGEST_new,
+//GO(PKCS7_dup,
+//GO(PKCS7_ENC_CONTENT_free,
+//GO(PKCS7_ENC_CONTENT_new,
+//GO(PKCS7_encrypt,
+//GO(PKCS7_ENCRYPT_free,
+//GO(PKCS7_ENCRYPT_new,
+//GO(PKCS7_ENVELOPE_free,
+//GO(PKCS7_ENVELOPE_new,
+//GO(PKCS7_final,
+GO(PKCS7_free, vFp)
+//GO(PKCS7_get0_signers,
+//GO(PKCS7_get_attribute,
+//GO(PKCS7_get_issuer_and_serial,
+//GO(PKCS7_get_signed_attribute,
+//GO(PKCS7_get_signer_info,
+//GO(PKCS7_get_smimecap,
+//GO(PKCS7_ISSUER_AND_SERIAL_digest,
+//GO(PKCS7_ISSUER_AND_SERIAL_free,
+//GO(PKCS7_ISSUER_AND_SERIAL_new,
+//GO(PKCS7_new,
+//GO(PKCS7_print_ctx,
+//GO(PKCS7_RECIP_INFO_free,
+//GO(PKCS7_RECIP_INFO_get0_alg,
+//GO(PKCS7_RECIP_INFO_new,
+//GO(PKCS7_RECIP_INFO_set,
+//GO(PKCS7_set0_type_other,
+//GO(PKCS7_set_attributes,
+//GO(PKCS7_set_cipher,
+//GO(PKCS7_set_content,
+//GO(PKCS7_set_digest,
+//GO(PKCS7_set_signed_attributes,
+//GO(PKCS7_set_type,
+GO(PKCS7_sign, pFppppi)
+GO(PKCS7_sign_add_signer, pFppppi)
+GO(PKCS7_signatureVerify, iFpppp)
+//GO(PKCS7_SIGNED_free,
+//GO(PKCS7_SIGNED_new,
+//GO(PKCS7_SIGN_ENVELOPE_free,
+//GO(PKCS7_SIGN_ENVELOPE_new,
+//GO(PKCS7_SIGNER_INFO_free,
+//GO(PKCS7_SIGNER_INFO_get0_algs,
+//GO(PKCS7_SIGNER_INFO_new,
+//GO(PKCS7_SIGNER_INFO_set,
+//GO(PKCS7_SIGNER_INFO_sign,
+//GO(PKCS7_simple_smimecap,
+//GO(PKCS7_stream,
+//GO(PKCS7_to_TS_TST_INFO,
+//GO(PKCS7_verify,
+//GO(PKCS8_add_keyusage,
+//GO(PKCS8_decrypt,
+//GO(PKCS8_encrypt,
+//GO(PKCS8_pkey_get0,
+//GO(PKCS8_pkey_set0,
+GO(PKCS8_PRIV_KEY_INFO_free, vFp)
+GO(PKCS8_PRIV_KEY_INFO_new, pFv)
+//GO(PKCS8_set_broken,
+//GO(PKEY_USAGE_PERIOD_free,
+//GO(PKEY_USAGE_PERIOD_new,
+//GO(policy_cache_find_data,
+//GO(policy_cache_free,
+//GO(policy_cache_set,
+//GO(policy_cache_set_mapping,
+//GO(POLICY_CONSTRAINTS_free,
+//GO(POLICY_CONSTRAINTS_new,
+//GO(policy_data_free,
+//GO(policy_data_new,
+//GO(POLICYINFO_free,
+//GO(POLICYINFO_new,
+//GO(POLICY_MAPPING_free,
+//GO(POLICY_MAPPING_new,
+//GO(policy_node_cmp_new,
+//GO(policy_node_free,
+//GO(policy_node_match,
+//GO(POLICYQUALINFO_free,
+//GO(POLICYQUALINFO_new,
+//GO(pqueue_find,
+//GO(pqueue_free,
+//GO(pqueue_insert,
+//GO(pqueue_iterator,
+//GO(pqueue_new,
+//GO(pqueue_next,
+//GO(pqueue_peek,
+//GO(pqueue_pop,
+//GO(pqueue_print,
+//GO(pqueue_size,
+GO(private_AES_set_decrypt_key, iFpip)
+GO(private_AES_set_encrypt_key, iFpip)
+//GO(private_Camellia_set_key,
+//GO(private_RC4_set_key,
+//GO(PROXY_CERT_INFO_EXTENSION_free,
+//GO(PROXY_CERT_INFO_EXTENSION_new,
+//GO(PROXY_POLICY_free,
+//GO(PROXY_POLICY_new,
+GO(RAND_add, vFpid)
+GO(RAND_bytes, iFpi)
+//GO(RAND_cleanup,
+GO(RAND_egd, iFp)
+GO(RAND_egd_bytes, iFpi)
+GO(RAND_file_name, pFpL)
+//GO(RAND_get_rand_method,
+GO(RAND_load_file, iFpl)
+GO(RAND_poll, iFv)
+GO(RAND_pseudo_bytes, iFpi)
+GO(RAND_query_egd_bytes, iFppi)
+GO(RAND_seed, vFpi)
+//GO(RAND_set_rand_engine,
+//GO(RAND_set_rand_method,
+GO(RAND_SSLeay, pFv)
+GO(RAND_status, iFv)
+GO(RAND_write_file, iFp)
+//GO(RC2_cbc_encrypt,
+//GO(RC2_cfb64_encrypt,
+//GO(RC2_decrypt,
+//GO(RC2_ecb_encrypt,
+//GO(RC2_encrypt,
+//GO(RC2_ofb64_encrypt,
+//GO(RC2_set_key,
+//GO(RC4,
+//GO(RC4_options,
+//GO(RC4_set_key,
+//GO(RIPEMD160,
+//GO(ripemd160_block_data_order,
+//GO(RIPEMD160_Final,
+//GO(RIPEMD160_Init,
+//GO(RIPEMD160_Transform,
+//GO(RIPEMD160_Update,
+//GO(RSA_blinding_off,
+//GO(RSA_blinding_on,
+GO(RSA_check_key, iFp)
+//GO(RSA_flags,
+GO(RSA_free, vFp)
+//GO(RSA_generate_key,
+GO(RSA_generate_key_ex, iFpipp)
+GO(RSA_get0_crt_params, vFpppp)
+GO(RSA_get0_factors, vFppp)
+GO(RSA_get0_key, vFpppp)
+//GO(RSA_get_default_method,
+//GO(RSA_get_ex_data,
+//GO(RSA_get_ex_new_index,
+GO(RSA_get_method, pFp)
+//GO(RSA_memory_lock,
+GO(RSA_meth_get_flags, iFp)
+GO(RSA_new, pFv)
+GO(RSA_new_method, pFp)
+//GO(RSA_null_method,
+//GO(RSA_OAEP_PARAMS_free,
+//GO(RSA_OAEP_PARAMS_new,
+//GO(RSA_padding_add_none,
+//GO(RSA_padding_add_PKCS1_OAEP,
+//GO(RSA_padding_add_PKCS1_OAEP_mgf1,
+//GO(RSA_padding_add_PKCS1_PSS,
+//GO(RSA_padding_add_PKCS1_PSS_mgf1,
+//GO(RSA_padding_add_PKCS1_type_1,
+//GO(RSA_padding_add_PKCS1_type_2,
+//GO(RSA_padding_add_SSLv23,
+//GO(RSA_padding_add_X931,
+//GO(RSA_padding_check_none,
+//GO(RSA_padding_check_PKCS1_OAEP,
+//GO(RSA_padding_check_PKCS1_OAEP_mgf1,
+//GO(RSA_padding_check_PKCS1_type_1,
+//GO(RSA_padding_check_PKCS1_type_2,
+//GO(RSA_padding_check_SSLv23,
+//GO(RSA_padding_check_X931,
+GO(RSA_PKCS1_OpenSSL, pFv)
+GO(RSA_PKCS1_SSLeay, pFv)
+GO(RSA_pkey_ctx_ctrl, iFpiiip)
+//GO(RSA_print,
+//GO(RSA_print_fp,
+GO(RSA_private_decrypt, iFipppi)
+GO(RSA_private_encrypt, iFipppi)
+//GO(RSAPrivateKey_dup,
+//GO(RSA_PSS_PARAMS_free,
+//GO(RSA_PSS_PARAMS_new,
+GO(RSA_public_decrypt, iFipppi)
+GO(RSA_public_encrypt, iFipppi)
+//GO(RSAPublicKey_dup,
+GO(RSA_set0_crt_params, iFpppp)
+GO(RSA_set0_factors, iFppp)
+GO(RSA_set0_key, iFpppp)
+//GO(RSA_set_default_method,
+//GO(RSA_set_ex_data,
+GO(RSA_set_method, iFpp)
+//GO(RSA_setup_blinding,
+GO(RSA_sign, iFipuppp)
+GO(RSA_sign_ASN1_OCTET_STRING, iFipuppp)
+GO(RSA_size, iFp)
+GO(RSA_test_flags, iFpi)
+GO(RSA_up_ref, iFp)
+GO(RSA_verify, iFipupup)
+GO(RSA_verify_ASN1_OCTET_STRING, iFipupup)
+GO(RSA_verify_PKCS1_PSS, iFppppi)
+GO(RSA_verify_PKCS1_PSS_mgf1, iFpppppi)
+//GO(RSA_X931_hash_id,
+//GO(s2i_ASN1_INTEGER,
+//GO(s2i_ASN1_OCTET_STRING,
+//GO(SEED_cbc_encrypt,
+//GO(SEED_cfb128_encrypt,
+//GO(SEED_decrypt,
+//GO(SEED_ecb_encrypt,
+//GO(SEED_encrypt,
+//GO(SEED_ofb128_encrypt,
+//GO(SEED_set_key,
+//GO(SHA,
+GO(SHA1, pFpLp)
+//GO(sha1_block_data_order,
+GO(SHA1_Final, iFpp)
+GO(SHA1_Init, iFp)
+//GO(SHA1_Transform,
+GO(SHA1_Update, iFppL)
+GO(SHA224, pFpLp)
+GO(SHA224_Final, iFpp)
+GO(SHA224_Init, iFp)
+GO(SHA224_Update, iFppL)
+GO(SHA256, pFpLp)
+//GO(sha256_block_data_order,
+//GO(sha256_block_data_order_neon,
+GO(SHA256_Final, iFpp)
+GO(SHA256_Init, iFp)
+//GO(SHA256_Transform,
+GO(SHA256_Update, iFppL)
+GO(SHA384, pFpLp)
+GO(SHA384_Final, iFpp)
+GO(SHA384_Init, iFp)
+GO(SHA384_Update, iFppL)
+GO(SHA512, pFpLp)
+//GO(sha512_block_data_order,
+GO(SHA512_Final, iFpp)
+GO(SHA512_Init, iFp)
+//GO(SHA512_Transform,
+GO(SHA512_Update, iFppL)
+//GO(SHA_Final,
+//GO(SHA_Init,
+//GO(SHA_Transform,
+//GO(SHA_Update,
+GO(SMIME_crlf_copy, iFppi)
+GO(SMIME_read_ASN1, pFppp)
+//GO(SMIME_read_CMS,
+//GO(SMIME_read_PKCS7,
+GO(SMIME_text, iFpp)
+GO(SMIME_write_ASN1, iFpppiiipp)
+//GO(SMIME_write_CMS,
+//GO(SMIME_write_PKCS7,
+//GO(SRP_Calc_A,
+//GO(SRP_Calc_B,
+//GO(SRP_Calc_client_key,
+//GO(SRP_Calc_server_key,
+//GO(SRP_Calc_u,
+//GO(SRP_Calc_x,
+//GO(SRP_check_known_gN_param,
+//GO(SRP_create_verifier,
+//GO(SRP_create_verifier_BN,
+//GO(SRP_get_default_gN,
+//GO(SRP_user_pwd_free,
+//GO(SRP_VBASE_free,
+//GO(SRP_VBASE_get1_by_user,
+//GO(SRP_VBASE_get_by_user,
+//GO(SRP_VBASE_init,
+//GO(SRP_VBASE_new,
+//GO(SRP_Verify_A_mod_N,
+//GO(SRP_Verify_B_mod_N,
+GO(SSLeay, lFv)
+//GO(ssleay_rand_bytes,
+GO(SSLeay_version, pFi)
+//GO(string_to_hex,
+//GO(SXNET_add_id_asc,
+//GO(SXNET_add_id_INTEGER,
+//GO(SXNET_add_id_ulong,
+//GO(SXNET_free,
+//GO(SXNET_get_id_asc,
+//GO(SXNET_get_id_INTEGER,
+//GO(SXNET_get_id_ulong,
+//GO(SXNETID_free,
+//GO(SXNETID_new,
+//GO(SXNET_new,
+//GO(tree_find_sk,
+//GO(TS_ACCURACY_dup,
+//GO(TS_ACCURACY_free,
+//GO(TS_ACCURACY_get_micros,
+//GO(TS_ACCURACY_get_millis,
+//GO(TS_ACCURACY_get_seconds,
+//GO(TS_ACCURACY_new,
+//GO(TS_ACCURACY_set_micros,
+//GO(TS_ACCURACY_set_millis,
+//GO(TS_ACCURACY_set_seconds,
+//GO(TS_ASN1_INTEGER_print_bio,
+//GO(TS_CONF_get_tsa_section,
+//GO(TS_CONF_load_cert,
+//GO(TS_CONF_load_certs,
+//GO(TS_CONF_load_key,
+//GO(TS_CONF_set_accuracy,
+//GO(TS_CONF_set_certs,
+//GO(TS_CONF_set_clock_precision_digits,
+//GO(TS_CONF_set_crypto_device,
+//GO(TS_CONF_set_default_engine,
+//GO(TS_CONF_set_def_policy,
+//GO(TS_CONF_set_digests,
+//GO(TS_CONF_set_ess_cert_id_chain,
+//GO(TS_CONF_set_ordering,
+//GO(TS_CONF_set_policies,
+//GO(TS_CONF_set_serial,
+//GO(TS_CONF_set_signer_cert,
+//GO(TS_CONF_set_signer_key,
+//GO(TS_CONF_set_tsa_name,
+//GO(TS_ext_print_bio,
+//GO(TS_MSG_IMPRINT_dup,
+//GO(TS_MSG_IMPRINT_free,
+//GO(TS_MSG_IMPRINT_get_algo,
+//GO(TS_MSG_IMPRINT_get_msg,
+//GO(TS_MSG_IMPRINT_new,
+//GO(TS_MSG_IMPRINT_print_bio,
+//GO(TS_MSG_IMPRINT_set_algo,
+//GO(TS_MSG_IMPRINT_set_msg,
+//GO(TS_OBJ_print_bio,
+//GO(TS_REQ_add_ext,
+//GO(TS_REQ_delete_ext,
+//GO(TS_REQ_dup,
+//GO(TS_REQ_ext_free,
+//GO(TS_REQ_free,
+//GO(TS_REQ_get_cert_req,
+//GO(TS_REQ_get_ext,
+//GO(TS_REQ_get_ext_by_critical,
+//GO(TS_REQ_get_ext_by_NID,
+//GO(TS_REQ_get_ext_by_OBJ,
+//GO(TS_REQ_get_ext_count,
+//GO(TS_REQ_get_ext_d2i,
+//GO(TS_REQ_get_exts,
+//GO(TS_REQ_get_msg_imprint,
+//GO(TS_REQ_get_nonce,
+//GO(TS_REQ_get_policy_id,
+//GO(TS_REQ_get_version,
+//GO(TS_REQ_new,
+//GO(TS_REQ_print_bio,
+//GO(TS_REQ_set_cert_req,
+//GO(TS_REQ_set_msg_imprint,
+//GO(TS_REQ_set_nonce,
+//GO(TS_REQ_set_policy_id,
+//GO(TS_REQ_set_version,
+//GO(TS_REQ_to_TS_VERIFY_CTX,
+//GO(TS_RESP_create_response,
+//GO(TS_RESP_CTX_add_failure_info,
+//GO(TS_RESP_CTX_add_flags,
+//GO(TS_RESP_CTX_add_md,
+//GO(TS_RESP_CTX_add_policy,
+//GO(TS_RESP_CTX_free,
+//GO(TS_RESP_CTX_get_request,
+//GO(TS_RESP_CTX_get_tst_info,
+//GO(TS_RESP_CTX_new,
+//GO(TS_RESP_CTX_set_accuracy,
+//GO(TS_RESP_CTX_set_certs,
+//GO(TS_RESP_CTX_set_clock_precision_digits,
+//GO(TS_RESP_CTX_set_def_policy,
+//GO(TS_RESP_CTX_set_extension_cb,
+//GO(TS_RESP_CTX_set_serial_cb,
+//GO(TS_RESP_CTX_set_signer_cert,
+//GO(TS_RESP_CTX_set_signer_key,
+//GO(TS_RESP_CTX_set_status_info,
+//GO(TS_RESP_CTX_set_status_info_cond,
+//GO(TS_RESP_CTX_set_time_cb,
+//GO(TS_RESP_dup,
+//GO(TS_RESP_free,
+//GO(TS_RESP_get_status_info,
+//GO(TS_RESP_get_token,
+//GO(TS_RESP_get_tst_info,
+//GO(TS_RESP_new,
+//GO(TS_RESP_print_bio,
+//GO(TS_RESP_set_status_info,
+//GO(TS_RESP_set_tst_info,
+//GO(TS_RESP_verify_response,
+//GO(TS_RESP_verify_signature,
+//GO(TS_RESP_verify_token,
+//GO(TS_STATUS_INFO_dup,
+//GO(TS_STATUS_INFO_free,
+//GO(TS_STATUS_INFO_new,
+//GO(TS_STATUS_INFO_print_bio,
+//GO(TS_TST_INFO_add_ext,
+//GO(TS_TST_INFO_delete_ext,
+//GO(TS_TST_INFO_dup,
+//GO(TS_TST_INFO_ext_free,
+//GO(TS_TST_INFO_free,
+//GO(TS_TST_INFO_get_accuracy,
+//GO(TS_TST_INFO_get_ext,
+//GO(TS_TST_INFO_get_ext_by_critical,
+//GO(TS_TST_INFO_get_ext_by_NID,
+//GO(TS_TST_INFO_get_ext_by_OBJ,
+//GO(TS_TST_INFO_get_ext_count,
+//GO(TS_TST_INFO_get_ext_d2i,
+//GO(TS_TST_INFO_get_exts,
+//GO(TS_TST_INFO_get_msg_imprint,
+//GO(TS_TST_INFO_get_nonce,
+//GO(TS_TST_INFO_get_ordering,
+//GO(TS_TST_INFO_get_policy_id,
+//GO(TS_TST_INFO_get_serial,
+//GO(TS_TST_INFO_get_time,
+//GO(TS_TST_INFO_get_tsa,
+//GO(TS_TST_INFO_get_version,
+//GO(TS_TST_INFO_new,
+//GO(TS_TST_INFO_print_bio,
+//GO(TS_TST_INFO_set_accuracy,
+//GO(TS_TST_INFO_set_msg_imprint,
+//GO(TS_TST_INFO_set_nonce,
+//GO(TS_TST_INFO_set_ordering,
+//GO(TS_TST_INFO_set_policy_id,
+//GO(TS_TST_INFO_set_serial,
+//GO(TS_TST_INFO_set_time,
+//GO(TS_TST_INFO_set_tsa,
+//GO(TS_TST_INFO_set_version,
+//GO(TS_VERIFY_CTX_cleanup,
+//GO(TS_VERIFY_CTX_free,
+//GO(TS_VERIFY_CTX_init,
+//GO(TS_VERIFY_CTX_new,
+//GO(TS_X509_ALGOR_print_bio,
+//GO(TXT_DB_create_index,
+//GO(TXT_DB_free,
+//GO(TXT_DB_get_by_index,
+//GO(TXT_DB_insert,
+//GO(TXT_DB_read,
+//GO(TXT_DB_write,
+GO(UI_add_error_string, iFpp)
+GO(UI_add_info_string, iFpp)
+GO(UI_add_input_boolean, iFpppppip)
+GO(UI_add_input_string, iFppipii)
+GO(UI_add_user_data, pFpp)
+//GO(UI_add_verify_string,
+GO(UI_construct_prompt, pFppp)
+//GO(UI_create_method,
+//GO(UI_ctrl,
+//GO(UI_destroy_method,
+GO(UI_dup_error_string, iFpp)
+GO(UI_dup_info_string, iFpp)
+GO(UI_dup_input_boolean, iFpppppip)
+GO(UI_dup_input_string, iFppipii)
+GO(UI_dup_verify_string, iFppipiip)
+GO(UI_free, vFp)
+//GO(UI_get0_action_string,
+//GO(UI_get0_output_string,
+GO(UI_get0_result, pFpi)
+//GO(UI_get0_result_string,
+//GO(UI_get0_test_string,
+GO(UI_get0_user_data, pFp)
+GO(UI_get_default_method, pFv)
+//GO(UI_get_ex_data,
+//GO(UI_get_ex_new_index,
+//GO(UI_get_input_flags,
+GO(UI_get_method, pFp)
+//GO(UI_get_result_maxsize,
+//GO(UI_get_result_minsize,
+//GO(UI_get_string_type,
+//GO(UI_method_get_closer,
+//GO(UI_method_get_flusher,
+//GO(UI_method_get_opener,
+//GO(UI_method_get_prompt_constructor,
+//GO(UI_method_get_reader,
+//GO(UI_method_get_writer,
+//GO(UI_method_set_closer,
+//GO(UI_method_set_flusher,
+//GO(UI_method_set_opener,
+//GO(UI_method_set_prompt_constructor,
+//GO(UI_method_set_reader,
+//GO(UI_method_set_writer,
+GO(UI_new, pFv)
+GO(UI_new_method, pFp)
+GO(UI_OpenSSL, pFv)
+GO(UI_process, iFp)
+GO(UI_set_default_method, vFp)
+//GO(UI_set_ex_data,
+GO(UI_set_method, pFpp)
+//GO(UI_set_result,
+//GO(UI_UTIL_read_pw,
+//GO(UI_UTIL_read_pw_string,
+//GO(USERNOTICE_free,
+//GO(USERNOTICE_new,
+GO(UTF8_getc, iFpip)
+GO(UTF8_putc, iFpiL)
+//GO(v2i_ASN1_BIT_STRING,
+//GO(v2i_GENERAL_NAME,
+//GO(v2i_GENERAL_NAME_ex,
+//GO(v2i_GENERAL_NAMES,
+//GO(WHIRLPOOL,
+//GO(WHIRLPOOL_BitUpdate,
+//GO(whirlpool_block,
+//GO(WHIRLPOOL_Final,
+//GO(WHIRLPOOL_Init,
+//GO(WHIRLPOOL_Update,
+GO(X509_add1_ext_i2d, iFpipiL)
+//GO(X509_add1_reject_object,
+//GO(X509_add1_trust_object,
+//GO(X509_add_ext,
+//GO(X509_ALGOR_cmp,
+//GO(X509_ALGOR_dup,
+//GO(X509_ALGOR_free,
+//GO(X509_ALGOR_get0,
+//GO(X509_ALGOR_new,
+//GO(X509_ALGOR_set0,
+//GO(X509_ALGOR_set_md,
+//GO(X509_alias_get0,
+//GO(X509_alias_set1,
+//GO(X509at_add1_attr,
+//GO(X509at_add1_attr_by_NID,
+//GO(X509at_add1_attr_by_OBJ,
+//GO(X509at_add1_attr_by_txt,
+//GO(X509at_delete_attr,
+//GO(X509at_get0_data_by_OBJ,
+//GO(X509at_get_attr,
+//GO(X509at_get_attr_by_NID,
+//GO(X509at_get_attr_by_OBJ,
+//GO(X509at_get_attr_count,
+//GO(X509_ATTRIBUTE_count,
+//GO(X509_ATTRIBUTE_create,
+//GO(X509_ATTRIBUTE_create_by_NID,
+//GO(X509_ATTRIBUTE_create_by_OBJ,
+//GO(X509_ATTRIBUTE_create_by_txt,
+//GO(X509_ATTRIBUTE_dup,
+//GO(X509_ATTRIBUTE_free,
+//GO(X509_ATTRIBUTE_get0_data,
+//GO(X509_ATTRIBUTE_get0_object,
+//GO(X509_ATTRIBUTE_get0_type,
+//GO(X509_ATTRIBUTE_new,
+//GO(X509_ATTRIBUTE_set1_data,
+//GO(X509_ATTRIBUTE_set1_object,
+//GO(X509_CERT_AUX_free,
+//GO(X509_CERT_AUX_new,
+//GO(X509_CERT_AUX_print,
+//GO(X509_certificate_type,
+//GO(X509_CERT_PAIR_free,
+//GO(X509_CERT_PAIR_new,
+//GO(X509_chain_check_suiteb,
+//GO(X509_chain_up_ref,
+//GO(X509_check_akid,
+//GO(X509_check_ca,
+//GO(X509_check_email,
+GO(X509_check_host, iFppLup)
+//GO(X509_check_ip,
+//GO(X509_check_ip_asc,
+GO(X509_check_issued, iFpp)
+//GO(X509_check_private_key,
+GO(X509_check_purpose, iFpii)
+//GO(X509_check_trust,
+//GO(X509_CINF_free,
+//GO(X509_CINF_new,
+GO(X509_cmp, iFpp)
+GO(X509_cmp_current_time, iFp)
+GO(X509_cmp_time, iFpp)
+//GO(X509_CRL_add0_revoked,
+GO(X509_CRL_add1_ext_i2d, iFpipiL)
+//GO(X509_CRL_add_ext,
+//GO(X509_CRL_check_suiteb,
+//GO(X509_CRL_cmp,
+//GO(X509_CRL_delete_ext,
+//GO(X509_CRL_diff,
+//GO(X509_CRL_digest,
+//GO(X509_CRL_dup,
+GO(X509_CRL_free, vFp)
+//GO(X509_CRL_get0_by_cert,
+//GO(X509_CRL_get0_by_serial,
+GO(X509_CRL_get0_nextUpdate, pFp)
+//GO(X509_CRL_get_ext,
+//GO(X509_CRL_get_ext_by_critical,
+//GO(X509_CRL_get_ext_by_NID,
+//GO(X509_CRL_get_ext_by_OBJ,
+//GO(X509_CRL_get_ext_count,
+GO(X509_CRL_get_ext_d2i, pFpipp)
+//GO(X509_CRL_get_meth_data,
+//GO(X509_CRL_http_nbio,
+//GO(X509_CRL_INFO_free,
+//GO(X509_CRL_INFO_new,
+//GO(X509_CRL_match,
+//GO(X509_CRL_METHOD_free,
+//GO(X509_CRL_METHOD_new,
+//GO(X509_CRL_new,
+//GO(X509_CRL_print,
+//GO(X509_CRL_print_fp,
+//GO(X509_CRL_set_default_method,
+GO(X509_CRL_set_issuer_name, iFpp)
+//GO(X509_CRL_set_lastUpdate,
+//GO(X509_CRL_set_meth_data,
+//GO(X509_CRL_set_nextUpdate,
+//GO(X509_CRL_set_version,
+//GO(X509_CRL_sign,
+//GO(X509_CRL_sign_ctx,
+//GO(X509_CRL_sort,
+//GO(X509_CRL_verify,
+//GO(X509_delete_ext,
+GO(X509_digest, iFpppp)
+GO(X509_dup, pFp)
+//GO(X509_email_free,
+GO(X509_EXTENSION_create_by_NID, pFpiip)
+GO(X509_EXTENSION_create_by_OBJ, pFppip)
+//GO(X509_EXTENSION_dup,
+GO(X509_EXTENSION_free, vFp)
+GO(X509_EXTENSION_get_critical, iFp)
+GO(X509_EXTENSION_get_data, pFp)
+GO(X509_EXTENSION_get_object, pFp)
+//GO(X509_EXTENSION_new,
+GO(X509_EXTENSION_set_critical, iFpi)
+GO(X509_EXTENSION_set_data, iFpp)
+GO(X509_EXTENSION_set_object, iFpp)
+//GO(X509_find_by_issuer_and_serial,
+//GO(X509_find_by_subject,
+GO(X509_free, vFp)
+GO(X509_get0_pubkey_bitstr, pFp)
+//GO(X509_get0_signature,
+GO(X509_get0_tbs_sigalg, pFp)
+//GO(X509_get1_email,
+//GO(X509_get1_ocsp,
+//GO(X509_get_default_cert_area,
+GO(X509_get_default_cert_dir, pFv)
+GO(X509_get_default_cert_dir_env, pFv)
+GO(X509_get_default_cert_file, pFv)
+GO(X509_get_default_cert_file_env, pFv)
+//GO(X509_get_default_private_dir,
+//GO(X509_get_ex_data,
+//GO(X509_get_ex_new_index,
+GO(X509_get_ext, pFpi)
+GO(X509_get_ext_by_critical, iFpii)
+GO(X509_get_ext_by_NID, iFpii)
+GO(X509_get_ext_by_OBJ, iFppi)
+GO(X509_get_ext_count, iFp)
+GO(X509_get_ext_d2i, pFpipp)
+GO(X509_get_issuer_name, pFp)
+GO(X509_get_pubkey, pFp)
+//GO(X509_get_pubkey_parameters,
+GO(X509_get0_notAfter, pFp)
+GO(X509_get0_notBefore, pFp)
+GO(X509_get0_pubkey, pFp)
+GO(X509_get0_serialNumber, pFp)
+GO(X509_get_serialNumber, pFp)
+//GO(X509_get_signature_nid,
+GO(X509_get_subject_name, pFp)
+GO(X509_get_version, lFp)
+GO(X509_get_X509_PUBKEY, pFp)
+//GO(X509_gmtime_adj,
+//GO(X509_http_nbio,
+//GO(X509_INFO_free,
+//GO(X509_INFO_new,
+//GO(X509_issuer_and_serial_cmp,
+//GO(X509_issuer_and_serial_hash,
+//GO(X509_issuer_name_cmp,
+GO(X509_issuer_name_hash, LFp)
+GO(X509_issuer_name_hash_old, LFp)
+//GO(X509_keyid_get0,
+//GO(X509_keyid_set1,
+GO(X509_load_cert_crl_file, iFppi)
+GO(X509_load_cert_file, iFppi)
+GO(X509_load_crl_file, iFppi)
+//GO(X509_LOOKUP_by_alias,
+//GO(X509_LOOKUP_by_fingerprint,
+//GO(X509_LOOKUP_by_issuer_serial,
+//GO(X509_LOOKUP_by_subject,
+//GO(X509_LOOKUP_ctrl,
+GO(X509_LOOKUP_file, pFv)
+//GO(X509_LOOKUP_free,
+GO(X509_LOOKUP_hash_dir, pFv)
+//GO(X509_LOOKUP_init,
+//GO(X509_LOOKUP_new,
+//GO(X509_LOOKUP_shutdown,
+//GO(X509_NAME_add_entry,
+//GO(X509_NAME_add_entry_by_NID,
+//GO(X509_NAME_add_entry_by_OBJ,
+GO(X509_NAME_add_entry_by_txt, iFppipiii)
+//GO(X509_NAME_cmp,
+//GO(X509_NAME_delete_entry,
+//GO(X509_NAME_digest,
+//GO(X509_NAME_dup,
+GO(X509_NAME_entry_count, iFp)
+GO(X509_NAME_ENTRY_create_by_NID, pFpiipi)
+GO(X509_NAME_ENTRY_create_by_OBJ, pFppipi)
+GO(X509_NAME_ENTRY_create_by_txt, pFppipi)
+//GO(X509_NAME_ENTRY_dup,
+//GO(X509_NAME_ENTRY_free,
+GO(X509_NAME_ENTRY_get_data, pFp)
+GO(X509_NAME_ENTRY_get_object, pFp)
+//GO(X509_NAME_ENTRY_new,
+GO(X509_NAME_ENTRY_set_data, iFpipi)
+GO(X509_NAME_ENTRY_set_object, iFpp)
+GO(X509_NAME_free, vFp)
+GO(X509_NAME_get0_der, iFppp)
+GO(X509_NAME_get_entry, pFpi)
+GO(X509_NAME_get_index_by_NID, iFpii)
+GO(X509_NAME_get_index_by_OBJ, iFppi)
+GO(X509_NAME_get_text_by_NID, iFpipi)
+GO(X509_NAME_get_text_by_OBJ, iFpppi)
+//GO(X509_NAME_hash,
+//GO(X509_NAME_hash_old,
+//GO(X509_NAME_new,
+GO(X509_NAME_oneline, pFppi)
+GO(X509_NAME_print, iFppi)
+GO(X509_NAME_print_ex, iFppiu)
+GO(X509_NAME_print_ex_fp, iFppiu)
+//GO(X509_NAME_set,
+GO(X509_new, pFv)
+//GO(X509_OBJECT_free_contents,
+//GO(X509_OBJECT_idx_by_subject,
+//GO(X509_OBJECT_retrieve_by_subject,
+//GO(X509_OBJECT_retrieve_match,
+//GO(X509_OBJECT_up_ref_count,
+//GO(X509_ocspid_print,
+//GO(X509_PKEY_free,
+//GO(X509_PKEY_new,
+//GO(X509_policy_check,
+//GO(X509_policy_level_get0_node,
+//GO(X509_policy_level_node_count,
+//GO(X509_policy_node_get0_parent,
+//GO(X509_policy_node_get0_policy,
+//GO(X509_policy_node_get0_qualifiers,
+//GO(X509_POLICY_NODE_print,
+//GO(X509_policy_tree_free,
+//GO(X509_policy_tree_get0_level,
+//GO(X509_policy_tree_get0_policies,
+//GO(X509_policy_tree_get0_user_policies,
+//GO(X509_policy_tree_level_count,
+GO(X509_print, iFpp)
+GO(X509_print_ex, iFppLL)
+GO(X509_print_ex_fp, iFppLL)
+GO(X509_print_fp, iFpp)
+//GO(X509_pubkey_digest,
+//GO(X509_PUBKEY_free,
+GO(X509_PUBKEY_get, pFp)
+GO(X509_PUBKEY_get0_param, iFppppp)
+//GO(X509_PUBKEY_new,
+//GO(X509_PUBKEY_set,
+//GO(X509_PUBKEY_set0_param,
+//GO(X509_PURPOSE_add,
+//GO(X509_PURPOSE_cleanup,
+//GO(X509_PURPOSE_get0,
+//GO(X509_PURPOSE_get0_name,
+//GO(X509_PURPOSE_get0_sname,
+//GO(X509_PURPOSE_get_by_id,
+//GO(X509_PURPOSE_get_by_sname,
+//GO(X509_PURPOSE_get_count,
+//GO(X509_PURPOSE_get_id,
+//GO(X509_PURPOSE_get_trust,
+//GO(X509_PURPOSE_set,
+//GO(X509_reject_clear,
+//GO(X509_REQ_add1_attr,
+//GO(X509_REQ_add1_attr_by_NID,
+//GO(X509_REQ_add1_attr_by_OBJ,
+//GO(X509_REQ_add1_attr_by_txt,
+//GO(X509_REQ_add_extensions,
+//GO(X509_REQ_add_extensions_nid,
+//GO(X509_REQ_check_private_key,
+//GO(X509_REQ_delete_attr,
+//GO(X509_REQ_digest,
+//GO(X509_REQ_dup,
+//GO(X509_REQ_extension_nid,
+//GO(X509_REQ_free,
+//GO(X509_REQ_get1_email,
+//GO(X509_REQ_get_attr,
+//GO(X509_REQ_get_attr_by_NID,
+//GO(X509_REQ_get_attr_by_OBJ,
+//GO(X509_REQ_get_attr_count,
+//GO(X509_REQ_get_extension_nids,
+//GO(X509_REQ_get_extensions,
+GO(X509_REQ_get_pubkey, pFp)
+GO(X509_REQ_get_X509_PUBKEY, pFp)
+GO(X509_REQ_get0_pubkey, pFp)
+//GO(X509_REQ_INFO_free,
+//GO(X509_REQ_INFO_new,
+//GO(X509_REQ_new,
+//GO(X509_REQ_print,
+//GO(X509_REQ_print_ex,
+//GO(X509_REQ_print_fp,
+//GO(X509_REQ_set_extension_nids,
+GO(X509_REQ_set_pubkey, iFpp)
+GO(X509_REQ_set_subject_name, iFpp)
+//GO(X509_REQ_set_version,
+//GO(X509_REQ_sign,
+//GO(X509_REQ_sign_ctx,
+//GO(X509_REQ_to_X509,
+//GO(X509_REQ_verify,
+GO(X509_REVOKED_add1_ext_i2d, iFpipiL)
+//GO(X509_REVOKED_add_ext,
+//GO(X509_REVOKED_delete_ext,
+//GO(X509_REVOKED_dup,
+//GO(X509_REVOKED_free,
+//GO(X509_REVOKED_get_ext,
+//GO(X509_REVOKED_get_ext_by_critical,
+//GO(X509_REVOKED_get_ext_by_NID,
+//GO(X509_REVOKED_get_ext_by_OBJ,
+//GO(X509_REVOKED_get_ext_count,
+GO(X509_REVOKED_get_ext_d2i, pFpipp)
+//GO(X509_REVOKED_new,
+//GO(X509_REVOKED_set_revocationDate,
+//GO(X509_REVOKED_set_serialNumber,
+GO(X509_set1_notAfter, iFpp)
+GO(X509_set1_notBefore, iFpp)
+//GO(X509_set_ex_data,
+GO(X509_set_issuer_name, iFpp)
+//GO(X509_set_notAfter,
+//GO(X509_set_notBefore,
+GO(X509_set_pubkey, iFpp)
+GO(X509_set_serialNumber, iFpp)
+GO(X509_set_subject_name, iFpp)
+//GO(X509_set_version,
+//GO(X509_SIG_free,
+GO(X509_sign, iFppp)
+GO(X509_signature_dump, iFppi)
+GO(X509_signature_print, iFppp)
+GO(X509_sign_ctx, iFpp)
+//GO(X509_SIG_new,
+GO(X509_STORE_add_cert, iFpp)
+GO(X509_STORE_add_crl, iFpp)
+GO(X509_STORE_add_lookup, pFpp)
+GO(X509_STORE_CTX_cleanup, vFp)
+GO(X509_STORE_CTX_free, vFp)
+//GO(X509_STORE_CTX_get0_current_crl,
+//GO(X509_STORE_CTX_get0_current_issuer,
+GO(X509_STORE_CTX_get0_param, pFp)
+//GO(X509_STORE_CTX_get0_parent_ctx,
+//GO(X509_STORE_CTX_get0_policy_tree,
+GO(X509_STORE_CTX_get0_cert, pFp)
+GO(X509_STORE_CTX_get0_chain, pFp)
+GO(X509_STORE_CTX_get0_store, pFp)
+GO(X509_STORE_CTX_get0_untrusted, pFp)
+GO(X509_STORE_CTX_get1_chain, pFp)
+GO(X509_STORE_CTX_get1_issuer, iFppp)
+GO(X509_STORE_CTX_get_chain, pFp)
+GO(X509_STORE_CTX_get_current_cert, pFp)
+GO(X509_STORE_CTX_get_error, iFp)
+GO(X509_STORE_CTX_get_error_depth, iFp)
+//GO(X509_STORE_CTX_get_ex_data,
+//GO(X509_STORE_CTX_get_ex_new_index,
+//GO(X509_STORE_CTX_get_explicit_policy,
+GO(X509_STORE_CTX_init, iFpppp)
+GO(X509_STORE_CTX_new, pFv)
+//GO(X509_STORE_CTX_purpose_inherit,
+//GO(X509_STORE_CTX_set0_crls,
+//GO(X509_STORE_CTX_set0_param,
+//GO(X509_STORE_CTX_set_cert,
+//GO(X509_STORE_CTX_set_chain,
+GO(X509_STORE_CTX_set_current_cert, vFpp)
+GO(X509_STORE_CTX_set_default, iFp)
+//GO(X509_STORE_CTX_set_depth,
+GO(X509_STORE_CTX_set_error, vFpi)
+GO(X509_STORE_CTX_set_error_depth, vFpi)
+//GO(X509_STORE_CTX_set_ex_data,
+GO(X509_STORE_CTX_set_flags, vFpL)
+GO(X509_STORE_CTX_set_purpose, iFpi)
+//GO(X509_STORE_CTX_set_time,
+//GO(X509_STORE_CTX_set_trust,
+GOM(X509_STORE_CTX_set_verify_cb, vFEpp)
+//GO(X509_STORE_CTX_trusted_stack,
+GO(X509_STORE_free, vFp)
+GO(X509_STORE_get0_param, pFp)
+//GO(X509_STORE_get1_certs,
+//GO(X509_STORE_get1_crls,
+//GO(X509_STORE_get_by_subject,
+GO(X509_STORE_load_file, iFpp)
+GO(X509_STORE_load_path, iFpp)
+GO(X509_STORE_load_store, iFpp)
+//GO(X509_STORE_load_locations, iFppp)
+GO(X509_STORE_new, pFv)
+//GO(X509_STORE_set1_param,
+//GO(X509_STORE_set_default_paths,
+GO(X509_STORE_set_depth, iFpi)
+GO(X509_STORE_set_flags, iFpL)
+//GO(X509_STORE_set_lookup_crls_cb,
+GO(X509_STORE_set_purpose, iFpi)
+GO(X509_STORE_set_trust, iFpi)
+//GO(X509_STORE_set_verify_cb,
+//GO(X509_subject_name_cmp,
+GO(X509_subject_name_hash, LFp)
+GO(X509_subject_name_hash_old, LFp)
+//GO(X509_supported_extension,
+//GO(X509_time_adj,
+//GO(X509_time_adj_ex,
+//GO(X509_to_X509_REQ,
+//GO(X509_TRUST_add,
+//GO(X509_TRUST_cleanup,
+//GO(X509_trust_clear,
+//GO(X509_TRUST_get0,
+//GO(X509_TRUST_get0_name,
+//GO(X509_TRUST_get_by_id,
+//GO(X509_TRUST_get_count,
+//GO(X509_TRUST_get_flags,
+//GO(X509_TRUST_get_trust,
+//GO(X509_TRUST_set,
+//GO(X509_TRUST_set_default,
+GO(X509_up_ref, iFp)
+GO(X509V3_add1_i2d, iFpipiL)
+//GO(X509v3_add_ext,
+//GO(X509V3_add_standard_extensions,
+//GO(X509V3_add_value,
+//GO(X509V3_add_value_bool,
+//GO(X509V3_add_value_bool_nf,
+//GO(X509V3_add_value_int,
+//GO(X509V3_add_value_uchar,
+//GO(X509V3_conf_free,
+//GO(X509v3_delete_ext,
+//GO(X509V3_EXT_add,
+//GO(X509V3_EXT_add_alias,
+//GO(X509V3_EXT_add_conf,
+//GO(X509V3_EXT_add_list,
+//GO(X509V3_EXT_add_nconf,
+//GO(X509V3_EXT_add_nconf_sk,
+//GO(X509V3_EXT_cleanup,
+//GO(X509V3_EXT_conf,
+//GO(X509V3_EXT_conf_nid,
+//GO(X509V3_EXT_CRL_add_conf,
+//GO(X509V3_EXT_CRL_add_nconf,
+GO(X509V3_EXT_d2i, pFp)
+//GO(X509V3_extensions_print,
+//GO(X509V3_EXT_free,
+GO(X509V3_EXT_get, pFp)
+//GO(X509V3_EXT_get_nid,
+GO(X509V3_EXT_i2d, pFiip)
+//GO(X509V3_EXT_nconf,
+//GO(X509V3_EXT_nconf_nid,
+GO(X509V3_EXT_print, iFppLi)
+GO(X509V3_EXT_print_fp, iFppii)
+//GO(X509V3_EXT_REQ_add_conf,
+//GO(X509V3_EXT_REQ_add_nconf,
+//GO(X509V3_EXT_val_prn,
+GO(X509V3_get_d2i, pFpipp)
+//GO(X509v3_get_ext,
+//GO(X509v3_get_ext_by_critical,
+//GO(X509v3_get_ext_by_NID,
+//GO(X509v3_get_ext_by_OBJ,
+//GO(X509v3_get_ext_count,
+//GO(X509V3_get_section,
+//GO(X509V3_get_string,
+//GO(X509V3_get_value_bool,
+//GO(X509V3_get_value_int,
+//GO(X509V3_NAME_from_section,
+//GO(X509V3_parse_list,
+//GO(X509V3_section_free,
+//GO(X509V3_set_conf_lhash,
+//GO(X509V3_set_ctx,
+//GO(X509V3_set_nconf,
+//GO(X509V3_string_free,
+//GO(X509_VAL_free,
+//GO(X509_VAL_new,
+//GO(X509_verify,
+GO(X509_verify_cert, iFp)
+GO(X509_verify_cert_error_string, pFl)
+//GO(X509_VERIFY_PARAM_add0_policy,
+//GO(X509_VERIFY_PARAM_add0_table,
+//GO(X509_VERIFY_PARAM_add1_host,
+GO(X509_VERIFY_PARAM_clear_flags, iFpL)
+//GO(X509_VERIFY_PARAM_free,
+//GO(X509_VERIFY_PARAM_get0,
+//GO(X509_VERIFY_PARAM_get0_name,
+//GO(X509_VERIFY_PARAM_get0_peername,
+//GO(X509_VERIFY_PARAM_get_count,
+//GO(X509_VERIFY_PARAM_get_depth,
+GO(X509_VERIFY_PARAM_get_flags, LFp)
+//GO(X509_VERIFY_PARAM_inherit,
+//GO(X509_VERIFY_PARAM_lookup,
+//GO(X509_VERIFY_PARAM_new,
+//GO(X509_VERIFY_PARAM_set1,
+//GO(X509_VERIFY_PARAM_set1_email,
+//GO(X509_VERIFY_PARAM_set1_host,
+//GO(X509_VERIFY_PARAM_set1_ip,
+//GO(X509_VERIFY_PARAM_set1_ip_asc,
+//GO(X509_VERIFY_PARAM_set1_name,
+//GO(X509_VERIFY_PARAM_set1_policies,
+//GO(X509_VERIFY_PARAM_set_depth,
+//GO(X509_VERIFY_PARAM_set_flags,
+//GO(X509_VERIFY_PARAM_set_hostflags,
+//GO(X509_VERIFY_PARAM_set_purpose,
+GO(X509_VERIFY_PARAM_set_time, vFpl)
+//GO(X509_VERIFY_PARAM_set_trust,
+//GO(X509_VERIFY_PARAM_table_cleanup,
+//GO(X9_62_CHARACTERISTIC_TWO_free,
+//GO(X9_62_CHARACTERISTIC_TWO_new,
+//GO(X9_62_PENTANOMIAL_free,
+//GO(X9_62_PENTANOMIAL_new,
diff --git a/src/wrapped/wrappedcrypto_private.h b/src/wrapped/wrappedcrypto_private.h
index 87d73af..ab3b3ba 100755..100644
--- a/src/wrapped/wrappedcrypto_private.h
+++ b/src/wrapped/wrappedcrypto_private.h
@@ -96,7 +96,7 @@ GOM(ASN1_i2d_bio, iFEppp)
//GO(ASN1_i2d_fp,
//GO(ASN1_IA5STRING_free,
//GO(ASN1_IA5STRING_new,
-//GO(ASN1_INTEGER_cmp,
+GO(ASN1_INTEGER_cmp, iFpp)
//GO(ASN1_INTEGER_dup,
GO(ASN1_INTEGER_free, vFp)
GO(ASN1_INTEGER_get, lFp)
@@ -172,6 +172,7 @@ GO(ASN1_STRING_data, pFp)
GO(ASN1_STRING_dup, pFp)
GO(ASN1_STRING_free, vFp)
//GO(ASN1_STRING_get_default_mask,
+GO(ASN1_STRING_get0_data, pFp)
GO(ASN1_STRING_length, iFp)
//GO(ASN1_STRING_length_set,
//GO(ASN1_STRING_new,
@@ -255,12 +256,14 @@ GO(BASIC_CONSTRAINTS_new, pFv)
//GO(BF_options,
//GO(BF_set_key,
//GO(BIO_accept,
+GO(BIO_ADDR_free, vFp)
+GO(BIO_ADDR_new, pFv)
//GO(BIO_asn1_get_prefix,
//GO(BIO_asn1_get_suffix,
//GO(BIO_asn1_set_prefix,
//GO(BIO_asn1_set_suffix,
//GO(BIO_callback_ctrl,
-//GO(BIO_clear_flags,
+GO(BIO_clear_flags, vFpi)
//GO(BIO_CONNECT_free,
//GO(BIO_CONNECT_new,
//GO(BIO_copy_next_retry,
@@ -299,17 +302,28 @@ GO(BIO_free_all, vFp)
//GO(BIO_get_callback,
//GO(BIO_get_callback_arg,
GO(BIO_get_close, iFp)
-//GO(BIO_get_ex_data,
+GO(BIO_get_data, pFp)
+GO(BIO_get_ex_data, pFpi)
//GO(BIO_get_ex_new_index,
//GO(BIO_gethostbyname,
//GO(BIO_get_host_ip,
//GO(BIO_get_port,
//GO(BIO_get_retry_BIO,
//GO(BIO_get_retry_reason,
+GO(BIO_get_shutdown, iFp)
GO(BIO_gets, iFppi)
//GO(BIO_hex_string,
//GO(BIO_indent,
GO(BIO_int_ctrl, lFpili)
+GO(BIO_meth_free, vFp)
+GO(BIO_meth_new, pFip)
+GOM(BIO_meth_set_write, iFEpp)
+GOM(BIO_meth_set_read, iFEpp)
+GOM(BIO_meth_set_puts, iFEpp)
+GOM(BIO_meth_set_gets, iFEpp)
+GOM(BIO_meth_set_ctrl, iFEpp)
+GOM(BIO_meth_set_create, iFEpp)
+GOM(BIO_meth_set_destroy, iFEpp)
//GO(BIO_method_name,
//GO(BIO_method_type,
GO(BIO_new, pFp)
@@ -350,8 +364,11 @@ GO(BIO_set, iFpp)
//GO(BIO_set_callback_arg,
GO(BIO_set_close, iFpl)
//GO(BIO_set_cipher,
-//GO(BIO_set_ex_data,
-//GO(BIO_set_flags,
+GO(BIO_set_data, vFpp)
+GO(BIO_set_ex_data, iFpip)
+GO(BIO_set_flags, vFpi)
+GO(BIO_set_init, vFpi)
+GO(BIO_set_shutdown, vFpi)
//GO(BIO_set_tcp_ndelay,
//GO(BIO_s_fd,
//GO(BIO_s_file,
@@ -369,6 +386,7 @@ GO(BIO_s_mem, pFv)
//GO(BIO_s_socket,
GO(BIO_tell, iFp)
//GO(BIO_test_flags,
+GO(BIO_up_ref, iFp)
GO(BIO_vfree, vFp)
//GO(BIO_vprintf,
//GO(BIO_vsnprintf,
@@ -461,6 +479,7 @@ GO(BN_is_bit_set, iFpi)
//GO(BN_is_prime_ex,
//GO(BN_is_prime_fasttest,
//GO(BN_is_prime_fasttest_ex,
+GO(BN_is_word, iFpL)
GO(BN_is_zero, iFp)
//GO(BN_kronecker,
GO(BN_lshift, iFppi)
@@ -847,7 +866,7 @@ GO(CRYPTO_free, vFppi)
//GO(CRYPTO_get_dynlock_value,
//GO(CRYPTO_get_ex_data,
//GO(CRYPTO_get_ex_data_implementation,
-//GO(CRYPTO_get_ex_new_index,
+GO(CRYPTO_get_ex_new_index, iFilpppp)
//GO(CRYPTO_get_id_callback,
//GO(CRYPTO_get_locked_mem_ex_functions,
//GO(CRYPTO_get_locked_mem_functions,
@@ -1147,7 +1166,8 @@ GO(DES_set_odd_parity, vFp)
GO(DES_string_to_2keys, vFppp)
GO(DES_string_to_key, vFpp)
GO(DES_xcbc_encrypt, vFpplppppi)
-//GO(DH_check,
+GO(DH_bits, iFp)
+GO(DH_check, iFpp)
//GO(DH_check_pub_key,
//GO(DH_compute_key,
//GO(DH_compute_key_padded,
@@ -1155,6 +1175,7 @@ GO(DH_free, vFp)
//GO(DH_generate_key,
//GO(DH_generate_parameters,
//GO(DH_generate_parameters_ex,
+GO(DH_get0_pqg, vFpppp)
//GO(DH_get_1024_160,
//GO(DH_get_2048_224,
//GO(DH_get_2048_256,
@@ -1184,6 +1205,7 @@ GO(DH_new, pFv)
//GO(DIST_POINT_set_dpname,
//GO(dsa_builtin_paramgen,
//GO(dsa_builtin_paramgen2,
+GO(DSA_bits, iFp)
//GO(DSA_do_sign,
//GO(DSA_do_verify,
//GO(DSA_dup_DH,
@@ -1191,6 +1213,9 @@ GO(DSA_free, vFp)
GO(DSA_generate_key, iFp)
//GO(DSA_generate_parameters,
GO(DSA_generate_parameters_ex, iFpipippp)
+GO(DSA_get0_key, iFppp)
+GO(DSA_get_method, pFp)
+GO(DSA_get0_pqg, vFpppp)
//GO(DSA_get_default_method,
//GO(DSA_get_ex_data,
//GO(DSA_get_ex_new_index,
@@ -1198,6 +1223,8 @@ GO(DSA_new, pFv)
//GO(DSA_new_method,
GO(DSA_OpenSSL, pFv)
//GO(dsa_paramgen_check_g,
+GO(DSA_set0_key, iFppp)
+GO(DSA_set0_pqg, iFpppp)
//GO(DSAparams_dup,
//GO(DSAparams_print,
//GO(DSAparams_print_fp,
@@ -1807,6 +1834,7 @@ GO(EVP_CIPHER_CTX_init, vFp)
GO(EVP_CIPHER_CTX_new, pFv)
//GO(EVP_CIPHER_CTX_nid,
//GO(EVP_CIPHER_CTX_rand_key,
+GO(EVP_CIPHER_CTX_reset, iFp)
//GO(EVP_CIPHER_CTX_set_app_data,
//GO(EVP_CIPHER_CTX_set_flags,
GO(EVP_CIPHER_CTX_set_key_length, iFpi)
@@ -1947,7 +1975,7 @@ GO(EVP_MD_type, iFp)
//GO(EVP_PKEY_asn1_set_private,
//GO(EVP_PKEY_asn1_set_public,
GO(EVP_PKEY_assign, iFpip)
-//GO(EVP_PKEY_base_id,
+GO(EVP_PKEY_base_id, iFp)
//GO(EVP_PKEY_bits,
GO(EVP_PKEY_cmp, iFpp)
GO(EVP_PKEY_cmp_parameters, iFpp)
@@ -1982,7 +2010,7 @@ GO(EVP_PKEY_derive_set_peer, iFppi)
GO(EVP_PKEY_free, vFp)
//GO(EVP_PKEY_get0,
//GO(EVP_PKEY_get0_asn1,
-//GO(EVP_PKEY_get1_DH,
+GO(EVP_PKEY_get1_DH, pFp)
GO(EVP_PKEY_get1_DSA, pFp)
GO(EVP_PKEY_get1_EC_KEY, pFp)
GO(EVP_PKEY_get1_RSA, pFp)
@@ -2017,13 +2045,14 @@ GO(EVP_PKEY_keygen_init, iFp)
GO(EVP_PKEY_missing_parameters, iFp)
GO(EVP_PKEY_new, pFv)
GO(EVP_PKEY_new_mac_key, pFippi)
+GO(EVP_PKEY_param_check, iFp)
GO(EVP_PKEY_paramgen, iFpp)
GO(EVP_PKEY_paramgen_init, iFp)
//GO(EVP_PKEY_print_params,
//GO(EVP_PKEY_print_private,
//GO(EVP_PKEY_print_public,
//GO(EVP_PKEY_save_parameters,
-//GO(EVP_PKEY_set1_DH,
+GO(EVP_PKEY_set1_DH, iFpp)
GO(EVP_PKEY_set1_DSA, iFpp)
GO(EVP_PKEY_set1_EC_KEY, iFpp)
GO(EVP_PKEY_set1_RSA, iFpp)
@@ -2113,8 +2142,10 @@ GO(HMAC_CTX_copy, iFpp)
GO(HMAC_CTX_init, vFp)
GO(HMAC_CTX_set_flags, vFpL)
GO(HMAC_Final, iFppp)
+GO(HMAC_CTX_free, vFp)
GO(HMAC_Init, iFppip)
GO(HMAC_Init_ex, iFppipp)
+GO(HMAC_CTX_new, pFv)
GO(HMAC_Update, iFppi)
//GO(i2a_ACCESS_DESCRIPTION,
//GO(i2a_ASN1_ENUMERATED,
@@ -2483,7 +2514,7 @@ GO(OBJ_txt2obj, pFpi)
//GO(OCSP_archive_cutoff_new,
//GO(OCSP_basic_add1_cert,
//GO(OCSP_basic_add1_nonce,
-//GO(OCSP_basic_add1_status,
+GO(OCSP_basic_add1_status, pFppiippp)
//GO(OCSP_BASICRESP_add1_ext_i2d,
//GO(OCSP_BASICRESP_add_ext,
//GO(OCSP_BASICRESP_delete_ext,
@@ -2494,8 +2525,8 @@ GO(OCSP_BASICRESP_free, vFp)
//GO(OCSP_BASICRESP_get_ext_by_NID,
//GO(OCSP_BASICRESP_get_ext_by_OBJ,
//GO(OCSP_BASICRESP_get_ext_count,
-//GO(OCSP_BASICRESP_new,
-//GO(OCSP_basic_sign,
+GO(OCSP_BASICRESP_new, pFv)
+GO(OCSP_basic_sign, iFpppppL)
GO(OCSP_basic_verify, iFpppL)
//GO(OCSP_CERTID_dup,
GO(OCSP_CERTID_free, vFp)
@@ -2506,14 +2537,14 @@ GO(OCSP_CERTID_free, vFp)
//GO(OCSP_cert_status_str,
GO(OCSP_cert_to_id, pFppp)
GO(OCSP_check_nonce, iFpp)
-//GO(OCSP_check_validity,
+GO(OCSP_check_validity, iFppll)
//GO(OCSP_copy_nonce,
//GO(OCSP_CRLID_free,
//GO(OCSP_crlID_new,
//GO(OCSP_CRLID_new,
//GO(OCSP_crl_reason_str,
-//GO(OCSP_id_cmp,
-//GO(OCSP_id_get0_info,
+GO(OCSP_id_cmp, iFpp)
+GO(OCSP_id_get0_info, iFppppp)
//GO(OCSP_id_issuer_cmp,
//GO(OCSP_ONEREQ_add1_ext_i2d,
//GO(OCSP_ONEREQ_add_ext,
@@ -2562,21 +2593,22 @@ GO(OCSP_REQUEST_new, pFv)
//GO(OCSP_request_verify,
//GO(OCSP_RESPBYTES_free,
//GO(OCSP_RESPBYTES_new,
-//GO(OCSP_resp_count,
+GO(OCSP_resp_count, iFp)
//GO(OCSP_RESPDATA_free,
//GO(OCSP_RESPDATA_new,
//GO(OCSP_resp_find,
GO(OCSP_resp_find_status, iFppppppp)
-//GO(OCSP_resp_get0,
+GO(OCSP_resp_get0, pFpi)
+GO(OCSP_resp_get0_certs, pFp)
//GO(OCSP_RESPID_free,
//GO(OCSP_RESPID_new,
-//GO(OCSP_response_create,
+GO(OCSP_response_create, pFip)
GO(OCSP_RESPONSE_free, vFp)
GO(OCSP_response_get1_basic, pFp)
GO(OCSP_RESPONSE_new, pFv)
//GO(OCSP_RESPONSE_print,
-//GO(OCSP_response_status,
-//GO(OCSP_response_status_str,
+GO(OCSP_response_status, iFp)
+GO(OCSP_response_status_str, pFl)
//GO(OCSP_REVOKEDINFO_free,
//GO(OCSP_REVOKEDINFO_new,
//GO(OCSP_sendreq_bio,
@@ -2587,11 +2619,12 @@ GO(OCSP_RESPONSE_new, pFv)
//GO(OCSP_set_max_response_length,
//GO(OCSP_SIGNATURE_free,
//GO(OCSP_SIGNATURE_new,
-//GO(OCSP_single_get0_status,
+GO(OCSP_single_get0_status, iFppppp)
//GO(OCSP_SINGLERESP_add1_ext_i2d,
//GO(OCSP_SINGLERESP_add_ext,
//GO(OCSP_SINGLERESP_delete_ext,
//GO(OCSP_SINGLERESP_free,
+GO(OCSP_SINGLERESP_get0_id, pFp)
//GO(OCSP_SINGLERESP_get1_ext_d2i,
//GO(OCSP_SINGLERESP_get_ext,
//GO(OCSP_SINGLERESP_get_ext_by_critical,
@@ -2638,6 +2671,8 @@ GO(OPENSSL_sk_value, pFpi) //1.1+
//GO(OPENSSL_strcasecmp,
//GO(OPENSSL_strncasecmp,
//GO(OPENSSL_uni2asc,
+GO(OpenSSL_version, pFi)
+GO(OpenSSL_version_num, LFv)
//GO(OPENSSL_wipe_cpu,
//GO(_ossl_096_des_random_seed,
//GO(_ossl_old_crypt,
@@ -2700,7 +2735,7 @@ GO(OPENSSL_sk_value, pFpi) //1.1+
//GO(PEM_read,
//GO(PEM_read_bio,
//GO(PEM_read_bio_CMS,
-//GO(PEM_read_bio_DHparams,
+GOM(PEM_read_bio_DHparams, pFEpppp)
//GO(PEM_read_bio_DSAparams,
GOM(PEM_read_bio_DSAPrivateKey, pFEpppp)
GOM(PEM_read_bio_DSA_PUBKEY, pFEpppp)
@@ -2712,8 +2747,8 @@ GOM(PEM_read_bio_EC_PUBKEY, pFEpppp)
GOM(PEM_read_bio_PKCS7, pFEpppp)
//GO(PEM_read_bio_PKCS8,
//GO(PEM_read_bio_PKCS8_PRIV_KEY_INFO,
-//GO(PEM_read_bio_PrivateKey,
-//GO(PEM_read_bio_PUBKEY,
+GOM(PEM_read_bio_PrivateKey, pFEpppp)
+GOM(PEM_read_bio_PUBKEY, pFEpppp)
GOM(PEM_read_bio_RSAPrivateKey, pFEpppp)
GOM(PEM_read_bio_RSA_PUBKEY, pFEpppp)
//GO(PEM_read_bio_RSAPublicKey,
@@ -2771,8 +2806,8 @@ GO(PEM_write_bio_EC_PUBKEY, iFpp)
//GO(PEM_write_bio_PKCS8PrivateKey,
//GO(PEM_write_bio_PKCS8PrivateKey_nid,
//GO(PEM_write_bio_PKCS8_PRIV_KEY_INFO,
-//GO(PEM_write_bio_PrivateKey,
-//GO(PEM_write_bio_PUBKEY,
+GOM(PEM_write_bio_PrivateKey, iFEppppipp)
+GO(PEM_write_bio_PUBKEY, iFpp)
GOM(PEM_write_bio_RSAPrivateKey, iFEppppipp)
GO(PEM_write_bio_RSA_PUBKEY, iFpp)
//GO(PEM_write_bio_RSAPublicKey,
@@ -3021,6 +3056,7 @@ GO(RAND_write_file, iFp)
//GO(RIPEMD160_Init,
//GO(RIPEMD160_Transform,
//GO(RIPEMD160_Update,
+GO(RSA_bits, iFp)
//GO(RSA_blinding_off,
//GO(RSA_blinding_on,
GO(RSA_check_key, iFp)
@@ -3028,11 +3064,15 @@ GO(RSA_check_key, iFp)
GO(RSA_free, vFp)
//GO(RSA_generate_key,
GO(RSA_generate_key_ex, iFpipp)
+GO(RSA_get0_crt_params, vFpppp)
+GO(RSA_get0_factors, vFppp)
+GO(RSA_get0_key, vFpppp)
//GO(RSA_get_default_method,
//GO(RSA_get_ex_data,
//GO(RSA_get_ex_new_index,
GO(RSA_get_method, pFp)
//GO(RSA_memory_lock,
+GO(RSA_meth_get_flags, iFp)
GO(RSA_new, pFv)
GO(RSA_new_method, pFp)
//GO(RSA_null_method,
@@ -3066,6 +3106,9 @@ GO(RSA_private_encrypt, iFipppi)
GO(RSA_public_decrypt, iFipppi)
GO(RSA_public_encrypt, iFipppi)
//GO(RSAPublicKey_dup,
+GO(RSA_set0_crt_params, iFpppp)
+GO(RSA_set0_factors, iFppp)
+GO(RSA_set0_key, iFpppp)
//GO(RSA_set_default_method,
//GO(RSA_set_ex_data,
GO(RSA_set_method, iFpp)
@@ -3438,7 +3481,7 @@ GO(X509_add1_ext_i2d, iFpipiL)
//GO(X509_check_akid,
//GO(X509_check_ca,
//GO(X509_check_email,
-//GO(X509_check_host,
+GO(X509_check_host, iFppLup)
//GO(X509_check_ip,
//GO(X509_check_ip_asc,
GO(X509_check_issued, iFpp)
@@ -3462,6 +3505,7 @@ GO(X509_CRL_add1_ext_i2d, iFpipiL)
GO(X509_CRL_free, vFp)
//GO(X509_CRL_get0_by_cert,
//GO(X509_CRL_get0_by_serial,
+GO(X509_CRL_get0_nextUpdate, pFp)
//GO(X509_CRL_get_ext,
//GO(X509_CRL_get_ext_by_critical,
//GO(X509_CRL_get_ext_by_NID,
@@ -3506,7 +3550,8 @@ GO(X509_EXTENSION_set_object, iFpp)
//GO(X509_find_by_issuer_and_serial,
//GO(X509_find_by_subject,
GO(X509_free, vFp)
-//GO(X509_get0_pubkey_bitstr,
+GO(X509_get0_pubkey_bitstr, pFp)
+GO(X509_get0_tbs_sigalg, pFp)
//GO(X509_get0_signature,
//GO(X509_get1_email,
//GO(X509_get1_ocsp,
@@ -3532,8 +3577,13 @@ GO(X509_get0_serialNumber, pFp)
//GO(X509_get_signature_nid,
GO(X509_get_subject_name, pFp)
GO(X509_get_X509_PUBKEY, pFp)
+GO(X509_get_version, lFp)
+GO(X509_get0_notAfter, pFp)
+GO(X509_get0_notBefore, pFp)
GO(X509_get0_pubkey, pFp)
-//GO(X509_gmtime_adj,
+GO(X509_getm_notBefore, pFp)
+GO(X509_getm_notAfter, pFp)
+GO(X509_gmtime_adj, pFpl)
//GO(X509_http_nbio,
//GO(X509_INFO_free,
//GO(X509_INFO_new,
@@ -3578,6 +3628,7 @@ GO(X509_NAME_ENTRY_get_object, pFp)
GO(X509_NAME_ENTRY_set_data, iFpipi)
GO(X509_NAME_ENTRY_set_object, iFpp)
GO(X509_NAME_free, vFp)
+GO(X509_NAME_get0_der, iFppp)
GO(X509_NAME_get_entry, pFpi)
GO(X509_NAME_get_index_by_NID, iFpii)
GO(X509_NAME_get_index_by_OBJ, iFppi)
@@ -3685,6 +3736,8 @@ GO(X509_REVOKED_get_ext_d2i, pFpipp)
//GO(X509_REVOKED_new,
//GO(X509_REVOKED_set_revocationDate,
//GO(X509_REVOKED_set_serialNumber,
+GO(X509_set1_notAfter, iFpp)
+GO(X509_set1_notBefore, iFpp)
//GO(X509_set_ex_data,
GO(X509_set_issuer_name, iFpp)
//GO(X509_set_notAfter,
@@ -3704,19 +3757,23 @@ GO(X509_STORE_add_crl, iFpp)
GO(X509_STORE_add_lookup, pFpp)
GO(X509_STORE_CTX_cleanup, vFp)
GO(X509_STORE_CTX_free, vFp)
+GO(X509_STORE_CTX_get0_cert, pFp)
+GO(X509_STORE_CTX_get0_chain, pFp)
//GO(X509_STORE_CTX_get0_current_crl,
//GO(X509_STORE_CTX_get0_current_issuer,
GO(X509_STORE_CTX_get0_param, pFp)
//GO(X509_STORE_CTX_get0_parent_ctx,
//GO(X509_STORE_CTX_get0_policy_tree,
-//GO(X509_STORE_CTX_get0_store,
+GO(X509_STORE_CTX_get0_store, pFp)
GO(X509_STORE_CTX_get1_chain, pFp)
+GO(X509_STORE_get0_param, pFp)
+GO(X509_STORE_CTX_get0_untrusted, pFp)
GO(X509_STORE_CTX_get1_issuer, iFppp)
GO(X509_STORE_CTX_get_chain, pFp)
GO(X509_STORE_CTX_get_current_cert, pFp)
GO(X509_STORE_CTX_get_error, iFp)
GO(X509_STORE_CTX_get_error_depth, iFp)
-//GO(X509_STORE_CTX_get_ex_data,
+GO(X509_STORE_CTX_get_ex_data, pFpi)
//GO(X509_STORE_CTX_get_ex_new_index,
//GO(X509_STORE_CTX_get_explicit_policy,
GO(X509_STORE_CTX_init, iFpppp)
@@ -3741,7 +3798,8 @@ GOM(X509_STORE_CTX_set_verify_cb, vFEpp)
GO(X509_STORE_free, vFp)
//GO(X509_STORE_get1_certs,
//GO(X509_STORE_get1_crls,
-//GO(X509_STORE_get_by_subject,
+//GO(X509_STORE_get_by_subject,
+GO(X509_STORE_get_ex_data, pFpi)
GO(X509_STORE_load_file, iFpp)
GO(X509_STORE_load_path, iFpp)
GO(X509_STORE_load_store, iFpp)
@@ -3750,11 +3808,12 @@ GO(X509_STORE_new, pFv)
//GO(X509_STORE_set1_param,
//GO(X509_STORE_set_default_paths,
GO(X509_STORE_set_depth, iFpi)
+GO(X509_STORE_set_ex_data, iFpip)
GO(X509_STORE_set_flags, iFpL)
//GO(X509_STORE_set_lookup_crls_cb,
GO(X509_STORE_set_purpose, iFpi)
GO(X509_STORE_set_trust, iFpi)
-//GO(X509_STORE_set_verify_cb,
+GOM(X509_STORE_set_verify_cb, vFEpp)
//GO(X509_subject_name_cmp,
GO(X509_subject_name_hash, LFp)
GO(X509_subject_name_hash_old, LFp)
@@ -3773,6 +3832,7 @@ GO(X509_subject_name_hash_old, LFp)
//GO(X509_TRUST_get_trust,
//GO(X509_TRUST_set,
//GO(X509_TRUST_set_default,
+GO(X509_up_ref, iFp)
GO(X509V3_add1_i2d, iFpipiL)
//GO(X509v3_add_ext,
//GO(X509V3_add_standard_extensions,
diff --git a/src/wrapped/wrappedcurl.c b/src/wrapped/wrappedcurl.c
index ceda973..490d7f8 100755..100644
--- a/src/wrapped/wrappedcurl.c
+++ b/src/wrapped/wrappedcurl.c
@@ -346,7 +346,7 @@ typedef enum {
static uintptr_t my_write_fct_##A = 0; \
static size_t my_write_##A(char* ptr, size_t size, size_t nmemb, void* userdata) \
{ \
- return (size_t)RunFunction(my_context, my_write_fct_##A, 4, ptr, size, nmemb, userdata);\
+ return (size_t)RunFunctionFmt(my_write_fct_##A, "pLLp", ptr, size, nmemb, userdata);\
}
SUPER()
#undef GO
@@ -369,7 +369,7 @@ static void* find_write_Fct(void* fct)
static uintptr_t my_read_fct_##A = 0; \
static size_t my_read_##A(char* buffer, size_t size, size_t nitems, void* userdata) \
{ \
- return (size_t)RunFunction(my_context, my_read_fct_##A, 4, buffer, size, nitems, userdata);\
+ return (size_t)RunFunctionFmt(my_read_fct_##A, "pLLp", buffer, size, nitems, userdata);\
}
SUPER()
#undef GO
@@ -392,7 +392,7 @@ static void* find_read_Fct(void* fct)
static uintptr_t my_ioctl_fct_##A = 0; \
static size_t my_ioctl_##A(void* handle, int32_t fnc, void* userdata) \
{ \
- return (size_t)RunFunction(my_context, my_ioctl_fct_##A, 3, handle, fnc, userdata);\
+ return (size_t)RunFunctionFmt(my_ioctl_fct_##A, "pip", handle, fnc, userdata);\
}
SUPER()
#undef GO
@@ -415,7 +415,7 @@ static void* find_ioctl_Fct(void* fct)
static uintptr_t my_seek_fct_##A = 0; \
static int32_t my_seek_##A(void* userdata, int64_t off, int32_t origin) \
{ \
- return (int32_t)RunFunction(my_context, my_seek_fct_##A, 4, userdata, (off&0xffffffff), ((off>>32)&0xffffffff), origin);\
+ return (int32_t)RunFunctionFmt(my_seek_fct_##A, "pIi", userdata, off, origin);\
}
SUPER()
#undef GO
@@ -438,7 +438,7 @@ static void* find_seek_Fct(void* fct)
static uintptr_t my_header_fct_##A = 0; \
static size_t my_header_##A(char* buffer, size_t size, size_t nitems, void* userdata) \
{ \
- return (size_t)RunFunction(my_context, my_header_fct_##A, 4, buffer, size, nitems, userdata);\
+ return (size_t)RunFunctionFmt(my_header_fct_##A, "pLLp", buffer, size, nitems, userdata);\
}
SUPER()
#undef GO
@@ -461,7 +461,7 @@ static void* find_header_Fct(void* fct)
static uintptr_t my_progress_fct_##A = 0; \
static int my_progress_##A(void *clientp, double dltotal, double dlnow, double ultotal, double ulnow) \
{ \
- return (int)RunFunction(my_context, my_progress_fct_##A, 5, clientp, dltotal, dlnow, ultotal, ulnow);\
+ return (int)RunFunctionFmt(my_progress_fct_##A, "pdddd", clientp, dltotal, dlnow, ultotal, ulnow);\
}
SUPER()
#undef GO
@@ -484,7 +484,7 @@ static void* find_progress_Fct(void* fct)
static uintptr_t my_progress_int_fct_##A = 0; \
static int my_progress_int_##A(void *clientp, uint64_t dltotal, uint64_t dlnow, uint64_t ultotal, uint64_t ulnow) \
{ \
- return (int)RunFunction(my_context, my_progress_int_fct_##A, 5, clientp, dltotal, dlnow, ultotal, ulnow);\
+ return (int)RunFunctionFmt(my_progress_int_fct_##A, "pUUUU", clientp, dltotal, dlnow, ultotal, ulnow);\
}
SUPER()
#undef GO
@@ -507,7 +507,7 @@ static void* find_progress_int_Fct(void* fct)
static uintptr_t my_socket_fct_##A = 0; \
static int my_socket_##A(void *a, int b, int c, void* d, void* e) \
{ \
- return (int)RunFunction(my_context, my_socket_fct_##A, 5, a, b, c, d, e); \
+ return (int)RunFunctionFmt(my_socket_fct_##A, "piipp", a, b, c, d, e); \
}
SUPER()
#undef GO
@@ -530,7 +530,7 @@ static void* find_socket_Fct(void* fct)
static uintptr_t my_timer_fct_##A = 0; \
static int my_timer_##A(void *a, long b, void* c) \
{ \
- return (int)RunFunction(my_context, my_timer_fct_##A, 3, a, b, c); \
+ return (int)RunFunctionFmt(my_timer_fct_##A, "plp", a, b, c); \
}
SUPER()
#undef GO
@@ -553,7 +553,7 @@ static void* find_timer_Fct(void* fct)
static uintptr_t my_push_fct_##A = 0; \
static int my_push_##A(void *a, void* b, size_t c, void* d, void* e) \
{ \
- return (int)RunFunction(my_context, my_push_fct_##A, 5, a, b, c, d, e); \
+ return (int)RunFunctionFmt(my_push_fct_##A, "ppLpp", a, b, c, d, e); \
}
SUPER()
#undef GO
@@ -576,7 +576,7 @@ static void* find_push_Fct(void* fct)
static uintptr_t my_debug_fct_##A = 0; \
static int my_debug_##A(void *a, int b, void* c, size_t d, void* e) \
{ \
- return (int)RunFunction(my_context, my_debug_fct_##A, 5, a, b, c, d, e); \
+ return (int)RunFunctionFmt(my_debug_fct_##A, "pipLp", a, b, c, d, e); \
}
SUPER()
#undef GO
diff --git a/src/wrapped/wrappedcurl_private.h b/src/wrapped/wrappedcurl_private.h
index ffcc105..ffcc105 100755..100644
--- a/src/wrapped/wrappedcurl_private.h
+++ b/src/wrapped/wrappedcurl_private.h
diff --git a/src/wrapped/wrappedd3dadapter9.c b/src/wrapped/wrappedd3dadapter9.c
index c43331d..3701bba 100644
--- a/src/wrapped/wrappedd3dadapter9.c
+++ b/src/wrapped/wrappedd3dadapter9.c
@@ -225,7 +225,7 @@ static void freeMy()
#define GOV(ns, ret, fn, args, call) \
static uintptr_t my_##ns##_##fn##_fct = 0; \
static ret my_##ns##_##fn(UNPACK args) { \
- ret r = (ret)RunFunctionWindows(my_context, my_##ns##_##fn##_fct, UNPACK call); \
+ ret r = (ret)RunFunctionWindows(my_##ns##_##fn##_fct, UNPACK call); \
/* no closing brace */
#define GOV_1(ns, ret, fn, t1) \
@@ -319,13 +319,13 @@ typedef struct my_Direct3D9 {
unsigned my_Direct3D9_AddRef(void *This)
{
my_Direct3D9 *my = This;
- return RunFunctionWindows(my_context, (uintptr_t)(*my->real)->AddRef, 1, my->real);
+ return RunFunctionWindows((uintptr_t)(*my->real)->AddRef, 1, my->real);
}
unsigned my_Direct3D9_Release(void *This)
{
my_Direct3D9 *my = This;
- return RunFunctionWindows(my_context, (uintptr_t)(*my->real)->Release, 1, my->real);
+ return RunFunctionWindows((uintptr_t)(*my->real)->Release, 1, my->real);
}
IDirect3D9Vtbl my_Direct3D9_vtbl = {
@@ -341,13 +341,13 @@ typedef struct my_Direct3D9Ex {
unsigned my_Direct3D9Ex_AddRef(void *This)
{
my_Direct3D9Ex *my = This;
- return RunFunction(my_context, (uintptr_t)(*my->real)->AddRef, 1, my->real);
+ return RunFunctionFmt((uintptr_t)(*my->real)->AddRef, "p", my->real);
}
unsigned my_Direct3D9Ex_Release(void *This)
{
my_Direct3D9Ex *my = This;
- return RunFunction(my_context, (uintptr_t)(*my->real)->Release, 1, my->real);
+ return RunFunctionFmt((uintptr_t)(*my->real)->Release, "p", my->real);
}
IDirect3D9ExVtbl my_Direct3D9Ex_vtbl = {
diff --git a/src/wrapped/wrappeddbus.c b/src/wrapped/wrappeddbus.c
index 384c0d7..7f04091 100755..100644
--- a/src/wrapped/wrappeddbus.c
+++ b/src/wrapped/wrappeddbus.c
@@ -38,7 +38,7 @@ GO(3)
static uintptr_t my_DBusFreeFunction_fct_##A = 0; \
static void my_DBusFreeFunction_##A(void* p) \
{ \
- RunFunction(my_context, my_DBusFreeFunction_fct_##A, 1, p); \
+ RunFunctionFmt(my_DBusFreeFunction_fct_##A, "p", p); \
}
SUPER()
#undef GO
@@ -60,7 +60,7 @@ static void* find_DBusFreeFunction_Fct(void* fct)
static uintptr_t my_DBusHandleMessageFunction_fct_##A = 0; \
static int my_DBusHandleMessageFunction_##A(void* a, void* b, void* c) \
{ \
- return RunFunction(my_context, my_DBusHandleMessageFunction_fct_##A, 3, a, b, c); \
+ return RunFunctionFmt(my_DBusHandleMessageFunction_fct_##A, "ppp", a, b, c); \
}
SUPER()
#undef GO
@@ -82,7 +82,7 @@ static void* find_DBusHandleMessageFunction_Fct(void* fct)
static uintptr_t my_DBusAddTimeoutFunction_fct_##A = 0; \
static int my_DBusAddTimeoutFunction_##A(void* a, void* b) \
{ \
- return RunFunction(my_context, my_DBusAddTimeoutFunction_fct_##A, 2, a, b); \
+ return RunFunctionFmt(my_DBusAddTimeoutFunction_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -104,7 +104,7 @@ static void* find_DBusAddTimeoutFunction_Fct(void* fct)
static uintptr_t my_DBusRemoveTimeoutFunction_fct_##A = 0; \
static void my_DBusRemoveTimeoutFunction_##A(void* a, void* b) \
{ \
- RunFunction(my_context, my_DBusRemoveTimeoutFunction_fct_##A, 2, a, b); \
+ RunFunctionFmt(my_DBusRemoveTimeoutFunction_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -126,7 +126,7 @@ static void* find_DBusRemoveTimeoutFunction_Fct(void* fct)
static uintptr_t my_DBusTimeoutToggledFunction_fct_##A = 0; \
static void my_DBusTimeoutToggledFunction_##A(void* a, void* b) \
{ \
- RunFunction(my_context, my_DBusTimeoutToggledFunction_fct_##A, 2, a, b); \
+ RunFunctionFmt(my_DBusTimeoutToggledFunction_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -148,7 +148,7 @@ static void* find_DBusTimeoutToggledFunction_Fct(void* fct)
static uintptr_t my_DBusWakeupMainFunction_fct_##A = 0; \
static void my_DBusWakeupMainFunction_##A(void* a) \
{ \
- RunFunction(my_context, my_DBusWakeupMainFunction_fct_##A, 1, a); \
+ RunFunctionFmt(my_DBusWakeupMainFunction_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -171,7 +171,7 @@ static void* find_DBusWakeupMainFunction_Fct(void* fct)
static uintptr_t my_DBusPendingCallNotifyFunction_fct_##A = 0; \
static void my_DBusPendingCallNotifyFunction_##A(void* pending, void* data) \
{ \
- RunFunction(my_context, my_DBusPendingCallNotifyFunction_fct_##A, 2, pending, data);\
+ RunFunctionFmt(my_DBusPendingCallNotifyFunction_fct_##A, "pp", pending, data);\
}
SUPER()
#undef GO
@@ -194,7 +194,7 @@ static void* findDBusPendingCallNotifyFunctionFct(void* fct)
static uintptr_t my_DBusDispatchStatusFunction_fct_##A = 0; \
static void my_DBusDispatchStatusFunction_##A(void* connection, int new_status, void* data) \
{ \
- RunFunction(my_context, my_DBusDispatchStatusFunction_fct_##A, 3, connection, new_status, data);\
+ RunFunctionFmt(my_DBusDispatchStatusFunction_fct_##A, "pip", connection, new_status, data);\
}
SUPER()
#undef GO
@@ -217,7 +217,7 @@ static void* findDBusDispatchStatusFunctionFct(void* fct)
static uintptr_t my_DBusAddWatchFunction_fct_##A = 0; \
static int my_DBusAddWatchFunction_##A(void* watch, void* data) \
{ \
- return (int)RunFunction(my_context, my_DBusAddWatchFunction_fct_##A, 2, watch, data);\
+ return (int)RunFunctionFmt(my_DBusAddWatchFunction_fct_##A, "pp", watch, data);\
}
SUPER()
#undef GO
@@ -240,7 +240,7 @@ static void* findDBusAddWatchFunctionFct(void* fct)
static uintptr_t my_DBusRemoveWatchFunction_fct_##A = 0; \
static void my_DBusRemoveWatchFunction_##A(void* watch, void* data) \
{ \
- RunFunction(my_context, my_DBusRemoveWatchFunction_fct_##A, 2, watch, data);\
+ RunFunctionFmt(my_DBusRemoveWatchFunction_fct_##A, "pp", watch, data);\
}
SUPER()
#undef GO
@@ -263,7 +263,7 @@ static void* findDBusRemoveWatchFunctionFct(void* fct)
static uintptr_t my_DBusWatchToggledFunction_fct_##A = 0; \
static void my_DBusWatchToggledFunction_##A(void* watch, void* data) \
{ \
- RunFunction(my_context, my_DBusWatchToggledFunction_fct_##A, 2, watch, data);\
+ RunFunctionFmt(my_DBusWatchToggledFunction_fct_##A, "pp", watch, data);\
}
SUPER()
#undef GO
@@ -286,7 +286,7 @@ static void* findDBusWatchToggledFunctionFct(void* fct)
static uintptr_t my_DBusObjectPathUnregisterFunction_fct_##A = 0; \
static void my_DBusObjectPathUnregisterFunction_##A(void* connection, void* data) \
{ \
- RunFunction(my_context, my_DBusObjectPathUnregisterFunction_fct_##A, 2, connection, data);\
+ RunFunctionFmt(my_DBusObjectPathUnregisterFunction_fct_##A, "pp", connection, data);\
}
SUPER()
#undef GO
@@ -309,7 +309,7 @@ static void* findDBusObjectPathUnregisterFunctionFct(void* fct)
static uintptr_t my_DBusObjectPathMessageFunction_fct_##A = 0; \
static void my_DBusObjectPathMessageFunction_##A(void* connection, void* message, void* data) \
{ \
- RunFunction(my_context, my_DBusObjectPathMessageFunction_fct_##A, 3, connection, message, data);\
+ RunFunctionFmt(my_DBusObjectPathMessageFunction_fct_##A, "ppp", connection, message, data);\
}
SUPER()
#undef GO
@@ -332,7 +332,7 @@ static void* findDBusObjectPathMessageFunctionFct(void* fct)
static uintptr_t my_dbus_internal_pad_fct_##A = 0; \
static void my_dbus_internal_pad_##A(void* a, void* b, void* c, void* d) \
{ \
- RunFunction(my_context, my_dbus_internal_pad_fct_##A, 4, a, b, c, d);\
+ RunFunctionFmt(my_dbus_internal_pad_fct_##A, "pppp", a, b, c, d);\
}
SUPER()
#undef GO
@@ -349,6 +349,31 @@ static void* finddbus_internal_padFct(void* fct)
printf_log(LOG_NONE, "Warning, no more slot for dbus dbus_internal_pad callback\n");
return NULL;
}
+
+// DBusNewConnectionFunction
+#define GO(A) \
+static uintptr_t my_DBusNewConnectionFunction_fct_##A = 0; \
+static void my_DBusNewConnectionFunction_##A(void* a, void* b, void* c) \
+{ \
+ RunFunctionFmt(my_DBusNewConnectionFunction_fct_##A, "pppp", a, b, c); \
+}
+SUPER()
+#undef GO
+static void* findDBusNewConnectionFunctionFct(void* fct)
+{
+ if(!fct) return NULL;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_DBusNewConnectionFunction_fct_##A == (uintptr_t)fct) return my_DBusNewConnectionFunction_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_DBusNewConnectionFunction_fct_##A == 0) {my_DBusNewConnectionFunction_fct_##A = (uintptr_t)fct; return my_DBusNewConnectionFunction_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for dbus DBusNewConnectionFunction callback\n");
+ return NULL;
+}
+
+
#undef SUPER
EXPORT void my_dbus_timeout_set_data(x64emu_t* emu, void* e, void* p, void* f)
@@ -404,7 +429,64 @@ EXPORT int my_dbus_message_append_args_valist(x64emu_t* emu, void* message, int
#ifdef CONVERT_VALIST
CONVERT_VALIST(b);
#else
+ #if 1
CREATE_VALIST_FROM_VALIST(b, emu->scratch);
+ #else
+ va_list sysv_varargs;
+ uintptr_t *p = (uintptr_t*)(emu->scratch);
+ int n = (X64_VA_MAX_REG - b->gp_offset)/8;
+ int x = (X64_VA_MAX_XMM - b->fp_offset)/8;
+ int idx = 0;
+ int type = arg;
+ while(arg) {
+ if(arg == (int)'d') {
+ // double
+ if(x)
+ *(p++) = *(uintptr_t*)(b->reg_save_area + X64_VA_MAX_XMM - (x--)*8);
+ else
+ *(p++) = *(uintptr_t*)(b->overflow_arg_area + (idx++)*8);
+ } else if(arg == (int)'a') {
+ // array
+ // type
+ if(n)
+ *(p++) = *(uintptr_t*)(b->reg_save_area + X64_VA_MAX_REG - (n--)*8);
+ else
+ *(p++) = *(uintptr_t*)(b->overflow_arg_area + (idx++)*8);
+ // elements
+ if(n)
+ *(p++) = *(uintptr_t*)(b->reg_save_area + X64_VA_MAX_REG - (n--)*8);
+ else
+ *(p++) = *(uintptr_t*)(b->overflow_arg_area + (idx++)*8);
+ // number of elements
+ if(n)
+ *(p++) = *(uintptr_t*)(b->reg_save_area + X64_VA_MAX_REG - (n--)*8);
+ else
+ *(p++) = *(uintptr_t*)(b->overflow_arg_area + (idx++)*8);
+ } else if(arg == (int)'s' || arg == (int)'g' || arg == (int)'o') {
+ // elements
+ if(n)
+ *(p++) = *(uintptr_t*)(b->reg_save_area + X64_VA_MAX_REG - (n--)*8);
+ else
+ *(p++) = *(uintptr_t*)(b->overflow_arg_area + (idx++)*8);
+ // number of elements
+ if(n)
+ *(p++) = *(uintptr_t*)(b->reg_save_area + X64_VA_MAX_REG - (n--)*8);
+ else
+ *(p++) = *(uintptr_t*)(b->overflow_arg_area + (idx++)*8);
+ } else {
+ if(n)
+ *(p++) = *(uintptr_t*)(b->reg_save_area + X64_VA_MAX_REG - (n--)*8);
+ else
+ *(p++) = *(uintptr_t*)(b->overflow_arg_area + (idx++)*8);
+ }
+ if(n)
+ arg = *(uintptr_t*)(b->reg_save_area + X64_VA_MAX_REG - (n--)*8);
+ else
+ arg = *(uintptr_t*)(b->overflow_arg_area + (idx++)*8);
+ *(p++) = arg;
+ }
+ sysv_varargs = (va_list)p;
+ #endif
#endif
return my->dbus_message_append_args_valist(message, arg, VARARGS);
}
@@ -478,6 +560,22 @@ EXPORT int my_dbus_connection_try_register_object_path(x64emu_t* emu, void* conn
return my->dbus_connection_try_register_object_path(connection, path, vtable?&vt:NULL, data, error);
}
+EXPORT int my_dbus_connection_register_fallback(x64emu_t* emu, void* connection, void* path, my_DBusObjectPathVTable_t* vtable, void* data)
+{
+ (void)emu;
+ my_DBusObjectPathVTable_t vt = {0};
+ if(vtable) {
+ vt.unregister_function = findDBusObjectPathUnregisterFunctionFct(vtable->unregister_function);
+ vt.message_function = findDBusObjectPathMessageFunctionFct(vtable->message_function);
+ vt.pad1 = finddbus_internal_padFct(vtable->pad1);
+ vt.pad2 = finddbus_internal_padFct(vtable->pad2);
+ vt.pad3 = finddbus_internal_padFct(vtable->pad3);
+ vt.pad4 = finddbus_internal_padFct(vtable->pad4);
+ }
+
+ return my->dbus_connection_register_fallback(connection, path, vtable?&vt:NULL, data);
+}
+
EXPORT int my_dbus_connection_set_data(x64emu_t* emu, void* connection, int slot, void* data, void* free_func)
{
(void)emu;
@@ -506,7 +604,25 @@ EXPORT int my_dbus_connection_try_register_fallback(x64emu_t* emu, void* connect
return my->dbus_connection_try_register_fallback(connection, path, vtable?&vt:NULL, data, error);
}
+EXPORT int my_dbus_server_set_watch_functions(x64emu_t* emu, void* server, void* add, void* rem, void* toggle, void* data, void* d)
+{
+ return my->dbus_server_set_watch_functions(server, findDBusAddWatchFunctionFct(add), findDBusRemoveWatchFunctionFct(rem), findDBusWatchToggledFunctionFct(toggle), data, find_DBusFreeFunction_Fct(d));
+}
+
+EXPORT void my_dbus_server_set_new_connection_function(x64emu_t* emu, void* server, void* f, void* data, void* d)
+{
+ my->dbus_server_set_new_connection_function(server, findDBusNewConnectionFunctionFct(f), data, find_DBusFreeFunction_Fct(d));
+}
+EXPORT int my_dbus_server_set_timeout_functions(x64emu_t* emu, void* server, void* add, void* rem, void* toggle, void* data, void* d)
+{
+ return my->dbus_server_set_timeout_functions(server, find_DBusAddTimeoutFunction_Fct(add), find_DBusRemoveTimeoutFunction_Fct(rem), find_DBusTimeoutToggledFunction_Fct(toggle), data, find_DBusFreeFunction_Fct(d));
+}
+
+EXPORT int my_dbus_server_set_data(x64emu_t* emu, void* server, int slot, void* data, void* d)
+{
+ return my->dbus_server_set_data(server, slot, data, find_DBusFreeFunction_Fct(d));
+}
#define CUSTOM_INIT \
getMy(lib);
diff --git a/src/wrapped/wrappeddbus_private.h b/src/wrapped/wrappeddbus_private.h
index c72c99c..ccbe2a9 100755..100644
--- a/src/wrapped/wrappeddbus_private.h
+++ b/src/wrapped/wrappeddbus_private.h
@@ -54,7 +54,7 @@ GO(dbus_connection_preallocate_send, pFp)
GO(dbus_connection_read_write, iFpi)
GO(dbus_connection_read_write_dispatch, iFpi)
GO(dbus_connection_ref, pFp)
-//GO(dbus_connection_register_fallback,
+GOM(dbus_connection_register_fallback, iFEpppp)
//GO(dbus_connection_register_object_path,
GOM(dbus_connection_remove_filter, vFEppp)
GO(dbus_connection_return_message, vFpp)
@@ -179,21 +179,21 @@ GOM(dbus_pending_call_set_notify, iFEpppp)
GO(dbus_pending_call_steal_reply, pFp)
GO(dbus_pending_call_unref, vFp)
GO(dbus_realloc, pFpL)
-//GO(dbus_server_allocate_data_slot,
-//GO(dbus_server_disconnect,
-//GO(dbus_server_free_data_slot,
-//GO(dbus_server_get_address,
+GO(dbus_server_allocate_data_slot, iFp)
+GO(dbus_server_disconnect, vFp)
+GO(dbus_server_free_data_slot, vFp)
+GO(dbus_server_get_address, pFp)
//GO(dbus_server_get_data,
//GO(dbus_server_get_id,
-//GO(dbus_server_get_is_connected,
-//GO(dbus_server_listen,
+GO(dbus_server_get_is_connected, iFp)
+GO(dbus_server_listen, pFpp)
//GO(dbus_server_ref,
//GO(dbus_server_set_auth_mechanisms,
-//GO(dbus_server_set_data,
-//GO(dbus_server_set_new_connection_function,
-//GO(dbus_server_set_timeout_functions,
-//GO(dbus_server_set_watch_functions,
-//GO(dbus_server_unref,
+GOM(dbus_server_set_data, iFEpipp)
+GOM(dbus_server_set_new_connection_function, vFEpppp)
+GOM(dbus_server_set_timeout_functions, iFEpppppp)
+GOM(dbus_server_set_watch_functions, iFEpppppp)
+GO(dbus_server_unref, vFp)
GO(dbus_set_error, vFpppppppppp) //vaarg
GO(dbus_set_error_const, vFppp)
GO(dbus_set_error_from_message, iFpp)
diff --git a/src/wrapped/wrappeddbusglib1.c b/src/wrapped/wrappeddbusglib1.c
index b668046..6c9555a 100755..100644
--- a/src/wrapped/wrappeddbusglib1.c
+++ b/src/wrapped/wrappeddbusglib1.c
@@ -33,10 +33,10 @@ const char* dbusglib1Name = "libdbus-glib-1.so.2";
// GDestroyNotify
#define GO(A) \
-static uintptr_t my_GDestroyNotify_fct_##A = 0; \
-static void my_GDestroyNotify_##A(void* data) \
-{ \
- RunFunction(my_context, my_GDestroyNotify_fct_##A, 1, data);\
+static uintptr_t my_GDestroyNotify_fct_##A = 0; \
+static void my_GDestroyNotify_##A(void* data) \
+{ \
+ RunFunctionFmt(my_GDestroyNotify_fct_##A, "p", data); \
}
SUPER()
#undef GO
@@ -56,10 +56,10 @@ static void* findGDestroyNotifyFct(void* fct)
// GClosureNotify
#define GO(A) \
-static uintptr_t my_GClosureNotify_fct_##A = 0; \
-static void my_GClosureNotify_##A(void* data, void* closure) \
-{ \
- RunFunction(my_context, my_GClosureNotify_fct_##A, 2, data, closure);\
+static uintptr_t my_GClosureNotify_fct_##A = 0; \
+static void my_GClosureNotify_##A(void* data, void* closure) \
+{ \
+ RunFunctionFmt(my_GClosureNotify_fct_##A, "pp", data, closure); \
}
SUPER()
#undef GO
@@ -79,10 +79,10 @@ static void* findGClosureNotifyFct(void* fct)
// DBusGProxyCallNotify
#define GO(A) \
-static uintptr_t my_DBusGProxyCallNotify_fct_##A = 0; \
-static void my_DBusGProxyCallNotify_##A(void* proxy, void* call_id, void* data) \
-{ \
- RunFunction(my_context, my_DBusGProxyCallNotify_fct_##A, 3, proxy, call_id, data);\
+static uintptr_t my_DBusGProxyCallNotify_fct_##A = 0; \
+static void my_DBusGProxyCallNotify_##A(void* proxy, void* call_id, void* data) \
+{ \
+ RunFunctionFmt(my_DBusGProxyCallNotify_fct_##A, "ppp", proxy, call_id, data); \
}
SUPER()
#undef GO
@@ -102,10 +102,10 @@ static void* findDBusGProxyCallNotifyFct(void* fct)
// GCallback
#define GO(A) \
-static uintptr_t my_GCallback_fct_##A = 0; \
-static void my_GCallback_##A(void* a, void* b, void* c, void* d) \
-{ \
- RunFunction(my_context, my_GCallback_fct_##A, 4, a, b, c, d);\
+static uintptr_t my_GCallback_fct_##A = 0; \
+static void my_GCallback_##A(void* a, void* b, void* c, void* d) \
+{ \
+ RunFunctionFmt(my_GCallback_fct_##A, "pppp", a, b, c, d); \
}
SUPER()
#undef GO
@@ -125,10 +125,10 @@ static void* findGCallbackFct(void* fct)
// DBusGTypeSpecializedCollectionIterator
#define GO(A) \
-static uintptr_t my_DBusGTypeSpecializedCollectionIterator_fct_##A = 0; \
-static void my_DBusGTypeSpecializedCollectionIterator_##A(void* a, void* b) \
-{ \
- RunFunction(my_context, my_DBusGTypeSpecializedCollectionIterator_fct_##A, 2, a, b); \
+static uintptr_t my_DBusGTypeSpecializedCollectionIterator_fct_##A = 0; \
+static void my_DBusGTypeSpecializedCollectionIterator_##A(void* a, void* b) \
+{ \
+ RunFunctionFmt(my_DBusGTypeSpecializedCollectionIterator_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -147,10 +147,10 @@ static void* findDBusGTypeSpecializedCollectionIteratorFct(void* fct)
}
// DBusGTypeSpecializedMapIterator
#define GO(A) \
-static uintptr_t my_DBusGTypeSpecializedMapIterator_fct_##A = 0; \
-static void my_DBusGTypeSpecializedMapIterator_##A(void* a, void* b, void* c) \
-{ \
- RunFunction(my_context, my_DBusGTypeSpecializedMapIterator_fct_##A, 3, a, b, c); \
+static uintptr_t my_DBusGTypeSpecializedMapIterator_fct_##A = 0; \
+static void my_DBusGTypeSpecializedMapIterator_##A(void* a, void* b, void* c) \
+{ \
+ RunFunctionFmt(my_DBusGTypeSpecializedMapIterator_fct_##A, "ppp", a, b, c); \
}
SUPER()
#undef GO
diff --git a/src/wrapped/wrappeddbusglib1_private.h b/src/wrapped/wrappeddbusglib1_private.h
index 9485f42..9485f42 100755..100644
--- a/src/wrapped/wrappeddbusglib1_private.h
+++ b/src/wrapped/wrappeddbusglib1_private.h
diff --git a/src/wrapped/wrappedexpat.c b/src/wrapped/wrappedexpat.c
index 4891e37..783b0ca 100755..100644
--- a/src/wrapped/wrappedexpat.c
+++ b/src/wrapped/wrappedexpat.c
@@ -34,10 +34,10 @@ GO(4)
// Start ...
#define GO(A) \
-static uintptr_t my_Start_fct_##A = 0; \
-static void* my_Start_##A(void* data, void* name, void* attr) \
-{ \
- return (void*)RunFunction(my_context, my_Start_fct_##A, 3, data, name, attr); \
+static uintptr_t my_Start_fct_##A = 0; \
+static void* my_Start_##A(void* data, void* name, void* attr) \
+{ \
+ return (void*)RunFunctionFmt(my_Start_fct_##A, "ppp", data, name, attr); \
}
SUPER()
#undef GO
@@ -56,10 +56,10 @@ static void* find_Start_Fct(void* fct)
}
// End ...
#define GO(A) \
-static uintptr_t my_End_fct_##A = 0; \
-static void my_End_##A(void* data, void* name) \
-{ \
- RunFunction(my_context, my_End_fct_##A, 2, data, name);\
+static uintptr_t my_End_fct_##A = 0; \
+static void my_End_##A(void* data, void* name) \
+{ \
+ RunFunctionFmt(my_End_fct_##A, "pp", data, name); \
}
SUPER()
#undef GO
@@ -78,10 +78,10 @@ static void* find_End_Fct(void* fct)
}
// CharData ...
#define GO(A) \
-static uintptr_t my_CharData_fct_##A = 0; \
-static void my_CharData_##A(void* data, void* s, int l) \
-{ \
- RunFunction(my_context, my_CharData_fct_##A, 3, data, s, l);\
+static uintptr_t my_CharData_fct_##A = 0; \
+static void my_CharData_##A(void* data, void* s, int l) \
+{ \
+ RunFunctionFmt(my_CharData_fct_##A, "ppi", data, s, l); \
}
SUPER()
#undef GO
@@ -100,10 +100,10 @@ static void* find_CharData_Fct(void* fct)
}
// StartNamespaceDecl ...
#define GO(A) \
-static uintptr_t my_StartNamespaceDecl_fct_##A = 0; \
-static void my_StartNamespaceDecl_##A(void* data, void* name, void* attr) \
-{ \
- RunFunction(my_context, my_StartNamespaceDecl_fct_##A, 3, data, name, attr); \
+static uintptr_t my_StartNamespaceDecl_fct_##A = 0; \
+static void my_StartNamespaceDecl_##A(void* data, void* name, void* attr) \
+{ \
+ RunFunctionFmt(my_StartNamespaceDecl_fct_##A, "ppp", data, name, attr); \
}
SUPER()
#undef GO
@@ -122,10 +122,10 @@ static void* find_StartNamespaceDecl_Fct(void* fct)
}
// EndNamespaceDecl ...
#define GO(A) \
-static uintptr_t my_EndNamespaceDecl_fct_##A = 0; \
-static void my_EndNamespaceDecl_##A(void* data, void* name) \
-{ \
- RunFunction(my_context, my_EndNamespaceDecl_fct_##A, 2, data, name);\
+static uintptr_t my_EndNamespaceDecl_fct_##A = 0; \
+static void my_EndNamespaceDecl_##A(void* data, void* name) \
+{ \
+ RunFunctionFmt(my_EndNamespaceDecl_fct_##A, "pp", data, name); \
}
SUPER()
#undef GO
@@ -144,10 +144,10 @@ static void* find_EndNamespaceDecl_Fct(void* fct)
}
// StartElement ...
#define GO(A) \
-static uintptr_t my_StartElement_fct_##A = 0; \
-static void my_StartElement_##A(void* data, void* name, void* attr) \
-{ \
- RunFunction(my_context, my_StartElement_fct_##A, 3, data, name, attr); \
+static uintptr_t my_StartElement_fct_##A = 0; \
+static void my_StartElement_##A(void* data, void* name, void* attr) \
+{ \
+ RunFunctionFmt(my_StartElement_fct_##A, "ppp", data, name, attr); \
}
SUPER()
#undef GO
@@ -166,10 +166,10 @@ static void* find_StartElement_Fct(void* fct)
}
// EndElement ...
#define GO(A) \
-static uintptr_t my_EndElement_fct_##A = 0; \
-static void my_EndElement_##A(void* data, void* name) \
-{ \
- RunFunction(my_context, my_EndElement_fct_##A, 2, data, name);\
+static uintptr_t my_EndElement_fct_##A = 0; \
+static void my_EndElement_##A(void* data, void* name) \
+{ \
+ RunFunctionFmt(my_EndElement_fct_##A, "pp", data, name); \
}
SUPER()
#undef GO
@@ -188,10 +188,10 @@ static void* find_EndElement_Fct(void* fct)
}
// CharacterData ...
#define GO(A) \
-static uintptr_t my_CharacterData_fct_##A = 0; \
-static void my_CharacterData_##A(void* data, void* name, int len) \
-{ \
- RunFunction(my_context, my_CharacterData_fct_##A, 3, data, name, len); \
+static uintptr_t my_CharacterData_fct_##A = 0; \
+static void my_CharacterData_##A(void* data, void* name, int len) \
+{ \
+ RunFunctionFmt(my_CharacterData_fct_##A, "ppi", data, name, len); \
}
SUPER()
#undef GO
@@ -210,10 +210,10 @@ static void* find_CharacterData_Fct(void* fct)
}
// ProcessingInstruction ...
#define GO(A) \
-static uintptr_t my_ProcessingInstruction_fct_##A = 0; \
-static void my_ProcessingInstruction_##A(void* a, void* b, void* c) \
-{ \
- RunFunction(my_context, my_ProcessingInstruction_fct_##A, 3, a, b, c); \
+static uintptr_t my_ProcessingInstruction_fct_##A = 0; \
+static void my_ProcessingInstruction_##A(void* a, void* b, void* c) \
+{ \
+ RunFunctionFmt(my_ProcessingInstruction_fct_##A, "ppp", a, b, c); \
}
SUPER()
#undef GO
@@ -232,10 +232,10 @@ static void* find_ProcessingInstruction_Fct(void* fct)
}
// Comment ...
#define GO(A) \
-static uintptr_t my_Comment_fct_##A = 0; \
-static void my_Comment_##A(void* a, void* b) \
-{ \
- RunFunction(my_context, my_Comment_fct_##A, 2, a, b); \
+static uintptr_t my_Comment_fct_##A = 0; \
+static void my_Comment_##A(void* a, void* b) \
+{ \
+ RunFunctionFmt(my_Comment_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -254,10 +254,10 @@ static void* find_Comment_Fct(void* fct)
}
// StartCdataSection ...
#define GO(A) \
-static uintptr_t my_StartCdataSection_fct_##A = 0; \
-static void my_StartCdataSection_##A(void* data) \
-{ \
- RunFunction(my_context, my_StartCdataSection_fct_##A, 1, data); \
+static uintptr_t my_StartCdataSection_fct_##A = 0; \
+static void my_StartCdataSection_##A(void* data) \
+{ \
+ RunFunctionFmt(my_StartCdataSection_fct_##A, "p", data); \
}
SUPER()
#undef GO
@@ -276,10 +276,10 @@ static void* find_StartCdataSection_Fct(void* fct)
}
// EndCdataSection ...
#define GO(A) \
-static uintptr_t my_EndCdataSection_fct_##A = 0; \
-static void my_EndCdataSection_##A(void* data) \
-{ \
- RunFunction(my_context, my_EndCdataSection_fct_##A, 1, data); \
+static uintptr_t my_EndCdataSection_fct_##A = 0; \
+static void my_EndCdataSection_##A(void* data) \
+{ \
+ RunFunctionFmt(my_EndCdataSection_fct_##A, "p", data); \
}
SUPER()
#undef GO
@@ -298,10 +298,10 @@ static void* find_EndCdataSection_Fct(void* fct)
}
// Default ...
#define GO(A) \
-static uintptr_t my_Default_fct_##A = 0; \
-static void my_Default_##A(void* data, void* name, int len) \
-{ \
- RunFunction(my_context, my_Default_fct_##A, 3, data, name, len); \
+static uintptr_t my_Default_fct_##A = 0; \
+static void my_Default_##A(void* data, void* name, int len) \
+{ \
+ RunFunctionFmt(my_Default_fct_##A, "ppi", data, name, len); \
}
SUPER()
#undef GO
@@ -320,10 +320,10 @@ static void* find_Default_Fct(void* fct)
}
// StartDoctypeDecl ...
#define GO(A) \
-static uintptr_t my_StartDoctypeDecl_fct_##A = 0; \
-static void my_StartDoctypeDecl_##A(void* a, void* b, void* c, void* d, int e) \
-{ \
- RunFunction(my_context, my_StartDoctypeDecl_fct_##A, 5, a, b, c, d, e); \
+static uintptr_t my_StartDoctypeDecl_fct_##A = 0; \
+static void my_StartDoctypeDecl_##A(void* a, void* b, void* c, void* d, int e) \
+{ \
+ RunFunctionFmt(my_StartDoctypeDecl_fct_##A, "ppppi", a, b, c, d, e); \
}
SUPER()
#undef GO
@@ -342,10 +342,10 @@ static void* find_StartDoctypeDecl_Fct(void* fct)
}
// EndDoctypeDecl ...
#define GO(A) \
-static uintptr_t my_EndDoctypeDecl_fct_##A = 0; \
-static void my_EndDoctypeDecl_##A(void* data) \
-{ \
- RunFunction(my_context, my_EndDoctypeDecl_fct_##A, 1, data); \
+static uintptr_t my_EndDoctypeDecl_fct_##A = 0; \
+static void my_EndDoctypeDecl_##A(void* data) \
+{ \
+ RunFunctionFmt(my_EndDoctypeDecl_fct_##A, "p", data); \
}
SUPER()
#undef GO
@@ -364,10 +364,10 @@ static void* find_EndDoctypeDecl_Fct(void* fct)
}
// EntityDecl ...
#define GO(A) \
-static uintptr_t my_EntityDecl_fct_##A = 0; \
-static void my_EntityDecl_##A(void* a, void* b, int c, void* d, int e, void* f, void* g, void* h, void* i) \
-{ \
- RunFunction(my_context, my_EntityDecl_fct_##A, 9, a, b, c, d, e, f, g, h, i); \
+static uintptr_t my_EntityDecl_fct_##A = 0; \
+static void my_EntityDecl_##A(void* a, void* b, int c, void* d, int e, void* f, void* g, void* h, void* i) \
+{ \
+ RunFunctionFmt(my_EntityDecl_fct_##A, "ppipipppp", a, b, c, d, e, f, g, h, i); \
}
SUPER()
#undef GO
@@ -386,10 +386,10 @@ static void* find_EntityDecl_Fct(void* fct)
}
// ElementDecl ...
#define GO(A) \
-static uintptr_t my_ElementDecl_fct_##A = 0; \
-static void my_ElementDecl_##A(void* a, void* b, void* c) \
-{ \
- RunFunction(my_context, my_ElementDecl_fct_##A, 3, a, b, c); \
+static uintptr_t my_ElementDecl_fct_##A = 0; \
+static void my_ElementDecl_##A(void* a, void* b, void* c) \
+{ \
+ RunFunctionFmt(my_ElementDecl_fct_##A, "ppp", a, b, c); \
}
SUPER()
#undef GO
@@ -408,10 +408,10 @@ static void* find_ElementDecl_Fct(void* fct)
}
// UnknownEncoding ...
#define GO(A) \
-static uintptr_t my_UnknownEncoding_fct_##A = 0; \
-static int my_UnknownEncoding_##A(void* a, void* b, void* c) \
-{ \
- return (int)RunFunction(my_context, my_UnknownEncoding_fct_##A, 3, a, b, c); \
+static uintptr_t my_UnknownEncoding_fct_##A = 0; \
+static int my_UnknownEncoding_##A(void* a, void* b, void* c) \
+{ \
+ return (int)RunFunctionFmt(my_UnknownEncoding_fct_##A, "ppp", a, b, c); \
}
SUPER()
#undef GO
@@ -433,7 +433,7 @@ static void* find_UnknownEncoding_Fct(void* fct)
static uintptr_t my_UnparsedEntityDecl_fct_##A = 0; \
static void my_UnparsedEntityDecl_##A(void* a, void* b, void* c, void* d, void* e, void* f) \
{ \
- RunFunction(my_context, my_UnparsedEntityDecl_fct_##A, 6, a, b, c, d, e, f); \
+ RunFunctionFmt(my_UnparsedEntityDecl_fct_##A, "pppppp", a, b, c, d, e, f); \
}
SUPER()
#undef GO
@@ -452,10 +452,10 @@ static void* find_UnparsedEntityDecl_Fct(void* fct)
}
// NotationDecl ...
#define GO(A) \
-static uintptr_t my_NotationDecl_fct_##A = 0; \
-static void my_NotationDecl_##A(void* a, void* b, void* c, void* d, void* e) \
-{ \
- RunFunction(my_context, my_NotationDecl_fct_##A, 5, a, b, c, d, e); \
+static uintptr_t my_NotationDecl_fct_##A = 0; \
+static void my_NotationDecl_##A(void* a, void* b, void* c, void* d, void* e) \
+{ \
+ RunFunctionFmt(my_NotationDecl_fct_##A, "ppppp", a, b, c, d, e); \
}
SUPER()
#undef GO
@@ -474,10 +474,10 @@ static void* find_NotationDecl_Fct(void* fct)
}
// NotStandalone ...
#define GO(A) \
-static uintptr_t my_NotStandalone_fct_##A = 0; \
-static int my_NotStandalone_##A(void* data) \
-{ \
- return (int)RunFunction(my_context, my_NotStandalone_fct_##A, 1, data); \
+static uintptr_t my_NotStandalone_fct_##A = 0; \
+static int my_NotStandalone_##A(void* data) \
+{ \
+ return (int)RunFunctionFmt(my_NotStandalone_fct_##A, "p", data); \
}
SUPER()
#undef GO
@@ -496,10 +496,10 @@ static void* find_NotStandalone_Fct(void* fct)
}
// ExternalEntityRef ...
#define GO(A) \
-static uintptr_t my_ExternalEntityRef_fct_##A = 0; \
-static int my_ExternalEntityRef_##A(void* a, void* b, void* c, void* d, void* e) \
-{ \
- return (int)RunFunction(my_context, my_ExternalEntityRef_fct_##A, 5, a, b, c, d, e); \
+static uintptr_t my_ExternalEntityRef_fct_##A = 0; \
+static int my_ExternalEntityRef_##A(void* a, void* b, void* c, void* d, void* e) \
+{ \
+ return (int)RunFunctionFmt(my_ExternalEntityRef_fct_##A, "ppppp", a, b, c, d, e); \
}
SUPER()
#undef GO
@@ -518,10 +518,10 @@ static void* find_ExternalEntityRef_Fct(void* fct)
}
// XmlDecl ...
#define GO(A) \
-static uintptr_t my_XmlDecl_fct_##A = 0; \
-static void my_XmlDecl_##A(void* a, void* b, void* c, int d) \
-{ \
- RunFunction(my_context, my_XmlDecl_fct_##A, 4, a, b, c, d); \
+static uintptr_t my_XmlDecl_fct_##A = 0; \
+static void my_XmlDecl_##A(void* a, void* b, void* c, int d) \
+{ \
+ RunFunctionFmt(my_XmlDecl_fct_##A, "pppi", a, b, c, d); \
}
SUPER()
#undef GO
@@ -543,7 +543,7 @@ static void* find_XmlDecl_Fct(void* fct)
static uintptr_t my_AttlistDecl_fct_##A = 0; \
static void my_AttlistDecl_##A(void* a, void* b, void* c, void* d, void* e, int f) \
{ \
- RunFunction(my_context, my_AttlistDecl_fct_##A, 6, a, b, c, d, e, f); \
+ RunFunctionFmt(my_AttlistDecl_fct_##A, "pppppi", a, b, c, d, e, f); \
}
SUPER()
#undef GO
@@ -562,10 +562,10 @@ static void* find_AttlistDecl_Fct(void* fct)
}
// SkippedEntity ...
#define GO(A) \
-static uintptr_t my_SkippedEntity_fct_##A = 0; \
-static void my_SkippedEntity_##A(void* a, void* b, int c) \
-{ \
- RunFunction(my_context, my_SkippedEntity_fct_##A, 3, a, b, c); \
+static uintptr_t my_SkippedEntity_fct_##A = 0; \
+static void my_SkippedEntity_##A(void* a, void* b, int c) \
+{ \
+ RunFunctionFmt(my_SkippedEntity_fct_##A, "ppi", a, b, c); \
}
SUPER()
#undef GO
diff --git a/src/wrapped/wrappedexpat_private.h b/src/wrapped/wrappedexpat_private.h
index c57ad35..5ce94ae 100755..100644
--- a/src/wrapped/wrappedexpat_private.h
+++ b/src/wrapped/wrappedexpat_private.h
@@ -30,7 +30,7 @@ GO(XML_ParserCreate, pFp)
GO(XML_ParserCreate_MM, pFpppp) // return a structure
//GO(XML_ParserCreateNS,
GO(XML_ParserFree, vFp)
-//GO(XML_ParserReset,
+GO(XML_ParserReset, iFpp)
//GO(XML_ResumeParser,
GOM(XML_SetAttlistDeclHandler, vFEpp)
GO(XML_SetBase, iFpp)
diff --git a/src/wrapped/wrappedfaudio.c b/src/wrapped/wrappedfaudio.c
index ae4d337..619799e 100644
--- a/src/wrapped/wrappedfaudio.c
+++ b/src/wrapped/wrappedfaudio.c
@@ -34,10 +34,10 @@ GO(4)
// FAudioMalloc ...
#define GO(A) \
-static uintptr_t my_FAudioMalloc_fct_##A = 0; \
-static void* my_FAudioMalloc_##A(size_t a) \
-{ \
- return (void*)RunFunction(my_context, my_FAudioMalloc_fct_##A, 1, a); \
+static uintptr_t my_FAudioMalloc_fct_##A = 0; \
+static void* my_FAudioMalloc_##A(size_t a) \
+{ \
+ return (void*)RunFunctionFmt(my_FAudioMalloc_fct_##A, "L", a); \
}
SUPER()
#undef GO
@@ -56,10 +56,10 @@ static void* find_FAudioMalloc_Fct(void* fct)
}
// FAudioFree ...
#define GO(A) \
-static uintptr_t my_FAudioFree_fct_##A = 0; \
-static void my_FAudioFree_##A(void* a) \
-{ \
- RunFunction(my_context, my_FAudioFree_fct_##A, 1, a); \
+static uintptr_t my_FAudioFree_fct_##A = 0; \
+static void my_FAudioFree_##A(void* a) \
+{ \
+ RunFunctionFmt(my_FAudioFree_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -78,10 +78,10 @@ static void* find_FAudioFree_Fct(void* fct)
}
// FAudioRealloc ...
#define GO(A) \
-static uintptr_t my_FAudioRealloc_fct_##A = 0; \
-static void* my_FAudioRealloc_##A(void* a, size_t b) \
-{ \
- return (void*)RunFunction(my_context, my_FAudioRealloc_fct_##A, 2, a, b); \
+static uintptr_t my_FAudioRealloc_fct_##A = 0; \
+static void* my_FAudioRealloc_##A(void* a, size_t b) \
+{ \
+ return (void*)RunFunctionFmt(my_FAudioRealloc_fct_##A, "pL", a, b); \
}
SUPER()
#undef GO
@@ -100,10 +100,10 @@ static void* find_FAudioRealloc_Fct(void* fct)
}
// OnCriticalErrorFunc ...
#define GO(A) \
-static uintptr_t my_OnCriticalErrorFunc_fct_##A = 0; \
-static void my_OnCriticalErrorFunc_##A(void* a, uint32_t b) \
-{ \
- RunFunction(my_context, my_OnCriticalErrorFunc_fct_##A, 2, a, b); \
+static uintptr_t my_OnCriticalErrorFunc_fct_##A = 0; \
+static void my_OnCriticalErrorFunc_##A(void* a, uint32_t b) \
+{ \
+ RunFunctionFmt(my_OnCriticalErrorFunc_fct_##A, "pu", a, b); \
}
SUPER()
#undef GO
@@ -122,10 +122,10 @@ static void* find_OnCriticalErrorFunc_Fct(void* fct)
}
// OnProcessingPassEndFunc ...
#define GO(A) \
-static uintptr_t my_OnProcessingPassEndFunc_fct_##A = 0; \
-static void my_OnProcessingPassEndFunc_##A(void* a) \
-{ \
- RunFunction(my_context, my_OnProcessingPassEndFunc_fct_##A, 1, a); \
+static uintptr_t my_OnProcessingPassEndFunc_fct_##A = 0; \
+static void my_OnProcessingPassEndFunc_##A(void* a) \
+{ \
+ RunFunctionFmt(my_OnProcessingPassEndFunc_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -144,10 +144,10 @@ static void* find_OnProcessingPassEndFunc_Fct(void* fct)
}
// OnProcessingPassStartFunc ...
#define GO(A) \
-static uintptr_t my_OnProcessingPassStartFunc_fct_##A = 0; \
-static void my_OnProcessingPassStartFunc_##A(void* a) \
-{ \
- RunFunction(my_context, my_OnProcessingPassStartFunc_fct_##A, 1, a); \
+static uintptr_t my_OnProcessingPassStartFunc_fct_##A = 0; \
+static void my_OnProcessingPassStartFunc_##A(void* a) \
+{ \
+ RunFunctionFmt(my_OnProcessingPassStartFunc_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -172,10 +172,10 @@ typedef struct my_FAudioEngineCallback_s
} my_FAudioEngineCallback_t;
// OnBufferEndFunc ...
#define GO(A) \
-static uintptr_t my_OnBufferEndFunc_fct_##A = 0; \
-static void my_OnBufferEndFunc_##A(void* a, void* b) \
-{ \
- RunFunction(my_context, my_OnBufferEndFunc_fct_##A, 2, a, b); \
+static uintptr_t my_OnBufferEndFunc_fct_##A = 0; \
+static void my_OnBufferEndFunc_##A(void* a, void* b) \
+{ \
+ RunFunctionFmt(my_OnBufferEndFunc_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -194,10 +194,10 @@ static void* find_OnBufferEndFunc_Fct(void* fct)
}
// OnBufferStartFunc ...
#define GO(A) \
-static uintptr_t my_OnBufferStartFunc_fct_##A = 0; \
-static void my_OnBufferStartFunc_##A(void* a, void* b) \
-{ \
- RunFunction(my_context, my_OnBufferStartFunc_fct_##A, 2, a, b); \
+static uintptr_t my_OnBufferStartFunc_fct_##A = 0; \
+static void my_OnBufferStartFunc_##A(void* a, void* b) \
+{ \
+ RunFunctionFmt(my_OnBufferStartFunc_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -216,10 +216,10 @@ static void* find_OnBufferStartFunc_Fct(void* fct)
}
// OnLoopEndFunc ...
#define GO(A) \
-static uintptr_t my_OnLoopEndFunc_fct_##A = 0; \
-static void my_OnLoopEndFunc_##A(void* a, void* b) \
-{ \
- RunFunction(my_context, my_OnLoopEndFunc_fct_##A, 2, a, b); \
+static uintptr_t my_OnLoopEndFunc_fct_##A = 0; \
+static void my_OnLoopEndFunc_##A(void* a, void* b) \
+{ \
+ RunFunctionFmt(my_OnLoopEndFunc_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -238,10 +238,10 @@ static void* find_OnLoopEndFunc_Fct(void* fct)
}
// OnStreamEndFunc ...
#define GO(A) \
-static uintptr_t my_OnStreamEndFunc_fct_##A = 0; \
-static void my_OnStreamEndFunc_##A(void* a) \
-{ \
- RunFunction(my_context, my_OnStreamEndFunc_fct_##A, 1, a); \
+static uintptr_t my_OnStreamEndFunc_fct_##A = 0; \
+static void my_OnStreamEndFunc_##A(void* a) \
+{ \
+ RunFunctionFmt(my_OnStreamEndFunc_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -260,10 +260,10 @@ static void* find_OnStreamEndFunc_Fct(void* fct)
}
// OnVoiceErrorFunc ...
#define GO(A) \
-static uintptr_t my_OnVoiceErrorFunc_fct_##A = 0; \
-static void my_OnVoiceErrorFunc_##A(void* a, void* b, uint32_t c) \
-{ \
- RunFunction(my_context, my_OnVoiceErrorFunc_fct_##A, 3, a, b, c); \
+static uintptr_t my_OnVoiceErrorFunc_fct_##A = 0; \
+static void my_OnVoiceErrorFunc_##A(void* a, void* b, uint32_t c) \
+{ \
+ RunFunctionFmt(my_OnVoiceErrorFunc_fct_##A, "ppu", a, b, c); \
}
SUPER()
#undef GO
@@ -282,10 +282,10 @@ static void* find_OnVoiceErrorFunc_Fct(void* fct)
}
// OnVoiceProcessingPassEndFunc ...
#define GO(A) \
-static uintptr_t my_OnVoiceProcessingPassEndFunc_fct_##A = 0; \
-static void my_OnVoiceProcessingPassEndFunc_##A(void* a) \
-{ \
- RunFunction(my_context, my_OnVoiceProcessingPassEndFunc_fct_##A, 1, a); \
+static uintptr_t my_OnVoiceProcessingPassEndFunc_fct_##A = 0; \
+static void my_OnVoiceProcessingPassEndFunc_##A(void* a) \
+{ \
+ RunFunctionFmt(my_OnVoiceProcessingPassEndFunc_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -304,10 +304,10 @@ static void* find_OnVoiceProcessingPassEndFunc_Fct(void* fct)
}
// OnVoiceProcessingPassStartFunc ...
#define GO(A) \
-static uintptr_t my_OnVoiceProcessingPassStartFunc_fct_##A = 0; \
-static void my_OnVoiceProcessingPassStartFunc_##A(void* a, uint32_t b) \
-{ \
- RunFunction(my_context, my_OnVoiceProcessingPassStartFunc_fct_##A, 2, a, b); \
+static uintptr_t my_OnVoiceProcessingPassStartFunc_fct_##A = 0; \
+static void my_OnVoiceProcessingPassStartFunc_##A(void* a, uint32_t b) \
+{ \
+ RunFunctionFmt(my_OnVoiceProcessingPassStartFunc_fct_##A, "pu", a, b); \
}
SUPER()
#undef GO
@@ -336,10 +336,10 @@ typedef struct my_FAudioVoiceCallback_s
} my_FAudioVoiceCallback_t;
// FAudioEngineCallEXT ...
#define GO(A) \
-static uintptr_t my_FAudioEngineCallEXT_fct_##A = 0; \
-static void my_FAudioEngineCallEXT_##A(void* a, void* b) \
-{ \
- RunFunction(my_context, my_FAudioEngineCallEXT_fct_##A, 2, a, b); \
+static uintptr_t my_FAudioEngineCallEXT_fct_##A = 0; \
+static void my_FAudioEngineCallEXT_##A(void* a, void* b) \
+{ \
+ RunFunctionFmt(my_FAudioEngineCallEXT_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -358,10 +358,10 @@ static void* find_FAudioEngineCallEXT_Fct(void* fct)
}
// FAudioEngineProcedureEXT ...
#define GO(A) \
-static uintptr_t my_FAudioEngineProcedureEXT_fct_##A = 0; \
-static void my_FAudioEngineProcedureEXT_##A(void* a, void* b, void* c, void* d) \
-{ \
- RunFunction(my_context, my_FAudioEngineProcedureEXT_fct_##A, 4, find_FAudioEngineCallEXT_Fct(a), b, c, d); \
+static uintptr_t my_FAudioEngineProcedureEXT_fct_##A = 0; \
+static void my_FAudioEngineProcedureEXT_##A(void* a, void* b, void* c, void* d) \
+{ \
+ RunFunctionFmt(my_FAudioEngineProcedureEXT_fct_##A, "pppp", find_FAudioEngineCallEXT_Fct(a), b, c, d); \
}
SUPER()
#undef GO
diff --git a/src/wrapped/wrappedfaudio_private.h b/src/wrapped/wrappedfaudio_private.h
index bec2d84..d3ad060 100644
--- a/src/wrapped/wrappedfaudio_private.h
+++ b/src/wrapped/wrappedfaudio_private.h
@@ -18,8 +18,8 @@ GO(F3DAudioCalculate, vFpppup)
//GO(F3DAudioCheckInitParams,
GO(F3DAudioInitialize, vFufp)
GO(F3DAudioInitialize8, uFufp)
-//GO(FACT3DApply,
-//GO(FACT3DCalculate,
+GO(FACT3DApply, uFpp)
+GO(FACT3DCalculate, uFpppp)
GO(FACT3DInitialize, uFpp)
GO(FACTAudioEngine_AddRef, uFp)
GO(FACTAudioEngine_CreateInMemoryWaveBank, uFppuuup)
@@ -92,9 +92,9 @@ GO(FACTSoundBank_Stop, uFpWu)
GO(FACTWaveBank_Destroy, uFp)
GO(FACTWaveBank_GetNumWaves, uFpp)
GO(FACTWaveBank_GetState, uFpp)
-GO(FACTWaveBank_GetWaveIndex, uFpp)
+GO(FACTWaveBank_GetWaveIndex, WFpp)
GO(FACTWaveBank_GetWaveProperties, uFpWp)
-GO(FACTWaveBank_Play, uFpWuwCp)
+GO(FACTWaveBank_Play, uFpWuuCp)
GO(FACTWaveBank_Prepare, uFpWuuCp)
GO(FACTWaveBank_Stop, uFpWu)
GO(FACTWave_Destroy, uFp)
@@ -146,13 +146,13 @@ GOM(FAPOFX_CreateFXWithCustomAllocatorEXT, uFEpppuppp)
//GO(FAPOFXReverb_Process,
GO(FAudio_AddRef, uFp)
//GO(FAudio_close,
-GO(FAudioCOMConstructEXT, uFpuC)
+GO(FAudioCOMConstructEXT, uFpC)
GOM(FAudioCOMConstructWithCustomAllocatorEXT, uFEpCppp)
GO(FAudio_CommitChanges, uFp)
GO(FAudio_CommitOperationSet, uFpu)
GO(FAudioCreate, uFpuu)
GO(FAudio_CreateMasteringVoice, uFppuuuup)
-GO(FAudio_CreateMasteringVoice8, uFppuuuppi)
+GO(FAudio_CreateMasteringVoice8, uFppuuuppu)
GO(FAudioCreateReverb, uFpu)
GO(FAudioCreateReverb9, uFpu)
GOM(FAudioCreateReverb9WithCustomAllocatorEXT, uFEpuppp)
@@ -302,7 +302,7 @@ GO(FAudioVoice_SetVolume, uFpfu)
//GO(LinkedList_PrependEntry,
//GO(LinkedList_RemoveEntry,
GO(ReverbConvertI3DL2ToNative, vFpp)
-GO(ReverbConvertI3DL2ToNative9, vFpp)
+GO(ReverbConvertI3DL2ToNative9, vFppi)
GO(XNA_EnableVisualization, vFu)
GO(XNA_GetSongEnded, uFv)
GO(XNA_GetSongVisualizationData, vFppu)
diff --git a/src/wrapped/wrappedflac.c b/src/wrapped/wrappedflac.c
index 4bff742..bc1919c 100755..100644
--- a/src/wrapped/wrappedflac.c
+++ b/src/wrapped/wrappedflac.c
@@ -51,10 +51,10 @@ GO(7)
// read_write
#define GO(A) \
-static uintptr_t my_read_write_fct_##A = 0; \
-static unsigned long my_read_write_##A(void* ptr, unsigned long size, unsigned long nmemb, void* handle) \
-{ \
- return RunFunction(my_context, my_read_write_fct_##A, 4, ptr, size, nmemb, handle);\
+static uintptr_t my_read_write_fct_##A = 0; \
+static unsigned long my_read_write_##A(void* ptr, unsigned long size, unsigned long nmemb, void* handle) \
+{ \
+ return RunFunctionFmt(my_read_write_fct_##A, "pLLp", ptr, size, nmemb, handle); \
}
SUPER()
#undef GO
@@ -73,10 +73,10 @@ static void* findread_writeFct(void* fct)
}
// seek
#define GO(A) \
-static uintptr_t my_seek_fct_##A = 0; \
-static int my_seek_##A(void* ptr, int64_t offset, int whence) \
-{ \
- return (int)RunFunction(my_context, my_seek_fct_##A, 3, ptr, offset, whence);\
+static uintptr_t my_seek_fct_##A = 0; \
+static int my_seek_##A(void* ptr, int64_t offset, int whence) \
+{ \
+ return (int)RunFunctionFmt(my_seek_fct_##A, "pIi", ptr, offset, whence); \
}
SUPER()
#undef GO
@@ -95,10 +95,10 @@ static void* findseekFct(void* fct)
}
// close_eof
#define GO(A) \
-static uintptr_t my_close_eof_fct_##A = 0; \
-static int my_close_eof_##A(void* ptr) \
-{ \
- return (int)RunFunction(my_context, my_close_eof_fct_##A, 1, ptr);\
+static uintptr_t my_close_eof_fct_##A = 0; \
+static int my_close_eof_##A(void* ptr) \
+{ \
+ return (int)RunFunctionFmt(my_close_eof_fct_##A, "p", ptr); \
}
SUPER()
#undef GO
@@ -117,10 +117,10 @@ static void* findclose_eofFct(void* fct)
}
// tell
#define GO(A) \
-static uintptr_t my_tell_fct_##A = 0; \
-static long my_tell_##A(void* ptr) \
-{ \
- return (long)RunFunction(my_context, my_tell_fct_##A, 1, ptr);\
+static uintptr_t my_tell_fct_##A = 0; \
+static long my_tell_##A(void* ptr) \
+{ \
+ return (long)RunFunctionFmt(my_tell_fct_##A, "p", ptr); \
}
SUPER()
#undef GO
@@ -138,11 +138,11 @@ static void* findtellFct(void* fct)
return NULL;
}
// Read
-#define GO(A) \
-static uintptr_t my_Read_fct_##A = 0; \
-static int my_Read_##A(void* decoder, void* buffer, size_t* bytes, void* data) \
-{ \
- return (int)RunFunction(my_context, my_Read_fct_##A, 4, decoder, buffer, bytes, data); \
+#define GO(A) \
+static uintptr_t my_Read_fct_##A = 0; \
+static int my_Read_##A(void* decoder, void* buffer, size_t* bytes, void* data) \
+{ \
+ return (int)RunFunctionFmt(my_Read_fct_##A, "pppp", decoder, buffer, bytes, data); \
}
SUPER()
#undef GO
@@ -160,11 +160,11 @@ static void* findReadFct(void* fct)
return NULL;
}
// Seek
-#define GO(A) \
-static uintptr_t my_Seek_fct_##A = 0; \
-static int my_Seek_##A(void* decoder, uint64_t offset, void* data) \
-{ \
- return (int)RunFunction(my_context, my_Seek_fct_##A, 3, decoder, offset, data); \
+#define GO(A) \
+static uintptr_t my_Seek_fct_##A = 0; \
+static int my_Seek_##A(void* decoder, uint64_t offset, void* data) \
+{ \
+ return (int)RunFunctionFmt(my_Seek_fct_##A, "pUp", decoder, offset, data); \
}
SUPER()
#undef GO
@@ -182,11 +182,11 @@ static void* findSeekFct(void* fct)
return NULL;
}
// Tell
-#define GO(A) \
-static uintptr_t my_Tell_fct_##A = 0; \
-static int my_Tell_##A(void* decoder, uint64_t *offset, void* data) \
-{ \
- return (int)RunFunction(my_context, my_Tell_fct_##A, 3, decoder, offset, data); \
+#define GO(A) \
+static uintptr_t my_Tell_fct_##A = 0; \
+static int my_Tell_##A(void* decoder, uint64_t *offset, void* data) \
+{ \
+ return (int)RunFunctionFmt(my_Tell_fct_##A, "ppp", decoder, offset, data); \
}
SUPER()
#undef GO
@@ -204,11 +204,11 @@ static void* findTellFct(void* fct)
return NULL;
}
// Length
-#define GO(A) \
-static uintptr_t my_Length_fct_##A = 0; \
-static int my_Length_##A(void* decoder, uint64_t *length, void* data) \
-{ \
- return (int)RunFunction(my_context, my_Length_fct_##A, 3, decoder, length, data); \
+#define GO(A) \
+static uintptr_t my_Length_fct_##A = 0; \
+static int my_Length_##A(void* decoder, uint64_t *length, void* data) \
+{ \
+ return (int)RunFunctionFmt(my_Length_fct_##A, "ppp", decoder, length, data); \
}
SUPER()
#undef GO
@@ -226,11 +226,11 @@ static void* findLengthFct(void* fct)
return NULL;
}
// Eof
-#define GO(A) \
-static uintptr_t my_Eof_fct_##A = 0; \
-static int my_Eof_##A(void* decoder, void* data) \
-{ \
- return (int)RunFunction(my_context, my_Eof_fct_##A, 2, decoder, data); \
+#define GO(A) \
+static uintptr_t my_Eof_fct_##A = 0; \
+static int my_Eof_##A(void* decoder, void* data) \
+{ \
+ return (int)RunFunctionFmt(my_Eof_fct_##A, "pp", decoder, data); \
}
SUPER()
#undef GO
@@ -248,11 +248,11 @@ static void* findEofFct(void* fct)
return NULL;
}
// Write
-#define GO(A) \
-static uintptr_t my_Write_fct_##A = 0; \
-static int my_Write_##A(void* decoder, void* frame, void* buffer, void* data) \
-{ \
- return (int)RunFunction(my_context, my_Write_fct_##A, 4, decoder, frame, buffer, data); \
+#define GO(A) \
+static uintptr_t my_Write_fct_##A = 0; \
+static int my_Write_##A(void* decoder, void* frame, void* buffer, void* data) \
+{ \
+ return (int)RunFunctionFmt(my_Write_fct_##A, "pppp", decoder, frame, buffer, data); \
}
SUPER()
#undef GO
@@ -270,11 +270,11 @@ static void* findWriteFct(void* fct)
return NULL;
}
// Metadata
-#define GO(A) \
-static uintptr_t my_Metadata_fct_##A = 0; \
-static int my_Metadata_##A(void* decoder, void* metadata, void* data) \
-{ \
- return (int)RunFunction(my_context, my_Metadata_fct_##A, 3, decoder, metadata, data); \
+#define GO(A) \
+static uintptr_t my_Metadata_fct_##A = 0; \
+static int my_Metadata_##A(void* decoder, void* metadata, void* data) \
+{ \
+ return (int)RunFunctionFmt(my_Metadata_fct_##A, "ppp", decoder, metadata, data); \
}
SUPER()
#undef GO
@@ -292,11 +292,11 @@ static void* findMetadataFct(void* fct)
return NULL;
}
// Error
-#define GO(A) \
-static uintptr_t my_Error_fct_##A = 0; \
-static void my_Error_##A(void* decoder, int status, void* data) \
-{ \
- RunFunction(my_context, my_Error_fct_##A, 3, decoder, status, data); \
+#define GO(A) \
+static uintptr_t my_Error_fct_##A = 0; \
+static void my_Error_##A(void* decoder, int status, void* data) \
+{ \
+ RunFunctionFmt(my_Error_fct_##A, "pip", decoder, status, data); \
}
SUPER()
#undef GO
@@ -317,7 +317,7 @@ static void* findErrorFct(void* fct)
#undef SUPER
-EXPORT int my_FLAC__metadata_chain_read_with_callbacks(x64emu_t* emu, void* chain, void* handle,
+EXPORT int my_FLAC__metadata_chain_read_with_callbacks(x64emu_t* emu, void* chain, void* handle,
void* read_fnc, void* write_fnc, void* seek_fnc, void* tell_fnc, void* eof_fnc, void* close_fnc)
{
flac_callbacks cbs = {0};
@@ -332,10 +332,10 @@ EXPORT int my_FLAC__metadata_chain_read_with_callbacks(x64emu_t* emu, void* chai
}
EXPORT int my_FLAC__stream_decoder_init_stream(x64emu_t* emu, void* decoder,
- void* read_fnc, void* seek_fnc, void* tell_fnc, void* length_fnc, void* eof_fnc,
+ void* read_fnc, void* seek_fnc, void* tell_fnc, void* length_fnc, void* eof_fnc,
void* write_fnc, void* metadata_fnc, void* error_fnc, void* data)
{
- int ret = my->FLAC__stream_decoder_init_stream(decoder,
+ int ret = my->FLAC__stream_decoder_init_stream(decoder,
findReadFct(read_fnc), findSeekFct(seek_fnc), findTellFct(tell_fnc),
findLengthFct(length_fnc), findEofFct(eof_fnc), findWriteFct(write_fnc),
findMetadataFct(metadata_fnc), findErrorFct(error_fnc), data);
diff --git a/src/wrapped/wrappedflac_private.h b/src/wrapped/wrappedflac_private.h
index ba5d75c..f676c19 100755..100644
--- a/src/wrapped/wrappedflac_private.h
+++ b/src/wrapped/wrappedflac_private.h
@@ -5,39 +5,39 @@
//DATA(FLAC_API_SUPPORTS_OGG_FLAC,
//DATA(FLAC__ChannelAssignmentString,
//DATA(FLAC__EntropyCodingMethodTypeString,
-//GO(FLAC__format_blocksize_is_subset,
-//GO(FLAC__format_cuesheet_is_legal,
-//GO(FLAC__format_picture_is_legal,
-//GO(FLAC__format_sample_rate_is_subset,
+GO(FLAC__format_blocksize_is_subset, iFuu)
+GO(FLAC__format_cuesheet_is_legal, iFpip)
+GO(FLAC__format_picture_is_legal, iFpp)
+GO(FLAC__format_sample_rate_is_subset, iFu)
//GO(FLAC__format_sample_rate_is_valid,
-//GO(FLAC__format_seektable_is_legal,
-//GO(FLAC__format_seektable_sort,
-//GO(FLAC__format_vorbiscomment_entry_is_legal,
-//GO(FLAC__format_vorbiscomment_entry_name_is_legal,
+GO(FLAC__format_seektable_is_legal, iFp)
+GO(FLAC__format_seektable_sort, uFp)
+GO(FLAC__format_vorbiscomment_entry_is_legal, iFpu)
+GO(FLAC__format_vorbiscomment_entry_name_is_legal, iFp)
//GO(FLAC__format_vorbiscomment_entry_value_is_legal,
//DATA(FLAC__FrameNumberTypeString,
-//GO(FLAC__metadata_chain_check_if_tempfile_needed,
+GO(FLAC__metadata_chain_check_if_tempfile_needed, iFpi)
//GO(FLAC__metadata_chain_delete,
//GO(FLAC__metadata_chain_merge_padding,
GO(FLAC__metadata_chain_new, pFv)
//GO(FLAC__metadata_chain_read,
-//GO(FLAC__metadata_chain_read_ogg,
+GO(FLAC__metadata_chain_read_ogg, iFpp)
//GO(FLAC__metadata_chain_read_ogg_with_callbacks,
GOM(FLAC__metadata_chain_read_with_callbacks, iFEppPPPPPP) // FLAC__IOCallbacks is a struct with all callbacks
-//GO(FLAC__metadata_chain_sort_padding,
-GO(FLAC__metadata_chain_status, iFp)
+GO(FLAC__metadata_chain_sort_padding, vFp)
+GO(FLAC__metadata_chain_status, uFp)
DATA(FLAC__Metadata_ChainStatusString, sizeof(void*))
-//GO(FLAC__metadata_chain_write,
+GO(FLAC__metadata_chain_write, iFpii)
//GO(FLAC__metadata_chain_write_with_callbacks,
//GO(FLAC__metadata_chain_write_with_callbacks_and_tempfile,
-//GO(FLAC__metadata_get_cuesheet,
-//GO(FLAC__metadata_get_picture,
-//GO(FLAC__metadata_get_streaminfo,
+GO(FLAC__metadata_get_cuesheet, iFpp)
+GO(FLAC__metadata_get_picture, iFppuppuuuu)
+GO(FLAC__metadata_get_streaminfo, iFpp)
//GO(FLAC__metadata_get_tags,
GO(FLAC__metadata_iterator_delete, vFp)
GO(FLAC__metadata_iterator_delete_block, iFpi)
GO(FLAC__metadata_iterator_get_block, pFp)
-GO(FLAC__metadata_iterator_get_block_type, iFp)
+GO(FLAC__metadata_iterator_get_block_type, uFp)
GO(FLAC__metadata_iterator_init, vFpp)
GO(FLAC__metadata_iterator_insert_block_after, iFpp)
GO(FLAC__metadata_iterator_insert_block_before, iFpp)
@@ -45,69 +45,69 @@ GO(FLAC__metadata_iterator_new, pFv)
GO(FLAC__metadata_iterator_next, iFp)
GO(FLAC__metadata_iterator_prev, iFp)
GO(FLAC__metadata_iterator_set_block, iFpp)
-//GO(FLAC__metadata_object_application_set_data,
-//GO(FLAC__metadata_object_clone,
-//GO(FLAC__metadata_object_cuesheet_calculate_cddb_id,
-//GO(FLAC__metadata_object_cuesheet_delete_track,
+GO(FLAC__metadata_object_application_set_data, iFppui)
+GO(FLAC__metadata_object_clone, pFp)
+GO(FLAC__metadata_object_cuesheet_calculate_cddb_id, uFp)
+GO(FLAC__metadata_object_cuesheet_delete_track, iFpu)
//GO(FLAC__metadata_object_cuesheet_insert_blank_track,
-//GO(FLAC__metadata_object_cuesheet_insert_track,
-//GO(FLAC__metadata_object_cuesheet_is_legal,
+GO(FLAC__metadata_object_cuesheet_insert_track, iFpupi)
+GO(FLAC__metadata_object_cuesheet_is_legal, iFpip)
//GO(FLAC__metadata_object_cuesheet_resize_tracks,
//GO(FLAC__metadata_object_cuesheet_set_track,
-//GO(FLAC__metadata_object_cuesheet_track_clone,
-//GO(FLAC__metadata_object_cuesheet_track_delete,
-//GO(FLAC__metadata_object_cuesheet_track_delete_index,
+GO(FLAC__metadata_object_cuesheet_track_clone, pFp)
+GO(FLAC__metadata_object_cuesheet_track_delete, vFp)
+GO(FLAC__metadata_object_cuesheet_track_delete_index, iFpuu)
//GO(FLAC__metadata_object_cuesheet_track_insert_blank_index,
//GO(FLAC__metadata_object_cuesheet_track_insert_index,
-//GO(FLAC__metadata_object_cuesheet_track_new,
+GO(FLAC__metadata_object_cuesheet_track_new, pFv)
//GO(FLAC__metadata_object_cuesheet_track_resize_indices,
GO(FLAC__metadata_object_delete, vFp)
-//GO(FLAC__metadata_object_is_equal,
-//GO(FLAC__metadata_object_new,
-//GO(FLAC__metadata_object_picture_is_legal,
-//GO(FLAC__metadata_object_picture_set_data,
-//GO(FLAC__metadata_object_picture_set_description,
-//GO(FLAC__metadata_object_picture_set_mime_type,
+GO(FLAC__metadata_object_is_equal, iFpp)
+GO(FLAC__metadata_object_new, pFu)
+GO(FLAC__metadata_object_picture_is_legal, iFpp)
+GO(FLAC__metadata_object_picture_set_data, iFppui)
+GO(FLAC__metadata_object_picture_set_description, iFppi)
+GO(FLAC__metadata_object_picture_set_mime_type, iFppi)
//GO(FLAC__metadata_object_seektable_delete_point,
//GO(FLAC__metadata_object_seektable_insert_point,
-//GO(FLAC__metadata_object_seektable_is_legal,
+GO(FLAC__metadata_object_seektable_is_legal, iFp)
//GO(FLAC__metadata_object_seektable_resize_points,
//GO(FLAC__metadata_object_seektable_set_point,
//GO(FLAC__metadata_object_seektable_template_append_placeholders,
-//GO(FLAC__metadata_object_seektable_template_append_point,
-//GO(FLAC__metadata_object_seektable_template_append_points,
+GO(FLAC__metadata_object_seektable_template_append_point, iFpL)
+GO(FLAC__metadata_object_seektable_template_append_points, iFppu)
//GO(FLAC__metadata_object_seektable_template_append_spaced_points,
-//GO(FLAC__metadata_object_seektable_template_append_spaced_points_by_samples,
-//GO(FLAC__metadata_object_seektable_template_sort,
+GO(FLAC__metadata_object_seektable_template_append_spaced_points_by_samples, iFpuL)
+GO(FLAC__metadata_object_seektable_template_sort, iFpi)
//GO(FLAC__metadata_object_vorbiscomment_append_comment,
//GO(FLAC__metadata_object_vorbiscomment_delete_comment,
-//GO(FLAC__metadata_object_vorbiscomment_entry_from_name_value_pair,
+GO(FLAC__metadata_object_vorbiscomment_entry_from_name_value_pair, iFppp)
//GO(FLAC__metadata_object_vorbiscomment_entry_matches,
//GO(FLAC__metadata_object_vorbiscomment_entry_to_name_value_pair,
-//GO(FLAC__metadata_object_vorbiscomment_find_entry_from,
+GO(FLAC__metadata_object_vorbiscomment_find_entry_from, iFpup)
//GO(FLAC__metadata_object_vorbiscomment_insert_comment,
-//GO(FLAC__metadata_object_vorbiscomment_remove_entries_matching,
+GO(FLAC__metadata_object_vorbiscomment_remove_entries_matching, iFpp)
//GO(FLAC__metadata_object_vorbiscomment_remove_entry_matching,
//GO(FLAC__metadata_object_vorbiscomment_replace_comment,
//GO(FLAC__metadata_object_vorbiscomment_resize_comments,
//GO(FLAC__metadata_object_vorbiscomment_set_comment,
//GO(FLAC__metadata_object_vorbiscomment_set_vendor_string,
-//GO(FLAC__metadata_simple_iterator_delete,
-//GO(FLAC__metadata_simple_iterator_delete_block,
-//GO(FLAC__metadata_simple_iterator_get_application_id,
-//GO(FLAC__metadata_simple_iterator_get_block,
-//GO(FLAC__metadata_simple_iterator_get_block_length,
-//GO(FLAC__metadata_simple_iterator_get_block_offset,
-//GO(FLAC__metadata_simple_iterator_get_block_type,
-//GO(FLAC__metadata_simple_iterator_init,
-//GO(FLAC__metadata_simple_iterator_insert_block_after,
-//GO(FLAC__metadata_simple_iterator_is_last,
+GO(FLAC__metadata_simple_iterator_delete, vFp)
+GO(FLAC__metadata_simple_iterator_delete_block, iFpi)
+GO(FLAC__metadata_simple_iterator_get_application_id, iFpp)
+GO(FLAC__metadata_simple_iterator_get_block, pFp)
+GO(FLAC__metadata_simple_iterator_get_block_length, uFp)
+GO(FLAC__metadata_simple_iterator_get_block_offset, lFp)
+GO(FLAC__metadata_simple_iterator_get_block_type, uFp)
+GO(FLAC__metadata_simple_iterator_init, iFppii)
+GO(FLAC__metadata_simple_iterator_insert_block_after, iFppi)
+GO(FLAC__metadata_simple_iterator_is_last, iFp)
//GO(FLAC__metadata_simple_iterator_is_writable,
-//GO(FLAC__metadata_simple_iterator_new,
+GO(FLAC__metadata_simple_iterator_new, pFv)
//GO(FLAC__metadata_simple_iterator_next,
-//GO(FLAC__metadata_simple_iterator_prev,
+GO(FLAC__metadata_simple_iterator_prev, iFp)
//GO(FLAC__metadata_simple_iterator_set_block,
-//GO(FLAC__metadata_simple_iterator_status,
+GO(FLAC__metadata_simple_iterator_status, uFp)
//DATA(FLAC__Metadata_SimpleIteratorStatusString,
//DATA(FLAC__MetadataTypeString,
GO(FLAC__stream_decoder_delete, vFp)
@@ -115,22 +115,22 @@ DATA(FLAC__StreamDecoderErrorStatusString, sizeof(void*))
GO(FLAC__stream_decoder_finish, iFp)
GO(FLAC__stream_decoder_flush, iFp)
//GO(FLAC__stream_decoder_get_bits_per_sample,
-//GO(FLAC__stream_decoder_get_blocksize,
-//GO(FLAC__stream_decoder_get_channel_assignment,
+GO(FLAC__stream_decoder_get_blocksize, uFp)
+GO(FLAC__stream_decoder_get_channel_assignment, uFp)
//GO(FLAC__stream_decoder_get_channels,
GO(FLAC__stream_decoder_get_decode_position, iFpp)
-//GO(FLAC__stream_decoder_get_md5_checking,
+GO(FLAC__stream_decoder_get_md5_checking, iFp)
GO(FLAC__stream_decoder_get_resolved_state_string, pFp)
//GO(FLAC__stream_decoder_get_sample_rate,
-GO(FLAC__stream_decoder_get_state, iFp)
-//GO(FLAC__stream_decoder_get_total_samples,
+GO(FLAC__stream_decoder_get_state, uFp)
+GO(FLAC__stream_decoder_get_total_samples, LFp)
//GO(FLAC__stream_decoder_init_file,
//GO(FLAC__stream_decoder_init_FILE,
//GO(FLAC__stream_decoder_init_ogg_file,
//GO(FLAC__stream_decoder_init_ogg_FILE,
//GO(FLAC__stream_decoder_init_ogg_stream,
//DATA(FLAC__StreamDecoderInitStatusString,
-GOM(FLAC__stream_decoder_init_stream, iFEppppppppp)
+GOM(FLAC__stream_decoder_init_stream, iFEpppppppppp)
//DATA(FLAC__StreamDecoderLengthStatusString,
GO(FLAC__stream_decoder_new, pFv)
GO(FLAC__stream_decoder_process_single, iFp)
@@ -138,25 +138,25 @@ GO(FLAC__stream_decoder_process_until_end_of_metadata, iFp)
GO(FLAC__stream_decoder_process_until_end_of_stream, iFp)
//DATA(FLAC__StreamDecoderReadStatusString,
GO(FLAC__stream_decoder_reset, iFp)
-GO(FLAC__stream_decoder_seek_absolute, iFpU)
+GO(FLAC__stream_decoder_seek_absolute, iFpL)
//DATA(FLAC__StreamDecoderSeekStatusString,
-//GO(FLAC__stream_decoder_set_md5_checking,
-//GO(FLAC__stream_decoder_set_metadata_ignore,
+GO(FLAC__stream_decoder_set_md5_checking, iFpi)
+GO(FLAC__stream_decoder_set_metadata_ignore, iFpu)
GO(FLAC__stream_decoder_set_metadata_ignore_all, iFp)
-//GO(FLAC__stream_decoder_set_metadata_ignore_application,
+GO(FLAC__stream_decoder_set_metadata_ignore_application, iFpp)
//GO(FLAC__stream_decoder_set_metadata_respond,
//GO(FLAC__stream_decoder_set_metadata_respond_all,
//GO(FLAC__stream_decoder_set_metadata_respond_application,
-//GO(FLAC__stream_decoder_set_ogg_serial_number,
-//GO(FLAC__stream_decoder_skip_single_frame,
+GO(FLAC__stream_decoder_set_ogg_serial_number, iFpl)
+GO(FLAC__stream_decoder_skip_single_frame, iFp)
//DATA(FLAC__StreamDecoderStateString,
//DATA(FLAC__StreamDecoderTellStatusString,
//DATA(FLAC__StreamDecoderWriteStatusString,
-//GO(FLAC__stream_encoder_delete,
+GO(FLAC__stream_encoder_delete, vFp)
//GO(FLAC__stream_encoder_disable_constant_subframes,
//GO(FLAC__stream_encoder_disable_fixed_subframes,
//GO(FLAC__stream_encoder_disable_verbatim_subframes,
-//GO(FLAC__stream_encoder_finish,
+GO(FLAC__stream_encoder_finish, iFp)
//GO(FLAC__stream_encoder_get_bits_per_sample,
//GO(FLAC__stream_encoder_get_blocksize,
//GO(FLAC__stream_encoder_get_channels,
@@ -170,15 +170,15 @@ GO(FLAC__stream_decoder_set_metadata_ignore_all, iFp)
//GO(FLAC__stream_encoder_get_max_residual_partition_order,
//GO(FLAC__stream_encoder_get_min_residual_partition_order,
//GO(FLAC__stream_encoder_get_qlp_coeff_precision,
-//GO(FLAC__stream_encoder_get_resolved_state_string,
-//GO(FLAC__stream_encoder_get_rice_parameter_search_dist,
+GO(FLAC__stream_encoder_get_resolved_state_string, pFp)
+GO(FLAC__stream_encoder_get_rice_parameter_search_dist, uFp)
//GO(FLAC__stream_encoder_get_sample_rate,
-//GO(FLAC__stream_encoder_get_state,
+GO(FLAC__stream_encoder_get_state, uFp)
//GO(FLAC__stream_encoder_get_streamable_subset,
-//GO(FLAC__stream_encoder_get_total_samples_estimate,
+GO(FLAC__stream_encoder_get_total_samples_estimate, LFp)
//GO(FLAC__stream_encoder_get_verify,
-//GO(FLAC__stream_encoder_get_verify_decoder_error_stats,
-//GO(FLAC__stream_encoder_get_verify_decoder_state,
+GO(FLAC__stream_encoder_get_verify_decoder_error_stats, vFppppppp)
+GO(FLAC__stream_encoder_get_verify_decoder_state, uFp)
//GO(FLAC__stream_encoder_init_file,
//GO(FLAC__stream_encoder_init_FILE,
//GO(FLAC__stream_encoder_init_ogg_file,
@@ -186,12 +186,12 @@ GO(FLAC__stream_decoder_set_metadata_ignore_all, iFp)
//GO(FLAC__stream_encoder_init_ogg_stream,
//DATA(FLAC__StreamEncoderInitStatusString,
//GO(FLAC__stream_encoder_init_stream,
-//GO(FLAC__stream_encoder_new,
-//GO(FLAC__stream_encoder_process,
-//GO(FLAC__stream_encoder_process_interleaved,
+GO(FLAC__stream_encoder_new, pFv)
+GO(FLAC__stream_encoder_process, iFppu)
+GO(FLAC__stream_encoder_process_interleaved, iFppu)
//DATA(FLAC__StreamEncoderReadStatusString,
//DATA(FLAC__StreamEncoderSeekStatusString,
-//GO(FLAC__stream_encoder_set_apodization,
+GO(FLAC__stream_encoder_set_apodization, iFpp)
//GO(FLAC__stream_encoder_set_bits_per_sample,
//GO(FLAC__stream_encoder_set_blocksize,
//GO(FLAC__stream_encoder_set_channels,
@@ -204,14 +204,14 @@ GO(FLAC__stream_decoder_set_metadata_ignore_all, iFp)
//GO(FLAC__stream_encoder_set_loose_mid_side_stereo,
//GO(FLAC__stream_encoder_set_max_lpc_order,
//GO(FLAC__stream_encoder_set_max_residual_partition_order,
-//GO(FLAC__stream_encoder_set_metadata,
+GO(FLAC__stream_encoder_set_metadata, iFppu)
//GO(FLAC__stream_encoder_set_min_residual_partition_order,
-//GO(FLAC__stream_encoder_set_ogg_serial_number,
+GO(FLAC__stream_encoder_set_ogg_serial_number, iFpl)
//GO(FLAC__stream_encoder_set_qlp_coeff_precision,
-//GO(FLAC__stream_encoder_set_rice_parameter_search_dist,
+GO(FLAC__stream_encoder_set_rice_parameter_search_dist, iFpu)
//GO(FLAC__stream_encoder_set_sample_rate,
//GO(FLAC__stream_encoder_set_streamable_subset,
-//GO(FLAC__stream_encoder_set_total_samples_estimate,
+GO(FLAC__stream_encoder_set_total_samples_estimate, iFpL)
//GO(FLAC__stream_encoder_set_verify,
//DATA(FLAC__StreamEncoderStateString,
//DATA(FLAC__StreamEncoderTellStatusString,
diff --git a/src/wrapped/wrappedfontconfig.c b/src/wrapped/wrappedfontconfig.c
index b56e41c..b56e41c 100755..100644
--- a/src/wrapped/wrappedfontconfig.c
+++ b/src/wrapped/wrappedfontconfig.c
diff --git a/src/wrapped/wrappedfontconfig_private.h b/src/wrapped/wrappedfontconfig_private.h
index bd61dfb..055db1b 100755..100644
--- a/src/wrapped/wrappedfontconfig_private.h
+++ b/src/wrapped/wrappedfontconfig_private.h
@@ -7,126 +7,126 @@ GO(FcAtomicDeleteNew, vFp)
GO(FcAtomicDestroy, vFp)
GO(FcAtomicLock, iFp)
//GO(FcAtomicNewFile,
-//GO(FcAtomicOrigFile,
-//GO(FcAtomicReplaceOrig,
+GO(FcAtomicOrigFile, pFp)
+GO(FcAtomicReplaceOrig, iFp)
//GO(FcAtomicUnlock,
//GO(FcBlanksAdd,
-//GO(FcBlanksCreate,
-//GO(FcBlanksDestroy,
-//GO(FcBlanksIsMember,
+GO(FcBlanksCreate, pFv)
+GO(FcBlanksDestroy, vFp)
+GO(FcBlanksIsMember, iFpu)
GO(FcCacheCopySet, pFp)
-//GO(FcCacheDir,
-//GO(FcCacheNumFont,
+GO(FcCacheDir, pFp)
+GO(FcCacheNumFont, iFp)
GO(FcCacheNumSubdir, iFp)
GO(FcCacheSubdir, pFpi)
GO(FcCharSetAddChar, iFpu)
GO(FcCharSetCopy, pFp)
-//GO(FcCharSetCount,
-//GO(FcCharSetCoverage,
+GO(FcCharSetCount, uFp)
+GO(FcCharSetCoverage, uFpup)
GO(FcCharSetCreate, pFv)
GO(FcCharSetDestroy, vFp)
//GO(FcCharSetEqual,
GO(FcCharSetFirstPage, iFppp) // second p is a fixed sized array
-GO(FcCharSetHasChar, iFpi)
+GO(FcCharSetHasChar, iFpu)
//GO(FcCharSetIntersect,
//GO(FcCharSetIntersectCount,
-//GO(FcCharSetIsSubset,
-//GO(FcCharSetMerge,
-//GO(FcCharSetNew,
-GO(FcCharSetNextPage, iFppp) // second p is a fixed sized array
+GO(FcCharSetIsSubset, iFpp)
+GO(FcCharSetMerge, iFppp)
+GO(FcCharSetNew, pFv)
+GO(FcCharSetNextPage, uFppp)
GO(FcCharSetSubtract, pFpp)
-//GO(FcCharSetSubtractCount,
+GO(FcCharSetSubtractCount, uFpp)
GO(FcCharSetUnion, pFpp)
GO(FcConfigAppFontAddDir, iFpp)
GO(FcConfigAppFontAddFile, iFpp)
GO(FcConfigAppFontClear, vFp)
-//GO(FcConfigBuildFonts,
+GO(FcConfigBuildFonts, iFp)
//GO(FcConfigCreate,
GO(FcConfigDestroy, vFp)
-//GO(FcConfigEnableHome,
+GO(FcConfigEnableHome, iFi)
//GO(FcConfigFilename,
GO(FcConfigGetBlanks, pFp)
-//GO(FcConfigGetCache,
-//GO(FcConfigGetCacheDirs,
+GO(FcConfigGetCache, pFp)
+GO(FcConfigGetCacheDirs, pFp)
//GO(FcConfigGetConfigDirs,
//GO(FcConfigGetConfigFiles,
GO(FcConfigGetCurrent, pFv)
GO(FcConfigGetFontDirs, pFp)
-GO(FcConfigGetFonts, pFpi)
-//GO(FcConfigGetRescanInterval,
+GO(FcConfigGetFonts, pFpu)
+GO(FcConfigGetRescanInterval, iFp)
//GO(FcConfigGetRescanInverval,
GO(FcConfigGetSysRoot, pFp)
-//GO(FcConfigHome,
+GO(FcConfigHome, pFv)
//GO(FcConfigParseAndLoad,
GO(FcConfigReference, pFp)
//GO(FcConfigSetCurrent,
-//GO(FcConfigSetRescanInterval,
+GO(FcConfigSetRescanInterval, iFpi)
//GO(FcConfigSetRescanInverval,
-GO(FcConfigSubstitute, iFppi)
-GO(FcConfigSubstituteWithPat, iFpppi)
+GO(FcConfigSubstitute, iFppu)
+GO(FcConfigSubstituteWithPat, iFpppu)
//GO(FcConfigUptoDate,
GO(FcDefaultSubstitute, vFp)
-//GO(FcDirCacheLoad,
-//GO(FcDirCacheLoadFile,
+GO(FcDirCacheLoad, pFppp)
+GO(FcDirCacheLoadFile, pFpp)
GO(FcDirCacheRead, pFpip)
//GO(FcDirCacheUnlink,
GO(FcDirCacheUnload, vFp)
//GO(FcDirCacheValid,
-//GO(FcDirSave,
-//GO(FcDirScan,
-//GO(FcFileIsDir,
+GO(FcDirSave, iFppp)
+GO(FcDirScan, iFpppppi)
+GO(FcFileIsDir, iFp)
//GO(FcFileScan,
-//GO(FcFini,
+GO(FcFini, vFv)
GO(FcFontList, pFppp)
GO(FcFontMatch, pFppp)
GO(FcFontRenderPrepare, pFppp)
GO(FcFontSetAdd, iFpp)
GO(FcFontSetCreate, pFv)
GO(FcFontSetDestroy, vFp)
-//GO(FcFontSetList,
-//GO(FcFontSetMatch,
-//GO(FcFontSetPrint,
-//GO(FcFontSetSort,
-//GO(FcFontSetSortDestroy,
+GO(FcFontSetList, pFppipp)
+GO(FcFontSetMatch, pFppipp)
+GO(FcFontSetPrint, vFp)
+GO(FcFontSetSort, pFppipipp)
+GO(FcFontSetSortDestroy, vFp)
GO(FcFontSort, pFppipp)
//GO(FcFreeTypeCharIndex,
//GO(FcFreeTypeCharSet,
//GO(FcFreeTypeCharSetAndSpacing,
-GO(FcFreeTypeQuery, pFpipp)
+GO(FcFreeTypeQuery, pFpupp)
GO(FcFreeTypeQueryFace, pFppip)
//GO(FcGetLangs,
GO(FcGetVersion, iFv)
GO(FcInit, iFv)
-//GO(FcInitBringUptoDate,
+GO(FcInitBringUptoDate, iFv)
//GO(FcInitLoadConfig,
-//GO(FcInitLoadConfigAndFonts,
+GO(FcInitLoadConfigAndFonts, pFv)
GO(FcInitReinitialize, iFv)
-//GO(FcLangGetCharSet,
+GO(FcLangGetCharSet, pFp)
GO(FcLangSetAdd, iFpp)
-//GO(FcLangSetCompare,
+GO(FcLangSetCompare, uFpp)
//GO(FcLangSetContains,
-//GO(FcLangSetCopy,
+GO(FcLangSetCopy, pFp)
GO(FcLangSetCreate, pFv)
GO(FcLangSetDestroy, vFp)
-//GO(FcLangSetEqual,
-//GO(FcLangSetGetLangs,
-//GO(FcLangSetHash,
-GO(FcLangSetHasLang, iFpp)
-//GO(FcMatrixCopy,
-//GO(FcMatrixEqual,
-//GO(FcMatrixMultiply,
+GO(FcLangSetEqual, iFpp)
+GO(FcLangSetGetLangs, pFp)
+GO(FcLangSetHash, uFp)
+GO(FcLangSetHasLang, uFpp)
+GO(FcMatrixCopy, pFp)
+GO(FcMatrixEqual, iFpp)
+GO(FcMatrixMultiply, vFppp)
//GO(FcMatrixRotate,
//GO(FcMatrixScale,
-//GO(FcMatrixShear,
+GO(FcMatrixShear, vFpdd)
GO(FcNameConstant, iFpp)
-//GO(FcNameGetConstant,
-//GO(FcNameGetObjectType,
-//GO(FcNameParse,
+GO(FcNameGetConstant, pFp)
+GO(FcNameGetObjectType, pFp)
+GO(FcNameParse, pFp)
//GO(FcNameRegisterConstants,
//GO(FcNameRegisterObjectTypes,
-//GO(FcNameUnparse,
-//GO(FcNameUnregisterConstants,
-//GO(FcNameUnregisterObjectTypes,
+GO(FcNameUnparse, pFp)
+GO(FcNameUnregisterConstants, iFpi)
+GO(FcNameUnregisterObjectTypes, iFpi)
GO(FcObjectSetAdd, iFpp)
GOM(FcObjectSetBuild, pFEpV)
GO(FcObjectSetCreate, pFv)
@@ -148,21 +148,21 @@ GO(FcPatternDel, iFpp)
GO(FcPatternDestroy, vFp)
GO(FcPatternDuplicate, pFp)
GO(FcPatternEqual, iFpp)
-//GO(FcPatternEqualSubset,
-//GO(FcPatternFilter,
-//GO(FcPatternFormat,
-GO(FcPatternGet, iFppip)
-GO(FcPatternGetBool, iFppip)
-GO(FcPatternGetCharSet, iFppip)
-GO(FcPatternGetDouble, iFppip)
+GO(FcPatternEqualSubset, iFppp)
+GO(FcPatternFilter, pFpp)
+GO(FcPatternFormat, pFpp)
+GO(FcPatternGet, uFppip)
+GO(FcPatternGetBool, uFppip)
+GO(FcPatternGetCharSet, uFppip)
+GO(FcPatternGetDouble, uFppip)
GO(FcPatternGetFTFace, iFppip)
-GO(FcPatternGetInteger, iFppip)
-GO(FcPatternGetLangSet, iFppip)
-GO(FcPatternGetMatrix, iFppip)
-GO(FcPatternGetString, iFppip)
-GO(FcPatternHash, iFp)
-//GO(FcPatternPrint,
-//GO(FcPatternReference,
+GO(FcPatternGetInteger, uFppip)
+GO(FcPatternGetLangSet, uFppip)
+GO(FcPatternGetMatrix, uFppip)
+GO(FcPatternGetString, uFppip)
+GO(FcPatternHash, uFp)
+GO(FcPatternPrint, vFp)
+GO(FcPatternReference, vFp)
//GO(FcPatternRemove,
GO(FcPatternVaBuild, pFpp)
GO(FcStrBasename, pFp)
@@ -188,8 +188,8 @@ GO(FcStrSetMember, iFpp)
GO(FcStrStr, pFpp)
GO(FcStrStrIgnoreCase, pFpp)
GO(FcUcs4ToUtf8, iFup)
-GO(FcUtf16Len, iFpipp)
-GO(FcUtf16ToUcs4, iFpipi)
+GO(FcUtf16Len, iFpuipp)
+GO(FcUtf16ToUcs4, iFpupi)
GO(FcUtf8Len, iFpipp)
GO(FcUtf8ToUcs4, iFppi)
//GO(FcValueDestroy,
diff --git a/src/wrapped/wrappedfreetype.c b/src/wrapped/wrappedfreetype.c
index aacad27..4ced9be 100755..100644
--- a/src/wrapped/wrappedfreetype.c
+++ b/src/wrapped/wrappedfreetype.c
@@ -133,10 +133,10 @@ GO(4)
// FT_Generic_Finalizer
#define GO(A) \
-static uintptr_t my_FT_Generic_Finalizer_fct_##A = 0; \
-static void my_FT_Generic_Finalizer_##A(void* object) \
-{ \
- RunFunction(my_context, my_FT_Generic_Finalizer_fct_##A, 1, object); \
+static uintptr_t my_FT_Generic_Finalizer_fct_##A = 0; \
+static void my_FT_Generic_Finalizer_##A(void* object) \
+{ \
+ RunFunctionFmt(my_FT_Generic_Finalizer_fct_##A, "p", object); \
}
SUPER()
#undef GO
@@ -156,15 +156,15 @@ static void* find_FT_Generic_Finalizer_Fct(void* fct)
}
// FTC_Face_Requester
#define GO(A) \
-static uintptr_t my_FTC_Face_Requester_fct_##A = 0; \
-static int my_FTC_Face_Requester_##A(void* face_id, void* lib, void* req, void* aface) \
-{ \
- int ret = (int)RunFunction(my_context, my_FTC_Face_Requester_fct_##A, 4, face_id, lib, req, aface); \
- if(aface && *(void**)aface) { \
- FT_FaceRec_t *f = *(FT_FaceRec_t**)aface; \
- f->generic.finalizer = find_FT_Generic_Finalizer_Fct(f->generic.finalizer); \
- } \
- return ret; \
+static uintptr_t my_FTC_Face_Requester_fct_##A = 0; \
+static int my_FTC_Face_Requester_##A(void* face_id, void* lib, void* req, void* aface) \
+{ \
+ int ret = (int)RunFunctionFmt(my_FTC_Face_Requester_fct_##A, "pppp", face_id, lib, req, aface); \
+ if(aface && *(void**)aface) { \
+ FT_FaceRec_t *f = *(FT_FaceRec_t**)aface; \
+ f->generic.finalizer = find_FT_Generic_Finalizer_Fct(f->generic.finalizer); \
+ } \
+ return ret; \
}
SUPER()
#undef GO
@@ -184,10 +184,10 @@ static void* find_FTC_Face_Requester_Fct(void* fct)
}
// FT_Alloc
#define GO(A) \
-static uintptr_t my_FT_Alloc_fct_##A = 0; \
-static void* my_FT_Alloc_##A(void* memory, long size) \
-{ \
- return (void*)RunFunction(my_context, my_FT_Alloc_fct_##A, 2, memory, size);\
+static uintptr_t my_FT_Alloc_fct_##A = 0; \
+static void* my_FT_Alloc_##A(void* memory, long size) \
+{ \
+ return (void*)RunFunctionFmt(my_FT_Alloc_fct_##A, "pl", memory, size); \
}
SUPER()
#undef GO
@@ -207,10 +207,10 @@ static void* find_FT_Alloc_Fct(void* fct)
}
// FT_Free
#define GO(A) \
-static uintptr_t my_FT_Free_fct_##A = 0; \
-static void my_FT_Free_##A(void* memory, void* p) \
-{ \
- RunFunction(my_context, my_FT_Free_fct_##A, 2, memory, p); \
+static uintptr_t my_FT_Free_fct_##A = 0; \
+static void my_FT_Free_##A(void* memory, void* p) \
+{ \
+ RunFunctionFmt(my_FT_Free_fct_##A, "pp", memory, p); \
}
SUPER()
#undef GO
@@ -230,10 +230,10 @@ static void* find_FT_Free_Fct(void* fct)
}
// FT_Realloc
#define GO(A) \
-static uintptr_t my_FT_Realloc_fct_##A = 0; \
-static void* my_FT_Realloc_##A(void* memory, long cur, long size, void* p) \
-{ \
- return (void*)RunFunction(my_context, my_FT_Realloc_fct_##A, 4, memory, cur, size, p); \
+static uintptr_t my_FT_Realloc_fct_##A = 0; \
+static void* my_FT_Realloc_##A(void* memory, long cur, long size, void* p) \
+{ \
+ return (void*)RunFunctionFmt(my_FT_Realloc_fct_##A, "pllp", memory, cur, size, p); \
}
SUPER()
#undef GO
@@ -253,10 +253,10 @@ static void* find_FT_Realloc_Fct(void* fct)
}
// FT_Outline_MoveToFunc
#define GO(A) \
-static uintptr_t my_FT_Outline_MoveToFunc_fct_##A = 0; \
-static int my_FT_Outline_MoveToFunc_##A(void* to, void* user) \
-{ \
- return (int)RunFunction(my_context, my_FT_Outline_MoveToFunc_fct_##A, 2, to, user); \
+static uintptr_t my_FT_Outline_MoveToFunc_fct_##A = 0; \
+static int my_FT_Outline_MoveToFunc_##A(void* to, void* user) \
+{ \
+ return (int)RunFunctionFmt(my_FT_Outline_MoveToFunc_fct_##A, "pp", to, user); \
}
SUPER()
#undef GO
@@ -277,10 +277,10 @@ static void* find_FT_Outline_MoveToFunc_Fct(void* fct)
// FT_Outline_LineToFunc
#define GO(A) \
-static uintptr_t my_FT_Outline_LineToFunc_fct_##A = 0; \
-static int my_FT_Outline_LineToFunc_##A(void* to, void* user) \
-{ \
- return (int)RunFunction(my_context, my_FT_Outline_LineToFunc_fct_##A, 2, to, user); \
+static uintptr_t my_FT_Outline_LineToFunc_fct_##A = 0; \
+static int my_FT_Outline_LineToFunc_##A(void* to, void* user) \
+{ \
+ return (int)RunFunctionFmt(my_FT_Outline_LineToFunc_fct_##A, "pp", to, user); \
}
SUPER()
#undef GO
@@ -301,10 +301,10 @@ static void* find_FT_Outline_LineToFunc_Fct(void* fct)
// FT_Outline_ConicToFunc
#define GO(A) \
-static uintptr_t my_FT_Outline_ConicToFunc_fct_##A = 0; \
-static int my_FT_Outline_ConicToFunc_##A(void* ctl, void* to, void* user) \
-{ \
- return (int)RunFunction(my_context, my_FT_Outline_ConicToFunc_fct_##A, 3, ctl, to, user); \
+static uintptr_t my_FT_Outline_ConicToFunc_fct_##A = 0; \
+static int my_FT_Outline_ConicToFunc_##A(void* ctl, void* to, void* user) \
+{ \
+ return (int)RunFunctionFmt(my_FT_Outline_ConicToFunc_fct_##A, "ppp", ctl, to, user); \
}
SUPER()
#undef GO
@@ -325,10 +325,10 @@ static void* find_FT_Outline_ConicToFunc_Fct(void* fct)
// FT_Outline_CubicToFunc
#define GO(A) \
-static uintptr_t my_FT_Outline_CubicToFunc_fct_##A = 0; \
-static int my_FT_Outline_CubicToFunc_##A(void* ctl1, void* ctl2, void* to, void* user) \
-{ \
- return (int)RunFunction(my_context, my_FT_Outline_CubicToFunc_fct_##A, 4, ctl1, ctl2, to, user); \
+static uintptr_t my_FT_Outline_CubicToFunc_fct_##A = 0; \
+static int my_FT_Outline_CubicToFunc_##A(void* ctl1, void* ctl2, void* to, void* user) \
+{ \
+ return (int)RunFunctionFmt(my_FT_Outline_CubicToFunc_fct_##A, "pppp", ctl1, ctl2, to, user); \
}
SUPER()
#undef GO
@@ -378,13 +378,13 @@ static FT_MemoryRec_t* find_FT_MemoryRec_Struct(FT_MemoryRec_t* s)
static uintptr_t my_iofunc = 0;
static unsigned long my_FT_Stream_IoFunc(FT_StreamRec_t* stream, unsigned long offset, unsigned char* buffer, unsigned long count )
{
- return (unsigned long)RunFunction(my_context, my_iofunc, 4, stream, offset, buffer, count);
+ return (unsigned long)RunFunctionFmt(my_iofunc, "pLpL", stream, offset, buffer, count) ;
}
static uintptr_t my_closefunc = 0;
static void my_FT_Stream_CloseFunc(FT_StreamRec_t* stream)
{
- RunFunction(my_context, my_closefunc, 1, stream);
+ RunFunctionFmt(my_closefunc, "p", stream) ;
}
EXPORT int my_FT_Open_Face(x64emu_t* emu, void* library, FT_Open_Args_t* args, long face_index, void* aface)
diff --git a/src/wrapped/wrappedfreetype_private.h b/src/wrapped/wrappedfreetype_private.h
index c7c854e..4095693 100755..100644
--- a/src/wrapped/wrappedfreetype_private.h
+++ b/src/wrapped/wrappedfreetype_private.h
@@ -19,27 +19,32 @@ GO(FT_Bitmap_New, vFp)
//GO(FT_ClassicKern_Free,
//GO(FT_ClassicKern_Validate,
GO(FT_Cos, lFl)
-//GO(FT_DivFix,
+GO(FT_DivFix, lFll)
GO(FT_Done_Face, iFp)
GO(FT_Done_FreeType, iFp)
GO(FT_Done_Glyph, vFp)
GO(FT_Done_Library, iFp)
+GO(FT_Done_MM_Var, iFpp)
GO(FT_Done_Size, iFp)
//GO(FT_Face_CheckTrueTypePatents,
//GO(FT_Face_GetCharsOfVariant,
-//GO(FT_Face_GetCharVariantIndex,
+GO(FT_Face_GetCharVariantIndex, uFpuu)
//GO(FT_Face_GetCharVariantIsDefault,
//GO(FT_Face_GetVariantSelectors,
//GO(FT_Face_GetVariantsOfChar,
GO(FT_Face_Properties, iFpup)
//GO(FT_Face_SetUnpatentedHinting,
-//GO(FT_FloorFix,
+GO(FT_FloorFix, lFl)
GO(FT_Get_Advance, iFpiup)
GO(FT_Get_Advances, iFpuuip)
//GO(FT_Get_BDF_Charset_ID,
//GO(FT_Get_BDF_Property,
GO(FT_Get_Char_Index, uFpL)
GO(FT_Get_Charmap_Index, iFp)
+GO(FT_Get_Color_Glyph_Layer, iFpupp)
+GO(FT_Get_Color_Glyph_Paint, iFpuip)
+GO(FT_Get_Color_Glyph_ClipBox, iFpup)
+GO(FT_Get_Colorline_Stops, iFppp)
//GO(FT_Get_CID_From_Glyph_Index,
//GO(FT_Get_CID_Is_Internally_CID_Keyed,
//GO(FT_Get_CID_Registry_Ordering_Supplement,
@@ -54,10 +59,12 @@ GO(FT_Get_Glyph_Name, iFpupu)
GO(FT_Get_Kerning, iFpuuup)
//GO(FT_Get_MM_Blend_Coordinates,
GO(FT_Get_MM_Var, iFpp)
-//GO(FT_Get_Module,
+GO(FT_Get_Module, pFpp)
//GO(FT_Get_Multi_Master,
GO(FT_Get_Name_Index, uFpp)
GO(FT_Get_Next_Char, LFpLp)
+GO(FT_Get_Paint, iFppip) // FT_OpaquePaint is a struct with "pi"
+GO(FT_Get_Paint_Layers, iFppp)
//GO(FT_Get_PFR_Advance,
//GO(FT_Get_PFR_Kerning,
//GO(FT_Get_PFR_Metrics,
@@ -65,15 +72,16 @@ GO(FT_Get_Postscript_Name, pFp)
GO(FT_Get_PS_Font_Info, iFpp)
//GO(FT_Get_PS_Font_Private,
//GO(FT_Get_PS_Font_Value,
-//GO(FT_Get_Renderer,
+GO(FT_Get_Renderer, pFpu)
//GO(FT_Get_Sfnt_LangTag,
GO(FT_Get_Sfnt_Name, iFpip)
GO(FT_Get_Sfnt_Name_Count, uFp)
GO(FT_Get_Sfnt_Table, pFpi)
GO(FT_Get_SubGlyph_Info, iFpuppppp)
GO(FT_Get_Track_Kerning, iFplip)
-GO(FT_Get_TrueType_Engine_Type, iFp)
-//GO(FT_Get_Var_Blend_Coordinates,
+GO(FT_Get_Transform, vFppp)
+GO(FT_Get_TrueType_Engine_Type, uFp)
+GO(FT_Get_Var_Blend_Coordinates, iFpup)
//GO(FT_Get_Var_Design_Coordinates,
GO(FT_Get_WinFNT_Header, iFpp) // does FT_WinFNT_HeaderRec_ needs alignment?
GO(FT_Get_X11_Font_Format, pFp)
@@ -82,23 +90,23 @@ GO(FT_Glyph_Get_CBox, vFpup)
GO(FT_GlyphSlot_Embolden, vFp)
GO(FT_GlyphSlot_Oblique, vFp)
GO(FT_GlyphSlot_Own_Bitmap, iFp)
-GO(FT_Glyph_Stroke, iFppi)
+GO(FT_Glyph_Stroke, iFppC)
GO(FT_Glyph_StrokeBorder, iFppCC)
-GO(FT_Glyph_To_Bitmap, iFpipC)
+GO(FT_Glyph_To_Bitmap, iFpupC)
GO(FT_Glyph_Transform, iFppp)
//GO(FT_Gzip_Uncompress,
//GO(FT_Has_PS_Glyph_Names,
GO(FT_Init_FreeType, iFp)
-GO(FT_Library_SetLcdFilter, iFpi)
+GO(FT_Library_SetLcdFilter, iFpu)
GO(FT_Library_SetLcdFilterWeights, iFpp)
GO(FT_Library_Version, vFpppp)
//GO(FT_List_Add,
//GO(FT_List_Finalize,
-//GO(FT_List_Find,
+GO(FT_List_Find, pFpp)
//GO(FT_List_Insert,
//GO(FT_List_Iterate,
//GO(FT_List_Remove,
-//GO(FT_List_Up,
+GO(FT_List_Up, vFpp)
GO(FT_Load_Char, iFpLi)
GO(FT_Load_Glyph, iFpui)
GO(FT_Load_Sfnt_Table, iFpLlpp)
@@ -124,20 +132,21 @@ GO(FT_Outline_Get_BBox, iFpp)
GO(FT_Outline_Get_Bitmap, iFppp)
GO(FT_Outline_Get_CBox, vFpp)
//GO(FT_Outline_GetInsideBorder,
-//GO(FT_Outline_Get_Orientation,
-//GO(FT_Outline_GetOutsideBorder,
+GO(FT_Outline_Get_Orientation, uFp)
+GO(FT_Outline_GetOutsideBorder, uFp)
GO(FT_Outline_New, iFpuip)
//GO(FT_Outline_New_Internal,
GO(FT_Outline_Render, iFppp)
GO(FT_Outline_Reverse, vFp)
GO(FT_Outline_Transform, vFpp)
GO(FT_Outline_Translate, vFpll)
+GO(FT_Palette_Select, iFpWp)
GO(FT_Property_Get, iFpppp)
GO(FT_Property_Set, iFpppp)
GO(FT_Reference_Face, iFp)
//GO(FT_Reference_Library,
-//GO(FT_Remove_Module,
-GO(FT_Render_Glyph, iFpi)
+GO(FT_Remove_Module, iFpp)
+GO(FT_Render_Glyph, iFpu)
GO(FT_Request_Size, iFpp)
//GO(FT_RoundFix,
GO(FT_Select_Charmap, iFpi)
@@ -147,13 +156,13 @@ GO(FT_Set_Char_Size, iFplluu)
//GO(FT_Set_Debug_Hook,
//GO(FT_Set_Default_Properties,
//GO(FT_Set_MM_Blend_Coordinates,
-//GO(FT_Set_MM_Design_Coordinates,
+GO(FT_Set_MM_Design_Coordinates, iFpup)
GO(FT_Set_Pixel_Sizes, iFpuu)
-//GO(FT_Set_Renderer,
+GO(FT_Set_Renderer, iFppup)
GO(FT_Set_Transform, vFppp)
//GO(FT_Set_Var_Blend_Coordinates,
-//GO(FT_Set_Var_Design_Coordinates,
-//GO(FT_Sfnt_Table_Info,
+GO(FT_Set_Var_Design_Coordinates, iFpup)
+GO(FT_Sfnt_Table_Info, iFpupp)
GO(FT_Sin, lFl)
//GO(FT_Stream_OpenBzip2,
//GO(FT_Stream_OpenGzip,
@@ -164,14 +173,14 @@ GO(FT_Stroker_CubicTo, iFpppp)
GO(FT_Stroker_Done, vFp)
GO(FT_Stroker_EndSubPath, iFp)
GO(FT_Stroker_Export, vFpp)
-GO(FT_Stroker_ExportBorder, vFpip)
-GO(FT_Stroker_GetBorderCounts, iFpipp)
+GO(FT_Stroker_ExportBorder, vFpup)
+GO(FT_Stroker_GetBorderCounts, iFpupp)
GO(FT_Stroker_GetCounts, iFppp)
GO(FT_Stroker_LineTo, iFpp)
GO(FT_Stroker_New, iFpp)
GO(FT_Stroker_ParseOutline, iFppC)
GO(FT_Stroker_Rewind, vFp)
-GO(FT_Stroker_Set, vFpliil)
+GO(FT_Stroker_Set, vFpluul)
GO(FT_Tan, lFl)
//GO(FT_TrueTypeGX_Free,
//GO(FT_TrueTypeGX_Validate,
diff --git a/src/wrapped/wrappedgconf2.c b/src/wrapped/wrappedgconf2.c
index 59f47d9..ec651e6 100644
--- a/src/wrapped/wrappedgconf2.c
+++ b/src/wrapped/wrappedgconf2.c
@@ -22,10 +22,77 @@
const char* gconf2Name = "libgconf-2.so.4";
#define LIBNAME gconf2
+#include "generated/wrappedgconf2types.h"
+
+#include "wrappercallback.h"
+
+#define SUPER() \
+GO(0) \
+GO(1) \
+GO(2) \
+GO(3)
+
+// GFreeFct
+#define GO(A) \
+static uintptr_t my_GFreeFct_fct_##A = 0; \
+static void my_GFreeFct_##A(void* a) \
+{ \
+ RunFunctionFmt(my_GFreeFct_fct_##A, "p", a); \
+}
+SUPER()
+#undef GO
+static void* findGFreeFctFct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_GFreeFct_fct_##A == (uintptr_t)fct) return my_GFreeFct_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_GFreeFct_fct_##A == 0) {my_GFreeFct_fct_##A = (uintptr_t)fct; return my_GFreeFct_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for gconf2 GFreeFct callback\n");
+ return NULL;
+}
+// GConfClientNotifyFunc
+#define GO(A) \
+static uintptr_t my_GConfClientNotifyFunc_fct_##A = 0; \
+static void my_GConfClientNotifyFunc_##A(void* a, uint32_t b, void* c, void* d) \
+{ \
+ RunFunctionFmt(my_GConfClientNotifyFunc_fct_##A, "pupp", a, b, c, d); \
+}
+SUPER()
+#undef GO
+static void* findGConfClientNotifyFuncFct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_GConfClientNotifyFunc_fct_##A == (uintptr_t)fct) return my_GConfClientNotifyFunc_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_GConfClientNotifyFunc_fct_##A == 0) {my_GConfClientNotifyFunc_fct_##A = (uintptr_t)fct; return my_GConfClientNotifyFunc_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for gconf2 GConfClientNotifyFunc callback\n");
+ return NULL;
+}
+
+#undef SUPER
+
+EXPORT uint32_t my_gconf_client_notify_add(x64emu_t* emu, void* client, void* section, void* f, void* data, void* d, void* error)
+{
+ return my->gconf_client_notify_add(client, section, findGConfClientNotifyFuncFct(f), data, findGFreeFctFct(d), error);
+}
#define PRE_INIT \
if(box64_nogtk) \
return -1;
+#define CUSTOM_INIT \
+ getMy(lib); \
+
+#define CUSTOM_FINI \
+ freeMy();
+
#include "wrappedlib_init.h"
diff --git a/src/wrapped/wrappedgconf2_private.h b/src/wrapped/wrappedgconf2_private.h
index 7b2cbac..b89d684 100644
--- a/src/wrapped/wrappedgconf2_private.h
+++ b/src/wrapped/wrappedgconf2_private.h
@@ -34,7 +34,7 @@
//GO(gconf_change_set_unref,
//GO(gconf_change_set_unset,
//GO(gconf_clear_cache,
-//GO(gconf_client_add_dir,
+GO(gconf_client_add_dir, vFppip)
//GO(gconf_client_all_dirs,
//GO(gconf_client_all_entries,
//GO(gconf_client_change_set_from_current,
@@ -43,29 +43,29 @@
//GO(gconf_client_commit_change_set,
//GO(gconf_client_dir_exists,
//GO(gconf_client_error,
-//GO(gconf_client_error_handling_mode_get_type,
-//GO(gconf_client_get,
+GO(gconf_client_error_handling_mode_get_type, LFv)
+GO(gconf_client_get, pFppp)
//GO(gconf_client_get_bool,
-//GO(gconf_client_get_default,
+GO(gconf_client_get_default, pFv)
//GO(gconf_client_get_default_from_schema,
//GO(gconf_client_get_entry,
//GO(gconf_client_get_float,
//GO(gconf_client_get_for_engine,
-//GO(gconf_client_get_int,
-//GO(gconf_client_get_list,
+GO(gconf_client_get_int, iFppp)
+GO(gconf_client_get_list, pFppip)
//GO(gconf_client_get_pair,
//GO(gconf_client_get_schema,
-//GO(gconf_client_get_string,
+GO(gconf_client_get_string, pFppp)
//GO(gconf_client_get_type,
//GO(gconf_client_get_without_default,
//GO(gconf_client_key_is_writable,
//GO(gconf_client_notify,
-//GO(gconf_client_notify_add,
-//GO(gconf_client_notify_remove,
+GOM(gconf_client_notify_add, uFEpppppp)
+GO(gconf_client_notify_remove, vFpu)
//GO(gconf_client_preload,
//GO(gconf_client_preload_type_get_type,
//GO(gconf_client_recursive_unset,
-//GO(gconf_client_remove_dir,
+GO(gconf_client_remove_dir, vFppp)
//GO(gconf_client_reverse_change_set,
//GO(gconf_client_set,
//GO(gconf_client_set_bool,
@@ -82,7 +82,7 @@
//GO(gconf_client_unset,
//GO(gconf_client_value_changed,
//GO(gconf_compose_errors,
-//GO(gconf_concat_dir_and_key,
+GO(gconf_concat_dir_and_key, pFpp)
//GO(gconf_current_locale,
//GO(gconf_dbus_utils_append_entries,
//GO(gconf_dbus_utils_append_entry_values,
@@ -90,9 +90,9 @@
//GO(gconf_dbus_utils_get_entries,
//GO(gconf_dbus_utils_get_entry_values,
//GO(gconf_dbus_utils_get_value,
-//GO(gconf_debug_shutdown,
+GO(gconf_debug_shutdown, iFv)
//GO(gconf_double_to_string,
-//GO(gconf_engine_all_dirs,
+GO(gconf_engine_all_dirs, pFppp)
//GO(gconf_engine_all_entries,
//GO(gconf_engine_associate_schema,
//GO(gconf_engine_change_set_from_current,
@@ -100,80 +100,80 @@
//GO(gconf_engine_commit_change_set,
//GO(gconf_engine_dir_exists,
//GO(gconf_engine_get,
-//GO(gconf_engine_get_bool,
-//GO(gconf_engine_get_default,
-//GO(gconf_engine_get_default_from_schema,
-//GO(gconf_engine_get_entry,
-//GO(gconf_engine_get_float,
-//GO(gconf_engine_get_for_address,
-//GO(gconf_engine_get_for_addresses,
+GO(gconf_engine_get_bool, iFppp)
+GO(gconf_engine_get_default, pFv)
+GO(gconf_engine_get_default_from_schema, pFppp)
+GO(gconf_engine_get_entry, pFpppip)
+GO(gconf_engine_get_float, dFppp)
+GO(gconf_engine_get_for_address, pFpp)
+GO(gconf_engine_get_for_addresses, pFpp)
//GO(gconf_engine_get_full,
//GO(gconf_engine_get_fuller,
-//GO(gconf_engine_get_int,
-//GO(gconf_engine_get_list,
+GO(gconf_engine_get_int, iFppp)
+GO(gconf_engine_get_list, pFppup)
//GO(gconf_engine_get_local,
//GO(gconf_engine_get_local_for_addresses,
-//GO(gconf_engine_get_pair,
-//GO(gconf_engine_get_schema,
-//GO(gconf_engine_get_string,
-//GO(gconf_engine_get_user_data,
-//GO(gconf_engine_get_with_locale,
+GO(gconf_engine_get_pair, iFppuuppp)
+GO(gconf_engine_get_schema, pFppp)
+GO(gconf_engine_get_string, pFppp)
+GO(gconf_engine_get_user_data, pFp)
+GO(gconf_engine_get_with_locale, pFpppp)
//GO(gconf_engine_get_without_default,
//GO(gconf_engine_key_is_writable,
//GO(gconf_engine_notify_add,
-//GO(gconf_engine_notify_remove,
+GO(gconf_engine_notify_remove, vFpu)
//GO(gconf_engine_pop_owner_usage,
//GO(gconf_engine_push_owner_usage,
//GO(gconf_engine_recursive_unset,
-//GO(gconf_engine_ref,
-//GO(gconf_engine_remove_dir,
+GO(gconf_engine_ref, vFp)
+GO(gconf_engine_remove_dir, vFppp)
//GO(gconf_engine_reverse_change_set,
-//GO(gconf_engine_set,
-//GO(gconf_engine_set_bool,
-//GO(gconf_engine_set_float,
-//GO(gconf_engine_set_int,
-//GO(gconf_engine_set_list,
+GO(gconf_engine_set, iFpppp)
+GO(gconf_engine_set_bool, iFppip)
+GO(gconf_engine_set_float, iFppdp)
+GO(gconf_engine_set_int, iFppip)
+GO(gconf_engine_set_list, iFppupp)
//GO(gconf_engine_set_owner,
-//GO(gconf_engine_set_pair,
-//GO(gconf_engine_set_schema,
-//GO(gconf_engine_set_string,
+GO(gconf_engine_set_pair, iFppuuppp)
+GO(gconf_engine_set_schema, iFpppp)
+GO(gconf_engine_set_string, iFpppp)
//GO(gconf_engine_set_user_data,
-//GO(gconf_engine_suggest_sync,
+GO(gconf_engine_suggest_sync, vFpp)
//GO(gconf_engine_unref,
//GO(gconf_engine_unset,
-//GO(gconf_entry_copy,
-//GO(gconf_entry_equal,
+GO(gconf_entry_copy, pFp)
+GO(gconf_entry_equal, iFpp)
//GO(gconf_entry_free,
//GO(gconf_entry_get_is_default,
-//GO(gconf_entry_get_is_writable,
-//GO(gconf_entry_get_key,
-//GO(gconf_entry_get_schema_name,
+GO(gconf_entry_get_is_writable, iFp)
+GO(gconf_entry_get_key, pFp)
+GO(gconf_entry_get_schema_name, pFp)
//GO(gconf_entry_get_type,
-//GO(gconf_entry_get_value,
-//GO(gconf_entry_new,
-//GO(gconf_entry_new_nocopy,
-//GO(gconf_entry_ref,
+GO(gconf_entry_get_value, pFp)
+GO(gconf_entry_new, pFpp)
+GO(gconf_entry_new_nocopy, pFpp)
+GO(gconf_entry_ref, pFp)
//GO(gconf_entry_set_is_default,
-//GO(gconf_entry_set_is_writable,
-//GO(gconf_entry_set_schema_name,
-//GO(gconf_entry_set_value,
-//GO(gconf_entry_set_value_nocopy,
-//GO(gconf_entry_steal_value,
-//GO(gconf_entry_unref,
-//GO(gconf_enum_to_string,
+GO(gconf_entry_set_is_writable, vFpi)
+GO(gconf_entry_set_schema_name, vFpp)
+GO(gconf_entry_set_value, vFpp)
+GO(gconf_entry_set_value_nocopy, vFpp)
+GO(gconf_entry_steal_value, pFp)
+GO(gconf_entry_unref, vFp)
+GO(gconf_enum_to_string, pFpi)
//GO(gconf_error_get_type,
//GO(gconf_error_new,
-//GO(gconf_error_quark,
+GO(gconf_error_quark, uFv)
//GO(gconf_escape_key,
//GO(gconf_get_backend,
//GO(gconf_get_daemon_ior,
//GO(gconf_in_daemon_mode,
-//GO(gconf_init,
+GO(gconf_init, iFipp)
//GO(_gconf_init_i18n,
-//GO(gconf_is_initialized,
+GO(gconf_is_initialized, iFv)
//GO(gconf_key_check,
//GO(gconf_key_directory,
-//GO(gconf_key_is_below,
+GO(gconf_key_is_below, iFpp)
//GO(gconf_key_key,
//GO(gconf_listeners_add,
//GO(gconf_listeners_count,
@@ -194,13 +194,13 @@
//GO(gconf_log,
//DATAB(gconf_log_debug_messages,
//GO(gconf_marshal_VOID__STRING_POINTER,
-//GO(gconf_meta_info_free,
-//GO(gconf_meta_info_get_mod_user,
+GO(gconf_meta_info_free, vFp)
+GO(gconf_meta_info_get_mod_user, pFp)
//GO(gconf_meta_info_get_schema,
-//GO(gconf_meta_info_mod_time,
-//GO(gconf_meta_info_new,
-//GO(gconf_meta_info_set_mod_time,
-//GO(gconf_meta_info_set_mod_user,
+GO(gconf_meta_info_mod_time, iFp)
+GO(gconf_meta_info_new, pFv)
+GO(gconf_meta_info_set_mod_time, vFpi)
+GO(gconf_meta_info_set_mod_user, vFpp)
//GO(gconf_meta_info_set_schema,
//DATAB(gconf_options,
//GO(gconf_persistent_name_get_address_list,
@@ -209,28 +209,28 @@
//GO(gconf_preinit,
//GO(gconf_quote_string,
//GO(gconf_resolve_address,
-//GO(gconf_schema_copy,
-//GO(gconf_schema_free,
+GO(gconf_schema_copy, pFp)
+GO(gconf_schema_free, vFp)
//GO(gconf_schema_get_car_type,
-//GO(gconf_schema_get_cdr_type,
-//GO(gconf_schema_get_default_value,
+GO(gconf_schema_get_cdr_type, uFp)
+GO(gconf_schema_get_default_value, pFp)
//GO(gconf_schema_get_gettext_domain,
//GO(gconf_schema_get_list_type,
//GO(gconf_schema_get_locale,
//GO(gconf_schema_get_long_desc,
-//GO(gconf_schema_get_owner,
+GO(gconf_schema_get_owner, pFp)
//GO(gconf_schema_get_short_desc,
//GO(gconf_schema_get_type,
-//GO(gconf_schema_new,
+GO(gconf_schema_new, pFv)
//GO(gconf_schema_set_car_type,
-//GO(gconf_schema_set_cdr_type,
-//GO(gconf_schema_set_default_value,
-//GO(gconf_schema_set_default_value_nocopy,
+GO(gconf_schema_set_cdr_type, vFpu)
+GO(gconf_schema_set_default_value, vFpp)
+GO(gconf_schema_set_default_value_nocopy, vFpp)
//GO(gconf_schema_set_gettext_domain,
//GO(gconf_schema_set_list_type,
//GO(gconf_schema_set_locale,
//GO(gconf_schema_set_long_desc,
-//GO(gconf_schema_set_owner,
+GO(gconf_schema_set_owner, vFpp)
//GO(gconf_schema_set_short_desc,
//GO(gconf_schema_set_type,
//GO(gconf_schema_steal_default_value,
@@ -264,57 +264,57 @@
//GO(gconf_spawn_daemon,
//GO(gconf_split_locale,
//GO(gconf_string_to_double,
-//GO(gconf_string_to_enum,
+GO(gconf_string_to_enum, iFppp)
//GO(gconf_string_to_gulong,
//GO(gconf_synchronous_sync,
-//GO(gconf_unescape_key,
-//GO(gconf_unique_key,
+GO(gconf_unescape_key, pFpi)
+GO(gconf_unique_key, pFv)
//GO(gconf_unquote_string,
//GO(gconf_unquote_string_inplace,
//GO(gconf_unset_flags_get_type,
//GO(gconf_use_local_locks,
-//GO(gconf_valid_key,
-//GO(gconf_value_compare,
-//GO(gconf_value_copy,
-//GO(gconf_value_decode,
-//GO(gconf_value_encode,
-//GO(gconf_value_free,
-//GO(gconf_value_get_bool,
+GO(gconf_valid_key, iFpp)
+GO(gconf_value_compare, iFpp)
+GO(gconf_value_copy, pFp)
+GO(gconf_value_decode, pFp)
+GO(gconf_value_encode, pFp)
+GO(gconf_value_free, vFp)
+GO(gconf_value_get_bool, iFp)
//GO(gconf_value_get_car,
//GO(gconf_value_get_cdr,
-//GO(gconf_value_get_float,
-//GO(gconf_value_get_int,
-//GO(gconf_value_get_list,
-//GO(gconf_value_get_list_type,
-//GO(gconf_value_get_schema,
-//GO(gconf_value_get_string,
+GO(gconf_value_get_float, dFp)
+GO(gconf_value_get_int, iFp)
+GO(gconf_value_get_list, pFp)
+GO(gconf_value_get_list_type, uFp)
+GO(gconf_value_get_schema, pFp)
+GO(gconf_value_get_string, pFp)
//GO(gconf_value_get_type,
//GO(gconf_value_list_from_primitive_list,
//GO(gconf_value_list_to_primitive_list_destructive,
-//GO(gconf_value_new,
-//GO(gconf_value_new_from_string,
+GO(gconf_value_new, pFu)
+GO(gconf_value_new_from_string, pFupp)
//GO(gconf_value_new_list_from_string,
//GO(gconf_value_new_pair_from_string,
//GO(gconf_value_pair_from_primitive_pair,
//GO(gconf_value_pair_to_primitive_pair_destructive,
-//GO(gconf_value_set_bool,
+GO(gconf_value_set_bool, vFpi)
//GO(gconf_value_set_car,
//GO(gconf_value_set_car_nocopy,
-//GO(gconf_value_set_cdr,
-//GO(gconf_value_set_cdr_nocopy,
-//GO(gconf_value_set_float,
-//GO(gconf_value_set_int,
-//GO(gconf_value_set_list,
+GO(gconf_value_set_cdr, vFpp)
+GO(gconf_value_set_cdr_nocopy, vFpp)
+GO(gconf_value_set_float, vFpd)
+GO(gconf_value_set_int, vFpi)
+GO(gconf_value_set_list, vFpp)
//GO(gconf_value_set_list_nocopy,
-//GO(gconf_value_set_list_type,
-//GO(gconf_value_set_schema,
-//GO(gconf_value_set_schema_nocopy,
-//GO(gconf_value_set_string,
+GO(gconf_value_set_list_type, vFpu)
+GO(gconf_value_set_schema, vFpp)
+GO(gconf_value_set_schema_nocopy, vFpp)
+GO(gconf_value_set_string, vFpp)
//GO(gconf_value_set_string_nocopy,
//GO(gconf_value_steal_list,
//GO(gconf_value_steal_schema,
//GO(gconf_value_steal_string,
-//GO(gconf_value_to_string,
+GO(gconf_value_to_string, pFp)
//GO(gconf_value_type_from_string,
//GO(gconf_value_type_get_type,
//GO(gconf_value_type_to_string,
diff --git a/src/wrapped/wrappedgcrypt_private.h b/src/wrapped/wrappedgcrypt_private.h
index 07830c3..39b2e55 100644
--- a/src/wrapped/wrappedgcrypt_private.h
+++ b/src/wrapped/wrappedgcrypt_private.h
@@ -201,7 +201,7 @@ GO(gcry_sexp_find_token, pFppL)
//GO(gcry_sexp_new,
//GO(gcry_sexp_nth,
//GO(gcry_sexp_nth_buffer,
-//GO(gcry_sexp_nth_data,
+GO(gcry_sexp_nth_data, pFpip)
GO(gcry_sexp_nth_mpi, pFpii)
//GO(gcry_sexp_nth_string,
//GO(gcry_sexp_prepend,
diff --git a/src/wrapped/wrappedgdk3.c b/src/wrapped/wrappedgdk3.c
index 671301b..aea28c6 100755..100644
--- a/src/wrapped/wrappedgdk3.c
+++ b/src/wrapped/wrappedgdk3.c
@@ -37,10 +37,10 @@ GO(3)
// GdkFilterFunc
#define GO(A) \
-static uintptr_t my_filter_fct_##A = 0; \
-static int my_filter_##A(void* xevent, void* event, void* data) \
-{ \
- return (int)RunFunction(my_context, my_filter_fct_##A, 3, xevent, event, data);\
+static uintptr_t my_filter_fct_##A = 0; \
+static int my_filter_##A(void* xevent, void* event, void* data) \
+{ \
+ return (int)RunFunctionFmt(my_filter_fct_##A, "ppp", xevent, event, data); \
}
SUPER()
#undef GO
@@ -54,14 +54,60 @@ static void* findFilterFct(void* fct)
#define GO(A) if(my_filter_fct_##A == 0) {my_filter_fct_##A = (uintptr_t)fct; return my_filter_##A; }
SUPER()
#undef GO
- printf_log(LOG_NONE, "Warning, no more slot for gtk-2 GdkFilterFunc callback\n");
+ printf_log(LOG_NONE, "Warning, no more slot for gdk-3 GdkFilterFunc callback\n");
+ return NULL;
+}
+// GSourceFunc
+#define GO(A) \
+static uintptr_t my_GSourceFunc_fct_##A = 0; \
+static int my_GSourceFunc_##A(void* a) \
+{ \
+ return (int)RunFunctionFmt(my_GSourceFunc_fct_##A, "p", a); \
+}
+SUPER()
+#undef GO
+static void* findGSourceFunc(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_GSourceFunc_fct_##A == (uintptr_t)fct) return my_GSourceFunc_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_GSourceFunc_fct_##A == 0) {my_GSourceFunc_fct_##A = (uintptr_t)fct; return my_GSourceFunc_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for gdk-3 GSourceFunc callback\n");
+ return NULL;
+}
+// GDestroyNotify
+#define GO(A) \
+static uintptr_t my_GDestroyNotify_fct_##A = 0; \
+static void my_GDestroyNotify_##A(void* data) \
+{ \
+ RunFunctionFmt(my_GDestroyNotify_fct_##A, "p", data); \
+}
+SUPER()
+#undef GO
+static void* findGDestroyNotifyFct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_GDestroyNotify_fct_##A == (uintptr_t)fct) return my_GDestroyNotify_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_GDestroyNotify_fct_##A == 0) {my_GDestroyNotify_fct_##A = (uintptr_t)fct; return my_GDestroyNotify_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for gdk-3 GDestroyNotify callback\n");
return NULL;
}
+#undef SUPER
+
static void my3_event_handler(void* event, my_signal_t* sig)
{
- RunFunction(my_context, sig->c_handler, 2, event, sig->data);
+ RunFunctionFmt(sig->c_handler, "pp", event, sig->data) ;
}
EXPORT void my3_gdk_event_handler_set(x64emu_t* emu, void* func, void* data, void* notify)
@@ -76,7 +122,7 @@ EXPORT void my3_gdk_event_handler_set(x64emu_t* emu, void* func, void* data, voi
static void my3_input_function(my_signal_t* sig, int source, int condition)
{
- RunFunction(my_context, sig->c_handler, 3, sig->data, source, condition);
+ RunFunctionFmt(sig->c_handler, "pii", sig->data, source, condition) ;
}
EXPORT int my3_gdk_input_add(x64emu_t* emu, int source, int condition, void* f, void* data)
@@ -92,7 +138,7 @@ EXPORT int my3_gdk_input_add_full(x64emu_t* emu, int source, int condition, void
{
if(!f)
return my->gdk_input_add_full(source, condition, f, data, notify);
-
+
my_signal_t* sig = new_mysignal(f, data, notify);
return my->gdk_input_add_full(source, condition, my3_input_function, sig, my_signal_delete);
}
@@ -120,6 +166,11 @@ EXPORT void my3_gdk_window_remove_filter(x64emu_t* emu, void* window, void* f, v
my->gdk_window_remove_filter(window, findFilterFct(f), data);
}
+EXPORT uint32_t my3_gdk_threads_add_idle_full(x64emu_t* emu, int priority, void* f, void* data, void* d)
+{
+ return my->gdk_threads_add_idle_full(priority, findGSourceFunc(f), data, findGDestroyNotifyFct(d));
+}
+
#define PRE_INIT \
if(box64_nogtk) \
return -1;
diff --git a/src/wrapped/wrappedgdk3_private.h b/src/wrapped/wrappedgdk3_private.h
index 3e2abb5..97455ee 100755..100644
--- a/src/wrapped/wrappedgdk3_private.h
+++ b/src/wrapped/wrappedgdk3_private.h
@@ -3,15 +3,15 @@
#endif
//GOM(gdk_add_client_message_filter, vFpBp)
-//GO(gdk_add_option_entries_libgtk_only,
+GO(gdk_add_option_entries_libgtk_only, vFp)
//GO(gdk_app_launch_context_get_type,
-//GO(gdk_app_launch_context_new,
-//GO(gdk_app_launch_context_set_desktop,
-//GO(gdk_app_launch_context_set_display,
-//GO(gdk_app_launch_context_set_icon,
-//GO(gdk_app_launch_context_set_icon_name,
-//GO(gdk_app_launch_context_set_screen,
-//GO(gdk_app_launch_context_set_timestamp,
+GO(gdk_app_launch_context_new, pFv)
+GO(gdk_app_launch_context_set_desktop, vFpi)
+GO(gdk_app_launch_context_set_display, vFpp)
+GO(gdk_app_launch_context_set_icon, vFpp)
+GO(gdk_app_launch_context_set_icon_name, vFpp)
+GO(gdk_app_launch_context_set_screen, vFpp)
+GO(gdk_app_launch_context_set_timestamp, vFpu)
GO(gdk_atom_intern, pFpi)
GO(gdk_atom_intern_static_string, pFp)
GO(gdk_atom_name, pFp)
@@ -79,23 +79,23 @@ GO(gdk_cursor_ref, pFp)
GO(gdk_cursor_type_get_type, iFv)
GO(gdk_cursor_unref, vFp)
GO(gdk_device_free_history, vFpi)
-GO(gdk_device_get_axis, iFppip)
-GO(gdk_device_get_axis_use, iFpu)
+GO(gdk_device_get_axis, iFppup)
+GO(gdk_device_get_axis_use, uFpu)
GO(gdk_device_get_core_pointer, pFv)
GO(gdk_device_get_has_cursor, iFp)
GO(gdk_device_get_history, iFppuupp)
-GO(gdk_device_get_key, vFpupp)
-GO(gdk_device_get_mode, iFp)
+GO(gdk_device_get_key, iFpupp)
+GO(gdk_device_get_mode, uFp)
GO(gdk_device_get_name, pFp)
GO(gdk_device_get_n_axes, iFp)
GO(gdk_device_get_n_keys, iFp)
-GO(gdk_device_get_source, iFp)
+GO(gdk_device_get_source, uFp)
GO(gdk_device_get_state, vFpppp)
GO(gdk_device_get_type, iFv)
-GO(gdk_device_set_axis_use, vFpui)
+GO(gdk_device_set_axis_use, vFpuu)
GO(gdk_device_manager_get_type, lFv)
-GO(gdk_device_set_key, vFpuui)
-GO(gdk_device_set_mode, iFpi)
+GO(gdk_device_set_key, vFpuuu)
+GO(gdk_device_set_mode, iFpu)
GO(gdk_device_set_source, vFpi)
GO(gdk_devices_list, pFv)
//GOM(gdk_display_add_client_message_filter, vFEpppp)
@@ -127,7 +127,7 @@ GO(gdk_display_manager_set_default_display, vFpp)
GO(gdk_display_map_keycode, iFpuppp)
GO(gdk_display_notify_startup_complete, vFpp)
GO(gdk_display_open, pFp)
-//GO(gdk_display_open_default_libgtk_only,
+GO(gdk_display_open_default_libgtk_only, pFv)
GO(gdk_display_peek_event, pFp)
GO(gdk_display_pointer_is_grabbed, iFp)
GO(gdk_display_pointer_ungrab, vFpu)
@@ -151,8 +151,8 @@ GO(gdk_drag_action_get_type, iFv)
GO(gdk_drag_begin, pFpp)
GO(gdk_drag_context_get_actions, iFp)
GO(gdk_drag_context_get_dest_window, pFp)
-GO(gdk_drag_context_get_protocol, iFp)
-GO(gdk_drag_context_get_selected_action, iFp)
+GO(gdk_drag_context_get_protocol, uFp)
+GO(gdk_drag_context_get_selected_action, uFp)
GO(gdk_drag_context_get_source_window, pFp)
GO(gdk_drag_context_get_suggested_action, iFp)
GO(gdk_drag_context_get_type, iFv)
@@ -167,9 +167,9 @@ GO(gdk_drag_find_window_for_screen, vFpppiipp)
GO(gdk_drag_get_protocol, pFpp)
GO(gdk_drag_get_protocol_for_display, pFppp)
GO(gdk_drag_get_selection, pFp)
-GO(gdk_drag_motion, iFppiiiiiu)
+GO(gdk_drag_motion, iFppuiiuuu)
GO(gdk_drag_protocol_get_type, iFv)
-GO(gdk_drag_status, vFpiu)
+GO(gdk_drag_status, vFpuu)
GO(gdk_drawable_copy_to_image, pFppiiiiii)
GO(gdk_drawable_get_clip_region, pFp)
GO(gdk_drawable_get_colormap, pFp)
@@ -220,13 +220,14 @@ GO(gdk_error_trap_push, vFv)
GO(gdk_event_copy, pFp)
GO(gdk_event_free, vFp)
GO(gdk_event_get, pFv)
-GO(gdk_event_get_axis, iFpip)
+GO(gdk_event_get_axis, iFpup)
GO(gdk_event_get_coords, iFppp)
GO(gdk_event_get_graphics_expose, pFp)
GO(gdk_event_get_modifier_state, iFp)
GO(gdk_event_get_root_coords, iFppp)
GO(gdk_event_get_screen, pFp)
GO(gdk_event_get_state, iFpp)
+GO(gdk_event_get_source_device, pFp)
GO(gdk_event_get_surface, pFp)
GO(gdk_event_get_time, uFp)
GO(gdk_event_get_type, iFv)
@@ -304,6 +305,11 @@ GO(gdk_get_display_arg_name, pFv)
GO(gdk_get_program_class, pFv)
GO(gdk_get_show_events, iFv)
GO(gdk_get_use_xshm, iFv)
+GO(gdk_gl_context_get_type, LFv)
+GO(gdk_gl_context_clear_current, vFv)
+GO(gdk_gl_context_get_current, pFv)
+GO(gdk_gl_context_make_current, vFp)
+GO(gdk_gl_context_realize, iFpp)
GO(gdk_grab_status_get_type, iFv)
GO(gdk_gravity_get_type, iFv)
GO(gdk_image_get, pFpiiii)
@@ -339,13 +345,13 @@ GO(gdk_input_source_get_type, iFv)
GO(gdk_join_style_get_type, iFv)
GO(gdk_key_event_get_keycode, uFp)
GO(gdk_key_event_get_keyval, uFp)
-GO(gdk_keyboard_grab, iFpiu)
+GO(gdk_keyboard_grab, uFpiu)
//GO(gdk_keyboard_grab_info_libgtk_only,
GO(gdk_keyboard_ungrab, vFu)
GO(gdk_keymap_add_virtual_modifiers, vFpp)
GO(gdk_keymap_get_caps_lock_state, iFp)
GO(gdk_keymap_get_default, pFv)
-GO(gdk_keymap_get_direction, iFp)
+GO(gdk_keymap_get_direction, uFp)
GO(gdk_keymap_get_entries_for_keycode, iFpuppp)
GO(gdk_keymap_get_entries_for_keyval, iFpupp)
GO(gdk_keymap_get_for_display, pFp)
@@ -353,7 +359,7 @@ GO(gdk_keymap_get_type, iFv)
GO(gdk_keymap_have_bidi_layouts, iFp)
GO(gdk_keymap_lookup_key, uFpp)
GO(gdk_keymap_map_virtual_modifiers, iFpp)
-GO(gdk_keymap_translate_keyboard_state, iFpuiipppp)
+GO(gdk_keymap_translate_keyboard_state, iFpuuipppp)
GO(gdk_keyval_convert_case, vFupp)
GO(gdk_keyval_from_name, uFp)
GO(gdk_keyval_is_lower, iFu)
@@ -418,12 +424,12 @@ GO(gdk_pixmap_impl_x11_get_type, iFv)
GO(gdk_pixmap_lookup, pFp)
GO(gdk_pixmap_lookup_for_display, pFpp)
GO(gdk_pixmap_new, pFpiii)
-GO(gdk_pointer_grab, iFpiippu)
+GO(gdk_pointer_grab, uFpiuppu)
//GO(gdk_pointer_grab_info_libgtk_only,
GO(gdk_pointer_is_grabbed, iFv)
GO(gdk_pointer_ungrab, vFu)
//GO(gdk_pre_parse_libgtk_only,
-GO(gdk_property_change, vFpppiipi)
+GO(gdk_property_change, vFpppiupi)
GO(gdk_property_delete, vFpp)
GO(gdk_property_get, iFpppLLipppp)
GO(gdk_property_state_get_type, iFv)
@@ -543,7 +549,7 @@ GO(gdk_string_to_compound_text_for_display, iFpppppp)
//GO(gdk_subwindow_mode_get_type,
//GO(gdk_synthesize_window_state,
//GO(gdk_test_render_sync,
-//GO(gdk_test_simulate_button,
+GO(gdk_test_simulate_button, iFpiiuui)
//GO(gdk_test_simulate_key,
//GO(gdk_text_extents,
//GO(gdk_text_extents_wc,
@@ -552,14 +558,14 @@ GO(gdk_string_to_compound_text_for_display, iFpppppp)
GO(gdk_text_property_to_text_list, iFpipip)
GO(gdk_text_property_to_text_list_for_display, iFppipip)
GO(gdk_text_property_to_utf8_list, iFpipip)
-//GO(gdk_text_property_to_utf8_list_for_display,
+GO(gdk_text_property_to_utf8_list_for_display, iFppipip)
//GO(gdk_text_width,
//GO(gdk_text_width_wc,
GO(gdk_texture_download, vFppL)
GO(gdk_texture_get_width, uFp)
GO(gdk_texture_get_height, uFp)
//GOM(gdk_threads_add_idle, uFEpp)
-//GOM(gdk_threads_add_idle_full, uFEippp)
+GOM(gdk_threads_add_idle_full, uFEippp)
//GOM(gdk_threads_add_timeout, uFEupp)
//GOM(gdk_threads_add_timeout_full, uFEiuppp)
//GOM(gdk_threads_add_timeout_seconds, uFEupp)
@@ -576,21 +582,21 @@ GO(gdk_utf8_to_string_target, pFp)
GO(gdk_visibility_state_get_type, iFv)
GO(gdk_visual_get_best, pFv)
GO(gdk_visual_get_best_depth, iFv)
-GO(gdk_visual_get_best_type, iFv)
-GO(gdk_visual_get_best_with_both, pFii)
+GO(gdk_visual_get_best_type, uFv)
+GO(gdk_visual_get_best_with_both, pFiu)
GO(gdk_visual_get_best_with_depth, pFi)
-GO(gdk_visual_get_best_with_type, pFi)
+GO(gdk_visual_get_best_with_type, pFu)
GO(gdk_visual_get_bits_per_rgb, iFp)
GO(gdk_visual_get_blue_pixel_details, vFpppp)
-GO(gdk_visual_get_byte_order, iFp)
+GO(gdk_visual_get_byte_order, uFp)
GO(gdk_visual_get_colormap_size, iFp)
GO(gdk_visual_get_depth, iFp)
GO(gdk_visual_get_green_pixel_details, vFpppp)
GO(gdk_visual_get_red_pixel_details, vFpppp)
GO(gdk_visual_get_screen, pFp)
GO(gdk_visual_get_system, pFv)
-GO(gdk_visual_get_type, iFv)
-GO(gdk_visual_get_visual_type, iFp)
+GO(gdk_visual_get_type, LFv)
+GO(gdk_visual_get_visual_type, uFp)
GO(gdk_visual_type_get_type, iFv)
GO(gdk_wayland_toplevel_set_transient_for_exported, iFpp)
GO(gdk_wayland_window_set_transient_for_exported, iFpp)
@@ -611,8 +617,9 @@ GO(gdk_window_configure_finished, vFp)
GO(gdk_window_constrain_size, vFpuiipp)
GO(gdk_window_coords_from_parent, vFpddpp)
GO(gdk_window_coords_to_parent, vFpddpp)
+GO(gdk_window_create_gl_context, pFpp)
GO(gdk_window_create_similar_image_surface, pFpiiii)
-GO(gdk_window_create_similar_surface, pFpiii)
+GO(gdk_window_create_similar_surface, pFpuii)
GO(gdk_window_deiconify, vFp)
GO(gdk_window_destroy, vFp)
//GO(gdk_window_destroy_notify,
@@ -638,10 +645,10 @@ GO(gdk_window_get_deskrelative_origin, iFppp)
GO(gdk_window_get_display, pFp)
GO(gdk_window_get_effective_parent, pFp)
GO(gdk_window_get_effective_toplevel, pFp)
-GO(gdk_window_get_events, vFpi)
+GO(gdk_window_get_events, uFp)
GO(gdk_window_get_focus_on_map, iFp)
GO(gdk_window_get_frame_extents, vFpp)
-GO(gdk_window_get_geometry, vFpppppp)
+GO(gdk_window_get_geometry, vFppppp)
GO(gdk_window_get_group, pFp)
GO(gdk_window_get_height, iFp)
GO(gdk_window_get_internal_paint_info, vFpppp)
@@ -653,16 +660,16 @@ GO(gdk_window_get_position, vFppp)
GO(gdk_window_get_root_coords, vFpiipp)
GO(gdk_window_get_root_origin, vFppp)
GO(gdk_window_get_screen, pFp)
-GO(gdk_window_get_state, iFp)
+GO(gdk_window_get_state, uFp)
GO(gdk_window_get_toplevel, pFp)
GO(gdk_window_get_toplevels, pFp)
GO(gdk_window_get_type, lFv)
-GO(gdk_window_get_type_hint, iFp)
+GO(gdk_window_get_type_hint, uFp)
GO(gdk_window_get_update_area, pFp)
GO(gdk_window_get_user_data, vFpp)
GO(gdk_window_get_visual, pFp)
GO(gdk_window_get_width, iFp)
-GO(gdk_window_get_window_type, iFp)
+GO(gdk_window_get_window_type, uFp)
GO(gdk_window_has_native, iFp)
GO(gdk_window_hide, vFp)
GO(gdk_window_hints_get_type, iFv)
@@ -704,17 +711,18 @@ GO(gdk_window_restack, vFppi)
GO(gdk_window_scroll, vFpii)
GO(gdk_window_set_accept_focus, vFpi)
GO(gdk_window_set_background, vFpp)
+GO(gdk_window_set_background_rgba, vFpp)
GO(gdk_window_set_back_pixmap, vFppi)
GO(gdk_window_set_child_input_shapes, vFp)
GO(gdk_window_set_child_shapes, vFp)
GO(gdk_window_set_composited, vFpi)
GO(gdk_window_set_cursor, vFpp)
GO(gdk_window_set_debug_updates, vFi)
-GO(gdk_window_set_decorations, vFpp)
-GO(gdk_window_set_events, vFpp)
+GO(gdk_window_set_decorations, vFpu)
+GO(gdk_window_set_events, vFpu)
GO(gdk_window_set_focus_on_map, vFpi)
GO(gdk_window_set_functions, vFpu)
-GO(gdk_window_set_geometry_hints, vFppi)
+GO(gdk_window_set_geometry_hints, vFppu)
GO(gdk_window_set_group, vFpp)
GO(gdk_window_set_hints, vFpiiiiiii)
GO(gdk_window_set_icon, vFpppp)
@@ -723,7 +731,7 @@ GO(gdk_window_set_icon_name, vFpp)
GO(gdk_window_set_keep_above, vFpi)
GO(gdk_window_set_keep_below, vFpi)
GO(gdk_window_set_modal_hint, iFp)
-GO(gdk_window_set_opacity, vFpi)
+GO(gdk_window_set_opacity, vFpd)
GO(gdk_window_set_override_redirect, vFpi)
GO(gdk_window_set_role, vFpp)
GO(gdk_window_set_skip_pager_hint, vFpi)
@@ -732,7 +740,7 @@ GO(gdk_window_set_startup_id, vFpp)
GO(gdk_window_set_static_gravities, iFpi)
GO(gdk_window_set_title, vFpp)
GO(gdk_window_set_transient_for, vFpp)
-GO(gdk_window_set_type_hint, vFpi)
+GO(gdk_window_set_type_hint, vFpu)
GO(gdk_window_set_urgency_hint, vFpi)
GO(gdk_window_set_user_data, vFpp)
GO(gdk_window_shape_combine_mask, vFppii)
@@ -763,6 +771,7 @@ GO(gdk_x11_display_get_startup_notification_id, pFp)
GO(gdk_x11_display_get_type, iFv)
GO(gdk_x11_display_get_user_time, uFp)
GO(gdk_x11_display_get_xdisplay, pFp)
+GO(gdk_x11_window_get_type, LFv)
GO(gdk_x11_window_get_xid, LFp)
GO(gdk_x11_display_grab, vFp)
GO(gdk_x11_display_set_cursor_theme, vFppi)
@@ -820,4 +829,4 @@ DATA(gdk_threads_lock, 4)
DATA(gdk_threads_unlock, 4)
GO(dummy_set_child_property, vFppupp) // to get vFppupp for gtkclass.c
-GO(dummy_constructor, vFLup) // to get vFlup for gtkclass.c \ No newline at end of file
+GO(dummy_constructor, vFLup) // to get vFlup for gtkclass.c
diff --git a/src/wrapped/wrappedgdkpixbuf2.c b/src/wrapped/wrappedgdkpixbuf2.c
index 1f82399..34770c8 100755..100644
--- a/src/wrapped/wrappedgdkpixbuf2.c
+++ b/src/wrapped/wrappedgdkpixbuf2.c
@@ -32,10 +32,10 @@ GO(3)
// destroy_pixbuf
#define GO(A) \
-static uintptr_t my_destroy_pixbuf_fct_##A = 0; \
-static void my_destroy_pixbuf_##A(void* pixels, void* data) \
-{ \
- RunFunction(my_context, my_destroy_pixbuf_fct_##A, 2, pixels, data); \
+static uintptr_t my_destroy_pixbuf_fct_##A = 0; \
+static void my_destroy_pixbuf_##A(void* pixels, void* data) \
+{ \
+ RunFunctionFmt(my_destroy_pixbuf_fct_##A, "pp", pixels, data); \
}
SUPER()
#undef GO
diff --git a/src/wrapped/wrappedgdkpixbuf2_private.h b/src/wrapped/wrappedgdkpixbuf2_private.h
index adc0f9f..adc0f9f 100755..100644
--- a/src/wrapped/wrappedgdkpixbuf2_private.h
+++ b/src/wrapped/wrappedgdkpixbuf2_private.h
diff --git a/src/wrapped/wrappedgdkx112.c b/src/wrapped/wrappedgdkx112.c
index 4f3aeba..cb62731 100755..100644
--- a/src/wrapped/wrappedgdkx112.c
+++ b/src/wrapped/wrappedgdkx112.c
@@ -37,10 +37,10 @@ GO(3)
// GdkFilterFunc
#define GO(A) \
-static uintptr_t my_filter_fct_##A = 0; \
-static int my_filter_##A(void* xevent, void* event, void* data) \
-{ \
- return (int)RunFunction(my_context, my_filter_fct_##A, 3, xevent, event, data);\
+static uintptr_t my_filter_fct_##A = 0; \
+static int my_filter_##A(void* xevent, void* event, void* data) \
+{ \
+ return (int)RunFunctionFmt(my_filter_fct_##A, "ppp", xevent, event, data); \
}
SUPER()
#undef GO
@@ -61,7 +61,7 @@ static void* findFilterFct(void* fct)
static void my_event_handler(void* event, my_signal_t* sig)
{
- RunFunction(my_context, sig->c_handler, 2, event, sig->data);
+ RunFunctionFmt(sig->c_handler, "pp", event, sig->data);
}
EXPORT void my_gdk_event_handler_set(x64emu_t* emu, void* func, void* data, void* notify)
@@ -76,7 +76,7 @@ EXPORT void my_gdk_event_handler_set(x64emu_t* emu, void* func, void* data, void
static void my_input_function(my_signal_t* sig, int source, int condition)
{
- RunFunction(my_context, sig->c_handler, 3, sig->data, source, condition);
+ RunFunctionFmt(sig->c_handler, "pii", sig->data, source, condition);
}
EXPORT int my_gdk_input_add(x64emu_t* emu, int source, int condition, void* f, void* data)
@@ -92,7 +92,7 @@ EXPORT int my_gdk_input_add_full(x64emu_t* emu, int source, int condition, void*
{
if(!f)
return my->gdk_input_add_full(source, condition, f, data, notify);
-
+
my_signal_t* sig = new_mysignal(f, data, notify);
return my->gdk_input_add_full(source, condition, my_input_function, sig, my_signal_delete);
}
diff --git a/src/wrapped/wrappedgdkx112_private.h b/src/wrapped/wrappedgdkx112_private.h
index 1c0400a..f9c4d6b 100755..100644
--- a/src/wrapped/wrappedgdkx112_private.h
+++ b/src/wrapped/wrappedgdkx112_private.h
@@ -3,15 +3,15 @@
#endif
//GOM(gdk_add_client_message_filter, vFpBp)
-//GO(gdk_add_option_entries_libgtk_only,
+GO(gdk_add_option_entries_libgtk_only, vFp)
//GO(gdk_app_launch_context_get_type,
-//GO(gdk_app_launch_context_new,
-//GO(gdk_app_launch_context_set_desktop,
+GO(gdk_app_launch_context_new, pFv)
+GO(gdk_app_launch_context_set_desktop, vFpi)
//GO(gdk_app_launch_context_set_display,
-//GO(gdk_app_launch_context_set_icon,
-//GO(gdk_app_launch_context_set_icon_name,
-//GO(gdk_app_launch_context_set_screen,
-//GO(gdk_app_launch_context_set_timestamp,
+GO(gdk_app_launch_context_set_icon, vFpp)
+GO(gdk_app_launch_context_set_icon_name, vFpp)
+GO(gdk_app_launch_context_set_screen, vFpp)
+GO(gdk_app_launch_context_set_timestamp, vFpu)
GO(gdk_atom_intern, pFpi)
GO(gdk_atom_intern_static_string, pFp)
GO(gdk_atom_name, pFp)
@@ -28,10 +28,10 @@ GO(gdk_cairo_set_source_pixbuf, vFppdd)
GO(gdk_cairo_set_source_pixmap, vFppdd)
GO(gdk_cairo_set_source_window, vFppdd)
//GO(gdk_cap_style_get_type,
-//GO(gdk_char_height,
+GO(gdk_char_height, iFpC)
//GO(gdk_char_measure,
//GO(gdk_char_width,
-//GO(gdk_char_width_wc,
+GO(gdk_char_width_wc, iFpu)
GO(gdk_color_alloc, iFpp)
GO(gdk_color_black, iFpp)
GO(gdk_color_change, iFpp)
@@ -73,23 +73,23 @@ GO(gdk_cursor_ref, pFp)
GO(gdk_cursor_type_get_type, LFv)
GO(gdk_cursor_unref, vFp)
GO(gdk_device_free_history, vFpi)
-GO(gdk_device_get_axis, iFppip)
-GO(gdk_device_get_axis_use, iFpu)
+GO(gdk_device_get_axis, iFppup)
+GO(gdk_device_get_axis_use, uFpu)
GO(gdk_device_get_core_pointer, pFv)
GO(gdk_device_get_has_cursor, iFp)
GO(gdk_device_get_history, iFppuupp)
GO(gdk_device_get_key, vFpupp)
-GO(gdk_device_get_mode, iFp)
+GO(gdk_device_get_mode, uFp)
GO(gdk_device_get_name, pFp)
GO(gdk_device_get_n_axes, iFp)
GO(gdk_device_get_n_keys, iFp)
-GO(gdk_device_get_source, iFp)
+GO(gdk_device_get_source, uFp)
GO(gdk_device_get_state, vFpppp)
GO(gdk_device_get_type, LFv)
-GO(gdk_device_set_axis_use, vFpui)
-GO(gdk_device_set_key, vFpuui)
-GO(gdk_device_set_mode, iFpi)
-GO(gdk_device_set_source, vFpi)
+GO(gdk_device_set_axis_use, vFpuu)
+GO(gdk_device_set_key, vFpuuu)
+GO(gdk_device_set_mode, iFpu)
+GO(gdk_device_set_source, vFpu)
GO(gdk_devices_list, pFv)
//GOM(gdk_display_add_client_message_filter, vFEpppp)
GO(gdk_display_beep, vFp)
@@ -141,8 +141,8 @@ GO(gdk_drag_action_get_type, LFv)
GO(gdk_drag_begin, pFpp)
GO(gdk_drag_context_get_actions, iFp)
GO(gdk_drag_context_get_dest_window, pFp)
-GO(gdk_drag_context_get_protocol, iFp)
-GO(gdk_drag_context_get_selected_action, iFp)
+GO(gdk_drag_context_get_protocol, uFp)
+GO(gdk_drag_context_get_selected_action, uFp)
GO(gdk_drag_context_get_source_window, pFp)
GO(gdk_drag_context_get_suggested_action, iFp)
GO(gdk_drag_context_get_type, LFv)
@@ -154,12 +154,12 @@ GO(gdk_drag_drop, vFpu)
GO(gdk_drag_drop_succeeded, iFp)
GO(gdk_drag_find_window, vFppiipp)
GO(gdk_drag_find_window_for_screen, vFpppiipp)
-GO(gdk_drag_get_protocol, pFpp)
+GO(gdk_drag_get_protocol, uFup)
GO(gdk_drag_get_protocol_for_display, pFppp)
GO(gdk_drag_get_selection, pFp)
-GO(gdk_drag_motion, iFppiiiiiu)
+GO(gdk_drag_motion, iFppuiiuuu)
GO(gdk_drag_protocol_get_type, LFv)
-GO(gdk_drag_status, vFpiu)
+GO(gdk_drag_status, vFpuu)
GO(gdk_drawable_copy_to_image, pFppiiiiii)
GO(gdk_drawable_get_clip_region, pFp)
GO(gdk_drawable_get_colormap, pFp)
@@ -180,22 +180,22 @@ GO(gdk_draw_arc, vFppiiiiiii)
GO(gdk_draw_drawable, vFpppiiiiii)
GO(gdk_draw_glyphs, vFpppiip)
GO(gdk_draw_glyphs_transformed, vFppppiip)
-GO(gdk_draw_gray_image, vFppiiiiipi)
+GO(gdk_draw_gray_image, vFppiiiiupi)
GO(gdk_draw_image, vFpppiiiiii)
-GO(gdk_draw_indexed_image, vFppiiiiipip)
+GO(gdk_draw_indexed_image, vFppiiiiupip)
GO(gdk_draw_layout, vFppiip)
GO(gdk_draw_layout_line, vFppiip)
GO(gdk_draw_layout_line_with_colors, vFppiippp)
GO(gdk_draw_layout_with_colors, vFppiippp)
GO(gdk_draw_line, vFppiiii)
GO(gdk_draw_lines, vFpppi)
-GO(gdk_draw_pixbuf, vFpppiiiiiiiii)
+GO(gdk_draw_pixbuf, vFpppiiiiiiuii)
GO(gdk_draw_point, vFppii)
GO(gdk_draw_points, vFpppi)
GO(gdk_draw_polygon, vFppipi)
GO(gdk_draw_rectangle, vFppiiiii)
GO(gdk_draw_rgb_32_image, vFppiiiiipi)
-GO(gdk_draw_rgb_32_image_dithalign, vFppiiiiipiii)
+GO(gdk_draw_rgb_32_image_dithalign, vFppiiiiupiii)
GO(gdk_draw_rgb_image, vFppiiiiipi)
GO(gdk_draw_rgb_image_dithalign, vFppiiiiipiii)
GO(gdk_draw_segments, vFpppi)
@@ -210,7 +210,7 @@ GO(gdk_error_trap_push, vFv)
GO(gdk_event_copy, pFp)
GO(gdk_event_free, vFp)
GO(gdk_event_get, pFv)
-GO(gdk_event_get_axis, iFpip)
+GO(gdk_event_get_axis, iFpup)
GO(gdk_event_get_coords, iFppp)
GO(gdk_event_get_graphics_expose, pFp)
GO(gdk_event_get_root_coords, iFppp)
@@ -224,7 +224,7 @@ GO(gdk_event_new, pFi)
GO(gdk_event_peek, pFv)
GO(gdk_event_put, vFp)
GO(gdk_event_request_motions, vFp)
-GO(gdk_event_send_client_message, iFpp)
+GO(gdk_event_send_client_message, iFpu)
GO(gdk_event_send_client_message_for_display, iFppp)
GO(gdk_event_send_clientmessage_toall, vFp)
GO(gdk_event_set_screen, vFpp)
@@ -236,19 +236,19 @@ GO(gdk_exit, vFi)
//GO(gdk_fill_rule_get_type,
//GO(gdk_filter_return_get_type,
GO(gdk_flush, vFv)
-//GO(gdk_font_equal,
-//GO(gdk_font_from_description,
+GO(gdk_font_equal, iFpp)
+GO(gdk_font_from_description, pFp)
//GO(gdk_font_from_description_for_display,
//GO(gdk_font_get_display,
GO(gdk_font_get_type, LFv)
-//GO(gdk_font_id,
+GO(gdk_font_id, iFp)
//GO(gdk_font_load,
//GO(gdk_font_load_for_display,
-//GO(gdk_font_ref,
-//GO(gdk_fontset_load,
+GO(gdk_font_ref, pFp)
+GO(gdk_fontset_load, pFp)
//GO(gdk_fontset_load_for_display,
//GO(gdk_font_type_get_type,
-//GO(gdk_font_unref,
+GO(gdk_font_unref, vFp)
GO(gdk_free_compound_text, vFp)
GO(gdk_free_text_list, vFp)
GO(gdk_function_get_type, LFv)
@@ -269,15 +269,15 @@ GO(gdk_gc_set_clip_region, vFpp)
GO(gdk_gc_set_colormap, vFpp)
GO(gdk_gc_set_dashes, vFpipi)
GO(gdk_gc_set_exposures, vFpi)
-GO(gdk_gc_set_fill, vFpi)
+GO(gdk_gc_set_fill, vFpu)
GO(gdk_gc_set_font, vFpp)
GO(gdk_gc_set_foreground, vFpp)
-GO(gdk_gc_set_function,vFpi)
-GO(gdk_gc_set_line_attributes, vFpiiii)
+GO(gdk_gc_set_function, vFpu)
+GO(gdk_gc_set_line_attributes, vFpiuuu)
GO(gdk_gc_set_rgb_bg_color, vFpp)
GO(gdk_gc_set_rgb_fg_color, vFpp)
GO(gdk_gc_set_stipple, vFpp)
-GO(gdk_gc_set_subwindow, vFpi)
+GO(gdk_gc_set_subwindow, vFpu)
GO(gdk_gc_set_tile, vFpp)
GO(gdk_gc_set_ts_origin, vFpii)
GO(gdk_gc_set_values, vFppu)
@@ -293,19 +293,19 @@ GO(gdk_grab_status_get_type, LFv)
GO(gdk_gravity_get_type, LFv)
GO(gdk_image_get, pFpiiii)
GO(gdk_image_get_bits_per_pixel, WFp)
-GO(gdk_image_get_byte_order, iFp)
+GO(gdk_image_get_byte_order, uFp)
GO(gdk_image_get_bytes_per_line, WFp)
GO(gdk_image_get_bytes_per_pixel, WFp)
GO(gdk_image_get_colormap, pFp)
GO(gdk_image_get_depth, WFp)
GO(gdk_image_get_height, iFp)
-GO(gdk_image_get_image_type, iFp)
+GO(gdk_image_get_image_type, uFp)
GO(gdk_image_get_pixel, uFpii)
GO(gdk_image_get_pixels, pFp)
GO(gdk_image_get_type, LFv)
GO(gdk_image_get_visual, pFp)
GO(gdk_image_get_width, iFp)
-GO(gdk_image_new, pFipii)
+GO(gdk_image_new, pFupii)
GO(gdk_image_new_bitmap, pFppii)
GO(gdk_image_put_pixel, vFpiiu)
GO(gdk_image_ref, pFp)
@@ -319,10 +319,10 @@ GOM(gdk_input_add_full, iFEiippp)
GO(gdk_input_condition_get_type, LFv)
GO(gdk_input_mode_get_type, LFv)
GO(gdk_input_remove, vFi)
-GO(gdk_input_set_extension_events, vFpii)
+GO(gdk_input_set_extension_events, vFpiu)
GO(gdk_input_source_get_type, LFv)
GO(gdk_join_style_get_type, LFv)
-GO(gdk_keyboard_grab, iFpiu)
+GO(gdk_keyboard_grab, uFpiu)
//GO(gdk_keyboard_grab_info_libgtk_only,
GO(gdk_keyboard_ungrab, vFu)
GO(gdk_keymap_add_virtual_modifiers, vFpp)
@@ -347,7 +347,7 @@ GO(gdk_keyval_to_unicode, uFu)
GO(gdk_keyval_to_upper, uFu)
GO(gdk_line_style_get_type, LFv)
GO(gdk_list_visuals, pFv)
-//GO(gdk_mbstowcs,
+GO(gdk_mbstowcs, iFppi)
GO(gdk_modifier_type_get_type, LFv)
GO(gdk_net_wm_supports, iFp)
GO(gdk_notify_startup_complete, vFv)
@@ -372,16 +372,16 @@ GO(gdk_pango_renderer_get_type, LFv)
GO(gdk_pango_renderer_new, pFp)
GO(gdk_pango_renderer_set_drawable, vFpp)
GO(gdk_pango_renderer_set_gc, vFpp)
-GO(gdk_pango_renderer_set_override_color, vFpip)
-GO(gdk_pango_renderer_set_stipple, vFpip)
+GO(gdk_pango_renderer_set_override_color, vFpup)
+GO(gdk_pango_renderer_set_stipple, vFpup)
GO(gdk_parse_args, vFpp)
GO(gdk_pixbuf_get_from_drawable, pFpppiiiiii)
GO(gdk_pixbuf_get_from_image, pFpppiiiiii)
GO(gdk_pixbuf_render_pixmap_and_mask, vFpppi)
GO(gdk_pixbuf_render_pixmap_and_mask_for_colormap, vFppppi)
GO(gdk_pixbuf_render_threshold_alpha, vFppiiiiiii)
-GO(gdk_pixbuf_render_to_drawable, vFpppiiiiiiiii)
-GO(gdk_pixbuf_render_to_drawable_alpha, vFppiiiiiiiiiii)
+GO(gdk_pixbuf_render_to_drawable, vFpppiiiiiiuii)
+GO(gdk_pixbuf_render_to_drawable_alpha, vFppiiiiiiuiuii)
GO(gdk_pixmap_colormap_create_from_xpm, pFppppp)
GO(gdk_pixmap_colormap_create_from_xpm_d, pFppppp)
GO(gdk_pixmap_create_from_data, pFppiiipp)
@@ -389,19 +389,19 @@ GO(gdk_pixmap_create_from_xpm, pFpppp)
GO(gdk_pixmap_create_from_xpm_d, pFpppp)
GO(gdk_pixmap_foreign_new, pFp)
GO(gdk_pixmap_foreign_new_for_display, pFpp)
-GO(gdk_pixmap_foreign_new_for_screen, pFppiii)
+GO(gdk_pixmap_foreign_new_for_screen, pFpuiii)
GO(gdk_pixmap_get_size, vFppp)
GO(gdk_pixmap_get_type, LFv)
GO(gdk_pixmap_impl_x11_get_type, LFv)
-GO(gdk_pixmap_lookup, pFp)
+GO(gdk_pixmap_lookup, pFu)
GO(gdk_pixmap_lookup_for_display, pFpp)
GO(gdk_pixmap_new, pFpiii)
-GO(gdk_pointer_grab, iFpiippu)
+GO(gdk_pointer_grab, uFpiuppu)
//GO(gdk_pointer_grab_info_libgtk_only,
GO(gdk_pointer_is_grabbed, iFv)
GO(gdk_pointer_ungrab, vFu)
//GO(gdk_pre_parse_libgtk_only,
-GO(gdk_property_change, vFpppiipi)
+GO(gdk_property_change, vFpppiupi)
GO(gdk_property_delete, vFpp)
GO(gdk_property_get, iFpppLLipppp)
GO(gdk_property_state_get_type, LFv)
@@ -412,7 +412,7 @@ GO(gdk_rectangle_get_type, LFv)
GO(gdk_rectangle_intersect, iFppp)
GO(gdk_rectangle_union, vFppp)
GO(gdk_region_copy, pFp)
-GO(gdk_region_destroy, vFpp)
+GO(gdk_region_destroy, vFp)
GO(gdk_region_empty, iFp)
GO(gdk_region_equal, iFpp)
GO(gdk_region_get_clipbox, vFpp)
@@ -421,10 +421,10 @@ GO(gdk_region_intersect, vFpp)
GO(gdk_region_new, pFv)
GO(gdk_region_offset, vFpii)
GO(gdk_region_point_in, iFpii)
-GO(gdk_region_polygon, pFpii)
+GO(gdk_region_polygon, pFpiu)
GO(gdk_region_rectangle, pFp)
GO(gdk_region_rect_equal, iFpp)
-GO(gdk_region_rect_in, iFpp)
+GO(gdk_region_rect_in, uFpp)
GO(gdk_region_shrink, vFpii)
//GOM(gdk_region_spans_intersect_foreach, vFppiiBp)
GO(gdk_region_subtract, vFpp)
@@ -494,7 +494,7 @@ GO(gdk_selection_owner_get_for_display, pFpp)
GO(gdk_selection_owner_set, iFppui)
GO(gdk_selection_owner_set_for_display, iFpppui)
GO(gdk_selection_property_get, iFpppp)
-GO(gdk_selection_send_notify, vFppppu)
+GO(gdk_selection_send_notify, vFupppu)
GO(gdk_selection_send_notify_for_display, vFpppppu)
GO(gdk_set_double_click_time, vFu)
GO(gdk_set_locale, pFv)
@@ -509,27 +509,27 @@ GO(gdk_spawn_command_line_on_screen, iFppp)
//GOM(gdk_spawn_on_screen, iFEppppipppp)
//GOM(gdk_spawn_on_screen_with_pipes, iFEppppippppppp)
GO(gdk_status_get_type, LFv)
-//GO(gdk_string_extents,
-//GO(gdk_string_height,
+GO(gdk_string_extents, vFppppppp)
+GO(gdk_string_height, iFpp)
//GO(gdk_string_measure,
GO(gdk_string_to_compound_text, iFppppp)
GO(gdk_string_to_compound_text_for_display, iFpppppp)
//GO(gdk_string_width,
//GO(gdk_subwindow_mode_get_type,
//GO(gdk_synthesize_window_state,
-//GO(gdk_test_render_sync,
-//GO(gdk_test_simulate_button,
+GO(gdk_test_render_sync, vFp)
+GO(gdk_test_simulate_button, iFpiiuui)
//GO(gdk_test_simulate_key,
-//GO(gdk_text_extents,
-//GO(gdk_text_extents_wc,
-//GO(gdk_text_height,
+GO(gdk_text_extents, vFppippppp)
+GO(gdk_text_extents_wc, vFppippppp)
+GO(gdk_text_height, iFppi)
//GO(gdk_text_measure,
GO(gdk_text_property_to_text_list, iFpipip)
GO(gdk_text_property_to_text_list_for_display, iFppipip)
GO(gdk_text_property_to_utf8_list, iFpipip)
//GO(gdk_text_property_to_utf8_list_for_display,
//GO(gdk_text_width,
-//GO(gdk_text_width_wc,
+GO(gdk_text_width_wc, iFppi)
//GOM(gdk_threads_add_idle, uFEpp)
//GOM(gdk_threads_add_idle_full, uFEippp)
//GOM(gdk_threads_add_timeout, uFEupp)
@@ -547,13 +547,13 @@ GO(gdk_utf8_to_string_target, pFp)
GO(gdk_visibility_state_get_type, LFv)
GO(gdk_visual_get_best, pFv)
GO(gdk_visual_get_best_depth, iFv)
-GO(gdk_visual_get_best_type, iFv)
-GO(gdk_visual_get_best_with_both, pFii)
+GO(gdk_visual_get_best_type, uFv)
+GO(gdk_visual_get_best_with_both, pFiu)
GO(gdk_visual_get_best_with_depth, pFi)
-GO(gdk_visual_get_best_with_type, pFi)
+GO(gdk_visual_get_best_with_type, pFu)
GO(gdk_visual_get_bits_per_rgb, iFp)
GO(gdk_visual_get_blue_pixel_details, vFpppp)
-GO(gdk_visual_get_byte_order, iFp)
+GO(gdk_visual_get_byte_order, uFp)
GO(gdk_visual_get_colormap_size, iFp)
GO(gdk_visual_get_depth, iFp)
GO(gdk_visual_get_green_pixel_details, vFpppp)
@@ -561,9 +561,9 @@ GO(gdk_visual_get_red_pixel_details, vFpppp)
GO(gdk_visual_get_screen, pFp)
GO(gdk_visual_get_system, pFv)
GO(gdk_visual_get_type, LFv)
-GO(gdk_visual_get_visual_type, iFp)
+GO(gdk_visual_get_visual_type, uFp)
GO(gdk_visual_type_get_type, LFv)
-//GO(gdk_wcstombs,
+GO(gdk_wcstombs, pFp)
GOM(gdk_window_add_filter, vFEppp)
GO(gdk_window_at_pointer, pFpp)
//GO(gdk_window_attributes_type_get_type,
@@ -580,7 +580,7 @@ GO(gdk_window_configure_finished, vFp)
GO(gdk_window_constrain_size, vFpuiipp)
GO(gdk_window_coords_from_parent, vFpddpp)
GO(gdk_window_coords_to_parent, vFpddpp)
-GO(gdk_window_create_similar_surface, pFpiii)
+GO(gdk_window_create_similar_surface, pFpuii)
GO(gdk_window_deiconify, vFp)
GO(gdk_window_destroy, vFp)
//GO(gdk_window_destroy_notify,
@@ -606,7 +606,7 @@ GO(gdk_window_get_deskrelative_origin, iFppp)
GO(gdk_window_get_display, pFp)
GO(gdk_window_get_effective_parent, pFp)
GO(gdk_window_get_effective_toplevel, pFp)
-GO(gdk_window_get_events, vFpi)
+GO(gdk_window_get_events, uFp)
GO(gdk_window_get_focus_on_map, iFp)
GO(gdk_window_get_frame_extents, vFpp)
GO(gdk_window_get_geometry, vFpppppp)
@@ -621,15 +621,15 @@ GO(gdk_window_get_position, vFppp)
GO(gdk_window_get_root_coords, vFpiipp)
GO(gdk_window_get_root_origin, vFppp)
GO(gdk_window_get_screen, pFp)
-GO(gdk_window_get_state, iFp)
+GO(gdk_window_get_state, uFp)
GO(gdk_window_get_toplevel, pFp)
GO(gdk_window_get_toplevels, pFp)
-GO(gdk_window_get_type_hint, iFp)
+GO(gdk_window_get_type_hint, uFp)
GO(gdk_window_get_update_area, pFp)
GO(gdk_window_get_user_data, vFpp)
GO(gdk_window_get_visual, pFp)
GO(gdk_window_get_width, iFp)
-GO(gdk_window_get_window_type, iFp)
+GO(gdk_window_get_window_type, uFp)
GO(gdk_window_has_native, iFp)
GO(gdk_window_hide, vFp)
GO(gdk_window_hints_get_type, LFv)
@@ -646,7 +646,7 @@ GO(gdk_window_is_input_only, iFp)
GO(gdk_window_is_shaped, iFp)
GO(gdk_window_is_viewable, iFp)
GO(gdk_window_is_visible, iFp)
-GO(gdk_window_lookup, pFp)
+GO(gdk_window_lookup, pFu)
GO(gdk_window_lookup_for_display, pFpp)
GO(gdk_window_lower, vFp)
GO(gdk_window_maximize, vFp)
@@ -677,11 +677,11 @@ GO(gdk_window_set_child_shapes, vFp)
GO(gdk_window_set_composited, vFpi)
GO(gdk_window_set_cursor, vFpp)
GO(gdk_window_set_debug_updates, vFi)
-GO(gdk_window_set_decorations, vFpp)
-GO(gdk_window_set_events, vFpp)
+GO(gdk_window_set_decorations, vFpu)
+GO(gdk_window_set_events, vFpu)
GO(gdk_window_set_focus_on_map, vFpi)
GO(gdk_window_set_functions, vFpu)
-GO(gdk_window_set_geometry_hints, vFppi)
+GO(gdk_window_set_geometry_hints, vFppu)
GO(gdk_window_set_group, vFpp)
GO(gdk_window_set_hints, vFpiiiiiii)
GO(gdk_window_set_icon, vFpppp)
@@ -690,7 +690,7 @@ GO(gdk_window_set_icon_name, vFpp)
GO(gdk_window_set_keep_above, vFpi)
GO(gdk_window_set_keep_below, vFpi)
GO(gdk_window_set_modal_hint, iFp)
-GO(gdk_window_set_opacity, vFpi)
+GO(gdk_window_set_opacity, vFpd)
GO(gdk_window_set_override_redirect, vFpi)
GO(gdk_window_set_role, vFpp)
GO(gdk_window_set_skip_pager_hint, vFpi)
@@ -699,7 +699,7 @@ GO(gdk_window_set_startup_id, vFpp)
GO(gdk_window_set_static_gravities, iFpi)
GO(gdk_window_set_title, vFpp)
GO(gdk_window_set_transient_for, vFpp)
-GO(gdk_window_set_type_hint, vFpi)
+GO(gdk_window_set_type_hint, vFpu)
GO(gdk_window_set_urgency_hint, vFpi)
GO(gdk_window_set_user_data, vFpp)
GO(gdk_window_shape_combine_mask, vFppii)
@@ -789,4 +789,4 @@ GO(dummy_set_child_property, vFppupp) // to get vFppupp for gtkclass.c
GO2(gdk_pixmap_ref, pFp, g_object_ref)
GO2(gdk_pixmap_unref, vFp, g_object_unref)
GO2(gdk_bitmap_ref, pFp, g_object_ref)
-GO2(gdk_bitmap_unref, vFp, g_object_unref) \ No newline at end of file
+GO2(gdk_bitmap_unref, vFp, g_object_unref)
diff --git a/src/wrapped/wrappedgio2.c b/src/wrapped/wrappedgio2.c
index dbc67d7..e4837e7 100755..100644
--- a/src/wrapped/wrappedgio2.c
+++ b/src/wrapped/wrappedgio2.c
@@ -18,11 +18,16 @@
#include "box64context.h"
#include "emu/x64emu_private.h"
#include "myalign.h"
+#include "gtkclass.h"
const char* gio2Name = "libgio-2.0.so.0";
#define LIBNAME gio2
+typedef size_t(*LFv_t)(void);
+
#define ADDED_FUNCTIONS() \
+ GO(g_application_get_type, LFv_t) \
+ GO(g_dbus_proxy_get_type, LFv_t) \
#include "wrappedgio2types.h"
@@ -36,10 +41,10 @@ GO(3)
// GAsyncReadyCallback
#define GO(A) \
-static uintptr_t my_GAsyncReadyCallback_fct_##A = 0; \
-static void my_GAsyncReadyCallback_##A(void* source, void* res, void* data) \
-{ \
- RunFunction(my_context, my_GAsyncReadyCallback_fct_##A, 3, source, res, data);\
+static uintptr_t my_GAsyncReadyCallback_fct_##A = 0; \
+static void my_GAsyncReadyCallback_##A(void* source, void* res, void* data) \
+{ \
+ RunFunctionFmt(my_GAsyncReadyCallback_fct_##A, "ppp", source, res, data); \
}
SUPER()
#undef GO
@@ -59,10 +64,10 @@ static void* findGAsyncReadyCallbackFct(void* fct)
// GDestroyNotify
#define GO(A) \
-static uintptr_t my_GDestroyNotify_fct_##A = 0; \
-static void my_GDestroyNotify_##A(void* data) \
-{ \
- RunFunction(my_context, my_GDestroyNotify_fct_##A, 1, data);\
+static uintptr_t my_GDestroyNotify_fct_##A = 0; \
+static void my_GDestroyNotify_##A(void* data) \
+{ \
+ RunFunctionFmt(my_GDestroyNotify_fct_##A, "p", data); \
}
SUPER()
#undef GO
@@ -82,10 +87,10 @@ static void* findGDestroyNotifyFct(void* fct)
// GDBusProxyTypeFunc
#define GO(A) \
-static uintptr_t my_GDBusProxyTypeFunc_fct_##A = 0; \
-static int my_GDBusProxyTypeFunc_##A(void* manager, void* path, void* name, void* data) \
-{ \
- return (int)RunFunction(my_context, my_GDBusProxyTypeFunc_fct_##A, 4, manager, path, name, data);\
+static uintptr_t my_GDBusProxyTypeFunc_fct_##A = 0; \
+static int my_GDBusProxyTypeFunc_##A(void* manager, void* path, void* name, void* data) \
+{ \
+ return (int)RunFunctionFmt(my_GDBusProxyTypeFunc_fct_##A, "pppp", manager, path, name, data); \
}
SUPER()
#undef GO
@@ -105,10 +110,10 @@ static void* findGDBusProxyTypeFuncFct(void* fct)
// GSimpleAsyncThreadFunc
#define GO(A) \
-static uintptr_t my_GSimpleAsyncThreadFunc_fct_##A = 0; \
-static void my_GSimpleAsyncThreadFunc_##A(void* res, void* object, void* cancellable) \
-{ \
- RunFunction(my_context, my_GSimpleAsyncThreadFunc_fct_##A, 3, res, object, cancellable);\
+static uintptr_t my_GSimpleAsyncThreadFunc_fct_##A = 0; \
+static void my_GSimpleAsyncThreadFunc_##A(void* res, void* object, void* cancellable) \
+{ \
+ RunFunctionFmt(my_GSimpleAsyncThreadFunc_fct_##A, "ppp", res, object, cancellable); \
}
SUPER()
#undef GO
@@ -128,10 +133,10 @@ static void* findGSimpleAsyncThreadFuncFct(void* fct)
// GCallback
#define GO(A) \
-static uintptr_t my_GCallback_fct_##A = 0; \
-static void my_GCallback_##A(void* a, void* b, void* c, void* d) \
-{ \
- RunFunction(my_context, my_GCallback_fct_##A, 4, a, b, c, d);\
+static uintptr_t my_GCallback_fct_##A = 0; \
+static void my_GCallback_##A(void* a, void* b, void* c, void* d) \
+{ \
+ RunFunctionFmt(my_GCallback_fct_##A, "pppp", a, b, c, d); \
}
SUPER()
#undef GO
@@ -151,10 +156,10 @@ static void* findGCallbackFct(void* fct)
// GDBusSignalCallback
#define GO(A) \
-static uintptr_t my_GDBusSignalCallback_fct_##A = 0; \
-static void my_GDBusSignalCallback_##A(void* connection, void* sender, void* object, void* interface, void* signal, void* param, void* data) \
-{ \
- RunFunction(my_context, my_GDBusSignalCallback_fct_##A, 7, connection, sender, object, interface, signal, param, data);\
+static uintptr_t my_GDBusSignalCallback_fct_##A = 0; \
+static void my_GDBusSignalCallback_##A(void* connection, void* sender, void* object, void* interface, void* signal, void* param, void* data) \
+{ \
+ RunFunctionFmt(my_GDBusSignalCallback_fct_##A, "ppppppp", connection, sender, object, interface, signal, param, data); \
}
SUPER()
#undef GO
@@ -174,10 +179,10 @@ static void* findGDBusSignalCallbackFct(void* fct)
// GDBusMessageFilterFunction
#define GO(A) \
-static uintptr_t my_GDBusMessageFilterFunction_fct_##A = 0; \
-static void my_GDBusMessageFilterFunction_##A(void* connection, void* message, int incoming, void* data) \
-{ \
- RunFunction(my_context, my_GDBusMessageFilterFunction_fct_##A, 4, connection, message, incoming, data);\
+static uintptr_t my_GDBusMessageFilterFunction_fct_##A = 0; \
+static void my_GDBusMessageFilterFunction_##A(void* connection, void* message, int incoming, void* data) \
+{ \
+ RunFunctionFmt(my_GDBusMessageFilterFunction_fct_##A, "ppip", connection, message, incoming, data); \
}
SUPER()
#undef GO
@@ -197,10 +202,10 @@ static void* findGDBusMessageFilterFunctionFct(void* fct)
// GBusNameAppearedCallback
#define GO(A) \
-static uintptr_t my_GBusNameAppearedCallback_fct_##A = 0; \
-static void my_GBusNameAppearedCallback_##A(void* connection, void* name, void* owner, void* data) \
-{ \
- RunFunction(my_context, my_GBusNameAppearedCallback_fct_##A, 4, connection, name, owner, data); \
+static uintptr_t my_GBusNameAppearedCallback_fct_##A = 0; \
+static void my_GBusNameAppearedCallback_##A(void* connection, void* name, void* owner, void* data) \
+{ \
+ RunFunctionFmt(my_GBusNameAppearedCallback_fct_##A, "pppp", connection, name, owner, data); \
}
SUPER()
#undef GO
@@ -220,10 +225,10 @@ static void* findGBusNameAppearedCallbackFct(void* fct)
// GBusNameVanishedCallback
#define GO(A) \
-static uintptr_t my_GBusNameVanishedCallback_fct_##A = 0; \
-static void my_GBusNameVanishedCallback_##A(void* connection, void* name, void* data) \
-{ \
- RunFunction(my_context, my_GBusNameVanishedCallback_fct_##A, 3, connection, name, data);\
+static uintptr_t my_GBusNameVanishedCallback_fct_##A = 0; \
+static void my_GBusNameVanishedCallback_##A(void* connection, void* name, void* data) \
+{ \
+ RunFunctionFmt(my_GBusNameVanishedCallback_fct_##A, "ppp", connection, name, data); \
}
SUPER()
#undef GO
@@ -243,10 +248,10 @@ static void* findGBusNameVanishedCallbackFct(void* fct)
// GBusAcquiredCallback
#define GO(A) \
-static uintptr_t my_GBusAcquiredCallback_fct_##A = 0; \
-static void my_GBusAcquiredCallback_##A(void* connection, void* name, void* data) \
-{ \
- RunFunction(my_context, my_GBusAcquiredCallback_fct_##A, 3, connection, name, data);\
+static uintptr_t my_GBusAcquiredCallback_fct_##A = 0; \
+static void my_GBusAcquiredCallback_##A(void* connection, void* name, void* data) \
+{ \
+ RunFunctionFmt(my_GBusAcquiredCallback_fct_##A, "ppp", connection, name, data); \
}
SUPER()
#undef GO
@@ -266,10 +271,10 @@ static void* findGBusAcquiredCallbackFct(void* fct)
// GBusNameAcquiredCallback
#define GO(A) \
-static uintptr_t my_GBusNameAcquiredCallback_fct_##A = 0; \
-static void my_GBusNameAcquiredCallback_##A(void* connection, void* name, void* data) \
-{ \
- RunFunction(my_context, my_GBusNameAcquiredCallback_fct_##A, 3, connection, name, data);\
+static uintptr_t my_GBusNameAcquiredCallback_fct_##A = 0; \
+static void my_GBusNameAcquiredCallback_##A(void* connection, void* name, void* data) \
+{ \
+ RunFunctionFmt(my_GBusNameAcquiredCallback_fct_##A, "ppp", connection, name, data); \
}
SUPER()
#undef GO
@@ -289,10 +294,10 @@ static void* findGBusNameAcquiredCallbackFct(void* fct)
// GBusNameLostCallback
#define GO(A) \
-static uintptr_t my_GBusNameLostCallback_fct_##A = 0; \
-static void my_GBusNameLostCallback_##A(void* connection, void* name, void* data) \
-{ \
- RunFunction(my_context, my_GBusNameLostCallback_fct_##A, 3, connection, name, data);\
+static uintptr_t my_GBusNameLostCallback_fct_##A = 0; \
+static void my_GBusNameLostCallback_##A(void* connection, void* name, void* data) \
+{ \
+ RunFunctionFmt(my_GBusNameLostCallback_fct_##A, "ppp", connection, name, data); \
}
SUPER()
#undef GO
@@ -318,24 +323,24 @@ typedef struct my_GDBusInterfaceVTable_s {
int (*set_property) (void* connection, void* sender, void* object_path, void* interface_name, void* value, void* error, void* user_data);
} my_GDBusInterfaceVTable_t;
-#define GO(A) \
+#define GO(A) \
static my_GDBusInterfaceVTable_t my_GDBusInterfaceVTable_##A = {0}; \
static my_GDBusInterfaceVTable_t *ref_GDBusInterfaceVTable_##A = NULL;
SUPER()
#undef GO
// then the static functions callback that may be used with the structure, but dispatch also have a callback...
#define GO(A) \
-static uintptr_t fct_funcs_method_call_##A = 0; \
-static void my_funcs_method_call_##A(void* connection, void* sender, void* object_path, void* interface_name, void* method_name, void* invocation, void* user_data) { \
- RunFunction(my_context, fct_funcs_method_call_##A, 8, connection, sender, object_path, interface_name, method_name, invocation, user_data); \
-} \
-static uintptr_t fct_funcs_get_property_##A = 0; \
-static void* my_funcs_get_property_##A(void* connection, void* sender, void* object_path, void* interface_name, void* error, void* user_data) { \
- return (void*)RunFunction(my_context, fct_funcs_get_property_##A, 7, connection, sender, object_path, interface_name, error, user_data); \
-} \
-static uintptr_t fct_funcs_set_property_##A = 0; \
-static int my_funcs_set_property_##A(void* connection, void* sender, void* object_path, void* interface_name, void* value, void* error, void* user_data) { \
- return (int)RunFunction(my_context, fct_funcs_set_property_##A, 8, connection, sender, object_path, interface_name, value, error, user_data); \
+static uintptr_t fct_funcs_method_call_##A = 0; \
+static void my_funcs_method_call_##A(void* connection, void* sender, void* object_path, void* interface_name, void* method_name, void* parameters, void* invocation, void* user_data) { \
+ RunFunctionFmt(fct_funcs_method_call_##A, "pppppppp", connection, sender, object_path, interface_name, method_name, parameters, invocation, user_data); \
+} \
+static uintptr_t fct_funcs_get_property_##A = 0; \
+static void* my_funcs_get_property_##A(void* connection, void* sender, void* object_path, void* interface_name, void* property_name, void* error, void* user_data) { \
+ return (void*)RunFunctionFmt(fct_funcs_get_property_##A, "ppppppp", connection, sender, object_path, interface_name, property_name, error, user_data); \
+} \
+static uintptr_t fct_funcs_set_property_##A = 0; \
+static int my_funcs_set_property_##A(void* connection, void* sender, void* object_path, void* interface_name, void* property_name, void* value, void* error, void* user_data) { \
+ return (int)RunFunctionFmt(fct_funcs_set_property_##A, "pppppppp", connection, sender, object_path, interface_name, property_name, value, error, user_data); \
}
SUPER()
@@ -364,6 +369,16 @@ static my_GDBusInterfaceVTable_t* findFreeGDBusInterfaceVTable(my_GDBusInterface
}
#undef SUPER
+EXPORT void* my_g_task_new(x64emu_t* emu, void* source_object, void* cancellable, void* cb, void* data)
+{
+ return my->g_task_new(source_object, cancellable, findGAsyncReadyCallbackFct(cb), data);
+}
+
+EXPORT void my_g_task_return_pointer(x64emu_t* emu, void* task, void* result, void* destroy)
+{
+ my->g_task_return_pointer(task, result, findGDestroyNotifyFct(destroy));
+}
+
EXPORT void my_g_dbus_proxy_new(x64emu_t* emu, void* connection, int flags, void* info, void* name, void* path, void* interface, void* cancellable, void* cb, void* data)
{
my->g_dbus_proxy_new(connection, flags, info, name, path, interface, cancellable, findGAsyncReadyCallbackFct(cb), data);
@@ -563,8 +578,22 @@ EXPORT void my_g_simple_async_result_set_error(x64emu_t* emu, void* simple, void
EXPORT void* my_g_initable_new(x64emu_t* emu, void* type, void* cancel, void* err, void* first, uintptr_t* b)
{
- myStackAlign(emu, first, b, emu->scratch, R_EAX, 4);
+ #if 0
+ // look for number of pairs
+ int n = 1;
+ emu->scratch[0] = (uint64_t)first;
+ emu->scratch[1] = getVArgs(emu, 4, b, 0);
+ while(getVArgs(emu, 4, b, n)) {
+ emu->scratch[n+1] = getVArgs(emu, 4, b, n);
+ emu->scratch[n+2] = getVArgs(emu, 4, b, n+1);
+ n+=2;
+ }
+ emu->scratch[n+1] = 0;
+ emu->scratch[n+2] = 0;
PREPARE_VALIST;
+ #else
+ CREATE_VALIST_FROM_VAARG(b, emu->scratch, 4);
+ #endif
return my->g_initable_new_valist(type, first, VARARGS, cancel, err);
}
@@ -578,13 +607,23 @@ EXPORT void* my_g_initable_new_valist(x64emu_t* emu, void* type, void* first, x6
return my->g_initable_new_valist(type, first, VARARGS, cancel, err);
}
+EXPORT void my_g_task_return_new_error(x64emu_t* emu, void* task, uint32_t domain, int code, void *fmt, va_list b)
+{
+ char* tmp;
+ int dummy = vasprintf(&tmp, fmt, b);
+ (void)dummy;
+ my->g_task_return_new_error(task, domain, code, tmp);
+ free(tmp);
+}
#define PRE_INIT \
if(box64_nogtk) \
return -1;
#define CUSTOM_INIT \
- getMy(lib); \
+ getMy(lib); \
+ SetGApplicationID(my->g_application_get_type()); \
+ SetGDBusProxyID(my->g_dbus_proxy_get_type()); \
setNeededLibs(lib, 1, "libgmodule-2.0.so.0");
#define CUSTOM_FINI \
diff --git a/src/wrapped/wrappedgio2_private.h b/src/wrapped/wrappedgio2_private.h
index dca16c2..560b251 100755..100644
--- a/src/wrapped/wrappedgio2_private.h
+++ b/src/wrapped/wrappedgio2_private.h
@@ -3,17 +3,17 @@
#endif
//GO(_fini,
-//GO(g_action_activate,
+GO(g_action_activate, vFpp)
//GO(g_action_change_state,
-//GO(g_action_get_enabled,
-//GO(g_action_get_name,
+GO(g_action_get_enabled, iFp)
+GO(g_action_get_name, pFp)
//GO(g_action_get_parameter_type,
-//GO(g_action_get_state,
+GO(g_action_get_state, pFp)
//GO(g_action_get_state_hint,
-//GO(g_action_get_state_type,
+GO(g_action_get_state_type, pFp)
//GO(g_action_get_type,
GO(g_action_group_action_added, vFpp)
-GO(g_action_group_action_enabled_changed, vFppp)
+GO(g_action_group_action_enabled_changed, vFppi)
GO(g_action_group_action_removed, vFpp)
GO(g_action_group_action_state_changed, vFppp)
GO(g_action_group_activate_action, vFppp)
@@ -27,14 +27,14 @@ GO(g_action_group_get_type, LFv)
GO(g_action_group_has_action, iFpp)
GO(g_action_group_list_actions, pFp)
GO(g_action_group_query_action, iFppppppp)
-//GO(g_action_map_add_action,
-//GO(g_action_map_add_action_entries,
+GO(g_action_map_add_action, vFpp)
+GO(g_action_map_add_action_entries, vFppip)
//GO(g_action_map_get_type,
-//GO(g_action_map_lookup_action,
-//GO(g_action_map_remove_action,
+GO(g_action_map_lookup_action, pFpp)
+GO(g_action_map_remove_action, vFpp)
//GO(g_action_name_is_valid,
-//GO(g_action_parse_detailed_name,
-//GO(g_action_print_detailed_name,
+GO(g_action_parse_detailed_name, iFpppp)
+GO(g_action_print_detailed_name, pFpp)
GO(g_app_info_add_supports_type, iFppp)
GO(g_app_info_can_delete, iFp)
GO(g_app_info_can_remove_supports_type, iFp)
@@ -46,7 +46,7 @@ GO(g_app_info_equal, iFpp)
GO(g_app_info_get_all, pFv)
GO(g_app_info_get_all_for_type, pFp)
GO(g_app_info_get_commandline, pFp)
-GO(g_app_info_get_default_for_type, pFpp)
+GO(g_app_info_get_default_for_type, pFpi)
GO(g_app_info_get_default_for_uri_scheme, pFp)
GO(g_app_info_get_description, pFp)
GO(g_app_info_get_display_name, pFp)
@@ -61,7 +61,7 @@ GO(g_app_info_get_type, LFv)
GO(g_app_info_launch, iFpppp)
GO(g_app_info_launch_default_for_uri, iFppp)
GO(g_app_info_launch_uris, iFpppp)
-//GO(g_app_info_monitor_get,
+GO(g_app_info_monitor_get, pFv)
GO(g_app_info_monitor_get_type, LFv)
GO(g_app_info_remove_supports_type, iFppp)
GO(g_app_info_reset_type_associations, vFp)
@@ -72,60 +72,60 @@ GO(g_app_info_should_show, iFp)
GO(g_app_info_supports_files, iFp)
GO(g_app_info_supports_uris, iFp)
//GO(g_app_launch_context_get_display,
-//GO(g_app_launch_context_get_environment,
-//GO(g_app_launch_context_get_startup_notify_id,
+GO(g_app_launch_context_get_environment, pFp)
+GO(g_app_launch_context_get_startup_notify_id, pFppp)
GO(g_app_launch_context_get_type, LFv)
-//GO(g_app_launch_context_launch_failed,
-//GO(g_app_launch_context_new,
-//GO(g_app_launch_context_setenv,
+GO(g_app_launch_context_launch_failed, vFpp)
+GO(g_app_launch_context_new, pFv)
+GO(g_app_launch_context_setenv, vFppp)
//GO(g_app_launch_context_unsetenv,
-//GO(g_application_activate,
-//GO(g_application_add_main_option,
-//GO(g_application_add_main_option_entries,
-//GO(g_application_add_option_group,
-//GO(g_application_command_line_create_file_for_arg,
-//GO(g_application_command_line_get_arguments,
-//GO(g_application_command_line_get_cwd,
-//GO(g_application_command_line_getenv,
-//GO(g_application_command_line_get_environ,
-//GO(g_application_command_line_get_exit_status,
-//GO(g_application_command_line_get_is_remote,
-//GO(g_application_command_line_get_options_dict,
-//GO(g_application_command_line_get_platform_data,
-//GO(g_application_command_line_get_stdin,
+GO(g_application_activate, vFp)
+GO(g_application_add_main_option, vFppCuupp)
+GO(g_application_add_main_option_entries, vFpp)
+GO(g_application_add_option_group, vFpp)
+GO(g_application_command_line_create_file_for_arg, pFpp)
+GO(g_application_command_line_get_arguments, pFpp)
+GO(g_application_command_line_get_cwd, pFp)
+GO(g_application_command_line_getenv, pFpp)
+GO(g_application_command_line_get_environ, pFp)
+GO(g_application_command_line_get_exit_status, iFp)
+GO(g_application_command_line_get_is_remote, iFp)
+GO(g_application_command_line_get_options_dict, pFp)
+GO(g_application_command_line_get_platform_data, pFp)
+GO(g_application_command_line_get_stdin, pFp)
//GO(g_application_command_line_get_type,
//GO(g_application_command_line_print,
//GO(g_application_command_line_printerr,
-//GO(g_application_command_line_set_exit_status,
+GO(g_application_command_line_set_exit_status, vFpi)
//GO(g_application_flags_get_type,
//GO(g_application_get_application_id,
-//GO(g_application_get_dbus_connection,
+GO(g_application_get_dbus_connection, pFp)
//GO(g_application_get_dbus_object_path,
-//GO(g_application_get_default,
-//GO(g_application_get_flags,
-//GO(g_application_get_inactivity_timeout,
+GO(g_application_get_default, pFv)
+GO(g_application_get_flags, uFp)
+GO(g_application_get_inactivity_timeout, uFp)
//GO(g_application_get_is_registered,
//GO(g_application_get_is_remote,
-//GO(g_application_get_resource_base_path,
-//GO(g_application_get_type,
+GO(g_application_get_resource_base_path, pFp)
+GO(g_application_get_type, LFv)
//GO(g_application_hold,
//GO(g_application_id_is_valid,
//GO(g_application_mark_busy,
-//GO(g_application_new,
-//GO(g_application_open,
-//GO(g_application_quit,
-//GO(g_application_register,
-//GO(g_application_release,
-//GO(g_application_run,
-//GO(g_application_send_notification,
-//GO(g_application_set_action_group,
+GO(g_application_new, pFpu)
+GO(g_application_open, vFppip)
+GO(g_application_quit, vFp)
+GO(g_application_register, iFppp)
+GO(g_application_release, vFp)
+GO(g_application_run, iFpip)
+GO(g_application_send_notification, vFppp)
+GO(g_application_set_action_group, vFpp)
//GO(g_application_set_application_id,
//GO(g_application_set_default,
-//GO(g_application_set_flags,
-//GO(g_application_set_inactivity_timeout,
+GO(g_application_set_flags, vFpu)
+GO(g_application_set_inactivity_timeout, vFpu)
//GO(g_application_set_resource_base_path,
//GO(g_application_unmark_busy,
-//GO(g_application_withdraw_notification,
+GO(g_application_withdraw_notification, vFpp)
//GO(g_ask_password_flags_get_type,
GO(g_async_initable_get_type, LFv)
GOM(g_async_initable_init_async, vFEpippp)
@@ -134,30 +134,30 @@ GOM(g_async_initable_new_async, vFEiippppV)
GO(g_async_initable_new_finish, pFppp)
GOM(g_async_initable_new_valist_async, vFEipAippp)
GOM(g_async_initable_newv_async, vFEiupippp)
-//GO(g_async_result_get_source_object,
-//GO(g_async_result_get_type,
-//GO(g_async_result_get_user_data,
-//GO(g_async_result_is_tagged,
+GO(g_async_result_get_source_object, pFp)
+GO(g_async_result_get_type, LFv)
+GO(g_async_result_get_user_data, pFp)
+GO(g_async_result_is_tagged, iFpp)
//GO(g_async_result_legacy_propagate_error,
-//GO(g_buffered_input_stream_fill,
+GO(g_buffered_input_stream_fill, lFplpp)
//GO(g_buffered_input_stream_fill_async,
-//GO(g_buffered_input_stream_fill_finish,
-//GO(g_buffered_input_stream_get_available,
+GO(g_buffered_input_stream_fill_finish, lFppp)
+GO(g_buffered_input_stream_get_available, LFp)
//GO(g_buffered_input_stream_get_buffer_size,
//GO(g_buffered_input_stream_get_type,
-//GO(g_buffered_input_stream_new,
-//GO(g_buffered_input_stream_new_sized,
-//GO(g_buffered_input_stream_peek,
-//GO(g_buffered_input_stream_peek_buffer,
-//GO(g_buffered_input_stream_read_byte,
-//GO(g_buffered_input_stream_set_buffer_size,
-//GO(g_buffered_output_stream_get_auto_grow,
-//GO(g_buffered_output_stream_get_buffer_size,
+GO(g_buffered_input_stream_new, pFp)
+GO(g_buffered_input_stream_new_sized, pFpL)
+GO(g_buffered_input_stream_peek, LFppLL)
+GO(g_buffered_input_stream_peek_buffer, pFpp)
+GO(g_buffered_input_stream_read_byte, iFppp)
+GO(g_buffered_input_stream_set_buffer_size, vFpL)
+GO(g_buffered_output_stream_get_auto_grow, iFp)
+GO(g_buffered_output_stream_get_buffer_size, LFp)
//GO(g_buffered_output_stream_get_type,
-//GO(g_buffered_output_stream_new,
-//GO(g_buffered_output_stream_new_sized,
-//GO(g_buffered_output_stream_set_auto_grow,
-//GO(g_buffered_output_stream_set_buffer_size,
+GO(g_buffered_output_stream_new, pFp)
+GO(g_buffered_output_stream_new_sized, pFpL)
+GO(g_buffered_output_stream_set_auto_grow, vFpi)
+GO(g_buffered_output_stream_set_buffer_size, vFpL)
GOM(g_bus_get, vFEippp)
GO(g_bus_get_finish, pFpp)
GO(g_bus_get_sync, pFipp)
@@ -174,9 +174,9 @@ GOM(g_bus_watch_name, uFEipipppp)
GOM(g_bus_watch_name_on_connection, uFEppipppp)
GO(g_bus_watch_name_on_connection_with_closures, uFppipp) // mmm closure, wrapped or unwrapped?
GO(g_bus_watch_name_with_closures, uFipipp)
-//GO(g_bytes_icon_get_bytes,
+GO(g_bytes_icon_get_bytes, pFp)
//GO(g_bytes_icon_get_type,
-//GO(g_bytes_icon_new,
+GO(g_bytes_icon_new, pFp)
GO(g_cancellable_cancel, vFp)
GOM(g_cancellable_connect, LFEpppp)
GO(g_cancellable_disconnect, vFpL)
@@ -192,11 +192,11 @@ GO(g_cancellable_release_fd, vFp)
GO(g_cancellable_reset, vFp)
GO(g_cancellable_set_error_if_cancelled, iFpp)
GO(g_cancellable_source_new, pFp)
-//GO(g_charset_converter_get_num_fallbacks,
+GO(g_charset_converter_get_num_fallbacks, uFp)
GO(g_charset_converter_get_type, LFv)
-//GO(g_charset_converter_get_use_fallback,
-//GO(g_charset_converter_new,
-//GO(g_charset_converter_set_use_fallback,
+GO(g_charset_converter_get_use_fallback, iFp)
+GO(g_charset_converter_new, pFppp)
+GO(g_charset_converter_set_use_fallback, vFpi)
GO(g_content_type_can_be_executable, iFp)
GO(g_content_type_equals, iFpp)
GO(g_content_type_from_mime_type, pFp)
@@ -210,72 +210,72 @@ GO(g_content_type_guess_for_tree, pFp)
GO(g_content_type_is_a, iFpp)
GO(g_content_type_is_unknown, iFp)
GO(g_content_types_get_registered, pFv)
-//GO(g_converter_convert,
+GO(g_converter_convert, uFppLpLuppp)
//GO(g_converter_flags_get_type,
//GO(g_converter_get_type,
-//GO(g_converter_input_stream_get_converter,
+GO(g_converter_input_stream_get_converter, pFp)
//GO(g_converter_input_stream_get_type,
-//GO(g_converter_input_stream_new,
-//GO(g_converter_output_stream_get_converter,
+GO(g_converter_input_stream_new, pFpp)
+GO(g_converter_output_stream_get_converter, pFp)
//GO(g_converter_output_stream_get_type,
-//GO(g_converter_output_stream_new,
+GO(g_converter_output_stream_new, pFpp)
//GO(g_converter_reset,
//GO(g_converter_result_get_type,
-//GO(g_credentials_get_native,
+GO(g_credentials_get_native, pFpu)
//GO(g_credentials_get_type,
-//GO(g_credentials_get_unix_pid,
-//GO(g_credentials_get_unix_user,
-//GO(g_credentials_is_same_user,
-//GO(g_credentials_new,
-//GO(g_credentials_set_native,
-//GO(g_credentials_set_unix_user,
-//GO(g_credentials_to_string,
+GO(g_credentials_get_unix_pid, iFpp)
+GO(g_credentials_get_unix_user, uFpp)
+GO(g_credentials_is_same_user, iFppp)
+GO(g_credentials_new, pFv)
+GO(g_credentials_set_native, vFpup)
+GO(g_credentials_set_unix_user, iFpup)
+GO(g_credentials_to_string, pFp)
//GO(g_credentials_type_get_type,
-//GO(g_data_input_stream_get_byte_order,
-//GO(g_data_input_stream_get_newline_type,
+GO(g_data_input_stream_get_byte_order, uFp)
+GO(g_data_input_stream_get_newline_type, uFp)
//GO(g_data_input_stream_get_type,
-//GO(g_data_input_stream_new,
-//GO(g_data_input_stream_read_byte,
-//GO(g_data_input_stream_read_int16,
-//GO(g_data_input_stream_read_int32,
-//GO(g_data_input_stream_read_int64,
+GO(g_data_input_stream_new, pFp)
+GO(g_data_input_stream_read_byte, CFppp)
+GO(g_data_input_stream_read_int16, wFppp)
+GO(g_data_input_stream_read_int32, iFppp)
+GO(g_data_input_stream_read_int64, lFppp)
//GO(g_data_input_stream_read_line,
//GO(g_data_input_stream_read_line_async,
//GO(g_data_input_stream_read_line_finish,
//GO(g_data_input_stream_read_line_finish_utf8,
-//GO(g_data_input_stream_read_line_utf8,
-//GO(g_data_input_stream_read_uint16,
-//GO(g_data_input_stream_read_uint32,
-//GO(g_data_input_stream_read_uint64,
-//GO(g_data_input_stream_read_until,
+GO(g_data_input_stream_read_line_utf8, pFpppp)
+GO(g_data_input_stream_read_uint16, WFppp)
+GO(g_data_input_stream_read_uint32, uFppp)
+GO(g_data_input_stream_read_uint64, LFppp)
+GO(g_data_input_stream_read_until, pFppppp)
//GO(g_data_input_stream_read_until_async,
//GO(g_data_input_stream_read_until_finish,
-//GO(g_data_input_stream_read_upto,
+GO(g_data_input_stream_read_upto, pFpplppp)
//GO(g_data_input_stream_read_upto_async,
-//GO(g_data_input_stream_read_upto_finish,
-//GO(g_data_input_stream_set_byte_order,
-//GO(g_data_input_stream_set_newline_type,
-//GO(g_data_output_stream_get_byte_order,
+GO(g_data_input_stream_read_upto_finish, pFpppp)
+GO(g_data_input_stream_set_byte_order, vFpu)
+GO(g_data_input_stream_set_newline_type, vFpu)
+GO(g_data_output_stream_get_byte_order, uFp)
//GO(g_data_output_stream_get_type,
-//GO(g_data_output_stream_new,
-//GO(g_data_output_stream_put_byte,
-//GO(g_data_output_stream_put_int16,
-//GO(g_data_output_stream_put_int32,
-//GO(g_data_output_stream_put_int64,
-//GO(g_data_output_stream_put_string,
-//GO(g_data_output_stream_put_uint16,
-//GO(g_data_output_stream_put_uint32,
-//GO(g_data_output_stream_put_uint64,
-//GO(g_data_output_stream_set_byte_order,
+GO(g_data_output_stream_new, pFp)
+GO(g_data_output_stream_put_byte, iFpCpp)
+GO(g_data_output_stream_put_int16, iFpwpp)
+GO(g_data_output_stream_put_int32, iFpipp)
+GO(g_data_output_stream_put_int64, iFplpp)
+GO(g_data_output_stream_put_string, iFpppp)
+GO(g_data_output_stream_put_uint16, iFpWpp)
+GO(g_data_output_stream_put_uint32, iFpupp)
+GO(g_data_output_stream_put_uint64, iFpLpp)
+GO(g_data_output_stream_set_byte_order, vFpu)
//GO(g_data_stream_byte_order_get_type,
//GO(g_data_stream_newline_type_get_type,
-//GO(g_dbus_action_group_get,
+GO(g_dbus_action_group_get, pFppp)
//GO(g_dbus_action_group_get_type,
//GO(g_dbus_address_escape_value,
-//GO(g_dbus_address_get_for_bus_sync,
+GO(g_dbus_address_get_for_bus_sync, pFipp)
//GO(g_dbus_address_get_stream,
-//GO(g_dbus_address_get_stream_finish,
-//GO(g_dbus_address_get_stream_sync,
+GO(g_dbus_address_get_stream_finish, pFppp)
+GO(g_dbus_address_get_stream_sync, pFpppp)
GO(g_dbus_annotation_info_get_type, LFv)
GO(g_dbus_annotation_info_lookup, pFpp)
GO(g_dbus_annotation_info_ref, pFp)
@@ -283,30 +283,30 @@ GO(g_dbus_annotation_info_unref, vFp)
GO(g_dbus_arg_info_get_type, LFv)
GO(g_dbus_arg_info_ref, pFp)
GO(g_dbus_arg_info_unref, vFp)
-//GO(g_dbus_auth_observer_allow_mechanism,
-//GO(g_dbus_auth_observer_authorize_authenticated_peer,
+GO(g_dbus_auth_observer_allow_mechanism, iFpp)
+GO(g_dbus_auth_observer_authorize_authenticated_peer, iFppp)
//GO(g_dbus_auth_observer_get_type,
-//GO(g_dbus_auth_observer_new,
+GO(g_dbus_auth_observer_new, pFv)
GO(g_dbus_call_flags_get_type, LFv)
GO(g_dbus_capability_flags_get_type, LFv)
GOM(g_dbus_connection_add_filter, uFEpppp)
GOM(g_dbus_connection_call, vFEpppppppiippp)
GO(g_dbus_connection_call_finish, pFppp)
-GO(g_dbus_connection_call_sync, pFpppppppiipp)
+GO(g_dbus_connection_call_sync, pFpppppppuipp)
//GO(g_dbus_connection_call_with_unix_fd_list,
-//GO(g_dbus_connection_call_with_unix_fd_list_finish,
-//GO(g_dbus_connection_call_with_unix_fd_list_sync,
+GO(g_dbus_connection_call_with_unix_fd_list_finish, pFpppp)
+GO(g_dbus_connection_call_with_unix_fd_list_sync, pFpppppppuipppp)
GOM(g_dbus_connection_close, vFEpppp)
GO(g_dbus_connection_close_finish, iFppp)
GO(g_dbus_connection_close_sync, iFppp)
GO(g_dbus_connection_emit_signal, iFppppppp)
-//GO(g_dbus_connection_export_action_group,
-//GO(g_dbus_connection_export_menu_model,
+GO(g_dbus_connection_export_action_group, uFpppp)
+GO(g_dbus_connection_export_menu_model, uFpppp)
GO(g_dbus_connection_flags_get_type, LFv)
GOM(g_dbus_connection_flush, vFEpppp)
GO(g_dbus_connection_flush_finish, iFppp)
GO(g_dbus_connection_flush_sync, iFppp)
-GO(g_dbus_connection_get_capabilities, iFp)
+GO(g_dbus_connection_get_capabilities, uFp)
GO(g_dbus_connection_get_exit_on_close, iFp)
GO(g_dbus_connection_get_guid, pFp)
GO(g_dbus_connection_get_last_serial, uFp)
@@ -319,40 +319,40 @@ GOM(g_dbus_connection_new, vFEppipppp)
GO(g_dbus_connection_new_finish, pFpp)
GOM(g_dbus_connection_new_for_address, vFEpipppp)
GO(g_dbus_connection_new_for_address_finish, pFpp)
-GO(g_dbus_connection_new_for_address_sync, pFpippp)
-GO(g_dbus_connection_new_sync, pFppippp)
+GO(g_dbus_connection_new_for_address_sync, pFpuppp)
+GO(g_dbus_connection_new_sync, pFppuppp)
GOM(g_dbus_connection_register_object, uFEppppppp)
//GOM(g_dbus_connection_register_subtree, uFEppppppp) // vtable need wrapping
GO(g_dbus_connection_remove_filter, vFpu)
-GO(g_dbus_connection_send_message, iFppipp) //TODO: there is an argument as "volatile".. does that change anything???
+GO(g_dbus_connection_send_message, iFppupp)
GOM(g_dbus_connection_send_message_with_reply, vFEppiipppp) //TODO: same volatile argument...
GO(g_dbus_connection_send_message_with_reply_finish, pFppp)
-GO(g_dbus_connection_send_message_with_reply_sync, pFppiippp) //TODO: same volatile
+GO(g_dbus_connection_send_message_with_reply_sync, pFppuippp)
GO(g_dbus_connection_set_exit_on_close, vFpi)
GOM(g_dbus_connection_signal_subscribe, uFEppppppippp)
GO(g_dbus_connection_signal_unsubscribe, vFpu)
GO(g_dbus_connection_start_message_processing, vFp)
//GO(g_dbus_connection_unexport_action_group,
-//GO(g_dbus_connection_unexport_menu_model,
+GO(g_dbus_connection_unexport_menu_model, vFpu)
GO(g_dbus_connection_unregister_object, iFpu)
GO(g_dbus_connection_unregister_subtree, iFpu)
-//GO(g_dbus_error_encode_gerror,
+GO(g_dbus_error_encode_gerror, pFp)
//GO(g_dbus_error_get_remote_error,
//GO(g_dbus_error_get_type,
-//GO(g_dbus_error_is_remote_error,
-//GO(g_dbus_error_new_for_dbus_error,
-//GO(g_dbus_error_quark,
+GO(g_dbus_error_is_remote_error, iFp)
+GO(g_dbus_error_new_for_dbus_error, pFpp)
+GO(g_dbus_error_quark, uFv)
//GO(g_dbus_error_register_error,
GO(g_dbus_error_register_error_domain, vFpppu)
//GO(g_dbus_error_set_dbus_error,
//GO(g_dbus_error_set_dbus_error_valist,
-//GO(g_dbus_error_strip_remote_error,
-//GO(g_dbus_error_unregister_error,
+GO(g_dbus_error_strip_remote_error, iFp)
+GO(g_dbus_error_unregister_error, iFuip)
GO(g_dbus_generate_guid, pFv)
GO(g_dbus_gvalue_to_gvariant, pFpp)
GO(g_dbus_gvariant_to_gvalue, vFpp)
-//GO(g_dbus_interface_dup_object,
-//GO(g_dbus_interface_get_info,
+GO(g_dbus_interface_dup_object, pFp)
+GO(g_dbus_interface_get_info, pFp)
//GO(g_dbus_interface_get_object,
//GO(g_dbus_interface_get_type,
GO(g_dbus_interface_info_cache_build, vFp)
@@ -364,22 +364,22 @@ GO(g_dbus_interface_info_lookup_property, pFpp)
GO(g_dbus_interface_info_lookup_signal, pFpp)
GO(g_dbus_interface_info_ref, pFp)
GO(g_dbus_interface_info_unref, vFp)
-//GO(g_dbus_interface_set_object,
-//GO(g_dbus_interface_skeleton_export,
+GO(g_dbus_interface_set_object, vFpp)
+GO(g_dbus_interface_skeleton_export, iFpppp)
//GO(g_dbus_interface_skeleton_flags_get_type,
//GO(g_dbus_interface_skeleton_flush,
-//GO(g_dbus_interface_skeleton_get_connection,
-//GO(g_dbus_interface_skeleton_get_connections,
-//GO(g_dbus_interface_skeleton_get_flags,
-//GO(g_dbus_interface_skeleton_get_info,
-//GO(g_dbus_interface_skeleton_get_object_path,
-//GO(g_dbus_interface_skeleton_get_properties,
+GO(g_dbus_interface_skeleton_get_connection, pFp)
+GO(g_dbus_interface_skeleton_get_connections, pFp)
+GO(g_dbus_interface_skeleton_get_flags, uFp)
+GO(g_dbus_interface_skeleton_get_info, pFp)
+GO(g_dbus_interface_skeleton_get_object_path, pFp)
+GO(g_dbus_interface_skeleton_get_properties, pFp)
//GO(g_dbus_interface_skeleton_get_type,
//GO(g_dbus_interface_skeleton_get_vtable,
-//GO(g_dbus_interface_skeleton_has_connection,
-//GO(g_dbus_interface_skeleton_set_flags,
+GO(g_dbus_interface_skeleton_has_connection, iFpp)
+GO(g_dbus_interface_skeleton_set_flags, vFpu)
//GO(g_dbus_interface_skeleton_unexport,
-//GO(g_dbus_interface_skeleton_unexport_from_connection,
+GO(g_dbus_interface_skeleton_unexport_from_connection, vFpp)
GO(g_dbus_is_address, iFp)
GO(g_dbus_is_guid, iFp)
GO(g_dbus_is_interface_name, iFp)
@@ -395,16 +395,16 @@ GO(g_dbus_message_copy, pFpp)
GO(g_dbus_message_flags_get_type, LFv)
GO(g_dbus_message_get_arg0, pFp)
GO(g_dbus_message_get_body, pFp)
-GO(g_dbus_message_get_byte_order, iFp)
+GO(g_dbus_message_get_byte_order, uFp)
GO(g_dbus_message_get_destination, pFp)
GO(g_dbus_message_get_error_name, pFp)
-GO(g_dbus_message_get_flags, iFp)
-GO(g_dbus_message_get_header, pFpi)
+GO(g_dbus_message_get_flags, uFp)
+GO(g_dbus_message_get_header, pFpu)
GO(g_dbus_message_get_header_fields, pFp)
GO(g_dbus_message_get_interface, pFp)
GO(g_dbus_message_get_locked, iFp)
GO(g_dbus_message_get_member, pFp)
-GO(g_dbus_message_get_message_type, iFp)
+GO(g_dbus_message_get_message_type, uFp)
GO(g_dbus_message_get_num_unix_fds, uFp)
GO(g_dbus_message_get_path, pFp)
GO(g_dbus_message_get_reply_serial, uFp)
@@ -416,7 +416,7 @@ GO(g_dbus_message_get_unix_fd_list, pFp)
GO(g_dbus_message_header_field_get_type, LFv)
GO(g_dbus_message_lock, vFp)
GO(g_dbus_message_new, pFv)
-GO(g_dbus_message_new_from_blob, pFpLip)
+GO(g_dbus_message_new_from_blob, pFpLup)
GO(g_dbus_message_new_method_call, pFpppp)
//GO2(g_dbus_message_new_method_error, pFpppV, g_dbus_message_new_method_error_valist)
GO(g_dbus_message_new_method_error_literal, pFppp)
@@ -425,14 +425,14 @@ GO(g_dbus_message_new_method_reply, pFp)
GO(g_dbus_message_new_signal, pFppp)
GO(g_dbus_message_print, pFpu)
GO(g_dbus_message_set_body, vFpp)
-GO(g_dbus_message_set_byte_order, iFp)
+GO(g_dbus_message_set_byte_order, vFpu)
GO(g_dbus_message_set_destination, vFpp)
GO(g_dbus_message_set_error_name, vFpp)
-GO(g_dbus_message_set_flags, vFpi)
-GO(g_dbus_message_set_header, vFpip)
+GO(g_dbus_message_set_flags, vFpu)
+GO(g_dbus_message_set_header, vFpup)
GO(g_dbus_message_set_interface, vFpp)
GO(g_dbus_message_set_member, vFpp)
-GO(g_dbus_message_set_message_type, vFpi)
+GO(g_dbus_message_set_message_type, vFpu)
GO(g_dbus_message_set_num_unix_fds, vFpu)
GO(g_dbus_message_set_path, vFpp)
GO(g_dbus_message_set_reply_serial, vFpu)
@@ -440,7 +440,7 @@ GO(g_dbus_message_set_sender, vFpp)
GO(g_dbus_message_set_serial, vFpu)
GO(g_dbus_message_set_signature, vFpp)
GO(g_dbus_message_set_unix_fd_list, vFpp)
-GO(g_dbus_message_to_blob, pFppip)
+GO(g_dbus_message_to_blob, pFppup)
GO(g_dbus_message_to_gerror, iFpp)
GO(g_dbus_message_type_get_type, LFv)
GO(g_dbus_method_info_get_type, LFv)
@@ -477,7 +477,7 @@ GO(g_dbus_object_get_object_path, pFp)
GO(g_dbus_object_get_type, LFv)
GO(g_dbus_object_manager_client_flags_get_type, LFv)
GO(g_dbus_object_manager_client_get_connection, pFp)
-GO(g_dbus_object_manager_client_get_flags, iFp)
+GO(g_dbus_object_manager_client_get_flags, uFp)
GO(g_dbus_object_manager_client_get_name, pFp)
GO(g_dbus_object_manager_client_get_name_owner, pFp)
GO(g_dbus_object_manager_client_get_type, LFv)
@@ -493,39 +493,39 @@ GO(g_dbus_object_manager_get_object_path, pFp)
GO(g_dbus_object_manager_get_objects, pFp)
//GO(g_dbus_object_manager_get_type,
//GO(g_dbus_object_manager_server_export,
-//GO(g_dbus_object_manager_server_export_uniquely,
-//GO(g_dbus_object_manager_server_get_connection,
+GO(g_dbus_object_manager_server_export_uniquely, vFpp)
+GO(g_dbus_object_manager_server_get_connection, pFp)
//GO(g_dbus_object_manager_server_get_type,
-//GO(g_dbus_object_manager_server_is_exported,
-//GO(g_dbus_object_manager_server_new,
-//GO(g_dbus_object_manager_server_set_connection,
-//GO(g_dbus_object_manager_server_unexport,
-//GO(g_dbus_object_proxy_get_connection,
+GO(g_dbus_object_manager_server_is_exported, iFpp)
+GO(g_dbus_object_manager_server_new, pFp)
+GO(g_dbus_object_manager_server_set_connection, vFpp)
+GO(g_dbus_object_manager_server_unexport, iFpp)
+GO(g_dbus_object_proxy_get_connection, pFp)
//GO(g_dbus_object_proxy_get_type,
-//GO(g_dbus_object_proxy_new,
+GO(g_dbus_object_proxy_new, pFpp)
//GO(g_dbus_object_skeleton_add_interface,
//GO(g_dbus_object_skeleton_flush,
//GO(g_dbus_object_skeleton_get_type,
-//GO(g_dbus_object_skeleton_new,
-//GO(g_dbus_object_skeleton_remove_interface,
+GO(g_dbus_object_skeleton_new, pFp)
+GO(g_dbus_object_skeleton_remove_interface, vFpp)
//GO(g_dbus_object_skeleton_remove_interface_by_name,
-//GO(g_dbus_object_skeleton_set_object_path,
+GO(g_dbus_object_skeleton_set_object_path, vFpp)
//GO(g_dbus_property_info_flags_get_type,
GO(g_dbus_property_info_get_type, LFv)
GO(g_dbus_property_info_ref, pFp)
GO(g_dbus_property_info_unref, vFp)
GOM(g_dbus_proxy_call, vFEpppiippp)
GO(g_dbus_proxy_call_finish, pFppp)
-GO(g_dbus_proxy_call_sync, pFpppiipp)
+GO(g_dbus_proxy_call_sync, pFpppuipp)
GOM(g_dbus_proxy_call_with_unix_fd_list, vFEpppiipppp)
GO(g_dbus_proxy_call_with_unix_fd_list_finish, pFpppp)
-GO(g_dbus_proxy_call_with_unix_fd_list_sync, pFpppiipppp)
+GO(g_dbus_proxy_call_with_unix_fd_list_sync, pFpppuipppp)
GO(g_dbus_proxy_flags_get_type, LFv)
GO(g_dbus_proxy_get_cached_property, pFpp)
GO(g_dbus_proxy_get_cached_property_names, pFp)
GO(g_dbus_proxy_get_connection, pFp)
GO(g_dbus_proxy_get_default_timeout, iFp)
-GO(g_dbus_proxy_get_flags, iFp)
+GO(g_dbus_proxy_get_flags, uFp)
GO(g_dbus_proxy_get_interface_info, pFp)
GO(g_dbus_proxy_get_interface_name, pFp)
GO(g_dbus_proxy_get_name, pFp)
@@ -536,19 +536,19 @@ GOM(g_dbus_proxy_new, vFEpippppppp)
GO(g_dbus_proxy_new_finish, pFpp)
GOM(g_dbus_proxy_new_for_bus, vFEiippppppp)
GO(g_dbus_proxy_new_for_bus_finish, pFpp)
-GO(g_dbus_proxy_new_for_bus_sync, pFiipppppp)
-GO(g_dbus_proxy_new_sync, pFpipppppp)
+GO(g_dbus_proxy_new_for_bus_sync, pFiupppppp)
+GO(g_dbus_proxy_new_sync, pFpupppppp)
GO(g_dbus_proxy_set_cached_property, vFppp)
GO(g_dbus_proxy_set_default_timeout, vFpi)
GO(g_dbus_proxy_set_interface_info, vFpp)
//GO(g_dbus_send_message_flags_get_type,
//GO(g_dbus_server_flags_get_type,
//GO(g_dbus_server_get_client_address,
-//GO(g_dbus_server_get_flags,
-//GO(g_dbus_server_get_guid,
+GO(g_dbus_server_get_flags, uFp)
+GO(g_dbus_server_get_guid, pFp)
//GO(g_dbus_server_get_type,
-//GO(g_dbus_server_is_active,
-//GO(g_dbus_server_new_sync,
+GO(g_dbus_server_is_active, iFp)
+GO(g_dbus_server_new_sync, pFpupppp)
//GO(g_dbus_server_start,
//GO(g_dbus_server_stop,
//GO(g_dbus_signal_flags_get_type,
@@ -567,7 +567,7 @@ GO(g_desktop_app_info_get_keywords, pFp)
GO(g_desktop_app_info_get_nodisplay, iFp)
GO(g_desktop_app_info_get_show_in, iFpp)
//GO(g_desktop_app_info_get_startup_wm_class,
-//GO(g_desktop_app_info_get_string,
+GO(g_desktop_app_info_get_string, pFpp)
GO(g_desktop_app_info_get_type, LFv)
//GO(g_desktop_app_info_has_key,
//GO(g_desktop_app_info_launch_action,
@@ -584,20 +584,20 @@ GO(g_desktop_app_info_set_desktop_env, vFp)
//GO(g_drive_can_poll_for_media,
//GO(g_drive_can_start,
//GO(g_drive_can_start_degraded,
-//GO(g_drive_can_stop,
+GO(g_drive_can_stop, iFp)
//GO(g_drive_eject,
//GO(g_drive_eject_finish,
//GO(g_drive_eject_with_operation,
-//GO(g_drive_eject_with_operation_finish,
-//GO(g_drive_enumerate_identifiers,
+GO(g_drive_eject_with_operation_finish, iFppp)
+GO(g_drive_enumerate_identifiers, pFp)
//GO(g_drive_get_icon,
-//GO(g_drive_get_identifier,
-//GO(g_drive_get_name,
-//GO(g_drive_get_sort_key,
-//GO(g_drive_get_start_stop_type,
-//GO(g_drive_get_symbolic_icon,
+GO(g_drive_get_identifier, pFpp)
+GO(g_drive_get_name, pFp)
+GO(g_drive_get_sort_key, pFp)
+GO(g_drive_get_start_stop_type, uFp)
+GO(g_drive_get_symbolic_icon, pFp)
//GO(g_drive_get_type,
-//GO(g_drive_get_volumes,
+GO(g_drive_get_volumes, pFp)
//GO(g_drive_has_media,
//GO(g_drive_has_volumes,
//GO(g_drive_is_media_check_automatic,
@@ -610,51 +610,51 @@ GO(g_desktop_app_info_set_desktop_env, vFp)
//GO(g_drive_start_stop_type_get_type,
//GO(g_drive_stop,
//GO(g_drive_stop_finish,
-//GO(g_emblemed_icon_add_emblem,
+GO(g_emblemed_icon_add_emblem, vFpp)
//GO(g_emblemed_icon_clear_emblems,
-//GO(g_emblemed_icon_get_emblems,
-//GO(g_emblemed_icon_get_icon,
+GO(g_emblemed_icon_get_emblems, pFp)
+GO(g_emblemed_icon_get_icon, pFp)
//GO(g_emblemed_icon_get_type,
-//GO(g_emblemed_icon_new,
-//GO(g_emblem_get_icon,
-//GO(g_emblem_get_origin,
+GO(g_emblemed_icon_new, pFpp)
+GO(g_emblem_get_icon, pFp)
+GO(g_emblem_get_origin, uFp)
//GO(g_emblem_get_type,
-//GO(g_emblem_new,
-//GO(g_emblem_new_with_origin,
+GO(g_emblem_new, pFp)
+GO(g_emblem_new_with_origin, pFpu)
//GO(g_emblem_origin_get_type,
GO(g_file_append_to, pFpipp)
//GOM(g_file_append_to_async, vFEpiipBp)
GO(g_file_append_to_finish, pFppp)
//GO(g_file_attribute_info_flags_get_type,
-//GO(g_file_attribute_info_list_add,
-//GO(g_file_attribute_info_list_dup,
+GO(g_file_attribute_info_list_add, vFppuu)
+GO(g_file_attribute_info_list_dup, pFp)
//GO(g_file_attribute_info_list_get_type,
-//GO(g_file_attribute_info_list_lookup,
-//GO(g_file_attribute_info_list_new,
+GO(g_file_attribute_info_list_lookup, pFpp)
+GO(g_file_attribute_info_list_new, pFv)
//GO(g_file_attribute_info_list_ref,
//GO(g_file_attribute_info_list_unref,
-//GO(g_file_attribute_matcher_enumerate_namespace,
-//GO(g_file_attribute_matcher_enumerate_next,
+GO(g_file_attribute_matcher_enumerate_namespace, iFpp)
+GO(g_file_attribute_matcher_enumerate_next, pFp)
//GO(g_file_attribute_matcher_get_type,
//GO(g_file_attribute_matcher_matches,
//GO(g_file_attribute_matcher_matches_only,
-//GO(g_file_attribute_matcher_new,
-//GO(g_file_attribute_matcher_ref,
-//GO(g_file_attribute_matcher_subtract,
-//GO(g_file_attribute_matcher_to_string,
-//GO(g_file_attribute_matcher_unref,
+GO(g_file_attribute_matcher_new, pFp)
+GO(g_file_attribute_matcher_ref, pFp)
+GO(g_file_attribute_matcher_subtract, pFpp)
+GO(g_file_attribute_matcher_to_string, pFp)
+GO(g_file_attribute_matcher_unref, vFp)
//GO(g_file_attribute_status_get_type,
//GO(g_file_attribute_type_get_type,
//GOM(g_file_copy, iFEppipBpp)
//GOM(g_file_copy_async, vFEppiipBpBp)
-GO(g_file_copy_attributes, iFppipp)
+GO(g_file_copy_attributes, iFppupp)
GO(g_file_copy_finish, iFppp)
GO(g_file_copy_flags_get_type, LFv)
-GO(g_file_create, pFpipp)
+GO(g_file_create, pFpupp)
//GOM(g_file_create_async, vFEpiipBp)
GO(g_file_create_finish, pFppp)
GO(g_file_create_flags_get_type, LFv)
-GO(g_file_create_readwrite, pFpipp)
+GO(g_file_create_readwrite, pFpupp)
//GOM(g_file_create_readwrite_async, vFEpiipBp)
GO(g_file_create_readwrite_finish, pFppp)
GO(g_file_delete, iFppp)
@@ -667,21 +667,21 @@ GO(g_file_dup, pFp)
GO(g_file_eject_mountable_finish, iFppp)
//GOM(g_file_eject_mountable_with_operation, vFpippBp)
GO(g_file_eject_mountable_with_operation_finish, iFppp)
-GO(g_file_enumerate_children, pFppipp)
+GO(g_file_enumerate_children, pFppupp)
//GOM(g_file_enumerate_children_async, vFppiipBp)
GO(g_file_enumerate_children_finish, pFppp)
-//GO(g_file_enumerator_close,
+GO(g_file_enumerator_close, iFppp)
//GO(g_file_enumerator_close_async,
-//GO(g_file_enumerator_close_finish,
-//GO(g_file_enumerator_get_child,
-//GO(g_file_enumerator_get_container,
+GO(g_file_enumerator_close_finish, iFppp)
+GO(g_file_enumerator_get_child, pFpp)
+GO(g_file_enumerator_get_container, pFp)
//GO(g_file_enumerator_get_type,
-//GO(g_file_enumerator_has_pending,
+GO(g_file_enumerator_has_pending, iFp)
//GO(g_file_enumerator_is_closed,
-//GO(g_file_enumerator_next_file,
+GO(g_file_enumerator_next_file, pFppp)
//GO(g_file_enumerator_next_files_async,
-//GO(g_file_enumerator_next_files_finish,
-//GO(g_file_enumerator_set_pending,
+GO(g_file_enumerator_next_files_finish, pFppp)
+GO(g_file_enumerator_set_pending, vFpi)
GO(g_file_equal, iFpp)
GO(g_file_find_enclosing_mount, pFppp)
//GOM(g_file_find_enclosing_mount_async, vFEpipBp)
@@ -704,78 +704,78 @@ GO(g_file_icon_get_file, pFp)
GO(g_file_icon_get_type, LFv)
GO(g_file_icon_new, pFp)
//GO(g_file_info_clear_status,
-//GO(g_file_info_copy_into,
-//GO(g_file_info_dup,
-//GO(g_file_info_get_attribute_as_string,
-//GO(g_file_info_get_attribute_boolean,
-//GO(g_file_info_get_attribute_byte_string,
-//GO(g_file_info_get_attribute_data,
-//GO(g_file_info_get_attribute_int32,
-//GO(g_file_info_get_attribute_int64,
-//GO(g_file_info_get_attribute_object,
-//GO(g_file_info_get_attribute_status,
+GO(g_file_info_copy_into, vFpp)
+GO(g_file_info_dup, pFp)
+GO(g_file_info_get_attribute_as_string, pFpp)
+GO(g_file_info_get_attribute_boolean, iFpp)
+GO(g_file_info_get_attribute_byte_string, pFpp)
+GO(g_file_info_get_attribute_data, iFppppp)
+GO(g_file_info_get_attribute_int32, iFpp)
+GO(g_file_info_get_attribute_int64, lFpp)
+GO(g_file_info_get_attribute_object, pFpp)
+GO(g_file_info_get_attribute_status, uFpp)
//GO(g_file_info_get_attribute_string,
-//GO(g_file_info_get_attribute_stringv,
-//GO(g_file_info_get_attribute_type,
-//GO(g_file_info_get_attribute_uint32,
-//GO(g_file_info_get_attribute_uint64,
+GO(g_file_info_get_attribute_stringv, pFpp)
+GO(g_file_info_get_attribute_type, uFpp)
+GO(g_file_info_get_attribute_uint32, uFpp)
+GO(g_file_info_get_attribute_uint64, LFpp)
//GO(g_file_info_get_content_type,
//GO(g_file_info_get_deletion_date,
//GO(g_file_info_get_display_name,
//GO(g_file_info_get_edit_name,
-//GO(g_file_info_get_etag,
-//GO(g_file_info_get_file_type,
+GO(g_file_info_get_etag, pFp)
+GO(g_file_info_get_file_type, uFp)
//GO(g_file_info_get_icon,
//GO(g_file_info_get_is_backup,
//GO(g_file_info_get_is_hidden,
-//GO(g_file_info_get_is_symlink,
+GO(g_file_info_get_is_symlink, iFp)
//GO(g_file_info_get_modification_time,
//GO(g_file_info_get_name,
-//GO(g_file_info_get_size,
-//GO(g_file_info_get_sort_order,
-//GO(g_file_info_get_symbolic_icon,
+GO(g_file_info_get_size, lFp)
+GO(g_file_info_get_sort_order, iFp)
+GO(g_file_info_get_symbolic_icon, pFp)
//GO(g_file_info_get_symlink_target,
//GO(g_file_info_get_type,
//GO(g_file_info_has_attribute,
//GO(g_file_info_has_namespace,
//GO(g_file_info_list_attributes,
-//GO(g_file_info_new,
+GO(g_file_info_new, pFv)
//GO(g_file_info_remove_attribute,
-//GO(g_file_info_set_attribute,
-//GO(g_file_info_set_attribute_boolean,
-//GO(g_file_info_set_attribute_byte_string,
-//GO(g_file_info_set_attribute_int32,
-//GO(g_file_info_set_attribute_int64,
-//GO(g_file_info_set_attribute_mask,
-//GO(g_file_info_set_attribute_object,
-//GO(g_file_info_set_attribute_status,
+GO(g_file_info_set_attribute, vFppup)
+GO(g_file_info_set_attribute_boolean, vFppi)
+GO(g_file_info_set_attribute_byte_string, vFppp)
+GO(g_file_info_set_attribute_int32, vFppi)
+GO(g_file_info_set_attribute_int64, vFppl)
+GO(g_file_info_set_attribute_mask, vFpp)
+GO(g_file_info_set_attribute_object, vFppp)
+GO(g_file_info_set_attribute_status, iFppu)
//GO(g_file_info_set_attribute_string,
-//GO(g_file_info_set_attribute_stringv,
-//GO(g_file_info_set_attribute_uint32,
-//GO(g_file_info_set_attribute_uint64,
+GO(g_file_info_set_attribute_stringv, vFppp)
+GO(g_file_info_set_attribute_uint32, vFppu)
+GO(g_file_info_set_attribute_uint64, vFppL)
//GO(g_file_info_set_content_type,
//GO(g_file_info_set_display_name,
//GO(g_file_info_set_edit_name,
-//GO(g_file_info_set_file_type,
+GO(g_file_info_set_file_type, vFpu)
//GO(g_file_info_set_icon,
//GO(g_file_info_set_is_hidden,
-//GO(g_file_info_set_is_symlink,
-//GO(g_file_info_set_modification_time,
+GO(g_file_info_set_is_symlink, vFpi)
+GO(g_file_info_set_modification_time, vFpp)
//GO(g_file_info_set_name,
-//GO(g_file_info_set_size,
-//GO(g_file_info_set_sort_order,
-//GO(g_file_info_set_symbolic_icon,
-//GO(g_file_info_set_symlink_target,
+GO(g_file_info_set_size, vFpl)
+GO(g_file_info_set_sort_order, vFpi)
+GO(g_file_info_set_symbolic_icon, vFpp)
+GO(g_file_info_set_symlink_target, vFpp)
//GO(g_file_info_unset_attribute_mask,
//GO(g_file_input_stream_get_type,
-//GO(g_file_input_stream_query_info,
+GO(g_file_input_stream_query_info, pFpppp)
//GO(g_file_input_stream_query_info_async,
-//GO(g_file_input_stream_query_info_finish,
-//GO(g_file_io_stream_get_etag,
+GO(g_file_input_stream_query_info_finish, pFppp)
+GO(g_file_io_stream_get_etag, pFp)
//GO(g_file_io_stream_get_type,
-//GO(g_file_io_stream_query_info,
+GO(g_file_io_stream_query_info, pFpppp)
//GO(g_file_io_stream_query_info_async,
-//GO(g_file_io_stream_query_info_finish,
+GO(g_file_io_stream_query_info_finish, pFppp)
GO(g_file_is_native, iFpp)
GO(g_file_load_bytes, pFpppp) //sice 2.56+
//GOM(g_file_load_bytes_async, vFEppBp) //since 2.56+
@@ -794,26 +794,26 @@ GO(g_file_make_symbolic_link, iFpppp)
//GOM(g_file_measure_disk_usage_async, vFEpiipBpBp)
GO(g_file_measure_disk_usage_finish, iFpppppp)
//GO(g_file_measure_flags_get_type,
-GO(g_file_monitor, pFpipp)
+GO(g_file_monitor, pFpupp)
//GO(g_file_monitor_cancel,
GO(g_file_monitor_directory, pFpipp)
-//GO(g_file_monitor_emit_event,
+GO(g_file_monitor_emit_event, vFpppu)
//GO(g_file_monitor_event_get_type,
GO(g_file_monitor_file, pFpipp)
//GO(g_file_monitor_flags_get_type,
//GO(g_file_monitor_get_type,
-//GO(g_file_monitor_is_cancelled,
-//GO(g_file_monitor_set_rate_limit,
+GO(g_file_monitor_is_cancelled, iFp)
+GO(g_file_monitor_set_rate_limit, vFpi)
//GOM(g_file_mount_enclosing_volume, vFEpippBp)
GO(g_file_mount_enclosing_volume_finish, iFppp)
//GOM(g_file_mount_mountable, vFEpippBp)
GO(g_file_mount_mountable_finish, pFppp)
//GOM(g_file_move, iFEppipBpp)
-//GO(g_filename_completer_get_completions,
-//GO(g_filename_completer_get_completion_suffix,
+GO(g_filename_completer_get_completions, pFpp)
+GO(g_filename_completer_get_completion_suffix, pFpp)
//GO(g_filename_completer_get_type,
-//GO(g_filename_completer_new,
-//GO(g_filename_completer_set_dirs_only,
+GO(g_filename_completer_new, pFv)
+GO(g_filename_completer_set_dirs_only, vFpi)
GO(g_file_new_build_filename, pFppppppppppp) // vaarg, since v2.56+
GO(g_file_new_for_commandline_arg, pFp)
GO(g_file_new_for_commandline_arg_and_cwd, pFpp)
@@ -823,11 +823,11 @@ GO(g_file_new_tmp, pFppp)
GO(g_file_open_readwrite, pFppp)
//GOM(g_file_open_readwrite_async, vFEpipBp)
GO(g_file_open_readwrite_finish, pFppp)
-//GO(g_file_output_stream_get_etag,
+GO(g_file_output_stream_get_etag, pFp)
//GO(g_file_output_stream_get_type,
-//GO(g_file_output_stream_query_info,
+GO(g_file_output_stream_query_info, pFpppp)
//GO(g_file_output_stream_query_info_async,
-//GO(g_file_output_stream_query_info_finish,
+GO(g_file_output_stream_query_info_finish, pFppp)
GO(g_file_parse_name, pFp)
GO(g_file_peek_path , pFp) // sice 2.56+
//GOM(g_file_poll_mountable, vFEppBp)
@@ -839,8 +839,8 @@ GO(g_file_query_exists, iFpp)
GO(g_file_query_filesystem_info, pFpppp)
//GOM(g_file_query_filesystem_info_async, vFEppipBp)
GO(g_file_query_filesystem_info_finish, pFppp)
-GO(g_file_query_file_type, iFpip)
-GO(g_file_query_info, pFppipp)
+GO(g_file_query_file_type, uFpup)
+GO(g_file_query_info, pFppupp)
//GOM(g_file_query_info_async, vFEppiipBp)
GO(g_file_query_info_finish, pFppp)
//GO(g_file_query_info_flags_get_type,
@@ -849,27 +849,27 @@ GO(g_file_query_writable_namespaces, pFppp)
GO(g_file_read, pFppp)
//GOM(g_file_read_async, vFEpipBp)
GO(g_file_read_finish, pFppp)
-GO(g_file_replace, pFppiipp)
+GO(g_file_replace, pFppiupp)
//GOM(g_file_replace_async, vFEppiiipBp)
-GO(g_file_replace_contents, iFppLpiippp)
+GO(g_file_replace_contents, iFppLpiuppp)
//GOM(g_file_replace_contents_async, vFEppLpuupBp)
//GOM(g_file_replace_contents_bytes_async, vFEpppiipBp)
GO(g_file_replace_contents_finish, iFpppp)
-//GO(g_file_replace_finish,
-GO(g_file_replace_readwrite, pFppiipp)
+GO(g_file_replace_finish, pFppp)
+GO(g_file_replace_readwrite, pFppiupp)
//GOM(g_file_replace_readwrite_async, vFEppiiipBp)
GO(g_file_replace_readwrite_finish, pFppp)
GO(g_file_resolve_relative_path, pFpp)
-GO(g_file_set_attribute, iFppipipp)
-GO(g_file_set_attribute_byte_string, iFpppipp)
-GO(g_file_set_attribute_int32, iFppiipp)
-GO(g_file_set_attribute_int64, iFppIipp)
+GO(g_file_set_attribute, iFppupupp)
+GO(g_file_set_attribute_byte_string, iFpppupp)
+GO(g_file_set_attribute_int32, iFppiupp)
+GO(g_file_set_attribute_int64, iFpplupp)
//GOM(g_file_set_attributes_async, vFEppiipBp)
GO(g_file_set_attributes_finish, iFpppp)
-GO(g_file_set_attributes_from_info, iFppipp)
+GO(g_file_set_attributes_from_info, iFppupp)
GO(g_file_set_attribute_string, iFpppipp)
-GO(g_file_set_attribute_uint32, iFppuipp)
-GO(g_file_set_attribute_uint64, iFppUipp)
+GO(g_file_set_attribute_uint32, iFppuupp)
+GO(g_file_set_attribute_uint64, iFppLupp)
GO(g_file_set_display_name, pFpppp)
//GOM(g_file_set_display_name_async, vFEppipBp)
GO(g_file_set_display_name_finish, pFppp)
@@ -887,14 +887,14 @@ GO(g_file_type_get_type, LFv)
GO(g_file_unmount_mountable_finish, iFppp)
//GOM(g_file_unmount_mountable_with_operation, vFEpippBp)
GO(g_file_unmount_mountable_with_operation_finish, iFppp)
-//GO(g_filter_input_stream_get_base_stream,
-//GO(g_filter_input_stream_get_close_base_stream,
+GO(g_filter_input_stream_get_base_stream, pFp)
+GO(g_filter_input_stream_get_close_base_stream, iFp)
//GO(g_filter_input_stream_get_type,
-//GO(g_filter_input_stream_set_close_base_stream,
-//GO(g_filter_output_stream_get_base_stream,
-//GO(g_filter_output_stream_get_close_base_stream,
+GO(g_filter_input_stream_set_close_base_stream, vFpi)
+GO(g_filter_output_stream_get_base_stream, pFp)
+GO(g_filter_output_stream_get_close_base_stream, iFp)
//GO(g_filter_output_stream_get_type,
-//GO(g_filter_output_stream_set_close_base_stream,
+GO(g_filter_output_stream_set_close_base_stream, vFpi)
GO(g_icon_deserialize, pFp)
GO(g_icon_equal, iFpp)
//GO(g_icon_get_type,
@@ -902,8 +902,8 @@ GO(g_icon_hash, uFp)
GO(g_icon_new_for_string, pFpp)
GO(g_icon_serialize, pFp)
GO(g_icon_to_string, pFp)
-//GO(g_inet_address_equal,
-//GO(g_inet_address_get_family,
+GO(g_inet_address_equal, iFpp)
+GO(g_inet_address_get_family, uFp)
//GO(g_inet_address_get_is_any,
//GO(g_inet_address_get_is_link_local,
//GO(g_inet_address_get_is_loopback,
@@ -911,212 +911,212 @@ GO(g_icon_to_string, pFp)
//GO(g_inet_address_get_is_mc_link_local,
//GO(g_inet_address_get_is_mc_node_local,
//GO(g_inet_address_get_is_mc_org_local,
-//GO(g_inet_address_get_is_mc_site_local,
+GO(g_inet_address_get_is_mc_site_local, iFp)
//GO(g_inet_address_get_is_multicast,
//GO(g_inet_address_get_is_site_local,
-//GO(g_inet_address_get_native_size,
+GO(g_inet_address_get_native_size, LFp)
//GO(g_inet_address_get_type,
-//GO(g_inet_address_mask_equal,
-//GO(g_inet_address_mask_get_address,
-//GO(g_inet_address_mask_get_family,
-//GO(g_inet_address_mask_get_length,
+GO(g_inet_address_mask_equal, iFpp)
+GO(g_inet_address_mask_get_address, pFp)
+GO(g_inet_address_mask_get_family, uFp)
+GO(g_inet_address_mask_get_length, uFp)
//GO(g_inet_address_mask_get_type,
-//GO(g_inet_address_mask_matches,
-//GO(g_inet_address_mask_new,
-//GO(g_inet_address_mask_new_from_string,
-//GO(g_inet_address_mask_to_string,
-//GO(g_inet_address_new_any,
-//GO(g_inet_address_new_from_bytes,
-//GO(g_inet_address_new_from_string,
+GO(g_inet_address_mask_matches, iFpp)
+GO(g_inet_address_mask_new, pFpup)
+GO(g_inet_address_mask_new_from_string, pFpp)
+GO(g_inet_address_mask_to_string, pFp)
+GO(g_inet_address_new_any, pFu)
+GO(g_inet_address_new_from_bytes, pFpu)
+GO(g_inet_address_new_from_string, pFp)
//GO(g_inet_address_new_loopback,
-//GO(g_inet_address_to_bytes,
-//GO(g_inet_address_to_string,
-//GO(g_inet_socket_address_get_address,
+GO(g_inet_address_to_bytes, pFp)
+GO(g_inet_address_to_string, pFp)
+GO(g_inet_socket_address_get_address, pFp)
//GO(g_inet_socket_address_get_flowinfo,
-//GO(g_inet_socket_address_get_port,
-//GO(g_inet_socket_address_get_scope_id,
+GO(g_inet_socket_address_get_port, WFp)
+GO(g_inet_socket_address_get_scope_id, uFp)
//GO(g_inet_socket_address_get_type,
-//GO(g_inet_socket_address_new,
-//GO(g_inet_socket_address_new_from_string,
+GO(g_inet_socket_address_new, pFpW)
+GO(g_inet_socket_address_new_from_string, pFpu)
GO(g_initable_get_type, LFv)
GO(g_initable_init, iFppp)
GOM(g_initable_new, pFEppppV)
-GO(g_initable_newv, pFpuppp)
+GO(g_initable_newv, pFLuppp)
GOM(g_initable_new_valist, pFEppApp)
//GO(g_input_stream_clear_pending,
-//GO(g_input_stream_close,
+GO(g_input_stream_close, iFppp)
//GO(g_input_stream_close_async,
-//GO(g_input_stream_close_finish,
+GO(g_input_stream_close_finish, iFppp)
//GO(g_input_stream_get_type,
-//GO(g_input_stream_has_pending,
+GO(g_input_stream_has_pending, iFp)
//GO(g_input_stream_is_closed,
-//GO(g_input_stream_read,
-//GO(g_input_stream_read_all,
+GO(g_input_stream_read, lFppLpp)
+GO(g_input_stream_read_all, iFppLppp)
//GO(g_input_stream_read_async,
-//GO(g_input_stream_read_bytes,
+GO(g_input_stream_read_bytes, pFpLpp)
//GO(g_input_stream_read_bytes_async,
-//GO(g_input_stream_read_bytes_finish,
+GO(g_input_stream_read_bytes_finish, pFppp)
//GO(g_input_stream_read_finish,
-//GO(g_input_stream_set_pending,
-//GO(g_input_stream_skip,
+GO(g_input_stream_set_pending, iFpp)
+GO(g_input_stream_skip, lFpLpp)
//GO(g_input_stream_skip_async,
-//GO(g_input_stream_skip_finish,
+GO(g_input_stream_skip_finish, lFppp)
//GO(g_io_error_enum_get_type,
-//GO(g_io_error_from_errno,
+GO(g_io_error_from_errno, uFi)
GO(g_io_error_quark, uFv)
-//GO(g_io_extension_get_name,
-//GO(g_io_extension_get_priority,
-//GO(g_io_extension_get_type,
-//GO(g_io_extension_point_get_extension_by_name,
-//GO(g_io_extension_point_get_extensions,
-//GO(g_io_extension_point_get_required_type,
-//GO(g_io_extension_point_implement,
-//GO(g_io_extension_point_lookup,
+GO(g_io_extension_get_name, pFp)
+GO(g_io_extension_get_priority, iFp)
+GO(g_io_extension_get_type, LFp)
+GO(g_io_extension_point_get_extension_by_name, pFpp)
+GO(g_io_extension_point_get_extensions, pFp)
+GO(g_io_extension_point_get_required_type, LFp)
+GO(g_io_extension_point_implement, pFpLpi)
+GO(g_io_extension_point_lookup, pFp)
//GO(g_io_extension_point_register,
-//GO(g_io_extension_point_set_required_type,
-//GO(g_io_extension_ref_class,
+GO(g_io_extension_point_set_required_type, vFpL)
+GO(g_io_extension_ref_class, pFp)
//GO(g_io_module_get_type,
-//GO(g_io_module_new,
-//GO(g_io_module_scope_block,
+GO(g_io_module_new, pFp)
+GO(g_io_module_scope_block, vFpp)
//GO(g_io_module_scope_flags_get_type,
-//GO(g_io_module_scope_free,
-//GO(g_io_module_scope_new,
-//GO(g_io_modules_load_all_in_directory,
-//GO(g_io_modules_load_all_in_directory_with_scope,
-//GO(g_io_modules_scan_all_in_directory,
-//GO(g_io_modules_scan_all_in_directory_with_scope,
+GO(g_io_module_scope_free, vFp)
+GO(g_io_module_scope_new, pFu)
+GO(g_io_modules_load_all_in_directory, pFp)
+GO(g_io_modules_load_all_in_directory_with_scope, pFpp)
+GO(g_io_modules_scan_all_in_directory, vFp)
+GO(g_io_modules_scan_all_in_directory_with_scope, vFpp)
//GO(g_io_scheduler_cancel_all_jobs,
//GO(g_io_scheduler_job_send_to_mainloop,
//GO(g_io_scheduler_job_send_to_mainloop_async,
//GO(g_io_scheduler_push_job,
//GO(g_io_stream_clear_pending,
-//GO(g_io_stream_close,
+GO(g_io_stream_close, iFppp)
//GO(g_io_stream_close_async,
-//GO(g_io_stream_close_finish,
-//GO(g_io_stream_get_input_stream,
-//GO(g_io_stream_get_output_stream,
+GO(g_io_stream_close_finish, iFppp)
+GO(g_io_stream_get_input_stream, pFp)
+GO(g_io_stream_get_output_stream, pFp)
//GO(g_io_stream_get_type,
-//GO(g_io_stream_has_pending,
+GO(g_io_stream_has_pending, iFp)
//GO(g_io_stream_is_closed,
-//GO(g_io_stream_set_pending,
+GO(g_io_stream_set_pending, iFpp)
//GO(g_io_stream_splice_async,
-//GO(g_io_stream_splice_finish,
+GO(g_io_stream_splice_finish, iFpp)
//GO(g_io_stream_splice_flags_get_type,
//GO(g_keyfile_settings_backend_new,
GO(g_list_model_get_item, pFpu)
GO(g_list_model_get_n_items, uFp)
GO(g_list_model_get_object, pFpu)
//GO(g_loadable_icon_get_type,
-//GO(g_loadable_icon_load,
+GO(g_loadable_icon_load, pFpippp)
//GO(g_loadable_icon_load_async,
-//GO(g_loadable_icon_load_finish,
+GO(g_loadable_icon_load_finish, pFpppp)
//GO(g_local_directory_monitor_get_type,
//GO(g_local_file_monitor_get_type,
-//GO(g_memory_input_stream_add_bytes,
+GO(g_memory_input_stream_add_bytes, vFpp)
//GO(g_memory_input_stream_add_data,
//GO(g_memory_input_stream_get_type,
-//GO(g_memory_input_stream_new,
-//GO(g_memory_input_stream_new_from_bytes,
+GO(g_memory_input_stream_new, pFv)
+GO(g_memory_input_stream_new_from_bytes, pFp)
//GO(g_memory_input_stream_new_from_data,
//GO(g_memory_output_stream_get_data,
-//GO(g_memory_output_stream_get_data_size,
+GO(g_memory_output_stream_get_data_size, LFp)
//GO(g_memory_output_stream_get_size,
//GO(g_memory_output_stream_get_type,
//GO(g_memory_output_stream_new,
-//GO(g_memory_output_stream_new_resizable,
-//GO(g_memory_output_stream_steal_as_bytes,
-//GO(g_memory_output_stream_steal_data,
+GO(g_memory_output_stream_new_resizable, pFv)
+GO(g_memory_output_stream_steal_as_bytes, pFp)
+GO(g_memory_output_stream_steal_data, pFp)
//GO(g_memory_settings_backend_new,
-//GO(g_menu_append,
-//GO(g_menu_append_item,
-//GO(g_menu_append_section,
-//GO(g_menu_append_submenu,
-//GO(g_menu_attribute_iter_get_name,
-//GO(g_menu_attribute_iter_get_next,
+GO(g_menu_append, vFppp)
+GO(g_menu_append_item, vFpp)
+GO(g_menu_append_section, vFppp)
+GO(g_menu_append_submenu, vFppp)
+GO(g_menu_attribute_iter_get_name, pFp)
+GO(g_menu_attribute_iter_get_next, iFppp)
//GO(g_menu_attribute_iter_get_type,
-//GO(g_menu_attribute_iter_get_value,
-//GO(g_menu_attribute_iter_next,
+GO(g_menu_attribute_iter_get_value, pFp)
+GO(g_menu_attribute_iter_next, iFp)
//GO(g_menu_freeze,
//GO(g_menu_get_type,
-//GO(g_menu_insert,
-//GO(g_menu_insert_item,
+GO(g_menu_insert, vFpipp)
+GO(g_menu_insert_item, vFpip)
//GO(g_menu_insert_section,
-//GO(g_menu_insert_submenu,
+GO(g_menu_insert_submenu, vFpipp)
//GO(g_menu_item_get_attribute,
-//GO(g_menu_item_get_attribute_value,
-//GO(g_menu_item_get_link,
+GO(g_menu_item_get_attribute_value, pFppp)
+GO(g_menu_item_get_link, pFpp)
//GO(g_menu_item_get_type,
-//GO(g_menu_item_new,
-//GO(g_menu_item_new_from_model,
-//GO(g_menu_item_new_section,
+GO(g_menu_item_new, pFpp)
+GO(g_menu_item_new_from_model, pFpi)
+GO(g_menu_item_new_section, pFpp)
//GO(g_menu_item_new_submenu,
//GO(g_menu_item_set_action_and_target,
-//GO(g_menu_item_set_action_and_target_value,
+GO(g_menu_item_set_action_and_target_value, vFppp)
//GO(g_menu_item_set_attribute,
//GO(g_menu_item_set_attribute_value,
-//GO(g_menu_item_set_detailed_action,
-//GO(g_menu_item_set_icon,
+GO(g_menu_item_set_detailed_action, vFpp)
+GO(g_menu_item_set_icon, vFpp)
//GO(g_menu_item_set_label,
-//GO(g_menu_item_set_link,
-//GO(g_menu_item_set_section,
+GO(g_menu_item_set_link, vFppp)
+GO(g_menu_item_set_section, vFpp)
//GO(g_menu_item_set_submenu,
-//GO(g_menu_link_iter_get_name,
-//GO(g_menu_link_iter_get_next,
+GO(g_menu_link_iter_get_name, pFp)
+GO(g_menu_link_iter_get_next, iFppp)
//GO(g_menu_link_iter_get_type,
-//GO(g_menu_link_iter_get_value,
-//GO(g_menu_link_iter_next,
+GO(g_menu_link_iter_get_value, pFp)
+GO(g_menu_link_iter_next, iFp)
//GO(g_menu_model_get_item_attribute,
-//GO(g_menu_model_get_item_attribute_value,
-//GO(g_menu_model_get_item_link,
-//GO(g_menu_model_get_n_items,
+GO(g_menu_model_get_item_attribute_value, pFpipp)
+GO(g_menu_model_get_item_link, pFpip)
+GO(g_menu_model_get_n_items, iFp)
//GO(g_menu_model_get_type,
-//GO(g_menu_model_is_mutable,
-//GO(g_menu_model_items_changed,
-//GO(g_menu_model_iterate_item_attributes,
-//GO(g_menu_model_iterate_item_links,
-//GO(g_menu_new,
+GO(g_menu_model_is_mutable, iFp)
+GO(g_menu_model_items_changed, vFpiii)
+GO(g_menu_model_iterate_item_attributes, pFpi)
+GO(g_menu_model_iterate_item_links, pFpi)
+GO(g_menu_new, pFv)
//GO(g_menu_prepend,
//GO(g_menu_prepend_item,
//GO(g_menu_prepend_section,
//GO(g_menu_prepend_submenu,
-//GO(g_menu_remove,
+GO(g_menu_remove, vFpi)
//GO(g_menu_remove_all,
//GO(g_mount_can_eject,
//GO(g_mount_can_unmount,
//GO(g_mount_eject,
//GO(g_mount_eject_finish,
//GO(g_mount_eject_with_operation,
-//GO(g_mount_eject_with_operation_finish,
-//GO(g_mount_get_default_location,
-//GO(g_mount_get_drive,
+GO(g_mount_eject_with_operation_finish, iFppp)
+GO(g_mount_get_default_location, pFp)
+GO(g_mount_get_drive, pFp)
//GO(g_mount_get_icon,
//GO(g_mount_get_name,
//GO(g_mount_get_root,
-//GO(g_mount_get_sort_key,
-//GO(g_mount_get_symbolic_icon,
+GO(g_mount_get_sort_key, pFp)
+GO(g_mount_get_symbolic_icon, pFp)
//GO(g_mount_get_type,
-//GO(g_mount_get_uuid,
+GO(g_mount_get_uuid, pFp)
//GO(g_mount_get_volume,
//GO(g_mount_guess_content_type,
-//GO(g_mount_guess_content_type_finish,
-//GO(g_mount_guess_content_type_sync,
-//GO(g_mount_is_shadowed,
+GO(g_mount_guess_content_type_finish, pFppp)
+GO(g_mount_guess_content_type_sync, pFpipp)
+GO(g_mount_is_shadowed, iFp)
//GO(g_mount_mount_flags_get_type,
//GO(g_mount_operation_get_anonymous,
-//GO(g_mount_operation_get_choice,
-//GO(g_mount_operation_get_domain,
+GO(g_mount_operation_get_choice, iFp)
+GO(g_mount_operation_get_domain, pFp)
//GO(g_mount_operation_get_password,
-//GO(g_mount_operation_get_password_save,
+GO(g_mount_operation_get_password_save, uFp)
//GO(g_mount_operation_get_type,
//GO(g_mount_operation_get_username,
-//GO(g_mount_operation_new,
-//GO(g_mount_operation_reply,
+GO(g_mount_operation_new, pFv)
+GO(g_mount_operation_reply, vFpu)
//GO(g_mount_operation_result_get_type,
//GO(g_mount_operation_set_anonymous,
-//GO(g_mount_operation_set_choice,
-//GO(g_mount_operation_set_domain,
+GO(g_mount_operation_set_choice, vFpi)
+GO(g_mount_operation_set_domain, vFpp)
//GO(g_mount_operation_set_password,
-//GO(g_mount_operation_set_password_save,
+GO(g_mount_operation_set_password_save, vFpu)
//GO(g_mount_operation_set_username,
//GO(g_mount_remount,
//GO(g_mount_remount_finish,
@@ -1129,67 +1129,67 @@ GO(g_list_model_get_object, pFpu)
//GO(g_mount_unshadow,
//GO(g_native_volume_monitor_get_type,
//GO(g_network_address_get_hostname,
-//GO(g_network_address_get_port,
-//GO(g_network_address_get_scheme,
+GO(g_network_address_get_port, WFp)
+GO(g_network_address_get_scheme, pFp)
//GO(g_network_address_get_type,
-//GO(g_network_address_new,
+GO(g_network_address_new, pFpW)
//GO(g_network_address_parse,
-//GO(g_network_address_parse_uri,
+GO(g_network_address_parse_uri, pFpWp)
//GO(g_networking_init,
//GO(g_network_monitor_base_add_network,
//GO(g_network_monitor_base_get_type,
//GO(g_network_monitor_base_remove_network,
//GO(g_network_monitor_base_set_networks,
-//GO(g_network_monitor_can_reach,
+GO(g_network_monitor_can_reach, iFpppp)
//GO(g_network_monitor_can_reach_async,
-//GO(g_network_monitor_can_reach_finish,
-//GO(g_network_monitor_get_default,
+GO(g_network_monitor_can_reach_finish, iFppp)
+GO(g_network_monitor_get_default, pFv)
//GO(g_network_monitor_get_network_available,
//GO(g_network_monitor_get_type,
//GO(g_network_service_get_domain,
//GO(g_network_service_get_protocol,
-//GO(g_network_service_get_scheme,
+GO(g_network_service_get_scheme, pFp)
//GO(g_network_service_get_service,
//GO(g_network_service_get_type,
-//GO(g_network_service_new,
-//GO(g_network_service_set_scheme,
-//GO(g_notification_add_button,
+GO(g_network_service_new, pFppp)
+GO(g_network_service_set_scheme, vFpp)
+GO(g_notification_add_button, vFppp)
//GO(g_notification_add_button_with_target,
-//GO(g_notification_add_button_with_target_value,
+GO(g_notification_add_button_with_target_value, vFpppp)
//GO(g_notification_get_type,
-//GO(g_notification_new,
+GO(g_notification_new, pFp)
//GO(g_notification_priority_get_type,
//GO(g_notification_set_body,
-//GO(g_notification_set_default_action,
+GO(g_notification_set_default_action, vFpp)
//GO(g_notification_set_default_action_and_target,
-//GO(g_notification_set_default_action_and_target_value,
-//GO(g_notification_set_icon,
-//GO(g_notification_set_priority,
+GO(g_notification_set_default_action_and_target_value, vFppp)
+GO(g_notification_set_icon, vFpp)
+GO(g_notification_set_priority, vFpu)
//GO(g_notification_set_title,
-//GO(g_notification_set_urgent,
+GO(g_notification_set_urgent, vFpi)
//GO(g_null_settings_backend_new,
//GO(g_output_stream_clear_pending,
-//GO(g_output_stream_close,
+GO(g_output_stream_close, iFppp)
//GO(g_output_stream_close_async,
-//GO(g_output_stream_close_finish,
+GO(g_output_stream_close_finish, iFppp)
//GO(g_output_stream_flush,
//GO(g_output_stream_flush_async,
//GO(g_output_stream_flush_finish,
//GO(g_output_stream_get_type,
-//GO(g_output_stream_has_pending,
+GO(g_output_stream_has_pending, iFp)
//GO(g_output_stream_is_closed,
//GO(g_output_stream_is_closing,
//GO(g_output_stream_printf,
-//GO(g_output_stream_set_pending,
-//GO(g_output_stream_splice,
+GO(g_output_stream_set_pending, iFpp)
+GO(g_output_stream_splice, lFppupp)
//GO(g_output_stream_splice_async,
-//GO(g_output_stream_splice_finish,
+GO(g_output_stream_splice_finish, lFppp)
//GO(g_output_stream_splice_flags_get_type,
//GO(g_output_stream_vprintf,
-//GO(g_output_stream_write,
-//GO(g_output_stream_write_all,
+GO(g_output_stream_write, lFppLpp)
+GO(g_output_stream_write_all, iFppLppp)
//GO(g_output_stream_write_async,
-//GO(g_output_stream_write_bytes,
+GO(g_output_stream_write_bytes, lFpppp)
//GO(g_output_stream_write_bytes_async,
//GO(g_output_stream_write_bytes_finish,
//GO(g_output_stream_write_finish,
@@ -1199,99 +1199,99 @@ GO(g_list_model_get_object, pFpu)
//GO(g_permission_acquire_finish,
//GO(g_permission_get_allowed,
//GO(g_permission_get_can_acquire,
-//GO(g_permission_get_can_release,
+GO(g_permission_get_can_release, iFp)
//GO(g_permission_get_type,
-//GO(g_permission_impl_update,
-//GO(g_permission_release,
+GO(g_permission_impl_update, vFpiii)
+GO(g_permission_release, iFppp)
//GO(g_permission_release_async,
-//GO(g_permission_release_finish,
+GO(g_permission_release_finish, iFppp)
//GO(g_pollable_input_stream_can_poll,
//GO(g_pollable_input_stream_create_source,
//GO(g_pollable_input_stream_get_type,
-//GO(g_pollable_input_stream_is_readable,
-//GO(g_pollable_input_stream_read_nonblocking,
+GO(g_pollable_input_stream_is_readable, iFp)
+GO(g_pollable_input_stream_read_nonblocking, lFppLpp)
//GO(g_pollable_output_stream_can_poll,
//GO(g_pollable_output_stream_create_source,
//GO(g_pollable_output_stream_get_type,
-//GO(g_pollable_output_stream_is_writable,
-//GO(g_pollable_output_stream_write_nonblocking,
+GO(g_pollable_output_stream_is_writable, iFp)
+GO(g_pollable_output_stream_write_nonblocking, lFppLpp)
//GO(g_pollable_source_new,
//GO(g_pollable_source_new_full,
-//GO(g_pollable_stream_read,
-//GO(g_pollable_stream_write,
-//GO(g_pollable_stream_write_all,
+GO(g_pollable_stream_read, lFppLipp)
+GO(g_pollable_stream_write, lFppLipp)
+GO(g_pollable_stream_write_all, iFppLippp)
//GO(g_property_action_get_type,
-//GO(g_property_action_new,
+GO(g_property_action_new, pFppp)
//GO(g_proxy_address_enumerator_get_type,
//GO(g_proxy_address_get_destination_hostname,
-//GO(g_proxy_address_get_destination_port,
+GO(g_proxy_address_get_destination_port, WFp)
//GO(g_proxy_address_get_destination_protocol,
//GO(g_proxy_address_get_password,
//GO(g_proxy_address_get_protocol,
//GO(g_proxy_address_get_type,
-//GO(g_proxy_address_get_uri,
+GO(g_proxy_address_get_uri, pFp)
//GO(g_proxy_address_get_username,
-//GO(g_proxy_address_new,
-//GO(g_proxy_connect,
+GO(g_proxy_address_new, pFpWppWpp)
+GO(g_proxy_connect, pFppppp)
//GO(g_proxy_connect_async,
-//GO(g_proxy_connect_finish,
-//GO(g_proxy_get_default_for_protocol,
+GO(g_proxy_connect_finish, pFppp)
+GO(g_proxy_get_default_for_protocol, pFp)
//GO(g_proxy_get_type,
-//GO(g_proxy_resolver_get_default,
+GO(g_proxy_resolver_get_default, pFv)
//GO(g_proxy_resolver_get_type,
-//GO(g_proxy_resolver_is_supported,
-//GO(g_proxy_resolver_lookup,
+GO(g_proxy_resolver_is_supported, iFp)
+GO(g_proxy_resolver_lookup, pFpppp)
//GO(g_proxy_resolver_lookup_async,
-//GO(g_proxy_resolver_lookup_finish,
-//GO(g_proxy_supports_hostname,
+GO(g_proxy_resolver_lookup_finish, pFppp)
+GO(g_proxy_supports_hostname, iFp)
//GO(g_remote_action_group_activate_action_full,
-//GO(g_remote_action_group_change_action_state_full,
+GO(g_remote_action_group_change_action_state_full, vFpppp)
//GO(g_remote_action_group_get_type,
//GO(g_resolver_error_get_type,
//GO(g_resolver_error_quark,
//GO(g_resolver_free_addresses,
-//GO(g_resolver_free_targets,
-//GO(g_resolver_get_default,
+GO(g_resolver_free_targets, vFp)
+GO(g_resolver_get_default, pFv)
//GO(g_resolver_get_type,
-//GO(g_resolver_lookup_by_address,
+GO(g_resolver_lookup_by_address, pFpppp)
//GO(g_resolver_lookup_by_address_async,
-//GO(g_resolver_lookup_by_address_finish,
-//GO(g_resolver_lookup_by_name,
+GO(g_resolver_lookup_by_address_finish, pFppp)
+GO(g_resolver_lookup_by_name, pFpppp)
//GO(g_resolver_lookup_by_name_async,
//GO(g_resolver_lookup_by_name_finish,
-//GO(g_resolver_lookup_records,
+GO(g_resolver_lookup_records, pFppupp)
//GO(g_resolver_lookup_records_async,
-//GO(g_resolver_lookup_records_finish,
-//GO(g_resolver_lookup_service,
+GO(g_resolver_lookup_records_finish, pFppp)
+GO(g_resolver_lookup_service, pFpppppp)
//GO(g_resolver_lookup_service_async,
//GO(g_resolver_lookup_service_finish,
//GO(g_resolver_record_type_get_type,
//GO(g_resolver_set_default,
-//GO(g_resource_enumerate_children,
+GO(g_resource_enumerate_children, pFppup)
//GO(g_resource_error_get_type,
//GO(g_resource_error_quark,
//GO(g_resource_flags_get_type,
-//GO(g_resource_get_info,
+GO(g_resource_get_info, iFppuppp)
//GO(g_resource_get_type,
-//GO(g_resource_load,
-//GO(g_resource_lookup_data,
+GO(g_resource_load, pFpp)
+GO(g_resource_lookup_data, pFppup)
//GO(g_resource_lookup_flags_get_type,
-//GO(g_resource_new_from_data,
-//GO(g_resource_open_stream,
-//GO(g_resource_ref,
-//GO(g_resources_enumerate_children,
-//GO(g_resources_get_info,
-//GO(g_resources_lookup_data,
-//GO(g_resources_open_stream,
+GO(g_resource_new_from_data, pFpp)
+GO(g_resource_open_stream, pFppup)
+GO(g_resource_ref, pFp)
+GO(g_resources_enumerate_children, pFpup)
+GO(g_resources_get_info, iFpuppp)
+GO(g_resources_lookup_data, pFpup)
+GO(g_resources_open_stream, pFpup)
//GO(g_resources_register,
//GO(g_resources_unregister,
//GO(g_resource_unref,
//GO(g_seekable_can_seek,
-//GO(g_seekable_can_truncate,
+GO(g_seekable_can_truncate, iFp)
//GO(g_seekable_get_type,
-//GO(g_seekable_seek,
-//GO(g_seekable_tell,
-//GO(g_seekable_truncate,
+GO(g_seekable_seek, iFplupp)
+GO(g_seekable_tell, lFp)
+GO(g_seekable_truncate, iFplpp)
GO(g_settings_apply, vFp)
//GO(g_settings_backend_changed,
//GO(g_settings_backend_changed_tree,
@@ -1302,87 +1302,87 @@ GO(g_settings_apply, vFp)
//GO(g_settings_backend_path_changed,
//GO(g_settings_backend_path_writable_changed,
//GO(g_settings_backend_writable_changed,
-//GO(g_settings_bind,
+GO(g_settings_bind, vFppppu)
//GO(g_settings_bind_flags_get_type,
//GO(g_settings_bind_with_mapping,
-//GO(g_settings_bind_writable,
-//GO(g_settings_create_action,
+GO(g_settings_bind_writable, vFppppi)
+GO(g_settings_create_action, pFpp)
GO(g_settings_delay, vFp)
//GO(g_settings_get,
-//GO(g_settings_get_boolean,
+GO(g_settings_get_boolean, iFpp)
GO(g_settings_get_child, pFpp)
GO(g_settings_get_default_value, pFpp)
-//GO(g_settings_get_double,
-//GO(g_settings_get_enum,
-//GO(g_settings_get_flags,
+GO(g_settings_get_double, dFpp)
+GO(g_settings_get_enum, iFpp)
+GO(g_settings_get_flags, uFpp)
GO(g_settings_get_has_unapplied, iFp)
-//GO(g_settings_get_int,
+GO(g_settings_get_int, iFpp)
//GO(g_settings_get_mapped,
//GO(g_settings_get_range,
GO(g_settings_get_string, pFpp)
-//GO(g_settings_get_strv,
-//GO(g_settings_get_type,
-//GO(g_settings_get_uint,
+GO(g_settings_get_strv, pFpp)
+GO(g_settings_get_type, pFv)
+GO(g_settings_get_uint, uFpp)
GO(g_settings_get_user_value, pFpp)
GO(g_settings_get_value, pFpp)
GO(g_settings_is_writable, iFpp)
//GO(g_settings_list_children,
GO(g_settings_list_keys, pFp)
-//GO(g_settings_list_relocatable_schemas,
+GO(g_settings_list_relocatable_schemas, pFv)
//GO(g_settings_list_schemas,
GO(g_settings_new, pFp)
-//GO(g_settings_new_full,
-//GO(g_settings_new_with_backend,
-//GO(g_settings_new_with_backend_and_path,
+GO(g_settings_new_full, pFppp)
+GO(g_settings_new_with_backend, pFpp)
+GO(g_settings_new_with_backend_and_path, pFppp)
GO(g_settings_new_with_path, pFpp)
//GO(g_settings_range_check,
GO(g_settings_reset, vFpp)
//GO(g_settings_revert,
//GO(g_settings_schema_get_id,
-//GO(g_settings_schema_get_key,
-//GO(g_settings_schema_get_path,
+GO(g_settings_schema_get_key, pFpp)
+GO(g_settings_schema_get_path, pFp)
//GO(g_settings_schema_get_type,
-//GO(g_settings_schema_has_key,
+GO(g_settings_schema_has_key, iFpp)
//GO(g_settings_schema_key_get_default_value,
-//GO(g_settings_schema_key_get_description,
-//GO(g_settings_schema_key_get_range,
+GO(g_settings_schema_key_get_description, pFp)
+GO(g_settings_schema_key_get_range, pFp)
//GO(g_settings_schema_key_get_summary,
//GO(g_settings_schema_key_get_type,
-//GO(g_settings_schema_key_get_value_type,
-//GO(g_settings_schema_key_range_check,
-//GO(g_settings_schema_key_ref,
+GO(g_settings_schema_key_get_value_type, pFp)
+GO(g_settings_schema_key_range_check, iFpp)
+GO(g_settings_schema_key_ref, pFp)
//GO(g_settings_schema_key_unref,
-//GO(g_settings_schema_ref,
+GO(g_settings_schema_ref, pFp)
GO(g_settings_schema_source_get_default, pFv)
GO(g_settings_schema_source_get_type, LFv)
-//GO(g_settings_schema_source_list_schemas,
+GO(g_settings_schema_source_list_schemas, vFpipp)
GO(g_settings_schema_source_lookup, pFppi)
-//GO(g_settings_schema_source_new_from_directory,
+GO(g_settings_schema_source_new_from_directory, pFppip)
GO(g_settings_schema_source_ref, pFp)
GO(g_settings_schema_source_unref, vFp)
-//GO(g_settings_schema_unref,
+GO(g_settings_schema_unref, vFp)
//GO(g_settings_set,
-//GO(g_settings_set_boolean,
-//GO(g_settings_set_double,
-//GO(g_settings_set_enum,
-//GO(g_settings_set_flags,
-//GO(g_settings_set_int,
-//GO(g_settings_set_string,
-//GO(g_settings_set_strv,
+GO(g_settings_set_boolean, iFppi)
+GO(g_settings_set_double, iFppd)
+GO(g_settings_set_enum, iFppi)
+GO(g_settings_set_flags, iFppu)
+GO(g_settings_set_int, iFppi)
+GO(g_settings_set_string, iFppp)
+GO(g_settings_set_strv, iFppp)
//GO(g_settings_set_uint,
GO(g_settings_set_value, iFppp)
GO(g_settings_sync, vFv)
-//GO(g_settings_unbind,
-//GO(g_simple_action_get_type,
+GO(g_settings_unbind, vFpp)
+GO(g_simple_action_get_type, LFv)
//GO(g_simple_action_group_add_entries,
//GO(g_simple_action_group_get_type,
-//GO(g_simple_action_group_insert,
-//GO(g_simple_action_group_lookup,
-//GO(g_simple_action_group_new,
-//GO(g_simple_action_group_remove,
-//GO(g_simple_action_new,
-//GO(g_simple_action_new_stateful,
-//GO(g_simple_action_set_enabled,
+GO(g_simple_action_group_insert, vFpp)
+GO(g_simple_action_group_lookup, pFpp)
+GO(g_simple_action_group_new, pFv)
+GO(g_simple_action_group_remove, vFpp)
+GO(g_simple_action_new, pFpp)
+GO(g_simple_action_new_stateful, pFppp)
+GO(g_simple_action_set_enabled, vFpi)
//GO(g_simple_action_set_state,
GOM(g_simple_async_report_error_in_idle, vFEpppuipV)
GOM(g_simple_async_report_gerror_in_idle, vFEpppp)
@@ -1411,255 +1411,255 @@ GOM(g_simple_async_result_set_op_res_gpointer, vFEppp)
GO(g_simple_async_result_set_op_res_gssize, vFpl)
GO(g_simple_async_result_take_error, vFpp)
GO(g_simple_permission_get_type, LFv)
-//GO(g_simple_permission_new,
+GO(g_simple_permission_new, pFi)
GO(g_simple_proxy_resolver_get_type, LFv)
-//GO(g_simple_proxy_resolver_new,
-//GO(g_simple_proxy_resolver_set_default_proxy,
-//GO(g_simple_proxy_resolver_set_ignore_hosts,
-//GO(g_simple_proxy_resolver_set_uri_proxy,
-//GO(g_socket_accept,
+GO(g_simple_proxy_resolver_new, pFpp)
+GO(g_simple_proxy_resolver_set_default_proxy, vFpp)
+GO(g_simple_proxy_resolver_set_ignore_hosts, vFpp)
+GO(g_simple_proxy_resolver_set_uri_proxy, vFppp)
+GO(g_socket_accept, pFppp)
//GO(g_socket_address_enumerator_get_type,
-//GO(g_socket_address_enumerator_next,
+GO(g_socket_address_enumerator_next, pFppp)
//GO(g_socket_address_enumerator_next_async,
-//GO(g_socket_address_enumerator_next_finish,
-//GO(g_socket_address_get_family,
-//GO(g_socket_address_get_native_size,
+GO(g_socket_address_enumerator_next_finish, pFppp)
+GO(g_socket_address_get_family, uFp)
+GO(g_socket_address_get_native_size, lFp)
//GO(g_socket_address_get_type,
//GO(g_socket_address_new_from_native,
-//GO(g_socket_address_to_native,
-//GO(g_socket_bind,
+GO(g_socket_address_to_native, iFppLp)
+GO(g_socket_bind, iFppip)
//GO(g_socket_check_connect_result,
-//GO(g_socket_client_add_application_proxy,
-//GO(g_socket_client_connect,
+GO(g_socket_client_add_application_proxy, vFpp)
+GO(g_socket_client_connect, pFpppp)
//GO(g_socket_client_connect_async,
//GO(g_socket_client_connect_finish,
//GO(g_socket_client_connect_to_host,
//GO(g_socket_client_connect_to_host_async,
//GO(g_socket_client_connect_to_host_finish,
-//GO(g_socket_client_connect_to_service,
+GO(g_socket_client_connect_to_service, pFppppp)
//GO(g_socket_client_connect_to_service_async,
//GO(g_socket_client_connect_to_service_finish,
-//GO(g_socket_client_connect_to_uri,
+GO(g_socket_client_connect_to_uri, pFppWpp)
//GO(g_socket_client_connect_to_uri_async,
-//GO(g_socket_client_connect_to_uri_finish,
+GO(g_socket_client_connect_to_uri_finish, pFppp)
//GO(g_socket_client_event_get_type,
//GO(g_socket_client_get_enable_proxy,
-//GO(g_socket_client_get_family,
-//GO(g_socket_client_get_local_address,
-//GO(g_socket_client_get_protocol,
-//GO(g_socket_client_get_proxy_resolver,
-//GO(g_socket_client_get_socket_type,
-//GO(g_socket_client_get_timeout,
-//GO(g_socket_client_get_tls,
-//GO(g_socket_client_get_tls_validation_flags,
+GO(g_socket_client_get_family, uFp)
+GO(g_socket_client_get_local_address, pFp)
+GO(g_socket_client_get_protocol, iFp)
+GO(g_socket_client_get_proxy_resolver, pFp)
+GO(g_socket_client_get_socket_type, uFp)
+GO(g_socket_client_get_timeout, uFp)
+GO(g_socket_client_get_tls, iFp)
+GO(g_socket_client_get_tls_validation_flags, uFp)
//GO(g_socket_client_get_type,
-//GO(g_socket_client_new,
+GO(g_socket_client_new, pFv)
//GO(g_socket_client_set_enable_proxy,
-//GO(g_socket_client_set_family,
-//GO(g_socket_client_set_local_address,
-//GO(g_socket_client_set_protocol,
-//GO(g_socket_client_set_proxy_resolver,
-//GO(g_socket_client_set_socket_type,
-//GO(g_socket_client_set_timeout,
-//GO(g_socket_client_set_tls,
-//GO(g_socket_client_set_tls_validation_flags,
-//GO(g_socket_close,
-//GO(g_socket_condition_check,
-//GO(g_socket_condition_timed_wait,
-//GO(g_socket_condition_wait,
-//GO(g_socket_connect,
+GO(g_socket_client_set_family, vFpu)
+GO(g_socket_client_set_local_address, vFpp)
+GO(g_socket_client_set_protocol, vFpi)
+GO(g_socket_client_set_proxy_resolver, vFpp)
+GO(g_socket_client_set_socket_type, vFpu)
+GO(g_socket_client_set_timeout, vFpu)
+GO(g_socket_client_set_tls, vFpi)
+GO(g_socket_client_set_tls_validation_flags, vFpu)
+GO(g_socket_close, iFpp)
+GO(g_socket_condition_check, uFpu)
+GO(g_socket_condition_timed_wait, iFpulpp)
+GO(g_socket_condition_wait, iFpupp)
+GO(g_socket_connect, iFpppp)
//GO(g_socket_connectable_enumerate,
//GO(g_socket_connectable_get_type,
-//GO(g_socket_connectable_proxy_enumerate,
-//GO(g_socket_connection_connect,
+GO(g_socket_connectable_proxy_enumerate, pFp)
+GO(g_socket_connection_connect, iFpppp)
//GO(g_socket_connection_connect_async,
-//GO(g_socket_connection_connect_finish,
-//GO(g_socket_connection_factory_create_connection,
-//GO(g_socket_connection_factory_lookup_type,
-//GO(g_socket_connection_factory_register_type,
+GO(g_socket_connection_connect_finish, iFppp)
+GO(g_socket_connection_factory_create_connection, pFp)
+GO(g_socket_connection_factory_lookup_type, LFuui)
+GO(g_socket_connection_factory_register_type, vFLuui)
//GO(g_socket_connection_get_local_address,
-//GO(g_socket_connection_get_remote_address,
-//GO(g_socket_connection_get_socket,
+GO(g_socket_connection_get_remote_address, pFpp)
+GO(g_socket_connection_get_socket, pFp)
//GO(g_socket_connection_get_type,
-//GO(g_socket_connection_is_connected,
-//GO(g_socket_control_message_deserialize,
+GO(g_socket_connection_is_connected, iFp)
+GO(g_socket_control_message_deserialize, pFiiLp)
//GO(g_socket_control_message_get_level,
-//GO(g_socket_control_message_get_msg_type,
-//GO(g_socket_control_message_get_size,
+GO(g_socket_control_message_get_msg_type, iFp)
+GO(g_socket_control_message_get_size, LFp)
//GO(g_socket_control_message_get_type,
-//GO(g_socket_control_message_serialize,
+GO(g_socket_control_message_serialize, vFpp)
//GO(g_socket_create_source,
//GO(g_socket_family_get_type,
-//GO(g_socket_get_available_bytes,
+GO(g_socket_get_available_bytes, lFp)
//GO(g_socket_get_blocking,
//GO(g_socket_get_broadcast,
-//GO(g_socket_get_credentials,
-//GO(g_socket_get_family,
-//GO(g_socket_get_fd,
+GO(g_socket_get_credentials, pFpp)
+GO(g_socket_get_family, uFp)
+GO(g_socket_get_fd, iFp)
//GO(g_socket_get_keepalive,
-//GO(g_socket_get_listen_backlog,
+GO(g_socket_get_listen_backlog, iFp)
//GO(g_socket_get_local_address,
//GO(g_socket_get_multicast_loopback,
-//GO(g_socket_get_multicast_ttl,
-//GO(g_socket_get_option,
-//GO(g_socket_get_protocol,
-//GO(g_socket_get_remote_address,
-//GO(g_socket_get_socket_type,
+GO(g_socket_get_multicast_ttl, uFp)
+GO(g_socket_get_option, iFpiipp)
+GO(g_socket_get_protocol, iFp)
+GO(g_socket_get_remote_address, pFpp)
+GO(g_socket_get_socket_type, uFp)
//GO(g_socket_get_timeout,
//GO(g_socket_get_ttl,
//GO(g_socket_get_type,
//GO(g_socket_is_closed,
//GO(g_socket_is_connected,
//GO(g_socket_join_multicast_group,
-//GO(g_socket_leave_multicast_group,
+GO(g_socket_leave_multicast_group, iFppipp)
//GO(g_socket_listen,
-//GO(g_socket_listener_accept,
+GO(g_socket_listener_accept, pFpppp)
//GO(g_socket_listener_accept_async,
-//GO(g_socket_listener_accept_finish,
-//GO(g_socket_listener_accept_socket,
+GO(g_socket_listener_accept_finish, pFpppp)
+GO(g_socket_listener_accept_socket, pFpppp)
//GO(g_socket_listener_accept_socket_async,
-//GO(g_socket_listener_accept_socket_finish,
-//GO(g_socket_listener_add_address,
-//GO(g_socket_listener_add_any_inet_port,
-//GO(g_socket_listener_add_inet_port,
-//GO(g_socket_listener_add_socket,
+GO(g_socket_listener_accept_socket_finish, pFpppp)
+GO(g_socket_listener_add_address, iFppuippp)
+GO(g_socket_listener_add_any_inet_port, WFppp)
+GO(g_socket_listener_add_inet_port, iFpWpp)
+GO(g_socket_listener_add_socket, iFpppp)
//GO(g_socket_listener_close,
//GO(g_socket_listener_get_type,
-//GO(g_socket_listener_new,
-//GO(g_socket_listener_set_backlog,
+GO(g_socket_listener_new, pFv)
+GO(g_socket_listener_set_backlog, vFpi)
//GO(g_socket_msg_flags_get_type,
-//GO(g_socket_new,
-//GO(g_socket_new_from_fd,
+GO(g_socket_new, pFuuip)
+GO(g_socket_new_from_fd, pFip)
//GO(g_socket_protocol_get_type,
-//GO(g_socket_receive,
-//GO(g_socket_receive_from,
-//GO(g_socket_receive_message,
-//GO(g_socket_receive_with_blocking,
-//GO(g_socket_send,
-//GO(g_socket_send_message,
-//GO(g_socket_send_to,
-//GO(g_socket_send_with_blocking,
+GO(g_socket_receive, lFppLpp)
+GO(g_socket_receive_from, lFpppLpp)
+GO(g_socket_receive_message, lFpppippppp)
+GO(g_socket_receive_with_blocking, lFppLipp)
+GO(g_socket_send, lFppLpp)
+GO(g_socket_send_message, lFpppipiipp)
+GO(g_socket_send_to, lFpppLpp)
+GO(g_socket_send_with_blocking, lFppLipp)
//GO(g_socket_service_get_type,
-//GO(g_socket_service_is_active,
-//GO(g_socket_service_new,
+GO(g_socket_service_is_active, iFp)
+GO(g_socket_service_new, pFv)
//GO(g_socket_service_start,
//GO(g_socket_service_stop,
//GO(g_socket_set_blocking,
//GO(g_socket_set_broadcast,
//GO(g_socket_set_keepalive,
-//GO(g_socket_set_listen_backlog,
-//GO(g_socket_set_multicast_loopback,
-//GO(g_socket_set_multicast_ttl,
-//GO(g_socket_set_option,
+GO(g_socket_set_listen_backlog, vFpi)
+GO(g_socket_set_multicast_loopback, vFpi)
+GO(g_socket_set_multicast_ttl, vFpu)
+GO(g_socket_set_option, iFpiiip)
//GO(g_socket_set_timeout,
//GO(g_socket_set_ttl,
-//GO(g_socket_shutdown,
-//GO(g_socket_speaks_ipv4,
+GO(g_socket_shutdown, iFpiip)
+GO(g_socket_speaks_ipv4, iFp)
//GO(g_socket_type_get_type,
-//GO(g_srv_target_copy,
-//GO(g_srv_target_free,
-//GO(g_srv_target_get_hostname,
+GO(g_srv_target_copy, pFp)
+GO(g_srv_target_free, vFp)
+GO(g_srv_target_get_hostname, pFp)
//GO(g_srv_target_get_port,
//GO(g_srv_target_get_priority,
//GO(g_srv_target_get_type,
-//GO(g_srv_target_get_weight,
-//GO(g_srv_target_list_sort,
-//GO(g_srv_target_new,
-//GO(g_static_resource_fini,
-//GO(g_static_resource_get_resource,
-//GO(g_static_resource_init,
-//GO(g_subprocess_communicate,
+GO(g_srv_target_get_weight, WFp)
+GO(g_srv_target_list_sort, pFp)
+GO(g_srv_target_new, pFpWWW)
+GO(g_static_resource_fini, vFp)
+GO(g_static_resource_get_resource, pFp)
+GO(g_static_resource_init, vFp)
+GO(g_subprocess_communicate, iFpppppp)
//GO(g_subprocess_communicate_async,
-//GO(g_subprocess_communicate_finish,
-//GO(g_subprocess_communicate_utf8,
+GO(g_subprocess_communicate_finish, iFppppp)
+GO(g_subprocess_communicate_utf8, iFpppppp)
//GO(g_subprocess_communicate_utf8_async,
-//GO(g_subprocess_communicate_utf8_finish,
+GO(g_subprocess_communicate_utf8_finish, iFppppp)
//GO(g_subprocess_flags_get_type,
//GO(g_subprocess_force_exit,
//GO(g_subprocess_get_exit_status,
-//GO(g_subprocess_get_identifier,
+GO(g_subprocess_get_identifier, pFp)
//GO(g_subprocess_get_if_exited,
-//GO(g_subprocess_get_if_signaled,
+GO(g_subprocess_get_if_signaled, iFp)
//GO(g_subprocess_get_status,
-//GO(g_subprocess_get_stderr_pipe,
-//GO(g_subprocess_get_stdin_pipe,
+GO(g_subprocess_get_stderr_pipe, pFp)
+GO(g_subprocess_get_stdin_pipe, pFp)
//GO(g_subprocess_get_stdout_pipe,
//GO(g_subprocess_get_successful,
-//GO(g_subprocess_get_term_sig,
+GO(g_subprocess_get_term_sig, iFp)
//GO(g_subprocess_get_type,
-//GO(g_subprocess_launcher_getenv,
+GO(g_subprocess_launcher_getenv, pFpp)
//GO(g_subprocess_launcher_get_type,
-//GO(g_subprocess_launcher_new,
+GO(g_subprocess_launcher_new, pFu)
//GO(g_subprocess_launcher_set_child_setup,
//GO(g_subprocess_launcher_set_cwd,
-//GO(g_subprocess_launcher_setenv,
-//GO(g_subprocess_launcher_set_environ,
-//GO(g_subprocess_launcher_set_flags,
-//GO(g_subprocess_launcher_set_stderr_file_path,
+GO(g_subprocess_launcher_setenv, vFpppi)
+GO(g_subprocess_launcher_set_environ, vFpp)
+GO(g_subprocess_launcher_set_flags, vFpu)
+GO(g_subprocess_launcher_set_stderr_file_path, vFpp)
//GO(g_subprocess_launcher_set_stdin_file_path,
//GO(g_subprocess_launcher_set_stdout_file_path,
//GO(g_subprocess_launcher_spawn,
-//GO(g_subprocess_launcher_spawnv,
-//GO(g_subprocess_launcher_take_fd,
-//GO(g_subprocess_launcher_take_stderr_fd,
+GO(g_subprocess_launcher_spawnv, pFppp)
+GO(g_subprocess_launcher_take_fd, vFpii)
+GO(g_subprocess_launcher_take_stderr_fd, vFpi)
//GO(g_subprocess_launcher_take_stdin_fd,
//GO(g_subprocess_launcher_take_stdout_fd,
//GO(g_subprocess_launcher_unsetenv,
//GO(g_subprocess_new,
-//GO(g_subprocess_newv,
-//GO(g_subprocess_send_signal,
+GO(g_subprocess_newv, pFpup)
+GO(g_subprocess_send_signal, vFpi)
//GO(g_subprocess_wait,
//GO(g_subprocess_wait_async,
-//GO(g_subprocess_wait_check,
+GO(g_subprocess_wait_check, iFppp)
//GO(g_subprocess_wait_check_async,
-//GO(g_subprocess_wait_check_finish,
+GO(g_subprocess_wait_check_finish, iFppp)
//GO(g_subprocess_wait_finish,
//GO(g_task_attach_source,
-//GO(g_task_get_cancellable,
+GO(g_task_get_cancellable, pFp)
//GO(g_task_get_check_cancellable,
-//GO(g_task_get_context,
-//GO(g_task_get_priority,
+GO(g_task_get_context, pFp)
+GO(g_task_get_priority, iFp)
//GO(g_task_get_return_on_cancel,
//GO(g_task_get_source_object,
-//GO(g_task_get_source_tag,
+GO(g_task_get_source_tag, pFp)
//GO(g_task_get_task_data,
-//GO(g_task_get_type,
+GO(g_task_get_type, LFv)
//GO(g_task_had_error,
-//GO(g_task_is_valid,
-//GO(g_task_new,
-//GO(g_task_propagate_boolean,
-//GO(g_task_propagate_int,
-//GO(g_task_propagate_pointer,
+GO(g_task_is_valid, iFpp)
+GOM(g_task_new, pFEpppp)
+GO(g_task_propagate_boolean, iFpp)
+GO(g_task_propagate_int, lFpp)
+GO(g_task_propagate_pointer, pFpp)
//GO(g_task_report_error,
//GO(g_task_report_new_error,
-//GO(g_task_return_boolean,
-//GO(g_task_return_error,
+GO(g_task_return_boolean, vFpi)
+GO(g_task_return_error, vFpp)
//GO(g_task_return_error_if_cancelled,
-//GO(g_task_return_int,
-//GO(g_task_return_new_error,
-//GO(g_task_return_pointer,
+GO(g_task_return_int, vFpl)
+GOM(g_task_return_new_error, vFEpuipV)
+GOM(g_task_return_pointer, vFEppp)
//GO(g_task_run_in_thread,
//GO(g_task_run_in_thread_sync,
//GO(g_task_set_check_cancellable,
-//GO(g_task_set_priority,
-//GO(g_task_set_return_on_cancel,
-//GO(g_task_set_source_tag,
+GO(g_task_set_priority, vFpi)
+GO(g_task_set_return_on_cancel, iFpi)
+GO(g_task_set_source_tag, vFpp)
//GO(g_task_set_task_data,
-//GO(g_tcp_connection_get_graceful_disconnect,
+GO(g_tcp_connection_get_graceful_disconnect, iFp)
//GO(g_tcp_connection_get_type,
-//GO(g_tcp_connection_set_graceful_disconnect,
-//GO(g_tcp_wrapper_connection_get_base_io_stream,
+GO(g_tcp_connection_set_graceful_disconnect, vFpi)
+GO(g_tcp_wrapper_connection_get_base_io_stream, pFp)
//GO(g_tcp_wrapper_connection_get_type,
-//GO(g_tcp_wrapper_connection_new,
-//GO(g_test_dbus_add_service_dir,
+GO(g_tcp_wrapper_connection_new, pFpp)
+GO(g_test_dbus_add_service_dir, vFpp)
//GO(g_test_dbus_down,
//GO(g_test_dbus_flags_get_type,
-//GO(g_test_dbus_get_bus_address,
-//GO(g_test_dbus_get_flags,
+GO(g_test_dbus_get_bus_address, pFp)
+GO(g_test_dbus_get_flags, uFp)
//GO(g_test_dbus_get_type,
-//GO(g_test_dbus_new,
+GO(g_test_dbus_new, pFu)
//GO(g_test_dbus_stop,
-//GO(g_test_dbus_unset,
+GO(g_test_dbus_unset, vFv)
//GO(g_test_dbus_up,
GO(g_themed_icon_append_name, vFpp)
GO(g_themed_icon_get_names, pFp)
@@ -1670,121 +1670,121 @@ GO(g_themed_icon_new_with_default_fallbacks, pFp)
GO(g_themed_icon_prepend_name, vFpp)
//GO(g_threaded_resolver_get_type,
//GO(g_threaded_socket_service_get_type,
-//GO(g_threaded_socket_service_new,
+GO(g_threaded_socket_service_new, pFi)
//GO(g_tls_authentication_mode_get_type,
//GO(g_tls_backend_get_certificate_type,
//GO(g_tls_backend_get_client_connection_type,
-//GO(g_tls_backend_get_default,
-//GO(g_tls_backend_get_default_database,
+GO(g_tls_backend_get_default, pFv)
+GO(g_tls_backend_get_default_database, pFp)
//GO(g_tls_backend_get_file_database_type,
//GO(g_tls_backend_get_server_connection_type,
//GO(g_tls_backend_get_type,
//GO(g_tls_backend_supports_tls,
//GO(g_tls_certificate_flags_get_type,
-//GO(g_tls_certificate_get_issuer,
+GO(g_tls_certificate_get_issuer, pFp)
//GO(g_tls_certificate_get_type,
-//GO(g_tls_certificate_is_same,
-//GO(g_tls_certificate_list_new_from_file,
-//GO(g_tls_certificate_new_from_file,
+GO(g_tls_certificate_is_same, iFpp)
+GO(g_tls_certificate_list_new_from_file, pFpp)
+GO(g_tls_certificate_new_from_file, pFpp)
//GO(g_tls_certificate_new_from_files,
-//GO(g_tls_certificate_new_from_pem,
+GO(g_tls_certificate_new_from_pem, pFplp)
//GO(g_tls_certificate_request_flags_get_type,
-//GO(g_tls_certificate_verify,
-//GO(g_tls_client_connection_get_accepted_cas,
-//GO(g_tls_client_connection_get_server_identity,
+GO(g_tls_certificate_verify, uFppp)
+GO(g_tls_client_connection_get_accepted_cas, pFp)
+GO(g_tls_client_connection_get_server_identity, pFp)
//GO(g_tls_client_connection_get_type,
-//GO(g_tls_client_connection_get_use_ssl3,
-//GO(g_tls_client_connection_get_validation_flags,
-//GO(g_tls_client_connection_new,
-//GO(g_tls_client_connection_set_server_identity,
-//GO(g_tls_client_connection_set_use_ssl3,
-//GO(g_tls_client_connection_set_validation_flags,
-//GO(g_tls_connection_emit_accept_certificate,
+GO(g_tls_client_connection_get_use_ssl3, iFp)
+GO(g_tls_client_connection_get_validation_flags, uFp)
+GO(g_tls_client_connection_new, pFppp)
+GO(g_tls_client_connection_set_server_identity, vFpp)
+GO(g_tls_client_connection_set_use_ssl3, vFpi)
+GO(g_tls_client_connection_set_validation_flags, vFpu)
+GO(g_tls_connection_emit_accept_certificate, iFppu)
//GO(g_tls_connection_get_certificate,
-//GO(g_tls_connection_get_database,
-//GO(g_tls_connection_get_interaction,
-//GO(g_tls_connection_get_peer_certificate,
-//GO(g_tls_connection_get_peer_certificate_errors,
-//GO(g_tls_connection_get_rehandshake_mode,
-//GO(g_tls_connection_get_require_close_notify,
+GO(g_tls_connection_get_database, pFp)
+GO(g_tls_connection_get_interaction, pFp)
+GO(g_tls_connection_get_peer_certificate, pFp)
+GO(g_tls_connection_get_peer_certificate_errors, uFp)
+GO(g_tls_connection_get_rehandshake_mode, uFp)
+GO(g_tls_connection_get_require_close_notify, iFp)
//GO(g_tls_connection_get_type,
//GO(g_tls_connection_get_use_system_certdb,
-//GO(g_tls_connection_handshake,
+GO(g_tls_connection_handshake, iFppp)
//GO(g_tls_connection_handshake_async,
-//GO(g_tls_connection_handshake_finish,
-//GO(g_tls_connection_set_certificate,
-//GO(g_tls_connection_set_database,
-//GO(g_tls_connection_set_interaction,
-//GO(g_tls_connection_set_rehandshake_mode,
-//GO(g_tls_connection_set_require_close_notify,
+GO(g_tls_connection_handshake_finish, iFppp)
+GO(g_tls_connection_set_certificate, vFpp)
+GO(g_tls_connection_set_database, vFpp)
+GO(g_tls_connection_set_interaction, vFpp)
+GO(g_tls_connection_set_rehandshake_mode, vFpu)
+GO(g_tls_connection_set_require_close_notify, vFpi)
//GO(g_tls_connection_set_use_system_certdb,
-//GO(g_tls_database_create_certificate_handle,
+GO(g_tls_database_create_certificate_handle, pFpp)
//GO(g_tls_database_get_type,
-//GO(g_tls_database_lookup_certificate_for_handle,
+GO(g_tls_database_lookup_certificate_for_handle, pFpppupp)
//GO(g_tls_database_lookup_certificate_for_handle_async,
//GO(g_tls_database_lookup_certificate_for_handle_finish,
-//GO(g_tls_database_lookup_certificate_issuer,
+GO(g_tls_database_lookup_certificate_issuer, pFpppupp)
//GO(g_tls_database_lookup_certificate_issuer_async,
-//GO(g_tls_database_lookup_certificate_issuer_finish,
-//GO(g_tls_database_lookup_certificates_issued_by,
+GO(g_tls_database_lookup_certificate_issuer_finish, pFppp)
+GO(g_tls_database_lookup_certificates_issued_by, pFpppupp)
//GO(g_tls_database_lookup_certificates_issued_by_async,
-//GO(g_tls_database_lookup_certificates_issued_by_finish,
+GO(g_tls_database_lookup_certificates_issued_by_finish, pFppp)
//GO(g_tls_database_lookup_flags_get_type,
-//GO(g_tls_database_verify_chain,
+GO(g_tls_database_verify_chain, uFpppppupp)
//GO(g_tls_database_verify_chain_async,
-//GO(g_tls_database_verify_chain_finish,
+GO(g_tls_database_verify_chain_finish, uFppp)
//GO(g_tls_database_verify_flags_get_type,
//GO(g_tls_error_get_type,
//GO(g_tls_error_quark,
//GO(g_tls_file_database_get_type,
-//GO(g_tls_file_database_new,
-//GO(g_tls_interaction_ask_password,
+GO(g_tls_file_database_new, pFpp)
+GO(g_tls_interaction_ask_password, uFpppp)
//GO(g_tls_interaction_ask_password_async,
//GO(g_tls_interaction_ask_password_finish,
//GO(g_tls_interaction_get_type,
//GO(g_tls_interaction_invoke_ask_password,
//GO(g_tls_interaction_invoke_request_certificate,
-//GO(g_tls_interaction_request_certificate,
+GO(g_tls_interaction_request_certificate, uFppupp)
//GO(g_tls_interaction_request_certificate_async,
-//GO(g_tls_interaction_request_certificate_finish,
+GO(g_tls_interaction_request_certificate_finish, uFppp)
//GO(g_tls_interaction_result_get_type,
//GO(g_tls_password_flags_get_type,
//GO(g_tls_password_get_description,
-//GO(g_tls_password_get_flags,
+GO(g_tls_password_get_flags, uFp)
//GO(g_tls_password_get_type,
-//GO(g_tls_password_get_value,
-//GO(g_tls_password_get_warning,
-//GO(g_tls_password_new,
+GO(g_tls_password_get_value, pFpp)
+GO(g_tls_password_get_warning, pFp)
+GO(g_tls_password_new, pFup)
//GO(g_tls_password_set_description,
-//GO(g_tls_password_set_flags,
-//GO(g_tls_password_set_value,
+GO(g_tls_password_set_flags, vFpu)
+GO(g_tls_password_set_value, vFppl)
//GO(g_tls_password_set_value_full,
-//GO(g_tls_password_set_warning,
+GO(g_tls_password_set_warning, vFpp)
//GO(g_tls_rehandshake_mode_get_type,
//GO(g_tls_server_connection_get_type,
-//GO(g_tls_server_connection_new,
+GO(g_tls_server_connection_new, pFppp)
//GO(g_unix_connection_get_type,
-//GO(g_unix_connection_receive_credentials,
+GO(g_unix_connection_receive_credentials, pFppp)
//GO(g_unix_connection_receive_credentials_async,
-//GO(g_unix_connection_receive_credentials_finish,
-//GO(g_unix_connection_receive_fd,
-//GO(g_unix_connection_send_credentials,
+GO(g_unix_connection_receive_credentials_finish, pFppp)
+GO(g_unix_connection_receive_fd, iFppp)
+GO(g_unix_connection_send_credentials, iFppp)
//GO(g_unix_connection_send_credentials_async,
-//GO(g_unix_connection_send_credentials_finish,
-//GO(g_unix_connection_send_fd,
-//GO(g_unix_credentials_message_get_credentials,
+GO(g_unix_connection_send_credentials_finish, iFppp)
+GO(g_unix_connection_send_fd, iFpipp)
+GO(g_unix_credentials_message_get_credentials, pFp)
//GO(g_unix_credentials_message_get_type,
//GO(g_unix_credentials_message_is_supported,
-//GO(g_unix_credentials_message_new,
-//GO(g_unix_credentials_message_new_with_credentials,
+GO(g_unix_credentials_message_new, pFv)
+GO(g_unix_credentials_message_new_with_credentials, pFp)
//GO(g_unix_fd_list_append,
GO(g_unix_fd_list_get, iFpip)
GO(g_unix_fd_list_get_length, iFp)
GO(g_unix_fd_list_get_type, LFv)
-//GO(g_unix_fd_list_new,
-//GO(g_unix_fd_list_new_from_array,
-//GO(g_unix_fd_list_peek_fds,
-//GO(g_unix_fd_list_steal_fds,
+GO(g_unix_fd_list_new, pFv)
+GO(g_unix_fd_list_new_from_array, pFpi)
+GO(g_unix_fd_list_peek_fds, pFpp)
+GO(g_unix_fd_list_steal_fds, pFpp)
//GO(g_unix_fd_message_append_fd,
//GO(g_unix_fd_message_get_fd_list,
//GO(g_unix_fd_message_get_type,
@@ -1835,58 +1835,58 @@ GO(g_unix_fd_list_get_type, LFv)
//GO(g_unix_output_stream_get_type,
//GO(g_unix_output_stream_new,
//GO(g_unix_output_stream_set_close_fd,
-//GO(g_unix_socket_address_abstract_names_supported,
-//GO(g_unix_socket_address_get_address_type,
-//GO(g_unix_socket_address_get_is_abstract,
-//GO(g_unix_socket_address_get_path,
-//GO(g_unix_socket_address_get_path_len,
+GO(g_unix_socket_address_abstract_names_supported, iFv)
+GO(g_unix_socket_address_get_address_type, uFp)
+GO(g_unix_socket_address_get_is_abstract, iFp)
+GO(g_unix_socket_address_get_path, pFp)
+GO(g_unix_socket_address_get_path_len, LFp)
//GO(g_unix_socket_address_get_type,
-//GO(g_unix_socket_address_new,
-//GO(g_unix_socket_address_new_abstract,
-//GO(g_unix_socket_address_new_with_type,
+GO(g_unix_socket_address_new, pFp)
+GO(g_unix_socket_address_new_abstract, pFpi)
+GO(g_unix_socket_address_new_with_type, pFpiu)
//GO(g_unix_socket_address_type_get_type,
//GO(g_vfs_get_default,
//GO(g_vfs_get_file_for_path,
//GO(g_vfs_get_file_for_uri,
-//GO(g_vfs_get_local,
-//GO(g_vfs_get_supported_uri_schemes,
+GO(g_vfs_get_local, pFv)
+GO(g_vfs_get_supported_uri_schemes, pFp)
//GO(g_vfs_get_type,
-//GO(g_vfs_is_active,
-//GO(g_vfs_parse_name,
+GO(g_vfs_is_active, iFp)
+GO(g_vfs_parse_name, pFpp)
//GO(g_volume_can_eject,
//GO(g_volume_can_mount,
//GO(g_volume_eject,
//GO(g_volume_eject_finish,
//GO(g_volume_eject_with_operation,
-//GO(g_volume_eject_with_operation_finish,
-//GO(g_volume_enumerate_identifiers,
-//GO(g_volume_get_activation_root,
-//GO(g_volume_get_drive,
+GO(g_volume_eject_with_operation_finish, iFppp)
+GO(g_volume_enumerate_identifiers, pFp)
+GO(g_volume_get_activation_root, pFp)
+GO(g_volume_get_drive, pFp)
//GO(g_volume_get_icon,
-//GO(g_volume_get_identifier,
-//GO(g_volume_get_mount,
+GO(g_volume_get_identifier, pFpp)
+GO(g_volume_get_mount, pFp)
//GO(g_volume_get_name,
-//GO(g_volume_get_sort_key,
-//GO(g_volume_get_symbolic_icon,
+GO(g_volume_get_sort_key, pFp)
+GO(g_volume_get_symbolic_icon, pFp)
//GO(g_volume_get_type,
-//GO(g_volume_get_uuid,
-//GO(g_volume_monitor_adopt_orphan_mount,
-//GO(g_volume_monitor_get,
+GO(g_volume_get_uuid, pFp)
+GO(g_volume_monitor_adopt_orphan_mount, pFp)
+GO(g_volume_monitor_get, pFv)
//GO(g_volume_monitor_get_connected_drives,
-//GO(g_volume_monitor_get_mount_for_uuid,
-//GO(g_volume_monitor_get_mounts,
+GO(g_volume_monitor_get_mount_for_uuid, pFpp)
+GO(g_volume_monitor_get_mounts, pFp)
//GO(g_volume_monitor_get_type,
-//GO(g_volume_monitor_get_volume_for_uuid,
+GO(g_volume_monitor_get_volume_for_uuid, pFpp)
//GO(g_volume_monitor_get_volumes,
//GO(g_volume_mount,
//GO(g_volume_mount_finish,
-//GO(g_volume_should_automount,
+GO(g_volume_should_automount, iFp)
//GO(g_zlib_compressor_format_get_type,
-//GO(g_zlib_compressor_get_file_info,
+GO(g_zlib_compressor_get_file_info, pFp)
//GO(g_zlib_compressor_get_type,
-//GO(g_zlib_compressor_new,
-//GO(g_zlib_compressor_set_file_info,
-//GO(g_zlib_decompressor_get_file_info,
-//GO(g_zlib_decompressor_get_type,
-//GO(g_zlib_decompressor_new,
+GO(g_zlib_compressor_new, pFui)
+GO(g_zlib_compressor_set_file_info, vFpp)
+GO(g_zlib_decompressor_get_file_info, pFp)
+GO(g_zlib_decompressor_get_type, LFv)
+GO(g_zlib_decompressor_new, pFu)
//GO(_init,
diff --git a/src/wrapped/wrappedglib2.c b/src/wrapped/wrappedglib2.c
index 1ddd6cb..5614314 100755..100644
--- a/src/wrapped/wrappedglib2.c
+++ b/src/wrapped/wrappedglib2.c
@@ -57,7 +57,7 @@ EXPORT void* my_g_build_filename(x64emu_t* emu, void* first, uintptr_t* b)
static int my_timeout_cb(my_signal_t* sig)
{
- return (int)RunFunction(my_context, sig->c_handler, 1, sig->data);
+ return (int)RunFunctionFmt(sig->c_handler, "p", sig->data);
}
EXPORT uint32_t my_g_timeout_add(x64emu_t* emu, uint32_t interval, void* func, void* data)
{
@@ -89,10 +89,10 @@ GO(9) \
// GCopyFct
#define GO(A) \
-static uintptr_t my_copy_fct_##A = 0; \
-static void* my_copy_##A(void* data) \
-{ \
- return (void*)RunFunction(my_context, my_copy_fct_##A, 1, data);\
+static uintptr_t my_copy_fct_##A = 0; \
+static void* my_copy_##A(void* data) \
+{ \
+ return (void*)RunFunctionFmt(my_copy_fct_##A, "p", data); \
}
SUPER()
#undef GO
@@ -111,10 +111,10 @@ static void* findCopyFct(void* fct)
}
// GFreeFct
#define GO(A) \
-static uintptr_t my_free_fct_##A = 0; \
-static void my_free_##A(void* data) \
-{ \
- RunFunction(my_context, my_free_fct_##A, 1, data);\
+static uintptr_t my_free_fct_##A = 0; \
+static void my_free_##A(void* data) \
+{ \
+ RunFunctionFmt(my_free_fct_##A, "p", data); \
}
SUPER()
#undef GO
@@ -133,10 +133,10 @@ static void* findFreeFct(void* fct)
}
// GDuplicateFct
#define GO(A) \
-static uintptr_t my_duplicate_fct_##A = 0; \
-static void* my_duplicate_##A(void* data) \
-{ \
- return (void*)RunFunction(my_context, my_duplicate_fct_##A, 1, data);\
+static uintptr_t my_duplicate_fct_##A = 0; \
+static void* my_duplicate_##A(void* data) \
+{ \
+ return (void*)RunFunctionFmt(my_duplicate_fct_##A, "p", data); \
}
SUPER()
#undef GO
@@ -155,35 +155,35 @@ static void* findDuplicateFct(void* fct)
}
// GSourceFuncs....
// g_source_new callback. First the structure GSourceFuncs statics, with paired x64 source pointer
-#define GO(A) \
+#define GO(A) \
static my_GSourceFuncs_t my_gsourcefuncs_##A = {0}; \
static my_GSourceFuncs_t *ref_gsourcefuncs_##A = NULL;
SUPER()
#undef GO
// then the static functions callback that may be used with the structure, but dispatch also have a callback...
#define GO(A) \
-static uintptr_t fct_funcs_prepare_##A = 0; \
-static int my_funcs_prepare_##A(void* source, int *timeout_) { \
- return (int)RunFunction(my_context, fct_funcs_prepare_##A, 2, source, timeout_); \
-} \
-static uintptr_t fct_funcs_check_##A = 0; \
-static int my_funcs_check_##A(void* source) { \
- return (int)RunFunction(my_context, fct_funcs_check_##A, 1, source); \
-} \
-static uintptr_t fct_funcs_dispatch_cb_##A = 0; \
-static int my_funcs_dispatch_cb_##A(void* a, void* b, void* c, void* d) { \
- return (int)RunFunction(my_context, fct_funcs_dispatch_cb_##A, 4, a, b, c, d); \
-} \
-static uintptr_t fct_funcs_dispatch_##A = 0; \
-static int my_funcs_dispatch_##A(void* source, void* cb, void* data) { \
- uintptr_t old = fct_funcs_dispatch_cb_##A; \
- fct_funcs_dispatch_cb_##A = (uintptr_t)cb; \
- return (int)RunFunction(my_context, fct_funcs_dispatch_##A, 3, source, cb?my_funcs_dispatch_cb_##A:NULL, data); \
- fct_funcs_dispatch_cb_##A = old; \
-} \
-static uintptr_t fct_funcs_finalize_##A = 0; \
-static int my_funcs_finalize_##A(void* source) { \
- return (int)RunFunction(my_context, fct_funcs_finalize_##A, 1, source); \
+static uintptr_t fct_funcs_prepare_##A = 0; \
+static int my_funcs_prepare_##A(void* source, int *timeout_) { \
+ return (int)RunFunctionFmt(fct_funcs_prepare_##A, "pp", source, timeout_); \
+} \
+static uintptr_t fct_funcs_check_##A = 0; \
+static int my_funcs_check_##A(void* source) { \
+ return (int)RunFunctionFmt(fct_funcs_check_##A, "p", source); \
+} \
+static uintptr_t fct_funcs_dispatch_cb_##A = 0; \
+static int my_funcs_dispatch_cb_##A(void* a, void* b, void* c, void* d) { \
+ return (int)RunFunctionFmt(fct_funcs_dispatch_cb_##A, "pppp", a, b, c, d); \
+} \
+static uintptr_t fct_funcs_dispatch_##A = 0; \
+static int my_funcs_dispatch_##A(void* source, void* cb, void* data) { \
+ uintptr_t old = fct_funcs_dispatch_cb_##A; \
+ fct_funcs_dispatch_cb_##A = (uintptr_t)cb; \
+ return (int)RunFunctionFmt(fct_funcs_dispatch_##A, "ppp", source, cb?my_funcs_dispatch_cb_##A:NULL, data); \
+ fct_funcs_dispatch_cb_##A = old; \
+} \
+static uintptr_t fct_funcs_finalize_##A = 0; \
+static int my_funcs_finalize_##A(void* source) { \
+ return (int)RunFunctionFmt(fct_funcs_finalize_##A, "p", source); \
}
SUPER()
#undef GO
@@ -214,10 +214,10 @@ static my_GSourceFuncs_t* findFreeGSourceFuncs(my_GSourceFuncs_t* fcts)
// PollFunc ...
#define GO(A) \
-static uintptr_t my_poll_fct_##A = 0; \
-static int my_poll_##A(void* ufds, uint32_t nfsd, int32_t timeout_) \
-{ \
- return RunFunction(my_context, my_poll_fct_##A, 3, ufds, nfsd, timeout_);\
+static uintptr_t my_poll_fct_##A = 0; \
+static int my_poll_##A(void* ufds, uint32_t nfsd, int32_t timeout_) \
+{ \
+ return RunFunctionFmt(my_poll_fct_##A, "pui", ufds, nfsd, timeout_); \
}
SUPER()
#undef GO
@@ -246,10 +246,10 @@ static void* reversePollFct(void* fct)
// GHashFunc ...
#define GO(A) \
-static uintptr_t my_hashfunc_fct_##A = 0; \
-static uint32_t my_hashfunc_##A(void* key) \
-{ \
- return (uint32_t)RunFunction(my_context, my_hashfunc_fct_##A, 1, key);\
+static uintptr_t my_hashfunc_fct_##A = 0; \
+static uint32_t my_hashfunc_##A(void* key) \
+{ \
+ return (uint32_t)RunFunctionFmt(my_hashfunc_fct_##A, "p", key); \
}
SUPER()
#undef GO
@@ -268,10 +268,10 @@ static void* findHashFct(void* fct)
}
// GEqualFunc ...
#define GO(A) \
-static uintptr_t my_equalfunc_fct_##A = 0; \
-static int my_equalfunc_##A(void* a, void* b) \
-{ \
- return RunFunction(my_context, my_equalfunc_fct_##A, 2, a, b);\
+static uintptr_t my_equalfunc_fct_##A = 0; \
+static int my_equalfunc_##A(void* a, void* b) \
+{ \
+ return RunFunctionFmt(my_equalfunc_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -290,10 +290,10 @@ static void* findEqualFct(void* fct)
}
// GDestroyFunc ...
#define GO(A) \
-static uintptr_t my_destroyfunc_fct_##A = 0; \
-static int my_destroyfunc_##A(void* a, void* b) \
-{ \
- return RunFunction(my_context, my_destroyfunc_fct_##A, 2, a, b);\
+static uintptr_t my_destroyfunc_fct_##A = 0; \
+static int my_destroyfunc_##A(void* a, void* b) \
+{ \
+ return RunFunctionFmt(my_destroyfunc_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -312,10 +312,10 @@ static void* findDestroyFct(void* fct)
}
// GSpawnChildSetupFunc ...
#define GO(A) \
-static uintptr_t my_spwnchildsetup_fct_##A = 0; \
-static void my_spwnchildsetup_##A(void* data) \
-{ \
- RunFunction(my_context, my_spwnchildsetup_fct_##A, 1, data);\
+static uintptr_t my_spwnchildsetup_fct_##A = 0; \
+static void my_spwnchildsetup_##A(void* data) \
+{ \
+ RunFunctionFmt(my_spwnchildsetup_fct_##A, "p", data); \
}
SUPER()
#undef GO
@@ -334,10 +334,10 @@ static void* findSpawnChildSetupFct(void* fct)
}
// GSourceFunc ...
#define GO(A) \
-static uintptr_t my_GSourceFunc_fct_##A = 0; \
-static void my_GSourceFunc_##A(void* a, void* b, void* c, void* d) \
-{ \
- RunFunction(my_context, my_GSourceFunc_fct_##A, 4, a, b, c, d);\
+static uintptr_t my_GSourceFunc_fct_##A = 0; \
+static void my_GSourceFunc_##A(void* a, void* b, void* c, void* d) \
+{ \
+ RunFunctionFmt(my_GSourceFunc_fct_##A, "pppp", a, b, c, d); \
}
SUPER()
#undef GO
@@ -356,10 +356,10 @@ static void* findGSourceFuncFct(void* fct)
}
// GCompareFunc ...
#define GO(A) \
-static uintptr_t my_GCompareFunc_fct_##A = 0; \
-static int my_GCompareFunc_##A(void* a, void* b) \
-{ \
- return (int)RunFunction(my_context, my_GCompareFunc_fct_##A, 2, a, b);\
+static uintptr_t my_GCompareFunc_fct_##A = 0; \
+static int my_GCompareFunc_##A(void* a, void* b) \
+{ \
+ return (int)RunFunctionFmt(my_GCompareFunc_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -378,10 +378,10 @@ static void* findGCompareFuncFct(void* fct)
}
// GCompareDataFunc ...
#define GO(A) \
-static uintptr_t my_GCompareDataFunc_fct_##A = 0; \
-static int my_GCompareDataFunc_##A(void* a, void* b, void* data) \
-{ \
- return (int)RunFunction(my_context, my_GCompareDataFunc_fct_##A, 3, a, b, data);\
+static uintptr_t my_GCompareDataFunc_fct_##A = 0; \
+static int my_GCompareDataFunc_##A(void* a, void* b, void* data) \
+{ \
+ return (int)RunFunctionFmt(my_GCompareDataFunc_fct_##A, "ppp", a, b, data); \
}
SUPER()
#undef GO
@@ -400,10 +400,10 @@ static void* findGCompareDataFuncFct(void* fct)
}
// GCompletionFunc ...
#define GO(A) \
-static uintptr_t my_GCompletionFunc_fct_##A = 0; \
-static void* my_GCompletionFunc_##A(void* a) \
-{ \
- return (void*)RunFunction(my_context, my_GCompletionFunc_fct_##A, 1, a);\
+static uintptr_t my_GCompletionFunc_fct_##A = 0; \
+static void* my_GCompletionFunc_##A(void* a) \
+{ \
+ return (void*)RunFunctionFmt(my_GCompletionFunc_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -422,10 +422,10 @@ static void* findGCompletionFct(void* fct)
}
// GCompletionStrncmpFunc ...
#define GO(A) \
-static uintptr_t my_GCompletionStrncmpFunc_fct_##A = 0; \
-static int my_GCompletionStrncmpFunc_##A(void* a, void* b, unsigned long n) \
-{ \
- return (int)RunFunction(my_context, my_GCompletionStrncmpFunc_fct_##A, 3, a, b, n); \
+static uintptr_t my_GCompletionStrncmpFunc_fct_##A = 0; \
+static int my_GCompletionStrncmpFunc_##A(void* a, void* b, unsigned long n) \
+{ \
+ return (int)RunFunctionFmt(my_GCompletionStrncmpFunc_fct_##A, "ppL", a, b, n); \
}
SUPER()
#undef GO
@@ -444,10 +444,10 @@ static void* findGCompletionStrncmpFuncFct(void* fct)
}
// GIOFunc ...
#define GO(A) \
-static uintptr_t my_GIOFunc_fct_##A = 0; \
-static int my_GIOFunc_##A(void* a, int b, void* c) \
-{ \
- return (int)RunFunction(my_context, my_GIOFunc_fct_##A, 3, a, b, c); \
+static uintptr_t my_GIOFunc_fct_##A = 0; \
+static int my_GIOFunc_##A(void* a, int b, void* c) \
+{ \
+ return (int)RunFunctionFmt(my_GIOFunc_fct_##A, "pip", a, b, c); \
}
SUPER()
#undef GO
@@ -466,10 +466,10 @@ static void* findGIOFuncFct(void* fct)
}
// GDestroyNotify ...
#define GO(A) \
-static uintptr_t my_GDestroyNotify_fct_##A = 0; \
-static void my_GDestroyNotify_##A(void* a) \
-{ \
- RunFunction(my_context, my_GDestroyNotify_fct_##A, 1, a); \
+static uintptr_t my_GDestroyNotify_fct_##A = 0; \
+static void my_GDestroyNotify_##A(void* a) \
+{ \
+ RunFunctionFmt(my_GDestroyNotify_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -488,10 +488,10 @@ static void* findGDestroyNotifyFct(void* fct)
}
// GFunc ...
#define GO(A) \
-static uintptr_t my_GFunc_fct_##A = 0; \
-static void my_GFunc_##A(void* a, void* b) \
-{ \
- RunFunction(my_context, my_GFunc_fct_##A, 2, a, b); \
+static uintptr_t my_GFunc_fct_##A = 0; \
+static void my_GFunc_##A(void* a, void* b) \
+{ \
+ RunFunctionFmt(my_GFunc_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -510,10 +510,10 @@ static void* findGFuncFct(void* fct)
}
// GHFunc ...
#define GO(A) \
-static uintptr_t my_GHFunc_fct_##A = 0; \
-static void my_GHFunc_##A(void* a, void* b, void* c) \
-{ \
- RunFunction(my_context, my_GHFunc_fct_##A, 3, a, b, c); \
+static uintptr_t my_GHFunc_fct_##A = 0; \
+static void my_GHFunc_##A(void* a, void* b, void* c) \
+{ \
+ RunFunctionFmt(my_GHFunc_fct_##A, "ppp", a, b, c); \
}
SUPER()
#undef GO
@@ -532,10 +532,10 @@ static void* findGHFuncFct(void* fct)
}
// GHRFunc ...
#define GO(A) \
-static uintptr_t my_GHRFunc_fct_##A = 0; \
-static int my_GHRFunc_##A(void* a, void* b, void* c) \
-{ \
- return RunFunction(my_context, my_GHRFunc_fct_##A, 3, a, b, c); \
+static uintptr_t my_GHRFunc_fct_##A = 0; \
+static int my_GHRFunc_##A(void* a, void* b, void* c) \
+{ \
+ return RunFunctionFmt(my_GHRFunc_fct_##A, "ppp", a, b, c); \
}
SUPER()
#undef GO
@@ -554,10 +554,10 @@ static void* findGHRFuncFct(void* fct)
}
// GChildWatchFunc ...
#define GO(A) \
-static uintptr_t my_GChildWatchFunc_fct_##A = 0; \
-static void my_GChildWatchFunc_##A(int a, int b, void* c) \
-{ \
- RunFunction(my_context, my_GChildWatchFunc_fct_##A, 3, a, b, c); \
+static uintptr_t my_GChildWatchFunc_fct_##A = 0; \
+static void my_GChildWatchFunc_##A(int a, int b, void* c) \
+{ \
+ RunFunctionFmt(my_GChildWatchFunc_fct_##A, "iip", a, b, c); \
}
SUPER()
#undef GO
@@ -576,10 +576,10 @@ static void* findGChildWatchFuncFct(void* fct)
}
// GLogFunc ...
#define GO(A) \
-static uintptr_t my_GLogFunc_fct_##A = 0; \
-static void my_GLogFunc_##A(void* a, int b, void* c, void* d) \
-{ \
- RunFunction(my_context, my_GLogFunc_fct_##A, 4, a, b, c, d); \
+static uintptr_t my_GLogFunc_fct_##A = 0; \
+static void my_GLogFunc_##A(void* a, int b, void* c, void* d) \
+{ \
+ RunFunctionFmt(my_GLogFunc_fct_##A, "pipp", a, b, c, d); \
}
SUPER()
#undef GO
@@ -606,10 +606,10 @@ static void* reverseGLogFuncFct(void* fct)
}
// GPrintFunc ...
#define GO(A) \
-static uintptr_t my_GPrintFunc_fct_##A = 0; \
-static void my_GPrintFunc_##A(void* a) \
-{ \
- RunFunction(my_context, my_GPrintFunc_fct_##A, 1, a); \
+static uintptr_t my_GPrintFunc_fct_##A = 0; \
+static void my_GPrintFunc_##A(void* a) \
+{ \
+ RunFunctionFmt(my_GPrintFunc_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -636,10 +636,10 @@ static void* reverseGPrintFuncFct(void* fct)
}
// GOptionArg ...
#define GO(A) \
-static uintptr_t my_GOptionArg_fct_##A = 0; \
-static int my_GOptionArg_##A(void* a, void* b, void* c, void* d) \
-{ \
- return (int)RunFunction(my_context, my_GOptionArg_fct_##A, 4, a, b, c, d); \
+static uintptr_t my_GOptionArg_fct_##A = 0; \
+static int my_GOptionArg_##A(void* a, void* b, void* c, void* d) \
+{ \
+ return (int)RunFunctionFmt(my_GOptionArg_fct_##A, "pppp", a, b, c, d); \
}
SUPER()
#undef GO
@@ -666,10 +666,10 @@ static void* reverseGOptionArgFct(void* fct)
}
// GNodeTraverseFunc ...
#define GO(A) \
-static uintptr_t my_GNodeTraverseFunc_fct_##A = 0; \
-static int my_GNodeTraverseFunc_##A(void* a, void* b) \
-{ \
- return (int)RunFunction(my_context, my_GNodeTraverseFunc_fct_##A, 2, a, b); \
+static uintptr_t my_GNodeTraverseFunc_fct_##A = 0; \
+static int my_GNodeTraverseFunc_##A(void* a, void* b) \
+{ \
+ return (int)RunFunctionFmt(my_GNodeTraverseFunc_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -688,10 +688,10 @@ static void* findGNodeTraverseFuncFct(void* fct)
}
// GThreadFunc ...
#define GO(A) \
-static uintptr_t my_GThreadFunc_fct_##A = 0; \
-static void* my_GThreadFunc_##A(void* a) \
-{ \
- return (void*)RunFunction(my_context, my_GThreadFunc_fct_##A, 1, a);\
+static uintptr_t my_GThreadFunc_fct_##A = 0; \
+static void* my_GThreadFunc_##A(void* a) \
+{ \
+ return (void*)RunFunctionFmt(my_GThreadFunc_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -863,7 +863,7 @@ EXPORT void* my_g_main_context_get_poll_func(x64emu_t* emu, void* context)
// needs to bridge....
return (void*)AddCheckBridge(my_lib->w.bridge, iFpui, ret, 0, NULL);
}
-
+
EXPORT void my_g_main_context_set_poll_func(x64emu_t* emu, void* context, void* func)
{
my->g_main_context_set_poll_func(context, findPollFct(func));
@@ -896,17 +896,17 @@ EXPORT void my_g_hash_table_foreach(x64emu_t* emu, void* table, void* f, void* d
EXPORT uint32_t my_g_hash_table_foreach_remove(x64emu_t* emu, void* table, void* f, void* data)
{
-
+
return my->g_hash_table_foreach_remove(table, findGHRFuncFct(f), data);
}
EXPORT uint32_t my_g_hash_table_foreach_steal(x64emu_t* emu, void* table, void* f, void* data)
{
-
+
return my->g_hash_table_foreach_steal(table, findGHRFuncFct(f), data);
}
EXPORT void* my_g_hash_table_find(x64emu_t* emu, void* table, void* f, void* data)
{
-
+
return my->g_hash_table_find(table, findGHRFuncFct(f), data);
}
@@ -1388,6 +1388,11 @@ EXPORT void my_g_slist_free_full(x64emu_t* emu, void* list, void* f)
my->g_slist_free_full(list, findDestroyFct(f));
}
+EXPORT void* my_g_list_insert_sorted_with_data(x64emu_t* emu, void* list, void* data, void* f, void* user)
+{
+ return my->g_list_insert_sorted_with_data(list, data, findGCompareDataFuncFct(f), user);
+}
+
#define PRE_INIT \
if(box64_nogtk) \
return -1;
diff --git a/src/wrapped/wrappedglib2_private.h b/src/wrapped/wrappedglib2_private.h
index 6cbff07..6ee782f 100755..100644
--- a/src/wrapped/wrappedglib2_private.h
+++ b/src/wrapped/wrappedglib2_private.h
@@ -29,26 +29,22 @@ GO(g_ascii_dtostr, pFpid)
GO(g_ascii_formatd, pFpipd)
GO(g_ascii_strcasecmp, iFpp)
GO(g_ascii_strdown, pFpi)
-GO(g_ascii_strncasecmp, iFppu)
+GO(g_ascii_strncasecmp, iFppL)
GO(g_ascii_strtod, dFpp)
-GO(g_ascii_strtoll, IFppu)
-GO(g_ascii_strtoull, UFppu)
-GO(g_ascii_strup, pFpi)
+GO(g_ascii_strtoll, lFppu)
+GO(g_ascii_strtoull, LFppu)
+GO(g_ascii_strup, pFpl)
GO(g_ascii_tolower, CFC)
GO(g_ascii_toupper, CFC)
GO(g_ascii_xdigit_value, iFC)
GO(g_assertion_message, vFppipp)
-#ifdef HAVE_LD80BITS
-GO(g_assertion_message_cmpnum, vFppippDDC)
-#else
-GO(g_assertion_message_cmpnum, vFppippKKC)
-#endif
+GO(g_assertion_message_cmpnum, vFppippDpDC)
GO(g_assertion_message_cmpstr, vFppippppp)
GO(g_assertion_message_error, vFppipppui)
GO(g_assertion_message_expr, vFppipp)
GO(g_assert_warning, vFppipp)
GO(g_async_queue_length, iFp)
-//GO(g_async_queue_length_unlocked,
+GO(g_async_queue_length_unlocked, iFp)
GO(g_async_queue_lock, vFp)
GO(g_async_queue_new, pFv)
//GO(g_async_queue_new_full,
@@ -58,14 +54,14 @@ GO(g_async_queue_push, vFpp)
//GO(g_async_queue_push_sorted,
//GO(g_async_queue_push_sorted_unlocked,
GO(g_async_queue_push_unlocked, vFpp)
-GO(g_async_queue_ref, vFp)
+GO(g_async_queue_ref, pFp)
//GO(g_async_queue_ref_unlocked,
//GO(g_async_queue_sort,
//GO(g_async_queue_sort_unlocked,
//GO(g_async_queue_timed_pop,
-//GO(g_async_queue_timed_pop_unlocked,
+GO(g_async_queue_timed_pop_unlocked, pFpp)
GO(g_async_queue_timeout_pop, pFpU)
-GO(g_async_queue_timeout_pop_unlocked, pFpU)
+GO(g_async_queue_timeout_pop_unlocked, pFpL)
GO(g_async_queue_try_pop, pFp)
GO(g_async_queue_try_pop_unlocked, pFp)
GO(g_async_queue_unlock, vFp)
@@ -74,21 +70,21 @@ GO(g_async_queue_unref_and_unlock, vFp)
GO2(g_atexit, vFEp, my_atexit)
//GO(g_atomic_int_add,
//GO(g_atomic_int_and,
-//GO(g_atomic_int_compare_and_exchange,
-//GO(g_atomic_int_dec_and_test,
+GO(g_atomic_int_compare_and_exchange, iFpii)
+GO(g_atomic_int_dec_and_test, iFp)
GO(g_atomic_int_exchange_and_add, iFpi)
-//GO(g_atomic_int_get,
-//GO(g_atomic_int_inc,
+GO(g_atomic_int_get, iFp)
+GO(g_atomic_int_inc, vFp)
//GO(g_atomic_int_or,
//GO(g_atomic_int_set,
-//GO(g_atomic_int_xor,
-//GO(g_atomic_pointer_add,
+GO(g_atomic_int_xor, uFpu)
+GO(g_atomic_pointer_add, lFpl)
//GO(g_atomic_pointer_and,
-//GO(g_atomic_pointer_compare_and_exchange,
-//GO(g_atomic_pointer_get,
+GO(g_atomic_pointer_compare_and_exchange, iFppp)
+GO(g_atomic_pointer_get, pFp)
//GO(g_atomic_pointer_or,
-//GO(g_atomic_pointer_set,
-//GO(g_atomic_pointer_xor,
+GO(g_atomic_pointer_set, vFpp)
+GO(g_atomic_pointer_xor, LFpL)
GO(g_base64_decode, pFpp)
GO(g_base64_decode_inplace, pFpp)
GO(g_base64_decode_step, LFpLppp)
@@ -98,50 +94,50 @@ GO(g_base64_encode_step, LFpLippp)
GO(g_basename, pFp)
//GO(g_bit_lock,
GO(g_bit_nth_lsf, iFii)
-GO(g_bit_nth_msf, iFii)
-GO(g_bit_storage, iFi)
-//GO(g_bit_trylock,
-//GO(g_bit_unlock,
+GO(g_bit_nth_msf, iFLi)
+GO(g_bit_storage, uFL)
+GO(g_bit_trylock, iFpi)
+GO(g_bit_unlock, vFpi)
//GO(g_blow_chunks,
//GO(g_bookmark_file_add_application,
-//GO(g_bookmark_file_add_group,
+GO(g_bookmark_file_add_group, vFppp)
//GO(g_bookmark_file_error_quark,
//GO(g_bookmark_file_free,
//GO(g_bookmark_file_get_added,
-//GO(g_bookmark_file_get_app_info,
-//GO(g_bookmark_file_get_applications,
+GO(g_bookmark_file_get_app_info, iFppppppp)
+GO(g_bookmark_file_get_applications, pFpppp)
//GO(g_bookmark_file_get_description,
//GO(g_bookmark_file_get_groups,
-//GO(g_bookmark_file_get_icon,
+GO(g_bookmark_file_get_icon, iFppppp)
//GO(g_bookmark_file_get_is_private,
-//GO(g_bookmark_file_get_mime_type,
+GO(g_bookmark_file_get_mime_type, pFppp)
//GO(g_bookmark_file_get_modified,
-//GO(g_bookmark_file_get_size,
+GO(g_bookmark_file_get_size, iFp)
//GO(g_bookmark_file_get_title,
-//GO(g_bookmark_file_get_uris,
-//GO(g_bookmark_file_get_visited,
+GO(g_bookmark_file_get_uris, pFpp)
+GO(g_bookmark_file_get_visited, lFppp)
//GO(g_bookmark_file_has_application,
//GO(g_bookmark_file_has_group,
-//GO(g_bookmark_file_has_item,
-//GO(g_bookmark_file_load_from_data,
-//GO(g_bookmark_file_load_from_data_dirs,
+GO(g_bookmark_file_has_item, iFpp)
+GO(g_bookmark_file_load_from_data, iFppLp)
+GO(g_bookmark_file_load_from_data_dirs, iFpppp)
//GO(g_bookmark_file_load_from_file,
-//GO(g_bookmark_file_move_item,
-//GO(g_bookmark_file_new,
+GO(g_bookmark_file_move_item, iFpppp)
+GO(g_bookmark_file_new, pFv)
//GO(g_bookmark_file_remove_application,
//GO(g_bookmark_file_remove_group,
-//GO(g_bookmark_file_remove_item,
+GO(g_bookmark_file_remove_item, iFppp)
//GO(g_bookmark_file_set_added,
-//GO(g_bookmark_file_set_app_info,
+GO(g_bookmark_file_set_app_info, iFppppilp)
//GO(g_bookmark_file_set_description,
-//GO(g_bookmark_file_set_groups,
-//GO(g_bookmark_file_set_icon,
-//GO(g_bookmark_file_set_is_private,
+GO(g_bookmark_file_set_groups, vFpppL)
+GO(g_bookmark_file_set_icon, vFpppp)
+GO(g_bookmark_file_set_is_private, vFppi)
//GO(g_bookmark_file_set_mime_type,
//GO(g_bookmark_file_set_modified,
//GO(g_bookmark_file_set_title,
-//GO(g_bookmark_file_set_visited,
-//GO(g_bookmark_file_to_data,
+GO(g_bookmark_file_set_visited, vFppl)
+GO(g_bookmark_file_to_data, pFppp)
//GO(g_bookmark_file_to_file,
GOM(g_build_filename, pFEpV)
GO(g_build_filenamev, pFp)
@@ -164,7 +160,7 @@ GO(g_byte_array_sized_new, pFu)
GO(g_byte_array_unref, vFp)
GO(g_bytes_compare, iFpp)
GO(g_bytes_equal, iFpp)
-GO(g_bytes_get_data, pFpL)
+GO(g_bytes_get_data, pFpp)
GO(g_bytes_get_size, LFp)
GO(g_bytes_hash, uFp)
GO(g_bytes_new, pFpL)
@@ -176,21 +172,21 @@ GO(g_bytes_ref, pFp)
GO(g_bytes_unref, vFp)
GO(g_bytes_unref_to_array, pFp)
GO(g_bytes_unref_to_data, pFpp)
-//GO(g_cache_destroy,
-//GO(g_cache_insert,
+GO(g_cache_destroy, vFp)
+GO(g_cache_insert, pFpp)
//GO(g_cache_key_foreach,
//GO(g_cache_new,
-//GO(g_cache_remove,
+GO(g_cache_remove, vFpp)
//GO(g_cache_value_foreach,
GO(g_chdir, iFp)
-//GO(g_checksum_copy,
+GO(g_checksum_copy, pFp)
//GO(g_checksum_free,
-//GO(g_checksum_get_digest,
-//GO(g_checksum_get_string,
-//GO(g_checksum_new,
+GO(g_checksum_get_digest, vFppp)
+GO(g_checksum_get_string, pFp)
+GO(g_checksum_new, pFu)
//GO(g_checksum_reset,
-//GO(g_checksum_type_get_length,
-//GO(g_checksum_update,
+GO(g_checksum_type_get_length, lFu)
+GO(g_checksum_update, vFppl)
GOM(g_child_watch_add, uFEipp)
GOM(g_child_watch_add_full, uFEiippp)
GO(g_child_watch_source_new, pFi)
@@ -206,20 +202,20 @@ GO(g_completion_free, vFp)
GOM(g_completion_new, pFEp)
GO(g_completion_remove_items, vFpp)
GOM(g_completion_set_compare, vFEpp)
-//GO(g_compute_checksum_for_bytes,
-//GO(g_compute_checksum_for_data,
-//GO(g_compute_checksum_for_string,
-//GO(g_compute_hmac_for_data,
-//GO(g_compute_hmac_for_string,
+GO(g_compute_checksum_for_bytes, pFup)
+GO(g_compute_checksum_for_data, pFupL)
+GO(g_compute_checksum_for_string, pFupl)
+GO(g_compute_hmac_for_data, pFupLpL)
+GO(g_compute_hmac_for_string, pFupLpl)
GO(g_cond_broadcast, vFp)
GO(g_cond_clear, vFp)
GO(g_cond_free, vFp)
GO(g_cond_init, vFp)
GO(g_cond_new, pFv)
GO(g_cond_signal, vFp)
-//GO(g_cond_timed_wait,
+GO(g_cond_timed_wait, iFppp)
GO(g_cond_wait, vFpp)
-//GO(g_cond_wait_until,
+GO(g_cond_wait_until, iFppl)
GO(g_convert, pFplppppp)
//GO(g_convert_error_quark,
GO(g_convert_with_fallback, pFplpppppp)
@@ -237,10 +233,10 @@ GOM(g_datalist_id_set_data_full, vFEpupp)
GO(g_datalist_init, vFp)
GO(g_datalist_set_flags, vFpu)
GO(g_datalist_unset_flags, vFpu)
-//GO(g_dataset_destroy,
+GO(g_dataset_destroy, vFp)
//GO(g_dataset_foreach,
//GO(g_dataset_id_get_data,
-//GO(g_dataset_id_remove_no_notify,
+GO(g_dataset_id_remove_no_notify, pFpu)
//GO(g_dataset_id_set_data_full,
GO(g_date_add_days, vFpu)
GO(g_date_add_months, vFpu)
@@ -252,90 +248,90 @@ GO(g_date_days_between, iFpp)
GO(g_date_free, vFp)
GO(g_date_get_day, CFp)
GO(g_date_get_day_of_year, uFp)
-GO(g_date_get_days_in_month, CFip)
+GO(g_date_get_days_in_month, CFuW)
GO(g_date_get_iso8601_week_of_year, uFp)
GO(g_date_get_julian, uFp)
GO(g_date_get_monday_week_of_year, uFp)
GO(g_date_get_monday_weeks_in_year, CFp)
-GO(g_date_get_month, iFp)
+GO(g_date_get_month, uFp)
GO(g_date_get_sunday_week_of_year, uFp)
-GO(g_date_get_sunday_weeks_in_year, CFp)
-GO(g_date_get_weekday, iFp)
+GO(g_date_get_sunday_weeks_in_year, CFW)
+GO(g_date_get_weekday, uFp)
GO(g_date_get_year, WFp)
GO(g_date_is_first_of_month, iFp)
GO(g_date_is_last_of_month, iFp)
-GO(g_date_is_leap_year, iFp)
+GO(g_date_is_leap_year, iFW)
GO(g_date_new, pFv)
-GO(g_date_new_dmy, pFCiW)
+GO(g_date_new_dmy, pFCuW)
GO(g_date_new_julian, pFu)
GO(g_date_order, vFpp)
GO(g_date_set_day, vFpC)
-GO(g_date_set_dmy, vFpCiW)
+GO(g_date_set_dmy, vFpCuW)
GO(g_date_set_julian, vFpu)
-GO(g_date_set_month, vFpi)
+GO(g_date_set_month, vFpu)
GO(g_date_set_parse, vFpp)
GO(g_date_set_time, vFpi)
-//GO(g_date_set_time_t,
+GO(g_date_set_time_t, vFpl)
GO(g_date_set_time_val, vFpp)
GO(g_date_set_year, vFpW)
GO(g_date_strftime, LFpLpp)
GO(g_date_subtract_days, vFpu)
GO(g_date_subtract_months, vFpu)
GO(g_date_subtract_years, vFpu)
-//GO(g_date_time_add,
+GO(g_date_time_add, pFpl)
//GO(g_date_time_add_days,
-//GO(g_date_time_add_full,
+GO(g_date_time_add_full, pFpiiiiid)
//GO(g_date_time_add_hours,
-//GO(g_date_time_add_minutes,
+GO(g_date_time_add_minutes, pFpi)
//GO(g_date_time_add_months,
-//GO(g_date_time_add_seconds,
+GO(g_date_time_add_seconds, pFpd)
//GO(g_date_time_add_weeks,
//GO(g_date_time_add_years,
//GO(g_date_time_compare,
-//GO(g_date_time_difference,
+GO(g_date_time_difference, lFpp)
//GO(g_date_time_equal,
-//GO(g_date_time_format,
+GO(g_date_time_format, pFpp)
//GO(g_date_time_get_day_of_month,
//GO(g_date_time_get_day_of_week,
//GO(g_date_time_get_day_of_year,
//GO(g_date_time_get_hour,
-//GO(g_date_time_get_microsecond,
+GO(g_date_time_get_microsecond, iFp)
//GO(g_date_time_get_minute,
//GO(g_date_time_get_month,
//GO(g_date_time_get_second,
-//GO(g_date_time_get_seconds,
-//GO(g_date_time_get_timezone_abbreviation,
-//GO(g_date_time_get_utc_offset,
+GO(g_date_time_get_seconds, dFp)
+GO(g_date_time_get_timezone_abbreviation, pFp)
+GO(g_date_time_get_utc_offset, lFp)
//GO(g_date_time_get_week_numbering_year,
//GO(g_date_time_get_week_of_year,
//GO(g_date_time_get_year,
-//GO(g_date_time_get_ymd,
+GO(g_date_time_get_ymd, vFpppp)
//GO(g_date_time_hash,
-//GO(g_date_time_is_daylight_savings,
-//GO(g_date_time_new,
+GO(g_date_time_is_daylight_savings, iFp)
+GO(g_date_time_new, pFpiiiiid)
//GO(g_date_time_new_from_timeval_local,
-//GO(g_date_time_new_from_timeval_utc,
+GO(g_date_time_new_from_timeval_utc, pFp)
//GO(g_date_time_new_from_unix_local,
-//GO(g_date_time_new_from_unix_utc,
+GO(g_date_time_new_from_unix_utc, pFl)
//GO(g_date_time_new_local,
-//GO(g_date_time_new_now,
+GO(g_date_time_new_now, pFp)
//GO(g_date_time_new_now_local,
-//GO(g_date_time_new_now_utc,
-//GO(g_date_time_new_utc,
+GO(g_date_time_new_now_utc, pFv)
+GO(g_date_time_new_utc, pFiiiiid)
//GO(g_date_time_ref,
//GO(g_date_time_to_local,
-//GO(g_date_time_to_timeval,
-//GO(g_date_time_to_timezone,
-//GO(g_date_time_to_unix,
-//GO(g_date_time_to_utc,
+GO(g_date_time_to_timeval, iFpp)
+GO(g_date_time_to_timezone, pFpp)
+GO(g_date_time_to_unix, lFp)
+GO(g_date_time_to_utc, pFp)
//GO(g_date_time_unref,
GO(g_date_to_struct_tm, vFpp)
GO(g_date_valid, iFp)
GO(g_date_valid_day, iFC)
-GO(g_date_valid_dmy, iFCiW)
+GO(g_date_valid_dmy, iFCuW)
GO(g_date_valid_julian, iFu)
-GO(g_date_valid_month, iFi)
-GO(g_date_valid_weekday, iFi)
+GO(g_date_valid_month, iFu)
+GO(g_date_valid_weekday, iFu)
GO(g_date_valid_year, iFW)
GO(g_dcgettext, pFppi)
GO(g_dgettext, pFpp)
@@ -343,7 +339,7 @@ GO(g_dir_close, vFp)
GO(g_direct_equal, iFpp)
GO(g_direct_hash, uFp)
GO(g_dir_make_tmp, pFpp)
-GO(g_dir_open, pFp)
+GO(g_dir_open, pFpup)
GO(g_dir_read_name, pFp)
GO(g_dir_rewind, vFp)
GO(g_dngettext, pFpppL)
@@ -356,28 +352,28 @@ GO(g_environ_setenv, pFpppi)
GO(g_environ_unsetenv, pFpp)
GO(g_error_copy, pFp)
GO(g_error_free, vFp)
-GO(g_error_matches, iFppi)
+GO(g_error_matches, iFpui)
GOM(g_error_new, pFEpipV)
-GO(g_error_new_literal, pFpip)
+GO(g_error_new_literal, pFuip)
GOM(g_error_new_valist, pFEpipA)
-GO(g_file_error_from_errno, iFi)
+GO(g_file_error_from_errno, uFi)
GO(g_file_error_quark, pFv)
GO(g_file_get_contents, iFpppp)
GO(g_filename_display_basename, pFp)
GO(g_filename_display_name, pFp)
GO(g_filename_from_uri, pFppp)
-GO(g_filename_from_utf8, pFpippp)
+GO(g_filename_from_utf8, pFplppp)
GO(g_filename_to_uri, pFppp)
GO(g_filename_to_utf8, pFpippp)
GO(g_file_open_tmp, iFppp)
GO(g_file_read_link, pFpp)
-GO(g_file_set_contents, iFppip)
-GO(g_file_test, iFpi)
+GO(g_file_set_contents, iFpplp)
+GO(g_file_test, iFpu)
GO(g_find_program_in_path, pFp) // need wrap?
GO(g_fopen, pFpp)
-GO(g_format_size, pFU)
-GO(g_format_size_for_display, pFI)
-GO(g_format_size_full, pFUi)
+GO(g_format_size, pFL)
+GO(g_format_size_for_display, pFl)
+GO(g_format_size_full, pFLu)
GOM(g_fprintf, iFEppV)
GO(g_free, vFp)
GO(g_freopen, pFppp)
@@ -397,7 +393,7 @@ GO(g_get_monotonic_time, IFv)
//GO(g_get_num_processors,
GO(g_get_prgname, pFv)
GO(g_get_real_name, pFv)
-GO(g_get_real_time, IFv)
+GO(g_get_real_time, lFv)
GO(g_get_system_config_dirs, pFv)
GO(g_get_system_data_dirs, pFv)
GO(g_get_tmp_dir, pFv)
@@ -406,7 +402,7 @@ GO(g_get_user_config_dir, pFv)
GO(g_get_user_data_dir, pFv)
GO(g_get_user_name, pFv)
GO(g_get_user_runtime_dir, pFv)
-GO(g_get_user_special_dir, pFi)
+GO(g_get_user_special_dir, pFu)
GO(g_hash_table_add, iFpp)
GO(g_hash_table_contains, iFpp)
GO(g_hash_table_destroy, vFp)
@@ -436,13 +432,13 @@ GO(g_hash_table_size, uFp)
GO(g_hash_table_steal, iFpp)
GO(g_hash_table_steal_all, vFp)
GO(g_hash_table_unref, vFp)
-//GO(g_hmac_copy,
-//GO(g_hmac_get_digest,
-//GO(g_hmac_get_string,
-//GO(g_hmac_new,
-//GO(g_hmac_ref,
+GO(g_hmac_copy, pFp)
+GO(g_hmac_get_digest, vFppp)
+GO(g_hmac_get_string, pFp)
+GO(g_hmac_new, pFupL)
+GO(g_hmac_ref, pFp)
//GO(g_hmac_unref,
-//GO(g_hmac_update,
+GO(g_hmac_update, vFppl)
//GO(g_hook_alloc,
//GO(g_hook_compare_ids,
//GO(g_hook_destroy,
@@ -487,7 +483,7 @@ GO(g_int_hash, uFp)
GOM(g_io_add_watch, uFEpipp)
GOM(g_io_add_watch_full, uFEpiippp)
GO(g_io_channel_close, vFp)
-GO(g_io_channel_error_from_errno, iFi)
+GO(g_io_channel_error_from_errno, uFi)
GO(g_io_channel_error_quark, pFv)
GO(g_io_channel_flush, iFpp)
GO(g_io_channel_get_buffer_condition, iFp)
@@ -530,7 +526,7 @@ GO(g_key_file_get_comment, pFpppp)
GO(g_key_file_get_double, dFpppp)
GO(g_key_file_get_double_list, pFppppp)
GO(g_key_file_get_groups, pFpp)
-GO(g_key_file_get_int64, IFpppp)
+GO(g_key_file_get_int64, lFpppp)
GO(g_key_file_get_integer, iFpppp)
GO(g_key_file_get_integer_list, pFppppp)
GO(g_key_file_get_keys, pFpppp)
@@ -539,14 +535,14 @@ GO(g_key_file_get_locale_string_list, pFpppppp)
GO(g_key_file_get_start_group, pFp)
GO(g_key_file_get_string, pFpppp)
GO(g_key_file_get_string_list, pFppppp)
-GO(g_key_file_get_uint64, UFpppp)
+GO(g_key_file_get_uint64, LFpppp)
GO(g_key_file_get_value, pFpppp)
GO(g_key_file_has_group, iFpp)
GO(g_key_file_has_key, iFpppp)
-GO(g_key_file_load_from_data, iFppLip)
-GO(g_key_file_load_from_data_dirs, iFpppip)
-GO(g_key_file_load_from_dirs, iFppppip)
-GO(g_key_file_load_from_file, iFppip)
+GO(g_key_file_load_from_data, iFppLup)
+GO(g_key_file_load_from_data_dirs, iFpppup)
+GO(g_key_file_load_from_dirs, iFppppup)
+GO(g_key_file_load_from_file, iFppup)
GO(g_key_file_new, pFv)
GO(g_key_file_ref, pFp)
GO(g_key_file_remove_comment, iFpppp)
@@ -558,7 +554,7 @@ GO(g_key_file_set_boolean_list, vFppppL)
GO(g_key_file_set_comment, iFppppp)
GO(g_key_file_set_double, vFpppd)
GO(g_key_file_set_double_list, vFppppL)
-GO(g_key_file_set_int64, vFpppI)
+GO(g_key_file_set_int64, vFpppl)
GO(g_key_file_set_integer, vFpppi)
GO(g_key_file_set_integer_list, vFppppL)
GO(g_key_file_set_list_separator, vFpC)
@@ -566,7 +562,7 @@ GO(g_key_file_set_locale_string, vFppppp)
GO(g_key_file_set_locale_string_list, vFpppppL)
GO(g_key_file_set_string, vFpppp)
GO(g_key_file_set_string_list, vFppppL)
-GO(g_key_file_set_uint64, vFpppU)
+GO(g_key_file_set_uint64, vFpppL)
GO(g_key_file_set_value, vFpppp)
GO(g_key_file_to_data, pFppp)
GO(g_key_file_unref, vFp)
@@ -592,7 +588,7 @@ GO(g_list_index, iFpp)
GO(g_list_insert, pFppi)
GO(g_list_insert_before, pFppp)
GOM(g_list_insert_sorted, pFEppp)
-//GO(g_list_insert_sorted_with_data, pFEppBp)
+GOM(g_list_insert_sorted_with_data, pFEpppp)
GO(g_list_last, pFp)
GO(g_list_length, uFp)
GO(g_list_nth, pFpu)
@@ -663,8 +659,8 @@ GO(g_malloc_n, pFLL)
GO(g_mapped_file_free, vFp)
GO(g_mapped_file_get_bytes, pFp)
GO(g_mapped_file_get_contents, pFp)
-GO(g_mapped_file_get_length, uFp)
-GO(g_mapped_file_new, pFppp)
+GO(g_mapped_file_get_length, LFp)
+GO(g_mapped_file_new, pFpip)
GO(g_mapped_file_new_from_fd, pFiip)
GO(g_mapped_file_ref, pFp)
GO(g_mapped_file_unref, vFp)
@@ -673,15 +669,15 @@ GO(g_mapped_file_unref, vFp)
GO(g_markup_escape_text, pFpl)
GO(g_markup_parse_context_end_parse, iFpp)
GO(g_markup_parse_context_free, vFp)
-//GO(g_markup_parse_context_get_element,
-//GO(g_markup_parse_context_get_element_stack,
-//GO(g_markup_parse_context_get_position,
-//GO(g_markup_parse_context_get_user_data,
+GO(g_markup_parse_context_get_element, pFp)
+GO(g_markup_parse_context_get_element_stack, pFp)
+GO(g_markup_parse_context_get_position, vFppp)
+GO(g_markup_parse_context_get_user_data, pFp)
GOM(g_markup_parse_context_new, pFEpipp)
GO(g_markup_parse_context_parse, iFpplp)
//GO(g_markup_parse_context_pop,
//GO(g_markup_parse_context_push,
-//GO(g_markup_parse_context_ref,
+GO(g_markup_parse_context_ref, pFp)
//GO(g_markup_parse_context_unref,
GOM(g_markup_printf_escaped, pFEpV)
GOM(g_markup_vprintf_escaped, pFEpA)
@@ -701,13 +697,13 @@ GO(g_match_info_next, iFpp)
GO(g_match_info_ref, pFp)
GO(g_match_info_unref, vFp)
//GO(g_mem_chunk_alloc,
-//GO(g_mem_chunk_alloc0,
+GO(g_mem_chunk_alloc0, pFp)
//GO(g_mem_chunk_clean,
//GO(g_mem_chunk_destroy,
-//GO(g_mem_chunk_free,
+GO(g_mem_chunk_free, vFpp)
//GO(g_mem_chunk_info,
-//GO(g_mem_chunk_new,
-//GO(g_mem_chunk_print,
+GO(g_mem_chunk_new, pFpiLi)
+GO(g_mem_chunk_print, vFp)
//GO(g_mem_chunk_reset,
GO(g_memdup, pFpu)
GO(g_mem_is_system_malloc, iFv)
@@ -726,39 +722,39 @@ GO(g_mutex_lock, vFp)
GO(g_mutex_new, pFv)
GO(g_mutex_trylock, iFp)
GO(g_mutex_unlock, vFp)
-//GO(g_node_child_index,
-//GO(g_node_child_position,
+GO(g_node_child_index, iFpp)
+GO(g_node_child_position, iFpp)
//GO(g_node_children_foreach,
//GO(g_node_copy,
GOM(g_node_copy_deep, pFEppp)
//GO(g_node_depth,
GO(g_node_destroy, vFp)
-//GO(g_node_find,
-//GO(g_node_find_child,
+GO(g_node_find, pFpuup)
+GO(g_node_find_child, pFpup)
//GO(g_node_first_sibling,
GO(g_node_get_root, pFp)
-//GO(g_node_insert,
-//GO(g_node_insert_after,
+GO(g_node_insert, pFpip)
+GO(g_node_insert_after, pFppp)
GO(g_node_insert_before, pFppp)
-//GO(g_node_is_ancestor,
+GO(g_node_is_ancestor, iFpp)
//GO(g_node_last_child,
-//GO(g_node_last_sibling,
+GO(g_node_last_sibling, pFp)
//GO(g_node_max_height,
-//GO(g_node_n_children,
+GO(g_node_n_children, uFp)
GO(g_node_new, pFp)
-//GO(g_node_n_nodes,
-//GO(g_node_nth_child,
+GO(g_node_n_nodes, uFpu)
+GO(g_node_nth_child, pFpu)
//GO(g_node_pop_allocator,
-//GO(g_node_prepend,
-//GO(g_node_push_allocator,
+GO(g_node_prepend, pFpp)
+GO(g_node_push_allocator, vFp)
//GO(g_node_reverse_children,
GOM(g_node_traverse, vFEpiiipp)
//GO(g_node_unlink,
GO(g_nullify_pointer, vFp)
//GO(g_once_impl,
GO(g_once_init_enter, iFp)
-//GO(g_once_init_enter_impl,
-GO(g_once_init_leave, vFpL)
+GO(g_once_init_enter_impl, iFp)
+GO(g_once_init_leave, vFpi)
GO(g_on_error_query, vFp)
GO(g_on_error_stack_trace, vFp)
GO(g_open, iFpii)
@@ -783,7 +779,7 @@ GO(g_option_context_set_strict_posix, vFpi) // 2.44+
GO(g_option_context_set_summary, vFpp)
//GOM(g_option_context_set_translate_func, vFEpBpB)
GO(g_option_context_set_translation_domain, vFpp)
-//GO(g_option_error_quark,
+GO(g_option_error_quark, pFv)
GO(g_option_group_add_entries, vFpp)
GO(g_option_group_free, vFp)
GOM(g_option_group_new, pFEppppp)
@@ -793,7 +789,7 @@ GO(g_option_group_ref, pFp) // 2.44+
//GOM(g_option_group_set_translate_func, vFEpBpB)
GO(g_option_group_set_translation_domain, vFpp)
GO(g_option_group_unref, vFp) // 2.44+
-GO(g_parse_debug_string, uFppi)
+GO(g_parse_debug_string, uFppu)
GO(g_path_get_basename, pFp)
GO(g_path_get_dirname, pFp)
GO(g_path_is_absolute, iFp)
@@ -805,8 +801,8 @@ GO(g_pattern_spec_equal, iFpp)
GO(g_pattern_spec_free, vFp)
GO(g_pattern_spec_new, pFp)
//GO(g_pointer_bit_lock,
-//GO(g_pointer_bit_trylock,
-//GO(g_pointer_bit_unlock,
+GO(g_pointer_bit_trylock, iFpi)
+GO(g_pointer_bit_unlock, vFpi)
GO(g_poll, iFpui)
//GO(g_prefix_error, vFpppppppppp) //vaarg, should align?
GOM(g_print, vFEpV)
@@ -882,22 +878,22 @@ GO(g_queue_push_nth_link, vFpip)
GO(g_queue_push_tail, vFpp)
GO(g_queue_push_tail_link, vFpp)
GO(g_queue_remove, iFpp)
-GO(g_queue_remove_all, iFpp)
+GO(g_queue_remove_all, uFpp)
GO(g_queue_reverse, pFp)
//GOM(g_queue_sort, vFEpBp)
GO(g_queue_unlink, vFpp)
GO(g_rand_copy, pFp)
-GO(g_rand_double, dFv)
-GO(g_rand_double_range, dFdd)
+GO(g_rand_double, dFp)
+GO(g_rand_double_range, dFpdd)
GO(g_rand_free, vFp)
GO(g_rand_int, uFp)
-GO(g_rand_int_range, uFpuu)
+GO(g_rand_int_range, iFpii)
GO(g_rand_new, pFv)
GO(g_rand_new_with_seed, pFu)
GO(g_rand_new_with_seed_array, pFpu)
-GO(g_random_double, dFp)
-GO(g_random_double_range, dFpdd)
-GO(g_random_int, iFii)
+GO(g_random_double, dFv)
+GO(g_random_double_range, dFdd)
+GO(g_random_int, uFv)
GO(g_random_int_range, iFii)
GO(g_random_set_seed, vFu)
GO(g_rand_set_seed, vFpu)
@@ -914,36 +910,36 @@ GO(g_regex_check_replacement, iFppp)
GO(g_regex_escape_nul, pFpi)
GO(g_regex_escape_string, pFpi)
GO(g_regex_get_capture_count, iFp)
-GO(g_regex_get_compile_flags, iFp)
+GO(g_regex_get_compile_flags, uFp)
GO(g_regex_get_has_cr_or_lf, iFp)
-GO(g_regex_get_match_flags, iFp)
+GO(g_regex_get_match_flags, uFp)
GO(g_regex_get_max_backref, iFp)
GO(g_regex_get_max_lookbehind, iFp)
GO(g_regex_get_pattern, pFp)
GO(g_regex_get_string_number, iFpp)
GO(g_regex_match, iFppip)
-GO(g_regex_match_all, iFppip)
-GO(g_regex_match_all_full, iFppLiipp)
+GO(g_regex_match_all, iFppup)
+GO(g_regex_match_all_full, iFppliupp)
GO(g_regex_match_full, iFppLiipp)
-GO(g_regex_match_simple, iFppii)
-GO(g_regex_new, pFpiip)
+GO(g_regex_match_simple, iFppuu)
+GO(g_regex_new, pFpuup)
GO(g_regex_ref, pFp)
GO(g_regex_replace, pFppLipip)
//GOM(g_regex_replace_eval, pFEppLiiBpp)
-GO(g_regex_replace_literal, pFppLipip)
-GO(g_regex_split, pFppi)
-GO(g_regex_split_full, pFppLiiip)
-GO(g_regex_split_simple, pFppii)
+GO(g_regex_replace_literal, pFpplipup)
+GO(g_regex_split, pFppu)
+GO(g_regex_split_full, pFppliuip)
+GO(g_regex_split_simple, pFppuu)
GO(g_regex_unref, vFp)
-//GO(g_relation_count,
+GO(g_relation_count, iFppi)
//GO(g_relation_delete,
//GO(g_relation_destroy,
//GO(g_relation_exists,
//GO(g_relation_index,
//GO(g_relation_insert,
-//GO(g_relation_new,
-//GO(g_relation_print,
-//GO(g_relation_select,
+GO(g_relation_new, pFi)
+GO(g_relation_print, vFp)
+GO(g_relation_select, pFppi)
//GO(g_reload_user_special_dirs_cache,
GO(g_remove, iFp)
GO(g_rename, iFpp)
@@ -952,8 +948,8 @@ GO(g_rmdir, iFp)
//GO(g_rw_lock_clear,
//GO(g_rw_lock_init,
//GO(g_rw_lock_reader_lock,
-//GO(g_rw_lock_reader_trylock,
-//GO(g_rw_lock_reader_unlock,
+GO(g_rw_lock_reader_trylock, iFp)
+GO(g_rw_lock_reader_unlock, vFp)
//GO(g_rw_lock_writer_lock,
//GO(g_rw_lock_writer_trylock,
//GO(g_rw_lock_writer_unlock,
@@ -982,34 +978,34 @@ GO(g_rmdir, iFp)
//GO(g_sequence_foreach,
//GO(g_sequence_foreach_range,
//GO(g_sequence_free,
-//GO(g_sequence_get,
+GO(g_sequence_get, pFp)
//GO(g_sequence_get_begin_iter,
-//GO(g_sequence_get_end_iter,
-//GO(g_sequence_get_iter_at_pos,
-//GO(g_sequence_get_length,
-//GO(g_sequence_insert_before,
+GO(g_sequence_get_end_iter, pFp)
+GO(g_sequence_get_iter_at_pos, pFpi)
+GO(g_sequence_get_length, iFp)
+GO(g_sequence_insert_before, pFpp)
//GO(g_sequence_insert_sorted,
//GO(g_sequence_insert_sorted_iter,
-//GO(g_sequence_iter_compare,
-//GO(g_sequence_iter_get_position,
-//GO(g_sequence_iter_get_sequence,
+GO(g_sequence_iter_compare, iFpp)
+GO(g_sequence_iter_get_position, iFp)
+GO(g_sequence_iter_get_sequence, pFp)
//GO(g_sequence_iter_is_begin,
-//GO(g_sequence_iter_is_end,
-//GO(g_sequence_iter_move,
+GO(g_sequence_iter_is_end, iFp)
+GO(g_sequence_iter_move, pFpi)
//GO(g_sequence_iter_next,
-//GO(g_sequence_iter_prev,
+GO(g_sequence_iter_prev, pFp)
//GO(g_sequence_lookup,
//GO(g_sequence_lookup_iter,
//GO(g_sequence_move,
-//GO(g_sequence_move_range,
+GO(g_sequence_move_range, vFppp)
//GO(g_sequence_new,
-//GO(g_sequence_prepend,
-//GO(g_sequence_range_get_midpoint,
-//GO(g_sequence_remove,
-//GO(g_sequence_remove_range,
+GO(g_sequence_prepend, pFpp)
+GO(g_sequence_range_get_midpoint, pFpp)
+GO(g_sequence_remove, vFp)
+GO(g_sequence_remove_range, vFpp)
//GO(g_sequence_search,
//GO(g_sequence_search_iter,
-//GO(g_sequence_set,
+GO(g_sequence_set, vFpp)
//GO(g_sequence_sort,
//GO(g_sequence_sort_changed,
//GO(g_sequence_sort_changed_iter,
@@ -1018,7 +1014,7 @@ GO(g_rmdir, iFp)
GO(g_set_application_name, vFp)
GO(g_setenv, iFppi)
GOM(g_set_error, vFEppipV)
-GO(g_set_error_literal, vFppip)
+GO(g_set_error_literal, vFpuip)
GO(g_set_prgname, vFp)
GOM(g_set_printerr_handler, pFEp)
GOM(g_set_print_handler, pFEp)
@@ -1031,9 +1027,9 @@ GO(g_slice_alloc0, pFL)
GO(g_slice_copy, pFLp)
GO(g_slice_free1, vFLp)
GO(g_slice_free_chain_with_offset, vFLpL)
-GO(g_slice_get_config, IFi)
-GO(g_slice_get_config_state, pFiIp)
-GO(g_slice_set_config, vFiI)
+GO(g_slice_get_config, lFu)
+GO(g_slice_get_config_state, pFulp)
+GO(g_slice_set_config, vFul)
GO(g_slist_alloc, pFv)
GO(g_slist_append, pFpp)
GO(g_slist_concat, pFpp)
@@ -1103,7 +1099,7 @@ GO(g_spaced_primes_closest, uFu)
GOM(g_spawn_async, iFEpppipppp)
GOM(g_spawn_async_with_pipes, iFEpppippppppp)
GO(g_spawn_check_exit_status, iFip)
-GO(g_spawn_close_pid, vFp)
+GO(g_spawn_close_pid, vFi)
GO(g_spawn_command_line_async, iFpp)
GO(g_spawn_command_line_sync, iFppppp)
GO(g_spawn_error_quark, pFv)
@@ -1182,8 +1178,8 @@ GO(g_string_insert_len, pFplpl)
GO(g_string_insert_unichar, pFplu)
GO(g_string_new, pFp)
GO(g_string_new_len, pFpl)
-GO(g_string_overwrite, pFplp)
-GO(g_string_overwrite_len, pFplpl)
+GO(g_string_overwrite, pFpLp)
+GO(g_string_overwrite_len, pFpLpl)
GO(g_string_prepend, pFpp)
GO(g_string_prepend_c, pFpC)
GO(g_string_prepend_len, pFppl)
@@ -1198,15 +1194,15 @@ GO(g_strip_context, pFpp)
GO(g_str_is_ascii, iFp)
GOM(g_strjoin, pFEpV)
GOM(g_strjoinv, pFEpp)
-GO(g_strlcat, uFppu)
+GO(g_strlcat, LFppL)
GO(g_strlcpy, uFppu)
GO(g_str_match_string, iFppi)
GO(g_strncasecmp, iFppu)
-GO(g_strndup, pFpu)
-GO(g_strnfill, pFuC)
+GO(g_strndup, pFpL)
+GO(g_strnfill, pFLC)
GO(g_strreverse, pFp)
GO(g_strrstr, pFpp)
-GO(g_strrstr_len, pFpip)
+GO(g_strrstr_len, pFplp)
GO(g_strsignal, pFi)
GO(g_strsplit, pFppi)
GO(g_strsplit_set, pFppi)
@@ -1220,71 +1216,71 @@ GO(g_strv_length, uFp)
//GO(g_test_add_data_func_full,
//GO(g_test_add_func,
//GO(g_test_add_vtable,
-//GO(g_test_assert_expected_messages_internal,
+GO(g_test_assert_expected_messages_internal, vFppip)
//GO(g_test_bug,
//GO(g_test_bug_base,
//GO(g_test_build_filename,
//GO(g_test_create_case,
-//GO(g_test_create_suite,
-//GO(g_test_expect_message,
+GO(g_test_create_suite, pFp)
+GO(g_test_expect_message, vFpip)
//GO(g_test_fail,
//GO(g_test_failed,
-//GO(g_test_get_dir,
+GO(g_test_get_dir, pFu)
//GO(g_test_get_filename,
-//GO(g_test_get_root,
+GO(g_test_get_root, pFv)
//GO(g_test_incomplete,
//GO(g_test_init,
-//GO(g_test_log_buffer_free,
-//GO(g_test_log_buffer_new,
-//GO(g_test_log_buffer_pop,
-//GO(g_test_log_buffer_push,
-//GO(g_test_log_msg_free,
+GO(g_test_log_buffer_free, vFp)
+GO(g_test_log_buffer_new, pFv)
+GO(g_test_log_buffer_pop, pFp)
+GO(g_test_log_buffer_push, vFpup)
+GO(g_test_log_msg_free, vFp)
//GO(g_test_log_set_fatal_handler,
-//GO(g_test_log_type_name,
+GO(g_test_log_type_name, pFu)
//GO(g_test_maximized_result,
//GO(g_test_message,
//GO(g_test_minimized_result,
//GO(g_test_queue_destroy,
//GO(g_test_queue_free,
-//GO(g_test_rand_double,
-//GO(g_test_rand_double_range,
-//GO(g_test_rand_int,
-//GO(g_test_rand_int_range,
+GO(g_test_rand_double, dFv)
+GO(g_test_rand_double_range, dFdd)
+GO(g_test_rand_int, iFv)
+GO(g_test_rand_int_range, iFii)
//GO(g_test_run,
-//GO(g_test_run_suite,
+GO(g_test_run_suite, iFp)
//GO(g_test_set_nonfatal_assertions,
-//GO(g_test_skip,
+GO(g_test_skip, vFp)
//GO(g_test_subprocess,
-//GO(g_test_suite_add,
-//GO(g_test_suite_add_suite,
+GO(g_test_suite_add, vFpp)
+GO(g_test_suite_add_suite, vFpp)
//GO(g_test_timer_elapsed,
//GO(g_test_timer_last,
//GO(g_test_timer_start,
-//GO(g_test_trap_assertions,
-//GO(g_test_trap_fork,
+GO(g_test_trap_assertions, vFppipLp)
+GO(g_test_trap_fork, iFLu)
//GO(g_test_trap_has_passed,
//GO(g_test_trap_reached_timeout,
-//GO(g_test_trap_subprocess,
+GO(g_test_trap_subprocess, vFpLu)
GOM(g_thread_create, pFEppip)
GOM(g_thread_create_full, pFEppLiiip)
-//GO(g_thread_error_quark,
+GO(g_thread_error_quark, pFv)
GO(g_thread_exit, vFp)
GOM(g_thread_foreach, vFEpp)
-//GO(g_thread_get_initialized,
+GO(g_thread_get_initialized, iFv)
//GO(g_thread_init_glib,
GO(g_thread_join, pFp)
//GO(g_thread_new,
//GO(g_thread_pool_free,
-//GO(g_thread_pool_get_max_idle_time,
+GO(g_thread_pool_get_max_idle_time, uFv)
//GO(g_thread_pool_get_max_threads,
-//GO(g_thread_pool_get_max_unused_threads,
+GO(g_thread_pool_get_max_unused_threads, iFv)
//GO(g_thread_pool_get_num_threads,
//GO(g_thread_pool_get_num_unused_threads,
//GO(g_thread_pool_new,
//GO(g_thread_pool_push,
-//GO(g_thread_pool_set_max_idle_time,
+GO(g_thread_pool_set_max_idle_time, vFu)
//GO(g_thread_pool_set_max_threads,
-//GO(g_thread_pool_set_max_unused_threads,
+GO(g_thread_pool_set_max_unused_threads, vFi)
//GO(g_thread_pool_set_sort_function,
//GO(g_thread_pool_stop_unused_threads,
//GO(g_thread_pool_unprocessed,
@@ -1302,23 +1298,23 @@ GO(g_timeout_source_new, pFu)
GO(g_timeout_source_new_seconds, pFu)
//GO(g_timer_continue,
//GO(g_timer_destroy,
-//GO(g_timer_elapsed,
-//GO(g_timer_new,
+GO(g_timer_elapsed, dFpp)
+GO(g_timer_new, pFv)
//GO(g_timer_reset,
//GO(g_timer_start,
//GO(g_timer_stop,
GO(g_time_val_add, vFpl)
GO(g_time_val_from_iso8601, iFpp)
GO(g_time_val_to_iso8601, pFp)
-//GO(g_time_zone_adjust_time,
-//GO(g_time_zone_find_interval,
-//GO(g_time_zone_get_abbreviation,
-//GO(g_time_zone_get_offset,
-//GO(g_time_zone_is_dst,
+GO(g_time_zone_adjust_time, iFpup)
+GO(g_time_zone_find_interval, iFpul)
+GO(g_time_zone_get_abbreviation, pFpi)
+GO(g_time_zone_get_offset, iFpi)
+GO(g_time_zone_is_dst, iFpi)
//GO(g_time_zone_new,
-//GO(g_time_zone_new_local,
+GO(g_time_zone_new_local, pFv)
//GO(g_time_zone_new_utc,
-//GO(g_time_zone_ref,
+GO(g_time_zone_ref, pFp)
//GO(g_time_zone_unref,
GO(g_trash_stack_height, uFp)
GO(g_trash_stack_peek, pFp)
@@ -1328,17 +1324,17 @@ GO(g_trash_stack_push, vFpp)
//GO(g_tree_foreach,
//GO(g_tree_height,
//GO(g_tree_insert,
-//GO(g_tree_lookup,
-//GO(g_tree_lookup_extended,
+GO(g_tree_lookup, pFpp)
+GO(g_tree_lookup_extended, iFpppp)
//GO(g_tree_new,
//GO(g_tree_new_full,
//GO(g_tree_new_with_data,
-//GO(g_tree_nnodes,
-//GO(g_tree_ref,
+GO(g_tree_nnodes, iFp)
+GO(g_tree_ref, pFp)
//GO(g_tree_remove,
-//GO(g_tree_replace,
+GO(g_tree_replace, vFppp)
//GO(g_tree_search,
-//GO(g_tree_steal,
+GO(g_tree_steal, iFpp)
//GO(g_tree_traverse,
//GO(g_tree_unref,
GO(g_try_malloc, pFL)
@@ -1347,16 +1343,16 @@ GO(g_try_malloc0_n, pFLL)
GO(g_try_malloc_n, pFLL)
GO(g_try_realloc, pFpL)
GO(g_try_realloc_n, pFpLL)
-//GO(g_tuples_destroy,
-//GO(g_tuples_index,
+GO(g_tuples_destroy, vFp)
+GO(g_tuples_index, pFpii)
GO(g_ucs4_to_utf16, pFplppp)
GO(g_ucs4_to_utf8, pFplppp)
-GO(g_unichar_break_type, iFu)
+GO(g_unichar_break_type, uFu)
GO(g_unichar_combining_class, iFu)
GO(g_unichar_compose, iFuup)
GO(g_unichar_decompose, iFupp)
GO(g_unichar_digit_value, iFu)
-GO(g_unichar_fully_decompose, iFuipu)
+GO(g_unichar_fully_decompose, LFuipL)
GO(g_unichar_get_mirror_char, iFup)
GO(g_unichar_get_script, iFu)
GO(g_unichar_isalnum, iFu)
@@ -1380,11 +1376,11 @@ GO(g_unichar_tolower, uFu)
GO(g_unichar_totitle, uFu)
GO(g_unichar_toupper, uFu)
GO(g_unichar_to_utf8, iFup)
-GO(g_unichar_type, iFu)
+GO(g_unichar_type, uFu)
GO(g_unichar_validate, iFu)
GO(g_unichar_xdigit_value, iFu)
GO(g_unicode_canonical_decomposition, pFup)
-GO(g_unicode_canonical_ordering, vFpu)
+GO(g_unicode_canonical_ordering, vFpL)
GO(g_unicode_script_from_iso15924, iFu)
GO(g_unicode_script_to_iso15924, uFi)
//GO(g_unix_error_quark,
@@ -1413,16 +1409,16 @@ GO(g_utf8_collate_key_for_filename, pFpi)
GO(g_utf8_find_next_char, pFpp)
GO(g_utf8_find_prev_char, pFpp)
GO(g_utf8_get_char, uFp)
-GO(g_utf8_get_char_validated, uFpi)
-GO(g_utf8_normalize, pFpii)
+GO(g_utf8_get_char_validated, uFpl)
+GO(g_utf8_normalize, pFplu)
GO(g_utf8_offset_to_pointer, pFpl)
GO(g_utf8_pointer_to_offset, lFpp)
GO(g_utf8_prev_char, pFp)
GO(g_utf8_strchr, pFpiu)
GO(g_utf8_strdown, pFpi)
-GO(g_utf8_strlen, lFpi)
-GO(g_utf8_strncpy, pFppu)
-GO(g_utf8_strrchr, pFpiu)
+GO(g_utf8_strlen, lFpl)
+GO(g_utf8_strncpy, pFppL)
+GO(g_utf8_strrchr, pFplu)
GO(g_utf8_strreverse, pFpi)
GO(g_utf8_strup, pFpi)
GO(g_utf8_substring, pFpll)
@@ -1444,7 +1440,7 @@ GO(g_variant_builder_ref, pFp)
GO(g_variant_builder_unref, vFp)
GO(g_variant_byteswap, pFp)
GO(g_variant_check_format_string, iFppi)
-GO(g_variant_classify, iFp)
+GO(g_variant_classify, uFp)
GO(g_variant_compare, iFpp)
GO(g_variant_dict_clear, vFp)
GO(g_variant_dict_contains, iFpp)
@@ -1471,27 +1467,27 @@ GO(g_variant_get_boolean, iFp)
GO(g_variant_get_byte, CFp)
GO(g_variant_get_bytestring, pFp)
GO(g_variant_get_bytestring_array, pFpp)
-//GO(g_variant_get_child, vFpuppppppppppp) //vaarg here
-GO(g_variant_get_child_value, pFpu)
+GO(g_variant_get_child, vFpuppppppppppp) //vaarg here, only pointers so should be ok
+GO(g_variant_get_child_value, pFpL)
GO(g_variant_get_data, pFp)
GO(g_variant_get_data_as_bytes, pFp)
GO(g_variant_get_double, dFp)
-GO(g_variant_get_fixed_array, pFppu)
+GO(g_variant_get_fixed_array, pFppL)
GO(g_variant_get_handle, iFp)
GO(g_variant_get_int16, wFp)
GO(g_variant_get_int32, iFp)
-GO(g_variant_get_int64, IFp)
+GO(g_variant_get_int64, lFp)
GO(g_variant_get_maybe, pFp)
GO(g_variant_get_normal_form, pFp)
GO(g_variant_get_objv, pFpp)
-GO(g_variant_get_size, uFp)
+GO(g_variant_get_size, LFp)
GO(g_variant_get_string, pFpp)
GO(g_variant_get_strv, pFpp)
GO(g_variant_get_type, pFp)
GO(g_variant_get_type_string, pFp)
GO(g_variant_get_uint16, WFp)
GO(g_variant_get_uint32, uFp)
-GO(g_variant_get_uint64, UFp)
+GO(g_variant_get_uint64, LFp)
GO(g_variant_get_va, vFpppp) // no need to GOM, it's a "scanf" type of function, so using only pointer in va_list
GO(g_variant_get_variant, pFp)
GO(g_variant_hash, uFp)
@@ -1503,30 +1499,30 @@ GO(g_variant_is_of_type, iFpp)
GO(g_variant_is_signature, iFp)
GO(g_variant_iter_copy, pFp)
GO(g_variant_iter_free, vFp)
-GO(g_variant_iter_init, uFpp)
+GO(g_variant_iter_init, LFpp)
GO(g_variant_iter_loop, iFpppppppppppp) // vaarg
-GO(g_variant_iter_n_children, uFp)
+GO(g_variant_iter_n_children, LFp)
GO(g_variant_iter_new, pFp)
-//GO(g_variant_iter_next, iFpppppppppppp) // vaarg here
+GO(g_variant_iter_next, iFpppppppppppp) // vaarg here, only pointers so should be ok
GO(g_variant_iter_next_value, pFp)
GO(g_variant_lookup, iFpppppppppppp) // vaarg
GO(g_variant_lookup_value, pFppp)
GO(g_variant_n_children, uFp)
GOM(g_variant_new, pFEpV)
-GO(g_variant_new_array, pFppu)
+GO(g_variant_new_array, pFppL)
GO(g_variant_new_boolean, pFi)
GO(g_variant_new_byte, pFC)
GO(g_variant_new_bytestring, pFp)
-GO(g_variant_new_bytestring_array, pFpi)
+GO(g_variant_new_bytestring_array, pFpl)
GO(g_variant_new_dict_entry, pFpp)
GO(g_variant_new_double, pFd)
-GO(g_variant_new_fixed_array, pFppuu)
+GO(g_variant_new_fixed_array, pFppLL)
GO(g_variant_new_from_bytes, pFppi)
GOM(g_variant_new_from_data, pFEppuipp)
GO(g_variant_new_handle, pFi)
GO(g_variant_new_int16, pFw)
GO(g_variant_new_int32, pFi)
-GO(g_variant_new_int64, pFI)
+GO(g_variant_new_int64, pFl)
GO(g_variant_new_maybe, pFpp)
GO(g_variant_new_object_path, pFp)
GO(g_variant_new_objv, pFpi)
@@ -1537,10 +1533,10 @@ GO(g_variant_new_signature, pFp)
GO(g_variant_new_string, pFp)
GO(g_variant_new_strv, pFpi)
GO(g_variant_new_take_string, pFp)
-GO(g_variant_new_tuple, pFpu)
+GO(g_variant_new_tuple, pFpL)
GO(g_variant_new_uint16, pFW)
GO(g_variant_new_uint32, pFu)
-GO(g_variant_new_uint64, pFU)
+GO(g_variant_new_uint64, pFL)
GOM(g_variant_new_va, pFEppp)
GO(g_variant_new_variant, pFp)
GO(g_variant_parse, pFppppp)
@@ -1560,7 +1556,7 @@ GO(g_variant_ref_sink, pFp)
//GO(g_variant_serialiser_is_string,
//GO(g_variant_serialiser_needed_size,
//GO(g_variant_serialiser_serialise,
-GO(g_variant_store, vFp)
+GO(g_variant_store, vFpp)
GO(g_variant_take_ref, pFp)
GO(g_variant_type_checked_, pFp)
GO(g_variant_type_copy, pFp)
@@ -1597,7 +1593,7 @@ GO(g_variant_type_new_dict_entry, pFpp)
GO(g_variant_type_new_maybe, pFp)
GO(g_variant_type_new_tuple, pFpi)
GO(g_variant_type_next, pFp)
-GO(g_variant_type_n_items, iFp)
+GO(g_variant_type_n_items, LFp)
GO(g_variant_type_peek_string, pFp)
GO(g_variant_type_string_is_valid, iFp)
GO(g_variant_type_string_scan, iFppp)
diff --git a/src/wrapped/wrappedgmodule2.c b/src/wrapped/wrappedgmodule2.c
index b5681d4..b5681d4 100755..100644
--- a/src/wrapped/wrappedgmodule2.c
+++ b/src/wrapped/wrappedgmodule2.c
diff --git a/src/wrapped/wrappedgmodule2_private.h b/src/wrapped/wrappedgmodule2_private.h
index 45beba4..9aed451 100755..100644
--- a/src/wrapped/wrappedgmodule2_private.h
+++ b/src/wrapped/wrappedgmodule2_private.h
@@ -8,7 +8,7 @@ GO(g_module_close, iFp)
GO(g_module_error, pFv)
GO(g_module_make_resident, vFp)
GO(g_module_name, pFp)
-GO(g_module_open, pFpi)
+GO(g_module_open, pFpu)
GO(g_module_supported, iFv)
GO(g_module_symbol, iFppp)
//GO(_init,
diff --git a/src/wrapped/wrappedgmp.c b/src/wrapped/wrappedgmp.c
index e29da8e..731d2d8 100644
--- a/src/wrapped/wrappedgmp.c
+++ b/src/wrapped/wrappedgmp.c
@@ -11,8 +11,146 @@
#include "bridge.h"
#include "librarian/library_private.h"
#include "x64emu.h"
+#include "emu/x64emu_private.h"
+#include "callback.h"
+#include "librarian.h"
+#include "box64context.h"
+#include "emu/x64emu_private.h"
+#include "callback.h"
const char* gmpName = "libgmp.so.10";
#define LIBNAME gmp
+#include "generated/wrappedgmptypes.h"
+
+#include "wrappercallback.h"
+
+// utility functions
+#define SUPER() \
+GO(0) \
+GO(1) \
+GO(2) \
+GO(3) \
+GO(4)
+
+// alloc_func
+#define GO(A) \
+static uintptr_t my_alloc_func_fct_##A = 0; \
+static void* my_alloc_func_##A(size_t a) \
+{ \
+ return (void*)RunFunctionFmt(my_alloc_func_fct_##A, "L", a); \
+}
+SUPER()
+#undef GO
+static void* find_alloc_func_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my_alloc_func_fct_##A == (uintptr_t)fct) return my_alloc_func_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_alloc_func_fct_##A == 0) {my_alloc_func_fct_##A = (uintptr_t)fct; return my_alloc_func_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libgmp.so.10 alloc_func callback\n");
+ return NULL;
+}
+static void* reverse_alloc_func_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(CheckBridged(my_lib->w.bridge, fct))
+ return (void*)CheckBridged(my_lib->w.bridge, fct);
+ #define GO(A) if(my_alloc_func_##A == fct) return (void*)my_alloc_func_fct_##A;
+ SUPER()
+ #undef GO
+ return (void*)AddBridge(my_lib->w.bridge, pFL, fct, 0, NULL);
+}
+// realloc_func
+#define GO(A) \
+static uintptr_t my_realloc_func_fct_##A = 0; \
+static void* my_realloc_func_##A(void* a, size_t b) \
+{ \
+ return (void*)RunFunctionFmt(my_realloc_func_fct_##A, "pL", a, b); \
+}
+SUPER()
+#undef GO
+static void* find_realloc_func_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my_realloc_func_fct_##A == (uintptr_t)fct) return my_realloc_func_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_realloc_func_fct_##A == 0) {my_realloc_func_fct_##A = (uintptr_t)fct; return my_realloc_func_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libgmp.so.10 realloc_func callback\n");
+ return NULL;
+}
+static void* reverse_realloc_func_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(CheckBridged(my_lib->w.bridge, fct))
+ return (void*)CheckBridged(my_lib->w.bridge, fct);
+ #define GO(A) if(my_realloc_func_##A == fct) return (void*)my_realloc_func_fct_##A;
+ SUPER()
+ #undef GO
+ return (void*)AddBridge(my_lib->w.bridge, pFpL, fct, 0, NULL);
+}
+// free_func
+#define GO(A) \
+static uintptr_t my_free_func_fct_##A = 0; \
+static void my_free_func_##A(void* a) \
+{ \
+ RunFunctionFmt(my_free_func_fct_##A, "p", a); \
+}
+SUPER()
+#undef GO
+static void* find_free_func_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my_free_func_fct_##A == (uintptr_t)fct) return my_free_func_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_free_func_fct_##A == 0) {my_free_func_fct_##A = (uintptr_t)fct; return my_free_func_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libgmp.so.10 free_func callback\n");
+ return NULL;
+}
+static void* reverse_free_func_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(CheckBridged(my_lib->w.bridge, fct))
+ return (void*)CheckBridged(my_lib->w.bridge, fct);
+ #define GO(A) if(my_free_func_##A == fct) return (void*)my_free_func_fct_##A;
+ SUPER()
+ #undef GO
+ return (void*)AddBridge(my_lib->w.bridge, vFp, fct, 0, NULL);
+}
+
+#undef SUPER
+
+EXPORT void my___gmp_get_memory_functions(x64emu_t* emu, void** f_alloc, void** f_realloc, void** f_free)
+{
+ my->__gmp_get_memory_functions(f_alloc, f_realloc, f_free);
+ *f_alloc = reverse_alloc_func_Fct(*f_alloc);
+ *f_realloc = reverse_realloc_func_Fct(*f_realloc);
+ *f_free = reverse_free_func_Fct(*f_free);
+}
+EXPORT void my___gmp_set_memory_functions(x64emu_t* emu, void* f_alloc, void* f_realloc, void* f_free)
+{
+ my->__gmp_set_memory_functions(find_alloc_func_Fct(f_alloc), find_realloc_func_Fct(f_realloc), find_free_func_Fct(f_free));
+}
+
+#define CUSTOM_INIT \
+ getMy(lib);
+
+#define CUSTOM_FINI \
+ freeMy();
+
#include "wrappedlib_init.h"
diff --git a/src/wrapped/wrappedgmp_private.h b/src/wrapped/wrappedgmp_private.h
index 1a28497..3aa119b 100644
--- a/src/wrapped/wrappedgmp_private.h
+++ b/src/wrapped/wrappedgmp_private.h
@@ -2,6 +2,8 @@
#error meh!
#endif
+// mp_bitcnt_t unsigned long int
+
//DATA(__gmp_allocate_func,
//GO(__gmp_asprintf,
//GO(__gmp_asprintf_final,
@@ -95,7 +97,7 @@
//GO(__gmpf_ui_div,
//GO(__gmpf_ui_sub,
//GO(__gmpf_urandomb,
-//GO(__gmp_get_memory_functions,
+GOM(__gmp_get_memory_functions, vFEppp)
//GO(__gmp_init_primesieve,
//GO(__gmp_invalid_operation,
//DATAB(__gmp_junk,
@@ -107,8 +109,8 @@
//GO(__gmpn_add_err3_n,
//GO(__gmpn_addlsh1_n,
//GO(__gmpn_addlsh2_n,
-//GO(__gmpn_addmul_1,
-//GO(__gmpn_add_n,
+GO(__gmpn_addmul_1, LFppLL)
+GO(__gmpn_add_n, LFpppL)
//GO(__gmpn_add_nc,
//GO(__gmpn_add_n_sub_n,
//GO(__gmpn_and_n,
@@ -129,13 +131,13 @@
//GO(__gmpn_bsqrt,
//GO(__gmpn_bsqrtinv,
//GO(__gmpn_cmp,
-//GO(__gmpn_cnd_add_n,
-//GO(__gmpn_cnd_sub_n,
+GO(__gmpn_cnd_add_n, LFLpppL)
+GO(__gmpn_cnd_sub_n, LFLpppL)
//GO(__gmpn_cnd_swap,
//GO(__gmpn_com,
//GO(__gmpn_compute_powtab,
-//GO(__gmpn_copyd,
-//GO(__gmpn_copyi,
+GO(__gmpn_copyd, vFppL)
+GO(__gmpn_copyi, vFppL)
//GO(__gmpn_dcpi1_bdiv_q,
//GO(__gmpn_dcpi1_bdiv_qr,
//GO(__gmpn_dcpi1_bdiv_qr_n,
@@ -229,7 +231,7 @@
//GO(__gmpn_mu_div_qr,
//GO(__gmpn_mu_div_qr_itch,
//GO(__gmpn_mul,
-//GO(__gmpn_mul_1,
+GO(__gmpn_mul_1, LFppLL)
//GO(__gmpn_mul_1c,
//GO(__gmpn_mul_basecase,
//GO(__gmpn_mul_fft,
@@ -240,14 +242,14 @@
//GO(__gmpn_mulmid_n,
//GO(__gmpn_mulmod_bnm1,
//GO(__gmpn_mulmod_bnm1_next_size,
-//GO(__gmpn_mul_n,
+GO(__gmpn_mul_n, vFpppL)
//GO(__gmpn_nand_n,
//GO(__gmpn_neg,
//GO(__gmpn_ni_invertappr,
//GO(__gmpn_nior_n,
//GO(__gmpn_nussbaumer_mul,
//GO(__gmpn_perfect_power_p,
-//GO(__gmpn_perfect_square_p,
+GO(__gmpn_perfect_square_p, iFpL)
//GO(__gmpn_pi1_bdiv_q_1,
//GO(__gmpn_popcount,
//GO(__gmpn_pow_1,
@@ -268,7 +270,7 @@
//GO(__gmpn_rsblsh2_n,
//GO(__gmpn_rsh1add_n,
//GO(__gmpn_rsh1sub_n,
-//GO(__gmpn_rshift,
+GO(__gmpn_rshift, LFppLu)
//GO(__gmpn_sbpi1_bdiv_q,
//GO(__gmpn_sbpi1_bdiv_qr,
//GO(__gmpn_sbpi1_bdiv_r,
@@ -298,7 +300,7 @@
//GO(__gmpn_sec_tabselect,
//GO(__gmpn_set_str,
//GO(__gmpn_sizeinbase,
-//GO(__gmpn_sqr,
+GO(__gmpn_sqr, vFppL)
//GO(__gmpn_sqr_basecase,
//GO(__gmpn_sqr_diag_addlsh1,
//GO(__gmpn_sqrlo,
@@ -314,8 +316,8 @@
//GO(__gmpn_sub_err3_n,
//GO(__gmpn_sublsh1_n,
//GO(__gmpn_sublsh2_n,
-//GO(__gmpn_submul_1,
-//GO(__gmpn_sub_n,
+GO(__gmpn_submul_1, LFppLL)
+GO(__gmpn_sub_n, LFpppL)
//GO(__gmpn_sub_nc,
//GO(__gmpn_tdiv_qr,
//GO(__gmpn_toom22_mul,
@@ -353,7 +355,7 @@
//GO(__gmpn_trialdiv,
//GO(__gmpn_xnor_n,
//GO(__gmpn_xor_n,
-//GO(__gmpn_zero,
+GO(__gmpn_zero, vFpL)
//GO(__gmpn_zero_p,
//GO(__gmp_obstack_printf,
//DATA(__gmp_obstack_printf_funs,
@@ -412,7 +414,7 @@
//DATAB(__gmp_rands_initialized,
//DATA(__gmp_reallocate_func,
//GO(__gmp_scanf,
-//GO(__gmp_set_memory_functions,
+GOM(__gmp_set_memory_functions, vFEppp)
//GO(__gmp_snprintf,
//DATA(__gmp_snprintf_funs,
//GO(__gmp_sprintf,
@@ -435,16 +437,16 @@
//GO(__gmp_vsscanf,
//GO(__gmpz_2fac_ui,
//GO(__gmpz_abs,
-//GO(__gmpz_add,
+GO(__gmpz_add, vFppp)
//GO(__gmpz_addmul,
//GO(__gmpz_addmul_ui,
-//GO(__gmpz_add_ui,
+GO(__gmpz_add_ui, vFppL)
//GO(__gmpz_and,
//GO(__gmpz_aorsmul_1,
//GO(__gmpz_array_init,
//GO(__gmpz_bin_ui,
//GO(__gmpz_bin_uiui,
-//GO(__gmpz_cdiv_q,
+GO(__gmpz_cdiv_q, vFppp)
//GO(__gmpz_cdiv_q_2exp,
//GO(__gmpz_cdiv_qr,
//GO(__gmpz_cdiv_qr_ui,
@@ -463,10 +465,10 @@ GO(__gmpz_cmp, iFpp)
//GO(__gmpz_cmp_d,
//GO(__gmpz_cmp_si,
GO(__gmpz_cmp_ui, iFpu)
-//GO(__gmpz_com,
+GO(__gmpz_com, vFpp)
//GO(__gmpz_combit,
//GO(__gmpz_congruent_2exp_p,
-//GO(__gmpz_congruent_p,
+GO(__gmpz_congruent_p, iFppp)
//GO(__gmpz_congruent_ui_p,
//GO(__gmpz_divexact,
//GO(__gmpz_divexact_gcd,
@@ -477,13 +479,13 @@ GO(__gmpz_cmp_ui, iFpu)
//GO(__gmpz_dump,
GO(__gmpz_export, vFppiLiLp)
//GO(__gmpz_fac_ui,
-//GO(__gmpz_fdiv_q,
-//GO(__gmpz_fdiv_q_2exp,
+GO(__gmpz_fdiv_q, vFppp)
+GO(__gmpz_fdiv_q_2exp, vFppL)
//GO(__gmpz_fdiv_qr,
//GO(__gmpz_fdiv_qr_ui,
//GO(__gmpz_fdiv_q_ui,
-//GO(__gmpz_fdiv_r,
-//GO(__gmpz_fdiv_r_2exp,
+GO(__gmpz_fdiv_r, vFppp)
+GO(__gmpz_fdiv_r_2exp, vFppL)
//GO(__gmpz_fdiv_r_ui,
//GO(__gmpz_fdiv_ui,
//GO(__gmpz_fib2_ui,
@@ -494,7 +496,7 @@ GO(__gmpz_export, vFppiLiLp)
//GO(__gmpz_fits_uint_p,
//GO(__gmpz_fits_ulong_p,
//GO(__gmpz_fits_ushort_p,
-//GO(__gmpz_gcd,
+GO(__gmpz_gcd, vFppp)
//GO(__gmpz_gcdext,
//GO(__gmpz_gcd_ui,
//GO(__gmpz_get_d,
@@ -508,15 +510,15 @@ GO(__gmpz_import, vFpLiLiLp)
GO(__gmpz_init, vFp)
//GO(__gmpz_init2,
//GO(__gmpz_inits,
-//GO(__gmpz_init_set,
+GO(__gmpz_init_set, vFpp)
//GO(__gmpz_init_set_d,
//GO(__gmpz_init_set_si,
//GO(__gmpz_init_set_str,
-//GO(__gmpz_init_set_ui,
+GO(__gmpz_init_set_ui, vFpL)
//GO(__gmpz_inp_raw,
//GO(__gmpz_inp_str,
//GO(__gmpz_inp_str_nowhite,
-//GO(__gmpz_invert,
+GO(__gmpz_invert, iFppp)
//GO(__gmpz_ior,
//GO(__gmpz_jacobi,
//GO(__gmpz_kronecker_si,
@@ -524,20 +526,20 @@ GO(__gmpz_init, vFp)
//GO(__gmpz_lcm,
//GO(__gmpz_lcm_ui,
//GO(__gmpz_legendre,
-//GO(__gmpz_limbs_finish,
-//GO(__gmpz_limbs_modify,
-//GO(__gmpz_limbs_read,
-//GO(__gmpz_limbs_write,
+GO(__gmpz_limbs_finish, vFpL)
+GO(__gmpz_limbs_modify, pFpL)
+GO(__gmpz_limbs_read, pFp)
+GO(__gmpz_limbs_write, pFpL)
//GO(__gmpz_lucas_mod,
//GO(__gmpz_lucnum2_ui,
//GO(__gmpz_lucnum_ui,
//GO(__gmpz_mfac_uiui,
//GO(__gmpz_millerrabin,
GO(__gmpz_mod, vFppp)
-//GO(__gmpz_mul,
-//GO(__gmpz_mul_2exp,
+GO(__gmpz_mul, vFppp)
+GO(__gmpz_mul_2exp, vFppL)
//GO(__gmpz_mul_si,
-//GO(__gmpz_mul_ui,
+GO(__gmpz_mul_ui, vFppL)
//GO(__gmpz_neg,
//GO(__gmpz_nextprime,
//GO(__gmpz_n_pow_ui,
@@ -548,52 +550,52 @@ GO(__gmpz_mod, vFppp)
//GO(__gmpz_perfect_square_p,
//GO(__gmpz_popcount,
GO(__gmpz_powm, vFpppp)
-//GO(__gmpz_powm_sec,
-//GO(__gmpz_powm_ui,
+GO(__gmpz_powm_sec, vFpppp)
+GO(__gmpz_powm_ui, vFppLp)
//GO(__gmpz_pow_ui,
//GO(__gmpz_primorial_ui,
-//GO(__gmpz_probab_prime_p,
+GO(__gmpz_probab_prime_p, iFpi)
//GO(__gmpz_prodlimbs,
//GO(__gmpz_random,
//GO(__gmpz_random2,
//GO(__gmpz_realloc,
//GO(__gmpz_realloc2,
//GO(__gmpz_remove,
-//GO(__gmpz_roinit_n,
+GO(__gmpz_roinit_n, pFppL)
//GO(__gmpz_root,
//GO(__gmpz_rootrem,
//GO(__gmpz_rrandomb,
//GO(__gmpz_scan0,
-//GO(__gmpz_scan1,
-//GO(__gmpz_set,
-//GO(__gmpz_setbit,
+GO(__gmpz_scan1, LFpL)
+GO(__gmpz_set, vFpp)
+GO(__gmpz_setbit, vFpL)
//GO(__gmpz_set_d,
//GO(__gmpz_set_f,
//GO(__gmpz_set_q,
//GO(__gmpz_set_si,
//GO(__gmpz_set_str,
-//GO(__gmpz_set_ui,
+GO(__gmpz_set_ui, vFpL)
//GO(__gmpz_si_kronecker,
//GO(__gmpz_size,
GO(__gmpz_sizeinbase, LFpi)
//GO(__gmpz_sqrt,
//GO(__gmpz_sqrtrem,
//GO(__gmpz_stronglucas,
-//GO(__gmpz_sub,
+GO(__gmpz_sub, vFppp)
//GO(__gmpz_submul,
-//GO(__gmpz_submul_ui,
+GO(__gmpz_submul_ui, vFppL)
GO(__gmpz_sub_ui, vFppu)
//GO(__gmpz_swap,
//GO(__gmpz_tdiv_q,
-//GO(__gmpz_tdiv_q_2exp,
-//GO(__gmpz_tdiv_qr,
+GO(__gmpz_tdiv_q_2exp, vFppL)
+GO(__gmpz_tdiv_qr, vFpppp)
//GO(__gmpz_tdiv_qr_ui,
//GO(__gmpz_tdiv_q_ui,
//GO(__gmpz_tdiv_r,
//GO(__gmpz_tdiv_r_2exp,
//GO(__gmpz_tdiv_r_ui,
//GO(__gmpz_tdiv_ui,
-//GO(__gmpz_tstbit,
+GO(__gmpz_tstbit, iFpL)
//GO(__gmpz_ui_kronecker,
//GO(__gmpz_ui_pow_ui,
//GO(__gmpz_ui_sub,
diff --git a/src/wrapped/wrappedgnutls.c b/src/wrapped/wrappedgnutls.c
index cc89e69..dd4cde2 100755..100644
--- a/src/wrapped/wrappedgnutls.c
+++ b/src/wrapped/wrappedgnutls.c
@@ -35,10 +35,10 @@ GO(4)
// gnutls_log
#define GO(A) \
-static uintptr_t my_gnutls_log_fct_##A = 0; \
-static void my_gnutls_log_##A(int level, const char* p) \
-{ \
- RunFunction(my_context, my_gnutls_log_fct_##A, 2, level, p); \
+static uintptr_t my_gnutls_log_fct_##A = 0; \
+static void my_gnutls_log_##A(int level, const char* p) \
+{ \
+ RunFunctionFmt(my_gnutls_log_fct_##A, "ip", level, p); \
}
SUPER()
#undef GO
@@ -59,10 +59,10 @@ static void* find_gnutls_log_Fct(void* fct)
// pullpush
#define GO(A) \
-static uintptr_t my_pullpush_fct_##A = 0; \
-static long my_pullpush_##A(void* p, void* d, size_t l) \
-{ \
- return (long)RunFunction(my_context, my_pullpush_fct_##A, 3, p, d, l); \
+static uintptr_t my_pullpush_fct_##A = 0; \
+static long my_pullpush_##A(void* p, void* d, size_t l) \
+{ \
+ return (long)RunFunctionFmt(my_pullpush_fct_##A, "ppL", p, d, l); \
}
SUPER()
#undef GO
@@ -83,10 +83,10 @@ static void* find_pullpush_Fct(void* fct)
// timeout
#define GO(A) \
-static uintptr_t my_timeout_fct_##A = 0; \
-static int my_timeout_##A(void* p, uint32_t t) \
-{ \
- return (int)RunFunction(my_context, my_timeout_fct_##A, 2, p, t); \
+static uintptr_t my_timeout_fct_##A = 0; \
+static int my_timeout_##A(void* p, uint32_t t) \
+{ \
+ return (int)RunFunctionFmt(my_timeout_fct_##A, "pu", p, t); \
}
SUPER()
#undef GO
diff --git a/src/wrapped/wrappedgnutls_private.h b/src/wrapped/wrappedgnutls_private.h
index 3697259..13363b0 100755..100644
--- a/src/wrapped/wrappedgnutls_private.h
+++ b/src/wrapped/wrappedgnutls_private.h
@@ -189,6 +189,8 @@ GO(gnutls_dtls_set_timeouts, vFpuu)
//GO(gnutls_ecc_curve_get_pk,
//GO(gnutls_ecc_curve_get_size,
//GO(gnutls_ecc_curve_list,
+GO(_gnutls_ecdh_compute_key, iFppp)
+GO(gnutls_ecdh_compute_key, iFppp)
//GO(gnutls_encode_ber_digest_info,
//GO(_gnutls_encode_ber_rs_raw,
//GO(gnutls_error_is_fatal,
@@ -560,6 +562,7 @@ GO(gnutls_privkey_import_rsa_raw, iFppppppppp)
GO(gnutls_privkey_init, iFp)
//GO(gnutls_privkey_set_flags,
//GO(gnutls_privkey_set_pin_function,
+GO(gnutls_privkey_set_spki, iFppu)
//GO(gnutls_privkey_sign_data,
GO(gnutls_privkey_sign_hash, iFppupp)
//GO(gnutls_privkey_status,
@@ -616,6 +619,7 @@ GO(gnutls_pubkey_init, iFp)
//GO(gnutls_pubkey_print,
//GO(gnutls_pubkey_set_key_usage,
//GO(gnutls_pubkey_set_pin_function,
+GO(gnutls_pubkey_set_spki, iFppu)
//GO(gnutls_pubkey_verify_data2,
GO(gnutls_pubkey_verify_hash2, iFppupp)
//GO(gnutls_pubkey_verify_params,
@@ -1092,6 +1096,9 @@ GO(gnutls_x509_privkey_get_pk_algorithm2, iFpp)
//GO(gnutls_x509_rdn_get2,
//GO(gnutls_x509_rdn_get_by_oid,
//GO(gnutls_x509_rdn_get_oid,
+GO(gnutls_x509_spki_deinit, vFp)
+GO(gnutls_x509_spki_init, vFp)
+GO(gnutls_x509_spki_set_rsa_pss_params, vFppu)
//GO(gnutls_x509_tlsfeatures_add,
//GO(gnutls_x509_tlsfeatures_check_crt,
//GO(gnutls_x509_tlsfeatures_deinit,
diff --git a/src/wrapped/wrappedgobject2.c b/src/wrapped/wrappedgobject2.c
index f9fc35b..d51a736 100755..100644
--- a/src/wrapped/wrappedgobject2.c
+++ b/src/wrapped/wrappedgobject2.c
@@ -67,11 +67,11 @@ static int signal_cb(void* a, void* b, void* c, void* d, void* e)
}
printf_log(LOG_DEBUG, "gobject2 Signal called, sig=%p, handler=%p, NArgs=%d\n", sig, sig?(void*)sig->c_handler:NULL, i);
switch(i) {
- case 1: return (int)RunFunction(my_context, sig->c_handler, 1, sig->data);
- case 2: return (int)RunFunction(my_context, sig->c_handler, 2, a, sig->data);
- case 3: return (int)RunFunction(my_context, sig->c_handler, 3, a, b, sig->data);
- case 4: return (int)RunFunction(my_context, sig->c_handler, 4, a, b, c, sig->data);
- case 5: return (int)RunFunction(my_context, sig->c_handler, 5, a, b, c, d, sig->data);
+ case 1: return (int)RunFunctionFmt(sig->c_handler, "p", sig->data);
+ case 2: return (int)RunFunctionFmt(sig->c_handler, "pp", a, sig->data);
+ case 3: return (int)RunFunctionFmt(sig->c_handler, "ppp", a, b, sig->data);
+ case 4: return (int)RunFunctionFmt(sig->c_handler, "pppp", a, b, c, sig->data);
+ case 5: return (int)RunFunctionFmt(sig->c_handler, "ppppp", a, b, c, d, sig->data);
}
printf_log(LOG_NONE, "Warning, GObject2 signal callback but no data found!\n");
return 0;
@@ -80,47 +80,47 @@ static int signal_cb_swapped(my_signal_t* sig, void* b, void* c, void* d)
{
// data is in front here...
printf_log(LOG_DEBUG, "gobject2 swaped4 Signal called, sig=%p\n", sig);
- return (int)RunFunction(my_context, sig->c_handler, 4, sig->data, b, c, d);
+ return (int)RunFunctionFmt(sig->c_handler, "pppp", sig->data, b, c, d);
}
static int signal_cb_5(void* a, void* b, void* c, void* d, my_signal_t* sig)
{
printf_log(LOG_DEBUG, "gobject2 5 Signal called, sig=%p\n", sig);
- return (int)RunFunction(my_context, sig->c_handler, 5, a, b, c, d, sig->data);
+ return (int)RunFunctionFmt(sig->c_handler, "ppppp", a, b, c, d, sig->data);
}
static int signal_cb_swapped_5(my_signal_t* sig, void* b, void* c, void* d, void* e)
{
// data is in front here...
printf_log(LOG_DEBUG, "gobject2 swaped5 Signal called, sig=%p\n", sig);
- return (int)RunFunction(my_context, sig->c_handler, 5, sig->data, b, c, d, e);
+ return (int)RunFunctionFmt(sig->c_handler, "ppppp", sig->data, b, c, d, e);
}
static int signal_cb_6(void* a, void* b, void* c, void* d, void* e, my_signal_t* sig)
{
printf_log(LOG_DEBUG, "gobject2 6 Signal called, sig=%p\n", sig);
- return (int)RunFunction(my_context, sig->c_handler, 6, a, b, c, d, e, sig->data);
+ return (int)RunFunctionFmt(sig->c_handler, "pppppp", a, b, c, d, e, sig->data);
}
static int signal_cb_swapped_6(my_signal_t* sig, void* b, void* c, void* d, void* e, void* f)
{
// data is in front here...
printf_log(LOG_DEBUG, "gobject2 swaped6 Signal called, sig=%p\n", sig);
- return (int)RunFunction(my_context, sig->c_handler, 6, sig->data, b, c, d, e, f);
+ return (int)RunFunctionFmt(sig->c_handler, "pppppp", sig->data, b, c, d, e, f);
}
static int signal_cb_8(void* a, void* b, void* c, void* d, void* e, void* f, void* g, my_signal_t* sig)
{
printf_log(LOG_DEBUG, "gobject2 8 Signal called, sig=%p\n", sig);
- return (int)RunFunction(my_context, sig->c_handler, 8, a, b, c, d, e, f, g, sig->data);
+ return (int)RunFunctionFmt(sig->c_handler, "pppppppp", a, b, c, d, e, f, g, sig->data);
}
static int signal_cb_swapped_8(my_signal_t* sig, void* b, void* c, void* d, void* e, void* f, void* g, void* h)
{
// data is in front here...
printf_log(LOG_DEBUG, "gobject2 swaped8 Signal called, sig=%p\n", sig);
- return (int)RunFunction(my_context, sig->c_handler, 8, sig->data, b, c, d, e, f, g, h);
+ return (int)RunFunctionFmt(sig->c_handler, "pppppppp", sig->data, b, c, d, e, f, g, h);
}
static void signal_delete(my_signal_t* sig, void* b)
{
uintptr_t d = sig->destroy;
if(d) {
- RunFunction(my_context, d, 2, sig->data, b);
+ RunFunctionFmt(d, "pp", sig->data, b);
}
printf_log(LOG_DEBUG, "gobject2 Signal deleted, sig=%p, destroy=%p\n", sig, (void*)d);
free(sig);
@@ -128,7 +128,7 @@ static void signal_delete(my_signal_t* sig, void* b)
static void addGObject2Alternate(library_t* lib)
{
- #define GO(A, W) AddAutomaticBridge(thread_get_emu(), lib->w.bridge, W, dlsym(lib->w.lib, #A), 0)
+ #define GO(A, W) AddAutomaticBridge(thread_get_emu(), lib->w.bridge, W, dlsym(lib->w.lib, #A), 0, #A)
GO(g_cclosure_marshal_VOID__VOID, vFppuppp);
GO(g_cclosure_marshal_VOID__BOOLEAN, vFppuppp);
GO(g_cclosure_marshal_VOID__UCHAR, vFppuppp);
@@ -174,7 +174,7 @@ static void addGObject2Alternate(library_t* lib)
GO(g_cclosure_marshal_BOOLEAN__FLAGSv, vFpppppip);
GO(g_cclosure_marshal_BOOLEAN__BOXED_BOXEDv, vFpppppip);
#undef GO
- #define GO(A, W) AddAutomaticBridge(thread_get_emu(), lib->w.bridge, W, A, 0)
+ #define GO(A, W) AddAutomaticBridge(thread_get_emu(), lib->w.bridge, W, A, 0, #A)
GO(signal_cb, iFpppp);
GO(signal_cb_swapped, iFpppp);
GO(signal_cb_5, iFppppp);
@@ -267,10 +267,10 @@ GO(11) \
GO(12) \
#define GO(A) \
-static uintptr_t my_copy_fct_##A = 0; \
-static void* my_copy_##A(void* data) \
-{ \
- return (void*)RunFunction(my_context, my_copy_fct_##A, 1, data);\
+static uintptr_t my_copy_fct_##A = 0; \
+static void* my_copy_##A(void* data) \
+{ \
+ return (void*)RunFunctionFmt(my_copy_fct_##A, "p", data); \
}
SUPER()
#undef GO
@@ -288,10 +288,10 @@ static void* findCopyFct(void* fct)
}
#define GO(A) \
-static uintptr_t my_free_fct_##A = 0; \
-static void my_free_##A(void* data) \
-{ \
- RunFunction(my_context, my_free_fct_##A, 1, data);\
+static uintptr_t my_free_fct_##A = 0; \
+static void my_free_##A(void* data) \
+{ \
+ RunFunctionFmt(my_free_fct_##A, "p", data); \
}
SUPER()
#undef GO
@@ -309,10 +309,10 @@ static void* findFreeFct(void* fct)
}
// GSignalAccumulator
#define GO(A) \
-static uintptr_t my_accumulator_fct_##A = 0; \
-static int my_accumulator_##A(void* ihint, void* return_accu, void* handler_return, void* data) \
-{ \
- return RunFunction(my_context, my_accumulator_fct_##A, 4, ihint, return_accu, handler_return, data);\
+static uintptr_t my_accumulator_fct_##A = 0; \
+static int my_accumulator_##A(void* ihint, void* return_accu, void* handler_return, void* data) \
+{ \
+ return RunFunctionFmt(my_accumulator_fct_##A, "pppp", ihint, return_accu, handler_return, data); \
}
SUPER()
#undef GO
@@ -332,10 +332,10 @@ static void* findAccumulatorFct(void* fct)
// GClosureMarshal
#define GO(A) \
-static uintptr_t my_marshal_fct_##A = 0; \
+static uintptr_t my_marshal_fct_##A = 0; \
static void my_marshal_##A(void* closure, void* return_value, uint32_t n, void* values, void* hint, void* data) \
{ \
- RunFunction(my_context, my_marshal_fct_##A, 6, closure, return_value, n, values, hint, data); \
+ RunFunctionFmt(my_marshal_fct_##A, "ppuppp", closure, return_value, n, values, hint, data); \
}
SUPER()
#undef GO
@@ -346,7 +346,7 @@ static void* findMarshalFct(void* fct)
#define GO(A) if(my_marshal_fct_##A == (uintptr_t)fct) return my_marshal_##A;
SUPER()
#undef GO
- #define GO(A) if(my_marshal_fct_##A == 0) {AddAutomaticBridge(thread_get_emu(), my_lib->w.bridge, vFppuppp, my_marshal_##A, 0); my_marshal_fct_##A = (uintptr_t)fct; return my_marshal_##A; }
+ #define GO(A) if(my_marshal_fct_##A == 0) {AddAutomaticBridge(thread_get_emu(), my_lib->w.bridge, vFppuppp, my_marshal_##A, 0, #A); my_marshal_fct_##A = (uintptr_t)fct; return my_marshal_##A; }
SUPER()
#undef GO
printf_log(LOG_NONE, "Warning, no more slot for gobject Closure Marshal callback\n");
@@ -355,10 +355,10 @@ static void* findMarshalFct(void* fct)
// GClosureNotify
#define GO(A) \
-static uintptr_t my_GClosureNotify_fct_##A = 0; \
-static int my_GClosureNotify_func_##A(void* a, void* b) \
-{ \
- return RunFunction(my_context, my_GClosureNotify_fct_##A, 2, a, b);\
+static uintptr_t my_GClosureNotify_fct_##A = 0; \
+static int my_GClosureNotify_func_##A(void* a, void* b) \
+{ \
+ return RunFunctionFmt(my_GClosureNotify_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -378,10 +378,10 @@ static void* findGClosureNotify_Fct(void* fct)
// GValueTransform
#define GO(A) \
-static uintptr_t my_valuetransform_fct_##A = 0; \
-static void my_valuetransform_##A(void* src, void* dst) \
-{ \
- RunFunction(my_context, my_valuetransform_fct_##A, 2, src, dst);\
+static uintptr_t my_valuetransform_fct_##A = 0; \
+static void my_valuetransform_##A(void* src, void* dst) \
+{ \
+ RunFunctionFmt(my_valuetransform_fct_##A, "pp", src, dst); \
}
SUPER()
#undef GO
@@ -401,10 +401,10 @@ static void* findValueTransformFct(void* fct)
// GDestroyFunc ...
#define GO(A) \
-static uintptr_t my_destroyfunc_fct_##A = 0; \
-static int my_destroyfunc_##A(void* a, void* b) \
-{ \
- return RunFunction(my_context, my_destroyfunc_fct_##A, 2, a, b);\
+static uintptr_t my_destroyfunc_fct_##A = 0; \
+static int my_destroyfunc_##A(void* a, void* b) \
+{ \
+ return RunFunctionFmt(my_destroyfunc_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -424,10 +424,10 @@ static void* findDestroyFct(void* fct)
// GWeakNotify
#define GO(A) \
-static uintptr_t my_weaknotifyfunc_fct_##A = 0; \
-static int my_weaknotifyfunc_##A(void* a, void* b) \
-{ \
- return RunFunction(my_context, my_weaknotifyfunc_fct_##A, 2, a, b);\
+static uintptr_t my_weaknotifyfunc_fct_##A = 0; \
+static int my_weaknotifyfunc_##A(void* a, void* b) \
+{ \
+ return RunFunctionFmt(my_weaknotifyfunc_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -447,10 +447,10 @@ static void* findWeakNotifyFct(void* fct)
// GCallback (generic function with 6 arguments, hopefully it's enough)
#define GO(A) \
-static uintptr_t my_GCallback_fct_##A = 0; \
-static void* my_GCallback_##A(void* a, void* b, void* c, void* d, void* e, void* f) \
-{ \
- return (void*)RunFunction(my_context, my_GCallback_fct_##A, 6, a, b, c, d, e, f); \
+static uintptr_t my_GCallback_fct_##A = 0; \
+static void* my_GCallback_##A(void* a, void* b, void* c, void* d, void* e, void* f) \
+{ \
+ return (void*)RunFunctionFmt(my_GCallback_fct_##A, "pppppp", a, b, c, d, e, f); \
}
SUPER()
#undef GO
@@ -481,32 +481,32 @@ typedef struct my_GParamSpecTypeInfo_s {
int (*values_cmp) (void* pspec, void* value1, void* value2);
} my_GParamSpecTypeInfo_t;
-#define GO(A) \
+#define GO(A) \
static my_GParamSpecTypeInfo_t my_GParamSpecTypeInfo_##A = {0}; \
static my_GParamSpecTypeInfo_t *ref_GParamSpecTypeInfo_##A = NULL;
SUPER()
#undef GO
// then the static functions callback that may be used with the structure, but dispatch also have a callback...
#define GO(A) \
-static uintptr_t fct_funcs_instance_init_##A = 0; \
-static void my_funcs_instance_init_##A(void* pspec) { \
- RunFunction(my_context, fct_funcs_instance_init_##A, 1, pspec); \
+static uintptr_t fct_funcs_instance_init_##A = 0; \
+static void my_funcs_instance_init_##A(void* pspec) { \
+ RunFunctionFmt(fct_funcs_instance_init_##A, "p", pspec); \
} \
-static uintptr_t fct_funcs_finalize_##A = 0; \
-static void my_funcs_finalize_##A(void* pspec) { \
- RunFunction(my_context, fct_funcs_finalize_##A, 1, pspec); \
+static uintptr_t fct_funcs_finalize_##A = 0; \
+static void my_funcs_finalize_##A(void* pspec) { \
+ RunFunctionFmt(fct_funcs_finalize_##A, "p", pspec); \
} \
-static uintptr_t fct_funcs_value_set_default_##A = 0; \
-static void my_funcs_value_set_default_##A(void* pspec, void* value) { \
- RunFunction(my_context, fct_funcs_value_set_default_##A, 2, pspec, value); \
+static uintptr_t fct_funcs_value_set_default_##A = 0; \
+static void my_funcs_value_set_default_##A(void* pspec, void* value) { \
+ RunFunctionFmt(fct_funcs_value_set_default_##A, "pp", pspec, value); \
} \
-static uintptr_t fct_funcs_value_validate_##A = 0; \
-static int my_funcs_value_validate_##A(void* pspec, void* value) { \
- return (int)RunFunction(my_context, fct_funcs_value_validate_##A, 2, pspec, value); \
+static uintptr_t fct_funcs_value_validate_##A = 0; \
+static int my_funcs_value_validate_##A(void* pspec, void* value) { \
+ return (int)RunFunctionFmt(fct_funcs_value_validate_##A, "pp", pspec, value); \
} \
-static uintptr_t fct_funcs_values_cmp_##A = 0; \
+static uintptr_t fct_funcs_values_cmp_##A = 0; \
static int my_funcs_values_cmp_##A(void* pspec, void* value1, void* value2) { \
- return (int)RunFunction(my_context, fct_funcs_values_cmp_##A, 3, pspec, value1, value2); \
+ return (int)RunFunctionFmt(fct_funcs_values_cmp_##A, "ppp", pspec, value1, value2); \
}
SUPER()
@@ -540,10 +540,10 @@ static my_GParamSpecTypeInfo_t* findFreeGParamSpecTypeInfo(my_GParamSpecTypeInfo
// GInterfaceInitFunc
#define GO(A) \
-static uintptr_t my_GInterfaceInitFunc_fct_##A = 0; \
-static void my_GInterfaceInitFunc_##A(void* src, void* dst) \
-{ \
- RunFunction(my_context, my_GInterfaceInitFunc_fct_##A, 2, src, dst);\
+static uintptr_t my_GInterfaceInitFunc_fct_##A = 0; \
+static void my_GInterfaceInitFunc_##A(void* src, void* dst) \
+{ \
+ RunFunctionFmt(my_GInterfaceInitFunc_fct_##A, "pp", src, dst); \
}
SUPER()
#undef GO
@@ -562,10 +562,10 @@ static void* findGInterfaceInitFuncFct(void* fct)
}
// GInterfaceFinalizeFunc
#define GO(A) \
-static uintptr_t my_GInterfaceFinalizeFunc_fct_##A = 0; \
-static void my_GInterfaceFinalizeFunc_##A(void* src, void* dst) \
-{ \
- RunFunction(my_context, my_GInterfaceFinalizeFunc_fct_##A, 2, src, dst);\
+static uintptr_t my_GInterfaceFinalizeFunc_fct_##A = 0; \
+static void my_GInterfaceFinalizeFunc_##A(void* src, void* dst) \
+{ \
+ RunFunctionFmt(my_GInterfaceFinalizeFunc_fct_##A, "pp", src, dst); \
}
SUPER()
#undef GO
@@ -584,10 +584,10 @@ static void* findGInterfaceFinalizeFuncFct(void* fct)
}
// compare
#define GO(A) \
-static uintptr_t my_compare_fct_##A = 0; \
-static int my_compare_##A(void* a, void* b, void* data) \
-{ \
- return RunFunction(my_context, my_compare_fct_##A, 3, a, b, data); \
+static uintptr_t my_compare_fct_##A = 0; \
+static int my_compare_##A(void* a, void* b, void* data) \
+{ \
+ return RunFunctionFmt(my_compare_fct_##A, "ppp", a, b, data); \
}
SUPER()
#undef GO
@@ -623,7 +623,7 @@ EXPORT int my_g_boxed_type_register_static(x64emu_t* emu, void* name, void* boxe
EXPORT uint32_t my_g_signal_new(x64emu_t* emu, void* name, size_t itype, int flags, uint32_t offset, void* acc, void* accu_data, void* marsh, size_t rtype, uint32_t n, void** b)
{
printf_log(LOG_DEBUG, "g_signal_new for \"%s\", with offset=%d and %d args\n", (const char*)name, offset, n);
-
+
void* cb_acc = findAccumulatorFct(acc);
void* cb_marsh = findMarshalFct(marsh);
my_add_signal_offset(itype, offset, n); // register the signal for later use
@@ -644,7 +644,7 @@ EXPORT uint32_t my_g_signal_new(x64emu_t* emu, void* name, size_t itype, int fla
EXPORT uint32_t my_g_signal_newv(x64emu_t* emu, void* name, size_t itype, int flags, void* closure, void* acc, void* accu_data, void* marsh, size_t rtype, uint32_t n, void* types)
{
printf_log(LOG_DEBUG, "g_signal_newv for \"%s\", with %d args\n", (const char*)name, n);
-
+
return my->g_signal_newv(name, itype, flags, closure, findAccumulatorFct(acc), accu_data, findMarshalFct(marsh), rtype, n, types);
}
@@ -732,7 +732,7 @@ EXPORT void my_g_value_register_transform_func(x64emu_t* emu, size_t src, size_t
static int my_signal_emission_hook(void* ihint, uint32_t n, void* values, my_signal_t* sig)
{
printf_log(LOG_DEBUG, "gobject2 Signal Emission Hook called, sig=%p\n", sig);
- return (int)RunFunction(my_context, sig->c_handler, 4, ihint, n, values, sig->data);
+ return (int)RunFunctionFmt(sig->c_handler, "pupp", ihint, n, values, sig->data);
}
EXPORT unsigned long my_g_signal_add_emission_hook(x64emu_t* emu, uint32_t signal, void* detail, void* f, void* data, void* notify)
{
@@ -745,7 +745,7 @@ EXPORT unsigned long my_g_signal_add_emission_hook(x64emu_t* emu, uint32_t signa
return my->g_signal_add_emission_hook(signal, detail, my_signal_emission_hook, sig, my_signal_delete);
}
-EXPORT size_t my_g_type_register_static_simple(x64emu_t* emu, size_t parent, void* name, size_t class_size, void* class_init, size_t instance_size, void* instance_init, int flags)
+EXPORT size_t my_g_type_register_static_simple(x64emu_t* emu, size_t parent, void* name, uint32_t class_size, void* class_init, uint32_t instance_size, void* instance_init, uint32_t flags)
{
//gobject2_my_t *my = (gobject2_my_t*)my_lib->w.p2;
@@ -821,7 +821,7 @@ EXPORT void my_g_signal_emit_valist(x64emu_t* emu, void* inst, uint32_t id, void
my->g_signal_emit_valist(inst, id, quark, VARARGS);
}
-EXPORT void my_g_signal_emit(x64emu_t* emu, void* inst, uint32_t id, void* quark, x64_va_list_t b)
+EXPORT void my_g_signal_emit(x64emu_t* emu, void* inst, uint32_t id, void* quark, uintptr_t* b)
{
CREATE_VALIST_FROM_VAARG(b, emu->scratch, 3);
my->g_signal_emit_valist(inst, id, quark, VARARGS);
diff --git a/src/wrapped/wrappedgobject2_private.h b/src/wrapped/wrappedgobject2_private.h
index 4d74c45..b81d036 100755..100644
--- a/src/wrapped/wrappedgobject2_private.h
+++ b/src/wrapped/wrappedgobject2_private.h
@@ -8,15 +8,15 @@
//GO(_fini,
GO(g_array_get_type, LFv)
GO(g_binding_flags_get_type, LFv)
-//GO(g_binding_get_flags,
+GO(g_binding_get_flags, uFp)
//GO(g_binding_get_source,
//GO(g_binding_get_source_property,
//GO(g_binding_get_target,
-//GO(g_binding_get_target_property,
+GO(g_binding_get_target_property, pFp)
GO(g_binding_get_type, LFv)
-//GO(g_binding_unbind,
-GO(g_boxed_copy, pFip)
-GO(g_boxed_free, vFip)
+GO(g_binding_unbind, vFp)
+GO(g_boxed_copy, pFLp)
+GO(g_boxed_free, vFLp)
GOM(g_boxed_type_register_static, LFEppp)
GO(g_byte_array_get_type, LFv)
GO(g_bytes_get_type, LFv)
@@ -96,10 +96,10 @@ GO(g_enum_get_value_by_nick, pFpp)
GO(g_enum_register_static, LFpp)
GO(g_error_get_type, LFv)
GO(g_flags_complete_type_info, vFipp)
-GO(g_flags_get_first_value, pFpi)
+GO(g_flags_get_first_value, pFpu)
GO(g_flags_get_value_by_name, pFpp)
GO(g_flags_get_value_by_nick, pFpp)
-GO(g_flags_register_static, iFpp)
+GO(g_flags_register_static, LFpp)
GO(g_gstring_get_type, LFv)
GO(g_gtype_get_type, LFv)
GO(g_hash_table_get_type, LFv)
@@ -114,7 +114,7 @@ GO(g_markup_parse_context_get_type, LFv)
GO(g_match_info_get_type, LFv)
//GOM(g_object_add_toggle_ref, vFEpBp)
GO(g_object_add_weak_pointer, vFpp)
-//GO(g_object_bind_property,
+GO(g_object_bind_property, pFppppu)
//GO(g_object_bind_property_full,
//GO(g_object_bind_property_with_closures,
GO(g_object_class_find_property, pFpp)
@@ -122,7 +122,7 @@ GOM(g_object_class_install_properties, vFEpup)
GO(g_object_class_install_property, vFpup)
GO(g_object_class_list_properties, pFpp)
GO(g_object_class_override_property, vFpup)
-//GO(g_object_compat_control,
+GO(g_object_compat_control, LFLp)
GOM(g_object_connect, pFEppV)
GO(g_object_disconnect, vFpppppppppppppppp) // caarg
//GOM(g_object_dup_data, pFEppBp)
@@ -155,11 +155,11 @@ GOM(g_object_set, vFEppV)
GO(g_object_set_data, vFppp)
GOM(g_object_set_data_full, vFEpppp)
GO(g_object_set_property, vFppp)
-GO(g_object_set_qdata, vFppp)
+GO(g_object_set_qdata, vFpup)
GOM(g_object_set_qdata_full, vFEpppp)
GOM(g_object_set_valist, vFEppA)
GO(g_object_steal_data, pFpp)
-GO(g_object_steal_qdata, pFpp)
+GO(g_object_steal_qdata, pFpu)
GO(g_object_thaw_notify, vFp)
GO(g_object_unref, vFp)
GO(g_object_watch_closure, vFpp)
@@ -169,8 +169,8 @@ GO(g_param_spec_boolean, pFpppii)
GO(g_param_spec_boxed, pFpppLi)
GO(g_param_spec_char, pFpppccci)
GO(g_param_spec_double, pFpppdddi)
-GO(g_param_spec_enum, pFpppiii)
-GO(g_param_spec_flags, pFpppiui)
+GO(g_param_spec_enum, pFpppLii)
+GO(g_param_spec_flags, pFpppLui)
GO(g_param_spec_float, pFpppfffi)
GO(g_param_spec_get_blurb, pFp)
GO(g_param_spec_get_default_value, pFp)
@@ -178,19 +178,19 @@ GO(g_param_spec_get_name, pFp)
GO(g_param_spec_get_nick, pFp)
GO(g_param_spec_get_qdata, pFpu)
GO(g_param_spec_get_redirect_target, pFp)
-GO(g_param_spec_gtype, pFpppii)
+GO(g_param_spec_gtype, pFpppLi)
GO(g_param_spec_int, pFpppiiii)
-GO(g_param_spec_int64, pFpppIIIi)
-GO(g_param_spec_internal, pFipppu)
+GO(g_param_spec_int64, pFpppllli)
+GO(g_param_spec_internal, pFLpppi)
GO(g_param_spec_long, pFpppllli)
GO(g_param_spec_object, pFpppii)
GO(g_param_spec_override, pFpp)
GO(g_param_spec_param, pFpppii)
GO(g_param_spec_pointer, pFpppi)
-GO(g_param_spec_pool_insert, vFppi)
-GO(g_param_spec_pool_list, pFpip)
-GO(g_param_spec_pool_list_owned, pFpi)
-GO(g_param_spec_pool_lookup, pFppii)
+GO(g_param_spec_pool_insert, vFppL)
+GO(g_param_spec_pool_list, pFpLp)
+GO(g_param_spec_pool_list_owned, pFpL)
+GO(g_param_spec_pool_lookup, pFppLi)
GO(g_param_spec_pool_new, pFi)
GO(g_param_spec_pool_remove, vFpp)
GO(g_param_spec_ref, pFp)
@@ -203,7 +203,7 @@ GO(g_param_spec_string, pFppppi)
DATA(g_param_spec_types, sizeof(void*))
GO(g_param_spec_uchar, pFpppCCCi)
GO(g_param_spec_uint, pFpppuuui)
-GO(g_param_spec_uint64, pFpppUUUi)
+GO(g_param_spec_uint64, pFpppLLLi)
GO(g_param_spec_ulong, pFpppLLLi)
GO(g_param_spec_unichar, pFpppui)
GO(g_param_spec_unref, vFp)
@@ -215,7 +215,7 @@ GO(g_param_value_defaults, iFpp)
GO(g_param_values_cmp, iFppp)
GO(g_param_value_set_default, vFpp)
GO(g_param_value_validate, iFpp)
-//GO(g_pointer_type_register_static,
+GO(g_pointer_type_register_static, LFp)
//GO(g_pollfd_get_type,
//GO(g_ptr_array_get_type,
//GO(g_regex_get_type,
@@ -242,9 +242,9 @@ GOM(g_signal_handlers_block_matched, uFEpiupppp)
GOM(g_signal_handlers_disconnect_matched, uFEpiupppp)
GOM(g_signal_handlers_unblock_matched, uFEpiupppp)
GO(g_signal_handler_unblock, vFpL)
-GO(g_signal_has_handler_pending, iFpupi)
-GO(g_signal_list_ids, pFip)
-GO(g_signal_lookup, uFpi)
+GO(g_signal_has_handler_pending, iFpuui)
+GO(g_signal_list_ids, pFLp)
+GO(g_signal_lookup, uFpL)
GO(g_signal_name, pFu)
GOM(g_signal_new, uFEpLiupppLuV)
//GOM(g_signal_new_class_handler, uFEpLupppppnV)
@@ -254,9 +254,9 @@ GO(g_signal_override_class_closure, vFuLp)
GOM(g_signal_override_class_handler, vFEppp)
GO(g_signal_parse_name, iFpLppi)
GO(g_signal_query, vFup)
-GO(g_signal_remove_emission_hook, vFpL)
+GO(g_signal_remove_emission_hook, vFuL)
//GOM(g_signal_set_va_marshaller, vFEuiB)
-GO(g_signal_stop_emission, vFpup)
+GO(g_signal_stop_emission, vFpuu)
GO(g_signal_stop_emission_by_name, vFpp)
GO(g_signal_type_cclosure_new, pFLu) //should wrap?
GO(g_source_get_type, LFv)
@@ -267,46 +267,46 @@ GO(g_strv_get_type, LFv)
GO(g_thread_get_type, LFv)
GO(g_time_zone_get_type, LFv)
//GOM(g_type_add_class_cache_func, vFEpB)
-GO(g_type_add_class_private, vFpLu)
-//GO(g_type_add_instance_private,
+GO(g_type_add_class_private, vFLL)
+GO(g_type_add_instance_private, iFLL)
//GOM(g_type_add_interface_check, vFEpB)
//GOM(g_type_add_interface_dynamic, vFEiip)
GOM(g_type_add_interface_static, vFELLp)
GO(g_type_check_class_cast, pFpL)
-GO(g_type_check_class_is_a, LFpL)
-GO(g_type_check_instance, LFp)
+GO(g_type_check_class_is_a, iFpL)
+GO(g_type_check_instance, iFp)
GO(g_type_check_instance_cast, pFpL)
GO(g_type_check_instance_is_a, LFpL)
-GO(g_type_check_instance_is_fundamentally_a, LFpL)
-GO(g_type_check_is_value_type, LFp)
+GO(g_type_check_instance_is_fundamentally_a, iFpL)
+GO(g_type_check_is_value_type, iFL)
GO(g_type_check_value, LFp)
-GO(g_type_check_value_holds, LFpL)
+GO(g_type_check_value_holds, iFpL)
GO(g_type_children, pFip)
-GO(g_type_class_add_private, vFpu)
+GO(g_type_class_add_private, vFpL)
GO(g_type_class_adjust_private_offset, vFpp)
GO(g_type_class_get_instance_private_offset, iFp)
-GO(g_type_class_get_private, pFpi)
+GO(g_type_class_get_private, pFpL)
GO(g_type_class_peek, pFi)
GOM(g_type_class_peek_parent, pFEp)
GO(g_type_class_peek_static, pFi)
GO(g_type_class_ref, pFp)
GO(g_type_class_unref, vFp)
GO(g_type_class_unref_uncached, vFp)
-GO(g_type_create_instance, pFi)
-GO(g_type_default_interface_peek, pFi)
+GO(g_type_create_instance, pFL)
+GO(g_type_default_interface_peek, pFL)
GO(g_type_default_interface_ref, pFi)
GO(g_type_default_interface_unref, vFp)
-GO(g_type_depth, uFi)
+GO(g_type_depth, uFL)
GO(g_type_ensure, vFi)
GO(g_type_free_instance, vFp)
GO(g_type_from_name, iFp)
-GO(g_type_fundamental, iFi)
+GO(g_type_fundamental, LFL)
GO(g_type_fundamental_next, iFv)
//GOM(g_type_get_plugin, pFEi) // GTypePugin is a stuct with callback
-GO(g_type_get_qdata, pFip)
+GO(g_type_get_qdata, pFLu)
GO(g_type_get_type_registration_serial, uFv)
GO(g_type_init, vFv)
-GO(g_type_init_with_debug_flags, vFi)
+GO(g_type_init_with_debug_flags, vFu)
GO(g_type_instance_get_private, pFpL)
GO(g_type_interface_add_prerequisite, vFLL)
//GOM(g_type_interface_get_plugin, pFEii) // return GTypePlugin*
@@ -317,31 +317,31 @@ GO(g_type_interfaces, pFLp)
GO(g_type_is_a, iFLL)
//GO(g_type_module_add_interface,
//GO(g_type_module_get_type,
-//GO(g_type_module_register_enum,
-//GO(g_type_module_register_flags,
+GO(g_type_module_register_enum, LFppp)
+GO(g_type_module_register_flags, LFppp)
//GO(g_type_module_register_type,
-//GO(g_type_module_set_name,
-//GO(g_type_module_unuse,
-//GO(g_type_module_use,
+GO(g_type_module_set_name, vFpp)
+GO(g_type_module_unuse, vFp)
+GO(g_type_module_use, iFp)
GO(g_type_name, pFL)
-//GO(g_type_name_from_class,
-//GO(g_type_name_from_instance,
+GO(g_type_name_from_class, pFp)
+GO(g_type_name_from_instance, pFp)
GO(g_type_next_base, LFLL)
GO(g_type_parent, LFL)
//GO(g_type_plugin_complete_interface_info,
//GO(g_type_plugin_complete_type_info,
//GO(g_type_plugin_get_type,
-//GO(g_type_plugin_unuse,
+GO(g_type_plugin_unuse, vFp)
//GO(g_type_plugin_use,
-GO(g_type_qname, pFL)
+GO(g_type_qname, uFL)
GO(g_type_query, vFLp)
//GOM(type_register_dynamic, iFEpippi)
GOM(g_type_register_fundamental, LFELpppi)
GOM(g_type_register_static, LFELppi)
-GOM(g_type_register_static_simple, LFELpLpLpi)
+GOM(g_type_register_static_simple, LFELpupupu)
//GOM(g_type_remove_class_cache_func, vFEpB)
//GOM(g_type_remove_interface_check, vFEpB)
-GO(g_type_set_qdata, vFLpp)
+GO(g_type_set_qdata, vFLup)
GO(g_type_test_flags, iFLu)
GOM(g_type_value_table_peek, pFEL) //need to bridge GTypeValueTable
GO(g_value_array_append, pFpp) //TODO: does GValueArray needs alignement?
@@ -369,9 +369,9 @@ GO(g_value_get_double, dFp)
GO(g_value_get_enum, iFp)
GO(g_value_get_flags, uFp)
GO(g_value_get_float, fFp)
-GO(g_value_get_gtype, iFp)
+GO(g_value_get_gtype, LFp)
GO(g_value_get_int, iFp)
-GO(g_value_get_int64, IFp)
+GO(g_value_get_int64, lFp)
GO(g_value_get_long, lFp)
GO(g_value_get_object, pFp)
GO(g_value_get_param, pFp)
@@ -381,10 +381,10 @@ GO(g_value_get_string, pFp)
GO(g_value_get_type, LFv)
GO(g_value_get_uchar, CFp)
GO(g_value_get_uint, uFp)
-GO(g_value_get_uint64, UFp)
+GO(g_value_get_uint64, LFp)
GO(g_value_get_ulong, LFp)
GO(g_value_get_variant, pFp)
-GO(g_value_init, pFpi)
+GO(g_value_init, pFpL)
GO(g_value_init_from_instance, vFpp)
GO(g_value_peek_pointer, pFp)
GOM(g_value_register_transform_func, vFEiip)
@@ -397,10 +397,10 @@ GO(g_value_set_double, vFpd)
GO(g_value_set_enum, vFpi)
GO(g_value_set_flags, vFpu)
GO(g_value_set_float, vFpf)
-GO(g_value_set_gtype, vFpi)
+GO(g_value_set_gtype, vFpL)
GO(g_value_set_instance, vFpp)
GO(g_value_set_int, vFpi)
-GO(g_value_set_int64, vFpI)
+GO(g_value_set_int64, vFpl)
GO(g_value_set_long, vFpl)
GO(g_value_set_object, vFpp)
GO(g_value_set_object_take_ownership, vFpp)
@@ -414,7 +414,7 @@ GO(g_value_set_string, vFpp)
GO(g_value_set_string_take_ownership, vFpp)
GO(g_value_set_uchar, vFpC)
GO(g_value_set_uint, vFpu)
-GO(g_value_set_uint64, vFpU)
+GO(g_value_set_uint64, vFpL)
GO(g_value_set_ulong, vFpL)
GO(g_value_set_variant, vFpp)
GO(g_value_take_boxed, vFpp)
@@ -424,7 +424,7 @@ GO(g_value_take_string, vFpp)
GO(g_value_take_variant, vFpp)
GO(g_value_transform, iFpp)
GO(g_value_type_compatible, iFii)
-GO(g_value_type_transformable, iFii)
+GO(g_value_type_transformable, iFLL)
GO(g_value_unset, vFp)
//GO(g_variant_builder_get_type,
//GO(g_variant_dict_get_type,
diff --git a/src/wrapped/wrappedgomp.c b/src/wrapped/wrappedgomp.c
new file mode 100644
index 0000000..650da53
--- /dev/null
+++ b/src/wrapped/wrappedgomp.c
@@ -0,0 +1,18 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#define _GNU_SOURCE /* See feature_test_macros(7) */
+#include <dlfcn.h>
+
+#include "wrappedlibs.h"
+
+#include "wrapper.h"
+#include "bridge.h"
+#include "librarian/library_private.h"
+#include "x64emu.h"
+
+const char* gompName = "libgomp.so.1";
+#define LIBNAME gomp
+
+#include "wrappedlib_init.h"
+
diff --git a/src/wrapped/wrappedgomp_private.h b/src/wrapped/wrappedgomp_private.h
new file mode 100644
index 0000000..33b1970
--- /dev/null
+++ b/src/wrapped/wrappedgomp_private.h
@@ -0,0 +1,477 @@
+#if !(defined(GO) && defined(GOM) && defined(GO2) && defined(DATA))
+#error meh!
+#endif
+//GO(acc_async_test,
+//GO(acc_async_test_all,
+//GO(acc_async_test_all_h_,
+//GO(acc_async_test_h_,
+//GO(acc_async_wait,
+//GO(acc_async_wait_all,
+//GO(acc_attach,
+//GO(acc_attach_async,
+//GO(acc_copyin,
+//GO(acc_copyin_32_h_,
+//GO(acc_copyin_64_h_,
+//GO(acc_copyin_array_h_,
+//GO(acc_copyin_async,
+//GO(acc_copyin_async_32_h_,
+//GO(acc_copyin_async_64_h_,
+//GO(acc_copyin_async_array_h_,
+//GO(acc_copyout,
+//GO(acc_copyout_32_h_,
+//GO(acc_copyout_64_h_,
+//GO(acc_copyout_array_h_,
+//GO(acc_copyout_async,
+//GO(acc_copyout_async_32_h_,
+//GO(acc_copyout_async_64_h_,
+//GO(acc_copyout_async_array_h_,
+//GO(acc_copyout_finalize,
+//GO(acc_copyout_finalize_32_h_,
+//GO(acc_copyout_finalize_64_h_,
+//GO(acc_copyout_finalize_array_h_,
+//GO(acc_copyout_finalize_async,
+//GO(acc_create,
+//GO(acc_create_32_h_,
+//GO(acc_create_64_h_,
+//GO(acc_create_array_h_,
+//GO(acc_create_async,
+//GO(acc_create_async_32_h_,
+//GO(acc_create_async_64_h_,
+//GO(acc_create_async_array_h_,
+//GO(acc_delete,
+//GO(acc_delete_32_h_,
+//GO(acc_delete_64_h_,
+//GO(acc_delete_array_h_,
+//GO(acc_delete_async,
+//GO(acc_delete_async_32_h_,
+//GO(acc_delete_async_64_h_,
+//GO(acc_delete_async_array_h_,
+//GO(acc_delete_finalize,
+//GO(acc_delete_finalize_32_h_,
+//GO(acc_delete_finalize_64_h_,
+//GO(acc_delete_finalize_array_h_,
+//GO(acc_delete_finalize_async,
+//GO(acc_detach,
+//GO(acc_detach_async,
+//GO(acc_detach_finalize,
+//GO(acc_detach_finalize_async,
+//GO(acc_deviceptr,
+//GO(acc_free,
+//GO(acc_get_cuda_stream,
+//GO(acc_get_current_cuda_context,
+//GO(acc_get_current_cuda_device,
+//GO(acc_get_device_num,
+//GO(acc_get_device_num_h_,
+//GO(acc_get_device_type,
+//GO(acc_get_device_type_h_,
+//GO(acc_get_num_devices,
+//GO(acc_get_num_devices_h_,
+//GO(acc_get_property,
+//GO(acc_get_property_h_,
+//GO(acc_get_property_string,
+//GO(acc_get_property_string_h_,
+//GO(acc_hostptr,
+//GO(acc_init,
+//GO(acc_init_h_,
+//GO(acc_is_present,
+//GO(acc_is_present_32_h_,
+//GO(acc_is_present_64_h_,
+//GO(acc_is_present_array_h_,
+//GO(acc_malloc,
+//GO(acc_map_data,
+//GO(acc_memcpy_from_device,
+//GO(acc_memcpy_from_device_async,
+//GO(acc_memcpy_to_device,
+//GO(acc_memcpy_to_device_async,
+//GO(acc_on_device,
+//GO(acc_on_device_h_,
+//GO(acc_pcopyin,
+//GO(acc_pcreate,
+//GO(acc_present_or_copyin,
+//GO(acc_present_or_copyin_32_h_,
+//GO(acc_present_or_copyin_64_h_,
+//GO(acc_present_or_copyin_array_h_,
+//GO(acc_present_or_create,
+//GO(acc_present_or_create_32_h_,
+//GO(acc_present_or_create_64_h_,
+//GO(acc_present_or_create_array_h_,
+//GO(acc_prof_lookup,
+//GO(acc_prof_register,
+//GO(acc_prof_unregister,
+//GO(acc_register_library,
+//GO(acc_set_cuda_stream,
+//GO(acc_set_device_num,
+//GO(acc_set_device_num_h_,
+//GO(acc_set_device_type,
+//GO(acc_set_device_type_h_,
+//GO(acc_shutdown,
+//GO(acc_shutdown_h_,
+//GO(acc_unmap_data,
+//GO(acc_update_device,
+//GO(acc_update_device_32_h_,
+//GO(acc_update_device_64_h_,
+//GO(acc_update_device_array_h_,
+//GO(acc_update_device_async,
+//GO(acc_update_device_async_32_h_,
+//GO(acc_update_device_async_64_h_,
+//GO(acc_update_device_async_array_h_,
+//GO(acc_update_self,
+//GO(acc_update_self_32_h_,
+//GO(acc_update_self_64_h_,
+//GO(acc_update_self_array_h_,
+//GO(acc_update_self_async,
+//GO(acc_update_self_async_32_h_,
+//GO(acc_update_self_async_64_h_,
+//GO(acc_update_self_async_array_h_,
+//GO(acc_wait,
+//GO(acc_wait_all,
+//GO(acc_wait_all_async,
+//GO(acc_wait_all_async_h_,
+//GO(acc_wait_all_h_,
+//GO(acc_wait_async,
+//GO(acc_wait_async_h_,
+//GO(acc_wait_h_,
+
+//GO(GOMP_alloc,
+//GO(GOMP_atomic_end,
+//GO(GOMP_atomic_start,
+//GO(GOMP_barrier,
+//GO(GOMP_barrier_cancel,
+//GO(GOMP_cancel,
+//GO(GOMP_cancellation_point,
+//GO(GOMP_critical_end,
+//GO(GOMP_critical_name_end,
+//GO(GOMP_critical_name_start,
+//GO(GOMP_critical_start,
+//GO(GOMP_doacross_post,
+//GO(GOMP_doacross_ull_post,
+//GO(GOMP_doacross_ull_wait,
+//GO(GOMP_doacross_wait,
+//GO(GOMP_error,
+//GO(GOMP_free,
+//GO(GOMP_loop_doacross_dynamic_start,
+//GO(GOMP_loop_doacross_guided_start,
+//GO(GOMP_loop_doacross_runtime_start,
+//GO(GOMP_loop_doacross_start,
+//GO(GOMP_loop_doacross_static_start,
+//GO(GOMP_loop_dynamic_next,
+//GO(GOMP_loop_dynamic_start,
+//GO(GOMP_loop_end,
+//GO(GOMP_loop_end_cancel,
+//GO(GOMP_loop_end_nowait,
+//GO(GOMP_loop_guided_next,
+//GO(GOMP_loop_guided_start,
+//GO(GOMP_loop_maybe_nonmonotonic_runtime_next,
+//GO(GOMP_loop_maybe_nonmonotonic_runtime_start,
+//GO(GOMP_loop_nonmonotonic_dynamic_next,
+//GO(GOMP_loop_nonmonotonic_dynamic_start,
+//GO(GOMP_loop_nonmonotonic_guided_next,
+//GO(GOMP_loop_nonmonotonic_guided_start,
+//GO(GOMP_loop_nonmonotonic_runtime_next,
+//GO(GOMP_loop_nonmonotonic_runtime_start,
+//GO(GOMP_loop_ordered_dynamic_next,
+//GO(GOMP_loop_ordered_dynamic_start,
+//GO(GOMP_loop_ordered_guided_next,
+//GO(GOMP_loop_ordered_guided_start,
+//GO(GOMP_loop_ordered_runtime_next,
+//GO(GOMP_loop_ordered_runtime_start,
+//GO(GOMP_loop_ordered_start,
+//GO(GOMP_loop_ordered_static_next,
+//GO(GOMP_loop_ordered_static_start,
+//GO(GOMP_loop_runtime_next,
+//GO(GOMP_loop_runtime_start,
+//GO(GOMP_loop_start,
+//GO(GOMP_loop_static_next,
+//GO(GOMP_loop_static_start,
+//GO(GOMP_loop_ull_doacross_dynamic_start,
+//GO(GOMP_loop_ull_doacross_guided_start,
+//GO(GOMP_loop_ull_doacross_runtime_start,
+//GO(GOMP_loop_ull_doacross_start,
+//GO(GOMP_loop_ull_doacross_static_start,
+//GO(GOMP_loop_ull_dynamic_next,
+//GO(GOMP_loop_ull_dynamic_start,
+//GO(GOMP_loop_ull_guided_next,
+//GO(GOMP_loop_ull_guided_start,
+//GO(GOMP_loop_ull_maybe_nonmonotonic_runtime_next,
+//GO(GOMP_loop_ull_maybe_nonmonotonic_runtime_start,
+//GO(GOMP_loop_ull_nonmonotonic_dynamic_next,
+//GO(GOMP_loop_ull_nonmonotonic_dynamic_start,
+//GO(GOMP_loop_ull_nonmonotonic_guided_next,
+//GO(GOMP_loop_ull_nonmonotonic_guided_start,
+//GO(GOMP_loop_ull_nonmonotonic_runtime_next,
+//GO(GOMP_loop_ull_nonmonotonic_runtime_start,
+//GO(GOMP_loop_ull_ordered_dynamic_next,
+//GO(GOMP_loop_ull_ordered_dynamic_start,
+//GO(GOMP_loop_ull_ordered_guided_next,
+//GO(GOMP_loop_ull_ordered_guided_start,
+//GO(GOMP_loop_ull_ordered_runtime_next,
+//GO(GOMP_loop_ull_ordered_runtime_start,
+//GO(GOMP_loop_ull_ordered_start,
+//GO(GOMP_loop_ull_ordered_static_next,
+//GO(GOMP_loop_ull_ordered_static_start,
+//GO(GOMP_loop_ull_runtime_next,
+//GO(GOMP_loop_ull_runtime_start,
+//GO(GOMP_loop_ull_start,
+//GO(GOMP_loop_ull_static_next,
+//GO(GOMP_loop_ull_static_start,
+//GO(GOMP_offload_register,
+//GO(GOMP_offload_register_ver,
+//GO(GOMP_offload_unregister,
+//GO(GOMP_offload_unregister_ver,
+//GO(GOMP_ordered_end,
+//GO(GOMP_ordered_start,
+//GO(GOMP_parallel,
+//GO(GOMP_parallel_end,
+//GO(GOMP_parallel_loop_dynamic,
+//GO(GOMP_parallel_loop_dynamic_start,
+//GO(GOMP_parallel_loop_guided,
+//GO(GOMP_parallel_loop_guided_start,
+//GO(GOMP_parallel_loop_maybe_nonmonotonic_runtime,
+//GO(GOMP_parallel_loop_nonmonotonic_dynamic,
+//GO(GOMP_parallel_loop_nonmonotonic_guided,
+//GO(GOMP_parallel_loop_nonmonotonic_runtime,
+//GO(GOMP_parallel_loop_runtime,
+//GO(GOMP_parallel_loop_runtime_start,
+//GO(GOMP_parallel_loop_static,
+//GO(GOMP_parallel_loop_static_start,
+//GO(GOMP_parallel_reductions,
+//GO(GOMP_parallel_sections,
+//GO(GOMP_parallel_sections_start,
+//GO(GOMP_parallel_start,
+//GO(GOMP_PLUGIN_acc_default_dim,
+//GO(GOMP_PLUGIN_acc_thread,
+//GO(GOMP_PLUGIN_async_unmap_vars,
+//GO(GOMP_PLUGIN_debug,
+//GO(GOMP_PLUGIN_error,
+//GO(GOMP_PLUGIN_fatal,
+//GO(GOMP_PLUGIN_goacc_profiling_dispatch,
+//GO(GOMP_PLUGIN_goacc_thread,
+//GO(GOMP_PLUGIN_malloc,
+//GO(GOMP_PLUGIN_malloc_cleared,
+//GO(GOMP_PLUGIN_realloc,
+//GO(GOMP_PLUGIN_target_rev,
+//GO(GOMP_PLUGIN_target_task_completion,
+//GO(GOMP_scope_start,
+//GO(GOMP_sections2_start,
+//GO(GOMP_sections_end,
+//GO(GOMP_sections_end_cancel,
+//GO(GOMP_sections_end_nowait,
+//GO(GOMP_sections_next,
+//GO(GOMP_sections_start,
+//GO(GOMP_single_copy_end,
+//GO(GOMP_single_copy_start,
+//GO(GOMP_single_start,
+//GO(GOMP_target,
+//GO(GOMP_target_data,
+//GO(GOMP_target_data_ext,
+//GO(GOMP_target_end_data,
+//GO(GOMP_target_enter_exit_data,
+//GO(GOMP_target_ext,
+//GO(GOMP_target_update,
+//GO(GOMP_target_update_ext,
+//GO(GOMP_task,
+//GO(GOMP_taskgroup_end,
+//GO(GOMP_taskgroup_reduction_register,
+//GO(GOMP_taskgroup_reduction_unregister,
+//GO(GOMP_taskgroup_start,
+//GO(GOMP_taskloop,
+//GO(GOMP_taskloop_ull,
+//GO(GOMP_task_reduction_remap,
+//GO(GOMP_taskwait,
+//GO(GOMP_taskwait_depend,
+//GO(GOMP_taskwait_depend_nowait,
+//GO(GOMP_taskyield,
+//GO(GOMP_teams,
+//GO(GOMP_teams4,
+//GO(GOMP_teams_reg,
+//GO(GOMP_warning,
+//GO(GOMP_workshare_task_reduction_unregister,
+
+//GO(omp_aligned_alloc,
+//GO(omp_aligned_calloc,
+//GO(omp_alloc,
+//GO(omp_calloc,
+//GO(omp_capture_affinity,
+//GO(omp_capture_affinity_,
+//GO(omp_destroy_allocator,
+//GO(omp_destroy_allocator_,
+//GO(omp_destroy_lock@OMP_1.0
+//GO(omp_destroy_lock,
+//GO(omp_destroy_lock_,
+//GO(omp_destroy_lock_@OMP_1.0
+//GO(omp_destroy_nest_lock@OMP_1.0
+//GO(omp_destroy_nest_lock,
+//GO(omp_destroy_nest_lock_,
+//GO(omp_destroy_nest_lock_@OMP_1.0
+//GO(omp_display_affinity,
+//GO(omp_display_affinity_,
+//GO(omp_display_env,
+//GO(omp_display_env_,
+//GO(omp_display_env_8_,
+//GO(omp_free,
+//GO(omp_fulfill_event,
+//GO(omp_fulfill_event_,
+//GO(omp_get_active_level,
+//GO(omp_get_active_level_,
+//GO(omp_get_affinity_format,
+//GO(omp_get_affinity_format_,
+//GO(omp_get_ancestor_thread_num,
+//GO(omp_get_ancestor_thread_num_,
+//GO(omp_get_ancestor_thread_num_8_,
+//GO(omp_get_cancellation,
+//GO(omp_get_cancellation_,
+//GO(omp_get_default_allocator,
+//GO(omp_get_default_allocator_,
+//GO(omp_get_default_device,
+//GO(omp_get_default_device_,
+//GO(omp_get_device_num,
+//GO(omp_get_device_num_,
+//GO(omp_get_dynamic,
+//GO(omp_get_dynamic_,
+//GO(omp_get_initial_device,
+//GO(omp_get_initial_device_,
+//GO(omp_get_level,
+//GO(omp_get_level_,
+//GO(omp_get_mapped_ptr,
+//GO(omp_get_max_active_levels,
+//GO(omp_get_max_active_levels_,
+//GO(omp_get_max_task_priority,
+//GO(omp_get_max_task_priority_,
+//GO(omp_get_max_teams,
+//GO(omp_get_max_teams_,
+//GO(omp_get_max_threads,
+//GO(omp_get_max_threads_,
+//GO(omp_get_nested,
+//GO(omp_get_nested_,
+//GO(omp_get_num_devices,
+//GO(omp_get_num_devices_,
+//GO(omp_get_num_places,
+//GO(omp_get_num_places_,
+//GO(omp_get_num_procs,
+//GO(omp_get_num_procs_,
+//GO(omp_get_num_teams,
+//GO(omp_get_num_teams_,
+//GO(omp_get_num_threads,
+//GO(omp_get_num_threads_,
+//GO(omp_get_partition_num_places,
+//GO(omp_get_partition_num_places_,
+//GO(omp_get_partition_place_nums,
+//GO(omp_get_partition_place_nums_,
+//GO(omp_get_partition_place_nums_8_,
+//GO(omp_get_place_num,
+//GO(omp_get_place_num_,
+//GO(omp_get_place_num_procs,
+//GO(omp_get_place_num_procs_,
+//GO(omp_get_place_num_procs_8_,
+//GO(omp_get_place_proc_ids,
+//GO(omp_get_place_proc_ids_,
+//GO(omp_get_place_proc_ids_8_,
+//GO(omp_get_proc_bind,
+//GO(omp_get_proc_bind_,
+//GO(omp_get_schedule,
+//GO(omp_get_schedule_,
+//GO(omp_get_schedule_8_,
+//GO(omp_get_supported_active_levels,
+//GO(omp_get_supported_active_levels_,
+//GO(omp_get_team_num,
+//GO(omp_get_team_num_,
+//GO(omp_get_team_size,
+//GO(omp_get_team_size_,
+//GO(omp_get_team_size_8_,
+//GO(omp_get_teams_thread_limit,
+//GO(omp_get_teams_thread_limit_,
+//GO(omp_get_thread_limit,
+//GO(omp_get_thread_limit_,
+//GO(omp_get_thread_num,
+//GO(omp_get_thread_num_,
+//GO(omp_get_wtick,
+//GO(omp_get_wtick_,
+//GO(omp_get_wtime,
+//GO(omp_get_wtime_,
+//GO(omp_in_explicit_task,
+//GO(omp_in_explicit_task_,
+//GO(omp_in_final,
+//GO(omp_in_final_,
+//GO(omp_init_allocator,
+//GO(omp_init_allocator_,
+//GO(omp_init_allocator_8_,
+//GO(omp_init_lock,
+//GO(omp_init_lock@OMP_1.0
+//GO(omp_init_lock_,
+//GO(omp_init_lock_@OMP_1.0
+//GO(omp_init_nest_lock,
+//GO(omp_init_nest_lock@OMP_1.0
+//GO(omp_init_nest_lock_,
+//GO(omp_init_nest_lock_@OMP_1.0
+//GO(omp_in_parallel,
+//GO(omp_in_parallel_,
+//GO(omp_is_initial_device,
+//GO(omp_is_initial_device_,
+//GO(omp_pause_resource,
+//GO(omp_pause_resource_,
+//GO(omp_pause_resource_all,
+//GO(omp_pause_resource_all_,
+//GO(omp_realloc,
+//GO(omp_set_affinity_format,
+//GO(omp_set_affinity_format_,
+//GO(omp_set_default_allocator,
+//GO(omp_set_default_allocator_,
+//GO(omp_set_default_device,
+//GO(omp_set_default_device_,
+//GO(omp_set_default_device_8_,
+//GO(omp_set_dynamic,
+//GO(omp_set_dynamic_,
+//GO(omp_set_dynamic_8_,
+//GO(omp_set_lock,
+//GO(omp_set_lock@OMP_1.0
+//GO(omp_set_lock_,
+//GO(omp_set_lock_@OMP_1.0
+//GO(omp_set_max_active_levels,
+//GO(omp_set_max_active_levels_,
+//GO(omp_set_max_active_levels_8_,
+//GO(omp_set_nested,
+//GO(omp_set_nested_,
+//GO(omp_set_nested_8_,
+//GO(omp_set_nest_lock@OMP_1.0
+//GO(omp_set_nest_lock,
+//GO(omp_set_nest_lock_,
+//GO(omp_set_nest_lock_@OMP_1.0
+//GO(omp_set_num_teams,
+//GO(omp_set_num_teams_,
+//GO(omp_set_num_teams_8_,
+//GO(omp_set_num_threads,
+//GO(omp_set_num_threads_,
+//GO(omp_set_num_threads_8_,
+//GO(omp_set_schedule,
+//GO(omp_set_schedule_,
+//GO(omp_set_schedule_8_,
+//GO(omp_set_teams_thread_limit,
+//GO(omp_set_teams_thread_limit_,
+//GO(omp_set_teams_thread_limit_8_,
+//GO(omp_target_alloc,
+//GO(omp_target_associate_ptr,
+//GO(omp_target_disassociate_ptr,
+//GO(omp_target_free,
+//GO(omp_target_is_accessible,
+//GO(omp_target_is_present,
+//GO(omp_target_memcpy,
+//GO(omp_target_memcpy_async,
+//GO(omp_target_memcpy_rect,
+//GO(omp_target_memcpy_rect_async,
+//GO(omp_test_lock@OMP_1.0
+//GO(omp_test_lock,
+//GO(omp_test_lock_,
+//GO(omp_test_lock_@OMP_1.0
+//GO(omp_test_nest_lock@OMP_1.0
+//GO(omp_test_nest_lock,
+//GO(omp_test_nest_lock_@OMP_1.0
+//GO(omp_test_nest_lock_,
+//GO(omp_unset_lock,
+//GO(omp_unset_lock@OMP_1.0
+//GO(omp_unset_lock_@OMP_1.0
+//GO(omp_unset_lock_,
+//GO(omp_unset_nest_lock,
+//GO(omp_unset_nest_lock@OMP_1.0
+//GO(omp_unset_nest_lock_,
+//GO(omp_unset_nest_lock_@OMP_1.0
+
diff --git a/src/wrapped/wrappedgssapi.c b/src/wrapped/wrappedgssapi.c
index 959d49c..959d49c 100755..100644
--- a/src/wrapped/wrappedgssapi.c
+++ b/src/wrapped/wrappedgssapi.c
diff --git a/src/wrapped/wrappedgssapi_private.h b/src/wrapped/wrappedgssapi_private.h
index bf393f7..bf393f7 100755..100644
--- a/src/wrapped/wrappedgssapi_private.h
+++ b/src/wrapped/wrappedgssapi_private.h
diff --git a/src/wrapped/wrappedgssapikrb5.c b/src/wrapped/wrappedgssapikrb5.c
index b3befc3..b3befc3 100755..100644
--- a/src/wrapped/wrappedgssapikrb5.c
+++ b/src/wrapped/wrappedgssapikrb5.c
diff --git a/src/wrapped/wrappedgssapikrb5_private.h b/src/wrapped/wrappedgssapikrb5_private.h
index fa57c6a..fa57c6a 100755..100644
--- a/src/wrapped/wrappedgssapikrb5_private.h
+++ b/src/wrapped/wrappedgssapikrb5_private.h
diff --git a/src/wrapped/wrappedgstapp_private.h b/src/wrapped/wrappedgstapp_private.h
index 7cda393..2b3bd09 100644
--- a/src/wrapped/wrappedgstapp_private.h
+++ b/src/wrapped/wrappedgstapp_private.h
@@ -7,7 +7,7 @@
//GO(gst_app_sink_get_drop,
//GO(gst_app_sink_get_emit_signals,
//GO(gst_app_sink_get_max_buffers,
-//GO(gst_app_sink_get_type,
+GO(gst_app_sink_get_type, LFv)
//GO(gst_app_sink_get_wait_on_eos,
//GO(gst_app_sink_is_eos,
//GO(gst_app_sink_pull_preroll,
diff --git a/src/wrapped/wrappedgstaudio_private.h b/src/wrapped/wrappedgstaudio_private.h
index 4573f24..ef7996c 100644
--- a/src/wrapped/wrappedgstaudio_private.h
+++ b/src/wrapped/wrappedgstaudio_private.h
@@ -29,27 +29,27 @@
//GO(gst_audio_base_src_set_provide_clock,
//GO(gst_audio_base_src_set_slave_method,
//GO(gst_audio_base_src_slave_method_get_type,
-//GO(gst_audio_buffer_clip,
+GO(gst_audio_buffer_clip, pFppii)
//GO(gst_audio_buffer_map,
-//GO(gst_audio_buffer_reorder_channels,
-//GO(gst_audio_buffer_truncate,
+GO(gst_audio_buffer_reorder_channels, iFpuipp)
+GO(gst_audio_buffer_truncate, pFpiLL)
//GO(gst_audio_buffer_unmap,
//GO(gst_audio_cd_src_add_track,
//GO(gst_audio_cd_src_get_type,
//GO(gst_audio_cd_src_mode_get_type,
-//GO(gst_audio_channel_get_fallback_mask,
+GO(gst_audio_channel_get_fallback_mask, LFi)
//GO(gst_audio_channel_mixer_flags_get_type,
-//GO(gst_audio_channel_mixer_free,
-//GO(gst_audio_channel_mixer_is_passthrough,
-//GO(gst_audio_channel_mixer_new,
-//GO(gst_audio_channel_mixer_new_with_matrix,
-//GO(gst_audio_channel_mixer_samples,
+GO(gst_audio_channel_mixer_free, vFp)
+GO(gst_audio_channel_mixer_is_passthrough, iFp)
+GO(gst_audio_channel_mixer_new, pFuuipip)
+GO(gst_audio_channel_mixer_new_with_matrix, pFuuiip)
+GO(gst_audio_channel_mixer_samples, vFpppi)
//GO(gst_audio_channel_position_get_type,
-//GO(gst_audio_channel_positions_from_mask,
-//GO(gst_audio_channel_positions_to_mask,
-//GO(gst_audio_channel_positions_to_string,
-//GO(gst_audio_channel_positions_to_valid_order,
-//GO(gst_audio_check_valid_channel_positions,
+GO(gst_audio_channel_positions_from_mask, iFiLp)
+GO(gst_audio_channel_positions_to_mask, iFpiip)
+GO(gst_audio_channel_positions_to_string, pFpi)
+GO(gst_audio_channel_positions_to_valid_order, iFpi)
+GO(gst_audio_check_valid_channel_positions, iFpii)
//GO(gst_audio_clipping_meta_api_get_type,
//GO(gst_audio_clipping_meta_get_info,
//GO(gst_audio_clock_adjust,
@@ -58,20 +58,20 @@
//GO(gst_audio_clock_invalidate,
//GO(gst_audio_clock_new,
//GO(gst_audio_clock_reset,
-//GO(gst_audio_converter_convert,
+GO(gst_audio_converter_convert, iFpupLpp)
//GO(gst_audio_converter_flags_get_type,
//GO(gst_audio_converter_free,
-//GO(gst_audio_converter_get_config,
-//GO(gst_audio_converter_get_in_frames,
-//GO(gst_audio_converter_get_max_latency,
+GO(gst_audio_converter_get_config, pFppp)
+GO(gst_audio_converter_get_in_frames, LFpL)
+GO(gst_audio_converter_get_max_latency, LFp)
//GO(gst_audio_converter_get_out_frames,
//GO(gst_audio_converter_get_type,
-//GO(gst_audio_converter_is_passthrough,
+GO(gst_audio_converter_is_passthrough, iFp)
//GO(gst_audio_converter_new,
-//GO(gst_audio_converter_reset,
-//GO(gst_audio_converter_samples,
+GO(gst_audio_converter_reset, vFp)
+GO(gst_audio_converter_samples, iFpupLpL)
//GO(gst_audio_converter_supports_inplace,
-//GO(gst_audio_converter_update_config,
+GO(gst_audio_converter_update_config, iFpiip)
//GO(gst_audio_decoder_allocate_output_buffer,
//GO(_gst_audio_decoder_error,
//GO(gst_audio_decoder_finish_frame,
@@ -145,16 +145,16 @@
//GO(gst_audio_filter_class_add_pad_templates,
//GO(gst_audio_filter_get_type,
//GO(gst_audio_flags_get_type,
-GO(gst_audio_format_build_integer, iFiiii)
+GO(gst_audio_format_build_integer, uFiiii)
//GO(gst_audio_format_fill_silence,
//GO(gst_audio_format_flags_get_type,
-//GO(gst_audio_format_from_string,
+GO(gst_audio_format_from_string, uFp)
//GO(gst_audio_format_get_info,
//GO(gst_audio_format_get_type,
//GO(gst_audio_format_info_get_type,
-//GO(gst_audio_formats_raw,
-//GO(gst_audio_format_to_string,
-//GO(gst_audio_get_channel_reorder_map,
+GO(gst_audio_formats_raw, pFp)
+GO(gst_audio_format_to_string, pFu)
+GO(gst_audio_get_channel_reorder_map, iFippp)
//GO(gst_audio_iec61937_frame_size,
//GO(gst_audio_iec61937_payload,
GO(gst_audio_info_convert, iFpiIip)
@@ -175,23 +175,23 @@ GO(gst_audio_layout_get_type, pFv)
//GO(gst_audio_pack_flags_get_type,
//GO(gst_audio_quantize_flags_get_type,
//GO(gst_audio_quantize_free,
-//GO(gst_audio_quantize_new,
-//GO(gst_audio_quantize_reset,
-//GO(gst_audio_quantize_samples,
-//GO(gst_audio_reorder_channels,
+GO(gst_audio_quantize_new, pFuuuuuu)
+GO(gst_audio_quantize_reset, vFp)
+GO(gst_audio_quantize_samples, vFpppu)
+GO(gst_audio_reorder_channels, iFpLuipp)
//GO(gst_audio_resampler_filter_interpolation_get_type,
//GO(gst_audio_resampler_filter_mode_get_type,
//GO(gst_audio_resampler_flags_get_type,
//GO(gst_audio_resampler_free,
-//GO(gst_audio_resampler_get_in_frames,
-//GO(gst_audio_resampler_get_max_latency,
+GO(gst_audio_resampler_get_in_frames, LFpL)
+GO(gst_audio_resampler_get_max_latency, LFp)
//GO(gst_audio_resampler_get_out_frames,
//GO(gst_audio_resampler_method_get_type,
-//GO(gst_audio_resampler_new,
-//GO(gst_audio_resampler_options_set_quality,
-//GO(gst_audio_resampler_resample,
-//GO(gst_audio_resampler_reset,
-//GO(gst_audio_resampler_update,
+GO(gst_audio_resampler_new, pFuuuiiip)
+GO(gst_audio_resampler_options_set_quality, vFuuiip)
+GO(gst_audio_resampler_resample, vFppLpL)
+GO(gst_audio_resampler_reset, vFp)
+GO(gst_audio_resampler_update, iFpiip)
//GO(gst_audio_ring_buffer_acquire,
//GO(gst_audio_ring_buffer_activate,
//GO(gst_audio_ring_buffer_advance,
@@ -228,27 +228,27 @@ GO(gst_audio_layout_get_type, pFv)
//GO(gst_audio_ring_buffer_stop,
//GO(gst_audio_sink_get_type,
//GO(gst_audio_src_get_type,
-//GO(gst_audio_stream_align_copy,
+GO(gst_audio_stream_align_copy, pFp)
//GO(gst_audio_stream_align_free,
//GO(gst_audio_stream_align_get_alignment_threshold,
//GO(gst_audio_stream_align_get_discont_wait,
-//GO(gst_audio_stream_align_get_rate,
-//GO(gst_audio_stream_align_get_samples_since_discont,
-//GO(gst_audio_stream_align_get_timestamp_at_discont,
+GO(gst_audio_stream_align_get_rate, iFp)
+GO(gst_audio_stream_align_get_samples_since_discont, LFp)
+GO(gst_audio_stream_align_get_timestamp_at_discont, LFp)
//GO(gst_audio_stream_align_get_type,
-//GO(gst_audio_stream_align_mark_discont,
-//GO(gst_audio_stream_align_new,
-//GO(gst_audio_stream_align_process,
+GO(gst_audio_stream_align_mark_discont, vFp)
+GO(gst_audio_stream_align_new, pFiLL)
+GO(gst_audio_stream_align_process, iFpiLuppp)
//GO(gst_audio_stream_align_set_alignment_threshold,
-//GO(gst_audio_stream_align_set_discont_wait,
-//GO(gst_audio_stream_align_set_rate,
-//GO(gst_buffer_add_audio_clipping_meta,
-//GO(gst_buffer_add_audio_downmix_meta,
+GO(gst_audio_stream_align_set_discont_wait, vFpL)
+GO(gst_audio_stream_align_set_rate, vFpi)
+GO(gst_buffer_add_audio_clipping_meta, pFpuLL)
+GO(gst_buffer_add_audio_downmix_meta, pFppipip)
//GO(gst_buffer_add_audio_meta,
-//GO(gst_buffer_get_audio_downmix_meta_for_channels,
-//GO(gst_stream_volume_convert_volume,
-//GO(gst_stream_volume_get_mute,
-//GO(gst_stream_volume_get_type,
-//GO(gst_stream_volume_get_volume,
-//GO(gst_stream_volume_set_mute,
-//GO(gst_stream_volume_set_volume,
+GO(gst_buffer_get_audio_downmix_meta_for_channels, pFppi)
+GO(gst_stream_volume_convert_volume, dFuud)
+GO(gst_stream_volume_get_mute, iFp)
+GO(gst_stream_volume_get_type, LFv)
+GO(gst_stream_volume_get_volume, dFpu)
+GO(gst_stream_volume_set_mute, vFpi)
+GO(gst_stream_volume_set_volume, vFpud)
diff --git a/src/wrapped/wrappedgstbase_private.h b/src/wrapped/wrappedgstbase_private.h
index 5e38d93..f203a1b 100644
--- a/src/wrapped/wrappedgstbase_private.h
+++ b/src/wrapped/wrappedgstbase_private.h
@@ -3,31 +3,31 @@
#endif
//GO(gst_adapter_available,
-//GO(gst_adapter_available_fast,
+GO(gst_adapter_available_fast, LFp)
//GO(gst_adapter_clear,
-//GO(gst_adapter_copy,
-//GO(gst_adapter_copy_bytes,
-//GO(gst_adapter_distance_from_discont,
-//GO(gst_adapter_dts_at_discont,
-//GO(gst_adapter_flush,
+GO(gst_adapter_copy, vFppLL)
+GO(gst_adapter_copy_bytes, pFpLL)
+GO(gst_adapter_distance_from_discont, LFp)
+GO(gst_adapter_dts_at_discont, LFp)
+GO(gst_adapter_flush, vFpL)
//GO(gst_adapter_get_buffer,
-//GO(gst_adapter_get_buffer_fast,
-//GO(gst_adapter_get_buffer_list,
-//GO(gst_adapter_get_list,
+GO(gst_adapter_get_buffer_fast, pFpL)
+GO(gst_adapter_get_buffer_list, pFpL)
+GO(gst_adapter_get_list, pFpL)
//GO(gst_adapter_get_type,
-//GO(gst_adapter_map,
-//GO(gst_adapter_masked_scan_uint32,
-//GO(gst_adapter_masked_scan_uint32_peek,
-//GO(gst_adapter_new,
+GO(gst_adapter_map, pFpL)
+GO(gst_adapter_masked_scan_uint32, lFpuuLL)
+GO(gst_adapter_masked_scan_uint32_peek, lFpuuLLp)
+GO(gst_adapter_new, pFv)
//GO(gst_adapter_offset_at_discont,
-//GO(gst_adapter_prev_dts,
-//GO(gst_adapter_prev_dts_at_offset,
-//GO(gst_adapter_prev_offset,
+GO(gst_adapter_prev_dts, LFpp)
+GO(gst_adapter_prev_dts_at_offset, LFpLp)
+GO(gst_adapter_prev_offset, LFpp)
//GO(gst_adapter_prev_pts,
//GO(gst_adapter_prev_pts_at_offset,
//GO(gst_adapter_pts_at_discont,
-//GO(gst_adapter_push,
-//GO(gst_adapter_take,
+GO(gst_adapter_push, vFpp)
+GO(gst_adapter_take, pFpL)
//GO(gst_adapter_take_buffer,
//GO(gst_adapter_take_buffer_fast,
//GO(gst_adapter_take_buffer_list,
@@ -156,8 +156,8 @@
//GO(gst_bit_reader_get_pos,
//GO(gst_bit_reader_get_remaining,
//GO(gst_bit_reader_get_size,
-//GO(gst_bit_reader_init,
-//GO(gst_bit_reader_new,
+GO(gst_bit_reader_init, vFppu)
+GO(gst_bit_reader_new, pFpu)
//GO(gst_bit_reader_peek_bits_uint16,
//GO(gst_bit_reader_peek_bits_uint32,
//GO(gst_bit_reader_peek_bits_uint64,
@@ -172,25 +172,25 @@
//GO(gst_bit_writer_get_data,
//GO(gst_bit_writer_get_size,
//GO(gst_bit_writer_init,
-//GO(gst_bit_writer_init_with_data,
-//GO(gst_bit_writer_init_with_size,
-//GO(gst_bit_writer_new,
-//GO(gst_bit_writer_new_with_data,
-//GO(gst_bit_writer_new_with_size,
+GO(gst_bit_writer_init_with_data, vFppui)
+GO(gst_bit_writer_init_with_size, vFpui)
+GO(gst_bit_writer_new, pFv)
+GO(gst_bit_writer_new_with_data, pFpui)
+GO(gst_bit_writer_new_with_size, pFui)
//GO(gst_bit_writer_put_bits_uint16,
//GO(gst_bit_writer_put_bits_uint32,
//GO(gst_bit_writer_put_bits_uint64,
//GO(gst_bit_writer_put_bits_uint8,
//GO(gst_bit_writer_put_bytes,
-//GO(gst_bit_writer_reset,
-//GO(gst_bit_writer_reset_and_get_buffer,
-//GO(gst_bit_writer_reset_and_get_data,
+GO(gst_bit_writer_reset, vFp)
+GO(gst_bit_writer_reset_and_get_buffer, pFp)
+GO(gst_bit_writer_reset_and_get_data, pFp)
//GO(gst_bit_writer_set_pos,
//GO(gst_byte_reader_dup_data,
-//GO(gst_byte_reader_dup_string_utf16,
-//GO(gst_byte_reader_dup_string_utf32,
-//GO(gst_byte_reader_dup_string_utf8,
-//GO(gst_byte_reader_free,
+GO(gst_byte_reader_dup_string_utf16, iFpp)
+GO(gst_byte_reader_dup_string_utf32, iFpp)
+GO(gst_byte_reader_dup_string_utf8, iFpp)
+GO(gst_byte_reader_free, vFp)
//GO(gst_byte_reader_get_data,
//GO(gst_byte_reader_get_float32_be,
//GO(gst_byte_reader_get_float32_le,
@@ -208,7 +208,7 @@
//GO(gst_byte_reader_get_pos,
//GO(gst_byte_reader_get_remaining,
//GO(gst_byte_reader_get_size,
-//GO(gst_byte_reader_get_string_utf8,
+GO(gst_byte_reader_get_string_utf8, iFpp)
//GO(gst_byte_reader_get_sub_reader,
//GO(gst_byte_reader_get_uint16_be,
//GO(gst_byte_reader_get_uint16_le,
@@ -220,9 +220,9 @@
//GO(gst_byte_reader_get_uint64_le,
//GO(gst_byte_reader_get_uint8,
//GO(gst_byte_reader_init,
-//GO(gst_byte_reader_masked_scan_uint32,
-//GO(gst_byte_reader_masked_scan_uint32_peek,
-//GO(gst_byte_reader_new,
+GO(gst_byte_reader_masked_scan_uint32, uFpuuuu)
+GO(gst_byte_reader_masked_scan_uint32_peek, uFpuuuup)
+GO(gst_byte_reader_new, pFpu)
//GO(gst_byte_reader_peek_data,
//GO(gst_byte_reader_peek_float32_be,
//GO(gst_byte_reader_peek_float32_le,
@@ -237,7 +237,7 @@
//GO(gst_byte_reader_peek_int64_be,
//GO(gst_byte_reader_peek_int64_le,
//GO(gst_byte_reader_peek_int8,
-//GO(gst_byte_reader_peek_string_utf8,
+GO(gst_byte_reader_peek_string_utf8, iFpp)
//GO(gst_byte_reader_peek_sub_reader,
//GO(gst_byte_reader_peek_uint16_be,
//GO(gst_byte_reader_peek_uint16_le,
@@ -251,20 +251,20 @@
//GO(gst_byte_reader_set_pos,
//GO(gst_byte_reader_skip,
//GO(gst_byte_reader_skip_string_utf16,
-//GO(gst_byte_reader_skip_string_utf32,
+GO(gst_byte_reader_skip_string_utf32, iFp)
//GO(gst_byte_reader_skip_string_utf8,
//GO(gst_byte_writer_ensure_free_space,
//GO(gst_byte_writer_fill,
//GO(gst_byte_writer_free,
//GO(gst_byte_writer_free_and_get_buffer,
//GO(gst_byte_writer_free_and_get_data,
-//GO(gst_byte_writer_get_remaining,
+GO(gst_byte_writer_get_remaining, uFp)
//GO(gst_byte_writer_init,
-//GO(gst_byte_writer_init_with_data,
-//GO(gst_byte_writer_init_with_size,
-//GO(gst_byte_writer_new,
-//GO(gst_byte_writer_new_with_data,
-//GO(gst_byte_writer_new_with_size,
+GO(gst_byte_writer_init_with_data, vFppui)
+GO(gst_byte_writer_init_with_size, vFpui)
+GO(gst_byte_writer_new, pFv)
+GO(gst_byte_writer_new_with_data, pFpui)
+GO(gst_byte_writer_new_with_size, pFui)
//GO(gst_byte_writer_put_data,
//GO(gst_byte_writer_put_float32_be,
//GO(gst_byte_writer_put_float32_le,
@@ -279,9 +279,9 @@
//GO(gst_byte_writer_put_int64_be,
//GO(gst_byte_writer_put_int64_le,
//GO(gst_byte_writer_put_int8,
-//GO(gst_byte_writer_put_string_utf16,
-//GO(gst_byte_writer_put_string_utf32,
-//GO(gst_byte_writer_put_string_utf8,
+GO(gst_byte_writer_put_string_utf16, iFpp)
+GO(gst_byte_writer_put_string_utf32, iFpp)
+GO(gst_byte_writer_put_string_utf8, iFpp)
//GO(gst_byte_writer_put_uint16_be,
//GO(gst_byte_writer_put_uint16_le,
//GO(gst_byte_writer_put_uint24_be,
@@ -291,16 +291,16 @@
//GO(gst_byte_writer_put_uint64_be,
//GO(gst_byte_writer_put_uint64_le,
//GO(gst_byte_writer_put_uint8,
-//GO(gst_byte_writer_reset,
-//GO(gst_byte_writer_reset_and_get_buffer,
-//GO(gst_byte_writer_reset_and_get_data,
+GO(gst_byte_writer_reset, vFp)
+GO(gst_byte_writer_reset_and_get_buffer, pFp)
+GO(gst_byte_writer_reset_and_get_data, pFp)
//GO(gst_collect_pads_add_pad,
-//GO(gst_collect_pads_available,
+GO(gst_collect_pads_available, uFp)
//GO(gst_collect_pads_clip_running_time,
//GO(gst_collect_pads_event_default,
//GO(gst_collect_pads_flush,
//GO(gst_collect_pads_get_type,
-//GO(gst_collect_pads_new,
+GO(gst_collect_pads_new, pFv)
//GO(gst_collect_pads_peek,
//GO(gst_collect_pads_pop,
//GO(gst_collect_pads_query_default,
@@ -311,7 +311,7 @@
//GO(gst_collect_pads_set_compare_function,
//GO(gst_collect_pads_set_event_function,
//GO(gst_collect_pads_set_flush_function,
-//GO(gst_collect_pads_set_flushing,
+GO(gst_collect_pads_set_flushing, vFpi)
//GO(gst_collect_pads_set_function,
//GO(gst_collect_pads_set_query_function,
//GO(gst_collect_pads_set_waiting,
@@ -319,58 +319,58 @@
//GO(gst_collect_pads_start,
//GO(gst_collect_pads_stop,
//GO(gst_collect_pads_take_buffer,
-//GO(gst_data_queue_drop_head,
+GO(gst_data_queue_drop_head, iFpL)
//GO(gst_data_queue_flush,
-//GO(gst_data_queue_get_level,
+GO(gst_data_queue_get_level, vFpp)
//GO(gst_data_queue_get_type,
-//GO(gst_data_queue_is_empty,
+GO(gst_data_queue_is_empty, iFp)
//GO(gst_data_queue_is_full,
//GO(gst_data_queue_limits_changed,
//GO(gst_data_queue_new,
-//GO(gst_data_queue_peek,
+GO(gst_data_queue_peek, iFpp)
//GO(gst_data_queue_pop,
//GO(gst_data_queue_push,
//GO(gst_data_queue_push_force,
-//GO(gst_data_queue_set_flushing,
+GO(gst_data_queue_set_flushing, vFpi)
//GO(gst_flow_combiner_add_pad,
//GO(gst_flow_combiner_clear,
//GO(gst_flow_combiner_free,
//GO(gst_flow_combiner_get_type,
-//GO(gst_flow_combiner_new,
-//GO(gst_flow_combiner_ref,
+GO(gst_flow_combiner_new, pFv)
+GO(gst_flow_combiner_ref, pFp)
//GO(gst_flow_combiner_remove_pad,
//GO(gst_flow_combiner_reset,
//GO(gst_flow_combiner_unref,
-//GO(gst_flow_combiner_update_flow,
+GO(gst_flow_combiner_update_flow, iFpi)
//GO(gst_flow_combiner_update_pad_flow,
-//GO(gst_push_src_get_type,
-//GO(gst_queue_array_clear,
+GO(gst_push_src_get_type, LFv)
+GO(gst_queue_array_clear, vFp)
//GO(gst_queue_array_drop_element,
-//GO(gst_queue_array_drop_struct,
+GO(gst_queue_array_drop_struct, iFpup)
//GO(gst_queue_array_find,
//GO(gst_queue_array_free,
-//GO(gst_queue_array_get_length,
-//GO(gst_queue_array_is_empty,
-//GO(gst_queue_array_new,
-//GO(gst_queue_array_new_for_struct,
+GO(gst_queue_array_get_length, uFp)
+GO(gst_queue_array_is_empty, iFp)
+GO(gst_queue_array_new, pFu)
+GO(gst_queue_array_new_for_struct, pFLu)
//GO(gst_queue_array_peek_head,
//GO(gst_queue_array_peek_head_struct,
//GO(gst_queue_array_peek_nth,
-//GO(gst_queue_array_peek_nth_struct,
+GO(gst_queue_array_peek_nth_struct, pFpu)
//GO(gst_queue_array_peek_tail,
-//GO(gst_queue_array_peek_tail_struct,
+GO(gst_queue_array_peek_tail_struct, pFp)
//GO(gst_queue_array_pop_head,
//GO(gst_queue_array_pop_head_struct,
//GO(gst_queue_array_pop_tail,
//GO(gst_queue_array_pop_tail_struct,
//GO(gst_queue_array_push_tail,
-//GO(gst_queue_array_push_tail_struct,
+GO(gst_queue_array_push_tail_struct, vFpp)
//GO(gst_queue_array_set_clear_func,
//GO(gst_type_find_helper,
//GO(gst_type_find_helper_for_buffer,
//GO(gst_type_find_helper_for_buffer_with_extension,
//GO(gst_type_find_helper_for_data,
-//GO(gst_type_find_helper_for_data_with_extension,
+GO(gst_type_find_helper_for_data_with_extension, pFppLpp)
//GO(gst_type_find_helper_for_extension,
//GO(gst_type_find_helper_get_range,
//GO(gst_type_find_helper_get_range_full,
diff --git a/src/wrapped/wrappedgstgl_private.h b/src/wrapped/wrappedgstgl_private.h
index 436fa1d..6ca18cc 100644
--- a/src/wrapped/wrappedgstgl_private.h
+++ b/src/wrapped/wrappedgstgl_private.h
@@ -6,7 +6,7 @@
//GO(gst_buffer_add_gl_sync_meta_full,
//GO(gst_buffer_pool_config_get_gl_allocation_params,
//GO(gst_buffer_pool_config_set_gl_allocation_params,
-//GO(gst_context_get_gl_display,
+GO(gst_context_get_gl_display, iFpp)
GO(gst_context_set_gl_display, vFpp)
//GO(gst_egl_get_error_string,
//GO(gst_egl_image_export_dmabuf,
@@ -23,9 +23,9 @@ GO(gst_context_set_gl_display, vFpp)
//GO(gst_gl_allocation_params_free_data,
//GO(gst_gl_allocation_params_get_type,
//GO(gst_gl_allocation_params_init,
-//GO(gst_gl_api_from_string,
+GO(gst_gl_api_from_string, uFp)
//GO(gst_gl_api_get_type,
-//GO(gst_gl_api_to_string,
+GO(gst_gl_api_to_string, pFu)
//GO(gst_gl_async_debug_free,
//GO(gst_gl_async_debug_freeze,
//GO(gst_gl_async_debug_init,
@@ -42,7 +42,7 @@ GO(gst_context_set_gl_display, vFpp)
//GO(gst_gl_base_memory_allocator_get_type,
//GO(gst_gl_base_memory_alloc_data,
//GO(gst_gl_base_memory_error_get_type,
-//GO(gst_gl_base_memory_error_quark,
+GO(gst_gl_base_memory_error_quark, uFv)
//GO(gst_gl_base_memory_get_type,
//GO(gst_gl_base_memory_init,
//GO(gst_gl_base_memory_init_once,
@@ -57,7 +57,7 @@ GO(gst_context_set_gl_display, vFpp)
//GO(gst_gl_buffer_pool_get_gl_allocation_params,
//GO(gst_gl_buffer_pool_get_type,
//GO(gst_gl_buffer_pool_new,
-//GO(gst_gl_check_extension,
+GO(gst_gl_check_extension, iFpp)
//GO(gst_gl_color_convert_decide_allocation,
//GO(gst_gl_color_convert_fixate_caps,
//GO(gst_gl_color_convert_get_type,
@@ -89,9 +89,9 @@ GO(gst_context_set_gl_display, vFpp)
//DATA(GST_GL_CONFIG_ATTRIB_STENCIL_SIZE_NAME,
//DATA(GST_GL_CONFIG_ATTRIB_SURFACE_TYPE_NAME,
//GO(gst_gl_config_caveat_get_type,
-//GO(gst_gl_config_caveat_to_string,
+GO(gst_gl_config_caveat_to_string, pFu)
//GO(gst_gl_config_surface_type_get_type,
-//GO(gst_gl_config_surface_type_to_string,
+GO(gst_gl_config_surface_type_to_string, pFu)
//GO(gst_gl_context_activate,
//GO(gst_gl_context_can_share,
//GO(gst_gl_context_check_feature,
@@ -100,15 +100,15 @@ GO(gst_context_set_gl_display, vFpp)
//GO(gst_gl_context_clear_framebuffer,
//GO(gst_gl_context_clear_shader,
//GO(gst_gl_context_create,
-//GO(gst_gl_context_default_get_proc_address,
+GO(gst_gl_context_default_get_proc_address, pFup)
//GO(gst_gl_context_destroy,
//GO(gst_gl_context_error_get_type,
//GO(gst_gl_context_error_quark,
//GO(gst_gl_context_fill_info,
//GO(gst_gl_context_get_config,
//GO(gst_gl_context_get_current,
-//GO(gst_gl_context_get_current_gl_api,
-//GO(gst_gl_context_get_current_gl_context,
+GO(gst_gl_context_get_current_gl_api, uFupp)
+GO(gst_gl_context_get_current_gl_context, LFu)
//GO(gst_gl_context_get_display,
//GO(gst_gl_context_get_gl_api,
//GO(gst_gl_context_get_gl_context,
@@ -116,7 +116,7 @@ GO(gst_context_set_gl_display, vFpp)
//GO(gst_gl_context_get_gl_platform_version,
//GO(gst_gl_context_get_gl_version,
//GO(gst_gl_context_get_proc_address,
-//GO(gst_gl_context_get_proc_address_with_platform,
+GO(gst_gl_context_get_proc_address_with_platform, pFuup)
//GO(gst_gl_context_get_thread,
//GO(gst_gl_context_get_type,
//GO(gst_gl_context_get_window,
@@ -163,7 +163,7 @@ GO(gst_gl_display_new_with_type, pFi)
//GO(gst_gl_display_x11_new,
//GO(gst_gl_display_x11_new_with_display,
//GO(gst_gl_element_propagate_display_context,
-//GO(gst_gl_ensure_element_data,
+GO(gst_gl_ensure_element_data, iFppp)
//GO(gst_gl_filter_add_rgba_pad_templates,
//GO(gst_gl_filter_draw_fullscreen_quad,
//GO(gst_gl_filter_filter_texture,
@@ -173,13 +173,13 @@ GO(gst_gl_display_new_with_type, pFi)
//GO(gst_gl_format_from_video_info,
//GO(gst_gl_format_get_type,
//GO(gst_gl_format_is_supported,
-//GO(gst_gl_format_type_from_sized_gl_format,
-//GO(gst_gl_format_type_n_bytes,
+GO(gst_gl_format_type_from_sized_gl_format, vFupp)
+GO(gst_gl_format_type_n_bytes, uFuu)
//GO(gst_gl_framebuffer_attach,
//GO(gst_gl_framebuffer_bind,
//GO(gst_gl_framebuffer_draw_to_texture,
-//GO(gst_gl_framebuffer_get_effective_dimensions,
-//GO(gst_gl_framebuffer_get_id,
+GO(gst_gl_framebuffer_get_effective_dimensions, vFppp)
+GO(gst_gl_framebuffer_get_id, uFp)
//GO(gst_gl_framebuffer_get_type,
//GO(gst_gl_framebuffer_new,
//GO(gst_gl_framebuffer_new_with_default_depth,
@@ -187,7 +187,7 @@ GO(gst_gl_display_new_with_type, pFi)
//GO(gst_gl_get_plane_data_size,
//GO(gst_gl_get_plane_start,
//GO(gst_gl_handle_context_query,
-//GO(gst_gl_handle_set_context,
+GO(gst_gl_handle_set_context, iFpppp)
//GO(gst_gl_insert_debug_marker,
//GO(gst_gl_memory_allocator_get_default,
//GO(gst_gl_memory_allocator_get_type,
@@ -215,21 +215,21 @@ GO(gst_gl_display_new_with_type, pFi)
//GO(gst_gl_memory_read_pixels,
//GO(gst_gl_memory_setup_buffer,
//GO(gst_gl_memory_texsubimage,
-//GO(gst_gl_multiply_matrix4,
+GO(gst_gl_multiply_matrix4, vFppp)
//GO(gst_gl_overlay_compositor_add_caps,
//GO(gst_gl_overlay_compositor_draw_overlays,
//GO(gst_gl_overlay_compositor_free_overlays,
-//GO(gst_gl_overlay_compositor_get_type,
+GO(gst_gl_overlay_compositor_get_type, LFv)
//GO(gst_gl_overlay_compositor_new,
//GO(gst_gl_overlay_compositor_upload_overlays,
-//GO(gst_gl_platform_from_string,
+GO(gst_gl_platform_from_string, uFp)
//GO(gst_gl_platform_get_type,
-//GO(gst_gl_platform_to_string,
+GO(gst_gl_platform_to_string, pFu)
//GO(gst_gl_query_counter,
//GO(gst_gl_query_end,
//GO(gst_gl_query_free,
//GO(gst_gl_query_init,
-//GO(gst_gl_query_local_gl_context,
+GO(gst_gl_query_local_gl_context, iFpup)
//GO(gst_gl_query_new,
//GO(gst_gl_query_result,
//GO(gst_gl_query_start,
@@ -244,42 +244,42 @@ GO(gst_gl_display_new_with_type, pFi)
//GO(gst_gl_renderbuffer_get_id,
//GO(gst_gl_renderbuffer_get_type,
//GO(gst_gl_renderbuffer_get_width,
-//GO(gst_gl_renderbuffer_init_once,
+GO(gst_gl_renderbuffer_init_once, vFv)
//GO(gst_gl_set_affine_transformation_meta_from_ndc,
//GO(gst_gl_shader_attach,
//GO(gst_gl_shader_attach_unlocked,
//GO(gst_gl_shader_bind_attribute_location,
-//GO(gst_gl_shader_bind_frag_data_location,
+GO(gst_gl_shader_bind_frag_data_location, vFpup)
//GO(gst_gl_shader_compile_attach_stage,
//GO(gst_gl_shader_detach,
//GO(gst_gl_shader_detach_unlocked,
-//GO(gst_gl_shader_get_attribute_location,
-//GO(gst_gl_shader_get_program_handle,
+GO(gst_gl_shader_get_attribute_location, iFpp)
+GO(gst_gl_shader_get_program_handle, iFp)
//GO(gst_gl_shader_get_type,
-//GO(gst_gl_shader_is_linked,
-//GO(gst_gl_shader_link,
+GO(gst_gl_shader_is_linked, iFp)
+GO(gst_gl_shader_link, iFpp)
//GO(gst_gl_shader_new,
//GO(gst_gl_shader_new_default,
//GO(gst_gl_shader_new_link_with_stages,
//GO(gst_gl_shader_new_with_stages,
//GO(gst_gl_shader_release,
//GO(gst_gl_shader_release_unlocked,
-//GO(gst_gl_shader_set_uniform_1f,
+GO(gst_gl_shader_set_uniform_1f, vFppf)
//GO(gst_gl_shader_set_uniform_1fv,
-//GO(gst_gl_shader_set_uniform_1i,
+GO(gst_gl_shader_set_uniform_1i, vFppi)
//GO(gst_gl_shader_set_uniform_1iv,
-//GO(gst_gl_shader_set_uniform_2f,
+GO(gst_gl_shader_set_uniform_2f, vFppff)
//GO(gst_gl_shader_set_uniform_2fv,
-//GO(gst_gl_shader_set_uniform_2i,
+GO(gst_gl_shader_set_uniform_2i, vFppii)
//GO(gst_gl_shader_set_uniform_2iv,
-//GO(gst_gl_shader_set_uniform_3f,
+GO(gst_gl_shader_set_uniform_3f, vFppfff)
//GO(gst_gl_shader_set_uniform_3fv,
-//GO(gst_gl_shader_set_uniform_3i,
+GO(gst_gl_shader_set_uniform_3i, vFppiii)
//GO(gst_gl_shader_set_uniform_3iv,
-//GO(gst_gl_shader_set_uniform_4f,
-//GO(gst_gl_shader_set_uniform_4fv,
-//GO(gst_gl_shader_set_uniform_4i,
-//GO(gst_gl_shader_set_uniform_4iv,
+GO(gst_gl_shader_set_uniform_4f, vFppffff)
+GO(gst_gl_shader_set_uniform_4fv, vFppup)
+GO(gst_gl_shader_set_uniform_4i, vFppiiii)
+GO(gst_gl_shader_set_uniform_4iv, vFppup)
//GO(gst_gl_shader_set_uniform_matrix_2fv,
//GO(gst_gl_shader_set_uniform_matrix_2x3fv,
//GO(gst_gl_shader_set_uniform_matrix_2x4fv,
@@ -288,7 +288,7 @@ GO(gst_gl_display_new_with_type, pFi)
//GO(gst_gl_shader_set_uniform_matrix_3x4fv,
//GO(gst_gl_shader_set_uniform_matrix_4fv,
//GO(gst_gl_shader_set_uniform_matrix_4x2fv,
-//GO(gst_gl_shader_set_uniform_matrix_4x3fv,
+GO(gst_gl_shader_set_uniform_matrix_4x3fv, vFppiip)
//DATA(gst_gl_shader_string_fragment_default,
//DATA(gst_gl_shader_string_fragment_external_oes_default,
//GO(gst_gl_shader_string_fragment_external_oes_get_default,
@@ -299,13 +299,13 @@ GO(gst_gl_display_new_with_type, pFi)
//DATA(gst_gl_shader_string_vertex_default,
//DATA(gst_gl_shader_string_vertex_mat4_texture_transform,
//DATA(gst_gl_shader_string_vertex_mat4_vertex_transform,
-//GO(gst_gl_shader_use,
+GO(gst_gl_shader_use, vFp)
//GO(gst_gl_sized_gl_format_from_gl_format_type,
//GO(gst_glsl_error_get_type,
//GO(gst_glsl_error_quark,
-//GO(gst_glsl_profile_from_string,
+GO(gst_glsl_profile_from_string, iFp)
//GO(gst_glsl_profile_get_type,
-//GO(gst_glsl_profile_to_string,
+GO(gst_glsl_profile_to_string, pFi)
//GO(gst_glsl_stage_compile,
//GO(gst_glsl_stage_get_handle,
//GO(gst_glsl_stage_get_profile,
@@ -318,12 +318,12 @@ GO(gst_gl_display_new_with_type, pFi)
//GO(gst_glsl_stage_new_with_string,
//GO(gst_glsl_stage_new_with_strings,
//GO(gst_glsl_stage_set_strings,
-//GO(gst_glsl_string_get_version_profile,
-//GO(gst_glsl_version_from_string,
+GO(gst_glsl_string_get_version_profile, iFppp)
+GO(gst_glsl_version_from_string, uFp)
//GO(gst_glsl_version_get_type,
//GO(gst_glsl_version_profile_from_string,
-//GO(gst_glsl_version_profile_to_string,
-//GO(gst_glsl_version_to_string,
+GO(gst_glsl_version_profile_to_string, pFui)
+GO(gst_glsl_version_to_string, pFu)
//GO(gst_gl_stereo_downmix_get_type,
//GO(gst_gl_stereo_downmix_mode_get_type,
//GO(gst_gl_sync_meta_api_get_type,
@@ -331,11 +331,11 @@ GO(gst_gl_display_new_with_type, pFi)
//GO(gst_gl_sync_meta_set_sync_point,
//GO(gst_gl_sync_meta_wait,
//GO(gst_gl_sync_meta_wait_cpu,
-//GO(gst_gl_texture_target_from_gl,
-//GO(gst_gl_texture_target_from_string,
+GO(gst_gl_texture_target_from_gl, uFu)
+GO(gst_gl_texture_target_from_string, uFp)
//GO(gst_gl_texture_target_get_type,
-//GO(gst_gl_texture_target_to_buffer_pool_option,
-//GO(gst_gl_texture_target_to_gl,
+GO(gst_gl_texture_target_to_buffer_pool_option, pFu)
+GO(gst_gl_texture_target_to_gl, uFu)
//GO(gst_gl_texture_target_to_string,
//GO(gst_gl_upload_get_caps,
//GO(gst_gl_upload_get_input_template_caps,
@@ -347,10 +347,10 @@ GO(gst_gl_display_new_with_type, pFi)
//GO(gst_gl_upload_set_caps,
//GO(gst_gl_upload_set_context,
//GO(gst_gl_upload_transform_caps,
-//GO(gst_gl_value_get_texture_target_mask,
-//GO(gst_gl_value_set_texture_target,
+GO(gst_gl_value_get_texture_target_mask, uFp)
+GO(gst_gl_value_set_texture_target, iFpu)
//GO(gst_gl_value_set_texture_target_from_mask,
-//GO(gst_gl_version_to_glsl_version,
+GO(gst_gl_version_to_glsl_version, uFuii)
//GO(gst_gl_video_allocation_params_copy_data,
//GO(gst_gl_video_allocation_params_free_data,
//GO(gst_gl_video_allocation_params_get_type,
diff --git a/src/wrapped/wrappedgstreamer.c b/src/wrapped/wrappedgstreamer.c
index 35f5610..8a27986 100644
--- a/src/wrapped/wrappedgstreamer.c
+++ b/src/wrapped/wrappedgstreamer.c
@@ -23,14 +23,21 @@ const char* gstreamerName = "libgstreamer-1.0.so.0";
#define LIBNAME gstreamer
typedef void* (*pFppA_t)(void*, void*, va_list);
+typedef void* (*pFv_t)();
typedef size_t (*LFv_t)();
typedef void* (*pFp_t)(void*);
+typedef void (*vFpp_t)(void*, void*);
+typedef int (*iFpp_t)(void*, void*);
#define ADDED_FUNCTIONS() \
GO(gst_object_get_type, LFv_t) \
GO(gst_allocator_get_type, LFv_t) \
+ GO(gst_task_pool_get_type, LFv_t) \
GO(gst_structure_new_valist, pFppA_t) \
- GO(gst_structure_new_empty, pFp_t)
+ GO(gst_structure_new_empty, pFp_t) \
+ GO(gst_caps_new_empty, pFv_t) \
+ GO(gst_caps_replace, iFpp_t) \
+ GO(gst_caps_append_structure, vFpp_t) \
#include "generated/wrappedgstreamertypes.h"
@@ -44,10 +51,10 @@ GO(3) \
// GDestroyFunc ...
#define GO(A) \
-static uintptr_t my_destroyfunc_fct_##A = 0; \
-static int my_destroyfunc_##A(void* a, void* b) \
-{ \
- return RunFunction(my_context, my_destroyfunc_fct_##A, 2, a, b);\
+static uintptr_t my_destroyfunc_fct_##A = 0; \
+static int my_destroyfunc_##A(void* a, void* b) \
+{ \
+ return RunFunctionFmt(my_destroyfunc_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -68,10 +75,10 @@ static void* findDestroyFct(void* fct)
}
//GstPadActivateModeFunction
#define GO(A) \
-static uintptr_t my_GstPadActivateModeFunction_fct_##A = 0; \
-static int my_GstPadActivateModeFunction_##A(void* a, void* b, int c, int d) \
-{ \
- return (int)RunFunction(my_context, my_GstPadActivateModeFunction_fct_##A, 4, a, b, c, d); \
+static uintptr_t my_GstPadActivateModeFunction_fct_##A = 0; \
+static int my_GstPadActivateModeFunction_##A(void* a, void* b, int c, int d) \
+{ \
+ return (int)RunFunctionFmt(my_GstPadActivateModeFunction_fct_##A, "ppii", a, b, c, d); \
}
SUPER()
#undef GO
@@ -91,10 +98,10 @@ static void* findGstPadActivateModeFunctionFct(void* fct)
}
//GstPadQueryFunction
#define GO(A) \
-static uintptr_t my_GstPadQueryFunction_fct_##A = 0; \
-static int my_GstPadQueryFunction_##A(void* a, void* b, void* c) \
-{ \
- return (int)RunFunction(my_context, my_GstPadQueryFunction_fct_##A, 3, a, b, c); \
+static uintptr_t my_GstPadQueryFunction_fct_##A = 0; \
+static int my_GstPadQueryFunction_##A(void* a, void* b, void* c) \
+{ \
+ return (int)RunFunctionFmt(my_GstPadQueryFunction_fct_##A, "ppp", a, b, c); \
}
SUPER()
#undef GO
@@ -114,10 +121,10 @@ static void* findGstPadQueryFunctionFct(void* fct)
}
//GstPadGetRangeFunction
#define GO(A) \
-static uintptr_t my_GstPadGetRangeFunction_fct_##A = 0; \
-static int my_GstPadGetRangeFunction_##A(void* a, void* b, uint64_t c, uint32_t d, void* e) \
-{ \
- return (int)RunFunction(my_context, my_GstPadGetRangeFunction_fct_##A, 5, a, b, c, d, e); \
+static uintptr_t my_GstPadGetRangeFunction_fct_##A = 0; \
+static int my_GstPadGetRangeFunction_##A(void* a, void* b, uint64_t c, uint32_t d, void* e) \
+{ \
+ return (int)RunFunctionFmt(my_GstPadGetRangeFunction_fct_##A, "ppUup", a, b, c, d, e); \
}
SUPER()
#undef GO
@@ -137,10 +144,10 @@ static void* findGstPadGetRangeFunctionFct(void* fct)
}
//GstPadChainFunction
#define GO(A) \
-static uintptr_t my_GstPadChainFunction_fct_##A = 0; \
-static int my_GstPadChainFunction_##A(void* a, void* b, void* c) \
-{ \
- return (int)RunFunction(my_context, my_GstPadChainFunction_fct_##A, 3, a, b, c); \
+static uintptr_t my_GstPadChainFunction_fct_##A = 0; \
+static int my_GstPadChainFunction_##A(void* a, void* b, void* c) \
+{ \
+ return (int)RunFunctionFmt(my_GstPadChainFunction_fct_##A, "ppp", a, b, c); \
}
SUPER()
#undef GO
@@ -160,10 +167,10 @@ static void* findGstPadChainFunctionFct(void* fct)
}
//GstPadEventFunction
#define GO(A) \
-static uintptr_t my_GstPadEventFunction_fct_##A = 0; \
-static int my_GstPadEventFunction_##A(void* a, void* b, void* c) \
-{ \
- return (int)RunFunction(my_context, my_GstPadEventFunction_fct_##A, 3, a, b, c); \
+static uintptr_t my_GstPadEventFunction_fct_##A = 0; \
+static int my_GstPadEventFunction_##A(void* a, void* b, void* c) \
+{ \
+ return (int)RunFunctionFmt(my_GstPadEventFunction_fct_##A, "ppp", a, b, c); \
}
SUPER()
#undef GO
@@ -181,10 +188,10 @@ static void* findGstPadEventFunctionFct(void* fct)
}
//GstBusSyncHandler
#define GO(A) \
-static uintptr_t my_GstBusSyncHandler_fct_##A = 0; \
-static int my_GstBusSyncHandler_##A(void* a, void* b, void* c) \
-{ \
- return (int)RunFunction(my_context, my_GstBusSyncHandler_fct_##A, 3, a, b, c); \
+static uintptr_t my_GstBusSyncHandler_fct_##A = 0; \
+static int my_GstBusSyncHandler_##A(void* a, void* b, void* c) \
+{ \
+ return (int)RunFunctionFmt(my_GstBusSyncHandler_fct_##A, "ppp", a, b, c); \
}
SUPER()
#undef GO
@@ -200,6 +207,51 @@ static void* findGstBusSyncHandlerFct(void* fct)
printf_log(LOG_NONE, "Warning, no more slot for gstreamer GstBusSyncHandler callback\n");
return NULL;
}
+
+//GstPluginFeatureFilter
+#define GO(A) \
+static uintptr_t my_GstPluginFeatureFilter_fct_##A = 0; \
+static int my_GstPluginFeatureFilter_##A(void* a, void* b) \
+{ \
+ return (int)RunFunctionFmt(my_GstPluginFeatureFilter_fct_##A, "pp", a, b); \
+}
+SUPER()
+#undef GO
+static void* findGstPluginFeatureFilterFct(void* fct)
+{
+ if(!fct) return fct;
+ #define GO(A) if(my_GstPluginFeatureFilter_fct_##A == (uintptr_t)fct) return my_GstPluginFeatureFilter_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_GstPluginFeatureFilter_fct_##A == 0) {my_GstPluginFeatureFilter_fct_##A = (uintptr_t)fct; return my_GstPluginFeatureFilter_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for gstreamer GstPluginFeatureFilter callback\n");
+ return NULL;
+}
+
+//GstCapsFilterMapFunc
+#define GO(A) \
+static uintptr_t my_GstCapsFilterMapFunc_fct_##A = 0; \
+static int my_GstCapsFilterMapFunc_##A(void* a, void* b, void* c) \
+{ \
+ return (int)RunFunctionFmt(my_GstCapsFilterMapFunc_fct_##A, "ppp", a, b, c); \
+}
+SUPER()
+#undef GO
+static void* findGstCapsFilterMapFuncFct(void* fct)
+{
+ if(!fct) return fct;
+ #define GO(A) if(my_GstCapsFilterMapFunc_fct_##A == (uintptr_t)fct) return my_GstCapsFilterMapFunc_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_GstCapsFilterMapFunc_fct_##A == 0) {my_GstCapsFilterMapFunc_fct_##A = (uintptr_t)fct; return my_GstCapsFilterMapFunc_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for gstreamer GstCapsFilterMapFunc callback\n");
+ return NULL;
+}
+
#undef SUPER
EXPORT void my_gst_caps_set_simple(x64emu_t* emu, void* caps, void* field, void* b) {
@@ -303,12 +355,41 @@ EXPORT void* my_gst_buffer_new_wrapped_full(x64emu_t* emu, uint32_t f, void* dat
EXPORT void* my_gst_structure_new(x64emu_t* emu, void* name, void* first, uint64_t* b)
{
- if(!first)
+ if(!first)
return my->gst_structure_new_empty(name);
CREATE_VALIST_FROM_VAARG(b, emu->scratch, 2);
return my->gst_structure_new_valist(name, first, VARARGS);
}
+EXPORT void my_gst_mini_object_set_qdata(x64emu_t* emu, void* object, void* quark, void* data, void* d)
+{
+ my->gst_mini_object_set_qdata(object, quark, data, findDestroyFct(d));
+}
+
+EXPORT void* my_gst_caps_new_simple(x64emu_t* emu, void* type, void* name, void* b)
+{
+ // need to unroll the function here, there is no direct VA equivalent
+ CREATE_VALIST_FROM_VAARG(b, emu->scratch, 2);
+ void* caps = my->gst_caps_new_empty();
+ void* structure = my->gst_structure_new_valist(type, name, VARARGS);
+ if (structure)
+ my->gst_caps_append_structure(caps, structure);
+ else
+ my->gst_caps_replace(&caps, NULL);
+
+ return caps;
+}
+
+EXPORT void* my_gst_registry_feature_filter(x64emu_t* emu, void* reg, void* filter, int first, void* data)
+{
+ return my->gst_registry_feature_filter(reg, findGstPluginFeatureFilterFct(filter), first, data);
+}
+
+EXPORT int my_gst_caps_foreach(x64emu_t* emu, void* caps, void* f, void* data)
+{
+ return my->gst_caps_foreach(caps, findGstCapsFilterMapFuncFct(f), data);
+}
+
#define PRE_INIT \
if(box64_nogtk) \
return -1;
@@ -317,6 +398,7 @@ EXPORT void* my_gst_structure_new(x64emu_t* emu, void* name, void* first, uint64
getMy(lib); \
SetGstObjectID(my->gst_object_get_type()); \
SetGstAllocatorID(my->gst_allocator_get_type()); \
+ SetGstTaskPoolID(my->gst_task_pool_get_type()); \
setNeededLibs(lib, 1, "libgtk-3.so.0");
#define CUSTOM_FINI \
diff --git a/src/wrapped/wrappedgstreamer_private.h b/src/wrapped/wrappedgstreamer_private.h
index 3e48153..696de89 100644
--- a/src/wrapped/wrappedgstreamer_private.h
+++ b/src/wrapped/wrappedgstreamer_private.h
@@ -2,7 +2,7 @@
#error meh!
#endif
-//GO(gst_allocation_params_copy,
+GO(gst_allocation_params_copy, pFp)
//GO(gst_allocation_params_free,
//GO(gst_allocation_params_get_type,
//GO(gst_allocation_params_init,
@@ -25,10 +25,10 @@ GO(gst_bin_add, iFpp)
//GOM(gst_bin_add_many, vFppV)
GO(gst_bin_find_unlinked_pad, pFpi)
GO(gst_bin_flags_get_type, pFv)
-GO(gst_bin_get_by_interface, pFpp)
+GO(gst_bin_get_by_interface, pFpL)
GO(gst_bin_get_by_name, pFpp)
GO(gst_bin_get_by_name_recurse_up, pFpp)
-GO(gst_bin_get_suppressed_flags, iFp)
+GO(gst_bin_get_suppressed_flags, uFp)
GO(gst_bin_get_type, pFv)
GO(gst_bin_iterate_all_by_element_factory_name, pFpp)
GO(gst_bin_iterate_all_by_interface, pFpp)
@@ -41,7 +41,7 @@ GO(gst_bin_new, pFp)
GO(gst_bin_recalculate_latency, iFp)
GO(gst_bin_remove, iFpp)
//GOM(gst_bin_remove_many, iFEppV)
-GO(gst_bin_set_suppressed_flags, vFpi)
+GO(gst_bin_set_suppressed_flags, vFpu)
GO(gst_bin_sync_children_states, iFp)
GO(gst_bitmask_get_type, pFv)
DATAB(_gst_bitmask_type, sizeof(void*))
@@ -82,21 +82,21 @@ GO(gst_buffer_is_all_memory_writable, iFp)
GO(gst_buffer_is_memory_range_writable, iFpui)
GO(gst_buffer_iterate_meta, pFpp)
GO(gst_buffer_iterate_meta_filtered, pFppp)
-//GO(gst_buffer_list_calculate_size,
+GO(gst_buffer_list_calculate_size, LFp)
//GO(gst_buffer_list_copy,
-//GO(gst_buffer_list_copy_deep,
+GO(gst_buffer_list_copy_deep, pFp)
//GO(gst_buffer_list_foreach,
//GO(gst_buffer_list_get,
//GO(gst_buffer_list_get_type,
//GO(gst_buffer_list_get_writable,
//GO(gst_buffer_list_insert,
-//GO(gst_buffer_list_length,
-//GO(gst_buffer_list_new,
-//GO(gst_buffer_list_new_sized,
-//GO(gst_buffer_list_ref,
-//GO(gst_buffer_list_remove,
+GO(gst_buffer_list_length, uFp)
+GO(gst_buffer_list_new, pFv)
+GO(gst_buffer_list_new_sized, pFu)
+GO(gst_buffer_list_ref, pFp)
+GO(gst_buffer_list_remove, vFpuu)
//GO(gst_buffer_list_replace,
-//GO(gst_buffer_list_take,
+GO(gst_buffer_list_take, iFpp)
//DATAB(_gst_buffer_list_type,
//GO(gst_buffer_list_unref,
GO(gst_buffer_map, iFppi)
@@ -110,27 +110,27 @@ GO(gst_buffer_new_wrapped_bytes, pFp)
GOM(gst_buffer_new_wrapped_full, pFEiplllpp)
GO(gst_buffer_n_memory, uFp)
GO(gst_buffer_peek_memory, pFpu)
-//GO(gst_buffer_pool_acquire_buffer,
+GO(gst_buffer_pool_acquire_buffer, iFppp)
//GO(gst_buffer_pool_acquire_flags_get_type,
GO(gst_buffer_pool_config_add_option, vFpp)
-//GO(gst_buffer_pool_config_get_allocator,
-//GO(gst_buffer_pool_config_get_option,
-//GO(gst_buffer_pool_config_get_params,
-//GO(gst_buffer_pool_config_has_option,
-//GO(gst_buffer_pool_config_n_options,
+GO(gst_buffer_pool_config_get_allocator, iFppp)
+GO(gst_buffer_pool_config_get_option, pFpu)
+GO(gst_buffer_pool_config_get_params, iFppppp)
+GO(gst_buffer_pool_config_has_option, iFpp)
+GO(gst_buffer_pool_config_n_options, uFp)
GO(gst_buffer_pool_config_set_allocator, vFppp)
GO(gst_buffer_pool_config_set_params, vFppuuu)
//GO(gst_buffer_pool_config_validate_params,
GO(gst_buffer_pool_get_config, pFp)
-//GO(gst_buffer_pool_get_options,
+GO(gst_buffer_pool_get_options, pFp)
//GO(gst_buffer_pool_get_type,
-//GO(gst_buffer_pool_has_option,
-//GO(gst_buffer_pool_is_active,
-//GO(gst_buffer_pool_new,
+GO(gst_buffer_pool_has_option, iFpp)
+GO(gst_buffer_pool_is_active, iFp)
+GO(gst_buffer_pool_new, pFv)
//GO(gst_buffer_pool_release_buffer,
GO(gst_buffer_pool_set_active, iFpi)
GO(gst_buffer_pool_set_config, iFpp)
-//GO(gst_buffer_pool_set_flushing,
+GO(gst_buffer_pool_set_flushing, vFpi)
GO(gst_buffer_prepend_memory, vFpp)
GO(gst_buffer_ref, pFp)
GO(gst_buffer_remove_all_memory, vFp)
@@ -175,7 +175,7 @@ GO(gst_bus_sync_reply_get_type, pFv)
GO(gst_bus_sync_signal_handler, iFppp)
GO(gst_bus_timed_pop, pFpU)
GO(gst_bus_timed_pop_filtered, pFpUi)
-//GO(gst_calculate_linear_regression,
+GO(gst_calculate_linear_regression, iFppuppppp)
//DATAB(_gst_caps_any,
GO(gst_caps_append, vFpp)
GO(gst_caps_append_structure, vFpp)
@@ -186,33 +186,33 @@ GO(gst_caps_copy_nth, pFpu)
//GOM(gst_caps_features_add, vFEpBp)
//GO(gst_caps_features_add_id,
//DATAB(_gst_caps_features_any,
-//GO(gst_caps_features_contains,
-//GO(gst_caps_features_contains_id,
-//GO(gst_caps_features_copy,
+GO(gst_caps_features_contains, iFpp)
+GO(gst_caps_features_contains_id, iFpu)
+GO(gst_caps_features_copy, pFp)
//GO(gst_caps_features_free,
-//GO(gst_caps_features_from_string,
-//GO(gst_caps_features_get_nth,
-//GO(gst_caps_features_get_nth_id,
-//GO(gst_caps_features_get_size,
+GO(gst_caps_features_from_string, pFp)
+GO(gst_caps_features_get_nth, pFpu)
+GO(gst_caps_features_get_nth_id, uFpu)
+GO(gst_caps_features_get_size, uFp)
//GO(gst_caps_features_get_type,
-//GO(gst_caps_features_is_any,
-//GO(gst_caps_features_is_equal,
+GO(gst_caps_features_is_any, iFp)
+GO(gst_caps_features_is_equal, iFpp)
//DATAB(_gst_caps_features_memory_system_memory,
//GO(gst_caps_features_new,
-//GO(gst_caps_features_new_any,
+GO(gst_caps_features_new_any, pFv)
//GO(gst_caps_features_new_empty,
//GO(gst_caps_features_new_id,
-//GO(gst_caps_features_new_id_valist,
-//GO(gst_caps_features_new_valist,
-//GO(gst_caps_features_remove,
-//GO(gst_caps_features_remove_id,
-//GO(gst_caps_features_set_parent_refcount,
-//GO(gst_caps_features_to_string,
+GO(gst_caps_features_new_id_valist, pFup)
+GO(gst_caps_features_new_valist, pFpp)
+GO(gst_caps_features_remove, vFpp)
+GO(gst_caps_features_remove_id, vFpu)
+GO(gst_caps_features_set_parent_refcount, iFpp)
+GO(gst_caps_features_to_string, pFp)
//DATAB(_gst_caps_features_type,
//GO(gst_caps_filter_and_map_in_place,
GO(gst_caps_fixate, pFp)
GO(gst_caps_flags_get_type, pFv)
-//GOM(gst_caps_foreach, iFEpBp)
+GOM(gst_caps_foreach, iFEppp)
GO(gst_caps_from_string, pFp)
GO(gst_caps_get_features, pFpu)
GO(gst_caps_get_size, uFp)
@@ -240,7 +240,7 @@ GO(gst_caps_new_empty, pFv)
GO(gst_caps_new_empty_simple, pFp)
//GOM(gst_caps_new_full, pFEpV)
//GOM(gst_caps_new_full_valist, pFEpA)
-//GOM(gst_caps_new_simple, pFppV)
+GOM(gst_caps_new_simple, pFEppV)
//DATAB(_gst_caps_none,
GO(gst_caps_normalize, pFp)
GO(gst_caps_ref, pFp)
@@ -257,7 +257,7 @@ GO(gst_caps_subtract, pFpp)
GO(gst_caps_take, iFpp)
GO(gst_caps_to_string, pFp)
GO(gst_caps_truncate, pFp)
-//DATAB(_gst_caps_type,
+DATAB(_gst_caps_type, sizeof(void*))
GO(gst_caps_unref, vFp)
//DATAB(GST_CAT_BUFFER,
//DATAB(GST_CAT_BUFFER_LIST,
@@ -266,7 +266,7 @@ GO(gst_caps_unref, vFp)
//DATAB(GST_CAT_CAPS,
//DATAB(GST_CAT_CLOCK,
//DATAB(GST_CAT_CONTEXT,
-//DATAB(GST_CAT_DEFAULT,
+DATAB(GST_CAT_DEFAULT, sizeof(void*))
//DATAB(GST_CAT_ELEMENT_PADS,
//DATAB(GST_CAT_ERROR_SYSTEM,
//DATAB(GST_CAT_EVENT,
@@ -292,85 +292,85 @@ GO(gst_caps_unref, vFp)
//DATAB(GST_CAT_SIGNAL,
//DATAB(GST_CAT_STATES,
//GO(gst_child_proxy_child_added,
-//GO(gst_child_proxy_child_removed,
+GO(gst_child_proxy_child_removed, vFppp)
//GO(gst_child_proxy_get,
-//GO(gst_child_proxy_get_child_by_index,
+GO(gst_child_proxy_get_child_by_index, pFpu)
//GO(gst_child_proxy_get_child_by_name,
-//GO(gst_child_proxy_get_children_count,
-//GO(gst_child_proxy_get_property,
+GO(gst_child_proxy_get_children_count, uFp)
+GO(gst_child_proxy_get_property, vFppp)
//GO(gst_child_proxy_get_type,
//GO(gst_child_proxy_get_valist,
-//GO(gst_child_proxy_lookup,
+GO(gst_child_proxy_lookup, iFpppp)
//GO(gst_child_proxy_set,
-//GO(gst_child_proxy_set_property,
+GO(gst_child_proxy_set_property, vFppp)
//GO(gst_child_proxy_set_valist,
//GO(gst_clear_buffer,
//GO(gst_clear_buffer_list,
GO(gst_clear_caps, vFp)
GO(gst_clear_event, vFp)
GO(gst_clear_message, vFp)
-//GO(gst_clear_mini_object,
+GO(gst_clear_mini_object, vFp)
//GO(gst_clear_object,
GO(gst_clear_query, vFp)
GO(gst_clear_structure, vFp)
//GO(gst_clear_tag_list,
//GO(gst_clear_uri,
-//GO(gst_clock_add_observation,
-//GO(gst_clock_add_observation_unapplied,
+GO(gst_clock_add_observation, iFpLLp)
+GO(gst_clock_add_observation_unapplied, iFpLLppppp)
//GO(gst_clock_adjust_unlocked,
//GO(gst_clock_adjust_with_calibration,
//GO(gst_clock_entry_type_get_type,
//GO(gst_clock_flags_get_type,
-//GO(gst_clock_get_calibration,
-//GO(gst_clock_get_internal_time,
-//GO(gst_clock_get_master,
+GO(gst_clock_get_calibration, vFppppp)
+GO(gst_clock_get_internal_time, LFp)
+GO(gst_clock_get_master, pFp)
//GO(gst_clock_get_resolution,
//GO(gst_clock_get_time,
//GO(gst_clock_get_timeout,
//GO(gst_clock_get_type,
//GO(gst_clock_id_compare_func,
-//GO(gst_clock_id_get_clock,
-//GO(gst_clock_id_get_time,
-//GO(gst_clock_id_ref,
+GO(gst_clock_id_get_clock, pFp)
+GO(gst_clock_id_get_time, LFp)
+GO(gst_clock_id_ref, pFp)
//GO(gst_clock_id_unref,
-//GO(gst_clock_id_unschedule,
-//GO(gst_clock_id_uses_clock,
-//GO(gst_clock_id_wait,
+GO(gst_clock_id_unschedule, vFp)
+GO(gst_clock_id_uses_clock, iFpp)
+GO(gst_clock_id_wait, uFpp)
//GO(gst_clock_id_wait_async,
-//GO(gst_clock_is_synced,
-//GO(gst_clock_new_periodic_id,
-//GO(gst_clock_new_single_shot_id,
-//GO(gst_clock_periodic_id_reinit,
+GO(gst_clock_is_synced, iFp)
+GO(gst_clock_new_periodic_id, pFpLL)
+GO(gst_clock_new_single_shot_id, pFpL)
+GO(gst_clock_periodic_id_reinit, iFppLL)
//GO(gst_clock_return_get_type,
-//GO(gst_clock_set_calibration,
-//GO(gst_clock_set_master,
+GO(gst_clock_set_calibration, vFpLLLL)
+GO(gst_clock_set_master, iFpp)
//GO(gst_clock_set_resolution,
-//GO(gst_clock_set_synced,
-//GO(gst_clock_set_timeout,
-//GO(gst_clock_single_shot_id_reinit,
+GO(gst_clock_set_synced, vFpi)
+GO(gst_clock_set_timeout, vFpL)
+GO(gst_clock_single_shot_id_reinit, iFppL)
//GO(gst_clock_type_get_type,
-//GO(gst_clock_unadjust_unlocked,
-//GO(gst_clock_unadjust_with_calibration,
-//GO(gst_clock_wait_for_sync,
-//GO(gst_context_copy,
-//GO(gst_context_get_context_type,
-//GO(gst_context_get_structure,
+GO(gst_clock_unadjust_unlocked, LFpL)
+GO(gst_clock_unadjust_with_calibration, LFpLLLLL)
+GO(gst_clock_wait_for_sync, iFpL)
+GO(gst_context_copy, pFp)
+GO(gst_context_get_context_type, pFp)
+GO(gst_context_get_structure, pFp)
//GO(gst_context_get_type,
-//GO(gst_context_has_context_type,
-//GO(gst_context_is_persistent,
+GO(gst_context_has_context_type, iFpp)
+GO(gst_context_is_persistent, iFp)
GO(gst_context_new, pFpi)
-//GO(gst_context_ref,
-//GO(gst_context_replace,
+GO(gst_context_ref, pFp)
+GO(gst_context_replace, iFpp)
//DATAB(_gst_context_type,
//GO(gst_context_unref,
-//GO(gst_context_writable_structure,
-//GO(gst_control_binding_get_g_value_array,
+GO(gst_context_writable_structure, pFp)
+GO(gst_control_binding_get_g_value_array, iFpLLup)
//GO(gst_control_binding_get_type,
-//GO(gst_control_binding_get_value,
-//GO(gst_control_binding_get_value_array,
-//GO(gst_control_binding_is_disabled,
-//GO(gst_control_binding_set_disabled,
-//GO(gst_control_binding_sync_values,
+GO(gst_control_binding_get_value, pFpL)
+GO(gst_control_binding_get_value_array, iFpLLup)
+GO(gst_control_binding_is_disabled, iFp)
+GO(gst_control_binding_set_disabled, vFpi)
+GO(gst_control_binding_sync_values, iFppLL)
//GO(gst_control_source_get_type,
//GO(gst_control_source_get_value,
//GO(gst_control_source_get_value_array,
@@ -378,68 +378,68 @@ GO(gst_context_new, pFpi)
//GO(gst_core_error_quark,
//GO(gst_date_time_get_day,
//GO(gst_date_time_get_hour,
-//GO(gst_date_time_get_microsecond,
+GO(gst_date_time_get_microsecond, iFp)
//GO(gst_date_time_get_minute,
//GO(gst_date_time_get_month,
//GO(gst_date_time_get_second,
-//GO(gst_date_time_get_time_zone_offset,
+GO(gst_date_time_get_time_zone_offset, fFp)
//GO(gst_date_time_get_type,
//GO(gst_date_time_get_year,
//GO(gst_date_time_has_day,
//GO(gst_date_time_has_month,
-//GO(gst_date_time_has_second,
+GO(gst_date_time_has_second, iFp)
//GO(gst_date_time_has_time,
//GO(gst_date_time_has_year,
-//GO(gst_date_time_new,
-//GO(gst_date_time_new_from_g_date_time,
-//GO(gst_date_time_new_from_iso8601_string,
+GO(gst_date_time_new, pFfiiiiid)
+GO(gst_date_time_new_from_g_date_time, pFp)
+GO(gst_date_time_new_from_iso8601_string, pFp)
//GO(gst_date_time_new_from_unix_epoch_local_time,
//GO(gst_date_time_new_from_unix_epoch_local_time_usecs,
//GO(gst_date_time_new_from_unix_epoch_utc,
-//GO(gst_date_time_new_from_unix_epoch_utc_usecs,
-//GO(gst_date_time_new_local_time,
+GO(gst_date_time_new_from_unix_epoch_utc_usecs, pFl)
+GO(gst_date_time_new_local_time, pFiiiiid)
//GO(gst_date_time_new_now_local_time,
-//GO(gst_date_time_new_now_utc,
-//GO(gst_date_time_new_y,
-//GO(gst_date_time_new_ym,
-//GO(gst_date_time_new_ymd,
-//GO(gst_date_time_ref,
-//GO(gst_date_time_to_g_date_time,
-//GO(gst_date_time_to_iso8601_string,
-//DATAB(_gst_date_time_type,
+GO(gst_date_time_new_now_utc, pFv)
+GO(gst_date_time_new_y, pFi)
+GO(gst_date_time_new_ym, pFii)
+GO(gst_date_time_new_ymd, pFiii)
+GO(gst_date_time_ref, pFp)
+GO(gst_date_time_to_g_date_time, pFp)
+GO(gst_date_time_to_iso8601_string, pFp)
+DATAB(_gst_date_time_type, sizeof(void*))
//GO(gst_date_time_unref,
//GO(gst_debug_add_log_function,
-//GO(gst_debug_add_ring_buffer_logger,
-//GO(gst_debug_bin_to_dot_data,
+GO(gst_debug_add_ring_buffer_logger, vFuu)
+GO(gst_debug_bin_to_dot_data, pFpi)
//GO(gst_debug_bin_to_dot_file,
-//GO(gst_debug_bin_to_dot_file_with_ts,
+GO(gst_debug_bin_to_dot_file_with_ts, vFpip)
//GO(gst_debug_category_free,
-//GO(gst_debug_category_get_color,
-//GO(gst_debug_category_get_description,
+GO(gst_debug_category_get_color, uFp)
+GO(gst_debug_category_get_description, pFp)
//GO(gst_debug_category_get_name,
-GO(gst_debug_category_get_threshold, iFp)
-GO(_gst_debug_category_new, pFppp)
-//GO(gst_debug_category_reset_threshold,
-//GO(gst_debug_category_set_threshold,
+GO(gst_debug_category_get_threshold, uFp)
+GO(_gst_debug_category_new, pFpup)
+GO(gst_debug_category_reset_threshold, vFp)
+GO(gst_debug_category_set_threshold, vFpu)
//GO(gst_debug_color_flags_get_type,
//GO(gst_debug_color_mode_get_type,
-//GO(gst_debug_construct_term_color,
-//GO(gst_debug_construct_win_color,
-//GO(_gst_debug_dump_mem,
+GO(gst_debug_construct_term_color, pFu)
+GO(gst_debug_construct_win_color, iFu)
+GO(_gst_debug_dump_mem, vFpppipppu)
//DATAB(_gst_debug_enabled,
-//GO(gst_debug_get_all_categories,
-//GO(_gst_debug_get_category,
-//GO(gst_debug_get_color_mode,
-//GO(gst_debug_get_default_threshold,
-//GO(gst_debug_get_stack_trace,
+GO(gst_debug_get_all_categories, pFv)
+GO(_gst_debug_get_category, pFp)
+GO(gst_debug_get_color_mode, uFv)
+GO(gst_debug_get_default_threshold, uFv)
+GO(gst_debug_get_stack_trace, pFu)
//GO(gst_debug_graph_details_get_type,
//GO(gst_debug_is_active,
//GO(gst_debug_is_colored,
-//GO(gst_debug_level_get_name,
+GO(gst_debug_level_get_name, pFu)
//GO(gst_debug_level_get_type,
GOM(gst_debug_log, vFEpippippV)
-//GO(gst_debug_log_default,
-//GO(gst_debug_log_get_line,
+GO(gst_debug_log_default, vFpuppippp)
+GO(gst_debug_log_get_line, pFpuppipp)
GOM(gst_debug_log_valist, vFEpippippA)
//GO(gst_debug_message_get,
DATAB(_gst_debug_min, sizeof(int))
@@ -447,35 +447,35 @@ DATAB(_gst_debug_min, sizeof(int))
//GO(gst_debug_print_stack_trace,
//GO(_gst_debug_register_funcptr,
//GO(gst_debug_remove_log_function,
-//GO(gst_debug_remove_log_function_by_data,
+GO(gst_debug_remove_log_function_by_data, uFp)
//GO(gst_debug_remove_ring_buffer_logger,
-//GO(gst_debug_ring_buffer_logger_get_logs,
+GO(gst_debug_ring_buffer_logger_get_logs, pFv)
//GO(gst_debug_set_active,
//GO(gst_debug_set_colored,
-//GO(gst_debug_set_color_mode,
+GO(gst_debug_set_color_mode, vFu)
//GO(gst_debug_set_color_mode_from_string,
-//GO(gst_debug_set_default_threshold,
-//GO(gst_debug_set_threshold_for_name,
-//GO(gst_debug_set_threshold_from_string,
-//GO(gst_debug_unset_threshold_for_name,
+GO(gst_debug_set_default_threshold, vFu)
+GO(gst_debug_set_threshold_for_name, vFpu)
+GO(gst_debug_set_threshold_from_string, vFpi)
+GO(gst_debug_unset_threshold_for_name, vFp)
GO(gst_deinit, vFv)
-//GO(gst_device_create_element,
+GO(gst_device_create_element, pFpp)
//GO(gst_device_get_caps,
-//GO(gst_device_get_device_class,
+GO(gst_device_get_device_class, pFp)
//GO(gst_device_get_display_name,
-//GO(gst_device_get_properties,
+GO(gst_device_get_properties, pFp)
//GO(gst_device_get_type,
-//GO(gst_device_has_classes,
-//GO(gst_device_has_classesv,
+GO(gst_device_has_classes, iFpp)
+GO(gst_device_has_classesv, iFpp)
//GO(gst_device_monitor_add_filter,
-//GO(gst_device_monitor_get_bus,
-//GO(gst_device_monitor_get_devices,
-//GO(gst_device_monitor_get_providers,
-//GO(gst_device_monitor_get_show_all_devices,
+GO(gst_device_monitor_get_bus, pFp)
+GO(gst_device_monitor_get_devices, pFp)
+GO(gst_device_monitor_get_providers, pFp)
+GO(gst_device_monitor_get_show_all_devices, iFp)
//GO(gst_device_monitor_get_type,
-//GO(gst_device_monitor_new,
-//GO(gst_device_monitor_remove_filter,
-//GO(gst_device_monitor_set_show_all_devices,
+GO(gst_device_monitor_new, pFv)
+GO(gst_device_monitor_remove_filter, iFpu)
+GO(gst_device_monitor_set_show_all_devices, vFpi)
//GO(gst_device_monitor_start,
//GO(gst_device_monitor_stop,
//GO(gst_device_provider_can_monitor,
@@ -485,42 +485,42 @@ GO(gst_deinit, vFv)
//GO(gst_device_provider_class_set_metadata,
//GO(gst_device_provider_class_set_static_metadata,
//GO(gst_device_provider_device_add,
-//GO(gst_device_provider_device_changed,
-//GO(gst_device_provider_device_remove,
-//GO(gst_device_provider_factory_find,
-//GO(gst_device_provider_factory_get,
-//GO(gst_device_provider_factory_get_by_name,
-//GO(gst_device_provider_factory_get_device_provider_type,
-//GO(gst_device_provider_factory_get_metadata,
-//GO(gst_device_provider_factory_get_metadata_keys,
+GO(gst_device_provider_device_changed, vFppp)
+GO(gst_device_provider_device_remove, vFpp)
+GO(gst_device_provider_factory_find, pFp)
+GO(gst_device_provider_factory_get, pFp)
+GO(gst_device_provider_factory_get_by_name, pFp)
+GO(gst_device_provider_factory_get_device_provider_type, LFp)
+GO(gst_device_provider_factory_get_metadata, pFpp)
+GO(gst_device_provider_factory_get_metadata_keys, pFp)
//GO(gst_device_provider_factory_get_type,
-//GO(gst_device_provider_factory_has_classes,
-//GO(gst_device_provider_factory_has_classesv,
-//GO(gst_device_provider_factory_list_get_device_providers,
-//GO(gst_device_provider_get_bus,
-//GO(gst_device_provider_get_devices,
-//GO(gst_device_provider_get_factory,
-//GO(gst_device_provider_get_hidden_providers,
-//GO(gst_device_provider_get_metadata,
+GO(gst_device_provider_factory_has_classes, iFpp)
+GO(gst_device_provider_factory_has_classesv, iFpp)
+GO(gst_device_provider_factory_list_get_device_providers, pFu)
+GO(gst_device_provider_get_bus, pFp)
+GO(gst_device_provider_get_devices, pFp)
+GO(gst_device_provider_get_factory, pFp)
+GO(gst_device_provider_get_hidden_providers, pFp)
+GO(gst_device_provider_get_metadata, pFpp)
//GO(gst_device_provider_get_type,
//GO(gst_device_provider_hide_provider,
-//GO(gst_device_provider_register,
+GO(gst_device_provider_register, iFppuL)
//GO(gst_device_provider_start,
//GO(gst_device_provider_stop,
-//GO(gst_device_provider_unhide_provider,
-//GO(gst_device_reconfigure_element,
+GO(gst_device_provider_unhide_provider, vFpp)
+GO(gst_device_reconfigure_element, iFpp)
//DATAB(_gst_disable_registry_cache,
//GO(gst_double_range_get_type,
//DATAB(_gst_double_range_type,
//GO(gst_dynamic_type_factory_get_type,
-//GO(gst_dynamic_type_factory_load,
-//GO(gst_dynamic_type_register,
+GO(gst_dynamic_type_factory_load, LFp)
+GO(gst_dynamic_type_register, iFpL)
GO(gst_element_abort_state, vFp)
GO(gst_element_add_pad, iFpp)
GO(gst_element_add_property_deep_notify_watch, LFppi)
GO(gst_element_add_property_notify_watch, LFppi)
//GOM(gst_element_call_async, vFEpBpB)
-GO(gst_element_change_state, iFpi)
+GO(gst_element_change_state, uFpu)
GO(gst_element_class_add_metadata, vFppp)
GO(gst_element_class_add_pad_template, vFpp)
GO(gst_element_class_add_static_metadata, vFppp)
@@ -531,7 +531,7 @@ GO(gst_element_class_get_pad_template, pFpp)
GO(gst_element_class_get_pad_template_list, pFp)
GO(gst_element_class_set_metadata, vFppppp)
GO(gst_element_class_set_static_metadata, vFppppp)
-GO(gst_element_continue_state, iFpi)
+GO(gst_element_continue_state, uFpu)
//GOM(gst_element_create_all_pads, iFEpBp)
//GO(_gst_element_error_printf,
GO(gst_element_factory_can_sink_all_caps, iFpp)
@@ -540,18 +540,18 @@ GO(gst_element_factory_can_src_all_caps, iFpp)
GO(gst_element_factory_can_src_any_caps, iFpp)
GO(gst_element_factory_create, pFpp)
GO(gst_element_factory_find, pFp)
-GO(gst_element_factory_get_element_type, pFp)
+GO(gst_element_factory_get_element_type, LFp)
GO(gst_element_factory_get_metadata, pFpp)
GO(gst_element_factory_get_metadata_keys, pFp)
GO(gst_element_factory_get_num_pad_templates, uFp)
GO(gst_element_factory_get_static_pad_templates, pFp)
GO(gst_element_factory_get_type, pFv)
GO(gst_element_factory_get_uri_protocols, pFp)
-GO(gst_element_factory_get_uri_type, iFp)
+GO(gst_element_factory_get_uri_type, uFp)
GO(gst_element_factory_has_interface, iFpp)
GO(gst_element_factory_list_filter, pFppii)
-GO(gst_element_factory_list_get_elements, pFpi)
-GO(gst_element_factory_list_is_type, iFpi)
+GO(gst_element_factory_list_get_elements, pFLu)
+GO(gst_element_factory_list_is_type, iFpL)
GO(gst_element_factory_make, pFpp)
GO(gst_element_flags_get_type, pFv)
//GOM(gst_element_foreach_pad, iFEpBp)
@@ -565,7 +565,7 @@ GO(gst_element_get_compatible_pad_template, pFpp)
GO(gst_element_get_context, pFpp)
GO(gst_element_get_contexts, pFp)
GO(gst_element_get_context_unlocked, pFpp)
-GO(gst_element_get_current_clock_time, UFp)
+GO(gst_element_get_current_clock_time, LFp)
GO(gst_element_get_current_running_time, UFp)
GO(gst_element_get_factory, pFp)
GO(gst_element_get_metadata, pFpp)
@@ -573,7 +573,7 @@ GO(gst_element_get_pad_template, pFpp)
GO(gst_element_get_pad_template_list, pFp)
//GO(gst_element_get_request_pad,
GO(gst_element_get_start_time, UFp)
-GO(gst_element_get_state, iFpppU)
+GO(gst_element_get_state, uFpppL)
GO(gst_element_get_static_pad, pFpp)
GO(gst_element_get_type, pFv)
GO(gst_element_is_locked_state, iFp)
@@ -585,40 +585,40 @@ GO(gst_element_link_filtered, iFppp)
//GOM(gst_element_link_many, iFEppV)
GO(gst_element_link_pads, iFpppp)
GO(gst_element_link_pads_filtered, iFppppp)
-GO(gst_element_link_pads_full, iFppppi)
+GO(gst_element_link_pads_full, iFppppu)
GO(gst_element_lost_state, vFp)
-GO(gst_element_make_from_uri, pFpppp)
-GO(gst_element_message_full, vFpipippppi)
-GO(gst_element_message_full_with_details, vFpipippppip)
+GO(gst_element_make_from_uri, pFuppp)
+GO(gst_element_message_full, vFpiuippppi)
+GO(gst_element_message_full_with_details, vFpiuippppip)
GO(gst_element_no_more_pads, vFp)
GO(gst_element_post_message, iFpp)
GO(gst_element_provide_clock, pFp)
GO(gst_element_query, iFpp)
-GO(gst_element_query_convert, iFpiIip)
-GO(gst_element_query_duration, iFpip)
+GO(gst_element_query_convert, iFpulup)
+GO(gst_element_query_duration, iFpup)
GO(gst_element_query_position, iFpip)
GO(gst_element_register, iFppup)
GO(gst_element_release_request_pad, vFpp)
GO(gst_element_remove_pad, iFpp)
GO(gst_element_remove_property_notify_watch, vFpL)
GO(gst_element_request_pad, pFpppp)
-GO(gst_element_seek, iFpdiiiIiI)
-GO(gst_element_seek_simple, iFpiiI)
+GO(gst_element_seek, iFpduuulul)
+GO(gst_element_seek_simple, iFpuul)
GO(gst_element_send_event, iFpp)
GO(gst_element_set_base_time, vFpU)
GO(gst_element_set_bus, vFpp)
GO(gst_element_set_clock, iFpp)
GO(gst_element_set_context, vFpp)
GO(gst_element_set_locked_state, iFpi)
-GO(gst_element_set_start_time, vFpU)
-GO(gst_element_set_state, iFpi)
-GO(gst_element_state_change_return_get_name, pFi)
-GO(gst_element_state_get_name, pFi)
+GO(gst_element_set_start_time, vFpL)
+GO(gst_element_set_state, uFpu)
+GO(gst_element_state_change_return_get_name, pFu)
+GO(gst_element_state_get_name, pFu)
GO(gst_element_sync_state_with_parent, iFp)
GO(gst_element_unlink, vFpp)
//GOM(gst_element_unlink_many, vFEppV)
GO(gst_element_unlink_pads, vFpppp)
-//GO(gst_error_get_message,
+GO(gst_error_get_message, pFui)
GO(gst_event_copy, pFp)
GO(gst_event_copy_segment, vFpp)
GO(gst_event_get_running_time_offset, IFp)
@@ -688,33 +688,33 @@ GO(gst_event_set_stream, vFpp)
GO(gst_event_set_stream_flags, vFpi)
GO(gst_event_steal, pFp)
GO(gst_event_take, iFpp)
-//DATAB(_gst_event_type,
+DATAB(_gst_event_type, sizeof(void*))
GO(gst_event_type_flags_get_type, pFv)
-GO(gst_event_type_get_flags, iFp)
-GO(gst_event_type_get_name, pFi)
+GO(gst_event_type_get_flags, uFu)
+GO(gst_event_type_get_name, pFu)
GO(gst_event_type_get_type, pFv)
-GO(gst_event_type_to_quark, pFi)
+GO(gst_event_type_to_quark, uFu)
GO(gst_event_unref, vFp)
GO(gst_event_writable_structure, pFp)
//DATAB(_gst_executable_path,
-//GO(gst_filename_to_uri,
+GO(gst_filename_to_uri, pFpp)
//GO(gst_flagset_get_type,
-//GO(gst_flagset_register,
+GO(gst_flagset_register, LFL)
//DATAB(_gst_flagset_type,
GO(gst_flow_get_name, pFi)
GO(gst_flow_return_get_type, pFv)
-GO(gst_flow_to_quark, pFi)
-GO(gst_format_get_by_nick, iFp)
-GO(gst_format_get_details, pFi)
-GO(gst_format_get_name, pFi)
+GO(gst_flow_to_quark, uFi)
+GO(gst_format_get_by_nick, uFp)
+GO(gst_format_get_details, pFu)
+GO(gst_format_get_name, pFu)
GO(gst_format_get_type, pFv)
GO(gst_format_iterate_definitions, pFv)
-GO(gst_format_register, iFpp)
-GO(gst_formats_contains, iFpi)
-GO(gst_format_to_quark, pFi)
+GO(gst_format_register, uFpp)
+GO(gst_formats_contains, iFpu)
+GO(gst_format_to_quark, uFu)
GO(gst_fraction_get_type, pFv)
GO(gst_fraction_range_get_type, pFv)
-//DATAB(_gst_fraction_range_type,
+DATAB(_gst_fraction_range_type, sizeof(void*))
DATAB(_gst_fraction_type, sizeof(void*))
GO(gst_get_main_executable_path, pFv)
//GO(gst_ghost_pad_activate_mode_default,
@@ -737,24 +737,24 @@ GO(gst_init_get_option_group, pFv)
//GO(gst_int64_range_get_type,
//DATAB(_gst_int64_range_type,
//GO(gst_int_range_get_type,
-//DATAB(_gst_int_range_type,
-//GO(gst_is_caps_features,
+DATAB(_gst_int_range_type, sizeof(void*))
+GO(gst_is_caps_features, iFp)
GO(gst_is_initialized, iFv)
//GO(gst_iterator_copy,
//GO(gst_iterator_filter,
//GO(gst_iterator_find_custom,
//GO(gst_iterator_fold,
//GO(gst_iterator_foreach,
-//GO(gst_iterator_free,
+GO(gst_iterator_free, vFp)
//GO(gst_iterator_get_type,
//GO(gst_iterator_item_get_type,
//GO(gst_iterator_new,
//GO(gst_iterator_new_list,
//GO(gst_iterator_new_single,
-//GO(gst_iterator_next,
+GO(gst_iterator_next, iFpp)
//GO(gst_iterator_push,
//GO(gst_iterator_result_get_type,
-//GO(gst_iterator_resync,
+GO(gst_iterator_resync, vFp)
//GO(gst_library_error_get_type,
//GO(gst_library_error_quark,
//GO(gst_lock_flags_get_type,
@@ -878,15 +878,15 @@ GO(gst_message_streams_selected_add, vFpp)
GO(gst_message_streams_selected_get_size, uFp)
GO(gst_message_streams_selected_get_stream, pFpu)
GO(gst_message_take, iFpp)
-//DATAB(_gst_message_type,
+DATAB(_gst_message_type, sizeof(void*))
GO(gst_message_type_get_name, pFi)
GO(gst_message_type_get_type, pFv)
-GO(gst_message_type_to_quark, pFi)
+GO(gst_message_type_to_quark, uFi)
GO(gst_message_unref, vFp)
GO(gst_message_writable_structure, pFp)
-//GO(gst_meta_api_type_get_tags,
-//GO(gst_meta_api_type_has_tag,
-//GO(gst_meta_api_type_register,
+GO(gst_meta_api_type_get_tags, pFL)
+GO(gst_meta_api_type_has_tag, iFLu)
+GO(gst_meta_api_type_register, LFpp)
//GO(gst_meta_compare_seqnum,
//GO(gst_meta_flags_get_type,
//GO(gst_meta_get_info,
@@ -895,9 +895,9 @@ GO(gst_message_writable_structure, pFp)
//DATAB(_gst_meta_tag_memory,
//DATAB(_gst_meta_transform_copy,
//GO(gst_mini_object_add_parent,
-//GO(gst_mini_object_copy,
+GO(gst_mini_object_copy, pFp)
//GO(gst_mini_object_flags_get_type,
-//GO(gst_mini_object_get_qdata,
+GO(gst_mini_object_get_qdata, pFpp)
//GO(gst_mini_object_init,
GO(gst_mini_object_is_writable, iFp)
//GO(gst_mini_object_lock,
@@ -905,7 +905,7 @@ GO(gst_mini_object_make_writable, pFp)
GO(gst_mini_object_ref, pFp)
//GO(gst_mini_object_remove_parent,
//GO(gst_mini_object_replace,
-//GO(gst_mini_object_set_qdata,
+GOM(gst_mini_object_set_qdata, vFEpppp)
//GO(gst_mini_object_steal,
//GO(gst_mini_object_steal_qdata,
//GO(gst_mini_object_take,
@@ -919,14 +919,14 @@ GO(gst_object_default_deep_notify, vFpppp)
GO(gst_object_default_error, vFppp)
GO(gst_object_flags_get_type, pFv)
GO(gst_object_get_control_binding, pFpp)
-GO(gst_object_get_control_rate, UFp)
-GO(gst_object_get_g_value_array, iFppUUup)
+GO(gst_object_get_control_rate, LFp)
+GO(gst_object_get_g_value_array, iFppLLup)
GO(gst_object_get_name, pFp)
GO(gst_object_get_parent, pFp)
GO(gst_object_get_path_string, pFp)
GO(gst_object_get_type, pFv)
-GO(gst_object_get_value, pFppU)
-GO(gst_object_get_value_array, iFppUUup)
+GO(gst_object_get_value, pFppL)
+GO(gst_object_get_value_array, iFppLLup)
GO(gst_object_has_active_control_bindings, iFp)
GO(gst_object_has_ancestor, iFpp)
GO(gst_object_has_as_ancestor, iFpp)
@@ -936,12 +936,12 @@ GO(gst_object_ref_sink, pFp)
GO(gst_object_remove_control_binding, iFpp)
GO(gst_object_replace, iFpp)
GO(gst_object_set_control_binding_disabled, vFppi)
-GO(gst_object_set_control_bindings_disabled, vFpp)
-GO(gst_object_set_control_rate, vFpU)
+GO(gst_object_set_control_bindings_disabled, vFpi)
+GO(gst_object_set_control_rate, vFpL)
GO(gst_object_set_name, iFpp)
GO(gst_object_set_parent, iFpp)
GO(gst_object_suggest_next_sync, UFp)
-GO(gst_object_sync_values, iFpU)
+GO(gst_object_sync_values, iFpL)
GO(gst_object_unparent, vFp)
GO(gst_object_unref, vFp)
GO(gst_pad_activate_mode, iFpii)
@@ -984,12 +984,12 @@ GO(gst_pad_iterate_internal_links_default, pFpp)
GO(gst_pad_link, iFpp)
GO(gst_pad_link_check_get_type, pFv)
GO(gst_pad_link_full, iFppi)
-GO(gst_pad_link_get_name, pFp)
+GO(gst_pad_link_get_name, pFi)
GO(gst_pad_link_maybe_ghosting, iFpp)
GO(gst_pad_link_maybe_ghosting_full, iFppi)
GO(gst_pad_link_return_get_type, pFv)
GO(gst_pad_mark_reconfigure, vFp)
-GO(gst_pad_mode_get_name, pFi)
+GO(gst_pad_mode_get_name, pFu)
GO(gst_pad_mode_get_type, pFv)
GO(gst_pad_needs_reconfigure, iFp)
GO(gst_pad_new, pFpi)
@@ -1004,7 +1004,7 @@ GO(gst_pad_peer_query_duration, iFpip)
GO(gst_pad_peer_query_position, iFpip)
GO(gst_pad_presence_get_type, pFv)
//GO(gst_pad_probe_info_get_buffer,
-//GO(gst_pad_probe_info_get_buffer_list,
+GO(gst_pad_probe_info_get_buffer_list, pFp)
//GO(gst_pad_probe_info_get_event,
//GO(gst_pad_probe_info_get_query,
//GO(gst_pad_probe_return_get_type,
@@ -1053,113 +1053,113 @@ GO(gst_pad_template_new, pFpiip)
//GO(gst_pad_template_set_documentation_caps,
GO(gst_pad_unlink, iFpp)
GO(gst_pad_use_fixed_caps, vFp)
-//GO(gst_param_spec_array,
+GO(gst_param_spec_array, pFppppi)
//GO(gst_param_spec_array_get_type,
-//GO(gst_param_spec_fraction,
+GO(gst_param_spec_fraction, pFpppiiiiiii)
//GO(gst_param_spec_fraction_get_type,
//GO(gst_parent_buffer_meta_api_get_type,
//GO(gst_parent_buffer_meta_get_info,
-//GO(gst_parse_bin_from_description,
-//GO(gst_parse_bin_from_description_full,
-//GO(gst_parse_context_copy,
+GO(gst_parse_bin_from_description, pFpip)
+GO(gst_parse_bin_from_description_full, pFpipup)
+GO(gst_parse_context_copy, pFp)
//GO(gst_parse_context_free,
-//GO(gst_parse_context_get_missing_elements,
-//GO(gst_parse_context_get_type,
-//GO(gst_parse_context_new,
+GO(gst_parse_context_get_missing_elements, pFp)
+GO(gst_parse_context_get_type, LFv)
+GO(gst_parse_context_new, pFv)
//GO(gst_parse_error_get_type,
-//GO(gst_parse_error_quark,
+GO(gst_parse_error_quark, uFv)
//GO(gst_parse_flags_get_type,
-//GO(gst_parse_launch,
-//GO(gst_parse_launch_full,
-//GO(gst_parse_launchv,
-//GO(gst_parse_launchv_full,
+GO(gst_parse_launch, pFpp)
+GO(gst_parse_launch_full, pFppup)
+GO(gst_parse_launchv, pFpp)
+GO(gst_parse_launchv_full, pFppup)
//GO(gst_pipeline_auto_clock,
//GO(gst_pipeline_flags_get_type,
-//GO(gst_pipeline_get_auto_flush_bus,
-//GO(gst_pipeline_get_bus,
+GO(gst_pipeline_get_auto_flush_bus, iFp)
+GO(gst_pipeline_get_bus, pFp)
//GO(gst_pipeline_get_clock,
//GO(gst_pipeline_get_delay,
-//GO(gst_pipeline_get_latency,
-//GO(gst_pipeline_get_pipeline_clock,
+GO(gst_pipeline_get_latency, LFp)
+GO(gst_pipeline_get_pipeline_clock, pFp)
//GO(gst_pipeline_get_type,
-//GO(gst_pipeline_new,
-//GO(gst_pipeline_set_auto_flush_bus,
-//GO(gst_pipeline_set_clock,
+GO(gst_pipeline_new, pFp)
+GO(gst_pipeline_set_auto_flush_bus, vFpi)
+GO(gst_pipeline_set_clock, iFpp)
//GO(gst_pipeline_set_delay,
-//GO(gst_pipeline_set_latency,
-//GO(gst_pipeline_use_clock,
-//GO(gst_plugin_add_dependency,
-//GO(gst_plugin_add_dependency_simple,
+GO(gst_pipeline_set_latency, vFpL)
+GO(gst_pipeline_use_clock, vFpp)
+GO(gst_plugin_add_dependency, vFppppu)
+GO(gst_plugin_add_dependency_simple, vFppppu)
//GO(gst_plugin_api_flags_get_type,
//GO(gst_plugin_dependency_flags_get_type,
//GO(gst_plugin_error_get_type,
//GO(gst_plugin_error_quark,
-//GO(gst_plugin_feature_check_version,
-//GO(gst_plugin_feature_get_plugin,
-//GO(gst_plugin_feature_get_plugin_name,
-//GO(gst_plugin_feature_get_rank,
+GO(gst_plugin_feature_check_version, iFpuuu)
+GO(gst_plugin_feature_get_plugin, pFp)
+GO(gst_plugin_feature_get_plugin_name, pFp)
+GO(gst_plugin_feature_get_rank, uFp)
GO(gst_plugin_feature_get_type, LFv)
-//GO(gst_plugin_feature_list_copy,
-//GO(gst_plugin_feature_list_debug,
+GO(gst_plugin_feature_list_copy, pFp)
+GO(gst_plugin_feature_list_debug, vFp)
GO(gst_plugin_feature_list_free, vFp)
-//GO(gst_plugin_feature_load,
+GO(gst_plugin_feature_load, pFp)
GO(gst_plugin_feature_rank_compare_func, iFpp)
-//GO(gst_plugin_feature_set_rank,
+GO(gst_plugin_feature_set_rank, vFpu)
//GO(gst_plugin_flags_get_type,
-//GO(gst_plugin_get_cache_data,
+GO(gst_plugin_get_cache_data, pFp)
//GO(gst_plugin_get_description,
//GO(gst_plugin_get_filename,
//GO(gst_plugin_get_license,
//GO(gst_plugin_get_name,
//GO(gst_plugin_get_origin,
//GO(gst_plugin_get_package,
-//GO(gst_plugin_get_release_date_string,
+GO(gst_plugin_get_release_date_string, pFp)
//GO(gst_plugin_get_source,
//GO(gst_plugin_get_type,
//GO(gst_plugin_get_version,
-//GO(gst_plugin_is_loaded,
+GO(gst_plugin_is_loaded, iFp)
//GO(gst_plugin_list_free,
-//GO(gst_plugin_load,
-//GO(gst_plugin_load_by_name,
+GO(gst_plugin_load, pFp)
+GO(gst_plugin_load_by_name, pFp)
//GO(_gst_plugin_loader_client_run,
-//GO(gst_plugin_load_file,
+GO(gst_plugin_load_file, pFpp)
//GO(gst_plugin_register_static,
//GO(gst_plugin_register_static_full,
-//GO(gst_plugin_set_cache_data,
+GO(gst_plugin_set_cache_data, vFpp)
//GO(gst_poll_add_fd,
//GO(gst_poll_fd_can_read,
//GO(gst_poll_fd_can_write,
-//GO(gst_poll_fd_ctl_pri,
+GO(gst_poll_fd_ctl_pri, iFppi)
//GO(gst_poll_fd_ctl_read,
//GO(gst_poll_fd_ctl_write,
//GO(gst_poll_fd_has_closed,
//GO(gst_poll_fd_has_error,
-//GO(gst_poll_fd_has_pri,
-//GO(gst_poll_fd_ignored,
-//GO(gst_poll_fd_init,
+GO(gst_poll_fd_has_pri, iFpp)
+GO(gst_poll_fd_ignored, vFpp)
+GO(gst_poll_fd_init, vFp)
//GO(gst_poll_free,
-//GO(gst_poll_get_read_gpollfd,
-//GO(gst_poll_new,
-//GO(gst_poll_new_timer,
-//GO(gst_poll_read_control,
-//GO(gst_poll_remove_fd,
-//GO(gst_poll_restart,
-//GO(gst_poll_set_controllable,
-//GO(gst_poll_set_flushing,
-//GO(gst_poll_wait,
+GO(gst_poll_get_read_gpollfd, vFpp)
+GO(gst_poll_new, pFi)
+GO(gst_poll_new_timer, pFv)
+GO(gst_poll_read_control, iFp)
+GO(gst_poll_remove_fd, iFpp)
+GO(gst_poll_restart, vFp)
+GO(gst_poll_set_controllable, iFpi)
+GO(gst_poll_set_flushing, vFpi)
+GO(gst_poll_wait, iFpL)
//GO(gst_poll_write_control,
-//GO(gst_preset_delete_preset,
+GO(gst_preset_delete_preset, iFpp)
//GO(gst_preset_get_app_dir,
-//GO(gst_preset_get_meta,
+GO(gst_preset_get_meta, iFpppp)
//GO(gst_preset_get_preset_names,
-//GO(gst_preset_get_property_names,
+GO(gst_preset_get_property_names, pFp)
//GO(gst_preset_get_type,
-//GO(gst_preset_is_editable,
+GO(gst_preset_is_editable, iFp)
//GO(gst_preset_load_preset,
-//GO(gst_preset_rename_preset,
+GO(gst_preset_rename_preset, iFppp)
//GO(gst_preset_save_preset,
-//GO(gst_preset_set_app_dir,
-//GO(gst_preset_set_meta,
+GO(gst_preset_set_app_dir, iFp)
+GO(gst_preset_set_meta, iFpppp)
//GO(gst_print,
//GO(gst_printerr,
//GO(gst_printerrln,
@@ -1176,10 +1176,10 @@ GO(gst_plugin_feature_rank_compare_func, iFpp)
//GO(gst_promise_result_get_type,
//GO(gst_promise_unref,
//GO(gst_promise_wait,
-//GO(gst_protection_filter_systems_by_available_decryptors,
+GO(gst_protection_filter_systems_by_available_decryptors, pFp)
//GO(gst_protection_meta_api_get_type,
//GO(gst_protection_meta_get_info,
-//GO(gst_protection_select_system,
+GO(gst_protection_select_system, pFp)
//GO(gst_proxy_pad_chain_default,
//GO(gst_proxy_pad_chain_list_default,
//GO(gst_proxy_pad_get_internal,
@@ -1277,35 +1277,35 @@ GO(gst_query_set_uri_redirection_permanent, vFpi)
GO(gst_query_take, iFpp)
//DATAB(_gst_query_type,
GO(gst_query_type_flags_get_type, pFv)
-GO(gst_query_type_get_flags, iFi)
-GO(gst_query_type_get_name, pFi)
+GO(gst_query_type_get_flags, uFu)
+GO(gst_query_type_get_name, pFu)
GO(gst_query_type_get_type, pFv)
-GO(gst_query_type_to_quark, pFi)
+GO(gst_query_type_to_quark, uFu)
GO(gst_query_unref, vFp)
GO(gst_query_writable_structure, pFp)
//GO(gst_rank_get_type,
//GO(gst_reference_timestamp_meta_api_get_type,
//GO(gst_reference_timestamp_meta_get_info,
-//GO(gst_registry_add_feature,
-//GO(gst_registry_add_plugin,
-//GO(gst_registry_check_feature_version,
-//GO(gst_registry_feature_filter,
-//GO(gst_registry_find_feature,
-//GO(gst_registry_find_plugin,
+GO(gst_registry_add_feature, iFpp)
+GO(gst_registry_add_plugin, iFpp)
+GO(gst_registry_check_feature_version, iFppuuu)
+GOM(gst_registry_feature_filter, pFEppip)
+GO(gst_registry_find_feature, pFppL)
+GO(gst_registry_find_plugin, pFpp)
//GO(gst_registry_fork_is_enabled,
-//GO(gst_registry_fork_set_enabled,
-//GO(gst_registry_get,
-//GO(gst_registry_get_feature_list,
-//GO(gst_registry_get_feature_list_by_plugin,
-//GO(gst_registry_get_feature_list_cookie,
-//GO(gst_registry_get_plugin_list,
+GO(gst_registry_fork_set_enabled, vFi)
+GO(gst_registry_get, pFv)
+GO(gst_registry_get_feature_list, pFpL)
+GO(gst_registry_get_feature_list_by_plugin, pFpp)
+GO(gst_registry_get_feature_list_cookie, uFp)
+GO(gst_registry_get_plugin_list, pFp)
//GO(gst_registry_get_type,
-//GO(gst_registry_lookup,
-//GO(gst_registry_lookup_feature,
+GO(gst_registry_lookup, pFpp)
+GO(gst_registry_lookup_feature, pFpp)
//GO(gst_registry_plugin_filter,
-//GO(gst_registry_remove_feature,
-//GO(gst_registry_remove_plugin,
-//GO(gst_registry_scan_path,
+GO(gst_registry_remove_feature, vFpp)
+GO(gst_registry_remove_plugin, vFpp)
+GO(gst_registry_scan_path, iFpp)
//GO(gst_resource_error_get_type,
//GO(gst_resource_error_quark,
GO(gst_sample_copy, pFp)
@@ -1318,32 +1318,32 @@ GO(gst_sample_get_type, pFv)
GO(gst_sample_new, pFpppp)
GO(gst_sample_ref, pFp)
//GO(gst_sample_set_buffer,
-//GO(gst_sample_set_buffer_list,
+GO(gst_sample_set_buffer_list, vFpp)
//GO(gst_sample_set_caps,
-//GO(gst_sample_set_info,
-//GO(gst_sample_set_segment,
+GO(gst_sample_set_info, iFpp)
+GO(gst_sample_set_segment, vFpp)
DATAB(_gst_sample_type, sizeof(long))
//GO(gst_sample_unref,
GO(gst_scheduling_flags_get_type, pFv)
GO(gst_search_mode_get_type, pFv)
GO(gst_seek_flags_get_type, pFv)
GO(gst_seek_type_get_type, pFv)
-GO(gst_segment_clip, iFpiUUpp)
+GO(gst_segment_clip, iFpuLLpp)
GO(gst_segment_copy, pFp)
GO(gst_segment_copy_into, vFpp)
-GO(gst_segment_do_seek, iFpdiiiUiUp)
+GO(gst_segment_do_seek, iFpduuuLuLp)
GO(gst_segment_flags_get_type, pFv)
GO(gst_segment_free, vFp)
GO(gst_segment_get_type, pFv)
-GO(gst_segment_init, vFpi)
+GO(gst_segment_init, vFpu)
GO(gst_segment_is_equal, iFpp)
GO(gst_segment_new, pFv)
-GO(gst_segment_offset_running_time, iFpiI)
-GO(gst_segment_position_from_running_time, UFpiU)
-GO(gst_segment_position_from_running_time_full, iFpiUp)
+GO(gst_segment_offset_running_time, iFpul)
+GO(gst_segment_position_from_running_time, LFpuL)
+GO(gst_segment_position_from_running_time_full, iFpuLp)
GO(gst_segment_position_from_stream_time, UFpiU)
GO(gst_segment_position_from_stream_time_full, iFpiUp)
-GO(gst_segment_set_running_time, iFpiU)
+GO(gst_segment_set_running_time, iFpuL)
//GO(gst_segment_to_position,
GO(gst_segment_to_running_time, UFpiU)
GO(gst_segment_to_running_time_full, iFpiUp)
@@ -1352,7 +1352,7 @@ GO(gst_segment_to_stream_time_full, iFpiUp)
GO(gst_segtrap_is_enabled, iFv)
GO(gst_segtrap_set_enabled, vFi)
GO(gst_stack_trace_flags_get_type, pFv)
-//GO(gst_state_change_get_name,
+GO(gst_state_change_get_name, pFu)
GO(gst_state_change_get_type, pFv)
GO(gst_state_change_return_get_type, pFv)
GO(gst_state_get_type, pFv)
@@ -1362,28 +1362,28 @@ GO(gst_static_caps_get_type, pFv)
//GO(gst_static_pad_template_get,
//GO(gst_static_pad_template_get_caps,
//GO(gst_static_pad_template_get_type,
-//GO(gst_stream_collection_add_stream,
-//GO(gst_stream_collection_get_size,
-//GO(gst_stream_collection_get_stream,
+GO(gst_stream_collection_add_stream, iFpp)
+GO(gst_stream_collection_get_size, uFp)
+GO(gst_stream_collection_get_stream, pFpu)
//GO(gst_stream_collection_get_type,
-//GO(gst_stream_collection_get_upstream_id,
-//GO(gst_stream_collection_new,
+GO(gst_stream_collection_get_upstream_id, pFp)
+GO(gst_stream_collection_new, pFp)
//GO(gst_stream_error_get_type,
//GO(gst_stream_error_quark,
//GO(gst_stream_flags_get_type,
-//GO(gst_stream_get_caps,
-//GO(gst_stream_get_stream_flags,
-//GO(gst_stream_get_stream_id,
-//GO(gst_stream_get_stream_type,
-//GO(gst_stream_get_tags,
+GO(gst_stream_get_caps, pFp)
+GO(gst_stream_get_stream_flags, uFp)
+GO(gst_stream_get_stream_id, pFp)
+GO(gst_stream_get_stream_type, uFp)
+GO(gst_stream_get_tags, pFp)
//GO(gst_stream_get_type,
-//GO(gst_stream_new,
-//GO(gst_stream_set_caps,
-//GO(gst_stream_set_stream_flags,
-//GO(gst_stream_set_stream_type,
-//GO(gst_stream_set_tags,
+GO(gst_stream_new, pFppuu)
+GO(gst_stream_set_caps, vFpp)
+GO(gst_stream_set_stream_flags, vFpu)
+GO(gst_stream_set_stream_type, vFpu)
+GO(gst_stream_set_tags, vFpp)
//GO(gst_stream_status_type_get_type,
-//GO(gst_stream_type_get_name,
+GO(gst_stream_type_get_name, pFu)
//GO(gst_stream_type_get_type,
GO(gst_structure_can_intersect, iFpp)
//GO(gst_structure_change_type_get_type,
@@ -1406,15 +1406,15 @@ GO(gst_structure_get_clock_time, iFppp)
GO(gst_structure_get_date, iFppp)
GO(gst_structure_get_date_time, iFppp)
GO(gst_structure_get_double, iFppp)
-GO(gst_structure_get_enum, iFpppp)
-GO(gst_structure_get_field_type, pFpp)
+GO(gst_structure_get_enum, iFppLp)
+GO(gst_structure_get_field_type, LFpp)
GO(gst_structure_get_flagset, iFpppp)
GO(gst_structure_get_fraction, iFpppp)
GO(gst_structure_get_int, iFppp)
GO(gst_structure_get_int64, iFppp)
GO(gst_structure_get_list, iFppp)
GO(gst_structure_get_name, pFp)
-GO(gst_structure_get_name_id, pFp)
+GO(gst_structure_get_name_id, uFp)
GO(gst_structure_get_string, pFpp)
GO(gst_structure_get_type, pFv)
GO(gst_structure_get_uint, iFppp)
@@ -1422,17 +1422,17 @@ GO(gst_structure_get_uint64, iFppp)
GOM(gst_structure_get_valist, iFEppA)
GO(gst_structure_get_value, pFpp)
GO(gst_structure_has_field, iFpp)
-GO(gst_structure_has_field_typed, iFppp)
+GO(gst_structure_has_field_typed, iFppL)
GO(gst_structure_has_name, iFpp)
//GOM(gst_structure_id_get, iFEppV)
//GOM(gst_structure_id_get_valist, iFEppA)
-GO(gst_structure_id_get_value, pFpp)
-GO(gst_structure_id_has_field, iFpp)
-GO(gst_structure_id_has_field_typed, iFppp)
+GO(gst_structure_id_get_value, pFpu)
+GO(gst_structure_id_has_field, iFpu)
+GO(gst_structure_id_has_field_typed, iFpuL)
//GOM(gst_structure_id_set, iFEppV)
//GOM(gst_structure_id_set_valist, iFEppA)
-GO(gst_structure_id_set_value, vFppp)
-GO(gst_structure_id_take_value, pFppp)
+GO(gst_structure_id_set_value, vFpup)
+GO(gst_structure_id_take_value, vFpup)
GO(gst_structure_intersect, pFpp)
GO(gst_structure_is_equal, iFpp)
GO(gst_structure_is_subset, iFpp)
@@ -1441,7 +1441,7 @@ GOM(gst_structure_new, pFEppV)
GO(gst_structure_new_empty, pFp)
GO(gst_structure_new_from_string, pFp)
//GOM(gst_structure_new_id, pFEppV)
-GO(gst_structure_new_id_empty, pFp)
+GO(gst_structure_new_id_empty, pFu)
//GOM(gst_structure_new_valist, pFppA)
GO(gst_structure_n_fields, iFp)
GO(gst_structure_nth_field_name, pFpu)
@@ -1459,14 +1459,14 @@ GO(gst_structure_set_value, vFppp)
GO(gst_structure_take, iFpp)
GO(gst_structure_take_value, vFppp)
GO(gst_structure_to_string, pFp)
-//DATAB(_gst_structure_type,
+DATAB(_gst_structure_type, sizeof(void*))
//GO(gst_system_clock_get_type,
-//GO(gst_system_clock_obtain,
-//GO(gst_system_clock_set_default,
+GO(gst_system_clock_obtain, pFv)
+GO(gst_system_clock_set_default, vFp)
//GO(gst_tag_exists,
//GO(gst_tag_flag_get_type,
-//GO(gst_tag_get_description,
-//GO(gst_tag_get_flag,
+GO(gst_tag_get_description, pFp)
+GO(gst_tag_get_flag, uFp)
//GO(gst_tag_get_nick,
//GO(gst_tag_get_type,
//GO(gst_tag_is_fixed,
@@ -1523,7 +1523,7 @@ GO(gst_tag_list_replace, iFpp)
GO(gst_tag_list_set_scope, vFpi)
GO(gst_tag_list_take, iFpp)
GO(gst_tag_list_to_string, pFp)
-//DATAB(_gst_tag_list_type,
+DATAB(_gst_tag_list_type, sizeof(void*))
GO(gst_tag_list_unref, vFp)
GO(gst_tag_merge_mode_get_type, pFv)
//GO(gst_tag_merge_strings_with_comma,
@@ -1534,91 +1534,91 @@ GO(gst_tag_merge_mode_get_type, pFv)
//GO(gst_tag_setter_add_tags,
//GO(gst_tag_setter_add_tag_valist,
//GO(gst_tag_setter_add_tag_valist_values,
-//GO(gst_tag_setter_add_tag_value,
+GO(gst_tag_setter_add_tag_value, vFpupp)
//GO(gst_tag_setter_add_tag_values,
//GO(gst_tag_setter_get_tag_list,
-//GO(gst_tag_setter_get_tag_merge_mode,
+GO(gst_tag_setter_get_tag_merge_mode, uFp)
//GO(gst_tag_setter_get_type,
//GO(gst_tag_setter_merge_tags,
-//GO(gst_tag_setter_reset_tags,
-//GO(gst_tag_setter_set_tag_merge_mode,
+GO(gst_tag_setter_reset_tags, vFp)
+GO(gst_tag_setter_set_tag_merge_mode, vFpu)
//GO(gst_task_cleanup_all,
//GO(gst_task_get_pool,
//GO(gst_task_get_state,
-//GO(gst_task_get_type,
+GO(gst_task_get_type, pFv)
//GO(gst_task_join,
//GO(gst_task_new,
//GO(gst_task_pause,
-//GO(gst_task_pool_cleanup,
-//GO(gst_task_pool_get_type,
+GO(gst_task_pool_cleanup, vFp)
+GO(gst_task_pool_get_type, pFv)
//GO(gst_task_pool_join,
//GO(gst_task_pool_new,
-//GO(gst_task_pool_prepare,
+GO(gst_task_pool_prepare, vFp)
//GO(gst_task_pool_push,
//GO(gst_task_resume,
//GO(gst_task_set_enter_callback,
//GO(gst_task_set_leave_callback,
//GO(gst_task_set_lock,
-//GO(gst_task_set_pool,
+GO(gst_task_set_pool, vFpp)
//GO(gst_task_set_state,
//GO(gst_task_start,
//GO(gst_task_state_get_type,
//GO(gst_task_stop,
-//GO(gst_toc_append_entry,
+GO(gst_toc_append_entry, vFpp)
//GO(gst_toc_dump,
-//GO(gst_toc_entry_append_sub_entry,
-//GO(gst_toc_entry_get_entry_type,
-//GO(gst_toc_entry_get_loop,
-//GO(gst_toc_entry_get_parent,
-//GO(gst_toc_entry_get_start_stop_times,
-//GO(gst_toc_entry_get_sub_entries,
+GO(gst_toc_entry_append_sub_entry, vFpp)
+GO(gst_toc_entry_get_entry_type, iFp)
+GO(gst_toc_entry_get_loop, iFppp)
+GO(gst_toc_entry_get_parent, pFp)
+GO(gst_toc_entry_get_start_stop_times, iFppp)
+GO(gst_toc_entry_get_sub_entries, pFp)
//GO(gst_toc_entry_get_tags,
-//GO(gst_toc_entry_get_toc,
+GO(gst_toc_entry_get_toc, pFp)
//GO(gst_toc_entry_get_type,
-//GO(gst_toc_entry_get_uid,
+GO(gst_toc_entry_get_uid, pFp)
//GO(gst_toc_entry_is_alternative,
-//GO(gst_toc_entry_is_sequence,
+GO(gst_toc_entry_is_sequence, iFp)
//GO(gst_toc_entry_merge_tags,
-//GO(gst_toc_entry_new,
-//GO(gst_toc_entry_set_loop,
-//GO(gst_toc_entry_set_start_stop_times,
+GO(gst_toc_entry_new, pFip)
+GO(gst_toc_entry_set_loop, vFpui)
+GO(gst_toc_entry_set_start_stop_times, vFpll)
//GO(gst_toc_entry_set_tags,
//DATAB(_gst_toc_entry_type,
-//GO(gst_toc_entry_type_get_nick,
+GO(gst_toc_entry_type_get_nick, pFi)
//GO(gst_toc_entry_type_get_type,
-//GO(gst_toc_find_entry,
-//GO(gst_toc_get_entries,
-//GO(gst_toc_get_scope,
+GO(gst_toc_find_entry, pFpp)
+GO(gst_toc_get_entries, pFp)
+GO(gst_toc_get_scope, uFp)
//GO(gst_toc_get_tags,
//GO(gst_toc_get_type,
//GO(gst_toc_loop_type_get_type,
//GO(gst_toc_merge_tags,
-//GO(gst_toc_new,
+GO(gst_toc_new, pFu)
//GO(gst_toc_scope_get_type,
//GO(gst_toc_set_tags,
-//GO(gst_toc_setter_get_toc,
+GO(gst_toc_setter_get_toc, pFp)
//GO(gst_toc_setter_get_type,
-//GO(gst_toc_setter_reset,
-//GO(gst_toc_setter_set_toc,
-//DATAB(_gst_toc_type,
+GO(gst_toc_setter_reset, vFp)
+GO(gst_toc_setter_set_toc, vFpp)
+DATAB(_gst_toc_type, sizeof(void*))
//GO(gst_tracer_factory_get_list,
-//GO(gst_tracer_factory_get_tracer_type,
+GO(gst_tracer_factory_get_tracer_type, LFp)
//GO(gst_tracer_factory_get_type,
//GO(gst_tracer_get_type,
//GO(gst_tracer_record_get_type,
//GO(gst_tracer_record_log,
//GO(gst_tracer_record_new,
-//GO(gst_tracer_register,
+GO(gst_tracer_register, iFppL)
//GO(gst_tracer_value_flags_get_type,
//GO(gst_tracer_value_scope_get_type,
//GO(gst_tracing_get_active_tracers,
//GO(gst_tracing_register_hook,
//GO(gst_type_find_factory_call_function,
//GO(gst_type_find_factory_get_caps,
-//GO(gst_type_find_factory_get_extensions,
-//GO(gst_type_find_factory_get_list,
+GO(gst_type_find_factory_get_extensions, pFp)
+GO(gst_type_find_factory_get_list, pFv)
//GO(gst_type_find_factory_get_type,
-//GO(gst_type_find_factory_has_function,
+GO(gst_type_find_factory_has_function, iFp)
//GO(gst_type_find_get_length,
//GO(gst_type_find_get_type,
//GO(gst_type_find_peek,
@@ -1626,133 +1626,133 @@ GO(gst_tag_merge_mode_get_type, pFv)
//GO(gst_type_find_register,
//GO(gst_type_find_suggest,
//GO(gst_type_find_suggest_simple,
-//GO(gst_type_is_plugin_api,
-//GO(gst_type_mark_as_plugin_api,
-//GO(gst_update_registry,
+GO(gst_type_is_plugin_api, iFLp)
+GO(gst_type_mark_as_plugin_api, vFLu)
+GO(gst_update_registry, iFv)
//GO(gst_uri_append_path,
//GO(gst_uri_append_path_segment,
//GO(gst_uri_construct,
-//GO(gst_uri_copy,
-//GO(gst_uri_equal,
+GO(gst_uri_copy, pFp)
+GO(gst_uri_equal, iFpp)
//GO(gst_uri_error_get_type,
//GO(gst_uri_error_quark,
//GO(gst_uri_from_string,
-//GO(gst_uri_from_string_escaped,
-//GO(gst_uri_from_string_with_base,
-//GO(gst_uri_get_fragment,
+GO(gst_uri_from_string_escaped, pFp)
+GO(gst_uri_from_string_with_base, pFpp)
+GO(gst_uri_get_fragment, pFp)
//GO(gst_uri_get_host,
-//GO(gst_uri_get_location,
-//GO(gst_uri_get_media_fragment_table,
+GO(gst_uri_get_location, pFp)
+GO(gst_uri_get_media_fragment_table, pFp)
//GO(gst_uri_get_path,
//GO(gst_uri_get_path_segments,
//GO(gst_uri_get_path_string,
-//GO(gst_uri_get_port,
+GO(gst_uri_get_port, uFp)
//GO(gst_uri_get_protocol,
-//GO(gst_uri_get_query_keys,
-//GO(gst_uri_get_query_string,
+GO(gst_uri_get_query_keys, pFp)
+GO(gst_uri_get_query_string, pFp)
//GO(gst_uri_get_query_table,
-//GO(gst_uri_get_query_value,
+GO(gst_uri_get_query_value, pFpp)
//GO(gst_uri_get_scheme,
//GO(gst_uri_get_type,
//GO(gst_uri_get_userinfo,
-//GO(gst_uri_handler_get_protocols,
+GO(gst_uri_handler_get_protocols, pFp)
//GO(gst_uri_handler_get_type,
-//GO(gst_uri_handler_get_uri,
-//GO(gst_uri_handler_get_uri_type,
-//GO(gst_uri_handler_set_uri,
-//GO(gst_uri_has_protocol,
-//GO(gst_uri_is_normalized,
+GO(gst_uri_handler_get_uri, pFp)
+GO(gst_uri_handler_get_uri_type, uFp)
+GO(gst_uri_handler_set_uri, iFppp)
+GO(gst_uri_has_protocol, iFpp)
+GO(gst_uri_is_normalized, iFp)
//GO(gst_uri_is_valid,
//GO(gst_uri_is_writable,
-//GO(gst_uri_join,
-//GO(gst_uri_join_strings,
+GO(gst_uri_join, pFpp)
+GO(gst_uri_join_strings, pFpp)
//GO(gst_uri_make_writable,
-//GO(gst_uri_new,
-//GO(gst_uri_new_with_base,
-//GO(gst_uri_normalize,
-//GO(gst_uri_protocol_is_supported,
+GO(gst_uri_new, pFpppuppp)
+GO(gst_uri_new_with_base, pFppppuppp)
+GO(gst_uri_normalize, iFp)
+GO(gst_uri_protocol_is_supported, iFup)
//GO(gst_uri_protocol_is_valid,
-//GO(gst_uri_query_has_key,
-//GO(gst_uri_ref,
+GO(gst_uri_query_has_key, iFpp)
+GO(gst_uri_ref, pFp)
//GO(gst_uri_remove_query_key,
-//GO(gst_uri_set_fragment,
+GO(gst_uri_set_fragment, iFpp)
//GO(gst_uri_set_host,
//GO(gst_uri_set_path,
-//GO(gst_uri_set_path_segments,
+GO(gst_uri_set_path_segments, iFpp)
//GO(gst_uri_set_path_string,
-//GO(gst_uri_set_port,
+GO(gst_uri_set_port, iFpu)
//GO(gst_uri_set_query_string,
-//GO(gst_uri_set_query_table,
-//GO(gst_uri_set_query_value,
+GO(gst_uri_set_query_table, iFpp)
+GO(gst_uri_set_query_value, iFppp)
//GO(gst_uri_set_scheme,
//GO(gst_uri_set_userinfo,
//GO(gst_uri_to_string,
//GO(gst_uri_type_get_type,
//GO(gst_uri_unref,
//GO(gst_util_array_binary_search,
-//GO(gst_util_double_to_fraction,
+GO(gst_util_double_to_fraction, vFdpp)
//GO(gst_util_dump_buffer,
-//GO(gst_util_dump_mem,
-//GO(gst_util_fraction_add,
-//GO(gst_util_fraction_compare,
+GO(gst_util_dump_mem, vFpu)
+GO(gst_util_fraction_add, iFiiiipp)
+GO(gst_util_fraction_compare, iFiiii)
//GO(gst_util_fraction_multiply,
-//GO(gst_util_fraction_to_double,
-//GO(gst_util_gdouble_to_guint64,
-//GO(gst_util_get_object_array,
-//GO(gst_util_get_timestamp,
-//GO(gst_util_greatest_common_divisor,
-//GO(gst_util_greatest_common_divisor_int64,
-//GO(gst_util_group_id_next,
-//GO(gst_util_guint64_to_gdouble,
-//GO(gst_util_seqnum_compare,
-//GO(gst_util_seqnum_next,
+GO(gst_util_fraction_to_double, vFiip)
+GO(gst_util_gdouble_to_guint64, LFd)
+GO(gst_util_get_object_array, iFppp)
+GO(gst_util_get_timestamp, LFv)
+GO(gst_util_greatest_common_divisor, iFii)
+GO(gst_util_greatest_common_divisor_int64, lFll)
+GO(gst_util_group_id_next, uFv)
+GO(gst_util_guint64_to_gdouble, dFL)
+GO(gst_util_seqnum_compare, iFuu)
+GO(gst_util_seqnum_next, uFv)
GO(gst_util_set_object_arg, vFppp)
-//GO(gst_util_set_object_array,
-//GO(gst_util_set_value_from_string,
+GO(gst_util_set_object_array, iFppp)
+GO(gst_util_set_value_from_string, vFpp)
GO(gst_util_uint64_scale, UFUUU)
-//GO(gst_util_uint64_scale_ceil,
+GO(gst_util_uint64_scale_ceil, LFLLL)
//GO(gst_util_uint64_scale_int,
-//GO(gst_util_uint64_scale_int_ceil,
+GO(gst_util_uint64_scale_int_ceil, LFLii)
//GO(gst_util_uint64_scale_int_round,
//GO(gst_util_uint64_scale_round,
-//GO(gst_value_array_append_and_take_value,
+GO(gst_value_array_append_and_take_value, vFpp)
//GO(gst_value_array_append_value,
//GO(gst_value_array_get_size,
//GO(gst_value_array_get_type,
-//GO(gst_value_array_get_value,
-//GO(gst_value_array_init,
-//GO(gst_value_array_prepend_value,
-//DATAB(_gst_value_array_type,
+GO(gst_value_array_get_value, pFpu)
+GO(gst_value_array_init, pFpu)
+GO(gst_value_array_prepend_value, vFpp)
+DATAB(_gst_value_array_type, sizeof(void*))
//GO(gst_value_can_compare,
//GO(gst_value_can_intersect,
-//GO(gst_value_can_subtract,
+GO(gst_value_can_subtract, iFpp)
//GO(gst_value_can_union,
-//GO(gst_value_compare,
-//GO(gst_value_deserialize,
-//GO(gst_value_fixate,
+GO(gst_value_compare, iFpp)
+GO(gst_value_deserialize, iFpp)
+GO(gst_value_fixate, iFpp)
//GO(gst_value_fraction_multiply,
//GO(gst_value_fraction_subtract,
-//GO(gst_value_get_bitmask,
+GO(gst_value_get_bitmask, LFp)
//GO(gst_value_get_caps,
-//GO(gst_value_get_caps_features,
-//GO(gst_value_get_double_range_max,
+GO(gst_value_get_caps_features, pFp)
+GO(gst_value_get_double_range_max, dFp)
//GO(gst_value_get_double_range_min,
//GO(gst_value_get_flagset_flags,
-//GO(gst_value_get_flagset_mask,
-//GO(gst_value_get_fraction_denominator,
+GO(gst_value_get_flagset_mask, uFp)
+GO(gst_value_get_fraction_denominator, iFp)
//GO(gst_value_get_fraction_numerator,
-//GO(gst_value_get_fraction_range_max,
+GO(gst_value_get_fraction_range_max, pFp)
//GO(gst_value_get_fraction_range_min,
//GO(gst_value_get_int64_range_max,
//GO(gst_value_get_int64_range_min,
-//GO(gst_value_get_int64_range_step,
+GO(gst_value_get_int64_range_step, lFp)
//GO(gst_value_get_int_range_max,
//GO(gst_value_get_int_range_min,
//GO(gst_value_get_int_range_step,
-//GO(gst_value_get_structure,
+GO(gst_value_get_structure, pFp)
//GO(gst_value_init_and_copy,
//GO(gst_value_intersect,
-//GO(gst_value_is_fixed,
+GO(gst_value_is_fixed, iFp)
//GO(gst_value_is_subset,
//GO(gst_value_list_append_and_take_value,
//GO(gst_value_list_append_value,
@@ -1763,23 +1763,23 @@ GO(gst_util_uint64_scale, UFUUU)
//GO(gst_value_list_init,
//GO(gst_value_list_merge,
//GO(gst_value_list_prepend_value,
-//DATAB(_gst_value_list_type,
+DATAB(_gst_value_list_type, sizeof(void*))
//GO(gst_value_register,
-//GO(gst_value_serialize,
-//GO(gst_value_set_bitmask,
+GO(gst_value_serialize, pFp)
+GO(gst_value_set_bitmask, vFpL)
//GO(gst_value_set_caps,
-//GO(gst_value_set_caps_features,
-//GO(gst_value_set_double_range,
-//GO(gst_value_set_flagset,
-//GO(gst_value_set_fraction,
-//GO(gst_value_set_fraction_range,
-//GO(gst_value_set_fraction_range_full,
-//GO(gst_value_set_int64_range,
-//GO(gst_value_set_int64_range_step,
+GO(gst_value_set_caps_features, vFpp)
+GO(gst_value_set_double_range, vFpdd)
+GO(gst_value_set_flagset, vFpuu)
+GO(gst_value_set_fraction, vFpii)
+GO(gst_value_set_fraction_range, vFppp)
+GO(gst_value_set_fraction_range_full, vFpiiii)
+GO(gst_value_set_int64_range, vFpll)
+GO(gst_value_set_int64_range_step, vFplll)
//GO(gst_value_set_int_range,
-//GO(gst_value_set_int_range_step,
-//GO(gst_value_set_structure,
-//GO(gst_value_subtract,
+GO(gst_value_set_int_range_step, vFpiii)
+GO(gst_value_set_structure, vFpp)
+GO(gst_value_subtract, iFppp)
//GO(gst_value_union,
GO(gst_version, vFpppp)
GO(gst_version_string, pFv)
diff --git a/src/wrapped/wrappedgstvideo_private.h b/src/wrapped/wrappedgstvideo_private.h
index 1027f9b..27eb4ae 100644
--- a/src/wrapped/wrappedgstvideo_private.h
+++ b/src/wrapped/wrappedgstvideo_private.h
@@ -17,16 +17,16 @@
//GO(gst_buffer_get_video_meta,
//GO(gst_buffer_get_video_meta_id,
//GO(gst_buffer_get_video_region_of_interest_meta_id,
-//GO(gst_buffer_pool_config_get_video_alignment,
+GO(gst_buffer_pool_config_get_video_alignment, iFpp)
GO(gst_buffer_pool_config_set_video_alignment, vFpp)
//GO(gst_color_balance_channel_get_type,
-//GO(gst_color_balance_get_balance_type,
+GO(gst_color_balance_get_balance_type, uFp)
//GO(gst_color_balance_get_type,
-//GO(gst_color_balance_get_value,
-//GO(gst_color_balance_list_channels,
+GO(gst_color_balance_get_value, iFpp)
+GO(gst_color_balance_list_channels, pFp)
//GO(gst_color_balance_set_value,
//GO(gst_color_balance_type_get_type,
-//GO(gst_color_balance_value_changed,
+GO(gst_color_balance_value_changed, vFppi)
//GO(gst_is_video_overlay_prepare_window_handle_message,
//GO(gst_navigation_command_get_type,
//GO(gst_navigation_event_get_type,
@@ -56,11 +56,11 @@ GO(gst_buffer_pool_config_set_video_alignment, vFpp)
//GO(gst_navigation_query_set_commands,
//GO(gst_navigation_query_set_commandsv,
//GO(gst_navigation_query_type_get_type,
-//GO(gst_navigation_send_command,
-//GO(gst_navigation_send_event,
-//GO(gst_navigation_send_key_event,
-//GO(gst_navigation_send_mouse_event,
-//GO(gst_navigation_send_mouse_scroll_event,
+GO(gst_navigation_send_command, vFpu)
+GO(gst_navigation_send_event, vFpp)
+GO(gst_navigation_send_key_event, vFppp)
+GO(gst_navigation_send_mouse_event, vFppidd)
+GO(gst_navigation_send_mouse_scroll_event, vFpdddd)
//GO(gst_video_afd_meta_api_get_type,
//GO(gst_video_afd_meta_get_info,
//GO(gst_video_afd_spec_get_type,
@@ -87,7 +87,7 @@ GO(gst_video_alignment_reset, vFp)
//GO(gst_video_buffer_flags_get_type,
//GO(gst_video_buffer_pool_get_type,
GO(gst_video_buffer_pool_new, pFv)
-//GO(gst_video_calculate_display_ratio,
+GO(gst_video_calculate_display_ratio, iFppuuuuuu)
//GO(gst_video_caption_meta_api_get_type,
//GO(gst_video_caption_meta_get_info,
//GO(gst_video_caption_type_from_caps,
@@ -97,12 +97,12 @@ GO(gst_video_buffer_pool_new, pFv)
//GO(gst_video_chroma_from_string,
//GO(gst_video_chroma_method_get_type,
//GO(gst_video_chroma_mode_get_type,
-//GO(gst_video_chroma_resample,
-//GO(gst_video_chroma_resample_free,
-//GO(gst_video_chroma_resample_get_info,
-//GO(gst_video_chroma_resample_new,
+GO(gst_video_chroma_resample, vFppi)
+GO(gst_video_chroma_resample_free, vFp)
+GO(gst_video_chroma_resample_get_info, vFppp)
+GO(gst_video_chroma_resample_new, pFuuuuii)
//GO(gst_video_chroma_site_get_type,
-//GO(gst_video_chroma_to_string,
+GO(gst_video_chroma_to_string, pFu)
//GO(gst_video_codec_frame_get_type,
//GO(gst_video_codec_frame_get_user_data,
//GO(gst_video_codec_frame_ref,
@@ -111,32 +111,32 @@ GO(gst_video_buffer_pool_new, pFv)
//GO(gst_video_codec_state_get_type,
//GO(gst_video_codec_state_ref,
//GO(gst_video_codec_state_unref,
-//GO(gst_video_colorimetry_from_string,
-//GO(gst_video_colorimetry_is_equal,
-//GO(gst_video_colorimetry_matches,
-//GO(gst_video_colorimetry_to_string,
-//GO(gst_video_color_matrix_from_iso,
-//GO(gst_video_color_matrix_get_Kr_Kb,
+GO(gst_video_colorimetry_from_string, iFpp)
+GO(gst_video_colorimetry_is_equal, iFpp)
+GO(gst_video_colorimetry_matches, iFpp)
+GO(gst_video_colorimetry_to_string, pFp)
+GO(gst_video_color_matrix_from_iso, uFu)
+GO(gst_video_color_matrix_get_Kr_Kb, iFupp)
//GO(gst_video_color_matrix_get_type,
-//GO(gst_video_color_matrix_to_iso,
-//GO(gst_video_color_primaries_from_iso,
-//GO(gst_video_color_primaries_get_info,
+GO(gst_video_color_matrix_to_iso, uFu)
+GO(gst_video_color_primaries_from_iso, uFu)
+GO(gst_video_color_primaries_get_info, pFu)
//GO(gst_video_color_primaries_get_type,
-//GO(gst_video_color_primaries_to_iso,
+GO(gst_video_color_primaries_to_iso, uFu)
//GO(gst_video_color_range_get_type,
//GO(gst_video_color_range_offsets,
//GO(gst_video_color_transfer_decode,
//GO(gst_video_color_transfer_encode,
//GO(gst_video_content_light_level_add_to_caps,
//GO(gst_video_content_light_level_from_caps,
-//GO(gst_video_content_light_level_from_string,
-//GO(gst_video_content_light_level_init,
-//GO(gst_video_content_light_level_to_string,
+GO(gst_video_content_light_level_from_string, iFpp)
+GO(gst_video_content_light_level_init, vFp)
+GO(gst_video_content_light_level_to_string, pFp)
//GO(gst_video_converter_frame,
//GO(gst_video_converter_free,
-//GO(gst_video_converter_get_config,
+GO(gst_video_converter_get_config, pFp)
//GO(gst_video_converter_new,
-//GO(gst_video_converter_set_config,
+GO(gst_video_converter_set_config, iFpp)
//GO(gst_video_convert_sample,
//GO(gst_video_convert_sample_async,
//GO(gst_video_crop_meta_api_get_type,
@@ -178,10 +178,10 @@ GO(gst_video_buffer_pool_new, pFv)
//GO(gst_video_decoder_set_use_default_pad_acceptcaps,
//GO(gst_video_direction_get_type,
//GO(gst_video_dither_flags_get_type,
-//GO(gst_video_dither_free,
-//GO(gst_video_dither_line,
+GO(gst_video_dither_free, vFp)
+GO(gst_video_dither_line, vFppuuu)
//GO(gst_video_dither_method_get_type,
-//GO(gst_video_dither_new,
+GO(gst_video_dither_new, pFuuupu)
//GO(gst_video_encoder_allocate_output_buffer,
//GO(gst_video_encoder_allocate_output_frame,
//GO(gst_video_encoder_finish_frame,
@@ -212,22 +212,22 @@ GO(gst_video_buffer_pool_new, pFv)
//GO(gst_video_event_parse_downstream_force_key_unit,
//GO(gst_video_event_parse_still_frame,
//GO(gst_video_event_parse_upstream_force_key_unit,
-GO(gst_video_field_order_from_string, iFp)
+GO(gst_video_field_order_from_string, uFp)
GO(gst_video_field_order_get_type, pFv)
-GO(gst_video_field_order_to_string, pFi)
+GO(gst_video_field_order_to_string, pFu)
GO(gst_video_filter_get_type, pFv)
GO(gst_video_flags_get_type, pFv)
GO(gst_video_format_flags_get_type, pFv)
-GO(gst_video_format_from_fourcc, iFu)
-//GO(gst_video_format_from_masks,
-//GO(gst_video_format_from_string,
+GO(gst_video_format_from_fourcc, uFu)
+GO(gst_video_format_from_masks, uFiiiuuuu)
+GO(gst_video_format_from_string, uFp)
//GO(gst_video_format_get_info,
-//GO(gst_video_format_get_palette,
+GO(gst_video_format_get_palette, pFup)
//GO(gst_video_format_get_type,
//GO(gst_video_format_info_component,
-//GO(gst_video_formats_raw,
-GO(gst_video_format_to_fourcc, uFi)
-GO(gst_video_format_to_string, pFi)
+GO(gst_video_formats_raw, pFp)
+GO(gst_video_format_to_fourcc, uFu)
+GO(gst_video_format_to_string, pFu)
GO(gst_video_frame_copy, iFpp)
//GO(gst_video_frame_copy_plane,
//GO(gst_video_frame_flags_get_type,
@@ -239,7 +239,7 @@ GO(gst_video_frame_unmap, vFp)
//GO(gst_video_gl_texture_upload_meta_api_get_type,
//GO(gst_video_gl_texture_upload_meta_get_info,
//GO(gst_video_gl_texture_upload_meta_upload,
-//GO(gst_video_guess_framerate,
+GO(gst_video_guess_framerate, iFLpp)
GO(gst_video_info_align, iFpp)
GO(gst_video_info_align_full, iFppp)
GO(gst_video_info_convert, iFpiIip)
@@ -253,17 +253,17 @@ GO(gst_video_info_new, pFv)
GO(gst_video_info_set_format, iFpiuu)
GO(gst_video_info_set_interlaced_format, iFpiiuu)
GO(gst_video_info_to_caps, pFp)
-GO(gst_video_interlace_mode_from_string, iFp)
+GO(gst_video_interlace_mode_from_string, uFp)
GO(gst_video_interlace_mode_get_type, pFv)
-GO(gst_video_interlace_mode_to_string, pFi)
+GO(gst_video_interlace_mode_to_string, pFu)
//GO(gst_video_make_raw_caps,
//GO(gst_video_make_raw_caps_with_features,
//GO(gst_video_mastering_display_info_add_to_caps,
//GO(gst_video_mastering_display_info_from_caps,
-//GO(gst_video_mastering_display_info_from_string,
-//GO(gst_video_mastering_display_info_init,
-//GO(gst_video_mastering_display_info_is_equal,
-//GO(gst_video_mastering_display_info_to_string,
+GO(gst_video_mastering_display_info_from_string, iFpp)
+GO(gst_video_mastering_display_info_init, vFp)
+GO(gst_video_mastering_display_info_is_equal, iFpp)
+GO(gst_video_mastering_display_info_to_string, pFp)
//GO(gst_video_matrix_mode_get_type,
GO(gst_video_meta_api_get_type, pFv)
//GO(gst_video_meta_get_info,
@@ -271,66 +271,66 @@ GO(gst_video_meta_api_get_type, pFv)
//GO(gst_video_meta_get_plane_size,
//GO(gst_video_meta_map,
//GO(gst_video_meta_set_alignment,
-//GO(gst_video_meta_transform_scale_get_quark,
+GO(gst_video_meta_transform_scale_get_quark, uFv)
//GO(gst_video_meta_unmap,
//GO(gst_video_multiview_flagset_get_type,
//GO(gst_video_multiview_flags_get_type,
//GO(gst_video_multiview_frame_packing_get_type,
//GO(gst_video_multiview_get_doubled_height_modes,
-//GO(gst_video_multiview_get_doubled_size_modes,
+GO(gst_video_multiview_get_doubled_size_modes, pFv)
//GO(gst_video_multiview_get_doubled_width_modes,
//GO(gst_video_multiview_get_mono_modes,
//GO(gst_video_multiview_get_unpacked_modes,
-//GO(gst_video_multiview_guess_half_aspect,
-//GO(gst_video_multiview_mode_from_caps_string,
+GO(gst_video_multiview_guess_half_aspect, iFiuuuu)
+GO(gst_video_multiview_mode_from_caps_string, iFp)
//GO(gst_video_multiview_mode_get_type,
-//GO(gst_video_multiview_mode_to_caps_string,
+GO(gst_video_multiview_mode_to_caps_string, pFi)
//GO(gst_video_multiview_video_info_change_mode,
//GO(gst_video_orientation_get_hcenter,
//GO(gst_video_orientation_get_hflip,
//GO(gst_video_orientation_get_type,
-//GO(gst_video_orientation_get_vcenter,
-//GO(gst_video_orientation_get_vflip,
+GO(gst_video_orientation_get_vcenter, iFpp)
+GO(gst_video_orientation_get_vflip, iFpp)
//GO(gst_video_orientation_method_get_type,
//GO(gst_video_orientation_set_hcenter,
//GO(gst_video_orientation_set_hflip,
-//GO(gst_video_orientation_set_vcenter,
-//GO(gst_video_orientation_set_vflip,
-//GO(gst_video_overlay_composition_add_rectangle,
+GO(gst_video_orientation_set_vcenter, iFpi)
+GO(gst_video_orientation_set_vflip, iFpi)
+GO(gst_video_overlay_composition_add_rectangle, vFpp)
//GO(gst_video_overlay_composition_blend,
//GO(gst_video_overlay_composition_copy,
-//GO(gst_video_overlay_composition_get_rectangle,
-//GO(gst_video_overlay_composition_get_seqnum,
+GO(gst_video_overlay_composition_get_rectangle, pFpu)
+GO(gst_video_overlay_composition_get_seqnum, uFp)
//GO(gst_video_overlay_composition_get_type,
-//GO(gst_video_overlay_composition_make_writable,
+GO(gst_video_overlay_composition_make_writable, pFp)
//GO(gst_video_overlay_composition_meta_api_get_type,
//GO(gst_video_overlay_composition_meta_get_info,
-//GO(gst_video_overlay_composition_new,
+GO(gst_video_overlay_composition_new, pFp)
//GO(gst_video_overlay_composition_n_rectangles,
//GO(gst_video_overlay_expose,
//GO(gst_video_overlay_format_flags_get_type,
//GO(gst_video_overlay_get_type,
-//GO(gst_video_overlay_got_window_handle,
-//GO(gst_video_overlay_handle_events,
+GO(gst_video_overlay_got_window_handle, vFpL)
+GO(gst_video_overlay_handle_events, vFpi)
//GO(gst_video_overlay_install_properties,
-//GO(gst_video_overlay_prepare_window_handle,
-//GO(gst_video_overlay_rectangle_copy,
-//GO(gst_video_overlay_rectangle_get_flags,
-//GO(gst_video_overlay_rectangle_get_global_alpha,
+GO(gst_video_overlay_prepare_window_handle, vFp)
+GO(gst_video_overlay_rectangle_copy, pFp)
+GO(gst_video_overlay_rectangle_get_flags, uFp)
+GO(gst_video_overlay_rectangle_get_global_alpha, fFp)
//GO(gst_video_overlay_rectangle_get_pixels_argb,
//GO(gst_video_overlay_rectangle_get_pixels_ayuv,
//GO(gst_video_overlay_rectangle_get_pixels_raw,
//GO(gst_video_overlay_rectangle_get_pixels_unscaled_argb,
//GO(gst_video_overlay_rectangle_get_pixels_unscaled_ayuv,
//GO(gst_video_overlay_rectangle_get_pixels_unscaled_raw,
-//GO(gst_video_overlay_rectangle_get_render_rectangle,
-//GO(gst_video_overlay_rectangle_get_seqnum,
+GO(gst_video_overlay_rectangle_get_render_rectangle, iFppppp)
+GO(gst_video_overlay_rectangle_get_seqnum, uFp)
//GO(gst_video_overlay_rectangle_get_type,
//GO(gst_video_overlay_rectangle_new_raw,
-//GO(gst_video_overlay_rectangle_set_global_alpha,
-//GO(gst_video_overlay_rectangle_set_render_rectangle,
-//GO(gst_video_overlay_set_property,
-//GO(gst_video_overlay_set_render_rectangle,
+GO(gst_video_overlay_rectangle_set_global_alpha, vFpf)
+GO(gst_video_overlay_rectangle_set_render_rectangle, vFpiiuu)
+GO(gst_video_overlay_set_property, iFpiup)
+GO(gst_video_overlay_set_render_rectangle, iFpiiii)
//GO(gst_video_overlay_set_window_handle,
//GO(gst_video_pack_flags_get_type,
//GO(gst_video_primaries_mode_get_type,
@@ -338,69 +338,69 @@ GO(gst_video_meta_api_get_type, pFv)
//GO(gst_video_region_of_interest_meta_api_get_type,
//GO(gst_video_region_of_interest_meta_get_info,
//GO(gst_video_region_of_interest_meta_get_param,
-//GO(gst_video_resampler_clear,
+GO(gst_video_resampler_clear, vFp)
//GO(gst_video_resampler_flags_get_type,
-//GO(gst_video_resampler_init,
+GO(gst_video_resampler_init, iFpuuuuduup)
//GO(gst_video_resampler_method_get_type,
-//GO(gst_video_scaler_2d,
-//GO(gst_video_scaler_combine_packed_YUV,
+GO(gst_video_scaler_2d, vFppupipiuuuu)
+GO(gst_video_scaler_combine_packed_YUV, pFppuu)
//GO(gst_video_scaler_flags_get_type,
-//GO(gst_video_scaler_free,
-//GO(gst_video_scaler_get_coeff,
-//GO(gst_video_scaler_get_max_taps,
-//GO(gst_video_scaler_horizontal,
-//GO(gst_video_scaler_new,
-//GO(gst_video_scaler_vertical,
+GO(gst_video_scaler_free, vFp)
+GO(gst_video_scaler_get_coeff, pFpupp)
+GO(gst_video_scaler_get_max_taps, uFp)
+GO(gst_video_scaler_horizontal, vFpuppuu)
+GO(gst_video_scaler_new, pFuuuuup)
+GO(gst_video_scaler_vertical, vFpuppuu)
//GO(gst_video_sink_center_rect,
//GO(gst_video_sink_get_type,
-//GO(gst_video_tile_get_index,
+GO(gst_video_tile_get_index, uFuiiii)
//GO(gst_video_tile_mode_get_type,
//GO(gst_video_tile_type_get_type,
-//GO(gst_video_time_code_add_frames,
-//GO(gst_video_time_code_add_interval,
+GO(gst_video_time_code_add_frames, vFpl)
+GO(gst_video_time_code_add_interval, pFpp)
//GO(gst_video_time_code_clear,
-//GO(gst_video_time_code_compare,
-//GO(gst_video_time_code_copy,
+GO(gst_video_time_code_compare, iFpp)
+GO(gst_video_time_code_copy, pFp)
//GO(gst_video_time_code_flags_get_type,
-//GO(gst_video_time_code_frames_since_daily_jam,
+GO(gst_video_time_code_frames_since_daily_jam, LFp)
//GO(gst_video_time_code_free,
//GO(gst_video_time_code_get_type,
-//GO(gst_video_time_code_increment_frame,
-//GO(gst_video_time_code_init,
-//GO(gst_video_time_code_init_from_date_time,
-//GO(gst_video_time_code_init_from_date_time_full,
-//GO(gst_video_time_code_interval_clear,
-//GO(gst_video_time_code_interval_copy,
+GO(gst_video_time_code_increment_frame, vFp)
+GO(gst_video_time_code_init, vFpuupuuuuuu)
+GO(gst_video_time_code_init_from_date_time, vFpuupuu)
+GO(gst_video_time_code_init_from_date_time_full, iFpuupuu)
+GO(gst_video_time_code_interval_clear, vFp)
+GO(gst_video_time_code_interval_copy, pFp)
//GO(gst_video_time_code_interval_free,
//GO(gst_video_time_code_interval_get_type,
-//GO(gst_video_time_code_interval_init,
-//GO(gst_video_time_code_interval_new,
-//GO(gst_video_time_code_interval_new_from_string,
-//GO(gst_video_time_code_is_valid,
+GO(gst_video_time_code_interval_init, vFpuuuu)
+GO(gst_video_time_code_interval_new, pFuuuu)
+GO(gst_video_time_code_interval_new_from_string, pFp)
+GO(gst_video_time_code_is_valid, iFp)
//GO(gst_video_time_code_meta_api_get_type,
//GO(gst_video_time_code_meta_get_info,
-//GO(gst_video_time_code_new,
-//GO(gst_video_time_code_new_empty,
+GO(gst_video_time_code_new, pFuupuuuuuu)
+GO(gst_video_time_code_new_empty, pFv)
//GO(gst_video_time_code_new_from_date_time,
-//GO(gst_video_time_code_new_from_date_time_full,
-//GO(gst_video_time_code_new_from_string,
+GO(gst_video_time_code_new_from_date_time_full, pFuupuu)
+GO(gst_video_time_code_new_from_string, pFp)
//GO(gst_video_time_code_nsec_since_daily_jam,
-//GO(gst_video_time_code_to_date_time,
-//GO(gst_video_time_code_to_string,
-//GO(gst_video_transfer_function_from_iso,
+GO(gst_video_time_code_to_date_time, pFp)
+GO(gst_video_time_code_to_string, pFp)
+GO(gst_video_transfer_function_from_iso, uFu)
//GO(gst_video_transfer_function_get_type,
-//GO(gst_video_transfer_function_is_equivalent,
-//GO(gst_video_transfer_function_to_iso,
-//GO(gst_video_vbi_encoder_add_ancillary,
-//GO(gst_video_vbi_encoder_copy,
-//GO(gst_video_vbi_encoder_free,
+GO(gst_video_transfer_function_is_equivalent, iFuuuu)
+GO(gst_video_transfer_function_to_iso, uFu)
+GO(gst_video_vbi_encoder_add_ancillary, iFpiCCpu)
+GO(gst_video_vbi_encoder_copy, pFp)
+GO(gst_video_vbi_encoder_free, vFp)
//GO(gst_video_vbi_encoder_get_type,
-//GO(gst_video_vbi_encoder_new,
-//GO(gst_video_vbi_encoder_write_line,
-//GO(gst_video_vbi_parser_add_line,
-//GO(gst_video_vbi_parser_copy,
-//GO(gst_video_vbi_parser_free,
-//GO(gst_video_vbi_parser_get_ancillary,
+GO(gst_video_vbi_encoder_new, pFuu)
+GO(gst_video_vbi_encoder_write_line, vFpp)
+GO(gst_video_vbi_parser_add_line, vFpp)
+GO(gst_video_vbi_parser_copy, pFp)
+GO(gst_video_vbi_parser_free, vFp)
+GO(gst_video_vbi_parser_get_ancillary, uFpp)
//GO(gst_video_vbi_parser_get_type,
-//GO(gst_video_vbi_parser_new,
+GO(gst_video_vbi_parser_new, pFuu)
//GO(gst_video_vbi_parser_result_get_type,
diff --git a/src/wrapped/wrappedgthread2.c b/src/wrapped/wrappedgthread2.c
index 6e66c72..6e66c72 100755..100644
--- a/src/wrapped/wrappedgthread2.c
+++ b/src/wrapped/wrappedgthread2.c
diff --git a/src/wrapped/wrappedgthread2_private.h b/src/wrapped/wrappedgthread2_private.h
index fd8c61c..fd8c61c 100755..100644
--- a/src/wrapped/wrappedgthread2_private.h
+++ b/src/wrapped/wrappedgthread2_private.h
diff --git a/src/wrapped/wrappedgtk3.c b/src/wrapped/wrappedgtk3.c
index 46adf78..87a7bd7 100755..100644
--- a/src/wrapped/wrappedgtk3.c
+++ b/src/wrapped/wrappedgtk3.c
@@ -38,12 +38,15 @@ typedef void (*vFpipV_t)(void*, int, void*, ...);
#define ADDED_FUNCTIONS() \
GO(g_type_class_ref, pFL_t) \
GO(g_type_class_unref, vFp_t) \
+GO(gtk_application_window_get_type, LFv_t) \
GO(gtk_bin_get_type, LFv_t) \
GO(gtk_widget_get_type, LFv_t) \
GO(gtk_button_get_type, LFv_t) \
GO(gtk_container_get_type, LFv_t) \
GO(gtk_misc_get_type, LFv_t) \
GO(gtk_label_get_type, LFv_t) \
+GO(gtk_list_box_get_type, LFv_t) \
+GO(gtk_list_box_row_get_type, LFv_t) \
GO(gtk_tree_view_get_type, LFv_t) \
GO(gtk_window_get_type, LFv_t) \
GO(gtk_table_get_type, LFv_t) \
@@ -60,6 +63,12 @@ GO(gtk_progress_bar_get_type, LFv_t) \
GO(gtk_menu_shell_get_type, LFv_t) \
GO(gtk_menu_bar_get_type, LFv_t) \
GO(gtk_action_get_type, LFv_t) \
+GO(gtk_application_get_type, LFv_t) \
+GO(gtk_grid_get_type, LFv_t) \
+GO(gtk_event_controller_get_type, LFv_t) \
+GO(gtk_gesture_get_type, LFv_t) \
+GO(gtk_gesture_single_get_type, LFv_t) \
+GO(gtk_gesture_long_press_get_type, LFv_t) \
GO(gtk_dialog_add_button, pFppi_t) \
GO(gtk_spin_button_get_value, dFp_t) \
GO(gtk_builder_lookup_callback_symbol, pFpp_t) \
@@ -90,10 +99,10 @@ GO(3)
// GtkMenuDetachFunc
#define GO(A) \
-static uintptr_t my_menudetach_fct_##A = 0; \
-static void my_menudetach_##A(void* widget, void* menu) \
-{ \
- RunFunction(my_context, my_menudetach_fct_##A, 2, widget, menu);\
+static uintptr_t my_menudetach_fct_##A = 0; \
+static void my_menudetach_##A(void* widget, void* menu) \
+{ \
+ RunFunctionFmt(my_menudetach_fct_##A, "pp", widget, menu); \
}
SUPER()
#undef GO
@@ -113,10 +122,10 @@ static void* findMenuDetachFct(void* fct)
// GtkMenuPositionFunc
#define GO(A) \
-static uintptr_t my_menuposition_fct_##A = 0; \
-static void my_menuposition_##A(void* menu, void* x, void* y, void* push_in, void* data) \
-{ \
- RunFunction(my_context, my_menuposition_fct_##A, 5, menu, x, y, push_in, data);\
+static uintptr_t my_menuposition_fct_##A = 0; \
+static void my_menuposition_##A(void* menu, void* x, void* y, void* push_in, void* data) \
+{ \
+ RunFunctionFmt(my_menuposition_fct_##A, "ppppp", menu, x, y, push_in, data); \
}
SUPER()
#undef GO
@@ -136,10 +145,10 @@ static void* findMenuPositionFct(void* fct)
// GtkFunction
#define GO(A) \
-static uintptr_t my3_gtkfunction_fct_##A = 0; \
-static int my3_gtkfunction_##A(void* data) \
-{ \
- return RunFunction(my_context, my3_gtkfunction_fct_##A, 1, data);\
+static uintptr_t my3_gtkfunction_fct_##A = 0; \
+static int my3_gtkfunction_##A(void* data) \
+{ \
+ return RunFunctionFmt(my3_gtkfunction_fct_##A, "p", data); \
}
SUPER()
#undef GO
@@ -159,10 +168,10 @@ static void* findGtkFunctionFct(void* fct)
// GtkClipboardGetFunc
#define GO(A) \
-static uintptr_t my_clipboardget_fct_##A = 0; \
-static void my_clipboardget_##A(void* clipboard, void* selection, uint32_t info, void* data) \
-{ \
- RunFunction(my_context, my_clipboardget_fct_##A, 4, clipboard, selection, info, data);\
+static uintptr_t my_clipboardget_fct_##A = 0; \
+static void my_clipboardget_##A(void* clipboard, void* selection, uint32_t info, void* data) \
+{ \
+ RunFunctionFmt(my_clipboardget_fct_##A, "ppup", clipboard, selection, info, data); \
}
SUPER()
#undef GO
@@ -182,10 +191,10 @@ static void* findClipboadGetFct(void* fct)
// GtkClipboardClearFunc
#define GO(A) \
-static uintptr_t my_clipboardclear_fct_##A = 0; \
-static void my_clipboardclear_##A(void* clipboard, void* data) \
-{ \
- RunFunction(my_context, my_clipboardclear_fct_##A, 2, clipboard, data);\
+static uintptr_t my_clipboardclear_fct_##A = 0; \
+static void my_clipboardclear_##A(void* clipboard, void* data) \
+{ \
+ RunFunctionFmt(my_clipboardclear_fct_##A, "pp", clipboard, data); \
}
SUPER()
#undef GO
@@ -204,11 +213,11 @@ static void* findClipboadClearFct(void* fct)
}
// GtkCallback
-#define GO(A) \
-static uintptr_t my3_gtkcallback_fct_##A = 0; \
-static void my3_gtkcallback_##A(void* widget, void* data) \
-{ \
- RunFunction(my_context, my3_gtkcallback_fct_##A, 2, widget, data);\
+#define GO(A) \
+static uintptr_t my3_gtkcallback_fct_##A = 0; \
+static void my3_gtkcallback_##A(void* widget, void* data) \
+{ \
+ RunFunctionFmt(my3_gtkcallback_fct_##A, "pp", widget, data); \
}
SUPER()
#undef GO
@@ -228,10 +237,10 @@ static void* findGtkCallbackFct(void* fct)
// GtkTextCharPredicate
#define GO(A) \
-static uintptr_t my_textcharpredicate_fct_##A = 0; \
-static int my_textcharpredicate_##A(uint32_t ch, void* data) \
-{ \
- return (int)RunFunction(my_context, my_textcharpredicate_fct_##A, 2, ch, data);\
+static uintptr_t my_textcharpredicate_fct_##A = 0; \
+static int my_textcharpredicate_##A(uint32_t ch, void* data) \
+{ \
+ return (int)RunFunctionFmt(my_textcharpredicate_fct_##A, "up", ch, data); \
}
SUPER()
#undef GO
@@ -251,10 +260,10 @@ static void* findGtkTextCharPredicateFct(void* fct)
// Toolbar
#define GO(A) \
-static uintptr_t my_toolbar_fct_##A = 0; \
-static void my_toolbar_##A(void* widget, void* data) \
-{ \
- RunFunction(my_context, my_toolbar_fct_##A, 2, widget, data);\
+static uintptr_t my_toolbar_fct_##A = 0; \
+static void my_toolbar_##A(void* widget, void* data) \
+{ \
+ RunFunctionFmt(my_toolbar_fct_##A, "pp", widget, data); \
}
SUPER()
#undef GO
@@ -274,10 +283,10 @@ static void* findToolbarFct(void* fct)
// Builder
#define GO(A) \
-static uintptr_t my_builderconnect_fct_##A = 0; \
-static void my_builderconnect_##A(void* builder, void* object, void* signal, void* handler, void* connect, int flags, void* data) \
-{ \
- RunFunction(my_context, my_builderconnect_fct_##A, 7, builder, object, signal, handler, connect, flags, data);\
+static uintptr_t my_builderconnect_fct_##A = 0; \
+static void my_builderconnect_##A(void* builder, void* object, void* signal, void* handler, void* connect, int flags, void* data) \
+{ \
+ RunFunctionFmt(my_builderconnect_fct_##A, "pppppip", builder, object, signal, handler, connect, flags, data); \
}
SUPER()
#undef GO
@@ -297,10 +306,10 @@ static void* findBuilderConnectFct(void* fct)
// GtkTreeViewSearchEqualFunc
#define GO(A) \
-static uintptr_t my_GtkTreeViewSearchEqualFunc_fct_##A = 0; \
-static int my_GtkTreeViewSearchEqualFunc_##A(void* model, int column, void* key, void* iter, void* data) \
-{ \
- return RunFunction(my_context, my_GtkTreeViewSearchEqualFunc_fct_##A, 5, model, column, key, iter, data); \
+static uintptr_t my_GtkTreeViewSearchEqualFunc_fct_##A = 0; \
+static int my_GtkTreeViewSearchEqualFunc_##A(void* model, int column, void* key, void* iter, void* data) \
+{ \
+ return RunFunctionFmt(my_GtkTreeViewSearchEqualFunc_fct_##A, "pippp", model, column, key, iter, data); \
}
SUPER()
#undef GO
@@ -319,10 +328,10 @@ static void* findGtkTreeViewSearchEqualFuncFct(void* fct)
}
// GtkTreeCellDataFunc
#define GO(A) \
-static uintptr_t my_GtkTreeCellDataFunc_fct_##A = 0; \
-static void my_GtkTreeCellDataFunc_##A(void* tree, void* cell, void* model, void* iter, void* data) \
-{ \
- RunFunction(my_context, my_GtkTreeCellDataFunc_fct_##A, 5, tree, cell, model, iter, data); \
+static uintptr_t my_GtkTreeCellDataFunc_fct_##A = 0; \
+static void my_GtkTreeCellDataFunc_##A(void* tree, void* cell, void* model, void* iter, void* data) \
+{ \
+ RunFunctionFmt(my_GtkTreeCellDataFunc_fct_##A, "ppppp", tree, cell, model, iter, data); \
}
SUPER()
#undef GO
@@ -342,10 +351,10 @@ static void* findGtkTreeCellDataFuncFct(void* fct)
// GDestroyNotify
#define GO(A) \
-static uintptr_t my_GDestroyNotify_fct_##A = 0; \
-static void my_GDestroyNotify_##A(void* data) \
-{ \
- RunFunction(my_context, my_GDestroyNotify_fct_##A, 1, data); \
+static uintptr_t my_GDestroyNotify_fct_##A = 0; \
+static void my_GDestroyNotify_##A(void* data) \
+{ \
+ RunFunctionFmt(my_GDestroyNotify_fct_##A, "p", data); \
}
SUPER()
#undef GO
@@ -365,10 +374,10 @@ static void* findGDestroyNotifyFct(void* fct)
// GtkTreeIterCompareFunc
#define GO(A) \
-static uintptr_t my_GtkTreeIterCompareFunc_fct_##A = 0; \
-static int my_GtkTreeIterCompareFunc_##A(void* model, void* a, void* b, void* data) \
-{ \
- return RunFunction(my_context, my_GtkTreeIterCompareFunc_fct_##A, 4, model, a, b, data); \
+static uintptr_t my_GtkTreeIterCompareFunc_fct_##A = 0; \
+static int my_GtkTreeIterCompareFunc_##A(void* model, void* a, void* b, void* data) \
+{ \
+ return RunFunctionFmt(my_GtkTreeIterCompareFunc_fct_##A, "pppp", model, a, b, data); \
}
SUPER()
#undef GO
@@ -388,10 +397,10 @@ static void* findGtkTreeIterCompareFuncFct(void* fct)
// GtkPrinterFunc
#define GO(A) \
-static uintptr_t my_GtkPrinterFunc_fct_##A = 0; \
-static int my_GtkPrinterFunc_##A(void* printer, void* data) \
-{ \
- return RunFunction(my_context, my_GtkPrinterFunc_fct_##A, 2, printer, data); \
+static uintptr_t my_GtkPrinterFunc_fct_##A = 0; \
+static int my_GtkPrinterFunc_##A(void* printer, void* data) \
+{ \
+ return RunFunctionFmt(my_GtkPrinterFunc_fct_##A, "pp", printer, data); \
}
SUPER()
#undef GO
@@ -411,10 +420,10 @@ static void* findGtkPrinterFuncFct(void* fct)
// GtkPrintJobCompleteHunc
#define GO(A) \
-static uintptr_t my_GtkPrintJobCompleteHunc_fct_##A = 0; \
-static void my_GtkPrintJobCompleteHunc_##A(void* job, void* data, void* error) \
-{ \
- RunFunction(my_context, my_GtkPrintJobCompleteHunc_fct_##A, 3, job, data, error); \
+static uintptr_t my_GtkPrintJobCompleteHunc_fct_##A = 0; \
+static void my_GtkPrintJobCompleteHunc_##A(void* job, void* data, void* error) \
+{ \
+ RunFunctionFmt(my_GtkPrintJobCompleteHunc_fct_##A, "ppp", job, data, error); \
}
SUPER()
#undef GO
@@ -432,6 +441,30 @@ static void* findGtkPrintJobCompleteHuncFct(void* fct)
return NULL;
}
+
+// GtkClipboardTextReceivedFunc
+#define GO(A) \
+static uintptr_t my_GtkClipboardTextReceivedFunc_fct_##A = 0; \
+static void my_GtkClipboardTextReceivedFunc_##A(void* clipboard, void* text, void* data) \
+{ \
+ RunFunctionFmt(my_GtkClipboardTextReceivedFunc_fct_##A, "ppp", clipboard, text, data); \
+}
+SUPER()
+#undef GO
+static void* findGtkClipboardTextReceivedFuncFct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_GtkClipboardTextReceivedFunc_fct_##A == (uintptr_t)fct) return my_GtkClipboardTextReceivedFunc_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_GtkClipboardTextReceivedFunc_fct_##A == 0) {my_GtkClipboardTextReceivedFunc_fct_##A = (uintptr_t)fct; return my_GtkClipboardTextReceivedFunc_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for gtk-3 GtkClipboardTextReceivedFunc callback\n");
+ return NULL;
+}
+
#undef SUPER
/*
EXPORT void my3_gtk_dialog_add_buttons(x64emu_t* emu, void* dialog, void* first, uintptr_t* b)
@@ -524,7 +557,7 @@ EXPORT int my3_gtk_clipboard_set_with_owner(x64emu_t* emu, void* clipboard, void
static void* my_translate_func(void* path, my_signal_t* sig)
{
- return (void*)RunFunction(my_context, sig->c_handler, 2, path, sig->data);
+ return (void*)RunFunctionFmt(sig->c_handler, "pp", path, sig->data) ;
}
EXPORT void my3_gtk_stock_set_translate_func(x64emu_t* emu, void* domain, void* f, void* data, void* notify)
@@ -630,7 +663,7 @@ typedef struct my_connectargs_s {
//defined in gobject2...
uintptr_t my_g_signal_connect_object(x64emu_t* emu, void* instance, void* detailed, void* c_handler, void* object, uint32_t flags);
uintptr_t my_g_signal_connect_data(x64emu_t* emu, void* instance, void* detailed, void* c_handler, void* data, void* closure, uint32_t flags);
-static void my3_gtk_builder_connect_signals_default(void* builder, void* object,
+static void my3_gtk_builder_connect_signals_default(void* builder, void* object,
char* signal_name, char* handler_name,
void* connect_object, uint32_t flags, my_connectargs_t* args)
{
@@ -714,6 +747,11 @@ EXPORT void my3_gtk_container_foreach(x64emu_t* emu, void* container, void* cb,
my->gtk_container_foreach(container, findGtkCallbackFct(cb), data);
}
+EXPORT void my3_gtk_clipboard_request_text(x64emu_t* emu, void* clipboard, void* f, void* data)
+{
+ my->gtk_clipboard_request_text(clipboard, findGtkClipboardTextReceivedFuncFct(f), data);
+}
+
#define PRE_INIT \
if(box64_nogtk) \
return -1;
@@ -722,11 +760,25 @@ EXPORT void my3_gtk_container_foreach(x64emu_t* emu, void* container, void* cb,
libname = lib->name; \
getMy(lib); \
SETALT(my3_); \
+ SetGtkApplicationID(my->gtk_application_get_type()); \
SetGtkWidget3ID(my->gtk_widget_get_type()); \
SetGtkContainer3ID(my->gtk_container_get_type()); \
+ SetGtkBin3ID(my->gtk_bin_get_type()); \
+ SetGtkButton3ID(my->gtk_button_get_type()); \
+ SetGtkWindow3ID(my->gtk_window_get_type()); \
+ SetGtkApplicationWindowID(my->gtk_application_window_get_type());\
+ SetGtkListBoxID(my->gtk_list_box_get_type()); \
+ SetGtkListBoxRowID(my->gtk_list_box_row_get_type()); \
SetGtkTextView3ID(my->gtk_text_view_get_type()); \
+ SetGtkGrid3ID(my->gtk_grid_get_type()); \
+ SetGtkMisc3ID(my->gtk_misc_get_type()); \
+ SetGtkLabel3ID(my->gtk_label_get_type()); \
+ SetGtkEventControllerID(my->gtk_event_controller_get_type());\
+ SetGtkGestureID(my->gtk_gesture_get_type()); \
+ SetGtkGestureSingleID(my->gtk_gesture_single_get_type()); \
+ SetGtkGestureLongPressID(my->gtk_gesture_long_press_get_type());\
SetGtkActionID(my->gtk_action_get_type()); \
- setNeededLibs(lib, 2, "libgdk-3.so.0", "libpangocairo-1.0.so.0");
+ setNeededLibs(lib, 3, "libgdk-3.so.0", "libpangocairo-1.0.so.0", "libgio-2.0.so.0");
#define CUSTOM_FINI \
freeMy();
diff --git a/src/wrapped/wrappedgtk3_private.h b/src/wrapped/wrappedgtk3_private.h
index e5213a8..a6e4e3e 100755..100644
--- a/src/wrapped/wrappedgtk3_private.h
+++ b/src/wrapped/wrappedgtk3_private.h
@@ -9,7 +9,7 @@ GO(gtk_about_dialog_get_comments, pFp)
GO(gtk_about_dialog_get_copyright, pFp)
GO(gtk_about_dialog_get_documenters, pFp)
GO(gtk_about_dialog_get_license, pFp)
-GO(gtk_about_dialog_get_license_type, iFp)
+GO(gtk_about_dialog_get_license_type, uFp)
GO(gtk_about_dialog_get_logo, pFp)
GO(gtk_about_dialog_get_logo_icon_name, pFp)
GO(gtk_about_dialog_get_name, pFp)
@@ -28,7 +28,7 @@ GO(gtk_about_dialog_set_copyright, vFpp)
GO(gtk_about_dialog_set_documenters, vFpp)
//GO(gtk_about_dialog_set_email_hook,
GO(gtk_about_dialog_set_license, vFpp)
-GO(gtk_about_dialog_set_license_type, vFpi)
+GO(gtk_about_dialog_set_license_type, vFpu)
GO(gtk_about_dialog_set_logo, vFpp)
GO(gtk_about_dialog_set_logo_icon_name, vFpp)
GO(gtk_about_dialog_set_name, vFpp)
@@ -40,54 +40,54 @@ GO(gtk_about_dialog_set_website, vFpp)
GO(gtk_about_dialog_set_website_label, vFpp)
GO(gtk_about_dialog_set_wrap_license, vFpi)
GO(gtk_accelerator_get_default_mod_mask, uFv)
-GO(gtk_accelerator_get_label, pFui)
+GO(gtk_accelerator_get_label, pFuu)
GO(gtk_accelerator_name, pFui)
GO(gtk_accelerator_parse, vFppp)
GO(gtk_accelerator_set_default_mod_mask, vFu)
-GO(gtk_accelerator_valid, iFui)
+GO(gtk_accelerator_valid, iFuu)
GO(gtk_accel_flags_get_type, pFv)
-GO(gtk_accel_group_activate, iFpppui)
+GO(gtk_accel_group_activate, iFpupuu)
GO(gtk_accel_group_connect, vFpuiip) // Closure probably needs wrapping when not null
GO(gtk_accel_group_connect_by_path, vFppp)
GO(gtk_accel_group_disconnect, iFpp)
-GO(gtk_accel_group_disconnect_key, iFpui)
+GO(gtk_accel_group_disconnect_key, iFpuu)
//GOM(gtk_accel_group_find, pFEppp)
GO(gtk_accel_group_from_accel_closure, pFp)
GO(gtk_accel_group_get_is_locked, iFp)
-GO(gtk_accel_group_get_modifier_mask, iFp)
+GO(gtk_accel_group_get_modifier_mask, uFp)
GO(gtk_accel_group_get_type, pFv)
GO(gtk_accel_group_lock, vFp)
GO(gtk_accel_group_new, pFv)
-GO(gtk_accel_group_query, pFpuip)
+GO(gtk_accel_group_query, pFpuup)
GO(gtk_accel_groups_activate, iFpui)
GO(gtk_accel_groups_from_object, pFp)
GO(gtk_accel_group_unlock, vFp)
-//GO(gtk_accel_label_get_accel_widget,
-//GO(gtk_accel_label_get_accel_width,
+GO(gtk_accel_label_get_accel_widget, pFp)
+GO(gtk_accel_label_get_accel_width, uFp)
GO(gtk_accel_label_get_type, pFv)
//GO(gtk_accel_label_new,
-//GO(gtk_accel_label_refetch,
+GO(gtk_accel_label_refetch, iFp)
//GO(gtk_accel_label_set_accel_closure,
-//GO(gtk_accel_label_set_accel_widget,
-//GO(gtk_accel_map_add_entry,
+GO(gtk_accel_label_set_accel_widget, vFpp)
+GO(gtk_accel_map_add_entry, vFpuu)
//GO(gtk_accel_map_add_filter,
-//GO(gtk_accel_map_change_entry,
+GO(gtk_accel_map_change_entry, iFpuui)
//GO(gtk_accel_map_foreach,
//GO(gtk_accel_map_foreach_unfiltered,
-//GO(gtk_accel_map_get,
+GO(gtk_accel_map_get, pFv)
GO(gtk_accel_map_get_type, pFv)
//GO(gtk_accel_map_load,
//GO(gtk_accel_map_load_fd,
//GO(gtk_accel_map_load_scanner,
//GO(gtk_accel_map_lock_path,
-//GO(gtk_accel_map_lookup_entry,
+GO(gtk_accel_map_lookup_entry, iFpp)
//GO(gtk_accel_map_save,
-//GO(gtk_accel_map_save_fd,
+GO(gtk_accel_map_save_fd, vFi)
//GO(gtk_accel_map_unlock_path,
//GO(gtk_accessible_connect_widget_destroyed,
GO(gtk_accessible_get_type, pFv)
-//GO(gtk_accessible_get_widget,
-//GO(gtk_accessible_set_widget,
+GO(gtk_accessible_get_widget, pFp)
+GO(gtk_accessible_set_widget, vFpp)
GO(gtk_actionable_get_type, pFv)
//GO(gtk_action_activate,
GO(gtk_action_bar_get_type, pFv)
@@ -95,21 +95,21 @@ GO(gtk_action_bar_get_type, pFv)
//GO(gtk_action_block_activate_from,
//GO(gtk_action_connect_accelerator,
//GO(gtk_action_connect_proxy,
-//GO(gtk_action_create_icon,
-//GO(gtk_action_create_menu,
+GO(gtk_action_create_icon, pFpu)
+GO(gtk_action_create_menu, pFp)
//GO(gtk_action_create_menu_item,
//GO(gtk_action_create_tool_item,
//GO(gtk_action_disconnect_accelerator,
//GO(gtk_action_disconnect_proxy,
//GO(gtk_action_get_accel_closure,
//GO(gtk_action_get_accel_path,
-//GO(gtk_action_get_always_show_image,
-//GO(gtk_action_get_gicon,
-//GO(gtk_action_get_icon_name,
+GO(gtk_action_get_always_show_image, iFp)
+GO(gtk_action_get_gicon, pFp)
+GO(gtk_action_get_icon_name, pFp)
//GO(gtk_action_get_is_important,
//GO(gtk_action_get_label,
//GO(gtk_action_get_name,
-//GO(gtk_action_get_proxies,
+GO(gtk_action_get_proxies, pFp)
//GO(gtk_action_get_sensitive,
//GO(gtk_action_get_short_label,
//GO(gtk_action_get_stock_id,
@@ -121,32 +121,32 @@ GO(gtk_action_get_type, pFv)
//GO(gtk_action_group_add_action,
//GO(gtk_action_group_add_actions,
//GO(gtk_action_group_add_actions_full,
-//GO(gtk_action_group_add_action_with_accel,
+GO(gtk_action_group_add_action_with_accel, vFppp)
//GO(gtk_action_group_add_radio_actions,
//GO(gtk_action_group_add_radio_actions_full,
//GO(gtk_action_group_add_toggle_actions,
//GO(gtk_action_group_add_toggle_actions_full,
-//GO(gtk_action_group_get_action,
-//GO(gtk_action_group_get_name,
+GO(gtk_action_group_get_action, pFpp)
+GO(gtk_action_group_get_name, pFp)
//GO(gtk_action_group_get_sensitive,
GO(gtk_action_group_get_type, pFv)
-//GO(gtk_action_group_get_visible,
-//GO(gtk_action_group_list_actions,
-//GO(gtk_action_group_new,
+GO(gtk_action_group_get_visible, iFp)
+GO(gtk_action_group_list_actions, pFp)
+GO(gtk_action_group_new, pFp)
//GO(gtk_action_group_remove_action,
//GO(gtk_action_group_set_sensitive,
//GO(gtk_action_group_set_translate_func,
-//GO(gtk_action_group_set_translation_domain,
-//GO(gtk_action_group_set_visible,
-//GO(gtk_action_group_translate_string,
+GO(gtk_action_group_set_translation_domain, vFpp)
+GO(gtk_action_group_set_visible, vFpi)
+GO(gtk_action_group_translate_string, pFpp)
//GO(gtk_action_is_sensitive,
//GO(gtk_action_is_visible,
//GO(gtk_action_new,
-//GO(gtk_action_set_accel_group,
+GO(gtk_action_set_accel_group, vFpp)
//GO(gtk_action_set_accel_path,
-//GO(gtk_action_set_always_show_image,
-//GO(gtk_action_set_gicon,
-//GO(gtk_action_set_icon_name,
+GO(gtk_action_set_always_show_image, vFpi)
+GO(gtk_action_set_gicon, vFpp)
+GO(gtk_action_set_icon_name, vFpp)
//GO(gtk_action_set_is_important,
//GO(gtk_action_set_label,
//GO(gtk_action_set_sensitive,
@@ -158,12 +158,12 @@ GO(gtk_action_group_get_type, pFv)
//GO(gtk_action_set_visible_vertical,
//GO(gtk_action_unblock_activate,
//GO(gtk_action_unblock_activate_from,
-//GO(gtk_activatable_do_set_related_action,
-//GO(gtk_activatable_get_related_action,
+GO(gtk_activatable_do_set_related_action, vFpp)
+GO(gtk_activatable_get_related_action, pFp)
GO(gtk_activatable_get_type, pFv)
-//GO(gtk_activatable_get_use_action_appearance,
+GO(gtk_activatable_get_use_action_appearance, iFp)
//GO(gtk_activatable_set_related_action,
-//GO(gtk_activatable_set_use_action_appearance,
+GO(gtk_activatable_set_use_action_appearance, vFpi)
//GO(gtk_activatable_sync_action_properties,
GO(gtk_adjustment_changed, vFp)
GO(gtk_adjustment_clamp_page, vFpdd)
@@ -191,7 +191,12 @@ GO(gtk_alignment_set_padding, vFpuuuu)
GO(gtk_align_get_type, pFv)
GO(gtk_alternative_dialog_button_order, iFp)
GO(gtk_anchor_type_get_type, pFv)
-GO(gtk_application_get_type, pFv)
+GO(gtk_application_add_window, vFpp)
+GO(gtk_application_get_new, pFpi)
+GO(gtk_application_get_type, LFv)
+GO(gtk_application_new, pFpu)
+GO(gtk_application_set_accels_for_action, vFppp)
+GO(gtk_application_window_new, pFp)
GO(gtk_application_window_get_type, pFv)
GO(gtk_app_chooser_button_get_type, pFv)
GO(gtk_app_chooser_dialog_get_type, pFv)
@@ -199,51 +204,51 @@ GO(gtk_app_chooser_get_type, pFv)
GO(gtk_app_chooser_widget_get_type, pFv)
GO(gtk_arg_flags_get_type, pFv)
GO(gtk_arrow_get_type, pFv)
-GO(gtk_arrow_new, pFii)
+GO(gtk_arrow_new, pFuu)
GO(gtk_arrow_placement_get_type, pFv)
-GO(gtk_arrow_set, vFpii)
+GO(gtk_arrow_set, vFpuu)
GO(gtk_arrow_type_get_type, pFv)
GO(gtk_aspect_frame_get_type, pFv)
-//GO(gtk_aspect_frame_new,
-//GO(gtk_aspect_frame_set,
+GO(gtk_aspect_frame_new, pFpfffi)
+GO(gtk_aspect_frame_set, vFpfffi)
//GO(gtk_assistant_add_action_widget,
-//GO(gtk_assistant_append_page,
+GO(gtk_assistant_append_page, iFpp)
//GO(gtk_assistant_commit,
//GO(gtk_assistant_get_current_page,
-//GO(gtk_assistant_get_n_pages,
-//GO(gtk_assistant_get_nth_page,
+GO(gtk_assistant_get_n_pages, iFp)
+GO(gtk_assistant_get_nth_page, pFpi)
//GO(gtk_assistant_get_page_complete,
//GO(gtk_assistant_get_page_header_image,
-//GO(gtk_assistant_get_page_side_image,
-//GO(gtk_assistant_get_page_title,
-//GO(gtk_assistant_get_page_type,
+GO(gtk_assistant_get_page_side_image, pFpp)
+GO(gtk_assistant_get_page_title, pFpp)
+GO(gtk_assistant_get_page_type, uFpp)
GO(gtk_assistant_get_type, pFv)
-//GO(gtk_assistant_insert_page,
+GO(gtk_assistant_insert_page, iFppi)
//GO(gtk_assistant_new,
GO(gtk_assistant_page_type_get_type, pFv)
//GO(gtk_assistant_prepend_page,
-//GO(gtk_assistant_remove_action_widget,
+GO(gtk_assistant_remove_action_widget, vFpp)
//GO(gtk_assistant_set_current_page,
//GO(gtk_assistant_set_forward_page_func,
//GO(gtk_assistant_set_page_complete,
//GO(gtk_assistant_set_page_header_image,
-//GO(gtk_assistant_set_page_side_image,
-//GO(gtk_assistant_set_page_title,
-//GO(gtk_assistant_set_page_type,
+GO(gtk_assistant_set_page_side_image, vFppp)
+GO(gtk_assistant_set_page_title, vFppp)
+GO(gtk_assistant_set_page_type, vFppu)
//GO(gtk_assistant_update_buttons_state,
GO(gtk_attach_options_get_type, pFv)
//GO(gtk_binding_entry_add_signal,
-//GO(gtk_binding_entry_add_signall,
+GO(gtk_binding_entry_add_signall, vFpuupp)
//GO(gtk_binding_entry_clear,
-//GO(gtk_binding_entry_remove,
+GO(gtk_binding_entry_remove, vFpuu)
//GO(gtk_binding_entry_skip,
//GO(gtk_binding_parse_binding,
-//GO(gtk_bindings_activate,
+GO(gtk_bindings_activate, iFpuu)
GO(gtk_bindings_activate_event, iFpp)
-//GO(gtk_binding_set_activate,
-//GO(gtk_binding_set_add_path,
-//GO(gtk_binding_set_by_class,
-//GO(gtk_binding_set_find,
+GO(gtk_binding_set_activate, iFpuup)
+GO(gtk_binding_set_add_path, vFpupu)
+GO(gtk_binding_set_by_class, pFp)
+GO(gtk_binding_set_find, pFp)
//GO(gtk_binding_set_new,
GO(gtk_bin_get_child, pFp)
GO(gtk_bin_get_type, pFv)
@@ -254,14 +259,14 @@ GO(gtk_border_new, pFv)
GO(gtk_box_get_homogeneous, iFp)
GO(gtk_box_get_spacing, iFp)
GO(gtk_box_get_type, pFv)
-GO(gtk_box_new, pFii)
+GO(gtk_box_new, pFui)
GO(gtk_box_pack_end, vFppiiu)
GO(gtk_box_pack_end_defaults, vFpp)
GO(gtk_box_pack_start, vFppiiu)
GO(gtk_box_pack_start_defaults, vFpp)
GO(gtk_box_query_child_packing, vFpppppp)
GO(gtk_box_reorder_child, vFppi)
-GO(gtk_box_set_child_packing, vFppiiui)
+GO(gtk_box_set_child_packing, vFppiiuu)
GO(gtk_box_set_homogeneous, vFpi)
GO(gtk_box_set_spacing, vFpi)
GO(gtk_buildable_add_child, vFpppp)
@@ -277,7 +282,7 @@ GO(gtk_buildable_set_buildable_property, vFpppp)
GO(gtk_buildable_set_name, vFpp)
GO(gtk_builder_add_from_file, uFppp)
GO(gtk_builder_add_from_resource, uFppp)
-GO(gtk_builder_add_from_string, iFppLp)
+GO(gtk_builder_add_from_string, uFppLp)
GO(gtk_builder_add_objects_from_file, uFpppp)
GO(gtk_builder_add_objects_from_string, uFppLpp)
GOM(gtk_builder_connect_signals, vFEpp)
@@ -288,22 +293,22 @@ GO(gtk_builder_get_object, pFpp)
GO(gtk_builder_get_objects, pFp)
GO(gtk_builder_get_translation_domain, pFp)
GO(gtk_builder_get_type, pFv)
-GO(gtk_builder_get_type_from_name, iFpp)
+GO(gtk_builder_get_type_from_name, LFpp)
GO(gtk_builder_new, pFv)
GO(gtk_builder_set_translation_domain, vFpp)
GO(gtk_builder_value_from_string, iFppppp)
-GO(gtk_builder_value_from_string_type, iFpippp)
+GO(gtk_builder_value_from_string_type, iFpLppp)
GO(gtk_button_action_get_type, pFv)
GO(gtk_button_box_get_child_ipadding, vFppp)
GO(gtk_button_box_get_child_secondary, iFpp)
GO(gtk_button_box_get_child_size, vFppp)
-GO(gtk_button_box_get_layout, iFp)
+GO(gtk_button_box_get_layout, uFp)
GO(gtk_button_box_get_type, pFv)
GO(gtk_button_box_new, pFi)
GO(gtk_button_box_set_child_ipadding, vFpii)
GO(gtk_button_box_set_child_secondary, vFppi)
GO(gtk_button_box_set_child_size, vFpii)
-GO(gtk_button_box_set_layout, vFpi)
+GO(gtk_button_box_set_layout, vFpu)
GO(gtk_button_box_style_get_type, pFv)
//GO(gtk_button_clicked,
//GO(gtk_button_enter,
@@ -311,9 +316,9 @@ GO(gtk_button_get_alignment, vFppp)
GO(gtk_button_get_event_window, pFp)
GO(gtk_button_get_focus_on_click, iFp)
GO(gtk_button_get_image, pFp)
-GO(gtk_button_get_image_position, iFp)
+GO(gtk_button_get_image_position, uFp)
GO(gtk_button_get_label, pFp)
-GO(gtk_button_get_relief, iFp)
+GO(gtk_button_get_relief, uFp)
GO(gtk_button_get_type, pFv)
GO(gtk_button_get_use_stock, iFp)
GO(gtk_button_get_use_underline, iFp)
@@ -327,9 +332,9 @@ GO(gtk_button_released, vFp)
GO(gtk_button_set_alignment, vFpff)
GO(gtk_button_set_focus_on_click, vFpi)
GO(gtk_button_set_image, vFpp)
-GO(gtk_button_set_image_position, vFpi)
+GO(gtk_button_set_image_position, vFpu)
GO(gtk_button_set_label, vFpp)
-GO(gtk_button_set_relief, vFpi)
+GO(gtk_button_set_relief, vFpu)
GO(gtk_button_set_use_stock, vFpi)
GO(gtk_button_set_use_underline, vFpi)
GO(gtk_buttons_type_get_type, pFv)
@@ -337,25 +342,25 @@ GO(gtk_buttons_type_get_type, pFv)
//GO(gtk_calendar_display_options,
GO(gtk_calendar_display_options_get_type, pFv)
//GO(gtk_calendar_freeze,
-//GO(gtk_calendar_get_date,
-//GO(gtk_calendar_get_detail_height_rows,
+GO(gtk_calendar_get_date, vFpppp)
+GO(gtk_calendar_get_detail_height_rows, iFp)
//GO(gtk_calendar_get_detail_width_chars,
-//GO(gtk_calendar_get_display_options,
+GO(gtk_calendar_get_display_options, uFp)
GO(gtk_calendar_get_type, pFv)
//GO(gtk_calendar_mark_day,
//GO(gtk_calendar_new,
//GO(gtk_calendar_select_day,
-//GO(gtk_calendar_select_month,
+GO(gtk_calendar_select_month, vFpuu)
//GO(gtk_calendar_set_detail_func,
-//GO(gtk_calendar_set_detail_height_rows,
+GO(gtk_calendar_set_detail_height_rows, vFpi)
//GO(gtk_calendar_set_detail_width_chars,
-//GO(gtk_calendar_set_display_options,
+GO(gtk_calendar_set_display_options, vFpu)
//GO(gtk_calendar_thaw,
-//GO(gtk_calendar_unmark_day,
+GO(gtk_calendar_unmark_day, vFpu)
//GO(gtk_cell_editable_editing_done,
GO(gtk_cell_editable_get_type, pFv)
//GO(gtk_cell_editable_remove_widget,
-//GO(gtk_cell_editable_start_editing,
+GO(gtk_cell_editable_start_editing, vFpp)
GO(gtk_cell_layout_add_attribute, vFpppi)
GO(gtk_cell_layout_clear, vFp)
GO(gtk_cell_layout_clear_attributes, vFpp)
@@ -369,15 +374,15 @@ GO(gtk_cell_layout_set_attributes, vFpppppppppp) // vaarg
GO(gtk_cell_renderer_accel_get_type, pFv)
GO(gtk_cell_renderer_accel_mode_get_type, pFv)
//GO(gtk_cell_renderer_accel_new,
-//GO(gtk_cell_renderer_activate,
+GO(gtk_cell_renderer_activate, iFppppppu)
GO(gtk_cell_renderer_combo_get_type, pFv)
//GO(gtk_cell_renderer_combo_new,
//GO(gtk_cell_renderer_editing_canceled,
-//GO(gtk_cell_renderer_get_alignment,
+GO(gtk_cell_renderer_get_alignment, vFppp)
//GO(gtk_cell_renderer_get_fixed_size,
-//GO(gtk_cell_renderer_get_padding,
+GO(gtk_cell_renderer_get_padding, vFppp)
//GO(gtk_cell_renderer_get_sensitive,
-//GO(gtk_cell_renderer_get_size,
+GO(gtk_cell_renderer_get_size, vFppppppp)
GO(gtk_cell_renderer_get_type, pFv)
//GO(gtk_cell_renderer_get_visible,
GO(gtk_cell_renderer_mode_get_type, pFv)
@@ -385,19 +390,19 @@ GO(gtk_cell_renderer_pixbuf_get_type, pFv)
GO(gtk_cell_renderer_pixbuf_new, pFv)
GO(gtk_cell_renderer_progress_get_type, pFv)
//GO(gtk_cell_renderer_progress_new,
-//GO(gtk_cell_renderer_render,
-//GO(gtk_cell_renderer_set_alignment,
+GO(gtk_cell_renderer_render, vFpppppu)
+GO(gtk_cell_renderer_set_alignment, vFpff)
//GO(gtk_cell_renderer_set_fixed_size,
-//GO(gtk_cell_renderer_set_padding,
+GO(gtk_cell_renderer_set_padding, vFpii)
//GO(gtk_cell_renderer_set_sensitive,
//GO(gtk_cell_renderer_set_visible,
GO(gtk_cell_renderer_spin_get_type, pFv)
GO(gtk_cell_renderer_spinner_get_type, pFv)
//GO(gtk_cell_renderer_spinner_new,
//GO(gtk_cell_renderer_spin_new,
-//GO(gtk_cell_renderer_start_editing,
+GO(gtk_cell_renderer_start_editing, pFppppppu)
GO(gtk_cell_renderer_state_get_type, pFv)
-//GO(gtk_cell_renderer_stop_editing,
+GO(gtk_cell_renderer_stop_editing, vFpi)
GO(gtk_cell_renderer_text_get_type, pFv)
GO(gtk_cell_renderer_text_new, pFv)
GO(gtk_cell_renderer_text_set_fixed_height_from_font, vFpi)
@@ -411,17 +416,17 @@ GO(gtk_cell_renderer_toggle_set_active, vFpi)
GO(gtk_cell_renderer_toggle_set_radio, vFpi)
GO(gtk_cell_type_get_type, pFv)
//GO(gtk_cell_view_get_cell_renderers,
-//GO(gtk_cell_view_get_displayed_row,
-//GO(gtk_cell_view_get_model,
-//GO(gtk_cell_view_get_size_of_row,
+GO(gtk_cell_view_get_displayed_row, pFp)
+GO(gtk_cell_view_get_model, pFp)
+GO(gtk_cell_view_get_size_of_row, iFppp)
GO(gtk_cell_view_get_type, pFv)
//GO(gtk_cell_view_new,
//GO(gtk_cell_view_new_with_markup,
-//GO(gtk_cell_view_new_with_pixbuf,
+GO(gtk_cell_view_new_with_pixbuf, pFp)
//GO(gtk_cell_view_new_with_text,
-//GO(gtk_cell_view_set_background_color,
-//GO(gtk_cell_view_set_displayed_row,
-//GO(gtk_cell_view_set_model,
+GO(gtk_cell_view_set_background_color, vFpp)
+GO(gtk_cell_view_set_displayed_row, vFpp)
+GO(gtk_cell_view_set_model, vFpp)
GO(gtk_check_button_get_type, pFv)
GO(gtk_check_button_new, pFv)
GO(gtk_check_button_new_with_label, pFp)
@@ -441,6 +446,7 @@ GO(gtk_check_menu_item_toggled, vFp)
GO(gtk_check_version, pFuuu)
GO(gtk_clipboard_clear, vFp)
GO(gtk_clipboard_get, pFp)
+GO(gtk_clipboard_get_default, pFp)
GO(gtk_clipboard_get_display, pFp)
GO(gtk_clipboard_get_for_display, pFpp)
GO(gtk_clipboard_get_owner, pFp)
@@ -449,9 +455,9 @@ GO(gtk_clipboard_get_type, pFv)
//GOM(gtk_clipboard_request_image, vFEppp)
//GOM(gtk_clipboard_request_rich_text, vFEpppp)
//GOM(gtk_clipboard_request_targets, vFEppp)
-//GOM(gtk_clipboard_request_text, vFEppp)
+GOM(gtk_clipboard_request_text, vFEppp)
//GOM(gtk_clipboard_request_uris, vFEppp)
-GO(gtk_clipboard_set_can_store, vFppp)
+GO(gtk_clipboard_set_can_store, vFppi)
GO(gtk_clipboard_set_image, vFpp)
GO(gtk_clipboard_set_text, vFppi)
GOM(gtk_clipboard_set_with_data, iFEppuppp)
@@ -592,7 +598,7 @@ GO(gtk_combo_box_get_active, iFp)
GO(gtk_combo_box_get_active_iter, iFpp)
GO(gtk_combo_box_get_active_text, pFp)
GO(gtk_combo_box_get_add_tearoffs, iFp)
-GO(gtk_combo_box_get_button_sensitivity, iFp)
+GO(gtk_combo_box_get_button_sensitivity, uFp)
GO(gtk_combo_box_get_column_span_column, iFp)
GO(gtk_combo_box_get_entry_text_column, iFp)
GO(gtk_combo_box_get_focus_on_click, iFp)
@@ -617,7 +623,7 @@ GO(gtk_combo_box_remove_text, vFpi)
GO(gtk_combo_box_set_active, vFpi)
GO(gtk_combo_box_set_active_iter, vFpp)
GO(gtk_combo_box_set_add_tearoffs, vFpi)
-GO(gtk_combo_box_set_button_sensitivity, vFpi)
+GO(gtk_combo_box_set_button_sensitivity, vFpu)
GO(gtk_combo_box_set_column_span_column, vFpi)
GO(gtk_combo_box_set_entry_text_column, vFpi)
GO(gtk_combo_box_set_focus_on_click, vFpi)
@@ -645,6 +651,7 @@ GO(gtk_combo_set_popdown_strings, vFpp)
GO(gtk_combo_set_use_arrows, vFpi)
GO(gtk_combo_set_use_arrows_always, vFpi)
GO(gtk_combo_set_value_in_list, vFpii)
+GO(gtk_container_accessible_get_type, LFv)
GO(gtk_container_add, vFpp)
GO(gtk_container_add_with_properties, vFpppppppppppp) //vaarg
GO(gtk_container_check_resize, vFp)
@@ -654,7 +661,7 @@ GO(gtk_container_child_get_property, vFpppp)
//GO2(gtk_container_child_set, vFpppV, gtk_container_child_set_valist)
GO(gtk_container_child_set_property, vFpppp)
//GO(gtk_container_child_set_valist, vFpppp)
-GO(gtk_container_child_type, iFp)
+GO(gtk_container_child_type, LFp)
GO(gtk_container_class_find_child_property, pFpp)
GO(gtk_container_class_install_child_property, vFpup)
GO(gtk_container_class_list_child_properties, pFpp)
@@ -667,7 +674,7 @@ GO(gtk_container_get_focus_chain, iFpp)
GO(gtk_container_get_focus_child, pFp)
GO(gtk_container_get_focus_hadjustment, pFp)
GO(gtk_container_get_focus_vadjustment, pFp)
-GO(gtk_container_get_resize_mode, iFp)
+GO(gtk_container_get_resize_mode, uFp)
GO(gtk_container_get_type, pFv)
GO(gtk_container_propagate_expose, vFppp)
GO(gtk_container_remove, vFpp)
@@ -677,8 +684,8 @@ GO(gtk_container_set_focus_chain, vFpp)
GO(gtk_container_set_focus_child, vFpp)
GO(gtk_container_set_focus_hadjustment, vFpp)
GO(gtk_container_set_focus_vadjustment, vFpp)
-GO(gtk_container_set_reallocate_redraws, vFpp)
-GO(gtk_container_set_resize_mode, vFpi)
+GO(gtk_container_set_reallocate_redraws, vFpi)
+GO(gtk_container_set_resize_mode, vFpu)
GO(gtk_container_unset_focus_chain, vFp)
GO(gtk_corner_type_get_type, pFv)
GO(gtk_css_provider_get_default, pFv)
@@ -693,7 +700,7 @@ GO(gtk_css_section_get_end_line, uFp)
GO(gtk_css_section_get_end_position, uFp)
GO(gtk_css_section_get_file, pFp)
GO(gtk_css_section_get_parent, pFp)
-GO(gtk_css_section_get_section_type, iFp)
+GO(gtk_css_section_get_section_type, uFp)
GO(gtk_css_section_get_start_line, uFp)
GO(gtk_css_section_get_start_position, uFp)
GO(gtk_css_section_ref, pFp)
@@ -808,8 +815,8 @@ GO(gtk_dialog_set_has_separator, vFpi)
GO(gtk_dialog_set_response_sensitive, vFpii)
GO(gtk_direction_type_get_type, pFv)
GO(gtk_disable_setlocale, vFv)
-GO(gtk_distribute_natural_allocation, iFpup)
-GO(gtk_drag_begin, pFppiip)
+GO(gtk_distribute_natural_allocation, iFiup)
+GO(gtk_drag_begin, pFppuip)
GO(gtk_drag_check_threshold, iFpiiii)
GO(gtk_drag_dest_add_image_targets, vFp)
GO(gtk_drag_dest_add_text_targets, vFp)
@@ -817,8 +824,8 @@ GO(gtk_drag_dest_add_uri_targets, vFp)
GO(gtk_drag_dest_find_target, pFppp)
GO(gtk_drag_dest_get_target_list, pFp)
GO(gtk_drag_dest_get_track_motion, iFp)
-GO(gtk_drag_dest_set, vFpipii)
-GO(gtk_drag_dest_set_proxy, vFppii)
+GO(gtk_drag_dest_set, vFpupiu)
+GO(gtk_drag_dest_set_proxy, vFppui)
GO(gtk_drag_dest_set_target_list, vFpp)
GO(gtk_drag_dest_set_track_motion, vFpi)
GO(gtk_drag_dest_unset, vFp)
@@ -838,7 +845,7 @@ GO(gtk_drag_source_add_image_targets, vFp)
GO(gtk_drag_source_add_text_targets, vFp)
GO(gtk_drag_source_add_uri_targets, vFp)
GO(gtk_drag_source_get_target_list, pFp)
-GO(gtk_drag_source_set, vFpipii)
+GO(gtk_drag_source_set, vFpupiu)
GO(gtk_drag_source_set_icon, vFpppp)
GO(gtk_drag_source_set_icon_name, vFpp)
GO(gtk_drag_source_set_icon_pixbuf, vFpp)
@@ -860,7 +867,7 @@ GO(gtk_draw_hline, vFppiiii)
GO(gtk_drawing_area_get_type, pFv)
GO(gtk_drawing_area_new, pFv)
GO(gtk_drawing_area_size, vFpii)
-GO(gtk_draw_insertion_cursor, vFppppiii)
+GO(gtk_draw_insertion_cursor, vFpppiui)
GO(gtk_draw_layout, vFppiiiip)
GO(gtk_draw_option, vFppiiiiii)
GO(gtk_draw_polygon, vFppiipii)
@@ -886,70 +893,70 @@ GO(gtk_editable_select_region, vFpii)
GO(gtk_editable_set_editable, vFpi)
GO(gtk_editable_set_position, vFpi)
GO(gtk_entry_append_text, vFpp)
-//GO(gtk_entry_buffer_delete_text,
-//GO(gtk_entry_buffer_emit_deleted_text,
-//GO(gtk_entry_buffer_emit_inserted_text,
-//GO(gtk_entry_buffer_get_bytes,
-//GO(gtk_entry_buffer_get_length,
-//GO(gtk_entry_buffer_get_max_length,
-//GO(gtk_entry_buffer_get_text,
+GO(gtk_entry_buffer_delete_text, uFpui)
+GO(gtk_entry_buffer_emit_deleted_text, vFpuu)
+GO(gtk_entry_buffer_emit_inserted_text, vFpupu)
+GO(gtk_entry_buffer_get_bytes, LFp)
+GO(gtk_entry_buffer_get_length, uFp)
+GO(gtk_entry_buffer_get_max_length, iFp)
+GO(gtk_entry_buffer_get_text, pFp)
GO(gtk_entry_buffer_get_type, pFv)
-//GO(gtk_entry_buffer_insert_text,
-//GO(gtk_entry_buffer_new,
-//GO(gtk_entry_buffer_set_max_length,
-//GO(gtk_entry_buffer_set_text,
+GO(gtk_entry_buffer_insert_text, uFpupi)
+GO(gtk_entry_buffer_new, pFpi)
+GO(gtk_entry_buffer_set_max_length, vFpi)
+GO(gtk_entry_buffer_set_text, vFppi)
//GO(gtk_entry_completion_complete,
//GO(gtk_entry_completion_delete_action,
-//GO(gtk_entry_completion_get_completion_prefix,
-//GO(gtk_entry_completion_get_entry,
+GO(gtk_entry_completion_get_completion_prefix, pFp)
+GO(gtk_entry_completion_get_entry, pFp)
//GO(gtk_entry_completion_get_inline_completion,
//GO(gtk_entry_completion_get_inline_selection,
//GO(gtk_entry_completion_get_minimum_key_length,
-//GO(gtk_entry_completion_get_model,
+GO(gtk_entry_completion_get_model, pFp)
//GO(gtk_entry_completion_get_popup_completion,
//GO(gtk_entry_completion_get_popup_set_width,
-//GO(gtk_entry_completion_get_popup_single_match,
-//GO(gtk_entry_completion_get_text_column,
+GO(gtk_entry_completion_get_popup_single_match, iFp)
+GO(gtk_entry_completion_get_text_column, iFp)
GO(gtk_entry_completion_get_type, pFv)
-//GO(gtk_entry_completion_insert_action_markup,
+GO(gtk_entry_completion_insert_action_markup, vFpip)
//GO(gtk_entry_completion_insert_action_text,
//GO(gtk_entry_completion_insert_prefix,
-//GO(gtk_entry_completion_new,
+GO(gtk_entry_completion_new, pFv)
//GO(gtk_entry_completion_set_inline_completion,
//GO(gtk_entry_completion_set_inline_selection,
//GO(gtk_entry_completion_set_match_func,
//GO(gtk_entry_completion_set_minimum_key_length,
-//GO(gtk_entry_completion_set_model,
+GO(gtk_entry_completion_set_model, vFpp)
//GO(gtk_entry_completion_set_popup_completion,
//GO(gtk_entry_completion_set_popup_set_width,
-//GO(gtk_entry_completion_set_popup_single_match,
-//GO(gtk_entry_completion_set_text_column,
+GO(gtk_entry_completion_set_popup_single_match, vFpi)
+GO(gtk_entry_completion_set_text_column, vFpi)
GO(gtk_entry_get_activates_default, iFp)
GO(gtk_entry_get_alignment, fFp)
-//GO(gtk_entry_get_buffer,
-//GO(gtk_entry_get_completion,
-//GO(gtk_entry_get_current_icon_drag_source,
-//GO(gtk_entry_get_cursor_hadjustment,
+GO(gtk_entry_get_buffer, pFp)
+GO(gtk_entry_get_completion, pFp)
+GO(gtk_entry_get_current_icon_drag_source, iFp)
+GO(gtk_entry_get_cursor_hadjustment, pFp)
GO(gtk_entry_get_has_frame, iFp)
//GO(gtk_entry_get_icon_activatable,
-//GO(gtk_entry_get_icon_at_pos,
-//GO(gtk_entry_get_icon_gicon,
-//GO(gtk_entry_get_icon_name,
-//GO(gtk_entry_get_icon_pixbuf,
-//GO(gtk_entry_get_icon_sensitive,
+GO(gtk_entry_get_icon_at_pos, iFpii)
+GO(gtk_entry_get_icon_gicon, pFpu)
+GO(gtk_entry_get_icon_name, pFpu)
+GO(gtk_entry_get_icon_pixbuf, pFpu)
+GO(gtk_entry_get_icon_sensitive, iFpu)
//GO(gtk_entry_get_icon_stock,
-//GO(gtk_entry_get_icon_storage_type,
-//GO(gtk_entry_get_icon_tooltip_markup,
+GO(gtk_entry_get_icon_storage_type, uFpu)
+GO(gtk_entry_get_icon_tooltip_markup, pFpu)
//GO(gtk_entry_get_icon_tooltip_text,
//GO(gtk_entry_get_icon_window,
GO(gtk_entry_get_inner_border, pFp)
-//GO(gtk_entry_get_invisible_char,
+GO(gtk_entry_get_invisible_char, uFp)
GO(gtk_entry_get_layout, pFp)
GO(gtk_entry_get_layout_offsets, vFppp)
//GO(gtk_entry_get_max_length,
GO(gtk_entry_get_overwrite_mode, iFp)
//GO(gtk_entry_get_progress_fraction,
-//GO(gtk_entry_get_progress_pulse_step,
+GO(gtk_entry_get_progress_pulse_step, dFp)
GO(gtk_entry_get_text, pFp)
GO(gtk_entry_get_text_length, WFp)
//GO(gtk_entry_get_text_window,
@@ -957,7 +964,7 @@ GO(gtk_entry_get_type, pFv)
//GO(gtk_entry_get_visibility,
GO(gtk_entry_get_width_chars, iFp)
GO(gtk_entry_icon_position_get_type, pFv)
-//GO(gtk_entry_im_context_filter_keypress,
+GO(gtk_entry_im_context_filter_keypress, iFpp)
//GO(gtk_entry_layout_index_to_text_index,
GO(gtk_entry_new, pFv)
GO(gtk_entry_new_with_buffer, pFp)
@@ -969,30 +976,30 @@ GO(gtk_entry_select_region, vFpii)
GO(gtk_entry_set_activates_default, vFpi)
GO(gtk_entry_set_alignment, vFpf)
GO(gtk_entry_set_buffer, vFpp)
-//GO(gtk_entry_set_completion,
-//GO(gtk_entry_set_cursor_hadjustment,
+GO(gtk_entry_set_completion, vFpp)
+GO(gtk_entry_set_cursor_hadjustment, vFpp)
GO(gtk_entry_set_editable, vFpi)
GO(gtk_entry_set_has_frame, vFpi)
//GO(gtk_entry_set_icon_activatable,
-//GO(gtk_entry_set_icon_drag_source,
-//GO(gtk_entry_set_icon_from_gicon,
+GO(gtk_entry_set_icon_drag_source, vFpupu)
+GO(gtk_entry_set_icon_from_gicon, vFpup)
//GO(gtk_entry_set_icon_from_icon_name,
-//GO(gtk_entry_set_icon_from_pixbuf,
+GO(gtk_entry_set_icon_from_pixbuf, vFpup)
//GO(gtk_entry_set_icon_from_stock,
-//GO(gtk_entry_set_icon_sensitive,
-//GO(gtk_entry_set_icon_tooltip_markup,
+GO(gtk_entry_set_icon_sensitive, vFpui)
+GO(gtk_entry_set_icon_tooltip_markup, vFpup)
//GO(gtk_entry_set_icon_tooltip_text,
GO(gtk_entry_set_inner_border, vFpp)
-GO(gtk_entry_set_invisible_char, vFp)
+GO(gtk_entry_set_invisible_char, vFpu)
GO(gtk_entry_set_max_length, vFpi)
GO(gtk_entry_set_overwrite_mode, vFpi)
GO(gtk_entry_set_position, vFpi)
//GO(gtk_entry_set_progress_fraction,
-//GO(gtk_entry_set_progress_pulse_step,
+GO(gtk_entry_set_progress_pulse_step, vFpd)
GO(gtk_entry_set_text, vFpp)
GO(gtk_entry_set_visibility, vFpi)
GO(gtk_entry_set_width_chars, uFp)
-//GO(gtk_entry_text_index_to_layout_index,
+GO(gtk_entry_text_index_to_layout_index, iFpi)
//GO(gtk_entry_unset_invisible_char,
GOM(gtk_enumerate_printers, vFEpppi)
GO(gtk_event_box_get_above_child, iFp)
@@ -1030,7 +1037,7 @@ GO(gtk_file_chooser_button_get_focus_on_click, iFp)
GO(gtk_file_chooser_button_get_title, pFp)
GO(gtk_file_chooser_button_get_type, pFv)
GO(gtk_file_chooser_button_get_width_chars, iFp)
-GO(gtk_file_chooser_button_new, pFpi)
+GO(gtk_file_chooser_button_new, pFpu)
GO(gtk_file_chooser_button_new_with_backend, pFpip)
GO(gtk_file_chooser_button_new_with_dialog, pFp)
GO(gtk_file_chooser_button_set_focus_on_click, vFpi)
@@ -1042,7 +1049,7 @@ GO(gtk_file_chooser_dialog_new, pFppipipipipipipip) // vaargs (so pFppipV) with
GO(gtk_file_chooser_dialog_new_with_backend, pFppippipipipipipip) // same but pFppippV
GO(gtk_file_chooser_error_get_type, pFv)
GO(gtk_file_chooser_error_quark, pFv)
-GO(gtk_file_chooser_get_action, iFp)
+GO(gtk_file_chooser_get_action, uFp)
GO(gtk_file_chooser_get_create_folders, iFp)
GO(gtk_file_chooser_get_current_folder, pFp)
GO(gtk_file_chooser_get_current_folder_file, pFp)
@@ -1077,7 +1084,7 @@ GO(gtk_file_chooser_select_all, vFp)
GO(gtk_file_chooser_select_file, iFppp)
GO(gtk_file_chooser_select_filename, iFpp)
GO(gtk_file_chooser_select_uri, iFpp)
-GO(gtk_file_chooser_set_action, vFpi)
+GO(gtk_file_chooser_set_action, vFpu)
GO(gtk_file_chooser_set_create_folders, vFpi)
GO(gtk_file_chooser_set_current_folder, iFpp)
GO(gtk_file_chooser_set_current_folder_file, iFppp)
@@ -1100,7 +1107,7 @@ GO(gtk_file_chooser_unselect_file, vFpp)
GO(gtk_file_chooser_unselect_filename, vFpp)
GO(gtk_file_chooser_unselect_uri, vFpp)
GO(gtk_file_chooser_widget_get_type, pFv)
-GO(gtk_file_chooser_widget_new, pFi)
+GO(gtk_file_chooser_widget_new, pFu)
GO(gtk_file_chooser_widget_new_with_backend, pFip)
//GOM(gtk_file_filter_add_custom, vFEppppp)
GO(gtk_file_filter_add_mime_type, vFpp)
@@ -1109,7 +1116,7 @@ GO(gtk_file_filter_add_pixbuf_formats, vFp)
GO(gtk_file_filter_filter, iFpp)
GO(gtk_file_filter_flags_get_type, pFv)
GO(gtk_file_filter_get_name, pFp)
-GO(gtk_file_filter_get_needed, iFp)
+GO(gtk_file_filter_get_needed, uFp)
GO(gtk_file_filter_get_type, pFv)
GO(gtk_file_filter_new, pFv)
GO(gtk_file_filter_set_name, vFpp)
@@ -1156,7 +1163,7 @@ GO(gtk_font_selection_dialog_get_ok_button, pFp)
GO(gtk_font_selection_dialog_get_preview_text, pFp)
GO(gtk_font_selection_dialog_get_type, pFv)
GO(gtk_font_selection_dialog_new, pFp)
-GO(gtk_font_selection_dialog_set_font_name, vFpp)
+GO(gtk_font_selection_dialog_set_font_name, iFpp)
GO(gtk_font_selection_dialog_set_preview_text, vFpp)
GO(gtk_font_selection_get_face, pFp)
GO(gtk_font_selection_get_face_list, pFp)
@@ -1176,17 +1183,18 @@ GO(gtk_font_selection_set_preview_text, vFpp)
GO(gtk_frame_get_label, pFp)
GO(gtk_frame_get_label_align, vFppp)
GO(gtk_frame_get_label_widget, pFp)
-GO(gtk_frame_get_shadow_type, iFp)
+GO(gtk_frame_get_shadow_type, uFp)
GO(gtk_frame_get_type, pFv)
GO(gtk_frame_new, pFp)
GO(gtk_frame_set_label, vFpp)
GO(gtk_frame_set_label_align, vFpff)
GO(gtk_frame_set_label_widget, vFpp)
-GO(gtk_frame_set_shadow_type, vFpi)
+GO(gtk_frame_set_shadow_type, vFpu)
GO(gtk_gamma_curve_get_type, pFv)
GO(gtk_gamma_curve_new, pFv)
GO(gtk_gc_get, pFippu)
GO(gtk_gc_release, vFp)
+GO(gtk_gesture_long_press_new, pFv)
GO(gtk_get_current_event, pFv)
GO(gtk_get_current_event_state, iFp)
GO(gtk_get_current_event_time, uFv)
@@ -1201,16 +1209,21 @@ GO(gtk_get_option_group, pFi)
GO(gtk_grab_add, vFp)
GO(gtk_grab_get_current, pFv)
GO(gtk_grab_remove, vFp)
+GO(gtk_grid_attach, vFppiiii)
GO(gtk_grid_get_type, pFv)
+GO(gtk_grid_set_column_homogeneous, vFpi)
+GO(gtk_grid_set_column_spacing, vFpu)
+GO(gtk_grid_set_row_homogeneous, vFpi)
+GO(gtk_grid_set_row_spacing, vFpu)
GO(gtk_handle_box_get_child_detached, iFp)
GO(gtk_handle_box_get_handle_position, iFp)
-GO(gtk_handle_box_get_shadow_type, iFp)
-GO(gtk_handle_box_get_snap_edge, iFp)
+GO(gtk_handle_box_get_shadow_type, uFp)
+GO(gtk_handle_box_get_snap_edge, uFp)
GO(gtk_handle_box_get_type, pFv)
GO(gtk_handle_box_new, pFv)
GO(gtk_handle_box_set_handle_position, vFpi)
-GO(gtk_handle_box_set_shadow_type, vFpi)
-GO(gtk_handle_box_set_snap_edge, vFpi)
+GO(gtk_handle_box_set_shadow_type, vFpu)
+GO(gtk_handle_box_set_snap_edge, vFpu)
GO(gtk_hbox_get_type, pFv)
GO(gtk_hbox_new, pFii)
GO(gtk_hbutton_box_get_layout_default, iFv)
@@ -1219,7 +1232,11 @@ GO(gtk_hbutton_box_get_type, pFv)
GO(gtk_hbutton_box_new, pFv)
GO(gtk_hbutton_box_set_layout_default, vFi)
GO(gtk_hbutton_box_set_spacing_default, vFi)
+GO(gtk_header_bar_new, pFv)
GO(gtk_header_bar_get_type, lFv)
+GO(gtk_header_bar_pack_end, vFpp)
+GO(gtk_header_bar_set_show_close_button, vFpi)
+GO(gtk_header_bar_set_title, vFpp)
GO(gtk_hpaned_get_type, pFv)
//GO(gtk_hpaned_new,
GO(gtk_hruler_get_type, pFv)
@@ -1231,13 +1248,13 @@ GO(gtk_hscrollbar_get_type, pFv)
GO(gtk_hscrollbar_new, pFp)
GO(gtk_hseparator_get_type, pFv)
GO(gtk_hseparator_new, pFv)
-//GO(gtk_hsv_get_color,
-//GO(gtk_hsv_get_metrics,
+GO(gtk_hsv_get_color, vFpppp)
+GO(gtk_hsv_get_metrics, vFppp)
GO(gtk_hsv_get_type, pFv)
-//GO(gtk_hsv_is_adjusting,
+GO(gtk_hsv_is_adjusting, iFp)
//GO(gtk_hsv_new,
-//GO(gtk_hsv_set_color,
-//GO(gtk_hsv_set_metrics,
+GO(gtk_hsv_set_color, vFpddd)
+GO(gtk_hsv_set_metrics, vFpii)
//GO(gtk_hsv_to_rgb,
GO(gtk_icon_factory_add, vFppp)
GO(gtk_icon_factory_add_default, vFp)
@@ -1259,7 +1276,7 @@ GO(gtk_icon_info_load_icon, pFpp)
GO(gtk_icon_info_load_surface, pFppp)
GO(gtk_icon_info_load_symbolic_for_context, pFpppp)
GO(gtk_icon_info_new_for_pixbuf, pFpp)
-GO(gtk_icon_info_set_raw_coordinates, vFpp)
+GO(gtk_icon_info_set_raw_coordinates, vFpi)
GO(gtk_icon_lookup_flags_get_type, pFv)
GO(gtk_icon_set_add_source, vFpp)
GO(gtk_icon_set_copy, pFp)
@@ -1268,36 +1285,36 @@ GO(gtk_icon_set_get_type, pFv)
GO(gtk_icon_set_new, pFv)
GO(gtk_icon_set_new_from_pixbuf, pFp)
GO(gtk_icon_set_ref, pFp)
-GO(gtk_icon_set_render_icon, pFppipipp)
+GO(gtk_icon_set_render_icon, pFppuuupp)
GO(gtk_icon_set_unref, vFp)
-GO(gtk_icon_size_from_name, iFp)
-GO(gtk_icon_size_get_name, pFi)
+GO(gtk_icon_size_from_name, uFp)
+GO(gtk_icon_size_get_name, pFu)
GO(gtk_icon_size_get_type, pFv)
-GO(gtk_icon_size_lookup, iFipp)
-GO(gtk_icon_size_lookup_for_settings, iFpipp)
-GO(gtk_icon_size_register, iFpii)
-GO(gtk_icon_size_register_alias, vFpi)
+GO(gtk_icon_size_lookup, iFupp)
+GO(gtk_icon_size_lookup_for_settings, iFpupp)
+GO(gtk_icon_size_register, uFpii)
+GO(gtk_icon_size_register_alias, vFpu)
GO(gtk_icon_source_copy, pFp)
GO(gtk_icon_source_free, vFp)
-GO(gtk_icon_source_get_direction, iFp)
+GO(gtk_icon_source_get_direction, uFp)
GO(gtk_icon_source_get_direction_wildcarded, iFp)
GO(gtk_icon_source_get_filename, pFp)
GO(gtk_icon_source_get_icon_name, pFp)
GO(gtk_icon_source_get_pixbuf, pFp)
-GO(gtk_icon_source_get_size, iFp)
+GO(gtk_icon_source_get_size, uFp)
GO(gtk_icon_source_get_size_wildcarded, iFp)
-GO(gtk_icon_source_get_state, iFp)
+GO(gtk_icon_source_get_state, uFp)
GO(gtk_icon_source_get_state_wildcarded, iFp)
GO(gtk_icon_source_get_type, pFv)
GO(gtk_icon_source_new, pFv)
-GO(gtk_icon_source_set_direction, vFpi)
+GO(gtk_icon_source_set_direction, vFpu)
GO(gtk_icon_source_set_direction_wildcarded, vFpi)
GO(gtk_icon_source_set_filename, vFpp)
GO(gtk_icon_source_set_icon_name, vFpp)
GO(gtk_icon_source_set_pixbuf, vFpp)
-GO(gtk_icon_source_set_size, vFpi)
+GO(gtk_icon_source_set_size, vFpu)
GO(gtk_icon_source_set_size_wildcarded, vFpi)
-GO(gtk_icon_source_set_state, vFpi)
+GO(gtk_icon_source_set_state, vFpu)
GO(gtk_icon_source_set_state_wildcarded, vFpi)
GO(gtk_icon_theme_add_builtin_icon, vFpip)
GO(gtk_icon_theme_append_search_path, vFpp)
@@ -1317,7 +1334,7 @@ GO(gtk_icon_theme_list_icons, pFpp)
GO(gtk_icon_theme_load_icon, pFppiup)
GO(gtk_icon_theme_lookup_by_gicon, pFppiu)
GO(gtk_icon_theme_lookup_icon, pFppiu)
-GO(gtk_icon_theme_lookup_icon_for_scale, pFppiii)
+GO(gtk_icon_theme_lookup_icon_for_scale, pFppiiu)
GO(gtk_icon_theme_new, pFv)
//GO(gtk_icon_theme_prepend_search_path,
GO(gtk_icon_theme_rescan_if_needed, iFp)
@@ -1327,8 +1344,8 @@ GO(gtk_icon_theme_set_search_path, vFppi)
GO(gtk_icon_view_convert_widget_to_bin_window_coords, vFpiipp)
GO(gtk_icon_view_create_drag_icon, pFpp)
GO(gtk_icon_view_drop_position_get_type, pFv)
-GO(gtk_icon_view_enable_model_drag_dest, vFppii)
-GO(gtk_icon_view_enable_model_drag_source, vFpipii)
+GO(gtk_icon_view_enable_model_drag_dest, vFppiu)
+GO(gtk_icon_view_enable_model_drag_source, vFpupiu)
GO(gtk_icon_view_get_columns, iFp)
GO(gtk_icon_view_get_column_spacing, iFp)
GO(gtk_icon_view_get_cursor, iFppp)
@@ -1336,7 +1353,7 @@ GO(gtk_icon_view_get_dest_item_at_pos, iFpiipp)
GO(gtk_icon_view_get_drag_dest_item, vFppp)
GO(gtk_icon_view_get_item_at_pos, iFpiipp)
GO(gtk_icon_view_get_item_column, iFpp)
-GO(gtk_icon_view_get_item_orientation, iFp)
+GO(gtk_icon_view_get_item_orientation, uFp)
GO(gtk_icon_view_get_item_padding, iFp)
GO(gtk_icon_view_get_item_row, iFpp)
GO(gtk_icon_view_get_item_width, iFp)
@@ -1349,7 +1366,7 @@ GO(gtk_icon_view_get_pixbuf_column, iFp)
GO(gtk_icon_view_get_reorderable, iFp)
GO(gtk_icon_view_get_row_spacing, iFp)
GO(gtk_icon_view_get_selected_items, pFp)
-GO(gtk_icon_view_get_selection_mode, iFp)
+GO(gtk_icon_view_get_selection_mode, uFp)
GO(gtk_icon_view_get_spacing, iFp)
GO(gtk_icon_view_get_text_column, iFp)
GO(gtk_icon_view_get_tooltip_column, iFp)
@@ -1367,8 +1384,8 @@ GO(gtk_icon_view_select_path, vFpp)
GO(gtk_icon_view_set_columns, vFpi)
GO(gtk_icon_view_set_column_spacing, vFpi)
GO(gtk_icon_view_set_cursor, vFpppi)
-GO(gtk_icon_view_set_drag_dest_item, vFppi)
-GO(gtk_icon_view_set_item_orientation, vFpi)
+GO(gtk_icon_view_set_drag_dest_item, vFppu)
+GO(gtk_icon_view_set_item_orientation, vFpu)
GO(gtk_icon_view_set_item_padding, vFpi)
GO(gtk_icon_view_set_item_width, vFpi)
GO(gtk_icon_view_set_margin, vFpi)
@@ -1378,7 +1395,7 @@ GO(gtk_icon_view_set_orientation, vFpi)
GO(gtk_icon_view_set_pixbuf_column, vFpi)
GO(gtk_icon_view_set_reorderable, vFpi)
GO(gtk_icon_view_set_row_spacing, vFpi)
-GO(gtk_icon_view_set_selection_mode, vFpi)
+GO(gtk_icon_view_set_selection_mode, vFpu)
GO(gtk_icon_view_set_spacing, vFpi)
GO(gtk_icon_view_set_text_column, vFpi)
GO(gtk_icon_view_set_tooltip_cell, vFpppp)
@@ -1405,7 +1422,7 @@ GO(gtk_image_get_pixbuf, pFp)
GO(gtk_image_get_pixel_size, iFp)
GO(gtk_image_get_pixmap, vFppp)
GO(gtk_image_get_stock, vFppp)
-GO(gtk_image_get_storage_type, iFp)
+GO(gtk_image_get_storage_type, uFp)
GO(gtk_image_get_type, pFv)
GO(gtk_image_menu_item_get_always_show_image, iFp)
GO(gtk_image_menu_item_get_image, pFp)
@@ -1422,9 +1439,9 @@ GO(gtk_image_menu_item_set_use_stock, vFpi)
GO(gtk_image_new, pFv)
GO(gtk_image_new_from_animation, pFp)
GO(gtk_image_new_from_file, pFp)
-GO(gtk_image_new_from_gicon, pFpi)
+GO(gtk_image_new_from_gicon, pFpu)
GO(gtk_image_new_from_icon_name, pFpi)
-GO(gtk_image_new_from_icon_set, pFpi)
+GO(gtk_image_new_from_icon_set, pFpu)
GO(gtk_image_new_from_image, pFpp)
GO(gtk_image_new_from_pixbuf, pFp)
GO(gtk_image_new_from_pixmap, pFpp)
@@ -1432,9 +1449,9 @@ GO(gtk_image_new_from_stock, pFpi)
GO(gtk_image_set, vFppp)
GO(gtk_image_set_from_animation, vFpp)
GO(gtk_image_set_from_file, vFppp)
-GO(gtk_image_set_from_gicon, vFppi)
-GO(gtk_image_set_from_icon_name, vFppi)
-GO(gtk_image_set_from_icon_set, vFppi)
+GO(gtk_image_set_from_gicon, vFppu)
+GO(gtk_image_set_from_icon_name, vFppu)
+GO(gtk_image_set_from_icon_set, vFppu)
GO(gtk_image_set_from_image, vFppp)
GO(gtk_image_set_from_pixbuf, vFpp)
GO(gtk_image_set_from_pixmap, vFppp)
@@ -1465,19 +1482,19 @@ GO(gtk_im_multicontext_new, pFv)
GO(gtk_im_multicontext_set_context_id, vFpp)
GO(gtk_im_preedit_style_get_type, pFv)
GO(gtk_im_status_style_get_type, pFv)
-//GO(gtk_info_bar_add_action_widget,
-//GO(gtk_info_bar_add_button,
+GO(gtk_info_bar_add_action_widget, vFppi)
+GO(gtk_info_bar_add_button, pFppi)
//GO(gtk_info_bar_add_buttons,
//GO(gtk_info_bar_get_action_area,
-//GO(gtk_info_bar_get_content_area,
-//GO(gtk_info_bar_get_message_type,
+GO(gtk_info_bar_get_content_area, pFp)
+GO(gtk_info_bar_get_message_type, uFp)
GO(gtk_info_bar_get_type, pFv)
//GO(gtk_info_bar_new,
//GO(gtk_info_bar_new_with_buttons,
-//GO(gtk_info_bar_response,
+GO(gtk_info_bar_response, vFpi)
//GO(gtk_info_bar_set_default_response,
-//GO(gtk_info_bar_set_message_type,
-//GO(gtk_info_bar_set_response_sensitive,
+GO(gtk_info_bar_set_message_type, vFpu)
+GO(gtk_info_bar_set_response_sensitive, vFpii)
GOM(gtk_init, vFEpp)
//GO(gtk_init_add,
GOM(gtk_init_check, iFEpp)
@@ -1488,11 +1505,11 @@ GO(gtk_input_dialog_new, pFv)
GO(gtk_input_hints_get_type, pFv)
GO(gtk_input_purpose_get_type, pFv)
GO(gtk_input_remove, vFu)
-//GO(gtk_invisible_get_screen,
+GO(gtk_invisible_get_screen, pFp)
GO(gtk_invisible_get_type, pFv)
//GO(gtk_invisible_new,
-//GO(gtk_invisible_new_for_screen,
-//GO(gtk_invisible_set_screen,
+GO(gtk_invisible_new_for_screen, pFp)
+GO(gtk_invisible_set_screen, vFpp)
//GO(gtk_item_deselect,
//GO(gtk_item_factories_path_delete,
//GO(gtk_item_factory_add_foreign,
@@ -1528,13 +1545,13 @@ GO(gtk_label_get, vFpp)
GO(gtk_label_get_angle, dFp)
GO(gtk_label_get_attributes, pFp)
GO(gtk_label_get_current_uri, pFp)
-GO(gtk_label_get_ellipsize, iFp)
-GO(gtk_label_get_justify, iFp)
+GO(gtk_label_get_ellipsize, uFp)
+GO(gtk_label_get_justify, uFp)
GO(gtk_label_get_label, pFp)
GO(gtk_label_get_layout, pFp)
GO(gtk_label_get_layout_offsets, vFppp)
GO(gtk_label_get_line_wrap, iFp)
-GO(gtk_label_get_line_wrap_mode, iFp)
+GO(gtk_label_get_line_wrap_mode, uFp)
GO(gtk_label_get_max_width_chars, iFp)
GO(gtk_label_get_mnemonic_keyval, uFp)
GO(gtk_label_get_mnemonic_widget, pFp)
@@ -1553,11 +1570,11 @@ GO(gtk_label_parse_uline, uFpp)
GO(gtk_label_select_region, vFpii)
GO(gtk_label_set_angle, vFpd)
GO(gtk_label_set_attributes, vFpp)
-GO(gtk_label_set_ellipsize, vFpi)
-GO(gtk_label_set_justify, vFpi)
+GO(gtk_label_set_ellipsize, vFpu)
+GO(gtk_label_set_justify, vFpu)
GO(gtk_label_set_label, vFpp)
GO(gtk_label_set_line_wrap, vFpi)
-GO(gtk_label_set_line_wrap_mode, vFpi)
+GO(gtk_label_set_line_wrap_mode, vFpu)
GO(gtk_label_set_markup, vFpp)
GO(gtk_label_set_markup_with_mnemonic, vFpp)
GO(gtk_label_set_max_width_chars, vFpi)
@@ -1572,32 +1589,33 @@ GO(gtk_label_set_use_markup, vFpi)
GO(gtk_label_set_use_underline, vFpi)
GO(gtk_label_set_width_chars, vFpi)
//GO(gtk_layout_freeze,
-//GO(gtk_layout_get_bin_window,
+GO(gtk_layout_get_bin_window, pFp)
//GO(gtk_layout_get_hadjustment,
-//GO(gtk_layout_get_size,
+GO(gtk_layout_get_size, vFppp)
GO(gtk_layout_get_type, pFv)
-//GO(gtk_layout_get_vadjustment,
-//GO(gtk_layout_move,
+GO(gtk_layout_get_vadjustment, pFp)
+GO(gtk_layout_move, vFppii)
GO(gtk_layout_new, pFpp)
//GO(gtk_layout_put,
//GO(gtk_layout_set_hadjustment,
-//GO(gtk_layout_set_size,
-//GO(gtk_layout_set_vadjustment,
+GO(gtk_layout_set_size, vFpuu)
+GO(gtk_layout_set_vadjustment, vFpp)
//GO(gtk_layout_thaw,
GO(gtk_level_bar_mode_get_type, pFv)
GO(gtk_level_bar_get_type, pFv)
GO(gtk_license_get_type, pFv)
GO(gtk_link_button_get_type, pFv)
-//GO(gtk_link_button_get_uri,
-//GO(gtk_link_button_get_visited,
+GO(gtk_link_button_get_uri, pFp)
+GO(gtk_link_button_get_visited, iFp)
//GO(gtk_link_button_new,
//GO(gtk_link_button_new_with_label,
-//GO(gtk_link_button_set_uri,
+GO(gtk_link_button_set_uri, vFpp)
//GO(gtk_link_button_set_uri_hook,
-//GO(gtk_link_button_set_visited,
+GO(gtk_link_button_set_visited, vFpi)
GO(gtk_list_append_items, vFpp)
GO(gtk_list_box_get_type, pFv)
GO(gtk_list_box_row_get_type, pFv)
+GO(gtk_list_box_set_header_func, vFppp)
GO(gtk_list_child_position, iFpp)
GO(gtk_list_clear_items, vFpii)
GO(gtk_list_end_drag_selection, vFp)
@@ -1685,12 +1703,14 @@ GO(gtk_main_quit, vFv)
GO(gtk_match_type_get_type, pFv)
GO(gtk_menu_attach, vFppuuuu)
GOM(gtk_menu_attach_to_widget, vFEppp)
-GO(gtk_menu_bar_get_child_pack_direction, iFp)
+GO(gtk_menu_bar_get_child_pack_direction, uFp)
GO(gtk_menu_bar_get_pack_direction, iFp)
GO(gtk_menu_bar_get_type, pFv)
GO(gtk_menu_bar_new, pFv)
-GO(gtk_menu_bar_set_child_pack_direction, vFpi)
+GO(gtk_menu_bar_set_child_pack_direction, vFpu)
GO(gtk_menu_bar_set_pack_direction, vFpi)
+GO(gtk_menu_button_new, pFv)
+GO(gtk_menu_button_set_menu_model, vFpp)
GO(gtk_menu_button_get_type, pFv)
GO(gtk_menu_detach, vFp)
GO(gtk_menu_direction_type_get_type, pFv)
@@ -1737,26 +1757,26 @@ GO(gtk_menu_set_reserve_toggle_size, vFpi)
GO(gtk_menu_set_screen, vFpp)
GO(gtk_menu_set_tearoff_state, vFpi)
GO(gtk_menu_set_title, vFpp)
-//GO(gtk_menu_shell_activate_item,
+GO(gtk_menu_shell_activate_item, vFppi)
GO(gtk_menu_shell_append, vFpp)
//GO(gtk_menu_shell_cancel,
//GO(gtk_menu_shell_deactivate,
//GO(gtk_menu_shell_deselect,
-//GO(gtk_menu_shell_get_take_focus,
+GO(gtk_menu_shell_get_take_focus, iFp)
GO(gtk_menu_shell_get_type, pFv)
GO(gtk_menu_shell_insert, vFppi)
GO(gtk_menu_shell_prepend, vFpp)
GO(gtk_menu_shell_select_first, vFpi)
GO(gtk_menu_shell_select_item, vFpp)
-//GO(gtk_menu_shell_set_take_focus,
-//GO(gtk_menu_tool_button_get_menu,
+GO(gtk_menu_shell_set_take_focus, vFpi)
+GO(gtk_menu_tool_button_get_menu, pFp)
GO(gtk_menu_tool_button_get_type, pFv)
-//GO(gtk_menu_tool_button_new,
+GO(gtk_menu_tool_button_new, pFpp)
//GO(gtk_menu_tool_button_new_from_stock,
//GO(gtk_menu_tool_button_set_arrow_tooltip,
-//GO(gtk_menu_tool_button_set_arrow_tooltip_markup,
+GO(gtk_menu_tool_button_set_arrow_tooltip_markup, vFpp)
//GO(gtk_menu_tool_button_set_arrow_tooltip_text,
-//GO(gtk_menu_tool_button_set_menu,
+GO(gtk_menu_tool_button_set_menu, vFpp)
GOM(gtk_message_dialog_format_secondary_markup, vFEppV)
GOM(gtk_message_dialog_format_secondary_text, vFEppV)
GO(gtk_message_dialog_get_image, pFp)
@@ -1784,7 +1804,7 @@ GO(gtk_movement_step_get_type, pFv)
GO(gtk_native_get_surface, pFp)
GO(gtk_notebook_append_page, iFppp)
GO(gtk_notebook_append_page_menu, iFpppp)
-GO(gtk_notebook_get_action_widget, pFpi)
+GO(gtk_notebook_get_action_widget, pFpu)
GO(gtk_notebook_get_current_page, iFp)
GO(gtk_notebook_get_group, pFp)
GO(gtk_notebook_get_group_id, iFp)
@@ -1800,7 +1820,7 @@ GO(gtk_notebook_get_tab_detachable, iFpp)
GO(gtk_notebook_get_tab_hborder, WFp)
GO(gtk_notebook_get_tab_label, pFpp)
GO(gtk_notebook_get_tab_label_text, pFpp)
-GO(gtk_notebook_get_tab_pos, iFp)
+GO(gtk_notebook_get_tab_pos, uFp)
GO(gtk_notebook_get_tab_reorderable, iFpp)
GO(gtk_notebook_get_tab_vborder, WFp)
GO(gtk_notebook_get_type, pFv)
@@ -1817,7 +1837,7 @@ GO(gtk_notebook_prev_page, vFp)
GO(gtk_notebook_query_tab_label_packing, vFppppp)
GO(gtk_notebook_remove_page, vFpi)
GO(gtk_notebook_reorder_child, vFppi)
-GO(gtk_notebook_set_action_widget, vFppi)
+GO(gtk_notebook_set_action_widget, vFppu)
GO(gtk_notebook_set_current_page, vFpi)
GO(gtk_notebook_set_group, vFpp)
GO(gtk_notebook_set_group_id, vFpi)
@@ -1834,7 +1854,7 @@ GO(gtk_notebook_set_tab_hborder, vFpu)
GO(gtk_notebook_set_tab_label, vFppp)
GO(gtk_notebook_set_tab_label_packing, vFppiii)
GO(gtk_notebook_set_tab_label_text, vFppp)
-GO(gtk_notebook_set_tab_pos, vFpi)
+GO(gtk_notebook_set_tab_pos, vFpu)
GO(gtk_notebook_set_tab_reorderable, vFppi)
GO(gtk_notebook_set_tab_vborder, vFpu)
//GOM(gtk_notebook_set_window_creation_hook, pFEppp)
@@ -1878,20 +1898,21 @@ GO(gtk_option_menu_new, pFv)
GO(gtk_option_menu_remove_menu, vFp)
GO(gtk_option_menu_set_history, vFpu)
GO(gtk_option_menu_set_menu, vFpp)
-GO(gtk_orientable_get_orientation, iFp)
+GO(gtk_orientable_get_orientation, uFp)
GO(gtk_orientable_get_type, pFv)
-GO(gtk_orientable_set_orientation, vFpi)
+GO(gtk_orientable_set_orientation, vFpu)
GO(gtk_orientation_get_type, pFv)
+GO(gtk_overlay_add_overlay, vFpp)
GO(gtk_overlay_get_type, pFv)
GO(gtk_pack_direction_get_type, pFv)
GO(gtk_pack_type_get_type, pFv)
GO(gtk_page_orientation_get_type, pFv)
GO(gtk_page_set_get_type, pFv)
-//GO(gtk_page_setup_copy,
+GO(gtk_page_setup_copy, pFp)
//GO(gtk_page_setup_get_bottom_margin,
GO(gtk_page_setup_get_left_margin, dFpi)
-//GO(gtk_page_setup_get_orientation,
-GO(gtk_page_setup_get_page_height, dFpi)
+GO(gtk_page_setup_get_orientation, uFp)
+GO(gtk_page_setup_get_page_height, dFpu)
GO(gtk_page_setup_get_page_width, dFpi)
GO(gtk_page_setup_get_paper_height, dFpi)
GO(gtk_page_setup_get_paper_size, pFp)
@@ -1900,54 +1921,54 @@ GO(gtk_page_setup_get_right_margin, dFpi)
GO(gtk_page_setup_get_top_margin, dFpi)
GO(gtk_page_setup_get_type, pFv)
//GO(gtk_page_setup_load_file,
-//GO(gtk_page_setup_load_key_file,
+GO(gtk_page_setup_load_key_file, iFpppp)
GO(gtk_page_setup_new, pFv)
-//GO(gtk_page_setup_new_from_file,
-//GO(gtk_page_setup_new_from_key_file,
+GO(gtk_page_setup_new_from_file, pFpp)
+GO(gtk_page_setup_new_from_key_file, pFppp)
//GO(gtk_page_setup_set_bottom_margin,
//GO(gtk_page_setup_set_left_margin,
-//GO(gtk_page_setup_set_orientation,
+GO(gtk_page_setup_set_orientation, vFpu)
GO(gtk_page_setup_set_paper_size, vFpp)
-//GO(gtk_page_setup_set_paper_size_and_default_margins,
-//GO(gtk_page_setup_set_right_margin,
+GO(gtk_page_setup_set_paper_size_and_default_margins, vFpp)
+GO(gtk_page_setup_set_right_margin, vFpdu)
//GO(gtk_page_setup_set_top_margin,
-//GO(gtk_page_setup_to_file,
-//GO(gtk_page_setup_to_key_file,
+GO(gtk_page_setup_to_file, iFppp)
+GO(gtk_page_setup_to_key_file, vFppp)
//GO(gtk_page_setup_unix_dialog_get_page_setup,
//GO(gtk_page_setup_unix_dialog_get_print_settings,
GO(gtk_page_setup_unix_dialog_get_type, pFv)
//GO(gtk_page_setup_unix_dialog_new,
//GO(gtk_page_setup_unix_dialog_set_page_setup,
//GO(gtk_page_setup_unix_dialog_set_print_settings,
-GO(gtk_paint_arrow, vFppiipppiiiiii)
+GO(gtk_paint_arrow, vFppuuppuiiiii)
GO(gtk_paint_box, vFppiipppiiii)
-GO(gtk_paint_box_gap, vFppiipppiiiiiii)
+GO(gtk_paint_box_gap, vFppuuppiiiiuii)
GO(gtk_paint_check, vFppiipppiiii)
GO(gtk_paint_diamond, vFppiipppiiii)
-GO(gtk_paint_expander, vFppipppiii)
-GO(gtk_paint_extension, vFppiipppiiiii)
+GO(gtk_paint_expander, vFppuppiiu)
+GO(gtk_paint_extension, vFppuuppiiiiu)
GO(gtk_paint_flat_box, vFppiipppiiii)
-GO(gtk_paint_focus, vFppipppiiii)
-GO(gtk_paint_handle, vFppiipppiiiii)
+GO(gtk_paint_focus, vFppuppiiii)
+GO(gtk_paint_handle, vFppuuppiiiiu)
GO(gtk_paint_hline, vFppipppiii)
-GO(gtk_paint_layout, vFppiipppiip)
+GO(gtk_paint_layout, vFppuippiip)
GO(gtk_paint_option, vFppiipppiiii)
GO(gtk_paint_polygon, vFppiippppii)
-GO(gtk_paint_resize_grip, vFppipppiiiii)
+GO(gtk_paint_resize_grip, vFppuppuiiii)
GO(gtk_paint_shadow, vFppiipppiiii)
GO(gtk_paint_shadow_gap, vFppiipppiiiiiii)
GO(gtk_paint_slider, vFppiipppiiiii)
-GO(gtk_paint_spinner, vFppipppuiiii)
+GO(gtk_paint_spinner, vFppuppuiiii)
GO(gtk_paint_string, vFppipppiip)
-GO(gtk_paint_tab, vFppiipppiiii)
-GO(gtk_paint_vline, vFppipppiii)
+GO(gtk_paint_tab, vFppuuppiiii)
+GO(gtk_paint_vline, vFppuppiii)
GO(gtk_paned_add1, vFpp)
GO(gtk_paned_add2, vFpp)
GO(gtk_paned_compute_position, vFpiii)
GO(gtk_paned_get_child1, pFp)
GO(gtk_paned_get_child2, pFp)
GO(gtk_paned_get_handle_window, pFp)
-GO(gtk_paned_get_position, pFp)
+GO(gtk_paned_get_position, iFp)
GO(gtk_paned_get_type, pFv)
GO(gtk_paned_pack1, vFppii)
GO(gtk_paned_pack2, vFppii)
@@ -1957,7 +1978,7 @@ GO(gtk_paper_size_free, vFp)
GO(gtk_paper_size_get_default, pFv)
GO(gtk_paper_size_get_default_bottom_margin, dFpi)
GO(gtk_paper_size_get_default_left_margin, dFpi)
-GO(gtk_paper_size_get_default_right_margin, dFpi)
+GO(gtk_paper_size_get_default_right_margin, dFpu)
GO(gtk_paper_size_get_default_top_margin, dFpi)
GO(gtk_paper_size_get_display_name, pFp)
GO(gtk_paper_size_get_height, dFpi)
@@ -1969,10 +1990,10 @@ GO(gtk_paper_size_get_width, dFpi)
GO(gtk_paper_size_is_custom, iFp)
GO(gtk_paper_size_is_equal, iFpp)
GO(gtk_paper_size_new, pFp)
-GO(gtk_paper_size_new_custom, pFppddi)
+GO(gtk_paper_size_new_custom, pFppddu)
GO(gtk_paper_size_new_from_key_file, pFppp)
GO(gtk_paper_size_new_from_ppd, pFppdd)
-GO(gtk_paper_size_set_size, vFpddi)
+GO(gtk_paper_size_set_size, vFpddu)
GO(gtk_paper_size_to_key_file, vFppp)
GO(gtk_parse_args, iFpp)
GO(gtk_path_bar_get_type, pFv)
@@ -2024,18 +2045,18 @@ GO(gtk_print_backend_get_type, pFv)
//GO(gtk_print_backend_set_list_done,
//GO(gtk_print_backend_set_password,
GO(gtk_print_capabilities_get_type, pFv)
-//GO(gtk_print_context_create_pango_context,
-//GO(gtk_print_context_create_pango_layout,
-//GO(gtk_print_context_get_cairo_context,
+GO(gtk_print_context_create_pango_context, pFp)
+GO(gtk_print_context_create_pango_layout, pFp)
+GO(gtk_print_context_get_cairo_context, pFp)
//GO(gtk_print_context_get_dpi_x,
-//GO(gtk_print_context_get_dpi_y,
-//GO(gtk_print_context_get_hard_margins,
+GO(gtk_print_context_get_dpi_y, dFp)
+GO(gtk_print_context_get_hard_margins, iFppppp)
//GO(gtk_print_context_get_height,
-//GO(gtk_print_context_get_page_setup,
-//GO(gtk_print_context_get_pango_fontmap,
+GO(gtk_print_context_get_page_setup, pFp)
+GO(gtk_print_context_get_pango_fontmap, pFp)
GO(gtk_print_context_get_type, pFv)
//GO(gtk_print_context_get_width,
-//GO(gtk_print_context_set_cairo_context,
+GO(gtk_print_context_set_cairo_context, vFppdd)
GO(gtk_print_duplex_get_type, pFv)
//GO(gtk_printer_accepts_pdf,
//GO(gtk_printer_accepts_ps,
@@ -2117,118 +2138,118 @@ GO(gtk_print_job_set_source_file, iFppp)
GO(gtk_print_operation_action_get_type, pFv)
//GO(gtk_print_operation_cancel,
//GO(gtk_print_operation_draw_page_finish,
-//GO(gtk_print_operation_get_default_page_setup,
-//GO(gtk_print_operation_get_embed_page_setup,
-//GO(gtk_print_operation_get_error,
+GO(gtk_print_operation_get_default_page_setup, pFp)
+GO(gtk_print_operation_get_embed_page_setup, iFp)
+GO(gtk_print_operation_get_error, vFpp)
//GO(gtk_print_operation_get_has_selection,
-//GO(gtk_print_operation_get_n_pages_to_print,
-//GO(gtk_print_operation_get_print_settings,
-//GO(gtk_print_operation_get_status,
-//GO(gtk_print_operation_get_status_string,
+GO(gtk_print_operation_get_n_pages_to_print, iFp)
+GO(gtk_print_operation_get_print_settings, pFp)
+GO(gtk_print_operation_get_status, uFp)
+GO(gtk_print_operation_get_status_string, pFp)
//GO(gtk_print_operation_get_support_selection,
GO(gtk_print_operation_get_type, pFv)
//GO(gtk_print_operation_is_finished,
-//GO(gtk_print_operation_new,
+GO(gtk_print_operation_new, pFv)
//GO(gtk_print_operation_preview_end_preview,
GO(gtk_print_operation_preview_get_type, pFv)
-//GO(gtk_print_operation_preview_is_selected,
-//GO(gtk_print_operation_preview_render_page,
+GO(gtk_print_operation_preview_is_selected, iFpi)
+GO(gtk_print_operation_preview_render_page, vFpi)
GO(gtk_print_operation_result_get_type, pFv)
-//GO(gtk_print_operation_run,
+GO(gtk_print_operation_run, uFpupp)
//GO(gtk_print_operation_set_allow_async,
-//GO(gtk_print_operation_set_current_page,
-//GO(gtk_print_operation_set_custom_tab_label,
-//GO(gtk_print_operation_set_default_page_setup,
+GO(gtk_print_operation_set_current_page, vFpi)
+GO(gtk_print_operation_set_custom_tab_label, vFpp)
+GO(gtk_print_operation_set_default_page_setup, vFpp)
//GO(gtk_print_operation_set_defer_drawing,
-//GO(gtk_print_operation_set_embed_page_setup,
+GO(gtk_print_operation_set_embed_page_setup, vFpi)
//GO(gtk_print_operation_set_export_filename,
//GO(gtk_print_operation_set_has_selection,
//GO(gtk_print_operation_set_job_name,
//GO(gtk_print_operation_set_n_pages,
-//GO(gtk_print_operation_set_print_settings,
+GO(gtk_print_operation_set_print_settings, vFpp)
//GO(gtk_print_operation_set_show_progress,
//GO(gtk_print_operation_set_support_selection,
//GO(gtk_print_operation_set_track_print_status,
-//GO(gtk_print_operation_set_unit,
+GO(gtk_print_operation_set_unit, vFpu)
//GO(gtk_print_operation_set_use_full_page,
GO(gtk_print_pages_get_type, pFv)
GO(gtk_print_quality_get_type, pFv)
-//GO(gtk_print_run_page_setup_dialog,
+GO(gtk_print_run_page_setup_dialog, pFppp)
//GO(gtk_print_run_page_setup_dialog_async,
GO(gtk_print_settings_copy, pFp)
//GO(gtk_print_settings_foreach,
-//GO(gtk_print_settings_get,
-//GO(gtk_print_settings_get_bool,
+GO(gtk_print_settings_get, pFpp)
+GO(gtk_print_settings_get_bool, iFpp)
//GO(gtk_print_settings_get_collate,
//GO(gtk_print_settings_get_default_source,
//GO(gtk_print_settings_get_dither,
-//GO(gtk_print_settings_get_double,
-//GO(gtk_print_settings_get_double_with_default,
-//GO(gtk_print_settings_get_duplex,
+GO(gtk_print_settings_get_double, dFpp)
+GO(gtk_print_settings_get_double_with_default, dFppd)
+GO(gtk_print_settings_get_duplex, uFp)
//GO(gtk_print_settings_get_finishings,
-//GO(gtk_print_settings_get_int,
-//GO(gtk_print_settings_get_int_with_default,
-//GO(gtk_print_settings_get_length,
+GO(gtk_print_settings_get_int, iFpp)
+GO(gtk_print_settings_get_int_with_default, iFppi)
+GO(gtk_print_settings_get_length, dFppu)
//GO(gtk_print_settings_get_media_type,
//GO(gtk_print_settings_get_n_copies,
//GO(gtk_print_settings_get_number_up,
-//GO(gtk_print_settings_get_number_up_layout,
-GO(gtk_print_settings_get_orientation, iFp)
-//GO(gtk_print_settings_get_output_bin,
+GO(gtk_print_settings_get_number_up_layout, uFp)
+GO(gtk_print_settings_get_orientation, uFp)
+GO(gtk_print_settings_get_output_bin, pFp)
GO(gtk_print_settings_get_page_ranges, pFpp)
-//GO(gtk_print_settings_get_page_set,
-//GO(gtk_print_settings_get_paper_height,
-//GO(gtk_print_settings_get_paper_size,
+GO(gtk_print_settings_get_page_set, uFp)
+GO(gtk_print_settings_get_paper_height, dFpu)
+GO(gtk_print_settings_get_paper_size, pFp)
//GO(gtk_print_settings_get_paper_width,
GO(gtk_print_settings_get_printer, pFp)
//GO(gtk_print_settings_get_printer_lpi,
-GO(gtk_print_settings_get_print_pages, iFp)
-//GO(gtk_print_settings_get_quality,
+GO(gtk_print_settings_get_print_pages, uFp)
+GO(gtk_print_settings_get_quality, uFp)
GO(gtk_print_settings_get_resolution, iFp)
//GO(gtk_print_settings_get_resolution_x,
-//GO(gtk_print_settings_get_resolution_y,
-//GO(gtk_print_settings_get_reverse,
-//GO(gtk_print_settings_get_scale,
+GO(gtk_print_settings_get_resolution_y, iFp)
+GO(gtk_print_settings_get_reverse, iFp)
+GO(gtk_print_settings_get_scale, dFp)
GO(gtk_print_settings_get_type, pFv)
//GO(gtk_print_settings_get_use_color,
//GO(gtk_print_settings_has_key,
//GO(gtk_print_settings_load_file,
-//GO(gtk_print_settings_load_key_file,
+GO(gtk_print_settings_load_key_file, iFpppp)
GO(gtk_print_settings_new, pFv)
-//GO(gtk_print_settings_new_from_file,
-//GO(gtk_print_settings_new_from_key_file,
+GO(gtk_print_settings_new_from_file, pFpp)
+GO(gtk_print_settings_new_from_key_file, pFppp)
GO(gtk_print_settings_set, vFppp)
-//GO(gtk_print_settings_set_bool,
+GO(gtk_print_settings_set_bool, vFppi)
GO(gtk_print_settings_set_collate, vFpi)
//GO(gtk_print_settings_set_default_source,
//GO(gtk_print_settings_set_dither,
-//GO(gtk_print_settings_set_double,
-//GO(gtk_print_settings_set_duplex,
+GO(gtk_print_settings_set_double, vFppd)
+GO(gtk_print_settings_set_duplex, vFpu)
//GO(gtk_print_settings_set_finishings,
-//GO(gtk_print_settings_set_int,
-//GO(gtk_print_settings_set_length,
+GO(gtk_print_settings_set_int, vFppi)
+GO(gtk_print_settings_set_length, vFppdu)
//GO(gtk_print_settings_set_media_type,
GO(gtk_print_settings_set_n_copies, vFpi)
//GO(gtk_print_settings_set_number_up,
-//GO(gtk_print_settings_set_number_up_layout,
-GO(gtk_print_settings_set_orientation, vFpi)
-//GO(gtk_print_settings_set_output_bin,
-//GO(gtk_print_settings_set_page_ranges,
-//GO(gtk_print_settings_set_page_set,
-//GO(gtk_print_settings_set_paper_height,
-//GO(gtk_print_settings_set_paper_size,
+GO(gtk_print_settings_set_number_up_layout, vFpu)
+GO(gtk_print_settings_set_orientation, vFpu)
+GO(gtk_print_settings_set_output_bin, vFpp)
+GO(gtk_print_settings_set_page_ranges, vFppi)
+GO(gtk_print_settings_set_page_set, vFpu)
+GO(gtk_print_settings_set_paper_height, vFpdu)
+GO(gtk_print_settings_set_paper_size, vFpp)
//GO(gtk_print_settings_set_paper_width,
GO(gtk_print_settings_set_printer, vFpp)
GO(gtk_print_settings_set_printer_lpi, vFpd)
-GO(gtk_print_settings_set_print_pages, vFpi)
-//GO(gtk_print_settings_set_quality,
-//GO(gtk_print_settings_set_resolution,
+GO(gtk_print_settings_set_print_pages, vFpu)
+GO(gtk_print_settings_set_quality, vFpu)
+GO(gtk_print_settings_set_resolution, vFpi)
GO(gtk_print_settings_set_resolution_xy, vFpii)
-//GO(gtk_print_settings_set_reverse,
-//GO(gtk_print_settings_set_scale,
+GO(gtk_print_settings_set_reverse, vFpi)
+GO(gtk_print_settings_set_scale, vFpd)
//GO(gtk_print_settings_set_use_color,
-//GO(gtk_print_settings_to_file,
-//GO(gtk_print_settings_to_key_file,
+GO(gtk_print_settings_to_file, iFppp)
+GO(gtk_print_settings_to_key_file, vFppp)
//GO(gtk_print_settings_unset,
GO(gtk_print_status_get_type, pFv)
//GO(gtk_print_unix_dialog_add_custom_tab,
@@ -2251,10 +2272,10 @@ GO(gtk_print_unix_dialog_set_manual_capabilities, vFpi)
GO(gtk_print_unix_dialog_set_settings, vFpp)
GO(gtk_print_unix_dialog_set_support_selection, vFpi)
GO(gtk_private_flags_get_type, pFv)
-GO(gtk_progress_bar_get_ellipsize, iFp)
+GO(gtk_progress_bar_get_ellipsize, uFp)
GO(gtk_progress_bar_get_fraction, dFp)
GO(gtk_progress_bar_get_orientation, iFp)
-GO(gtk_progress_bar_get_pulse_step, fFp)
+GO(gtk_progress_bar_get_pulse_step, dFp)
GO(gtk_progress_bar_get_text, pFp)
GO(gtk_progress_bar_get_type, pFv)
GO(gtk_progress_bar_new, pFv)
@@ -2265,7 +2286,7 @@ GO(gtk_progress_bar_set_activity_blocks, vFpu)
GO(gtk_progress_bar_set_activity_step, vFpu)
GO(gtk_progress_bar_set_bar_style, vFpi)
GO(gtk_progress_bar_set_discrete_blocks, vFpu)
-GO(gtk_progress_bar_set_ellipsize, vFpi)
+GO(gtk_progress_bar_set_ellipsize, vFpu)
GO(gtk_progress_bar_set_fraction, vFpd)
GO(gtk_progress_bar_set_orientation, vFpi)
GO(gtk_progress_bar_set_pulse_step, vFpd)
@@ -2337,7 +2358,7 @@ GO(gtk_range_get_slider_range, vFppp)
GO(gtk_range_get_slider_size_fixed, iFp)
GO(gtk_range_get_type, pFv)
GO(gtk_range_get_update_policy, iFp)
-GO(gtk_range_get_upper_stepper_sensitivity, iFp)
+GO(gtk_range_get_upper_stepper_sensitivity, uFp)
GO(gtk_range_get_value, dFp)
GO(gtk_range_set_adjustment, vFpp)
GO(gtk_range_set_fill_level, vFpd)
@@ -2352,7 +2373,7 @@ GO(gtk_range_set_round_digits, vFpi)
GO(gtk_range_set_show_fill_level, vFpi)
GO(gtk_range_set_slider_size_fixed, vFpi)
GO(gtk_range_set_update_policy, vFpi)
-GO(gtk_range_set_upper_stepper_sensitivity, vFpi)
+GO(gtk_range_set_upper_stepper_sensitivity, vFpu)
GO(gtk_range_set_value, vFpd)
GO(gtk_rc_add_class_style, vFpp)
GO(gtk_rc_add_default_file, vFp)
@@ -2366,7 +2387,7 @@ GO(gtk_rc_get_im_module_file, pFv)
GO(gtk_rc_get_im_module_path, pFv)
GO(gtk_rc_get_module_dir, pFv)
GO(gtk_rc_get_style, pFp)
-GO(gtk_rc_get_style_by_paths, pFpppi)
+GO(gtk_rc_get_style_by_paths, pFpppL)
GO(gtk_rc_get_theme_dir, pFv)
GO(gtk_rc_parse, vFp)
GO(gtk_rc_parse_color, uFpp)
@@ -2392,111 +2413,111 @@ GO(gtk_rc_style_unref, vFp)
GO(gtk_rc_token_type_get_type, pFv)
GO(gtk_revealer_get_type, pFv)
GO(gtk_revealer_transition_type_get_type, pFv)
-//GO(gtk_recent_action_get_show_numbers,
+GO(gtk_recent_action_get_show_numbers, iFp)
GO(gtk_recent_action_get_type, pFv)
-//GO(gtk_recent_action_new,
-//GO(gtk_recent_action_new_for_manager,
-//GO(gtk_recent_action_set_show_numbers,
+GO(gtk_recent_action_new, pFpppp)
+GO(gtk_recent_action_new_for_manager, pFppppp)
+GO(gtk_recent_action_set_show_numbers, vFpi)
//GO(gtk_recent_chooser_add_filter,
GO(gtk_recent_chooser_dialog_get_type, pFv)
//GO(gtk_recent_chooser_dialog_new,
//GO(gtk_recent_chooser_dialog_new_for_manager,
GO(gtk_recent_chooser_error_get_type, pFv)
-//GO(gtk_recent_chooser_error_quark,
-//GO(gtk_recent_chooser_get_current_item,
-//GO(gtk_recent_chooser_get_current_uri,
-//GO(gtk_recent_chooser_get_filter,
-//GO(gtk_recent_chooser_get_items,
-//GO(gtk_recent_chooser_get_limit,
+GO(gtk_recent_chooser_error_quark, uFv)
+GO(gtk_recent_chooser_get_current_item, pFp)
+GO(gtk_recent_chooser_get_current_uri, pFp)
+GO(gtk_recent_chooser_get_filter, pFp)
+GO(gtk_recent_chooser_get_items, pFp)
+GO(gtk_recent_chooser_get_limit, iFp)
//GO(gtk_recent_chooser_get_local_only,
//GO(gtk_recent_chooser_get_select_multiple,
-//GO(gtk_recent_chooser_get_show_icons,
+GO(gtk_recent_chooser_get_show_icons, iFp)
//GO(gtk_recent_chooser_get_show_not_found,
//GO(gtk_recent_chooser_get_show_numbers,
//GO(gtk_recent_chooser_get_show_private,
//GO(gtk_recent_chooser_get_show_tips,
-//GO(gtk_recent_chooser_get_sort_type,
+GO(gtk_recent_chooser_get_sort_type, uFp)
GO(gtk_recent_chooser_get_type, pFv)
-//GO(gtk_recent_chooser_get_uris,
-//GO(gtk_recent_chooser_list_filters,
-//GO(gtk_recent_chooser_menu_get_show_numbers,
+GO(gtk_recent_chooser_get_uris, pFpp)
+GO(gtk_recent_chooser_list_filters, pFp)
+GO(gtk_recent_chooser_menu_get_show_numbers, iFp)
GO(gtk_recent_chooser_menu_get_type, pFv)
//GO(gtk_recent_chooser_menu_new,
//GO(gtk_recent_chooser_menu_new_for_manager,
-//GO(gtk_recent_chooser_menu_set_show_numbers,
+GO(gtk_recent_chooser_menu_set_show_numbers, vFpi)
//GO(gtk_recent_chooser_remove_filter,
//GO(gtk_recent_chooser_select_all,
-//GO(gtk_recent_chooser_select_uri,
+GO(gtk_recent_chooser_select_uri, iFppp)
//GO(gtk_recent_chooser_set_current_uri,
-//GO(gtk_recent_chooser_set_filter,
-//GO(gtk_recent_chooser_set_limit,
+GO(gtk_recent_chooser_set_filter, vFpp)
+GO(gtk_recent_chooser_set_limit, vFpi)
//GO(gtk_recent_chooser_set_local_only,
//GO(gtk_recent_chooser_set_select_multiple,
-//GO(gtk_recent_chooser_set_show_icons,
+GO(gtk_recent_chooser_set_show_icons, vFpi)
//GO(gtk_recent_chooser_set_show_not_found,
//GO(gtk_recent_chooser_set_show_numbers,
//GO(gtk_recent_chooser_set_show_private,
//GO(gtk_recent_chooser_set_show_tips,
//GO(gtk_recent_chooser_set_sort_func,
-//GO(gtk_recent_chooser_set_sort_type,
+GO(gtk_recent_chooser_set_sort_type, vFpu)
//GO(gtk_recent_chooser_unselect_all,
-//GO(gtk_recent_chooser_unselect_uri,
+GO(gtk_recent_chooser_unselect_uri, vFpp)
GO(gtk_recent_chooser_widget_get_type, pFv)
//GO(gtk_recent_chooser_widget_new,
-//GO(gtk_recent_chooser_widget_new_for_manager,
-//GO(gtk_recent_filter_add_age,
+GO(gtk_recent_chooser_widget_new_for_manager, pFp)
+GO(gtk_recent_filter_add_age, vFpi)
//GO(gtk_recent_filter_add_application,
//GO(gtk_recent_filter_add_custom,
-//GO(gtk_recent_filter_add_group,
+GO(gtk_recent_filter_add_group, vFpp)
//GO(gtk_recent_filter_add_mime_type,
//GO(gtk_recent_filter_add_pattern,
//GO(gtk_recent_filter_add_pixbuf_formats,
-//GO(gtk_recent_filter_filter,
+GO(gtk_recent_filter_filter, iFpp)
GO(gtk_recent_filter_flags_get_type, pFv)
-//GO(gtk_recent_filter_get_name,
-//GO(gtk_recent_filter_get_needed,
+GO(gtk_recent_filter_get_name, pFp)
+GO(gtk_recent_filter_get_needed, uFp)
GO(gtk_recent_filter_get_type, pFv)
-//GO(gtk_recent_filter_new,
+GO(gtk_recent_filter_new, pFv)
//GO(gtk_recent_filter_set_name,
-//GO(gtk_recent_info_exists,
+GO(gtk_recent_info_exists, iFp)
//GO(gtk_recent_info_get_added,
-//GO(gtk_recent_info_get_age,
-//GO(gtk_recent_info_get_application_info,
+GO(gtk_recent_info_get_age, iFp)
+GO(gtk_recent_info_get_application_info, iFppppp)
//GO(gtk_recent_info_get_applications,
//GO(gtk_recent_info_get_description,
//GO(gtk_recent_info_get_display_name,
-//GO(gtk_recent_info_get_groups,
-//GO(gtk_recent_info_get_icon,
-//GO(gtk_recent_info_get_mime_type,
+GO(gtk_recent_info_get_groups, pFpp)
+GO(gtk_recent_info_get_icon, pFpi)
+GO(gtk_recent_info_get_mime_type, pFp)
//GO(gtk_recent_info_get_modified,
//GO(gtk_recent_info_get_private_hint,
//GO(gtk_recent_info_get_short_name,
GO(gtk_recent_info_get_type, pFv)
//GO(gtk_recent_info_get_uri,
-//GO(gtk_recent_info_get_uri_display,
-//GO(gtk_recent_info_get_visited,
+GO(gtk_recent_info_get_uri_display, pFp)
+GO(gtk_recent_info_get_visited, lFp)
//GO(gtk_recent_info_has_application,
-//GO(gtk_recent_info_has_group,
+GO(gtk_recent_info_has_group, iFpp)
//GO(gtk_recent_info_is_local,
//GO(gtk_recent_info_last_application,
-//GO(gtk_recent_info_match,
-//GO(gtk_recent_info_ref,
-//GO(gtk_recent_info_unref,
-//GO(gtk_recent_manager_add_full,
+GO(gtk_recent_info_match, iFpp)
+GO(gtk_recent_info_ref, pFp)
+GO(gtk_recent_info_unref, vFp)
+GO(gtk_recent_manager_add_full, iFppp)
//GO(gtk_recent_manager_add_item,
GO(gtk_recent_manager_error_get_type, pFv)
//GO(gtk_recent_manager_error_quark,
-//GO(gtk_recent_manager_get_default,
+GO(gtk_recent_manager_get_default, pFv)
//GO(gtk_recent_manager_get_for_screen,
-//GO(gtk_recent_manager_get_items,
+GO(gtk_recent_manager_get_items, pFp)
//GO(gtk_recent_manager_get_limit,
GO(gtk_recent_manager_get_type, pFv)
-//GO(gtk_recent_manager_has_item,
-//GO(gtk_recent_manager_lookup_item,
-//GO(gtk_recent_manager_move_item,
+GO(gtk_recent_manager_has_item, iFpp)
+GO(gtk_recent_manager_lookup_item, pFppp)
+GO(gtk_recent_manager_move_item, iFpppp)
//GO(gtk_recent_manager_new,
-//GO(gtk_recent_manager_purge_items,
-//GO(gtk_recent_manager_remove_item,
+GO(gtk_recent_manager_purge_items, iFpp)
+GO(gtk_recent_manager_remove_item, iFppp)
//GO(gtk_recent_manager_set_limit,
//GO(gtk_recent_manager_set_screen,
GO(gtk_recent_sort_type_get_type, pFv)
@@ -2507,25 +2528,25 @@ GO(gtk_render_background, vFppdddd)
GO(gtk_render_background_get_clip, vFpddddp)
GO(gtk_render_check, vFppdddd)
GO(gtk_render_expander, vFppdddd)
-GO(gtk_render_extension, vFppddddi)
+GO(gtk_render_extension, vFppddddu)
GO(gtk_render_focus, vFppdddd)
GO(gtk_render_frame, vFppdddd)
-GO(gtk_render_frame_gap, vFppddddidd)
+GO(gtk_render_frame_gap, vFppddddudd)
GO(gtk_render_handle, vFppdddd)
GO(gtk_render_icon, vFpppdd)
-GO(gtk_render_icon_pixbuf, pFppi)
+GO(gtk_render_icon_pixbuf, pFppu)
GO(gtk_render_icon_surface, vFpppdd)
-GO(gtk_render_insertion_cursor, vFppddpii)
+GO(gtk_render_insertion_cursor, vFppddpiu)
GO(gtk_render_layout, vFppddp)
GO(gtk_render_line, vFppdddd)
GO(gtk_render_option, vFppdddd)
-GO(gtk_render_slider, vFppddddi)
+GO(gtk_render_slider, vFppddddu)
GO(gtk_requisition_copy, pFp)
GO(gtk_requisition_free, vFp)
GO(gtk_requisition_get_type, pFv)
GO(gtk_resize_mode_get_type, pFv)
GO(gtk_response_type_get_type, pFv)
-//GO(gtk_rgb_to_hsv,
+GO(gtk_rgb_to_hsv, vFdddppp)
//GO(gtk_ruler_draw_pos,
//GO(gtk_ruler_draw_ticks,
//GO(gtk_ruler_get_metric,
@@ -2533,44 +2554,44 @@ GO(gtk_response_type_get_type, pFv)
GO(gtk_ruler_get_type, pFv)
//GO(gtk_ruler_set_metric,
//GO(gtk_ruler_set_range,
-//GO(gtk_scale_add_mark,
-//GO(gtk_scale_button_get_adjustment,
+GO(gtk_scale_add_mark, vFpdup)
+GO(gtk_scale_button_get_adjustment, pFp)
//GO(gtk_scale_button_get_minus_button,
//GO(gtk_scale_button_get_orientation,
//GO(gtk_scale_button_get_plus_button,
-//GO(gtk_scale_button_get_popup,
+GO(gtk_scale_button_get_popup, pFp)
GO(gtk_scale_button_get_type, pFv)
-//GO(gtk_scale_button_get_value,
-//GO(gtk_scale_button_new,
-//GO(gtk_scale_button_set_adjustment,
-//GO(gtk_scale_button_set_icons,
+GO(gtk_scale_button_get_value, dFp)
+GO(gtk_scale_button_new, pFudddp)
+GO(gtk_scale_button_set_adjustment, vFpp)
+GO(gtk_scale_button_set_icons, vFpp)
//GO(gtk_scale_button_set_orientation,
-//GO(gtk_scale_button_set_value,
+GO(gtk_scale_button_set_value, vFpd)
//GO(gtk_scale_clear_marks,
-//GO(gtk_scale_get_digits,
+GO(gtk_scale_get_digits, iFp)
//GO(gtk_scale_get_draw_value,
-//GO(gtk_scale_get_layout,
-//GO(gtk_scale_get_layout_offsets,
+GO(gtk_scale_get_layout, pFp)
+GO(gtk_scale_get_layout_offsets, vFppp)
GO(gtk_scale_get_type, pFv)
-//GO(gtk_scale_get_value_pos,
-//GO(gtk_scale_set_digits,
+GO(gtk_scale_get_value_pos, uFp)
+GO(gtk_scale_set_digits, vFpi)
//GO(gtk_scale_set_draw_value,
-//GO(gtk_scale_set_value_pos,
+GO(gtk_scale_set_value_pos, vFpu)
GO(gtk_scrollbar_get_type, pFv)
-//GO(gtk_scrolled_window_add_with_viewport,
+GO(gtk_scrolled_window_add_with_viewport, vFpp)
GO(gtk_scrolled_window_get_hadjustment, pFp)
GO(gtk_scrolled_window_get_hscrollbar, pFp)
-GO(gtk_scrolled_window_get_placement, iFp)
+GO(gtk_scrolled_window_get_placement, uFp)
GO(gtk_scrolled_window_get_policy, vFppp)
-GO(gtk_scrolled_window_get_shadow_type, iFp)
+GO(gtk_scrolled_window_get_shadow_type, uFp)
GO(gtk_scrolled_window_get_type, pFv)
GO(gtk_scrolled_window_get_vadjustment, pFp)
GO(gtk_scrolled_window_get_vscrollbar, pFp)
GO(gtk_scrolled_window_new, pFpp)
GO(gtk_scrolled_window_set_hadjustment, vFpp)
-GO(gtk_scrolled_window_set_placement, vFpi)
-GO(gtk_scrolled_window_set_policy, vFpii)
-GO(gtk_scrolled_window_set_shadow_type, vFpi)
+GO(gtk_scrolled_window_set_placement, vFpu)
+GO(gtk_scrolled_window_set_policy, vFpuu)
+GO(gtk_scrolled_window_set_shadow_type, vFpu)
GO(gtk_scrolled_window_set_vadjustment, vFpp)
GO(gtk_scrolled_window_unset_placement, vFp)
GO(gtk_scroll_step_get_type, pFv)
@@ -2585,7 +2606,7 @@ GO(gtk_selection_convert, iFpppu)
GO(gtk_selection_data_copy, pFp)
GO(gtk_selection_data_free, vFp)
GO(gtk_selection_data_get_data, pFp)
-GO(gtk_selection_data_get_data_type, iFp)
+GO(gtk_selection_data_get_data_type, pFp)
GO(gtk_selection_data_get_display, pFp)
GO(gtk_selection_data_get_format, iFp)
GO(gtk_selection_data_get_length, iFp)
@@ -2612,7 +2633,7 @@ GO(gtk_sensitivity_type_get_type, pFv)
GO(gtk_separator_get_type, pFv)
GO(gtk_separator_menu_item_get_type, pFv)
GO(gtk_separator_menu_item_new, pFv)
-GO(gtk_separator_new, pFi)
+GO(gtk_separator_new, pFu)
GO(gtk_separator_tool_item_get_draw, iFp)
GO(gtk_separator_tool_item_get_type, pFv)
GO(gtk_separator_tool_item_new, pFv)
@@ -2630,6 +2651,7 @@ GO(gtk_settings_set_string_property, vFpppp)
GO(gtk_shadow_type_get_type, pFv)
GO(gtk_show_about_dialog, vFpppppppppppppppppppppppp) //vaarg
GO(gtk_show_uri, iFppup)
+GO(gtk_show_uri_on_window, iFppup)
GO(gtk_side_type_get_type, pFv)
//GO(gtk_signal_compat_matched,
GOM(gtk_signal_connect_full, LFEppppppii)
@@ -2644,15 +2666,15 @@ GOM(gtk_signal_connect_full, LFEppppppii)
//GO(gtk_signal_newv,
GO(gtk_signal_run_type_get_type, pFv)
//GO(gtk_size_group_add_widget,
-//GO(gtk_size_group_get_ignore_hidden,
-//GO(gtk_size_group_get_mode,
+GO(gtk_size_group_get_ignore_hidden, iFp)
+GO(gtk_size_group_get_mode, uFp)
GO(gtk_size_group_get_type, pFv)
-//GO(gtk_size_group_get_widgets,
+GO(gtk_size_group_get_widgets, pFp)
GO(gtk_size_group_mode_get_type, pFv)
-//GO(gtk_size_group_new,
-//GO(gtk_size_group_remove_widget,
-//GO(gtk_size_group_set_ignore_hidden,
-//GO(gtk_size_group_set_mode,
+GO(gtk_size_group_new, pFu)
+GO(gtk_size_group_remove_widget, vFpp)
+GO(gtk_size_group_set_ignore_hidden, vFpi)
+GO(gtk_size_group_set_mode, vFpu)
GO(gtk_snapshot_new, pFv)
GO(gtk_snapshot_free_to_node, pFp)
GO(gtk_snapshot_render_background, vFppdddd)
@@ -2671,7 +2693,7 @@ GO(gtk_spin_button_get_numeric, iFp)
GO(gtk_spin_button_get_range, vFppp)
GO(gtk_spin_button_get_snap_to_ticks, iFp)
GO(gtk_spin_button_get_type, pFv)
-GO(gtk_spin_button_get_update_policy, iFp)
+GO(gtk_spin_button_get_update_policy, uFp)
GO(gtk_spin_button_get_value, dFp)
GO(gtk_spin_button_get_value_as_int, iFp)
GO(gtk_spin_button_get_wrap, iFp)
@@ -2683,10 +2705,10 @@ GO(gtk_spin_button_set_increments, vFpdd)
GO(gtk_spin_button_set_numeric, vFpi)
GO(gtk_spin_button_set_range, vFpdd)
GO(gtk_spin_button_set_snap_to_ticks, vFpi)
-GO(gtk_spin_button_set_update_policy, vFpi)
+GO(gtk_spin_button_set_update_policy, vFpu)
GO(gtk_spin_button_set_value, vFpd)
GO(gtk_spin_button_set_wrap, vFpi)
-GO(gtk_spin_button_spin, vFpid)
+GO(gtk_spin_button_spin, vFpud)
GO(gtk_spin_button_update, vFp)
GO(gtk_spin_button_update_policy_get_type, pFv)
GO(gtk_spinner_get_type, pFv)
@@ -2718,7 +2740,7 @@ GO(gtk_status_icon_get_pixbuf, pFp)
GO(gtk_status_icon_get_screen, pFp)
GO(gtk_status_icon_get_size, iFp)
GO(gtk_status_icon_get_stock, pFp)
-GO(gtk_status_icon_get_storage_type, iFp)
+GO(gtk_status_icon_get_storage_type, uFp)
GO(gtk_status_icon_get_title, pFp)
GO(gtk_status_icon_get_tooltip_markup, pFp)
GO(gtk_status_icon_get_tooltip_text, pFp)
@@ -2754,32 +2776,32 @@ GO(gtk_stock_item_free, vFp)
GO(gtk_stock_list_ids, pFv)
GO(gtk_stock_lookup, iFpp)
GOM(gtk_stock_set_translate_func, vFEpppp)
-GO(gtk_style_apply_default_background, vFppiipiiii)
+GO(gtk_style_apply_default_background, vFpppuiiii)
GO(gtk_style_attach, pFpp)
GO(gtk_style_context_add_class, vFpp)
GO(gtk_style_context_add_provider, vFppu)
GO(gtk_style_context_add_provider_for_display, vFppu)
GO(gtk_style_context_add_provider_for_screen, vFppu)
-GO(gtk_style_context_add_region, vFppi)
+GO(gtk_style_context_add_region, vFppu)
GO(gtk_style_context_cancel_animations, vFpp)
//GO2(gtk_style_context_get, vFppV, gtk_style_context_get_valist)
GO(gtk_style_context_get_border, vFpip)
GO(gtk_style_context_get_background_color, vFpip)
-GO(gtk_style_context_get_border_color, vFpip)
+GO(gtk_style_context_get_border_color, vFpup)
GO(gtk_style_context_get_color, vFpip)
-GO(gtk_style_context_get_direction, iFp)
-GO(gtk_style_context_get_font, pFpi)
-GO(gtk_style_context_get_junction_sides, iFp)
-GO(gtk_style_context_get_margin, vFpip)
+GO(gtk_style_context_get_direction, uFp)
+GO(gtk_style_context_get_font, pFpu)
+GO(gtk_style_context_get_junction_sides, uFp)
+GO(gtk_style_context_get_margin, vFpup)
GO(gtk_style_context_get_padding, vFpip)
GO(gtk_style_context_get_parent, pFp)
GO(gtk_style_context_get_path, pFp)
-GO(gtk_style_context_get_property, vFppip)
+GO(gtk_style_context_get_property, vFppup)
GO(gtk_style_context_get_frame_clock, pFp)
GO(gtk_style_context_get_scale, iFp)
GO(gtk_style_context_get_screen, pFp)
GO(gtk_style_context_get_section, pFpp)
-GO(gtk_style_context_get_state, iFp)
+GO(gtk_style_context_get_state, uFp)
//GO2(gtk_style_context_get_style, vFpV, gtk_style_context_get_style_valist)
GO(gtk_style_context_get_style_property, vFppp)
GOM(gtk_style_context_get_style_valist, vFEpA)
@@ -2792,7 +2814,7 @@ GO(gtk_style_context_list_regions, pFp)
GO(gtk_style_context_lookup_color, iFppp)
GO(gtk_style_context_lookup_icon_set, pFpp)
GO(gtk_style_context_new, pFv)
-GO(gtk_style_context_notify_state_change, vFpppip)
+GO(gtk_style_context_notify_state_change, vFpppui)
GO(gtk_style_context_pop_animatable_region, vFp)
GO(gtk_style_context_push_animatable_region, vFpp)
GO(gtk_style_context_restore, vFp)
@@ -2805,36 +2827,36 @@ GO(gtk_style_context_reset_widgets, vFp)
GO(gtk_style_context_save, vFp)
GO(gtk_style_context_scroll_animations, vFppii)
GO(gtk_style_context_set_background, vFpp)
-GO(gtk_style_context_set_direction, vFpi)
+GO(gtk_style_context_set_direction, vFpu)
GO(gtk_style_context_set_frame_clock, vFpp)
-GO(gtk_style_context_set_junction_sides, vFpi)
+GO(gtk_style_context_set_junction_sides, vFpu)
GO(gtk_style_context_set_parent, vFpp)
GO(gtk_style_context_set_path, vFpp)
GO(gtk_style_context_set_scale, vFpi)
GO(gtk_style_context_set_screen, vFpp)
-GO(gtk_style_context_set_state, vFpi)
-GO(gtk_style_context_state_is_running, iFpip)
-GO(gtk_style_context_to_string, pFpi)
+GO(gtk_style_context_set_state, vFpu)
+GO(gtk_style_context_state_is_running, iFpup)
+GO(gtk_style_context_to_string, pFpu)
GO(gtk_style_copy, pFp)
GO(gtk_style_detach, vFp)
GO(gtk_style_get, vFpippppppppppp) //vaarg, wrap with gtk_style_get_valist?
GO(gtk_style_get_font, pFp)
-GO(gtk_style_get_style_property, vFpipp)
+GO(gtk_style_get_style_property, vFpLpp)
GO(gtk_style_get_type, pFv)
//GO(gtk_style_get_valist, vFpipA)
GO(gtk_style_lookup_color, iFppp)
GO(gtk_style_lookup_icon_set, pFpp)
GO(gtk_style_new, pFv)
GO(gtk_style_ref, pFp)
-GO(gtk_style_render_icon, pFppiiipp)
-GO(gtk_style_set_background, vFppi)
+GO(gtk_style_render_icon, pFppuuupp)
+GO(gtk_style_set_background, vFppu)
GO(gtk_style_set_font, vFpp)
GO(gtk_style_provider_get_type, pFv)
GO(gtk_style_unref, vFp)
GO(gtk_submenu_direction_get_type, pFv)
GO(gtk_submenu_placement_get_type, pFv)
GO(gtk_switch_get_type, pFv)
-GO(gtk_table_attach, vFppuuuuiiuu)
+GO(gtk_table_attach, vFppuuuuuuuu)
GO(gtk_table_attach_defaults, vFppuuuu)
GO(gtk_table_get_col_spacing, uFpu)
GO(gtk_table_get_default_col_spacing, uFp)
@@ -2862,7 +2884,7 @@ GO(gtk_target_list_find, iFppp)
GO(gtk_target_list_get_type, pFv)
GO(gtk_target_list_new, pFpu)
GO(gtk_target_list_ref, pFp)
-GO(gtk_target_list_remove, iFppp)
+GO(gtk_target_list_remove, vFpp)
GO(gtk_target_list_unref, vFp)
GO(gtk_targets_include_image, iFpii)
GO(gtk_targets_include_rich_text, iFpip)
@@ -2872,22 +2894,22 @@ GO(gtk_target_table_free, vFpi)
GO(gtk_target_table_new_from_list, pFpp)
GO(gtk_tearoff_menu_item_get_type, pFv)
GO(gtk_tearoff_menu_item_new, pFv)
-//GO(gtk_test_create_simple_window,
+GO(gtk_test_create_simple_window, pFpp)
//GO(gtk_test_create_widget,
//GO(gtk_test_display_button_window,
-//GO(gtk_test_find_label,
-//GO(gtk_test_find_sibling,
-//GO(gtk_test_find_widget,
+GO(gtk_test_find_label, pFpp)
+GO(gtk_test_find_sibling, pFpL)
+GO(gtk_test_find_widget, pFppL)
//GO(gtk_test_init,
-//GO(gtk_test_list_all_types,
-//GO(gtk_test_register_all_types,
-//GO(gtk_test_slider_get_value,
-//GO(gtk_test_slider_set_perc,
-//GO(gtk_test_spin_button_click,
-//GO(gtk_test_text_get,
-//GO(gtk_test_text_set,
+GO(gtk_test_list_all_types, pFp)
+GO(gtk_test_register_all_types, vFv)
+GO(gtk_test_slider_get_value, dFp)
+GO(gtk_test_slider_set_perc, vFpd)
+GO(gtk_test_spin_button_click, iFpui)
+GO(gtk_test_text_get, pFp)
+GO(gtk_test_text_set, vFpp)
//GO(gtk_test_widget_click,
-//GO(gtk_test_widget_send_key,
+GO(gtk_test_widget_send_key, iFpuu)
GO(gtk_text_anchored_child_set_layout, vFpp)
GO(gtk_text_attributes_copy, pFp)
GO(gtk_text_attributes_copy_values, vFpp)
@@ -2912,7 +2934,7 @@ GO(gtk_text_buffer_delete_interactive, iFpppi)
GO(gtk_text_buffer_delete_mark, vFpp)
GO(gtk_text_buffer_delete_mark_by_name, vFpp)
GO(gtk_text_buffer_delete_selection, iFpii)
-GO(gtk_text_buffer_deserialize, iFpppppup)
+GO(gtk_text_buffer_deserialize, iFpppppLp)
GO(gtk_text_buffer_deserialize_get_can_create_tags, iFpp)
GO(gtk_text_buffer_deserialize_set_can_create_tags, vFppi)
GO(gtk_text_buffer_end_user_action, vFp)
@@ -3143,7 +3165,7 @@ GO(gtk_text_tag_get_priority, iFp)
GO(gtk_text_tag_get_type, pFv)
GO(gtk_text_tag_new, pFp)
GO(gtk_text_tag_set_priority, vFpi)
-GO(gtk_text_tag_table_add, vFpp)
+GO(gtk_text_tag_table_add, iFpp)
//GOM(gtk_text_tag_table_foreach, vFEpBp)
GO(gtk_text_tag_table_get_size, iFp)
GO(gtk_text_tag_table_get_type, pFv)
@@ -3152,24 +3174,24 @@ GO(gtk_text_tag_table_new, pFv)
GO(gtk_text_tag_table_remove, vFpp)
GO(gtk_text_thaw, vFp)
GO(gtk_text_view_add_child_at_anchor, vFppp)
-GO(gtk_text_view_add_child_in_window, vFppiii)
+GO(gtk_text_view_add_child_in_window, vFppuii)
GO(gtk_text_view_backward_display_line, iFpp)
GO(gtk_text_view_backward_display_line_start, iFpp)
GO(gtk_text_view_buffer_to_window_coords, vFpiiipp)
GO(gtk_text_view_forward_display_line, iFpp)
GO(gtk_text_view_forward_display_line_end, iFpp)
GO(gtk_text_view_get_accepts_tab, iFp)
-GO(gtk_text_view_get_border_window_size, iFpi)
+GO(gtk_text_view_get_border_window_size, iFpu)
GO(gtk_text_view_get_buffer, pFp)
GO(gtk_text_view_get_cursor_visible, iFp)
GO(gtk_text_view_get_default_attributes, pFp)
GO(gtk_text_view_get_editable, iFp)
GO(gtk_text_view_get_hadjustment, pFp)
GO(gtk_text_view_get_indent, iFp)
-GO(gtk_text_view_get_iter_at_location, vFppii)
-GO(gtk_text_view_get_iter_at_position, vFpppii)
+GO(gtk_text_view_get_iter_at_location, iFppii)
+GO(gtk_text_view_get_iter_at_position, iFpppii)
GO(gtk_text_view_get_iter_location, vFppp)
-GO(gtk_text_view_get_justification, iFp)
+GO(gtk_text_view_get_justification, uFp)
GO(gtk_text_view_get_left_margin, iFp)
GO(gtk_text_view_get_line_at_y, vFppip)
GO(gtk_text_view_get_line_yrange, vFpppp)
@@ -3182,9 +3204,9 @@ GO(gtk_text_view_get_tabs, pFp)
GO(gtk_text_view_get_type, pFv)
GO(gtk_text_view_get_vadjustment, pFp)
GO(gtk_text_view_get_visible_rect, vFpp)
-GO(gtk_text_view_get_window, pFpi)
-GO(gtk_text_view_get_window_type, iFpp)
-GO(gtk_text_view_get_wrap_mode, iFp)
+GO(gtk_text_view_get_window, pFpu)
+GO(gtk_text_view_get_window_type, uFpp)
+GO(gtk_text_view_get_wrap_mode, uFp)
GO(gtk_text_view_im_context_filter_keypress, iFpp)
GO(gtk_text_view_move_child, vFppii)
GO(gtk_text_view_move_mark_onscreen, iFpp)
@@ -3197,12 +3219,12 @@ GO(gtk_text_view_scroll_mark_onscreen, vFpp)
GO(gtk_text_view_scroll_to_iter, iFppdidd)
GO(gtk_text_view_scroll_to_mark, vFppdidd)
GO(gtk_text_view_set_accepts_tab, vFpi)
-GO(gtk_text_view_set_border_window_size, vFpii)
+GO(gtk_text_view_set_border_window_size, vFpui)
GO(gtk_text_view_set_buffer, vFpp)
GO(gtk_text_view_set_cursor_visible, vFpi)
GO(gtk_text_view_set_editable, vFpi)
GO(gtk_text_view_set_indent, vFpi)
-GO(gtk_text_view_set_justification, vFpi)
+GO(gtk_text_view_set_justification, vFpu)
GO(gtk_text_view_set_left_margin, vFpi)
GO(gtk_text_view_set_overwrite, vFpi)
GO(gtk_text_view_set_pixels_above_lines, vFpi)
@@ -3210,9 +3232,9 @@ GO(gtk_text_view_set_pixels_below_lines, vFpi)
GO(gtk_text_view_set_pixels_inside_wrap, vFpi)
GO(gtk_text_view_set_right_margin, vFpi)
GO(gtk_text_view_set_tabs, vFpp)
-GO(gtk_text_view_set_wrap_mode, vFpi)
+GO(gtk_text_view_set_wrap_mode, vFpu)
GO(gtk_text_view_starts_display_line, iFpp)
-GO(gtk_text_view_window_to_buffer_coords, vFpiiipp)
+GO(gtk_text_view_window_to_buffer_coords, vFpuiipp)
GO(gtk_text_window_type_get_type, pFv)
//GO(gtk_theme_engine_create_rc_style,
//GO(gtk_theme_engine_get,
@@ -3227,12 +3249,12 @@ GO(gtk_tips_query_get_type, pFv)
//GO(gtk_tips_query_start_query,
//GO(gtk_tips_query_stop_query,
//GO(gtk_toggle_action_get_active,
-//GO(gtk_toggle_action_get_draw_as_radio,
+GO(gtk_toggle_action_get_draw_as_radio, iFp)
GO(gtk_toggle_action_get_type, pFv)
-//GO(gtk_toggle_action_new,
+GO(gtk_toggle_action_new, pFpppp)
//GO(gtk_toggle_action_set_active,
//GO(gtk_toggle_action_set_draw_as_radio,
-//GO(gtk_toggle_action_toggled,
+GO(gtk_toggle_action_toggled, vFp)
GO(gtk_toggle_button_get_active, iFp)
GO(gtk_toggle_button_get_inconsistent, iFp)
GO(gtk_toggle_button_get_mode, iFp)
@@ -3255,14 +3277,14 @@ GO(gtk_toolbar_append_space, vFp)
GO(gtk_toolbar_append_widget, vFpppp)
GO(gtk_toolbar_child_type_get_type, pFv)
GO(gtk_toolbar_get_drop_index, iFpii)
-GO(gtk_toolbar_get_icon_size, iFp)
+GO(gtk_toolbar_get_icon_size, uFp)
GO(gtk_toolbar_get_item_index, iFpp)
GO(gtk_toolbar_get_n_items, iFp)
GO(gtk_toolbar_get_nth_item, pFpi)
GO(gtk_toolbar_get_orientation, iFp)
-GO(gtk_toolbar_get_relief_style, iFp)
+GO(gtk_toolbar_get_relief_style, uFp)
GO(gtk_toolbar_get_show_arrow, iFp)
-GO(gtk_toolbar_get_style, iFp)
+GO(gtk_toolbar_get_style, uFp)
GO(gtk_toolbar_get_tooltips, iFp)
GO(gtk_toolbar_get_type, pFv)
GO(gtk_toolbar_insert, vFppi)
@@ -3278,10 +3300,10 @@ GO(gtk_toolbar_prepend_space, vFp)
GO(gtk_toolbar_prepend_widget, vFpppp)
GO(gtk_toolbar_remove_space, vFpi)
GO(gtk_toolbar_set_drop_highlight_item, vFppi)
-GO(gtk_toolbar_set_icon_size, vFpi)
+GO(gtk_toolbar_set_icon_size, vFpu)
GO(gtk_toolbar_set_orientation, vFpi)
GO(gtk_toolbar_set_show_arrow, vFpi)
-GO(gtk_toolbar_set_style, vFpi)
+GO(gtk_toolbar_set_style, vFpu)
GO(gtk_toolbar_set_tooltips, vFpi)
GO(gtk_toolbar_space_style_get_type, pFv)
GO(gtk_toolbar_style_get_type, pFv)
@@ -3302,119 +3324,119 @@ GO(gtk_tool_button_set_label, vFpp)
GO(gtk_tool_button_set_label_widget, vFpp)
GO(gtk_tool_button_set_stock_id, vFpp)
GO(gtk_tool_button_set_use_underline, vFpi)
-//GO(gtk_tool_item_get_ellipsize_mode,
+GO(gtk_tool_item_get_ellipsize_mode, uFp)
//GO(gtk_tool_item_get_expand,
//GO(gtk_tool_item_get_homogeneous,
-//GO(gtk_tool_item_get_icon_size,
+GO(gtk_tool_item_get_icon_size, uFp)
//GO(gtk_tool_item_get_is_important,
//GO(gtk_tool_item_get_orientation,
-//GO(gtk_tool_item_get_proxy_menu_item,
-//GO(gtk_tool_item_get_relief_style,
-//GO(gtk_tool_item_get_text_alignment,
-//GO(gtk_tool_item_get_text_orientation,
-//GO(gtk_tool_item_get_text_size_group,
-//GO(gtk_tool_item_get_toolbar_style,
+GO(gtk_tool_item_get_proxy_menu_item, pFpp)
+GO(gtk_tool_item_get_relief_style, uFp)
+GO(gtk_tool_item_get_text_alignment, fFp)
+GO(gtk_tool_item_get_text_orientation, uFp)
+GO(gtk_tool_item_get_text_size_group, pFp)
+GO(gtk_tool_item_get_toolbar_style, uFp)
GO(gtk_tool_item_get_type, pFv)
//GO(gtk_tool_item_get_use_drag_window,
//GO(gtk_tool_item_get_visible_horizontal,
//GO(gtk_tool_item_get_visible_vertical,
-//GO(gtk_tool_item_group_get_collapsed,
-//GO(gtk_tool_item_group_get_drop_item,
-//GO(gtk_tool_item_group_get_ellipsize,
-//GO(gtk_tool_item_group_get_header_relief,
-//GO(gtk_tool_item_group_get_item_position,
-//GO(gtk_tool_item_group_get_label,
-//GO(gtk_tool_item_group_get_label_widget,
-//GO(gtk_tool_item_group_get_n_items,
-//GO(gtk_tool_item_group_get_nth_item,
+GO(gtk_tool_item_group_get_collapsed, iFp)
+GO(gtk_tool_item_group_get_drop_item, pFpii)
+GO(gtk_tool_item_group_get_ellipsize, uFp)
+GO(gtk_tool_item_group_get_header_relief, uFp)
+GO(gtk_tool_item_group_get_item_position, iFpp)
+GO(gtk_tool_item_group_get_label, pFp)
+GO(gtk_tool_item_group_get_label_widget, pFp)
+GO(gtk_tool_item_group_get_n_items, uFp)
+GO(gtk_tool_item_group_get_nth_item, pFpu)
GO(gtk_tool_item_group_get_type, pFv)
//GO(gtk_tool_item_group_insert,
//GO(gtk_tool_item_group_new,
-//GO(gtk_tool_item_group_set_collapsed,
-//GO(gtk_tool_item_group_set_ellipsize,
-//GO(gtk_tool_item_group_set_header_relief,
-//GO(gtk_tool_item_group_set_item_position,
-//GO(gtk_tool_item_group_set_label,
-//GO(gtk_tool_item_group_set_label_widget,
+GO(gtk_tool_item_group_set_collapsed, vFpi)
+GO(gtk_tool_item_group_set_ellipsize, vFpu)
+GO(gtk_tool_item_group_set_header_relief, vFpu)
+GO(gtk_tool_item_group_set_item_position, vFppi)
+GO(gtk_tool_item_group_set_label, vFpp)
+GO(gtk_tool_item_group_set_label_widget, vFpp)
//GO(gtk_tool_item_new,
//GO(gtk_tool_item_rebuild_menu,
-//GO(gtk_tool_item_retrieve_proxy_menu_item,
+GO(gtk_tool_item_retrieve_proxy_menu_item, pFp)
//GO(gtk_tool_item_set_expand,
//GO(gtk_tool_item_set_homogeneous,
-//GO(gtk_tool_item_set_is_important,
-//GO(gtk_tool_item_set_proxy_menu_item,
+GO(gtk_tool_item_set_is_important, vFpi)
+GO(gtk_tool_item_set_proxy_menu_item, vFppp)
//GO(gtk_tool_item_set_tooltip,
-//GO(gtk_tool_item_set_tooltip_markup,
+GO(gtk_tool_item_set_tooltip_markup, vFpp)
//GO(gtk_tool_item_set_tooltip_text,
//GO(gtk_tool_item_set_use_drag_window,
//GO(gtk_tool_item_set_visible_horizontal,
//GO(gtk_tool_item_set_visible_vertical,
//GO(gtk_tool_item_toolbar_reconfigured,
-//GO(gtk_tool_palette_add_drag_dest,
+GO(gtk_tool_palette_add_drag_dest, vFppuuu)
GO(gtk_tool_palette_drag_targets_get_type, pFv)
-//GO(gtk_tool_palette_get_drag_item,
-//GO(gtk_tool_palette_get_drag_target_group,
+GO(gtk_tool_palette_get_drag_item, pFpp)
+GO(gtk_tool_palette_get_drag_target_group, pFv)
//GO(gtk_tool_palette_get_drag_target_item,
-//GO(gtk_tool_palette_get_drop_group,
-//GO(gtk_tool_palette_get_drop_item,
+GO(gtk_tool_palette_get_drop_group, pFpii)
+GO(gtk_tool_palette_get_drop_item, pFpii)
//GO(gtk_tool_palette_get_exclusive,
-//GO(gtk_tool_palette_get_expand,
-//GO(gtk_tool_palette_get_group_position,
+GO(gtk_tool_palette_get_expand, iFpp)
+GO(gtk_tool_palette_get_group_position, iFpp)
//GO(gtk_tool_palette_get_hadjustment,
-//GO(gtk_tool_palette_get_icon_size,
-//GO(gtk_tool_palette_get_style,
+GO(gtk_tool_palette_get_icon_size, uFp)
+GO(gtk_tool_palette_get_style, uFp)
GO(gtk_tool_palette_get_type, pFv)
-//GO(gtk_tool_palette_get_vadjustment,
+GO(gtk_tool_palette_get_vadjustment, pFp)
//GO(gtk_tool_palette_new,
-//GO(gtk_tool_palette_set_drag_source,
+GO(gtk_tool_palette_set_drag_source, vFpu)
//GO(gtk_tool_palette_set_exclusive,
-//GO(gtk_tool_palette_set_expand,
-//GO(gtk_tool_palette_set_group_position,
-//GO(gtk_tool_palette_set_icon_size,
-//GO(gtk_tool_palette_set_style,
+GO(gtk_tool_palette_set_expand, vFppi)
+GO(gtk_tool_palette_set_group_position, vFppi)
+GO(gtk_tool_palette_set_icon_size, vFpu)
+GO(gtk_tool_palette_set_style, vFpu)
//GO(gtk_tool_palette_unset_icon_size,
//GO(gtk_tool_palette_unset_style,
-//GO(gtk_tool_shell_get_ellipsize_mode,
-//GO(gtk_tool_shell_get_icon_size,
+GO(gtk_tool_shell_get_ellipsize_mode, uFp)
+GO(gtk_tool_shell_get_icon_size, uFp)
//GO(gtk_tool_shell_get_orientation,
-//GO(gtk_tool_shell_get_relief_style,
-//GO(gtk_tool_shell_get_style,
-//GO(gtk_tool_shell_get_text_alignment,
-//GO(gtk_tool_shell_get_text_orientation,
-//GO(gtk_tool_shell_get_text_size_group,
+GO(gtk_tool_shell_get_relief_style, uFp)
+GO(gtk_tool_shell_get_style, uFp)
+GO(gtk_tool_shell_get_text_alignment, fFp)
+GO(gtk_tool_shell_get_text_orientation, uFp)
+GO(gtk_tool_shell_get_text_size_group, pFp)
GO(gtk_tool_shell_get_type, pFv)
//GO(gtk_tool_shell_rebuild_menu,
GO(gtk_tooltip_get_type, pFv)
GO(gtk_tooltips_data_get, pFp)
GO(gtk_tooltips_disable, vFp)
GO(gtk_tooltips_enable, vFp)
-//GO(gtk_tooltip_set_custom,
-//GO(gtk_tooltip_set_icon,
-//GO(gtk_tooltip_set_icon_from_gicon,
-//GO(gtk_tooltip_set_icon_from_icon_name,
+GO(gtk_tooltip_set_custom, vFpp)
+GO(gtk_tooltip_set_icon, vFpp)
+GO(gtk_tooltip_set_icon_from_gicon, vFppu)
+GO(gtk_tooltip_set_icon_from_icon_name, vFppu)
//GO(gtk_tooltip_set_icon_from_stock,
//GO(gtk_tooltip_set_markup,
-//GO(gtk_tooltip_set_text,
-//GO(gtk_tooltip_set_tip_area,
+GO(gtk_tooltip_set_text, vFpp)
+GO(gtk_tooltip_set_tip_area, vFpp)
GO(gtk_tooltips_force_window, vFp)
GO(gtk_tooltips_get_info_from_tip_window, iFppp)
GO(gtk_tooltips_get_type, pFv)
GO(gtk_tooltips_new, pFv)
GO(gtk_tooltips_set_delay, vFpu)
GO(gtk_tooltips_set_tip, vFpppp)
-//GO(gtk_tooltip_trigger_tooltip_query,
+GO(gtk_tooltip_trigger_tooltip_query, vFp)
GO(gtk_tray_icon_get_type, pFv)
//GO(gtk_tree_append,
//GO(gtk_tree_child_position,
//GO(gtk_tree_clear_items,
//GO(gtk_tree_drag_dest_drag_data_received,
GO(gtk_tree_drag_dest_get_type, pFv)
-//GO(gtk_tree_drag_dest_row_drop_possible,
-//GO(gtk_tree_drag_source_drag_data_delete,
-//GO(gtk_tree_drag_source_drag_data_get,
+GO(gtk_tree_drag_dest_row_drop_possible, iFppp)
+GO(gtk_tree_drag_source_drag_data_delete, iFpp)
+GO(gtk_tree_drag_source_drag_data_get, iFppp)
GO(gtk_tree_drag_source_get_type, pFv)
//GO(gtk_tree_drag_source_row_draggable,
-//GO(gtk_tree_get_row_drag_data,
+GO(gtk_tree_get_row_drag_data, iFppp)
GO(gtk_tree_get_type, pFv)
//GO(gtk_tree_insert,
//GO(gtk_tree_item_collapse,
@@ -3430,22 +3452,22 @@ GO(gtk_tree_iter_copy, pFp)
GO(gtk_tree_iter_free, vFp)
GO(gtk_tree_iter_get_type, pFv)
//GO(gtk_tree_model_filter_clear_cache,
-//GO(gtk_tree_model_filter_convert_child_iter_to_iter,
+GO(gtk_tree_model_filter_convert_child_iter_to_iter, iFppp)
//GO(gtk_tree_model_filter_convert_child_path_to_path,
-//GO(gtk_tree_model_filter_convert_iter_to_child_iter,
-//GO(gtk_tree_model_filter_convert_path_to_child_path,
-//GO(gtk_tree_model_filter_get_model,
+GO(gtk_tree_model_filter_convert_iter_to_child_iter, vFppp)
+GO(gtk_tree_model_filter_convert_path_to_child_path, pFpp)
+GO(gtk_tree_model_filter_get_model, pFp)
GO(gtk_tree_model_filter_get_type, pFv)
-//GO(gtk_tree_model_filter_new,
+GO(gtk_tree_model_filter_new, pFpp)
//GO(gtk_tree_model_filter_refilter,
//GO(gtk_tree_model_filter_set_modify_func,
-//GO(gtk_tree_model_filter_set_visible_column,
+GO(gtk_tree_model_filter_set_visible_column, vFpi)
//GO(gtk_tree_model_filter_set_visible_func,
GO(gtk_tree_model_flags_get_type, pFv)
//GOM(gtk_tree_model_foreach, vFEpBp)
//GO2(gtk_tree_model_get, vFppV, gtk_tree_model_get_valist)
-GO(gtk_tree_model_get_column_type, iFpi)
-GO(gtk_tree_model_get_flags, iFp)
+GO(gtk_tree_model_get_column_type, LFpi)
+GO(gtk_tree_model_get_flags, uFp)
GO(gtk_tree_model_get_iter, iFppp)
GO(gtk_tree_model_get_iter_first, iFpp)
GO(gtk_tree_model_get_iter_from_string, iFppp)
@@ -3468,14 +3490,14 @@ GO(gtk_tree_model_row_has_child_toggled, vFppp)
GO(gtk_tree_model_row_inserted, vFppp)
GO(gtk_tree_model_rows_reordered, vFpppp)
//GO(gtk_tree_model_sort_clear_cache,
-//GO(gtk_tree_model_sort_convert_child_iter_to_iter,
+GO(gtk_tree_model_sort_convert_child_iter_to_iter, iFppp)
//GO(gtk_tree_model_sort_convert_child_path_to_path,
-//GO(gtk_tree_model_sort_convert_iter_to_child_iter,
-//GO(gtk_tree_model_sort_convert_path_to_child_path,
-//GO(gtk_tree_model_sort_get_model,
+GO(gtk_tree_model_sort_convert_iter_to_child_iter, vFppp)
+GO(gtk_tree_model_sort_convert_path_to_child_path, pFpp)
+GO(gtk_tree_model_sort_get_model, pFp)
GO(gtk_tree_model_sort_get_type, pFv)
-//GO(gtk_tree_model_sort_iter_is_valid,
-//GO(gtk_tree_model_sort_new_with_model,
+GO(gtk_tree_model_sort_iter_is_valid, iFpp)
+GO(gtk_tree_model_sort_new_with_model, pFp)
//GO(gtk_tree_model_sort_reset_default_sort_func,
GO(gtk_tree_model_unref_node, vFpp)
//GO(gtk_tree_new,
@@ -3515,7 +3537,7 @@ GO(gtk_tree_row_reference_reordered, vFpppp)
GO(gtk_tree_row_reference_valid, iFp)
//GO(gtk_tree_select_child,
GO(gtk_tree_selection_count_selected_rows, iFp)
-GO(gtk_tree_selection_get_mode, iFp)
+GO(gtk_tree_selection_get_mode, uFp)
GO(gtk_tree_selection_get_selected, iFppp)
GO(gtk_tree_selection_get_selected_rows, pFpp)
//GOM(gtk_tree_selection_get_select_function, BFEp)
@@ -3529,14 +3551,14 @@ GO(gtk_tree_selection_select_all, vFp)
GO(gtk_tree_selection_select_iter, vFpp)
GO(gtk_tree_selection_select_path, vFpp)
GO(gtk_tree_selection_select_range, vFppp)
-GO(gtk_tree_selection_set_mode, vFpi)
+GO(gtk_tree_selection_set_mode, vFpu)
//GOM(gtk_tree_selection_set_select_function, vFEpBpB)
GO(gtk_tree_selection_unselect_all, vFp)
GO(gtk_tree_selection_unselect_iter, vFpp)
GO(gtk_tree_selection_unselect_path, vFpp)
GO(gtk_tree_selection_unselect_range, vFppp)
//GO(gtk_tree_select_item,
-//GO(gtk_tree_set_row_drag_data,
+GO(gtk_tree_set_row_drag_data, iFppp)
//GO(gtk_tree_set_selection_mode,
//GO(gtk_tree_set_view_lines,
//GO(gtk_tree_set_view_mode,
@@ -3544,32 +3566,32 @@ GO(gtk_tree_sortable_get_sort_column_id, iFppp)
GO(gtk_tree_sortable_get_type, pFv)
GO(gtk_tree_sortable_has_default_sort_func, iFp)
GOM(gtk_tree_sortable_set_default_sort_func, vFEpppp)
-GO(gtk_tree_sortable_set_sort_column_id, vFpii)
+GO(gtk_tree_sortable_set_sort_column_id, vFpiu)
GOM(gtk_tree_sortable_set_sort_func, vFEpippp)
GO(gtk_tree_sortable_sort_column_changed, vFp)
GO(gtk_tree_store_append, vFppp)
GO(gtk_tree_store_clear, vFp)
GO(gtk_tree_store_get_type, pFv)
-//GO(gtk_tree_store_insert,
-//GO(gtk_tree_store_insert_after,
+GO(gtk_tree_store_insert, vFpppi)
+GO(gtk_tree_store_insert_after, vFpppp)
//GO(gtk_tree_store_insert_before,
//GO(gtk_tree_store_insert_with_values,
-//GO(gtk_tree_store_insert_with_valuesv,
+GO(gtk_tree_store_insert_with_valuesv, vFpppippi)
GO(gtk_tree_store_is_ancestor, iFppp)
GO(gtk_tree_store_iter_depth, iFpp)
GO(gtk_tree_store_iter_is_valid, iFpp)
-//GO(gtk_tree_store_move_after,
+GO(gtk_tree_store_move_after, vFppp)
//GO(gtk_tree_store_move_before,
GOM(gtk_tree_store_new, pFEuV)
-GO(gtk_tree_store_newv, pFup)
+GO(gtk_tree_store_newv, pFip)
GO(gtk_tree_store_prepend, vFppp)
//GO(gtk_tree_store_remove,
GO(gtk_tree_store_reorder, vFppp)
//GO2(gtk_tree_store_set, vFppV, gtk_tree_store_set_valist)
-//GO(gtk_tree_store_set_column_types,
+GO(gtk_tree_store_set_column_types, vFpip)
//GO(gtk_tree_store_set_valist, vFppp)
-//GO(gtk_tree_store_set_value,
-//GO(gtk_tree_store_set_valuesv,
+GO(gtk_tree_store_set_value, vFppip)
+GO(gtk_tree_store_set_valuesv, vFppppi)
//GO(gtk_tree_store_swap,
//GO(gtk_tree_unselect_child,
//GO(gtk_tree_unselect_item,
@@ -3594,10 +3616,10 @@ GO(gtk_tree_view_column_get_max_width, iFp)
GO(gtk_tree_view_column_get_min_width, iFp)
GO(gtk_tree_view_column_get_reorderable, iFp)
GO(gtk_tree_view_column_get_resizable, iFp)
-GO(gtk_tree_view_column_get_sizing, iFp)
+GO(gtk_tree_view_column_get_sizing, uFp)
GO(gtk_tree_view_column_get_sort_column_id, iFp)
GO(gtk_tree_view_column_get_sort_indicator, iFp)
-GO(gtk_tree_view_column_get_sort_order, iFp)
+GO(gtk_tree_view_column_get_sort_order, uFp)
GO(gtk_tree_view_column_get_spacing, iFp)
GO(gtk_tree_view_column_get_title, pFp)
GO(gtk_tree_view_column_get_tree_view, pFp)
@@ -3621,10 +3643,10 @@ GO(gtk_tree_view_column_set_max_width, vFpi)
GO(gtk_tree_view_column_set_min_width, vFpi)
GO(gtk_tree_view_column_set_reorderable, vFpi)
GO(gtk_tree_view_column_set_resizable, vFpi)
-GO(gtk_tree_view_column_set_sizing, vFpi)
-GO(gtk_tree_view_column_set_sort_column_id, iFp)
+GO(gtk_tree_view_column_set_sizing, vFpu)
+GO(gtk_tree_view_column_set_sort_column_id, vFpi)
GO(gtk_tree_view_column_set_sort_indicator, vFpi)
-GO(gtk_tree_view_column_set_sort_order, vFpi)
+GO(gtk_tree_view_column_set_sort_order, vFpu)
GO(gtk_tree_view_column_set_spacing, vFpi)
GO(gtk_tree_view_column_set_title, vFpp)
GO(gtk_tree_view_column_set_visible, vFpi)
@@ -3639,7 +3661,7 @@ GO(gtk_tree_view_convert_widget_to_tree_coords, vFpiipp)
GO(gtk_tree_view_create_row_drag_icon, pFpp)
GO(gtk_tree_view_drop_position_get_type, pFv)
GO(gtk_tree_view_enable_model_drag_dest, vFppiu)
-GO(gtk_tree_view_enable_model_drag_source, vFpipiu)
+GO(gtk_tree_view_enable_model_drag_source, vFpupiu)
GO(gtk_tree_view_expand_all, vFp)
GO(gtk_tree_view_expand_row, iFppi)
GO(gtk_tree_view_expand_to_path, vFpp)
@@ -3655,7 +3677,7 @@ GO(gtk_tree_view_get_enable_search, iFp)
GO(gtk_tree_view_get_enable_tree_lines, iFp)
GO(gtk_tree_view_get_expander_column, pFp)
GO(gtk_tree_view_get_fixed_height_mode, iFp)
-GO(gtk_tree_view_get_grid_lines, iFp)
+GO(gtk_tree_view_get_grid_lines, uFp)
GO(gtk_tree_view_get_hadjustment, pFp)
GO(gtk_tree_view_get_headers_clickable, iFp)
GO(gtk_tree_view_get_headers_visible, iFp)
@@ -3691,7 +3713,7 @@ GO(gtk_tree_view_move_column_after, vFppp)
GO(gtk_tree_view_new, pFv)
GO(gtk_tree_view_new_with_model, pFp)
GO(gtk_tree_view_remove_column, iFpp)
-GO(gtk_tree_view_row_activated, vFp)
+GO(gtk_tree_view_row_activated, vFppp)
GO(gtk_tree_view_row_expanded, iFpp)
GO(gtk_tree_view_scroll_to_cell, vFpppiff)
GO(gtk_tree_view_scroll_to_point, vFpii)
@@ -3699,12 +3721,12 @@ GO(gtk_tree_view_scroll_to_point, vFpii)
GO(gtk_tree_view_set_cursor, vFpppi)
GO(gtk_tree_view_set_cursor_on_cell, vFppppi)
//GOM(gtk_tree_view_set_destroy_count_func, vFEpBpB)
-GO(gtk_tree_view_set_drag_dest_row, vFppi)
+GO(gtk_tree_view_set_drag_dest_row, vFppu)
GO(gtk_tree_view_set_enable_search, vFpi)
GO(gtk_tree_view_set_enable_tree_lines, vFpi)
GO(gtk_tree_view_set_expander_column, vFpp)
GO(gtk_tree_view_set_fixed_height_mode, vFpi)
-GO(gtk_tree_view_set_grid_lines, vFpi)
+GO(gtk_tree_view_set_grid_lines, vFpu)
GO(gtk_tree_view_set_hadjustment, vFpp)
GO(gtk_tree_view_set_headers_clickable, vFpi)
GO(gtk_tree_view_set_headers_visible, vFpi)
@@ -3738,25 +3760,25 @@ GO(gtk_type_flags_get_values, pFi)
GO(gtk_type_init, vFi)
GO(gtk_type_new, pFi)
GOM(gtk_type_unique, iFELp)
-//GO(gtk_ui_manager_add_ui,
+GO(gtk_ui_manager_add_ui, vFpupppui)
//GO(gtk_ui_manager_add_ui_from_file,
-//GO(gtk_ui_manager_add_ui_from_string,
-//GO(gtk_ui_manager_ensure_update,
-//GO(gtk_ui_manager_get_accel_group,
-//GO(gtk_ui_manager_get_action,
-//GO(gtk_ui_manager_get_action_groups,
-//GO(gtk_ui_manager_get_add_tearoffs,
-//GO(gtk_ui_manager_get_toplevels,
+GO(gtk_ui_manager_add_ui_from_string, uFpplp)
+GO(gtk_ui_manager_ensure_update, vFp)
+GO(gtk_ui_manager_get_accel_group, pFp)
+GO(gtk_ui_manager_get_action, pFpp)
+GO(gtk_ui_manager_get_action_groups, pFp)
+GO(gtk_ui_manager_get_add_tearoffs, iFp)
+GO(gtk_ui_manager_get_toplevels, pFpu)
GO(gtk_ui_manager_get_type, pFv)
-//GO(gtk_ui_manager_get_ui,
-//GO(gtk_ui_manager_get_widget,
-//GO(gtk_ui_manager_insert_action_group,
+GO(gtk_ui_manager_get_ui, pFp)
+GO(gtk_ui_manager_get_widget, pFpp)
+GO(gtk_ui_manager_insert_action_group, vFppi)
GO(gtk_ui_manager_item_type_get_type, pFv)
-//GO(gtk_ui_manager_new,
-//GO(gtk_ui_manager_new_merge_id,
-//GO(gtk_ui_manager_remove_action_group,
-//GO(gtk_ui_manager_remove_ui,
-//GO(gtk_ui_manager_set_add_tearoffs,
+GO(gtk_ui_manager_new, pFv)
+GO(gtk_ui_manager_new_merge_id, uFp)
+GO(gtk_ui_manager_remove_action_group, vFpp)
+GO(gtk_ui_manager_remove_ui, vFpu)
+GO(gtk_ui_manager_set_add_tearoffs, vFpi)
GO(gtk_unit_get_type, pFv)
GO(gtk_update_type_get_type, pFv)
GO(gtk_vbox_get_type, pFv)
@@ -3769,14 +3791,14 @@ GO(gtk_vbutton_box_get_type, pFv)
//GO(gtk_vbutton_box_set_spacing_default,
//GO(gtk_viewport_get_bin_window,
//GO(gtk_viewport_get_hadjustment,
-//GO(gtk_viewport_get_shadow_type,
+GO(gtk_viewport_get_shadow_type, uFp)
GO(gtk_viewport_get_type, pFv)
-//GO(gtk_viewport_get_vadjustment,
-//GO(gtk_viewport_get_view_window,
-//GO(gtk_viewport_new,
+GO(gtk_viewport_get_vadjustment, pFp)
+GO(gtk_viewport_get_view_window, pFp)
+GO(gtk_viewport_new, pFpp)
//GO(gtk_viewport_set_hadjustment,
-//GO(gtk_viewport_set_shadow_type,
-//GO(gtk_viewport_set_vadjustment,
+GO(gtk_viewport_set_shadow_type, vFpu)
+GO(gtk_viewport_set_vadjustment, vFpp)
GO(gtk_visibility_get_type, pFv)
GO(gtk_volume_button_get_type, pFv)
GO(gtk_volume_button_new, pFv)
@@ -3789,10 +3811,10 @@ GO(gtk_vscale_new, pFp)
GO(gtk_vscale_new_with_range, pFddd)
GO(gtk_vscrollbar_get_type, pFv)
GO(gtk_vscrollbar_new, pFp)
-GO(gtk_vseparator_get_type, pFv)
+GO(gtk_vseparator_get_type, LFv)
GO(gtk_vseparator_new, pFv)
GO(gtk_widget_activate, iFp)
-GO(gtk_widget_add_accelerator, vFpppuii)
+GO(gtk_widget_add_accelerator, vFpppuuu)
GO(gtk_widget_add_events, vFpi)
GO(gtk_widget_add_mnemonic_label, vFpp)
GO(gtk_widget_can_activate_accel, iFpu)
@@ -3805,8 +3827,10 @@ GO(gtk_widget_class_install_style_property, vFpp)
//GOM(gtk_widget_class_install_style_property_parser, vFEppB)
GO(gtk_widget_class_list_style_properties, pFpp)
GO(gtk_widget_class_path, vFpppp)
+GO(gtk_widget_class_set_accessible_role, vFpu)
+GO(gtk_widget_class_set_accessible_type, vFpL)
//GOM(gtk_widget_class_set_connect_func, vFEpBpB)
-GO(gtk_widget_compute_expand, iFpi)
+GO(gtk_widget_compute_expand, iFpu)
GO(gtk_widget_create_pango_context, pFp)
GO(gtk_widget_create_pango_layout, pFpp)
GO(gtk_widget_destroy, vFp)
@@ -3836,7 +3860,7 @@ GO(gtk_widget_get_default_colormap, pFv)
GO(gtk_widget_get_default_direction, iFv)
GO(gtk_widget_get_default_style, pFv)
GO(gtk_widget_get_default_visual, pFv)
-GO(gtk_widget_get_direction, iFp)
+GO(gtk_widget_get_direction, uFp)
GO(gtk_widget_get_display, pFp)
GO(gtk_widget_get_double_buffered, iFp)
GO(gtk_widget_get_events, iFp)
@@ -3870,7 +3894,7 @@ GO(gtk_widget_get_preferred_width, vFppp)
GO(gtk_widget_get_preferred_width_for_height, vFpipp)
GO(gtk_widget_get_realized, iFp)
GO(gtk_widget_get_receives_default, iFp)
-GO(gtk_widget_get_request_mode, iFp)
+GO(gtk_widget_get_request_mode, uFp)
GO(gtk_widget_get_requisition, vFpp)
GO(gtk_widget_get_root_window, pFp)
GO(gtk_widget_get_scale_factor, iFp)
@@ -3879,17 +3903,17 @@ GO(gtk_widget_get_sensitive, iFp)
GO(gtk_widget_get_settings, pFp)
GO(gtk_widget_get_size_request, vFppp)
GO(gtk_widget_get_snapshot, pFpp)
-GO(gtk_widget_get_state, iFp)
+GO(gtk_widget_get_state, uFp)
GO(gtk_widget_get_style, pFp)
GO(gtk_widget_get_style_context, pFp)
-GO(gtk_widget_get_template_child, pFpip)
+GO(gtk_widget_get_template_child, pFpLp)
GO(gtk_widget_get_tooltip_markup, pFp)
GO(gtk_widget_get_tooltip_text, pFp)
GO(gtk_widget_get_tooltip_window, pFp)
GO(gtk_widget_get_toplevel, pFp)
GO(gtk_widget_get_type, pFv)
GO(gtk_widget_get_valign, iFp)
-GO(gtk_widget_get_valign_with_baseline, iFp)
+GO(gtk_widget_get_valign_with_baseline, uFp)
GO(gtk_widget_get_vexpand, iFp)
GO(gtk_widget_get_vexpand_set, iFp)
GO(gtk_widget_get_visible, iFp)
@@ -3915,13 +3939,13 @@ GO(gtk_widget_is_drawable, iFp)
GO(gtk_widget_is_focus, iFp)
GO(gtk_widget_is_sensitive, iFp)
GO(gtk_widget_is_toplevel, iFp)
-GO(gtk_widget_keynav_failed, iFpi)
+GO(gtk_widget_keynav_failed, iFpu)
GO(gtk_widget_list_accel_closures, pFp)
GO(gtk_widget_list_mnemonic_labels, pFp)
GO(gtk_widget_map, vFp)
GO(gtk_widget_measure, vFpiipppp)
GO(gtk_widget_mnemonic_activate, iFpi)
-GO(gtk_widget_modify_base, vFpip)
+GO(gtk_widget_modify_base, vFpup)
GO(gtk_widget_modify_bg, vFpip)
GO(gtk_widget_modify_cursor, vFppp)
GO(gtk_widget_modify_fg, vFpip)
@@ -3930,29 +3954,29 @@ GO(gtk_widget_modify_style, vFpp)
GO(gtk_widget_modify_text, vFpip)
GO(gtk_widget_new, pFppppppppppppp) //vaarg
GO(gtk_widget_path, vFpppp)
-GO(gtk_widget_path_append_type, iFpp)
+GO(gtk_widget_path_append_type, iFpL)
GO(gtk_widget_path_append_with_siblings, iFppu)
GO(gtk_widget_path_append_for_widget, iFpp)
GO(gtk_widget_path_copy, pFp)
GO(gtk_widget_path_free, vFp)
-GO(gtk_widget_path_get_object_type, pFp)
-GO(gtk_widget_path_has_parent, iFpp)
+GO(gtk_widget_path_get_object_type, LFp)
+GO(gtk_widget_path_has_parent, iFpL)
GO(gtk_widget_path_is_type, iFpp)
GO(gtk_widget_path_iter_add_class, vFpip)
-GO(gtk_widget_path_iter_add_region, vFpipi)
+GO(gtk_widget_path_iter_add_region, vFpipu)
GO(gtk_widget_path_iter_clear_classes, vFpi)
GO(gtk_widget_path_iter_clear_regions, vFpi)
GO(gtk_widget_path_iter_get_name, pFpi)
GO(gtk_widget_path_iter_get_object_name, pFpi)
-GO(gtk_widget_path_iter_get_object_type, pFpi)
+GO(gtk_widget_path_iter_get_object_type, LFpi)
GO(gtk_widget_path_iter_get_siblings, pFpi)
GO(gtk_widget_path_iter_get_sibling_index, uFpi)
-GO(gtk_widget_path_iter_get_state, iFpi)
+GO(gtk_widget_path_iter_get_state, uFpi)
GO(gtk_widget_path_iter_has_class, iFpip)
GO(gtk_widget_path_iter_has_name, iFpip)
-GO(gtk_widget_path_iter_has_qclass, iFpip)
+GO(gtk_widget_path_iter_has_qclass, iFpiu)
GO(gtk_widget_path_iter_has_qname, iFpip)
-GO(gtk_widget_path_iter_has_qregion, iFpipp)
+GO(gtk_widget_path_iter_has_qregion, iFpiup)
GO(gtk_widget_path_iter_has_region, iFpipp)
GO(gtk_widget_path_iter_list_classes, pFpi)
GO(gtk_widget_path_iter_list_regions, pFpi)
@@ -3960,11 +3984,11 @@ GO(gtk_widget_path_iter_remove_class, vFpip)
GO(gtk_widget_path_iter_remove_region, vFpip)
GO(gtk_widget_path_iter_set_name, vFpip)
GO(gtk_widget_path_iter_set_object_name, vFpip)
-GO(gtk_widget_path_iter_set_object_type, vFpip)
-GO(gtk_widget_path_iter_set_state, vFpii)
+GO(gtk_widget_path_iter_set_object_type, vFpiL)
+GO(gtk_widget_path_iter_set_state, vFpiu)
GO(gtk_widget_path_length, iFp)
GO(gtk_widget_path_new, pFv)
-GO(gtk_widget_path_prepend_type, vFpp)
+GO(gtk_widget_path_prepend_type, vFpL)
GO(gtk_widget_path_to_string, pFp)
GO(gtk_widget_path_ref, pFp)
GO(gtk_widget_path_unref, vFp)
@@ -3981,9 +4005,10 @@ GO(gtk_widget_queue_resize_no_redraw, vFp)
GO(gtk_widget_realize, vFp)
GO(gtk_widget_ref, pFp)
GO(gtk_widget_region_intersect, pFpp)
-GO(gtk_widget_remove_accelerator, iFppui)
+GO(gtk_widget_register_window, vFpp)
+GO(gtk_widget_remove_accelerator, iFppuu)
GO(gtk_widget_remove_mnemonic_label, vFpp)
-GO(gtk_widget_render_icon, pFppip)
+GO(gtk_widget_render_icon, pFppup)
GO(gtk_widget_reparent, vFpp)
GO(gtk_widget_reset_rc_styles, vFp)
GO(gtk_widget_reset_shapes, vFp)
@@ -4000,8 +4025,8 @@ GO(gtk_widget_set_colormap, vFpp)
GO(gtk_widget_set_composite_name, vFpp)
GO(gtk_widget_set_css_classes, vFpp)
GO(gtk_widget_set_default_colormap, vFp)
-GO(gtk_widget_set_default_direction, vFi)
-GO(gtk_widget_set_direction, vFpi)
+GO(gtk_widget_set_default_direction, vFu)
+GO(gtk_widget_set_direction, vFpu)
GO(gtk_widget_set_double_buffered, vFpi)
GO(gtk_widget_set_events, vFpi)
GO(gtk_widget_set_extension_events, vFpi)
@@ -4028,8 +4053,8 @@ GO(gtk_widget_set_redraw_on_allocate, vFpi)
GO(gtk_widget_set_scroll_adjustments, iFppp)
GO(gtk_widget_set_sensitive, vFpi)
GO(gtk_widget_set_size_request, vFpii)
-GO(gtk_widget_set_state, vFpi)
-GO(gtk_widget_set_state_flags, vFpii)
+GO(gtk_widget_set_state, vFpu)
+GO(gtk_widget_set_state_flags, vFpui)
GO(gtk_widget_set_style, vFpp)
GO(gtk_widget_class_set_template, vFpp)
GO(gtk_widget_class_set_template_from_resource, vFpp)
@@ -4038,7 +4063,7 @@ GO(gtk_widget_set_tooltip_text, vFpp)
GO(gtk_widget_set_tooltip_window, vFpp)
GO(gtk_widget_set_uposition, vFpii)
GO(gtk_widget_set_usize, vFpii)
-GO(gtk_widget_set_valign, vFpi)
+GO(gtk_widget_set_valign, vFpu)
GO(gtk_widget_set_vexpand, vFpi)
GO(gtk_widget_set_vexpand_set, vFpi)
GO(gtk_widget_set_visible, vFpi)
@@ -4068,6 +4093,7 @@ GO(gtk_window_add_embedded_xid, vFpu)
GO(gtk_window_add_mnemonic, vFpup)
GO(gtk_window_begin_move_drag, vFpiiiu)
GO(gtk_window_begin_resize_drag, vFpuiiiu)
+GO(gtk_window_close, vFp)
GO(gtk_window_deiconify, vFp)
GO(gtk_window_destroy, vFp)
GO(gtk_window_fullscreen, vFp)
@@ -4082,13 +4108,13 @@ GO(gtk_window_get_destroy_with_parent, iFp)
GO(gtk_window_get_focus, pFp)
GO(gtk_window_get_focus_on_map, iFp)
GO(gtk_window_get_frame_dimensions, vFppppp)
-GO(gtk_window_get_gravity, iFp)
+GO(gtk_window_get_gravity, uFp)
GO(gtk_window_get_group, pFp)
GO(gtk_window_get_has_frame, iFp)
GO(gtk_window_get_icon, pFp)
GO(gtk_window_get_icon_list, pFp)
GO(gtk_window_get_icon_name, pFp)
-GO(gtk_window_get_mnemonic_modifier, iFp)
+GO(gtk_window_get_mnemonic_modifier, uFp)
GO(gtk_window_get_mnemonics_visible, iFp)
GO(gtk_window_get_modal, iFp)
GO(gtk_window_get_opacity, dFp)
@@ -4102,7 +4128,7 @@ GO(gtk_window_get_skip_taskbar_hint, iFp)
GO(gtk_window_get_title, pFp)
GO(gtk_window_get_transient_for, pFp)
GO(gtk_window_get_type, pFv)
-GO(gtk_window_get_type_hint, iFp)
+GO(gtk_window_get_type_hint, uFp)
GO(gtk_window_get_urgency_hint, iFp)
GO(gtk_window_get_window_type, uFp)
GO(gtk_window_group_add_window, vFpp)
@@ -4117,9 +4143,9 @@ GO(gtk_window_iconify, vFp)
GO(gtk_window_is_active, iFp)
GO(gtk_window_list_toplevels, pFv)
GO(gtk_window_maximize, vFp)
-GO(gtk_window_mnemonic_activate, iFpui)
+GO(gtk_window_mnemonic_activate, iFpuu)
GO(gtk_window_move, vFpii)
-GO(gtk_window_new, pFi)
+GO(gtk_window_new, pFu)
GO(gtk_window_parse_geometry, iFpp)
GO(gtk_window_position_get_type, pFv)
GO(gtk_window_present, vFp)
@@ -4144,8 +4170,8 @@ GO(gtk_window_set_destroy_with_parent, vFpi)
GO(gtk_window_set_focus, vFpp)
GO(gtk_window_set_focus_on_map, vFpi)
GO(gtk_window_set_frame_dimensions, vFpiiii)
-GO(gtk_window_set_geometry_hints, vFpppi)
-GO(gtk_window_set_gravity, vFpi)
+GO(gtk_window_set_geometry_hints, vFpppu)
+GO(gtk_window_set_gravity, vFpu)
GO(gtk_window_set_has_frame, vFpi)
GO(gtk_window_set_hide_on_close, vFpi)
GO(gtk_window_set_icon, vFpp)
@@ -4154,12 +4180,12 @@ GO(gtk_window_set_icon_list, vFpp)
GO(gtk_window_set_icon_name, vFpp)
GO(gtk_window_set_keep_above, vFpi)
GO(gtk_window_set_keep_below, vFpi)
-GO(gtk_window_set_mnemonic_modifier, vFpi)
+GO(gtk_window_set_mnemonic_modifier, vFpu)
GO(gtk_window_set_mnemonics_visible, vFpi)
GO(gtk_window_set_modal, vFpi)
GO(gtk_window_set_opacity, vFpd)
GO(gtk_window_set_policy, vFpiii)
-GO(gtk_window_set_position, vFpi)
+GO(gtk_window_set_position, vFpu)
GO(gtk_window_set_resizable, vFpi)
GO(gtk_window_set_role, vFpp)
GO(gtk_window_set_screen, vFpp)
@@ -4168,7 +4194,8 @@ GO(gtk_window_set_skip_taskbar_hint, vFpi)
GO(gtk_window_set_startup_id, vFpp)
GO(gtk_window_set_title, vFpp)
GO(gtk_window_set_transient_for, vFpp)
-GO(gtk_window_set_type_hint, vFpi)
+GO(gtk_window_set_type_hint, vFpu)
+GO(gtk_window_set_titlebar, vFpp)
GO(gtk_window_set_urgency_hint, vFpi)
GO(gtk_widget_set_visual, vFpp)
GO(gtk_window_set_wmclass, vFppp)
@@ -4178,3 +4205,13 @@ GO(gtk_window_unfullscreen, vFp)
GO(gtk_window_unmaximize, vFp)
GO(gtk_window_unstick, vFp)
GO(gtk_wrap_mode_get_type, pFv)
+GO(gtk_gesture_long_press_get_type, LFv)
+GO(gtk_gesture_single_get_type, LFv)
+GO(gtk_gesture_get_type, LFv)
+GO(gtk_gesture_rotate_new, pFp)
+GO(gtk_gesture_zoom_new, pFp)
+GO(gtk_event_controller_get_type, LFv)
+GO(gtk_stack_set_visible_child_name, vFpp)
+GO(gtk_stack_get_visible_child_name, pFp)
+
+GO(dummy_iFppdd, iFppdd) // for GtkEventController wrapping
diff --git a/src/wrapped/wrappedgtkx112.c b/src/wrapped/wrappedgtkx112.c
index 4955385..462f924 100755..100644
--- a/src/wrapped/wrappedgtkx112.c
+++ b/src/wrapped/wrappedgtkx112.c
@@ -150,10 +150,10 @@ GO(39) \
// GtkMenuDetachFunc
#define GO(A) \
-static uintptr_t my_menudetach_fct_##A = 0; \
-static void my_menudetach_##A(void* widget, void* menu) \
-{ \
- RunFunction(my_context, my_menudetach_fct_##A, 2, widget, menu);\
+static uintptr_t my_menudetach_fct_##A = 0; \
+static void my_menudetach_##A(void* widget, void* menu) \
+{ \
+ RunFunctionFmt(my_menudetach_fct_##A, "pp", widget, menu); \
}
SUPER()
#undef GO
@@ -173,10 +173,10 @@ static void* findMenuDetachFct(void* fct)
// GtkMenuPositionFunc
#define GO(A) \
-static uintptr_t my_menuposition_fct_##A = 0; \
-static void my_menuposition_##A(void* menu, void* x, void* y, void* push_in, void* data) \
-{ \
- RunFunction(my_context, my_menuposition_fct_##A, 5, menu, x, y, push_in, data);\
+static uintptr_t my_menuposition_fct_##A = 0; \
+static void my_menuposition_##A(void* menu, void* x, void* y, void* push_in, void* data) \
+{ \
+ RunFunctionFmt(my_menuposition_fct_##A, "ppppp", menu, x, y, push_in, data); \
}
SUPER()
#undef GO
@@ -196,10 +196,10 @@ static void* findMenuPositionFct(void* fct)
// GtkFunction
#define GO(A) \
-static uintptr_t my_gtkfunction_fct_##A = 0; \
-static int my_gtkfunction_##A(void* data) \
-{ \
- return RunFunction(my_context, my_gtkfunction_fct_##A, 1, data);\
+static uintptr_t my_gtkfunction_fct_##A = 0; \
+static int my_gtkfunction_##A(void* data) \
+{ \
+ return RunFunctionFmt(my_gtkfunction_fct_##A, "p", data); \
}
SUPER()
#undef GO
@@ -219,10 +219,10 @@ static void* findGtkFunctionFct(void* fct)
// GtkClipboardGetFunc
#define GO(A) \
-static uintptr_t my_clipboardget_fct_##A = 0; \
-static void my_clipboardget_##A(void* clipboard, void* selection, uint32_t info, void* data) \
-{ \
- RunFunction(my_context, my_clipboardget_fct_##A, 4, clipboard, selection, info, data);\
+static uintptr_t my_clipboardget_fct_##A = 0; \
+static void my_clipboardget_##A(void* clipboard, void* selection, uint32_t info, void* data) \
+{ \
+ RunFunctionFmt(my_clipboardget_fct_##A, "ppup", clipboard, selection, info, data); \
}
SUPER()
#undef GO
@@ -242,10 +242,10 @@ static void* findClipboadGetFct(void* fct)
// GtkClipboardClearFunc
#define GO(A) \
-static uintptr_t my_clipboardclear_fct_##A = 0; \
-static void my_clipboardclear_##A(void* clipboard, void* data) \
-{ \
- RunFunction(my_context, my_clipboardclear_fct_##A, 2, clipboard, data);\
+static uintptr_t my_clipboardclear_fct_##A = 0; \
+static void my_clipboardclear_##A(void* clipboard, void* data) \
+{ \
+ RunFunctionFmt(my_clipboardclear_fct_##A, "pp", clipboard, data); \
}
SUPER()
#undef GO
@@ -265,10 +265,10 @@ static void* findClipboadClearFct(void* fct)
// GtkCallback
#define GO(A) \
-static uintptr_t my_gtkcallback_fct_##A = 0; \
-static void my_gtkcallback_##A(void* widget, void* data) \
-{ \
- RunFunction(my_context, my_gtkcallback_fct_##A, 2, widget, data);\
+static uintptr_t my_gtkcallback_fct_##A = 0; \
+static void my_gtkcallback_##A(void* widget, void* data) \
+{ \
+ RunFunctionFmt(my_gtkcallback_fct_##A, "pp", widget, data); \
}
SUPER()
#undef GO
@@ -288,10 +288,10 @@ static void* findGtkCallbackFct(void* fct)
// GtkTextCharPredicate
#define GO(A) \
-static uintptr_t my_textcharpredicate_fct_##A = 0; \
-static int my_textcharpredicate_##A(uint32_t ch, void* data) \
-{ \
- return (int)RunFunction(my_context, my_textcharpredicate_fct_##A, 2, ch, data);\
+static uintptr_t my_textcharpredicate_fct_##A = 0; \
+static int my_textcharpredicate_##A(uint32_t ch, void* data) \
+{ \
+ return (int)RunFunctionFmt(my_textcharpredicate_fct_##A, "up", ch, data); \
}
SUPER()
#undef GO
@@ -311,10 +311,10 @@ static void* findGtkTextCharPredicateFct(void* fct)
// Toolbar
#define GO(A) \
-static uintptr_t my_toolbar_fct_##A = 0; \
-static void my_toolbar_##A(void* widget, void* data) \
-{ \
- RunFunction(my_context, my_toolbar_fct_##A, 2, widget, data);\
+static uintptr_t my_toolbar_fct_##A = 0; \
+static void my_toolbar_##A(void* widget, void* data) \
+{ \
+ RunFunctionFmt(my_toolbar_fct_##A, "pp", widget, data); \
}
SUPER()
#undef GO
@@ -334,10 +334,10 @@ static void* findToolbarFct(void* fct)
// Builder
#define GO(A) \
-static uintptr_t my_builderconnect_fct_##A = 0; \
-static void my_builderconnect_##A(void* builder, void* object, void* signal, void* handler, void* connect, int flags, void* data) \
-{ \
- RunFunction(my_context, my_builderconnect_fct_##A, 7, builder, object, signal, handler, connect, flags, data);\
+static uintptr_t my_builderconnect_fct_##A = 0; \
+static void my_builderconnect_##A(void* builder, void* object, void* signal, void* handler, void* connect, int flags, void* data) \
+{ \
+ RunFunctionFmt(my_builderconnect_fct_##A, "pppppip", builder, object, signal, handler, connect, flags, data); \
}
SUPER()
#undef GO
@@ -357,10 +357,10 @@ static void* findBuilderConnectFct(void* fct)
// GtkCellLayoutDataFunc
#define GO(A) \
-static uintptr_t my_GtkCellLayoutDataFunc_fct_##A = 0; \
-static void my_GtkCellLayoutDataFunc_##A(void* layout, void* cell, void* tree, void* iter, void* data) \
-{ \
- RunFunction(my_context, my_GtkCellLayoutDataFunc_fct_##A, 5, layout, cell, tree, iter, data);\
+static uintptr_t my_GtkCellLayoutDataFunc_fct_##A = 0; \
+static void my_GtkCellLayoutDataFunc_##A(void* layout, void* cell, void* tree, void* iter, void* data) \
+{ \
+ RunFunctionFmt(my_GtkCellLayoutDataFunc_fct_##A, "ppppp", layout, cell, tree, iter, data); \
}
SUPER()
#undef GO
@@ -380,10 +380,10 @@ static void* findGtkCellLayoutDataFuncFct(void* fct)
// GtkTreeCellDataFunc
#define GO(A) \
-static uintptr_t my_GtkTreeCellDataFunc_fct_##A = 0; \
-static void my_GtkTreeCellDataFunc_##A(void* column, void* cell, void* tree, void* iter, void* data) \
-{ \
- RunFunction(my_context, my_GtkTreeCellDataFunc_fct_##A, 5, column, cell, tree, iter, data);\
+static uintptr_t my_GtkTreeCellDataFunc_fct_##A = 0; \
+static void my_GtkTreeCellDataFunc_##A(void* column, void* cell, void* tree, void* iter, void* data) \
+{ \
+ RunFunctionFmt(my_GtkTreeCellDataFunc_fct_##A, "ppppp", column, cell, tree, iter, data); \
}
SUPER()
#undef GO
@@ -404,10 +404,10 @@ static void* findGtkTreeCellDataFuncFct(void* fct)
// GDestroyNotify
#define GO(A) \
-static uintptr_t my_GDestroyNotify_fct_##A = 0; \
-static void my_GDestroyNotify_##A(void* data) \
-{ \
- RunFunction(my_context, my_GDestroyNotify_fct_##A, 1, data); \
+static uintptr_t my_GDestroyNotify_fct_##A = 0; \
+static void my_GDestroyNotify_##A(void* data) \
+{ \
+ RunFunctionFmt(my_GDestroyNotify_fct_##A, "p", data); \
}
SUPER()
#undef GO
@@ -427,10 +427,10 @@ static void* findGDestroyNotifyFct(void* fct)
// GtkTreeModelForeachFunc
#define GO(A) \
-static uintptr_t my_GtkTreeModelForeachFunc_fct_##A = 0; \
-static int my_GtkTreeModelForeachFunc_##A(void* model, void* path, void* iter, void* data) \
-{ \
- return (int)RunFunction(my_context, my_GtkTreeModelForeachFunc_fct_##A, 4, model, path, iter, data); \
+static uintptr_t my_GtkTreeModelForeachFunc_fct_##A = 0; \
+static int my_GtkTreeModelForeachFunc_##A(void* model, void* path, void* iter, void* data) \
+{ \
+ return (int)RunFunctionFmt(my_GtkTreeModelForeachFunc_fct_##A, "pppp", model, path, iter, data); \
}
SUPER()
#undef GO
@@ -450,10 +450,10 @@ static void* findGtkTreeModelForeachFuncFct(void* fct)
// GtkTreeSelectionSelectedForeachFunc
#define GO(A) \
-static uintptr_t my_GtkTreeSelectionSelectedForeachFunc_fct_##A = 0; \
-static int my_GtkTreeSelectionSelectedForeachFunc_##A(void* selection, void* path, void* iter, void* data) \
-{ \
- return (int)RunFunction(my_context, my_GtkTreeSelectionSelectedForeachFunc_fct_##A, 4, selection, path, iter, data); \
+static uintptr_t my_GtkTreeSelectionSelectedForeachFunc_fct_##A = 0; \
+static int my_GtkTreeSelectionSelectedForeachFunc_##A(void* selection, void* path, void* iter, void* data) \
+{ \
+ return (int)RunFunctionFmt(my_GtkTreeSelectionSelectedForeachFunc_fct_##A, "pppp", selection, path, iter, data); \
}
SUPER()
#undef GO
@@ -473,10 +473,10 @@ static void* findGtkTreeSelectionSelectedForeachFuncFct(void* fct)
// GtkClipboardReceivedFunc
#define GO(A) \
-static uintptr_t my_GtkClipboardReceivedFunc_fct_##A = 0; \
-static void my_GtkClipboardReceivedFunc_##A(void* clipboard, void* sel, void* data) \
-{ \
- RunFunction(my_context, my_GtkClipboardReceivedFunc_fct_##A, 3, clipboard, sel, data); \
+static uintptr_t my_GtkClipboardReceivedFunc_fct_##A = 0; \
+static void my_GtkClipboardReceivedFunc_##A(void* clipboard, void* sel, void* data) \
+{ \
+ RunFunctionFmt(my_GtkClipboardReceivedFunc_fct_##A, "ppp", clipboard, sel, data); \
}
SUPER()
#undef GO
@@ -496,10 +496,10 @@ static void* findGtkClipboardReceivedFuncFct(void* fct)
// GtkClipboardTextReceivedFunc
#define GO(A) \
-static uintptr_t my_GtkClipboardTextReceivedFunc_fct_##A = 0; \
-static void my_GtkClipboardTextReceivedFunc_##A(void* clipboard, void* text, void* data) \
-{ \
- RunFunction(my_context, my_GtkClipboardTextReceivedFunc_fct_##A, 3, clipboard, text, data); \
+static uintptr_t my_GtkClipboardTextReceivedFunc_fct_##A = 0; \
+static void my_GtkClipboardTextReceivedFunc_##A(void* clipboard, void* text, void* data) \
+{ \
+ RunFunctionFmt(my_GtkClipboardTextReceivedFunc_fct_##A, "ppp", clipboard, text, data); \
}
SUPER()
#undef GO
@@ -519,10 +519,10 @@ static void* findGtkClipboardTextReceivedFuncFct(void* fct)
// GtkTreeViewSearchEqualFunc
#define GO(A) \
-static uintptr_t my_GtkTreeViewSearchEqualFunc_fct_##A = 0; \
-static int my_GtkTreeViewSearchEqualFunc_##A(void* model, int column, void* key, void* iter, void* data) \
-{ \
- return RunFunction(my_context, my_GtkTreeViewSearchEqualFunc_fct_##A, 5, model, column, key, iter, data); \
+static uintptr_t my_GtkTreeViewSearchEqualFunc_fct_##A = 0; \
+static int my_GtkTreeViewSearchEqualFunc_##A(void* model, int column, void* key, void* iter, void* data) \
+{ \
+ return RunFunctionFmt(my_GtkTreeViewSearchEqualFunc_fct_##A, "pippp", model, column, key, iter, data); \
}
SUPER()
#undef GO
@@ -542,10 +542,10 @@ static void* findGtkTreeViewSearchEqualFuncFct(void* fct)
// GtkTreeIterCompareFunc
#define GO(A) \
-static uintptr_t my_GtkTreeIterCompareFunc_fct_##A = 0; \
-static int my_GtkTreeIterCompareFunc_##A(void* model, void* a, void* b, void* data) \
-{ \
- return RunFunction(my_context, my_GtkTreeIterCompareFunc_fct_##A, 4, model, a, b, data); \
+static uintptr_t my_GtkTreeIterCompareFunc_fct_##A = 0; \
+static int my_GtkTreeIterCompareFunc_##A(void* model, void* a, void* b, void* data) \
+{ \
+ return RunFunctionFmt(my_GtkTreeIterCompareFunc_fct_##A, "pppp", model, a, b, data); \
}
SUPER()
#undef GO
@@ -565,10 +565,10 @@ static void* findGtkTreeIterCompareFuncFct(void* fct)
// GdkInputFunction
#define GO(A) \
-static uintptr_t my_GdkInputFunction_fct_##A = 0; \
-static void my_GdkInputFunction_##A(void* data, int source, int cond) \
-{ \
- RunFunction(my_context, my_GdkInputFunction_fct_##A, 3, data, source, cond); \
+static uintptr_t my_GdkInputFunction_fct_##A = 0; \
+static void my_GdkInputFunction_##A(void* data, int source, int cond) \
+{ \
+ RunFunctionFmt(my_GdkInputFunction_fct_##A, "pii", data, source, cond); \
}
SUPER()
#undef GO
@@ -588,10 +588,10 @@ static void* findGdkInputFunctionFct(void* fct)
// GtkCallbackMarshal
#define GO(A) \
-static uintptr_t my_GtkCallbackMarshal_fct_##A = 0; \
-static void my_GtkCallbackMarshal_##A(void* obj, void* data, uint32_t n, void* args)\
-{ \
- RunFunction(my_context, my_GtkCallbackMarshal_fct_##A, 4, obj, data, n, args); \
+static uintptr_t my_GtkCallbackMarshal_fct_##A = 0; \
+static void my_GtkCallbackMarshal_##A(void* obj, void* data, uint32_t n, void* args) \
+{ \
+ RunFunctionFmt(my_GtkCallbackMarshal_fct_##A, "ppup", obj, data, n, args); \
}
SUPER()
#undef GO
@@ -608,13 +608,79 @@ static void* findGtkCallbackMarshalFct(void* fct)
printf_log(LOG_NONE, "Warning, no more slot for gtk-2 GtkCallbackMarshal callback\n");
return NULL;
}
+// GtkPrinterFunc ...
+#define GO(A) \
+static uintptr_t my_GtkPrinterFunc_fct_##A = 0; \
+static int my_GtkPrinterFunc_##A(void* a, void* b) \
+{ \
+ return (int)RunFunctionFmt(my_GtkPrinterFunc_fct_##A, "pp", a, b); \
+}
+SUPER()
+#undef GO
+static void* find_GtkPrinterFunc_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_GtkPrinterFunc_fct_##A == (uintptr_t)fct) return my_GtkPrinterFunc_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_GtkPrinterFunc_fct_##A == 0) {my_GtkPrinterFunc_fct_##A = (uintptr_t)fct; return my_GtkPrinterFunc_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for gtk-2 GtkPrinterFunc callback\n");
+ return NULL;
+}
+// GtkFileFilterFunc ...
+#define GO(A) \
+static uintptr_t my_GtkFileFilterFunc_fct_##A = 0; \
+static int my_GtkFileFilterFunc_##A(void* a, void* b) \
+{ \
+ return (int)RunFunctionFmt(my_GtkFileFilterFunc_fct_##A, "pp", a, b); \
+}
+SUPER()
+#undef GO
+static void* find_GtkFileFilterFunc_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_GtkFileFilterFunc_fct_##A == (uintptr_t)fct) return my_GtkFileFilterFunc_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_GtkFileFilterFunc_fct_##A == 0) {my_GtkFileFilterFunc_fct_##A = (uintptr_t)fct; return my_GtkFileFilterFunc_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for gtk-2 GtkFileFilterFunc callback\n");
+ return NULL;
+}
+// GtkPrintJobCompleteFunc ...
+#define GO(A) \
+static uintptr_t my_GtkPrintJobCompleteFunc_fct_##A = 0; \
+static void my_GtkPrintJobCompleteFunc_##A(void* a, void* b, void* c) \
+{ \
+ RunFunctionFmt(my_GtkPrintJobCompleteFunc_fct_##A, "ppp", a, b, c); \
+}
+SUPER()
+#undef GO
+static void* find_GtkPrintJobCompleteFunc_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_GtkPrintJobCompleteFunc_fct_##A == (uintptr_t)fct) return my_GtkPrintJobCompleteFunc_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_GtkPrintJobCompleteFunc_fct_##A == 0) {my_GtkPrintJobCompleteFunc_fct_##A = (uintptr_t)fct; return my_GtkPrintJobCompleteFunc_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for gtk-2 GtkPrintJobCompleteFunc callback\n");
+ return NULL;
+}
// GtkLinkButtonUri ...
#define GO(A) \
-static uintptr_t my_GtkLinkButtonUri_fct_##A = 0; \
-static void my_GtkLinkButtonUri_##A(void* a, void* b, void* c) \
-{ \
- RunFunction(my_context, my_GtkLinkButtonUri_fct_##A, 3, a, b, c); \
+static uintptr_t my_GtkLinkButtonUri_fct_##A = 0; \
+static void my_GtkLinkButtonUri_##A(void* a, void* b, void* c) \
+{ \
+ RunFunctionFmt(my_GtkLinkButtonUri_fct_##A, "ppp", a, b, c); \
}
SUPER()
#undef GO
@@ -767,7 +833,7 @@ EXPORT int my_gtk_clipboard_set_with_owner(x64emu_t* emu, void* clipboard, void*
static void* my_translate_func(void* path, my_signal_t* sig)
{
- return (void*)RunFunction(my_context, sig->c_handler, 2, path, sig->data);
+ return (void*)RunFunctionFmt(sig->c_handler, "pp", path, sig->data) ;
}
EXPORT void my_gtk_stock_set_translate_func(x64emu_t* emu, void* domain, void* f, void* data, void* notify)
@@ -964,7 +1030,7 @@ static void my_gtk_builder_connect_signals_custom(void* builder,
uintptr_t offs = 0;
uintptr_t end = 0;
- GetGlobalSymbolStartEnd(my_context->maplib, handler_name, &offs, &end, NULL, -1, NULL);
+ GetGlobalSymbolStartEnd(my_context->maplib, handler_name, &offs, &end, NULL, -1, NULL, NULL, NULL);
if(!offs) {
if (args->module == NULL)
args->my->g_log("Gtk", 1<<2 ,"gtk_builder_connect_signals() requires working GModule");
@@ -1100,6 +1166,24 @@ EXPORT void* my_gtk_link_button_set_uri_hook(x64emu_t* emu, void* f, void* data,
return reverse_GtkLinkButtonUri_Fct(ret);
}
+EXPORT void my_gtk_enumerate_printers(x64emu_t* emu, void* f, void* data, void* d, int wait)
+{
+ (void)emu;
+ my->gtk_enumerate_printers(find_GtkPrinterFunc_Fct(f), data, findGDestroyNotifyFct(d), wait);
+}
+
+EXPORT void my_gtk_file_filter_add_custom(x64emu_t* emu, void* filter, uint32_t needed, void* f, void* data, void* d)
+{
+ (void)emu;
+ my->gtk_file_filter_add_custom(filter, needed, find_GtkFileFilterFunc_Fct(f), data, findGDestroyNotifyFct(d));
+}
+
+EXPORT void my_gtk_print_job_send(x64emu_t* emu, void* job, void* f, void* data, void* d)
+{
+ (void)emu;
+ my->gtk_print_job_send(job, find_GtkPrintJobCompleteFunc_Fct(f), data, findGDestroyNotifyFct(d));
+}
+
#define PRE_INIT \
if(box64_nogtk) \
return -1;
diff --git a/src/wrapped/wrappedgtkx112_private.h b/src/wrapped/wrappedgtkx112_private.h
index ac0bf44..ea9c9df 100755..100644
--- a/src/wrapped/wrappedgtkx112_private.h
+++ b/src/wrapped/wrappedgtkx112_private.h
@@ -2,14 +2,14 @@
#error meh!
#endif
-//GO(gtk_about_dialog_get_artists,
+GO(gtk_about_dialog_get_artists, pFp)
//GO(gtk_about_dialog_get_authors,
//GO(gtk_about_dialog_get_comments,
//GO(gtk_about_dialog_get_copyright,
//GO(gtk_about_dialog_get_documenters,
//GO(gtk_about_dialog_get_license,
-//GO(gtk_about_dialog_get_logo,
-//GO(gtk_about_dialog_get_logo_icon_name,
+GO(gtk_about_dialog_get_logo, pFp)
+GO(gtk_about_dialog_get_logo_icon_name, pFp)
//GO(gtk_about_dialog_get_name,
//GO(gtk_about_dialog_get_program_name,
//GO(gtk_about_dialog_get_translator_credits,
@@ -17,17 +17,17 @@ GO(gtk_about_dialog_get_type, LFv)
//GO(gtk_about_dialog_get_version,
//GO(gtk_about_dialog_get_website,
//GO(gtk_about_dialog_get_website_label,
-//GO(gtk_about_dialog_get_wrap_license,
-//GO(gtk_about_dialog_new,
-//GO(gtk_about_dialog_set_artists,
+GO(gtk_about_dialog_get_wrap_license, iFp)
+GO(gtk_about_dialog_new, pFv)
+GO(gtk_about_dialog_set_artists, vFpp)
//GO(gtk_about_dialog_set_authors,
//GO(gtk_about_dialog_set_comments,
//GO(gtk_about_dialog_set_copyright,
//GO(gtk_about_dialog_set_documenters,
//GO(gtk_about_dialog_set_email_hook,
//GO(gtk_about_dialog_set_license,
-//GO(gtk_about_dialog_set_logo,
-//GO(gtk_about_dialog_set_logo_icon_name,
+GO(gtk_about_dialog_set_logo, vFpp)
+GO(gtk_about_dialog_set_logo_icon_name, vFpp)
//GO(gtk_about_dialog_set_name,
//GO(gtk_about_dialog_set_program_name,
//GO(gtk_about_dialog_set_translator_credits,
@@ -35,13 +35,13 @@ GO(gtk_about_dialog_get_type, LFv)
//GO(gtk_about_dialog_set_version,
//GO(gtk_about_dialog_set_website,
//GO(gtk_about_dialog_set_website_label,
-//GO(gtk_about_dialog_set_wrap_license,
+GO(gtk_about_dialog_set_wrap_license, vFpi)
GO(gtk_accelerator_get_default_mod_mask, uFv)
-GO(gtk_accelerator_get_label, pFui)
+GO(gtk_accelerator_get_label, pFuu)
GO(gtk_accelerator_name, pFui)
GO(gtk_accelerator_parse, vFppp)
GO(gtk_accelerator_set_default_mod_mask, vFu)
-GO(gtk_accelerator_valid, iFui)
+GO(gtk_accelerator_valid, iFuu)
GO(gtk_accel_flags_get_type, LFv)
GO(gtk_accel_group_activate, iFpppui)
GO(gtk_accel_group_connect, vFpuiip) // Closure probably needs wrapping when not null
@@ -56,7 +56,7 @@ GO(gtk_accel_group_get_type, LFv)
GO(gtk_accel_group_lock, vFp)
GO(gtk_accel_group_new, pFv)
GO(gtk_accel_group_query, pFpuip)
-GO(gtk_accel_groups_activate, iFpui)
+GO(gtk_accel_groups_activate, iFpuu)
GO(gtk_accel_groups_from_object, pFp)
GO(gtk_accel_group_unlock, vFp)
//GO(gtk_accel_label_get_accel_widget,
@@ -66,31 +66,31 @@ GO(gtk_accel_label_get_type, LFv)
//GO(gtk_accel_label_refetch,
//GO(gtk_accel_label_set_accel_closure,
//GO(gtk_accel_label_set_accel_widget,
-//GO(gtk_accel_map_add_entry,
-//GO(gtk_accel_map_add_filter,
-//GO(gtk_accel_map_change_entry,
+GO(gtk_accel_map_add_entry, vFpuu)
+GO(gtk_accel_map_add_filter, vFp)
+GO(gtk_accel_map_change_entry, iFpuui)
//GO(gtk_accel_map_foreach,
//GO(gtk_accel_map_foreach_unfiltered,
-//GO(gtk_accel_map_get,
+GO(gtk_accel_map_get, pFv)
GO(gtk_accel_map_get_type, LFv)
//GO(gtk_accel_map_load,
//GO(gtk_accel_map_load_fd,
//GO(gtk_accel_map_load_scanner,
//GO(gtk_accel_map_lock_path,
-//GO(gtk_accel_map_lookup_entry,
+GO(gtk_accel_map_lookup_entry, iFpp)
//GO(gtk_accel_map_save,
//GO(gtk_accel_map_save_fd,
//GO(gtk_accel_map_unlock_path,
-//GO(gtk_accessible_connect_widget_destroyed,
+GO(gtk_accessible_connect_widget_destroyed, vFp)
GO(gtk_accessible_get_type, LFv)
-//GO(gtk_accessible_get_widget,
-//GO(gtk_accessible_set_widget,
+GO(gtk_accessible_get_widget, pFp)
+GO(gtk_accessible_set_widget, vFpp)
GO(gtk_action_activate, vFp)
GO(gtk_action_block_activate, vFp)
GO(gtk_action_block_activate_from, vFpp)
GO(gtk_action_connect_accelerator, vFp)
GO(gtk_action_connect_proxy, vFpp)
-GO(gtk_action_create_icon, pFpi)
+GO(gtk_action_create_icon, pFpu)
GO(gtk_action_create_menu, pFp)
GO(gtk_action_create_menu_item, pFp)
GO(gtk_action_create_tool_item, pFp)
@@ -153,12 +153,12 @@ GO(gtk_action_set_visible_horizontal, vFpi)
GO(gtk_action_set_visible_vertical, vFpi)
GO(gtk_action_unblock_activate, vFp)
GO(gtk_action_unblock_activate_from, vFpp)
-//GO(gtk_activatable_do_set_related_action,
-//GO(gtk_activatable_get_related_action,
+GO(gtk_activatable_do_set_related_action, vFpp)
+GO(gtk_activatable_get_related_action, pFp)
GO(gtk_activatable_get_type, LFv)
-//GO(gtk_activatable_get_use_action_appearance,
+GO(gtk_activatable_get_use_action_appearance, iFp)
//GO(gtk_activatable_set_related_action,
-//GO(gtk_activatable_set_use_action_appearance,
+GO(gtk_activatable_set_use_action_appearance, vFpi)
//GO(gtk_activatable_sync_action_properties,
GO(gtk_adjustment_changed, vFp)
GO(gtk_adjustment_clamp_page, vFpdd)
@@ -187,49 +187,49 @@ GO(gtk_alternative_dialog_button_order, iFp)
GO(gtk_anchor_type_get_type, LFv)
GO(gtk_arg_flags_get_type, LFv)
GO(gtk_arrow_get_type, LFv)
-GO(gtk_arrow_new, pFii)
+GO(gtk_arrow_new, pFuu)
GO(gtk_arrow_placement_get_type, LFv)
-GO(gtk_arrow_set, vFpii)
+GO(gtk_arrow_set, vFpuu)
GO(gtk_arrow_type_get_type, LFv)
GO(gtk_aspect_frame_get_type, LFv)
-//GO(gtk_aspect_frame_new,
-//GO(gtk_aspect_frame_set,
+GO(gtk_aspect_frame_new, pFpfffi)
+GO(gtk_aspect_frame_set, vFpfffi)
//GO(gtk_assistant_add_action_widget,
-//GO(gtk_assistant_append_page,
-//GO(gtk_assistant_commit,
+GO(gtk_assistant_append_page, iFpp)
+GO(gtk_assistant_commit, vFp)
//GO(gtk_assistant_get_current_page,
-//GO(gtk_assistant_get_n_pages,
-//GO(gtk_assistant_get_nth_page,
-//GO(gtk_assistant_get_page_complete,
+GO(gtk_assistant_get_n_pages, iFp)
+GO(gtk_assistant_get_nth_page, pFpi)
+GO(gtk_assistant_get_page_complete, iFpp)
//GO(gtk_assistant_get_page_header_image,
-//GO(gtk_assistant_get_page_side_image,
-//GO(gtk_assistant_get_page_title,
-//GO(gtk_assistant_get_page_type,
+GO(gtk_assistant_get_page_side_image, pFpp)
+GO(gtk_assistant_get_page_title, pFpp)
+GO(gtk_assistant_get_page_type, uFpp)
GO(gtk_assistant_get_type, LFv)
-//GO(gtk_assistant_insert_page,
+GO(gtk_assistant_insert_page, iFppi)
//GO(gtk_assistant_new,
GO(gtk_assistant_page_type_get_type, LFv)
//GO(gtk_assistant_prepend_page,
-//GO(gtk_assistant_remove_action_widget,
-//GO(gtk_assistant_set_current_page,
+GO(gtk_assistant_remove_action_widget, vFpp)
+GO(gtk_assistant_set_current_page, vFpi)
//GO(gtk_assistant_set_forward_page_func,
-//GO(gtk_assistant_set_page_complete,
+GO(gtk_assistant_set_page_complete, vFppi)
//GO(gtk_assistant_set_page_header_image,
-//GO(gtk_assistant_set_page_side_image,
-//GO(gtk_assistant_set_page_title,
-//GO(gtk_assistant_set_page_type,
+GO(gtk_assistant_set_page_side_image, vFppp)
+GO(gtk_assistant_set_page_title, vFppp)
+GO(gtk_assistant_set_page_type, vFppu)
//GO(gtk_assistant_update_buttons_state,
GO(gtk_attach_options_get_type, LFv)
GOM(gtk_binding_entry_add_signal, vFEpuipuV) //vaarg
GO(gtk_binding_entry_add_signall, vFpuipp)
GO(gtk_binding_entry_clear, vFpui)
-GO(gtk_binding_entry_remove, vFpui)
+GO(gtk_binding_entry_remove, vFpuu)
GO(gtk_binding_entry_skip, vFpui)
GO(gtk_binding_parse_binding, uFp)
-GO(gtk_bindings_activate, iFpui)
+GO(gtk_bindings_activate, iFpuu)
GO(gtk_bindings_activate_event, iFpp)
-GO(gtk_binding_set_activate, iFpuip)
-GO(gtk_binding_set_add_path, vFpipi)
+GO(gtk_binding_set_activate, iFpuup)
+GO(gtk_binding_set_add_path, vFpupu)
GO(gtk_binding_set_by_class, pFp)
GO(gtk_binding_set_find, pFp)
GO(gtk_binding_set_new, pFp)
@@ -248,7 +248,7 @@ GO(gtk_box_pack_start, vFppiiu)
GO(gtk_box_pack_start_defaults, vFpp)
GO(gtk_box_query_child_packing, vFpppppp)
GO(gtk_box_reorder_child, vFppi)
-GO(gtk_box_set_child_packing, vFppiiui)
+GO(gtk_box_set_child_packing, vFppiiuu)
GO(gtk_box_set_homogeneous, vFpi)
GO(gtk_box_set_spacing, vFpi)
GO(gtk_buildable_add_child, vFpppp)
@@ -263,7 +263,7 @@ GO(gtk_buildable_parser_finished, vFpp)
GO(gtk_buildable_set_buildable_property, vFpppp)
GO(gtk_buildable_set_name, vFpp)
GO(gtk_builder_add_from_file, uFppp)
-GO(gtk_builder_add_from_string, iFppLp)
+GO(gtk_builder_add_from_string, uFppLp)
GO(gtk_builder_add_objects_from_file, uFpppp)
GO(gtk_builder_add_objects_from_string, uFppLpp)
GOM(gtk_builder_connect_signals, vFEpp)
@@ -274,21 +274,21 @@ GO(gtk_builder_get_object, pFpp)
GO(gtk_builder_get_objects, pFp)
GO(gtk_builder_get_translation_domain, pFp)
GO(gtk_builder_get_type, LFv)
-GO(gtk_builder_get_type_from_name, iFpp)
+GO(gtk_builder_get_type_from_name, LFpp)
GO(gtk_builder_new, pFv)
GO(gtk_builder_set_translation_domain, vFpp)
GO(gtk_builder_value_from_string, iFppppp)
-GO(gtk_builder_value_from_string_type, iFpippp)
+GO(gtk_builder_value_from_string_type, iFpLppp)
GO(gtk_button_action_get_type, LFv)
GO(gtk_button_box_get_child_ipadding, vFppp)
GO(gtk_button_box_get_child_secondary, iFpp)
GO(gtk_button_box_get_child_size, vFppp)
-GO(gtk_button_box_get_layout, iFp)
+GO(gtk_button_box_get_layout, uFp)
GO(gtk_button_box_get_type, LFv)
GO(gtk_button_box_set_child_ipadding, vFpii)
GO(gtk_button_box_set_child_secondary, vFppi)
GO(gtk_button_box_set_child_size, vFpii)
-GO(gtk_button_box_set_layout, vFpi)
+GO(gtk_button_box_set_layout, vFpu)
GO(gtk_button_box_style_get_type, LFv)
GO(gtk_button_clicked, vFp)
GO(gtk_button_enter, vFp)
@@ -296,9 +296,9 @@ GO(gtk_button_get_alignment, vFppp)
GO(gtk_button_get_event_window, pFp)
GO(gtk_button_get_focus_on_click, iFp)
GO(gtk_button_get_image, pFp)
-GO(gtk_button_get_image_position, iFp)
+GO(gtk_button_get_image_position, uFp)
GO(gtk_button_get_label, pFp)
-GO(gtk_button_get_relief, iFp)
+GO(gtk_button_get_relief, uFp)
GO(gtk_button_get_type, LFv)
GO(gtk_button_get_use_stock, iFp)
GO(gtk_button_get_use_underline, iFp)
@@ -312,9 +312,9 @@ GO(gtk_button_released, vFp)
GO(gtk_button_set_alignment, vFpff)
GO(gtk_button_set_focus_on_click, vFpi)
GO(gtk_button_set_image, vFpp)
-GO(gtk_button_set_image_position, vFpi)
+GO(gtk_button_set_image_position, vFpu)
GO(gtk_button_set_label, vFpp)
-GO(gtk_button_set_relief, vFpi)
+GO(gtk_button_set_relief, vFpu)
GO(gtk_button_set_use_stock, vFpi)
GO(gtk_button_set_use_underline, vFpi)
GO(gtk_buttons_type_get_type, LFv)
@@ -339,8 +339,8 @@ GO(gtk_calendar_get_type, LFv)
//GO(gtk_calendar_unmark_day,
//GO(gtk_cell_editable_editing_done,
GO(gtk_cell_editable_get_type, LFv)
-//GO(gtk_cell_editable_remove_widget,
-//GO(gtk_cell_editable_start_editing,
+GO(gtk_cell_editable_remove_widget, vFp)
+GO(gtk_cell_editable_start_editing, vFpp)
GO(gtk_cell_layout_add_attribute, vFpppi)
GO(gtk_cell_layout_clear, vFp)
GO(gtk_cell_layout_clear_attributes, vFpp)
@@ -354,7 +354,7 @@ GOM(gtk_cell_layout_set_cell_data_func, vFEppppp)
GO(gtk_cell_renderer_accel_get_type, LFv)
GO(gtk_cell_renderer_accel_mode_get_type, LFv)
GO(gtk_cell_renderer_accel_new, pFv)
-GO(gtk_cell_renderer_activate, iFppppppi)
+GO(gtk_cell_renderer_activate, iFppppppu)
GO(gtk_cell_renderer_combo_get_type, LFv)
GO(gtk_cell_renderer_combo_new, pFv)
GO(gtk_cell_renderer_editing_canceled, vFp)
@@ -370,7 +370,7 @@ GO(gtk_cell_renderer_pixbuf_get_type, LFv)
GO(gtk_cell_renderer_pixbuf_new, pFv)
GO(gtk_cell_renderer_progress_get_type, LFv)
GO(gtk_cell_renderer_progress_new, pFv)
-GO(gtk_cell_renderer_render, vFppppppi)
+GO(gtk_cell_renderer_render, vFppppppu)
GO(gtk_cell_renderer_set_alignment, vFpff)
GO(gtk_cell_renderer_set_fixed_size, vFpii)
GO(gtk_cell_renderer_set_padding, vFpii)
@@ -380,7 +380,7 @@ GO(gtk_cell_renderer_spin_get_type, LFv)
GO(gtk_cell_renderer_spinner_get_type, LFv)
GO(gtk_cell_renderer_spinner_new, pFv)
GO(gtk_cell_renderer_spin_new, pFv)
-GO(gtk_cell_renderer_start_editing, pFppppppi)
+GO(gtk_cell_renderer_start_editing, pFppppppu)
GO(gtk_cell_renderer_state_get_type, LFv)
GO(gtk_cell_renderer_stop_editing, vFpi)
GO(gtk_cell_renderer_text_get_type, LFv)
@@ -395,18 +395,18 @@ GO(gtk_cell_renderer_toggle_set_activatable, vFpi)
GO(gtk_cell_renderer_toggle_set_active, vFpi)
GO(gtk_cell_renderer_toggle_set_radio, vFpi)
GO(gtk_cell_type_get_type, LFv)
-//GO(gtk_cell_view_get_cell_renderers,
-//GO(gtk_cell_view_get_displayed_row,
-//GO(gtk_cell_view_get_model,
-//GO(gtk_cell_view_get_size_of_row,
+GO(gtk_cell_view_get_cell_renderers, pFp)
+GO(gtk_cell_view_get_displayed_row, pFp)
+GO(gtk_cell_view_get_model, pFp)
+GO(gtk_cell_view_get_size_of_row, iFppp)
GO(gtk_cell_view_get_type, LFv)
//GO(gtk_cell_view_new,
//GO(gtk_cell_view_new_with_markup,
-//GO(gtk_cell_view_new_with_pixbuf,
+GO(gtk_cell_view_new_with_pixbuf, pFp)
//GO(gtk_cell_view_new_with_text,
-//GO(gtk_cell_view_set_background_color,
-//GO(gtk_cell_view_set_displayed_row,
-//GO(gtk_cell_view_set_model,
+GO(gtk_cell_view_set_background_color, vFpp)
+GO(gtk_cell_view_set_displayed_row, vFpp)
+GO(gtk_cell_view_set_model, vFpp)
GO(gtk_check_button_get_type, LFv)
GO(gtk_check_button_new, pFv)
GO(gtk_check_button_new_with_label, pFp)
@@ -436,7 +436,7 @@ GOM(gtk_clipboard_request_contents, vFEpppp)
//GOM(gtk_clipboard_request_targets, vFEppp)
GOM(gtk_clipboard_request_text, vFEppp)
//GOM(gtk_clipboard_request_uris, vFEppp)
-GO(gtk_clipboard_set_can_store, vFppp)
+GO(gtk_clipboard_set_can_store, vFppi)
GO(gtk_clipboard_set_image, vFpp)
GO(gtk_clipboard_set_text, vFppi)
GOM(gtk_clipboard_set_with_data, iFEppuppp)
@@ -563,7 +563,7 @@ GO(gtk_color_selection_set_has_opacity_control, vFpi)
GO(gtk_color_selection_set_has_palette, vFpi)
GO(gtk_color_selection_set_previous_alpha, vFpW)
GO(gtk_color_selection_set_previous_color, vFpp)
-GO(gtk_color_selection_set_update_policy, vFpi)
+GO(gtk_color_selection_set_update_policy, vFpu)
GO(gtk_combo_box_append_text, vFpp)
GO(gtk_combo_box_entry_get_text_column, iFp)
GO(gtk_combo_box_entry_get_type, LFv)
@@ -575,7 +575,7 @@ GO(gtk_combo_box_get_active, iFp)
GO(gtk_combo_box_get_active_iter, iFpp)
GO(gtk_combo_box_get_active_text, pFp)
GO(gtk_combo_box_get_add_tearoffs, iFp)
-GO(gtk_combo_box_get_button_sensitivity, iFp)
+GO(gtk_combo_box_get_button_sensitivity, uFp)
GO(gtk_combo_box_get_column_span_column, iFp)
GO(gtk_combo_box_get_entry_text_column, iFp)
GO(gtk_combo_box_get_focus_on_click, iFp)
@@ -600,7 +600,7 @@ GO(gtk_combo_box_remove_text, vFpi)
GO(gtk_combo_box_set_active, vFpi)
GO(gtk_combo_box_set_active_iter, vFpp)
GO(gtk_combo_box_set_add_tearoffs, vFpi)
-GO(gtk_combo_box_set_button_sensitivity, vFpi)
+GO(gtk_combo_box_set_button_sensitivity, vFpu)
GO(gtk_combo_box_set_column_span_column, vFpi)
GO(gtk_combo_box_set_entry_text_column, vFpi)
GO(gtk_combo_box_set_focus_on_click, vFpi)
@@ -610,13 +610,13 @@ GO(gtk_combo_box_set_row_span_column, vFpi)
GO(gtk_combo_box_set_title, vFpp)
GO(gtk_combo_box_set_wrap_width, vFpi)
//GO(gtk_combo_box_text_append_text,
-//GO(gtk_combo_box_text_get_active_text,
+GO(gtk_combo_box_text_get_active_text, pFp)
GO(gtk_combo_box_text_get_type, LFv)
-//GO(gtk_combo_box_text_insert_text,
+GO(gtk_combo_box_text_insert_text, vFpip)
//GO(gtk_combo_box_text_new,
//GO(gtk_combo_box_text_new_with_entry,
-//GO(gtk_combo_box_text_prepend_text,
-//GO(gtk_combo_box_text_remove,
+GO(gtk_combo_box_text_prepend_text, vFpp)
+GO(gtk_combo_box_text_remove, vFpi)
GO(gtk_combo_disable_activate, vFp)
GO(gtk_combo_get_type, LFv)
GO(gtk_combo_new, pFv)
@@ -635,7 +635,7 @@ GO(gtk_container_child_get_property, vFpppp)
//GO2(gtk_container_child_set, vFpppV, gtk_container_child_set_valist)
GO(gtk_container_child_set_property, vFpppp)
//GO(gtk_container_child_set_valist, vFpppA)
-GO(gtk_container_child_type, iFp)
+GO(gtk_container_child_type, LFp)
GO(gtk_container_class_find_child_property, pFpp)
GO(gtk_container_class_install_child_property, vFpup)
GO(gtk_container_class_list_child_properties, pFpp)
@@ -648,7 +648,7 @@ GO(gtk_container_get_focus_chain, iFpp)
GO(gtk_container_get_focus_child, pFp)
GO(gtk_container_get_focus_hadjustment, pFp)
GO(gtk_container_get_focus_vadjustment, pFp)
-GO(gtk_container_get_resize_mode, iFp)
+GO(gtk_container_get_resize_mode, uFp)
GO(gtk_container_get_type, LFv)
GO(gtk_container_propagate_expose, vFppp)
GO(gtk_container_remove, vFpp)
@@ -658,8 +658,8 @@ GO(gtk_container_set_focus_chain, vFpp)
GO(gtk_container_set_focus_child, vFpp)
GO(gtk_container_set_focus_hadjustment, vFpp)
GO(gtk_container_set_focus_vadjustment, vFpp)
-GO(gtk_container_set_reallocate_redraws, vFpp)
-GO(gtk_container_set_resize_mode, vFpi)
+GO(gtk_container_set_reallocate_redraws, vFpi)
+GO(gtk_container_set_resize_mode, vFpu)
GO(gtk_container_unset_focus_chain, vFp)
GO(gtk_corner_type_get_type, LFv)
//GO(gtk_ctree_collapse,
@@ -687,8 +687,8 @@ GO(gtk_ctree_get_type, LFv)
//GO(gtk_ctree_last,
GO(gtk_ctree_line_style_get_type, LFv)
//GO(gtk_ctree_move,
-//GO(gtk_ctree_new,
-//GO(gtk_ctree_new_with_titles,
+GO(gtk_ctree_new, pFii)
+GO(gtk_ctree_new_with_titles, pFiip)
//GO(gtk_ctree_node_get_cell_style,
//GO(gtk_ctree_node_get_cell_type,
//GO(gtk_ctree_node_get_pixmap,
@@ -738,7 +738,7 @@ GO(gtk_curve_get_type, LFv)
GO(gtk_curve_get_vector, vFpip)
GO(gtk_curve_new, pFv)
GO(gtk_curve_reset, vFp)
-GO(gtk_curve_set_curve_type, vFpi)
+GO(gtk_curve_set_curve_type, vFpu)
GO(gtk_curve_set_gamma, vFpf)
GO(gtk_curve_set_range, vFpffff)
GO(gtk_curve_set_vector, vFpip)
@@ -772,7 +772,7 @@ GO(gtk_dialog_set_has_separator, vFpi)
GO(gtk_dialog_set_response_sensitive, vFpii)
GO(gtk_direction_type_get_type, LFv)
GO(gtk_disable_setlocale, vFv)
-GO(gtk_drag_begin, pFppiip)
+GO(gtk_drag_begin, pFppuip)
GO(gtk_drag_check_threshold, iFpiiii)
GO(gtk_drag_dest_add_image_targets, vFp)
GO(gtk_drag_dest_add_text_targets, vFp)
@@ -780,8 +780,8 @@ GO(gtk_drag_dest_add_uri_targets, vFp)
GO(gtk_drag_dest_find_target, pFppp)
GO(gtk_drag_dest_get_target_list, pFp)
GO(gtk_drag_dest_get_track_motion, iFp)
-GO(gtk_drag_dest_set, vFpipii)
-GO(gtk_drag_dest_set_proxy, vFppii)
+GO(gtk_drag_dest_set, vFpupiu)
+GO(gtk_drag_dest_set_proxy, vFppui)
GO(gtk_drag_dest_set_target_list, vFpp)
GO(gtk_drag_dest_set_track_motion, vFpi)
GO(gtk_drag_dest_unset, vFp)
@@ -801,7 +801,7 @@ GO(gtk_drag_source_add_image_targets, vFp)
GO(gtk_drag_source_add_text_targets, vFp)
GO(gtk_drag_source_add_uri_targets, vFp)
GO(gtk_drag_source_get_target_list, pFp)
-GO(gtk_drag_source_set, vFpipii)
+GO(gtk_drag_source_set, vFpupiu)
GO(gtk_drag_source_set_icon, vFpppp)
GO(gtk_drag_source_set_icon_name, vFpp)
GO(gtk_drag_source_set_icon_pixbuf, vFpp)
@@ -809,31 +809,31 @@ GO(gtk_drag_source_set_icon_stock, vFpp)
GO(gtk_drag_source_set_target_list, vFpp)
GO(gtk_drag_source_unset, vFp)
GO(gtk_drag_unhighlight, vFp)
-GO(gtk_draw_arrow, vFppiiiiiiii)
+GO(gtk_draw_arrow, vFppuuuiiiii)
GO(gtk_draw_box, vFppiiiiii)
-GO(gtk_draw_box_gap, vFppiiiiiiiii)
+GO(gtk_draw_box_gap, vFppuuiiiiuii)
GO(gtk_draw_check, vFppiiiiii)
GO(gtk_draw_diamond, vFppiiiiii)
-GO(gtk_draw_expander, vFppiiii)
-GO(gtk_draw_extension, vFppiiiiiii)
+GO(gtk_draw_expander, vFppuiiu)
+GO(gtk_draw_extension, vFppuuiiiiu)
GO(gtk_draw_flat_box, vFppiiiiii)
GO(gtk_draw_focus, vFppiiii)
-GO(gtk_draw_handle, vFppiiiiiii)
+GO(gtk_draw_handle, vFppuuiiiiu)
GO(gtk_draw_hline, vFppiiii)
GO(gtk_drawing_area_get_type, LFv)
GO(gtk_drawing_area_new, pFv)
GO(gtk_drawing_area_size, vFpii)
-GO(gtk_draw_insertion_cursor, vFppppiii)
-GO(gtk_draw_layout, vFppiiiip)
+GO(gtk_draw_insertion_cursor, vFppppiui)
+GO(gtk_draw_layout, vFppuiiip)
GO(gtk_draw_option, vFppiiiiii)
-GO(gtk_draw_polygon, vFppiipii)
-GO(gtk_draw_resize_grip, vFppiiiiii)
+GO(gtk_draw_polygon, vFppuupii)
+GO(gtk_draw_resize_grip, vFppuuiiii)
GO(gtk_draw_shadow, vFppiiiiii)
GO(gtk_draw_shadow_gap, vFppiiiiiiiii)
GO(gtk_draw_slider, vFppiiiiiii)
-GO(gtk_draw_string, vFppiiip)
-GO(gtk_draw_tab, vFppiiiiii)
-GO(gtk_draw_vline, vFppiiii)
+GO(gtk_draw_string, vFppuiip)
+GO(gtk_draw_tab, vFppuuiiii)
+GO(gtk_draw_vline, vFppuiii)
GO(gtk_editable_copy_clipboard, vFp)
GO(gtk_editable_cut_clipboard, vFp)
GO(gtk_editable_delete_selection, vFp)
@@ -849,115 +849,115 @@ GO(gtk_editable_select_region, vFpii)
GO(gtk_editable_set_editable, vFpi)
GO(gtk_editable_set_position, vFpi)
GO(gtk_entry_append_text, vFpp)
-//GO(gtk_entry_buffer_delete_text,
-//GO(gtk_entry_buffer_emit_deleted_text,
-//GO(gtk_entry_buffer_emit_inserted_text,
-//GO(gtk_entry_buffer_get_bytes,
-//GO(gtk_entry_buffer_get_length,
-//GO(gtk_entry_buffer_get_max_length,
-//GO(gtk_entry_buffer_get_text,
+GO(gtk_entry_buffer_delete_text, uFpui)
+GO(gtk_entry_buffer_emit_deleted_text, vFpuu)
+GO(gtk_entry_buffer_emit_inserted_text, vFpupu)
+GO(gtk_entry_buffer_get_bytes, LFp)
+GO(gtk_entry_buffer_get_length, uFp)
+GO(gtk_entry_buffer_get_max_length, iFp)
+GO(gtk_entry_buffer_get_text, pFp)
GO(gtk_entry_buffer_get_type, LFv)
-//GO(gtk_entry_buffer_insert_text,
-//GO(gtk_entry_buffer_new,
-//GO(gtk_entry_buffer_set_max_length,
-//GO(gtk_entry_buffer_set_text,
+GO(gtk_entry_buffer_insert_text, uFpupi)
+GO(gtk_entry_buffer_new, pFpi)
+GO(gtk_entry_buffer_set_max_length, vFpi)
+GO(gtk_entry_buffer_set_text, vFppi)
//GO(gtk_entry_completion_complete,
//GO(gtk_entry_completion_delete_action,
-//GO(gtk_entry_completion_get_completion_prefix,
-//GO(gtk_entry_completion_get_entry,
+GO(gtk_entry_completion_get_completion_prefix, pFp)
+GO(gtk_entry_completion_get_entry, pFp)
//GO(gtk_entry_completion_get_inline_completion,
//GO(gtk_entry_completion_get_inline_selection,
//GO(gtk_entry_completion_get_minimum_key_length,
-//GO(gtk_entry_completion_get_model,
+GO(gtk_entry_completion_get_model, pFp)
//GO(gtk_entry_completion_get_popup_completion,
//GO(gtk_entry_completion_get_popup_set_width,
-//GO(gtk_entry_completion_get_popup_single_match,
-//GO(gtk_entry_completion_get_text_column,
+GO(gtk_entry_completion_get_popup_single_match, iFp)
+GO(gtk_entry_completion_get_text_column, iFp)
GO(gtk_entry_completion_get_type, LFv)
-//GO(gtk_entry_completion_insert_action_markup,
+GO(gtk_entry_completion_insert_action_markup, vFpip)
//GO(gtk_entry_completion_insert_action_text,
-//GO(gtk_entry_completion_insert_prefix,
-//GO(gtk_entry_completion_new,
+GO(gtk_entry_completion_insert_prefix, vFp)
+GO(gtk_entry_completion_new, pFv)
//GO(gtk_entry_completion_set_inline_completion,
//GO(gtk_entry_completion_set_inline_selection,
//GO(gtk_entry_completion_set_match_func,
//GO(gtk_entry_completion_set_minimum_key_length,
-//GO(gtk_entry_completion_set_model,
+GO(gtk_entry_completion_set_model, vFpp)
//GO(gtk_entry_completion_set_popup_completion,
//GO(gtk_entry_completion_set_popup_set_width,
-//GO(gtk_entry_completion_set_popup_single_match,
-//GO(gtk_entry_completion_set_text_column,
+GO(gtk_entry_completion_set_popup_single_match, vFpi)
+GO(gtk_entry_completion_set_text_column, vFpi)
GO(gtk_entry_get_activates_default, iFp)
GO(gtk_entry_get_alignment, fFp)
-//GO(gtk_entry_get_buffer,
-//GO(gtk_entry_get_completion,
-//GO(gtk_entry_get_current_icon_drag_source,
-//GO(gtk_entry_get_cursor_hadjustment,
+GO(gtk_entry_get_buffer, pFp)
+GO(gtk_entry_get_completion, pFp)
+GO(gtk_entry_get_current_icon_drag_source, iFp)
+GO(gtk_entry_get_cursor_hadjustment, pFp)
GO(gtk_entry_get_has_frame, iFp)
//GO(gtk_entry_get_icon_activatable,
-//GO(gtk_entry_get_icon_at_pos,
-//GO(gtk_entry_get_icon_gicon,
-//GO(gtk_entry_get_icon_name,
-//GO(gtk_entry_get_icon_pixbuf,
-//GO(gtk_entry_get_icon_sensitive,
+GO(gtk_entry_get_icon_at_pos, iFpii)
+GO(gtk_entry_get_icon_gicon, pFpu)
+GO(gtk_entry_get_icon_name, pFpu)
+GO(gtk_entry_get_icon_pixbuf, pFpu)
+GO(gtk_entry_get_icon_sensitive, iFpu)
//GO(gtk_entry_get_icon_stock,
-//GO(gtk_entry_get_icon_storage_type,
-//GO(gtk_entry_get_icon_tooltip_markup,
+GO(gtk_entry_get_icon_storage_type, uFpu)
+GO(gtk_entry_get_icon_tooltip_markup, pFpu)
//GO(gtk_entry_get_icon_tooltip_text,
-//GO(gtk_entry_get_icon_window,
+GO(gtk_entry_get_icon_window, pFpu)
GO(gtk_entry_get_inner_border, pFp)
-//GO(gtk_entry_get_invisible_char,
+GO(gtk_entry_get_invisible_char, uFp)
GO(gtk_entry_get_layout, pFp)
GO(gtk_entry_get_layout_offsets, vFppp)
//GO(gtk_entry_get_max_length,
GO(gtk_entry_get_overwrite_mode, iFp)
//GO(gtk_entry_get_progress_fraction,
-//GO(gtk_entry_get_progress_pulse_step,
+GO(gtk_entry_get_progress_pulse_step, dFp)
GO(gtk_entry_get_text, pFp)
GO(gtk_entry_get_text_length, WFp)
-//GO(gtk_entry_get_text_window,
+GO(gtk_entry_get_text_window, pFp)
GO(gtk_entry_get_type, LFv)
//GO(gtk_entry_get_visibility,
GO(gtk_entry_get_width_chars, iFp)
GO(gtk_entry_icon_position_get_type, LFv)
-//GO(gtk_entry_im_context_filter_keypress,
+GO(gtk_entry_im_context_filter_keypress, iFpp)
//GO(gtk_entry_layout_index_to_text_index,
GO(gtk_entry_new, pFv)
GO(gtk_entry_new_with_buffer, pFp)
GO(gtk_entry_new_with_max_length, pFi)
GO(gtk_entry_prepend_text, vFpp)
//GO(gtk_entry_progress_pulse,
-//GO(gtk_entry_reset_im_context,
+GO(gtk_entry_reset_im_context, vFp)
GO(gtk_entry_select_region, vFpii)
GO(gtk_entry_set_activates_default, vFpi)
GO(gtk_entry_set_alignment, vFpf)
GO(gtk_entry_set_buffer, vFpp)
-//GO(gtk_entry_set_completion,
-//GO(gtk_entry_set_cursor_hadjustment,
+GO(gtk_entry_set_completion, vFpp)
+GO(gtk_entry_set_cursor_hadjustment, vFpp)
GO(gtk_entry_set_editable, vFpi)
GO(gtk_entry_set_has_frame, vFpi)
//GO(gtk_entry_set_icon_activatable,
-//GO(gtk_entry_set_icon_drag_source,
-//GO(gtk_entry_set_icon_from_gicon,
+GO(gtk_entry_set_icon_drag_source, vFpupu)
+GO(gtk_entry_set_icon_from_gicon, vFpup)
//GO(gtk_entry_set_icon_from_icon_name,
-//GO(gtk_entry_set_icon_from_pixbuf,
+GO(gtk_entry_set_icon_from_pixbuf, vFpup)
//GO(gtk_entry_set_icon_from_stock,
-//GO(gtk_entry_set_icon_sensitive,
-//GO(gtk_entry_set_icon_tooltip_markup,
+GO(gtk_entry_set_icon_sensitive, vFpui)
+GO(gtk_entry_set_icon_tooltip_markup, vFpup)
//GO(gtk_entry_set_icon_tooltip_text,
GO(gtk_entry_set_inner_border, vFpp)
-GO(gtk_entry_set_invisible_char, vFp)
+GO(gtk_entry_set_invisible_char, vFpu)
GO(gtk_entry_set_max_length, vFpi)
GO(gtk_entry_set_overwrite_mode, vFpi)
GO(gtk_entry_set_position, vFpi)
//GO(gtk_entry_set_progress_fraction,
-//GO(gtk_entry_set_progress_pulse_step,
+GO(gtk_entry_set_progress_pulse_step, vFpd)
GO(gtk_entry_set_text, vFpp)
GO(gtk_entry_set_visibility, vFpi)
GO(gtk_entry_set_width_chars, uFp)
-//GO(gtk_entry_text_index_to_layout_index,
+GO(gtk_entry_text_index_to_layout_index, iFpi)
//GO(gtk_entry_unset_invisible_char,
-//GO(gtk_enumerate_printers,
+GOM(gtk_enumerate_printers, vFEpppi)
GO(gtk_event_box_get_above_child, iFp)
GO(gtk_event_box_get_type, LFv)
GO(gtk_event_box_get_visible_window, iFp)
@@ -993,8 +993,8 @@ GO(gtk_file_chooser_button_get_focus_on_click, iFp)
GO(gtk_file_chooser_button_get_title, pFp)
GO(gtk_file_chooser_button_get_type, LFv)
GO(gtk_file_chooser_button_get_width_chars, iFp)
-GO(gtk_file_chooser_button_new, pFpi)
-GO(gtk_file_chooser_button_new_with_backend, pFpip)
+GO(gtk_file_chooser_button_new, pFpu)
+GO(gtk_file_chooser_button_new_with_backend, pFpup)
GO(gtk_file_chooser_button_new_with_dialog, pFp)
GO(gtk_file_chooser_button_set_focus_on_click, vFpi)
GO(gtk_file_chooser_button_set_title, vFpp)
@@ -1005,7 +1005,7 @@ GO(gtk_file_chooser_dialog_new, pFppipipipipipipip) // vaargs (so pFppipV) with
GO(gtk_file_chooser_dialog_new_with_backend, pFppippipipipipipip) // same but pFppippV
GO(gtk_file_chooser_error_get_type, LFv)
GO(gtk_file_chooser_error_quark, pFv)
-GO(gtk_file_chooser_get_action, iFp)
+GO(gtk_file_chooser_get_action, uFp)
GO(gtk_file_chooser_get_create_folders, iFp)
GO(gtk_file_chooser_get_current_folder, pFp)
GO(gtk_file_chooser_get_current_folder_file, pFp)
@@ -1039,7 +1039,7 @@ GO(gtk_file_chooser_select_all, vFp)
GO(gtk_file_chooser_select_file, iFppp)
GO(gtk_file_chooser_select_filename, iFpp)
GO(gtk_file_chooser_select_uri, iFpp)
-GO(gtk_file_chooser_set_action, vFpi)
+GO(gtk_file_chooser_set_action, vFpu)
GO(gtk_file_chooser_set_create_folders, vFpi)
GO(gtk_file_chooser_set_current_folder, iFpp)
GO(gtk_file_chooser_set_current_folder_file, iFppp)
@@ -1062,16 +1062,16 @@ GO(gtk_file_chooser_unselect_file, vFpp)
GO(gtk_file_chooser_unselect_filename, vFpp)
GO(gtk_file_chooser_unselect_uri, vFpp)
GO(gtk_file_chooser_widget_get_type, LFv)
-GO(gtk_file_chooser_widget_new, pFi)
-GO(gtk_file_chooser_widget_new_with_backend, pFip)
-//GOM(gtk_file_filter_add_custom, vFEppppp)
+GO(gtk_file_chooser_widget_new, pFu)
+GO(gtk_file_chooser_widget_new_with_backend, pFup)
+GOM(gtk_file_filter_add_custom, vFEpuppp)
//GO(gtk_file_filter_add_mime_type, vFpp)
GO(gtk_file_filter_add_pattern, vFpp)
GO(gtk_file_filter_add_pixbuf_formats, vFp)
GO(gtk_file_filter_filter, iFpp)
GO(gtk_file_filter_flags_get_type, LFv)
GO(gtk_file_filter_get_name, pFp)
-GO(gtk_file_filter_get_needed, iFp)
+GO(gtk_file_filter_get_needed, uFp)
GO(gtk_file_filter_get_type, LFv)
GO(gtk_file_filter_new, pFv)
GO(gtk_file_filter_set_name, vFpp)
@@ -1115,7 +1115,7 @@ GO(gtk_font_selection_dialog_get_ok_button, pFp)
GO(gtk_font_selection_dialog_get_preview_text, pFp)
GO(gtk_font_selection_dialog_get_type, LFv)
GO(gtk_font_selection_dialog_new, pFp)
-GO(gtk_font_selection_dialog_set_font_name, vFpp)
+GO(gtk_font_selection_dialog_set_font_name, iFpp)
GO(gtk_font_selection_dialog_set_preview_text, vFpp)
GO(gtk_font_selection_get_face, pFp)
GO(gtk_font_selection_get_face_list, pFp)
@@ -1135,13 +1135,13 @@ GO(gtk_font_selection_set_preview_text, vFpp)
GO(gtk_frame_get_label, pFp)
GO(gtk_frame_get_label_align, vFppp)
GO(gtk_frame_get_label_widget, pFp)
-GO(gtk_frame_get_shadow_type, iFp)
+GO(gtk_frame_get_shadow_type, uFp)
GO(gtk_frame_get_type, LFv)
GO(gtk_frame_new, pFp)
GO(gtk_frame_set_label, vFpp)
GO(gtk_frame_set_label_align, vFpff)
GO(gtk_frame_set_label_widget, vFpp)
-GO(gtk_frame_set_shadow_type, vFpi)
+GO(gtk_frame_set_shadow_type, vFpu)
GO(gtk_gamma_curve_get_type, LFv)
GO(gtk_gamma_curve_new, pFv)
GO(gtk_gc_get, pFippu)
@@ -1157,13 +1157,13 @@ GO(gtk_grab_get_current, pFv)
GO(gtk_grab_remove, vFp)
GO(gtk_handle_box_get_child_detached, iFp)
GO(gtk_handle_box_get_handle_position, iFp)
-GO(gtk_handle_box_get_shadow_type, iFp)
-GO(gtk_handle_box_get_snap_edge, iFp)
+GO(gtk_handle_box_get_shadow_type, uFp)
+GO(gtk_handle_box_get_snap_edge, uFp)
GO(gtk_handle_box_get_type, LFv)
GO(gtk_handle_box_new, pFv)
GO(gtk_handle_box_set_handle_position, vFpi)
-GO(gtk_handle_box_set_shadow_type, vFpi)
-GO(gtk_handle_box_set_snap_edge, vFpi)
+GO(gtk_handle_box_set_shadow_type, vFpu)
+GO(gtk_handle_box_set_snap_edge, vFpu)
GO(gtk_hbox_get_type, LFv)
GO(gtk_hbox_new, pFii)
GO(gtk_hbutton_box_get_layout_default, iFv)
@@ -1183,13 +1183,13 @@ GO(gtk_hscrollbar_get_type, LFv)
GO(gtk_hscrollbar_new, pFp)
GO(gtk_hseparator_get_type, LFv)
GO(gtk_hseparator_new, pFv)
-//GO(gtk_hsv_get_color,
-//GO(gtk_hsv_get_metrics,
+GO(gtk_hsv_get_color, vFpppp)
+GO(gtk_hsv_get_metrics, vFppp)
GO(gtk_hsv_get_type, LFv)
-//GO(gtk_hsv_is_adjusting,
+GO(gtk_hsv_is_adjusting, iFp)
//GO(gtk_hsv_new,
-//GO(gtk_hsv_set_color,
-//GO(gtk_hsv_set_metrics,
+GO(gtk_hsv_set_color, vFpddd)
+GO(gtk_hsv_set_metrics, vFpii)
//GO(gtk_hsv_to_rgb,
GO(gtk_icon_factory_add, vFppp)
GO(gtk_icon_factory_add_default, vFp)
@@ -1209,7 +1209,7 @@ GO(gtk_icon_info_get_filename, pFp)
GO(gtk_icon_info_get_type, LFv)
GO(gtk_icon_info_load_icon, pFpp)
GO(gtk_icon_info_new_for_pixbuf, pFpp)
-GO(gtk_icon_info_set_raw_coordinates, vFpp)
+GO(gtk_icon_info_set_raw_coordinates, vFpi)
GO(gtk_icon_lookup_flags_get_type, LFv)
GO(gtk_icon_set_add_source, vFpp)
GO(gtk_icon_set_copy, pFp)
@@ -1218,36 +1218,36 @@ GO(gtk_icon_set_get_type, LFv)
GO(gtk_icon_set_new, pFv)
GO(gtk_icon_set_new_from_pixbuf, pFp)
GO(gtk_icon_set_ref, pFp)
-GO(gtk_icon_set_render_icon, pFppipipp)
+GO(gtk_icon_set_render_icon, pFppuuupp)
GO(gtk_icon_set_unref, vFp)
-GO(gtk_icon_size_from_name, iFp)
-GO(gtk_icon_size_get_name, pFi)
+GO(gtk_icon_size_from_name, uFp)
+GO(gtk_icon_size_get_name, pFu)
GO(gtk_icon_size_get_type, LFv)
-GO(gtk_icon_size_lookup, iFipp)
-GO(gtk_icon_size_lookup_for_settings, iFpipp)
-GO(gtk_icon_size_register, iFpii)
-GO(gtk_icon_size_register_alias, vFpi)
+GO(gtk_icon_size_lookup, iFupp)
+GO(gtk_icon_size_lookup_for_settings, iFpupp)
+GO(gtk_icon_size_register, uFpii)
+GO(gtk_icon_size_register_alias, vFpu)
GO(gtk_icon_source_copy, pFp)
GO(gtk_icon_source_free, vFp)
-GO(gtk_icon_source_get_direction, iFp)
+GO(gtk_icon_source_get_direction, uFp)
GO(gtk_icon_source_get_direction_wildcarded, iFp)
GO(gtk_icon_source_get_filename, pFp)
GO(gtk_icon_source_get_icon_name, pFp)
GO(gtk_icon_source_get_pixbuf, pFp)
-GO(gtk_icon_source_get_size, iFp)
+GO(gtk_icon_source_get_size, uFp)
GO(gtk_icon_source_get_size_wildcarded, iFp)
-GO(gtk_icon_source_get_state, iFp)
+GO(gtk_icon_source_get_state, uFp)
GO(gtk_icon_source_get_state_wildcarded, iFp)
GO(gtk_icon_source_get_type, LFv)
GO(gtk_icon_source_new, pFv)
-GO(gtk_icon_source_set_direction, vFpi)
+GO(gtk_icon_source_set_direction, vFpu)
GO(gtk_icon_source_set_direction_wildcarded, vFpi)
GO(gtk_icon_source_set_filename, vFpp)
GO(gtk_icon_source_set_icon_name, vFpp)
GO(gtk_icon_source_set_pixbuf, vFpp)
-GO(gtk_icon_source_set_size, vFpi)
+GO(gtk_icon_source_set_size, vFpu)
GO(gtk_icon_source_set_size_wildcarded, vFpi)
-GO(gtk_icon_source_set_state, vFpi)
+GO(gtk_icon_source_set_state, vFpu)
GO(gtk_icon_source_set_state_wildcarded, vFpi)
GO(gtk_icon_theme_add_builtin_icon, vFpip)
GO(gtk_icon_theme_append_search_path, vFpp)
@@ -1275,8 +1275,8 @@ GO(gtk_icon_theme_set_search_path, vFppi)
GO(gtk_icon_view_convert_widget_to_bin_window_coords, vFpiipp)
GO(gtk_icon_view_create_drag_icon, pFpp)
GO(gtk_icon_view_drop_position_get_type, LFv)
-GO(gtk_icon_view_enable_model_drag_dest, vFppii)
-GO(gtk_icon_view_enable_model_drag_source, vFpipii)
+GO(gtk_icon_view_enable_model_drag_dest, vFppiu)
+GO(gtk_icon_view_enable_model_drag_source, vFpupiu)
GO(gtk_icon_view_get_columns, iFp)
GO(gtk_icon_view_get_column_spacing, iFp)
GO(gtk_icon_view_get_cursor, iFppp)
@@ -1284,7 +1284,7 @@ GO(gtk_icon_view_get_dest_item_at_pos, iFpiipp)
GO(gtk_icon_view_get_drag_dest_item, vFppp)
GO(gtk_icon_view_get_item_at_pos, iFpiipp)
GO(gtk_icon_view_get_item_column, iFpp)
-GO(gtk_icon_view_get_item_orientation, iFp)
+GO(gtk_icon_view_get_item_orientation, uFp)
GO(gtk_icon_view_get_item_padding, iFp)
GO(gtk_icon_view_get_item_row, iFpp)
GO(gtk_icon_view_get_item_width, iFp)
@@ -1297,7 +1297,7 @@ GO(gtk_icon_view_get_pixbuf_column, iFp)
GO(gtk_icon_view_get_reorderable, iFp)
GO(gtk_icon_view_get_row_spacing, iFp)
GO(gtk_icon_view_get_selected_items, pFp)
-GO(gtk_icon_view_get_selection_mode, iFp)
+GO(gtk_icon_view_get_selection_mode, uFp)
GO(gtk_icon_view_get_spacing, iFp)
GO(gtk_icon_view_get_text_column, iFp)
GO(gtk_icon_view_get_tooltip_column, iFp)
@@ -1315,8 +1315,8 @@ GO(gtk_icon_view_select_path, vFpp)
GO(gtk_icon_view_set_columns, vFpi)
GO(gtk_icon_view_set_column_spacing, vFpi)
GO(gtk_icon_view_set_cursor, vFpppi)
-GO(gtk_icon_view_set_drag_dest_item, vFppi)
-GO(gtk_icon_view_set_item_orientation, vFpi)
+GO(gtk_icon_view_set_drag_dest_item, vFppu)
+GO(gtk_icon_view_set_item_orientation, vFpu)
GO(gtk_icon_view_set_item_padding, vFpi)
GO(gtk_icon_view_set_item_width, vFpi)
GO(gtk_icon_view_set_margin, vFpi)
@@ -1326,7 +1326,7 @@ GO(gtk_icon_view_set_orientation, vFpi)
GO(gtk_icon_view_set_pixbuf_column, vFpi)
GO(gtk_icon_view_set_reorderable, vFpi)
GO(gtk_icon_view_set_row_spacing, vFpi)
-GO(gtk_icon_view_set_selection_mode, vFpi)
+GO(gtk_icon_view_set_selection_mode, vFpu)
GO(gtk_icon_view_set_spacing, vFpi)
GO(gtk_icon_view_set_text_column, vFpi)
GO(gtk_icon_view_set_tooltip_cell, vFpppp)
@@ -1353,7 +1353,7 @@ GO(gtk_image_get_pixbuf, pFp)
GO(gtk_image_get_pixel_size, iFp)
GO(gtk_image_get_pixmap, vFppp)
GO(gtk_image_get_stock, vFppp)
-GO(gtk_image_get_storage_type, iFp)
+GO(gtk_image_get_storage_type, uFp)
GO(gtk_image_get_type, LFv)
GO(gtk_image_menu_item_get_always_show_image, iFp)
GO(gtk_image_menu_item_get_image, pFp)
@@ -1370,19 +1370,19 @@ GO(gtk_image_menu_item_set_use_stock, vFpi)
GO(gtk_image_new, pFv)
GO(gtk_image_new_from_animation, pFp)
GO(gtk_image_new_from_file, pFp)
-GO(gtk_image_new_from_gicon, pFpi)
-GO(gtk_image_new_from_icon_name, pFpi)
-GO(gtk_image_new_from_icon_set, pFpi)
+GO(gtk_image_new_from_gicon, pFpu)
+GO(gtk_image_new_from_icon_name, pFpu)
+GO(gtk_image_new_from_icon_set, pFpu)
GO(gtk_image_new_from_image, pFpp)
GO(gtk_image_new_from_pixbuf, pFp)
GO(gtk_image_new_from_pixmap, pFpp)
GO(gtk_image_new_from_stock, pFpi)
GO(gtk_image_set, vFppp)
GO(gtk_image_set_from_animation, vFpp)
-GO(gtk_image_set_from_file, vFppp)
-GO(gtk_image_set_from_gicon, vFppi)
-GO(gtk_image_set_from_icon_name, vFppi)
-GO(gtk_image_set_from_icon_set, vFppi)
+GO(gtk_image_set_from_file, vFpp)
+GO(gtk_image_set_from_gicon, vFppu)
+GO(gtk_image_set_from_icon_name, vFppu)
+GO(gtk_image_set_from_icon_set, vFppu)
GO(gtk_image_set_from_image, vFppp)
GO(gtk_image_set_from_pixbuf, vFpp)
GO(gtk_image_set_from_pixmap, vFppp)
@@ -1411,19 +1411,19 @@ GO(gtk_im_multicontext_new, pFv)
GO(gtk_im_multicontext_set_context_id, vFpp)
GO(gtk_im_preedit_style_get_type, LFv)
GO(gtk_im_status_style_get_type, LFv)
-//GO(gtk_info_bar_add_action_widget,
-//GO(gtk_info_bar_add_button,
+GO(gtk_info_bar_add_action_widget, vFppi)
+GO(gtk_info_bar_add_button, pFppi)
//GO(gtk_info_bar_add_buttons,
//GO(gtk_info_bar_get_action_area,
-//GO(gtk_info_bar_get_content_area,
-//GO(gtk_info_bar_get_message_type,
+GO(gtk_info_bar_get_content_area, pFp)
+GO(gtk_info_bar_get_message_type, uFp)
GO(gtk_info_bar_get_type, LFv)
//GO(gtk_info_bar_new,
//GO(gtk_info_bar_new_with_buttons,
-//GO(gtk_info_bar_response,
+GO(gtk_info_bar_response, vFpi)
//GO(gtk_info_bar_set_default_response,
-//GO(gtk_info_bar_set_message_type,
-//GO(gtk_info_bar_set_response_sensitive,
+GO(gtk_info_bar_set_message_type, vFpu)
+GO(gtk_info_bar_set_response_sensitive, vFpii)
GOM(gtk_init, vFEpp)
//GO(gtk_init_add,
GOM(gtk_init_check, iFEpp)
@@ -1432,13 +1432,13 @@ GOM(gtk_input_add_full, uFEiipppp)
GO(gtk_input_dialog_get_type, LFv)
GO(gtk_input_dialog_new, pFv)
GO(gtk_input_remove, vFu)
-//GO(gtk_invisible_get_screen,
+GO(gtk_invisible_get_screen, pFp)
GO(gtk_invisible_get_type, LFv)
//GO(gtk_invisible_new,
-//GO(gtk_invisible_new_for_screen,
-//GO(gtk_invisible_set_screen,
+GO(gtk_invisible_new_for_screen, pFp)
+GO(gtk_invisible_set_screen, vFpp)
//GO(gtk_item_deselect,
-//GO(gtk_item_factories_path_delete,
+GO(gtk_item_factories_path_delete, vFpp)
//GO(gtk_item_factory_add_foreign,
//GO(gtk_item_factory_construct,
//GO(gtk_item_factory_create_item,
@@ -1456,15 +1456,15 @@ GO(gtk_item_factory_get_type, LFv)
//GO(gtk_item_factory_get_widget,
//GO(gtk_item_factory_get_widget_by_action,
//GO(gtk_item_factory_new,
-//GO(gtk_item_factory_path_from_widget,
+GO(gtk_item_factory_path_from_widget, pFp)
//GO(gtk_item_factory_popup,
//GO(gtk_item_factory_popup_data,
-//GO(gtk_item_factory_popup_data_from_widget,
+GO(gtk_item_factory_popup_data_from_widget, pFp)
//GO(gtk_item_factory_popup_with_data,
//GO(gtk_item_factory_set_translate_func,
GO(gtk_item_get_type, LFv)
//GO(gtk_item_select,
-//GO(gtk_item_toggle,
+GO(gtk_item_toggle, vFp)
GO(gtk_justification_get_type, LFv)
//GOM(gtk_key_snooper_install, uFEBp)
GO(gtk_key_snooper_remove, vFu)
@@ -1472,13 +1472,13 @@ GO(gtk_label_get, vFpp)
GO(gtk_label_get_angle, dFp)
GO(gtk_label_get_attributes, pFp)
GO(gtk_label_get_current_uri, pFp)
-GO(gtk_label_get_ellipsize, iFp)
-GO(gtk_label_get_justify, iFp)
+GO(gtk_label_get_ellipsize, uFp)
+GO(gtk_label_get_justify, uFp)
GO(gtk_label_get_label, pFp)
GO(gtk_label_get_layout, pFp)
GO(gtk_label_get_layout_offsets, vFppp)
GO(gtk_label_get_line_wrap, iFp)
-GO(gtk_label_get_line_wrap_mode, iFp)
+GO(gtk_label_get_line_wrap_mode, uFp)
GO(gtk_label_get_max_width_chars, iFp)
GO(gtk_label_get_mnemonic_keyval, uFp)
GO(gtk_label_get_mnemonic_widget, pFp)
@@ -1497,11 +1497,11 @@ GO(gtk_label_parse_uline, uFpp)
GO(gtk_label_select_region, vFpii)
GO(gtk_label_set_angle, vFpd)
GO(gtk_label_set_attributes, vFpp)
-GO(gtk_label_set_ellipsize, vFpi)
-GO(gtk_label_set_justify, vFpi)
+GO(gtk_label_set_ellipsize, vFpu)
+GO(gtk_label_set_justify, vFpu)
GO(gtk_label_set_label, vFpp)
GO(gtk_label_set_line_wrap, vFpi)
-GO(gtk_label_set_line_wrap_mode, vFpi)
+GO(gtk_label_set_line_wrap_mode, vFpu)
GO(gtk_label_set_markup, vFpp)
GO(gtk_label_set_markup_with_mnemonic, vFpp)
GO(gtk_label_set_max_width_chars, vFpi)
@@ -1525,7 +1525,7 @@ GO(gtk_layout_move, vFppii)
GO(gtk_layout_new, pFpp)
GO(gtk_layout_put, vFppii)
GO(gtk_layout_set_hadjustment, vFpp)
-GO(gtk_layout_set_size, vFpii)
+GO(gtk_layout_set_size, vFpuu)
GO(gtk_layout_set_vadjustment, vFpp)
GO(gtk_layout_thaw, vFp)
GO(gtk_link_button_get_type, LFv)
@@ -1541,7 +1541,7 @@ GO(gtk_list_child_position, iFpp)
GO(gtk_list_clear_items, vFpii)
GO(gtk_list_end_drag_selection, vFp)
GO(gtk_list_end_selection, vFp)
-GO(gtk_list_extend_selection, vFpifi)
+GO(gtk_list_extend_selection, vFpufi)
GO(gtk_list_get_type, LFv)
GO(gtk_list_insert_items, vFppi)
GO(gtk_list_item_deselect, vFp)
@@ -1554,11 +1554,11 @@ GO(gtk_list_prepend_items, vFpp)
GO(gtk_list_remove_items, vFpp)
GO(gtk_list_remove_items_no_unref, vFpp)
GO(gtk_list_scroll_horizontal, vFpif)
-GO(gtk_list_scroll_vertical, vFpif)
+GO(gtk_list_scroll_vertical, vFpuf)
GO(gtk_list_select_all, vFp)
GO(gtk_list_select_child, vFpp)
GO(gtk_list_select_item, vFpi)
-GO(gtk_list_set_selection_mode, vFpi)
+GO(gtk_list_set_selection_mode, vFpu)
GO(gtk_list_start_selection, vFp)
GO(gtk_list_store_append, vFpp)
GO(gtk_list_store_clear, vFp)
@@ -1624,11 +1624,11 @@ GO(gtk_main_quit, vFv)
GO(gtk_match_type_get_type, LFv)
GO(gtk_menu_attach, vFppuuuu)
GOM(gtk_menu_attach_to_widget, vFEppp)
-GO(gtk_menu_bar_get_child_pack_direction, iFp)
+GO(gtk_menu_bar_get_child_pack_direction, uFp)
GO(gtk_menu_bar_get_pack_direction, iFp)
GO(gtk_menu_bar_get_type, LFv)
GO(gtk_menu_bar_new, pFv)
-GO(gtk_menu_bar_set_child_pack_direction, vFpi)
+GO(gtk_menu_bar_set_child_pack_direction, vFpu)
GO(gtk_menu_bar_set_pack_direction, vFpi)
GO(gtk_menu_detach, vFp)
GO(gtk_menu_direction_type_get_type, LFv)
@@ -1649,11 +1649,11 @@ GO(gtk_menu_item_get_label, pFp)
GO(gtk_menu_item_get_right_justified, iFp)
GO(gtk_menu_item_get_submenu, pFp)
GO(gtk_menu_item_get_type, LFv)
-GO(gtk_menu_item_get_use_underline, vFpi)
+GO(gtk_menu_item_get_use_underline, iFp)
GO(gtk_menu_item_new, pFv)
GO(gtk_menu_item_new_with_label, pFp)
GO(gtk_menu_item_new_with_mnemonic, pFp)
-GO(gtk_menu_item_remove_submenu, pFp)
+GO(gtk_menu_item_remove_submenu, vFp)
GO(gtk_menu_item_select, vFp)
GO(gtk_menu_item_set_accel_path, vFpp)
GO(gtk_menu_item_set_label, vFpp)
@@ -1675,7 +1675,7 @@ GO(gtk_menu_set_reserve_toggle_size, vFpi)
GO(gtk_menu_set_screen, vFpp)
GO(gtk_menu_set_tearoff_state, vFpi)
GO(gtk_menu_set_title, vFpp)
-//GO(gtk_menu_shell_activate_item,
+GO(gtk_menu_shell_activate_item, vFppi)
GO(gtk_menu_shell_append, vFpp)
//GO(gtk_menu_shell_cancel,
//GO(gtk_menu_shell_deactivate,
@@ -1721,7 +1721,7 @@ GO(gtk_mount_operation_set_screen, vFpp)
GO(gtk_movement_step_get_type, LFv)
GO(gtk_notebook_append_page, iFppp)
GO(gtk_notebook_append_page_menu, iFpppp)
-GO(gtk_notebook_get_action_widget, pFpi)
+GO(gtk_notebook_get_action_widget, pFpu)
GO(gtk_notebook_get_current_page, iFp)
GO(gtk_notebook_get_group, pFp)
GO(gtk_notebook_get_group_id, iFp)
@@ -1737,7 +1737,7 @@ GO(gtk_notebook_get_tab_detachable, iFpp)
GO(gtk_notebook_get_tab_hborder, WFp)
GO(gtk_notebook_get_tab_label, pFpp)
GO(gtk_notebook_get_tab_label_text, pFpp)
-GO(gtk_notebook_get_tab_pos, iFp)
+GO(gtk_notebook_get_tab_pos, uFp)
GO(gtk_notebook_get_tab_reorderable, iFpp)
GO(gtk_notebook_get_tab_vborder, WFp)
GO(gtk_notebook_get_type, LFv)
@@ -1754,7 +1754,7 @@ GO(gtk_notebook_prev_page, vFp)
GO(gtk_notebook_query_tab_label_packing, vFppppp)
GO(gtk_notebook_remove_page, vFpi)
GO(gtk_notebook_reorder_child, vFppi)
-GO(gtk_notebook_set_action_widget, vFppi)
+GO(gtk_notebook_set_action_widget, vFppu)
GO(gtk_notebook_set_current_page, vFpi)
GO(gtk_notebook_set_group, vFpp)
GO(gtk_notebook_set_group_id, vFpi)
@@ -1769,20 +1769,20 @@ GO(gtk_notebook_set_tab_border, vFpu)
GO(gtk_notebook_set_tab_detachable, vFppi)
GO(gtk_notebook_set_tab_hborder, vFpu)
GO(gtk_notebook_set_tab_label, vFppp)
-GO(gtk_notebook_set_tab_label_packing, vFppiii)
+GO(gtk_notebook_set_tab_label_packing, vFppiiu)
GO(gtk_notebook_set_tab_label_text, vFppp)
-GO(gtk_notebook_set_tab_pos, vFpi)
+GO(gtk_notebook_set_tab_pos, vFpu)
GO(gtk_notebook_set_tab_reorderable, vFppi)
GO(gtk_notebook_set_tab_vborder, vFpu)
//GOM(gtk_notebook_set_window_creation_hook, pFEppp)
GO(gtk_notebook_tab_get_type, LFv)
GO(gtk_number_up_layout_get_type, LFv)
-GO(gtk_object_add_arg_type, vFpiuu)
+GO(gtk_object_add_arg_type, vFpLuu)
GO(gtk_object_destroy, vFp)
GO(gtk_object_flags_get_type, LFv)
GO(gtk_object_get, vFppppppppppp) // vaarg
GO(gtk_object_get_data, pFpp)
-GO(gtk_object_get_data_by_id, pFpp)
+GO(gtk_object_get_data_by_id, pFpu)
GO(gtk_object_get_type, LFv)
GO(gtk_object_get_user_data, pFp)
GO(gtk_object_new, pFppppppppppp) //vaarg
@@ -1790,10 +1790,10 @@ GO(gtk_object_ref, pFp)
GO(gtk_object_remove_data, vFpp)
GO(gtk_object_remove_data_by_id, vFpp)
GO(gtk_object_remove_no_notify, vFpp)
-GO(gtk_object_remove_no_notify_by_id, vFpp)
+GO(gtk_object_remove_no_notify_by_id, vFpu)
GO(gtk_object_set, vFppppppppppp) //vaarg
GO(gtk_object_set_data, vFppp)
-GO(gtk_object_set_data_by_id, vFppp)
+GO(gtk_object_set_data_by_id, vFpup)
//GOM(gtk_object_set_data_by_id_full, vFEpppp)
GOM(gtk_object_set_data_full, vFEpppp)
GO(gtk_object_set_user_data, vFpp)
@@ -1815,75 +1815,75 @@ GO(gtk_option_menu_new, pFv)
GO(gtk_option_menu_remove_menu, vFp)
GO(gtk_option_menu_set_history, vFpu)
GO(gtk_option_menu_set_menu, vFpp)
-GO(gtk_orientable_get_orientation, iFp)
+GO(gtk_orientable_get_orientation, uFp)
GO(gtk_orientable_get_type, LFv)
-GO(gtk_orientable_set_orientation, vFpi)
+GO(gtk_orientable_set_orientation, vFpu)
GO(gtk_orientation_get_type, LFv)
GO(gtk_pack_direction_get_type, LFv)
GO(gtk_pack_type_get_type, LFv)
GO(gtk_page_orientation_get_type, LFv)
GO(gtk_page_set_get_type, LFv)
-//GO(gtk_page_setup_copy,
-//GO(gtk_page_setup_get_bottom_margin,
-//GO(gtk_page_setup_get_left_margin,
-//GO(gtk_page_setup_get_orientation,
-//GO(gtk_page_setup_get_page_height,
-//GO(gtk_page_setup_get_page_width,
-//GO(gtk_page_setup_get_paper_height,
-//GO(gtk_page_setup_get_paper_size,
-//GO(gtk_page_setup_get_paper_width,
-//GO(gtk_page_setup_get_right_margin,
-//GO(gtk_page_setup_get_top_margin,
+GO(gtk_page_setup_copy, pFp)
+GO(gtk_page_setup_get_bottom_margin, dFpi)
+GO(gtk_page_setup_get_left_margin, dFpi)
+GO(gtk_page_setup_get_orientation, uFp)
+GO(gtk_page_setup_get_page_height, dFpu)
+GO(gtk_page_setup_get_page_width, dFpi)
+GO(gtk_page_setup_get_paper_height, dFpi)
+GO(gtk_page_setup_get_paper_size, pFp)
+GO(gtk_page_setup_get_paper_width, dFpi)
+GO(gtk_page_setup_get_right_margin, dFpi)
+GO(gtk_page_setup_get_top_margin, dFpi)
GO(gtk_page_setup_get_type, LFv)
//GO(gtk_page_setup_load_file,
-//GO(gtk_page_setup_load_key_file,
-//GO(gtk_page_setup_new,
-//GO(gtk_page_setup_new_from_file,
-//GO(gtk_page_setup_new_from_key_file,
+GO(gtk_page_setup_load_key_file, iFpppp)
+GO(gtk_page_setup_new, pFv)
+GO(gtk_page_setup_new_from_file, pFpp)
+GO(gtk_page_setup_new_from_key_file, pFppp)
//GO(gtk_page_setup_set_bottom_margin,
//GO(gtk_page_setup_set_left_margin,
-//GO(gtk_page_setup_set_orientation,
-//GO(gtk_page_setup_set_paper_size,
-//GO(gtk_page_setup_set_paper_size_and_default_margins,
-//GO(gtk_page_setup_set_right_margin,
+GO(gtk_page_setup_set_orientation, vFpu)
+GO(gtk_page_setup_set_paper_size, vFpp)
+GO(gtk_page_setup_set_paper_size_and_default_margins, vFpp)
+GO(gtk_page_setup_set_right_margin, vFpdu)
//GO(gtk_page_setup_set_top_margin,
-//GO(gtk_page_setup_to_file,
-//GO(gtk_page_setup_to_key_file,
+GO(gtk_page_setup_to_file, iFppp)
+GO(gtk_page_setup_to_key_file, vFppp)
//GO(gtk_page_setup_unix_dialog_get_page_setup,
//GO(gtk_page_setup_unix_dialog_get_print_settings,
GO(gtk_page_setup_unix_dialog_get_type, LFv)
//GO(gtk_page_setup_unix_dialog_new,
//GO(gtk_page_setup_unix_dialog_set_page_setup,
//GO(gtk_page_setup_unix_dialog_set_print_settings,
-GO(gtk_paint_arrow, vFppiipppiiiiii)
+GO(gtk_paint_arrow, vFppuupppuiiiii)
GO(gtk_paint_box, vFppiipppiiii)
-GO(gtk_paint_box_gap, vFppiipppiiiiiii)
+GO(gtk_paint_box_gap, vFppuupppiiiiuii)
GO(gtk_paint_check, vFppiipppiiii)
GO(gtk_paint_diamond, vFppiipppiiii)
-GO(gtk_paint_expander, vFppipppiii)
-GO(gtk_paint_extension, vFppiipppiiiii)
+GO(gtk_paint_expander, vFppupppiiu)
+GO(gtk_paint_extension, vFppuupppiiiiu)
GO(gtk_paint_flat_box, vFppiipppiiii)
-GO(gtk_paint_focus, vFppipppiiii)
-GO(gtk_paint_handle, vFppiipppiiiii)
+GO(gtk_paint_focus, vFppupppiiii)
+GO(gtk_paint_handle, vFppuupppiiiiu)
GO(gtk_paint_hline, vFppipppiii)
-GO(gtk_paint_layout, vFppiipppiip)
+GO(gtk_paint_layout, vFppuipppiip)
GO(gtk_paint_option, vFppiipppiiii)
-GO(gtk_paint_polygon, vFppiippppii)
-GO(gtk_paint_resize_grip, vFppipppiiiii)
+GO(gtk_paint_polygon, vFppuuppppii)
+GO(gtk_paint_resize_grip, vFppupppuiiii)
GO(gtk_paint_shadow, vFppiipppiiii)
GO(gtk_paint_shadow_gap, vFppiipppiiiiiii)
GO(gtk_paint_slider, vFppiipppiiiii)
-GO(gtk_paint_spinner, vFppipppuiiii)
-GO(gtk_paint_string, vFppipppiip)
-GO(gtk_paint_tab, vFppiipppiiii)
-GO(gtk_paint_vline, vFppipppiii)
+GO(gtk_paint_spinner, vFppupppuiiii)
+GO(gtk_paint_string, vFppupppiip)
+GO(gtk_paint_tab, vFppuupppiiii)
+GO(gtk_paint_vline, vFppupppiii)
GO(gtk_paned_add1, vFpp)
GO(gtk_paned_add2, vFpp)
GO(gtk_paned_compute_position, vFpiii)
GO(gtk_paned_get_child1, pFp)
GO(gtk_paned_get_child2, pFp)
GO(gtk_paned_get_handle_window, pFp)
-GO(gtk_paned_get_position, pFp)
+GO(gtk_paned_get_position, iFp)
GO(gtk_paned_get_type, LFv)
GO(gtk_paned_pack1, vFppii)
GO(gtk_paned_pack2, vFppii)
@@ -1893,7 +1893,7 @@ GO(gtk_paper_size_free, vFp)
GO(gtk_paper_size_get_default, pFv)
GO(gtk_paper_size_get_default_bottom_margin, dFpi)
GO(gtk_paper_size_get_default_left_margin, dFpi)
-GO(gtk_paper_size_get_default_right_margin, dFpi)
+GO(gtk_paper_size_get_default_right_margin, dFpu)
GO(gtk_paper_size_get_default_top_margin, dFpi)
GO(gtk_paper_size_get_display_name, pFp)
GO(gtk_paper_size_get_height, dFpi)
@@ -1905,10 +1905,10 @@ GO(gtk_paper_size_get_width, dFpi)
GO(gtk_paper_size_is_custom, iFp)
GO(gtk_paper_size_is_equal, iFpp)
GO(gtk_paper_size_new, pFp)
-GO(gtk_paper_size_new_custom, pFppddi)
+GO(gtk_paper_size_new_custom, pFppddu)
GO(gtk_paper_size_new_from_key_file, pFppp)
GO(gtk_paper_size_new_from_ppd, pFppdd)
-GO(gtk_paper_size_set_size, vFpddi)
+GO(gtk_paper_size_set_size, vFpddu)
GO(gtk_paper_size_to_key_file, vFppp)
GO(gtk_parse_args, iFpp)
GO(gtk_path_bar_get_type, LFv)
@@ -1919,31 +1919,31 @@ GO(gtk_pixmap_get_type, LFv)
GO(gtk_pixmap_new, pFpp)
GO(gtk_pixmap_set, vFppp)
GO(gtk_pixmap_set_build_insensitive, vFpi)
-GO(gtk_plug_construct, vFpp)
+GO(gtk_plug_construct, vFpu)
GO(gtk_plug_construct_for_display, vFppp)
GO(gtk_plug_get_embedded, iFp)
-GO(gtk_plug_get_id, pFp)
+GO(gtk_plug_get_id, uFp)
GO(gtk_plug_get_socket_window, pFp)
GO(gtk_plug_get_type, LFv)
-GO(gtk_plug_new, pFp)
+GO(gtk_plug_new, pFu)
GO(gtk_plug_new_for_display, pFpp)
GO(gtk_policy_type_get_type, LFv)
GO(gtk_position_type_get_type, LFv)
-//GO(gtk_preview_draw_row,
-//GO(gtk_preview_get_cmap,
-//GO(gtk_preview_get_info,
+GO(gtk_preview_draw_row, vFppiii)
+GO(gtk_preview_get_cmap, pFv)
+GO(gtk_preview_get_info, pFv)
GO(gtk_preview_get_type, LFv)
-//GO(gtk_preview_get_visual,
-//GO(gtk_preview_new,
-//GO(gtk_preview_put,
-//GO(gtk_preview_reset,
-//GO(gtk_preview_set_color_cube,
-//GO(gtk_preview_set_dither,
-//GO(gtk_preview_set_expand,
-//GO(gtk_preview_set_gamma,
+GO(gtk_preview_get_visual, pFv)
+GO(gtk_preview_new, pFu)
+GO(gtk_preview_put, vFpppiiiiii)
+GO(gtk_preview_reset, vFv)
+GO(gtk_preview_set_color_cube, vFuuuu)
+GO(gtk_preview_set_dither, vFpu)
+GO(gtk_preview_set_expand, vFpi)
+GO(gtk_preview_set_gamma, vFd)
//GO(gtk_preview_set_install_cmap,
-//GO(gtk_preview_set_reserved,
-//GO(gtk_preview_size,
+GO(gtk_preview_set_reserved, vFi)
+GO(gtk_preview_size, vFpii)
GO(gtk_preview_type_get_type, LFv)
//GO(gtk_preview_uninit,
//GO(gtk_print_backend_add_printer,
@@ -1959,37 +1959,37 @@ GO(gtk_print_backend_get_type, LFv)
//GO(gtk_print_backend_set_list_done,
//GO(gtk_print_backend_set_password,
GO(gtk_print_capabilities_get_type, LFv)
-//GO(gtk_print_context_create_pango_context,
-//GO(gtk_print_context_create_pango_layout,
-//GO(gtk_print_context_get_cairo_context,
+GO(gtk_print_context_create_pango_context, pFp)
+GO(gtk_print_context_create_pango_layout, pFp)
+GO(gtk_print_context_get_cairo_context, pFp)
//GO(gtk_print_context_get_dpi_x,
-//GO(gtk_print_context_get_dpi_y,
-//GO(gtk_print_context_get_hard_margins,
+GO(gtk_print_context_get_dpi_y, dFp)
+GO(gtk_print_context_get_hard_margins, iFppppp)
//GO(gtk_print_context_get_height,
-//GO(gtk_print_context_get_page_setup,
-//GO(gtk_print_context_get_pango_fontmap,
+GO(gtk_print_context_get_page_setup, pFp)
+GO(gtk_print_context_get_pango_fontmap, pFp)
GO(gtk_print_context_get_type, LFv)
//GO(gtk_print_context_get_width,
-//GO(gtk_print_context_set_cairo_context,
+GO(gtk_print_context_set_cairo_context, vFppdd)
GO(gtk_print_duplex_get_type, LFv)
//GO(gtk_printer_accepts_pdf,
//GO(gtk_printer_accepts_ps,
//GO(gtk_printer_compare,
//GO(gtk_printer_get_backend,
//GO(gtk_printer_get_capabilities,
-//GO(gtk_printer_get_default_page_size,
+GO(gtk_printer_get_default_page_size, pFp)
//GO(gtk_printer_get_description,
//GO(gtk_printer_get_hard_margins,
//GO(gtk_printer_get_icon_name,
//GO(gtk_printer_get_job_count,
//GO(gtk_printer_get_location,
-//GO(gtk_printer_get_name,
+GO(gtk_printer_get_name, pFp)
//GO(gtk_printer_get_state_message,
GO(gtk_printer_get_type, LFv)
//GO(gtk_printer_has_details,
//GO(gtk_printer_is_accepting_jobs,
//GO(gtk_printer_is_active,
-//GO(gtk_printer_is_default,
+GO(gtk_printer_is_default, iFp)
//GO(gtk_printer_is_new,
//GO(gtk_printer_is_paused,
//GO(gtk_printer_is_virtual,
@@ -2044,126 +2044,126 @@ GO(gtk_print_error_get_type, LFv)
//GO(gtk_print_job_get_title,
//GO(gtk_print_job_get_track_print_status,
GO(gtk_print_job_get_type, LFv)
-//GO(gtk_print_job_new,
-//GO(gtk_print_job_send,
-//GO(gtk_print_job_set_source_file,
+GO(gtk_print_job_new, pFpppp)
+GOM(gtk_print_job_send, vFEpppp)
+GO(gtk_print_job_set_source_file, vFppp)
//GO(gtk_print_job_set_status,
//GO(gtk_print_job_set_track_print_status,
GO(gtk_print_operation_action_get_type, LFv)
//GO(gtk_print_operation_cancel,
//GO(gtk_print_operation_draw_page_finish,
-//GO(gtk_print_operation_get_default_page_setup,
-//GO(gtk_print_operation_get_embed_page_setup,
-//GO(gtk_print_operation_get_error,
+GO(gtk_print_operation_get_default_page_setup, pFp)
+GO(gtk_print_operation_get_embed_page_setup, iFp)
+GO(gtk_print_operation_get_error, vFpp)
//GO(gtk_print_operation_get_has_selection,
-//GO(gtk_print_operation_get_n_pages_to_print,
-//GO(gtk_print_operation_get_print_settings,
-//GO(gtk_print_operation_get_status,
-//GO(gtk_print_operation_get_status_string,
+GO(gtk_print_operation_get_n_pages_to_print, iFp)
+GO(gtk_print_operation_get_print_settings, pFp)
+GO(gtk_print_operation_get_status, uFp)
+GO(gtk_print_operation_get_status_string, pFp)
//GO(gtk_print_operation_get_support_selection,
GO(gtk_print_operation_get_type, LFv)
//GO(gtk_print_operation_is_finished,
-//GO(gtk_print_operation_new,
-//GO(gtk_print_operation_preview_end_preview,
+GO(gtk_print_operation_new, pFv)
+GO(gtk_print_operation_preview_end_preview, vFp)
GO(gtk_print_operation_preview_get_type, LFv)
-//GO(gtk_print_operation_preview_is_selected,
-//GO(gtk_print_operation_preview_render_page,
+GO(gtk_print_operation_preview_is_selected, iFpi)
+GO(gtk_print_operation_preview_render_page, vFpi)
GO(gtk_print_operation_result_get_type, LFv)
-//GO(gtk_print_operation_run,
+GO(gtk_print_operation_run, uFpupp)
//GO(gtk_print_operation_set_allow_async,
-//GO(gtk_print_operation_set_current_page,
-//GO(gtk_print_operation_set_custom_tab_label,
-//GO(gtk_print_operation_set_default_page_setup,
-//GO(gtk_print_operation_set_defer_drawing,
-//GO(gtk_print_operation_set_embed_page_setup,
+GO(gtk_print_operation_set_current_page, vFpi)
+GO(gtk_print_operation_set_custom_tab_label, vFpp)
+GO(gtk_print_operation_set_default_page_setup, vFpp)
+GO(gtk_print_operation_set_defer_drawing, vFp)
+GO(gtk_print_operation_set_embed_page_setup, vFpi)
//GO(gtk_print_operation_set_export_filename,
//GO(gtk_print_operation_set_has_selection,
//GO(gtk_print_operation_set_job_name,
//GO(gtk_print_operation_set_n_pages,
-//GO(gtk_print_operation_set_print_settings,
+GO(gtk_print_operation_set_print_settings, vFpp)
//GO(gtk_print_operation_set_show_progress,
//GO(gtk_print_operation_set_support_selection,
//GO(gtk_print_operation_set_track_print_status,
-//GO(gtk_print_operation_set_unit,
+GO(gtk_print_operation_set_unit, vFpu)
//GO(gtk_print_operation_set_use_full_page,
GO(gtk_print_pages_get_type, LFv)
GO(gtk_print_quality_get_type, LFv)
-//GO(gtk_print_run_page_setup_dialog,
+GO(gtk_print_run_page_setup_dialog, pFppp)
//GO(gtk_print_run_page_setup_dialog_async,
-//GO(gtk_print_settings_copy,
+GO(gtk_print_settings_copy, pFp)
//GO(gtk_print_settings_foreach,
-//GO(gtk_print_settings_get,
-//GO(gtk_print_settings_get_bool,
+GO(gtk_print_settings_get, pFpp)
+GO(gtk_print_settings_get_bool, iFpp)
//GO(gtk_print_settings_get_collate,
//GO(gtk_print_settings_get_default_source,
//GO(gtk_print_settings_get_dither,
-//GO(gtk_print_settings_get_double,
-//GO(gtk_print_settings_get_double_with_default,
-//GO(gtk_print_settings_get_duplex,
+GO(gtk_print_settings_get_double, dFpp)
+GO(gtk_print_settings_get_double_with_default, dFppd)
+GO(gtk_print_settings_get_duplex, uFp)
//GO(gtk_print_settings_get_finishings,
-//GO(gtk_print_settings_get_int,
-//GO(gtk_print_settings_get_int_with_default,
-//GO(gtk_print_settings_get_length,
+GO(gtk_print_settings_get_int, iFpp)
+GO(gtk_print_settings_get_int_with_default, iFppi)
+GO(gtk_print_settings_get_length, dFppu)
//GO(gtk_print_settings_get_media_type,
//GO(gtk_print_settings_get_n_copies,
//GO(gtk_print_settings_get_number_up,
-//GO(gtk_print_settings_get_number_up_layout,
-//GO(gtk_print_settings_get_orientation,
-//GO(gtk_print_settings_get_output_bin,
-//GO(gtk_print_settings_get_page_ranges,
-//GO(gtk_print_settings_get_page_set,
-//GO(gtk_print_settings_get_paper_height,
-//GO(gtk_print_settings_get_paper_size,
+GO(gtk_print_settings_get_number_up_layout, uFp)
+GO(gtk_print_settings_get_orientation, uFp)
+GO(gtk_print_settings_get_output_bin, pFp)
+GO(gtk_print_settings_get_page_ranges, pFpp)
+GO(gtk_print_settings_get_page_set, uFp)
+GO(gtk_print_settings_get_paper_height, dFpu)
+GO(gtk_print_settings_get_paper_size, pFp)
//GO(gtk_print_settings_get_paper_width,
-//GO(gtk_print_settings_get_printer,
+GO(gtk_print_settings_get_printer, pFp)
//GO(gtk_print_settings_get_printer_lpi,
-//GO(gtk_print_settings_get_print_pages,
-//GO(gtk_print_settings_get_quality,
-//GO(gtk_print_settings_get_resolution,
+GO(gtk_print_settings_get_print_pages, uFp)
+GO(gtk_print_settings_get_quality, uFp)
+GO(gtk_print_settings_get_resolution, iFp)
//GO(gtk_print_settings_get_resolution_x,
-//GO(gtk_print_settings_get_resolution_y,
-//GO(gtk_print_settings_get_reverse,
-//GO(gtk_print_settings_get_scale,
+GO(gtk_print_settings_get_resolution_y, iFp)
+GO(gtk_print_settings_get_reverse, iFp)
+GO(gtk_print_settings_get_scale, dFp)
GO(gtk_print_settings_get_type, LFv)
//GO(gtk_print_settings_get_use_color,
//GO(gtk_print_settings_has_key,
//GO(gtk_print_settings_load_file,
-//GO(gtk_print_settings_load_key_file,
-//GO(gtk_print_settings_new,
-//GO(gtk_print_settings_new_from_file,
-//GO(gtk_print_settings_new_from_key_file,
-//GO(gtk_print_settings_set,
-//GO(gtk_print_settings_set_bool,
-//GO(gtk_print_settings_set_collate,
+GO(gtk_print_settings_load_key_file, iFpppp)
+GO(gtk_print_settings_new, pFv)
+GO(gtk_print_settings_new_from_file, pFpp)
+GO(gtk_print_settings_new_from_key_file, pFppp)
+GO(gtk_print_settings_set, vFppp)
+GO(gtk_print_settings_set_bool, vFppi)
+GO(gtk_print_settings_set_collate, vFpi)
//GO(gtk_print_settings_set_default_source,
//GO(gtk_print_settings_set_dither,
-//GO(gtk_print_settings_set_double,
-//GO(gtk_print_settings_set_duplex,
+GO(gtk_print_settings_set_double, vFppd)
+GO(gtk_print_settings_set_duplex, vFpu)
//GO(gtk_print_settings_set_finishings,
-//GO(gtk_print_settings_set_int,
-//GO(gtk_print_settings_set_length,
+GO(gtk_print_settings_set_int, vFppi)
+GO(gtk_print_settings_set_length, vFppdu)
//GO(gtk_print_settings_set_media_type,
-//GO(gtk_print_settings_set_n_copies,
+GO(gtk_print_settings_set_n_copies, vFpi)
//GO(gtk_print_settings_set_number_up,
-//GO(gtk_print_settings_set_number_up_layout,
-//GO(gtk_print_settings_set_orientation,
-//GO(gtk_print_settings_set_output_bin,
-//GO(gtk_print_settings_set_page_ranges,
-//GO(gtk_print_settings_set_page_set,
-//GO(gtk_print_settings_set_paper_height,
-//GO(gtk_print_settings_set_paper_size,
+GO(gtk_print_settings_set_number_up_layout, vFpu)
+GO(gtk_print_settings_set_orientation, vFpu)
+GO(gtk_print_settings_set_output_bin, vFpp)
+GO(gtk_print_settings_set_page_ranges, vFppi)
+GO(gtk_print_settings_set_page_set, vFpu)
+GO(gtk_print_settings_set_paper_height, vFpdu)
+GO(gtk_print_settings_set_paper_size, vFpp)
//GO(gtk_print_settings_set_paper_width,
-//GO(gtk_print_settings_set_printer,
+GO(gtk_print_settings_set_printer, vFpp)
//GO(gtk_print_settings_set_printer_lpi,
-//GO(gtk_print_settings_set_print_pages,
-//GO(gtk_print_settings_set_quality,
-//GO(gtk_print_settings_set_resolution,
-//GO(gtk_print_settings_set_resolution_xy,
-//GO(gtk_print_settings_set_reverse,
-//GO(gtk_print_settings_set_scale,
+GO(gtk_print_settings_set_print_pages, vFpu)
+GO(gtk_print_settings_set_quality, vFpu)
+GO(gtk_print_settings_set_resolution, vFpi)
+GO(gtk_print_settings_set_resolution_xy, vFpii)
+GO(gtk_print_settings_set_reverse, vFpi)
+GO(gtk_print_settings_set_scale, vFpd)
//GO(gtk_print_settings_set_use_color,
-//GO(gtk_print_settings_to_file,
-//GO(gtk_print_settings_to_key_file,
+GO(gtk_print_settings_to_file, iFppp)
+GO(gtk_print_settings_to_key_file, vFppp)
//GO(gtk_print_settings_unset,
GO(gtk_print_status_get_type, LFv)
//GO(gtk_print_unix_dialog_add_custom_tab,
@@ -2171,25 +2171,25 @@ GO(gtk_print_status_get_type, LFv)
//GO(gtk_print_unix_dialog_get_embed_page_setup,
//GO(gtk_print_unix_dialog_get_has_selection,
//GO(gtk_print_unix_dialog_get_manual_capabilities,
-//GO(gtk_print_unix_dialog_get_page_setup,
+GO(gtk_print_unix_dialog_get_page_setup, pFp)
//GO(gtk_print_unix_dialog_get_page_setup_set,
-//GO(gtk_print_unix_dialog_get_selected_printer,
-//GO(gtk_print_unix_dialog_get_settings,
+GO(gtk_print_unix_dialog_get_selected_printer, pFp)
+GO(gtk_print_unix_dialog_get_settings, pFp)
//GO(gtk_print_unix_dialog_get_support_selection,
GO(gtk_print_unix_dialog_get_type, LFv)
-//GO(gtk_print_unix_dialog_new,
+GO(gtk_print_unix_dialog_new, pFpp)
//GO(gtk_print_unix_dialog_set_current_page,
-//GO(gtk_print_unix_dialog_set_embed_page_setup,
-//GO(gtk_print_unix_dialog_set_has_selection,
-//GO(gtk_print_unix_dialog_set_manual_capabilities,
+GO(gtk_print_unix_dialog_set_embed_page_setup, vFpi)
+GO(gtk_print_unix_dialog_set_has_selection, vFpi)
+GO(gtk_print_unix_dialog_set_manual_capabilities, vFpi)
//GO(gtk_print_unix_dialog_set_page_setup,
-//GO(gtk_print_unix_dialog_set_settings,
-//GO(gtk_print_unix_dialog_set_support_selection,
+GO(gtk_print_unix_dialog_set_settings, vFpp)
+GO(gtk_print_unix_dialog_set_support_selection, vFpi)
GO(gtk_private_flags_get_type, LFv)
-GO(gtk_progress_bar_get_ellipsize, iFp)
+GO(gtk_progress_bar_get_ellipsize, uFp)
GO(gtk_progress_bar_get_fraction, dFp)
-GO(gtk_progress_bar_get_orientation, iFp)
-GO(gtk_progress_bar_get_pulse_step, fFp)
+GO(gtk_progress_bar_get_orientation, uFp)
+GO(gtk_progress_bar_get_pulse_step, dFp)
GO(gtk_progress_bar_get_text, pFp)
GO(gtk_progress_bar_get_type, LFv)
GO(gtk_progress_bar_new, pFv)
@@ -2198,11 +2198,11 @@ GO(gtk_progress_bar_orientation_get_type, LFv)
GO(gtk_progress_bar_pulse, vFp)
GO(gtk_progress_bar_set_activity_blocks, vFpu)
GO(gtk_progress_bar_set_activity_step, vFpu)
-GO(gtk_progress_bar_set_bar_style, vFpi)
+GO(gtk_progress_bar_set_bar_style, vFpu)
GO(gtk_progress_bar_set_discrete_blocks, vFpu)
-GO(gtk_progress_bar_set_ellipsize, vFpi)
+GO(gtk_progress_bar_set_ellipsize, vFpu)
GO(gtk_progress_bar_set_fraction, vFpd)
-GO(gtk_progress_bar_set_orientation, vFpi)
+GO(gtk_progress_bar_set_orientation, vFpu)
GO(gtk_progress_bar_set_pulse_step, vFpd)
GO(gtk_progress_bar_set_text, vFpp)
GO(gtk_progress_bar_style_get_type, LFv)
@@ -2271,8 +2271,8 @@ GO(gtk_range_get_show_fill_level, iFp)
GO(gtk_range_get_slider_range, vFppp)
GO(gtk_range_get_slider_size_fixed, iFp)
GO(gtk_range_get_type, LFv)
-GO(gtk_range_get_update_policy, iFp)
-GO(gtk_range_get_upper_stepper_sensitivity, iFp)
+GO(gtk_range_get_update_policy, uFp)
+GO(gtk_range_get_upper_stepper_sensitivity, uFp)
GO(gtk_range_get_value, dFp)
GO(gtk_range_set_adjustment, vFpp)
GO(gtk_range_set_fill_level, vFpd)
@@ -2286,8 +2286,8 @@ GO(gtk_range_set_restrict_to_fill_level, vFpi)
GO(gtk_range_set_round_digits, vFpi)
GO(gtk_range_set_show_fill_level, vFpi)
GO(gtk_range_set_slider_size_fixed, vFpi)
-GO(gtk_range_set_update_policy, vFpi)
-GO(gtk_range_set_upper_stepper_sensitivity, vFpi)
+GO(gtk_range_set_update_policy, vFpu)
+GO(gtk_range_set_upper_stepper_sensitivity, vFpu)
GO(gtk_range_set_value, vFpd)
GO(gtk_rc_add_class_style, vFpp)
GO(gtk_rc_add_default_file, vFp)
@@ -2301,7 +2301,7 @@ GO(gtk_rc_get_im_module_file, pFv)
GO(gtk_rc_get_im_module_path, pFv)
GO(gtk_rc_get_module_dir, pFv)
GO(gtk_rc_get_style, pFp)
-GO(gtk_rc_get_style_by_paths, pFpppi)
+GO(gtk_rc_get_style_by_paths, pFpppL)
GO(gtk_rc_get_theme_dir, pFv)
GO(gtk_rc_parse, vFp)
GO(gtk_rc_parse_color, uFpp)
@@ -2325,33 +2325,33 @@ GO(gtk_rc_style_new, pFv)
GO(gtk_rc_style_ref, vFp)
GO(gtk_rc_style_unref, vFp)
GO(gtk_rc_token_type_get_type, LFv)
-//GO(gtk_recent_action_get_show_numbers,
+GO(gtk_recent_action_get_show_numbers, iFp)
GO(gtk_recent_action_get_type, LFv)
-//GO(gtk_recent_action_new,
-//GO(gtk_recent_action_new_for_manager,
-//GO(gtk_recent_action_set_show_numbers,
+GO(gtk_recent_action_new, pFpppp)
+GO(gtk_recent_action_new_for_manager, pFppppp)
+GO(gtk_recent_action_set_show_numbers, vFpi)
//GO(gtk_recent_chooser_add_filter,
GO(gtk_recent_chooser_dialog_get_type, LFv)
//GO(gtk_recent_chooser_dialog_new,
//GO(gtk_recent_chooser_dialog_new_for_manager,
GO(gtk_recent_chooser_error_get_type, LFv)
-//GO(gtk_recent_chooser_error_quark,
-//GO(gtk_recent_chooser_get_current_item,
-//GO(gtk_recent_chooser_get_current_uri,
-//GO(gtk_recent_chooser_get_filter,
-//GO(gtk_recent_chooser_get_items,
-//GO(gtk_recent_chooser_get_limit,
+GO(gtk_recent_chooser_error_quark, uFv)
+GO(gtk_recent_chooser_get_current_item, pFp)
+GO(gtk_recent_chooser_get_current_uri, pFp)
+GO(gtk_recent_chooser_get_filter, pFp)
+GO(gtk_recent_chooser_get_items, pFp)
+GO(gtk_recent_chooser_get_limit, iFp)
//GO(gtk_recent_chooser_get_local_only,
//GO(gtk_recent_chooser_get_select_multiple,
-//GO(gtk_recent_chooser_get_show_icons,
+GO(gtk_recent_chooser_get_show_icons, iFp)
//GO(gtk_recent_chooser_get_show_not_found,
//GO(gtk_recent_chooser_get_show_numbers,
//GO(gtk_recent_chooser_get_show_private,
//GO(gtk_recent_chooser_get_show_tips,
-//GO(gtk_recent_chooser_get_sort_type,
+GO(gtk_recent_chooser_get_sort_type, uFp)
GO(gtk_recent_chooser_get_type, LFv)
-//GO(gtk_recent_chooser_get_uris,
-//GO(gtk_recent_chooser_list_filters,
+GO(gtk_recent_chooser_get_uris, pFpp)
+GO(gtk_recent_chooser_list_filters, pFp)
//GO(gtk_recent_chooser_menu_get_show_numbers,
GO(gtk_recent_chooser_menu_get_type, LFv)
//GO(gtk_recent_chooser_menu_new,
@@ -2359,24 +2359,24 @@ GO(gtk_recent_chooser_menu_get_type, LFv)
//GO(gtk_recent_chooser_menu_set_show_numbers,
//GO(gtk_recent_chooser_remove_filter,
//GO(gtk_recent_chooser_select_all,
-//GO(gtk_recent_chooser_select_uri,
+GO(gtk_recent_chooser_select_uri, iFppp)
//GO(gtk_recent_chooser_set_current_uri,
-//GO(gtk_recent_chooser_set_filter,
-//GO(gtk_recent_chooser_set_limit,
+GO(gtk_recent_chooser_set_filter, vFpp)
+GO(gtk_recent_chooser_set_limit, vFpi)
//GO(gtk_recent_chooser_set_local_only,
//GO(gtk_recent_chooser_set_select_multiple,
-//GO(gtk_recent_chooser_set_show_icons,
+GO(gtk_recent_chooser_set_show_icons, vFpi)
//GO(gtk_recent_chooser_set_show_not_found,
//GO(gtk_recent_chooser_set_show_numbers,
//GO(gtk_recent_chooser_set_show_private,
//GO(gtk_recent_chooser_set_show_tips,
//GO(gtk_recent_chooser_set_sort_func,
-//GO(gtk_recent_chooser_set_sort_type,
-//GO(gtk_recent_chooser_unselect_all,
-//GO(gtk_recent_chooser_unselect_uri,
+GO(gtk_recent_chooser_set_sort_type, vFpu)
+GO(gtk_recent_chooser_unselect_all, vFp)
+GO(gtk_recent_chooser_unselect_uri, vFpp)
GO(gtk_recent_chooser_widget_get_type, LFv)
//GO(gtk_recent_chooser_widget_new,
-//GO(gtk_recent_chooser_widget_new_for_manager,
+GO(gtk_recent_chooser_widget_new_for_manager, pFp)
GO(gtk_recent_filter_add_age, vFpi)
GO(gtk_recent_filter_add_application, vFpp)
//GOM(gtk_recent_filter_add_custom, vFEpippp)
@@ -2387,7 +2387,7 @@ GO(gtk_recent_filter_add_pixbuf_formats, vFp)
GO(gtk_recent_filter_filter, iFpp)
GO(gtk_recent_filter_flags_get_type, LFv)
GO(gtk_recent_filter_get_name, pFp)
-GO(gtk_recent_filter_get_needed, iFp)
+GO(gtk_recent_filter_get_needed, uFp)
GO(gtk_recent_filter_get_type, LFv)
GO(gtk_recent_filter_new, pFv)
GO(gtk_recent_filter_set_name, vFpp)
@@ -2439,52 +2439,52 @@ GO(gtk_requisition_free, vFp)
GO(gtk_requisition_get_type, LFv)
GO(gtk_resize_mode_get_type, LFv)
GO(gtk_response_type_get_type, LFv)
-//GO(gtk_rgb_to_hsv,
-//GO(gtk_ruler_draw_pos,
+GO(gtk_rgb_to_hsv, vFdddppp)
+GO(gtk_ruler_draw_pos, vFp)
//GO(gtk_ruler_draw_ticks,
-//GO(gtk_ruler_get_metric,
-//GO(gtk_ruler_get_range,
+GO(gtk_ruler_get_metric, uFp)
+GO(gtk_ruler_get_range, vFppppp)
GO(gtk_ruler_get_type, LFv)
-//GO(gtk_ruler_set_metric,
-//GO(gtk_ruler_set_range,
-GO(gtk_scale_add_mark, vFpdip)
-//GO(gtk_scale_button_get_adjustment,
+GO(gtk_ruler_set_metric, vFpu)
+GO(gtk_ruler_set_range, vFpdddd)
+GO(gtk_scale_add_mark, vFpdup)
+GO(gtk_scale_button_get_adjustment, pFp)
//GO(gtk_scale_button_get_minus_button,
-//GO(gtk_scale_button_get_orientation,
+GO(gtk_scale_button_get_orientation, uFp)
//GO(gtk_scale_button_get_plus_button,
-//GO(gtk_scale_button_get_popup,
+GO(gtk_scale_button_get_popup, pFp)
GO(gtk_scale_button_get_type, LFv)
-//GO(gtk_scale_button_get_value,
-//GO(gtk_scale_button_new,
-//GO(gtk_scale_button_set_adjustment,
-//GO(gtk_scale_button_set_icons,
-//GO(gtk_scale_button_set_orientation,
-//GO(gtk_scale_button_set_value,
+GO(gtk_scale_button_get_value, dFp)
+GO(gtk_scale_button_new, pFudddp)
+GO(gtk_scale_button_set_adjustment, vFpp)
+GO(gtk_scale_button_set_icons, vFpp)
+GO(gtk_scale_button_set_orientation, vFpu)
+GO(gtk_scale_button_set_value, vFpd)
GO(gtk_scale_clear_marks, vFp)
GO(gtk_scale_get_digits, iFp)
GO(gtk_scale_get_draw_value, iFp)
GO(gtk_scale_get_layout, pFp)
GO(gtk_scale_get_layout_offsets, vFppp)
GO(gtk_scale_get_type, LFv)
-GO(gtk_scale_get_value_pos, iFp)
+GO(gtk_scale_get_value_pos, uFp)
GO(gtk_scale_set_digits, vFpi)
GO(gtk_scale_set_draw_value, vFpi)
-GO(gtk_scale_set_value_pos, vFpi)
+GO(gtk_scale_set_value_pos, vFpu)
GO(gtk_scrollbar_get_type, LFv)
GO(gtk_scrolled_window_add_with_viewport, vFpp)
GO(gtk_scrolled_window_get_hadjustment, pFp)
GO(gtk_scrolled_window_get_hscrollbar, pFp)
-GO(gtk_scrolled_window_get_placement, iFp)
+GO(gtk_scrolled_window_get_placement, uFp)
GO(gtk_scrolled_window_get_policy, vFppp)
-GO(gtk_scrolled_window_get_shadow_type, iFp)
+GO(gtk_scrolled_window_get_shadow_type, uFp)
GO(gtk_scrolled_window_get_type, LFv)
GO(gtk_scrolled_window_get_vadjustment, pFp)
GO(gtk_scrolled_window_get_vscrollbar, pFp)
GO(gtk_scrolled_window_new, pFpp)
GO(gtk_scrolled_window_set_hadjustment, vFpp)
-GO(gtk_scrolled_window_set_placement, vFpi)
-GO(gtk_scrolled_window_set_policy, vFpii)
-GO(gtk_scrolled_window_set_shadow_type, vFpi)
+GO(gtk_scrolled_window_set_placement, vFpu)
+GO(gtk_scrolled_window_set_policy, vFpuu)
+GO(gtk_scrolled_window_set_shadow_type, vFpu)
GO(gtk_scrolled_window_set_vadjustment, vFpp)
GO(gtk_scrolled_window_unset_placement, vFp)
GO(gtk_scroll_step_get_type, LFv)
@@ -2548,7 +2548,7 @@ GOM(gtk_signal_connect_full, LFEppppppii)
//GO(gtk_signal_connect_while_alive,
//GO(gtk_signal_emit,
//GO(gtk_signal_emit_by_name,
-//GO(gtk_signal_emit_stop_by_name,
+GO(gtk_signal_emit_stop_by_name, vFpp)
//GO(gtk_signal_emitv,
//GO(gtk_signal_emitv_by_name,
//GO(gtk_signal_new,
@@ -2556,14 +2556,14 @@ GOM(gtk_signal_connect_full, LFEppppppii)
GO(gtk_signal_run_type_get_type, LFv)
GO(gtk_size_group_add_widget, vFpp)
GO(gtk_size_group_get_ignore_hidden, iFp)
-GO(gtk_size_group_get_mode, iFp)
+GO(gtk_size_group_get_mode, uFp)
GO(gtk_size_group_get_type, LFv)
GO(gtk_size_group_get_widgets, pFp)
GO(gtk_size_group_mode_get_type, LFv)
-GO(gtk_size_group_new, pFi)
+GO(gtk_size_group_new, pFu)
GO(gtk_size_group_remove_widget, vFpp)
GO(gtk_size_group_set_ignore_hidden, vFpi)
-GO(gtk_size_group_set_mode, vFpi)
+GO(gtk_size_group_set_mode, vFpu)
GO(gtk_socket_add_id, vFpp)
GO(gtk_socket_get_id, pFp)
GO(gtk_socket_get_plug_window, pFp)
@@ -2579,7 +2579,7 @@ GO(gtk_spin_button_get_numeric, iFp)
GO(gtk_spin_button_get_range, vFppp)
GO(gtk_spin_button_get_snap_to_ticks, iFp)
GO(gtk_spin_button_get_type, LFv)
-GO(gtk_spin_button_get_update_policy, iFp)
+GO(gtk_spin_button_get_update_policy, uFp)
GO(gtk_spin_button_get_value, dFp)
GO(gtk_spin_button_get_value_as_int, iFp)
GO(gtk_spin_button_get_wrap, iFp)
@@ -2591,10 +2591,10 @@ GO(gtk_spin_button_set_increments, vFpdd)
GO(gtk_spin_button_set_numeric, vFpi)
GO(gtk_spin_button_set_range, vFpdd)
GO(gtk_spin_button_set_snap_to_ticks, vFpi)
-GO(gtk_spin_button_set_update_policy, vFpi)
+GO(gtk_spin_button_set_update_policy, vFpu)
GO(gtk_spin_button_set_value, vFpd)
GO(gtk_spin_button_set_wrap, vFpi)
-GO(gtk_spin_button_spin, vFpid)
+GO(gtk_spin_button_spin, vFpud)
GO(gtk_spin_button_update, vFp)
GO(gtk_spin_button_update_policy_get_type, LFv)
GO(gtk_spinner_get_type, LFv)
@@ -2622,7 +2622,7 @@ GO(gtk_status_icon_get_pixbuf, pFp)
GO(gtk_status_icon_get_screen, pFp)
GO(gtk_status_icon_get_size, iFp)
GO(gtk_status_icon_get_stock, pFp)
-GO(gtk_status_icon_get_storage_type, iFp)
+GO(gtk_status_icon_get_storage_type, uFp)
GO(gtk_status_icon_get_title, pFp)
GO(gtk_status_icon_get_tooltip_markup, pFp)
GO(gtk_status_icon_get_tooltip_text, pFp)
@@ -2658,26 +2658,26 @@ GO(gtk_stock_item_free, vFp)
GO(gtk_stock_list_ids, pFv)
GO(gtk_stock_lookup, iFpp)
GOM(gtk_stock_set_translate_func, vFEpppp)
-GO(gtk_style_apply_default_background, vFppiipiiii)
+GO(gtk_style_apply_default_background, vFppiupiiii)
GO(gtk_style_attach, pFpp)
GO(gtk_style_copy, pFp)
GO(gtk_style_detach, vFp)
GO(gtk_style_get, vFpippppppppppp) //vaarg, wrap with gtk_style_get_valist?
GO(gtk_style_get_font, pFp)
-GO(gtk_style_get_style_property, vFpipp)
+GO(gtk_style_get_style_property, vFpLpp)
GO(gtk_style_get_type, LFv)
//GO(gtk_style_get_valist, vFpipp)
GO(gtk_style_lookup_color, iFppp)
GO(gtk_style_lookup_icon_set, pFpp)
GO(gtk_style_new, pFv)
GO(gtk_style_ref, pFp)
-GO(gtk_style_render_icon, pFppiiipp)
-GO(gtk_style_set_background, vFppi)
+GO(gtk_style_render_icon, pFppuuupp)
+GO(gtk_style_set_background, vFppu)
GO(gtk_style_set_font, vFpp)
GO(gtk_style_unref, vFp)
GO(gtk_submenu_direction_get_type, LFv)
GO(gtk_submenu_placement_get_type, LFv)
-GO(gtk_table_attach, vFppuuuuiiuu)
+GO(gtk_table_attach, vFppuuuuuuuu)
GO(gtk_table_attach_defaults, vFppuuuu)
GO(gtk_table_get_col_spacing, uFpu)
GO(gtk_table_get_default_col_spacing, uFp)
@@ -2704,7 +2704,7 @@ GO(gtk_target_list_find, iFppp)
GO(gtk_target_list_get_type, LFv)
GO(gtk_target_list_new, pFpu)
GO(gtk_target_list_ref, pFp)
-GO(gtk_target_list_remove, iFppp)
+GO(gtk_target_list_remove, vFpp)
GO(gtk_target_list_unref, vFp)
GO(gtk_targets_include_image, iFpii)
GO(gtk_targets_include_rich_text, iFpip)
@@ -2714,22 +2714,22 @@ GO(gtk_target_table_free, vFpi)
GO(gtk_target_table_new_from_list, pFpp)
GO(gtk_tearoff_menu_item_get_type, LFv)
GO(gtk_tearoff_menu_item_new, pFv)
-//GO(gtk_test_create_simple_window,
+GO(gtk_test_create_simple_window, pFpp)
//GO(gtk_test_create_widget,
//GO(gtk_test_display_button_window,
-//GO(gtk_test_find_label,
-//GO(gtk_test_find_sibling,
-//GO(gtk_test_find_widget,
+GO(gtk_test_find_label, pFpp)
+GO(gtk_test_find_sibling, pFpL)
+GO(gtk_test_find_widget, pFppL)
//GO(gtk_test_init,
-//GO(gtk_test_list_all_types,
+GO(gtk_test_list_all_types, pFp)
//GO(gtk_test_register_all_types,
-//GO(gtk_test_slider_get_value,
-//GO(gtk_test_slider_set_perc,
-//GO(gtk_test_spin_button_click,
-//GO(gtk_test_text_get,
-//GO(gtk_test_text_set,
+GO(gtk_test_slider_get_value, dFp)
+GO(gtk_test_slider_set_perc, vFpd)
+GO(gtk_test_spin_button_click, iFpui)
+GO(gtk_test_text_get, pFp)
+GO(gtk_test_text_set, vFpp)
//GO(gtk_test_widget_click,
-//GO(gtk_test_widget_send_key,
+GO(gtk_test_widget_send_key, iFpuu)
GO(gtk_text_anchored_child_set_layout, vFpp)
GO(gtk_text_attributes_copy, pFp)
GO(gtk_text_attributes_copy_values, vFpp)
@@ -2754,7 +2754,7 @@ GO(gtk_text_buffer_delete_interactive, iFpppi)
GO(gtk_text_buffer_delete_mark, vFpp)
GO(gtk_text_buffer_delete_mark_by_name, vFpp)
GO(gtk_text_buffer_delete_selection, iFpii)
-GO(gtk_text_buffer_deserialize, iFpppppup)
+GO(gtk_text_buffer_deserialize, iFpppppLp)
GO(gtk_text_buffer_deserialize_get_can_create_tags, iFpp)
GO(gtk_text_buffer_deserialize_set_can_create_tags, vFppi)
GO(gtk_text_buffer_end_user_action, vFp)
@@ -2867,7 +2867,7 @@ GO(gtk_text_iter_forward_lines, iFpi)
GO(gtk_text_iter_forward_search, iFppuppp)
GO(gtk_text_iter_forward_sentence_end, iFp)
GO(gtk_text_iter_forward_sentence_ends, iFpi)
-GO(gtk_text_iter_forward_to_end, iFp)
+GO(gtk_text_iter_forward_to_end, vFp)
GO(gtk_text_iter_forward_to_line_end, iFp)
GO(gtk_text_iter_forward_to_tag_toggle, iFpp)
GO(gtk_text_iter_forward_visible_cursor_position, iFp)
@@ -2994,14 +2994,14 @@ GO(gtk_text_tag_table_new, pFv)
GO(gtk_text_tag_table_remove, vFpp)
GO(gtk_text_thaw, vFp)
GO(gtk_text_view_add_child_at_anchor, vFppp)
-GO(gtk_text_view_add_child_in_window, vFppiii)
+GO(gtk_text_view_add_child_in_window, vFppuii)
GO(gtk_text_view_backward_display_line, iFpp)
GO(gtk_text_view_backward_display_line_start, iFpp)
GO(gtk_text_view_buffer_to_window_coords, vFpiiipp)
GO(gtk_text_view_forward_display_line, iFpp)
GO(gtk_text_view_forward_display_line_end, iFpp)
GO(gtk_text_view_get_accepts_tab, iFp)
-GO(gtk_text_view_get_border_window_size, iFpi)
+GO(gtk_text_view_get_border_window_size, iFpu)
GO(gtk_text_view_get_buffer, pFp)
GO(gtk_text_view_get_cursor_visible, iFp)
GO(gtk_text_view_get_default_attributes, pFp)
@@ -3011,7 +3011,7 @@ GO(gtk_text_view_get_indent, iFp)
GO(gtk_text_view_get_iter_at_location, vFppii)
GO(gtk_text_view_get_iter_at_position, vFpppii)
GO(gtk_text_view_get_iter_location, vFppp)
-GO(gtk_text_view_get_justification, iFp)
+GO(gtk_text_view_get_justification, uFp)
GO(gtk_text_view_get_left_margin, iFp)
GO(gtk_text_view_get_line_at_y, vFppip)
GO(gtk_text_view_get_line_yrange, vFpppp)
@@ -3024,9 +3024,9 @@ GO(gtk_text_view_get_tabs, pFp)
GO(gtk_text_view_get_type, LFv)
GO(gtk_text_view_get_vadjustment, pFp)
GO(gtk_text_view_get_visible_rect, vFpp)
-GO(gtk_text_view_get_window, pFpi)
-GO(gtk_text_view_get_window_type, iFpp)
-GO(gtk_text_view_get_wrap_mode, iFp)
+GO(gtk_text_view_get_window, pFpu)
+GO(gtk_text_view_get_window_type, uFpp)
+GO(gtk_text_view_get_wrap_mode, uFp)
GO(gtk_text_view_im_context_filter_keypress, iFpp)
GO(gtk_text_view_move_child, vFppii)
GO(gtk_text_view_move_mark_onscreen, iFpp)
@@ -3039,12 +3039,12 @@ GO(gtk_text_view_scroll_mark_onscreen, vFpp)
GO(gtk_text_view_scroll_to_iter, iFppdidd)
GO(gtk_text_view_scroll_to_mark, vFppdidd)
GO(gtk_text_view_set_accepts_tab, vFpi)
-GO(gtk_text_view_set_border_window_size, vFpii)
+GO(gtk_text_view_set_border_window_size, vFpui)
GO(gtk_text_view_set_buffer, vFpp)
GO(gtk_text_view_set_cursor_visible, vFpi)
GO(gtk_text_view_set_editable, vFpi)
GO(gtk_text_view_set_indent, vFpi)
-GO(gtk_text_view_set_justification, vFpi)
+GO(gtk_text_view_set_justification, vFpu)
GO(gtk_text_view_set_left_margin, vFpi)
GO(gtk_text_view_set_overwrite, vFpi)
GO(gtk_text_view_set_pixels_above_lines, vFpi)
@@ -3052,9 +3052,9 @@ GO(gtk_text_view_set_pixels_below_lines, vFpi)
GO(gtk_text_view_set_pixels_inside_wrap, vFpi)
GO(gtk_text_view_set_right_margin, vFpi)
GO(gtk_text_view_set_tabs, vFpp)
-GO(gtk_text_view_set_wrap_mode, vFpi)
+GO(gtk_text_view_set_wrap_mode, vFpu)
GO(gtk_text_view_starts_display_line, iFpp)
-GO(gtk_text_view_window_to_buffer_coords, vFpiiipp)
+GO(gtk_text_view_window_to_buffer_coords, vFpuiipp)
GO(gtk_text_window_type_get_type, LFv)
//GO(gtk_theme_engine_create_rc_style,
//GO(gtk_theme_engine_get,
@@ -3063,18 +3063,18 @@ GOM(gtk_timeout_add, uFEupp)
//GOM(gtk_timeout_add_full, uFuBppB)
GO(gtk_timeout_remove, vFu)
GO(gtk_tips_query_get_type, LFv)
-//GO(gtk_tips_query_new,
-//GO(gtk_tips_query_set_caller,
-//GO(gtk_tips_query_set_labels,
+GO(gtk_tips_query_new, pFv)
+GO(gtk_tips_query_set_caller, vFpp)
+GO(gtk_tips_query_set_labels, vFppp)
//GO(gtk_tips_query_start_query,
-//GO(gtk_tips_query_stop_query,
+GO(gtk_tips_query_stop_query, vFp)
//GO(gtk_toggle_action_get_active,
-//GO(gtk_toggle_action_get_draw_as_radio,
+GO(gtk_toggle_action_get_draw_as_radio, iFp)
GO(gtk_toggle_action_get_type, LFv)
-//GO(gtk_toggle_action_new,
+GO(gtk_toggle_action_new, pFpppp)
//GO(gtk_toggle_action_set_active,
-//GO(gtk_toggle_action_set_draw_as_radio,
-//GO(gtk_toggle_action_toggled,
+GO(gtk_toggle_action_set_draw_as_radio, vFpi)
+GO(gtk_toggle_action_toggled, vFp)
GO(gtk_toggle_button_get_active, iFp)
GO(gtk_toggle_button_get_inconsistent, iFp)
GO(gtk_toggle_button_get_mode, iFp)
@@ -3097,14 +3097,14 @@ GO(gtk_toolbar_append_space, vFp)
GO(gtk_toolbar_append_widget, vFpppp)
GO(gtk_toolbar_child_type_get_type, LFv)
GO(gtk_toolbar_get_drop_index, iFpii)
-GO(gtk_toolbar_get_icon_size, iFp)
+GO(gtk_toolbar_get_icon_size, uFp)
GO(gtk_toolbar_get_item_index, iFpp)
GO(gtk_toolbar_get_n_items, iFp)
GO(gtk_toolbar_get_nth_item, pFpi)
-GO(gtk_toolbar_get_orientation, iFp)
-GO(gtk_toolbar_get_relief_style, iFp)
+GO(gtk_toolbar_get_orientation, uFp)
+GO(gtk_toolbar_get_relief_style, uFp)
GO(gtk_toolbar_get_show_arrow, iFp)
-GO(gtk_toolbar_get_style, iFp)
+GO(gtk_toolbar_get_style, uFp)
GO(gtk_toolbar_get_tooltips, iFp)
GO(gtk_toolbar_get_type, LFv)
GO(gtk_toolbar_insert, vFppi)
@@ -3120,10 +3120,10 @@ GO(gtk_toolbar_prepend_space, vFp)
GO(gtk_toolbar_prepend_widget, vFpppp)
GO(gtk_toolbar_remove_space, vFpi)
GO(gtk_toolbar_set_drop_highlight_item, vFppi)
-GO(gtk_toolbar_set_icon_size, vFpi)
-GO(gtk_toolbar_set_orientation, vFpi)
+GO(gtk_toolbar_set_icon_size, vFpu)
+GO(gtk_toolbar_set_orientation, vFpu)
GO(gtk_toolbar_set_show_arrow, vFpi)
-GO(gtk_toolbar_set_style, vFpi)
+GO(gtk_toolbar_set_style, vFpu)
GO(gtk_toolbar_set_tooltips, vFpi)
GO(gtk_toolbar_space_style_get_type, LFv)
GO(gtk_toolbar_style_get_type, LFv)
@@ -3144,100 +3144,100 @@ GO(gtk_tool_button_set_label, vFpp)
GO(gtk_tool_button_set_label_widget, vFpp)
GO(gtk_tool_button_set_stock_id, vFpp)
GO(gtk_tool_button_set_use_underline, vFpi)
-//GO(gtk_tool_item_get_ellipsize_mode,
+GO(gtk_tool_item_get_ellipsize_mode, uFp)
//GO(gtk_tool_item_get_expand,
//GO(gtk_tool_item_get_homogeneous,
-//GO(gtk_tool_item_get_icon_size,
+GO(gtk_tool_item_get_icon_size, uFp)
//GO(gtk_tool_item_get_is_important,
//GO(gtk_tool_item_get_orientation,
-//GO(gtk_tool_item_get_proxy_menu_item,
-//GO(gtk_tool_item_get_relief_style,
-//GO(gtk_tool_item_get_text_alignment,
-//GO(gtk_tool_item_get_text_orientation,
-//GO(gtk_tool_item_get_text_size_group,
-//GO(gtk_tool_item_get_toolbar_style,
+GO(gtk_tool_item_get_proxy_menu_item, pFpp)
+GO(gtk_tool_item_get_relief_style, uFp)
+GO(gtk_tool_item_get_text_alignment, fFp)
+GO(gtk_tool_item_get_text_orientation, uFp)
+GO(gtk_tool_item_get_text_size_group, pFp)
+GO(gtk_tool_item_get_toolbar_style, uFp)
GO(gtk_tool_item_get_type, LFv)
//GO(gtk_tool_item_get_use_drag_window,
//GO(gtk_tool_item_get_visible_horizontal,
//GO(gtk_tool_item_get_visible_vertical,
-//GO(gtk_tool_item_group_get_collapsed,
-//GO(gtk_tool_item_group_get_drop_item,
-//GO(gtk_tool_item_group_get_ellipsize,
-//GO(gtk_tool_item_group_get_header_relief,
-//GO(gtk_tool_item_group_get_item_position,
-//GO(gtk_tool_item_group_get_label,
-//GO(gtk_tool_item_group_get_label_widget,
-//GO(gtk_tool_item_group_get_n_items,
-//GO(gtk_tool_item_group_get_nth_item,
+GO(gtk_tool_item_group_get_collapsed, iFp)
+GO(gtk_tool_item_group_get_drop_item, pFpii)
+GO(gtk_tool_item_group_get_ellipsize, uFp)
+GO(gtk_tool_item_group_get_header_relief, uFp)
+GO(gtk_tool_item_group_get_item_position, iFpp)
+GO(gtk_tool_item_group_get_label, pFp)
+GO(gtk_tool_item_group_get_label_widget, pFp)
+GO(gtk_tool_item_group_get_n_items, uFp)
+GO(gtk_tool_item_group_get_nth_item, pFpu)
GO(gtk_tool_item_group_get_type, LFv)
//GO(gtk_tool_item_group_insert,
//GO(gtk_tool_item_group_new,
-//GO(gtk_tool_item_group_set_collapsed,
-//GO(gtk_tool_item_group_set_ellipsize,
-//GO(gtk_tool_item_group_set_header_relief,
-//GO(gtk_tool_item_group_set_item_position,
-//GO(gtk_tool_item_group_set_label,
-//GO(gtk_tool_item_group_set_label_widget,
+GO(gtk_tool_item_group_set_collapsed, vFpi)
+GO(gtk_tool_item_group_set_ellipsize, vFpu)
+GO(gtk_tool_item_group_set_header_relief, vFpu)
+GO(gtk_tool_item_group_set_item_position, vFppi)
+GO(gtk_tool_item_group_set_label, vFpp)
+GO(gtk_tool_item_group_set_label_widget, vFpp)
//GO(gtk_tool_item_new,
//GO(gtk_tool_item_rebuild_menu,
-//GO(gtk_tool_item_retrieve_proxy_menu_item,
+GO(gtk_tool_item_retrieve_proxy_menu_item, pFp)
//GO(gtk_tool_item_set_expand,
//GO(gtk_tool_item_set_homogeneous,
-//GO(gtk_tool_item_set_is_important,
-//GO(gtk_tool_item_set_proxy_menu_item,
-//GO(gtk_tool_item_set_tooltip,
-//GO(gtk_tool_item_set_tooltip_markup,
+GO(gtk_tool_item_set_is_important, vFpi)
+GO(gtk_tool_item_set_proxy_menu_item, vFppp)
+GO(gtk_tool_item_set_tooltip, vFpppp)
+GO(gtk_tool_item_set_tooltip_markup, vFpp)
//GO(gtk_tool_item_set_tooltip_text,
//GO(gtk_tool_item_set_use_drag_window,
//GO(gtk_tool_item_set_visible_horizontal,
//GO(gtk_tool_item_set_visible_vertical,
-//GO(gtk_tool_item_toolbar_reconfigured,
-//GO(gtk_tool_palette_add_drag_dest,
+GO(gtk_tool_item_toolbar_reconfigured, vFp)
+GO(gtk_tool_palette_add_drag_dest, vFppuuu)
GO(gtk_tool_palette_drag_targets_get_type, LFv)
//GO(gtk_tool_palette_get_drag_item,
-//GO(gtk_tool_palette_get_drag_target_group,
+GO(gtk_tool_palette_get_drag_target_group, pFv)
//GO(gtk_tool_palette_get_drag_target_item,
-//GO(gtk_tool_palette_get_drop_group,
-//GO(gtk_tool_palette_get_drop_item,
+GO(gtk_tool_palette_get_drop_group, pFpii)
+GO(gtk_tool_palette_get_drop_item, pFpii)
//GO(gtk_tool_palette_get_exclusive,
-//GO(gtk_tool_palette_get_expand,
-//GO(gtk_tool_palette_get_group_position,
+GO(gtk_tool_palette_get_expand, iFpp)
+GO(gtk_tool_palette_get_group_position, iFpp)
//GO(gtk_tool_palette_get_hadjustment,
-//GO(gtk_tool_palette_get_icon_size,
-//GO(gtk_tool_palette_get_style,
+GO(gtk_tool_palette_get_icon_size, uFp)
+GO(gtk_tool_palette_get_style, uFp)
GO(gtk_tool_palette_get_type, LFv)
-//GO(gtk_tool_palette_get_vadjustment,
+GO(gtk_tool_palette_get_vadjustment, pFp)
//GO(gtk_tool_palette_new,
-//GO(gtk_tool_palette_set_drag_source,
+GO(gtk_tool_palette_set_drag_source, vFpu)
//GO(gtk_tool_palette_set_exclusive,
-//GO(gtk_tool_palette_set_expand,
-//GO(gtk_tool_palette_set_group_position,
-//GO(gtk_tool_palette_set_icon_size,
-//GO(gtk_tool_palette_set_style,
+GO(gtk_tool_palette_set_expand, vFppi)
+GO(gtk_tool_palette_set_group_position, vFppi)
+GO(gtk_tool_palette_set_icon_size, vFpu)
+GO(gtk_tool_palette_set_style, vFpu)
//GO(gtk_tool_palette_unset_icon_size,
-//GO(gtk_tool_palette_unset_style,
-//GO(gtk_tool_shell_get_ellipsize_mode,
-//GO(gtk_tool_shell_get_icon_size,
+GO(gtk_tool_palette_unset_style, vFp)
+GO(gtk_tool_shell_get_ellipsize_mode, uFp)
+GO(gtk_tool_shell_get_icon_size, uFp)
//GO(gtk_tool_shell_get_orientation,
-//GO(gtk_tool_shell_get_relief_style,
-//GO(gtk_tool_shell_get_style,
-//GO(gtk_tool_shell_get_text_alignment,
-//GO(gtk_tool_shell_get_text_orientation,
-//GO(gtk_tool_shell_get_text_size_group,
+GO(gtk_tool_shell_get_relief_style, uFp)
+GO(gtk_tool_shell_get_style, uFp)
+GO(gtk_tool_shell_get_text_alignment, fFp)
+GO(gtk_tool_shell_get_text_orientation, uFp)
+GO(gtk_tool_shell_get_text_size_group, pFp)
GO(gtk_tool_shell_get_type, LFv)
-//GO(gtk_tool_shell_rebuild_menu,
+GO(gtk_tool_shell_rebuild_menu, vFp)
GO(gtk_tooltip_get_type, LFv)
GO(gtk_tooltips_data_get, pFp)
GO(gtk_tooltips_disable, vFp)
GO(gtk_tooltips_enable, vFp)
-//GO(gtk_tooltip_set_custom,
-//GO(gtk_tooltip_set_icon,
-//GO(gtk_tooltip_set_icon_from_gicon,
-//GO(gtk_tooltip_set_icon_from_icon_name,
+GO(gtk_tooltip_set_custom, vFpp)
+GO(gtk_tooltip_set_icon, vFpp)
+GO(gtk_tooltip_set_icon_from_gicon, vFppu)
+GO(gtk_tooltip_set_icon_from_icon_name, vFppu)
//GO(gtk_tooltip_set_icon_from_stock,
//GO(gtk_tooltip_set_markup,
-//GO(gtk_tooltip_set_text,
-//GO(gtk_tooltip_set_tip_area,
+GO(gtk_tooltip_set_text, vFpp)
+GO(gtk_tooltip_set_tip_area, vFpp)
GO(gtk_tooltips_force_window, vFp)
GO(gtk_tooltips_get_info_from_tip_window, iFppp)
GO(gtk_tooltips_get_type, LFv)
@@ -3252,7 +3252,7 @@ GO(gtk_tray_icon_get_type, LFv)
//GO(gtk_tree_drag_dest_drag_data_received,
GO(gtk_tree_drag_dest_get_type, LFv)
//GO(gtk_tree_drag_dest_row_drop_possible,
-//GO(gtk_tree_drag_source_drag_data_delete,
+GO(gtk_tree_drag_source_drag_data_delete, iFpp)
//GO(gtk_tree_drag_source_drag_data_get,
GO(gtk_tree_drag_source_get_type, LFv)
//GO(gtk_tree_drag_source_row_draggable,
@@ -3271,23 +3271,23 @@ GO(gtk_tree_item_get_type, LFv)
GO(gtk_tree_iter_copy, pFp)
GO(gtk_tree_iter_free, vFp)
GO(gtk_tree_iter_get_type, LFv)
-//GO(gtk_tree_model_filter_clear_cache,
-//GO(gtk_tree_model_filter_convert_child_iter_to_iter,
+GO(gtk_tree_model_filter_clear_cache, vFp)
+GO(gtk_tree_model_filter_convert_child_iter_to_iter, iFppp)
//GO(gtk_tree_model_filter_convert_child_path_to_path,
-//GO(gtk_tree_model_filter_convert_iter_to_child_iter,
-//GO(gtk_tree_model_filter_convert_path_to_child_path,
-//GO(gtk_tree_model_filter_get_model,
+GO(gtk_tree_model_filter_convert_iter_to_child_iter, vFppp)
+GO(gtk_tree_model_filter_convert_path_to_child_path, pFpp)
+GO(gtk_tree_model_filter_get_model, pFp)
GO(gtk_tree_model_filter_get_type, LFv)
-//GO(gtk_tree_model_filter_new,
+GO(gtk_tree_model_filter_new, pFpp)
//GO(gtk_tree_model_filter_refilter,
//GO(gtk_tree_model_filter_set_modify_func,
-//GO(gtk_tree_model_filter_set_visible_column,
+GO(gtk_tree_model_filter_set_visible_column, vFpi)
//GO(gtk_tree_model_filter_set_visible_func,
GO(gtk_tree_model_flags_get_type, LFv)
GOM(gtk_tree_model_foreach, vFEppp)
GOM(gtk_tree_model_get, vFEppV)
-GO(gtk_tree_model_get_column_type, iFpi)
-GO(gtk_tree_model_get_flags, iFp)
+GO(gtk_tree_model_get_column_type, LFpi)
+GO(gtk_tree_model_get_flags, uFp)
GO(gtk_tree_model_get_iter, iFppp)
GO(gtk_tree_model_get_iter_first, iFpp)
GO(gtk_tree_model_get_iter_from_string, iFppp)
@@ -3317,7 +3317,7 @@ GO(gtk_tree_model_rows_reordered, vFpppp)
//GO(gtk_tree_model_sort_get_model,
GO(gtk_tree_model_sort_get_type, LFv)
//GO(gtk_tree_model_sort_iter_is_valid,
-//GO(gtk_tree_model_sort_new_with_model,
+GO(gtk_tree_model_sort_new_with_model, pFp)
//GO(gtk_tree_model_sort_reset_default_sort_func,
GO(gtk_tree_model_unref_node, vFpp)
//GO(gtk_tree_new,
@@ -3386,7 +3386,7 @@ GO(gtk_tree_sortable_get_sort_column_id, iFppp)
GO(gtk_tree_sortable_get_type, LFv)
GO(gtk_tree_sortable_has_default_sort_func, iFp)
GOM(gtk_tree_sortable_set_default_sort_func, vFEpppp)
-GO(gtk_tree_sortable_set_sort_column_id, vFpii)
+GO(gtk_tree_sortable_set_sort_column_id, vFpiu)
GOM(gtk_tree_sortable_set_sort_func, vFEpippp)
GO(gtk_tree_sortable_sort_column_changed, vFp)
GO(gtk_tree_store_append, vFppp)
@@ -3436,10 +3436,10 @@ GO(gtk_tree_view_column_get_max_width, iFp)
GO(gtk_tree_view_column_get_min_width, iFp)
GO(gtk_tree_view_column_get_reorderable, iFp)
GO(gtk_tree_view_column_get_resizable, iFp)
-GO(gtk_tree_view_column_get_sizing, iFp)
+GO(gtk_tree_view_column_get_sizing, uFp)
GO(gtk_tree_view_column_get_sort_column_id, iFp)
GO(gtk_tree_view_column_get_sort_indicator, iFp)
-GO(gtk_tree_view_column_get_sort_order, iFp)
+GO(gtk_tree_view_column_get_sort_order, uFp)
GO(gtk_tree_view_column_get_spacing, iFp)
GO(gtk_tree_view_column_get_title, pFp)
GO(gtk_tree_view_column_get_tree_view, pFp)
@@ -3463,10 +3463,10 @@ GO(gtk_tree_view_column_set_max_width, vFpi)
GO(gtk_tree_view_column_set_min_width, vFpi)
GO(gtk_tree_view_column_set_reorderable, vFpi)
GO(gtk_tree_view_column_set_resizable, vFpi)
-GO(gtk_tree_view_column_set_sizing, vFpi)
-GO(gtk_tree_view_column_set_sort_column_id, iFp)
+GO(gtk_tree_view_column_set_sizing, vFpu)
+GO(gtk_tree_view_column_set_sort_column_id, vFpi)
GO(gtk_tree_view_column_set_sort_indicator, vFpi)
-GO(gtk_tree_view_column_set_sort_order, vFpi)
+GO(gtk_tree_view_column_set_sort_order, vFpu)
GO(gtk_tree_view_column_set_spacing, vFpi)
GO(gtk_tree_view_column_set_title, vFpp)
GO(gtk_tree_view_column_set_visible, vFpi)
@@ -3481,7 +3481,7 @@ GO(gtk_tree_view_convert_widget_to_tree_coords, vFpiipp)
GO(gtk_tree_view_create_row_drag_icon, pFpp)
GO(gtk_tree_view_drop_position_get_type, LFv)
GO(gtk_tree_view_enable_model_drag_dest, vFppiu)
-GO(gtk_tree_view_enable_model_drag_source, vFpipiu)
+GO(gtk_tree_view_enable_model_drag_source, vFpupiu)
GO(gtk_tree_view_expand_all, vFp)
GO(gtk_tree_view_expand_row, iFppi)
GO(gtk_tree_view_expand_to_path, vFpp)
@@ -3497,7 +3497,7 @@ GO(gtk_tree_view_get_enable_search, iFp)
GO(gtk_tree_view_get_enable_tree_lines, iFp)
GO(gtk_tree_view_get_expander_column, pFp)
GO(gtk_tree_view_get_fixed_height_mode, iFp)
-GO(gtk_tree_view_get_grid_lines, iFp)
+GO(gtk_tree_view_get_grid_lines, uFp)
GO(gtk_tree_view_get_hadjustment, pFp)
GO(gtk_tree_view_get_headers_clickable, iFp)
GO(gtk_tree_view_get_headers_visible, iFp)
@@ -3533,7 +3533,7 @@ GO(gtk_tree_view_move_column_after, vFppp)
GO(gtk_tree_view_new, pFv)
GO(gtk_tree_view_new_with_model, pFp)
GO(gtk_tree_view_remove_column, iFpp)
-GO(gtk_tree_view_row_activated, vFp)
+GO(gtk_tree_view_row_activated, vFppp)
GO(gtk_tree_view_row_expanded, iFpp)
GO(gtk_tree_view_scroll_to_cell, vFpppiff)
GO(gtk_tree_view_scroll_to_point, vFpii)
@@ -3541,12 +3541,12 @@ GO(gtk_tree_view_scroll_to_point, vFpii)
GO(gtk_tree_view_set_cursor, vFpppi)
GO(gtk_tree_view_set_cursor_on_cell, vFppppi)
//GOM(gtk_tree_view_set_destroy_count_func, vFEpBpB)
-GO(gtk_tree_view_set_drag_dest_row, vFppi)
+GO(gtk_tree_view_set_drag_dest_row, vFppu)
GO(gtk_tree_view_set_enable_search, vFpi)
GO(gtk_tree_view_set_enable_tree_lines, vFpi)
GO(gtk_tree_view_set_expander_column, vFpp)
GO(gtk_tree_view_set_fixed_height_mode, vFpi)
-GO(gtk_tree_view_set_grid_lines, vFpi)
+GO(gtk_tree_view_set_grid_lines, vFpu)
GO(gtk_tree_view_set_hadjustment, vFpp)
GO(gtk_tree_view_set_headers_clickable, vFpi)
GO(gtk_tree_view_set_headers_visible, vFpi)
@@ -3573,22 +3573,22 @@ GO(gtk_tree_view_unset_rows_drag_source, vFp)
GO(gtk_tree_view_widget_to_tree_coords, vFpiipp)
GO(gtk_true, iFv)
GOM(gtk_type_class, pFEi)
-GO(gtk_type_enum_find_value, pFip)
-GO(gtk_type_enum_get_values, pFi)
-GO(gtk_type_flags_find_value, pFip)
-GO(gtk_type_flags_get_values, pFi)
-GO(gtk_type_init, vFi)
-GO(gtk_type_new, pFi)
+GO(gtk_type_enum_find_value, pFLp)
+GO(gtk_type_enum_get_values, pFL)
+GO(gtk_type_flags_find_value, pFLp)
+GO(gtk_type_flags_get_values, pFL)
+GO(gtk_type_init, vFu)
+GO(gtk_type_new, pFL)
GOM(gtk_type_unique, iFEpp)
-GO(gtk_ui_manager_add_ui, vFpipppii)
+GO(gtk_ui_manager_add_ui, vFpupppui)
GO(gtk_ui_manager_add_ui_from_file, uFppp)
-GO(gtk_ui_manager_add_ui_from_string, uFppLp)
+GO(gtk_ui_manager_add_ui_from_string, uFpplp)
GO(gtk_ui_manager_ensure_update, vFp)
GO(gtk_ui_manager_get_accel_group, pFp)
GO(gtk_ui_manager_get_action, pFpp)
GO(gtk_ui_manager_get_action_groups, pFp)
GO(gtk_ui_manager_get_add_tearoffs, iFp)
-GO(gtk_ui_manager_get_toplevels, pFpi)
+GO(gtk_ui_manager_get_toplevels, pFpu)
GO(gtk_ui_manager_get_type, LFv)
GO(gtk_ui_manager_get_ui, pFp)
GO(gtk_ui_manager_get_widget, pFpp)
@@ -3607,17 +3607,17 @@ GO(gtk_vbutton_box_get_layout_default, iFv)
GO(gtk_vbutton_box_get_spacing_default, iFv)
GO(gtk_vbutton_box_get_type, LFv)
GO(gtk_vbutton_box_new, pFv)
-GO(gtk_vbutton_box_set_layout_default, vFi)
+GO(gtk_vbutton_box_set_layout_default, vFu)
GO(gtk_vbutton_box_set_spacing_default, vFi)
GO(gtk_viewport_get_bin_window, pFp)
GO(gtk_viewport_get_hadjustment, pFp)
-GO(gtk_viewport_get_shadow_type, iFp)
+GO(gtk_viewport_get_shadow_type, uFp)
GO(gtk_viewport_get_type, LFv)
GO(gtk_viewport_get_vadjustment, pFp)
GO(gtk_viewport_get_view_window, pFp)
GO(gtk_viewport_new, pFpp)
GO(gtk_viewport_set_hadjustment, vFpp)
-GO(gtk_viewport_set_shadow_type, vFpi)
+GO(gtk_viewport_set_shadow_type, vFpu)
GO(gtk_viewport_set_vadjustment, vFpp)
GO(gtk_visibility_get_type, LFv)
GO(gtk_volume_button_get_type, LFv)
@@ -3658,7 +3658,7 @@ GO(gtk_widget_freeze_child_notify, vFp)
GO(gtk_widget_get_accessible, pFp)
GO(gtk_widget_get_action, pFp)
GO(gtk_widget_get_allocation, vFpp)
-GO(gtk_widget_get_ancestor, pFpi)
+GO(gtk_widget_get_ancestor, pFpL)
GO(gtk_widget_get_app_paintable, iFp)
GO(gtk_widget_get_can_default, iFp)
GO(gtk_widget_get_can_focus, iFp)
@@ -3668,14 +3668,14 @@ GO(gtk_widget_get_clipboard, pFpp)
GO(gtk_widget_get_colormap, pFp)
GO(gtk_widget_get_composite_name, pFp)
GO(gtk_widget_get_default_colormap, pFv)
-GO(gtk_widget_get_default_direction, iFv)
+GO(gtk_widget_get_default_direction, uFv)
GO(gtk_widget_get_default_style, pFv)
GO(gtk_widget_get_default_visual, pFv)
-GO(gtk_widget_get_direction, iFp)
+GO(gtk_widget_get_direction, uFp)
GO(gtk_widget_get_display, pFp)
GO(gtk_widget_get_double_buffered, iFp)
GO(gtk_widget_get_events, iFp)
-GO(gtk_widget_get_extension_events, iFp)
+GO(gtk_widget_get_extension_events, uFp)
GO(gtk_widget_get_has_tooltip, iFp)
GO(gtk_widget_get_has_window, iFp)
GO(gtk_widget_get_mapped, iFp)
@@ -3695,7 +3695,7 @@ GO(gtk_widget_get_sensitive, iFp)
GO(gtk_widget_get_settings, pFp)
GO(gtk_widget_get_size_request, vFppp)
GO(gtk_widget_get_snapshot, pFpp)
-GO(gtk_widget_get_state, iFp)
+GO(gtk_widget_get_state, uFp)
GO(gtk_widget_get_style, pFp)
GO(gtk_widget_get_tooltip_markup, pFp)
GO(gtk_widget_get_tooltip_text, pFp)
@@ -3724,12 +3724,12 @@ GO(gtk_widget_is_drawable, iFp)
GO(gtk_widget_is_focus, iFp)
GO(gtk_widget_is_sensitive, iFp)
GO(gtk_widget_is_toplevel, iFp)
-GO(gtk_widget_keynav_failed, iFpi)
+GO(gtk_widget_keynav_failed, iFpu)
GO(gtk_widget_list_accel_closures, pFp)
GO(gtk_widget_list_mnemonic_labels, pFp)
GO(gtk_widget_map, vFp)
GO(gtk_widget_mnemonic_activate, iFpi)
-GO(gtk_widget_modify_base, vFpip)
+GO(gtk_widget_modify_base, vFpup)
GO(gtk_widget_modify_bg, vFpip)
GO(gtk_widget_modify_cursor, vFppp)
GO(gtk_widget_modify_fg, vFpip)
@@ -3753,7 +3753,7 @@ GO(gtk_widget_ref, pFp)
GO(gtk_widget_region_intersect, pFpp)
GO(gtk_widget_remove_accelerator, iFppui)
GO(gtk_widget_remove_mnemonic_label, vFpp)
-GO(gtk_widget_render_icon, pFppip)
+GO(gtk_widget_render_icon, pFppup)
GO(gtk_widget_reparent, vFpp)
GO(gtk_widget_reset_rc_styles, vFp)
GO(gtk_widget_reset_shapes, vFp)
@@ -3769,11 +3769,11 @@ GO(gtk_widget_set_child_visible, vFpi)
GO(gtk_widget_set_colormap, vFpp)
GO(gtk_widget_set_composite_name, vFpp)
GO(gtk_widget_set_default_colormap, vFp)
-GO(gtk_widget_set_default_direction, vFi)
-GO(gtk_widget_set_direction, vFpi)
+GO(gtk_widget_set_default_direction, vFu)
+GO(gtk_widget_set_direction, vFpu)
GO(gtk_widget_set_double_buffered, vFpi)
GO(gtk_widget_set_events, vFpi)
-GO(gtk_widget_set_extension_events, vFpi)
+GO(gtk_widget_set_extension_events, vFpu)
GO(gtk_widget_set_has_tooltip, vFpi)
GO(gtk_widget_set_has_window, vFpi)
GO(gtk_widget_set_mapped, vFpi)
@@ -3787,7 +3787,7 @@ GO(gtk_widget_set_redraw_on_allocate, vFpi)
GO(gtk_widget_set_scroll_adjustments, iFppp)
GO(gtk_widget_set_sensitive, vFpi)
GO(gtk_widget_set_size_request, vFpii)
-GO(gtk_widget_set_state, vFpi)
+GO(gtk_widget_set_state, vFpu)
GO(gtk_widget_set_style, vFpp)
GO(gtk_widget_set_tooltip_markup, vFpp)
GO(gtk_widget_set_tooltip_text, vFpp)
@@ -3834,13 +3834,13 @@ GO(gtk_window_get_destroy_with_parent, iFp)
GO(gtk_window_get_focus, pFp)
GO(gtk_window_get_focus_on_map, iFp)
GO(gtk_window_get_frame_dimensions, vFppppp)
-GO(gtk_window_get_gravity, iFp)
+GO(gtk_window_get_gravity, uFp)
GO(gtk_window_get_group, pFp)
GO(gtk_window_get_has_frame, iFp)
GO(gtk_window_get_icon, pFp)
GO(gtk_window_get_icon_list, pFp)
GO(gtk_window_get_icon_name, pFp)
-GO(gtk_window_get_mnemonic_modifier, iFp)
+GO(gtk_window_get_mnemonic_modifier, uFp)
GO(gtk_window_get_mnemonics_visible, iFp)
GO(gtk_window_get_modal, iFp)
GO(gtk_window_get_opacity, dFp)
@@ -3854,7 +3854,7 @@ GO(gtk_window_get_skip_taskbar_hint, iFp)
GO(gtk_window_get_title, pFp)
GO(gtk_window_get_transient_for, pFp)
GO(gtk_window_get_type, LFv)
-GO(gtk_window_get_type_hint, iFp)
+GO(gtk_window_get_type_hint, uFp)
GO(gtk_window_get_urgency_hint, iFp)
GO(gtk_window_get_window_type, uFp)
GO(gtk_window_group_add_window, vFpp)
@@ -3871,7 +3871,7 @@ GO(gtk_window_list_toplevels, pFv)
GO(gtk_window_maximize, vFp)
GO(gtk_window_mnemonic_activate, iFpui)
GO(gtk_window_move, vFpii)
-GO(gtk_window_new, pFi)
+GO(gtk_window_new, pFu)
GO(gtk_window_parse_geometry, iFpp)
GO(gtk_window_position_get_type, LFv)
GO(gtk_window_present, vFp)
@@ -3896,8 +3896,8 @@ GO(gtk_window_set_destroy_with_parent, vFpi)
GO(gtk_window_set_focus, vFpp)
GO(gtk_window_set_focus_on_map, vFpi)
GO(gtk_window_set_frame_dimensions, vFpiiii)
-GO(gtk_window_set_geometry_hints, vFpppi)
-GO(gtk_window_set_gravity, vFpi)
+GO(gtk_window_set_geometry_hints, vFpppu)
+GO(gtk_window_set_gravity, vFpu)
GO(gtk_window_set_has_frame, vFpi)
GO(gtk_window_set_icon, vFpp)
GO(gtk_window_set_icon_from_file, iFppp)
@@ -3905,12 +3905,12 @@ GO(gtk_window_set_icon_list, vFpp)
GO(gtk_window_set_icon_name, vFpp)
GO(gtk_window_set_keep_above, vFpi)
GO(gtk_window_set_keep_below, vFpi)
-GO(gtk_window_set_mnemonic_modifier, vFpi)
+GO(gtk_window_set_mnemonic_modifier, vFpu)
GO(gtk_window_set_mnemonics_visible, vFpi)
GO(gtk_window_set_modal, vFpi)
GO(gtk_window_set_opacity, vFpd)
GO(gtk_window_set_policy, vFpiii)
-GO(gtk_window_set_position, vFpi)
+GO(gtk_window_set_position, vFpu)
GO(gtk_window_set_resizable, vFpi)
GO(gtk_window_set_role, vFpp)
GO(gtk_window_set_screen, vFpp)
@@ -3919,7 +3919,7 @@ GO(gtk_window_set_skip_taskbar_hint, vFpi)
GO(gtk_window_set_startup_id, vFpp)
GO(gtk_window_set_title, vFpp)
GO(gtk_window_set_transient_for, vFpp)
-GO(gtk_window_set_type_hint, vFpi)
+GO(gtk_window_set_type_hint, vFpu)
GO(gtk_window_set_urgency_hint, vFpi)
GO(gtk_window_set_wmclass, vFppp)
GO(gtk_window_stick, vFp)
diff --git a/src/wrapped/wrappedicui18n67.c b/src/wrapped/wrappedicui18n67.c
new file mode 100644
index 0000000..13630f3
--- /dev/null
+++ b/src/wrapped/wrappedicui18n67.c
@@ -0,0 +1,29 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#define _GNU_SOURCE /* See feature_test_macros(7) */
+#include <dlfcn.h>
+
+#include "wrappedlibs.h"
+
+#include "debug.h"
+#include "wrapper.h"
+#include "bridge.h"
+#include "librarian/library_private.h"
+#include "x64emu.h"
+#include "emu/x64emu_private.h"
+#include "callback.h"
+#include "librarian.h"
+#include "box64context.h"
+#include "emu/x64emu_private.h"
+#include "myalign.h"
+
+const char* icui18n67Name = "libicui18n.so.67";
+#define LIBNAME icui18n67
+
+#define CUSTOM_INIT \
+ SETALT(my67_); \
+ setNeededLibs(lib, 1, "libicuuc.so.67");
+
+#include "wrappedlib_init.h"
+
diff --git a/src/wrapped/wrappedicui18n67_private.h b/src/wrapped/wrappedicui18n67_private.h
new file mode 100644
index 0000000..431164b
--- /dev/null
+++ b/src/wrapped/wrappedicui18n67_private.h
@@ -0,0 +1,100 @@
+#if !(defined(GO) && defined(GOM) && defined(GO2) && defined(DATA))
+#error meh!
+#endif
+
+GO(ucal_add_67, vFpiip)
+GO(ucal_clear_67, vFp)
+GO(ucal_clearField_67, vFpi)
+GO(ucal_clone_67, pFpp)
+GO(ucal_close_67, vFp)
+GO(ucal_countAvailable_67, iFv)
+GO(ucal_equivalentTo_67, cFpp)
+GO(ucal_get_67, iFpip)
+GO(ucal_getAttribute_67, iFpi)
+GO(ucal_getAvailable_67, pFi)
+GO(ucal_getCanonicalTimeZoneID_67, iFpipipp)
+GO(ucal_getDayOfWeekType_67, iFpip)
+GO(ucal_getDefaultTimeZone_67, iFpip)
+GO(ucal_getDSTSavings_67, iFpp)
+GO(ucal_getFieldDifference_67, iFpdip)
+GO(ucal_getGregorianChange_67, dFpp)
+GO(ucal_getHostTimeZone_67, iFpip)
+GO(ucal_getKeywordValuesForLocale_67, pFppCp)
+GO(ucal_getLimit_67, iFpiip)
+GO(ucal_getLocaleByType_67, pFpip)
+GO(ucal_getMillis_67, dFpp)
+GO(ucal_getNow_67, dFv)
+GO(ucal_getTimeZoneDisplayName_67, iFpippip)
+GO(ucal_getTimeZoneID_67, iFppip)
+GO(ucal_getTimeZoneIDForWindowsID_67, iFpippip)
+GO(ucal_getTimeZoneOffsetFromLocal_67, vFpiippp)
+GO(ucal_getTimeZoneTransitionDate_67, cFpipp)
+GO(ucal_getType_67, pFpp)
+GO(ucal_getTZDataVersion_67, pFp)
+GO(ucal_getWeekendTransition_67, iFpip)
+GO(ucal_getWindowsTimeZoneID_67, iFpipip)
+GO(ucal_inDaylightTime_67, cFpp)
+GO(ucal_isSet_67, cFpi)
+GO(ucal_isWeekend_67, cFpdp)
+GO(ucal_open_67, pFpipip)
+GO(ucal_openCountryTimeZones_67, pFpp)
+GO(ucal_openTimeZoneIDEnumeration_67, pFippp)
+GO(ucal_openTimeZones_67, pFp)
+GO(ucal_roll_67, vFpiip)
+GO(ucal_set_67, vFpii)
+GO(ucal_setAttribute_67, vFpii)
+GO(ucal_setDate_67, vFpiiip)
+GO(ucal_setDateTime_67, vFpiiiiiip)
+GO(ucal_setDefaultTimeZone_67, vFpp)
+GO(ucal_setGregorianChange_67, vFpdp)
+GO(ucal_setMillis_67, vFpdp)
+GO(ucal_setTimeZone_67, vFppip)
+
+GO(ucol_clone_67, pFpp)
+GO(ucol_close_67, vFp)
+GO(ucol_closeElements_67, vFp)
+GO(ucol_setMaxVariable_67, vFpip)
+GO(ucol_getOffset_67, iFp)
+GO(ucol_getRules_67, pFpp)
+GO(ucol_getSortKey_67, iFppipi)
+GO(ucol_getStrength_67, iFp)
+GO(ucol_getVersion_67, vFpp)
+GO(ucol_next_67, iFpp)
+GO(ucol_previous_67, iFpp)
+GO(ucol_open_67, pFpp)
+GO(ucol_openElements_67, pFppip)
+GO(ucol_openRules_67, pFpiiipp)
+GO(ucol_safeClone_67, pFpppp)
+GO(ucol_setAttribute_67, vFpiip)
+GO(ucol_setVariableTop_67, uFppip)
+GO(ucol_strcoll_67, iFppipi)
+
+GO(udat_close_67, vFp)
+GO(udat_countSymbols_67, iFpi)
+GO(udat_getSymbols_67, iFpiipip)
+GO(udat_format_67, iFpdpipp)
+GO(udat_open_67, pFiippipip)
+GO(udat_setCalendar_67, vFpp)
+GO(udat_toPattern_67, iFpCpip)
+
+GO(unum_close_67, vFp)
+GO(unum_getAttribute_67, iFpi)
+GO(unum_getSymbol_67, iFpipip)
+GO(unum_open_67, pFipippp)
+GO(unum_toPattern_67, iFpCpip)
+
+GO(udatpg_close_67, vFp)
+GO(udatpg_getBestPattern_67, iFppipip)
+GO(udatpg_open_67, pFpp)
+
+GO(ulocdata_getCLDRVersion_67, vFpp)
+GO(ulocdata_getMeasurementSystem_67, iFpp)
+
+GO(usearch_close_67, vFp)
+GO(usearch_first_67, iFpp)
+GO(usearch_getBreakIterator_67, pFp)
+GO(usearch_getMatchedLength_67, iFp)
+GO(usearch_last_67, iFpp)
+GO(usearch_openFromCollator_67, pFpipippp)
+GO(usearch_setPattern_67, vFppip)
+GO(usearch_setText_67, vFppip)
diff --git a/src/wrapped/wrappedicui18n72.c b/src/wrapped/wrappedicui18n72.c
new file mode 100644
index 0000000..7a39dd1
--- /dev/null
+++ b/src/wrapped/wrappedicui18n72.c
@@ -0,0 +1,29 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#define _GNU_SOURCE /* See feature_test_macros(7) */
+#include <dlfcn.h>
+
+#include "wrappedlibs.h"
+
+#include "debug.h"
+#include "wrapper.h"
+#include "bridge.h"
+#include "librarian/library_private.h"
+#include "x64emu.h"
+#include "emu/x64emu_private.h"
+#include "callback.h"
+#include "librarian.h"
+#include "box64context.h"
+#include "emu/x64emu_private.h"
+#include "myalign.h"
+
+const char* icui18n72Name = "libicui18n.so.72";
+#define LIBNAME icui18n72
+
+#define CUSTOM_INIT \
+ SETALT(my72_); \
+ setNeededLibs(lib, 1, "libicuuc.so.72");
+
+#include "wrappedlib_init.h"
+
diff --git a/src/wrapped/wrappedicui18n72_private.h b/src/wrapped/wrappedicui18n72_private.h
new file mode 100644
index 0000000..351b7e6
--- /dev/null
+++ b/src/wrapped/wrappedicui18n72_private.h
@@ -0,0 +1,103 @@
+#if !(defined(GO) && defined(GOM) && defined(GO2) && defined(DATA))
+#error meh!
+#endif
+
+// UDate is double
+// UBool is int8_t
+
+GO(ucal_add_72, vFpiip)
+GO(ucal_clear_72, vFp)
+GO(ucal_clearField_72, vFpi)
+GO(ucal_clone_72, pFpp)
+GO(ucal_close_72, vFp)
+GO(ucal_countAvailable_72, iFv)
+GO(ucal_equivalentTo_72, cFpp)
+GO(ucal_get_72, iFpip)
+GO(ucal_getAttribute_72, iFpi)
+GO(ucal_getAvailable_72, pFi)
+GO(ucal_getCanonicalTimeZoneID_72, iFpipipp)
+GO(ucal_getDayOfWeekType_72, iFpip)
+GO(ucal_getDefaultTimeZone_72, iFpip)
+GO(ucal_getDSTSavings_72, iFpp)
+GO(ucal_getFieldDifference_72, iFpdip)
+GO(ucal_getGregorianChange_72, dFpp)
+GO(ucal_getHostTimeZone_72, iFpip)
+GO(ucal_getKeywordValuesForLocale_72, pFppCp)
+GO(ucal_getLimit_72, iFpiip)
+GO(ucal_getLocaleByType_72, pFpip)
+GO(ucal_getMillis_72, dFpp)
+GO(ucal_getNow_72, dFv)
+GO(ucal_getTimeZoneDisplayName_72, iFpippip)
+GO(ucal_getTimeZoneID_72, iFppip)
+GO(ucal_getTimeZoneIDForWindowsID_72, iFpippip)
+GO(ucal_getTimeZoneOffsetFromLocal_72, vFpiippp)
+GO(ucal_getTimeZoneTransitionDate_72, cFpipp)
+GO(ucal_getType_72, pFpp)
+GO(ucal_getTZDataVersion_72, pFp)
+GO(ucal_getWeekendTransition_72, iFpip)
+GO(ucal_getWindowsTimeZoneID_72, iFpipip)
+GO(ucal_inDaylightTime_72, cFpp)
+GO(ucal_isSet_72, cFpi)
+GO(ucal_isWeekend_72, cFpdp)
+GO(ucal_open_72, pFpipip)
+GO(ucal_openCountryTimeZones_72, pFpp)
+GO(ucal_openTimeZoneIDEnumeration_72, pFippp)
+GO(ucal_openTimeZones_72, pFp)
+GO(ucal_roll_72, vFpiip)
+GO(ucal_set_72, vFpii)
+GO(ucal_setAttribute_72, vFpii)
+GO(ucal_setDate_72, vFpiiip)
+GO(ucal_setDateTime_72, vFpiiiiiip)
+GO(ucal_setDefaultTimeZone_72, vFpp)
+GO(ucal_setGregorianChange_72, vFpdp)
+GO(ucal_setMillis_72, vFpdp)
+GO(ucal_setTimeZone_72, vFppip)
+
+GO(ucol_clone_72, pFpp)
+GO(ucol_close_72, vFp)
+GO(ucol_closeElements_72, vFp)
+GO(ucol_setMaxVariable_72, vFpip)
+GO(ucol_getOffset_72, iFp)
+GO(ucol_getRules_72, pFpp)
+GO(ucol_getSortKey_72, iFppipi)
+GO(ucol_getStrength_72, iFp)
+GO(ucol_getVersion_72, vFpp)
+GO(ucol_next_72, iFpp)
+GO(ucol_previous_72, iFpp)
+GO(ucol_open_72, pFpp)
+GO(ucol_openElements_72, pFppip)
+GO(ucol_openRules_72, pFpiiipp)
+GO(ucol_safeClone_72, pFpppp)
+GO(ucol_setAttribute_72, vFpiip)
+GO(ucol_setVariableTop_72, uFppip)
+GO(ucol_strcoll_72, iFppipi)
+
+GO(udat_close_72, vFp)
+GO(udat_countSymbols_72, iFpi)
+GO(udat_getSymbols_72, iFpiipip)
+GO(udat_format_72, iFpdpipp)
+GO(udat_open_72, pFiippipip)
+GO(udat_setCalendar_72, vFpp)
+GO(udat_toPattern_72, iFpCpip)
+
+GO(unum_close_72, vFp)
+GO(unum_getAttribute_72, iFpi)
+GO(unum_getSymbol_72, iFpipip)
+GO(unum_open_72, pFipippp)
+GO(unum_toPattern_72, iFpCpip)
+
+GO(udatpg_close_72, vFp)
+GO(udatpg_getBestPattern_72, iFppipip)
+GO(udatpg_open_72, pFpp)
+
+GO(ulocdata_getCLDRVersion_72, vFpp)
+GO(ulocdata_getMeasurementSystem_72, iFpp)
+
+GO(usearch_close_72, vFp)
+GO(usearch_first_72, iFpp)
+GO(usearch_getBreakIterator_72, pFp)
+GO(usearch_getMatchedLength_72, iFp)
+GO(usearch_last_72, iFpp)
+GO(usearch_openFromCollator_72, pFpipippp)
+GO(usearch_setPattern_72, vFppip)
+GO(usearch_setText_72, vFppip)
diff --git a/src/wrapped/wrappedicuuc67.c b/src/wrapped/wrappedicuuc67.c
new file mode 100644
index 0000000..a2c2cb4
--- /dev/null
+++ b/src/wrapped/wrappedicuuc67.c
@@ -0,0 +1,28 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#define _GNU_SOURCE /* See feature_test_macros(7) */
+#include <dlfcn.h>
+
+#include "wrappedlibs.h"
+
+#include "debug.h"
+#include "wrapper.h"
+#include "bridge.h"
+#include "librarian/library_private.h"
+#include "x64emu.h"
+#include "emu/x64emu_private.h"
+#include "callback.h"
+#include "librarian.h"
+#include "box64context.h"
+#include "emu/x64emu_private.h"
+#include "myalign.h"
+
+const char* icuuc67Name = "libicuuc.so.67";
+#define LIBNAME icuuc67
+
+#define CUSTOM_INIT \
+ SETALT(my67_); \
+
+#include "wrappedlib_init.h"
+
diff --git a/src/wrapped/wrappedicuuc67_private.h b/src/wrapped/wrappedicuuc67_private.h
new file mode 100644
index 0000000..276342d
--- /dev/null
+++ b/src/wrapped/wrappedicuuc67_private.h
@@ -0,0 +1,86 @@
+#if !(defined(GO) && defined(GOM) && defined(GO2) && defined(DATA))
+#error meh!
+#endif
+
+GO(ubrk_clone_67, pFpp)
+GO(ubrk_close_67, vFp)
+GO(ubrk_countAvailable_67, iFv)
+GO(ubrk_current_67, iFp)
+GO(ubrk_first_67, iFp)
+GO(ubrk_following_67, iFpi)
+GO(ubrk_getAvailable_67, pFi)
+GO(ubrk_getBinaryRules_67, iFppip)
+GO(ubrk_getLocaleByType_67, pFpip)
+GO(ubrk_getRuleStatus_67, iFp)
+GO(ubrk_getRuleStatusVec_67, iFppip)
+GO(ubrk_isBoundary_67, cFpi)
+GO(ubrk_last_67, iFp)
+GO(ubrk_next_67, iFp)
+GO(ubrk_open_67, pFppip)
+GO(ubrk_openBinaryRules_67, pFpipip)
+GO(ubrk_openRules_67, pFpipipp)
+GO(ubrk_preceding_67, iFpi)
+GO(ubrk_previous_67, iFp)
+GO(ubrk_refreshUText_67, vFppp)
+GO(ubrk_safeClone_67, pFpppp)
+GO(ubrk_setText_67, vFppip)
+GO(ubrk_setUText_67, vFppp)
+GO(ubrk_swap_67, iFppipp)
+
+GO(ucurr_forLocale_67, iFppip)
+GO(ucurr_getName_67, pFppippp)
+
+GO(uloc_canonicalize_67, iFppip)
+GO(uloc_countAvailable_67, iFv)
+GO(uloc_getAvailable_67, pFi)
+GO(uloc_getBaseName_67, iFppip)
+GO(uloc_getCharacterOrientation_67, iFpp)
+GO(uloc_getCountry_67, iFppip)
+GO(uloc_getDefault_67, pFv)
+GO(uloc_getDisplayCountry_67, iFpppip)
+GO(uloc_getDisplayLanguage_67, iFpppip)
+GO(uloc_getDisplayName_67, iFpppip)
+GO(uloc_getISO3Country_67, pFp)
+GO(uloc_getISO3Language_67, pFp)
+GO(uloc_getKeywordValue_67, iFpppip)
+GO(uloc_getLanguage_67, iFppip)
+GO(uloc_getLCID_67, uFp)
+GO(uloc_getName_67, iFppip)
+GO(uloc_getParent_67, iFppip)
+GO(uloc_setKeywordValue_67, iFpppip)
+
+GO(ures_close_67, vFp)
+GO(ures_getByKey_67, pFpppp)
+GO(ures_getSize_67, iFp)
+GO(ures_getStringByIndex_67, pFpipp)
+GO(ures_open_67, pFppp)
+
+GO(uldn_close_67, vFp)
+GO(uldn_keyValueDisplayName_67, iFppppip)
+GO(uldn_open_67, pFpip)
+
+GO(uenum_close_67, vFp)
+GO(uenum_count_67, iFpp)
+GO(uenum_next_67, pFppp)
+
+GO(uidna_close_67, vFp)
+GO(uidna_nameToASCII_67, iFppipipp)
+GO(uidna_nameToUnicode_67, iFppipipp)
+GO(uidna_openUTS46_67, pFpp)
+
+GO(unorm2_getNFCInstance_67, pFp)
+GO(unorm2_getNFDInstance_67, pFp)
+GO(unorm2_getNFKCInstance_67, pFp)
+GO(unorm2_getNFKDInstance_67, pFp)
+GO(unorm2_isNormalized_67, CFppip)
+GO(unorm2_normalize_67, iFppipip)
+
+GO(u_charsToUChars_67, vFppi)
+GO(u_getVersion_67, vFp)
+GO(u_strcmp_67, iFpp)
+GO(u_strcpy_67, pFpp)
+GO(u_strlen_67, iFp)
+GO(u_strncpy_67, pFppi)
+GO(u_tolower_67, uFu)
+GO(u_toupper_67, uFu)
+GO(u_uastrncpy_67, pFppi)
diff --git a/src/wrapped/wrappedicuuc72.c b/src/wrapped/wrappedicuuc72.c
new file mode 100644
index 0000000..6582780
--- /dev/null
+++ b/src/wrapped/wrappedicuuc72.c
@@ -0,0 +1,28 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#define _GNU_SOURCE /* See feature_test_macros(7) */
+#include <dlfcn.h>
+
+#include "wrappedlibs.h"
+
+#include "debug.h"
+#include "wrapper.h"
+#include "bridge.h"
+#include "librarian/library_private.h"
+#include "x64emu.h"
+#include "emu/x64emu_private.h"
+#include "callback.h"
+#include "librarian.h"
+#include "box64context.h"
+#include "emu/x64emu_private.h"
+#include "myalign.h"
+
+const char* icuuc72Name = "libicuuc.so.72";
+#define LIBNAME icuuc72
+
+#define CUSTOM_INIT \
+ SETALT(my72_); \
+
+#include "wrappedlib_init.h"
+
diff --git a/src/wrapped/wrappedicuuc72_private.h b/src/wrapped/wrappedicuuc72_private.h
new file mode 100644
index 0000000..99d2dd8
--- /dev/null
+++ b/src/wrapped/wrappedicuuc72_private.h
@@ -0,0 +1,86 @@
+#if !(defined(GO) && defined(GOM) && defined(GO2) && defined(DATA))
+#error meh!
+#endif
+
+GO(ubrk_clone_72, pFpp)
+GO(ubrk_close_72, vFp)
+GO(ubrk_countAvailable_72, iFv)
+GO(ubrk_current_72, iFp)
+GO(ubrk_first_72, iFp)
+GO(ubrk_following_72, iFpi)
+GO(ubrk_getAvailable_72, pFi)
+GO(ubrk_getBinaryRules_72, iFppip)
+GO(ubrk_getLocaleByType_72, pFpip)
+GO(ubrk_getRuleStatus_72, iFp)
+GO(ubrk_getRuleStatusVec_72, iFppip)
+GO(ubrk_isBoundary_72, cFpi)
+GO(ubrk_last_72, iFp)
+GO(ubrk_next_72, iFp)
+GO(ubrk_open_72, pFppip)
+GO(ubrk_openBinaryRules_72, pFpipip)
+GO(ubrk_openRules_72, pFpipipp)
+GO(ubrk_preceding_72, iFpi)
+GO(ubrk_previous_72, iFp)
+GO(ubrk_refreshUText_72, vFppp)
+GO(ubrk_safeClone_72, pFpppp)
+GO(ubrk_setText_72, vFppip)
+GO(ubrk_setUText_72, vFppp)
+GO(ubrk_swap_72, iFppipp)
+
+GO(ucurr_forLocale_72, iFppip)
+GO(ucurr_getName_72, pFppippp)
+
+GO(uloc_canonicalize_72, iFppip)
+GO(uloc_countAvailable_72, iFv)
+GO(uloc_getAvailable_72, pFi)
+GO(uloc_getBaseName_72, iFppip)
+GO(uloc_getCharacterOrientation_72, iFpp)
+GO(uloc_getCountry_72, iFppip)
+GO(uloc_getDefault_72, pFv)
+GO(uloc_getDisplayCountry_72, iFpppip)
+GO(uloc_getDisplayLanguage_72, iFpppip)
+GO(uloc_getDisplayName_72, iFpppip)
+GO(uloc_getISO3Country_72, pFp)
+GO(uloc_getISO3Language_72, pFp)
+GO(uloc_getKeywordValue_72, iFpppip)
+GO(uloc_getLanguage_72, iFppip)
+GO(uloc_getLCID_72, uFp)
+GO(uloc_getName_72, iFppip)
+GO(uloc_getParent_72, iFppip)
+GO(uloc_setKeywordValue_72, iFpppip)
+
+GO(ures_close_72, vFp)
+GO(ures_getByKey_72, pFpppp)
+GO(ures_getSize_72, iFp)
+GO(ures_getStringByIndex_72, pFpipp)
+GO(ures_open_72, pFppp)
+
+GO(uldn_close_72, vFp)
+GO(uldn_keyValueDisplayName_72, iFppppip)
+GO(uldn_open_72, pFpip)
+
+GO(uenum_close_72, vFp)
+GO(uenum_count_72, iFpp)
+GO(uenum_next_72, pFppp)
+
+GO(uidna_close_72, vFp)
+GO(uidna_nameToASCII_72, iFppipipp)
+GO(uidna_nameToUnicode_72, iFppipipp)
+GO(uidna_openUTS46_72, pFpp)
+
+GO(unorm2_getNFCInstance_72, pFp)
+GO(unorm2_getNFDInstance_72, pFp)
+GO(unorm2_getNFKCInstance_72, pFp)
+GO(unorm2_getNFKDInstance_72, pFp)
+GO(unorm2_isNormalized_72, CFppip)
+GO(unorm2_normalize_72, iFppipip)
+
+GO(u_charsToUChars_72, vFppi)
+GO(u_getVersion_72, vFp)
+GO(u_strcmp_72, iFpp)
+GO(u_strcpy_72, pFpp)
+GO(u_strlen_72, iFp)
+GO(u_strncpy_72, pFppi)
+GO(u_tolower_72, uFu)
+GO(u_toupper_72, uFu)
+GO(u_uastrncpy_72, pFppi)
diff --git a/src/wrapped/wrappedkrb5.c b/src/wrapped/wrappedkrb5.c
index 2641981..abad8c5 100755..100644
--- a/src/wrapped/wrappedkrb5.c
+++ b/src/wrapped/wrappedkrb5.c
@@ -34,10 +34,10 @@ GO(4)
// krb5_prompter ...
#define GO(A) \
-static uintptr_t my_krb5_prompter_fct_##A = 0; \
-static int my_krb5_prompter_##A(void* a, void* b, void* c, void* d, int e, void* f) \
-{ \
- return RunFunction(my_context, my_krb5_prompter_fct_##A, 6, a, b, c, d, e, f); \
+static uintptr_t my_krb5_prompter_fct_##A = 0; \
+static int my_krb5_prompter_##A(void* a, void* b, void* c, void* d, int e, void* f) \
+{ \
+ return RunFunctionFmt(my_krb5_prompter_fct_##A, "ppppip", a, b, c, d, e, f); \
}
SUPER()
#undef GO
diff --git a/src/wrapped/wrappedkrb5_private.h b/src/wrapped/wrappedkrb5_private.h
index d06e984..d06e984 100755..100644
--- a/src/wrapped/wrappedkrb5_private.h
+++ b/src/wrapped/wrappedkrb5_private.h
diff --git a/src/wrapped/wrappedlber.c b/src/wrapped/wrappedlber.c
index 16eefc5..16eefc5 100755..100644
--- a/src/wrapped/wrappedlber.c
+++ b/src/wrapped/wrappedlber.c
diff --git a/src/wrapped/wrappedlber_private.h b/src/wrapped/wrappedlber_private.h
index 4f1b1d1..4f1b1d1 100755..100644
--- a/src/wrapped/wrappedlber_private.h
+++ b/src/wrapped/wrappedlber_private.h
diff --git a/src/wrapped/wrappedldapr.c b/src/wrapped/wrappedldapr.c
index 7b5087e..fbaee98 100755..100644
--- a/src/wrapped/wrappedldapr.c
+++ b/src/wrapped/wrappedldapr.c
@@ -41,10 +41,10 @@ GO(4)
// LDAP_SASL_INTERACT_PROC ...
#define GO(A) \
-static uintptr_t my_LDAP_SASL_INTERACT_PROC_fct_##A = 0; \
-static int my_LDAP_SASL_INTERACT_PROC_##A(void* a, unsigned b, void* c, void* d) \
-{ \
- return RunFunction(my_context, my_LDAP_SASL_INTERACT_PROC_fct_##A, 4, a, b, c, d); \
+static uintptr_t my_LDAP_SASL_INTERACT_PROC_fct_##A = 0; \
+static int my_LDAP_SASL_INTERACT_PROC_##A(void* a, unsigned b, void* c, void* d) \
+{ \
+ return RunFunctionFmt(my_LDAP_SASL_INTERACT_PROC_fct_##A, "pupp", a, b, c, d); \
}
SUPER()
#undef GO
diff --git a/src/wrapped/wrappedldapr_private.h b/src/wrapped/wrappedldapr_private.h
index 97ae8fe..97ae8fe 100755..100644
--- a/src/wrapped/wrappedldapr_private.h
+++ b/src/wrapped/wrappedldapr_private.h
diff --git a/src/wrapped/wrappedldlinux.c b/src/wrapped/wrappedldlinux.c
index d88c10c..83245e9 100755..100644
--- a/src/wrapped/wrappedldlinux.c
+++ b/src/wrapped/wrappedldlinux.c
@@ -14,6 +14,7 @@
#include "emu/x64emu_private.h"
#include "elfloader.h"
#include "box64context.h"
+#include "x64tls.h"
typedef struct my_tls_s {
unsigned long int i;
@@ -23,8 +24,14 @@ typedef struct my_tls_s {
EXPORT void* my___tls_get_addr(void* p)
{
my_tls_t *t = (my_tls_t*)p;
- void* ret = (void*)((char*)GetTLSPointer(my_context, my_context->elfs[t->i])+t->o);
- return ret;
+ tlsdatasize_t* ptr = getTLSData(my_context);
+ return ptr->data+GetTLSBase(my_context->elfs[t->i])+t->o;
+}
+
+EXPORT void* my___libc_stack_end;
+void stSetup(box64context_t* context)
+{
+ my___libc_stack_end = context->stack; // is this the end, or should I add stasz?
}
// don't try to load the actual ld-linux (because name is variable), just use box64 itself, as it's linked to ld-linux
@@ -36,6 +43,9 @@ const char* ldlinuxName = "ld-linux.so.2";
lib->w.lib = dlopen(NULL, RTLD_LAZY | RTLD_GLOBAL); \
else
+#define CUSTOM_INIT \
+ stSetup(box64); \
+
// define all standard library functions
#include "wrappedlib_init.h"
diff --git a/src/wrapped/wrappedldlinux_private.h b/src/wrapped/wrappedldlinux_private.h
index 7b863d1..9bdcccb 100755..100644
--- a/src/wrapped/wrappedldlinux_private.h
+++ b/src/wrapped/wrappedldlinux_private.h
@@ -14,7 +14,7 @@
// _dl_rtld_di_serinfo
// _dl_tls_setup
DATA(__libc_enable_secure, sizeof(void*))
-DATA(__libc_stack_end, sizeof(void*))
+DATAM(__libc_stack_end, sizeof(void*))
DATA(__pointer_chk_guard, sizeof(void*))
DATAB(_r_debug, 40)
DATA(_rtld_global, sizeof(void*))
diff --git a/src/wrapped/wrappedlib_init.h b/src/wrapped/wrappedlib_init.h
index f6b5266..f6b5266 100755..100644
--- a/src/wrapped/wrappedlib_init.h
+++ b/src/wrapped/wrappedlib_init.h
diff --git a/src/wrapped/wrappedlibasound.c b/src/wrapped/wrappedlibasound.c
index 11fffc6..c49f391 100755..100644
--- a/src/wrapped/wrappedlibasound.c
+++ b/src/wrapped/wrappedlibasound.c
@@ -47,10 +47,10 @@ GO(3)
// snd_async_callback_t
#define GO(A) \
-static uintptr_t my_async_fct_##A = 0; \
-static void* my_async_##A(void* handler) \
-{ \
- return (void*)RunFunction(my_context, my_async_fct_##A, 1, handler);\
+static uintptr_t my_async_fct_##A = 0; \
+static void* my_async_##A(void* handler) \
+{ \
+ return (void*)RunFunctionFmt(my_async_fct_##A, "p", handler); \
}
SUPER()
#undef GO
@@ -67,6 +67,28 @@ static void* findAsyncFct(void* fct)
printf_log(LOG_NONE, "Warning, no more slot for Asound Async callback\n");
return NULL;
}
+// snd_mixer_elem_callback_t
+#define GO(A) \
+static uintptr_t my_elem_fct_##A = 0; \
+static int my_elem_##A(void* elem, uint32_t mask) \
+{ \
+ return (int)RunFunctionFmt(my_elem_fct_##A, "pu", elem, mask); \
+}
+SUPER()
+#undef GO
+static void* findElemFct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_elem_fct_##A == (uintptr_t)fct) return my_elem_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_elem_fct_##A == 0) {my_elem_fct_##A = (uintptr_t)fct; return my_elem_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for Asound Elem callback\n");
+ return NULL;
+}
EXPORT int my_snd_async_add_handler(x64emu_t *emu, void *handler, int fd, void* callback, void *private_data)
@@ -115,6 +137,11 @@ EXPORT int my_snd_lib_error_set_handler(x64emu_t* emu, void* handler)
return my->snd_lib_error_set_handler(error_handler);
}
+EXPORT void my_snd_mixer_elem_set_callback(x64emu_t* emu, void* handler, void* f)
+{
+ my->snd_mixer_elem_set_callback(handler, findElemFct(f));
+}
+
void* my_dlopen(x64emu_t* emu, void *filename, int flag); // defined in wrappedlibdl.c
char* my_dlerror(x64emu_t* emu);
int my_dlclose(x64emu_t* emu, void *handle);
diff --git a/src/wrapped/wrappedlibasound_private.h b/src/wrapped/wrappedlibasound_private.h
index fdb34b0..ab6e05b 100755..100644
--- a/src/wrapped/wrappedlibasound_private.h
+++ b/src/wrapped/wrappedlibasound_private.h
@@ -476,6 +476,7 @@ GO(snd_pcm_sw_params_get_xfer_align, iFpp)
GO(snd_pcm_sw_params_get_xrun_mode, iFp)
GO(snd_pcm_sw_params_malloc, iFp)
GO(snd_pcm_sw_params_set_avail_min, iFppu)
+GO(snd_pcm_sw_params_set_period_event, iFppi)
GO(snd_pcm_sw_params_set_silence_size, iFppu)
GO(snd_pcm_sw_params_set_silence_threshold, iFppu)
GO(snd_pcm_sw_params_set_sleep_min, iFppu)
@@ -919,9 +920,9 @@ GO(snd_mixer_get_count, uFp)
GO(snd_mixer_class_unregister, iFp)
GO(snd_mixer_elem_next, pFp)
GO(snd_mixer_elem_prev, pFp)
-//GO(snd_mixer_elem_set_callback, vFpP)
-//GO(snd_mixer_elem_get_callback_private, pFp)
-//GO(snd_mixer_elem_set_callback_private, vFpp)
+GOM(snd_mixer_elem_set_callback, vFEpp)
+GO(snd_mixer_elem_get_callback_private, pFp)
+GO(snd_mixer_elem_set_callback_private, vFpp)
GO(snd_mixer_elem_get_type, iFp)
//GO(snd_mixer_class_register, iFpp)
GO(snd_mixer_add_elem, iFpp)
@@ -954,6 +955,8 @@ GO(snd_mixer_selem_get_id, vFpp)
GO(snd_mixer_selem_get_name, pFp)
GO(snd_mixer_selem_get_index, uFp)
GO(snd_mixer_find_selem, pFpp)
+GO(snd_mixer_selem_ask_playback_dB_vol, iFplip)
+GO(snd_mixer_selem_ask_playback_vol_dB, iFplp)
GO(snd_mixer_selem_is_active, iFp)
GO(snd_mixer_selem_is_playback_mono, iFp)
GO(snd_mixer_selem_has_playback_channel, iFpi)
diff --git a/src/wrapped/wrappedlibc.c b/src/wrapped/wrappedlibc.c
index ca4db82..0672692 100755..100644
--- a/src/wrapped/wrappedlibc.c
+++ b/src/wrapped/wrappedlibc.c
@@ -24,7 +24,7 @@
#include <poll.h>
#include <sys/epoll.h>
#include <ftw.h>
-#include <sys/syscall.h>
+#include <sys/syscall.h>
#include <sys/socket.h>
#include <sys/utsname.h>
#include <sys/mman.h>
@@ -39,6 +39,7 @@
#include <malloc.h>
#include <getopt.h>
#include <sys/prctl.h>
+#include <sys/ptrace.h>
#undef LOG_INFO
#undef LOG_DEBUG
@@ -131,10 +132,10 @@ GO(15)
// compare
#define GO(A) \
-static uintptr_t my_compare_fct_##A = 0; \
-static int my_compare_##A(void* a, void* b) \
-{ \
- return (int)RunFunction(my_context, my_compare_fct_##A, 2, a, b);\
+static uintptr_t my_compare_fct_##A = 0; \
+static int my_compare_##A(void* a, void* b) \
+{ \
+ return (int)RunFunctionFmt(my_compare_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -160,7 +161,7 @@ static int my_ftw64_##A(void* fpath, void* sb, int flag) \
{ \
struct x64_stat64 x64st; \
UnalignStat64(sb, &x64st); \
- return (int)RunFunction(my_context, my_ftw64_fct_##A, 3, fpath, &x64st, flag); \
+ return (int)RunFunctionFmt(my_ftw64_fct_##A, "ppi", fpath, &x64st, flag); \
}
SUPER()
#undef GO
@@ -182,9 +183,9 @@ static void* findftw64Fct(void* fct)
static uintptr_t my_nftw64_fct_##A = 0; \
static int my_nftw64_##A(void* fpath, void* sb, int flag, void* ftwbuff) \
{ \
- struct x64_stat64 x64st; \
- UnalignStat64(sb, &x64st); \
- return (int)RunFunction(my_context, my_nftw64_fct_##A, 4, fpath, &x64st, flag, ftwbuff); \
+ struct x64_stat64 x64st; \
+ UnalignStat64(sb, &x64st); \
+ return (int)RunFunctionFmt(my_nftw64_fct_##A, "ppip", fpath, &x64st, flag, ftwbuff); \
}
SUPER()
#undef GO
@@ -202,10 +203,10 @@ static void* findnftw64Fct(void* fct)
}
// globerr
#define GO(A) \
-static uintptr_t my_globerr_fct_##A = 0; \
-static int my_globerr_##A(void* epath, int eerrno) \
-{ \
- return (int)RunFunction(my_context, my_globerr_fct_##A, 2, epath, eerrno); \
+static uintptr_t my_globerr_fct_##A = 0; \
+static int my_globerr_##A(void* epath, int eerrno) \
+{ \
+ return (int)RunFunctionFmt(my_globerr_fct_##A, "pi", epath, eerrno); \
}
SUPER()
#undef GO
@@ -225,10 +226,10 @@ static void* findgloberrFct(void* fct)
}
// free
#define GO(A) \
-static uintptr_t my_free_fct_##A = 0; \
-static void my_free_##A(void* p) \
-{ \
- RunFunction(my_context, my_free_fct_##A, 1, p); \
+static uintptr_t my_free_fct_##A = 0; \
+static void my_free_##A(void* p) \
+{ \
+ RunFunctionFmt(my_free_fct_##A, "p", p); \
}
SUPER()
#undef GO
@@ -251,10 +252,10 @@ static void* findfreeFct(void* fct)
#undef dirent
// filter_dir
#define GO(A) \
-static uintptr_t my_filter_dir_fct_##A = 0; \
-static int my_filter_dir_##A(const struct dirent* a) \
-{ \
- return (int)RunFunction(my_context, my_filter_dir_fct_##A, 1, a); \
+static uintptr_t my_filter_dir_fct_##A = 0; \
+static int my_filter_dir_##A(const struct dirent* a) \
+{ \
+ return (int)RunFunctionFmt(my_filter_dir_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -274,10 +275,10 @@ static void* findfilter_dirFct(void* fct)
}
// compare_dir
#define GO(A) \
-static uintptr_t my_compare_dir_fct_##A = 0; \
-static int my_compare_dir_##A(const struct dirent* a, const struct dirent* b) \
-{ \
- return (int)RunFunction(my_context, my_compare_dir_fct_##A, 2, a, b); \
+static uintptr_t my_compare_dir_fct_##A = 0; \
+static int my_compare_dir_##A(const struct dirent* a, const struct dirent* b) \
+{ \
+ return (int)RunFunctionFmt(my_compare_dir_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -299,10 +300,10 @@ static void* findcompare_dirFct(void* fct)
// filter64
#define GO(A) \
-static uintptr_t my_filter64_fct_##A = 0; \
-static int my_filter64_##A(const struct dirent64* a) \
-{ \
- return (int)RunFunction(my_context, my_filter64_fct_##A, 1, a); \
+static uintptr_t my_filter64_fct_##A = 0; \
+static int my_filter64_##A(const struct dirent64* a) \
+{ \
+ return (int)RunFunctionFmt(my_filter64_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -325,7 +326,7 @@ static void* findfilter64Fct(void* fct)
static uintptr_t my_compare64_fct_##A = 0; \
static int my_compare64_##A(const struct dirent64* a, const struct dirent64* b) \
{ \
- return (int)RunFunction(my_context, my_compare64_fct_##A, 2, a, b); \
+ return (int)RunFunctionFmt(my_compare64_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -345,10 +346,10 @@ static void* findcompare64Fct(void* fct)
}
// printf_output
#define GO(A) \
-static uintptr_t my_printf_output_fct_##A = 0; \
-static int my_printf_output_##A(void* a, void* b, void* c) \
-{ \
- return (int)RunFunction(my_context, my_printf_output_fct_##A, 3, a, b, c); \
+static uintptr_t my_printf_output_fct_##A = 0; \
+static int my_printf_output_##A(void* a, void* b, void* c) \
+{ \
+ return (int)RunFunctionFmt(my_printf_output_fct_##A, "ppp", a, b, c); \
}
SUPER()
#undef GO
@@ -368,10 +369,10 @@ static void* findprintf_outputFct(void* fct)
}
// printf_arginfo
#define GO(A) \
-static uintptr_t my_printf_arginfo_fct_##A = 0; \
-static int my_printf_arginfo_##A(void* a, size_t b, void* c, void* d) \
-{ \
- return (int)RunFunction(my_context, my_printf_arginfo_fct_##A, 4, a, b, c, d); \
+static uintptr_t my_printf_arginfo_fct_##A = 0; \
+static int my_printf_arginfo_##A(void* a, size_t b, void* c, void* d) \
+{ \
+ return (int)RunFunctionFmt(my_printf_arginfo_fct_##A, "pLpp", a, b, c, d); \
}
SUPER()
#undef GO
@@ -391,10 +392,10 @@ static void* findprintf_arginfoFct(void* fct)
}
// printf_type
#define GO(A) \
-static uintptr_t my_printf_type_fct_##A = 0; \
-static void my_printf_type_##A(void* a, va_list* b) \
-{ \
- RunFunction(my_context, my_printf_type_fct_##A, 2, a, b); \
+static uintptr_t my_printf_type_fct_##A = 0; \
+static void my_printf_type_##A(void* a, va_list* b) \
+{ \
+ RunFunctionFmt(my_printf_type_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -416,8 +417,8 @@ static void* findprintf_typeFct(void* fct)
#undef SUPER
// some my_XXX declare and defines
-int32_t my___libc_start_main(x64emu_t* emu, int *(main) (int, char * *, char * *),
- int argc, char * * ubp_av, void (*init) (void), void (*fini) (void),
+int32_t my___libc_start_main(x64emu_t* emu, int *(main) (int, char * *, char * *),
+ int argc, char * * ubp_av, void (*init) (void), void (*fini) (void),
void (*rtld_fini) (void), void (* stack_end)); // implemented in x64run_private.c
EXPORT void my___libc_init_first(x64emu_t* emu, int argc, char* arg0, char** b)
{
@@ -437,7 +438,7 @@ void EXPORT my___stack_chk_fail(x64emu_t* emu)
if(cycle_log) {
print_cycle_log(LOG_INFO);
}
- StopEmu(emu, buff);
+ StopEmu(emu, buff, emu->segs[_CS]==0x23);
}
void EXPORT my___gmon_start__(x64emu_t *emu)
{
@@ -447,8 +448,7 @@ void EXPORT my___gmon_start__(x64emu_t *emu)
int EXPORT my___cxa_atexit(x64emu_t* emu, void* p, void* a, void* dso_handle)
{
- (void)dso_handle;
- AddCleanup1Arg(emu, p, a);
+ AddCleanup1Arg(emu, p, a, dso_handle);
return 0;
}
void EXPORT my___cxa_finalize(x64emu_t* emu, void* p)
@@ -462,7 +462,7 @@ void EXPORT my___cxa_finalize(x64emu_t* emu, void* p)
}
int EXPORT my_atexit(x64emu_t* emu, void *p)
{
- AddCleanup(emu, p);
+ AddCleanup(emu, p, NULL); // should grab current dso_handle?
return 0;
}
@@ -483,6 +483,11 @@ int my_dl_iterate_phdr(x64emu_t *emu, void* F, void *data);
pid_t EXPORT my_fork(x64emu_t* emu)
{
+ #if 1
+ emu->quit = 1;
+ emu->fork = 3; // use regular fork...
+ return 0;
+ #else
// execute atforks prepare functions, in reverse order
for (int i=my_context->atfork_sz-1; i>=0; --i)
if(my_context->atforks[i].prepare)
@@ -495,7 +500,7 @@ pid_t EXPORT my_fork(x64emu_t* emu)
if(v<0) {
printf_log(LOG_NONE, "BOX64: Warning, fork errored... (%d)\n", v);
// error...
- } else if(v>0) {
+ } else if(v>0) {
// execute atforks parent functions
for (int i=0; i<my_context->atfork_sz; --i)
if(my_context->atforks[i].parent)
@@ -508,6 +513,7 @@ pid_t EXPORT my_fork(x64emu_t* emu)
RunFunctionWithEmu(emu, 0, my_context->atforks[i].child, 0);
}
return v;
+ #endif
}
pid_t EXPORT my___fork(x64emu_t* emu) __attribute__((alias("my_fork")));
pid_t EXPORT my_vfork(x64emu_t* emu)
@@ -685,32 +691,17 @@ EXPORT int my___fprintf_chk(x64emu_t *emu, void* F, int flag, void* fmt, void* b
return vfprintf(F, fmt, VARARGS);
}
-#if 0
-EXPORT int my_wprintf(x64emu_t *emu, void* fmt, void* b, va_list V) {
- #ifndef NOALIGN
- // need to align on arm
- myStackAlignW((const char*)fmt, b, emu->scratch);
- PREPARE_VALIST;
- void* f = vwprintf;
- return ((iFpp_t)f)(fmt, VARARGS);
+EXPORT int my_vwprintf(x64emu_t *emu, void* fmt, x64_va_list_t b) {
+ (void)emu;
+ #ifdef CONVERT_VALIST
+ CONVERT_VALIST(b);
#else
- // other platform don't need that
- return vwprintf((const wchar_t*)fmt, V);
- #endif
-}
-EXPORT int my___wprintf_chk(x64emu_t *emu, int flag, void* fmt, void* b, va_list V) {
- #ifndef NOALIGN
- // need to align on arm
- myStackAlignW((const char*)fmt, b, emu->scratch);
+ myStackAlignWValist(emu, (const char*)fmt, emu->scratch, b);
PREPARE_VALIST;
- void* f = vwprintf;
- return ((iFpp_t)f)(fmt, VARARGS);
- #else
- // other platform don't need that
- return vwprintf((const wchar_t*)fmt, V);
#endif
+ int r = vwprintf(fmt, VARARGS);
+ return r;
}
-#endif
EXPORT int my_fwprintf(x64emu_t *emu, void* F, void* fmt, void* b) {
myStackAlignW(emu, (const char*)fmt, b, emu->scratch, R_EAX, 2);
@@ -743,19 +734,42 @@ EXPORT int my___vfwprintf_chk(x64emu_t *emu, void* F, int flag, void* fmt, x64_v
return vfwprintf(F, fmt, VARARGS);
}
-#if 0
-EXPORT int my_vwprintf(x64emu_t *emu, void* fmt, void* b) {
- #ifndef NOALIGN
- myStackAlignW((const char*)fmt, b, emu->scratch);
+EXPORT int my_dprintf(x64emu_t *emu, int d, void* fmt, void* b) {
+ myStackAlign(emu, (const char*)fmt, b, emu->scratch, R_EAX, 2);
PREPARE_VALIST;
- void* f = vwprintf;
- return ((iFpp_t)f)(fmt, VARARGS);
+ return vdprintf(d, fmt, VARARGS);
+}
+
+EXPORT int my___dprintf_chk(x64emu_t *emu, int d, int flag, void* fmt, void* b) {
+ (void)flag;
+ myStackAlign(emu, (const char*)fmt, b, emu->scratch, R_EAX, 3);
+ PREPARE_VALIST;
+ return vdprintf(d, fmt, VARARGS);
+}
+
+
+EXPORT int my_vdprintf(x64emu_t *emu, int d, void* fmt, x64_va_list_t b) {
+ #ifdef CONVERT_VALIST
+ CONVERT_VALIST(b);
+ #else
+ myStackAlignValist(emu, (const char*)fmt, emu->scratch, b);
+ PREPARE_VALIST;
+ #endif
+ return vdprintf(d, fmt, VARARGS);
+}
+
+EXPORT int my___vdprintf_chk(x64emu_t *emu, int d, int flag, void* fmt, x64_va_list_t b) {
+ (void)flag;
+ #ifdef CONVERT_VALIST
+ CONVERT_VALIST(b);
#else
- void* f = vwprintf;
- return ((iFpp_t)f)(fmt, b);
+ myStackAlignValist(emu, (const char*)fmt, emu->scratch, b);
+ PREPARE_VALIST;
#endif
+ return vdprintf(d, fmt, VARARGS);
}
+#if 0
EXPORT void *my_div(void *result, int numerator, int denominator) {
*(div_t *)result = div(numerator, denominator);
return result;
@@ -910,6 +924,14 @@ EXPORT int my___isoc99_sscanf(x64emu_t* emu, void* stream, void* fmt, uint64_t*
return vsscanf(stream, fmt, VARARGS);
}
+EXPORT int my___isoc99_swscanf(x64emu_t* emu, void* stream, void* fmt, uint64_t* b)
+{
+ myStackAlignScanf(emu, (const char*)fmt, b, emu->scratch, 2);
+ PREPARE_VALIST;
+
+ return vswscanf(stream, fmt, VARARGS);
+}
+
EXPORT int my_vsnprintf(x64emu_t* emu, void* buff, size_t s, void * fmt, x64_va_list_t b) {
(void)emu;
#ifdef CONVERT_VALIST
@@ -922,7 +944,17 @@ EXPORT int my_vsnprintf(x64emu_t* emu, void* buff, size_t s, void * fmt, x64_va_
return r;
}
EXPORT int my___vsnprintf(x64emu_t* emu, void* buff, size_t s, void * fmt, x64_va_list_t b) __attribute__((alias("my_vsnprintf")));
-EXPORT int my___vsnprintf_chk(x64emu_t* emu, void* buff, size_t s, void * fmt, x64_va_list_t b) __attribute__((alias("my_vsnprintf")));
+EXPORT int my___vsnprintf_chk(x64emu_t* emu, void* buff, size_t s, int flags, size_t slen, void * fmt, x64_va_list_t b) {
+ (void)emu;
+ #ifdef CONVERT_VALIST
+ CONVERT_VALIST(b);
+ #else
+ myStackAlignValist(emu, (const char*)fmt, emu->scratch, b);
+ PREPARE_VALIST;
+ #endif
+ int r = vsnprintf(buff, s, fmt, VARARGS);
+ return r;
+}
#if 0
EXPORT int my_vasprintf(x64emu_t* emu, void* strp, void* fmt, void* b, va_list V)
{
@@ -1282,7 +1314,17 @@ EXPORT void* my_tsearch(x64emu_t* emu, void* key, void* root, void* fnc)
EXPORT void my_tdestroy(x64emu_t* emu, void* root, void* fnc)
{
(void)emu;
- return tdestroy(root, findfreeFct(fnc));
+ tdestroy(root, findfreeFct(fnc));
+}
+EXPORT void* my_tdelete(x64emu_t* emu, void* key, void** root, void* fnc)
+{
+ (void)emu;
+ return tdelete(key, root, findcompareFct(fnc));
+}
+EXPORT void* my_tfind(x64emu_t* emu, void* key, void** root, void* fnc)
+{
+ (void)emu;
+ return tfind(key, root, findcompareFct(fnc));
}
EXPORT void* my_lfind(x64emu_t* emu, void* key, void* base, size_t* nmemb, size_t size, void* fnc)
{
@@ -1548,7 +1590,7 @@ void CreateCPUInfoFile(int fd)
P;
sprintf(buff, "bogomips\t: %g\n", bogoMips);
P;
- sprintf(buff, "flags\t\t: fpu cx8 sep cmov clflush mmx sse sse2 syscall tsc lahf_lm ssse3 ht tm lm fma fxsr cpuid pclmulqdq cx16 aes movbe pni\n");
+ sprintf(buff, "flags\t\t: fpu cx8 sep cmov clflush mmx sse sse2 syscall tsc lahf_lm ssse3 ht tm lm fma fxsr cpuid pclmulqdq cx16 aes movbe pni sse4_1 popcnt\n");
P;
sprintf(buff, "address sizes\t: 46 bits physical, 48 bits virtual\n");
P;
@@ -1630,7 +1672,7 @@ EXPORT int32_t my___open(x64emu_t* emu, void* pathname, int32_t flags, uint32_t
// unprotectDB((uintptr_t)p, count-ret, 1);
// int l;
// do {
-// l = read(fd, p, count-ret);
+// l = read(fd, p, count-ret);
// if(l>0) {
// p+=l; ret+=l;
// }
@@ -1854,11 +1896,11 @@ EXPORT int32_t my_execv(x64emu_t* emu, const char* path, char* const argv[])
int n=skip_first;
while(argv[n]) ++n;
int toadd = script?2:1;
- const char** newargv = (const char**)box_calloc(n+toadd+1, sizeof(char*));
+ const char** newargv = (const char**)box_calloc(n+toadd+2, sizeof(char*));
newargv[0] = x86?emu->context->box86path:emu->context->box64path;
if(script) newargv[1] = emu->context->bashpath; // script needs to be launched with bash
memcpy(newargv+toadd, argv+skip_first, sizeof(char*)*(n+toadd));
- if(self)
+ if(self)
newargv[1] = emu->context->fullpath;
else {
// TODO check if envp is not environ and add the value on a copy
@@ -2034,7 +2076,7 @@ EXPORT int32_t my_execvp(x64emu_t* emu, const char* path, char* const argv[])
// uname -m is redirected to box64 -m
path = my_context->box64path;
char *argv2[3] = { my_context->box64path, argv[1], NULL };
-
+
return execvp(path, argv2);
}
@@ -2048,7 +2090,7 @@ EXPORT int32_t my_execl(x64emu_t* emu, const char* path)
int x64 = FileIsX64ELF(path);
int x86 = my_context->box86path?FileIsX86ELF(path):0;
int script = (my_context->bashpath && FileIsShell(path))?1:0;
- printf_log(LOG_DEBUG, "execl(\"%s\", ...), IsX86=%d, self=%d\n", path, x64, self);
+ printf_log(LOG_DEBUG, "execle(\"%s\", ...), IsX86=%d, self=%d\n", path, x64, self);
// count argv...
int i=0;
while(getVargN(emu, i+1)) ++i;
@@ -2061,12 +2103,42 @@ EXPORT int32_t my_execl(x64emu_t* emu, const char* path)
for (int k=0; k<i; ++k)
newargv[j++] = getVargN(emu, k+1);
if(self) newargv[1] = emu->context->fullpath;
- printf_log(LOG_DEBUG, " => execl(\"%s\", %p [\"%s\", \"%s\"...:%d])\n", newargv[0], newargv, newargv[1], i?newargv[2]:"", i);
+ printf_log(LOG_DEBUG, " => execle(\"%s\", %p [\"%s\", \"%s\"...:%d])\n", newargv[0], newargv, newargv[1], i?newargv[2]:"", i);
int ret = execv(newargv[0], newargv);
box_free(newargv);
return ret;
}
+EXPORT int32_t my_execle(x64emu_t* emu, const char* path)
+{
+ int self = isProcSelf(path, "exe");
+ int x64 = FileIsX64ELF(path);
+ int x86 = my_context->box86path?FileIsX86ELF(path):0;
+ int script = (my_context->bashpath && FileIsShell(path))?1:0;
+ printf_log(LOG_DEBUG, "execl(\"%s\", ...), IsX86=%d, self=%d\n", path, x64, self);
+ // hack to update the environ var if needed
+ // count argv...
+ int i=0;
+ while(getVargN(emu, i+1)) ++i;
+ int toadd = script?2:((x64||self)?1:0);
+ char** newargv = (char**)box_calloc(i+toadd+1, sizeof(char*));
+ char** envp = (char**)getVargN(emu, i+2);
+ if(envp == my_context->envv && environ) {
+ envp = environ;
+ }
+ int j=0;
+ if ((x64 || x86 || script || self))
+ newargv[j++] = x86?emu->context->box86path:emu->context->box64path;
+ if(script) newargv[j++] = emu->context->bashpath;
+ for (int k=0; k<i; ++k)
+ newargv[j++] = getVargN(emu, k+1);
+ if(self) newargv[1] = emu->context->fullpath;
+ printf_log(LOG_DEBUG, " => execle(\"%s\", %p [\"%s\", \"%s\"...:%d], %p)\n", newargv[0], newargv, newargv[1], i?newargv[2]:"", i, envp);
+ int ret = execve(newargv[0], newargv, envp);
+ box_free(newargv);
+ return ret;
+}
+
EXPORT int32_t my_execlp(x64emu_t* emu, const char* path)
{
// need to use BOX64_PATH / PATH here...
@@ -2105,7 +2177,7 @@ EXPORT int32_t my_execlp(x64emu_t* emu, const char* path)
return ret;
}
-EXPORT int32_t my_posix_spawn(x64emu_t* emu, pid_t* pid, const char* fullpath,
+EXPORT int32_t my_posix_spawn(x64emu_t* emu, pid_t* pid, const char* fullpath,
const posix_spawn_file_actions_t *actions, const posix_spawnattr_t* attrp, char* const argv[], char* const envp[])
{
int self = isProcSelf(fullpath, "exe");
@@ -2138,13 +2210,13 @@ EXPORT int32_t my_posix_spawn(x64emu_t* emu, pid_t* pid, const char* fullpath,
ret = posix_spawn(pid, newargv[0], actions, attrp, (char* const*)newargv, envp);
printf_log(/*LOG_DEBUG*/LOG_INFO, "posix_spawn returned %d\n", ret);
//box_free(newargv);
- } else
+ } else
ret = posix_spawn(pid, fullpath, actions, attrp, argv, envp);
return ret;
}
// execvp should use PATH to search for the program first
-EXPORT int32_t my_posix_spawnp(x64emu_t* emu, pid_t* pid, const char* path,
+EXPORT int32_t my_posix_spawnp(x64emu_t* emu, pid_t* pid, const char* path,
const posix_spawn_file_actions_t *actions, const posix_spawnattr_t* attrp, char* const argv[], char* const envp[])
{
// need to use BOX64_PATH / PATH here...
@@ -2187,7 +2259,10 @@ EXPORT void my__Jv_RegisterClasses() {}
EXPORT int32_t my___cxa_thread_atexit_impl(x64emu_t* emu, void* dtor, void* obj, void* dso)
{
(void)emu;
- printf_log(LOG_INFO, "Warning, call to __cxa_thread_atexit_impl(%p, %p, %p) ignored\n", dtor, obj, dso);
+ //printf_log(LOG_INFO, "Warning, call to __cxa_thread_atexit_impl(%p, %p, %p) ignored\n", dtor, obj, dso);
+ AddCleanup1Arg(emu, dtor, obj, dso);
+ return 0;
+
return 0;
}
@@ -2210,7 +2285,7 @@ EXPORT int32_t my___register_atfork(x64emu_t *emu, void* prepare, void* parent,
EXPORT uint64_t my___umoddi3(uint64_t a, uint64_t b)
{
return a%b;
-}
+}
EXPORT uint64_t my___udivdi3(uint64_t a, uint64_t b)
{
return a/b;
@@ -2275,8 +2350,8 @@ EXPORT int32_t my_fcntl(x64emu_t* emu, int32_t a, int32_t b, void* c)
int ret = fcntl(a, b, c);
if(b==F_GETFL && ret!=-1)
ret = of_unconvert(ret);
-
- return ret;
+
+ return ret;
}
EXPORT int32_t my___fcntl(x64emu_t* emu, int32_t a, int32_t b, void* c) __attribute__((alias("my_fcntl")));
@@ -2349,10 +2424,10 @@ void InitCpuModel()
my___cpu_model.__cpu_vendor = VENDOR_INTEL;
my___cpu_model.__cpu_type = INTEL_PENTIUM_M;
my___cpu_model.__cpu_subtype = 0; // N/A
- my___cpu_model.__cpu_features[0] = (1<<FEATURE_CMOV)
- | (1<<FEATURE_MMX)
- | (1<<FEATURE_SSE)
- | (1<<FEATURE_SSE2)
+ my___cpu_model.__cpu_features[0] = (1<<FEATURE_CMOV)
+ | (1<<FEATURE_MMX)
+ | (1<<FEATURE_SSE)
+ | (1<<FEATURE_SSE2)
| (1<<FEATURE_SSE3)
| (1<<FEATURE_SSSE3)
| (1<<FEATURE_MOVBE)
@@ -2371,12 +2446,6 @@ void ctSetup()
my___ctype_tolower = *(__ctype_tolower_loc());
}
-EXPORT void* my___libc_stack_end;
-void stSetup(box64context_t* context)
-{
- my___libc_stack_end = context->stack; // is this the end, or should I add stasz?
-}
-
EXPORT void my___register_frame_info(void* a, void* b)
{
// nothing
@@ -2425,8 +2494,8 @@ void EXPORT my_longjmp(x64emu_t* emu, /*struct __jmp_buf_tag __env[1]*/void *p,
if(((__jmp_buf_tag_t*)p)->__mask_was_saved) {
sigprocmask(SIG_SETMASK, &((__jmp_buf_tag_t*)p)->__saved_mask, NULL);
}
- if(emu->quitonlongjmp) {
- emu->longjmp = 1;
+ if(emu->flags.quitonlongjmp) {
+ emu->flags.longjmp = 1;
emu->quit = 1;
}
}
@@ -2450,6 +2519,11 @@ EXPORT int32_t my___sigsetjmp(x64emu_t* emu, /*struct __jmp_buf_tag __env[1]*/vo
((__jmp_buf_tag_t*)p)->__mask_was_saved = 1;
} else
((__jmp_buf_tag_t*)p)->__mask_was_saved = 0;
+ // quit emulation loop and create a new jumpbuf if needed
+ if(!emu->flags.jmpbuf_ready) {
+ emu->flags.need_jmpbuf = 1;
+ emu->quit = 1;
+ }
return 0;
}
EXPORT int32_t my_sigsetjmp(x64emu_t* emu, /*struct __jmp_buf_tag __env[1]*/void *p, int savesigs)
@@ -2492,7 +2566,7 @@ EXPORT int my_readlinkat(x64emu_t* emu, int fd, void* path, void* buf, size_t bu
EXPORT void* my_mmap64(x64emu_t* emu, void *addr, unsigned long length, int prot, int flags, int fd, int64_t offset)
{
(void)emu;
- if(prot&PROT_WRITE)
+ if(prot&PROT_WRITE)
prot|=PROT_READ; // PROT_READ is implicit with PROT_WRITE on i386
if(box64_log<LOG_DEBUG) {dynarec_log(LOG_DEBUG, "mmap64(%p, %lu, 0x%x, 0x%x, %d, %ld) => ", addr, length, prot, flags, fd, offset);}
#ifndef NOALIGN
@@ -2508,7 +2582,7 @@ EXPORT void* my_mmap64(x64emu_t* emu, void *addr, unsigned long length, int prot
#endif
void* ret = mmap64(addr, length, prot, flags, fd, offset);
#ifndef NOALIGN
- if((ret!=(void*)-1) && (flags&0x40) &&
+ if((ret!=(void*)-1) && (flags&0x40) &&
(((uintptr_t)ret>0xffffffffLL) || (box64_wine && ((uintptr_t)ret&0xffff)))) {
printf_log(LOG_DEBUG, "Warning, mmap on 32bits didn't worked, ask %p, got %p ", addr, ret);
munmap(ret, length);
@@ -2559,7 +2633,7 @@ EXPORT void* my_mremap(x64emu_t* emu, void* old_addr, size_t old_size, size_t ne
uint32_t prot = getProtection((uintptr_t)old_addr)&~PROT_CUSTOM;
if(ret==old_addr) {
if(old_size && old_size<new_size) {
- setProtection((uintptr_t)ret+old_size, new_size-old_size, prot);
+ setProtection_mmap((uintptr_t)ret+old_size, new_size-old_size, prot);
#ifdef DYNAREC
if(box64_dynarec)
addDBFromAddressRange((uintptr_t)ret+old_size, new_size-old_size);
@@ -2568,10 +2642,10 @@ EXPORT void* my_mremap(x64emu_t* emu, void* old_addr, size_t old_size, size_t ne
freeProtection((uintptr_t)ret+new_size, old_size-new_size);
#ifdef DYNAREC
if(box64_dynarec)
- cleanDBFromAddressRange((uintptr_t)ret+new_size, new_size-old_size, 1);
+ cleanDBFromAddressRange((uintptr_t)ret+new_size, old_size-new_size, 1);
#endif
} else if(!old_size) {
- setProtection((uintptr_t)ret, new_size, prot);
+ setProtection_mmap((uintptr_t)ret, new_size, prot);
#ifdef DYNAREC
if(box64_dynarec)
addDBFromAddressRange((uintptr_t)ret, new_size);
@@ -2618,19 +2692,26 @@ EXPORT int my_mprotect(x64emu_t* emu, void *addr, unsigned long len, int prot)
{
(void)emu;
dynarec_log(LOG_DEBUG, "mprotect(%p, %lu, 0x%x)\n", addr, len, prot);
- if(prot&PROT_WRITE)
+ if(prot&PROT_WRITE)
prot|=PROT_READ; // PROT_READ is implicit with PROT_WRITE on x86_64
int ret = mprotect(addr, len, prot);
#ifdef DYNAREC
- if(box64_dynarec && !ret) {
+ if(box64_dynarec && !ret && len) {
if(prot& PROT_EXEC)
addDBFromAddressRange((uintptr_t)addr, len);
else
- cleanDBFromAddressRange((uintptr_t)addr, len, 0);
+ cleanDBFromAddressRange((uintptr_t)addr, len, 1);
}
#endif
- if(!ret)
- updateProtection((uintptr_t)addr, len, prot);
+ if(!ret && len) {
+ if(prot)
+ updateProtection((uintptr_t)addr, len, prot);
+ else {
+ // avoid allocating detailled protection for a no prot 0
+ freeProtection((uintptr_t)addr, len);
+ setProtection_mmap((uintptr_t)addr, len, prot);
+ }
+ }
return ret;
}
@@ -2674,7 +2755,13 @@ EXPORT int my_getopt_long_only(int argc, char* const argv[], const char* optstri
return ret;
}
-#if 0
+typedef struct {
+ void *read;
+ void *write;
+ void *seek;
+ void *close;
+} my_cookie_io_functions_t;
+
typedef struct my_cookie_s {
uintptr_t r, w, s, c;
void* cookie;
@@ -2683,39 +2770,41 @@ typedef struct my_cookie_s {
static ssize_t my_cookie_read(void *p, char *buf, size_t size)
{
my_cookie_t* cookie = (my_cookie_t*)p;
- return (ssize_t)RunFunction(my_context, cookie->r, 3, cookie->cookie, buf, size);
+ return (ssize_t)RunFunctionFmt(cookie->r, "ppL", cookie->cookie, buf, size) ;
}
static ssize_t my_cookie_write(void *p, const char *buf, size_t size)
{
my_cookie_t* cookie = (my_cookie_t*)p;
- return (ssize_t)RunFunction(my_context, cookie->w, 3, cookie->cookie, buf, size);
+ return (ssize_t)RunFunctionFmt(cookie->w, "ppL", cookie->cookie, buf, size) ;
}
static int my_cookie_seek(void *p, off64_t *offset, int whence)
{
my_cookie_t* cookie = (my_cookie_t*)p;
- return RunFunction(my_context, cookie->s, 3, cookie->cookie, offset, whence);
+ return RunFunctionFmt(cookie->s, "ppi", cookie->cookie, offset, whence) ;
}
static int my_cookie_close(void *p)
{
my_cookie_t* cookie = (my_cookie_t*)p;
int ret = 0;
if(cookie->c)
- ret = RunFunction(my_context, cookie->c, 1, cookie->cookie);
+ ret = RunFunctionFmt(cookie->c, "p", cookie->cookie) ;
box_free(cookie);
return ret;
}
-EXPORT void* my_fopencookie(x64emu_t* emu, void* cookie, void* mode, void* read, void* write, void* seek, void* close)
+EXPORT void* my_fopencookie(x64emu_t* emu, void* cookie, void* mode, my_cookie_io_functions_t *s)
{
- cookie_io_functions_t io_funcs = {read?my_cookie_read:NULL, write?my_cookie_write:NULL, seek?my_cookie_seek:NULL, my_cookie_close};
+ cookie_io_functions_t io_funcs = {s->read?my_cookie_read:NULL, s->write?my_cookie_write:NULL, s->seek?my_cookie_seek:NULL, my_cookie_close};
my_cookie_t *cb = (my_cookie_t*)box_calloc(1, sizeof(my_cookie_t));
- cb->r = (uintptr_t)read;
- cb->w = (uintptr_t)write;
- cb->s = (uintptr_t)seek;
- cb->c = (uintptr_t)close;
+ cb->r = (uintptr_t)s->read;
+ cb->w = (uintptr_t)s->write;
+ cb->s = (uintptr_t)s->seek;
+ cb->c = (uintptr_t)s->close;
cb->cookie = cookie;
return fopencookie(cb, mode, io_funcs);
}
+#if 0
+
EXPORT long my_prlimit64(void* pid, uint32_t res, void* new_rlim, void* old_rlim)
{
return syscall(__NR_prlimit64, pid, res, new_rlim, old_rlim);
@@ -2898,6 +2987,15 @@ EXPORT int my_semctl(int semid, int semnum, int cmd, union semun b)
return ret;
}
+EXPORT int my_ptrace(x64emu_t* emu, int request, pid_t pid, void* addr, void* data)
+{
+ if(request == PTRACE_POKEUSER) {
+ // lets just ignore this for now!
+ return 0;
+ }
+ return ptrace(request, pid, addr, data);
+}
+
// Backtrace stuff
#include "elfs/elfdwarf_private.h"
@@ -2911,7 +3009,7 @@ EXPORT int my_backtrace(x64emu_t* emu, void** buffer, int size)
buffer[0] = (void*)addr;
while (++idx < size) {
uintptr_t ret_addr = get_parent_registers(unwind, FindElfAddress(my_context, addr), addr, &success);
- if (ret_addr == (uintptr_t)GetExit()) {
+ if (ret_addr == my_context->exit_bridge) {
// TODO: do something to be able to get the function name
buffer[idx] = (void*)ret_addr;
success = 2;
@@ -2941,7 +3039,7 @@ EXPORT int my_backtrace_ip(x64emu_t* emu, void** buffer, int size)
buffer[0] = (void*)addr;
while ((++idx < size) && success) {
uintptr_t ret_addr = get_parent_registers(unwind, FindElfAddress(my_context, addr), addr, &success);
- if (ret_addr == (uintptr_t)GetExit()) {
+ if (ret_addr == my_context->exit_bridge) {
// TODO: do something to be able to get the function name
buffer[idx] = (void*)ret_addr;
success = 2;
@@ -2972,7 +3070,7 @@ EXPORT int my_backtrace_ip(x64emu_t* emu, void** buffer, int size)
unwind->regs[7] += 8;
buffer[idx] = (void*)ret_addr;
success = 2;
- } else
+ } else
break;
}
} else
@@ -3019,7 +3117,7 @@ EXPORT void my_backtrace_symbols_fd(x64emu_t* emu, uintptr_t* buffer, int size,
if(!sz) sz=0x100; // arbitrary value...
if(symbname && buffer[i]>=start && (buffer[i]<(start+sz) || !sz))
snprintf(s, 200, "%s+%ld [%p]\n", symbname, buffer[i] - start, (void*)buffer[i]);
- else
+ else
snprintf(s, 200, "??? [%p]\n", (void*)buffer[i]);
int dummy = write(fd, s, strlen(s));
(void)dummy;
@@ -3096,10 +3194,10 @@ static int clone_fn(void* p)
updateGlibcTidCache(); // update cache tid if needed
x64emu_t *emu = arg->emu;
R_RSP = arg->stack;
- emu->quitonexit = 1;
+ emu->flags.quitonexit = 1;
thread_set_emu(emu);
int ret = RunFunctionWithEmu(emu, 0, arg->fnc, 1, arg->args);
- int exited = (emu->quitonexit==2);
+ int exited = (emu->flags.quitonexit==2);
thread_set_emu(NULL);
FreeX64Emu(&emu);
if(arg->stack_clone_used)
@@ -3116,8 +3214,8 @@ EXPORT int my_clone(x64emu_t* emu, void* fn, void* stack, int flags, void* args,
void* mystack = NULL;
clone_arg_t* arg = (clone_arg_t*)box_calloc(1, sizeof(clone_arg_t));
x64emu_t * newemu = NewX64Emu(emu->context, R_RIP, (uintptr_t)stack, 0, 0);
- SetupX64Emu(newemu);
- CloneEmu(newemu, emu);
+ SetupX64Emu(newemu, emu);
+ //CloneEmu(newemu, emu);
if(my_context->stack_clone_used) {
printf_log(LOG_DEBUG, " no free stack_clone ");
mystack = box_malloc(1024*1024); // stack for own process... memory leak, but no practical way to remove it
@@ -3175,15 +3273,17 @@ EXPORT int my_register_printf_type(x64emu_t* emu, void* f)
return my->register_printf_type(findprintf_typeFct(f));
}
+extern int box64_quit;
EXPORT void my_exit(x64emu_t* emu, int code)
{
- if(emu->quitonexit) {
+ if(emu->flags.quitonexit) {
emu->quit = 1;
R_EAX = code;
- emu->quitonexit = 2;
+ emu->flags.quitonexit = 2;
return;
}
emu->quit = 1;
+ box64_quit = 1;
exit(code);
}
@@ -3220,7 +3320,6 @@ EXPORT char my___libc_single_threaded = 0;
box64->libclib = lib; \
/*InitCpuModel();*/ \
ctSetup(); \
- stSetup(box64); \
obstackSetup(); \
my_environ = my__environ = my___environ = box64->envv; \
my___progname_full = my_program_invocation_name = box64->argv[0]; \
diff --git a/src/wrapped/wrappedlibc_private.h b/src/wrapped/wrappedlibc_private.h
index ecf8c05..933178e 100755..100644
--- a/src/wrapped/wrappedlibc_private.h
+++ b/src/wrapped/wrappedlibc_private.h
@@ -24,7 +24,7 @@ GO(__adjtimex, iFp)
GOW(adjtimex, iFp)
//GOW(advance,
GO(alarm, uFu)
-GOW(aligned_alloc, pFLL)
+GO(aligned_alloc, pFUU)
GOW(alphasort, iFpp)
GOW(alphasort64, iFpp)
//GO(__arch_prctl,
@@ -94,7 +94,7 @@ GOW(brk, iFp)
GOM(bsearch, pFEppLLp)
GOW(btowc, uFi)
GO(__bzero, vFpL)
-GOW(bzero, vFpL)
+GO(bzero, vFpL)
//GO(c16rtomb, LFpW!)
//GOW(c32rtomb, LFpu!)
GOW(calloc, pFLL)
@@ -177,7 +177,7 @@ GO(ctime_r, pFpp)
//DATA(__ctype32_toupper,
DATA(__ctype_b, sizeof(void*))
GO(__ctype_b_loc, pFv)
-GOW(__ctype_get_mb_cur_max, LFv)
+GO(__ctype_get_mb_cur_max, LFv)
//GO(__ctype_init,
DATAM(__ctype_tolower, sizeof(void*))
GO(__ctype_tolower_loc, pFv)
@@ -219,8 +219,8 @@ GOWM(dl_iterate_phdr, iFEpp)
//GO(_dl_sym,
//GO(_dl_vsym,
GOW(dngettext, pFpppL)
-//GO(dprintf, iFipV)
-//GO(__dprintf_chk,
+GOM(dprintf, iFEipV)
+GOM(__dprintf_chk, iFEiipV)
GO(drand48, dFv)
GO(drand48_r, iFpp)
GOW(dup, iFi)
@@ -294,7 +294,7 @@ GO(eventfd, iFui)
GO(eventfd_read, iFip)
GO(eventfd_write, iFiL)
GOM(execl, iFEpV) // First argument is also part of the variadic
-//GOM(execle, iFEpV) // First argument is also part of the variadic
+GOM(execle, iFEpV) // First argument is also part of the variadic
GOM(execlp, iFEpV) // First argument is also part of the variadic
GOM(execv, iFEpp)
GOWM(execve, iFEppp)
@@ -324,7 +324,7 @@ GOWM(__fcntl, iFEiiN)
GOWM(fcntl, iFEiiN)
GOWM(fcntl64, iFEiiN)
GO(fcvt, pFdipp)
-GOW(fcvt_r, iFdipppL)
+GO(fcvt_r, iFdipppL)
GO(fdatasync, iFi)
GO(__fdelt_chk, LFL)
//GO(__fdelt_warn,
@@ -341,7 +341,7 @@ GOW(fflush, iFS)
GO(fflush_unlocked, iFS)
//GO(__ffs,
GO(ffs, iFi)
-GOW(ffsl, iFl)
+GO(ffsl, iFI)
GO(ffsll, iFI)
GOW(fgetc, iFp)
GOW(fgetc_unlocked, iFp)
@@ -384,11 +384,11 @@ GO(fmtmsg, iFlpippp)
GO(fnmatch, iFppi)
GOM(fopen, pFEpp)
GOWM(fopen64, pFEpp)
-//GO(fopencookie, pFpp?)
+GOM(fopencookie, pFEppV)
//GO(__fork,
GOWM(fork, iFEv)
//GO(__fortify_fail,
-GOW(fpathconf, lFii)
+GO(fpathconf, lFii)
GO(__fpending, LFp)
GOM(fprintf, iFEppV)
GOM(__fprintf_chk, iFEpipV)
@@ -402,11 +402,11 @@ GO(fputwc, uFip)
GO(fputwc_unlocked, uFip)
GO(fputws, iFpp)
GO(fputws_unlocked, iFpp)
-GOW(fread, LFpLLp)
+GO(fread, LFpLLp)
GO(__freadable, iFp)
GO(__fread_chk, LFpLLLp)
GO(__freading, iFp)
-GOW(fread_unlocked, LFpLLp)
+GO(fread_unlocked, LFpLLp)
GO(__fread_unlocked_chk, LFpLLLp)
GO(free, vFp)
GO(freeaddrinfo, vFp)
@@ -421,9 +421,9 @@ GOW(frexpf, fFfp)
GOW(frexpl, DFDp)
GOM(fscanf, iFEppV)
GO(fseek, iFpli)
-GOW(fseeko, iFpli)
+GO(fseeko, iFpIi)
GO(__fseeko64, iFpli)
-GOW(fseeko64, iFpli)
+GO(fseeko64, iFpli)
GO(__fsetlocking, iFpi)
GO(fsetpos, iFpp)
GO(fsetpos64, iFpp)
@@ -437,14 +437,14 @@ GOW(fstatfs64, iFip)
GOW(fstatvfs, iFip)
GOW(fstatvfs64, iFip)
GO(fsync, iFi)
-GOW(ftell, lFp)
-GOW(ftello, lFp)
+GO(ftell, lFp)
+GO(ftello, IFp)
GO(__ftello64, lFp)
-GOW(ftello64, lFp)
+GO(ftello64, lFp)
GO(ftime, iFp)
GO(ftok, iFpi)
-GOW(ftruncate, iFil)
-GOW(ftruncate64, iFil)
+GO(ftruncate, iFiI)
+GO(ftruncate64, iFil)
GOW(ftrylockfile, iFp)
GOW(fts64_children, pFpi)
GOW(fts64_close, iFp)
@@ -466,7 +466,7 @@ GO(fwide, iFpi)
GOWM(fwprintf, iFEppV)
GOM(__fwprintf_chk, iFEpipV)
GO(__fwritable, iFp)
-GOW(fwrite, LFpLLp)
+GO(fwrite, LFpLLp)
GO(fwrite_unlocked, LFpLLp)
GO(__fwriting, iFp)
//GO(fwscanf, iFppV)
@@ -496,16 +496,16 @@ GOWM(getcontext, iFEp)
GOW(getcpu, iFpp)
GOW(getc_unlocked, iFp)
GO(get_current_dir_name, pFv)
-GOW(getcwd, pFpL)
+GO(getcwd, pFpL)
GO(__getcwd_chk, pFpLL)
GO(getdate, pFp)
//DATAB(getdate_err,
GOW(getdate_r, iFpp)
GOW(__getdelim, lFppip)
-GOW(getdelim, lFppip)
-GOW(getdents64, lFipL)
-GOW(getdirentries, lFipLp)
-GOW(getdirentries64, lFipLp)
+GO(getdelim, lFppip)
+GO(getdents64, lFipL)
+GO(getdirentries, IFipUp)
+GO(getdirentries64, lFipLp)
GO(getdomainname, iFpL)
//GO(__getdomainname_chk,
GOW(getdtablesize, iFv)
@@ -541,7 +541,7 @@ GOW(getifaddrs, iFp)
//GO(getipv4sourcefilter, iFi??pp!)
GOW(getitimer, iFup)
//GO(get_kernel_syms, // Deprecated
-GOW(getline, lFppp)
+GO(getline, lFppp)
GO(getloadavg, iFpi)
GO(getlogin, pFv)
GOW(getlogin_r, iFpL)
@@ -675,7 +675,7 @@ GOW(group_member, iFu)
GOW(gsignal, iFi)
//GO(gtty, // Deprecated
GOW(hasmntopt, pFpp)
-GO(hcreate, iFL)
+GO(hcreate, iFU)
//GOW(hcreate_r, iFL!)
GOW(hdestroy, vFv)
//GOW(hdestroy_r, vF!)
@@ -738,8 +738,8 @@ GOW(inet_pton, iFipp)
//GO(__inet_pton_length,
GO(initgroups, iFpu)
//GO(init_module, // Deprecated
-GOW(initstate, pFupL)
-GOW(initstate_r, iFupLp)
+GO(initstate, pFupL)
+GO(initstate_r, iFupLp)
GO(innetgr, iFpppp)
GO(inotify_add_watch, iFipu)
GO(inotify_init, iFv)
@@ -929,7 +929,7 @@ GOM(__isoc99_fscanf, iFEppV)
//GO(__isoc99_fwscanf, iFppV)
GOM(__isoc99_scanf, iFEpV)
GOM(__isoc99_sscanf, iFEppV)
-//GO(__isoc99_swscanf, iFppV)
+GOM(__isoc99_swscanf, iFEppV)
GOM(__isoc99_vfscanf, iFEppp)
//GO(__isoc99_vfwscanf, iFppA)
//GO(__isoc99_vscanf, iFpA)
@@ -1095,8 +1095,8 @@ GO(localtime, pFp)
GO2(localtime64, pFp, localtime)
GOW(localtime_r, pFpp)
GO2(localtime64_r, pFpp, localtime_r) //Weak
-GO(lockf, iFiil)
-GOW(lockf64, iFiil)
+GO(lockf, iFiiI)
+GO(lockf64, iFiil)
//DATAB(locs,
GOWM(_longjmp, vFEpi)
GOWM(longjmp, vFEpi)
@@ -1106,8 +1106,8 @@ GO(lrand48_r, iFpp)
GO(lremovexattr, iFpp)
GOM(lsearch, pFEpppLp)
GO(__lseek, IFiIi)
-GOW(lseek, lFili)
-GOW(lseek64, lFili)
+GO(lseek, IFiIi)
+GO(lseek64, lFili)
GO(lsetxattr, iFpppLi)
GOM(lstat, iFEpp)
GOM(lstat64, iFEpp)
@@ -1118,27 +1118,27 @@ GO(__madvise, iFpLi)
GOW(madvise, iFpLi)
GOWM(makecontext, iFEppiV)
GOWM(mallinfo, pFEp)
-GO(malloc, pFL) // need to wrap to clear allocated memory?
+GO(malloc, pFL)
//GO(malloc_get_state, // Obsolete
GOW(malloc_info, iFip)
//GO(malloc_set_state, // Obsolete
GOW(malloc_stats, vFv)
-GOW(malloc_trim, iFL)
-GOW(malloc_usable_size, LFp)
+GO(malloc_trim, iFL)
+GO(malloc_usable_size, LFp)
GOW(mallopt, iFii)
//DATAB(mallwatch,
-GO(mblen, iFpL)
+GO(mblen, iFpU)
GO(__mbrlen, LFpLp)
-GOW(mbrlen, LFpLp)
+GO(mbrlen, LFpLp)
//GO(mbrtoc16, LFppL!)
//GOW(mbrtoc32, LFppL!)
GO(__mbrtowc, LFppLp)
-GOW(mbrtowc, LFppLp)
+GO(mbrtowc, LFppLp)
GOW(mbsinit, iFp)
-GOW(mbsnrtowcs, LFppLLp)
-//GO(__mbsnrtowcs_chk,
-GOW(mbsrtowcs, LFppLp)
-//GO(__mbsrtowcs_chk,
+GO(mbsnrtowcs, LFppLLp)
+GO(__mbsnrtowcs_chk, LFppLLpL)
+GO(mbsrtowcs, LFppLp)
+GO(__mbsrtowcs_chk, LFppLpL)
GO(mbstowcs, LFppL)
//GO(__mbstowcs_chk,
GO(mbtowc, iFppL)
@@ -1148,21 +1148,22 @@ GO(mcheck_check_all, vFv)
//GO(_mcleanup,
GO(_mcount, vFpp)
GO2(mcount, vFpp, _mcount)
-GOW(memalign, pFLL)
-GOW(memccpy, pFppiL)
+GO(memalign, pFLL)
+GO(memccpy, pFppiL)
GO(memchr, pFpiL)
GO(memcmp, iFppL)
+GO(__memcmpeq, iFppL)
GO(memcpy, pFppL)
GO(__memcpy_chk, pFppuL)
GO(memfd_create, iFpu)
GO(memfrob, pFpL)
-GOW(memmem, pFpLpL)
-GO(memmove, pFppL)
+GO(memmem, pFpLpL)
+GO(memmove, pFppU)
GO(__memmove_chk, pFppLL)
GO(__mempcpy, pFppL)
GO(mempcpy, pFppL)
GO(__mempcpy_chk, pFppLL)
-GOW(memrchr, pFpiL)
+GO(memrchr, pFpiL)
GO(memset, pFpiL)
GO(__memset_chk, pFpiLL)
//GO(__mempcpy_small,
@@ -1173,8 +1174,8 @@ GO(mkdirat, iFipu)
GO(mkdtemp, pFp)
GO(mkfifo, iFpu)
GO(mkfifoat, iFipu)
-GO(mknod, iFpuu)
-GO(mknodat, iFipuu)
+GO(mknod, iFpuL)
+GO(mknodat, iFipuL)
GO(mkostemp, iFpi)
GOW(mkostemp64, iFpi)
GO(mkostemps, iFpii)
@@ -1204,7 +1205,7 @@ GOW(mount, iFpppLp)
GO(mprobe, iFp)
//GO(__mprotect,
GOWM(mprotect, iFEpLi)
-GO(mrand48, lFv)
+GO(mrand48, IFv)
GO(mrand48_r, iFpp)
GOM(mremap, pFEpLLiN) //weal
GO(msgctl, iFiip)
@@ -1291,7 +1292,7 @@ GOW(openat, iFipON)
GO(__openat_2, iFipO)
GOW(openat64, iFipON)
GO(__openat64_2, iFipO)
-GO(open_by_handle_at, iFipO)
+GO(open_by_handle_at, iFipi)
//GO(__open_catalog,
GOW(opendir, pFp)
GO(openlog, vFpii)
@@ -1303,9 +1304,9 @@ DATA(opterr, sizeof(int))
DATA(optind, sizeof(int))
DATA(optopt, sizeof(int))
GO(__overflow, iFpi)
-//GO(parse_printf_format,
+GO(parse_printf_format, LFpLp)
//GO(passwd2des, // Deprecated
-GOW(pathconf, lFpi)
+GO(pathconf, lFpi)
GOW(pause, iFv)
//GO(__pause_nocancel,
GO(pclose, iFp)
@@ -1313,7 +1314,7 @@ GO(perror, vFp)
GOW(personality, iFL)
GO(__pipe, iFp)
GOW(pipe, iFp)
-GOW(pipe2, iFpO)
+GO(pipe2, iFpi)
//GO(pivot_root, // Deprecated
GO(pkey_alloc, iFuu)
GO(pkey_free, iFi)
@@ -1326,23 +1327,23 @@ GO(pkey_set, iFiu)
GO(pmap_set, iFLLiW)
GO(pmap_unset, iFLL)
GO(__poll, iFpLi)
-GOW(poll, iFpLi)
+GO(poll, iFpLi)
GO(__poll_chk, iFpuiL)
GO(popen, pFpp)
GO(posix_fadvise, iFilli)
-GOW(posix_fadvise64, iFilli)
+GO(posix_fadvise64, iFilli)
GO(posix_fallocate, iFill)
GO(posix_fallocate64, iFill)
//GO(__posix_getopt,
GO(posix_madvise, iFpLi)
-GOW(posix_memalign, iFpLL)
+GO(posix_memalign, iFpLL)
GOW(posix_openpt, iFi)
GOM(posix_spawn, iFEpppppp)
GOW(posix_spawnattr_destroy, iFp)
GO(posix_spawnattr_getflags, iFpp)
GO(posix_spawnattr_getpgroup, iFpp)
-//GO(posix_spawnattr_getschedparam, iF!!)
-//GO(posix_spawnattr_getschedpolicy, iF!p)
+GO(posix_spawnattr_getschedparam, iFpp)
+GO(posix_spawnattr_getschedpolicy, iFpp)
GO(posix_spawnattr_getsigdefault, iFpp)
GO(posix_spawnattr_getsigmask, iFpp)
GOW(posix_spawnattr_init, iFp)
@@ -1361,11 +1362,11 @@ GOW(posix_spawn_file_actions_destroy, iFp)
GOW(posix_spawn_file_actions_init, iFp)
GOM(posix_spawnp, iFEpppppp)
GO(ppoll, iFpLpp)
-//GO(__ppoll_chk,
+GO(__ppoll_chk, iFpuppL)
GOWM(prctl, iFEiLLLL)
-GOW(pread, lFipLl)
+GO(pread, IFipUI)
GOW(__pread64, lFipLI)
-GOW(pread64, lFipLl)
+GO(pread64, lFipLl)
//GO(__pread64_chk,
GO(__pread_chk, lFipLlL)
GO(preadv, lFipil)
@@ -1381,12 +1382,12 @@ GO(prlimit, iFiupp)
GOW(prlimit64, iFiupp)
GO(process_vm_readv, lFipLpLL)
GO(process_vm_writev, lFipLpLL)
-GOW(profil, iFpLLu)
+GO(profil, iFpLLu)
//GO(__profile_frequency,
DATA(__progname, sizeof(void*))
DATA(__progname_full, sizeof(void))
GOW(pselect, iFippppp)
-//GO(psiginfo, vF!p)
+GO(psiginfo, vFpp)
GO(psignal, vFip)
//GO(pthread_attr_destroy,
//GO(pthread_attr_getdetachstate,
@@ -1419,7 +1420,7 @@ GO(psignal, vFip)
//GO(pthread_setcancelstate,
//GO(pthread_setcanceltype,
//GO(pthread_setschedparam,
-GO(ptrace, lFuipp)
+GOM(ptrace, lFEuipp)
GO(ptsname, pFi)
GOW(ptsname_r, iFipL)
//GO(__ptsname_r_chk,
@@ -1438,14 +1439,14 @@ GO(putspent, iFpp)
GOW(pututline, pFp)
GO(pututxline, pFp)
GO(putw, iFip)
-GO(putwc, uFip)
-GO(putwchar, uFi)
-GO(putwchar_unlocked, uFi)
-GO(putwc_unlocked, uFip)
-GOW(pvalloc, pFL)
-GOW(pwrite, lFipLl)
+GO(putwc, uFup)
+GO(putwchar, uFu)
+GO(putwchar_unlocked, uFu)
+GO(putwc_unlocked, uFup)
+GO(pvalloc, pFL)
+GO(pwrite, IFipUI)
//GOW(__pwrite64,
-GOW(pwrite64, lFipLl)
+GO(pwrite64, lFipLl)
GO(pwritev, lFipil)
GO(pwritev2, lFipili)
GO(pwritev64, lFipil)
@@ -1453,7 +1454,7 @@ GO(pwritev64v2, lFipili)
GO(qecvt, pFDipp)
GOW(qecvt_r, iFDipppL)
GO(qfcvt, pFDipp)
-GOW(qfcvt_r, iFDipppL)
+GO(qfcvt_r, iFDipppL)
GO(qgcvt, pFDip)
GOM(qsort, vFEpLLp)
GOWM(qsort_r, vFEpLLpp)
@@ -1472,7 +1473,7 @@ GO(rcmd_af, iFpWppppW)
//DATAB(__rcmd_errstr,
GOW(__read, lFipL)
GO(read, lFipL)
-GOW(readahead, lFilL)
+GO(readahead, lFilL)
GO(__read_chk, lFipLL)
GOW(readdir, pFp) // struct dirent is 280 bytes on x86_64 and ARM64
GOW(readdir64, pFp)
@@ -1485,7 +1486,7 @@ GOM(readlinkat, iFEippL)
//GO(__read_nocancel,
GOW(readv, lFipi)
GO(realloc, pFpL)
-GOW(reallocarray, pFpLL)
+GO(reallocarray, pFpLL)
GOM(realpath, pFEpp)
GO2(__realpath_chk, pFEppv, my_realpath)
GO(reboot, iFi)
@@ -1493,12 +1494,12 @@ GO(reboot, iFi)
GOW(re_compile_fastmap, iFp)
GOW(re_compile_pattern, pFpLp)
GOW(__recv, lFipLi)
-GOW(recv, lFipLi)
+GO(recv, lFipLi)
GO(__recv_chk, lFipLLi)
GOW(recvfrom, lFipLipp)
//GO(__recvfrom_chk,
GO(recvmmsg, iFipuip)
-GOW(recvmsg, lFipi)
+GO(recvmsg, lFipi)
//GOW(re_exec, // Deprecated
GOW(regcomp, iFppi)
GOW(regerror, LFippL)
@@ -1510,7 +1511,7 @@ GOW(register_printf_modifier, iFp)
GOWM(register_printf_specifier, iFEipp)
GOWM(register_printf_type, iFEp)
//GO(registerrpc, // Deprecated?
-GOW(remap_file_pages, iFpLiLi)
+GO(remap_file_pages, iFpLiLi)
//GOW(re_match, iFppii!)
//GOW(re_match_2, iFppipii!i)
//DATA(re_max_failures,
@@ -1560,7 +1561,7 @@ GO(ruserok, iFpipp)
GO(ruserok_af, iFpippW)
//GO(ruserpass,
GO(__sbrk, pFl)
-GOW(sbrk, pFl)
+GO(sbrk, pFl)
GOW(scalbn, dFdi)
GOW(scalbnf, fFfi)
GOW(scalbnl, DFDi)
@@ -1601,16 +1602,16 @@ GO(semget, iFiii)
GO(semop, iFipL)
GO(semtimedop, iFipLp)
GO(__send, lFipLi)
-GOW(send, lFipLi)
+GO(send, lFipLi)
GO(sendfile, lFiipL)
GOW(sendfile64, lFiipL)
GO(__sendmmsg, iFipui)
GOW(sendmmsg, iFipui)
-GOW(sendmsg, lFipi)
+GO(sendmsg, lFipi)
GOW(sendto, lFipLipu)
GO(setaliasent, vFv)
GO(setbuf, vFpp)
-GOW(setbuffer, vFppL)
+GO(setbuffer, vFppL)
GOWM(setcontext, iFEp)
GO(setdomainname, iFpL)
GO(setegid, iFu)
@@ -1666,7 +1667,7 @@ GOW(setuid, iFu)
GO(setusershell, vFv)
GOW(setutent, vFv)
GO(setutxent, vFv)
-GOW(setvbuf, iFppiL)
+GO(setvbuf, iFppiL)
GO(setxattr, iFpppLi)
//GO(sgetsgent,
//GOW(sgetsgent_r,
@@ -1692,7 +1693,7 @@ GO(siggetmask, iFv)
GO(sighold, iFi)
GO(sigignore, iFi)
GO(siginterrupt, iFii)
-//GO(sigisemptyset, iF!)
+GO(sigisemptyset, iFp)
//GO(__sigismember,
GO(sigismember, iFpi)
GOM(siglongjmp, vFEpi)
@@ -1701,7 +1702,7 @@ GO(signalfd, iFipi)
GO(__signbit, iFd)
GO(__signbitf, iFf)
GO(__signbitl, iFD)
-//GO(sigorset, iF!!!)
+GO(sigorset, iFppp)
//GO(__sigpause,
//GOW(sigpause, // Deprecated
GO(sigpending, iFp)
@@ -1713,7 +1714,7 @@ GOM(sigset, pFEip)
GOM(__sigsetjmp, iFEpi)
GOM(sigsetjmp, iFEpi)
GOW(sigsetmask, iFi)
-//GO(sigstack, iF!!)
+GO(sigstack, iFpp)
GO(__sigsuspend, iFp)
GOW(sigsuspend, iFp)
GO(__sigtimedwait, iFppp)
@@ -1735,7 +1736,7 @@ GOM(__sprintf_chk, iFEpilpV)
//GOW(sprofil,
GOW(srand, vFu)
GO(srand48, vFl)
-GOW(srand48_r, iFlp)
+GO(srand48_r, iFlp)
GOW(srandom, vFu)
GOW(srandom_r, iFup)
GOM(sscanf, iFEppV)
@@ -1760,7 +1761,7 @@ GO(stpcpy, pFpp)
GO(__stpcpy_chk, pFppL)
//GO(__stpcpy_small,
GO(__stpncpy, pFppL)
-GOW(stpncpy, pFppL)
+GO(stpncpy, pFppL)
GO(__stpncpy_chk, pFppLL)
GO(__strcasecmp, iFpp)
GO(strcasecmp, iFpp)
@@ -1788,17 +1789,17 @@ GOW(strdup, pFp)
GO(strerror, pFi)
GO(strerror_l, pFip)
GO(__strerror_r, pFipL)
-GOW(strerror_r, pFipL)
+GO(strerror_r, pFipL)
//GO(strfmon, lFpLpV)
//GO(__strfmon_l,
//GOW(strfmon_l, lFpLppV)
GO(strfromd, iFpLpd)
GO(strfromf, iFpLpf)
-//GO(strfromf128,
-GOW(strfromf32, iFpLpf)
-GOW(strfromf32x, iFpLpd)
-GOW(strfromf64, iFpLpd)
-GOW(strfromf64x, iFpLpD)
+GO(strfromf128, iFpLpD)
+GO(strfromf32, iFpLpf)
+GO(strfromf32x, iFpLpd)
+GO(strfromf64, iFpLpd)
+GO(strfromf64x, iFpLpD)
GO(strfroml, iFpLpD)
GO(strfry, pFp)
GO(strftime, LFpLpp)
@@ -1814,7 +1815,7 @@ GO(strncmp, iFppL)
GO(strncpy, pFppL)
GO(__strncpy_chk, pFppLL)
GO(__strndup, pFpL)
-GOW(strndup, pFpL)
+GO(strndup, pFpL)
GO(strnlen, LFpL)
GO(strpbrk, pFpp)
//GO(__strpbrk_c2,
@@ -1839,7 +1840,7 @@ GO(__strtod_l, dFppp)
GOW(strtod_l, dFppp)
//GO(__strtod_nan,
GO(strtof, fFpp)
-//GO(strtof128,
+GO(strtof128, DFpp)
//GO(__strtof128_internal,
//GOW(strtof128_l,
//GO(__strtof128_nan,
@@ -1860,7 +1861,7 @@ GO(strtok, pFpp)
GO(__strtok_r, pFppp)
GOW(strtok_r, pFppp)
//GO(__strtok_r_1c,
-GOW(strtol, lFppi)
+GO(strtol, lFppi)
GO(strtold, DFpp)
GO(__strtold_internal, DFppi)
GO(__strtold_l, DFppp)
@@ -1868,16 +1869,16 @@ GOW(strtold_l, DFppp)
//GO(__strtold_nan,
GO(__strtol_internal, lFppii)
GO(__strtol_l, lFppi)
-GOW(strtol_l, lFppip)
+GO(strtol_l, lFppip)
GOW(strtoll, IFppi)
GO(__strtoll_internal, IFppii)
GOW(__strtoll_l, IFppip)
GOW(strtoll_l, IFppip)
GOW(strtoq, IFppi)
-GOW(strtoul, LFppi)
+GO(strtoul, LFppi)
GO(__strtoul_internal, LFppii)
//GO(__strtoul_l,
-GOW(strtoul_l, LFppip)
+GO(strtoul_l, LFppip)
GOW(strtoull, UFppi)
GO(__strtoull_internal, UFppii)
GOW(__strtoull_l, LFppip)
@@ -1888,7 +1889,7 @@ GOW(strtouq, UFppi)
GOW(strverscmp, iFpp)
GO(strxfrm, LFppL)
GO(__strxfrm_l, LFppLL)
-GOW(strxfrm_l, LFppLp)
+GO(strxfrm_l, LFppLp)
//GO(stty, // Deprecated
//DATAB(svcauthdes_stats,
//GO(svcerr_auth, vF!u)
@@ -1932,7 +1933,7 @@ GO(sync_file_range, iFillu)
GO(syncfs, iFi)
GOM(syscall, lFEv)
GO(__sysconf, lFi)
-GOW(sysconf, lFi)
+GO(sysconf, IFi)
GO(__sysctl, iFpipppL)
GOW(sysctl, iFpipppL) // Deprecated
DATA(_sys_errlist, sizeof(void*))
@@ -1956,14 +1957,14 @@ GO(tcsendbreak, iFii)
GO(tcsetattr, iFiip)
GO(tcsetpgrp, iFii)
//GO(__tdelete,
-//GOW(tdelete, pFpp@)
+GOWM(tdelete, pFEppp)
GOWM(tdestroy, vFEpp)
GO(tee, lFiiLu)
GO(telldir, lFp)
GO(tempnam, pFpp)
GOW(textdomain, pFp)
//GO(__tfind,
-//GOW(tfind, pFpp@)
+GOWM(tfind, pFEppp)
GOW(tgkill, iFiii)
//GO(thrd_current,
//GO(thrd_equal,
@@ -2004,12 +2005,12 @@ GOW(towupper, uFu)
GO(__towupper_l, iFip)
GOW(towupper_l, uFup)
//GO(tr_break,
-GOW(truncate, iFpl)
-GOW(truncate64, iFpl)
+GO(truncate, iFpI)
+GO(truncate64, iFpl)
//GO(__tsearch,
GOWM(tsearch, pFEppp)
GO(ttyname, pFi)
-GOW(ttyname_r, iFipL)
+GO(ttyname_r, iFipL)
//GO(__ttyname_r_chk,
GO(ttyslot, iFv)
//GO(__twalk,
@@ -2047,11 +2048,11 @@ GO(utimensat, iFippi)
GOW(utimes, iFpp)
GOW(utmpname, iFp)
GO(utmpxname, iFp)
-GOW(valloc, pFL)
+GO(valloc, pFL)
GOWM(vasprintf, iFEppA)
GOM(__vasprintf_chk, iFEpipp)
-//GOW(vdprintf, iFipA)
-//GO(__vdprintf_chk,
+GOM(vdprintf, iFEipA)
+GOM(__vdprintf_chk, iFEiipA)
//GO(verr, vFipA)
//GO(verrx, vFipA)
GOW(versionsort, iFpp)
@@ -2073,7 +2074,7 @@ GOM(__vprintf_chk, iFEvpp)
//GOW(vscanf, iFpA)
GOWM(__vsnprintf, iFEpLpA)
GOWM(vsnprintf, iFEpLpA)
-GOM(__vsnprintf_chk, iFEpLvvpp)
+GOM(__vsnprintf_chk, iFEpLiLpp)
GOWM(vsprintf, iFEppA)
GOM(__vsprintf_chk, iFEpvvppp)
GOWM(__vsscanf, iFEppp)
@@ -2086,7 +2087,7 @@ GOM(__vsyslog_chk, vFEiipA)
//GO(vtimes, // Deprecated
//GO(vwarn, vFpA)
//GO(vwarnx, vFpA)
-//GO(vwprintf, iFpA)
+GOM(vwprintf, iFEpA)
//GO(__vwprintf_chk,
//GO(vwscanf, iFpA)
GOW(__wait, iFp)
@@ -2100,17 +2101,17 @@ GOM(warn, vFEpV)
GOM(warnx, vFEpV)
GOW(wcpcpy, pFpp)
//GO(__wcpcpy_chk,
-GOW(wcpncpy, pFppL)
+GO(wcpncpy, pFppL)
//GO(__wcpncpy_chk,
-GOW(wcrtomb, LFpip)
+GO(wcrtomb, LFpup)
//GO(__wcrtomb_chk,
GOW(wcscasecmp, iFpp)
GO(__wcscasecmp_l, iFppp)
GOW(wcscasecmp_l, iFppp)
GOW(wcscat, pFpp)
GO(__wcscat_chk, pFppL)
-GO(wcschr, pFpi)
-GOW(wcschrnul, pFpi)
+GO(wcschr, pFpu)
+GO(wcschrnul, pFpu)
GO(wcscmp, iFpp)
GOW(wcscoll, iFpp)
GO(__wcscoll_l, iFppp)
@@ -2121,9 +2122,9 @@ GO(wcscspn, LFpp)
GO(wcsdup, pFp)
GO(wcsftime, LFpLpp)
GO(__wcsftime_l, LFpLppp)
-GOW(wcsftime_l, LFpLppp)
+GO(wcsftime_l, LFpLppp)
GO(wcslen, LFp)
-GOW(wcsncasecmp, iFppL)
+GO(wcsncasecmp, iFppL)
//GO(__wcsncasecmp_l,
//GOW(wcsncasecmp_l, iFppL!)
GO(wcsncat, pFppL)
@@ -2132,11 +2133,11 @@ GO(wcsncmp, iFppL)
GOW(wcsncpy, pFppL)
GO(__wcsncpy_chk, pFppLL)
GO(wcsnlen, LFpL)
-GOW(wcsnrtombs, LFppLLp)
+GO(wcsnrtombs, LFppLLp)
//GO(__wcsnrtombs_chk,
GO(wcspbrk, pFpp)
-GO(wcsrchr, pFpi)
-GOW(wcsrtombs, LFppLp)
+GO(wcsrchr, pFpu)
+GO(wcsrtombs, LFppLp)
//GO(__wcsrtombs_chk,
GO(wcsspn, LFpp)
GO(wcsstr, pFpp)
@@ -2145,7 +2146,7 @@ GO(wcstod, dFpp)
//GO(__wcstod_l,
//GOW(wcstod_l, dFpp!)
GO(wcstof, fFpp)
-//GO(wcstof128,
+GO(wcstof128, DFpp)
//GO(__wcstof128_internal,
//GOW(wcstof128_l,
GOW(wcstof32, fFpp)
@@ -2161,7 +2162,7 @@ GOW(wcstof64x, DFpp)
//GOW(wcstof_l, fFpp!)
GO(wcstoimax, lFppi)
GO(wcstok, pFppp)
-GOW(wcstol, lFppi)
+GO(wcstol, lFppi)
GO(wcstold, DFpp)
//GO(__wcstold_internal,
//GO(__wcstold_l,
@@ -2176,7 +2177,7 @@ GOW(wcstoll, IFppi)
GO(wcstombs, LFppL)
//GO(__wcstombs_chk,
GOW(wcstoq, IFppi)
-GOW(wcstoul, LFppi)
+GO(wcstoul, LFppi)
//GO(__wcstoul_internal,
//GO(__wcstoul_l,
//GOW(wcstoul_l, LFppi!)
@@ -2190,9 +2191,9 @@ GOW(wcswcs, pFpp)
GO(wcswidth, iFpL)
GO(wcsxfrm, LFppL)
GO(__wcsxfrm_l, LFppLL)
-GOW(wcsxfrm_l, LFppLp)
+GO(wcsxfrm_l, LFppLp)
GO(wctob, iFu)
-GO(wctomb, iFpi)
+GO(wctomb, iFpu)
GO(__wctomb_chk, iFpuL)
GOW(wctrans, pFp)
//GO(__wctrans_l,
@@ -2200,24 +2201,24 @@ GOW(wctrans_l, pFpp)
GOW(wctype, LFp)
GOW(wctype_l, LFpp)
GO(__wctype_l, LFpp)
-GO(wcwidth, iFi)
-GO(wmemchr, pFpiL)
+GO(wcwidth, iFu)
+GO(wmemchr, pFpuL)
GO(wmemcmp, iFppL)
GOW(wmemcpy, pFppL)
GO(__wmemcpy_chk, pFppLL)
-GOW(wmemmove, pFppL)
-//GO(__wmemmove_chk,
+GO(wmemmove, pFppL)
+GO(__wmemmove_chk, pFppLL)
GOW(wmempcpy, pFppL)
//GO(__wmempcpy_chk,
-GO(wmemset, pFpiL)
-//GO(__wmemset_chk,
+GO(wmemset, pFpuL)
+GO(__wmemset_chk, pFpuLL)
GO(wordexp, iFppi)
GO(wordfree, vFp)
//GO(__woverflow,
GOM(wprintf, iFEpV)
GOM(__wprintf_chk, lFEipV)
GOW(__write, lFipL)
-GOW(write, lFipL)
+GO(write, lFipL)
//GO(__write_nocancel,
GOW(writev, lFipi)
//GO(wscanf, iFpV)
diff --git a/src/wrapped/wrappedlibcmusl.c b/src/wrapped/wrappedlibcmusl.c
new file mode 100644
index 0000000..acef30b
--- /dev/null
+++ b/src/wrapped/wrappedlibcmusl.c
@@ -0,0 +1,35 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#define _GNU_SOURCE /* See feature_test_macros(7) */
+#include <dlfcn.h>
+
+#include "wrappedlibs.h"
+
+#include "debug.h"
+#include "wrapper.h"
+#include "bridge.h"
+#include "librarian/library_private.h"
+#include "x64emu.h"
+#include "emu/x64emu_private.h"
+#include "elfloader.h"
+#include "box64context.h"
+#include "x64tls.h"
+
+
+// don't try to load the actual ld-linux (because name is variable), just use box64 itself, as it's linked to ld-linux
+const char* libcmuslName = "libc.musl-x86_64.so.1";
+#define LIBNAME libcmusl
+
+#define PRE_INIT\
+ if(1) \
+ lib->w.lib = dlopen(NULL, RTLD_LAZY | RTLD_GLOBAL); \
+ else
+
+#define CUSTOM_INIT \
+ box64_musl = 1; \
+ setNeededLibs(lib, 4, "libc.so.6", "libdl.so.2", "libm.so.6", "libpthread.so.0");
+
+// define all standard library functions
+#include "wrappedlib_init.h"
+
diff --git a/src/wrapped/wrappedlibcmusl_private.h b/src/wrapped/wrappedlibcmusl_private.h
new file mode 100644
index 0000000..b295d35
--- /dev/null
+++ b/src/wrapped/wrappedlibcmusl_private.h
@@ -0,0 +1,4 @@
+#if !(defined(GO) && defined(GOM) && defined(GO2) && defined(DATA))
+#error meh!
+#endif
+
diff --git a/src/wrapped/wrappedlibcrypt.c b/src/wrapped/wrappedlibcrypt.c
index 58b7e4e..58b7e4e 100755..100644
--- a/src/wrapped/wrappedlibcrypt.c
+++ b/src/wrapped/wrappedlibcrypt.c
diff --git a/src/wrapped/wrappedlibcrypt_private.h b/src/wrapped/wrappedlibcrypt_private.h
index 4c08778..4c08778 100755..100644
--- a/src/wrapped/wrappedlibcrypt_private.h
+++ b/src/wrapped/wrappedlibcrypt_private.h
diff --git a/src/wrapped/wrappedlibcups.c b/src/wrapped/wrappedlibcups.c
index a99f0b4..16ea472 100755..100644
--- a/src/wrapped/wrappedlibcups.c
+++ b/src/wrapped/wrappedlibcups.c
@@ -21,5 +21,54 @@
const char* libcupsName = "libcups.so.2";
#define LIBNAME libcups
+#define ADDED_FUNCTIONS() \
+
+#include "generated/wrappedlibcupstypes.h"
+
+#include "wrappercallback.h"
+
+#define SUPER() \
+GO(0) \
+GO(1) \
+GO(2) \
+GO(3) \
+GO(4)
+
+// cups_dest_cb_t ...
+#define GO(A) \
+static uintptr_t my_cups_dest_cb_t_fct_##A = 0; \
+static int my_cups_dest_cb_t_##A(void* a, uint32_t b, void* c) \
+{ \
+ return (int)RunFunctionFmt(my_cups_dest_cb_t_fct_##A, "pup", a, b, c); \
+}
+SUPER()
+#undef GO
+static void* find_cups_dest_cb_t_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_cups_dest_cb_t_fct_##A == (uintptr_t)fct) return my_cups_dest_cb_t_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_cups_dest_cb_t_fct_##A == 0) {my_cups_dest_cb_t_fct_##A = (uintptr_t)fct; return my_cups_dest_cb_t_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libcups cups_dest_cb_t callback\n");
+ return NULL;
+}
+
+#undef SUPER
+
+EXPORT int my_cupsEnumDests(x64emu_t* emu, uint32_t flags, int msec, int* cancel, uint32_t type, uint32_t mask, void* f, void* data)
+{
+ my->cupsEnumDests(flags, msec, cancel, type, mask, find_cups_dest_cb_t_Fct(f), data);
+}
+
+#define CUSTOM_INIT \
+ getMy(lib);
+
+#define CUSTOM_FINI \
+ freeMy();
+
#include "wrappedlib_init.h"
diff --git a/src/wrapped/wrappedlibcups_private.h b/src/wrapped/wrappedlibcups_private.h
index 83f12f9..4978426 100755..100644
--- a/src/wrapped/wrappedlibcups_private.h
+++ b/src/wrapped/wrappedlibcups_private.h
@@ -52,7 +52,7 @@ GO(cupsAddOption, iFppip)
//GO(_cupsConnect,
//GO(cupsConnectDest,
//GO(_cupsConvertOptions,
-//GO(cupsCopyDest,
+GO(cupsCopyDest, iFpip)
//GO(cupsCopyDestConflicts,
//GO(cupsCopyDestInfo,
//GO(_cupsCreateDest,
@@ -72,7 +72,7 @@ GO(cupsAddOption, iFppip)
//GO(cupsEncodeOptions2,
//GO(_cupsEncodingName,
//GO(cupsEncryption,
-//GO(cupsEnumDests,
+GOM(cupsEnumDests, iFEuipuupp)
//GO(_cupsFileCheck,
//GO(_cupsFileCheckFilter,
//GO(cupsFileClose,
@@ -167,7 +167,7 @@ GO(cupsLastErrorString, pFv)
GO(cupsLocalizeDestOption, pFpppp)
GO(cupsLocalizeDestValue, pFppppp)
//GO(cupsMakeServerCredentials,
-//GO(cupsMarkOptions,
+GO(cupsMarkOptions, iFpip)
//GO(_cupsMessageFree,
//GO(_cupsMessageLoad,
//GO(_cupsMessageLookup,
@@ -282,15 +282,15 @@ GO(cupsSetDefaultDest, vFppip)
//GO(httpAssembleURI,
//GO(httpAssembleURIf,
//GO(httpAssembleUUID,
-//GO(httpBlocking,
+GO(httpBlocking, vFpi)
//GO(httpCheck,
//GO(httpClearCookie,
//GO(httpClearFields,
-//GO(httpClose,
+GO(httpClose, vFp)
//GO(httpCompareCredentials,
//GO(httpConnect,
GO(httpConnect2, pFpipiiiip)
-//GO(httpConnectEncrypt,
+GO(httpConnectEncrypt, pFpii)
//GO(httpCopyCredentials,
//GO(_httpCreateCredentials,
//GO(httpCredentialsAreValidForName,
@@ -306,7 +306,7 @@ GO(httpConnect2, pFpipiiiip)
//GO(httpEncode64_2,
//GO(_httpEncodeURI,
//GO(httpEncryption,
-//GO(httpError,
+GO(httpError, iFp)
//GO(httpFieldValue,
//GO(httpFlush,
//GO(httpFlushWrite,
@@ -503,7 +503,7 @@ GO(httpConnect2, pFpipiiiip)
//GO(_ppdCacheGetSource,
//GO(_ppdCacheGetType,
//GO(_ppdCacheWriteFile,
-//GO(ppdClose,
+GO(ppdClose, vFp)
//GO(ppdCollect,
//GO(ppdCollect2,
//GO(ppdConflicts,
@@ -514,14 +514,14 @@ GO(httpConnect2, pFpipiiiip)
//GO(ppdEmitJCL,
//GO(ppdEmitJCLEnd,
//GO(ppdEmitString,
-//GO(ppdErrorString,
-//GO(ppdFindAttr,
-//GO(ppdFindChoice,
+GO(ppdErrorString, pFi)
+GO(ppdFindAttr, pFppp)
+GO(ppdFindChoice, pFpp)
//GO(ppdFindCustomOption,
//GO(ppdFindCustomParam,
-//GO(ppdFindMarkedChoice,
+GO(ppdFindMarkedChoice, pFpp)
//GO(ppdFindNextAttr,
-//GO(ppdFindOption,
+GO(ppdFindOption, pFpp)
//GO(ppdFirstCustomParam,
//GO(ppdFirstOption,
//GO(_ppdFreeLanguages,
@@ -531,13 +531,13 @@ GO(httpConnect2, pFpipiiiip)
//GO(_ppdHashName,
//GO(ppdInstallableConflict,
//GO(ppdIsMarked,
-//GO(ppdLastError,
+GO(ppdLastError, iFp)
//GO(ppdLocalize,
//GO(ppdLocalizeAttr,
//GO(_ppdLocalizedAttr,
//GO(ppdLocalizeIPPReason,
//GO(ppdLocalizeMarkerName,
-//GO(ppdMarkDefaults,
+GO(ppdMarkDefaults, vFp)
//GO(ppdMarkOption,
//GO(ppdNextCustomParam,
//GO(ppdNextOption,
@@ -545,9 +545,9 @@ GO(httpConnect2, pFpipiiiip)
//GO(_ppdOpen,
//GO(ppdOpen,
//GO(ppdOpen2,
-//GO(ppdOpenFd,
+GO(ppdOpenFd, pFi)
//GO(_ppdOpenFile,
-//GO(ppdOpenFile,
+GO(ppdOpenFile, pFp)
//GO(ppdPageLength,
//GO(ppdPageSize,
//GO(ppdPageSizeLimits,
diff --git a/src/wrapped/wrappedlibdl.c b/src/wrapped/wrappedlibdl.c
index 9dee46b..47c47c6 100755..100644
--- a/src/wrapped/wrappedlibdl.c
+++ b/src/wrapped/wrappedlibdl.c
@@ -19,10 +19,16 @@
#include "elfloader.h"
#include "elfs/elfloader_private.h"
+typedef struct dllib_s {
+ library_t* lib;
+ int count;
+ int dlopened;
+ int is_self;
+ int full;
+} dllib_t;
+
typedef struct dlprivate_s {
- library_t **libs;
- size_t *count;
- size_t *dlopened;
+ dllib_t *dllibs;
size_t lib_sz;
size_t lib_cap;
char* last_error;
@@ -37,8 +43,6 @@ void FreeDLPrivate(dlprivate_t **lib) {
box_free(*lib);
}
-static needed_libs_t dl_loaded = {0};
-
// dead_cells consider the "2" value to be some king of issue?
#define MIN_NLIB 3
@@ -57,6 +61,20 @@ const char* libdlName = "libdl.so.2";
#define CLEARERR if(dl->last_error) box_free(dl->last_error); dl->last_error = NULL;
+void RemoveDlopen(library_t** lib, int idx)
+{
+ if(!my_context)
+ return;
+ dlprivate_t *dl = my_context->dlprivate;
+ if(dl && idx<dl->lib_sz) {
+ if(lib!=&dl->dllibs[idx].lib)
+ dl->dllibs[idx].lib = NULL;
+ dl->dllibs[idx].count = 0;
+ dl->dllibs[idx].dlopened = 0;
+ dl->dllibs[idx].full = 0;
+ }
+}
+
extern int box64_zoom;
// Implementation
void* my_dlopen(x64emu_t* emu, void *filename, int flag)
@@ -112,50 +130,69 @@ void* my_dlopen(x64emu_t* emu, void *filename, int flag)
}
// check if alread dlopenned...
for (size_t i=MIN_NLIB; i<dl->lib_sz; ++i) {
- if(IsSameLib(dl->libs[i], rfilename)) {
+ if(dl->dllibs[i].full && IsSameLib(dl->dllibs[i].lib, rfilename)) {
if(flag&0x4) { // don't re-open in RTLD_NOLOAD mode
- if(dl->count[i]==0 && dl->dlopened[i]) {
+ if(dl->dllibs[i].count==0 && dl->dllibs[i].dlopened) {
printf_dlsym(LOG_DEBUG, " => not present anymore\n");
return NULL; // don't re-open in RTLD_NOLOAD mode
}
}
- IncRefCount(dl->libs[i], emu);
- dl->count[i] = dl->count[i]+1;
- printf_dlsym(LOG_DEBUG, "dlopen: Recycling %s/%p count=%ld (dlopened=%ld, elf_index=%d)\n", rfilename, (void*)(i+1), dl->count[i], dl->dlopened[i], GetElfIndex(dl->libs[i]));
+ IncRefCount(dl->dllibs[i].lib, emu);
+ ++dl->dllibs[i].count;
+ if(!is_local && isLibLocal(dl->dllibs[i].lib))
+ promoteLocalLibGlobal(dl->dllibs[i].lib);
+ printf_dlsym(LOG_DEBUG, "dlopen: Recycling %s/%p count=%ld (dlopened=%ld, elf_index=%d)\n", rfilename, (void*)(i+1), dl->dllibs[i].count, dl->dllibs[i].dlopened, GetElfIndex(dl->dllibs[i].lib));
return (void*)(i+1);
}
}
+ lib = GetLibInternal(rfilename);
if(flag&0x4) { //RTLD_NOLOAD is just a "check" if lib is already loaded
+ if(lib) {
+ if(dl->lib_sz == dl->lib_cap) {
+ dl->lib_cap += 4;
+ dl->dllibs = (dllib_t*)box_realloc(dl->dllibs, sizeof(dllib_t)*dl->lib_cap);
+ // memset count...
+ memset(dl->dllibs+dl->lib_sz, 0, (dl->lib_cap-dl->lib_sz)*sizeof(dllib_t));
+ if(!dl->lib_sz)
+ dl->lib_sz = MIN_NLIB;
+ }
+ intptr_t idx = dl->lib_sz++;
+ dl->dllibs[idx].lib = lib;
+ ++dl->dllibs[idx].count;
+ dl->dllibs[idx].dlopened = dlopened;
+ dl->dllibs[idx].is_self = lib?0:1;
+ dl->dllibs[idx].full = 1;
+ IncRefCount(dl->dllibs[idx].lib, emu);
+ SetDlOpenIdx(lib, idx);
+ printf_dlsym(LOG_DEBUG, "dlopen: New handle %p (%s), dlopened=%ld\n", (void*)(idx+1), (char*)filename, dlopened);
+ return (void*)(idx+1);
+
+ }
printf_dlsym(LOG_DEBUG, " => not present\n");
return NULL;
}
- dlopened = (GetLibInternal(rfilename)==NULL);
+ dlopened = (lib==NULL);
// Then open the lib
- my_context->deferedInit = 1;
+ my_context->deferredInit = 1;
int bindnow = (!box64_musl && (flag&0x2))?1:0;
- needed_libs_t tmp = {0};
- char* names[] = {rfilename};
- library_t* libs[] = { NULL };
- tmp.size = tmp.cap = 1;
- tmp.names = names;
- tmp.libs = libs;
- if(AddNeededLib(NULL, is_local, bindnow, &tmp, my_context, emu)) {
+ needed_libs_t *tmp = new_neededlib(1);
+ tmp->names[0] = rfilename;
+ if(AddNeededLib(NULL, is_local, bindnow, tmp, NULL, my_context, emu)) {
printf_dlsym(strchr(rfilename,'/')?LOG_DEBUG:LOG_INFO, "Warning: Cannot dlopen(\"%s\"/%p, %X)\n", rfilename, filename, flag);
if(!dl->last_error)
dl->last_error = box_malloc(129);
snprintf(dl->last_error, 129, "Cannot dlopen(\"%s\"/%p, %X)\n", rfilename, filename, flag);
+ RemoveNeededLib(NULL, is_local, tmp, my_context, emu);
return NULL;
}
- add1_neededlib(&dl_loaded);
- dl_loaded.names[dl_loaded.size-1] = tmp.names[0];
- dl_loaded.libs[dl_loaded.size-1] = tmp.libs[0];
+ free_neededlib(tmp);
lib = GetLibInternal(rfilename);
- RunDeferedElfInit(emu);
+ RunDeferredElfInit(emu);
} else {
// check if already dlopenned...
for (size_t i=MIN_NLIB; i<dl->lib_sz; ++i) {
- if(!dl->libs[i]) {
- dl->count[i] = dl->count[i]+1;
+ if(dl->dllibs[i].is_self) {
+ ++dl->dllibs[i].count;
return (void*)(i+1);
}
}
@@ -165,18 +202,19 @@ void* my_dlopen(x64emu_t* emu, void *filename, int flag)
if(dl->lib_sz == dl->lib_cap) {
dl->lib_cap += 4;
- dl->libs = (library_t**)box_realloc(dl->libs, sizeof(library_t*)*dl->lib_cap);
- dl->count = (size_t*)box_realloc(dl->count, sizeof(size_t)*dl->lib_cap);
- dl->dlopened = (size_t*)box_realloc(dl->dlopened, sizeof(size_t)*dl->lib_cap);
+ dl->dllibs = (dllib_t*)box_realloc(dl->dllibs, sizeof(dllib_t)*dl->lib_cap);
// memset count...
- memset(dl->count+dl->lib_sz, 0, (dl->lib_cap-dl->lib_sz)*sizeof(size_t));
+ memset(dl->dllibs+dl->lib_sz, 0, (dl->lib_cap-dl->lib_sz)*sizeof(dllib_t));
if(!dl->lib_sz)
dl->lib_sz = MIN_NLIB;
}
- intptr_t idx = dl->lib_sz++;
- dl->libs[idx] = lib;
- dl->count[idx] = dl->count[idx]+1;
- dl->dlopened[idx] = dlopened;
+ intptr_t idx = dl->lib_sz++;
+ dl->dllibs[idx].lib = lib;
+ ++dl->dllibs[idx].count;
+ dl->dllibs[idx].dlopened = dlopened;
+ dl->dllibs[idx].is_self = lib?0:1;
+ dl->dllibs[idx].full = 1;
+ SetDlOpenIdx(lib, idx);
printf_dlsym(LOG_DEBUG, "dlopen: New handle %p (%s), dlopened=%ld\n", (void*)(idx+1), (char*)filename, dlopened);
return (void*)(idx+1);
}
@@ -196,7 +234,7 @@ char* my_dlerror(x64emu_t* emu)
KHASH_SET_INIT_INT(libs);
-int recursive_dlsym_lib(kh_libs_t* collection, library_t* lib, const char* rsymbol, uintptr_t *start, uintptr_t *end, int version, const char* vername)
+int recursive_dlsym_lib(kh_libs_t* collection, library_t* lib, const char* rsymbol, uintptr_t *start, uintptr_t *end, int version, const char* vername, const char* globdefver, const char* weakdefver)
{
if(!lib)
return 0;
@@ -208,60 +246,71 @@ int recursive_dlsym_lib(kh_libs_t* collection, library_t* lib, const char* rsymb
// TODO: should use librarian functions instead!
int weak;
// look in the library itself
- if(lib->getglobal(lib, rsymbol, start, end, 0, &weak, version, vername, 1))
+ if(lib->getglobal(lib, rsymbol, start, end, 0, &weak, version, vername, 1, globdefver))
return 1;
- if(lib->getweak(lib, rsymbol, start, end, 0, &weak, version, vername, 1))
+ if(lib->getweak(lib, rsymbol, start, end, 0, &weak, version, vername, 1, weakdefver))
return 1;
// look in other libs
int n = GetNeededLibsN(lib);
for (int i=0; i<n; ++i) {
library_t *l = GetNeededLib(lib, i);
- if(recursive_dlsym_lib(collection, l, rsymbol, start, end, version, vername))
+ if(recursive_dlsym_lib(collection, l, rsymbol, start, end, version, vername, globdefver, weakdefver))
return 1;
}
return 0;
}
-int my_dlsym_lib(library_t* lib, const char* rsymbol, uintptr_t *start, uintptr_t *end, int version, const char* vername)
+int my_dlsym_lib(library_t* lib, const char* rsymbol, uintptr_t *start, uintptr_t *end, int version, const char* vername, const char* globdefver, const char* weakdefver)
{
kh_libs_t *collection = kh_init(libs);
- int ret = recursive_dlsym_lib(collection, lib, rsymbol, start, end, version, vername);
+ int ret = recursive_dlsym_lib(collection, lib, rsymbol, start, end, version, vername, globdefver, weakdefver);
kh_destroy(libs, collection);
return ret;
}
+int GetTID();
void* my_dlsym(x64emu_t* emu, void *handle, void *symbol)
{
(void)emu;
+ static pthread_mutex_t mutex = PTHREAD_MUTEX_INITIALIZER;
+ pthread_mutex_lock(&mutex);
dlprivate_t *dl = my_context->dlprivate;
uintptr_t start = 0, end = 0;
char* rsymbol = (char*)symbol;
CLEARERR
- printf_dlsym(LOG_DEBUG, "Call to dlsym(%p, \"%s\")%s", handle, rsymbol, dlsym_error?"":"\n");
+ printf_dlsym(LOG_DEBUG, "%04d|Call to dlsym(%p, \"%s\")%s", GetTID(), handle, rsymbol, dlsym_error?"":"\n");
if(handle==NULL) {
// special case, look globably
- if(GetGlobalSymbolStartEnd(my_context->maplib, rsymbol, &start, &end, NULL, -1, NULL)) {
+ const char* globdefver = GetMaplibDefaultVersion(my_context->maplib, NULL, 0, rsymbol);
+ const char* weakdefver = GetMaplibDefaultVersion(my_context->maplib, NULL, 1, rsymbol);
+ if(GetGlobalSymbolStartEnd(my_context->maplib, rsymbol, &start, &end, NULL, -1, NULL, globdefver, weakdefver)) {
printf_dlsym(LOG_NEVER, "%p\n", (void*)start);
+ pthread_mutex_unlock(&mutex);
return (void*)start;
}
if(!dl->last_error)
dl->last_error = box_malloc(129);
snprintf(dl->last_error, 129, "Symbol \"%s\" not found in %p)\n", rsymbol, handle);
printf_dlsym(LOG_NEVER, "%p\n", NULL);
+ pthread_mutex_unlock(&mutex);
return NULL;
}
if(handle==(void*)~0LL) {
// special case, look globably but no self (RTLD_NEXT)
+ const char* globdefver = GetMaplibDefaultVersion(my_context->maplib, NULL, 0, rsymbol);
+ const char* weakdefver = GetMaplibDefaultVersion(my_context->maplib, NULL, 1, rsymbol);
elfheader_t *elf = FindElfAddress(my_context, *(uintptr_t*)R_RSP); // use return address to guess "self"
- if(GetNoSelfSymbolStartEnd(my_context->maplib, rsymbol, &start, &end, elf, 0, -1, NULL)) {
+ if(GetNoSelfSymbolStartEnd(my_context->maplib, rsymbol, &start, &end, elf, 0, -1, NULL, globdefver, weakdefver)) {
printf_dlsym(LOG_NEVER, "%p\n", (void*)start);
+ pthread_mutex_unlock(&mutex);
return (void*)start;
}
if(!dl->last_error)
dl->last_error = box_malloc(129);
snprintf(dl->last_error, 129, "Symbol \"%s\" not found in %p)\n", rsymbol, handle);
printf_dlsym(LOG_NEVER, "%p\n", NULL);
+ pthread_mutex_unlock(&mutex);
return NULL;
}
size_t nlib = (size_t)handle;
@@ -272,41 +321,49 @@ void* my_dlsym(x64emu_t* emu, void *handle, void *symbol)
dl->last_error = box_malloc(129);
snprintf(dl->last_error, 129, "Bad handle %p)\n", handle);
printf_dlsym(LOG_NEVER, "%p\n", NULL);
+ pthread_mutex_unlock(&mutex);
return NULL;
}
- if(dl->count[nlib]==0) {
+ if(!dl->dllibs[nlib].count || !dl->dllibs[nlib].full) {
if(!dl->last_error)
dl->last_error = box_malloc(129);
snprintf(dl->last_error, 129, "Bad handle %p (already closed))\n", handle);
printf_dlsym(LOG_NEVER, "%p\n", (void*)NULL);
+ pthread_mutex_unlock(&mutex);
return NULL;
}
- if(dl->libs[nlib]) {
- if(my_dlsym_lib(dl->libs[nlib], rsymbol, &start, &end, -1, NULL)==0) {
+ if(dl->dllibs[nlib].lib) {
+ const char* globdefver = GetMaplibDefaultVersion(my_context->maplib, (my_context->maplib==dl->dllibs[nlib].lib->maplib)?NULL:dl->dllibs[nlib].lib->maplib, 0, rsymbol);
+ const char* weakdefver = GetMaplibDefaultVersion(my_context->maplib, (my_context->maplib==dl->dllibs[nlib].lib->maplib)?NULL:dl->dllibs[nlib].lib->maplib, 1, rsymbol);
+ if(my_dlsym_lib(dl->dllibs[nlib].lib, rsymbol, &start, &end, -1, NULL, globdefver, weakdefver)==0) {
// not found
- printf_dlsym(LOG_NEVER, "%p\nCall to dlsym(%s, \"%s\") Symbol not found\n", NULL, GetNameLib(dl->libs[nlib]), rsymbol);
+ printf_dlsym(LOG_NEVER, "%p\nCall to dlsym(%s, \"%s\") Symbol not found\n", NULL, GetNameLib(dl->dllibs[nlib].lib), rsymbol);
printf_log(LOG_DEBUG, " Symbol not found\n");
if(!dl->last_error)
dl->last_error = box_malloc(129);
- snprintf(dl->last_error, 129, "Symbol \"%s\" not found in %p(%s)", rsymbol, handle, GetNameLib(dl->libs[nlib]));
+ snprintf(dl->last_error, 129, "Symbol \"%s\" not found in %p(%s)", rsymbol, handle, GetNameLib(dl->dllibs[nlib].lib));
+ pthread_mutex_unlock(&mutex);
return NULL;
}
} else {
// still usefull?
// => look globably
- const char* defver = GetDefaultVersion(my_context->globaldefver, rsymbol);
- if(!defver) defver = GetDefaultVersion(my_context->weakdefver, rsymbol);
- if(GetGlobalSymbolStartEnd(my_context->maplib, rsymbol, &start, &end, NULL, -1, defver)) {
+ const char* globdefver = GetMaplibDefaultVersion(my_context->maplib, NULL, 0, rsymbol);
+ const char* weakdefver = GetMaplibDefaultVersion(my_context->maplib, NULL, 1, rsymbol);
+ if(GetGlobalSymbolStartEnd(my_context->maplib, rsymbol, &start, &end, NULL, -1, NULL, globdefver, weakdefver)) {
printf_dlsym(LOG_NEVER, "%p\n", (void*)start);
+ pthread_mutex_unlock(&mutex);
return (void*)start;
}
if(!dl->last_error)
dl->last_error = box_malloc(129);
snprintf(dl->last_error, 129, "Symbol \"%s\" not found in %p)\n", rsymbol, handle);
printf_dlsym(LOG_NEVER, "%p\n", NULL);
+ pthread_mutex_unlock(&mutex);
return NULL;
}
printf_dlsym(LOG_NEVER, "%p\n", (void*)start);
+ pthread_mutex_unlock(&mutex);
return (void*)start;
}
int my_dlclose(x64emu_t* emu, void *handle)
@@ -325,15 +382,15 @@ int my_dlclose(x64emu_t* emu, void *handle)
printf_dlsym(LOG_DEBUG, "dlclose: %s\n", dl->last_error);
return -1;
}
- if(dl->count[nlib]==0) {
+ if(!dl->dllibs[nlib].count || !dl->dllibs[nlib].full) {
if(!dl->last_error)
dl->last_error = box_malloc(129);
snprintf(dl->last_error, 129, "Bad handle %p (already closed))\n", handle);
printf_dlsym(LOG_DEBUG, "dlclose: %s\n", dl->last_error);
return -1;
}
- dl->count[nlib] = dl->count[nlib]-1;
- FiniLibrary(dl->libs[nlib], emu);
+ --dl->dllibs[nlib].count;
+ DecRefCount(&dl->dllibs[nlib].lib, emu);
return 0;
}
int my_dladdr1(x64emu_t* emu, void *addr, void *i, void** extra_info, int flags)
@@ -372,7 +429,9 @@ void* my_dlvsym(x64emu_t* emu, void *handle, void *symbol, const char *vername)
printf_dlsym(LOG_DEBUG, "Call to dlvsym(%p, \"%s\", %s)%s", handle, rsymbol, vername?vername:"(nil)", dlsym_error?"":"\n");
if(handle==NULL) {
// special case, look globably
- if(GetGlobalSymbolStartEnd(my_context->maplib, rsymbol, &start, &end, NULL, version, vername)) {
+ const char* globdefver = GetMaplibDefaultVersion(my_context->maplib, NULL, 0, rsymbol);
+ const char* weakdefver = GetMaplibDefaultVersion(my_context->maplib, NULL, 1, rsymbol);
+ if(GetGlobalSymbolStartEnd(my_context->maplib, rsymbol, &start, &end, NULL, version, vername, globdefver, weakdefver)) {
printf_dlsym(LOG_NEVER, "%p\n", (void*)start);
return (void*)start;
}
@@ -384,8 +443,10 @@ void* my_dlvsym(x64emu_t* emu, void *handle, void *symbol, const char *vername)
}
if(handle==(void*)~0LL) {
// special case, look globably but no self (RTLD_NEXT)
+ const char* globdefver = GetMaplibDefaultVersion(my_context->maplib, NULL, 0, rsymbol);
+ const char* weakdefver = GetMaplibDefaultVersion(my_context->maplib, NULL, 1, rsymbol);
elfheader_t *elf = FindElfAddress(my_context, *(uintptr_t*)R_RSP); // use return address to guess "self"
- if(GetNoSelfSymbolStartEnd(my_context->maplib, rsymbol, &start, &end, elf, 0, version, vername)) {
+ if(GetNoSelfSymbolStartEnd(my_context->maplib, rsymbol, &start, &end, elf, 0, version, vername, globdefver, weakdefver)) {
printf_dlsym(LOG_NEVER, "%p\n", (void*)start);
return (void*)start;
}
@@ -405,28 +466,30 @@ void* my_dlvsym(x64emu_t* emu, void *handle, void *symbol, const char *vername)
printf_dlsym(LOG_NEVER, "%p\n", NULL);
return NULL;
}
- if(dl->count[nlib]==0) {
+ if(!dl->dllibs[nlib].count || !dl->dllibs[nlib].full) {
if(!dl->last_error)
dl->last_error = box_malloc(129);
snprintf(dl->last_error, 129, "Bad handle %p (already closed))\n", handle);
printf_dlsym(LOG_NEVER, "%p\n", (void*)NULL);
return NULL;
}
- if(dl->libs[nlib]) {
- if(my_dlsym_lib(dl->libs[nlib], rsymbol, &start, &end, version, vername)==0) {
+ if(dl->dllibs[nlib].lib) {
+ const char* globdefver = GetMaplibDefaultVersion(my_context->maplib, (my_context->maplib==dl->dllibs[nlib].lib->maplib)?NULL:dl->dllibs[nlib].lib->maplib, 0, rsymbol);
+ const char* weakdefver = GetMaplibDefaultVersion(my_context->maplib, (my_context->maplib==dl->dllibs[nlib].lib->maplib)?NULL:dl->dllibs[nlib].lib->maplib, 1, rsymbol);
+ if(my_dlsym_lib(dl->dllibs[nlib].lib, rsymbol, &start, &end, version, vername, globdefver, weakdefver)==0) {
// not found
- printf_dlsym(LOG_NEVER, "%p\nCall to dlvsym(%s, \"%s\", %s) Symbol not found\n", NULL, GetNameLib(dl->libs[nlib]), rsymbol, vername?vername:"(nil)");
+ printf_dlsym(LOG_NEVER, "%p\nCall to dlvsym(%s, \"%s\", %s) Symbol not found\n", NULL, GetNameLib(dl->dllibs[nlib].lib), rsymbol, vername?vername:"(nil)");
printf_log(LOG_DEBUG, " Symbol not found\n");
if(!dl->last_error)
dl->last_error = box_malloc(129);
- snprintf(dl->last_error, 129, "Symbol \"%s\" not found in %p(%s)", rsymbol, handle, GetNameLib(dl->libs[nlib]));
+ snprintf(dl->last_error, 129, "Symbol \"%s\" not found in %p(%s)", rsymbol, handle, GetNameLib(dl->dllibs[nlib].lib));
return NULL;
}
} else {
// still usefull?
- const char* defver = GetDefaultVersion(my_context->globaldefver, rsymbol);
- if(!defver) defver = GetDefaultVersion(my_context->weakdefver, rsymbol);
- if(GetGlobalSymbolStartEnd(my_context->maplib, rsymbol, &start, &end, NULL, -1, defver)) {
+ const char* globdefver = GetMaplibDefaultVersion(my_context->maplib, NULL, 0, rsymbol);
+ const char* weakdefver = GetMaplibDefaultVersion(my_context->maplib, NULL, 1, rsymbol);
+ if(GetGlobalSymbolStartEnd(my_context->maplib, rsymbol, &start, &end, NULL, -1, NULL, globdefver, weakdefver)) {
printf_dlsym(LOG_NEVER, "%p\n", (void*)start);
return (void*)start;
}
@@ -458,14 +521,14 @@ int my_dlinfo(x64emu_t* emu, void* handle, int request, void* info)
printf_dlsym(LOG_DEBUG, "dlinfo: %s\n", dl->last_error);
return -1;
}
- if(dl->count[nlib]==0) {
+ if(!dl->dllibs[nlib].count || !dl->dllibs[nlib].full) {
if(!dl->last_error)
dl->last_error = box_malloc(129);
snprintf(dl->last_error, 129, "Bad handle %p (already closed))\n", handle);
printf_dlsym(LOG_DEBUG, "dlinfo: %s\n", dl->last_error);
return -1;
}
- library_t *lib = dl->libs[nlib];
+ library_t *lib = dl->dllibs[nlib].lib;
//elfheader_t *h = (GetElfIndex(lib)>-1)?my_context->elfs[GetElfIndex(lib)]:NULL;
switch(request) {
case 2: // RTLD_DI_LINKMAP
@@ -493,7 +556,19 @@ typedef struct my_dl_find_object_s {
EXPORT int my__dl_find_object(x64emu_t* emu, void* addr, my_dl_find_object_t* result)
{
- printf_log(LOG_INFO, "Unimplemented _dl_find_object called\n");
+ //printf_log(LOG_INFO, "Unimplemented _dl_find_object called\n");
+ uintptr_t start=0, sz=0;
+ elfheader_t* h = FindElfAddress(my_context, (uintptr_t)addr);
+ if(h) {
+ // find an actual elf
+ const char* name = FindNearestSymbolName(h, addr, &start, &sz);
+ result->dlfo_map_start = (void*)start;
+ result->dlfo_map_end = (void*)(start+sz-1);
+ result->dlfo_eh_frame = (void*)(h->ehframehdr+h->delta);
+ result->dlfo_flags = 0; // unused it seems
+ result->dlf_link_map = (struct link_map *)getLinkMapElf(h);
+ return 0;
+ }
return -1;
}
diff --git a/src/wrapped/wrappedlibdl_private.h b/src/wrapped/wrappedlibdl_private.h
index f547ffb..f547ffb 100755..100644
--- a/src/wrapped/wrappedlibdl_private.h
+++ b/src/wrapped/wrappedlibdl_private.h
diff --git a/src/wrapped/wrappedlibdrm.c b/src/wrapped/wrappedlibdrm.c
index 01f4967..01f4967 100755..100644
--- a/src/wrapped/wrappedlibdrm.c
+++ b/src/wrapped/wrappedlibdrm.c
diff --git a/src/wrapped/wrappedlibdrm_private.h b/src/wrapped/wrappedlibdrm_private.h
index 8116d2a..a368b88 100755..100644
--- a/src/wrapped/wrappedlibdrm_private.h
+++ b/src/wrapped/wrappedlibdrm_private.h
@@ -64,7 +64,7 @@ GO(drmFreeVersion, vFp)
GO(drmGetDeviceNameFromFd, pFi)
//GO(drmGetDeviceNameFromFd2,
GO(drmGetDevices, iFpi)
-//GO(drmGetDevices2,
+GO(drmGetDevices2, iFupi)
//GO(drmGetEntry,
//GO(drmGetHashTable,
//GO(drmGetInterruptFromBusID,
@@ -79,14 +79,14 @@ GO(drmGetNodeTypeFromFd, iFi)
//GO(drmGetStats,
GO(drmGetVersion, pFi)
//GO(drmHandleEvent,
-//GO(drmHashCreate,
-//GO(drmHashDelete,
-//GO(drmHashDestroy,
-//GO(drmHashFirst,
-//GO(drmHashInsert,
-//GO(drmHashLookup,
-//GO(drmHashNext,
-//GO(drmIoctl,
+GO(drmHashCreate, pFv)
+GO(drmHashDelete, iFpL)
+GO(drmHashDestroy, iFp)
+GO(drmHashFirst, iFppp)
+GO(drmHashInsert, iFpLL)
+GO(drmHashLookup, iFpLp)
+GO(drmHashNext, iFppp)
+GO(drmIoctl, iFiLp)
//GO(drmIsMaster,
//GO(drmMalloc,
//GO(drmMap,
diff --git a/src/wrapped/wrappedlibegl.c b/src/wrapped/wrappedlibegl.c
index 2a19ed9..2a19ed9 100755..100644
--- a/src/wrapped/wrappedlibegl.c
+++ b/src/wrapped/wrappedlibegl.c
diff --git a/src/wrapped/wrappedlibegl_private.h b/src/wrapped/wrappedlibegl_private.h
index e109388..e109388 100755..100644
--- a/src/wrapped/wrappedlibegl_private.h
+++ b/src/wrapped/wrappedlibegl_private.h
diff --git a/src/wrapped/wrappedlibfuse.c b/src/wrapped/wrappedlibfuse.c
index ee75fa3..2bac509 100755..100644
--- a/src/wrapped/wrappedlibfuse.c
+++ b/src/wrapped/wrappedlibfuse.c
@@ -140,10 +140,10 @@ GO(3)
// fuse_opt_proc
#define GO(A) \
-static uintptr_t my_fuse_opt_proc_fct_##A = 0; \
-static int my_fuse_opt_proc_##A(void* a, void* b, int c, void* d) \
-{ \
- return (int)RunFunction(my_context, my_fuse_opt_proc_fct_##A, 4, a, b, c, d); \
+static uintptr_t my_fuse_opt_proc_fct_##A = 0; \
+static int my_fuse_opt_proc_##A(void* a, void* b, int c, void* d) \
+{ \
+ return (int)RunFunctionFmt(my_fuse_opt_proc_fct_##A, "ppip", a, b, c, d); \
}
SUPER()
#undef GO
@@ -163,11 +163,11 @@ static void* findfuse_opt_procFct(void* fct)
// init
#define GO(A) \
-static uintptr_t my_init_fct_##A = 0; \
-static void my_init_##A(void* a, void* b) \
-{ \
- printf_log(LOG_DEBUG, "fuse: call %s\n", "init"); \
- RunFunction(my_context, my_init_fct_##A, 2, a, b);\
+static uintptr_t my_init_fct_##A = 0; \
+static void my_init_##A(void* a, void* b) \
+{ \
+ printf_log(LOG_DEBUG, "fuse: call %s\n", "init"); \
+ RunFunctionFmt(my_init_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -187,11 +187,11 @@ static void* find_init_Fct(void* fct)
// destroy
#define GO(A) \
-static uintptr_t my_destroy_fct_##A = 0; \
-static void my_destroy_##A(void* a) \
-{ \
- printf_log(LOG_DEBUG, "fuse: call %s\n", "destroy"); \
- RunFunction(my_context, my_destroy_fct_##A, 1, a); \
+static uintptr_t my_destroy_fct_##A = 0; \
+static void my_destroy_##A(void* a) \
+{ \
+ printf_log(LOG_DEBUG, "fuse: call %s\n", "destroy"); \
+ RunFunctionFmt(my_destroy_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -215,7 +215,7 @@ static uintptr_t my_lookup_fct_##A = 0;
static void my_lookup_##A(void* a, unsigned long b, const char* c) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s(%p, %lu, %s)\n", "lookup", a, b, c); \
- RunFunction(my_context, my_lookup_fct_##A, 3, a, b, c); \
+ RunFunctionFmt(my_lookup_fct_##A, "pLp", a, b, c); \
}
SUPER()
#undef GO
@@ -235,11 +235,11 @@ static void* find_lookup_Fct(void* fct)
// forget
#define GO(A) \
-static uintptr_t my_forget_fct_##A = 0; \
-static void my_forget_##A(void* a, unsigned long b, unsigned long c)\
-{ \
- printf_log(LOG_DEBUG, "fuse: call %s\n", "forget"); \
- RunFunction(my_context, my_forget_fct_##A, 3, a, b, c); \
+static uintptr_t my_forget_fct_##A = 0; \
+static void my_forget_##A(void* a, unsigned long b, unsigned long c) \
+{ \
+ printf_log(LOG_DEBUG, "fuse: call %s\n", "forget"); \
+ RunFunctionFmt(my_forget_fct_##A, "pLL", a, b, c); \
}
SUPER()
#undef GO
@@ -259,11 +259,11 @@ static void* find_forget_Fct(void* fct)
// getattr
#define GO(A) \
-static uintptr_t my_getattr_fct_##A = 0; \
-static void my_getattr_##A(void* a, unsigned long b, void* c) \
-{ \
- printf_log(LOG_DEBUG, "fuse: call %s\n", "getattr"); \
- RunFunction(my_context, my_getattr_fct_##A, 3, a, b, c); \
+static uintptr_t my_getattr_fct_##A = 0; \
+static void my_getattr_##A(void* a, unsigned long b, void* c) \
+{ \
+ printf_log(LOG_DEBUG, "fuse: call %s\n", "getattr"); \
+ RunFunctionFmt(my_getattr_fct_##A, "pLp", a, b, c); \
}
SUPER()
#undef GO
@@ -283,13 +283,13 @@ static void* find_getattr_Fct(void* fct)
// setattr
#define GO(A) \
-static uintptr_t my_setattr_fct_##A = 0; \
-static void my_setattr_##A(void* a, unsigned long b, struct stat* c, int d, void* e) \
-{ \
- struct stat c_; \
- AlignStat64(c, &c_); \
- printf_log(LOG_DEBUG, "fuse: call %s\n", "setattr"); \
- RunFunction(my_context, my_setattr_fct_##A, 5, a, b, &c_, d, e); \
+static uintptr_t my_setattr_fct_##A = 0; \
+static void my_setattr_##A(void* a, unsigned long b, struct stat* c, int d, void* e)\
+{ \
+ struct stat c_; \
+ AlignStat64(c, &c_); \
+ printf_log(LOG_DEBUG, "fuse: call %s\n", "setattr"); \
+ RunFunctionFmt(my_setattr_fct_##A, "pLpip", a, b, &c_, d, e); \
}
SUPER()
#undef GO
@@ -309,11 +309,11 @@ static void* find_setattr_Fct(void* fct)
// readlink
#define GO(A) \
-static uintptr_t my_readlink_fct_##A = 0; \
-static void my_readlink_##A(void* a, unsigned long b) \
-{ \
- printf_log(LOG_DEBUG, "fuse: call %s\n", "readlink"); \
- RunFunction(my_context, my_readlink_fct_##A, 2, a, b); \
+static uintptr_t my_readlink_fct_##A = 0; \
+static void my_readlink_##A(void* a, unsigned long b) \
+{ \
+ printf_log(LOG_DEBUG, "fuse: call %s\n", "readlink"); \
+ RunFunctionFmt(my_readlink_fct_##A, "pL", a, b); \
}
SUPER()
#undef GO
@@ -336,8 +336,8 @@ static void* find_readlink_Fct(void* fct)
static uintptr_t my_mknod_fct_##A = 0; \
static void my_mknod_##A(void* a, unsigned long b, const char* c, mode_t d, dev_t e) \
{ \
- printf_log(LOG_DEBUG, "fuse: call %s\n", "mknod"); \
- RunFunction(my_context, my_mknod_fct_##A, 5, a, b, c, of_convert(d), e); \
+ printf_log(LOG_DEBUG, "fuse: call %s\n", "mknod"); \
+ RunFunctionFmt(my_mknod_fct_##A, "pLpuL", a, b, c, of_convert(d), e); \
}
SUPER()
#undef GO
@@ -357,11 +357,11 @@ static void* find_mknod_Fct(void* fct)
// mkdir
#define GO(A) \
-static uintptr_t my_mkdir_fct_##A = 0; \
-static void my_mkdir_##A(void* a, unsigned long b, const char* c, mode_t d) \
-{ \
- printf_log(LOG_DEBUG, "fuse: call %s\n", "mkdir"); \
- RunFunction(my_context, my_mkdir_fct_##A, 4, a, b, c, of_convert(d)); \
+static uintptr_t my_mkdir_fct_##A = 0; \
+static void my_mkdir_##A(void* a, unsigned long b, const char* c, mode_t d) \
+{ \
+ printf_log(LOG_DEBUG, "fuse: call %s\n", "mkdir"); \
+ RunFunctionFmt(my_mkdir_fct_##A, "pLpu", a, b, c, of_convert(d)); \
}
SUPER()
#undef GO
@@ -385,7 +385,7 @@ static uintptr_t my_unlink_fct_##A = 0; \
static void my_unlink_##A(void* a, unsigned long b, const char* c) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "unlink"); \
- RunFunction(my_context, my_unlink_fct_##A, 3, a, b, c); \
+ RunFunctionFmt(my_unlink_fct_##A, "pLp", a, b, c); \
}
SUPER()
#undef GO
@@ -405,11 +405,11 @@ static void* find_unlink_Fct(void* fct)
// rmdir
#define GO(A) \
-static uintptr_t my_rmdir_fct_##A = 0; \
-static void my_rmdir_##A(void* a, unsigned long b, const char* c) \
+static uintptr_t my_rmdir_fct_##A = 0; \
+static void my_rmdir_##A(void* a, unsigned long b, const char* c) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "rmdir"); \
- RunFunction(my_context, my_rmdir_fct_##A, 3, a, b, c); \
+ RunFunctionFmt(my_rmdir_fct_##A, "pLp", a, b, c); \
}
SUPER()
#undef GO
@@ -429,11 +429,11 @@ static void* find_rmdir_Fct(void* fct)
// symlink
#define GO(A) \
-static uintptr_t my_symlink_fct_##A = 0; \
+static uintptr_t my_symlink_fct_##A = 0; \
static void my_symlink_##A(void* a, const char* b, unsigned long c, const char* d) \
-{ \
+{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "symlink"); \
- RunFunction(my_context, my_symlink_fct_##A, 4, a, b, c, d); \
+ RunFunctionFmt(my_symlink_fct_##A, "ppLp", a, b, c, d); \
}
SUPER()
#undef GO
@@ -453,11 +453,11 @@ static void* find_symlink_Fct(void* fct)
// rename
#define GO(A) \
-static uintptr_t my_rename_fct_##A = 0; \
+static uintptr_t my_rename_fct_##A = 0; \
static void my_rename_##A(void* a, unsigned long b, const char* c, unsigned long d, const char* e) \
-{ \
- printf_log(LOG_DEBUG, "fuse: call %s\n", "rename"); \
- RunFunction(my_context, my_rename_fct_##A, 5, a, b, c, d, e); \
+{ \
+ printf_log(LOG_DEBUG, "fuse: call %s\n", "rename"); \
+ RunFunctionFmt(my_rename_fct_##A, "pLpLp", a, b, c, d, e); \
}
SUPER()
#undef GO
@@ -477,11 +477,11 @@ static void* find_rename_Fct(void* fct)
// link
#define GO(A) \
-static uintptr_t my_link_fct_##A = 0; \
+static uintptr_t my_link_fct_##A = 0; \
static void my_link_##A(void* a, unsigned long b, unsigned long c, const char* d) \
-{ \
- printf_log(LOG_DEBUG, "fuse: call %s\n", "link"); \
- RunFunction(my_context, my_link_fct_##A, 4, a, b, c, d); \
+{ \
+ printf_log(LOG_DEBUG, "fuse: call %s\n", "link"); \
+ RunFunctionFmt(my_link_fct_##A, "pLLp", a, b, c, d); \
}
SUPER()
#undef GO
@@ -501,11 +501,11 @@ static void* find_link_Fct(void* fct)
// open
#define GO(A) \
-static uintptr_t my_open_fct_##A = 0; \
-static void my_open_##A(void* a, unsigned long b, const char* c)\
-{ \
+static uintptr_t my_open_fct_##A = 0; \
+static void my_open_##A(void* a, unsigned long b, const char* c) \
+{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "open"); \
- RunFunction(my_context, my_open_fct_##A, 3, a, b, c); \
+ RunFunctionFmt(my_open_fct_##A, "pLp", a, b, c); \
}
SUPER()
#undef GO
@@ -525,11 +525,11 @@ static void* find_open_Fct(void* fct)
// read
#define GO(A) \
-static uintptr_t my_read_fct_##A = 0; \
+static uintptr_t my_read_fct_##A = 0; \
static void my_read_##A(void* a, unsigned long b, const char* c, size_t d, off_t e, void* f) \
-{ \
- printf_log(LOG_DEBUG, "fuse: call %s\n", "read"); \
- RunFunction(my_context, my_read_fct_##A, 6, a, b, c, d, e, f); \
+{ \
+ printf_log(LOG_DEBUG, "fuse: call %s\n", "read"); \
+ RunFunctionFmt(my_read_fct_##A, "pLpLlp", a, b, c, d, e, f); \
}
SUPER()
#undef GO
@@ -549,11 +549,11 @@ static void* find_read_Fct(void* fct)
// write
#define GO(A) \
-static uintptr_t my_write_fct_##A = 0; \
+static uintptr_t my_write_fct_##A = 0; \
static void my_write_##A(void* a, unsigned long b, const char* c, size_t d, off_t e, void* f) \
-{ \
- printf_log(LOG_DEBUG, "fuse: call %s\n", "write"); \
- RunFunction(my_context, my_write_fct_##A, 6, a, b, c, d, e, f); \
+{ \
+ printf_log(LOG_DEBUG, "fuse: call %s\n", "write"); \
+ RunFunctionFmt(my_write_fct_##A, "pLpLlp", a, b, c, d, e, f); \
}
SUPER()
#undef GO
@@ -577,7 +577,7 @@ static uintptr_t my_flush_fct_##A = 0; \
static void my_flush_##A(void* a, unsigned long b, const char* c) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "flush"); \
- RunFunction(my_context, my_flush_fct_##A, 3, a, b, c); \
+ RunFunctionFmt(my_flush_fct_##A, "pLp", a, b, c); \
}
SUPER()
#undef GO
@@ -597,11 +597,11 @@ static void* find_flush_Fct(void* fct)
// release
#define GO(A) \
-static uintptr_t my_release_fct_##A = 0; \
-static void my_release_##A(void* a, unsigned long b, const char* c) \
+static uintptr_t my_release_fct_##A = 0; \
+static void my_release_##A(void* a, unsigned long b, const char* c) \
{ \
- printf_log(LOG_DEBUG, "fuse: call %s\n", "release"); \
- RunFunction(my_context, my_release_fct_##A, 3, a, b, c); \
+ printf_log(LOG_DEBUG, "fuse: call %s\n", "release"); \
+ RunFunctionFmt(my_release_fct_##A, "pLp", a, b, c); \
}
SUPER()
#undef GO
@@ -621,11 +621,11 @@ static void* find_release_Fct(void* fct)
// fsync
#define GO(A) \
-static uintptr_t my_fsync_fct_##A = 0; \
-static void my_fsync_##A(void* a, unsigned long b, int c, void* d) \
-{ \
- printf_log(LOG_DEBUG, "fuse: call %s\n", "fsync"); \
- RunFunction(my_context, my_fsync_fct_##A, 4, a, b, c, d); \
+static uintptr_t my_fsync_fct_##A = 0; \
+static void my_fsync_##A(void* a, unsigned long b, int c, void* d) \
+{ \
+ printf_log(LOG_DEBUG, "fuse: call %s\n", "fsync"); \
+ RunFunctionFmt(my_fsync_fct_##A, "pLip", a, b, c, d); \
}
SUPER()
#undef GO
@@ -649,7 +649,7 @@ static uintptr_t my_opendir_fct_##A = 0;
static void my_opendir_##A(void* a, unsigned long b, void* c) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s(%p, %lu, %p)\n", "opendir", a, b, c); \
- RunFunction(my_context, my_opendir_fct_##A, 3, a, b, c); \
+ RunFunctionFmt(my_opendir_fct_##A, "pLp", a, b, c); \
}
SUPER()
#undef GO
@@ -673,7 +673,7 @@ static uintptr_t my_readdir_fct_##A = 0;
static void my_readdir_##A(void* a, unsigned long b, size_t c, off_t d, void* e) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "readdir"); \
- RunFunction(my_context, my_readdir_fct_##A, 5, a, b, c, d, e); \
+ RunFunctionFmt(my_readdir_fct_##A, "pLLlp", a, b, c, d, e); \
}
SUPER()
#undef GO
@@ -697,7 +697,7 @@ static uintptr_t my_releasedir_fct_##A = 0;
static void my_releasedir_##A(void* a, unsigned long b, void* c) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s(%p, %lu, %p)\n", "releasedir", a, b, c); \
- RunFunction(my_context, my_releasedir_fct_##A, 3, a, b, c); \
+ RunFunctionFmt(my_releasedir_fct_##A, "pLp", a, b, c); \
}
SUPER()
#undef GO
@@ -721,7 +721,7 @@ static uintptr_t my_fsyncdir_fct_##A = 0; \
static void my_fsyncdir_##A(void* a, unsigned long b, int c, void* d) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "fsyncdir"); \
- RunFunction(my_context, my_fsyncdir_fct_##A, 4, a, b, c, d); \
+ RunFunctionFmt(my_fsyncdir_fct_##A, "pLip", a, b, c, d); \
}
SUPER()
#undef GO
@@ -745,7 +745,7 @@ static uintptr_t my_statfs_fct_##A = 0; \
static void my_statfs_##A(void* a, unsigned long b) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "statfs"); \
- RunFunction(my_context, my_statfs_fct_##A, 2, a, b); \
+ RunFunctionFmt(my_statfs_fct_##A, "pL", a, b); \
}
SUPER()
#undef GO
@@ -769,7 +769,7 @@ static uintptr_t my_setxattr_fct_##A = 0;
static void my_setxattr_##A(void* a, unsigned long b, const char* c, const char* d, size_t e, int f) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "setxattr"); \
- RunFunction(my_context, my_setxattr_fct_##A, 6, a, b, c, d, e, f); \
+ RunFunctionFmt(my_setxattr_fct_##A, "pLppLi", a, b, c, d, e, f); \
}
SUPER()
#undef GO
@@ -793,7 +793,7 @@ static uintptr_t my_getxattr_fct_##A = 0;
static void my_getxattr_##A(void* a, unsigned long b, const char* c, const char* d, size_t e) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "getxattr"); \
- RunFunction(my_context, my_getxattr_fct_##A, 5, a, b, c, d, e); \
+ RunFunctionFmt(my_getxattr_fct_##A, "pLppL", a, b, c, d, e); \
}
SUPER()
#undef GO
@@ -817,7 +817,7 @@ static uintptr_t my_listxattr_fct_##A = 0; \
static void my_listxattr_##A(void* a, unsigned long b, size_t c)\
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "listxattr"); \
- RunFunction(my_context, my_listxattr_fct_##A, 3, a, b, c); \
+ RunFunctionFmt(my_listxattr_fct_##A, "pLL", a, b, c); \
}
SUPER()
#undef GO
@@ -841,7 +841,7 @@ static uintptr_t my_removexattr_fct_##A = 0; \
static void my_removexattr_##A(void* a, unsigned long b, const char* c) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "removexattr"); \
- RunFunction(my_context, my_removexattr_fct_##A, 3, a, b, c); \
+ RunFunctionFmt(my_removexattr_fct_##A, "pLp", a, b, c); \
}
SUPER()
#undef GO
@@ -865,7 +865,7 @@ static uintptr_t my_access_fct_##A = 0; \
static void my_access_##A(void* a, unsigned long b, int c) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "access"); \
- RunFunction(my_context, my_access_fct_##A, 3, a, b, c); \
+ RunFunctionFmt(my_access_fct_##A, "pLi", a, b, c); \
}
SUPER()
#undef GO
@@ -889,7 +889,7 @@ static uintptr_t my_create_fct_##A = 0;
static void my_create_##A(void* a, unsigned long b, const char* c, mode_t d, void* e) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "create"); \
- RunFunction(my_context, my_create_fct_##A, 5, a, b, c, of_convert(d), e); \
+ RunFunctionFmt(my_create_fct_##A, "pLpup", a, b, c, of_convert(d), e); \
}
SUPER()
#undef GO
@@ -913,7 +913,7 @@ static uintptr_t my_getlk_fct_##A = 0; \
static void my_getlk_##A(void* a, unsigned long b, void* c, void* d)\
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "getlk"); \
- RunFunction(my_context, my_getlk_fct_##A, 4, a, b, c, d); \
+ RunFunctionFmt(my_getlk_fct_##A, "pLpp", a, b, c, d); \
}
SUPER()
#undef GO
@@ -937,7 +937,7 @@ static uintptr_t my_setlk_fct_##A = 0; \
static void my_setlk_##A(void* a, unsigned long b, void* c, void* d, int e) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "setlk"); \
- RunFunction(my_context, my_setlk_fct_##A, 5, a, b, c, d, e); \
+ RunFunctionFmt(my_setlk_fct_##A, "pLppi", a, b, c, d, e); \
}
SUPER()
#undef GO
@@ -961,7 +961,7 @@ static uintptr_t my_bmap_fct_##A = 0; \
static void my_bmap_##A(void* a, unsigned long b, size_t c, uint64_t d) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "bmap"); \
- RunFunction(my_context, my_bmap_fct_##A, 4, a, b, c, d); \
+ RunFunctionFmt(my_bmap_fct_##A, "pLLU", a, b, c, d); \
}
SUPER()
#undef GO
@@ -985,7 +985,7 @@ static uintptr_t my_ioctl_fct_##A = 0;
static void my_ioctl_##A(void* a, unsigned long b, int c, void* d, void* e, unsigned f, void* g, size_t h, size_t i)\
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "ioctl"); \
- RunFunction(my_context, my_ioctl_fct_##A, 9, a, b, c, d, e, f, g, h, i); \
+ RunFunctionFmt(my_ioctl_fct_##A, "pLippupLL", a, b, c, d, e, f, g, h, i); \
}
SUPER()
#undef GO
@@ -1009,7 +1009,7 @@ static uintptr_t my_poll_fct_##A = 0; \
static void my_poll_##A(void* a, unsigned long b, void* c, void* d) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "poll"); \
- RunFunction(my_context, my_poll_fct_##A, 4, a, b, c, d); \
+ RunFunctionFmt(my_poll_fct_##A, "pLpp", a, b, c, d); \
}
SUPER()
#undef GO
@@ -1033,7 +1033,7 @@ static uintptr_t my_write_buf_fct_##A = 0;
static void my_write_buf_##A(void* a, unsigned long b, void* c, off_t d, void* e) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "write_buf"); \
- RunFunction(my_context, my_write_buf_fct_##A, 5, a, b, c, d, e); \
+ RunFunctionFmt(my_write_buf_fct_##A, "pLplp", a, b, c, d, e); \
}
SUPER()
#undef GO
@@ -1057,7 +1057,7 @@ static uintptr_t my_retrieve_reply_fct_##A = 0;
static void my_retrieve_reply_##A(void* a, void* b, unsigned long c, off_t d, void* e) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "retrieve_reply"); \
- RunFunction(my_context, my_retrieve_reply_fct_##A, 5, a, b, c, d, e); \
+ RunFunctionFmt(my_retrieve_reply_fct_##A, "ppLlp", a, b, c, d, e); \
}
SUPER()
#undef GO
@@ -1081,7 +1081,7 @@ static uintptr_t my_forget_multi_fct_##A = 0; \
static void my_forget_multi_##A(void* a, size_t b, void* c) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "forget_multi"); \
- RunFunction(my_context, my_forget_multi_fct_##A, 3, a, b, c); \
+ RunFunctionFmt(my_forget_multi_fct_##A, "pLp", a, b, c); \
}
SUPER()
#undef GO
@@ -1105,7 +1105,7 @@ static uintptr_t my_flock_fct_##A = 0; \
static void my_flock_##A(void* a, unsigned long b, void* c, int d) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "flock"); \
- RunFunction(my_context, my_flock_fct_##A, 4, a, b, c, d); \
+ RunFunctionFmt(my_flock_fct_##A, "pLpi", a, b, c, d); \
}
SUPER()
#undef GO
@@ -1129,7 +1129,7 @@ static uintptr_t my_fallocate_fct_##A = 0;
static void my_fallocate_##A(void* a, unsigned long b, int c, off_t d, off_t e, void* f) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "fallocate"); \
- RunFunction(my_context, my_fallocate_fct_##A, 6, a, b, c, d, e, f); \
+ RunFunctionFmt(my_fallocate_fct_##A, "pLillp", a, b, c, d, e, f); \
}
SUPER()
#undef GO
@@ -1155,7 +1155,7 @@ static int my_getattr_op_##A(const char * a, struct stat * b)
printf_log(LOG_DEBUG, "fuse: call %s\n", "getattr_op"); \
struct x64_stat64 b_; \
UnalignStat64(b, &b_); \
- int ret = (int)RunFunction(my_context, my_getattr_op_fct_##A, 2, a, &b_); \
+ int ret = (int)RunFunctionFmt(my_getattr_op_fct_##A, "pp", a, &b_); \
AlignStat64(&b_, b); \
return ret; \
}
@@ -1181,7 +1181,7 @@ static uintptr_t my_readlink_op_fct_##A = 0; \
static int my_readlink_op_##A(const char * a, char * b, size_t c) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "readlink_op"); \
- return (int)RunFunction(my_context, my_readlink_op_fct_##A, 3, a, b, c);\
+ return (int)RunFunctionFmt(my_readlink_op_fct_##A, "ppL", a, b, c);\
}
SUPER()
#undef GO
@@ -1205,7 +1205,7 @@ static uintptr_t my_getdir_op_fct_##A = 0;
static int my_getdir_op_##A(const char * a, void* b, void* c) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "getdir_op"); \
- return (int)RunFunction(my_context, my_getdir_op_fct_##A, 3, a, b, AddCheckBridge(my_lib->w.bridge, iFppiU, c, 0, NULL)); \
+ return (int)RunFunctionFmt(my_getdir_op_fct_##A, "ppp", a, b, AddCheckBridge(my_lib->w.bridge, iFppiU, c, 0, NULL)); \
}
SUPER()
#undef GO
@@ -1229,7 +1229,7 @@ static uintptr_t my_mknod_op_fct_##A = 0; \
static int my_mknod_op_##A(const char * a, mode_t b, dev_t c) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "mknod_op"); \
- return (int)RunFunction(my_context, my_mknod_op_fct_##A, 3, a, b, c); \
+ return (int)RunFunctionFmt(my_mknod_op_fct_##A, "puU", a, b, c); \
}
SUPER()
#undef GO
@@ -1253,7 +1253,7 @@ static uintptr_t my_mkdir_op_fct_##A = 0; \
static int my_mkdir_op_##A(const char * a, mode_t b) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "mkdir_op"); \
- return (int)RunFunction(my_context, my_mkdir_op_fct_##A, 2, a, b); \
+ return (int)RunFunctionFmt(my_mkdir_op_fct_##A, "pu", a, b); \
}
SUPER()
#undef GO
@@ -1277,7 +1277,7 @@ static uintptr_t my_unlink_op_fct_##A = 0; \
static int my_unlink_op_##A(const char * a) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "unlink_op"); \
- return (int)RunFunction(my_context, my_unlink_op_fct_##A, 1, a); \
+ return (int)RunFunctionFmt(my_unlink_op_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -1301,7 +1301,7 @@ static uintptr_t my_rmdir_op_fct_##A = 0; \
static int my_rmdir_op_##A(const char * a) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "rmdir_op"); \
- return (int)RunFunction(my_context, my_rmdir_op_fct_##A, 1, a); \
+ return (int)RunFunctionFmt(my_rmdir_op_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -1325,7 +1325,7 @@ static uintptr_t my_symlink_op_fct_##A = 0; \
static int my_symlink_op_##A(const char * a, const char * b) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "symlink_op"); \
- return (int)RunFunction(my_context, my_symlink_op_fct_##A, 2, a, b); \
+ return (int)RunFunctionFmt(my_symlink_op_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -1349,7 +1349,7 @@ static uintptr_t my_rename_op_fct_##A = 0; \
static int my_rename_op_##A(const char * a, const char * b) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "rename_op"); \
- return (int)RunFunction(my_context, my_rename_op_fct_##A, 2, a, b); \
+ return (int)RunFunctionFmt(my_rename_op_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -1373,7 +1373,7 @@ static uintptr_t my_link_op_fct_##A = 0; \
static int my_link_op_##A(const char * a, const char * b) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "link_op"); \
- return (int)RunFunction(my_context, my_link_op_fct_##A, 2, a, b); \
+ return (int)RunFunctionFmt(my_link_op_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -1397,7 +1397,7 @@ static uintptr_t my_chmod_op_fct_##A = 0; \
static int my_chmod_op_##A(const char * a, mode_t b) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "chmod_op"); \
- return (int)RunFunction(my_context, my_chmod_op_fct_##A, 2, a, b); \
+ return (int)RunFunctionFmt(my_chmod_op_fct_##A, "pu", a, b); \
}
SUPER()
#undef GO
@@ -1421,7 +1421,7 @@ static uintptr_t my_chown_op_fct_##A = 0; \
static int my_chown_op_##A(const char * a, uid_t b, gid_t c) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "chown_op"); \
- return (int)RunFunction(my_context, my_chown_op_fct_##A, 3, a, b, c); \
+ return (int)RunFunctionFmt(my_chown_op_fct_##A, "puu", a, b, c); \
}
SUPER()
#undef GO
@@ -1445,7 +1445,7 @@ static uintptr_t my_truncate_op_fct_##A = 0; \
static int my_truncate_op_##A(const char * a, off_t b) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "truncate_op"); \
- return (int)RunFunction(my_context, my_truncate_op_fct_##A, 2, a, b); \
+ return (int)RunFunctionFmt(my_truncate_op_fct_##A, "pl", a, b); \
}
SUPER()
#undef GO
@@ -1469,7 +1469,7 @@ static uintptr_t my_utime_op_fct_##A = 0; \
static int my_utime_op_##A(const char * a, void* b) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "utime_op"); \
- return (int)RunFunction(my_context, my_utime_op_fct_##A, 2, a, b); \
+ return (int)RunFunctionFmt(my_utime_op_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -1493,7 +1493,7 @@ static uintptr_t my_open_op_fct_##A = 0; \
static int my_open_op_##A(const char * a, void* b) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "open_op"); \
- return (int)RunFunction(my_context, my_open_op_fct_##A, 2, a, b); \
+ return (int)RunFunctionFmt(my_open_op_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -1517,7 +1517,7 @@ static uintptr_t my_read_op_fct_##A = 0;
static int my_read_op_##A(const char * a, char * b, size_t c, off_t d, void* e) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "read_op"); \
- return (int)RunFunction(my_context, my_read_op_fct_##A, 5, a, b, c, d, e); \
+ return (int)RunFunctionFmt(my_read_op_fct_##A, "ppLlp", a, b, c, d, e); \
}
SUPER()
#undef GO
@@ -1541,7 +1541,7 @@ static uintptr_t my_write_op_fct_##A = 0;
static int my_write_op_##A(const char * a, const char * b, size_t c, off_t d, void* e) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "write_op"); \
- return (int)RunFunction(my_context, my_write_op_fct_##A, 5, a, b, c, d, e); \
+ return (int)RunFunctionFmt(my_write_op_fct_##A, "ppLlp", a, b, c, d, e); \
}
SUPER()
#undef GO
@@ -1565,7 +1565,7 @@ static uintptr_t my_statfs_op_fct_##A = 0; \
static int my_statfs_op_##A(const char * a, void* b) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "statfs_op"); \
- return (int)RunFunction(my_context, my_statfs_op_fct_##A, 2, a, b); \
+ return (int)RunFunctionFmt(my_statfs_op_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -1589,7 +1589,7 @@ static uintptr_t my_flush_op_fct_##A = 0; \
static int my_flush_op_##A(const char * a, void* b) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "flush_op"); \
- return (int)RunFunction(my_context, my_flush_op_fct_##A, 2, a, b); \
+ return (int)RunFunctionFmt(my_flush_op_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -1613,7 +1613,7 @@ static uintptr_t my_release_op_fct_##A = 0; \
static int my_release_op_##A(const char * a, void* b) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "release_op"); \
- return (int)RunFunction(my_context, my_release_op_fct_##A, 2, a, b); \
+ return (int)RunFunctionFmt(my_release_op_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -1637,7 +1637,7 @@ static uintptr_t my_fsync_op_fct_##A = 0; \
static int my_fsync_op_##A(const char * a, int b, void* c) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "fsync_op"); \
- return (int)RunFunction(my_context, my_fsync_op_fct_##A, 3, a, b, c); \
+ return (int)RunFunctionFmt(my_fsync_op_fct_##A, "pip", a, b, c); \
}
SUPER()
#undef GO
@@ -1661,7 +1661,7 @@ static uintptr_t my_setxattr_op_fct_##A = 0;
static int my_setxattr_op_##A(const char * a, const char * b, const char * c, size_t d, int e) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "setxattr_op"); \
- return (int)RunFunction(my_context, my_setxattr_op_fct_##A, 5, a, b, c, d, e); \
+ return (int)RunFunctionFmt(my_setxattr_op_fct_##A, "pppLi", a, b, c, d, e); \
}
SUPER()
#undef GO
@@ -1685,7 +1685,7 @@ static uintptr_t my_getxattr_op_fct_##A = 0;
static int my_getxattr_op_##A(const char * a, const char * b, char * c, size_t d) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "getxattr_op"); \
- return (int)RunFunction(my_context, my_getxattr_op_fct_##A, 4, a, b, c, d); \
+ return (int)RunFunctionFmt(my_getxattr_op_fct_##A, "pppL", a, b, c, d); \
}
SUPER()
#undef GO
@@ -1709,7 +1709,7 @@ static uintptr_t my_listxattr_op_fct_##A = 0;
static int my_listxattr_op_##A(const char * a, char * b, size_t c) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "listxattr_op"); \
- return (int)RunFunction(my_context, my_listxattr_op_fct_##A, 3, a, b, c); \
+ return (int)RunFunctionFmt(my_listxattr_op_fct_##A, "ppL", a, b, c); \
}
SUPER()
#undef GO
@@ -1733,7 +1733,7 @@ static uintptr_t my_removexattr_op_fct_##A = 0;
static int my_removexattr_op_##A(const char * a, const char * b) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "removexattr_op"); \
- return (int)RunFunction(my_context, my_removexattr_op_fct_##A, 2, a, b); \
+ return (int)RunFunctionFmt(my_removexattr_op_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -1757,7 +1757,7 @@ static uintptr_t my_opendir_op_fct_##A = 0; \
static int my_opendir_op_##A(const char * a, void* b) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "opendir_op"); \
- return (int)RunFunction(my_context, my_opendir_op_fct_##A, 2, a, b); \
+ return (int)RunFunctionFmt(my_opendir_op_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -1781,7 +1781,7 @@ static uintptr_t my_readdir_op_fct_##A = 0;
static int my_readdir_op_##A(const char * a, void * b, fuse_fill_dir_t c, off_t d, void* e) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "readdir_op"); \
- return (int)RunFunction(my_context, my_readdir_op_fct_##A, 5, a, b, AddCheckBridge(my_lib->w.bridge, iFpppUi, c, 0, NULL), d, e); \
+ return (int)RunFunctionFmt(my_readdir_op_fct_##A, "ppplp", a, b, AddCheckBridge(my_lib->w.bridge, iFpppUi, c, 0, NULL), d, e); \
}
SUPER()
#undef GO
@@ -1805,7 +1805,7 @@ static uintptr_t my_releasedir_op_fct_##A = 0; \
static int my_releasedir_op_##A(const char * a, void* b) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "releasedir_op"); \
- return (int)RunFunction(my_context, my_releasedir_op_fct_##A,2, a, b); \
+ return (int)RunFunctionFmt(my_releasedir_op_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -1829,7 +1829,7 @@ static uintptr_t my_fsyncdir_op_fct_##A = 0; \
static int my_fsyncdir_op_##A(const char * a, int b, void* c) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "fsyncdir_op"); \
- return (int)RunFunction(my_context, my_fsyncdir_op_fct_##A, 3, a, b, c);\
+ return (int)RunFunctionFmt(my_fsyncdir_op_fct_##A, "pip", a, b, c);\
}
SUPER()
#undef GO
@@ -1853,7 +1853,7 @@ static uintptr_t my_init_op_fct_##A = 0; \
static void* my_init_op_##A(void* a) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "init_op"); \
- return (void*)RunFunction(my_context, my_init_op_fct_##A, 1, a); \
+ return (void*)RunFunctionFmt(my_init_op_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -1877,7 +1877,7 @@ static uintptr_t my_destroy_op_fct_##A = 0; \
static void my_destroy_op_##A(void * a) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "destroy_op"); \
- RunFunction(my_context, my_destroy_op_fct_##A, 1, a); \
+ RunFunctionFmt(my_destroy_op_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -1901,7 +1901,7 @@ static uintptr_t my_access_op_fct_##A = 0; \
static int my_access_op_##A(const char * a, int b) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "access_op"); \
- return (int)RunFunction(my_context, my_access_op_fct_##A, 2, a, b); \
+ return (int)RunFunctionFmt(my_access_op_fct_##A, "pi", a, b); \
}
SUPER()
#undef GO
@@ -1925,7 +1925,7 @@ static uintptr_t my_create_op_fct_##A = 0; \
static int my_create_op_##A(const char * a, mode_t b, void* c) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "create_op"); \
- return (int)RunFunction(my_context, my_create_op_fct_##A, 3, a, b, c); \
+ return (int)RunFunctionFmt(my_create_op_fct_##A, "pup", a, b, c); \
}
SUPER()
#undef GO
@@ -1949,7 +1949,7 @@ static uintptr_t my_ftruncate_op_fct_##A = 0;
static int my_ftruncate_op_##A(const char * a, off_t b, void* c) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "ftruncate_op"); \
- return (int)RunFunction(my_context, my_ftruncate_op_fct_##A, 3, a, b, c); \
+ return (int)RunFunctionFmt(my_ftruncate_op_fct_##A, "plp", a, b, c); \
}
SUPER()
#undef GO
@@ -1975,7 +1975,7 @@ static int my_fgetattr_op_##A(const char * a, struct stat* b, void* c)
printf_log(LOG_DEBUG, "fuse: call %s\n", "fgetattr_op"); \
struct x64_stat64 b_; \
UnalignStat64(b, &b_); \
- int ret = (int)RunFunction(my_context, my_fgetattr_op_fct_##A, 3, a, &b_, c); \
+ int ret = (int)RunFunctionFmt(my_fgetattr_op_fct_##A, "ppp", a, &b_, c); \
AlignStat64(&b_, b); \
return ret; \
}
@@ -2001,7 +2001,7 @@ static uintptr_t my_lock_op_fct_##A = 0;
static int my_lock_op_##A(const char * a, void* b, int c, void* d) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "lock_op"); \
- return (int)RunFunction(my_context, my_lock_op_fct_##A, 4, a, b, c, d); \
+ return (int)RunFunctionFmt(my_lock_op_fct_##A, "ppip", a, b, c, d); \
}
SUPER()
#undef GO
@@ -2025,7 +2025,7 @@ static uintptr_t my_utimens_op_fct_##A = 0; \
static int my_utimens_op_##A(const char * a, const struct timespec b[2]) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "utimens_op"); \
- return (int)RunFunction(my_context, my_utimens_op_fct_##A, 2, a, b); \
+ return (int)RunFunctionFmt(my_utimens_op_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -2049,7 +2049,7 @@ static uintptr_t my_bmap_op_fct_##A = 0; \
static int my_bmap_op_##A(const char * a, size_t b, uint64_t *c) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "bmap_op"); \
- return (int)RunFunction(my_context, my_bmap_op_fct_##A, 3, a, b, c); \
+ return (int)RunFunctionFmt(my_bmap_op_fct_##A, "pLp", a, b, c); \
}
SUPER()
#undef GO
@@ -2073,7 +2073,7 @@ static uintptr_t my_ioctl_op_fct_##A = 0;
static int my_ioctl_op_##A(const char * a, int b, void* c, void* d, unsigned int e, void* f) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "ioctl_op"); \
- return (int)RunFunction(my_context, my_ioctl_op_fct_##A, 6, a, b, c, d, e, f); \
+ return (int)RunFunctionFmt(my_ioctl_op_fct_##A, "pippup", a, b, c, d, e, f); \
}
SUPER()
#undef GO
@@ -2097,7 +2097,7 @@ static uintptr_t my_poll_op_fct_##A = 0; \
static int my_poll_op_##A(const char * a, void* b, void* c, unsigned * d) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "poll_op"); \
- return (int)RunFunction(my_context, my_poll_op_fct_##A, 4, a, b, c, d); \
+ return (int)RunFunctionFmt(my_poll_op_fct_##A, "pppp", a, b, c, d); \
}
SUPER()
#undef GO
@@ -2121,7 +2121,7 @@ static uintptr_t my_write_buf_op_fct_##A = 0;
static int my_write_buf_op_##A(const char * a, void* b, off_t c, void* d) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "write_buf_op"); \
- return (int)RunFunction(my_context, my_write_buf_op_fct_##A, 4, a, b, c, d); \
+ return (int)RunFunctionFmt(my_write_buf_op_fct_##A, "pplp", a, b, c, d); \
}
SUPER()
#undef GO
@@ -2145,7 +2145,7 @@ static uintptr_t my_read_buf_op_fct_##A = 0;
static int my_read_buf_op_##A(const char * a, void* b, size_t c, off_t d, void* e) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "read_buf_op"); \
- return (int)RunFunction(my_context, my_read_buf_op_fct_##A, 5, a, b, c, d, e); \
+ return (int)RunFunctionFmt(my_read_buf_op_fct_##A, "ppLlp", a, b, c, d, e); \
}
SUPER()
#undef GO
@@ -2169,7 +2169,7 @@ static uintptr_t my_flock_op_fct_##A = 0; \
static int my_flock_op_##A(const char * a, void* b, int c) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "flock_op"); \
- return (int)RunFunction(my_context, my_flock_op_fct_##A, 3, a, b, c); \
+ return (int)RunFunctionFmt(my_flock_op_fct_##A, "ppi", a, b, c); \
}
SUPER()
#undef GO
@@ -2193,7 +2193,7 @@ static uintptr_t my_fallocate_op_fct_##A = 0;
static int my_fallocate_op_##A(const char * a, int b, off_t c, off_t d, void* e) \
{ \
printf_log(LOG_DEBUG, "fuse: call %s\n", "fallocate_op"); \
- return (int)RunFunction(my_context, my_fallocate_op_fct_##A, 5, a, b, c, d, e); \
+ return (int)RunFunctionFmt(my_fallocate_op_fct_##A, "pillp", a, b, c, d, e); \
}
SUPER()
#undef GO
@@ -2376,5 +2376,5 @@ box64_showsegv=1;
#define CUSTOM_FINI \
freeMy();
-
+
#include "wrappedlib_init.h"
diff --git a/src/wrapped/wrappedlibfuse_private.h b/src/wrapped/wrappedlibfuse_private.h
index cc8e9cb..cc8e9cb 100755..100644
--- a/src/wrapped/wrappedlibfuse_private.h
+++ b/src/wrapped/wrappedlibfuse_private.h
diff --git a/src/wrapped/wrappedlibgl.c b/src/wrapped/wrappedlibgl.c
index f210a25..1d5eb93 100755..100644
--- a/src/wrapped/wrappedlibgl.c
+++ b/src/wrapped/wrappedlibgl.c
@@ -23,7 +23,7 @@ static library_t* my_lib = NULL;
// FIXME: old wrapped* type of file, cannot use generated/wrappedlibgltypes.h
-EXPORT void* my_glXGetProcAddress(x64emu_t* emu, void* name)
+EXPORT void* my_glXGetProcAddress(x64emu_t* emu, void* name)
{
khint_t k;
const char* rname = (const char*)name;
@@ -58,7 +58,7 @@ GO(4)
static uintptr_t my_debug_callback_fct_##A = 0; \
static void my_debug_callback_##A(int32_t a, int32_t b, uint32_t c, int32_t d, int32_t e, const char* f, const void* g) \
{ \
- RunFunction(my_context, my_debug_callback_fct_##A, 7, a, b, c, d, e, f, g); \
+ RunFunctionFmt(my_debug_callback_fct_##A, "iiuiipp", a, b, c, d, e, f, g); \
}
SUPER()
#undef GO
@@ -80,7 +80,7 @@ static void* find_debug_callback_Fct(void* fct)
static uintptr_t my_program_callback_fct_##A = 0; \
static void my_program_callback_##A(int32_t a, void* b) \
{ \
- RunFunction(my_context, my_program_callback_fct_##A, 2, a, b); \
+ RunFunctionFmt(my_program_callback_fct_##A, "ip", a, b); \
}
SUPER()
#undef GO
@@ -359,7 +359,7 @@ void* getGLProcAddress(x64emu_t* emu, glprocaddress_t procaddr, const char* rnam
}
#undef GO
#undef SUPER
- } else
+ } else
symbol = procaddr(rname);
if(!symbol) {
printf_dlsym(LOG_DEBUG, "%p\n", NULL);
@@ -371,7 +371,7 @@ void* getGLProcAddress(x64emu_t* emu, glprocaddress_t procaddr, const char* rnam
printf_dlsym(LOG_DEBUG, "%p\n", (void*)ret);
return (void*)ret; // already bridged
}
- // get wrapper
+ // get wrapper
k = kh_get(symbolmap, wrappers->glwrappers, rname);
if(k==kh_end(wrappers->glwrappers) && strstr(rname, "ARB")==NULL) {
// try again, adding ARB at the end if not present
@@ -397,4 +397,4 @@ void* getGLProcAddress(x64emu_t* emu, glprocaddress_t procaddr, const char* rnam
ret = AddBridge(emu->context->system, kh_value(wrappers->glwrappers, k), symbol, 0, constname);
printf_dlsym(LOG_DEBUG, "%p\n", (void*)ret);
return (void*)ret;
-} \ No newline at end of file
+}
diff --git a/src/wrapped/wrappedlibgl_private.h b/src/wrapped/wrappedlibgl_private.h
index eb9bdbf..c87bb80 100755..100644
--- a/src/wrapped/wrappedlibgl_private.h
+++ b/src/wrapped/wrappedlibgl_private.h
@@ -1,2902 +1,2903 @@
#if !(defined(GO) && defined(GOM) && defined(GO2) && defined(DATA))
#error meh!
#endif
+//VERSION_1_0
+GO(glAccum, vFuf)
+GO(glAlphaFunc, vFuf)
+GO(glBegin, vFu)
+GO(glBitmap, vFiiffffp)
+GO(glBlendFunc, vFuu)
+GO(glCallList, vFu)
+GO(glCallLists, vFiup)
+GO(glClear, vFi)
+GO(glClearAccum, vFffff)
+GO(glClearColor, vFffff)
+GO(glClearDepth, vFd)
+GO(glClearIndex, vFf)
+GO(glClearStencil, vFi)
+GO(glClipPlane, vFup)
+GO(glColor3b, vFccc)
+GO(glColor3bv, vFp)
+GO(glColor3d, vFddd)
+GO(glColor3dv, vFp)
+GO(glColor3f, vFfff)
+GO(glColor3fv, vFp)
+GO(glColor3i, vFiii)
+GO(glColor3iv, vFp)
+GO(glColor3s, vFiii)
+GO(glColor3sv, vFp)
+GO(glColor3ub, vFCCC)
+GO(glColor3ubv, vFp)
+GO(glColor3ui, vFuuu)
+GO(glColor3uiv, vFp)
+GO(glColor3us, vFWWW)
+GO(glColor3usv, vFp)
+GO(glColor4b, vFcccc)
+GO(glColor4bv, vFp)
+GO(glColor4d, vFdddd)
+GO(glColor4dv, vFp)
+GO(glColor4f, vFffff)
+GO(glColor4fv, vFp)
+GO(glColor4i, vFiiii)
+GO(glColor4iv, vFp)
+GO(glColor4s, vFiiii)
+GO(glColor4sv, vFp)
+GO(glColor4ub, vFCCCC)
+GO(glColor4ubv, vFp)
+GO(glColor4ui, vFuuuu)
+GO(glColor4uiv, vFp)
+GO(glColor4us, vFWWWW)
+GO(glColor4usv, vFp)
+GO(glColorMask, vFCCCC)
+GO(glColorMaterial, vFuu)
+GO(glCopyPixels, vFiiiiu)
+GO(glCullFace, vFu)
+GO(glDeleteLists, vFui)
+GO(glDepthFunc, vFu)
+GO(glDepthMask, vFi)
+GO(glDepthRange, vFdd)
+GO(glDisable, vFu)
+GO(glDrawBuffer, vFu)
+GO(glDrawPixels, vFiiuup)
+GO(glEdgeFlag, vFi)
+GO(glEdgeFlagv, vFp)
+GO(glEnable, vFu)
+GO(glEnd, vFv)
+GO(glEndList, vFv)
+GO(glEvalCoord1d, vFd)
+GO(glEvalCoord1dv, vFp)
+GO(glEvalCoord1f, vFf)
+GO(glEvalCoord1fv, vFp)
+GO(glEvalCoord2d, vFdd)
+GO(glEvalCoord2dv, vFp)
+GO(glEvalCoord2f, vFff)
+GO(glEvalCoord2fv, vFp)
+GO(glEvalMesh1, vFuii)
+GO(glEvalMesh2, vFuiiii)
+GO(glEvalPoint1, vFi)
+GO(glEvalPoint2, vFii)
+GO(glFeedbackBuffer, vFiup)
+GO(glFinish, vFv)
+GO(glFlush, vFv)
+GO(glFogf, vFuf)
+GO(glFogfv, vFup)
+GO(glFogi, vFui)
+GO(glFogiv, vFup)
+GO(glFrontFace, vFu)
+GO(glFrustum, vFdddddd)
+GO(glGenLists, uFi)
+GO(glGetBooleanv, vFup)
+GO(glGetClipPlane, vFup)
+GO(glGetDoublev, vFup)
+GO(glGetError, uFv)
+GO(glGetFloatv, vFup)
+GO(glGetIntegerv, vFup)
+GO(glGetLightfv, vFuup)
+GO(glGetLightiv, vFuup)
+GO(glGetMapdv, vFuup)
+GO(glGetMapfv, vFuup)
+GO(glGetMapiv, vFuup)
+GO(glGetMaterialfv, vFuup)
+GO(glGetMaterialiv, vFuup)
+GO(glGetPixelMapfv, vFup)
+GO(glGetPixelMapuiv, vFup)
+GO(glGetPixelMapusv, vFup)
+GO(glGetPolygonStipple, vFp)
+GO(glGetString, pFu)
+GO(glGetTexEnvfv, vFuup)
+GO(glGetTexEnviv, vFuup)
+GO(glGetTexGendv, vFuup)
+GO(glGetTexGenfv, vFuup)
+GO(glGetTexGeniv, vFuup)
+GO(glGetTexImage, vFuiuup)
+GO(glGetTexLevelParameterfv, vFuiup)
+GO(glGetTexLevelParameteriv, vFuiup)
+GO(glGetTexParameterfv, vFuup)
+GO(glGetTexParameteriv, vFuup)
+GO(glHint, vFuu)
+GO(glIndexMask, vFu)
+GO(glIndexd, vFd)
+GO(glIndexdv, vFp)
+GO(glIndexf, vFf)
+GO(glIndexfv, vFp)
+GO(glIndexi, vFi)
+GO(glIndexiv, vFp)
+GO(glIndexs, vFi)
+GO(glIndexsv, vFp)
+GO(glInitNames, vFv)
+GO(glIsEnabled, iFu)
+GO(glIsList, iFu)
+GO(glLightModelf, vFuf)
+GO(glLightModelfv, vFup)
+GO(glLightModeli, vFui)
+GO(glLightModeliv, vFup)
+GO(glLightf, vFuuf)
+GO(glLightfv, vFuup)
+GO(glLighti, vFuui)
+GO(glLightiv, vFuup)
+GO(glLineStipple, vFiW)
+GO(glLineWidth, vFf)
+GO(glListBase, vFu)
+GO(glLoadIdentity, vFv)
+GO(glLoadMatrixd, vFp)
+GO(glLoadMatrixf, vFp)
+GO(glLoadName, vFu)
+GO(glLogicOp, vFu)
+GO(glMap1d, vFuddiip)
+GO(glMap1f, vFuffiip)
+GO(glMap2d, vFuddiiddiip)
+GO(glMap2f, vFuffiiffiip)
+GO(glMapGrid1d, vFidd)
+GO(glMapGrid1f, vFiff)
+GO(glMapGrid2d, vFiddidd)
+GO(glMapGrid2f, vFiffiff)
+GO(glMaterialf, vFuuf)
+GO(glMaterialfv, vFuup)
+GO(glMateriali, vFuui)
+GO(glMaterialiv, vFuup)
+GO(glMatrixMode, vFu)
+GO(glMultMatrixd, vFp)
+GO(glMultMatrixf, vFp)
+GO(glNewList, vFuu)
+GO(glNormal3b, vFiii)
+GO(glNormal3bv, vFp)
+GO(glNormal3d, vFddd)
+GO(glNormal3dv, vFp)
+GO(glNormal3f, vFfff)
+GO(glNormal3fv, vFp)
+GO(glNormal3i, vFiii)
+GO(glNormal3iv, vFp)
+GO(glNormal3s, vFiii)
+GO(glNormal3sv, vFp)
+GO(glOrtho, vFdddddd)
+GO(glPassThrough, vFf)
+GO(glPixelMapfv, vFuip)
+GO(glPixelMapuiv, vFuip)
+GO(glPixelMapusv, vFuip)
+GO(glPixelStoref, vFuf)
+GO(glPixelStorei, vFui)
+GO(glPixelTransferf, vFuf)
+GO(glPixelTransferi, vFui)
+GO(glPixelZoom, vFff)
+GO(glPointSize, vFf)
+GO(glPolygonMode, vFuu)
+GO(glPolygonStipple, vFp)
+GO(glPopAttrib, vFv)
+GO(glPopMatrix, vFv)
+GO(glPopName, vFv)
+GO(glPushAttrib, vFi)
+GO(glPushMatrix, vFv)
+GO(glPushName, vFu)
+GO(glRasterPos2d, vFdd)
+GO(glRasterPos2dv, vFp)
+GO(glRasterPos2f, vFff)
+GO(glRasterPos2fv, vFp)
+GO(glRasterPos2i, vFii)
+GO(glRasterPos2iv, vFp)
+GO(glRasterPos2s, vFii)
+GO(glRasterPos2sv, vFp)
+GO(glRasterPos3d, vFddd)
+GO(glRasterPos3dv, vFp)
+GO(glRasterPos3f, vFfff)
+GO(glRasterPos3fv, vFp)
+GO(glRasterPos3i, vFiii)
+GO(glRasterPos3iv, vFp)
+GO(glRasterPos3s, vFiii)
+GO(glRasterPos3sv, vFp)
+GO(glRasterPos4d, vFdddd)
+GO(glRasterPos4dv, vFp)
+GO(glRasterPos4f, vFffff)
+GO(glRasterPos4fv, vFp)
+GO(glRasterPos4i, vFiiii)
+GO(glRasterPos4iv, vFp)
+GO(glRasterPos4s, vFiiii)
+GO(glRasterPos4sv, vFp)
+GO(glReadBuffer, vFu)
+GO(glReadPixels, vFiiiiuup)
+GO(glRectd, vFdddd)
+GO(glRectdv, vFpp)
+GO(glRectf, vFffff)
+GO(glRectfv, vFpp)
+GO(glRecti, vFiiii)
+GO(glRectiv, vFpp)
+GO(glRects, vFiiii)
+GO(glRectsv, vFpp)
+GO(glRenderMode, iFu)
+GO(glRotated, vFdddd)
+GO(glRotatef, vFffff)
+GO(glScaled, vFddd)
+GO(glScalef, vFfff)
+GO(glScissor, vFiiii)
+GO(glSelectBuffer, vFip)
+GO(glShadeModel, vFu)
+GO(glStencilFunc, vFuiu)
+GO(glStencilMask, vFu)
+GO(glStencilOp, vFuuu)
+GO(glTexCoord1d, vFd)
+GO(glTexCoord1dv, vFp)
+GO(glTexCoord1f, vFf)
+GO(glTexCoord1fv, vFp)
+GO(glTexCoord1i, vFi)
+GO(glTexCoord1iv, vFp)
+GO(glTexCoord1s, vFi)
+GO(glTexCoord1sv, vFp)
+GO(glTexCoord2d, vFdd)
+GO(glTexCoord2dv, vFp)
+GO(glTexCoord2f, vFff)
+GO(glTexCoord2fv, vFp)
+GO(glTexCoord2i, vFii)
+GO(glTexCoord2iv, vFp)
+GO(glTexCoord2s, vFii)
+GO(glTexCoord2sv, vFp)
+GO(glTexCoord3d, vFddd)
+GO(glTexCoord3dv, vFp)
+GO(glTexCoord3f, vFfff)
+GO(glTexCoord3fv, vFp)
+GO(glTexCoord3i, vFiii)
+GO(glTexCoord3iv, vFp)
+GO(glTexCoord3s, vFiii)
+GO(glTexCoord3sv, vFp)
+GO(glTexCoord4d, vFdddd)
+GO(glTexCoord4dv, vFp)
+GO(glTexCoord4f, vFffff)
+GO(glTexCoord4fv, vFp)
+GO(glTexCoord4i, vFiiii)
+GO(glTexCoord4iv, vFp)
+GO(glTexCoord4s, vFiiii)
+GO(glTexCoord4sv, vFp)
+GO(glTexEnvf, vFuuf)
+GO(glTexEnvfv, vFuup)
+GO(glTexEnvi, vFuui)
+GO(glTexEnviv, vFuup)
+GO(glTexGend, vFuud)
+GO(glTexGendv, vFuup)
+GO(glTexGenf, vFuuf)
+GO(glTexGenfv, vFuup)
+GO(glTexGeni, vFuui)
+GO(glTexGeniv, vFuup)
+GO(glTexImage1D, vFuiiiiuup)
+GO(glTexImage2D, vFuiiiiiuup)
+GO(glTexParameterf, vFuuf)
+GO(glTexParameterfv, vFuup)
+GO(glTexParameteri, vFuui)
+GO(glTexParameteriv, vFuup)
+GO(glTranslated, vFddd)
+GO(glTranslatef, vFfff)
+GO(glVertex2d, vFdd)
+GO(glVertex2dv, vFp)
+GO(glVertex2f, vFff)
+GO(glVertex2fv, vFp)
+GO(glVertex2i, vFii)
+GO(glVertex2iv, vFp)
+GO(glVertex2s, vFii)
+GO(glVertex2sv, vFp)
+GO(glVertex3d, vFddd)
+GO(glVertex3dv, vFp)
+GO(glVertex3f, vFfff)
+GO(glVertex3fv, vFp)
+GO(glVertex3i, vFiii)
+GO(glVertex3iv, vFp)
+GO(glVertex3s, vFiii)
+GO(glVertex3sv, vFp)
+GO(glVertex4d, vFdddd)
+GO(glVertex4dv, vFp)
+GO(glVertex4f, vFffff)
+GO(glVertex4fv, vFp)
+GO(glVertex4i, vFiiii)
+GO(glVertex4iv, vFp)
+GO(glVertex4s, vFiiii)
+GO(glVertex4sv, vFp)
+GO(glViewport, vFiiii)
+//VERSION_1_1
+GO(glAreTexturesResident, CFipp)
+GO(glArrayElement, vFi)
+GO(glBindTexture, vFuu)
+GO(glColorPointer, vFiuip)
+GO(glCopyTexImage1D, vFuiuiiii)
+GO(glCopyTexImage2D, vFuiuiiiii)
+GO(glCopyTexSubImage1D, vFuiiiii)
+GO(glCopyTexSubImage2D, vFuiiiiiii)
+GO(glDeleteTextures, vFip)
+GO(glDisableClientState, vFu)
+GO(glDrawArrays, vFuii)
+GO(glDrawElements, vFuiup)
+GO(glEdgeFlagPointer, vFip)
+GO(glEnableClientState, vFu)
+GO(glGenTextures, vFip)
+GO(glGetPointerv, vFup)
+GO(glIndexPointer, vFuip)
+GO(glIndexub, vFu)
+GO(glIndexubv, vFp)
+GO(glInterleavedArrays, vFuip)
+GO(glIsTexture, iFu)
+GO(glNormalPointer, vFuip)
+GO(glPolygonOffset, vFff)
+GO(glPopClientAttrib, vFv)
+GO(glPrioritizeTextures, vFipp)
+GO(glPushClientAttrib, vFi)
+GO(glTexCoordPointer, vFiuip)
+GO(glTexSubImage1D, vFuiiiuup)
+GO(glTexSubImage2D, vFuiiiiiuup)
+GO(glVertexPointer, vFiuip)
+//VERSION_1_2
+GO(glBlendColor, vFffff)
+GO(glBlendEquation, vFu)
+GO(glColorSubTable, vFuiiuup)
+GO(glColorTable, vFuuiuup)
+GO(glColorTableParameterfv, vFuup)
+GO(glColorTableParameteriv, vFuup)
+GO(glConvolutionFilter1D, vFuuiuup)
+GO(glConvolutionFilter2D, vFuuiiuup)
+GO(glConvolutionParameterf, vFuuf)
+GO(glConvolutionParameterfv, vFuup)
+GO(glConvolutionParameteri, vFuui)
+GO(glConvolutionParameteriv, vFuup)
+GO(glCopyColorSubTable, vFuiiii)
+GO(glCopyColorTable, vFuuiii)
+GO(glCopyConvolutionFilter1D, vFuuiii)
+GO(glCopyConvolutionFilter2D, vFuuiiii)
+GO(glCopyTexSubImage3D, vFuiiiiiiii)
+GO(glDrawRangeElements, vFuuuiup)
+GO(glGetColorTable, vFuuup)
+GO(glGetColorTableParameterfv, vFuup)
+GO(glGetColorTableParameteriv, vFuup)
+GO(glGetConvolutionFilter, vFuuup)
+GO(glGetConvolutionParameterfv, vFuup)
+GO(glGetConvolutionParameteriv, vFuup)
+GO(glGetHistogram, vFuiuup)
+GO(glGetHistogramParameterfv, vFuup)
+GO(glGetHistogramParameteriv, vFuup)
+GO(glGetMinmax, vFuCuup)
+GO(glGetMinmaxParameterfv, vFuup)
+GO(glGetMinmaxParameteriv, vFuup)
+GO(glGetSeparableFilter, vFuuuppp)
+GO(glHistogram, vFuiui)
+GO(glMinmax, vFuui)
+GO(glResetHistogram, vFu)
+GO(glResetMinmax, vFu)
+GO(glSeparableFilter2D, vFuuiiuupp)
+GO(glTexImage3D, vFuiiiiiiuup)
+GO(glTexSubImage3D, vFuiiiiiiiuup)
+//VERSION_1_3
+GO(glActiveTexture, vFu)
+GO(glClientActiveTexture, vFu)
+GO(glCompressedTexImage1D, vFuiuiiip)
+GO(glCompressedTexImage2D, vFuiuiiiip)
+GO(glCompressedTexImage3D, vFuiuiiiiip)
+GO(glCompressedTexSubImage1D, vFuiiiuip)
+GO(glCompressedTexSubImage2D, vFuiiiiiuip)
+GO(glCompressedTexSubImage3D, vFuiiiiiiiuip)
+GO(glGetCompressedTexImage, vFuip)
+GO(glLoadTransposeMatrixd, vFp)
+GO(glLoadTransposeMatrixf, vFp)
+GO(glMultTransposeMatrixd, vFp)
+GO(glMultTransposeMatrixf, vFp)
+GO(glMultiTexCoord1d, vFud)
+GO(glMultiTexCoord1dv, vFup)
+GO(glMultiTexCoord1f, vFuf)
+GO(glMultiTexCoord1fv, vFup)
+GO(glMultiTexCoord1i, vFui)
+GO(glMultiTexCoord1iv, vFup)
+GO(glMultiTexCoord1s, vFui)
+GO(glMultiTexCoord1sv, vFup)
+GO(glMultiTexCoord2d, vFudd)
+GO(glMultiTexCoord2dv, vFup)
+GO(glMultiTexCoord2f, vFuff)
+GO(glMultiTexCoord2fv, vFup)
+GO(glMultiTexCoord2i, vFuii)
+GO(glMultiTexCoord2iv, vFup)
+GO(glMultiTexCoord2s, vFuii)
+GO(glMultiTexCoord2sv, vFup)
+GO(glMultiTexCoord3d, vFuddd)
+GO(glMultiTexCoord3dv, vFup)
+GO(glMultiTexCoord3f, vFufff)
+GO(glMultiTexCoord3fv, vFup)
+GO(glMultiTexCoord3i, vFuiii)
+GO(glMultiTexCoord3iv, vFup)
+GO(glMultiTexCoord3s, vFuiii)
+GO(glMultiTexCoord3sv, vFup)
+GO(glMultiTexCoord4d, vFudddd)
+GO(glMultiTexCoord4dv, vFup)
+GO(glMultiTexCoord4f, vFuffff)
+GO(glMultiTexCoord4fv, vFup)
+GO(glMultiTexCoord4i, vFuiiii)
+GO(glMultiTexCoord4iv, vFup)
+GO(glMultiTexCoord4s, vFuiiii)
+GO(glMultiTexCoord4sv, vFup)
+GO(glSampleCoverage, vFfi)
+//VERSION_1_4
+GO(glBlendFuncSeparate, vFuuuu)
+GO(glFogCoordPointer, vFuip)
+GO(glFogCoordd, vFd)
+GO(glFogCoorddv, vFp)
+GO(glFogCoordf, vFf)
+GO(glFogCoordfv, vFp)
+GO(glMultiDrawArrays, vFuppi)
+GO(glMultiDrawElements, vFupupi)
+GO(glPointParameterf, vFuf)
+GO(glPointParameterfv, vFup)
+GO(glPointParameteri, vFui)
+GO(glPointParameteriv, vFup)
+GO(glSecondaryColor3b, vFiii)
+GO(glSecondaryColor3bv, vFp)
+GO(glSecondaryColor3d, vFddd)
+GO(glSecondaryColor3dv, vFp)
+GO(glSecondaryColor3f, vFfff)
+GO(glSecondaryColor3fv, vFp)
+GO(glSecondaryColor3i, vFiii)
+GO(glSecondaryColor3iv, vFp)
+GO(glSecondaryColor3s, vFiii)
+GO(glSecondaryColor3sv, vFp)
+GO(glSecondaryColor3ub, vFuuu)
+GO(glSecondaryColor3ubv, vFp)
+GO(glSecondaryColor3ui, vFuuu)
+GO(glSecondaryColor3uiv, vFp)
+GO(glSecondaryColor3us, vFuuu)
+GO(glSecondaryColor3usv, vFp)
+GO(glSecondaryColorPointer, vFiuip)
+GO(glWindowPos2d, vFdd)
+GO(glWindowPos2dv, vFp)
+GO(glWindowPos2f, vFff)
+GO(glWindowPos2fv, vFp)
+GO(glWindowPos2i, vFii)
+GO(glWindowPos2iv, vFp)
+GO(glWindowPos2s, vFii)
+GO(glWindowPos2sv, vFp)
+GO(glWindowPos3d, vFddd)
+GO(glWindowPos3dv, vFp)
+GO(glWindowPos3f, vFfff)
+GO(glWindowPos3fv, vFp)
+GO(glWindowPos3i, vFiii)
+GO(glWindowPos3iv, vFp)
+GO(glWindowPos3s, vFiii)
+GO(glWindowPos3sv, vFp)
+//VERSION_1_5
+GO(glBeginQuery, vFuu)
+GO(glBindBuffer, vFuu)
+GO(glBufferData, vFulpu)
+GO(glBufferSubData, vFullp)
+GO(glDeleteBuffers, vFip)
+GO(glDeleteQueries, vFip)
+GO(glEndQuery, vFu)
+GO(glGenBuffers, vFip)
+GO(glGenQueries, vFip)
+GO(glGetBufferParameteriv, vFuup)
+GO(glGetBufferPointerv, vFuup)
+GO(glGetBufferSubData, vFullp)
+GO(glGetQueryObjectiv, vFuup)
+GO(glGetQueryObjectuiv, vFuup)
+GO(glGetQueryiv, vFuup)
+GO(glIsBuffer, iFu)
+GO(glIsQuery, iFu)
+GO(glMapBuffer, pFuu)
+GO(glUnmapBuffer, iFu)
+//VERSION_2_0
+GO(glAttachShader, vFuu)
+GO(glBindAttribLocation, vFuup)
+GO(glBlendEquationSeparate, vFuu)
+GO(glCompileShader, vFu)
+GO(glCreateProgram, uFv)
+GO(glCreateShader, uFu)
+GO(glDeleteProgram, vFu)
+GO(glDeleteShader, vFu)
+GO(glDetachShader, vFuu)
+GO(glDisableVertexAttribArray, vFu)
+GO(glDrawBuffers, vFip)
+GO(glEnableVertexAttribArray, vFu)
+GO(glGetActiveAttrib, vFuuipppp)
+GO(glGetActiveUniform, vFuuipppp)
+GO(glGetAttachedShaders, vFuipp)
+GO(glGetAttribLocation, iFup)
+GO(glGetProgramInfoLog, vFuipp)
+GO(glGetProgramiv, vFuup)
+GO(glGetShaderInfoLog, vFuipp)
+GO(glGetShaderSource, vFuipp)
+GO(glGetShaderiv, vFuup)
+GO(glGetUniformLocation, iFup)
+GO(glGetUniformfv, vFuip)
+GO(glGetUniformiv, vFuip)
+GO(glGetVertexAttribPointerv, vFuup)
+GO(glGetVertexAttribdv, vFuup)
+GO(glGetVertexAttribfv, vFuup)
+GO(glGetVertexAttribiv, vFuup)
+GO(glIsProgram, iFu)
+GO(glIsShader, iFu)
+GO(glLinkProgram, vFu)
+GO(glShaderSource, vFuipp)
+GO(glStencilFuncSeparate, vFuuiu)
+GO(glStencilMaskSeparate, vFuu)
+GO(glStencilOpSeparate, vFuuuu)
+GO(glUniform1f, vFif)
+GO(glUniform1fv, vFiip)
+GO(glUniform1i, vFii)
+GO(glUniform1iv, vFiip)
+GO(glUniform2f, vFiff)
+GO(glUniform2fv, vFiip)
+GO(glUniform2i, vFiii)
+GO(glUniform2iv, vFiip)
+GO(glUniform3f, vFifff)
+GO(glUniform3fv, vFiip)
+GO(glUniform3i, vFiiii)
+GO(glUniform3iv, vFiip)
+GO(glUniform4f, vFiffff)
+GO(glUniform4fv, vFiip)
+GO(glUniform4i, vFiiiii)
+GO(glUniform4iv, vFiip)
+GO(glUniformMatrix2fv, vFiiip)
+GO(glUniformMatrix3fv, vFiiip)
+GO(glUniformMatrix4fv, vFiiip)
+GO(glUseProgram, vFu)
+GO(glValidateProgram, vFu)
+GO(glVertexAttrib1d, vFud)
+GO(glVertexAttrib1dv, vFup)
+GO(glVertexAttrib1f, vFuf)
+GO(glVertexAttrib1fv, vFup)
+GO(glVertexAttrib1s, vFui)
+GO(glVertexAttrib1sv, vFup)
+GO(glVertexAttrib2d, vFudd)
+GO(glVertexAttrib2dv, vFup)
+GO(glVertexAttrib2f, vFuff)
+GO(glVertexAttrib2fv, vFup)
+GO(glVertexAttrib2s, vFuii)
+GO(glVertexAttrib2sv, vFup)
+GO(glVertexAttrib3d, vFuddd)
+GO(glVertexAttrib3dv, vFup)
+GO(glVertexAttrib3f, vFufff)
+GO(glVertexAttrib3fv, vFup)
+GO(glVertexAttrib3s, vFuiii)
+GO(glVertexAttrib3sv, vFup)
+GO(glVertexAttrib4Nbv, vFup)
+GO(glVertexAttrib4Niv, vFup)
+GO(glVertexAttrib4Nsv, vFup)
+GO(glVertexAttrib4Nub, vFuuuuu)
+GO(glVertexAttrib4Nubv, vFup)
+GO(glVertexAttrib4Nuiv, vFup)
+GO(glVertexAttrib4Nusv, vFup)
+GO(glVertexAttrib4bv, vFup)
+GO(glVertexAttrib4d, vFudddd)
+GO(glVertexAttrib4dv, vFup)
+GO(glVertexAttrib4f, vFuffff)
+GO(glVertexAttrib4fv, vFup)
+GO(glVertexAttrib4iv, vFup)
+GO(glVertexAttrib4s, vFuiiii)
+GO(glVertexAttrib4sv, vFup)
+GO(glVertexAttrib4ubv, vFup)
+GO(glVertexAttrib4uiv, vFup)
+GO(glVertexAttrib4usv, vFup)
+GO(glVertexAttribPointer, vFuiuiip)
+//VERSION_2_1
+GO(glUniformMatrix2x3fv, vFiiip)
+GO(glUniformMatrix2x4fv, vFiiip)
+GO(glUniformMatrix3x2fv, vFiiip)
+GO(glUniformMatrix3x4fv, vFiiip)
+GO(glUniformMatrix4x2fv, vFiiip)
+GO(glUniformMatrix4x3fv, vFiiip)
+//VERSION_3_0
+GO(glBeginConditionalRender, vFuu)
+GO(glBeginTransformFeedback, vFu)
+GO(glBindBufferBase, vFuuu)
+GO(glBindBufferRange, vFuuuii)
+GO(glBindFragDataLocation, vFuup)
+GO(glClampColor, vFuu)
+GO(glClearBufferfi, vFuifi)
+GO(glClearBufferfv, vFuip)
+GO(glClearBufferiv, vFuip)
+GO(glClearBufferuiv, vFuip)
+GO(glColorMaski, vFuiiii)
+GO(glDisablei, vFuu)
+GO(glEnablei, vFuu)
+GO(glEndConditionalRender, vFv)
+GO(glEndTransformFeedback, vFv)
+GO(glGetBooleani_v, vFuup)
+GO(glGetFragDataLocation, iFup)
+GO(glGetIntegeri_v, vFuup)
+GO(glGetStringi, pFuu)
+GO(glGetTexParameterIiv, vFuup)
+GO(glGetTexParameterIuiv, vFuup)
+GO(glGetTransformFeedbackVarying, vFuuipppp)
+GO(glGetUniformuiv, vFuip)
+GO(glGetVertexAttribIiv, vFuup)
+GO(glGetVertexAttribIuiv, vFuup)
+GO(glIsEnabledi, iFuu)
+GO(glTexParameterIiv, vFuup)
+GO(glTexParameterIuiv, vFuup)
+GO(glTransformFeedbackVaryings, vFuipu)
+GO(glUniform1ui, vFiu)
+GO(glUniform1uiv, vFiip)
+GO(glUniform2ui, vFiuu)
+GO(glUniform2uiv, vFiip)
+GO(glUniform3ui, vFiuuu)
+GO(glUniform3uiv, vFiip)
+GO(glUniform4ui, vFiuuuu)
+GO(glUniform4uiv, vFiip)
+GO(glVertexAttribI1i, vFui)
+GO(glVertexAttribI1iv, vFup)
+GO(glVertexAttribI1ui, vFuu)
+GO(glVertexAttribI1uiv, vFup)
+GO(glVertexAttribI2i, vFuii)
+GO(glVertexAttribI2iv, vFup)
+GO(glVertexAttribI2ui, vFuuu)
+GO(glVertexAttribI2uiv, vFup)
+GO(glVertexAttribI3i, vFuiii)
+GO(glVertexAttribI3iv, vFup)
+GO(glVertexAttribI3ui, vFuuuu)
+GO(glVertexAttribI3uiv, vFup)
+GO(glVertexAttribI4bv, vFup)
+GO(glVertexAttribI4i, vFuiiii)
+GO(glVertexAttribI4iv, vFup)
+GO(glVertexAttribI4sv, vFup)
+GO(glVertexAttribI4ubv, vFup)
+GO(glVertexAttribI4ui, vFuuuuu)
+GO(glVertexAttribI4uiv, vFup)
+GO(glVertexAttribI4usv, vFup)
+GO(glVertexAttribIPointer, vFuiuip)
+//VERSION_3_1
+GO(glDrawArraysInstanced, vFuiii)
+GO(glDrawElementsInstanced, vFuiupi)
+GO(glPrimitiveRestartIndex, vFu)
+GO(glTexBuffer, vFuuu)
+//VERSION_3_2
+GO(glFramebufferTexture, vFuuui)
+GO(glGetBufferParameteri64v, vFuup)
+GO(glGetInteger64i_v, vFuup)
+//VERSION_3_3
+GO(glVertexAttribDivisor, vFuu)
+//VERSION_4_0
+GO(glBlendEquationSeparatei, vFuuu)
+GO(glBlendEquationi, vFuu)
+GO(glBlendFuncSeparatei, vFuuuuu)
+GO(glBlendFunci, vFuuu)
+GO(glMinSampleShading, vFf)
+//VERSION_4_3
+GO(glInvalidateNamedFramebuffer, vFiup)
+//VERSION_4_4
+GO(glBindBuffersBase, vFiuip)
+GO(glBindBuffersRange, vFuuippp)
+GO(glBindImageTextures, vFuip)
+GO(glBindSamplers, vFuip)
+GO(glBindTextures, vFuip)
+GO(glBindVertexBuffers, vFuippp)
+GO(glBufferStorage, vFulpu)
+GO(glClearTexImage, vFuiuup)
+GO(glClearTexSubImage, vFuiiiiiiiiip)
+//VERSION_4_5
+GO(glClipControl, vFii)
+GO(glCreateTransformFeedbacks, vFlp)
+GO(glTransformFeedbackBufferBase, vFuuu)
+GO(glTransformFeedbackBufferRange, vFuuull)
+GO(glGetTransformFeedbackiv, vFuip)
+GO(glGetTransformFeedbacki_v, vFuiup)
+GO(glGetTransformFeedbacki64_v, vFuuup)
+GO(glCreateBuffers, vFlp)
+GO(glNamedBufferStorage, vFulpu)
+GO(glNamedBufferStorageEXT, vFulpu)
+GO(glNamedBufferData, vFulpi)
+GO(glNamedBufferSubData, vFullp)
+GO(glCopyNamedBufferSubData, vFuulll)
+GO(glClearNamedBufferData, vFuiiip)
+GO(glClearNamedBufferSubData, vFuulluup)
+GO(glMapNamedBuffer, pFui)
+GO(glMapNamedBufferRange, pFullu)
+GO(glUnmapNamedBuffer, iFu)
+GO(glFlushMappedNamedBufferRange, vFull)
+GO(glGetNamedBufferParameteriv, vFuip)
+GO(glGetNamedBufferParameteri64v, vFuip)
+GO(glGetNamedBufferPointerv, vFuip)
+GO(glGetNamedBufferSubData, vFullp)
+GO(glCreateFramebuffers, vFlp)
+GO(glNamedFramebufferRenderbuffer, vFuiiu)
+GO(glNamedFramebufferParameteri, vFuii)
+GO(glNamedFramebufferTexture, vFuiui)
+GO(glNamedFramebufferTextureLayer, vFuiuii)
+GO(glNamedFramebufferDrawBuffer, vFui)
+GO(glNamedFramebufferDrawBuffers, vFulp)
+GO(glNamedFramebufferReadBuffer, vFui)
+GO(glInvalidateNamedFramebufferData, vFulp)
+GO(glInvalidateNamedFramebufferSubData, vFuipiiii)
+GO(glClearNamedFramebufferiv, vFuuip)
+GO(glClearNamedFramebufferuiv, vFuuip)
+GO(glClearNamedFramebufferfv, vFuuip)
+GO(glClearNamedFramebufferfi, vFuuifi)
+GO(glBlitNamedFramebuffer, vFuuiiiiiiiiui)
+GO(glCheckNamedFramebufferStatus, iFui)
+GO(glGetNamedFramebufferParameteriv, vFuip)
+GO(glGetNamedFramebufferAttachmentParameteriv, vFuiip)
+GO(glCreateRenderbuffers, vFlp)
+GO(glNamedRenderbufferStorage, vFuill)
+GO(glNamedRenderbufferStorageMultisample, vFulill)
+GO(glGetNamedRenderbufferParameteriv, vFuip)
+GO(glCreateTextures, vFilp)
+GO(glTextureBuffer, vFuiu)
+GO(glTextureBufferRange, vFuuull)
+GO(glTextureStorage1D, vFuiui)
+GO(glTextureStorage2D, vFulill)
+GO(glTextureStorage3D, vFuiuiii)
+GO(glTextureStorage2DMultisample, vFuiuiiC)
+GO(glTextureStorage3DMultisample, vFuiuiiiC)
+GO(glTextureSubImage1D, vFuiiiuup)
+GO(glTextureSubImage2D, vFuiiiiiuup)
+GO(glTextureSubImage3D, vFuiiiiiiiuup)
+GO(glCompressedTextureSubImage1D, vFuiiiuip)
+GO(glCompressedTextureSubImage2D, vFuiiiiiuip)
+GO(glCompressedTextureSubImage3D, vFuiiiiiiiuip)
+GO(glCopyTextureSubImage1D, vFuiiiii)
+GO(glCopyTextureSubImage2D, vFuiiiiiii)
+GO(glCopyTextureSubImage3D, vFuiiiiiiii)
+GO(glTextureParameterf, vFuif)
+GO(glTextureParameterfv, vFuip)
+GO(glTextureParameteri, vFuii)
+GO(glTextureParameterIiv, vFuip)
+GO(glTextureParameterIuiv, vFuup)
+GO(glTextureParameteriv, vFuip)
+GO(glGenerateTextureMipmap, vFu)
+GO(glBindTextureUnit, vFuu)
+GO(glGetTextureImage, vFuiuuip)
+GO(glGetCompressedTextureImage, vFuiip)
+GO(glGetTextureLevelParameterfv, vFuiup)
+GO(glGetTextureLevelParameteriv, vFuiup)
+GO(glGetTextureParameterfv, vFuip)
+GO(glGetTextureParameterIiv, vFuip)
+GO(glGetTextureParameterIuiv, vFuip)
+GO(glGetTextureParameteriv, vFuip)
+GO(glCreateVertexArrays, vFlp)
+GO(glDisableVertexArrayAttrib, vFuu)
+GO(glEnableVertexArrayAttrib, vFuu)
+GO(glVertexArrayElementBuffer, vFuu)
+GO(glVertexArrayVertexBuffer, vFuuull)
+GO(glVertexArrayVertexBuffers, vFuuippp)
+GO(glVertexArrayAttribBinding, vFuuu)
+GO(glVertexArrayAttribFormat, vFuuiiiu)
+GO(glVertexArrayAttribIFormat, vFuuiiu)
+GO(glVertexArrayAttribLFormat, vFuuiiu)
+GO(glVertexArrayBindingDivisor, vFuuu)
+GO(glGetVertexArrayiv, vFuip)
+GO(glGetVertexArrayIndexediv, vFuuip)
+GO(glGetVertexArrayIndexed64iv, vFuuip)
+GO(glCreateSamplers, vFlp)
+GO(glCreateProgramPipelines, vFip)
+GO(glTextureBarrier, vFv)
+GO(glTextureParameteriiv, vFuip)
+GO(glTextureParameteriuiv, vFuip)
+GO(glCreateQueries, vFilp)
+GO(glGetQueryBufferObjecti64v, vFuuil)
+GO(glGetQueryBufferObjectiv, vFuuil)
+GO(glGetQueryBufferObjectui64v, vFuuil)
+GO(glGetQueryBufferObjectuiv, vFuuul)
+GO(glMemoryBarrierByRegion, vFu)
+GO(glGetTextureSubImage, vFuiiiiiiiuuip)
+GO(glGetCompressedTextureSubImage, vFuiiiiiiiip)
+GO(glGetGraphicsResetStatus, iFv)
+//VERSION_4_6
+GO(glSpecializeShader, vFippp)
+
+GO(glTexturePageCommitmentEXT, vFuiiiiiiiC)
+GO(glVertexArrayVertexAttribDivisorEXT, vFuuu)
+
// _fini
//3DFX_tbuffer
-GO(glTbufferMask3DFX,vFu)
+GO(glTbufferMask3DFX, vFu)
//AMD_debug_output
-GOM(glDebugMessageCallbackAMD,vFEpp)
-GO(glDebugMessageEnableAMD,vFuuipi)
-GO(glDebugMessageInsertAMD,vFuuuip)
-GO(glGetDebugMessageLogAMD,uFuippppp)
+GOM(glDebugMessageCallbackAMD, vFEpp)
+GO(glDebugMessageEnableAMD, vFuuipC)
+GO(glDebugMessageInsertAMD, vFuuuip)
+GO(glGetDebugMessageLogAMD, uFuippppp)
//AMD_draw_buffers_blend
-GO(glBlendEquationIndexedAMD,vFuu)
-GO(glBlendEquationSeparateIndexedAMD,vFuuu)
-GO(glBlendFuncIndexedAMD,vFuuu)
-GO(glBlendFuncSeparateIndexedAMD,vFuuuuu)
+GO(glBlendEquationIndexedAMD, vFuu)
+GO(glBlendEquationSeparateIndexedAMD, vFuuu)
+GO(glBlendFuncIndexedAMD, vFuuu)
+GO(glBlendFuncSeparateIndexedAMD, vFuuuuu)
//AMD_multi_draw_indirect
-GO(glMultiDrawArraysIndirectAMD,vFupii)
-GO(glMultiDrawElementsIndirectAMD,vFuupii)
+GO(glMultiDrawArraysIndirectAMD, vFupii)
+GO(glMultiDrawElementsIndirectAMD, vFuupii)
//AMD_name_gen_delete
-GO(glDeleteNamesAMD,vFuup)
-GO(glGenNamesAMD,vFuup)
-GO(glIsNameAMD,iFuu)
+GO(glDeleteNamesAMD, vFuup)
+GO(glGenNamesAMD, vFuup)
+GO(glIsNameAMD, iFuu)
//AMD_performance_monitor
-GO(glBeginPerfMonitorAMD,vFu)
-GO(glDeletePerfMonitorsAMD,vFip)
-GO(glEndPerfMonitorAMD,vFu)
-GO(glGenPerfMonitorsAMD,vFip)
-GO(glGetPerfMonitorCounterDataAMD,vFuuipp)
-GO(glGetPerfMonitorCounterInfoAMD,vFuuup)
-GO(glGetPerfMonitorCounterStringAMD,vFuuipp)
-GO(glGetPerfMonitorCountersAMD,vFuppip)
-GO(glGetPerfMonitorGroupStringAMD,vFuipp)
-GO(glGetPerfMonitorGroupsAMD,vFpip)
-GO(glSelectPerfMonitorCountersAMD,vFuiuip)
+GO(glBeginPerfMonitorAMD, vFu)
+GO(glDeletePerfMonitorsAMD, vFip)
+GO(glEndPerfMonitorAMD, vFu)
+GO(glGenPerfMonitorsAMD, vFip)
+GO(glGetPerfMonitorCounterDataAMD, vFuuipp)
+GO(glGetPerfMonitorCounterInfoAMD, vFuuup)
+GO(glGetPerfMonitorCounterStringAMD, vFuuipp)
+GO(glGetPerfMonitorCountersAMD, vFuppip)
+GO(glGetPerfMonitorGroupStringAMD, vFuipp)
+GO(glGetPerfMonitorGroupsAMD, vFpip)
+GO(glSelectPerfMonitorCountersAMD, vFuCuip)
//AMD_sample_positions
-GO(glSetMultisamplefvAMD,vFuup)
+GO(glSetMultisamplefvAMD, vFuup)
//AMD_sparse_texture
-GO(glTexStorageSparseAMD,vFuuiiiii)
-GO(glTextureStorageSparseAMD,vFuuuiiiii)
+GO(glTexStorageSparseAMD, vFuuiiiiu)
+GO(glTextureStorageSparseAMD, vFuuuiiiiu)
//AMD_stencil_operation_extended
-GO(glStencilOpValueAMD,vFuu)
+GO(glStencilOpValueAMD, vFuu)
//AMD_vertex_shader_tessellator
-GO(glTessellationFactorAMD,vFf)
-GO(glTessellationModeAMD,vFu)
+GO(glTessellationFactorAMD, vFf)
+GO(glTessellationModeAMD, vFu)
//APPLE_element_array
-GO(glDrawElementArrayAPPLE,vFuii)
-GO(glDrawRangeElementArrayAPPLE,vFuuuii)
-GO(glElementPointerAPPLE,vFup)
-GO(glMultiDrawElementArrayAPPLE,vFuppi)
-GO(glMultiDrawRangeElementArrayAPPLE,vFuuuppi)
+GO(glDrawElementArrayAPPLE, vFuii)
+GO(glDrawRangeElementArrayAPPLE, vFuuuii)
+GO(glElementPointerAPPLE, vFup)
+GO(glMultiDrawElementArrayAPPLE, vFuppi)
+GO(glMultiDrawRangeElementArrayAPPLE, vFuuuppi)
//APPLE_fence
-GO(glDeleteFencesAPPLE,vFip)
-GO(glFinishFenceAPPLE,vFu)
-GO(glFinishObjectAPPLE,vFui)
-GO(glGenFencesAPPLE,vFip)
-GO(glIsFenceAPPLE,iFu)
-GO(glSetFenceAPPLE,vFu)
-GO(glTestFenceAPPLE,iFu)
-GO(glTestObjectAPPLE,iFuu)
+GO(glDeleteFencesAPPLE, vFip)
+GO(glFinishFenceAPPLE, vFu)
+GO(glFinishObjectAPPLE, vFui)
+GO(glGenFencesAPPLE, vFip)
+GO(glIsFenceAPPLE, iFu)
+GO(glSetFenceAPPLE, vFu)
+GO(glTestFenceAPPLE, iFu)
+GO(glTestObjectAPPLE, iFuu)
//APPLE_flush_buffer_range
-GO(glBufferParameteriAPPLE,vFuui)
-GO(glFlushMappedBufferRangeAPPLE,vFuii)
+GO(glBufferParameteriAPPLE, vFuui)
+GO(glFlushMappedBufferRangeAPPLE, vFull)
//APPLE_object_purgeable
-GO(glGetObjectParameterivAPPLE,vFuuup)
-GO(glObjectPurgeableAPPLE,uFuuu)
-GO(glObjectUnpurgeableAPPLE,uFuuu)
+GO(glGetObjectParameterivAPPLE, vFuuup)
+GO(glObjectPurgeableAPPLE, uFuuu)
+GO(glObjectUnpurgeableAPPLE, uFuuu)
//APPLE_texture_range
-GO(glGetTexParameterPointervAPPLE,vFuup)
-GO(glTextureRangeAPPLE,vFuip)
+GO(glGetTexParameterPointervAPPLE, vFuup)
+GO(glTextureRangeAPPLE, vFuip)
//APPLE_vertex_array_object
-GO(glBindVertexArrayAPPLE,vFu)
-GO(glDeleteVertexArraysAPPLE,vFip)
-GO(glGenVertexArraysAPPLE,vFip)
-GO(glIsVertexArrayAPPLE,iFu)
+GO(glBindVertexArrayAPPLE, vFu)
+GO(glDeleteVertexArraysAPPLE, vFip)
+GO(glGenVertexArraysAPPLE, vFip)
+GO(glIsVertexArrayAPPLE, iFu)
//APPLE_vertex_array_range
-GO(glFlushVertexArrayRangeAPPLE,vFip)
-GO(glVertexArrayParameteriAPPLE,vFui)
-GO(glVertexArrayRangeAPPLE,vFip)
+GO(glFlushVertexArrayRangeAPPLE, vFip)
+GO(glVertexArrayParameteriAPPLE, vFui)
+GO(glVertexArrayRangeAPPLE, vFip)
//APPLE_vertex_program_evaluators
-GO(glDisableVertexAttribAPPLE,vFuu)
-GO(glEnableVertexAttribAPPLE,vFuu)
-GO(glIsVertexAttribEnabledAPPLE,iFuu)
-GO(glMapVertexAttrib1dAPPLE,vFuuddiip)
-GO(glMapVertexAttrib1fAPPLE,vFuuffiip)
-GO(glMapVertexAttrib2dAPPLE,vFuuddiiddiip)
-GO(glMapVertexAttrib2fAPPLE,vFuuffiiffiip)
+GO(glDisableVertexAttribAPPLE, vFuu)
+GO(glEnableVertexAttribAPPLE, vFuu)
+GO(glIsVertexAttribEnabledAPPLE, iFuu)
+GO(glMapVertexAttrib1dAPPLE, vFuuddiip)
+GO(glMapVertexAttrib1fAPPLE, vFuuffiip)
+GO(glMapVertexAttrib2dAPPLE, vFuuddiiddiip)
+GO(glMapVertexAttrib2fAPPLE, vFuuffiiffiip)
//ARB_ES2_compatibility
-GO(glClearDepthf,vFf)
-GO(glDepthRangef,vFff)
-GO(glGetShaderPrecisionFormat,vFuupp)
-GO(glReleaseShaderCompiler,vFv)
-GO(glShaderBinary,vFipupi)
+GO(glClearDepthf, vFf)
+GO(glDepthRangef, vFff)
+GO(glGetShaderPrecisionFormat, vFuupp)
+GO(glReleaseShaderCompiler, vFv)
+GO(glShaderBinary, vFipupi)
//ARB_base_instance
-GO(glDrawArraysInstancedBaseInstance,vFuiiiu)
-GO(glDrawElementsInstancedBaseInstance,vFuiupiu)
-GO(glDrawElementsInstancedBaseVertexBaseInstance,vFuiupiiu)
+GO(glDrawArraysInstancedBaseInstance, vFuiiiu)
+GO(glDrawElementsInstancedBaseInstance, vFuiupiu)
+GO(glDrawElementsInstancedBaseVertexBaseInstance, vFuiupiiu)
//ARB_blend_func_extended
-GO(glBindFragDataLocationIndexed,vFuuup)
-GO(glGetFragDataIndex,iFup)
+GO(glBindFragDataLocationIndexed, vFuuup)
+GO(glGetFragDataIndex, iFup)
//ARB_cl_event
-GO(glCreateSyncFromCLeventARB,pFppi)
+GO(glCreateSyncFromCLeventARB, pFppu)
//ARB_clear_buffer_object
-GO(glClearBufferData,vFuuuup)
-GO(glClearBufferSubData,vFuuiiuup)
-GO(glClearNamedBufferDataEXT,vFuuuup)
-GO(glClearNamedBufferSubDataEXT,vFuuuuiip)
+GO(glClearBufferData, vFuuuup)
+GO(glClearBufferSubData, vFuulluup)
+GO(glClearNamedBufferDataEXT, vFuuuup)
+GO(glClearNamedBufferSubDataEXT, vFuulluup)
//ARB_color_buffer_float
-GO(glClampColorARB,vFuu)
+GO(glClampColorARB, vFuu)
//ARB_compute_shader
-GO(glDispatchCompute,vFuuu)
-GO(glDispatchComputeIndirect,vFi)
+GO(glDispatchCompute, vFuuu)
+GO(glDispatchComputeIndirect, vFi)
//ARB_copy_buffer
-GO(glCopyBufferSubData,vFuuiii)
+GO(glCopyBufferSubData, vFuulll)
//ARB_copy_image
-GO(glCopyImageSubData,vFuuiiiiuuiiiiiii)
+GO(glCopyImageSubData, vFuuiiiiuuiiiiiii)
//ARB_debug_output
-GOM(glDebugMessageCallbackARB,vFEpp)
-GO(glDebugMessageControlARB,vFuuuipi)
-GO(glDebugMessageInsertARB,vFuuuuip)
-GO(glGetDebugMessageLogARB,uFuipppppp)
+GOM(glDebugMessageCallbackARB, vFEpp)
+GO(glDebugMessageControlARB, vFuuuipC)
+GO(glDebugMessageInsertARB, vFuuuuip)
+GO(glGetDebugMessageLogARB, uFuipppppp)
//ARB_draw_buffers
-GO(glDrawBuffersARB,vFip)
+GO(glDrawBuffersARB, vFip)
//ARB_draw_buffers_blend
-GO(glBlendEquationSeparateiARB,vFuuu)
-GO(glBlendEquationiARB,vFuu)
-GO(glBlendFuncSeparateiARB,vFuuuuu)
-GO(glBlendFunciARB,vFuuu)
+GO(glBlendEquationSeparateiARB, vFuuu)
+GO(glBlendEquationiARB, vFuu)
+GO(glBlendFuncSeparateiARB, vFuuuuu)
+GO(glBlendFunciARB, vFuuu)
//ARB_draw_elements_base_vertex
-GO(glDrawElementsBaseVertex,vFuiupi)
-GO(glDrawElementsInstancedBaseVertex,vFuiupii)
-GO(glDrawRangeElementsBaseVertex,vFuuuiupi)
-GO(glMultiDrawElementsBaseVertex,vFupupip)
+GO(glDrawElementsBaseVertex, vFuiupi)
+GO(glDrawElementsInstancedBaseVertex, vFuiupii)
+GO(glDrawRangeElementsBaseVertex, vFuuuiupi)
+GO(glMultiDrawElementsBaseVertex, vFupupip)
//ARB_draw_indirect
-GO(glDrawArraysIndirect,vFup)
-GO(glDrawElementsIndirect,vFuup)
+GO(glDrawArraysIndirect, vFup)
+GO(glDrawElementsIndirect, vFuup)
//ARB_draw_instanced
-GO(glDrawArraysInstancedARB,vFuiii)
-GO(glDrawElementsInstancedARB,vFuiupi)
+GO(glDrawArraysInstancedARB, vFuiii)
+GO(glDrawElementsInstancedARB, vFuiupi)
//ARB_framebuffer_no_attachments
-GO(glFramebufferParameteri,vFuui)
-GO(glGetFramebufferParameteriv,vFuup)
-GO(glGetNamedFramebufferParameterivEXT,vFuup)
-GO(glNamedFramebufferParameteriEXT,vFuui)
+GO(glFramebufferParameteri, vFuui)
+GO(glGetFramebufferParameteriv, vFuup)
+GO(glGetNamedFramebufferParameterivEXT, vFuup)
+GO(glNamedFramebufferParameteriEXT, vFuui)
//ARB_framebuffer_object
-GO(glBindFramebuffer,vFuu)
-GO(glBindRenderbuffer,vFuu)
-GO(glBlitFramebuffer,vFiiiiiiiiiu)
-GO(glCheckFramebufferStatus,uFu)
-GO(glDeleteFramebuffers,vFip)
-GO(glDeleteRenderbuffers,vFip)
-GO(glFramebufferRenderbuffer,vFuuuu)
-GO(glFramebufferTexture1D,vFuuuui)
-GO(glFramebufferTexture2D,vFuuuui)
-GO(glFramebufferTexture3D,vFuuuuii)
-GO(glFramebufferTextureLayer,vFuuuii)
-GO(glGenFramebuffers,vFip)
-GO(glGenRenderbuffers,vFip)
-GO(glGenerateMipmap,vFu)
-GO(glGetFramebufferAttachmentParameteriv,vFuuup)
-GO(glGetRenderbufferParameteriv,vFuup)
-GO(glIsFramebuffer,iFu)
-GO(glIsRenderbuffer,iFu)
-GO(glRenderbufferStorage,vFuuii)
-GO(glRenderbufferStorageMultisample,vFuiuii)
+GO(glBindFramebuffer, vFuu)
+GO(glBindRenderbuffer, vFuu)
+GO(glBlitFramebuffer, vFiiiiiiiiiu)
+GO(glCheckFramebufferStatus, uFu)
+GO(glDeleteFramebuffers, vFip)
+GO(glDeleteRenderbuffers, vFip)
+GO(glFramebufferRenderbuffer, vFuuuu)
+GO(glFramebufferTexture1D, vFuuuui)
+GO(glFramebufferTexture2D, vFuuuui)
+GO(glFramebufferTexture3D, vFuuuuii)
+GO(glFramebufferTextureLayer, vFuuuii)
+GO(glGenFramebuffers, vFip)
+GO(glGenRenderbuffers, vFip)
+GO(glGenerateMipmap, vFu)
+GO(glGetFramebufferAttachmentParameteriv, vFuuup)
+GO(glGetRenderbufferParameteriv, vFuup)
+GO(glIsFramebuffer, iFu)
+GO(glIsRenderbuffer, iFu)
+GO(glRenderbufferStorage, vFuuii)
+GO(glRenderbufferStorageMultisample, vFuiuii)
//ARB_geometry_shader4
-GO(glFramebufferTextureARB,vFuuui)
-GO(glFramebufferTextureFaceARB,vFuuuiu)
-GO(glFramebufferTextureLayerARB,vFuuuii)
-GO(glProgramParameteriARB,vFuui)
+GO(glFramebufferTextureARB, vFuuui)
+GO(glFramebufferTextureFaceARB, vFuuuiu)
+GO(glFramebufferTextureLayerARB, vFuuuii)
+GO(glProgramParameteriARB, vFuui)
//ARB_get_program_binary
-GO(glGetProgramBinary,vFuippp)
-GO(glProgramBinary,vFuupi)
-GO(glProgramParameteri,vFuui)
+GO(glGetProgramBinary, vFuippp)
+GO(glProgramBinary, vFuupi)
+GO(glProgramParameteri, vFuui)
//ARB_gpu_shader_fp64
-GO(glGetUniformdv,vFuip)
-GO(glUniform1d,vFid)
-GO(glUniform1dv,vFiip)
-GO(glUniform2d,vFidd)
-GO(glUniform2dv,vFiip)
-GO(glUniform3d,vFiddd)
-GO(glUniform3dv,vFiip)
-GO(glUniform4d,vFidddd)
-GO(glUniform4dv,vFiip)
-GO(glUniformMatrix2dv,vFiiip)
-GO(glUniformMatrix2x3dv,vFiiip)
-GO(glUniformMatrix2x4dv,vFiiip)
-GO(glUniformMatrix3dv,vFiiip)
-GO(glUniformMatrix3x2dv,vFiiip)
-GO(glUniformMatrix3x4dv,vFiiip)
-GO(glUniformMatrix4dv,vFiiip)
-GO(glUniformMatrix4x2dv,vFiiip)
-GO(glUniformMatrix4x3dv,vFiiip)
+GO(glGetUniformdv, vFuip)
+GO(glUniform1d, vFid)
+GO(glUniform1dv, vFiip)
+GO(glUniform2d, vFidd)
+GO(glUniform2dv, vFiip)
+GO(glUniform3d, vFiddd)
+GO(glUniform3dv, vFiip)
+GO(glUniform4d, vFidddd)
+GO(glUniform4dv, vFiip)
+GO(glUniformMatrix2dv, vFiiip)
+GO(glUniformMatrix2x3dv, vFiiip)
+GO(glUniformMatrix2x4dv, vFiiip)
+GO(glUniformMatrix3dv, vFiiip)
+GO(glUniformMatrix3x2dv, vFiiip)
+GO(glUniformMatrix3x4dv, vFiiip)
+GO(glUniformMatrix4dv, vFiiip)
+GO(glUniformMatrix4x2dv, vFiiip)
+GO(glUniformMatrix4x3dv, vFiiCp)
//ARB_instanced_arrays
-GO(glVertexAttribDivisorARB,vFuu)
+GO(glVertexAttribDivisorARB, vFuu)
//ARB_internalformat_query
-GO(glGetInternalformativ,vFuuuip)
+GO(glGetInternalformativ, vFuuuip)
//ARB_internalformat_query2
-GO(glGetInternalformati64v,vFuuuip)
+GO(glGetInternalformati64v, vFuuuip)
//ARB_invalidate_subdata
-GO(glInvalidateBufferData,vFu)
-GO(glInvalidateBufferSubData,vFuii)
-GO(glInvalidateFramebuffer,vFuip)
-GO(glInvalidateSubFramebuffer,vFuipiiii)
-GO(glInvalidateTexImage,vFui)
-GO(glInvalidateTexSubImage,vFuiiiiiii)
+GO(glInvalidateBufferData, vFu)
+GO(glInvalidateBufferSubData, vFuii)
+GO(glInvalidateFramebuffer, vFuip)
+GO(glInvalidateSubFramebuffer, vFuipiiii)
+GO(glInvalidateTexImage, vFui)
+GO(glInvalidateTexSubImage, vFuiiiiiii)
//ARB_map_buffer_range
-GO(glFlushMappedBufferRange,vFull)
-GO(glMapBufferRange,pFulli)
+GO(glFlushMappedBufferRange, vFull)
+GO(glMapBufferRange, pFullu)
//ARB_matrix_palette
-GO(glCurrentPaletteMatrixARB,vFi)
-GO(glMatrixIndexPointerARB,vFiuip)
-GO(glMatrixIndexubvARB,vFip)
-GO(glMatrixIndexuivARB,vFip)
-GO(glMatrixIndexusvARB,vFip)
+GO(glCurrentPaletteMatrixARB, vFi)
+GO(glMatrixIndexPointerARB, vFiuip)
+GO(glMatrixIndexubvARB, vFip)
+GO(glMatrixIndexuivARB, vFip)
+GO(glMatrixIndexusvARB, vFip)
//ARB_multi_draw_indirect
-GO(glMultiDrawArraysIndirect,vFupii)
-GO(glMultiDrawElementsIndirect,vFuupii)
+GO(glMultiDrawArraysIndirect, vFupii)
+GO(glMultiDrawElementsIndirect, vFuupii)
//ARB_multisample
-GO(glSampleCoverageARB,vFfi)
+GO(glSampleCoverageARB, vFfC)
//ARB_multitexture
-GO(glActiveTextureARB,vFu)
-GO(glClientActiveTextureARB,vFu)
-GO(glMultiTexCoord1dARB,vFud)
-GO(glMultiTexCoord1dvARB,vFup)
-GO(glMultiTexCoord1fARB,vFuf)
-GO(glMultiTexCoord1fvARB,vFup)
-GO(glMultiTexCoord1iARB,vFui)
-GO(glMultiTexCoord1ivARB,vFup)
-GO(glMultiTexCoord1sARB,vFui)
-GO(glMultiTexCoord1svARB,vFup)
-GO(glMultiTexCoord2dARB,vFudd)
-GO(glMultiTexCoord2dvARB,vFup)
-GO(glMultiTexCoord2fARB,vFuff)
-GO(glMultiTexCoord2fvARB,vFup)
-GO(glMultiTexCoord2iARB,vFuii)
-GO(glMultiTexCoord2ivARB,vFup)
-GO(glMultiTexCoord2sARB,vFuii)
-GO(glMultiTexCoord2svARB,vFup)
-GO(glMultiTexCoord3dARB,vFuddd)
-GO(glMultiTexCoord3dvARB,vFup)
-GO(glMultiTexCoord3fARB,vFufff)
-GO(glMultiTexCoord3fvARB,vFup)
-GO(glMultiTexCoord3iARB,vFuiii)
-GO(glMultiTexCoord3ivARB,vFup)
-GO(glMultiTexCoord3sARB,vFuiii)
-GO(glMultiTexCoord3svARB,vFup)
-GO(glMultiTexCoord4dARB,vFudddd)
-GO(glMultiTexCoord4dvARB,vFup)
-GO(glMultiTexCoord4fARB,vFuffff)
-GO(glMultiTexCoord4fvARB,vFup)
-GO(glMultiTexCoord4iARB,vFuiiii)
-GO(glMultiTexCoord4ivARB,vFup)
-GO(glMultiTexCoord4sARB,vFuiiii)
-GO(glMultiTexCoord4svARB,vFup)
+GO(glActiveTextureARB, vFu)
+GO(glClientActiveTextureARB, vFu)
+GO(glMultiTexCoord1dARB, vFud)
+GO(glMultiTexCoord1dvARB, vFup)
+GO(glMultiTexCoord1fARB, vFuf)
+GO(glMultiTexCoord1fvARB, vFup)
+GO(glMultiTexCoord1iARB, vFui)
+GO(glMultiTexCoord1ivARB, vFup)
+GO(glMultiTexCoord1sARB, vFui)
+GO(glMultiTexCoord1svARB, vFup)
+GO(glMultiTexCoord2dARB, vFudd)
+GO(glMultiTexCoord2dvARB, vFup)
+GO(glMultiTexCoord2fARB, vFuff)
+GO(glMultiTexCoord2fvARB, vFup)
+GO(glMultiTexCoord2iARB, vFuii)
+GO(glMultiTexCoord2ivARB, vFup)
+GO(glMultiTexCoord2sARB, vFuii)
+GO(glMultiTexCoord2svARB, vFup)
+GO(glMultiTexCoord3dARB, vFuddd)
+GO(glMultiTexCoord3dvARB, vFup)
+GO(glMultiTexCoord3fARB, vFufff)
+GO(glMultiTexCoord3fvARB, vFup)
+GO(glMultiTexCoord3iARB, vFuiii)
+GO(glMultiTexCoord3ivARB, vFup)
+GO(glMultiTexCoord3sARB, vFuiii)
+GO(glMultiTexCoord3svARB, vFup)
+GO(glMultiTexCoord4dARB, vFudddd)
+GO(glMultiTexCoord4dvARB, vFup)
+GO(glMultiTexCoord4fARB, vFuffff)
+GO(glMultiTexCoord4fvARB, vFup)
+GO(glMultiTexCoord4iARB, vFuiiii)
+GO(glMultiTexCoord4ivARB, vFup)
+GO(glMultiTexCoord4sARB, vFuiiii)
+GO(glMultiTexCoord4svARB, vFup)
//ARB_occlusion_query
-GO(glBeginQueryARB,vFuu)
-GO(glDeleteQueriesARB,vFip)
-GO(glEndQueryARB,vFu)
-GO(glGenQueriesARB,vFip)
-GO(glGetQueryObjectivARB,vFuup)
-GO(glGetQueryObjectuivARB,vFuup)
-GO(glGetQueryivARB,vFuup)
-GO(glIsQueryARB,iFu)
+GO(glBeginQueryARB, vFuu)
+GO(glDeleteQueriesARB, vFip)
+GO(glEndQueryARB, vFu)
+GO(glGenQueriesARB, vFip)
+GO(glGetQueryObjectivARB, vFuup)
+GO(glGetQueryObjectuivARB, vFuup)
+GO(glGetQueryivARB, vFuup)
+GO(glIsQueryARB, iFu)
//ARB_point_parameters
-GO(glPointParameterfARB,vFuf)
-GO(glPointParameterfvARB,vFup)
+GO(glPointParameterfARB, vFuf)
+GO(glPointParameterfvARB, vFup)
//ARB_program_interface_query
-GO(glGetProgramInterfaceiv,vFuuup)
-GO(glGetProgramResourceIndex,uFuup)
-GO(glGetProgramResourceLocation,iFuup)
-GO(glGetProgramResourceLocationIndex,iFuup)
-GO(glGetProgramResourceName,vFuuuipp)
-GO(glGetProgramResourceiv,vFuuuipipp)
+GO(glGetProgramInterfaceiv, vFuuup)
+GO(glGetProgramResourceIndex, uFuup)
+GO(glGetProgramResourceLocation, iFuup)
+GO(glGetProgramResourceLocationIndex, iFuup)
+GO(glGetProgramResourceName, vFuuuipp)
+GO(glGetProgramResourceiv, vFuuuipipp)
//ARB_provoking_vertex
-GO(glProvokingVertex,vFu)
+GO(glProvokingVertex, vFu)
//ARB_robustness
-GO(glGetGraphicsResetStatusARB,uFv)
-GO(glGetnColorTableARB,vFuuuip)
-GO(glGetnCompressedTexImageARB,vFuiip)
-GO(glGetnConvolutionFilterARB,vFuuuip)
-GO(glGetnHistogramARB,vFuiuuip)
-GO(glGetnMapdvARB,vFuuip)
-GO(glGetnMapfvARB,vFuuip)
-GO(glGetnMapivARB,vFuuip)
-GO(glGetnMinmaxARB,vFuiuuip)
-GO(glGetnPixelMapfvARB,vFuip)
-GO(glGetnPixelMapuivARB,vFuip)
-GO(glGetnPixelMapusvARB,vFuip)
-GO(glGetnPolygonStippleARB,vFip)
-GO(glGetnSeparableFilterARB,vFuuuipipp)
-GO(glGetnTexImageARB,vFuiuuip)
-GO(glGetnUniformdvARB,vFuiip)
-GO(glGetnUniformfvARB,vFuiip)
-GO(glGetnUniformivARB,vFuiip)
-GO(glGetnUniformuivARB,vFuiip)
-GO(glReadnPixelsARB,vFiiiiuuip)
+GO(glGetGraphicsResetStatusARB, uFv)
+GO(glGetnColorTableARB, vFuuuip)
+GO(glGetnCompressedTexImageARB, vFuiip)
+GO(glGetnConvolutionFilterARB, vFuuuip)
+GO(glGetnHistogramARB, vFuiuuip)
+GO(glGetnMapdvARB, vFuuip)
+GO(glGetnMapfvARB, vFuuip)
+GO(glGetnMapivARB, vFuuip)
+GO(glGetnMinmaxARB, vFuCuuip)
+GO(glGetnPixelMapfvARB, vFuip)
+GO(glGetnPixelMapuivARB, vFuip)
+GO(glGetnPixelMapusvARB, vFuip)
+GO(glGetnPolygonStippleARB, vFip)
+GO(glGetnSeparableFilterARB, vFuuuipipp)
+GO(glGetnTexImageARB, vFuiuuip)
+GO(glGetnUniformdvARB, vFuiip)
+GO(glGetnUniformfvARB, vFuiip)
+GO(glGetnUniformivARB, vFuiip)
+GO(glGetnUniformuivARB, vFuiip)
+GO(glReadnPixelsARB, vFiiiiuuip)
//ARB_sample_shading
-GO(glMinSampleShadingARB,vFf)
+GO(glMinSampleShadingARB, vFf)
//ARB_sampler_objects
-GO(glBindSampler,vFuu)
-GO(glDeleteSamplers,vFip)
-GO(glGenSamplers,vFip)
-GO(glGetSamplerParameterIiv,vFuup)
-GO(glGetSamplerParameterIuiv,vFuup)
-GO(glGetSamplerParameterfv,vFuup)
-GO(glGetSamplerParameteriv,vFuup)
-GO(glIsSampler,iFu)
-GO(glSamplerParameterIiv,vFuup)
-GO(glSamplerParameterIuiv,vFuup)
-GO(glSamplerParameterf,vFuuf)
-GO(glSamplerParameterfv,vFuup)
-GO(glSamplerParameteri,vFuui)
-GO(glSamplerParameteriv,vFuup)
+GO(glBindSampler, vFuu)
+GO(glDeleteSamplers, vFip)
+GO(glGenSamplers, vFip)
+GO(glGetSamplerParameterIiv, vFuup)
+GO(glGetSamplerParameterIuiv, vFuup)
+GO(glGetSamplerParameterfv, vFuup)
+GO(glGetSamplerParameteriv, vFuup)
+GO(glIsSampler, iFu)
+GO(glSamplerParameterIiv, vFuup)
+GO(glSamplerParameterIuiv, vFuup)
+GO(glSamplerParameterf, vFuuf)
+GO(glSamplerParameterfv, vFuup)
+GO(glSamplerParameteri, vFuui)
+GO(glSamplerParameteriv, vFuup)
//ARB_separate_shader_objects
-GO(glActiveShaderProgram,vFuu)
-GO(glBindProgramPipeline,vFu)
-GO(glCreateShaderProgramv,uFuip)
-GO(glDeleteProgramPipelines,vFip)
-GO(glGenProgramPipelines,vFip)
-GO(glGetProgramPipelineInfoLog,vFuipp)
-GO(glGetProgramPipelineiv,vFuup)
-GO(glIsProgramPipeline,iFu)
-GO(glProgramUniform1d,vFuid)
-GO(glProgramUniform1dv,vFuiip)
-GO(glProgramUniform1f,vFuif)
-GO(glProgramUniform1fv,vFuiip)
-GO(glProgramUniform1i,vFuii)
-GO(glProgramUniform1iv,vFuiip)
-GO(glProgramUniform1ui,vFuiu)
-GO(glProgramUniform1uiv,vFuiip)
-GO(glProgramUniform2d,vFuidd)
-GO(glProgramUniform2dv,vFuiip)
-GO(glProgramUniform2f,vFuiff)
-GO(glProgramUniform2fv,vFuiip)
-GO(glProgramUniform2i,vFuiii)
-GO(glProgramUniform2iv,vFuiip)
-GO(glProgramUniform2ui,vFuiuu)
-GO(glProgramUniform2uiv,vFuiip)
-GO(glProgramUniform3d,vFuiddd)
-GO(glProgramUniform3dv,vFuiip)
-GO(glProgramUniform3f,vFuifff)
-GO(glProgramUniform3fv,vFuiip)
-GO(glProgramUniform3i,vFuiiii)
-GO(glProgramUniform3iv,vFuiip)
-GO(glProgramUniform3ui,vFuiuuu)
-GO(glProgramUniform3uiv,vFuiip)
-GO(glProgramUniform4d,vFuidddd)
-GO(glProgramUniform4dv,vFuiip)
-GO(glProgramUniform4f,vFuiffff)
-GO(glProgramUniform4fv,vFuiip)
-GO(glProgramUniform4i,vFuiiiii)
-GO(glProgramUniform4iv,vFuiip)
-GO(glProgramUniform4ui,vFuiuuuu)
-GO(glProgramUniform4uiv,vFuiip)
-GO(glProgramUniformMatrix2dv,vFuiiip)
-GO(glProgramUniformMatrix2fv,vFuiiip)
-GO(glProgramUniformMatrix2x3dv,vFuiiip)
-GO(glProgramUniformMatrix2x3fv,vFuiiip)
-GO(glProgramUniformMatrix2x4dv,vFuiiip)
-GO(glProgramUniformMatrix2x4fv,vFuiiip)
-GO(glProgramUniformMatrix3dv,vFuiiip)
-GO(glProgramUniformMatrix3fv,vFuiiip)
-GO(glProgramUniformMatrix3x2dv,vFuiiip)
-GO(glProgramUniformMatrix3x2fv,vFuiiip)
-GO(glProgramUniformMatrix3x4dv,vFuiiip)
-GO(glProgramUniformMatrix3x4fv,vFuiiip)
-GO(glProgramUniformMatrix4dv,vFuiiip)
-GO(glProgramUniformMatrix4fv,vFuiiip)
-GO(glProgramUniformMatrix4x2dv,vFuiiip)
-GO(glProgramUniformMatrix4x2fv,vFuiiip)
-GO(glProgramUniformMatrix4x3dv,vFuiiip)
-GO(glProgramUniformMatrix4x3fv,vFuiiip)
-GO(glUseProgramStages,vFuiu)
-GO(glValidateProgramPipeline,vFu)
+GO(glActiveShaderProgram, vFuu)
+GO(glBindProgramPipeline, vFu)
+GO(glCreateShaderProgramv, uFuip)
+GO(glDeleteProgramPipelines, vFip)
+GO(glGenProgramPipelines, vFip)
+GO(glGetProgramPipelineInfoLog, vFuipp)
+GO(glGetProgramPipelineiv, vFuup)
+GO(glIsProgramPipeline, iFu)
+GO(glProgramUniform1d, vFuid)
+GO(glProgramUniform1dv, vFuiip)
+GO(glProgramUniform1f, vFuif)
+GO(glProgramUniform1fv, vFuiip)
+GO(glProgramUniform1i, vFuii)
+GO(glProgramUniform1iv, vFuiip)
+GO(glProgramUniform1ui, vFuiu)
+GO(glProgramUniform1uiv, vFuiip)
+GO(glProgramUniform2d, vFuidd)
+GO(glProgramUniform2dv, vFuiip)
+GO(glProgramUniform2f, vFuiff)
+GO(glProgramUniform2fv, vFuiip)
+GO(glProgramUniform2i, vFuiii)
+GO(glProgramUniform2iv, vFuiip)
+GO(glProgramUniform2ui, vFuiuu)
+GO(glProgramUniform2uiv, vFuiip)
+GO(glProgramUniform3d, vFuiddd)
+GO(glProgramUniform3dv, vFuiip)
+GO(glProgramUniform3f, vFuifff)
+GO(glProgramUniform3fv, vFuiip)
+GO(glProgramUniform3i, vFuiiii)
+GO(glProgramUniform3iv, vFuiip)
+GO(glProgramUniform3ui, vFuiuuu)
+GO(glProgramUniform3uiv, vFuiip)
+GO(glProgramUniform4d, vFuidddd)
+GO(glProgramUniform4dv, vFuiip)
+GO(glProgramUniform4f, vFuiffff)
+GO(glProgramUniform4fv, vFuiip)
+GO(glProgramUniform4i, vFuiiiii)
+GO(glProgramUniform4iv, vFuiip)
+GO(glProgramUniform4ui, vFuiuuuu)
+GO(glProgramUniform4uiv, vFuiip)
+GO(glProgramUniformMatrix2dv, vFuiiip)
+GO(glProgramUniformMatrix2fv, vFuiiip)
+GO(glProgramUniformMatrix2x3dv, vFuiiip)
+GO(glProgramUniformMatrix2x3fv, vFuiiip)
+GO(glProgramUniformMatrix2x4dv, vFuiiip)
+GO(glProgramUniformMatrix2x4fv, vFuiiip)
+GO(glProgramUniformMatrix3dv, vFuiiip)
+GO(glProgramUniformMatrix3fv, vFuiiip)
+GO(glProgramUniformMatrix3x2dv, vFuiiip)
+GO(glProgramUniformMatrix3x2fv, vFuiiip)
+GO(glProgramUniformMatrix3x4dv, vFuiiip)
+GO(glProgramUniformMatrix3x4fv, vFuiiip)
+GO(glProgramUniformMatrix4dv, vFuiiip)
+GO(glProgramUniformMatrix4fv, vFuiiip)
+GO(glProgramUniformMatrix4x2dv, vFuiiip)
+GO(glProgramUniformMatrix4x2fv, vFuiiip)
+GO(glProgramUniformMatrix4x3dv, vFuiiip)
+GO(glProgramUniformMatrix4x3fv, vFuiiip)
+GO(glUseProgramStages, vFuuu)
+GO(glValidateProgramPipeline, vFu)
//ARB_shader_atomic_counters
-GO(glGetActiveAtomicCounterBufferiv,vFuuup)
+GO(glGetActiveAtomicCounterBufferiv, vFuuup)
//ARB_shader_image_load_store
-GO(glBindImageTexture,vFuuiiiuu)
-GO(glMemoryBarrier,vFi)
+GO(glBindImageTexture, vFuuiCiuu)
+GO(glMemoryBarrier, vFi)
//ARB_shader_objects
-GO(glAttachObjectARB,vFuu)
-GO(glCompileShaderARB,vFu)
-GO(glCreateProgramObjectARB,uFv)
-GO(glCreateShaderObjectARB,uFu)
-GO(glDeleteObjectARB,vFu)
-GO(glDetachObjectARB,vFuu)
-GO(glGetActiveUniformARB,vFuuipppp)
-GO(glGetAttachedObjectsARB,vFuipp)
-GO(glGetHandleARB,uFu)
-GO(glGetInfoLogARB,vFuipp)
-GO(glGetObjectParameterfvARB,vFuup)
-GO(glGetObjectParameterivARB,vFuup)
-GO(glGetShaderSourceARB,vFuipp)
-GO(glGetUniformLocationARB,iFup)
-GO(glGetUniformfvARB,vFuip)
-GO(glGetUniformivARB,vFuip)
-GO(glLinkProgramARB,vFu)
-GO(glShaderSourceARB,vFuipp)
-GO(glUniform1fARB,vFif)
-GO(glUniform1fvARB,vFiip)
-GO(glUniform1iARB,vFii)
-GO(glUniform1ivARB,vFiip)
-GO(glUniform2fARB,vFiff)
-GO(glUniform2fvARB,vFiip)
-GO(glUniform2iARB,vFiii)
-GO(glUniform2ivARB,vFiip)
-GO(glUniform3fARB,vFifff)
-GO(glUniform3fvARB,vFiip)
-GO(glUniform3iARB,vFiiii)
-GO(glUniform3ivARB,vFiip)
-GO(glUniform4fARB,vFiffff)
-GO(glUniform4fvARB,vFiip)
-GO(glUniform4iARB,vFiiiii)
-GO(glUniform4ivARB,vFiip)
-GO(glUniformMatrix2fvARB,vFiiip)
-GO(glUniformMatrix3fvARB,vFiiip)
-GO(glUniformMatrix4fvARB,vFiiip)
-GO(glUseProgramObjectARB,vFu)
-GO(glValidateProgramARB,vFu)
+GO(glAttachObjectARB, vFuu)
+GO(glCompileShaderARB, vFu)
+GO(glCreateProgramObjectARB, uFv)
+GO(glCreateShaderObjectARB, uFu)
+GO(glDeleteObjectARB, vFu)
+GO(glDetachObjectARB, vFuu)
+GO(glGetActiveUniformARB, vFuuipppp)
+GO(glGetAttachedObjectsARB, vFuipp)
+GO(glGetHandleARB, uFu)
+GO(glGetInfoLogARB, vFuipp)
+GO(glGetObjectParameterfvARB, vFuup)
+GO(glGetObjectParameterivARB, vFuup)
+GO(glGetShaderSourceARB, vFuipp)
+GO(glGetUniformLocationARB, iFup)
+GO(glGetUniformfvARB, vFuip)
+GO(glGetUniformivARB, vFuip)
+GO(glLinkProgramARB, vFu)
+GO(glShaderSourceARB, vFuipp)
+GO(glUniform1fARB, vFif)
+GO(glUniform1fvARB, vFiip)
+GO(glUniform1iARB, vFii)
+GO(glUniform1ivARB, vFiip)
+GO(glUniform2fARB, vFiff)
+GO(glUniform2fvARB, vFiip)
+GO(glUniform2iARB, vFiii)
+GO(glUniform2ivARB, vFiip)
+GO(glUniform3fARB, vFifff)
+GO(glUniform3fvARB, vFiip)
+GO(glUniform3iARB, vFiiii)
+GO(glUniform3ivARB, vFiip)
+GO(glUniform4fARB, vFiffff)
+GO(glUniform4fvARB, vFiip)
+GO(glUniform4iARB, vFiiiii)
+GO(glUniform4ivARB, vFiip)
+GO(glUniformMatrix2fvARB, vFiiip)
+GO(glUniformMatrix3fvARB, vFiiip)
+GO(glUniformMatrix4fvARB, vFiiCp)
+GO(glUseProgramObjectARB, vFu)
+GO(glValidateProgramARB, vFu)
//ARB_shader_storage_buffer_object
-GO(glShaderStorageBlockBinding,vFuuu)
+GO(glShaderStorageBlockBinding, vFuuu)
//ARB_shader_subroutine
-GO(glGetActiveSubroutineName,vFuuuipp)
-GO(glGetActiveSubroutineUniformName,vFuuuipp)
-GO(glGetActiveSubroutineUniformiv,vFuuuup)
-GO(glGetProgramStageiv,vFuuup)
-GO(glGetSubroutineIndex,uFuup)
-GO(glGetSubroutineUniformLocation,iFuup)
-GO(glGetUniformSubroutineuiv,vFuip)
-GO(glUniformSubroutinesuiv,vFuip)
+GO(glGetActiveSubroutineName, vFuuuipp)
+GO(glGetActiveSubroutineUniformName, vFuuuipp)
+GO(glGetActiveSubroutineUniformiv, vFuuuup)
+GO(glGetProgramStageiv, vFuuup)
+GO(glGetSubroutineIndex, uFuup)
+GO(glGetSubroutineUniformLocation, iFuup)
+GO(glGetUniformSubroutineuiv, vFuip)
+GO(glUniformSubroutinesuiv, vFuip)
//ARB_shading_language_include
-GO(glCompileShaderIncludeARB,vFuipp)
-GO(glDeleteNamedStringARB,vFip)
-GO(glGetNamedStringARB,vFipipp)
-GO(glGetNamedStringivARB,vFipup)
-GO(glIsNamedStringARB,iFip)
-GO(glNamedStringARB,vFuipip)
+GO(glCompileShaderIncludeARB, vFuipp)
+GO(glDeleteNamedStringARB, vFip)
+GO(glGetNamedStringARB, vFipipp)
+GO(glGetNamedStringivARB, vFipup)
+GO(glIsNamedStringARB, CFip)
+GO(glNamedStringARB, vFuipip)
//ARB_sync
-GO(glClientWaitSync,iFpuU)
-GO(glDeleteSync,vFp)
-GO(glFenceSync,pFiu)
-GO(glGetInteger64v,vFup)
-GO(glGetSynciv,vFpuipp)
-GO(glIsSync,iFp)
-GO(glWaitSync,vFpiu)
+GO(glClientWaitSync, uFpuL)
+GO(glDeleteSync, vFp)
+GO(glFenceSync, pFuu)
+GO(glGetInteger64v, vFup)
+GO(glGetSynciv, vFpuipp)
+GO(glIsSync, CFp)
+GO(glWaitSync, vFpuL)
//ARB_tessellation_shader
-GO(glPatchParameterfv,vFup)
-GO(glPatchParameteri,vFui)
+GO(glPatchParameterfv, vFup)
+GO(glPatchParameteri, vFui)
//ARB_texture_buffer_object
-GO(glTexBufferARB,vFuuu)
+GO(glTexBufferARB, vFuuu)
//ARB_texture_buffer_range
-GO(glTexBufferRange,vFuuuii)
-GO(glTextureBufferRangeEXT,vFuuuuii)
+GO(glTexBufferRange, vFuuull)
+GO(glTextureBufferRangeEXT, vFuuuull)
//ARB_texture_compression
-GO(glCompressedTexImage1DARB,vFuiuiiip)
-GO(glCompressedTexImage2DARB,vFuiuiiiip)
-GO(glCompressedTexImage3DARB,vFuiuiiiiip)
-GO(glCompressedTexSubImage1DARB,vFuiiiuip)
-GO(glCompressedTexSubImage2DARB,vFuiiiiiuip)
-GO(glCompressedTexSubImage3DARB,vFuiiiiiiiuip)
-GO(glGetCompressedTexImageARB,vFuip)
+GO(glCompressedTexImage1DARB, vFuiuiiip)
+GO(glCompressedTexImage2DARB, vFuiuiiiip)
+GO(glCompressedTexImage3DARB, vFuiuiiiiip)
+GO(glCompressedTexSubImage1DARB, vFuiiiuip)
+GO(glCompressedTexSubImage2DARB, vFuiiiiiuip)
+GO(glCompressedTexSubImage3DARB, vFuiiiiiiiuip)
+GO(glGetCompressedTexImageARB, vFuip)
//ARB_texture_multisample
-GO(glGetMultisamplefv,vFuup)
-GO(glSampleMaski,vFui)
-GO(glTexImage2DMultisample,vFuiiiii)
-GO(glTexImage3DMultisample,vFuiiiiii)
+GO(glGetMultisamplefv, vFuup)
+GO(glSampleMaski, vFui)
+GO(glTexImage2DMultisample, vFuiiiii)
+GO(glTexImage3DMultisample, vFuiiiiii)
//ARB_texture_storage
-GO(glTexStorage1D,vFuiui)
-GO(glTexStorage2D,vFuiuii)
-GO(glTexStorage3D,vFuiuiii)
-GO(glTextureStorage1DEXT,vFuuiui)
-GO(glTextureStorage2DEXT,vFuuiuii)
-GO(glTextureStorage3DEXT,vFuuiuiii)
+GO(glTexStorage1D, vFuiui)
+GO(glTexStorage2D, vFuiuii)
+GO(glTexStorage3D, vFuiuiii)
+GO(glTextureStorage1DEXT, vFuuiui)
+GO(glTextureStorage2DEXT, vFuuiuii)
+GO(glTextureStorage3DEXT, vFuuiuiii)
//ARB_texture_storage_multisample
-GO(glTexStorage2DMultisample,vFuiuiii)
-GO(glTexStorage3DMultisample,vFuiuiiii)
-GO(glTextureStorage2DMultisampleEXT,vFuuiuiii)
-GO(glTextureStorage3DMultisampleEXT,vFuuiuiiii)
+GO(glTexStorage2DMultisample, vFuiuiiC)
+GO(glTexStorage3DMultisample, vFuiuiiiC)
+GO(glTextureStorage2DMultisampleEXT, vFuuiuiiC)
+GO(glTextureStorage3DMultisampleEXT, vFuuiuiiiC)
//ARB_texture_view
-GO(glTextureView,vFuuuuuuuu)
+GO(glTextureView, vFuuuuuuuu)
//ARB_timer_query
-GO(glGetQueryObjecti64v,vFuup)
-GO(glGetQueryObjectui64v,vFuup)
-GO(glQueryCounter,vFuu)
+GO(glGetQueryObjecti64v, vFuup)
+GO(glGetQueryObjectui64v, vFuup)
+GO(glQueryCounter, vFuu)
//ARB_transform_feedback2
-GO(glBindTransformFeedback,vFuu)
-GO(glDeleteTransformFeedbacks,vFip)
-GO(glDrawTransformFeedback,vFuu)
-GO(glGenTransformFeedbacks,vFip)
-GO(glIsTransformFeedback,iFu)
-GO(glPauseTransformFeedback,vFv)
-GO(glResumeTransformFeedback,vFv)
+GO(glBindTransformFeedback, vFuu)
+GO(glDeleteTransformFeedbacks, vFip)
+GO(glDrawTransformFeedback, vFuu)
+GO(glGenTransformFeedbacks, vFip)
+GO(glIsTransformFeedback, iFu)
+GO(glPauseTransformFeedback, vFv)
+GO(glResumeTransformFeedback, vFv)
//ARB_transform_feedback3
-GO(glBeginQueryIndexed,vFuuu)
-GO(glDrawTransformFeedbackStream,vFuuu)
-GO(glEndQueryIndexed,vFuu)
-GO(glGetQueryIndexediv,vFuuup)
+GO(glBeginQueryIndexed, vFuuu)
+GO(glDrawTransformFeedbackStream, vFuuu)
+GO(glEndQueryIndexed, vFuu)
+GO(glGetQueryIndexediv, vFuuup)
//ARB_transform_feedback_instanced
-GO(glDrawTransformFeedbackInstanced,vFuui)
-GO(glDrawTransformFeedbackStreamInstanced,vFuuui)
+GO(glDrawTransformFeedbackInstanced, vFuui)
+GO(glDrawTransformFeedbackStreamInstanced, vFuuui)
//ARB_transpose_matrix
-GO(glLoadTransposeMatrixdARB,vFp)
-GO(glLoadTransposeMatrixfARB,vFp)
-GO(glMultTransposeMatrixdARB,vFp)
-GO(glMultTransposeMatrixfARB,vFp)
+GO(glLoadTransposeMatrixdARB, vFp)
+GO(glLoadTransposeMatrixfARB, vFp)
+GO(glMultTransposeMatrixdARB, vFp)
+GO(glMultTransposeMatrixfARB, vFp)
//ARB_uniform_buffer_object
-GO(glGetActiveUniformBlockName,vFuuipp)
-GO(glGetActiveUniformBlockiv,vFuuup)
-GO(glGetActiveUniformName,vFuuipp)
-GO(glGetActiveUniformsiv,vFuipup)
-GO(glGetUniformBlockIndex,uFup)
-GO(glGetUniformIndices,vFuipp)
-GO(glUniformBlockBinding,vFuuu)
+GO(glGetActiveUniformBlockName, vFuuipp)
+GO(glGetActiveUniformBlockiv, vFuuup)
+GO(glGetActiveUniformName, vFuuipp)
+GO(glGetActiveUniformsiv, vFuipup)
+GO(glGetUniformBlockIndex, uFup)
+GO(glGetUniformIndices, vFuipp)
+GO(glUniformBlockBinding, vFuuu)
//ARB_vertex_array_object
-GO(glBindVertexArray,vFu)
-GO(glDeleteVertexArrays,vFip)
-GO(glGenVertexArrays,vFip)
-GO(glIsVertexArray,iFu)
+GO(glBindVertexArray, vFu)
+GO(glDeleteVertexArrays, vFip)
+GO(glGenVertexArrays, vFip)
+GO(glIsVertexArray, iFu)
//ARB_vertex_attrib_64bit
-GO(glGetVertexAttribLdv,vFuup)
-GO(glVertexAttribL1d,vFud)
-GO(glVertexAttribL1dv,vFup)
-GO(glVertexAttribL2d,vFudd)
-GO(glVertexAttribL2dv,vFup)
-GO(glVertexAttribL3d,vFuddd)
-GO(glVertexAttribL3dv,vFup)
-GO(glVertexAttribL4d,vFudddd)
-GO(glVertexAttribL4dv,vFup)
-GO(glVertexAttribLPointer,vFuiuip)
+GO(glGetVertexAttribLdv, vFuup)
+GO(glVertexAttribL1d, vFud)
+GO(glVertexAttribL1dv, vFup)
+GO(glVertexAttribL2d, vFudd)
+GO(glVertexAttribL2dv, vFup)
+GO(glVertexAttribL3d, vFuddd)
+GO(glVertexAttribL3dv, vFup)
+GO(glVertexAttribL4d, vFudddd)
+GO(glVertexAttribL4dv, vFup)
+GO(glVertexAttribLPointer, vFuiuip)
//ARB_vertex_attrib_binding
-GO(glBindVertexBuffer,vFuuii)
-GO(glVertexArrayBindVertexBufferEXT,vFuuuii)
-GO(glVertexArrayVertexAttribBindingEXT,vFuuu)
-GO(glVertexArrayVertexAttribFormatEXT,vFuuiuiu)
-GO(glVertexArrayVertexAttribIFormatEXT,vFuuiuu)
-GO(glVertexArrayVertexAttribLFormatEXT,vFuuiuu)
-GO(glVertexArrayVertexBindingDivisorEXT,vFuuu)
-GO(glVertexAttribBinding,vFuu)
-GO(glVertexAttribFormat,vFuiuiu)
-GO(glVertexAttribIFormat,vFuiuu)
-GO(glVertexAttribLFormat,vFuiuu)
-GO(glVertexBindingDivisor,vFuu)
+GO(glBindVertexBuffer, vFuuli)
+GO(glVertexArrayBindVertexBufferEXT, vFuuuli)
+GO(glVertexArrayVertexAttribBindingEXT, vFuuu)
+GO(glVertexArrayVertexAttribFormatEXT, vFuuiuCu)
+GO(glVertexArrayVertexAttribIFormatEXT, vFuuiuu)
+GO(glVertexArrayVertexAttribLFormatEXT, vFuuiuu)
+GO(glVertexArrayVertexBindingDivisorEXT, vFuuu)
+GO(glVertexAttribBinding, vFuu)
+GO(glVertexAttribFormat, vFuiuCu)
+GO(glVertexAttribIFormat, vFuiuu)
+GO(glVertexAttribLFormat, vFuiuu)
+GO(glVertexBindingDivisor, vFuu)
//ARB_vertex_blend
-GO(glVertexBlendARB,vFi)
-GO(glWeightPointerARB,vFiuip)
-GO(glWeightbvARB,vFip)
-GO(glWeightdvARB,vFip)
-GO(glWeightfvARB,vFip)
-GO(glWeightivARB,vFip)
-GO(glWeightsvARB,vFip)
-GO(glWeightubvARB,vFip)
-GO(glWeightuivARB,vFip)
-GO(glWeightusvARB,vFip)
+GO(glVertexBlendARB, vFi)
+GO(glWeightPointerARB, vFiuip)
+GO(glWeightbvARB, vFip)
+GO(glWeightdvARB, vFip)
+GO(glWeightfvARB, vFip)
+GO(glWeightivARB, vFip)
+GO(glWeightsvARB, vFip)
+GO(glWeightubvARB, vFip)
+GO(glWeightuivARB, vFip)
+GO(glWeightusvARB, vFip)
//ARB_vertex_buffer_object
-GO(glBindBufferARB,vFuu)
-GO(glBufferDataARB,vFuipu)
-GO(glBufferSubDataARB,vFuiip)
-GO(glDeleteBuffersARB,vFip)
-GO(glGenBuffersARB,vFip)
-GO(glGetBufferParameterivARB,vFuup)
-GO(glGetBufferPointervARB,vFuup)
-GO(glGetBufferSubDataARB,vFuiip)
-GO(glIsBufferARB,iFu)
-GO(glMapBufferARB,pFuu)
-GO(glUnmapBufferARB,iFu)
+GO(glBindBufferARB, vFuu)
+GO(glBufferDataARB, vFulpu)
+GO(glBufferSubDataARB, vFullp)
+GO(glDeleteBuffersARB, vFip)
+GO(glGenBuffersARB, vFip)
+GO(glGetBufferParameterivARB, vFuup)
+GO(glGetBufferPointervARB, vFuup)
+GO(glGetBufferSubDataARB, vFullp)
+GO(glIsBufferARB, iFu)
+GO(glMapBufferARB, pFuu)
+GO(glUnmapBufferARB, iFu)
//ARB_vertex_program
-GO(glBindProgramARB,vFuu)
-GO(glDeleteProgramsARB,vFip)
-GO(glDisableVertexAttribArrayARB,vFu)
-GO(glEnableVertexAttribArrayARB,vFu)
-GO(glGenProgramsARB,vFip)
-GO(glGetProgramEnvParameterdvARB,vFuup)
-GO(glGetProgramEnvParameterfvARB,vFuup)
-GO(glGetProgramLocalParameterdvARB,vFuup)
-GO(glGetProgramLocalParameterfvARB,vFuup)
-GO(glGetProgramStringARB,vFuup)
-GO(glGetProgramivARB,vFuup)
-GO(glGetVertexAttribPointervARB,vFuup)
-GO(glGetVertexAttribdvARB,vFuup)
-GO(glGetVertexAttribfvARB,vFuup)
-GO(glGetVertexAttribivARB,vFuup)
-GO(glIsProgramARB,iFu)
-GO(glProgramEnvParameter4dARB,vFuudddd)
-GO(glProgramEnvParameter4dvARB,vFuup)
-GO(glProgramEnvParameter4fARB,vFuuffff)
-GO(glProgramEnvParameter4fvARB,vFuup)
-GO(glProgramLocalParameter4dARB,vFuudddd)
-GO(glProgramLocalParameter4dvARB,vFuup)
-GO(glProgramLocalParameter4fARB,vFuuffff)
-GO(glProgramLocalParameter4fvARB,vFuup)
-GO(glProgramStringARB,vFuuip)
-GO(glVertexAttrib1dARB,vFud)
-GO(glVertexAttrib1dvARB,vFup)
-GO(glVertexAttrib1fARB,vFuf)
-GO(glVertexAttrib1fvARB,vFup)
-GO(glVertexAttrib1sARB,vFui)
-GO(glVertexAttrib1svARB,vFup)
-GO(glVertexAttrib2dARB,vFudd)
-GO(glVertexAttrib2dvARB,vFup)
-GO(glVertexAttrib2fARB,vFuff)
-GO(glVertexAttrib2fvARB,vFup)
-GO(glVertexAttrib2sARB,vFuii)
-GO(glVertexAttrib2svARB,vFup)
-GO(glVertexAttrib3dARB,vFuddd)
-GO(glVertexAttrib3dvARB,vFup)
-GO(glVertexAttrib3fARB,vFufff)
-GO(glVertexAttrib3fvARB,vFup)
-GO(glVertexAttrib3sARB,vFuiii)
-GO(glVertexAttrib3svARB,vFup)
-GO(glVertexAttrib4NbvARB,vFup)
-GO(glVertexAttrib4NivARB,vFup)
-GO(glVertexAttrib4NsvARB,vFup)
-GO(glVertexAttrib4NubARB,vFuuuuu)
-GO(glVertexAttrib4NubvARB,vFup)
-GO(glVertexAttrib4NuivARB,vFup)
-GO(glVertexAttrib4NusvARB,vFup)
-GO(glVertexAttrib4bvARB,vFup)
-GO(glVertexAttrib4dARB,vFudddd)
-GO(glVertexAttrib4dvARB,vFup)
-GO(glVertexAttrib4fARB,vFuffff)
-GO(glVertexAttrib4fvARB,vFup)
-GO(glVertexAttrib4ivARB,vFup)
-GO(glVertexAttrib4sARB,vFuiiii)
-GO(glVertexAttrib4svARB,vFup)
-GO(glVertexAttrib4ubvARB,vFup)
-GO(glVertexAttrib4uivARB,vFup)
-GO(glVertexAttrib4usvARB,vFup)
-GO(glVertexAttribPointerARB,vFuiuiip)
+GO(glBindProgramARB, vFuu)
+GO(glDeleteProgramsARB, vFip)
+GO(glDisableVertexAttribArrayARB, vFu)
+GO(glEnableVertexAttribArrayARB, vFu)
+GO(glGenProgramsARB, vFip)
+GO(glGetProgramEnvParameterdvARB, vFuup)
+GO(glGetProgramEnvParameterfvARB, vFuup)
+GO(glGetProgramLocalParameterdvARB, vFuup)
+GO(glGetProgramLocalParameterfvARB, vFuup)
+GO(glGetProgramStringARB, vFuup)
+GO(glGetProgramivARB, vFuup)
+GO(glGetVertexAttribPointervARB, vFuup)
+GO(glGetVertexAttribdvARB, vFuup)
+GO(glGetVertexAttribfvARB, vFuup)
+GO(glGetVertexAttribivARB, vFuup)
+GO(glIsProgramARB, iFu)
+GO(glProgramEnvParameter4dARB, vFuudddd)
+GO(glProgramEnvParameter4dvARB, vFuup)
+GO(glProgramEnvParameter4fARB, vFuuffff)
+GO(glProgramEnvParameter4fvARB, vFuup)
+GO(glProgramLocalParameter4dARB, vFuudddd)
+GO(glProgramLocalParameter4dvARB, vFuup)
+GO(glProgramLocalParameter4fARB, vFuuffff)
+GO(glProgramLocalParameter4fvARB, vFuup)
+GO(glProgramStringARB, vFuuip)
+GO(glVertexAttrib1dARB, vFud)
+GO(glVertexAttrib1dvARB, vFup)
+GO(glVertexAttrib1fARB, vFuf)
+GO(glVertexAttrib1fvARB, vFup)
+GO(glVertexAttrib1sARB, vFui)
+GO(glVertexAttrib1svARB, vFup)
+GO(glVertexAttrib2dARB, vFudd)
+GO(glVertexAttrib2dvARB, vFup)
+GO(glVertexAttrib2fARB, vFuff)
+GO(glVertexAttrib2fvARB, vFup)
+GO(glVertexAttrib2sARB, vFuii)
+GO(glVertexAttrib2svARB, vFup)
+GO(glVertexAttrib3dARB, vFuddd)
+GO(glVertexAttrib3dvARB, vFup)
+GO(glVertexAttrib3fARB, vFufff)
+GO(glVertexAttrib3fvARB, vFup)
+GO(glVertexAttrib3sARB, vFuiii)
+GO(glVertexAttrib3svARB, vFup)
+GO(glVertexAttrib4NbvARB, vFup)
+GO(glVertexAttrib4NivARB, vFup)
+GO(glVertexAttrib4NsvARB, vFup)
+GO(glVertexAttrib4NubARB, vFuuuuu)
+GO(glVertexAttrib4NubvARB, vFup)
+GO(glVertexAttrib4NuivARB, vFup)
+GO(glVertexAttrib4NusvARB, vFup)
+GO(glVertexAttrib4bvARB, vFup)
+GO(glVertexAttrib4dARB, vFudddd)
+GO(glVertexAttrib4dvARB, vFup)
+GO(glVertexAttrib4fARB, vFuffff)
+GO(glVertexAttrib4fvARB, vFup)
+GO(glVertexAttrib4ivARB, vFup)
+GO(glVertexAttrib4sARB, vFuiiii)
+GO(glVertexAttrib4svARB, vFup)
+GO(glVertexAttrib4ubvARB, vFup)
+GO(glVertexAttrib4uivARB, vFup)
+GO(glVertexAttrib4usvARB, vFup)
+GO(glVertexAttribPointerARB, vFuiuCip)
//ARB_vertex_shader
-GO(glBindAttribLocationARB,vFuup)
-GO(glGetActiveAttribARB,vFuuipppp)
-GO(glGetAttribLocationARB,iFup)
+GO(glBindAttribLocationARB, vFuup)
+GO(glGetActiveAttribARB, vFuuipppp)
+GO(glGetAttribLocationARB, iFup)
//ARB_vertex_type_2_10_10_10_rev
-GO(glColorP3ui,vFuu)
-GO(glColorP3uiv,vFup)
-GO(glColorP4ui,vFuu)
-GO(glColorP4uiv,vFup)
-GO(glMultiTexCoordP1ui,vFuuu)
-GO(glMultiTexCoordP1uiv,vFuup)
-GO(glMultiTexCoordP2ui,vFuuu)
-GO(glMultiTexCoordP2uiv,vFuup)
-GO(glMultiTexCoordP3ui,vFuuu)
-GO(glMultiTexCoordP3uiv,vFuup)
-GO(glMultiTexCoordP4ui,vFuuu)
-GO(glMultiTexCoordP4uiv,vFuup)
-GO(glNormalP3ui,vFuu)
-GO(glNormalP3uiv,vFup)
-GO(glSecondaryColorP3ui,vFuu)
-GO(glSecondaryColorP3uiv,vFup)
-GO(glTexCoordP1ui,vFuu)
-GO(glTexCoordP1uiv,vFup)
-GO(glTexCoordP2ui,vFuu)
-GO(glTexCoordP2uiv,vFup)
-GO(glTexCoordP3ui,vFuu)
-GO(glTexCoordP3uiv,vFup)
-GO(glTexCoordP4ui,vFuu)
-GO(glTexCoordP4uiv,vFup)
-GO(glVertexAttribP1ui,vFuuiu)
-GO(glVertexAttribP1uiv,vFuuip)
-GO(glVertexAttribP2ui,vFuuiu)
-GO(glVertexAttribP2uiv,vFuuip)
-GO(glVertexAttribP3ui,vFuuiu)
-GO(glVertexAttribP3uiv,vFuuip)
-GO(glVertexAttribP4ui,vFuuiu)
-GO(glVertexAttribP4uiv,vFuuip)
-GO(glVertexP2ui,vFuu)
-GO(glVertexP2uiv,vFup)
-GO(glVertexP3ui,vFuu)
-GO(glVertexP3uiv,vFup)
-GO(glVertexP4ui,vFuu)
-GO(glVertexP4uiv,vFup)
+GO(glColorP3ui, vFuu)
+GO(glColorP3uiv, vFup)
+GO(glColorP4ui, vFuu)
+GO(glColorP4uiv, vFup)
+GO(glMultiTexCoordP1ui, vFuuu)
+GO(glMultiTexCoordP1uiv, vFuup)
+GO(glMultiTexCoordP2ui, vFuuu)
+GO(glMultiTexCoordP2uiv, vFuup)
+GO(glMultiTexCoordP3ui, vFuuu)
+GO(glMultiTexCoordP3uiv, vFuup)
+GO(glMultiTexCoordP4ui, vFuuu)
+GO(glMultiTexCoordP4uiv, vFuup)
+GO(glNormalP3ui, vFuu)
+GO(glNormalP3uiv, vFup)
+GO(glSecondaryColorP3ui, vFuu)
+GO(glSecondaryColorP3uiv, vFup)
+GO(glTexCoordP1ui, vFuu)
+GO(glTexCoordP1uiv, vFup)
+GO(glTexCoordP2ui, vFuu)
+GO(glTexCoordP2uiv, vFup)
+GO(glTexCoordP3ui, vFuu)
+GO(glTexCoordP3uiv, vFup)
+GO(glTexCoordP4ui, vFuu)
+GO(glTexCoordP4uiv, vFup)
+GO(glVertexAttribP1ui, vFuuiu)
+GO(glVertexAttribP1uiv, vFuuip)
+GO(glVertexAttribP2ui, vFuuiu)
+GO(glVertexAttribP2uiv, vFuuip)
+GO(glVertexAttribP3ui, vFuuiu)
+GO(glVertexAttribP3uiv, vFuuip)
+GO(glVertexAttribP4ui, vFuuCu)
+GO(glVertexAttribP4uiv, vFuuCp)
+GO(glVertexP2ui, vFuu)
+GO(glVertexP2uiv, vFup)
+GO(glVertexP3ui, vFuu)
+GO(glVertexP3uiv, vFup)
+GO(glVertexP4ui, vFuu)
+GO(glVertexP4uiv, vFup)
//ARB_viewport_array
-GO(glDepthRangeArrayv,vFuip)
-GO(glDepthRangeIndexed,vFudd)
-GO(glGetDoublei_v,vFuup)
-GO(glGetFloati_v,vFuup)
-GO(glScissorArrayv,vFuip)
-GO(glScissorIndexed,vFuiiii)
-GO(glScissorIndexedv,vFup)
-GO(glViewportArrayv,vFuip)
-GO(glViewportIndexedf,vFuffff)
-GO(glViewportIndexedfv,vFup)
+GO(glDepthRangeArrayv, vFuip)
+GO(glDepthRangeIndexed, vFudd)
+GO(glGetDoublei_v, vFuup)
+GO(glGetFloati_v, vFuup)
+GO(glScissorArrayv, vFuip)
+GO(glScissorIndexed, vFuiiii)
+GO(glScissorIndexedv, vFup)
+GO(glViewportArrayv, vFuip)
+GO(glViewportIndexedf, vFuffff)
+GO(glViewportIndexedfv, vFup)
//ARB_window_pos
-GO(glWindowPos2dARB,vFdd)
-GO(glWindowPos2dvARB,vFp)
-GO(glWindowPos2fARB,vFff)
-GO(glWindowPos2fvARB,vFp)
-GO(glWindowPos2iARB,vFii)
-GO(glWindowPos2ivARB,vFp)
-GO(glWindowPos2sARB,vFii)
-GO(glWindowPos2svARB,vFp)
-GO(glWindowPos3dARB,vFddd)
-GO(glWindowPos3dvARB,vFp)
-GO(glWindowPos3fARB,vFfff)
-GO(glWindowPos3fvARB,vFp)
-GO(glWindowPos3iARB,vFiii)
-GO(glWindowPos3ivARB,vFp)
-GO(glWindowPos3sARB,vFiii)
-GO(glWindowPos3svARB,vFp)
+GO(glWindowPos2dARB, vFdd)
+GO(glWindowPos2dvARB, vFp)
+GO(glWindowPos2fARB, vFff)
+GO(glWindowPos2fvARB, vFp)
+GO(glWindowPos2iARB, vFii)
+GO(glWindowPos2ivARB, vFp)
+GO(glWindowPos2sARB, vFii)
+GO(glWindowPos2svARB, vFp)
+GO(glWindowPos3dARB, vFddd)
+GO(glWindowPos3dvARB, vFp)
+GO(glWindowPos3fARB, vFfff)
+GO(glWindowPos3fvARB, vFp)
+GO(glWindowPos3iARB, vFiii)
+GO(glWindowPos3ivARB, vFp)
+GO(glWindowPos3sARB, vFiii)
+GO(glWindowPos3svARB, vFp)
//ATI_draw_buffers
-GO(glDrawBuffersATI,vFip)
+GO(glDrawBuffersATI, vFip)
//ATI_element_array
-GO(glDrawElementArrayATI,vFui)
-GO(glDrawRangeElementArrayATI,vFuuui)
-GO(glElementPointerATI,vFup)
+GO(glDrawElementArrayATI, vFui)
+GO(glDrawRangeElementArrayATI, vFuuui)
+GO(glElementPointerATI, vFup)
//ATI_envmap_bumpmap
-GO(glGetTexBumpParameterfvATI,vFup)
-GO(glGetTexBumpParameterivATI,vFup)
-GO(glTexBumpParameterfvATI,vFup)
-GO(glTexBumpParameterivATI,vFup)
+GO(glGetTexBumpParameterfvATI, vFup)
+GO(glGetTexBumpParameterivATI, vFup)
+GO(glTexBumpParameterfvATI, vFup)
+GO(glTexBumpParameterivATI, vFup)
//ATI_fragment_shader
-GO(glAlphaFragmentOp1ATI,vFuuuuuu)
-GO(glAlphaFragmentOp2ATI,vFuuuuuuuuu)
-GO(glAlphaFragmentOp3ATI,vFuuuuuuuuuuuu)
-GO(glBeginFragmentShaderATI,vFv)
-GO(glBindFragmentShaderATI,vFu)
-GO(glColorFragmentOp1ATI,vFuuuuuuu)
-GO(glColorFragmentOp2ATI,vFuuuuuuuuuu)
-GO(glColorFragmentOp3ATI,vFuuuuuuuuuuuuu)
-GO(glDeleteFragmentShaderATI,vFu)
-GO(glEndFragmentShaderATI,vFv)
-GO(glGenFragmentShadersATI,uFu)
-GO(glPassTexCoordATI,vFuuu)
-GO(glSampleMapATI,vFuuu)
-GO(glSetFragmentShaderConstantATI,vFup)
+GO(glAlphaFragmentOp1ATI, vFuuuuuu)
+GO(glAlphaFragmentOp2ATI, vFuuuuuuuuu)
+GO(glAlphaFragmentOp3ATI, vFuuuuuuuuuuuu)
+GO(glBeginFragmentShaderATI, vFv)
+GO(glBindFragmentShaderATI, vFu)
+GO(glColorFragmentOp1ATI, vFuuuuuuu)
+GO(glColorFragmentOp2ATI, vFuuuuuuuuuu)
+GO(glColorFragmentOp3ATI, vFuuuuuuuuuuuuu)
+GO(glDeleteFragmentShaderATI, vFu)
+GO(glEndFragmentShaderATI, vFv)
+GO(glGenFragmentShadersATI, uFu)
+GO(glPassTexCoordATI, vFuuu)
+GO(glSampleMapATI, vFuuu)
+GO(glSetFragmentShaderConstantATI, vFup)
//ATI_map_object_buffer
-GO(glMapObjectBufferATI,pFu)
-GO(glUnmapObjectBufferATI,vFu)
+GO(glMapObjectBufferATI, pFu)
+GO(glUnmapObjectBufferATI, vFu)
//ATI_pn_triangles
-GO(glPNTrianglesfATI,vFuf)
-GO(glPNTrianglesiATI,vFui)
+GO(glPNTrianglesfATI, vFuf)
+GO(glPNTrianglesiATI, vFui)
//ATI_separate_stencil
-GO(glStencilFuncSeparateATI,vFuuiu)
-GO(glStencilOpSeparateATI,vFuuuu)
+GO(glStencilFuncSeparateATI, vFuuiu)
+GO(glStencilOpSeparateATI, vFuuuu)
//ATI_vertex_array_object
-GO(glArrayObjectATI,vFuiuiuu)
-GO(glFreeObjectBufferATI,vFu)
-GO(glGetArrayObjectfvATI,vFuup)
-GO(glGetArrayObjectivATI,vFuup)
-GO(glGetObjectBufferfvATI,vFuup)
-GO(glGetObjectBufferivATI,vFuup)
-GO(glGetVariantArrayObjectfvATI,vFuup)
-GO(glGetVariantArrayObjectivATI,vFuup)
-GO(glIsObjectBufferATI,iFu)
-GO(glNewObjectBufferATI,uFipu)
-GO(glUpdateObjectBufferATI,vFuuipu)
-GO(glVariantArrayObjectATI,vFuuiuu)
+GO(glArrayObjectATI, vFuiuiuu)
+GO(glFreeObjectBufferATI, vFu)
+GO(glGetArrayObjectfvATI, vFuup)
+GO(glGetArrayObjectivATI, vFuup)
+GO(glGetObjectBufferfvATI, vFuup)
+GO(glGetObjectBufferivATI, vFuup)
+GO(glGetVariantArrayObjectfvATI, vFuup)
+GO(glGetVariantArrayObjectivATI, vFuup)
+GO(glIsObjectBufferATI, iFu)
+GO(glNewObjectBufferATI, uFipu)
+GO(glUpdateObjectBufferATI, vFuuipu)
+GO(glVariantArrayObjectATI, vFuuiuu)
//ATI_vertex_attrib_array_object
-GO(glGetVertexAttribArrayObjectfvATI,vFuup)
-GO(glGetVertexAttribArrayObjectivATI,vFuup)
-GO(glVertexAttribArrayObjectATI,vFuiuiiuu)
+GO(glGetVertexAttribArrayObjectfvATI, vFuup)
+GO(glGetVertexAttribArrayObjectivATI, vFuup)
+GO(glVertexAttribArrayObjectATI, vFuiuCiuu)
//ATI_vertex_streams
-GO(glClientActiveVertexStreamATI,vFu)
-GO(glNormalStream3bATI,vFuiii)
-GO(glNormalStream3bvATI,vFup)
-GO(glNormalStream3dATI,vFuddd)
-GO(glNormalStream3dvATI,vFup)
-GO(glNormalStream3fATI,vFufff)
-GO(glNormalStream3fvATI,vFup)
-GO(glNormalStream3iATI,vFuiii)
-GO(glNormalStream3ivATI,vFup)
-GO(glNormalStream3sATI,vFuiii)
-GO(glNormalStream3svATI,vFup)
-GO(glVertexBlendEnvfATI,vFuf)
-GO(glVertexBlendEnviATI,vFui)
-GO(glVertexStream1dATI,vFud)
-GO(glVertexStream1dvATI,vFup)
-GO(glVertexStream1fATI,vFuf)
-GO(glVertexStream1fvATI,vFup)
-GO(glVertexStream1iATI,vFui)
-GO(glVertexStream1ivATI,vFup)
-GO(glVertexStream1sATI,vFui)
-GO(glVertexStream1svATI,vFup)
-GO(glVertexStream2dATI,vFudd)
-GO(glVertexStream2dvATI,vFup)
-GO(glVertexStream2fATI,vFuff)
-GO(glVertexStream2fvATI,vFup)
-GO(glVertexStream2iATI,vFuii)
-GO(glVertexStream2ivATI,vFup)
-GO(glVertexStream2sATI,vFuii)
-GO(glVertexStream2svATI,vFup)
-GO(glVertexStream3dATI,vFuddd)
-GO(glVertexStream3dvATI,vFup)
-GO(glVertexStream3fATI,vFufff)
-GO(glVertexStream3fvATI,vFup)
-GO(glVertexStream3iATI,vFuiii)
-GO(glVertexStream3ivATI,vFup)
-GO(glVertexStream3sATI,vFuiii)
-GO(glVertexStream3svATI,vFup)
-GO(glVertexStream4dATI,vFudddd)
-GO(glVertexStream4dvATI,vFup)
-GO(glVertexStream4fATI,vFuffff)
-GO(glVertexStream4fvATI,vFup)
-GO(glVertexStream4iATI,vFuiiii)
-GO(glVertexStream4ivATI,vFup)
-GO(glVertexStream4sATI,vFuiiii)
-GO(glVertexStream4svATI,vFup)
+GO(glClientActiveVertexStreamATI, vFu)
+GO(glNormalStream3bATI, vFuccc)
+GO(glNormalStream3bvATI, vFup)
+GO(glNormalStream3dATI, vFuddd)
+GO(glNormalStream3dvATI, vFup)
+GO(glNormalStream3fATI, vFufff)
+GO(glNormalStream3fvATI, vFup)
+GO(glNormalStream3iATI, vFuiii)
+GO(glNormalStream3ivATI, vFup)
+GO(glNormalStream3sATI, vFuwww)
+GO(glNormalStream3svATI, vFup)
+GO(glVertexBlendEnvfATI, vFuf)
+GO(glVertexBlendEnviATI, vFui)
+GO(glVertexStream1dATI, vFud)
+GO(glVertexStream1dvATI, vFup)
+GO(glVertexStream1fATI, vFuf)
+GO(glVertexStream1fvATI, vFup)
+GO(glVertexStream1iATI, vFui)
+GO(glVertexStream1ivATI, vFup)
+GO(glVertexStream1sATI, vFuw)
+GO(glVertexStream1svATI, vFup)
+GO(glVertexStream2dATI, vFudd)
+GO(glVertexStream2dvATI, vFup)
+GO(glVertexStream2fATI, vFuff)
+GO(glVertexStream2fvATI, vFup)
+GO(glVertexStream2iATI, vFuii)
+GO(glVertexStream2ivATI, vFup)
+GO(glVertexStream2sATI, vFuww)
+GO(glVertexStream2svATI, vFup)
+GO(glVertexStream3dATI, vFuddd)
+GO(glVertexStream3dvATI, vFup)
+GO(glVertexStream3fATI, vFufff)
+GO(glVertexStream3fvATI, vFup)
+GO(glVertexStream3iATI, vFuiii)
+GO(glVertexStream3ivATI, vFup)
+GO(glVertexStream3sATI, vFuiii)
+GO(glVertexStream3svATI, vFup)
+GO(glVertexStream4dATI, vFudddd)
+GO(glVertexStream4dvATI, vFup)
+GO(glVertexStream4fATI, vFuffff)
+GO(glVertexStream4fvATI, vFup)
+GO(glVertexStream4iATI, vFuiiii)
+GO(glVertexStream4ivATI, vFup)
+GO(glVertexStream4sATI, vFuwwww)
+GO(glVertexStream4svATI, vFup)
//EXT_bindable_uniform
-GO(glGetUniformBufferSizeEXT,iFui)
-GO(glGetUniformOffsetEXT,iFui)
-GO(glUniformBufferEXT,vFuiu)
+GO(glGetUniformBufferSizeEXT, iFui)
+GO(glGetUniformOffsetEXT, lFui)
+GO(glUniformBufferEXT, vFuiu)
//EXT_blend_color
-GO(glBlendColorEXT,vFffff)
+GO(glBlendColorEXT, vFffff)
//EXT_blend_equation_separate
-GO(glBlendEquationSeparateEXT,vFuu)
+GO(glBlendEquationSeparateEXT, vFuu)
//EXT_blend_func_separate
-GO(glBlendFuncSeparateEXT,vFuuuu)
+GO(glBlendFuncSeparateEXT, vFuuuu)
//EXT_blend_minmax
-GO(glBlendEquationEXT,vFu)
+GO(glBlendEquationEXT, vFu)
//EXT_color_subtable
-GO(glColorSubTableEXT,vFuiiuup)
-GO(glCopyColorSubTableEXT,vFuiiii)
+GO(glColorSubTableEXT, vFuiiuup)
+GO(glCopyColorSubTableEXT, vFuiiii)
//EXT_compiled_vertex_array
-GO(glLockArraysEXT,vFii)
-GO(glUnlockArraysEXT,vFv)
+GO(glLockArraysEXT, vFii)
+GO(glUnlockArraysEXT, vFv)
//EXT_convolution
-GO(glConvolutionFilter1DEXT,vFuuiuup)
-GO(glConvolutionFilter2DEXT,vFuuiiuup)
-GO(glConvolutionParameterfEXT,vFuuf)
-GO(glConvolutionParameterfvEXT,vFuup)
-GO(glConvolutionParameteriEXT,vFuui)
-GO(glConvolutionParameterivEXT,vFuup)
-GO(glCopyConvolutionFilter1DEXT,vFuuiii)
-GO(glCopyConvolutionFilter2DEXT,vFuuiiii)
-GO(glGetConvolutionFilterEXT,vFuuup)
-GO(glGetConvolutionParameterfvEXT,vFuup)
-GO(glGetConvolutionParameterivEXT,vFuup)
-GO(glGetSeparableFilterEXT,vFuuuppp)
-GO(glSeparableFilter2DEXT,vFuuiiuupp)
+GO(glConvolutionFilter1DEXT, vFuuiuup)
+GO(glConvolutionFilter2DEXT, vFuuiiuup)
+GO(glConvolutionParameterfEXT, vFuuf)
+GO(glConvolutionParameterfvEXT, vFuup)
+GO(glConvolutionParameteriEXT, vFuui)
+GO(glConvolutionParameterivEXT, vFuup)
+GO(glCopyConvolutionFilter1DEXT, vFuuiii)
+GO(glCopyConvolutionFilter2DEXT, vFuuiiii)
+GO(glGetConvolutionFilterEXT, vFuuup)
+GO(glGetConvolutionParameterfvEXT, vFuup)
+GO(glGetConvolutionParameterivEXT, vFuup)
+GO(glGetSeparableFilterEXT, vFuuuppp)
+GO(glSeparableFilter2DEXT, vFuuiiuupp)
//EXT_coordinate_frame
-GO(glBinormal3bEXT,vFiii)
-GO(glBinormal3bvEXT,vFp)
-GO(glBinormal3dEXT,vFddd)
-GO(glBinormal3dvEXT,vFp)
-GO(glBinormal3fEXT,vFfff)
-GO(glBinormal3fvEXT,vFp)
-GO(glBinormal3iEXT,vFiii)
-GO(glBinormal3ivEXT,vFp)
-GO(glBinormal3sEXT,vFiii)
-GO(glBinormal3svEXT,vFp)
-GO(glBinormalPointerEXT,vFuip)
-GO(glTangent3bEXT,vFiii)
-GO(glTangent3bvEXT,vFp)
-GO(glTangent3dEXT,vFddd)
-GO(glTangent3dvEXT,vFp)
-GO(glTangent3fEXT,vFfff)
-GO(glTangent3fvEXT,vFp)
-GO(glTangent3iEXT,vFiii)
-GO(glTangent3ivEXT,vFp)
-GO(glTangent3sEXT,vFiii)
-GO(glTangent3svEXT,vFp)
-GO(glTangentPointerEXT,vFuip)
+GO(glBinormal3bEXT, vFiii)
+GO(glBinormal3bvEXT, vFp)
+GO(glBinormal3dEXT, vFddd)
+GO(glBinormal3dvEXT, vFp)
+GO(glBinormal3fEXT, vFfff)
+GO(glBinormal3fvEXT, vFp)
+GO(glBinormal3iEXT, vFiii)
+GO(glBinormal3ivEXT, vFp)
+GO(glBinormal3sEXT, vFiii)
+GO(glBinormal3svEXT, vFp)
+GO(glBinormalPointerEXT, vFuip)
+GO(glTangent3bEXT, vFiii)
+GO(glTangent3bvEXT, vFp)
+GO(glTangent3dEXT, vFddd)
+GO(glTangent3dvEXT, vFp)
+GO(glTangent3fEXT, vFfff)
+GO(glTangent3fvEXT, vFp)
+GO(glTangent3iEXT, vFiii)
+GO(glTangent3ivEXT, vFp)
+GO(glTangent3sEXT, vFiii)
+GO(glTangent3svEXT, vFp)
+GO(glTangentPointerEXT, vFuip)
//EXT_copy_texture
-GO(glCopyTexImage1DEXT,vFuiuiiii)
-GO(glCopyTexImage2DEXT,vFuiuiiiii)
-GO(glCopyTexSubImage1DEXT,vFuiiiii)
-GO(glCopyTexSubImage2DEXT,vFuiiiiiii)
-GO(glCopyTexSubImage3DEXT,vFuiiiiiiii)
+GO(glCopyTexImage1DEXT, vFuiuiiii)
+GO(glCopyTexImage2DEXT, vFuiuiiiii)
+GO(glCopyTexSubImage1DEXT, vFuiiiii)
+GO(glCopyTexSubImage2DEXT, vFuiiiiiii)
+GO(glCopyTexSubImage3DEXT, vFuiiiiiiii)
//EXT_cull_vertex
-GO(glCullParameterdvEXT,vFup)
-GO(glCullParameterfvEXT,vFup)
+GO(glCullParameterdvEXT, vFup)
+GO(glCullParameterfvEXT, vFup)
//EXT_depth_bounds_test
-GO(glDepthBoundsEXT,vFdd)
+GO(glDepthBoundsEXT, vFdd)
//EXT_direct_state_access
-GO(glBindMultiTextureEXT,vFuuu)
-GO(glCheckNamedFramebufferStatusEXT,uFuu)
-GO(glClientAttribDefaultEXT,vFi)
-GO(glCompressedMultiTexImage1DEXT,vFuuiuiiip)
-GO(glCompressedMultiTexImage2DEXT,vFuuiuiiiip)
-GO(glCompressedMultiTexImage3DEXT,vFuuiuiiiiip)
-GO(glCompressedMultiTexSubImage1DEXT,vFuuiiiuip)
-GO(glCompressedMultiTexSubImage2DEXT,vFuuiiiiiuip)
-GO(glCompressedMultiTexSubImage3DEXT,vFuuiiiiiiiuip)
-GO(glCompressedTextureImage1DEXT,vFuuiuiiip)
-GO(glCompressedTextureImage2DEXT,vFuuiuiiiip)
-GO(glCompressedTextureImage3DEXT,vFuuiuiiiiip)
-GO(glCompressedTextureSubImage1DEXT,vFuuiiiuip)
-GO(glCompressedTextureSubImage2DEXT,vFuuiiiiiuip)
-GO(glCompressedTextureSubImage3DEXT,vFuuiiiiiiiuip)
-GO(glCopyMultiTexImage1DEXT,vFuuiuiiii)
-GO(glCopyMultiTexImage2DEXT,vFuuiuiiiii)
-GO(glCopyMultiTexSubImage1DEXT,vFuuiiiii)
-GO(glCopyMultiTexSubImage2DEXT,vFuuiiiiiii)
-GO(glCopyMultiTexSubImage3DEXT,vFuuiiiiiiii)
-GO(glCopyTextureImage1DEXT,vFuuiuiiii)
-GO(glCopyTextureImage2DEXT,vFuuiuiiiii)
-GO(glCopyTextureSubImage1DEXT,vFuuiiiii)
-GO(glCopyTextureSubImage2DEXT,vFuuiiiiiii)
-GO(glCopyTextureSubImage3DEXT,vFuuiiiiiiii)
-GO(glDisableClientStateIndexedEXT,vFuu)
-GO(glDisableClientStateiEXT,vFuu)
-GO(glDisableVertexArrayAttribEXT,vFuu)
-GO(glDisableVertexArrayEXT,vFuu)
-GO(glEnableClientStateIndexedEXT,vFuu)
-GO(glEnableClientStateiEXT,vFuu)
-GO(glEnableVertexArrayAttribEXT,vFuu)
-GO(glEnableVertexArrayEXT,vFuu)
-GO(glFlushMappedNamedBufferRangeEXT,vFuii)
-GO(glFramebufferDrawBufferEXT,vFuu)
-GO(glFramebufferDrawBuffersEXT,vFuip)
-GO(glFramebufferReadBufferEXT,vFuu)
-GO(glGenerateMultiTexMipmapEXT,vFuu)
-GO(glGenerateTextureMipmapEXT,vFuu)
-GO(glGetCompressedMultiTexImageEXT,vFuuip)
-GO(glGetCompressedTextureImageEXT,vFuuip)
-GO(glGetDoubleIndexedvEXT,vFuup)
-GO(glGetDoublei_vEXT,vFuup)
-GO(glGetFloatIndexedvEXT,vFuup)
-GO(glGetFloati_vEXT,vFuup)
-GO(glGetFramebufferParameterivEXT,vFuup)
-GO(glGetMultiTexEnvfvEXT,vFuuup)
-GO(glGetMultiTexEnvivEXT,vFuuup)
-GO(glGetMultiTexGendvEXT,vFuuup)
-GO(glGetMultiTexGenfvEXT,vFuuup)
-GO(glGetMultiTexGenivEXT,vFuuup)
-GO(glGetMultiTexImageEXT,vFuuiuup)
-GO(glGetMultiTexLevelParameterfvEXT,vFuuiup)
-GO(glGetMultiTexLevelParameterivEXT,vFuuiup)
-GO(glGetMultiTexParameterIivEXT,vFuuup)
-GO(glGetMultiTexParameterIuivEXT,vFuuup)
-GO(glGetMultiTexParameterfvEXT,vFuuup)
-GO(glGetMultiTexParameterivEXT,vFuuup)
-GO(glGetNamedBufferParameterivEXT,vFuup)
-GO(glGetNamedBufferPointervEXT,vFuup)
-GO(glGetNamedBufferSubDataEXT,vFuiip)
-GO(glGetNamedFramebufferAttachmentParameterivEXT,vFuuup)
-GO(glGetNamedProgramLocalParameterIivEXT,vFuuup)
-GO(glGetNamedProgramLocalParameterIuivEXT,vFuuup)
-GO(glGetNamedProgramLocalParameterdvEXT,vFuuup)
-GO(glGetNamedProgramLocalParameterfvEXT,vFuuup)
-GO(glGetNamedProgramStringEXT,vFuuup)
-GO(glGetNamedProgramivEXT,vFuuup)
-GO(glGetNamedRenderbufferParameterivEXT,vFuup)
-GO(glGetPointerIndexedvEXT,vFuup)
-GO(glGetPointeri_vEXT,vFuup)
-GO(glGetTextureImageEXT,vFuuiuup)
-GO(glGetTextureLevelParameterfvEXT,vFuuiup)
-GO(glGetTextureLevelParameterivEXT,vFuuiup)
-GO(glGetTextureParameterIivEXT,vFuuup)
-GO(glGetTextureParameterIuivEXT,vFuuup)
-GO(glGetTextureParameterfvEXT,vFuuup)
-GO(glGetTextureParameterivEXT,vFuuup)
-GO(glGetVertexArrayIntegeri_vEXT,vFuuup)
-GO(glGetVertexArrayIntegervEXT,vFuup)
-GO(glGetVertexArrayPointeri_vEXT,vFuuup)
-GO(glGetVertexArrayPointervEXT,vFuup)
-GO(glMapNamedBufferEXT,pFuu)
-GO(glMapNamedBufferRangeEXT,pFuiii)
-GO(glMatrixFrustumEXT,vFudddddd)
-GO(glMatrixLoadIdentityEXT,vFu)
-GO(glMatrixLoadTransposedEXT,vFup)
-GO(glMatrixLoadTransposefEXT,vFup)
-GO(glMatrixLoaddEXT,vFup)
-GO(glMatrixLoadfEXT,vFup)
-GO(glMatrixMultTransposedEXT,vFup)
-GO(glMatrixMultTransposefEXT,vFup)
-GO(glMatrixMultdEXT,vFup)
-GO(glMatrixMultfEXT,vFup)
-GO(glMatrixOrthoEXT,vFudddddd)
-GO(glMatrixPopEXT,vFu)
-GO(glMatrixPushEXT,vFu)
-GO(glMatrixRotatedEXT,vFudddd)
-GO(glMatrixRotatefEXT,vFuffff)
-GO(glMatrixScaledEXT,vFuddd)
-GO(glMatrixScalefEXT,vFufff)
-GO(glMatrixTranslatedEXT,vFuddd)
-GO(glMatrixTranslatefEXT,vFufff)
-GO(glMultiTexBufferEXT,vFuuuu)
-GO(glMultiTexCoordPointerEXT,vFuiuip)
-GO(glMultiTexEnvfEXT,vFuuuf)
-GO(glMultiTexEnvfvEXT,vFuuup)
-GO(glMultiTexEnviEXT,vFuuui)
-GO(glMultiTexEnvivEXT,vFuuup)
-GO(glMultiTexGendEXT,vFuuud)
-GO(glMultiTexGendvEXT,vFuuup)
-GO(glMultiTexGenfEXT,vFuuuf)
-GO(glMultiTexGenfvEXT,vFuuup)
-GO(glMultiTexGeniEXT,vFuuui)
-GO(glMultiTexGenivEXT,vFuuup)
-GO(glMultiTexImage1DEXT,vFuuiuiiuup)
-GO(glMultiTexImage2DEXT,vFuuiuiiiuup)
-GO(glMultiTexImage3DEXT,vFuuiuiiiiuup)
-GO(glMultiTexParameterIivEXT,vFuuup)
-GO(glMultiTexParameterIuivEXT,vFuuup)
-GO(glMultiTexParameterfEXT,vFuuuf)
-GO(glMultiTexParameterfvEXT,vFuuup)
-GO(glMultiTexParameteriEXT,vFuuui)
-GO(glMultiTexParameterivEXT,vFuuup)
-GO(glMultiTexRenderbufferEXT,vFuuu)
-GO(glMultiTexSubImage1DEXT,vFuuiiiuup)
-GO(glMultiTexSubImage2DEXT,vFuuiiiiiuup)
-GO(glMultiTexSubImage3DEXT,vFuuiiiiiiiuup)
-GO(glNamedBufferDataEXT,vFuipu)
-GO(glNamedBufferSubDataEXT,vFuiip)
-GO(glNamedCopyBufferSubDataEXT,vFuuiii)
-GO(glNamedFramebufferRenderbufferEXT,vFuuuu)
-GO(glNamedFramebufferTexture1DEXT,vFuuuui)
-GO(glNamedFramebufferTexture2DEXT,vFuuuui)
-GO(glNamedFramebufferTexture3DEXT,vFuuuuii)
-GO(glNamedFramebufferTextureEXT,vFuuui)
-GO(glNamedFramebufferTextureFaceEXT,vFuuuiu)
-GO(glNamedFramebufferTextureLayerEXT,vFuuuii)
-GO(glNamedProgramLocalParameter4dEXT,vFuuudddd)
-GO(glNamedProgramLocalParameter4dvEXT,vFuuup)
-GO(glNamedProgramLocalParameter4fEXT,vFuuuffff)
-GO(glNamedProgramLocalParameter4fvEXT,vFuuup)
-GO(glNamedProgramLocalParameterI4iEXT,vFuuuiiii)
-GO(glNamedProgramLocalParameterI4ivEXT,vFuuup)
-GO(glNamedProgramLocalParameterI4uiEXT,vFuuuuuuu)
-GO(glNamedProgramLocalParameterI4uivEXT,vFuuup)
-GO(glNamedProgramLocalParameters4fvEXT,vFuuuip)
-GO(glNamedProgramLocalParametersI4ivEXT,vFuuuip)
-GO(glNamedProgramLocalParametersI4uivEXT,vFuuuip)
-GO(glNamedProgramStringEXT,vFuuuip)
-GO(glNamedRenderbufferStorageEXT,vFuuii)
-GO(glNamedRenderbufferStorageMultisampleCoverageEXT,vFuiiuii)
-GO(glNamedRenderbufferStorageMultisampleEXT,vFuiuii)
-GO(glProgramUniform1dEXT,vFuid)
-GO(glProgramUniform1dvEXT,vFuiip)
-GO(glProgramUniform1fEXT,vFuif)
-GO(glProgramUniform1fvEXT,vFuiip)
-GO(glProgramUniform1iEXT,vFuii)
-GO(glProgramUniform1ivEXT,vFuiip)
-GO(glProgramUniform1uiEXT,vFuiu)
-GO(glProgramUniform1uivEXT,vFuiip)
-GO(glProgramUniform2dEXT,vFuidd)
-GO(glProgramUniform2dvEXT,vFuiip)
-GO(glProgramUniform2fEXT,vFuiff)
-GO(glProgramUniform2fvEXT,vFuiip)
-GO(glProgramUniform2iEXT,vFuiii)
-GO(glProgramUniform2ivEXT,vFuiip)
-GO(glProgramUniform2uiEXT,vFuiuu)
-GO(glProgramUniform2uivEXT,vFuiip)
-GO(glProgramUniform3dEXT,vFuiddd)
-GO(glProgramUniform3dvEXT,vFuiip)
-GO(glProgramUniform3fEXT,vFuifff)
-GO(glProgramUniform3fvEXT,vFuiip)
-GO(glProgramUniform3iEXT,vFuiiii)
-GO(glProgramUniform3ivEXT,vFuiip)
-GO(glProgramUniform3uiEXT,vFuiuuu)
-GO(glProgramUniform3uivEXT,vFuiip)
-GO(glProgramUniform4dEXT,vFuidddd)
-GO(glProgramUniform4dvEXT,vFuiip)
-GO(glProgramUniform4fEXT,vFuiffff)
-GO(glProgramUniform4fvEXT,vFuiip)
-GO(glProgramUniform4iEXT,vFuiiiii)
-GO(glProgramUniform4ivEXT,vFuiip)
-GO(glProgramUniform4uiEXT,vFuiuuuu)
-GO(glProgramUniform4uivEXT,vFuiip)
-GO(glProgramUniformMatrix2dvEXT,vFuiiip)
-GO(glProgramUniformMatrix2fvEXT,vFuiiip)
-GO(glProgramUniformMatrix2x3dvEXT,vFuiiip)
-GO(glProgramUniformMatrix2x3fvEXT,vFuiiip)
-GO(glProgramUniformMatrix2x4dvEXT,vFuiiip)
-GO(glProgramUniformMatrix2x4fvEXT,vFuiiip)
-GO(glProgramUniformMatrix3dvEXT,vFuiiip)
-GO(glProgramUniformMatrix3fvEXT,vFuiiip)
-GO(glProgramUniformMatrix3x2dvEXT,vFuiiip)
-GO(glProgramUniformMatrix3x2fvEXT,vFuiiip)
-GO(glProgramUniformMatrix3x4dvEXT,vFuiiip)
-GO(glProgramUniformMatrix3x4fvEXT,vFuiiip)
-GO(glProgramUniformMatrix4dvEXT,vFuiiip)
-GO(glProgramUniformMatrix4fvEXT,vFuiiip)
-GO(glProgramUniformMatrix4x2dvEXT,vFuiiip)
-GO(glProgramUniformMatrix4x2fvEXT,vFuiiip)
-GO(glProgramUniformMatrix4x3dvEXT,vFuiiip)
-GO(glProgramUniformMatrix4x3fvEXT,vFuiiip)
-GO(glPushClientAttribDefaultEXT,vFi)
-GO(glTextureBufferEXT,vFuuuu)
-GO(glTextureImage1DEXT,vFuuiuiiuup)
-GO(glTextureImage2DEXT,vFuuiuiiiuup)
-GO(glTextureImage3DEXT,vFuuiuiiiiuup)
-GO(glTextureParameterIivEXT,vFuuup)
-GO(glTextureParameterIuivEXT,vFuuup)
-GO(glTextureParameterfEXT,vFuuuf)
-GO(glTextureParameterfvEXT,vFuuup)
-GO(glTextureParameteriEXT,vFuuui)
-GO(glTextureParameterivEXT,vFuuup)
-GO(glTextureRenderbufferEXT,vFuuu)
-GO(glTextureSubImage1DEXT,vFuuiiiuup)
-GO(glTextureSubImage2DEXT,vFuuiiiiiuup)
-GO(glTextureSubImage3DEXT,vFuuiiiiiiiuup)
-GO(glUnmapNamedBufferEXT,iFu)
-GO(glVertexArrayColorOffsetEXT,vFuuiuii)
-GO(glVertexArrayEdgeFlagOffsetEXT,vFuuii)
-GO(glVertexArrayFogCoordOffsetEXT,vFuuuii)
-GO(glVertexArrayIndexOffsetEXT,vFuuuii)
-GO(glVertexArrayMultiTexCoordOffsetEXT,vFuuuiuii)
-GO(glVertexArrayNormalOffsetEXT,vFuuuii)
-GO(glVertexArraySecondaryColorOffsetEXT,vFuuiuii)
-GO(glVertexArrayTexCoordOffsetEXT,vFuuiuii)
-GO(glVertexArrayVertexAttribIOffsetEXT,vFuuuiuii)
-GO(glVertexArrayVertexAttribOffsetEXT,vFuuuiuiii)
-GO(glVertexArrayVertexOffsetEXT,vFuuiuii)
+GO(glBindMultiTextureEXT, vFuuu)
+GO(glCheckNamedFramebufferStatusEXT, uFuu)
+GO(glClientAttribDefaultEXT, vFi)
+GO(glCompressedMultiTexImage1DEXT, vFuuiuiiip)
+GO(glCompressedMultiTexImage2DEXT, vFuuiuiiiip)
+GO(glCompressedMultiTexImage3DEXT, vFuuiuiiiiip)
+GO(glCompressedMultiTexSubImage1DEXT, vFuuiiiuip)
+GO(glCompressedMultiTexSubImage2DEXT, vFuuiiiiiuip)
+GO(glCompressedMultiTexSubImage3DEXT, vFuuiiiiiiiuip)
+GO(glCompressedTextureImage1DEXT, vFuuiuiiip)
+GO(glCompressedTextureImage2DEXT, vFuuiuiiiip)
+GO(glCompressedTextureImage3DEXT, vFuuiuiiiiip)
+GO(glCompressedTextureSubImage1DEXT, vFuuiiiuip)
+GO(glCompressedTextureSubImage2DEXT, vFuuiiiiiuip)
+GO(glCompressedTextureSubImage3DEXT, vFuuiiiiiiiuip)
+GO(glCopyMultiTexImage1DEXT, vFuuiuiiii)
+GO(glCopyMultiTexImage2DEXT, vFuuiuiiiii)
+GO(glCopyMultiTexSubImage1DEXT, vFuuiiiii)
+GO(glCopyMultiTexSubImage2DEXT, vFuuiiiiiii)
+GO(glCopyMultiTexSubImage3DEXT, vFuuiiiiiiii)
+GO(glCopyTextureImage1DEXT, vFuuiuiiii)
+GO(glCopyTextureImage2DEXT, vFuuiuiiiii)
+GO(glCopyTextureSubImage1DEXT, vFuuiiiii)
+GO(glCopyTextureSubImage2DEXT, vFuuiiiiiii)
+GO(glCopyTextureSubImage3DEXT, vFuuiiiiiiii)
+GO(glDisableClientStateIndexedEXT, vFuu)
+GO(glDisableClientStateiEXT, vFuu)
+GO(glDisableVertexArrayAttribEXT, vFuu)
+GO(glDisableVertexArrayEXT, vFuu)
+GO(glEnableClientStateIndexedEXT, vFuu)
+GO(glEnableClientStateiEXT, vFuu)
+GO(glEnableVertexArrayAttribEXT, vFuu)
+GO(glEnableVertexArrayEXT, vFuu)
+GO(glFlushMappedNamedBufferRangeEXT, vFull)
+GO(glFramebufferDrawBufferEXT, vFuu)
+GO(glFramebufferDrawBuffersEXT, vFuip)
+GO(glFramebufferReadBufferEXT, vFuu)
+GO(glGenerateMultiTexMipmapEXT, vFuu)
+GO(glGenerateTextureMipmapEXT, vFuu)
+GO(glGetCompressedMultiTexImageEXT, vFuuip)
+GO(glGetCompressedTextureImageEXT, vFuuip)
+GO(glGetDoubleIndexedvEXT, vFuup)
+GO(glGetDoublei_vEXT, vFuup)
+GO(glGetFloatIndexedvEXT, vFuup)
+GO(glGetFloati_vEXT, vFuup)
+GO(glGetFramebufferParameterivEXT, vFuup)
+GO(glGetMultiTexEnvfvEXT, vFuuup)
+GO(glGetMultiTexEnvivEXT, vFuuup)
+GO(glGetMultiTexGendvEXT, vFuuup)
+GO(glGetMultiTexGenfvEXT, vFuuup)
+GO(glGetMultiTexGenivEXT, vFuuup)
+GO(glGetMultiTexImageEXT, vFuuiuup)
+GO(glGetMultiTexLevelParameterfvEXT, vFuuiup)
+GO(glGetMultiTexLevelParameterivEXT, vFuuiup)
+GO(glGetMultiTexParameterIivEXT, vFuuup)
+GO(glGetMultiTexParameterIuivEXT, vFuuup)
+GO(glGetMultiTexParameterfvEXT, vFuuup)
+GO(glGetMultiTexParameterivEXT, vFuuup)
+GO(glGetNamedBufferParameterivEXT, vFuup)
+GO(glGetNamedBufferPointervEXT, vFuup)
+GO(glGetNamedBufferSubDataEXT, vFullp)
+GO(glGetNamedFramebufferAttachmentParameterivEXT, vFuuup)
+GO(glGetNamedProgramLocalParameterIivEXT, vFuuup)
+GO(glGetNamedProgramLocalParameterIuivEXT, vFuuup)
+GO(glGetNamedProgramLocalParameterdvEXT, vFuuup)
+GO(glGetNamedProgramLocalParameterfvEXT, vFuuup)
+GO(glGetNamedProgramStringEXT, vFuuup)
+GO(glGetNamedProgramivEXT, vFuuup)
+GO(glGetNamedRenderbufferParameterivEXT, vFuup)
+GO(glGetPointerIndexedvEXT, vFuup)
+GO(glGetPointeri_vEXT, vFuup)
+GO(glGetTextureImageEXT, vFuuiuup)
+GO(glGetTextureLevelParameterfvEXT, vFuuiup)
+GO(glGetTextureLevelParameterivEXT, vFuuiup)
+GO(glGetTextureParameterIivEXT, vFuuup)
+GO(glGetTextureParameterIuivEXT, vFuuup)
+GO(glGetTextureParameterfvEXT, vFuuup)
+GO(glGetTextureParameterivEXT, vFuuup)
+GO(glGetVertexArrayIntegeri_vEXT, vFuuup)
+GO(glGetVertexArrayIntegervEXT, vFuup)
+GO(glGetVertexArrayPointeri_vEXT, vFuuup)
+GO(glGetVertexArrayPointervEXT, vFuup)
+GO(glMapNamedBufferEXT, pFuu)
+GO(glMapNamedBufferRangeEXT, pFullu)
+GO(glMatrixFrustumEXT, vFudddddd)
+GO(glMatrixLoadIdentityEXT, vFu)
+GO(glMatrixLoadTransposedEXT, vFup)
+GO(glMatrixLoadTransposefEXT, vFup)
+GO(glMatrixLoaddEXT, vFup)
+GO(glMatrixLoadfEXT, vFup)
+GO(glMatrixMultTransposedEXT, vFup)
+GO(glMatrixMultTransposefEXT, vFup)
+GO(glMatrixMultdEXT, vFup)
+GO(glMatrixMultfEXT, vFup)
+GO(glMatrixOrthoEXT, vFudddddd)
+GO(glMatrixPopEXT, vFu)
+GO(glMatrixPushEXT, vFu)
+GO(glMatrixRotatedEXT, vFudddd)
+GO(glMatrixRotatefEXT, vFuffff)
+GO(glMatrixScaledEXT, vFuddd)
+GO(glMatrixScalefEXT, vFufff)
+GO(glMatrixTranslatedEXT, vFuddd)
+GO(glMatrixTranslatefEXT, vFufff)
+GO(glMultiTexBufferEXT, vFuuuu)
+GO(glMultiTexCoordPointerEXT, vFuiuip)
+GO(glMultiTexEnvfEXT, vFuuuf)
+GO(glMultiTexEnvfvEXT, vFuuup)
+GO(glMultiTexEnviEXT, vFuuui)
+GO(glMultiTexEnvivEXT, vFuuup)
+GO(glMultiTexGendEXT, vFuuud)
+GO(glMultiTexGendvEXT, vFuuup)
+GO(glMultiTexGenfEXT, vFuuuf)
+GO(glMultiTexGenfvEXT, vFuuup)
+GO(glMultiTexGeniEXT, vFuuui)
+GO(glMultiTexGenivEXT, vFuuup)
+GO(glMultiTexImage1DEXT, vFuuiiiiuup)
+GO(glMultiTexImage2DEXT, vFuuiiiiiuup)
+GO(glMultiTexImage3DEXT, vFuuiiiiiiuup)
+GO(glMultiTexParameterIivEXT, vFuuup)
+GO(glMultiTexParameterIuivEXT, vFuuup)
+GO(glMultiTexParameterfEXT, vFuuuf)
+GO(glMultiTexParameterfvEXT, vFuuup)
+GO(glMultiTexParameteriEXT, vFuuui)
+GO(glMultiTexParameterivEXT, vFuuup)
+GO(glMultiTexRenderbufferEXT, vFuuu)
+GO(glMultiTexSubImage1DEXT, vFuuiiiuup)
+GO(glMultiTexSubImage2DEXT, vFuuiiiiiuup)
+GO(glMultiTexSubImage3DEXT, vFuuiiiiiiiuup)
+GO(glNamedBufferDataEXT, vFulpu)
+GO(glNamedBufferSubDataEXT, vFullp)
+GO(glNamedCopyBufferSubDataEXT, vFuulll)
+GO(glNamedFramebufferRenderbufferEXT, vFuuuu)
+GO(glNamedFramebufferTexture1DEXT, vFuuuui)
+GO(glNamedFramebufferTexture2DEXT, vFuuuui)
+GO(glNamedFramebufferTexture3DEXT, vFuuuuii)
+GO(glNamedFramebufferTextureEXT, vFuuui)
+GO(glNamedFramebufferTextureFaceEXT, vFuuuiu)
+GO(glNamedFramebufferTextureLayerEXT, vFuuuii)
+GO(glNamedProgramLocalParameter4dEXT, vFuuudddd)
+GO(glNamedProgramLocalParameter4dvEXT, vFuuup)
+GO(glNamedProgramLocalParameter4fEXT, vFuuuffff)
+GO(glNamedProgramLocalParameter4fvEXT, vFuuup)
+GO(glNamedProgramLocalParameterI4iEXT, vFuuuiiii)
+GO(glNamedProgramLocalParameterI4ivEXT, vFuuup)
+GO(glNamedProgramLocalParameterI4uiEXT, vFuuuuuuu)
+GO(glNamedProgramLocalParameterI4uivEXT, vFuuup)
+GO(glNamedProgramLocalParameters4fvEXT, vFuuuip)
+GO(glNamedProgramLocalParametersI4ivEXT, vFuuuip)
+GO(glNamedProgramLocalParametersI4uivEXT, vFuuuip)
+GO(glNamedProgramStringEXT, vFuuuip)
+GO(glNamedRenderbufferStorageEXT, vFuuii)
+GO(glNamedRenderbufferStorageMultisampleCoverageEXT, vFuiiuii)
+GO(glNamedRenderbufferStorageMultisampleEXT, vFuiuii)
+GO(glProgramUniform1dEXT, vFuid)
+GO(glProgramUniform1dvEXT, vFuiip)
+GO(glProgramUniform1fEXT, vFuif)
+GO(glProgramUniform1fvEXT, vFuiip)
+GO(glProgramUniform1iEXT, vFuii)
+GO(glProgramUniform1ivEXT, vFuiip)
+GO(glProgramUniform1uiEXT, vFuiu)
+GO(glProgramUniform1uivEXT, vFuiip)
+GO(glProgramUniform2dEXT, vFuidd)
+GO(glProgramUniform2dvEXT, vFuiip)
+GO(glProgramUniform2fEXT, vFuiff)
+GO(glProgramUniform2fvEXT, vFuiip)
+GO(glProgramUniform2iEXT, vFuiii)
+GO(glProgramUniform2ivEXT, vFuiip)
+GO(glProgramUniform2uiEXT, vFuiuu)
+GO(glProgramUniform2uivEXT, vFuiip)
+GO(glProgramUniform3dEXT, vFuiddd)
+GO(glProgramUniform3dvEXT, vFuiip)
+GO(glProgramUniform3fEXT, vFuifff)
+GO(glProgramUniform3fvEXT, vFuiip)
+GO(glProgramUniform3iEXT, vFuiiii)
+GO(glProgramUniform3ivEXT, vFuiip)
+GO(glProgramUniform3uiEXT, vFuiuuu)
+GO(glProgramUniform3uivEXT, vFuiip)
+GO(glProgramUniform4dEXT, vFuidddd)
+GO(glProgramUniform4dvEXT, vFuiip)
+GO(glProgramUniform4fEXT, vFuiffff)
+GO(glProgramUniform4fvEXT, vFuiip)
+GO(glProgramUniform4iEXT, vFuiiiii)
+GO(glProgramUniform4ivEXT, vFuiip)
+GO(glProgramUniform4uiEXT, vFuiuuuu)
+GO(glProgramUniform4uivEXT, vFuiip)
+GO(glProgramUniformMatrix2dvEXT, vFuiiip)
+GO(glProgramUniformMatrix2fvEXT, vFuiiip)
+GO(glProgramUniformMatrix2x3dvEXT, vFuiiip)
+GO(glProgramUniformMatrix2x3fvEXT, vFuiiip)
+GO(glProgramUniformMatrix2x4dvEXT, vFuiiip)
+GO(glProgramUniformMatrix2x4fvEXT, vFuiiip)
+GO(glProgramUniformMatrix3dvEXT, vFuiiip)
+GO(glProgramUniformMatrix3fvEXT, vFuiiip)
+GO(glProgramUniformMatrix3x2dvEXT, vFuiiip)
+GO(glProgramUniformMatrix3x2fvEXT, vFuiiip)
+GO(glProgramUniformMatrix3x4dvEXT, vFuiiip)
+GO(glProgramUniformMatrix3x4fvEXT, vFuiiip)
+GO(glProgramUniformMatrix4dvEXT, vFuiiip)
+GO(glProgramUniformMatrix4fvEXT, vFuiiip)
+GO(glProgramUniformMatrix4x2dvEXT, vFuiiip)
+GO(glProgramUniformMatrix4x2fvEXT, vFuiiip)
+GO(glProgramUniformMatrix4x3dvEXT, vFuiiCp)
+GO(glProgramUniformMatrix4x3fvEXT, vFuiiCp)
+GO(glPushClientAttribDefaultEXT, vFi)
+GO(glTextureBufferEXT, vFuuuu)
+GO(glTextureImage1DEXT, vFuuiiiiuup)
+GO(glTextureImage2DEXT, vFuuiiiiiuup)
+GO(glTextureImage3DEXT, vFuuiiiiiiuup)
+GO(glTextureParameterIivEXT, vFuuup)
+GO(glTextureParameterIuivEXT, vFuuup)
+GO(glTextureParameterfEXT, vFuuuf)
+GO(glTextureParameterfvEXT, vFuuup)
+GO(glTextureParameteriEXT, vFuuui)
+GO(glTextureParameterivEXT, vFuuup)
+GO(glTextureRenderbufferEXT, vFuuu)
+GO(glTextureSubImage1DEXT, vFuuiiiuup)
+GO(glTextureSubImage2DEXT, vFuuiiiiiuup)
+GO(glTextureSubImage3DEXT, vFuuiiiiiiiuup)
+GO(glUnmapNamedBufferEXT, iFu)
+GO(glVertexArrayColorOffsetEXT, vFuuiuii)
+GO(glVertexArrayEdgeFlagOffsetEXT, vFuuil)
+GO(glVertexArrayFogCoordOffsetEXT, vFuuuil)
+GO(glVertexArrayIndexOffsetEXT, vFuuuii)
+GO(glVertexArrayMultiTexCoordOffsetEXT, vFuuuiuil)
+GO(glVertexArrayNormalOffsetEXT, vFuuuii)
+GO(glVertexArraySecondaryColorOffsetEXT, vFuuiuil)
+GO(glVertexArrayTexCoordOffsetEXT, vFuuiuii)
+GO(glVertexArrayVertexAttribIOffsetEXT, vFuuuiuii)
+GO(glVertexArrayVertexAttribOffsetEXT, vFuuuiuCil)
+GO(glVertexArrayVertexOffsetEXT, vFuuiuii)
//EXT_draw_buffers2
-GO(glColorMaskIndexedEXT,vFuiiii)
-GO(glDisableIndexedEXT,vFuu)
-GO(glEnableIndexedEXT,vFuu)
-GO(glGetBooleanIndexedvEXT,vFuup)
-GO(glGetIntegerIndexedvEXT,vFuup)
-GO(glIsEnabledIndexedEXT,iFuu)
+GO(glColorMaskIndexedEXT, vFuCCCC)
+GO(glDisableIndexedEXT, vFuu)
+GO(glEnableIndexedEXT, vFuu)
+GO(glGetBooleanIndexedvEXT, vFuup)
+GO(glGetIntegerIndexedvEXT, vFuup)
+GO(glIsEnabledIndexedEXT, CFuu)
//EXT_draw_instanced
-GO(glDrawArraysInstancedEXT,vFuiii)
-GO(glDrawElementsInstancedEXT,vFuiupi)
+GO(glDrawArraysInstancedEXT, vFuiii)
+GO(glDrawElementsInstancedEXT, vFuiupi)
//EXT_draw_range_elements
-GO(glDrawRangeElementsEXT,vFuuuiup)
+GO(glDrawRangeElementsEXT, vFuuuiup)
//EXT_fog_coord
-GO(glFogCoordPointerEXT,vFuip)
-GO(glFogCoorddEXT,vFd)
-GO(glFogCoorddvEXT,vFp)
-GO(glFogCoordfEXT,vFf)
-GO(glFogCoordfvEXT,vFp)
+GO(glFogCoordPointerEXT, vFuip)
+GO(glFogCoorddEXT, vFd)
+GO(glFogCoorddvEXT, vFp)
+GO(glFogCoordfEXT, vFf)
+GO(glFogCoordfvEXT, vFp)
//EXT_framebuffer_blit
-GO(glBlitFramebufferEXT,vFiiiiiiiiiu)
+GO(glBlitFramebufferEXT, vFiiiiiiiiuu)
//EXT_framebuffer_object
-GO(glBindFramebufferEXT,vFuu)
-GO(glBindRenderbufferEXT,vFuu)
-GO(glCheckFramebufferStatusEXT,uFu)
-GO(glDeleteFramebuffersEXT,vFip)
-GO(glDeleteRenderbuffersEXT,vFip)
-GO(glFramebufferRenderbufferEXT,vFuuuu)
-GO(glFramebufferTexture1DEXT,vFuuuui)
-GO(glFramebufferTexture2DEXT,vFuuuui)
-GO(glFramebufferTexture3DEXT,vFuuuuii)
-GO(glGenFramebuffersEXT,vFip)
-GO(glGenRenderbuffersEXT,vFip)
-GO(glGenerateMipmapEXT,vFu)
-GO(glGetFramebufferAttachmentParameterivEXT,vFuuup)
-GO(glGetRenderbufferParameterivEXT,vFuup)
-GO(glIsFramebufferEXT,iFu)
-GO(glIsRenderbufferEXT,iFu)
-GO(glRenderbufferStorageEXT,vFuuii)
+GO(glBindFramebufferEXT, vFuu)
+GO(glBindRenderbufferEXT, vFuu)
+GO(glCheckFramebufferStatusEXT, uFu)
+GO(glDeleteFramebuffersEXT, vFip)
+GO(glDeleteRenderbuffersEXT, vFip)
+GO(glFramebufferRenderbufferEXT, vFuuuu)
+GO(glFramebufferTexture1DEXT, vFuuuui)
+GO(glFramebufferTexture2DEXT, vFuuuui)
+GO(glFramebufferTexture3DEXT, vFuuuuii)
+GO(glGenFramebuffersEXT, vFip)
+GO(glGenRenderbuffersEXT, vFip)
+GO(glGenerateMipmapEXT, vFu)
+GO(glGetFramebufferAttachmentParameterivEXT, vFuuup)
+GO(glGetRenderbufferParameterivEXT, vFuup)
+GO(glIsFramebufferEXT, iFu)
+GO(glIsRenderbufferEXT, iFu)
+GO(glRenderbufferStorageEXT, vFuuii)
//EXT_geometry_shader4
-GO(glProgramParameteriEXT,vFuui)
+GO(glProgramParameteriEXT, vFuui)
//EXT_gpu_program_parameters
-GO(glProgramEnvParameters4fvEXT,vFuuip)
-GO(glProgramLocalParameters4fvEXT,vFuuip)
+GO(glProgramEnvParameters4fvEXT, vFuuip)
+GO(glProgramLocalParameters4fvEXT, vFuuip)
//EXT_gpu_shader4
-GO(glBindFragDataLocationEXT,vFuup)
-GO(glGetFragDataLocationEXT,iFup)
-GO(glGetUniformuivEXT,vFuip)
-GO(glUniform1uiEXT,vFiu)
-GO(glUniform1uivEXT,vFiip)
-GO(glUniform2uiEXT,vFiuu)
-GO(glUniform2uivEXT,vFiip)
-GO(glUniform3uiEXT,vFiuuu)
-GO(glUniform3uivEXT,vFiip)
-GO(glUniform4uiEXT,vFiuuuu)
-GO(glUniform4uivEXT,vFiip)
+GO(glBindFragDataLocationEXT, vFuup)
+GO(glGetFragDataLocationEXT, iFup)
+GO(glGetUniformuivEXT, vFuip)
+GO(glUniform1uiEXT, vFiu)
+GO(glUniform1uivEXT, vFiip)
+GO(glUniform2uiEXT, vFiuu)
+GO(glUniform2uivEXT, vFiip)
+GO(glUniform3uiEXT, vFiuuu)
+GO(glUniform3uivEXT, vFiip)
+GO(glUniform4uiEXT, vFiuuuu)
+GO(glUniform4uivEXT, vFiip)
//EXT_histogram
-GO(glGetHistogramEXT,vFuiuup)
-GO(glGetHistogramParameterfvEXT,vFuup)
-GO(glGetHistogramParameterivEXT,vFuup)
-GO(glGetMinmaxEXT,vFuiuup)
-GO(glGetMinmaxParameterfvEXT,vFuup)
-GO(glGetMinmaxParameterivEXT,vFuup)
-GO(glHistogramEXT,vFuiui)
-GO(glMinmaxEXT,vFuui)
-GO(glResetHistogramEXT,vFu)
-GO(glResetMinmaxEXT,vFu)
+GO(glGetHistogramEXT, vFuiuup)
+GO(glGetHistogramParameterfvEXT, vFuup)
+GO(glGetHistogramParameterivEXT, vFuup)
+GO(glGetMinmaxEXT, vFuCuup)
+GO(glGetMinmaxParameterfvEXT, vFuup)
+GO(glGetMinmaxParameterivEXT, vFuup)
+GO(glHistogramEXT, vFuiuC)
+GO(glMinmaxEXT, vFuuC)
+GO(glResetHistogramEXT, vFu)
+GO(glResetMinmaxEXT, vFu)
//EXT_index_func
-GO(glIndexFuncEXT,vFuf)
+GO(glIndexFuncEXT, vFuf)
//EXT_index_material
-GO(glIndexMaterialEXT,vFuu)
+GO(glIndexMaterialEXT, vFuu)
//EXT_light_texture
-GO(glApplyTextureEXT,vFu)
-GO(glTextureLightEXT,vFu)
-GO(glTextureMaterialEXT,vFuu)
+GO(glApplyTextureEXT, vFu)
+GO(glTextureLightEXT, vFu)
+GO(glTextureMaterialEXT, vFuu)
//EXT_multi_draw_arrays
-GO(glMultiDrawArraysEXT,vFuppi)
-GO(glMultiDrawElementsEXT,vFupupi)
+GO(glMultiDrawArraysEXT, vFuppi)
+GO(glMultiDrawElementsEXT, vFupupi)
//EXT_multisample
-GO(glSampleMaskEXT,vFfi)
-GO(glSamplePatternEXT,vFu)
+GO(glSampleMaskEXT, vFfi)
+GO(glSamplePatternEXT, vFu)
//EXT_paletted_texture
-GO(glColorTableEXT,vFuuiuup)
-GO(glGetColorTableEXT,vFuuup)
-GO(glGetColorTableParameterfvEXT,vFuup)
-GO(glGetColorTableParameterivEXT,vFuup)
+GO(glColorTableEXT, vFuuiuup)
+GO(glGetColorTableEXT, vFuuup)
+GO(glGetColorTableParameterfvEXT, vFuup)
+GO(glGetColorTableParameterivEXT, vFuup)
//EXT_pixel_transform
-GO(glGetPixelTransformParameterfvEXT,vFuup)
-GO(glGetPixelTransformParameterivEXT,vFuup)
-GO(glPixelTransformParameterfEXT,vFuuf)
-GO(glPixelTransformParameterfvEXT,vFuup)
-GO(glPixelTransformParameteriEXT,vFuui)
-GO(glPixelTransformParameterivEXT,vFuup)
+GO(glGetPixelTransformParameterfvEXT, vFuup)
+GO(glGetPixelTransformParameterivEXT, vFuup)
+GO(glPixelTransformParameterfEXT, vFuuf)
+GO(glPixelTransformParameterfvEXT, vFuup)
+GO(glPixelTransformParameteriEXT, vFuui)
+GO(glPixelTransformParameterivEXT, vFuup)
//EXT_point_parameters
-GO(glPointParameterfEXT,vFuf)
-GO(glPointParameterfvEXT,vFup)
+GO(glPointParameterfEXT, vFuf)
+GO(glPointParameterfvEXT, vFup)
//EXT_polygon_offset
-GO(glPolygonOffsetEXT,vFff)
+GO(glPolygonOffsetEXT, vFff)
//EXT_provoking_vertex
-GO(glProvokingVertexEXT,vFu)
+GO(glProvokingVertexEXT, vFu)
//EXT_secondary_color
-GO(glSecondaryColor3bEXT,vFiii)
-GO(glSecondaryColor3bvEXT,vFp)
-GO(glSecondaryColor3dEXT,vFddd)
-GO(glSecondaryColor3dvEXT,vFp)
-GO(glSecondaryColor3fEXT,vFfff)
-GO(glSecondaryColor3fvEXT,vFp)
-GO(glSecondaryColor3iEXT,vFiii)
-GO(glSecondaryColor3ivEXT,vFp)
-GO(glSecondaryColor3sEXT,vFiii)
-GO(glSecondaryColor3svEXT,vFp)
-GO(glSecondaryColor3ubEXT,vFuuu)
-GO(glSecondaryColor3ubvEXT,vFp)
-GO(glSecondaryColor3uiEXT,vFuuu)
-GO(glSecondaryColor3uivEXT,vFp)
-GO(glSecondaryColor3usEXT,vFuuu)
-GO(glSecondaryColor3usvEXT,vFp)
-GO(glSecondaryColorPointerEXT,vFiuip)
+GO(glSecondaryColor3bEXT, vFccc)
+GO(glSecondaryColor3bvEXT, vFp)
+GO(glSecondaryColor3dEXT, vFddd)
+GO(glSecondaryColor3dvEXT, vFp)
+GO(glSecondaryColor3fEXT, vFfff)
+GO(glSecondaryColor3fvEXT, vFp)
+GO(glSecondaryColor3iEXT, vFiii)
+GO(glSecondaryColor3ivEXT, vFp)
+GO(glSecondaryColor3sEXT, vFiii)
+GO(glSecondaryColor3svEXT, vFp)
+GO(glSecondaryColor3ubEXT, vFCCC)
+GO(glSecondaryColor3ubvEXT, vFp)
+GO(glSecondaryColor3uiEXT, vFuuu)
+GO(glSecondaryColor3uivEXT, vFp)
+GO(glSecondaryColor3usEXT, vFWWW)
+GO(glSecondaryColor3usvEXT, vFp)
+GO(glSecondaryColorPointerEXT, vFiuip)
//EXT_separate_shader_objects
-GO(glActiveProgramEXT,vFu)
-GO(glCreateShaderProgramEXT,uFup)
-GO(glUseShaderProgramEXT,vFuu)
+GO(glActiveProgramEXT, vFu)
+GO(glCreateShaderProgramEXT, uFup)
+GO(glUseShaderProgramEXT, vFuu)
//EXT_shader_image_load_store
-GO(glBindImageTextureEXT,vFuuiiiui)
-GO(glMemoryBarrierEXT,vFi)
+GO(glBindImageTextureEXT, vFuuiCiui)
+GO(glMemoryBarrierEXT, vFi)
//EXT_stencil_clear_tag
-GO(glStencilClearTagEXT,vFiu)
+GO(glStencilClearTagEXT, vFiu)
//EXT_stencil_two_side
-GO(glActiveStencilFaceEXT,vFu)
+GO(glActiveStencilFaceEXT, vFu)
//EXT_subtexture
-GO(glTexSubImage1DEXT,vFuiiiuup)
-GO(glTexSubImage2DEXT,vFuiiiiiuup)
+GO(glTexSubImage1DEXT, vFuiiiuup)
+GO(glTexSubImage2DEXT, vFuiiiiiuup)
//EXT_texture3D
-GO(glTexImage3DEXT,vFuiuiiiiuup)
-GO(glTexSubImage3DEXT,vFuiiiiiiiuup)
+GO(glTexImage3DEXT, vFuiuiiiiuup)
+GO(glTexSubImage3DEXT, vFuiiiiiiiuup)
//EXT_texture_buffer_object
-GO(glTexBufferEXT,vFuuu)
+GO(glTexBufferEXT, vFuuu)
//EXT_texture_integer
-GO(glClearColorIiEXT,vFiiii)
-GO(glClearColorIuiEXT,vFuuuu)
-GO(glGetTexParameterIivEXT,vFuup)
-GO(glGetTexParameterIuivEXT,vFuup)
-GO(glTexParameterIivEXT,vFuup)
-GO(glTexParameterIuivEXT,vFuup)
+GO(glClearColorIiEXT, vFiiii)
+GO(glClearColorIuiEXT, vFuuuu)
+GO(glGetTexParameterIivEXT, vFuup)
+GO(glGetTexParameterIuivEXT, vFuup)
+GO(glTexParameterIivEXT, vFuup)
+GO(glTexParameterIuivEXT, vFuup)
//EXT_texture_object
-GO(glAreTexturesResidentEXT,iFipp)
-GO(glBindTextureEXT,vFuu)
-GO(glDeleteTexturesEXT,vFip)
-GO(glGenTexturesEXT,vFip)
-GO(glIsTextureEXT,iFu)
-GO(glPrioritizeTexturesEXT,vFipp)
+GO(glAreTexturesResidentEXT, iFipp)
+GO(glBindTextureEXT, vFuu)
+GO(glDeleteTexturesEXT, vFip)
+GO(glGenTexturesEXT, vFip)
+GO(glIsTextureEXT, iFu)
+GO(glPrioritizeTexturesEXT, vFipp)
//EXT_texture_perturb_normal
-GO(glTextureNormalEXT,vFu)
+GO(glTextureNormalEXT, vFu)
//EXT_timer_query
-GO(glGetQueryObjecti64vEXT,vFuup)
-GO(glGetQueryObjectui64vEXT,vFuup)
+GO(glGetQueryObjecti64vEXT, vFuup)
+GO(glGetQueryObjectui64vEXT, vFuup)
//EXT_transform_feedback
-GO(glBeginTransformFeedbackEXT,vFu)
-GO(glBindBufferBaseEXT,vFuuu)
-GO(glBindBufferOffsetEXT,vFuuui)
-GO(glBindBufferRangeEXT,vFuuuii)
-GO(glEndTransformFeedbackEXT,vFv)
-GO(glGetTransformFeedbackVaryingEXT,vFuuipppp)
-GO(glTransformFeedbackVaryingsEXT,vFuipu)
+GO(glBeginTransformFeedbackEXT, vFu)
+GO(glBindBufferBaseEXT, vFuuu)
+GO(glBindBufferOffsetEXT, vFuuui)
+GO(glBindBufferRangeEXT, vFuuuii)
+GO(glEndTransformFeedbackEXT, vFv)
+GO(glGetTransformFeedbackVaryingEXT, vFuuipppp)
+GO(glTransformFeedbackVaryingsEXT, vFuipu)
//EXT_vertex_array
-GO(glArrayElementEXT,vFi)
-GO(glColorPointerEXT,vFiuiip)
-GO(glDrawArraysEXT,vFuii)
-GO(glEdgeFlagPointerEXT,vFiip)
-GO(glGetPointervEXT,vFup)
-GO(glIndexPointerEXT,vFuiip)
-GO(glNormalPointerEXT,vFuiip)
-GO(glTexCoordPointerEXT,vFiuiip)
-GO(glVertexPointerEXT,vFiuiip)
+GO(glArrayElementEXT, vFi)
+GO(glColorPointerEXT, vFiuiip)
+GO(glDrawArraysEXT, vFuii)
+GO(glEdgeFlagPointerEXT, vFiip)
+GO(glGetPointervEXT, vFup)
+GO(glIndexPointerEXT, vFuiip)
+GO(glNormalPointerEXT, vFuiip)
+GO(glTexCoordPointerEXT, vFiuiip)
+GO(glVertexPointerEXT, vFiuiip)
//EXT_vertex_attrib_64bit
-GO(glGetVertexAttribLdvEXT,vFuup)
-GO(glVertexArrayVertexAttribLOffsetEXT,vFuuuiuii)
-GO(glVertexAttribL1dEXT,vFud)
-GO(glVertexAttribL1dvEXT,vFup)
-GO(glVertexAttribL2dEXT,vFudd)
-GO(glVertexAttribL2dvEXT,vFup)
-GO(glVertexAttribL3dEXT,vFuddd)
-GO(glVertexAttribL3dvEXT,vFup)
-GO(glVertexAttribL4dEXT,vFudddd)
-GO(glVertexAttribL4dvEXT,vFup)
-GO(glVertexAttribLPointerEXT,vFuiuip)
+GO(glGetVertexAttribLdvEXT, vFuup)
+GO(glVertexArrayVertexAttribLOffsetEXT, vFuuuiuil)
+GO(glVertexAttribL1dEXT, vFud)
+GO(glVertexAttribL1dvEXT, vFup)
+GO(glVertexAttribL2dEXT, vFudd)
+GO(glVertexAttribL2dvEXT, vFup)
+GO(glVertexAttribL3dEXT, vFuddd)
+GO(glVertexAttribL3dvEXT, vFup)
+GO(glVertexAttribL4dEXT, vFudddd)
+GO(glVertexAttribL4dvEXT, vFup)
+GO(glVertexAttribLPointerEXT, vFuiuip)
//EXT_vertex_shader
-GO(glBeginVertexShaderEXT,vFv)
-GO(glBindLightParameterEXT,uFuu)
-GO(glBindMaterialParameterEXT,uFuu)
-GO(glBindParameterEXT,uFu)
-GO(glBindTexGenParameterEXT,uFuuu)
-GO(glBindTextureUnitParameterEXT,uFuu)
-GO(glBindVertexShaderEXT,vFu)
-GO(glDeleteVertexShaderEXT,vFu)
-GO(glDisableVariantClientStateEXT,vFu)
-GO(glEnableVariantClientStateEXT,vFu)
-GO(glEndVertexShaderEXT,vFv)
-GO(glExtractComponentEXT,vFuuu)
-GO(glGenSymbolsEXT,uFuuuu)
-GO(glGenVertexShadersEXT,uFu)
-GO(glGetInvariantBooleanvEXT,vFuup)
-GO(glGetInvariantFloatvEXT,vFuup)
-GO(glGetInvariantIntegervEXT,vFuup)
-GO(glGetLocalConstantBooleanvEXT,vFuup)
-GO(glGetLocalConstantFloatvEXT,vFuup)
-GO(glGetLocalConstantIntegervEXT,vFuup)
-GO(glGetVariantBooleanvEXT,vFuup)
-GO(glGetVariantFloatvEXT,vFuup)
-GO(glGetVariantIntegervEXT,vFuup)
-GO(glGetVariantPointervEXT,vFuup)
-GO(glInsertComponentEXT,vFuuu)
-GO(glIsVariantEnabledEXT,iFuu)
-GO(glSetInvariantEXT,vFuup)
-GO(glSetLocalConstantEXT,vFuup)
-GO(glShaderOp1EXT,vFuuu)
-GO(glShaderOp2EXT,vFuuuu)
-GO(glShaderOp3EXT,vFuuuuu)
-GO(glSwizzleEXT,vFuuuuuu)
-GO(glVariantPointerEXT,vFuuup)
-GO(glVariantbvEXT,vFup)
-GO(glVariantdvEXT,vFup)
-GO(glVariantfvEXT,vFup)
-GO(glVariantivEXT,vFup)
-GO(glVariantsvEXT,vFup)
-GO(glVariantubvEXT,vFup)
-GO(glVariantuivEXT,vFup)
-GO(glVariantusvEXT,vFup)
-GO(glWriteMaskEXT,vFuuuuuu)
+GO(glBeginVertexShaderEXT, vFv)
+GO(glBindLightParameterEXT, uFuu)
+GO(glBindMaterialParameterEXT, uFuu)
+GO(glBindParameterEXT, uFu)
+GO(glBindTexGenParameterEXT, uFuuu)
+GO(glBindTextureUnitParameterEXT, uFuu)
+GO(glBindVertexShaderEXT, vFu)
+GO(glDeleteVertexShaderEXT, vFu)
+GO(glDisableVariantClientStateEXT, vFu)
+GO(glEnableVariantClientStateEXT, vFu)
+GO(glEndVertexShaderEXT, vFv)
+GO(glExtractComponentEXT, vFuuu)
+GO(glGenSymbolsEXT, uFuuuu)
+GO(glGenVertexShadersEXT, uFu)
+GO(glGetInvariantBooleanvEXT, vFuup)
+GO(glGetInvariantFloatvEXT, vFuup)
+GO(glGetInvariantIntegervEXT, vFuup)
+GO(glGetLocalConstantBooleanvEXT, vFuup)
+GO(glGetLocalConstantFloatvEXT, vFuup)
+GO(glGetLocalConstantIntegervEXT, vFuup)
+GO(glGetVariantBooleanvEXT, vFuup)
+GO(glGetVariantFloatvEXT, vFuup)
+GO(glGetVariantIntegervEXT, vFuup)
+GO(glGetVariantPointervEXT, vFuup)
+GO(glInsertComponentEXT, vFuuu)
+GO(glIsVariantEnabledEXT, CFuu)
+GO(glSetInvariantEXT, vFuup)
+GO(glSetLocalConstantEXT, vFuup)
+GO(glShaderOp1EXT, vFuuu)
+GO(glShaderOp2EXT, vFuuuu)
+GO(glShaderOp3EXT, vFuuuuu)
+GO(glSwizzleEXT, vFuuuuuu)
+GO(glVariantPointerEXT, vFuuup)
+GO(glVariantbvEXT, vFup)
+GO(glVariantdvEXT, vFup)
+GO(glVariantfvEXT, vFup)
+GO(glVariantivEXT, vFup)
+GO(glVariantsvEXT, vFup)
+GO(glVariantubvEXT, vFup)
+GO(glVariantuivEXT, vFup)
+GO(glVariantusvEXT, vFup)
+GO(glWriteMaskEXT, vFuuuuuu)
//EXT_vertex_weighting
-GO(glVertexWeightPointerEXT,vFiuip)
-GO(glVertexWeightfEXT,vFf)
-GO(glVertexWeightfvEXT,vFp)
+GO(glVertexWeightPointerEXT, vFiuip)
+GO(glVertexWeightfEXT, vFf)
+GO(glVertexWeightfvEXT, vFp)
//EXT_x11_sync_object
-GO(glImportSyncEXT,pFuii)
+GO(glImportSyncEXT, pFulu)
//GREMEDY_frame_terminator
-GO(glFrameTerminatorGREMEDY,vFv)
+GO(glFrameTerminatorGREMEDY, vFv)
//GREMEDY_string_marker
-GO(glStringMarkerGREMEDY,vFip)
+GO(glStringMarkerGREMEDY, vFip)
//HP_image_transform
-GO(glGetImageTransformParameterfvHP,vFuup)
-GO(glGetImageTransformParameterivHP,vFuup)
-GO(glImageTransformParameterfHP,vFuuf)
-GO(glImageTransformParameterfvHP,vFuup)
-GO(glImageTransformParameteriHP,vFuui)
-GO(glImageTransformParameterivHP,vFuup)
+GO(glGetImageTransformParameterfvHP, vFuup)
+GO(glGetImageTransformParameterivHP, vFuup)
+GO(glImageTransformParameterfHP, vFuuf)
+GO(glImageTransformParameterfvHP, vFuup)
+GO(glImageTransformParameteriHP, vFuui)
+GO(glImageTransformParameterivHP, vFuup)
//IBM_multimode_draw_arrays
-GO(glMultiModeDrawArraysIBM,vFpppii)
-GO(glMultiModeDrawElementsIBM,vFppupii)
+GO(glMultiModeDrawArraysIBM, vFpppii)
+GO(glMultiModeDrawElementsIBM, vFppupii)
//IBM_static_data
-GO(glFlushStaticDataIBM,vFu)
+GO(glFlushStaticDataIBM, vFu)
//IBM_vertex_array_lists
-GO(glColorPointerListIBM,vFiuipi)
-GO(glEdgeFlagPointerListIBM,vFipi)
-GO(glFogCoordPointerListIBM,vFuipi)
-GO(glIndexPointerListIBM,vFuipi)
-GO(glNormalPointerListIBM,vFuipi)
-GO(glSecondaryColorPointerListIBM,vFiuipi)
-GO(glTexCoordPointerListIBM,vFiuipi)
-GO(glVertexPointerListIBM,vFiuipi)
+GO(glColorPointerListIBM, vFiuipi)
+GO(glEdgeFlagPointerListIBM, vFipi)
+GO(glFogCoordPointerListIBM, vFuipi)
+GO(glIndexPointerListIBM, vFuipi)
+GO(glNormalPointerListIBM, vFuipi)
+GO(glSecondaryColorPointerListIBM, vFiuipi)
+GO(glTexCoordPointerListIBM, vFiuipi)
+GO(glVertexPointerListIBM, vFiuipi)
//INGR_blend_func_separate
-GO(glBlendFuncSeparateINGR,vFuuuu)
+GO(glBlendFuncSeparateINGR, vFuuuu)
//INTEL_map_texture
-GO(glMapTexture2DINTEL,pFuiipp)
-GO(glSyncTextureINTEL,vFu)
-GO(glUnmapTexture2DINTEL,vFui)
+GO(glMapTexture2DINTEL, pFuiupp)
+GO(glSyncTextureINTEL, vFu)
+GO(glUnmapTexture2DINTEL, vFui)
//INTEL_parallel_arrays
-GO(glColorPointervINTEL,vFiup)
-GO(glNormalPointervINTEL,vFup)
-GO(glTexCoordPointervINTEL,vFiup)
-GO(glVertexPointervINTEL,vFiup)
+GO(glColorPointervINTEL, vFiup)
+GO(glNormalPointervINTEL, vFup)
+GO(glTexCoordPointervINTEL, vFiup)
+GO(glVertexPointervINTEL, vFiup)
//KHR_debug
-GOM(glDebugMessageCallback,vFEpp) // not ideal, because the my_ version will always exist, even if glDebugMessageCallback doesn't
-GO(glDebugMessageControl,vFuuuipi)
-GO(glDebugMessageInsert,vFuuuuip)
-GO(glGetDebugMessageLog,uFuipppppp)
-GO(glGetObjectLabel,vFuuipp)
-GO(glGetObjectPtrLabel,vFpipp)
-GO(glObjectLabel,vFuuip)
-GO(glObjectPtrLabel,vFpip)
-GO(glPopDebugGroup,vFv)
-GO(glPushDebugGroup,vFuuip)
+GOM(glDebugMessageCallback, vFEpp) // not ideal, because the my_ version will always exist, even if glDebugMessageCallback doesn't
+GO(glDebugMessageControl, vFuuuipi)
+GO(glDebugMessageInsert, vFuuuuip)
+GO(glGetDebugMessageLog, uFuipppppp)
+GO(glGetObjectLabel, vFuuipp)
+GO(glGetObjectPtrLabel, vFpipp)
+GO(glObjectLabel, vFuuip)
+GO(glObjectPtrLabel, vFpip)
+GO(glPopDebugGroup, vFv)
+GO(glPushDebugGroup, vFuuip)
//MESA_resize_buffers
-GO(glResizeBuffersMESA,vFv)
+GO(glResizeBuffersMESA, vFv)
//MESA_window_pos
-GO(glWindowPos2dMESA,vFdd)
-GO(glWindowPos2dvMESA,vFp)
-GO(glWindowPos2fMESA,vFff)
-GO(glWindowPos2fvMESA,vFp)
-GO(glWindowPos2iMESA,vFii)
-GO(glWindowPos2ivMESA,vFp)
-GO(glWindowPos2sMESA,vFii)
-GO(glWindowPos2svMESA,vFp)
-GO(glWindowPos3dMESA,vFddd)
-GO(glWindowPos3dvMESA,vFp)
-GO(glWindowPos3fMESA,vFfff)
-GO(glWindowPos3fvMESA,vFp)
-GO(glWindowPos3iMESA,vFiii)
-GO(glWindowPos3ivMESA,vFp)
-GO(glWindowPos3sMESA,vFiii)
-GO(glWindowPos3svMESA,vFp)
-GO(glWindowPos4dMESA,vFdddd)
-GO(glWindowPos4dvMESA,vFp)
-GO(glWindowPos4fMESA,vFffff)
-GO(glWindowPos4fvMESA,vFp)
-GO(glWindowPos4iMESA,vFiiii)
-GO(glWindowPos4ivMESA,vFp)
-GO(glWindowPos4sMESA,vFiiii)
-GO(glWindowPos4svMESA,vFp)
+GO(glWindowPos2dMESA, vFdd)
+GO(glWindowPos2dvMESA, vFp)
+GO(glWindowPos2fMESA, vFff)
+GO(glWindowPos2fvMESA, vFp)
+GO(glWindowPos2iMESA, vFii)
+GO(glWindowPos2ivMESA, vFp)
+GO(glWindowPos2sMESA, vFww)
+GO(glWindowPos2svMESA, vFp)
+GO(glWindowPos3dMESA, vFddd)
+GO(glWindowPos3dvMESA, vFp)
+GO(glWindowPos3fMESA, vFfff)
+GO(glWindowPos3fvMESA, vFp)
+GO(glWindowPos3iMESA, vFiii)
+GO(glWindowPos3ivMESA, vFp)
+GO(glWindowPos3sMESA, vFwww)
+GO(glWindowPos3svMESA, vFp)
+GO(glWindowPos4dMESA, vFdddd)
+GO(glWindowPos4dvMESA, vFp)
+GO(glWindowPos4fMESA, vFffff)
+GO(glWindowPos4fvMESA, vFp)
+GO(glWindowPos4iMESA, vFiiii)
+GO(glWindowPos4ivMESA, vFp)
+GO(glWindowPos4sMESA, vFwwww)
+GO(glWindowPos4svMESA, vFp)
//NVX_conditional_render
-GO(glBeginConditionalRenderNVX,vFu)
-GO(glEndConditionalRenderNVX,vFv)
+GO(glBeginConditionalRenderNVX, vFu)
+GO(glEndConditionalRenderNVX, vFv)
//NV_bindless_texture
-GO(glGetImageHandleNV,uFuiiiu)
-GO(glGetTextureHandleNV,uFu)
-GO(glGetTextureSamplerHandleNV,uFuu)
-GO(glIsImageHandleResidentNV,iFu)
-GO(glIsTextureHandleResidentNV,iFu)
-GO(glMakeImageHandleNonResidentNV,vFu)
-GO(glMakeImageHandleResidentNV,vFuu)
-GO(glMakeTextureHandleNonResidentNV,vFu)
-GO(glMakeTextureHandleResidentNV,vFu)
-GO(glProgramUniformHandleui64NV,vFuiu)
-GO(glProgramUniformHandleui64vNV,vFuiip)
-GO(glUniformHandleui64NV,vFiu)
-GO(glUniformHandleui64vNV,vFiip)
+GO(glGetImageHandleNV, LFuiCiu)
+GO(glGetTextureHandleNV, LFu)
+GO(glGetTextureSamplerHandleNV, LFuu)
+GO(glIsImageHandleResidentNV, CFL)
+GO(glIsTextureHandleResidentNV, iFu)
+GO(glMakeImageHandleNonResidentNV, vFu)
+GO(glMakeImageHandleResidentNV, vFLu)
+GO(glMakeTextureHandleNonResidentNV, vFu)
+GO(glMakeTextureHandleResidentNV, vFu)
+GO(glProgramUniformHandleui64NV, vFuiL)
+GO(glProgramUniformHandleui64vNV, vFuiip)
+GO(glUniformHandleui64NV, vFiL)
+GO(glUniformHandleui64vNV, vFiip)
//NV_conditional_render
-GO(glBeginConditionalRenderNV,vFuu)
-GO(glEndConditionalRenderNV,vFv)
+GO(glBeginConditionalRenderNV, vFuu)
+GO(glEndConditionalRenderNV, vFv)
//NV_copy_image
-GO(glCopyImageSubDataNV,vFuuiiiiuuiiiiiii)
+GO(glCopyImageSubDataNV, vFuuiiiiuuiiiiiii)
//NV_depth_buffer_float
-GO(glClearDepthdNV,vFd)
-GO(glDepthBoundsdNV,vFdd)
-GO(glDepthRangedNV,vFdd)
+GO(glClearDepthdNV, vFd)
+GO(glDepthBoundsdNV, vFdd)
+GO(glDepthRangedNV, vFdd)
//NV_draw_texture
-GO(glDrawTextureNV,vFuufffffffff)
+GO(glDrawTextureNV, vFuufffffffff)
//NV_evaluators
-GO(glEvalMapsNV,vFuu)
-GO(glGetMapAttribParameterfvNV,vFuuup)
-GO(glGetMapAttribParameterivNV,vFuuup)
-GO(glGetMapControlPointsNV,vFuuuiiip)
-GO(glGetMapParameterfvNV,vFuup)
-GO(glGetMapParameterivNV,vFuup)
-GO(glMapControlPointsNV,vFuuuiiiiip)
-GO(glMapParameterfvNV,vFuup)
-GO(glMapParameterivNV,vFuup)
+GO(glEvalMapsNV, vFuu)
+GO(glGetMapAttribParameterfvNV, vFuuup)
+GO(glGetMapAttribParameterivNV, vFuuup)
+GO(glGetMapControlPointsNV, vFuuuiiCp)
+GO(glGetMapParameterfvNV, vFuup)
+GO(glGetMapParameterivNV, vFuup)
+GO(glMapControlPointsNV, vFuuuiiiiCp)
+GO(glMapParameterfvNV, vFuup)
+GO(glMapParameterivNV, vFuup)
//NV_explicit_multisample
-GO(glGetMultisamplefvNV,vFuup)
-GO(glSampleMaskIndexedNV,vFui)
-GO(glTexRenderbufferNV,vFuu)
+GO(glGetMultisamplefvNV, vFuup)
+GO(glSampleMaskIndexedNV, vFui)
+GO(glTexRenderbufferNV, vFuu)
//NV_fence
-GO(glDeleteFencesNV,vFip)
-GO(glFinishFenceNV,vFu)
-GO(glGenFencesNV,vFip)
-GO(glGetFenceivNV,vFuup)
-GO(glIsFenceNV,iFu)
-GO(glSetFenceNV,vFuu)
-GO(glTestFenceNV,iFu)
+GO(glDeleteFencesNV, vFip)
+GO(glFinishFenceNV, vFu)
+GO(glGenFencesNV, vFip)
+GO(glGetFenceivNV, vFuup)
+GO(glIsFenceNV, iFu)
+GO(glSetFenceNV, vFuu)
+GO(glTestFenceNV, iFu)
//NV_fragment_program
-GO(glGetProgramNamedParameterdvNV,vFuipp)
-GO(glGetProgramNamedParameterfvNV,vFuipp)
-GO(glProgramNamedParameter4dNV,vFuipdddd)
-GO(glProgramNamedParameter4dvNV,vFuipp)
-GO(glProgramNamedParameter4fNV,vFuipffff)
-GO(glProgramNamedParameter4fvNV,vFuipp)
+GO(glGetProgramNamedParameterdvNV, vFuipp)
+GO(glGetProgramNamedParameterfvNV, vFuipp)
+GO(glProgramNamedParameter4dNV, vFuipdddd)
+GO(glProgramNamedParameter4dvNV, vFuipp)
+GO(glProgramNamedParameter4fNV, vFuipffff)
+GO(glProgramNamedParameter4fvNV, vFuipp)
//NV_framebuffer_multisample_coverage
-GO(glRenderbufferStorageMultisampleCoverageNV,vFuiiuii)
+GO(glRenderbufferStorageMultisampleCoverageNV, vFuiiuii)
//NV_geometry_program4
-GO(glFramebufferTextureEXT,vFuuui)
-GO(glFramebufferTextureFaceEXT,vFuuuiu)
-GO(glFramebufferTextureLayerEXT,vFuuuii)
-GO(glProgramVertexLimitNV,vFui)
+GO(glFramebufferTextureEXT, vFuuui)
+GO(glFramebufferTextureFaceEXT, vFuuuiu)
+GO(glFramebufferTextureLayerEXT, vFuuuii)
+GO(glProgramVertexLimitNV, vFui)
//NV_gpu_program4
-GO(glGetProgramEnvParameterIivNV,vFuup)
-GO(glGetProgramEnvParameterIuivNV,vFuup)
-GO(glGetProgramLocalParameterIivNV,vFuup)
-GO(glGetProgramLocalParameterIuivNV,vFuup)
-GO(glProgramEnvParameterI4iNV,vFuuiiii)
-GO(glProgramEnvParameterI4ivNV,vFuup)
-GO(glProgramEnvParameterI4uiNV,vFuuuuuu)
-GO(glProgramEnvParameterI4uivNV,vFuup)
-GO(glProgramEnvParametersI4ivNV,vFuuip)
-GO(glProgramEnvParametersI4uivNV,vFuuip)
-GO(glProgramLocalParameterI4iNV,vFuuiiii)
-GO(glProgramLocalParameterI4ivNV,vFuup)
-GO(glProgramLocalParameterI4uiNV,vFuuuuuu)
-GO(glProgramLocalParameterI4uivNV,vFuup)
-GO(glProgramLocalParametersI4ivNV,vFuuip)
-GO(glProgramLocalParametersI4uivNV,vFuuip)
+GO(glGetProgramEnvParameterIivNV, vFuup)
+GO(glGetProgramEnvParameterIuivNV, vFuup)
+GO(glGetProgramLocalParameterIivNV, vFuup)
+GO(glGetProgramLocalParameterIuivNV, vFuup)
+GO(glProgramEnvParameterI4iNV, vFuuiiii)
+GO(glProgramEnvParameterI4ivNV, vFuup)
+GO(glProgramEnvParameterI4uiNV, vFuuuuuu)
+GO(glProgramEnvParameterI4uivNV, vFuup)
+GO(glProgramEnvParametersI4ivNV, vFuuip)
+GO(glProgramEnvParametersI4uivNV, vFuuip)
+GO(glProgramLocalParameterI4iNV, vFuuiiii)
+GO(glProgramLocalParameterI4ivNV, vFuup)
+GO(glProgramLocalParameterI4uiNV, vFuuuuuu)
+GO(glProgramLocalParameterI4uivNV, vFuup)
+GO(glProgramLocalParametersI4ivNV, vFuuip)
+GO(glProgramLocalParametersI4uivNV, vFuuip)
//NV_gpu_program5
-GO(glGetProgramSubroutineParameteruivNV,vFuup)
-GO(glProgramSubroutineParametersuivNV,vFuip)
+GO(glGetProgramSubroutineParameteruivNV, vFuup)
+GO(glProgramSubroutineParametersuivNV, vFuip)
//NV_gpu_shader5
-GO(glGetUniformi64vNV,vFuip)
-GO(glProgramUniform1i64NV,vFuii)
-GO(glProgramUniform1i64vNV,vFuiip)
-GO(glProgramUniform1ui64NV,vFuiu)
-GO(glProgramUniform1ui64vNV,vFuiip)
-GO(glProgramUniform2i64NV,vFuiii)
-GO(glProgramUniform2i64vNV,vFuiip)
-GO(glProgramUniform2ui64NV,vFuiuu)
-GO(glProgramUniform2ui64vNV,vFuiip)
-GO(glProgramUniform3i64NV,vFuiiii)
-GO(glProgramUniform3i64vNV,vFuiip)
-GO(glProgramUniform3ui64NV,vFuiuuu)
-GO(glProgramUniform3ui64vNV,vFuiip)
-GO(glProgramUniform4i64NV,vFuiiiii)
-GO(glProgramUniform4i64vNV,vFuiip)
-GO(glProgramUniform4ui64NV,vFuiuuuu)
-GO(glProgramUniform4ui64vNV,vFuiip)
-GO(glUniform1i64NV,vFii)
-GO(glUniform1i64vNV,vFiip)
-GO(glUniform1ui64NV,vFiu)
-GO(glUniform1ui64vNV,vFiip)
-GO(glUniform2i64NV,vFiii)
-GO(glUniform2i64vNV,vFiip)
-GO(glUniform2ui64NV,vFiuu)
-GO(glUniform2ui64vNV,vFiip)
-GO(glUniform3i64NV,vFiiii)
-GO(glUniform3i64vNV,vFiip)
-GO(glUniform3ui64NV,vFiuuu)
-GO(glUniform3ui64vNV,vFiip)
-GO(glUniform4i64NV,vFiiiii)
-GO(glUniform4i64vNV,vFiip)
-GO(glUniform4ui64NV,vFiuuuu)
-GO(glUniform4ui64vNV,vFiip)
+GO(glGetUniformi64vNV, vFuip)
+GO(glProgramUniform1i64NV, vFuil)
+GO(glProgramUniform1i64vNV, vFuiip)
+GO(glProgramUniform1ui64NV, vFuiu)
+GO(glProgramUniform1ui64vNV, vFuiip)
+GO(glProgramUniform2i64NV, vFuill)
+GO(glProgramUniform2i64vNV, vFuiip)
+GO(glProgramUniform2ui64NV, vFuiLL)
+GO(glProgramUniform2ui64vNV, vFuiip)
+GO(glProgramUniform3i64NV, vFuilll)
+GO(glProgramUniform3i64vNV, vFuiip)
+GO(glProgramUniform3ui64NV, vFuiLLL)
+GO(glProgramUniform3ui64vNV, vFuiip)
+GO(glProgramUniform4i64NV, vFuillll)
+GO(glProgramUniform4i64vNV, vFuiip)
+GO(glProgramUniform4ui64NV, vFuiLLLL)
+GO(glProgramUniform4ui64vNV, vFuiip)
+GO(glUniform1i64NV, vFil)
+GO(glUniform1i64vNV, vFiip)
+GO(glUniform1ui64NV, vFiu)
+GO(glUniform1ui64vNV, vFiip)
+GO(glUniform2i64NV, vFill)
+GO(glUniform2i64vNV, vFiip)
+GO(glUniform2ui64NV, vFiLL)
+GO(glUniform2ui64vNV, vFiip)
+GO(glUniform3i64NV, vFilll)
+GO(glUniform3i64vNV, vFiip)
+GO(glUniform3ui64NV, vFiLLL)
+GO(glUniform3ui64vNV, vFiip)
+GO(glUniform4i64NV, vFillll)
+GO(glUniform4i64vNV, vFiip)
+GO(glUniform4ui64NV, vFiLLLL)
+GO(glUniform4ui64vNV, vFiip)
//NV_half_float
-GO(glColor3hNV,vFiii)
-GO(glColor3hvNV,vFp)
-GO(glColor4hNV,vFiiii)
-GO(glColor4hvNV,vFp)
-GO(glFogCoordhNV,vFi)
-GO(glFogCoordhvNV,vFp)
-GO(glMultiTexCoord1hNV,vFui)
-GO(glMultiTexCoord1hvNV,vFup)
-GO(glMultiTexCoord2hNV,vFuii)
-GO(glMultiTexCoord2hvNV,vFup)
-GO(glMultiTexCoord3hNV,vFuiii)
-GO(glMultiTexCoord3hvNV,vFup)
-GO(glMultiTexCoord4hNV,vFuiiii)
-GO(glMultiTexCoord4hvNV,vFup)
-GO(glNormal3hNV,vFiii)
-GO(glNormal3hvNV,vFp)
-GO(glSecondaryColor3hNV,vFiii)
-GO(glSecondaryColor3hvNV,vFp)
-GO(glTexCoord1hNV,vFi)
-GO(glTexCoord1hvNV,vFp)
-GO(glTexCoord2hNV,vFii)
-GO(glTexCoord2hvNV,vFp)
-GO(glTexCoord3hNV,vFiii)
-GO(glTexCoord3hvNV,vFp)
-GO(glTexCoord4hNV,vFiiii)
-GO(glTexCoord4hvNV,vFp)
-GO(glVertex2hNV,vFii)
-GO(glVertex2hvNV,vFp)
-GO(glVertex3hNV,vFiii)
-GO(glVertex3hvNV,vFp)
-GO(glVertex4hNV,vFiiii)
-GO(glVertex4hvNV,vFp)
-GO(glVertexAttrib1hNV,vFui)
-GO(glVertexAttrib1hvNV,vFup)
-GO(glVertexAttrib2hNV,vFuii)
-GO(glVertexAttrib2hvNV,vFup)
-GO(glVertexAttrib3hNV,vFuiii)
-GO(glVertexAttrib3hvNV,vFup)
-GO(glVertexAttrib4hNV,vFuiiii)
-GO(glVertexAttrib4hvNV,vFup)
-GO(glVertexAttribs1hvNV,vFuip)
-GO(glVertexAttribs2hvNV,vFuip)
-GO(glVertexAttribs3hvNV,vFuip)
-GO(glVertexAttribs4hvNV,vFuip)
-GO(glVertexWeighthNV,vFi)
-GO(glVertexWeighthvNV,vFp)
+GO(glColor3hNV, vFiii)
+GO(glColor3hvNV, vFp)
+GO(glColor4hNV, vFiiii)
+GO(glColor4hvNV, vFp)
+GO(glFogCoordhNV, vFi)
+GO(glFogCoordhvNV, vFp)
+GO(glMultiTexCoord1hNV, vFuW)
+GO(glMultiTexCoord1hvNV, vFup)
+GO(glMultiTexCoord2hNV, vFuWW)
+GO(glMultiTexCoord2hvNV, vFup)
+GO(glMultiTexCoord3hNV, vFuWWW)
+GO(glMultiTexCoord3hvNV, vFup)
+GO(glMultiTexCoord4hNV, vFuWWWW)
+GO(glMultiTexCoord4hvNV, vFup)
+GO(glNormal3hNV, vFiii)
+GO(glNormal3hvNV, vFp)
+GO(glSecondaryColor3hNV, vFWWW)
+GO(glSecondaryColor3hvNV, vFp)
+GO(glTexCoord1hNV, vFi)
+GO(glTexCoord1hvNV, vFp)
+GO(glTexCoord2hNV, vFWW)
+GO(glTexCoord2hvNV, vFp)
+GO(glTexCoord3hNV, vFiii)
+GO(glTexCoord3hvNV, vFp)
+GO(glTexCoord4hNV, vFWWWW)
+GO(glTexCoord4hvNV, vFp)
+GO(glVertex2hNV, vFii)
+GO(glVertex2hvNV, vFp)
+GO(glVertex3hNV, vFiii)
+GO(glVertex3hvNV, vFp)
+GO(glVertex4hNV, vFiiii)
+GO(glVertex4hvNV, vFp)
+GO(glVertexAttrib1hNV, vFuW)
+GO(glVertexAttrib1hvNV, vFup)
+GO(glVertexAttrib2hNV, vFuWW)
+GO(glVertexAttrib2hvNV, vFup)
+GO(glVertexAttrib3hNV, vFuWWW)
+GO(glVertexAttrib3hvNV, vFup)
+GO(glVertexAttrib4hNV, vFuWWWW)
+GO(glVertexAttrib4hvNV, vFup)
+GO(glVertexAttribs1hvNV, vFuip)
+GO(glVertexAttribs2hvNV, vFuip)
+GO(glVertexAttribs3hvNV, vFuip)
+GO(glVertexAttribs4hvNV, vFuip)
+GO(glVertexWeighthNV, vFW)
+GO(glVertexWeighthvNV, vFp)
//NV_occlusion_query
-GO(glBeginOcclusionQueryNV,vFu)
-GO(glDeleteOcclusionQueriesNV,vFip)
-GO(glEndOcclusionQueryNV,vFv)
-GO(glGenOcclusionQueriesNV,vFip)
-GO(glGetOcclusionQueryivNV,vFuup)
-GO(glGetOcclusionQueryuivNV,vFuup)
-GO(glIsOcclusionQueryNV,iFu)
+GO(glBeginOcclusionQueryNV, vFu)
+GO(glDeleteOcclusionQueriesNV, vFip)
+GO(glEndOcclusionQueryNV, vFv)
+GO(glGenOcclusionQueriesNV, vFip)
+GO(glGetOcclusionQueryivNV, vFuup)
+GO(glGetOcclusionQueryuivNV, vFuup)
+GO(glIsOcclusionQueryNV, iFu)
//NV_parameter_buffer_object
-GO(glProgramBufferParametersIivNV,vFuuuip)
-GO(glProgramBufferParametersIuivNV,vFuuuip)
-GO(glProgramBufferParametersfvNV,vFuuuip)
+GO(glProgramBufferParametersIivNV, vFuuuip)
+GO(glProgramBufferParametersIuivNV, vFuuuip)
+GO(glProgramBufferParametersfvNV, vFuuuip)
//NV_pixel_data_range
-GO(glFlushPixelDataRangeNV,vFu)
-GO(glPixelDataRangeNV,vFuip)
+GO(glFlushPixelDataRangeNV, vFu)
+GO(glPixelDataRangeNV, vFuip)
//NV_point_sprite
-GO(glPointParameteriNV,vFui)
-GO(glPointParameterivNV,vFup)
+GO(glPointParameteriNV, vFui)
+GO(glPointParameterivNV, vFup)
//NV_present_video
-GO(glGetVideoi64vNV,vFuup)
-GO(glGetVideoivNV,vFuup)
-GO(glGetVideoui64vNV,vFuup)
-GO(glGetVideouivNV,vFuup)
-GO(glPresentFrameDualFillNV,vFuuuuuuuuuuuuu)
-GO(glPresentFrameKeyedNV,vFuuuuuuuuuuu)
+GO(glGetVideoi64vNV, vFuup)
+GO(glGetVideoivNV, vFuup)
+GO(glGetVideoui64vNV, vFuup)
+GO(glGetVideouivNV, vFuup)
+GO(glPresentFrameDualFillNV, vFuLuuuuuuuuuuu)
+GO(glPresentFrameKeyedNV, vFuLuuuuuuuuu)
//NV_primitive_restart
-GO(glPrimitiveRestartIndexNV,vFu)
-GO(glPrimitiveRestartNV,vFv)
+GO(glPrimitiveRestartIndexNV, vFu)
+GO(glPrimitiveRestartNV, vFv)
//NV_register_combiners
-GO(glCombinerInputNV,vFuuuuuu)
-GO(glCombinerOutputNV,vFuuuuuuuiii)
-GO(glCombinerParameterfNV,vFuf)
-GO(glCombinerParameterfvNV,vFup)
-GO(glCombinerParameteriNV,vFui)
-GO(glCombinerParameterivNV,vFup)
-GO(glFinalCombinerInputNV,vFuuuu)
-GO(glGetCombinerInputParameterfvNV,vFuuuup)
-GO(glGetCombinerInputParameterivNV,vFuuuup)
-GO(glGetCombinerOutputParameterfvNV,vFuuup)
-GO(glGetCombinerOutputParameterivNV,vFuuup)
-GO(glGetFinalCombinerInputParameterfvNV,vFuup)
-GO(glGetFinalCombinerInputParameterivNV,vFuup)
+GO(glCombinerInputNV, vFuuuuuu)
+GO(glCombinerOutputNV, vFuuuuuuuCCC)
+GO(glCombinerParameterfNV, vFuf)
+GO(glCombinerParameterfvNV, vFup)
+GO(glCombinerParameteriNV, vFui)
+GO(glCombinerParameterivNV, vFup)
+GO(glFinalCombinerInputNV, vFuuuu)
+GO(glGetCombinerInputParameterfvNV, vFuuuup)
+GO(glGetCombinerInputParameterivNV, vFuuuup)
+GO(glGetCombinerOutputParameterfvNV, vFuuup)
+GO(glGetCombinerOutputParameterivNV, vFuuup)
+GO(glGetFinalCombinerInputParameterfvNV, vFuup)
+GO(glGetFinalCombinerInputParameterivNV, vFuup)
//NV_register_combiners2
-GO(glCombinerStageParameterfvNV,vFuup)
-GO(glGetCombinerStageParameterfvNV,vFuup)
+GO(glCombinerStageParameterfvNV, vFuup)
+GO(glGetCombinerStageParameterfvNV, vFuup)
//NV_shader_buffer_load
-GO(glGetBufferParameterui64vNV,vFuup)
-GO(glGetIntegerui64vNV,vFup)
-GO(glGetNamedBufferParameterui64vNV,vFuup)
-GO(glGetUniformui64vNV,vFuip)
-GO(glIsBufferResidentNV,iFu)
-GO(glIsNamedBufferResidentNV,iFu)
-GO(glMakeBufferNonResidentNV,vFu)
-GO(glMakeBufferResidentNV,vFuu)
-GO(glMakeNamedBufferNonResidentNV,vFu)
-GO(glMakeNamedBufferResidentNV,vFuu)
-GO(glProgramUniformui64NV,vFuiu)
-GO(glProgramUniformui64vNV,vFuiip)
-GO(glUniformui64NV,vFiu)
-GO(glUniformui64vNV,vFiip)
+GO(glGetBufferParameterui64vNV, vFuup)
+GO(glGetIntegerui64vNV, vFup)
+GO(glGetNamedBufferParameterui64vNV, vFuup)
+GO(glGetUniformui64vNV, vFuip)
+GO(glIsBufferResidentNV, CFu)
+GO(glIsNamedBufferResidentNV, iFu)
+GO(glMakeBufferNonResidentNV, vFu)
+GO(glMakeBufferResidentNV, vFuu)
+GO(glMakeNamedBufferNonResidentNV, vFu)
+GO(glMakeNamedBufferResidentNV, vFuu)
+GO(glProgramUniformui64NV, vFuiL)
+GO(glProgramUniformui64vNV, vFuiip)
+GO(glUniformui64NV, vFiL)
+GO(glUniformui64vNV, vFiip)
//NV_texture_barrier
-GO(glTextureBarrierNV,vFv)
+GO(glTextureBarrierNV, vFv)
//NV_texture_multisample
-GO(glTexImage2DMultisampleCoverageNV,vFuiiiiii)
-GO(glTexImage3DMultisampleCoverageNV,vFuiiiiiii)
-GO(glTextureImage2DMultisampleCoverageNV,vFuuiiiiii)
-GO(glTextureImage2DMultisampleNV,vFuuiiiii)
-GO(glTextureImage3DMultisampleCoverageNV,vFuuiiiiiii)
-GO(glTextureImage3DMultisampleNV,vFuuiiiiii)
+GO(glTexImage2DMultisampleCoverageNV, vFuiiiiiC)
+GO(glTexImage3DMultisampleCoverageNV, vFuiiiiiiC)
+GO(glTextureImage2DMultisampleCoverageNV, vFuuiiiiiC)
+GO(glTextureImage2DMultisampleNV, vFuuiiiiC)
+GO(glTextureImage3DMultisampleCoverageNV, vFuuiiiiiiC)
+GO(glTextureImage3DMultisampleNV, vFuuiiiiiC)
//NV_transform_feedback
-GO(glActiveVaryingNV,vFup)
-GO(glBeginTransformFeedbackNV,vFu)
-GO(glBindBufferBaseNV,vFuuu)
-GO(glBindBufferOffsetNV,vFuuui)
-GO(glBindBufferRangeNV,vFuuuii)
-GO(glEndTransformFeedbackNV,vFv)
-GO(glGetActiveVaryingNV,vFuuipppp)
-GO(glGetTransformFeedbackVaryingNV,vFuup)
-GO(glGetVaryingLocationNV,iFup)
-GO(glTransformFeedbackAttribsNV,vFipu)
-GO(glTransformFeedbackStreamAttribsNV,vFipipu)
-GO(glTransformFeedbackVaryingsNV,vFuipu)
+GO(glActiveVaryingNV, vFup)
+GO(glBeginTransformFeedbackNV, vFu)
+GO(glBindBufferBaseNV, vFuuu)
+GO(glBindBufferOffsetNV, vFuuul)
+GO(glBindBufferRangeNV, vFuuull)
+GO(glEndTransformFeedbackNV, vFv)
+GO(glGetActiveVaryingNV, vFuuipppp)
+GO(glGetTransformFeedbackVaryingNV, vFuup)
+GO(glGetVaryingLocationNV, iFup)
+GO(glTransformFeedbackAttribsNV, vFipu)
+GO(glTransformFeedbackStreamAttribsNV, vFipipu)
+GO(glTransformFeedbackVaryingsNV, vFuipu)
//NV_transform_feedback2
-GO(glBindTransformFeedbackNV,vFuu)
-GO(glDeleteTransformFeedbacksNV,vFip)
-GO(glDrawTransformFeedbackNV,vFuu)
-GO(glGenTransformFeedbacksNV,vFip)
-GO(glIsTransformFeedbackNV,iFu)
-GO(glPauseTransformFeedbackNV,vFv)
-GO(glResumeTransformFeedbackNV,vFv)
+GO(glBindTransformFeedbackNV, vFuu)
+GO(glDeleteTransformFeedbacksNV, vFip)
+GO(glDrawTransformFeedbackNV, vFuu)
+GO(glGenTransformFeedbacksNV, vFip)
+GO(glIsTransformFeedbackNV, iFu)
+GO(glPauseTransformFeedbackNV, vFv)
+GO(glResumeTransformFeedbackNV, vFv)
//NV_vdpau_interop
-GO(glVDPAUFiniNV,vFv)
-GO(glVDPAUGetSurfaceivNV,vFuuipp)
-GO(glVDPAUInitNV,vFpp)
-GO(glVDPAUIsSurfaceNV,vFu)
-GO(glVDPAUMapSurfacesNV,vFip)
-GO(glVDPAURegisterOutputSurfaceNV,uFpuip)
-GO(glVDPAURegisterVideoSurfaceNV,uFpuip)
-GO(glVDPAUSurfaceAccessNV,vFuu)
-GO(glVDPAUUnmapSurfacesNV,vFip)
-GO(glVDPAUUnregisterSurfaceNV,vFu)
+GO(glVDPAUFiniNV, vFv)
+GO(glVDPAUGetSurfaceivNV, vFluipp)
+GO(glVDPAUInitNV, vFpp)
+GO(glVDPAUIsSurfaceNV, CFl)
+GO(glVDPAUMapSurfacesNV, vFip)
+GO(glVDPAURegisterOutputSurfaceNV, lFpuip)
+GO(glVDPAURegisterVideoSurfaceNV, uFpuip)
+GO(glVDPAUSurfaceAccessNV, vFlu)
+GO(glVDPAUUnmapSurfacesNV, vFip)
+GO(glVDPAUUnregisterSurfaceNV, vFl)
//NV_vertex_array_range
-GO(glFlushVertexArrayRangeNV,vFv)
-GO(glVertexArrayRangeNV,vFip)
+GO(glFlushVertexArrayRangeNV, vFv)
+GO(glVertexArrayRangeNV, vFip)
//NV_vertex_attrib_integer_64bit
-GO(glGetVertexAttribLi64vNV,vFuup)
-GO(glGetVertexAttribLui64vNV,vFuup)
-GO(glVertexAttribL1i64NV,vFui)
-GO(glVertexAttribL1i64vNV,vFup)
-GO(glVertexAttribL1ui64NV,vFuu)
-GO(glVertexAttribL1ui64vNV,vFup)
-GO(glVertexAttribL2i64NV,vFuii)
-GO(glVertexAttribL2i64vNV,vFup)
-GO(glVertexAttribL2ui64NV,vFuuu)
-GO(glVertexAttribL2ui64vNV,vFup)
-GO(glVertexAttribL3i64NV,vFuiii)
-GO(glVertexAttribL3i64vNV,vFup)
-GO(glVertexAttribL3ui64NV,vFuuuu)
-GO(glVertexAttribL3ui64vNV,vFup)
-GO(glVertexAttribL4i64NV,vFuiiii)
-GO(glVertexAttribL4i64vNV,vFup)
-GO(glVertexAttribL4ui64NV,vFuuuuu)
-GO(glVertexAttribL4ui64vNV,vFup)
-GO(glVertexAttribLFormatNV,vFuiui)
+GO(glGetVertexAttribLi64vNV, vFuup)
+GO(glGetVertexAttribLui64vNV, vFuup)
+GO(glVertexAttribL1i64NV, vFul)
+GO(glVertexAttribL1i64vNV, vFup)
+GO(glVertexAttribL1ui64NV, vFuL)
+GO(glVertexAttribL1ui64vNV, vFup)
+GO(glVertexAttribL2i64NV, vFull)
+GO(glVertexAttribL2i64vNV, vFup)
+GO(glVertexAttribL2ui64NV, vFuLL)
+GO(glVertexAttribL2ui64vNV, vFup)
+GO(glVertexAttribL3i64NV, vFulll)
+GO(glVertexAttribL3i64vNV, vFup)
+GO(glVertexAttribL3ui64NV, vFuLLL)
+GO(glVertexAttribL3ui64vNV, vFup)
+GO(glVertexAttribL4i64NV, vFullll)
+GO(glVertexAttribL4i64vNV, vFup)
+GO(glVertexAttribL4ui64NV, vFuLLLL)
+GO(glVertexAttribL4ui64vNV, vFup)
+GO(glVertexAttribLFormatNV, vFuiui)
//NV_vertex_buffer_unified_memory
-GO(glBufferAddressRangeNV,vFuuui)
-GO(glColorFormatNV,vFiui)
-GO(glEdgeFlagFormatNV,vFi)
-GO(glFogCoordFormatNV,vFui)
-GO(glGetIntegerui64i_vNV,vFuup)
-GO(glIndexFormatNV,vFui)
-GO(glNormalFormatNV,vFui)
-GO(glSecondaryColorFormatNV,vFiui)
-GO(glTexCoordFormatNV,vFiui)
-GO(glVertexAttribFormatNV,vFuiuii)
-GO(glVertexAttribIFormatNV,vFuiui)
-GO(glVertexFormatNV,vFiui)
+GO(glBufferAddressRangeNV, vFuuLl)
+GO(glColorFormatNV, vFiui)
+GO(glEdgeFlagFormatNV, vFi)
+GO(glFogCoordFormatNV, vFui)
+GO(glGetIntegerui64i_vNV, vFuup)
+GO(glIndexFormatNV, vFui)
+GO(glNormalFormatNV, vFui)
+GO(glSecondaryColorFormatNV, vFiui)
+GO(glTexCoordFormatNV, vFiui)
+GO(glVertexAttribFormatNV, vFuiuCi)
+GO(glVertexAttribIFormatNV, vFuiui)
+GO(glVertexFormatNV, vFiui)
//NV_vertex_program
-GO(glAreProgramsResidentNV,iFipp)
-GO(glBindProgramNV,vFuu)
-GO(glDeleteProgramsNV,vFip)
-GO(glExecuteProgramNV,vFuup)
-GO(glGenProgramsNV,vFip)
-GO(glGetProgramParameterdvNV,vFuuup)
-GO(glGetProgramParameterfvNV,vFuuup)
-GO(glGetProgramStringNV,vFuup)
-GO(glGetProgramivNV,vFuup)
-GO(glGetTrackMatrixivNV,vFuuup)
-GO(glGetVertexAttribPointervNV,vFuup)
-GO(glGetVertexAttribdvNV,vFuup)
-GO(glGetVertexAttribfvNV,vFuup)
-GO(glGetVertexAttribivNV,vFuup)
-GO(glIsProgramNV,iFu)
-GO(glLoadProgramNV,vFuuip)
-GO(glProgramParameter4dNV,vFuudddd)
-GO(glProgramParameter4dvNV,vFuup)
-GO(glProgramParameter4fNV,vFuuffff)
-GO(glProgramParameter4fvNV,vFuup)
-GO(glProgramParameters4dvNV,vFuuip)
-GO(glProgramParameters4fvNV,vFuuip)
-GO(glRequestResidentProgramsNV,vFip)
-GO(glTrackMatrixNV,vFuuuu)
-GO(glVertexAttrib1dNV,vFud)
-GO(glVertexAttrib1dvNV,vFup)
-GO(glVertexAttrib1fNV,vFuf)
-GO(glVertexAttrib1fvNV,vFup)
-GO(glVertexAttrib1sNV,vFui)
-GO(glVertexAttrib1svNV,vFup)
-GO(glVertexAttrib2dNV,vFudd)
-GO(glVertexAttrib2dvNV,vFup)
-GO(glVertexAttrib2fNV,vFuff)
-GO(glVertexAttrib2fvNV,vFup)
-GO(glVertexAttrib2sNV,vFuii)
-GO(glVertexAttrib2svNV,vFup)
-GO(glVertexAttrib3dNV,vFuddd)
-GO(glVertexAttrib3dvNV,vFup)
-GO(glVertexAttrib3fNV,vFufff)
-GO(glVertexAttrib3fvNV,vFup)
-GO(glVertexAttrib3sNV,vFuiii)
-GO(glVertexAttrib3svNV,vFup)
-GO(glVertexAttrib4dNV,vFudddd)
-GO(glVertexAttrib4dvNV,vFup)
-GO(glVertexAttrib4fNV,vFuffff)
-GO(glVertexAttrib4fvNV,vFup)
-GO(glVertexAttrib4sNV,vFuiiii)
-GO(glVertexAttrib4svNV,vFup)
-GO(glVertexAttrib4ubNV,vFuuuuu)
-GO(glVertexAttrib4ubvNV,vFup)
-GO(glVertexAttribPointerNV,vFuiuip)
-GO(glVertexAttribs1dvNV,vFuip)
-GO(glVertexAttribs1fvNV,vFuip)
-GO(glVertexAttribs1svNV,vFuip)
-GO(glVertexAttribs2dvNV,vFuip)
-GO(glVertexAttribs2fvNV,vFuip)
-GO(glVertexAttribs2svNV,vFuip)
-GO(glVertexAttribs3dvNV,vFuip)
-GO(glVertexAttribs3fvNV,vFuip)
-GO(glVertexAttribs3svNV,vFuip)
-GO(glVertexAttribs4dvNV,vFuip)
-GO(glVertexAttribs4fvNV,vFuip)
-GO(glVertexAttribs4svNV,vFuip)
-GO(glVertexAttribs4ubvNV,vFuip)
+GO(glAreProgramsResidentNV, CFipp)
+GO(glBindProgramNV, vFuu)
+GO(glDeleteProgramsNV, vFip)
+GO(glExecuteProgramNV, vFuup)
+GO(glGenProgramsNV, vFip)
+GO(glGetProgramParameterdvNV, vFuuup)
+GO(glGetProgramParameterfvNV, vFuuup)
+GO(glGetProgramStringNV, vFuup)
+GO(glGetProgramivNV, vFuup)
+GO(glGetTrackMatrixivNV, vFuuup)
+GO(glGetVertexAttribPointervNV, vFuup)
+GO(glGetVertexAttribdvNV, vFuup)
+GO(glGetVertexAttribfvNV, vFuup)
+GO(glGetVertexAttribivNV, vFuup)
+GO(glIsProgramNV, iFu)
+GO(glLoadProgramNV, vFuuip)
+GO(glProgramParameter4dNV, vFuudddd)
+GO(glProgramParameter4dvNV, vFuup)
+GO(glProgramParameter4fNV, vFuuffff)
+GO(glProgramParameter4fvNV, vFuup)
+GO(glProgramParameters4dvNV, vFuuip)
+GO(glProgramParameters4fvNV, vFuuip)
+GO(glRequestResidentProgramsNV, vFip)
+GO(glTrackMatrixNV, vFuuuu)
+GO(glVertexAttrib1dNV, vFud)
+GO(glVertexAttrib1dvNV, vFup)
+GO(glVertexAttrib1fNV, vFuf)
+GO(glVertexAttrib1fvNV, vFup)
+GO(glVertexAttrib1sNV, vFuw)
+GO(glVertexAttrib1svNV, vFup)
+GO(glVertexAttrib2dNV, vFudd)
+GO(glVertexAttrib2dvNV, vFup)
+GO(glVertexAttrib2fNV, vFuff)
+GO(glVertexAttrib2fvNV, vFup)
+GO(glVertexAttrib2sNV, vFuww)
+GO(glVertexAttrib2svNV, vFup)
+GO(glVertexAttrib3dNV, vFuddd)
+GO(glVertexAttrib3dvNV, vFup)
+GO(glVertexAttrib3fNV, vFufff)
+GO(glVertexAttrib3fvNV, vFup)
+GO(glVertexAttrib3sNV, vFuwww)
+GO(glVertexAttrib3svNV, vFup)
+GO(glVertexAttrib4dNV, vFudddd)
+GO(glVertexAttrib4dvNV, vFup)
+GO(glVertexAttrib4fNV, vFuffff)
+GO(glVertexAttrib4fvNV, vFup)
+GO(glVertexAttrib4sNV, vFuwwww)
+GO(glVertexAttrib4svNV, vFup)
+GO(glVertexAttrib4ubNV, vFuCCCC)
+GO(glVertexAttrib4ubvNV, vFup)
+GO(glVertexAttribPointerNV, vFuiuip)
+GO(glVertexAttribs1dvNV, vFuip)
+GO(glVertexAttribs1fvNV, vFuip)
+GO(glVertexAttribs1svNV, vFuip)
+GO(glVertexAttribs2dvNV, vFuip)
+GO(glVertexAttribs2fvNV, vFuip)
+GO(glVertexAttribs2svNV, vFuip)
+GO(glVertexAttribs3dvNV, vFuip)
+GO(glVertexAttribs3fvNV, vFuip)
+GO(glVertexAttribs3svNV, vFuip)
+GO(glVertexAttribs4dvNV, vFuip)
+GO(glVertexAttribs4fvNV, vFuip)
+GO(glVertexAttribs4svNV, vFuip)
+GO(glVertexAttribs4ubvNV, vFuip)
//NV_vertex_program4
-GO(glGetVertexAttribIivEXT,vFuup)
-GO(glGetVertexAttribIuivEXT,vFuup)
-GO(glVertexAttribI1iEXT,vFui)
-GO(glVertexAttribI1ivEXT,vFup)
-GO(glVertexAttribI1uiEXT,vFuu)
-GO(glVertexAttribI1uivEXT,vFup)
-GO(glVertexAttribI2iEXT,vFuii)
-GO(glVertexAttribI2ivEXT,vFup)
-GO(glVertexAttribI2uiEXT,vFuuu)
-GO(glVertexAttribI2uivEXT,vFup)
-GO(glVertexAttribI3iEXT,vFuiii)
-GO(glVertexAttribI3ivEXT,vFup)
-GO(glVertexAttribI3uiEXT,vFuuuu)
-GO(glVertexAttribI3uivEXT,vFup)
-GO(glVertexAttribI4bvEXT,vFup)
-GO(glVertexAttribI4iEXT,vFuiiii)
-GO(glVertexAttribI4ivEXT,vFup)
-GO(glVertexAttribI4svEXT,vFup)
-GO(glVertexAttribI4ubvEXT,vFup)
-GO(glVertexAttribI4uiEXT,vFuuuuu)
-GO(glVertexAttribI4uivEXT,vFup)
-GO(glVertexAttribI4usvEXT,vFup)
-GO(glVertexAttribIPointerEXT,vFuiuip)
+GO(glGetVertexAttribIivEXT, vFuup)
+GO(glGetVertexAttribIuivEXT, vFuup)
+GO(glVertexAttribI1iEXT, vFui)
+GO(glVertexAttribI1ivEXT, vFup)
+GO(glVertexAttribI1uiEXT, vFuu)
+GO(glVertexAttribI1uivEXT, vFup)
+GO(glVertexAttribI2iEXT, vFuii)
+GO(glVertexAttribI2ivEXT, vFup)
+GO(glVertexAttribI2uiEXT, vFuuu)
+GO(glVertexAttribI2uivEXT, vFup)
+GO(glVertexAttribI3iEXT, vFuiii)
+GO(glVertexAttribI3ivEXT, vFup)
+GO(glVertexAttribI3uiEXT, vFuuuu)
+GO(glVertexAttribI3uivEXT, vFup)
+GO(glVertexAttribI4bvEXT, vFup)
+GO(glVertexAttribI4iEXT, vFuiiii)
+GO(glVertexAttribI4ivEXT, vFup)
+GO(glVertexAttribI4svEXT, vFup)
+GO(glVertexAttribI4ubvEXT, vFup)
+GO(glVertexAttribI4uiEXT, vFuuuuu)
+GO(glVertexAttribI4uivEXT, vFup)
+GO(glVertexAttribI4usvEXT, vFup)
+GO(glVertexAttribIPointerEXT, vFuiuip)
//NV_video_capture
-GO(glBeginVideoCaptureNV,vFu)
-GO(glBindVideoCaptureStreamBufferNV,vFuuui)
-GO(glBindVideoCaptureStreamTextureNV,vFuuuuu)
-GO(glEndVideoCaptureNV,vFu)
-GO(glGetVideoCaptureStreamdvNV,vFuuup)
-GO(glGetVideoCaptureStreamfvNV,vFuuup)
-GO(glGetVideoCaptureStreamivNV,vFuuup)
-GO(glGetVideoCaptureivNV,vFuup)
-GO(glVideoCaptureNV,uFupp)
-GO(glVideoCaptureStreamParameterdvNV,vFuuup)
-GO(glVideoCaptureStreamParameterfvNV,vFuuup)
-GO(glVideoCaptureStreamParameterivNV,vFuuup)
+GO(glBeginVideoCaptureNV, vFu)
+GO(glBindVideoCaptureStreamBufferNV, vFuuul)
+GO(glBindVideoCaptureStreamTextureNV, vFuuuuu)
+GO(glEndVideoCaptureNV, vFu)
+GO(glGetVideoCaptureStreamdvNV, vFuuup)
+GO(glGetVideoCaptureStreamfvNV, vFuuup)
+GO(glGetVideoCaptureStreamivNV, vFuuup)
+GO(glGetVideoCaptureivNV, vFuup)
+GO(glVideoCaptureNV, uFupp)
+GO(glVideoCaptureStreamParameterdvNV, vFuuup)
+GO(glVideoCaptureStreamParameterfvNV, vFuuup)
+GO(glVideoCaptureStreamParameterivNV, vFuuup)
//OES_byte_coordinates
-GO(glMultiTexCoord1bOES,vFui)
-GO(glMultiTexCoord1bvOES,vFup)
-GO(glMultiTexCoord2bOES,vFuii)
-GO(glMultiTexCoord2bvOES,vFup)
-GO(glMultiTexCoord3bOES,vFuiii)
-GO(glMultiTexCoord3bvOES,vFup)
-GO(glMultiTexCoord4bOES,vFuiiii)
-GO(glMultiTexCoord4bvOES,vFup)
-GO(glTexCoord1bOES,vFi)
-GO(glTexCoord1bvOES,vFp)
-GO(glTexCoord2bOES,vFii)
-GO(glTexCoord2bvOES,vFp)
-GO(glTexCoord3bOES,vFiii)
-GO(glTexCoord3bvOES,vFp)
-GO(glTexCoord4bOES,vFiiii)
-GO(glTexCoord4bvOES,vFp)
-GO(glVertex2bOES,vFi)
-GO(glVertex2bvOES,vFp)
-GO(glVertex3bOES,vFii)
-GO(glVertex3bvOES,vFp)
-GO(glVertex4bOES,vFiii)
-GO(glVertex4bvOES,vFp)
+GO(glMultiTexCoord1bOES, vFuc)
+GO(glMultiTexCoord1bvOES, vFup)
+GO(glMultiTexCoord2bOES, vFucc)
+GO(glMultiTexCoord2bvOES, vFup)
+GO(glMultiTexCoord3bOES, vFuiii)
+GO(glMultiTexCoord3bvOES, vFup)
+GO(glMultiTexCoord4bOES, vFucccc)
+GO(glMultiTexCoord4bvOES, vFup)
+GO(glTexCoord1bOES, vFi)
+GO(glTexCoord1bvOES, vFp)
+GO(glTexCoord2bOES, vFii)
+GO(glTexCoord2bvOES, vFp)
+GO(glTexCoord3bOES, vFiii)
+GO(glTexCoord3bvOES, vFp)
+GO(glTexCoord4bOES, vFiiii)
+GO(glTexCoord4bvOES, vFp)
+GO(glVertex2bOES, vFcc)
+GO(glVertex2bvOES, vFp)
+GO(glVertex3bOES, vFii)
+GO(glVertex3bvOES, vFp)
+GO(glVertex4bOES, vFcccc)
+GO(glVertex4bvOES, vFp)
//OES_fixed_point
-GO(glAccumxOES,vFui)
-GO(glAlphaFuncxOES,vFui)
-GO(glBitmapxOES,vFiiiiiip)
-GO(glBlendColorxOES,vFiiii)
-GO(glClearAccumxOES,vFiiii)
-GO(glClearColorxOES,vFiiii)
-GO(glClearDepthxOES,vFi)
-GO(glClipPlanexOES,vFup)
-GO(glColor3xOES,vFiii)
-GO(glColor3xvOES,vFp)
-GO(glColor4xOES,vFiiii)
-GO(glColor4xvOES,vFp)
-GO(glConvolutionParameterxOES,vFuui)
-GO(glConvolutionParameterxvOES,vFuup)
-GO(glDepthRangexOES,vFii)
-GO(glEvalCoord1xOES,vFi)
-GO(glEvalCoord1xvOES,vFp)
-GO(glEvalCoord2xOES,vFii)
-GO(glEvalCoord2xvOES,vFp)
-GO(glFeedbackBufferxOES,vFiup)
-GO(glFogxOES,vFui)
-GO(glFogxvOES,vFup)
-GO(glFrustumxOES,vFiiiiii)
-GO(glGetClipPlanexOES,vFup)
-GO(glGetConvolutionParameterxvOES,vFuup)
-GO(glGetFixedvOES,vFup)
-GO(glGetHistogramParameterxvOES,vFuup)
-GO(glGetLightxOES,vFuup)
-GO(glGetMapxvOES,vFuup)
-GO(glGetMaterialxOES,vFuui)
-GO(glGetPixelMapxv,vFuip)
-GO(glGetTexEnvxvOES,vFuup)
-GO(glGetTexGenxvOES,vFuup)
-GO(glGetTexLevelParameterxvOES,vFuiup)
-GO(glGetTexParameterxvOES,vFuup)
-GO(glIndexxOES,vFi)
-GO(glIndexxvOES,vFp)
-GO(glLightModelxOES,vFui)
-GO(glLightModelxvOES,vFup)
-GO(glLightxOES,vFuui)
-GO(glLightxvOES,vFuup)
-GO(glLineWidthxOES,vFi)
-GO(glLoadMatrixxOES,vFp)
-GO(glLoadTransposeMatrixxOES,vFp)
-GO(glMap1xOES,vFuiiiii)
-GO(glMap2xOES,vFuiiiiiiiii)
-GO(glMapGrid1xOES,vFiii)
-GO(glMapGrid2xOES,vFiiiii)
-GO(glMaterialxOES,vFuui)
-GO(glMaterialxvOES,vFuup)
-GO(glMultMatrixxOES,vFp)
-GO(glMultTransposeMatrixxOES,vFp)
-GO(glMultiTexCoord1xOES,vFui)
-GO(glMultiTexCoord1xvOES,vFup)
-GO(glMultiTexCoord2xOES,vFuii)
-GO(glMultiTexCoord2xvOES,vFup)
-GO(glMultiTexCoord3xOES,vFuiii)
-GO(glMultiTexCoord3xvOES,vFup)
-GO(glMultiTexCoord4xOES,vFuiiii)
-GO(glMultiTexCoord4xvOES,vFup)
-GO(glNormal3xOES,vFiii)
-GO(glNormal3xvOES,vFp)
-GO(glOrthoxOES,vFiiiiii)
-GO(glPassThroughxOES,vFi)
-GO(glPixelMapx,vFuip)
-GO(glPixelStorex,vFui)
-GO(glPixelTransferxOES,vFui)
-GO(glPixelZoomxOES,vFii)
-GO(glPointParameterxvOES,vFup)
-GO(glPointSizexOES,vFi)
-GO(glPolygonOffsetxOES,vFii)
-GO(glPrioritizeTexturesxOES,vFipp)
-GO(glRasterPos2xOES,vFii)
-GO(glRasterPos2xvOES,vFp)
-GO(glRasterPos3xOES,vFiii)
-GO(glRasterPos3xvOES,vFp)
-GO(glRasterPos4xOES,vFiiii)
-GO(glRasterPos4xvOES,vFp)
-GO(glRectxOES,vFiiii)
-GO(glRectxvOES,vFpp)
-GO(glRotatexOES,vFiiii)
-GO(glSampleCoverageOES,vFii)
-GO(glScalexOES,vFiii)
-GO(glTexCoord1xOES,vFi)
-GO(glTexCoord1xvOES,vFp)
-GO(glTexCoord2xOES,vFii)
-GO(glTexCoord2xvOES,vFp)
-GO(glTexCoord3xOES,vFiii)
-GO(glTexCoord3xvOES,vFp)
-GO(glTexCoord4xOES,vFiiii)
-GO(glTexCoord4xvOES,vFp)
-GO(glTexEnvxOES,vFuui)
-GO(glTexEnvxvOES,vFuup)
-GO(glTexGenxOES,vFuui)
-GO(glTexGenxvOES,vFuup)
-GO(glTexParameterxOES,vFuui)
-GO(glTexParameterxvOES,vFuup)
-GO(glTranslatexOES,vFiii)
-GO(glVertex2xOES,vFi)
-GO(glVertex2xvOES,vFp)
-GO(glVertex3xOES,vFii)
-GO(glVertex3xvOES,vFp)
-GO(glVertex4xOES,vFiii)
-GO(glVertex4xvOES,vFp)
+GO(glAccumxOES, vFui)
+GO(glAlphaFuncxOES, vFui)
+GO(glBitmapxOES, vFiiiiiip)
+GO(glBlendColorxOES, vFiiii)
+GO(glClearAccumxOES, vFiiii)
+GO(glClearColorxOES, vFiiii)
+GO(glClearDepthxOES, vFi)
+GO(glClipPlanexOES, vFup)
+GO(glColor3xOES, vFiii)
+GO(glColor3xvOES, vFp)
+GO(glColor4xOES, vFiiii)
+GO(glColor4xvOES, vFp)
+GO(glConvolutionParameterxOES, vFuui)
+GO(glConvolutionParameterxvOES, vFuup)
+GO(glDepthRangexOES, vFii)
+GO(glEvalCoord1xOES, vFi)
+GO(glEvalCoord1xvOES, vFp)
+GO(glEvalCoord2xOES, vFii)
+GO(glEvalCoord2xvOES, vFp)
+GO(glFeedbackBufferxOES, vFiup)
+GO(glFogxOES, vFui)
+GO(glFogxvOES, vFup)
+GO(glFrustumxOES, vFiiiiii)
+GO(glGetClipPlanexOES, vFup)
+GO(glGetConvolutionParameterxvOES, vFuup)
+GO(glGetFixedvOES, vFup)
+GO(glGetHistogramParameterxvOES, vFuup)
+GO(glGetLightxOES, vFuup)
+GO(glGetMapxvOES, vFuup)
+GO(glGetMaterialxOES, vFuui)
+GO(glGetPixelMapxv, vFuip)
+GO(glGetTexEnvxvOES, vFuup)
+GO(glGetTexGenxvOES, vFuup)
+GO(glGetTexLevelParameterxvOES, vFuiup)
+GO(glGetTexParameterxvOES, vFuup)
+GO(glIndexxOES, vFi)
+GO(glIndexxvOES, vFp)
+GO(glLightModelxOES, vFui)
+GO(glLightModelxvOES, vFup)
+GO(glLightxOES, vFuui)
+GO(glLightxvOES, vFuup)
+GO(glLineWidthxOES, vFi)
+GO(glLoadMatrixxOES, vFp)
+GO(glLoadTransposeMatrixxOES, vFp)
+GO(glMap1xOES, vFuiiiii)
+GO(glMap2xOES, vFuiiiiiiiii)
+GO(glMapGrid1xOES, vFiii)
+GO(glMapGrid2xOES, vFiiiii)
+GO(glMaterialxOES, vFuui)
+GO(glMaterialxvOES, vFuup)
+GO(glMultMatrixxOES, vFp)
+GO(glMultTransposeMatrixxOES, vFp)
+GO(glMultiTexCoord1xOES, vFui)
+GO(glMultiTexCoord1xvOES, vFup)
+GO(glMultiTexCoord2xOES, vFuii)
+GO(glMultiTexCoord2xvOES, vFup)
+GO(glMultiTexCoord3xOES, vFuiii)
+GO(glMultiTexCoord3xvOES, vFup)
+GO(glMultiTexCoord4xOES, vFuiiii)
+GO(glMultiTexCoord4xvOES, vFup)
+GO(glNormal3xOES, vFiii)
+GO(glNormal3xvOES, vFp)
+GO(glOrthoxOES, vFiiiiii)
+GO(glPassThroughxOES, vFi)
+GO(glPixelMapx, vFuip)
+GO(glPixelStorex, vFui)
+GO(glPixelTransferxOES, vFui)
+GO(glPixelZoomxOES, vFii)
+GO(glPointParameterxvOES, vFup)
+GO(glPointSizexOES, vFi)
+GO(glPolygonOffsetxOES, vFii)
+GO(glPrioritizeTexturesxOES, vFipp)
+GO(glRasterPos2xOES, vFii)
+GO(glRasterPos2xvOES, vFp)
+GO(glRasterPos3xOES, vFiii)
+GO(glRasterPos3xvOES, vFp)
+GO(glRasterPos4xOES, vFiiii)
+GO(glRasterPos4xvOES, vFp)
+GO(glRectxOES, vFiiii)
+GO(glRectxvOES, vFpp)
+GO(glRotatexOES, vFiiii)
+GO(glSampleCoverageOES, vFii)
+GO(glScalexOES, vFiii)
+GO(glTexCoord1xOES, vFi)
+GO(glTexCoord1xvOES, vFp)
+GO(glTexCoord2xOES, vFii)
+GO(glTexCoord2xvOES, vFp)
+GO(glTexCoord3xOES, vFiii)
+GO(glTexCoord3xvOES, vFp)
+GO(glTexCoord4xOES, vFiiii)
+GO(glTexCoord4xvOES, vFp)
+GO(glTexEnvxOES, vFuui)
+GO(glTexEnvxvOES, vFuup)
+GO(glTexGenxOES, vFuui)
+GO(glTexGenxvOES, vFuup)
+GO(glTexParameterxOES, vFuui)
+GO(glTexParameterxvOES, vFuup)
+GO(glTranslatexOES, vFiii)
+GO(glVertex2xOES, vFi)
+GO(glVertex2xvOES, vFp)
+GO(glVertex3xOES, vFii)
+GO(glVertex3xvOES, vFp)
+GO(glVertex4xOES, vFiii)
+GO(glVertex4xvOES, vFp)
//OES_query_matrix
-GO(glQueryMatrixxOES,iFpp)
+GO(glQueryMatrixxOES, uFpp)
//OES_single_precision
-GO(glClearDepthfOES,vFf)
-GO(glClipPlanefOES,vFup)
-GO(glDepthRangefOES,vFff)
-GO(glFrustumfOES,vFffffff)
-GO(glGetClipPlanefOES,vFup)
-GO(glOrthofOES,vFffffff)
+GO(glClearDepthfOES, vFf)
+GO(glClipPlanefOES, vFup)
+GO(glDepthRangefOES, vFff)
+GO(glFrustumfOES, vFffffff)
+GO(glGetClipPlanefOES, vFup)
+GO(glOrthofOES, vFffffff)
//PGI_misc_hints
-GO(glHintPGI,vFui)
+GO(glHintPGI, vFui)
//SGIS_detail_texture
-GO(glDetailTexFuncSGIS,vFuip)
-GO(glGetDetailTexFuncSGIS,vFup)
+GO(glDetailTexFuncSGIS, vFuip)
+GO(glGetDetailTexFuncSGIS, vFup)
//SGIS_fog_function
-GO(glFogFuncSGIS,vFip)
-GO(glGetFogFuncSGIS,vFp)
+GO(glFogFuncSGIS, vFip)
+GO(glGetFogFuncSGIS, vFp)
//SGIS_multisample
-GO(glSampleMaskSGIS,vFfi)
-GO(glSamplePatternSGIS,vFu)
+GO(glSampleMaskSGIS, vFfC)
+GO(glSamplePatternSGIS, vFu)
//SGIS_pixel_texture
-GO(glGetPixelTexGenParameterfvSGIS,vFup)
-GO(glGetPixelTexGenParameterivSGIS,vFup)
-GO(glPixelTexGenParameterfSGIS,vFuf)
-GO(glPixelTexGenParameterfvSGIS,vFup)
-GO(glPixelTexGenParameteriSGIS,vFui)
-GO(glPixelTexGenParameterivSGIS,vFup)
+GO(glGetPixelTexGenParameterfvSGIS, vFup)
+GO(glGetPixelTexGenParameterivSGIS, vFup)
+GO(glPixelTexGenParameterfSGIS, vFuf)
+GO(glPixelTexGenParameterfvSGIS, vFup)
+GO(glPixelTexGenParameteriSGIS, vFui)
+GO(glPixelTexGenParameterivSGIS, vFup)
//SGIS_point_parameters
-GO(glPointParameterfSGIS,vFuf)
-GO(glPointParameterfvSGIS,vFup)
+GO(glPointParameterfSGIS, vFuf)
+GO(glPointParameterfvSGIS, vFup)
//SGIS_sharpen_texture
-GO(glGetSharpenTexFuncSGIS,vFup)
-GO(glSharpenTexFuncSGIS,vFuip)
+GO(glGetSharpenTexFuncSGIS, vFup)
+GO(glSharpenTexFuncSGIS, vFuip)
//SGIS_texture4D
-GO(glTexImage4DSGIS,vFuiuiiiiiuup)
-GO(glTexSubImage4DSGIS,vFuiiiiiiiiiuup)
+GO(glTexImage4DSGIS, vFuiuiiiiiuup)
+GO(glTexSubImage4DSGIS, vFuiiiiiiiiiuup)
//SGIS_texture_color_mask
-GO(glTextureColorMaskSGIS,vFiiii)
+GO(glTextureColorMaskSGIS, vFCCCC)
//SGIS_texture_filter4
-GO(glGetTexFilterFuncSGIS,vFuup)
-GO(glTexFilterFuncSGIS,vFuuip)
+GO(glGetTexFilterFuncSGIS, vFuup)
+GO(glTexFilterFuncSGIS, vFuuip)
//SGIX_async
-GO(glAsyncMarkerSGIX,vFu)
-GO(glDeleteAsyncMarkersSGIX,vFui)
-GO(glFinishAsyncSGIX,iFp)
-GO(glGenAsyncMarkersSGIX,uFi)
-GO(glIsAsyncMarkerSGIX,iFu)
-GO(glPollAsyncSGIX,iFp)
+GO(glAsyncMarkerSGIX, vFu)
+GO(glDeleteAsyncMarkersSGIX, vFui)
+GO(glFinishAsyncSGIX, iFp)
+GO(glGenAsyncMarkersSGIX, uFi)
+GO(glIsAsyncMarkerSGIX, CFu)
+GO(glPollAsyncSGIX, iFp)
//SGIX_flush_raster
-GO(glFlushRasterSGIX,vFv)
+GO(glFlushRasterSGIX, vFv)
//SGIX_fragment_lighting
-GO(glFragmentColorMaterialSGIX,vFuu)
-GO(glFragmentLightModelfSGIX,vFuf)
-GO(glFragmentLightModelfvSGIX,vFup)
-GO(glFragmentLightModeliSGIX,vFui)
-GO(glFragmentLightModelivSGIX,vFup)
-GO(glFragmentLightfSGIX,vFuuf)
-GO(glFragmentLightfvSGIX,vFuup)
-GO(glFragmentLightiSGIX,vFuui)
-GO(glFragmentLightivSGIX,vFuup)
-GO(glFragmentMaterialfSGIX,vFuuf)
-GO(glFragmentMaterialfvSGIX,vFuup)
-GO(glFragmentMaterialiSGIX,vFuui)
-GO(glFragmentMaterialivSGIX,vFuup)
-GO(glGetFragmentLightfvSGIX,vFuup)
-GO(glGetFragmentLightivSGIX,vFuup)
-GO(glGetFragmentMaterialfvSGIX,vFuup)
-GO(glGetFragmentMaterialivSGIX,vFuup)
-GO(glLightEnviSGIX,vFui)
+GO(glFragmentColorMaterialSGIX, vFuu)
+GO(glFragmentLightModelfSGIX, vFuf)
+GO(glFragmentLightModelfvSGIX, vFup)
+GO(glFragmentLightModeliSGIX, vFui)
+GO(glFragmentLightModelivSGIX, vFup)
+GO(glFragmentLightfSGIX, vFuuf)
+GO(glFragmentLightfvSGIX, vFuup)
+GO(glFragmentLightiSGIX, vFuui)
+GO(glFragmentLightivSGIX, vFuup)
+GO(glFragmentMaterialfSGIX, vFuuf)
+GO(glFragmentMaterialfvSGIX, vFuup)
+GO(glFragmentMaterialiSGIX, vFuui)
+GO(glFragmentMaterialivSGIX, vFuup)
+GO(glGetFragmentLightfvSGIX, vFuup)
+GO(glGetFragmentLightivSGIX, vFuup)
+GO(glGetFragmentMaterialfvSGIX, vFuup)
+GO(glGetFragmentMaterialivSGIX, vFuup)
+GO(glLightEnviSGIX, vFui)
//SGIX_framezoom
-GO(glFrameZoomSGIX,vFi)
+GO(glFrameZoomSGIX, vFi)
//SGIX_igloo_interface
-GO(glIglooInterfaceSGIX,vFup)
+GO(glIglooInterfaceSGIX, vFup)
//SGIX_instruments
-GO(glGetInstrumentsSGIX,iFv)
-GO(glInstrumentsBufferSGIX,vFip)
-GO(glPollInstrumentsSGIX,iFp)
-GO(glReadInstrumentsSGIX,vFi)
-GO(glStartInstrumentsSGIX,vFv)
-GO(glStopInstrumentsSGIX,vFi)
+GO(glGetInstrumentsSGIX, iFv)
+GO(glInstrumentsBufferSGIX, vFip)
+GO(glPollInstrumentsSGIX, iFp)
+GO(glReadInstrumentsSGIX, vFi)
+GO(glStartInstrumentsSGIX, vFv)
+GO(glStopInstrumentsSGIX, vFi)
//SGIX_list_priority
-GO(glGetListParameterfvSGIX,vFuup)
-GO(glGetListParameterivSGIX,vFuup)
-GO(glListParameterfSGIX,vFuuf)
-GO(glListParameterfvSGIX,vFuup)
-GO(glListParameteriSGIX,vFuui)
-GO(glListParameterivSGIX,vFuup)
+GO(glGetListParameterfvSGIX, vFuup)
+GO(glGetListParameterivSGIX, vFuup)
+GO(glListParameterfSGIX, vFuuf)
+GO(glListParameterfvSGIX, vFuup)
+GO(glListParameteriSGIX, vFuui)
+GO(glListParameterivSGIX, vFuup)
//SGIX_pixel_texture
-GO(glPixelTexGenSGIX,vFu)
+GO(glPixelTexGenSGIX, vFu)
//SGIX_polynomial_ffd
-GO(glDeformSGIX,vFi)
-GO(glDeformationMap3dSGIX,vFuddiiddiiddiip)
-GO(glDeformationMap3fSGIX,vFuffiiffiiffiip)
-GO(glLoadIdentityDeformationMapSGIX,vFi)
+GO(glDeformSGIX, vFi)
+GO(glDeformationMap3dSGIX, vFuddiiddiiddiip)
+GO(glDeformationMap3fSGIX, vFuffiiffiiffiip)
+GO(glLoadIdentityDeformationMapSGIX, vFu)
//SGIX_reference_plane
-GO(glReferencePlaneSGIX,vFp)
+GO(glReferencePlaneSGIX, vFp)
//SGIX_sprite
-GO(glSpriteParameterfSGIX,vFuf)
-GO(glSpriteParameterfvSGIX,vFup)
-GO(glSpriteParameteriSGIX,vFui)
-GO(glSpriteParameterivSGIX,vFup)
+GO(glSpriteParameterfSGIX, vFuf)
+GO(glSpriteParameterfvSGIX, vFup)
+GO(glSpriteParameteriSGIX, vFui)
+GO(glSpriteParameterivSGIX, vFup)
//SGIX_tag_sample_buffer
-GO(glTagSampleBufferSGIX,vFv)
+GO(glTagSampleBufferSGIX, vFv)
//SGI_color_table
-GO(glColorTableParameterfvSGI,vFuup)
-GO(glColorTableParameterivSGI,vFuup)
-GO(glColorTableSGI,vFuuiuup)
-GO(glCopyColorTableSGI,vFuuiii)
-GO(glGetColorTableParameterfvSGI,vFuup)
-GO(glGetColorTableParameterivSGI,vFuup)
-GO(glGetColorTableSGI,vFuuup)
+GO(glColorTableParameterfvSGI, vFuup)
+GO(glColorTableParameterivSGI, vFuup)
+GO(glColorTableSGI, vFuuiuup)
+GO(glCopyColorTableSGI, vFuuiii)
+GO(glGetColorTableParameterfvSGI, vFuup)
+GO(glGetColorTableParameterivSGI, vFuup)
+GO(glGetColorTableSGI, vFuuup)
//SUNX_constant_data
-GO(glFinishTextureSUNX,vFv)
+GO(glFinishTextureSUNX, vFv)
//SUN_global_alpha
-GO(glGlobalAlphaFactorbSUN,vFi)
-GO(glGlobalAlphaFactordSUN,vFd)
-GO(glGlobalAlphaFactorfSUN,vFf)
-GO(glGlobalAlphaFactoriSUN,vFi)
-GO(glGlobalAlphaFactorsSUN,vFi)
-GO(glGlobalAlphaFactorubSUN,vFu)
-GO(glGlobalAlphaFactoruiSUN,vFu)
-GO(glGlobalAlphaFactorusSUN,vFu)
+GO(glGlobalAlphaFactorbSUN, vFc)
+GO(glGlobalAlphaFactordSUN, vFd)
+GO(glGlobalAlphaFactorfSUN, vFf)
+GO(glGlobalAlphaFactoriSUN, vFi)
+GO(glGlobalAlphaFactorsSUN, vFw)
+GO(glGlobalAlphaFactorubSUN, vFu)
+GO(glGlobalAlphaFactoruiSUN, vFu)
+GO(glGlobalAlphaFactorusSUN, vFu)
//SUN_mesh_array
-GO(glDrawMeshArraysSUN,vFuiii)
+GO(glDrawMeshArraysSUN, vFuiii)
//SUN_triangle_list
-GO(glReplacementCodePointerSUN,vFuip)
-GO(glReplacementCodeubSUN,vFu)
-GO(glReplacementCodeubvSUN,vFp)
-GO(glReplacementCodeuiSUN,vFu)
-GO(glReplacementCodeuivSUN,vFp)
-GO(glReplacementCodeusSUN,vFu)
-GO(glReplacementCodeusvSUN,vFp)
+GO(glReplacementCodePointerSUN, vFuip)
+GO(glReplacementCodeubSUN, vFC)
+GO(glReplacementCodeubvSUN, vFp)
+GO(glReplacementCodeuiSUN, vFu)
+GO(glReplacementCodeuivSUN, vFp)
+GO(glReplacementCodeusSUN, vFW)
+GO(glReplacementCodeusvSUN, vFp)
//SUN_vertex
-GO(glColor3fVertex3fSUN,vFffffff)
-GO(glColor3fVertex3fvSUN,vFpp)
-GO(glColor4fNormal3fVertex3fSUN,vFffffffffff)
-GO(glColor4fNormal3fVertex3fvSUN,vFppp)
-GO(glColor4ubVertex2fSUN,vFuuuuff)
-GO(glColor4ubVertex2fvSUN,vFpp)
-GO(glColor4ubVertex3fSUN,vFuuuufff)
-GO(glColor4ubVertex3fvSUN,vFpp)
-GO(glNormal3fVertex3fSUN,vFffffff)
-GO(glNormal3fVertex3fvSUN,vFpp)
-GO(glReplacementCodeuiColor3fVertex3fSUN,vFuffffff)
-GO(glReplacementCodeuiColor3fVertex3fvSUN,vFppp)
-GO(glReplacementCodeuiColor4fNormal3fVertex3fSUN,vFuffffffffff)
-GO(glReplacementCodeuiColor4fNormal3fVertex3fvSUN,vFpppp)
-GO(glReplacementCodeuiColor4ubVertex3fSUN,vFuuuuufff)
-GO(glReplacementCodeuiColor4ubVertex3fvSUN,vFppp)
-GO(glReplacementCodeuiNormal3fVertex3fSUN,vFuffffff)
-GO(glReplacementCodeuiNormal3fVertex3fvSUN,vFppp)
-GO(glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN,vFuffffffffffff)
-GO(glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN,vFppppp)
-GO(glReplacementCodeuiTexCoord2fNormal3fVertex3fSUN,vFuffffffff)
-GO(glReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN,vFpppp)
-GO(glReplacementCodeuiTexCoord2fVertex3fSUN,vFufffff)
-GO(glReplacementCodeuiTexCoord2fVertex3fvSUN,vFppp)
-GO(glReplacementCodeuiVertex3fSUN,vFufff)
-GO(glReplacementCodeuiVertex3fvSUN,vFpp)
-GO(glTexCoord2fColor3fVertex3fSUN,vFffffffff)
-GO(glTexCoord2fColor3fVertex3fvSUN,vFppp)
-GO(glTexCoord2fColor4fNormal3fVertex3fSUN,vFffffffffffff)
-GO(glTexCoord2fColor4fNormal3fVertex3fvSUN,vFpppp)
-GO(glTexCoord2fColor4ubVertex3fSUN,vFffuuuufff)
-GO(glTexCoord2fColor4ubVertex3fvSUN,vFppp)
-GO(glTexCoord2fNormal3fVertex3fSUN,vFffffffff)
-GO(glTexCoord2fNormal3fVertex3fvSUN,vFppp)
-GO(glTexCoord2fVertex3fSUN,vFfffff)
-GO(glTexCoord2fVertex3fvSUN,vFpp)
-GO(glTexCoord4fColor4fNormal3fVertex4fSUN,vFfffffffffffffff)
-GO(glTexCoord4fColor4fNormal3fVertex4fvSUN,vFpppp)
-GO(glTexCoord4fVertex4fSUN,vFffffffff)
-GO(glTexCoord4fVertex4fvSUN,vFpp)
-//VERSION_1_0
-GO(glAccum,vFuf)
-GO(glAlphaFunc,vFuf)
-GO(glBegin,vFu)
-GO(glBitmap,vFiiffffp)
-GO(glBlendFunc,vFuu)
-GO(glCallList,vFu)
-GO(glCallLists,vFiup)
-GO(glClear,vFi)
-GO(glClearAccum,vFffff)
-GO(glClearColor,vFffff)
-GO(glClearDepth,vFd)
-GO(glClearIndex,vFf)
-GO(glClearStencil,vFi)
-GO(glClipPlane,vFup)
-GO(glColor3b,vFiii)
-GO(glColor3bv,vFp)
-GO(glColor3d,vFddd)
-GO(glColor3dv,vFp)
-GO(glColor3f,vFfff)
-GO(glColor3fv,vFp)
-GO(glColor3i,vFiii)
-GO(glColor3iv,vFp)
-GO(glColor3s,vFiii)
-GO(glColor3sv,vFp)
-GO(glColor3ub,vFuuu)
-GO(glColor3ubv,vFp)
-GO(glColor3ui,vFuuu)
-GO(glColor3uiv,vFp)
-GO(glColor3us,vFuuu)
-GO(glColor3usv,vFp)
-GO(glColor4b,vFiiii)
-GO(glColor4bv,vFp)
-GO(glColor4d,vFdddd)
-GO(glColor4dv,vFp)
-GO(glColor4f,vFffff)
-GO(glColor4fv,vFp)
-GO(glColor4i,vFiiii)
-GO(glColor4iv,vFp)
-GO(glColor4s,vFiiii)
-GO(glColor4sv,vFp)
-GO(glColor4ub,vFuuuu)
-GO(glColor4ubv,vFp)
-GO(glColor4ui,vFuuuu)
-GO(glColor4uiv,vFp)
-GO(glColor4us,vFuuuu)
-GO(glColor4usv,vFp)
-GO(glColorMask,vFiiii)
-GO(glColorMaterial,vFuu)
-GO(glCopyPixels,vFiiiiu)
-GO(glCullFace,vFu)
-GO(glDeleteLists,vFui)
-GO(glDepthFunc,vFu)
-GO(glDepthMask,vFi)
-GO(glDepthRange,vFdd)
-GO(glDisable,vFu)
-GO(glDrawBuffer,vFu)
-GO(glDrawPixels,vFiiuup)
-GO(glEdgeFlag,vFi)
-GO(glEdgeFlagv,vFp)
-GO(glEnable,vFu)
-GO(glEnd,vFv)
-GO(glEndList,vFv)
-GO(glEvalCoord1d,vFd)
-GO(glEvalCoord1dv,vFp)
-GO(glEvalCoord1f,vFf)
-GO(glEvalCoord1fv,vFp)
-GO(glEvalCoord2d,vFdd)
-GO(glEvalCoord2dv,vFp)
-GO(glEvalCoord2f,vFff)
-GO(glEvalCoord2fv,vFp)
-GO(glEvalMesh1,vFuii)
-GO(glEvalMesh2,vFuiiii)
-GO(glEvalPoint1,vFi)
-GO(glEvalPoint2,vFii)
-GO(glFeedbackBuffer,vFiup)
-GO(glFinish,vFv)
-GO(glFlush,vFv)
-GO(glFogf,vFuf)
-GO(glFogfv,vFup)
-GO(glFogi,vFui)
-GO(glFogiv,vFup)
-GO(glFrontFace,vFu)
-GO(glFrustum,vFdddddd)
-GO(glGenLists,uFi)
-GO(glGetBooleanv,vFup)
-GO(glGetClipPlane,vFup)
-GO(glGetDoublev,vFup)
-GO(glGetError,uFv)
-GO(glGetFloatv,vFup)
-GO(glGetIntegerv,vFup)
-GO(glGetLightfv,vFuup)
-GO(glGetLightiv,vFuup)
-GO(glGetMapdv,vFuup)
-GO(glGetMapfv,vFuup)
-GO(glGetMapiv,vFuup)
-GO(glGetMaterialfv,vFuup)
-GO(glGetMaterialiv,vFuup)
-GO(glGetPixelMapfv,vFup)
-GO(glGetPixelMapuiv,vFup)
-GO(glGetPixelMapusv,vFup)
-GO(glGetPolygonStipple,vFp)
-GO(glGetString,pFu)
-GO(glGetTexEnvfv,vFuup)
-GO(glGetTexEnviv,vFuup)
-GO(glGetTexGendv,vFuup)
-GO(glGetTexGenfv,vFuup)
-GO(glGetTexGeniv,vFuup)
-GO(glGetTexImage,vFuiuup)
-GO(glGetTexLevelParameterfv,vFuiup)
-GO(glGetTexLevelParameteriv,vFuiup)
-GO(glGetTexParameterfv,vFuup)
-GO(glGetTexParameteriv,vFuup)
-GO(glHint,vFuu)
-GO(glIndexMask,vFu)
-GO(glIndexd,vFd)
-GO(glIndexdv,vFp)
-GO(glIndexf,vFf)
-GO(glIndexfv,vFp)
-GO(glIndexi,vFi)
-GO(glIndexiv,vFp)
-GO(glIndexs,vFi)
-GO(glIndexsv,vFp)
-GO(glInitNames,vFv)
-GO(glIsEnabled,iFu)
-GO(glIsList,iFu)
-GO(glLightModelf,vFuf)
-GO(glLightModelfv,vFup)
-GO(glLightModeli,vFui)
-GO(glLightModeliv,vFup)
-GO(glLightf,vFuuf)
-GO(glLightfv,vFuup)
-GO(glLighti,vFuui)
-GO(glLightiv,vFuup)
-GO(glLineStipple,vFiu)
-GO(glLineWidth,vFf)
-GO(glListBase,vFu)
-GO(glLoadIdentity,vFv)
-GO(glLoadMatrixd,vFp)
-GO(glLoadMatrixf,vFp)
-GO(glLoadName,vFu)
-GO(glLogicOp,vFu)
-GO(glMap1d,vFuddiip)
-GO(glMap1f,vFuffiip)
-GO(glMap2d,vFuddiiddiip)
-GO(glMap2f,vFuffiiffiip)
-GO(glMapGrid1d,vFidd)
-GO(glMapGrid1f,vFiff)
-GO(glMapGrid2d,vFiddidd)
-GO(glMapGrid2f,vFiffiff)
-GO(glMaterialf,vFuuf)
-GO(glMaterialfv,vFuup)
-GO(glMateriali,vFuui)
-GO(glMaterialiv,vFuup)
-GO(glMatrixMode,vFu)
-GO(glMultMatrixd,vFp)
-GO(glMultMatrixf,vFp)
-GO(glNewList,vFuu)
-GO(glNormal3b,vFiii)
-GO(glNormal3bv,vFp)
-GO(glNormal3d,vFddd)
-GO(glNormal3dv,vFp)
-GO(glNormal3f,vFfff)
-GO(glNormal3fv,vFp)
-GO(glNormal3i,vFiii)
-GO(glNormal3iv,vFp)
-GO(glNormal3s,vFiii)
-GO(glNormal3sv,vFp)
-GO(glOrtho,vFdddddd)
-GO(glPassThrough,vFf)
-GO(glPixelMapfv,vFuip)
-GO(glPixelMapuiv,vFuip)
-GO(glPixelMapusv,vFuip)
-GO(glPixelStoref,vFuf)
-GO(glPixelStorei,vFui)
-GO(glPixelTransferf,vFuf)
-GO(glPixelTransferi,vFui)
-GO(glPixelZoom,vFff)
-GO(glPointSize,vFf)
-GO(glPolygonMode,vFuu)
-GO(glPolygonStipple,vFp)
-GO(glPopAttrib,vFv)
-GO(glPopMatrix,vFv)
-GO(glPopName,vFv)
-GO(glPushAttrib,vFi)
-GO(glPushMatrix,vFv)
-GO(glPushName,vFu)
-GO(glRasterPos2d,vFdd)
-GO(glRasterPos2dv,vFp)
-GO(glRasterPos2f,vFff)
-GO(glRasterPos2fv,vFp)
-GO(glRasterPos2i,vFii)
-GO(glRasterPos2iv,vFp)
-GO(glRasterPos2s,vFii)
-GO(glRasterPos2sv,vFp)
-GO(glRasterPos3d,vFddd)
-GO(glRasterPos3dv,vFp)
-GO(glRasterPos3f,vFfff)
-GO(glRasterPos3fv,vFp)
-GO(glRasterPos3i,vFiii)
-GO(glRasterPos3iv,vFp)
-GO(glRasterPos3s,vFiii)
-GO(glRasterPos3sv,vFp)
-GO(glRasterPos4d,vFdddd)
-GO(glRasterPos4dv,vFp)
-GO(glRasterPos4f,vFffff)
-GO(glRasterPos4fv,vFp)
-GO(glRasterPos4i,vFiiii)
-GO(glRasterPos4iv,vFp)
-GO(glRasterPos4s,vFiiii)
-GO(glRasterPos4sv,vFp)
-GO(glReadBuffer,vFu)
-GO(glReadPixels,vFiiiiuup)
-GO(glRectd,vFdddd)
-GO(glRectdv,vFpp)
-GO(glRectf,vFffff)
-GO(glRectfv,vFpp)
-GO(glRecti,vFiiii)
-GO(glRectiv,vFpp)
-GO(glRects,vFiiii)
-GO(glRectsv,vFpp)
-GO(glRenderMode,iFu)
-GO(glRotated,vFdddd)
-GO(glRotatef,vFffff)
-GO(glScaled,vFddd)
-GO(glScalef,vFfff)
-GO(glScissor,vFiiii)
-GO(glSelectBuffer,vFip)
-GO(glShadeModel,vFu)
-GO(glStencilFunc,vFuiu)
-GO(glStencilMask,vFu)
-GO(glStencilOp,vFuuu)
-GO(glTexCoord1d,vFd)
-GO(glTexCoord1dv,vFp)
-GO(glTexCoord1f,vFf)
-GO(glTexCoord1fv,vFp)
-GO(glTexCoord1i,vFi)
-GO(glTexCoord1iv,vFp)
-GO(glTexCoord1s,vFi)
-GO(glTexCoord1sv,vFp)
-GO(glTexCoord2d,vFdd)
-GO(glTexCoord2dv,vFp)
-GO(glTexCoord2f,vFff)
-GO(glTexCoord2fv,vFp)
-GO(glTexCoord2i,vFii)
-GO(glTexCoord2iv,vFp)
-GO(glTexCoord2s,vFii)
-GO(glTexCoord2sv,vFp)
-GO(glTexCoord3d,vFddd)
-GO(glTexCoord3dv,vFp)
-GO(glTexCoord3f,vFfff)
-GO(glTexCoord3fv,vFp)
-GO(glTexCoord3i,vFiii)
-GO(glTexCoord3iv,vFp)
-GO(glTexCoord3s,vFiii)
-GO(glTexCoord3sv,vFp)
-GO(glTexCoord4d,vFdddd)
-GO(glTexCoord4dv,vFp)
-GO(glTexCoord4f,vFffff)
-GO(glTexCoord4fv,vFp)
-GO(glTexCoord4i,vFiiii)
-GO(glTexCoord4iv,vFp)
-GO(glTexCoord4s,vFiiii)
-GO(glTexCoord4sv,vFp)
-GO(glTexEnvf,vFuuf)
-GO(glTexEnvfv,vFuup)
-GO(glTexEnvi,vFuui)
-GO(glTexEnviv,vFuup)
-GO(glTexGend,vFuud)
-GO(glTexGendv,vFuup)
-GO(glTexGenf,vFuuf)
-GO(glTexGenfv,vFuup)
-GO(glTexGeni,vFuui)
-GO(glTexGeniv,vFuup)
-GO(glTexImage1D,vFuiiiiuup)
-GO(glTexImage2D,vFuiiiiiuup)
-GO(glTexParameterf,vFuuf)
-GO(glTexParameterfv,vFuup)
-GO(glTexParameteri,vFuui)
-GO(glTexParameteriv,vFuup)
-GO(glTranslated,vFddd)
-GO(glTranslatef,vFfff)
-GO(glVertex2d,vFdd)
-GO(glVertex2dv,vFp)
-GO(glVertex2f,vFff)
-GO(glVertex2fv,vFp)
-GO(glVertex2i,vFii)
-GO(glVertex2iv,vFp)
-GO(glVertex2s,vFii)
-GO(glVertex2sv,vFp)
-GO(glVertex3d,vFddd)
-GO(glVertex3dv,vFp)
-GO(glVertex3f,vFfff)
-GO(glVertex3fv,vFp)
-GO(glVertex3i,vFiii)
-GO(glVertex3iv,vFp)
-GO(glVertex3s,vFiii)
-GO(glVertex3sv,vFp)
-GO(glVertex4d,vFdddd)
-GO(glVertex4dv,vFp)
-GO(glVertex4f,vFffff)
-GO(glVertex4fv,vFp)
-GO(glVertex4i,vFiiii)
-GO(glVertex4iv,vFp)
-GO(glVertex4s,vFiiii)
-GO(glVertex4sv,vFp)
-GO(glViewport,vFiiii)
-//VERSION_1_1
-GO(glAreTexturesResident,iFipp)
-GO(glArrayElement,vFi)
-GO(glBindTexture,vFuu)
-GO(glColorPointer,vFiuip)
-GO(glCopyTexImage1D,vFuiuiiii)
-GO(glCopyTexImage2D,vFuiuiiiii)
-GO(glCopyTexSubImage1D,vFuiiiii)
-GO(glCopyTexSubImage2D,vFuiiiiiii)
-GO(glDeleteTextures,vFip)
-GO(glDisableClientState,vFu)
-GO(glDrawArrays,vFuii)
-GO(glDrawElements,vFuiup)
-GO(glEdgeFlagPointer,vFip)
-GO(glEnableClientState,vFu)
-GO(glGenTextures,vFip)
-GO(glGetPointerv,vFup)
-GO(glIndexPointer,vFuip)
-GO(glIndexub,vFu)
-GO(glIndexubv,vFp)
-GO(glInterleavedArrays,vFuip)
-GO(glIsTexture,iFu)
-GO(glNormalPointer,vFuip)
-GO(glPolygonOffset,vFff)
-GO(glPopClientAttrib,vFv)
-GO(glPrioritizeTextures,vFipp)
-GO(glPushClientAttrib,vFi)
-GO(glTexCoordPointer,vFiuip)
-GO(glTexSubImage1D,vFuiiiuup)
-GO(glTexSubImage2D,vFuiiiiiuup)
-GO(glVertexPointer,vFiuip)
-//VERSION_1_2
-GO(glBlendColor,vFffff)
-GO(glBlendEquation,vFu)
-GO(glColorSubTable,vFuiiuup)
-GO(glColorTable,vFuuiuup)
-GO(glColorTableParameterfv,vFuup)
-GO(glColorTableParameteriv,vFuup)
-GO(glConvolutionFilter1D,vFuuiuup)
-GO(glConvolutionFilter2D,vFuuiiuup)
-GO(glConvolutionParameterf,vFuuf)
-GO(glConvolutionParameterfv,vFuup)
-GO(glConvolutionParameteri,vFuui)
-GO(glConvolutionParameteriv,vFuup)
-GO(glCopyColorSubTable,vFuiiii)
-GO(glCopyColorTable,vFuuiii)
-GO(glCopyConvolutionFilter1D,vFuuiii)
-GO(glCopyConvolutionFilter2D,vFuuiiii)
-GO(glCopyTexSubImage3D,vFuiiiiiiii)
-GO(glDrawRangeElements,vFuuuiup)
-GO(glGetColorTable,vFuuup)
-GO(glGetColorTableParameterfv,vFuup)
-GO(glGetColorTableParameteriv,vFuup)
-GO(glGetConvolutionFilter,vFuuup)
-GO(glGetConvolutionParameterfv,vFuup)
-GO(glGetConvolutionParameteriv,vFuup)
-GO(glGetHistogram,vFuiuup)
-GO(glGetHistogramParameterfv,vFuup)
-GO(glGetHistogramParameteriv,vFuup)
-GO(glGetMinmax,vFuiuup)
-GO(glGetMinmaxParameterfv,vFuup)
-GO(glGetMinmaxParameteriv,vFuup)
-GO(glGetSeparableFilter,vFuuuppp)
-GO(glHistogram,vFuiui)
-GO(glMinmax,vFuui)
-GO(glResetHistogram,vFu)
-GO(glResetMinmax,vFu)
-GO(glSeparableFilter2D,vFuuiiuupp)
-GO(glTexImage3D,vFuiiiiiiuup)
-GO(glTexSubImage3D,vFuiiiiiiiuup)
-//VERSION_1_3
-GO(glActiveTexture,vFu)
-GO(glClientActiveTexture,vFu)
-GO(glCompressedTexImage1D,vFuiuiiip)
-GO(glCompressedTexImage2D,vFuiuiiiip)
-GO(glCompressedTexImage3D,vFuiuiiiiip)
-GO(glCompressedTexSubImage1D,vFuiiiuip)
-GO(glCompressedTexSubImage2D,vFuiiiiiuip)
-GO(glCompressedTexSubImage3D,vFuiiiiiiiuip)
-GO(glGetCompressedTexImage,vFuip)
-GO(glLoadTransposeMatrixd,vFp)
-GO(glLoadTransposeMatrixf,vFp)
-GO(glMultTransposeMatrixd,vFp)
-GO(glMultTransposeMatrixf,vFp)
-GO(glMultiTexCoord1d,vFud)
-GO(glMultiTexCoord1dv,vFup)
-GO(glMultiTexCoord1f,vFuf)
-GO(glMultiTexCoord1fv,vFup)
-GO(glMultiTexCoord1i,vFui)
-GO(glMultiTexCoord1iv,vFup)
-GO(glMultiTexCoord1s,vFui)
-GO(glMultiTexCoord1sv,vFup)
-GO(glMultiTexCoord2d,vFudd)
-GO(glMultiTexCoord2dv,vFup)
-GO(glMultiTexCoord2f,vFuff)
-GO(glMultiTexCoord2fv,vFup)
-GO(glMultiTexCoord2i,vFuii)
-GO(glMultiTexCoord2iv,vFup)
-GO(glMultiTexCoord2s,vFuii)
-GO(glMultiTexCoord2sv,vFup)
-GO(glMultiTexCoord3d,vFuddd)
-GO(glMultiTexCoord3dv,vFup)
-GO(glMultiTexCoord3f,vFufff)
-GO(glMultiTexCoord3fv,vFup)
-GO(glMultiTexCoord3i,vFuiii)
-GO(glMultiTexCoord3iv,vFup)
-GO(glMultiTexCoord3s,vFuiii)
-GO(glMultiTexCoord3sv,vFup)
-GO(glMultiTexCoord4d,vFudddd)
-GO(glMultiTexCoord4dv,vFup)
-GO(glMultiTexCoord4f,vFuffff)
-GO(glMultiTexCoord4fv,vFup)
-GO(glMultiTexCoord4i,vFuiiii)
-GO(glMultiTexCoord4iv,vFup)
-GO(glMultiTexCoord4s,vFuiiii)
-GO(glMultiTexCoord4sv,vFup)
-GO(glSampleCoverage,vFfi)
-//VERSION_1_4
-GO(glBlendFuncSeparate,vFuuuu)
-GO(glFogCoordPointer,vFuip)
-GO(glFogCoordd,vFd)
-GO(glFogCoorddv,vFp)
-GO(glFogCoordf,vFf)
-GO(glFogCoordfv,vFp)
-GO(glMultiDrawArrays,vFuppi)
-GO(glMultiDrawElements,vFupupi)
-GO(glPointParameterf,vFuf)
-GO(glPointParameterfv,vFup)
-GO(glPointParameteri,vFui)
-GO(glPointParameteriv,vFup)
-GO(glSecondaryColor3b,vFiii)
-GO(glSecondaryColor3bv,vFp)
-GO(glSecondaryColor3d,vFddd)
-GO(glSecondaryColor3dv,vFp)
-GO(glSecondaryColor3f,vFfff)
-GO(glSecondaryColor3fv,vFp)
-GO(glSecondaryColor3i,vFiii)
-GO(glSecondaryColor3iv,vFp)
-GO(glSecondaryColor3s,vFiii)
-GO(glSecondaryColor3sv,vFp)
-GO(glSecondaryColor3ub,vFuuu)
-GO(glSecondaryColor3ubv,vFp)
-GO(glSecondaryColor3ui,vFuuu)
-GO(glSecondaryColor3uiv,vFp)
-GO(glSecondaryColor3us,vFuuu)
-GO(glSecondaryColor3usv,vFp)
-GO(glSecondaryColorPointer,vFiuip)
-GO(glWindowPos2d,vFdd)
-GO(glWindowPos2dv,vFp)
-GO(glWindowPos2f,vFff)
-GO(glWindowPos2fv,vFp)
-GO(glWindowPos2i,vFii)
-GO(glWindowPos2iv,vFp)
-GO(glWindowPos2s,vFii)
-GO(glWindowPos2sv,vFp)
-GO(glWindowPos3d,vFddd)
-GO(glWindowPos3dv,vFp)
-GO(glWindowPos3f,vFfff)
-GO(glWindowPos3fv,vFp)
-GO(glWindowPos3i,vFiii)
-GO(glWindowPos3iv,vFp)
-GO(glWindowPos3s,vFiii)
-GO(glWindowPos3sv,vFp)
-//VERSION_1_5
-GO(glBeginQuery,vFuu)
-GO(glBindBuffer,vFuu)
-GO(glBufferData,vFuipu)
-GO(glBufferSubData,vFuiip)
-GO(glDeleteBuffers,vFip)
-GO(glDeleteQueries,vFip)
-GO(glEndQuery,vFu)
-GO(glGenBuffers,vFip)
-GO(glGenQueries,vFip)
-GO(glGetBufferParameteriv,vFuup)
-GO(glGetBufferPointerv,vFuup)
-GO(glGetBufferSubData,vFuiip)
-GO(glGetQueryObjectiv,vFuup)
-GO(glGetQueryObjectuiv,vFuup)
-GO(glGetQueryiv,vFuup)
-GO(glIsBuffer,iFu)
-GO(glIsQuery,iFu)
-GO(glMapBuffer,pFuu)
-GO(glUnmapBuffer,iFu)
-//VERSION_2_0
-GO(glAttachShader,vFuu)
-GO(glBindAttribLocation,vFuup)
-GO(glBlendEquationSeparate,vFuu)
-GO(glCompileShader,vFu)
-GO(glCreateProgram,uFv)
-GO(glCreateShader,uFu)
-GO(glDeleteProgram,vFu)
-GO(glDeleteShader,vFu)
-GO(glDetachShader,vFuu)
-GO(glDisableVertexAttribArray,vFu)
-GO(glDrawBuffers,vFip)
-GO(glEnableVertexAttribArray,vFu)
-GO(glGetActiveAttrib,vFuuipppp)
-GO(glGetActiveUniform,vFuuipppp)
-GO(glGetAttachedShaders,vFuipp)
-GO(glGetAttribLocation,iFup)
-GO(glGetProgramInfoLog,vFuipp)
-GO(glGetProgramiv,vFuup)
-GO(glGetShaderInfoLog,vFuipp)
-GO(glGetShaderSource,vFuipp)
-GO(glGetShaderiv,vFuup)
-GO(glGetUniformLocation,iFup)
-GO(glGetUniformfv,vFuip)
-GO(glGetUniformiv,vFuip)
-GO(glGetVertexAttribPointerv,vFuup)
-GO(glGetVertexAttribdv,vFuup)
-GO(glGetVertexAttribfv,vFuup)
-GO(glGetVertexAttribiv,vFuup)
-GO(glIsProgram,iFu)
-GO(glIsShader,iFu)
-GO(glLinkProgram,vFu)
-GO(glShaderSource,vFuipp)
-GO(glStencilFuncSeparate,vFuuiu)
-GO(glStencilMaskSeparate,vFuu)
-GO(glStencilOpSeparate,vFuuuu)
-GO(glUniform1f,vFif)
-GO(glUniform1fv,vFiip)
-GO(glUniform1i,vFii)
-GO(glUniform1iv,vFiip)
-GO(glUniform2f,vFiff)
-GO(glUniform2fv,vFiip)
-GO(glUniform2i,vFiii)
-GO(glUniform2iv,vFiip)
-GO(glUniform3f,vFifff)
-GO(glUniform3fv,vFiip)
-GO(glUniform3i,vFiiii)
-GO(glUniform3iv,vFiip)
-GO(glUniform4f,vFiffff)
-GO(glUniform4fv,vFiip)
-GO(glUniform4i,vFiiiii)
-GO(glUniform4iv,vFiip)
-GO(glUniformMatrix2fv,vFiiip)
-GO(glUniformMatrix3fv,vFiiip)
-GO(glUniformMatrix4fv,vFiiip)
-GO(glUseProgram,vFu)
-GO(glValidateProgram,vFu)
-GO(glVertexAttrib1d,vFud)
-GO(glVertexAttrib1dv,vFup)
-GO(glVertexAttrib1f,vFuf)
-GO(glVertexAttrib1fv,vFup)
-GO(glVertexAttrib1s,vFui)
-GO(glVertexAttrib1sv,vFup)
-GO(glVertexAttrib2d,vFudd)
-GO(glVertexAttrib2dv,vFup)
-GO(glVertexAttrib2f,vFuff)
-GO(glVertexAttrib2fv,vFup)
-GO(glVertexAttrib2s,vFuii)
-GO(glVertexAttrib2sv,vFup)
-GO(glVertexAttrib3d,vFuddd)
-GO(glVertexAttrib3dv,vFup)
-GO(glVertexAttrib3f,vFufff)
-GO(glVertexAttrib3fv,vFup)
-GO(glVertexAttrib3s,vFuiii)
-GO(glVertexAttrib3sv,vFup)
-GO(glVertexAttrib4Nbv,vFup)
-GO(glVertexAttrib4Niv,vFup)
-GO(glVertexAttrib4Nsv,vFup)
-GO(glVertexAttrib4Nub,vFuuuuu)
-GO(glVertexAttrib4Nubv,vFup)
-GO(glVertexAttrib4Nuiv,vFup)
-GO(glVertexAttrib4Nusv,vFup)
-GO(glVertexAttrib4bv,vFup)
-GO(glVertexAttrib4d,vFudddd)
-GO(glVertexAttrib4dv,vFup)
-GO(glVertexAttrib4f,vFuffff)
-GO(glVertexAttrib4fv,vFup)
-GO(glVertexAttrib4iv,vFup)
-GO(glVertexAttrib4s,vFuiiii)
-GO(glVertexAttrib4sv,vFup)
-GO(glVertexAttrib4ubv,vFup)
-GO(glVertexAttrib4uiv,vFup)
-GO(glVertexAttrib4usv,vFup)
-GO(glVertexAttribPointer,vFuiuiip)
-//VERSION_2_1
-GO(glUniformMatrix2x3fv,vFiiip)
-GO(glUniformMatrix2x4fv,vFiiip)
-GO(glUniformMatrix3x2fv,vFiiip)
-GO(glUniformMatrix3x4fv,vFiiip)
-GO(glUniformMatrix4x2fv,vFiiip)
-GO(glUniformMatrix4x3fv,vFiiip)
-//VERSION_3_0
-GO(glBeginConditionalRender,vFuu)
-GO(glBeginTransformFeedback,vFu)
-GO(glBindBufferBase,vFuuu)
-GO(glBindBufferRange,vFuuuii)
-GO(glBindFragDataLocation,vFuup)
-GO(glClampColor,vFuu)
-GO(glClearBufferfi,vFuifi)
-GO(glClearBufferfv,vFuip)
-GO(glClearBufferiv,vFuip)
-GO(glClearBufferuiv,vFuip)
-GO(glColorMaski,vFuiiii)
-GO(glDisablei,vFuu)
-GO(glEnablei,vFuu)
-GO(glEndConditionalRender,vFv)
-GO(glEndTransformFeedback,vFv)
-GO(glGetBooleani_v,vFuup)
-GO(glGetFragDataLocation,iFup)
-GO(glGetIntegeri_v,vFuup)
-GO(glGetStringi,pFuu)
-GO(glGetTexParameterIiv,vFuup)
-GO(glGetTexParameterIuiv,vFuup)
-GO(glGetTransformFeedbackVarying,vFuuipppp)
-GO(glGetUniformuiv,vFuip)
-GO(glGetVertexAttribIiv,vFuup)
-GO(glGetVertexAttribIuiv,vFuup)
-GO(glIsEnabledi,iFuu)
-GO(glTexParameterIiv,vFuup)
-GO(glTexParameterIuiv,vFuup)
-GO(glTransformFeedbackVaryings,vFuipu)
-GO(glUniform1ui,vFiu)
-GO(glUniform1uiv,vFiip)
-GO(glUniform2ui,vFiuu)
-GO(glUniform2uiv,vFiip)
-GO(glUniform3ui,vFiuuu)
-GO(glUniform3uiv,vFiip)
-GO(glUniform4ui,vFiuuuu)
-GO(glUniform4uiv,vFiip)
-GO(glVertexAttribI1i,vFui)
-GO(glVertexAttribI1iv,vFup)
-GO(glVertexAttribI1ui,vFuu)
-GO(glVertexAttribI1uiv,vFup)
-GO(glVertexAttribI2i,vFuii)
-GO(glVertexAttribI2iv,vFup)
-GO(glVertexAttribI2ui,vFuuu)
-GO(glVertexAttribI2uiv,vFup)
-GO(glVertexAttribI3i,vFuiii)
-GO(glVertexAttribI3iv,vFup)
-GO(glVertexAttribI3ui,vFuuuu)
-GO(glVertexAttribI3uiv,vFup)
-GO(glVertexAttribI4bv,vFup)
-GO(glVertexAttribI4i,vFuiiii)
-GO(glVertexAttribI4iv,vFup)
-GO(glVertexAttribI4sv,vFup)
-GO(glVertexAttribI4ubv,vFup)
-GO(glVertexAttribI4ui,vFuuuuu)
-GO(glVertexAttribI4uiv,vFup)
-GO(glVertexAttribI4usv,vFup)
-GO(glVertexAttribIPointer,vFuiuip)
-//VERSION_3_1
-GO(glDrawArraysInstanced,vFuiii)
-GO(glDrawElementsInstanced,vFuiupi)
-GO(glPrimitiveRestartIndex,vFu)
-GO(glTexBuffer,vFuuu)
-//VERSION_3_2
-GO(glFramebufferTexture,vFuuui)
-GO(glGetBufferParameteri64v,vFuup)
-GO(glGetInteger64i_v,vFuup)
-//VERSION_3_3
-GO(glVertexAttribDivisor,vFuu)
-//VERSION_4_0
-GO(glBlendEquationSeparatei,vFuuu)
-GO(glBlendEquationi,vFuu)
-GO(glBlendFuncSeparatei,vFuuuuu)
-GO(glBlendFunci,vFuuu)
-GO(glMinSampleShading,vFf)
-//VERSION_4_3
-GO(glInvalidateNamedFramebuffer, vFiup)
-//VERSION_4_4
-GO(glBindBuffersBase, vFiuip)
-GO(glBindBuffersRange, vFiuippp)
-GO(glBindImageTextures, vFuip)
-GO(glBindSamplers, vFuip)
-GO(glBindTextures, vFuip)
-GO(glBindVertexBuffers, vFuippp)
-GO(glBufferStorage, vFiupu)
-GO(glClearTexImage, vFuiiip)
-GO(glClearTexSubImage, vFuiiiiiiiiip)
-//VERSION_4_5
-GO(glClipControl, vFii)
-GO(glCreateTransformFeedbacks, vFlp)
-GO(glTransformFeedbackBufferBase, vFuuu)
-GO(glTransformFeedbackBufferRange, vFuuull)
-GO(glGetTransformFeedbackiv, vFuip)
-GO(glGetTransformFeedbacki_v, vFuiup)
-GO(glGetTransformFeedbacki64_v, vFuiup)
-GO(glCreateBuffers, vFlp)
-GO(glNamedBufferStorage, vFulpu)
-GO(glNamedBufferStorageEXT, vFulpu)
-GO(glNamedBufferData, vFulpi)
-GO(glNamedBufferSubData, vFullp)
-GO(glCopyNamedBufferSubData, vFuulll)
-GO(glClearNamedBufferData, vFuiiip)
-GO(glClearNamedBufferSubData, vFuilliip)
-GO(glMapNamedBuffer, pFui)
-GO(glMapNamedBufferRange, pFullu)
-GO(glUnmapNamedBuffer, iFu)
-GO(glFlushMappedNamedBufferRange, vFull)
-GO(glGetNamedBufferParameteriv, vFuip)
-GO(glGetNamedBufferParameteri64v, vFuip)
-GO(glGetNamedBufferPointerv, vFuip)
-GO(glGetNamedBufferSubData, vFullp)
-GO(glCreateFramebuffers, vFlp)
-GO(glNamedFramebufferRenderbuffer, vFuiiu)
-GO(glNamedFramebufferParameteri, vFuii)
-GO(glNamedFramebufferTexture, vFuiui)
-GO(glNamedFramebufferTextureLayer, vFuiuii)
-GO(glNamedFramebufferDrawBuffer, vFui)
-GO(glNamedFramebufferDrawBuffers, vFulp)
-GO(glNamedFramebufferReadBuffer, vFui)
-GO(glInvalidateNamedFramebufferData, vFulp)
-GO(glInvalidateNamedFramebufferSubData, vFulpiill)
-GO(glClearNamedFramebufferiv, vFuiip)
-GO(glClearNamedFramebufferuiv, vFuiip)
-GO(glClearNamedFramebufferfv, vFuiip)
-GO(glClearNamedFramebufferfi, vFuiifi)
-GO(glBlitNamedFramebuffer, vFuuiiiiiiiiui)
-GO(glCheckNamedFramebufferStatus, iFui)
-GO(glGetNamedFramebufferParameteriv, vFuip)
-GO(glGetNamedFramebufferAttachmentParameteriv, vFuiip)
-GO(glCreateRenderbuffers, vFlp)
-GO(glNamedRenderbufferStorage, vFuill)
-GO(glNamedRenderbufferStorageMultisample, vFulill)
-GO(glGetNamedRenderbufferParameteriv, vFuip)
-GO(glCreateTextures, vFilp)
-GO(glTextureBuffer, vFuiu)
-GO(glTextureBufferRange, vFuiull)
-GO(glTextureStorage1D, vFulil)
-GO(glTextureStorage2D, vFulill)
-GO(glTextureStorage3D, vFulilll)
-GO(glTextureStorage2DMultisample, vFulilli)
-GO(glTextureStorage3DMultisample, vFulillli)
-GO(glTextureSubImage1D, vFuiiliip)
-GO(glTextureSubImage2D, vFuiiilliip)
-GO(glTextureSubImage3D, vFuiiiillliip)
-GO(glCompressedTextureSubImage1D, vFuiililp)
-GO(glCompressedTextureSubImage2D, vFuiiillilp)
-GO(glCompressedTextureSubImage3D, vFuiiiilllilp)
-GO(glCopyTextureSubImage1D, vFuiiiil)
-GO(glCopyTextureSubImage2D, vFuiiiiill)
-GO(glCopyTextureSubImage3D, vFuiiiiiiill)
-GO(glTextureParameterf, vFuif)
-GO(glTextureParameterfv, vFuip)
-GO(glTextureParameteri, vFuii)
-GO(glTextureParameterIiv, vFuip)
-GO(glTextureParameterIuiv, vFuip)
-GO(glTextureParameteriv, vFuip)
-GO(glGenerateTextureMipmap, vFu)
-GO(glBindTextureUnit, vFuu)
-GO(glGetTextureImage, vFuiiilp)
-GO(glGetCompressedTextureImage, vFuilp)
-GO(glGetTextureLevelParameterfv, vFuiip)
-GO(glGetTextureLevelParameteriv, vFuiip)
-GO(glGetTextureParameterfv, vFuip)
-GO(glGetTextureParameterIiv, vFuip)
-GO(glGetTextureParameterIuiv, vFuip)
-GO(glGetTextureParameteriv, vFuip)
-GO(glCreateVertexArrays, vFlp)
-GO(glDisableVertexArrayAttrib, vFuu)
-GO(glEnableVertexArrayAttrib, vFuu)
-GO(glVertexArrayElementBuffer, vFuu)
-GO(glVertexArrayVertexBuffer, vFuuull)
-GO(glVertexArrayVertexBuffers, vFuulppp)
-GO(glVertexArrayAttribBinding, vFuuu)
-GO(glVertexArrayAttribFormat, vFuuiiiu)
-GO(glVertexArrayAttribIFormat, vFuuiiu)
-GO(glVertexArrayAttribLFormat, vFuuiiu)
-GO(glVertexArrayBindingDivisor, vFuuu)
-GO(glGetVertexArrayiv, vFuip)
-GO(glGetVertexArrayIndexediv, vFuuip)
-GO(glGetVertexArrayIndexed64iv, vFuuip)
-GO(glCreateSamplers, vFlp)
-GO(glCreateProgramPipelines, vFip)
-GO(glTextureBarrier, vFv)
-GO(glTextureParameteriiv, vFuip)
-GO(glTextureParameteriuiv, vFuip)
-GO(glCreateQueries, vFilp)
-GO(glGetQueryBufferObjecti64v, vFuuil)
-GO(glGetQueryBufferObjectiv, vFuuil)
-GO(glGetQueryBufferObjectui64v, vFuuil)
-GO(glGetQueryBufferObjectuiv, vFuuil)
-GO(glMemoryBarrierByRegion, vFu)
-GO(glGetTextureSubImage, vFuiiiillliilp)
-GO(glGetCompressedTextureSubImage, vFuiiiillllp)
-GO(glGetGraphicsResetStatus, iFv)
-//VERSION_4_6
-GO(glSpecializeShader, vFippp)
-
-GO(glTexturePageCommitmentEXT, vFuiiiillli)
-GO(glVertexArrayVertexAttribDivisorEXT, vFuuu)
+GO(glColor3fVertex3fSUN, vFffffff)
+GO(glColor3fVertex3fvSUN, vFpp)
+GO(glColor4fNormal3fVertex3fSUN, vFffffffffff)
+GO(glColor4fNormal3fVertex3fvSUN, vFppp)
+GO(glColor4ubVertex2fSUN, vFCCCCff)
+GO(glColor4ubVertex2fvSUN, vFpp)
+GO(glColor4ubVertex3fSUN, vFCCCCfff)
+GO(glColor4ubVertex3fvSUN, vFpp)
+GO(glNormal3fVertex3fSUN, vFffffff)
+GO(glNormal3fVertex3fvSUN, vFpp)
+GO(glReplacementCodeuiColor3fVertex3fSUN, vFuffffff)
+GO(glReplacementCodeuiColor3fVertex3fvSUN, vFppp)
+GO(glReplacementCodeuiColor4fNormal3fVertex3fSUN, vFuffffffffff)
+GO(glReplacementCodeuiColor4fNormal3fVertex3fvSUN, vFpppp)
+GO(glReplacementCodeuiColor4ubVertex3fSUN, vFuCCCCfff)
+GO(glReplacementCodeuiColor4ubVertex3fvSUN, vFppp)
+GO(glReplacementCodeuiNormal3fVertex3fSUN, vFuffffff)
+GO(glReplacementCodeuiNormal3fVertex3fvSUN, vFppp)
+GO(glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN, vFuffffffffffff)
+GO(glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN, vFppppp)
+GO(glReplacementCodeuiTexCoord2fNormal3fVertex3fSUN, vFuffffffff)
+GO(glReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN, vFpppp)
+GO(glReplacementCodeuiTexCoord2fVertex3fSUN, vFufffff)
+GO(glReplacementCodeuiTexCoord2fVertex3fvSUN, vFppp)
+GO(glReplacementCodeuiVertex3fSUN, vFufff)
+GO(glReplacementCodeuiVertex3fvSUN, vFpp)
+GO(glTexCoord2fColor3fVertex3fSUN, vFffffffff)
+GO(glTexCoord2fColor3fVertex3fvSUN, vFppp)
+GO(glTexCoord2fColor4fNormal3fVertex3fSUN, vFffffffffffff)
+GO(glTexCoord2fColor4fNormal3fVertex3fvSUN, vFpppp)
+GO(glTexCoord2fColor4ubVertex3fSUN, vFffCCCCfff)
+GO(glTexCoord2fColor4ubVertex3fvSUN, vFppp)
+GO(glTexCoord2fNormal3fVertex3fSUN, vFffffffff)
+GO(glTexCoord2fNormal3fVertex3fvSUN, vFppp)
+GO(glTexCoord2fVertex3fSUN, vFfffff)
+GO(glTexCoord2fVertex3fvSUN, vFpp)
+GO(glTexCoord4fColor4fNormal3fVertex4fSUN, vFfffffffffffffff)
+GO(glTexCoord4fColor4fNormal3fVertex4fvSUN, vFpppp)
+GO(glTexCoord4fVertex4fSUN, vFffffffff)
+GO(glTexCoord4fVertex4fvSUN, vFpp)
//GL_ARB_polygon_offset_clamp
GO(glPolygonOffsetClamp, vFfff)
@@ -2909,45 +2910,45 @@ GO(glRenderbufferStorageMultisampleEXT, vFilill)
GO(glFramebufferTexture2DMultisampleEXT, vFiiiuil)
//GL_KTX_buffer_region
-GO(glBufferRegionEnabled,uFv)
-GO(glNewBufferRegion,uFi)
-GO(glDeleteBufferRegion,vFi)
-GO(glReadBufferRegion,vFuiiii)
-GO(glDrawBufferRegion,vFuiiiiii)
+GO(glBufferRegionEnabled, uFv)
+GO(glNewBufferRegion, uFi)
+GO(glDeleteBufferRegion, vFi)
+GO(glReadBufferRegion, vFuiiii)
+GO(glDrawBufferRegion, vFuiiiiii)
//GL_ARB_sparse_buffer
-GO(glBufferPageCommitmentARB, vFippi)
-GO(glNamedBufferPageCommitmentARB, vFuppi)
+GO(glBufferPageCommitmentARB, vFullC)
+GO(glNamedBufferPageCommitmentARB, vFullC)
GO(glNamedBufferPageCommitmentEXT, vFuppi)
//GL_ARB_sparse_texture
GO(TexPageCommitmentARB, vFiiiiiiiii)
//glx
-GO(glXBindHyperpipeSGIX,iFpi)
+GO(glXBindHyperpipeSGIX, iFpi)
GO(glXBindTexImageEXT, vFppip)
GO(glXBindSwapBarrierNV, iFpuu)
GO(glXBindSwapBarrierSGIX,vFii)
GO(glXBindVideoCaptureDeviceNV, iFpup)
GO(glXBindVideoDeviceNV, iFpuup)
GO(glXBindVideoImageNV, iFpppi)
-GO(glXChangeDrawableAttributes,vFp)
-GO(glXChangeDrawableAttributesSGIX,vFp)
-GO(glXClientInfo,vFv)
-GO(glXCopyContext,vFppp)
+GO(glXChangeDrawableAttributes, vFp)
+GO(glXChangeDrawableAttributesSGIX, vFp)
+GO(glXClientInfo, vFv)
+GO(glXCopyContext, vFppp)
GO(glXChooseFBConfig, pFpipp)
GO(glXChooseFBConfigSGIX, pFpipp)
GO(glXCreateContext,pFpppi)
GO(glXCreateContextAttribsARB, pFpppip)
-GO(glXCreateContextWithConfigSGIX,pFppipi)
-GO(glXCreateGLXPbufferSGIX,pFppuup)
-GO(glXCreateGLXPixmap,pFppp)
-GO(glXCreateGLXPixmapWithConfigSGIX,pFppp)
-GO(glXCreateGLXVideoSourceSGIX,pFpippip)
-GO(glXCreateNewContext,pFppipi)
-GO(glXCreatePbuffer,pFppp)
-GO(glXCreatePixmap,pFppp)
-GO(glXCreateWindow,pFpppp)
+GO(glXCreateContextWithConfigSGIX, pFppipi)
+GO(glXCreateGLXPbufferSGIX, pFppuup)
+GO(glXCreateGLXPixmap, pFppp)
+GO(glXCreateGLXPixmapWithConfigSGIX, pFppp)
+GO(glXCreateGLXVideoSourceSGIX, pFpippip)
+GO(glXCreateNewContext, pFppipi)
+GO(glXCreatePbuffer, pFppp)
+GO(glXCreatePixmap, pFppp)
+GO(glXCreateWindow, pFpppp)
GO(glXChooseVisual, pFpip)
GO(glXCopyImageSubDataNV, vFppuiiiiipuiiiiiiii)
GO(glXCopySubBufferMESA, vFppiiii)
@@ -3061,15 +3062,15 @@ GO(glXAllocateMemoryNV, pFlfff)
GO(glXFreeMemoryNV, vFp)
//GLX_ARB_????
-GO(glSpecializeShaderARB, vFippp)
+GO(glSpecializeShaderARB, vFupupp)
//GL_EXT_debug_label
-GO(glGetObjectLabelEXT, vFiulpp)
-GO(glLabelObjectEXT, vFiulp)
+GO(glGetObjectLabelEXT, vFuuipp)
+GO(glLabelObjectEXT, vFuuip)
//GL_EXT_debug_marker
GO(glInsertEventMarkerEXT, vFlp)
-GO(glPushGroupMarkerEXT, vFlp)
+GO(glPushGroupMarkerEXT, vFip)
GO(glPopGroupMarkerEXT, vFv)
//GL_KHR_blend_equation_advanced
@@ -3077,7 +3078,7 @@ GO(glBlendBarrierKHR, vFv)
//Some various other extension
GO(glResolveMultisampleFramebufferAPPLE, vFv)
-GO(glTexPageCommitmentARB, vFiiiiillli)
+GO(glTexPageCommitmentARB, vFuiiiiiiiC)
//GL_ARB_sample_locations
GO(glFramebufferSampleLocationsfvARB, vFiulp)
@@ -3088,42 +3089,42 @@ GO(glEvaluateDepthValuesARB, vFv)
GO(glMaxShaderCompilerThreadsARB, vFu)
//GL_ARB_indirect_parameters
-GO(glMultiDrawArraysIndirectCountARB, vFiplll)
-GO(glMultiDrawElementsIndirectCountARB, vFiiplll)
+GO(glMultiDrawArraysIndirectCountARB, vFuplii)
+GO(glMultiDrawElementsIndirectCountARB, vFuuplii)
//GL_ARB_gpu_shader_int64
-GO(glUniform1i64ARB, vFiI)
-GO(glUniform2i64ARB, vFiII)
-GO(glUniform3i64ARB, vFiIII)
-GO(glUniform4i64ARB, vFiIIII)
+GO(glUniform1i64ARB, vFil)
+GO(glUniform2i64ARB, vFill)
+GO(glUniform3i64ARB, vFilll)
+GO(glUniform4i64ARB, vFillll)
GO(glUniform1i64vARB, vFilp)
GO(glUniform2i64vARB,vFilp)
GO(glUniform3i64vARB,vFilp)
-GO(glUniform4i64vARB,vFilp)
+GO(glUniform4i64vARB, vFiip)
GO(glUniform1ui64ARB,vFiU)
-GO(glUniform2ui64ARB,vFiUU)
-GO(glUniform3ui64ARB, vFiUUU)
-GO(glUniform4ui64ARB, vFiUUUU)
+GO(glUniform2ui64ARB, vFiLL)
+GO(glUniform3ui64ARB, vFiLLL)
+GO(glUniform4ui64ARB, vFiLLLL)
GO(glUniform1ui64vARB, vFilp)
GO(glUniform2ui64vARB, vFilp)
GO(glUniform3ui64vARB, vFilp)
GO(glUniform4ui64vARB, vFilp)
GO(glGetUniformi64vARB, vFuip)
GO(glGetUniformui64vARB, vFuip)
-GO(glGetnUniformi64vARB, vFuilp)
-GO(glGetnUniformui64vARB, vFuilp)
-GO(glProgramUniform1i64ARB, vFuiI)
-GO(glProgramUniform2i64ARB, vFuiII)
-GO(glProgramUniform3i64ARB, vFuiIII)
-GO(glProgramUniform4i64ARB, vFuiIIII)
+GO(glGetnUniformi64vARB, vFuiip)
+GO(glGetnUniformui64vARB, vFuiip)
+GO(glProgramUniform1i64ARB, vFuil)
+GO(glProgramUniform2i64ARB, vFuill)
+GO(glProgramUniform3i64ARB, vFuilll)
+GO(glProgramUniform4i64ARB, vFuillll)
GO(glProgramUniform1i64vARB, vFuilp)
GO(glProgramUniform2i64vARB, vFuilp)
GO(glProgramUniform3i64vARB, vFuilp)
-GO(glProgramUniform4i64vARB, vFuilp)
+GO(glProgramUniform4i64vARB, vFuiip)
GO(glProgramUniform1ui64ARB, vFuiU)
-GO(glProgramUniform2ui64ARB, vFuiUU)
-GO(glProgramUniform3ui64ARB, vFuiUUU)
-GO(glProgramUniform4ui64ARB, vFuiUUUU)
+GO(glProgramUniform2ui64ARB, vFuiLL)
+GO(glProgramUniform3ui64ARB, vFuiLLL)
+GO(glProgramUniform4ui64ARB, vFuiLLLL)
GO(glProgramUniform1ui64vARB, vFuilp)
GO(glProgramUniform2ui64vARB, vFuilp)
GO(glProgramUniform3ui64vARB, vFuilp)
@@ -3155,23 +3156,23 @@ GO(glGetVertexAttribLui64vARB, vFuip)
//GL_OES_EGL_image
GO(glEGLImageTargetTexture2DOES, vFip)
-GO(glEGLImageTargetRenderbufferStorageOES, vFip)
+GO(glEGLImageTargetRenderbufferStorageOES, vFup)
//GL_MESA_program_debug
GOM(glProgramCallbackMESA, vFEipp)
GO(glGetProgramRegisterfvMESA, vFilpp)
//GL_????_ATI
-GO(glBlendEquationSeparateATI, vFii)
+GO(glBlendEquationSeparateATI, vFuu)
//GL_AMD_interleaved_elements
GO(glVertexAttribParameteriAMD, vFuii)
//GL_AMD_occlusion_query_event
-GO(glQueryObjectParameteruiAMD, vFiuiu)
+GO(glQueryObjectParameteruiAMD, vFuuuu)
//GL_EXT_raster_multisample
-GO(glRasterSamplesEXT, vFui)
+GO(glRasterSamplesEXT, vFuC)
//GL_INTEL_performance_query
GO(glBeginPerfQueryINTEL, vFu)
@@ -3181,17 +3182,17 @@ GO(glEndPerfQueryINTEL, vFu)
GO(glGetFirstPerfQueryIdINTEL, vFp)
GO(glGetNextPerfQueryIdINTEL, vFup)
GO(glGetPerfCounterInfoINTEL, vFuuupupppppp)
-GO(glGetPerfQueryDataINTEL, vFuulpp)
+GO(glGetPerfQueryDataINTEL, vFuuipp)
GO(glGetPerfQueryIdByNameINTEL, vFpp)
GO(glGetPerfQueryInfoINTEL, vFuuppppp)
//GL_NV_bindless_multi_draw_indirect
-GO(glMultiDrawArraysIndirectBindlessNV, vFiplli)
-GO(glMultiDrawElementsIndirectBindlessNV, vFiiplli)
+GO(glMultiDrawArraysIndirectBindlessNV, vFupiii)
+GO(glMultiDrawElementsIndirectBindlessNV, vFuupiii)
//GL_NV_bindless_multi_draw_indirect_count
-GO(glMultiDrawArraysIndirectBindlessCountNV, vFipllli)
-GO(glMultiDrawElementsIndirectBindlessCountNV, vFiipllli)
+GO(glMultiDrawArraysIndirectBindlessCountNV, vFupiiii)
+GO(glMultiDrawElementsIndirectBindlessCountNV, vFuupiiii)
//GL_NV_blend_equation_advanced
GO(glBlendParameteriNV, vFii)
@@ -3202,10 +3203,10 @@ GO(glCreateStatesNV, vFlp)
GO(glDeleteStatesNV, vFlp)
GO(glIsStateNV, iFu)
GO(glStateCaptureNV, vFui)
-GO(glGetCommandHeaderNV, uFiu)
-GO(glGetStageIndexNV, WFi)
-GO(glDrawCommandsNV, vFiuppu)
-GO(glDrawCommandsAddressNV, vFippu)
+GO(glGetCommandHeaderNV, uFuu)
+GO(glGetStageIndexNV, WFu)
+GO(glDrawCommandsNV, vFuuppu)
+GO(glDrawCommandsAddressNV, vFuppu)
GO(glDrawCommandsStatesNV, vFuppppu)
GO(glDrawCommandsStatesAddressNV, vFppppu)
GO(glCreateCommandListsNV, vFlp)
@@ -3224,24 +3225,24 @@ GO(glFragmentCoverageColorNV, vFu)
//GL_NV_framebuffer_mixed_samples
GO(glCoverageModulationTableNV, vFlp)
-GO(glGetCoverageModulationTableNV, vFlp)
+GO(glGetCoverageModulationTableNV, vFip)
GO(glCoverageModulationNV, vFi)
//GL_NV_internalformat_sample_query
-GO(glGetInternalformatSampleivNV, vFiililp)
+GO(glGetInternalformatSampleivNV, vFuuiuip)
//GL_NV_path_rendering
GO(glGenPathsNV, uFl)
GO(glDeletePathsNV, vFul)
GO(glIsPathNV, iFu)
-GO(glPathCommandsNV, vFulplup)
-GO(glPathCoordsNV, vFulip)
-GO(glPathSubCommandsNV, vFulllplip)
-GO(glPathSubCoordsNV, vFullip)
-GO(glPathStringNV, vFuilp)
-GO(glPathGlyphsNV, vFuipulipiuf)
-GO(glPathGlyphRangeNV, vFuipuliuf)
-GO(glWeightPathsNV, vFulpp)
+GO(glPathCommandsNV, vFuipiup)
+GO(glPathCoordsNV, vFuiup)
+GO(glPathSubCommandsNV, vFuiiipiup)
+GO(glPathSubCoordsNV, vFuiiup)
+GO(glPathStringNV, vFuuip)
+GO(glPathGlyphsNV, vFuupuiupuuf)
+GO(glPathGlyphRangeNV, vFuupuuiuuf)
+GO(glWeightPathsNV, vFuipp)
GO(glCopyPathNV, vFuu)
GO(glInterpolatePathsNV, vFuuuf)
GO(glTransformPathNV, vFuuip)
@@ -3250,46 +3251,46 @@ GO(glPathParameteriNV, vFuii)
GO(glPathParameterfvNV, vFuip)
GO(glPathParameterfNV, vFuif)
GO(glPathDashArrayNV, vFulp)
-GO(glPathStencilFuncNV, vFiiu)
+GO(glPathStencilFuncNV, vFuiu)
GO(glPathStencilDepthOffsetNV, vFff)
-GO(glStencilFillPathNV, vFuiu)
+GO(glStencilFillPathNV, vFuuu)
GO(glStencilStrokePathNV, vFuiu)
-GO(glStencilFillPathInstancedNV, vFlipuiuip)
-GO(glStencilStrokePathInstancedNV, vFlipuiuip)
+GO(glStencilFillPathInstancedNV, vFiupuuuup)
+GO(glStencilStrokePathInstancedNV, vFiupuiuup)
GO(glPathCoverDepthFuncNV, vFi)
GO(glCoverFillPathNV, vFui)
GO(glCoverStrokePathNV, vFui)
GO(glCoverFillPathInstancedNV, vFlipuiip)
-GO(glCoverStrokePathInstancedNV, vFlipuiip)
+GO(glCoverStrokePathInstancedNV, vFiupuuup)
GO(glGetPathParameterivNV, vFuip)
GO(glGetPathParameterfvNV, vFuip)
GO(glGetPathCommandsNV, vFup)
GO(glGetPathCoordsNV, vFup)
GO(glGetPathDashArrayNV, vFup)
-GO(glGetPathMetricsNV, vFulipulp)
-GO(glGetPathMetricRangeNV, vFuullp)
-GO(glGetPathSpacingNV, vFilipufip)
-GO(glIsPointInFillPathNV, iFuuff)
-GO(glIsPointInStrokePathNV, iFuff)
-GO(glGetPathLengthNV, fFull)
-GO(glPointAlongPathNV, iFullfpppp)
+GO(glGetPathMetricsNV, vFuiupuip)
+GO(glGetPathMetricRangeNV, vFuuiip)
+GO(glGetPathSpacingNV, vFuiupuffup)
+GO(glIsPointInFillPathNV, CFuuff)
+GO(glIsPointInStrokePathNV, CFuff)
+GO(glGetPathLengthNV, fFuii)
+GO(glPointAlongPathNV, CFuiifpppp)
GO(glMatrixLoad3x2fNV, vFip)
GO(glMatrixLoad3x3fNV, vFip)
GO(glMatrixLoadTranspose3x3fNV, vFip)
GO(glMatrixMult3x2fNV, vFip)
GO(glMatrixMult3x3fNV, vFip)
GO(glMatrixMultTranspose3x3fNV, vFip)
-GO(glStencilThenCoverFillPathNV, vFuiui)
-GO(glStencilThenCoverStrokePathNV, vFuiui)
-GO(glStencilThenCoverFillPathInstancedNV, vFlipuiuiip)
-GO(glStencilThenCoverStrokePathInstancedNV, vFlipuiuiip)
-GO(glPathGlyphIndexRangeNV, iFipuufp)
-GO(glPathGlyphIndexArrayNV, iFuipuuluf)
-GO(glPathMemoryGlyphIndexArrayNV, iFuilpluluf)
-GO(glProgramPathFragmentInputGenNV, vFuiiip)
-GO(glGetProgramResourcefvNV, vFuiulplpp)
-GO(glPathColorGenNV, vFiiip)
-GO(glPathTexGenNV, vFiiip)
+GO(glStencilThenCoverFillPathNV, vFuuuu)
+GO(glStencilThenCoverStrokePathNV, vFuiuu)
+GO(glStencilThenCoverFillPathInstancedNV, vFiupuuuuup)
+GO(glStencilThenCoverStrokePathInstancedNV, vFiupuiuuup)
+GO(glPathGlyphIndexRangeNV, uFupuufp)
+GO(glPathGlyphIndexArrayNV, uFuupuuiuf)
+GO(glPathMemoryGlyphIndexArrayNV, uFuulpiuiuf)
+GO(glProgramPathFragmentInputGenNV, vFuiuip)
+GO(glGetProgramResourcefvNV, vFuuuipipp)
+GO(glPathColorGenNV, vFuuup)
+GO(glPathTexGenNV, vFuuip)
GO(glPathFogGenNV, vFi)
GO(glGetPathColorGenivNV, vFiip)
GO(glGetPathColorGenfvNV, vFiip)
@@ -3298,7 +3299,7 @@ GO(glGetPathTexGenfvNV, vFiip)
//GL_NV_sample_locations
GO(glFramebufferSampleLocationsfvNV, vFiulp)
-GO(glNamedFramebufferSampleLocationsfvNV, vFuulp)
+GO(glNamedFramebufferSampleLocationsfvNV, vFuuip)
GO(glResolveDepthValuesNV, vFv)
//GL_KHR_robustness
@@ -3408,40 +3409,40 @@ GO(glGetClipPlanef,vFup)
GO(glOrthof,vFffffff)
// GL_EXT_window_rectangles
-GO(glWindowRectanglesEXT, vFilp)
+GO(glWindowRectanglesEXT, vFuip)
// GL_EXT_memory_object
-GO(glGetUnsignedBytevEXT, vFip)
-GO(glGetUnsignedBytei_vEXT, vFiup)
+GO(glGetUnsignedBytevEXT, vFup)
+GO(glGetUnsignedBytei_vEXT, vFuup)
GO(glDeleteMemoryObjectsEXT, vFlp)
GO(glIsMemoryObjectEXT, iFu)
GO(glCreateMemoryObjectsEXT, vFlp)
GO(glMemoryObjectParameterivEXT, vFuip)
GO(glGetMemoryObjectParameterivEXT, vFuip)
-GO(glTexStorageMem2DEXT, vFililluU)
-GO(glTexStorageMem2DMultisampleEXT, vFililliuU)
-GO(glTexStorageMem3DEXT, vFilillluU)
-GO(glTexStorageMem3DMultisampleEXT, vFilillliuU)
-GO(glBufferStorageMemEXT, vFiluU)
-GO(glTextureStorageMem2DEXT, vFulilluU)
-GO(glTextureStorageMem2DMultisampleEXT, vFulilliuU)
-GO(glTextureStorageMem3DEXT, vFulillluU)
-GO(glTextureStorageMem3DMultisampleEXT, vFulillliuU)
-GO(glNamedBufferStorageMemEXT, vFuluU)
-GO(glTexStorageMem1DEXT, vFililuU)
-GO(glTextureStorageMem1DEXT, vFuliluU)
+GO(glTexStorageMem2DEXT, vFuiuiiuL)
+GO(glTexStorageMem2DMultisampleEXT, vFuiuiiCuL)
+GO(glTexStorageMem3DEXT, vFuiuiiiuL)
+GO(glTexStorageMem3DMultisampleEXT, vFuiuiiiCuL)
+GO(glBufferStorageMemEXT, vFuluL)
+GO(glTextureStorageMem2DEXT, vFuiuiiuL)
+GO(glTextureStorageMem2DMultisampleEXT, vFuiuiiCuL)
+GO(glTextureStorageMem3DEXT, vFuiuiiiuL)
+GO(glTextureStorageMem3DMultisampleEXT, vFuiuiiiCuL)
+GO(glNamedBufferStorageMemEXT, vFuluL)
+GO(glTexStorageMem1DEXT, vFuiuiuL)
+GO(glTextureStorageMem1DEXT, vFuiuiuL)
// GL_EXT_semaphore
GO(glGenSemaphoresEXT, vFlp)
GO(glDeleteSemaphoresEXT, vFlp)
GO(glIsSemaphoreEXT, iFu)
-GO(glSemaphoreParameterui64vEXT, vFuip)
+GO(glSemaphoreParameterui64vEXT, vFuup)
GO(glGetSemaphoreParameterui64vEXT, vFuip)
GO(glWaitSemaphoreEXT, vFuupupp)
GO(glSignalSemaphoreEXT, vFuupupp)
// GL_EXT_memory_object_fd
-GO(glImportMemoryFdEXT, vFuUii)
+GO(glImportMemoryFdEXT, vFuLui)
// GL_KHR_parallel_shader_compile
GO(glMaxShaderCompilerThreadsKHR, vFu)
@@ -3465,27 +3466,27 @@ GO(glRenderbufferStorageMultisampleIMG, vFilill)
GO(glGetTranslatedShaderSourceANGLE, vFulpp)
// GL_EXT_EGL_image_storage
-GO(glEGLImageTargetTexStorageEXT, vFipp)
+GO(glEGLImageTargetTexStorageEXT, vFupp)
GO(glEGLImageTargetTextureStorageEXT, vFupp)
// GL_EXT_external_buffer
-GO(glBufferStorageExternalEXT, vFillpu)
-GO(glNamedBufferStorageExternalEXT, vFullpp)
+GO(glBufferStorageExternalEXT, vFullpu)
+GO(glNamedBufferStorageExternalEXT, vFullpu)
// GL_EXT_memory_object_win32
-GO(glImportMemoryWin32HandleEXT, vFuUip)
-GO(glImportMemoryWin32NameEXT, vFuUip)
+GO(glImportMemoryWin32HandleEXT, vFuLup)
+GO(glImportMemoryWin32NameEXT, vFuLup)
// GL_EXT_semaphore_win32
-GO(glImportSemaphoreWin32HandleEXT, vFuip)
+GO(glImportSemaphoreWin32HandleEXT, vFuup)
GO(glImportSemaphoreWin32NameEXT, vFuip)
// GL_EXT_shader_framebuffer_fetch_non_coherent
GO(glFramebufferFetchBarrierEXT, vFv)
// GL_EXT_win32_keyed_mutex
-GO(glAcquireKeyedMutexWin32EXT, iFuUu)
-GO(glReleaseKeyedMutexWin32EXT, iFuU)
+GO(glAcquireKeyedMutexWin32EXT, CFuLu)
+GO(glReleaseKeyedMutexWin32EXT, CFuL)
// GL_INTEL_framebuffer_CMAA
GO(glApplyFramebufferAttachmentCMAAINTEL, vFv)
@@ -3503,73 +3504,73 @@ GO(glConservativeRasterParameterfNV, vFif)
GO(glConservativeRasterParameteriNV, vFii)
// GL_NV_draw_vulkan_image
-GO(glDrawVkImageNV, vFUufffffffff)
+GO(glDrawVkImageNV, vFLufffffffff)
GOM(glGetVkProcAddrNV, pFEp)
GO(glWaitVkSemaphoreNV, vFU)
GO(glSignalVkSemaphoreNV, vFU)
-GO(glSignalVkFenceNV, vFU)
+GO(glSignalVkFenceNV, vFL)
// GL_NV_gpu_multicast
GO(glRenderGpuMaskNV, vFu)
GO(glMulticastBufferSubDataNV, vFuullp)
GO(glMulticastCopyBufferSubDataNV, vFuuuulll)
-GO(glMulticastCopyImageSubDataNV, vFuuuiiiiiuiiiiilll)
-GO(glMulticastBlitFramebufferNV, vFuuiiiiiiiiui)
-GO(glMulticastFramebufferSampleLocationsfvNV, vFuuulp)
+GO(glMulticastCopyImageSubDataNV, vFuuuuiiiiuuiiiiiii)
+GO(glMulticastBlitFramebufferNV, vFuuiiiiiiiiuu)
+GO(glMulticastFramebufferSampleLocationsfvNV, vFuuuip)
GO(glMulticastBarrierNV, vFv)
GO(glMulticastWaitSyncNV, vFuu)
GO(glMulticastGetQueryObjectivNV, vFuuip)
-GO(glMulticastGetQueryObjectuivNV, vFuuip)
-GO(glMulticastGetQueryObjecti64vNV, vFuuip)
-GO(glMulticastGetQueryObjectui64vNV, vFuuip)
+GO(glMulticastGetQueryObjectuivNV, vFuuup)
+GO(glMulticastGetQueryObjecti64vNV, vFuuup)
+GO(glMulticastGetQueryObjectui64vNV, vFuuup)
// GL_NV_memory_attachment
-GO(glGetMemoryObjectDetachedResourcesuivNV, vFuiilp)
+GO(glGetMemoryObjectDetachedResourcesuivNV, vFuuiip)
GO(glResetMemoryObjectParameterNV, vFui)
GO(glTexAttachMemoryNV, vFiuU)
-GO(glBufferAttachMemoryNV, vFiuU)
+GO(glBufferAttachMemoryNV, vFuuL)
GO(glTextureAttachMemoryNV, vFuuU)
-GO(glNamedBufferAttachMemoryNV, vFuuU)
+GO(glNamedBufferAttachMemoryNV, vFuuL)
// GL_NV_mesh_shader
GO(glDrawMeshTasksNV, vFuu)
GO(glDrawMeshTasksIndirectNV, vFl)
-GO(glMultiDrawMeshTasksIndirectNV, vFlll)
-GO(glMultiDrawMeshTasksIndirectCountNV, vFllll)
+GO(glMultiDrawMeshTasksIndirectNV, vFlii)
+GO(glMultiDrawMeshTasksIndirectCountNV, vFllii)
// GL_NV_query_resource
-GO(glQueryResourceNV, iFiiup)
+GO(glQueryResourceNV, iFuiup)
// GL_NV_query_resource_tag
GO(glGenQueryResourceTagNV, vFlp)
-GO(glDeleteQueryResourceTagNV, vFlp)
-GO(glQueryResourceTagNV, vFup)
+GO(glDeleteQueryResourceTagNV, vFip)
+GO(glQueryResourceTagNV, vFip)
// GL_NV_scissor_exclusive
-GO(glScissorExclusiveArrayvNV, vFulp)
-GO(glScissorExclusiveNV, vFiill)
+GO(glScissorExclusiveArrayvNV, vFuip)
+GO(glScissorExclusiveNV, vFiiii)
// GL_NV_shading_rate_image
GO(glBindShadingRateImageNV, vFu)
-GO(glShadingRateImagePaletteNV, vFuulp)
+GO(glShadingRateImagePaletteNV, vFuuip)
GO(glGetShadingRateImagePaletteNV, vFuup)
-GO(glShadingRateImageBarrierNV, vFi)
+GO(glShadingRateImageBarrierNV, vFC)
GO(glShadingRateSampleOrderNV, vFi)
-GO(glShadingRateSampleOrderCustomNV, vFiup)
-GO(glGetShadingRateSampleLocationivNV, vFiuup)
+GO(glShadingRateSampleOrderCustomNV, vFuup)
+GO(glGetShadingRateSampleLocationivNV, vFuuup)
// GL_NV_viewport_swizzle
-GO(glViewportSwizzleNV, vFuiiii)
+GO(glViewportSwizzleNV, vFuuuuu)
// GL_OVR_multiview
-GO(glFramebufferTextureMultiviewOVR, vFiiuiil)
+GO(glFramebufferTextureMultiviewOVR, vFuuuiii)
GO(glNamedFramebufferTextureMultiviewOVR, vFuiuiil)
// GL_AMD_framebuffer_sample_positions
-GO(glFramebufferSamplePositionsfvAMD, vFiuup)
+GO(glFramebufferSamplePositionsfvAMD, vFuuup)
GO(glNamedFramebufferSamplePositionsfvAMD, vFuuup)
-GO(glGetFramebufferParameterfvAMD, vFiiuulp)
-GO(glGetNamedFramebufferParameterfvAMD, vFuiuulp)
+GO(glGetFramebufferParameterfvAMD, vFuuuuip)
+GO(glGetNamedFramebufferParameterfvAMD, vFuuuuip)
// GL_ANGLE_framebuffer_blit
GO(glBlitFramebufferANGLE, vFiiiiiiiiui)
@@ -3703,9 +3704,9 @@ GO(glClearPixelLocalStorageuiEXT, vFllp)
GO(glTexPageCommitmentEXT, vFiiiiillli)
// GL_EXT_texture_storage
-GO(glTexStorage1DEXT, vFilil)
-GO(glTexStorage2DEXT, vFilill)
-GO(glTexStorage3DEXT, vFililll)
+GO(glTexStorage1DEXT, vFuiui)
+GO(glTexStorage2DEXT, vFuiuii)
+GO(glTexStorage3DEXT, vFuiuiii)
// GL_EXT_texture_view
GO(glTextureViewEXT, vFuiuiuuuu)
@@ -3980,3 +3981,26 @@ GO(wglGetSwapIntervalEXT, iFv)
// GL_MESA_framebuffer_flip_y
GO(glFramebufferParameteriMESA, vFiii)
GO(glGetFramebufferParameterivMESA, vFiip)
+
+// GL_NVX_gpu_multicast2
+GO(glUploadGpuMaskNVX, vFu)
+GO(glMulticastViewportArrayvNVX, vFuulp)
+GO(glMulticastViewportPositionWScaleNVX, vFuuff)
+GO(glMulticastScissorArrayvNVX, vFuuip)
+GO(glAsyncCopyBufferSubDataNVX, uFippuuuulllipp)
+GO(glAsyncCopyImageSubDataNVX, uFippuuuuiiiiuuiiiiiiiipp)
+
+// GL_NVX_progress_fence
+GO(glCreateProgressFenceNVX, uFv)
+GO(glSignalSemaphoreui64NVX, vFulpp)
+GO(glWaitSemaphoreui64NVX, vFuipp)
+GO(glClientWaitSemaphoreui64NVX, vFipp)
+
+// GL_NV_memory_object_sparse
+GO(glBufferPageCommitmentMemNV, vFulluLC)
+GO(glTexPageCommitmentMemNV, vFuiiiiiiiiuLC)
+GO(glNamedBufferPageCommitmentMemNV, vFulluLC)
+GO(glTexturePageCommitmentMemNV, vFuiiiiiiiiuLC)
+
+// GL_NV_vdpau_interop2
+GO(glVDPAURegisterVideoSurfaceWithPictureStructureNV, lFpuipC)
diff --git a/src/wrapped/wrappedlibglu.c b/src/wrapped/wrappedlibglu.c
index 57a2bb4..8c37087 100755..100644
--- a/src/wrapped/wrappedlibglu.c
+++ b/src/wrapped/wrappedlibglu.c
@@ -42,7 +42,7 @@ GO(9) \
static uintptr_t my_glu_callback_fct_##A = 0; \
static void my_glu_callback_##A(void* a, void* b) \
{ \
- RunFunction(my_context, my_glu_callback_fct_##A, 2, a, b); \
+ RunFunctionFmt(my_glu_callback_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -64,7 +64,7 @@ static void* findglu_callbackFct(void* fct)
static uintptr_t my_glu_callback4_fct_##A = 0; \
static void my_glu_callback4_##A(void* a, void* b, void* c, void* d) \
{ \
- RunFunction(my_context, my_glu_callback4_fct_##A, 4, a, b, c, d); \
+ RunFunctionFmt(my_glu_callback4_fct_##A, "pppp", a, b, c, d); \
}
SUPER()
#undef GO
@@ -86,7 +86,7 @@ static void* findglu_callback4Fct(void* fct)
static uintptr_t my_glu_callback5_fct_##A = 0; \
static void my_glu_callback5_##A(void* a, void* b, void* c, void* d, void* e) \
{ \
- RunFunction(my_context, my_glu_callback5_fct_##A, 5, a, b, c, d, e); \
+ RunFunctionFmt(my_glu_callback5_fct_##A, "ppppp", a, b, c, d, e); \
}
SUPER()
#undef GO
diff --git a/src/wrapped/wrappedlibglu_private.h b/src/wrapped/wrappedlibglu_private.h
index a7c6b4a..a7c6b4a 100755..100644
--- a/src/wrapped/wrappedlibglu_private.h
+++ b/src/wrapped/wrappedlibglu_private.h
diff --git a/src/wrapped/wrappedlibharfbuzz.c b/src/wrapped/wrappedlibharfbuzz.c
new file mode 100644
index 0000000..8f4bb2c
--- /dev/null
+++ b/src/wrapped/wrappedlibharfbuzz.c
@@ -0,0 +1,1217 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#define _GNU_SOURCE /* See feature_test_macros(7) */
+#include <dlfcn.h>
+#include "wrappedlibs.h"
+#include "wrapper.h"
+#include "bridge.h"
+#include "librarian/library_private.h"
+#include "x64emu.h"
+#include <unistd.h>
+#include <sys/mman.h>
+#include <errno.h>
+#include "debug.h"
+#include "callback.h"
+
+const char* libharfbuzzName = "libharfbuzz.so.0";
+#define LIBNAME libharfbuzz
+
+#include "generated/wrappedlibharfbuzztypes.h"
+
+#include "wrappercallback.h"
+
+struct hb_atomic_int_t
+{
+ int v;
+};
+
+struct hb_reference_count_t
+{
+ struct hb_atomic_int_t ref_count;
+};
+
+struct hb_atomic_ptr_t {
+ void* v;
+};
+
+struct hb_object_header_t
+{
+ struct hb_reference_count_t ref_count;
+ struct hb_atomic_int_t writable;
+ struct hb_atomic_ptr_t user_data;
+};
+
+/*
+ * hb_draw_funcs_t
+ */
+
+#define HB_DRAW_FUNCS_IMPLEMENT_CALLBACKS \
+ HB_DRAW_FUNC_IMPLEMENT (move_to) \
+ HB_DRAW_FUNC_IMPLEMENT (line_to) \
+ HB_DRAW_FUNC_IMPLEMENT (quadratic_to) \
+ HB_DRAW_FUNC_IMPLEMENT (cubic_to) \
+ HB_DRAW_FUNC_IMPLEMENT (close_path) \
+ /* ^--- Add new callbacks here */
+
+struct hb_draw_funcs_t__func {
+#define HB_DRAW_FUNC_IMPLEMENT(name) void* name;
+ HB_DRAW_FUNCS_IMPLEMENT_CALLBACKS
+#undef HB_DRAW_FUNC_IMPLEMENT
+};
+
+struct hb_draw_funcs_t__destroy {
+#define HB_DRAW_FUNC_IMPLEMENT(name) void* name;
+ HB_DRAW_FUNCS_IMPLEMENT_CALLBACKS
+#undef HB_DRAW_FUNC_IMPLEMENT
+};
+
+struct hb_draw_funcs_t
+{
+ struct hb_object_header_t header;
+
+ struct hb_draw_funcs_t__func func;
+
+ struct {
+#define HB_DRAW_FUNC_IMPLEMENT(name) void *name;
+ HB_DRAW_FUNCS_IMPLEMENT_CALLBACKS
+#undef HB_DRAW_FUNC_IMPLEMENT
+ } *user_data;
+
+ struct hb_draw_funcs_t__destroy* destroy;
+};
+
+/*
+ * hb_font_funcs_t
+ */
+
+#define HB_FONT_FUNCS_IMPLEMENT_CALLBACKS \
+ HB_FONT_FUNC_IMPLEMENT (get_,font_h_extents) \
+ HB_FONT_FUNC_IMPLEMENT (get_,font_v_extents) \
+ HB_FONT_FUNC_IMPLEMENT (get_,nominal_glyph) \
+ HB_FONT_FUNC_IMPLEMENT (get_,nominal_glyphs) \
+ HB_FONT_FUNC_IMPLEMENT (get_,variation_glyph) \
+ HB_FONT_FUNC_IMPLEMENT (get_,glyph_h_advance) \
+ HB_FONT_FUNC_IMPLEMENT (get_,glyph_v_advance) \
+ HB_FONT_FUNC_IMPLEMENT (get_,glyph_h_advances) \
+ HB_FONT_FUNC_IMPLEMENT (get_,glyph_v_advances) \
+ HB_FONT_FUNC_IMPLEMENT (get_,glyph_h_origin) \
+ HB_FONT_FUNC_IMPLEMENT (get_,glyph_v_origin) \
+ HB_FONT_FUNC_IMPLEMENT (get_,glyph_h_kerning) \
+ HB_FONT_FUNC_IMPLEMENT (get_,glyph_v_kerning) \
+ HB_FONT_FUNC_IMPLEMENT (get_,glyph_extents) \
+ HB_FONT_FUNC_IMPLEMENT (get_,glyph_contour_point) \
+ HB_FONT_FUNC_IMPLEMENT (get_,glyph_name) \
+ HB_FONT_FUNC_IMPLEMENT (get_,glyph_from_name) \
+ HB_FONT_FUNC_IMPLEMENT (,draw_glyph) \
+ HB_FONT_FUNC_IMPLEMENT (,paint_glyph) \
+ /* ^--- Add new callbacks here */
+
+struct hb_font_funcs_t__destroy {
+#define HB_FONT_FUNC_IMPLEMENT(get_,name) void* name;
+ HB_FONT_FUNCS_IMPLEMENT_CALLBACKS
+#undef HB_FONT_FUNC_IMPLEMENT
+};
+
+struct hb_font_funcs_t
+{
+ struct hb_object_header_t header;
+
+ struct {
+#define HB_FONT_FUNC_IMPLEMENT(get_,name) void* name;
+ HB_FONT_FUNCS_IMPLEMENT_CALLBACKS
+#undef HB_FONT_FUNC_IMPLEMENT
+ } *user_data;
+
+ struct hb_font_funcs_t__destroy* destroy;
+
+ union get_t {
+ struct get_funcs_t {
+#define HB_FONT_FUNC_IMPLEMENT(get_,name) void* name;
+ HB_FONT_FUNCS_IMPLEMENT_CALLBACKS
+#undef HB_FONT_FUNC_IMPLEMENT
+ } f;
+ void (*array[0
+#define HB_FONT_FUNC_IMPLEMENT(get_,name) +1
+ HB_FONT_FUNCS_IMPLEMENT_CALLBACKS
+#undef HB_FONT_FUNC_IMPLEMENT
+ ]) ();
+ } get;
+};
+
+/*
+ * hb_unicode_funcs_t
+ */
+
+#define HB_UNICODE_FUNCS_IMPLEMENT_CALLBACKS \
+ HB_UNICODE_FUNC_IMPLEMENT (combining_class) \
+ HB_UNICODE_FUNC_IMPLEMENT (eastasian_width) \
+ HB_UNICODE_FUNC_IMPLEMENT (general_category) \
+ HB_UNICODE_FUNC_IMPLEMENT (mirroring) \
+ HB_UNICODE_FUNC_IMPLEMENT (script) \
+ HB_UNICODE_FUNC_IMPLEMENT (compose) \
+ HB_UNICODE_FUNC_IMPLEMENT (decompose) \
+ HB_UNICODE_FUNC_IMPLEMENT (decompose_compatibility) \
+ /* ^--- Add new callbacks here */
+
+/* Simple callbacks are those taking a hb_codepoint_t and returning a hb_codepoint_t */
+#define HB_UNICODE_FUNCS_IMPLEMENT_CALLBACKS_SIMPLE \
+ HB_UNICODE_FUNC_IMPLEMENT (hb_unicode_combining_class_t, combining_class) \
+ HB_UNICODE_FUNC_IMPLEMENT (unsigned int, eastasian_width) \
+ HB_UNICODE_FUNC_IMPLEMENT (hb_unicode_general_category_t, general_category) \
+ HB_UNICODE_FUNC_IMPLEMENT (hb_codepoint_t, mirroring) \
+ HB_UNICODE_FUNC_IMPLEMENT (hb_script_t, script) \
+ /* ^--- Add new simple callbacks here */
+
+
+struct hb_unicode_funcs_t__destroy {
+#define HB_UNICODE_FUNC_IMPLEMENT(name) void* name;
+ HB_UNICODE_FUNCS_IMPLEMENT_CALLBACKS
+#undef HB_UNICODE_FUNC_IMPLEMENT
+};
+
+struct hb_unicode_funcs_t
+{
+ struct hb_object_header_t header;
+ struct hb_unicode_funcs_t *parent;
+
+ struct {
+#define HB_UNICODE_FUNC_IMPLEMENT(name) void* name;
+ HB_UNICODE_FUNCS_IMPLEMENT_CALLBACKS
+#undef HB_UNICODE_FUNC_IMPLEMENT
+ } func;
+
+ struct {
+#define HB_UNICODE_FUNC_IMPLEMENT(name) void* name;
+ HB_UNICODE_FUNCS_IMPLEMENT_CALLBACKS
+#undef HB_UNICODE_FUNC_IMPLEMENT
+ } user_data;
+
+ struct hb_unicode_funcs_t__destroy destroy;
+};
+
+#define SUPER() \
+ GO(0) \
+ GO(1) \
+ GO(2) \
+ GO(3) \
+ GO(4) \
+ GO(5) \
+ GO(6) \
+ GO(7) \
+ GO(8) \
+ GO(9) \
+ GO(10) \
+ GO(11) \
+ GO(12) \
+
+// buffer_message
+#define GO(A) \
+static uintptr_t my_buffer_message_fct_##A = 0; \
+static int my_buffer_message_##A(void* a, void* b, void* c, void* d)\
+{ \
+ return (int)RunFunctionFmt(my_buffer_message_fct_##A, "pppp", a, b, c, d); \
+}
+SUPER()
+#undef GO
+static void* find_buffer_message_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_buffer_message_fct_##A == (uintptr_t)fct) return my_buffer_message_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_buffer_message_fct_##A == 0) {my_buffer_message_fct_##A = (uintptr_t)fct; return my_buffer_message_##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz buffer message callback\n");
+ return NULL;
+}
+
+// draw close path
+#define GO(A) \
+static uintptr_t my_draw_close_path_fct_##A = 0; \
+static void my_draw_close_path_##A(void* a, void* b, void* c, void* d) \
+{ \
+ RunFunctionFmt(my_draw_close_path_fct_##A, "pppp", a, b, c, d); \
+}
+SUPER()
+#undef GO
+static void* find_draw_close_path_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_draw_close_path_fct_##A == (uintptr_t)fct) return my_draw_close_path_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_draw_close_path_fct_##A == 0) {my_draw_close_path_fct_##A = (uintptr_t)fct; return my_draw_close_path_##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz draw close path callback\n");
+ return NULL;
+}
+
+// draw cubic to
+#define GO(A) \
+static uintptr_t my_draw_cubic_to_fct_##A = 0; \
+static void my_draw_cubic_to_##A(void* a, void* b, void* c, float d1, float d2, float d3, float d4, float d5, float d6, void* e) \
+{ \
+ RunFunctionFmt(my_draw_cubic_to_fct_##A, "pppffffffp", a, b, c, d1, d2, d3, d4, d5, d6, e); \
+}
+SUPER()
+#undef GO
+static void* find_draw_cubic_to_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_draw_cubic_to_fct_##A == (uintptr_t)fct) return my_draw_cubic_to_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_draw_cubic_to_fct_##A == 0) {my_draw_cubic_to_fct_##A = (uintptr_t)fct; return my_draw_cubic_to_##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz draw cubic to callback\n");
+ return NULL;
+}
+
+// draw line/move to
+#define GO(A) \
+static uintptr_t my_draw_line_or_move_to_fct_##A = 0; \
+static void my_draw_line_or_move_to_##A(void* a, void* b, void* c, float d1, float d2, void* e) \
+{ \
+ RunFunctionFmt(my_draw_line_or_move_to_fct_##A, "pppffp", a, b, c, d1, d2, e); \
+}
+SUPER()
+#undef GO
+static void* find_draw_line_or_move_to_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_draw_line_or_move_to_fct_##A == (uintptr_t)fct) return my_draw_line_or_move_to_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_draw_line_or_move_to_fct_##A == 0) {my_draw_line_or_move_to_fct_##A = (uintptr_t)fct; return my_draw_line_or_move_to_##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz draw line/move to callback\n");
+ return NULL;
+}
+
+// draw quadratic to
+#define GO(A) \
+static uintptr_t my_draw_quadratic_to_fct_##A = 0; \
+static void my_draw_quadratic_to_##A(void* a, void* b, void* c, float d1, float d2, float d3, float d4, void* e) \
+{ \
+ RunFunctionFmt(my_draw_quadratic_to_fct_##A, "pppffffp", a, b, c, d1, d2, d3, d4, e); \
+}
+SUPER()
+#undef GO
+static void* find_draw_quadratic_to_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_draw_quadratic_to_fct_##A == (uintptr_t)fct) return my_draw_quadratic_to_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_draw_quadratic_to_fct_##A == 0) {my_draw_quadratic_to_fct_##A = (uintptr_t)fct; return my_draw_quadratic_to_##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz draw quadratic to callback\n");
+ return NULL;
+}
+
+// reference table
+#define GO(A) \
+static uintptr_t my_reference_table_fct_##A = 0; \
+static void* my_reference_table_##A(void* a, uint32_t b, void* c) \
+{ \
+ return (void*)RunFunctionFmt(my_reference_table_fct_##A, "pup", a, b, c); \
+}
+SUPER()
+#undef GO
+static void* find_reference_table_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_reference_table_fct_##A == (uintptr_t)fct) return my_reference_table_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_reference_table_fct_##A == 0) {my_reference_table_fct_##A = (uintptr_t)fct; return my_reference_table_##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz reference table callback\n");
+ return NULL;
+}
+
+// unicode combining class
+#define GO(A) \
+static uintptr_t my_unicode_combining_class_fct_##A = 0; \
+static uint32_t my_unicode_combining_class_##A(void* a, uint32_t b, void* c)\
+{ \
+ return (uint32_t)RunFunctionFmt(my_unicode_combining_class_fct_##A, "pup", a, b, c); \
+}
+SUPER()
+#undef GO
+static void* find_unicode_combining_class_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_unicode_combining_class_fct_##A == (uintptr_t)fct) return my_unicode_combining_class_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_unicode_combining_class_fct_##A == 0) {my_unicode_combining_class_fct_##A = (uintptr_t)fct; return my_unicode_combining_class_##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz unicode combining class callback\n");
+ return NULL;
+}
+
+// unicode compose
+#define GO(A) \
+static uintptr_t my_unicode_compose_fct_##A = 0; \
+static int my_unicode_compose_##A(void* a, uint32_t b, uint32_t c, void* d, void* e)\
+{ \
+ return (int)RunFunctionFmt(my_unicode_compose_fct_##A, "puupp", a, b, c, d, e); \
+}
+SUPER()
+#undef GO
+static void* find_unicode_compose_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_unicode_compose_fct_##A == (uintptr_t)fct) return my_unicode_compose_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_unicode_compose_fct_##A == 0) {my_unicode_compose_fct_##A = (uintptr_t)fct; return my_unicode_compose_##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz unicode compose callback\n");
+ return NULL;
+}
+
+// unicode decompose compatibility
+#define GO(A) \
+static uintptr_t my_unicode_decompose_compatibility_fct_##A = 0; \
+static uint32_t my_unicode_decompose_compatibility_##A(void* a, uint32_t b, void* c, void* d) \
+{ \
+ return (uint32_t)RunFunctionFmt(my_unicode_decompose_compatibility_fct_##A, "pupp", a, b, c, d); \
+}
+SUPER()
+#undef GO
+static void* find_unicode_decompose_compatibility_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_unicode_decompose_compatibility_fct_##A == (uintptr_t)fct) return my_unicode_decompose_compatibility_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_unicode_decompose_compatibility_fct_##A == 0) {my_unicode_decompose_compatibility_fct_##A = (uintptr_t)fct; return my_unicode_decompose_compatibility_##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz unicode decompose compatibility callback\n");
+ return NULL;
+}
+
+// unicode decompose
+#define GO(A) \
+static uintptr_t my_unicode_decompose_fct_##A = 0; \
+static int my_unicode_decompose_##A(void* a, uint32_t b, void* c, void* d, void* e) \
+{ \
+ return (int)RunFunctionFmt(my_unicode_decompose_fct_##A, "puppp", a, b, c, d, e); \
+}
+SUPER()
+#undef GO
+static void* find_unicode_decompose_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_unicode_decompose_fct_##A == (uintptr_t)fct) return my_unicode_decompose_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_unicode_decompose_fct_##A == 0) {my_unicode_decompose_fct_##A = (uintptr_t)fct; return my_unicode_decompose_##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz unicode decompose class callback\n");
+ return NULL;
+}
+
+// unicode eastasian width
+#define GO(A) \
+static uintptr_t my_unicode_eastasian_width_fct_##A = 0; \
+static uint32_t my_unicode_eastasian_width_##A(void* a, uint32_t b, void* c) \
+{ \
+ return (uint32_t)RunFunctionFmt(my_unicode_eastasian_width_fct_##A, "pup", a, b, c); \
+}
+SUPER()
+#undef GO
+static void* find_unicode_eastasian_width_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_unicode_eastasian_width_fct_##A == (uintptr_t)fct) return my_unicode_eastasian_width_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_unicode_eastasian_width_fct_##A == 0) {my_unicode_eastasian_width_fct_##A = (uintptr_t)fct; return my_unicode_eastasian_width_##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz unicode eastasian width callback\n");
+ return NULL;
+}
+
+// unicode general category
+#define GO(A) \
+static uintptr_t my_unicode_general_category_fct_##A = 0; \
+static uint32_t my_unicode_general_category_##A(void* a, uint32_t b, void* c) \
+{ \
+ return (uint32_t)RunFunctionFmt(my_unicode_general_category_fct_##A, "pup", a, b, c); \
+}
+SUPER()
+#undef GO
+static void* find_unicode_general_category_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_unicode_general_category_fct_##A == (uintptr_t)fct) return my_unicode_general_category_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_unicode_general_category_fct_##A == 0) {my_unicode_general_category_fct_##A = (uintptr_t)fct; return my_unicode_general_category_##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz unicode general category callback\n");
+ return NULL;
+}
+
+// unicode mirroring
+#define GO(A) \
+static uintptr_t my_unicode_mirroring_fct_##A = 0; \
+static uint32_t my_unicode_mirroring_##A(void* a, uint32_t b, void* c) \
+{ \
+ return (uint32_t)RunFunctionFmt(my_unicode_mirroring_fct_##A, "pup", a, b, c); \
+}
+SUPER()
+#undef GO
+static void* find_unicode_mirroring_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_unicode_mirroring_fct_##A == (uintptr_t)fct) return my_unicode_mirroring_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_unicode_mirroring_fct_##A == 0) {my_unicode_mirroring_fct_##A = (uintptr_t)fct; return my_unicode_mirroring_##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz unicode mirroring callback\n");
+ return NULL;
+}
+
+// unicode script
+#define GO(A) \
+static uintptr_t my_unicode_script_fct_##A = 0; \
+static uint32_t my_unicode_script_##A(void* a, uint32_t b, void* c) \
+{ \
+ return (uint32_t)RunFunctionFmt(my_unicode_script_fct_##A, "pup", a, b, c); \
+}
+SUPER()
+#undef GO
+static void* find_unicode_script_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_unicode_script_fct_##A == (uintptr_t)fct) return my_unicode_script_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_unicode_script_fct_##A == 0) {my_unicode_script_fct_##A = (uintptr_t)fct; return my_unicode_script_##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz unicode script callback\n");
+ return NULL;
+}
+
+// font extents
+#define GO(A) \
+static uintptr_t my_font_extents_fct_##A = 0; \
+static int my_font_extents_##A(void* a, void* b, void* c, void* d) \
+{ \
+ return (int)RunFunctionFmt(my_font_extents_fct_##A, "pppp", a, b, c, d); \
+}
+SUPER()
+#undef GO
+static void* find_font_extents_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_font_extents_fct_##A == (uintptr_t)fct) return my_font_extents_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_font_extents_fct_##A == 0) {my_font_extents_fct_##A = (uintptr_t)fct; return my_font_extents_##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz font extents callback\n");
+ return NULL;
+}
+
+// glyph advance
+#define GO(A) \
+static uintptr_t my_glyph_advance_fct_##A = 0; \
+static int my_glyph_advance_##A(void* a, void* b, uint32_t c, void* d) \
+{ \
+ return (int)RunFunctionFmt(my_glyph_advance_fct_##A, "ppup", a, b, c, d); \
+}
+SUPER()
+#undef GO
+static void* find_glyph_advance_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_glyph_advance_fct_##A == (uintptr_t)fct) return my_glyph_advance_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_glyph_advance_fct_##A == 0) {my_glyph_advance_fct_##A = (uintptr_t)fct; return my_glyph_advance_##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz glyph advance callback\n");
+ return NULL;
+}
+
+// glyph advances
+#define GO(A) \
+static uintptr_t my_glyph_advances_fct_##A = 0; \
+static void my_glyph_advances_##A(void* a, void* b, uint32_t c, void* d, uint32_t e, void* f, uint32_t g, void* h) \
+{ \
+ RunFunctionFmt(my_glyph_advances_fct_##A, "ppupupup", a, b, c, d, e, f, g, h); \
+}
+SUPER()
+#undef GO
+static void* find_glyph_advances_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_glyph_advances_fct_##A == (uintptr_t)fct) return my_glyph_advances_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_glyph_advances_fct_##A == 0) {my_glyph_advances_fct_##A = (uintptr_t)fct; return my_glyph_advances_##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz glyph advances callback\n");
+ return NULL;
+}
+
+// glyph kerning
+#define GO(A) \
+static uintptr_t my_glyph_kerning_fct_##A = 0; \
+static int my_glyph_kerning_##A(void* a, void* b, uint32_t c, uint32_t d, void* e) \
+{ \
+ return (int)RunFunctionFmt(my_glyph_kerning_fct_##A, "ppuup", a, b, c, d, e); \
+}
+SUPER()
+#undef GO
+static void* find_glyph_kerning_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_glyph_kerning_fct_##A == (uintptr_t)fct) return my_glyph_kerning_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_glyph_kerning_fct_##A == 0) {my_glyph_kerning_fct_##A = (uintptr_t)fct; return my_glyph_kerning_##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz glyph kerning callback\n");
+ return NULL;
+}
+
+// glyph origin
+#define GO(A) \
+static uintptr_t my_glyph_origin_fct_##A = 0; \
+static int my_glyph_origin_##A(void* a, void* b, uint32_t c, void* d, void* e, void* f) \
+{ \
+ return (int)RunFunctionFmt(my_glyph_origin_fct_##A, "ppuppp", a, b, c, d, e, f); \
+}
+SUPER()
+#undef GO
+static void* find_glyph_origin_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_glyph_origin_fct_##A == (uintptr_t)fct) return my_glyph_origin_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_glyph_origin_fct_##A == 0) {my_glyph_origin_fct_##A = (uintptr_t)fct; return my_glyph_origin_##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz glyph origin callback\n");
+ return NULL;
+}
+
+// glyph contour point
+#define GO(A) \
+static uintptr_t my_glyph_contour_pointfct_##A = 0; \
+static int my_glyph_contour_point##A(void* a, void* b, uint32_t c, uint32_t d, void* e, void* f, void* g) \
+{ \
+ return (int)RunFunctionFmt(my_glyph_contour_pointfct_##A, "ppuuppp", a, b, c, d, e, f, g); \
+}
+SUPER()
+#undef GO
+static void* find_glyph_contour_point_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_glyph_contour_pointfct_##A == (uintptr_t)fct) return my_glyph_contour_point##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_glyph_contour_pointfct_##A == 0) {my_glyph_contour_pointfct_##A = (uintptr_t)fct; return my_glyph_contour_point##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz glyph contour point callback\n");
+ return NULL;
+}
+
+// glyph extents
+#define GO(A) \
+static uintptr_t my_glyph_extents_fct_##A = 0; \
+static int my_glyph_extents_##A(void* a, void* b, uint32_t c, void* d, void* e) \
+{ \
+ return (int)RunFunctionFmt(my_glyph_extents_fct_##A, "ppupp", a, b, c, d, e); \
+}
+SUPER()
+#undef GO
+static void* find_glyph_extents_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_glyph_extents_fct_##A == (uintptr_t)fct) return my_glyph_extents_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_glyph_extents_fct_##A == 0) {my_glyph_extents_fct_##A = (uintptr_t)fct; return my_glyph_extents_##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz glyph extents callback\n");
+ return NULL;
+}
+
+// glyph from name
+#define GO(A) \
+static uintptr_t my_glyph_from_name_fct_##A = 0; \
+static int my_glyph_from_name_##A(void* a, void* b, void* c, int d, void* e, void* f) \
+{ \
+ return (int)RunFunctionFmt(my_glyph_from_name_fct_##A, "pppipp", a, b, c, d, e, f); \
+}
+SUPER()
+#undef GO
+static void* find_glyph_from_name_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_glyph_from_name_fct_##A == (uintptr_t)fct) return my_glyph_from_name_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_glyph_from_name_fct_##A == 0) {my_glyph_from_name_fct_##A = (uintptr_t)fct; return my_glyph_from_name_##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz glyph from name callback\n");
+ return NULL;
+}
+
+
+
+
+
+
+// glyph
+#define GO(A) \
+static uintptr_t my_glyph_fct_##A = 0; \
+static int my_glyph_##A(void* a, void* b, uint32_t c, uint32_t d, void* e, void* f) \
+{ \
+ return (int)RunFunctionFmt(my_glyph_fct_##A, "ppuupp", a, b, c, d, e, f); \
+}
+SUPER()
+#undef GO
+static void* find_glyph_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_glyph_fct_##A == (uintptr_t)fct) return my_glyph_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_glyph_fct_##A == 0) {my_glyph_fct_##A = (uintptr_t)fct; return my_glyph_##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz glyph callback\n");
+ return NULL;
+}
+
+// glyph name
+#define GO(A) \
+static uintptr_t my_glyph_name_fct_##A = 0; \
+static int my_glyph_name_##A(void* a, void* b, uint32_t c, void* d, uint32_t e, void* f) \
+{ \
+ return (int)RunFunctionFmt(my_glyph_name_fct_##A, "ppupup", a, b, c, d, e, f); \
+}
+SUPER()
+#undef GO
+static void* find_glyph_name_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_glyph_name_fct_##A == (uintptr_t)fct) return my_glyph_name_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_glyph_name_fct_##A == 0) {my_glyph_name_fct_##A = (uintptr_t)fct; return my_glyph_name_##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz glyph origin callback\n");
+ return NULL;
+}
+
+// glyph shape
+#define GO(A) \
+static uintptr_t my_glyph_shape_fct_##A = 0; \
+static void my_glyph_shape_##A(void* a, void* b, uint32_t c, void* d, void* e, void* f) \
+{ \
+ RunFunctionFmt(my_glyph_shape_fct_##A, "ppuppp", a, b, c, d, e, f); \
+}
+SUPER()
+#undef GO
+static void* find_glyph_shape_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_glyph_shape_fct_##A == (uintptr_t)fct) return my_glyph_shape_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_glyph_shape_fct_##A == 0) {my_glyph_shape_fct_##A = (uintptr_t)fct; return my_glyph_shape_##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz glyph shape callback\n");
+ return NULL;
+}
+
+// nominal glyph
+#define GO(A) \
+static uintptr_t my_nominal_glyph_fct_##A = 0; \
+static int my_nominal_glyph_##A(void* a, void* b, uint32_t c, void* d, void* e) \
+{ \
+ return (int)RunFunctionFmt(my_nominal_glyph_fct_##A, "ppupp", a, b, c, d, e); \
+}
+SUPER()
+#undef GO
+static void* find_nominal_glyph_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_nominal_glyph_fct_##A == (uintptr_t)fct) return my_nominal_glyph_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_nominal_glyph_fct_##A == 0) {my_nominal_glyph_fct_##A = (uintptr_t)fct; return my_nominal_glyph_##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz nominal glyph callback\n");
+ return NULL;
+}
+
+
+
+
+
+
+// nominal glyphs
+#define GO(A) \
+static uintptr_t my_nominal_glyphs_fct_##A = 0; \
+static uint32_t my_nominal_glyphs_##A(void* a, void* b, uint32_t c, void* d, uint32_t e, void* f, uint32_t g, void* h) \
+{ \
+ return (uint32_t)RunFunctionFmt(my_nominal_glyphs_fct_##A, "ppupupup", a, b, c, d, e, f, g, h); \
+}
+SUPER()
+#undef GO
+static void* find_nominal_glyphs_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_nominal_glyphs_fct_##A == (uintptr_t)fct) return my_nominal_glyphs_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_nominal_glyphs_fct_##A == 0) {my_nominal_glyphs_fct_##A = (uintptr_t)fct; return my_nominal_glyphs_##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz nominal glyphs callback\n");
+ return NULL;
+}
+
+// variation glyph
+#define GO(A) \
+static uintptr_t my_variation_glyph_fct_##A = 0;\
+static int my_variation_glyph_##A(void* a, void* b, uint32_t c, uint32_t d, void* e, void* f) \
+{ \
+ return (int)RunFunctionFmt(my_variation_glyph_fct_##A, "ppuupp", a, b, c, d, e, f); \
+}
+SUPER()
+#undef GO
+static void* find_variation_glyph_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_variation_glyph_fct_##A == (uintptr_t)fct) return my_variation_glyph_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_variation_glyph_fct_##A == 0) {my_variation_glyph_fct_##A = (uintptr_t)fct; return my_variation_glyph_##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz variation glyph callback\n");
+ return NULL;
+}
+
+// destroy
+#define GO(A) \
+static uintptr_t my_destroy_fct_##A = 0; \
+static void my_destroy_##A(void* a) \
+{ \
+ RunFunctionFmt(my_destroy_fct_##A, "p", a); \
+}
+SUPER()
+#undef GO
+static void* find_destroy_Fct(void* fct)
+{
+ if (!fct) return NULL;
+ if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if (my_destroy_fct_##A == (uintptr_t)fct) return my_destroy_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if (my_destroy_fct_##A == 0) {my_destroy_fct_##A = (uintptr_t)fct; return my_destroy_##A;}
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libharfbuzz destroy callback\n");
+ return NULL;
+}
+
+#undef SUPER
+
+#define FUNC(A) \
+EXPORT void* my_##A(x64emu_t* emu, void* data, uint32_t length, uint32_t mode, void* user_data, void* destroy) \
+{ \
+ (void)emu; \
+ return my->A(data, length, mode, user_data, find_destroy_Fct(destroy)); \
+}
+
+FUNC(hb_blob_create)
+FUNC(hb_blob_create_or_fail)
+
+#undef FUNC
+
+#define FUNC(A) \
+EXPORT int my_##A(x64emu_t* emu, void* blob, void* key, void* data, void* destroy, int replace) \
+{ \
+ (void)emu; \
+ return (int)my->A(blob, key, data, find_destroy_Fct(destroy), replace); \
+}
+
+FUNC(hb_blob_set_user_data)
+FUNC(hb_buffer_set_user_data)
+
+#undef FUNC
+
+#define FUNC(A) \
+EXPORT void my_##A(x64emu_t* emu, void* buffer, void* func, void* user_data, void* destroy) \
+{ \
+ (void)emu; \
+ my->A(buffer, find_buffer_message_Fct(func), user_data, find_destroy_Fct(destroy)); \
+}
+
+FUNC(hb_buffer_set_message_func)
+
+#undef FUNC
+
+EXPORT void my_hb_draw_funcs_destroy(x64emu_t* emu, void* funcs)
+{
+ (void)emu;
+ struct hb_draw_funcs_t__destroy destroy = {0};
+ struct hb_draw_funcs_t* funcs_ = funcs;
+
+#define HB_DRAW_FUNC_IMPLEMENT(name) \
+ if (funcs_->destroy->name) destroy.name = find_destroy_Fct(funcs_->destroy->name);
+ HB_DRAW_FUNCS_IMPLEMENT_CALLBACKS
+#undef HB_DRAW_FUNC_IMPLEMENT
+
+ struct hb_draw_funcs_t__destroy* original = funcs_->destroy;
+ funcs_->destroy = &destroy;
+ my->hb_draw_funcs_destroy(funcs);
+ funcs_->destroy = original;
+}
+
+EXPORT void my_hb_draw_funcs_set_close_path_func(x64emu_t* emu, void* funcs, void* func, void* user_data, void* destroy)
+{
+ (void)emu;
+ my->hb_draw_funcs_set_close_path_func(funcs, find_draw_close_path_Fct(func), user_data, find_destroy_Fct(destroy));
+}
+
+EXPORT void my_hb_draw_funcs_set_cubic_to_func(x64emu_t* emu, void* funcs, void* func, void* user_data, void* destroy)
+{
+ (void)emu;
+ my->hb_draw_funcs_set_cubic_to_func(funcs, find_draw_cubic_to_Fct(func), user_data, find_destroy_Fct(destroy));
+}
+
+#define FUNC(A) \
+EXPORT void my_##A(x64emu_t* emu, void* buffer, void* func, void* user_data, void* destroy) \
+{ \
+ (void)emu; \
+ my->A(buffer, find_draw_line_or_move_to_Fct(func), user_data, find_destroy_Fct(destroy)); \
+}
+
+FUNC(hb_draw_funcs_set_line_to_func)
+FUNC(hb_draw_funcs_set_move_to_func)
+
+#undef FUNC
+
+EXPORT void my_hb_draw_funcs_set_quadratic_to_func(x64emu_t* emu, void* funcs, void* func, void* user_data, void* destroy)
+{
+ (void)emu;
+ my->hb_draw_funcs_set_quadratic_to_func(funcs, find_draw_quadratic_to_Fct(func), user_data, find_destroy_Fct(destroy));
+}
+
+EXPORT void* my_hb_face_create_for_tables(x64emu_t* emu, void* func, void* user_data, void* destroy)
+{
+ (void)emu;
+ return my->hb_face_create_for_tables(find_reference_table_Fct(func), user_data, find_destroy_Fct(destroy));
+}
+
+EXPORT int my_hb_face_set_user_data(x64emu_t* emu, void* face, void* key, void* data, void* destroy, int replace)
+{
+ (void)emu;
+ return (int)my->hb_face_set_user_data(face, key, data, find_destroy_Fct(destroy), replace);
+}
+
+EXPORT void my_hb_font_funcs_destroy(x64emu_t* emu, void* funcs)
+{
+ (void)emu;
+ struct hb_font_funcs_t__destroy destroy = {0};
+ struct hb_font_funcs_t* funcs_ = funcs;
+
+#define HB_FONT_FUNC_IMPLEMENT(get_,name) \
+ if (funcs_->destroy->name) destroy.name = find_destroy_Fct(funcs_->destroy->name);
+ HB_FONT_FUNCS_IMPLEMENT_CALLBACKS
+#undef HB_FONT_FUNC_IMPLEMENT
+
+ struct hb_font_funcs_t__destroy* original = funcs_->destroy;
+ funcs_->destroy = &destroy;
+ my->hb_font_funcs_destroy(funcs);
+ funcs_->destroy = original;
+}
+
+EXPORT void my_hb_unicode_funcs_destroy(x64emu_t* emu, void* funcs)
+{
+ (void)emu;
+ struct hb_unicode_funcs_t__destroy destroy = {0};
+ struct hb_unicode_funcs_t* funcs_ = funcs;
+
+#define HB_UNICODE_FUNC_IMPLEMENT(name) \
+ if (funcs_->destroy.name) destroy.name = find_destroy_Fct(funcs_->destroy.name);
+ HB_UNICODE_FUNCS_IMPLEMENT_CALLBACKS
+#undef HB_UNICODE_FUNC_IMPLEMENT
+
+ struct hb_unicode_funcs_t__destroy original = funcs_->destroy;
+ funcs_->destroy = destroy;
+ my->hb_font_funcs_destroy(funcs);
+ funcs_->destroy = original;
+}
+
+EXPORT void my_hb_unicode_funcs_set_combining_class_func(x64emu_t* emu, void* funcs, void* func, void* user_data, void* destroy)
+{
+ (void)emu;
+ my->hb_unicode_funcs_set_combining_class_func(funcs, find_unicode_combining_class_Fct(func), user_data, find_destroy_Fct(destroy));
+}
+
+EXPORT void my_hb_unicode_funcs_set_compose_func(x64emu_t* emu, void* funcs, void* func, void* user_data, void* destroy)
+{
+ (void)emu;
+ my->hb_unicode_funcs_set_compose_func(funcs, find_unicode_compose_Fct(func), user_data, find_destroy_Fct(destroy));
+}
+
+EXPORT void my_hb_unicode_funcs_set_decompose_compatibility_func(x64emu_t* emu, void* funcs, void* func, void* user_data, void* destroy)
+{
+ (void)emu;
+ my->hb_unicode_funcs_set_decompose_compatibility_func(funcs, find_unicode_decompose_compatibility_Fct(func), user_data, find_destroy_Fct(destroy));
+}
+
+EXPORT void my_hb_unicode_funcs_set_decompose_func(x64emu_t* emu, void* funcs, void* func, void* user_data, void* destroy)
+{
+ (void)emu;
+ my->hb_unicode_funcs_set_decompose_func(funcs, find_unicode_decompose_Fct(func), user_data, find_destroy_Fct(destroy));
+}
+
+EXPORT void my_hb_unicode_funcs_set_eastasian_width_func(x64emu_t* emu, void* funcs, void* func, void* user_data, void* destroy)
+{
+ (void)emu;
+ my->hb_unicode_funcs_set_eastasian_width_func(funcs, find_unicode_eastasian_width_Fct(func), user_data, find_destroy_Fct(destroy));
+}
+
+EXPORT void my_hb_unicode_funcs_set_general_category_func(x64emu_t* emu, void* funcs, void* func, void* user_data, void* destroy)
+{
+ (void)emu;
+ my->hb_unicode_funcs_set_general_category_func(funcs, find_unicode_general_category_Fct(func), user_data, find_destroy_Fct(destroy));
+}
+
+EXPORT void my_hb_unicode_funcs_set_mirroring_func(x64emu_t* emu, void* funcs, void* func, void* user_data, void* destroy)
+{
+ (void)emu;
+ my->hb_unicode_funcs_set_mirroring_func(funcs, find_unicode_mirroring_Fct(func), user_data, find_destroy_Fct(destroy));
+}
+
+EXPORT void my_hb_unicode_funcs_set_script_func(x64emu_t* emu, void* funcs, void* func, void* user_data, void* destroy)
+{
+ (void)emu;
+ my->hb_unicode_funcs_set_script_func(funcs, find_unicode_script_Fct(func), user_data, find_destroy_Fct(destroy));
+}
+
+EXPORT int my_hb_unicode_funcs_set_user_data(x64emu_t* emu, void* funcs, void* key, void* data, void* destroy, int replace)
+{
+ (void)emu;
+ return (int)my->hb_unicode_funcs_set_user_data(funcs, key, data, find_destroy_Fct(destroy), replace);
+}
+
+#define FUNC(A) \
+EXPORT void my_##A(x64emu_t* emu, void* funcs, void* func, void* user_data, void* destroy) \
+{ \
+ (void)emu; \
+ my->A(funcs, find_font_extents_Fct(func), user_data, find_destroy_Fct(destroy));\
+}
+
+FUNC(hb_font_funcs_set_font_h_extents_func)
+FUNC(hb_font_funcs_set_font_v_extents_func)
+
+#undef FUNC
+
+
+#define FUNC(A) \
+EXPORT void my_##A(x64emu_t* emu, void* funcs, void* func, void* user_data, void* destroy) \
+{ \
+ (void)emu; \
+ my->A(funcs, find_glyph_advance_Fct(func), user_data, find_destroy_Fct(destroy)); \
+}
+
+FUNC(hb_font_funcs_set_glyph_h_advance_func)
+FUNC(hb_font_funcs_set_glyph_v_advance_func)
+
+#undef FUNC
+
+
+#define FUNC(A) \
+EXPORT void my_##A(x64emu_t* emu, void* funcs, void* func, void* user_data, void* destroy) \
+{ \
+ (void)emu; \
+ my->A(funcs, find_glyph_advances_Fct(func), user_data, find_destroy_Fct(destroy)); \
+}
+
+FUNC(hb_font_funcs_set_glyph_h_advances_func)
+FUNC(hb_font_funcs_set_glyph_v_advances_func)
+
+#undef FUNC
+
+
+#define FUNC(A) \
+EXPORT void my_##A(x64emu_t* emu, void* funcs, void* func, void* user_data, void* destroy) \
+{ \
+ (void)emu; \
+ my->A(funcs, find_glyph_kerning_Fct(func), user_data, find_destroy_Fct(destroy)); \
+}
+
+FUNC(hb_font_funcs_set_glyph_h_kerning_func)
+FUNC(hb_font_funcs_set_glyph_v_kerning_func)
+
+#undef FUNC
+
+
+#define FUNC(A) \
+EXPORT void my_##A(x64emu_t* emu, void* funcs, void* func, void* user_data, void* destroy) \
+{ \
+ (void)emu; \
+ my->A(funcs, find_glyph_origin_Fct(func), user_data, find_destroy_Fct(destroy));\
+}
+
+FUNC(hb_font_funcs_set_glyph_h_origin_func)
+FUNC(hb_font_funcs_set_glyph_v_origin_func)
+
+#undef FUNC
+
+EXPORT void my_hb_font_funcs_set_glyph_contour_point_func(x64emu_t* emu, void* funcs, void* func, void* user_data, void* destroy)
+{
+ (void)emu;
+ my->hb_font_funcs_set_glyph_contour_point_func(funcs, find_glyph_contour_point_Fct(func), user_data, find_destroy_Fct(destroy));
+}
+
+EXPORT void my_hb_font_funcs_set_glyph_extents_func(x64emu_t* emu, void* funcs, void* func, void* user_data, void* destroy)
+{
+ (void)emu;
+ my->hb_font_funcs_set_glyph_extents_func(funcs, find_glyph_extents_Fct(func), user_data, find_destroy_Fct(destroy));
+}
+
+EXPORT void my_hb_font_funcs_set_glyph_from_name_func(x64emu_t* emu, void* funcs, void* func, void* user_data, void* destroy)
+{
+ (void)emu;
+ my->hb_font_funcs_set_glyph_from_name_func(funcs, find_glyph_from_name_Fct(func), user_data, find_destroy_Fct(destroy));
+}
+
+EXPORT void my_hb_font_funcs_set_glyph_func(x64emu_t* emu, void* funcs, void* func, void* user_data, void* destroy)
+{
+ (void)emu;
+ my->hb_font_funcs_set_glyph_func(funcs, find_glyph_Fct(func), user_data, find_destroy_Fct(destroy));
+}
+
+EXPORT void my_hb_font_funcs_set_glyph_name_func(x64emu_t* emu, void* funcs, void* func, void* user_data, void* destroy)
+{
+ (void)emu;
+ my->hb_font_funcs_set_glyph_name_func(funcs, find_glyph_name_Fct(func), user_data, find_destroy_Fct(destroy));
+}
+
+EXPORT void my_hb_font_funcs_set_glyph_shape_func(x64emu_t* emu, void* funcs, void* func, void* user_data, void* destroy)
+{
+ (void)emu;
+ my->hb_font_funcs_set_glyph_shape_func(funcs, find_glyph_shape_Fct(func), user_data, find_destroy_Fct(destroy));
+}
+
+EXPORT void my_hb_font_funcs_set_nominal_glyph_func(x64emu_t* emu, void* funcs, void* func, void* user_data, void* destroy)
+{
+ (void)emu;
+ my->hb_font_funcs_set_nominal_glyph_func(funcs, find_nominal_glyph_Fct(func), user_data, find_destroy_Fct(destroy));
+}
+
+EXPORT void my_hb_font_funcs_set_nominal_glyphs_func(x64emu_t* emu, void* funcs, void* func, void* user_data, void* destroy)
+{
+ (void)emu;
+ my->hb_font_funcs_set_nominal_glyphs_func(funcs, find_nominal_glyphs_Fct(func), user_data, find_destroy_Fct(destroy));
+}
+
+EXPORT void my_hb_font_funcs_set_variation_glyph_func(x64emu_t* emu, void* funcs, void* func, void* user_data, void* destroy)
+{
+ (void)emu;
+ my->hb_font_funcs_set_variation_glyph_func(funcs, find_variation_glyph_Fct(func), user_data, find_destroy_Fct(destroy));
+}
+
+EXPORT int my_hb_font_funcs_set_user_data(x64emu_t* emu, void* funcs, void* key, void* data, void* destroy, int replace)
+{
+ (void)emu;
+ return (int)my->hb_font_funcs_set_user_data(funcs, key, data, find_destroy_Fct(destroy), replace);
+}
+
+EXPORT int my_hb_font_set_funcs(x64emu_t* emu, void* font, void* klass, void* data, void* destroy)
+{
+ (void)emu;
+ my->hb_font_set_funcs(font, klass, data, find_destroy_Fct(destroy));
+}
+
+EXPORT int my_hb_font_set_funcs_data(x64emu_t* emu, void* font, void* data, void* destroy)
+{
+ (void)emu;
+ my->hb_font_set_funcs_data(font, data, find_destroy_Fct(destroy));
+}
+
+EXPORT int my_hb_font_set_user_data(x64emu_t* emu, void* font, void* key, void* data, void* destroy, int replace)
+{
+ (void)emu;
+ return (int)my->hb_font_set_user_data(font, key, data, find_destroy_Fct(destroy), replace);
+}
+
+#define CUSTOM_INIT \
+ getMy(lib);
+
+#define CUSTOM_FINI \
+ freeMy();
+
+#include "wrappedlib_init.h"
diff --git a/src/wrapped/wrappedlibharfbuzz_private.h b/src/wrapped/wrappedlibharfbuzz_private.h
new file mode 100644
index 0000000..2637f84
--- /dev/null
+++ b/src/wrapped/wrappedlibharfbuzz_private.h
@@ -0,0 +1,443 @@
+#if !(defined(GO) && defined(GOM) && defined(GO2) && defined(DATA))
+#error Meh...
+#endif
+
+GO(hb_aat_layout_feature_type_get_name_id, uFpu)
+GO(hb_aat_layout_feature_type_get_selector_infos, uFpuuppp)
+GO(hb_aat_layout_get_feature_types, uFpupp)
+GO(hb_aat_layout_has_positioning, iFp)
+GO(hb_aat_layout_has_substitution, iFp)
+GO(hb_aat_layout_has_tracking, iFp)
+GO(hb_blob_copy_writable_or_fail, pFp)
+GOM(hb_blob_create, pFEpuupp)
+GOM(hb_blob_create_or_fail, pFEpuupp)
+GO(hb_blob_create_from_file, pFp)
+GO(hb_blob_create_from_file_or_fail, pFp)
+GO(hb_blob_create_sub_blob, pFpuu)
+GO(hb_blob_destroy, vFp)
+GO(hb_blob_get_data, pFpp)
+GO(hb_blob_get_data_writable, pFpp)
+GO(hb_blob_get_empty, pFv)
+GO(hb_blob_get_length, uFp)
+GO(hb_blob_get_user_data, pFpp)
+GO(hb_blob_is_immutable, iFp)
+GO(hb_blob_make_immutable, vFp)
+GO(hb_blob_reference, pFp)
+GOM(hb_blob_set_user_data, iFEppppi)
+GO(hb_buffer_add, vFpuu)
+GO(hb_buffer_add_codepoints, vFppiui)
+GO(hb_buffer_add_latin1, vFppiui)
+GO(hb_buffer_add_utf16, vFppiui)
+GO(hb_buffer_add_utf32, vFppiui)
+GO(hb_buffer_add_utf8, vFppiui)
+GO(hb_buffer_allocation_successful, iFp)
+GO(hb_buffer_append, vFppuu)
+GO(hb_buffer_clear_contents, vFp)
+GO(hb_buffer_create, pFv)
+GO(hb_buffer_create_similar, pFp)
+GO(hb_buffer_deserialize_glyphs, iFppippu)
+GO(hb_buffer_deserialize_unicode, iFppipu)
+GO(hb_buffer_destroy, vFp)
+GO(hb_buffer_diff, uFppuu)
+GO(hb_buffer_get_cluster_level, uFp)
+GO(hb_buffer_get_content_type, uFp)
+GO(hb_buffer_get_direction, uFp)
+GO(hb_buffer_get_empty, pFv)
+GO(hb_buffer_get_flags, uFp)
+GO(hb_buffer_get_glyph_infos, pFpp)
+GO(hb_buffer_get_glyph_positions, pFpp)
+GO(hb_buffer_get_invisible_glyph, uFp)
+GO(hb_buffer_get_language, pFp)
+GO(hb_buffer_get_length, uFp)
+GO(hb_buffer_get_not_found_glyph, uFp)
+GO(hb_buffer_get_replacement_codepoint, uFp)
+GO(hb_buffer_get_script, uFp)
+GO(hb_buffer_get_segment_properties, vFpp)
+GO(hb_buffer_get_unicode_funcs, pFp)
+GO(hb_buffer_get_user_data, pFpp)
+GO(hb_buffer_guess_segment_properties, vFp)
+GO(hb_buffer_has_positions, iFp)
+GO(hb_buffer_normalize_glyphs, vFp)
+GO(hb_buffer_pre_allocate, iFpu)
+GO(hb_buffer_reference, pFp)
+GO(hb_buffer_reset, vFp)
+GO(hb_buffer_reverse, vFp)
+GO(hb_buffer_reverse_clusters, vFp)
+GO(hb_buffer_reverse_range, vFpuu)
+GO(hb_buffer_serialize, uFpuupuppuu)
+GO(hb_buffer_serialize_format_from_string, uFpi)
+GO(hb_buffer_serialize_format_to_string, pFu)
+GO(hb_buffer_serialize_glyphs, uFpuupuppuu)
+GO(hb_buffer_serialize_list_formats, pFv)
+GO(hb_buffer_serialize_unicode, uFpuupupuu)
+GO(hb_buffer_set_cluster_level, vFpu)
+GO(hb_buffer_set_content_type, vFpu)
+GO(hb_buffer_set_direction, vFpu)
+GO(hb_buffer_set_flags, vFpu)
+GO(hb_buffer_set_invisible_glyph, vFpu)
+GO(hb_buffer_set_language, vFpp)
+GO(hb_buffer_set_length, iFpu)
+GOM(hb_buffer_set_message_func, vFEpppp)
+GO(hb_buffer_set_not_found_glyph, vFpu)
+GO(hb_buffer_set_replacement_codepoint, vFpu)
+GO(hb_buffer_set_script, vFpu)
+GO(hb_buffer_set_segment_properties, vFpp)
+GO(hb_buffer_set_unicode_funcs, vFpp)
+GOM(hb_buffer_set_user_data, iFEppppi)
+GO(hb_color_get_alpha, CFu)
+GO(hb_color_get_blue, CFu)
+GO(hb_color_get_green, CFu)
+GO(hb_color_get_red, CFu)
+GO(hb_direction_from_string, uFpi)
+GO(hb_direction_to_string, pFu)
+GO(hb_draw_close_path, vFppp)
+GO(hb_draw_cubic_to, vFpppffffff)
+GO(hb_draw_funcs_create, pFv) // No need to reverse.
+GOM(hb_draw_funcs_destroy, vFEp)
+GO(hb_draw_funcs_is_immutable, iFp)
+GO(hb_draw_funcs_make_immutable, vFp)
+GO(hb_draw_funcs_reference, pFp)
+GOM(hb_draw_funcs_set_close_path_func, vFEpppp)
+GOM(hb_draw_funcs_set_cubic_to_func, vFEpppp)
+GOM(hb_draw_funcs_set_line_to_func, vFEpppp)
+GOM(hb_draw_funcs_set_move_to_func, vFEpppp)
+GOM(hb_draw_funcs_set_quadratic_to_func, vFEpppp)
+GO(hb_draw_line_to, vFpppff)
+GO(hb_draw_move_to, vFpppff)
+GO(hb_draw_quadratic_to, vFpppffff)
+GO(hb_face_builder_add_table, iFpup)
+GO(hb_face_builder_create, pFv)
+GO(hb_face_builder_sort_tables, vFpp)
+GO(hb_face_collect_unicodes, vFpp)
+GO(hb_face_collect_variation_selectors, vFpp)
+GO(hb_face_collect_variation_unicodes, vFpup)
+GO(hb_face_count, uFp)
+GO(hb_face_create, pFpu)
+GOM(hb_face_create_for_tables, pFEppp)
+GO(hb_face_destroy, vFp)
+GO(hb_face_get_empty, pFv)
+GO(hb_face_get_glyph_count, uFp)
+GO(hb_face_get_index, uFp)
+GO(hb_face_get_table_tags, uFpupp)
+GO(hb_face_get_upem, uFp)
+GO(hb_face_get_user_data, pFpp)
+GO(hb_face_is_immutable, iFp)
+GO(hb_face_make_immutable, vFp)
+GO(hb_face_reference, pFp)
+GO(hb_face_reference_blob, pFp)
+GO(hb_face_reference_table, pFpu)
+GO(hb_face_set_glyph_count, vFpu)
+GO(hb_face_set_index, vFpu)
+GO(hb_face_set_upem, vFpu)
+GOM(hb_face_set_user_data, iFEppppi)
+GO(hb_feature_from_string, iFpip)
+GO(hb_feature_to_string, vFppu)
+GO(hb_font_add_glyph_origin_for_direction, vFpuupp)
+GO(hb_font_changed, vFp)
+GO(hb_font_create, pFp)
+GO(hb_font_create_sub_font, pFp)
+GO(hb_font_destroy, vFp)
+GO(hb_font_funcs_create, pFv) // No need to reverse.
+GOM(hb_font_funcs_destroy, vFEp)
+GO(hb_font_funcs_get_empty, pFv)
+GO(hb_font_funcs_get_user_data, pFpp)
+GO(hb_font_funcs_is_immutable, iFp)
+GO(hb_font_funcs_make_immutable, vFp)
+GO(hb_font_funcs_reference, pFp)
+GOM(hb_font_funcs_set_font_h_extents_func, vFEpppp)
+GOM(hb_font_funcs_set_font_v_extents_func, vFEpppp)
+GOM(hb_font_funcs_set_glyph_h_advance_func, vFEpppp)
+GOM(hb_font_funcs_set_glyph_v_advance_func, vFEpppp)
+GOM(hb_font_funcs_set_glyph_h_advances_func, vFEpppp)
+GOM(hb_font_funcs_set_glyph_v_advances_func, vFEpppp)
+GOM(hb_font_funcs_set_glyph_h_kerning_func, vFEpppp)
+GOM(hb_font_funcs_set_glyph_v_kerning_func, vFEpppp)
+GOM(hb_font_funcs_set_glyph_h_origin_func, vFEpppp)
+GOM(hb_font_funcs_set_glyph_v_origin_func, vFEpppp)
+GOM(hb_font_funcs_set_glyph_contour_point_func, vFEpppp)
+GOM(hb_font_funcs_set_glyph_extents_func, vFEpppp)
+GOM(hb_font_funcs_set_glyph_from_name_func, vFEpppp)
+GOM(hb_font_funcs_set_glyph_func, vFEpppp)
+GOM(hb_font_funcs_set_glyph_name_func, vFEpppp)
+GOM(hb_font_funcs_set_glyph_shape_func, vFEpppp)
+GOM(hb_font_funcs_set_nominal_glyph_func, vFEpppp)
+GOM(hb_font_funcs_set_nominal_glyphs_func, vFEpppp)
+GOM(hb_font_funcs_set_variation_glyph_func, vFEpppp)
+GOM(hb_font_funcs_set_user_data, iFEppppi)
+GO(hb_font_get_empty, pFv)
+GO(hb_font_get_extents_for_direction, vFpup)
+GO(hb_font_get_face, pFp)
+GO(hb_font_get_glyph, iFpuup)
+GO(hb_font_get_glyph_advance_for_direction, vFpuupp)
+GO(hb_font_get_glyph_advances_for_direction, vFpuupupu)
+GO(hb_font_get_glyph_contour_point, iFpuupp)
+GO(hb_font_get_glyph_contour_point_for_origin, iFpuuupp)
+GO(hb_font_get_glyph_extents, iFpup)
+GO(hb_font_get_glyph_extents_for_origin, iFpuup)
+GO(hb_font_get_glyph_from_name, iFppip)
+GO(hb_font_get_glyph_h_advance, iFpu)
+GO(hb_font_get_glyph_h_advances, vFpupupu)
+GO(hb_font_get_glyph_h_kerning, iFpuu)
+GO(hb_font_get_glyph_h_origin, iFpupp)
+GO(hb_font_get_glyph_kerning_for_direction, vFpuuupp)
+GO(hb_font_get_glyph_name, iFpupu)
+GO(hb_font_get_glyph_origin_for_direction, vFpuupp)
+GO(hb_font_get_glyph_shape, vFpupp)
+GO(hb_font_get_glyph_v_advance, iFpu)
+GO(hb_font_get_glyph_v_advances, vFpupupu)
+GO(hb_font_get_glyph_v_kerning, iFpuu)
+GO(hb_font_get_glyph_v_origin, iFpupp)
+GO(hb_font_get_h_extents, iFpp)
+GO(hb_font_get_nominal_glyph, iFpup)
+GO(hb_font_get_nominal_glyphs, uFpupupu)
+GO(hb_font_get_parent, pFp)
+GO(hb_font_get_ppem, vFppp)
+GO(hb_font_get_ptem, fFp)
+GO(hb_font_get_scale, vFppp)
+GO(hb_font_get_serial, uFp)
+GO(hb_font_get_synthetic_slant, fFp)
+GO(hb_font_get_user_data, pFpp)
+GO(hb_font_get_var_coords_design, pFpp)
+GO(hb_font_get_var_coords_normalized, pFpp)
+GO(hb_font_get_variation_glyph, iFpuup)
+GO(hb_font_get_v_extents, iFpp)
+GO(hb_font_glyph_from_string, iFppip)
+GO(hb_font_glyph_to_string, vFpupu)
+GO(hb_font_is_immutable, iFp)
+GO(hb_font_make_immutable, vFp)
+GO(hb_font_reference, pFp)
+GO(hb_font_set_face, vFpp)
+GOM(hb_font_set_funcs, vFEpppp)
+GOM(hb_font_set_funcs_data, vFEppp)
+GO(hb_font_set_parent, vFpp)
+GO(hb_font_set_ppem, vFpuu)
+GO(hb_font_set_ptem, vFpf)
+GO(hb_font_set_scale, vFpii)
+GO(hb_font_set_synthetic_slant, vFpf)
+GOM(hb_font_set_user_data, iFEppppi)
+GO(hb_font_set_var_coords_design, vFppu)
+GO(hb_font_set_var_coords_normalized, vFppu)
+GO(hb_font_set_variations, vFppu)
+GO(hb_font_set_var_named_instance, vFpu)
+GO(hb_font_subtract_glyph_origin_for_direction, vFpuupp)
+//GO(hb_ft_face_create,
+GO(hb_ft_face_create_cached, pFp)
+GO(hb_ft_face_create_referenced, pFp)
+GO(hb_ft_font_changed, vFp)
+//GO(hb_ft_font_create,
+GO(hb_ft_font_create_referenced, pFp)
+GO(hb_ft_font_get_face, pFp)
+GO(hb_ft_font_get_load_flags, iFp)
+GO(hb_ft_font_lock_face, pFp)
+GO(hb_ft_font_set_funcs, vFp)
+GO(hb_ft_font_set_load_flags, vFpi)
+GO(hb_ft_font_unlock_face, vFp)
+GO(hb_ft_hb_font_changed, iFp)
+GO(hb_glib_blob_create, pFp)
+GO(hb_glib_get_unicode_funcs, pFv)
+GO(hb_glib_script_from_script, uFu)
+GO(hb_glib_script_to_script, uFu)
+GO(hb_glyph_info_get_glyph_flags, uFp)
+GO(hb_graphite2_face_get_gr_face, pFp)
+GO(hb_graphite2_font_get_gr_font, pFp)
+GO(hb_language_from_string, pFpi)
+GO(hb_language_get_default, pFv)
+GO(hb_language_matches, iFpp)
+GO(hb_language_to_string, pFp)
+GO(hb_map_allocation_successful, iFp)
+GO(hb_map_clear, vFp)
+GO(hb_map_copy, pFp)
+GO(hb_map_create, pFv)
+GO(hb_map_del, vFpu)
+GO(hb_map_destroy, vFp)
+GO(hb_map_get, uFpu)
+GO(hb_map_get_empty, pFv)
+GO(hb_map_get_population, uFp)
+GO(hb_map_get_user_data, pFpp)
+GO(hb_map_has, iFpu)
+GO(hb_map_hash, uFp)
+GO(hb_map_is_empty, iFp)
+GO(hb_map_is_equal, iFpp)
+GO(hb_map_reference, pFp)
+GO(hb_map_set, vFpuu)
+//GO(hb_map_set_user_data,
+GO(hb_ot_color_glyph_get_layers, uFpuupp)
+GO(hb_ot_color_glyph_reference_png, pFpu)
+GO(hb_ot_color_glyph_reference_svg, pFpu)
+GO(hb_ot_color_has_layers, iFp)
+GO(hb_ot_color_has_palettes, iFp)
+GO(hb_ot_color_has_png, iFp)
+GO(hb_ot_color_has_svg, iFp)
+GO(hb_ot_color_palette_color_get_name_id, uFpu)
+GO(hb_ot_color_palette_get_colors, uFpuupp)
+GO(hb_ot_color_palette_get_count, uFp)
+GO(hb_ot_color_palette_get_flags, uFpu)
+GO(hb_ot_color_palette_get_name_id, uFpu)
+GO(hb_ot_font_set_funcs, vFp)
+GO(hb_ot_layout_collect_features, vFpupppp)
+GO(hb_ot_layout_collect_lookups, vFpupppp)
+GO(hb_ot_layout_feature_get_characters, uFpuuupp)
+GO(hb_ot_layout_feature_get_lookups, uFpuuupp)
+GO(hb_ot_layout_feature_get_name_ids, iFpuuppppp)
+GO(hb_ot_layout_feature_with_variations_get_lookups, uFpuuuupp)
+GO(hb_ot_layout_get_attach_points, uFpuupp)
+GO(hb_ot_layout_get_baseline, iFpuuuup)
+GO(hb_ot_layout_get_baseline_with_fallback, vFpuuuup)
+GO(hb_ot_layout_get_glyph_class, uFpu)
+GO(hb_ot_layout_get_glyphs_in_class, vFpup)
+GO(hb_ot_layout_get_horizontal_baseline_tag_for_script, uFu)
+GO(hb_ot_layout_get_ligature_carets, uFpuuupp)
+GO(hb_ot_layout_get_size_params, iFpppppp)
+GO(hb_ot_layout_has_glyph_classes, iFp)
+GO(hb_ot_layout_has_positioning, iFp)
+GO(hb_ot_layout_has_substitution, iFp)
+GO(hb_ot_layout_language_find_feature, iFpuuuup)
+GO(hb_ot_layout_language_get_feature_indexes, uFpuuuupp)
+GO(hb_ot_layout_language_get_feature_tags, uFpuuuupp)
+GO(hb_ot_layout_language_get_required_feature, iFpuuupp)
+GO(hb_ot_layout_language_get_required_feature_index, iFpuuup)
+GO(hb_ot_layout_lookup_collect_glyphs, vFpuupppp)
+GO(hb_ot_layout_lookup_get_glyph_alternates, uFpuuupp)
+GO(hb_ot_layout_lookup_get_optical_bound, iFpuuu)
+GO(hb_ot_layout_lookups_substitute_closure, vFppp)
+GO(hb_ot_layout_lookup_substitute_closure, vFpup)
+GO(hb_ot_layout_lookup_would_substitute, iFpupui)
+GO(hb_ot_layout_script_find_language, iFpuuup)
+GO(hb_ot_layout_script_get_language_tags, uFpuuupp)
+GO(hb_ot_layout_script_select_language, iFpuuupp)
+GO(hb_ot_layout_table_choose_script, iFpuppp)
+GO(hb_ot_layout_table_find_feature_variations, iFpupup)
+GO(hb_ot_layout_table_find_script, iFpuup)
+GO(hb_ot_layout_table_get_feature_tags, uFpuupp)
+GO(hb_ot_layout_table_get_lookup_count, uFpu)
+GO(hb_ot_layout_table_get_script_tags, uFpuupp)
+GO(hb_ot_layout_table_select_script, iFpuuppp)
+GO(hb_ot_math_get_constant, iFpu)
+GO(hb_ot_math_get_glyph_assembly, uFpuuuppp)
+GO(hb_ot_math_get_glyph_italics_correction, iFpu)
+GO(hb_ot_math_get_glyph_kerning, iFpuui)
+GO(hb_ot_math_get_glyph_kernings, uFpuuupp)
+GO(hb_ot_math_get_glyph_top_accent_attachment, iFpu)
+GO(hb_ot_math_get_glyph_variants, uFpuuupp)
+GO(hb_ot_math_get_min_connector_overlap, iFpu)
+GO(hb_ot_math_has_data, iFp)
+GO(hb_ot_math_is_glyph_extended_shape, iFpu)
+GO(hb_ot_meta_get_entry_tags, uFpupp)
+GO(hb_ot_meta_reference_entry, pFpu)
+GO(hb_ot_metrics_get_position, iFpup)
+GO(hb_ot_metrics_get_position_with_fallback, vFpup)
+GO(hb_ot_metrics_get_variation, fFpu)
+GO(hb_ot_metrics_get_x_variation, iFpu)
+GO(hb_ot_metrics_get_y_variation, iFpu)
+GO(hb_ot_name_get_utf16, uFpuppp)
+GO(hb_ot_name_get_utf32, uFpuppp)
+GO(hb_ot_name_get_utf8, uFpuppp)
+GO(hb_ot_name_list_names, pFpp)
+GO(hb_ot_shape_glyphs_closure, vFpppup)
+GO(hb_ot_shape_plan_collect_lookups, vFpup)
+GO(hb_ot_tag_from_language, uFp)
+GO(hb_ot_tags_from_script, vFupp)
+GO(hb_ot_tags_from_script_and_language, vFuppppp)
+GO(hb_ot_tags_to_script_and_language, vFuupp)
+GO(hb_ot_tag_to_language, pFu)
+GO(hb_ot_tag_to_script, uFu)
+GO(hb_ot_var_find_axis, iFpupp)
+GO(hb_ot_var_find_axis_info, iFpup)
+GO(hb_ot_var_get_axes, uFpupp)
+GO(hb_ot_var_get_axis_count, uFp)
+GO(hb_ot_var_get_axis_infos, uFpupp)
+GO(hb_ot_var_get_named_instance_count, uFp)
+GO(hb_ot_var_has_data, iFp)
+GO(hb_ot_var_named_instance_get_design_coords, uFpupp)
+GO(hb_ot_var_named_instance_get_postscript_name_id, uFpu)
+GO(hb_ot_var_named_instance_get_subfamily_name_id, uFpu)
+GO(hb_ot_var_normalize_coords, vFpupp)
+GO(hb_ot_var_normalize_variations, vFppupu)
+GO(hb_script_from_iso15924_tag, uFu)
+GO(hb_script_from_string, uFpi)
+GO(hb_script_get_horizontal_direction, uFu)
+GO(hb_script_to_iso15924_tag, uFu)
+GO(hb_segment_properties_equal, iFpp)
+GO(hb_segment_properties_hash, uFp)
+GO(hb_segment_properties_overlay, vFpp)
+GO(hb_set_add, vFpu)
+GO(hb_set_add_range, vFpuu)
+GO(hb_set_add_sorted_array, vFppu)
+GO(hb_set_allocation_successful, iFp)
+GO(hb_set_clear, vFp)
+GO(hb_set_copy, pFp)
+GO(hb_set_create, pFv)
+GO(hb_set_del, vFpu)
+GO(hb_set_del_range, vFpuu)
+GO(hb_set_destroy, vFp)
+GO(hb_set_get_empty, pFv)
+GO(hb_set_get_max, uFp)
+GO(hb_set_get_min, uFp)
+GO(hb_set_get_population, uFp)
+GO(hb_set_get_user_data, pFpp)
+GO(hb_set_has, iFpu)
+GO(hb_set_hash, uFp)
+GO(hb_set_intersect, vFpp)
+GO(hb_set_invert, vFp)
+GO(hb_set_is_empty, iFp)
+GO(hb_set_is_equal, iFpp)
+GO(hb_set_is_subset, iFpp)
+GO(hb_set_next, iFpp)
+GO(hb_set_next_many, uFpupu)
+GO(hb_set_next_range, iFppp)
+GO(hb_set_previous, iFpp)
+GO(hb_set_previous_range, iFppp)
+GO(hb_set_reference, pFp)
+GO(hb_set_set, vFpp)
+//GO(hb_set_set_user_data,
+GO(hb_set_subtract, vFpp)
+GO(hb_set_symmetric_difference, vFpp)
+GO(hb_set_union, vFpp)
+GO(hb_shape, vFpppu)
+GO(hb_shape_full, iFpppup)
+GO(hb_shape_list_shapers, pFv)
+GO(hb_shape_plan_create, pFpppup)
+GO(hb_shape_plan_create2, pFpppupup)
+GO(hb_shape_plan_create_cached, pFpppup)
+GO(hb_shape_plan_create_cached2, pFpppupup)
+GO(hb_shape_plan_destroy, vFp)
+GO(hb_shape_plan_execute, iFppppu)
+GO(hb_shape_plan_get_empty, pFv)
+GO(hb_shape_plan_get_shaper, pFp)
+GO(hb_shape_plan_get_user_data, pFpp)
+GO(hb_shape_plan_reference, pFp)
+//GO(hb_shape_plan_set_user_data,
+GO(hb_style_get_value, fFpu)
+GO(hb_tag_from_string, uFpi)
+GO(hb_tag_to_string, vFup)
+GO(hb_unicode_combining_class, uFpu)
+GO(hb_unicode_compose, iFpuup)
+GO(hb_unicode_decompose, iFpupp)
+GO(hb_unicode_decompose_compatibility, uFpup)
+GO(hb_unicode_eastasian_width, uFpu)
+GO(hb_unicode_funcs_create, pFp)
+GO(hb_unicode_funcs_destroy, vFp)
+GO(hb_unicode_funcs_get_default, pFv)
+GO(hb_unicode_funcs_get_empty, pFv)
+GO(hb_unicode_funcs_get_parent, pFp)
+GO(hb_unicode_funcs_get_user_data, pFpp)
+GO(hb_unicode_funcs_is_immutable, iFp)
+GO(hb_unicode_funcs_make_immutable, vFp)
+GOM(hb_unicode_funcs_reference, pFEp)
+GOM(hb_unicode_funcs_set_combining_class_func, vFEpppp)
+GOM(hb_unicode_funcs_set_compose_func, vFEpppp)
+GOM(hb_unicode_funcs_set_decompose_compatibility_func, vFEpppp)
+GOM(hb_unicode_funcs_set_decompose_func, vFEpppp)
+GOM(hb_unicode_funcs_set_eastasian_width_func, vFEpppp)
+GOM(hb_unicode_funcs_set_general_category_func, vFEpppp)
+GOM(hb_unicode_funcs_set_mirroring_func, vFEpppp)
+GOM(hb_unicode_funcs_set_script_func, vFEpppp)
+GOM(hb_unicode_funcs_set_user_data, iFEppppi)
+GO(hb_unicode_general_category, uFpu)
+GO(hb_unicode_mirroring, uFpu)
+GO(hb_unicode_script, uFpu)
+GO(hb_variation_from_string, iFpip)
+GO(hb_variation_to_string, vFppu)
+GO(hb_version, vFppp)
+GO(hb_version_atleast, iFuuu)
+GO(hb_version_string, pFv)
diff --git a/src/wrapped/wrappedlibibus.c b/src/wrapped/wrappedlibibus.c
index 95ea0f8..22d83a2 100644
--- a/src/wrapped/wrappedlibibus.c
+++ b/src/wrapped/wrappedlibibus.c
@@ -38,7 +38,7 @@ GO(3)
static uintptr_t my_GAsyncReadyCallback_fct_##A = 0; \
static void my_GAsyncReadyCallback_##A(void* source, void* res, void* data) \
{ \
- RunFunction(my_context, my_GAsyncReadyCallback_fct_##A, 3, source, res, data);\
+ RunFunctionFmt(my_GAsyncReadyCallback_fct_##A, "ppp", source, res, data);\
}
SUPER()
#undef GO
diff --git a/src/wrapped/wrappedlibice.c b/src/wrapped/wrappedlibice.c
index 3a3ff74..3a3ff74 100755..100644
--- a/src/wrapped/wrappedlibice.c
+++ b/src/wrapped/wrappedlibice.c
diff --git a/src/wrapped/wrappedlibice_private.h b/src/wrapped/wrappedlibice_private.h
index 813d599..813d599 100755..100644
--- a/src/wrapped/wrappedlibice_private.h
+++ b/src/wrapped/wrappedlibice_private.h
diff --git a/src/wrapped/wrappedlibm.c b/src/wrapped/wrappedlibm.c
index 43bdf5c..43bdf5c 100755..100644
--- a/src/wrapped/wrappedlibm.c
+++ b/src/wrapped/wrappedlibm.c
diff --git a/src/wrapped/wrappedlibm_private.h b/src/wrapped/wrappedlibm_private.h
index 962d528..16a2f0e 100755..100644
--- a/src/wrapped/wrappedlibm_private.h
+++ b/src/wrapped/wrappedlibm_private.h
@@ -53,28 +53,28 @@ GOW(atanhl, DFD)
GO2(atanhl, KFK, atanh)
#endif
// atanl // Weak
-GOW(cabs, dFdd) // only 1 arg, but is a double complex
-GOW(cabsf, fFff) // only 1 arg, but is a float complex
+GOW(cabs, XFX)
+GOW(cabsf, xFx)
// cabsl // Weak
-GOS(cacos, pFpV) // Weak, complex
-GOM(cacosf, UFV) // Weak
-GOS(cacosh, pFpV) // Weak, complex
-GOM(cacoshf, UFV) // Weak
+GOW(cacos, XFX)
+GOW(cacosf, xFx)
+GOW(cacosh, XFX)
+GOW(cacoshf, xFx)
// cacoshl // Weak
// cacosl // Weak
-GOW(carg, dFdd) // 1arg, double complex
-GOW(cargf, fFff) // 1arg, float complex
+GOW(carg, XFX)
+GOW(cargf, xFx)
// cargl // Weak
-GOS(casin, pFpV) // Weak, complex
-GOM(casinf, UFV) // Weak
-GOS(casinh, pFpV) // Weak, complex
-GOM(casinhf, UFV) // Weak
+GOW(casin, XFX)
+GOW(casinf, xFx)
+GOW(casinh, XFX)
+GOW(casinhf, xFx)
// casinhl // Weak
// casinl // Weak
-GOS(catan, pFpV) // Weak, complex
-GOM(catanf, UFV) // Weak
-GOS(catanh, pFpV) // Weak, complex
-GOM(catanhf, UFV) // Weak
+GOS(catan, XFX)
+GOM(catanf, xFx)
+GOS(catanh, XFX)
+GOM(catanhf, xFx)
// catanhl // Weak
// catanl // Weak
GOW(cbrt, dFd)
@@ -84,10 +84,10 @@ GOW(cbrtl, DFD)
#else
GO2(cbrtl, KFK, cbrt)
#endif
-//GOS(ccos, pFpV) // Weak, return complex
-//GOM(ccosf, UFV) // Weak, return complex
-//GOS(ccosh, pFpV) // Weak, return complex
-//GOM(ccoshf, UFV) // Weak, return complex
+GOW(ccos, XFX)
+GOW(ccosf, xFx)
+GOW(ccosh, XFX)
+GOW(ccoshf, xFx)
// ccoshl // Weak
// ccosl // Weak
GOW(ceil, dFd)
@@ -97,13 +97,13 @@ GOW(ceill, DFD) // Weak
#else
GO2(ceill, KFK, ceil)
#endif
-//GOS(cexp, pFpV) // Weak, return complex
-//GOM(cexpf, UFV) // Weak, return complex
+GOW(cexp, XFX)
+GOW(cexpf, xFx)
// cexpl // Weak
// cimag // Weak
// cimagf // Weak
// cimagl // Weak
-//GOS(clog, pFpV) // return a double complex, so ret 4
+GOW(clog, XFX)
// clog10 // Weak
// __clog10
// clog10f // Weak
@@ -126,28 +126,28 @@ GOM(__coshf_finite, fFf)
GOM(__cosh_finite, dFd)
// coshl // Weak
// cosl // Weak
-//GOS(cpow, pFpVvvvvV) // Weak, return complex
-//GOM(cpowf, UFVvvV) // Weak
+GOW(cpow, XFXX)
+GOW(cpowf, xFxx)
// cpowl // Weak
-//GOS(cproj, pFpV) // double complex
-//GOM(cprojf, UFV)
+GOW(cproj, XFX)
+GOW(cprojf, xFx)
// cprojl // Weak
// creal // Weak
// crealf // Weak
// creall // Weak
-//GOS(csin, pFpV) // Weak, return complex
-//GOM(csinf, UFV) // Weak, return complex
-//GOS(csinh, pFpV) // Weak, return complex
-//GOM(csinhf, UFV) // Weak, return complex
+GOW(csin, XFX)
+GOW(csinf, xFx)
+GOW(csinh, XFX)
+GOW(csinhf, xFx)
// csinhl // Weak
// csinl // Weak
-//GOS(csqrt, pFpV)
-//GOS(csqrtf, UFV) // Weak
+GOW(csqrt, XFX)
+GOW(csqrtf, xFx)
// csqrtl // Weak
-//GOS(ctan, pFpV) // Weak, return complex
-//GOM(ctanf, UFV) // Weak, return complex
-//GOS(ctanh, pFpV) // Weak, return complex
-//GOM(ctanhf, UFV) // Weak, return complex
+GOW(ctan, XFX)
+GOW(ctanf, xFx)
+GOW(ctanh, XFX)
+GOW(ctanhf, xFx)
// ctanhl // Weak
// ctanl // Weak
// __cxa_finalize // Weak
@@ -182,7 +182,11 @@ GOM(__exp2_finite, dFd)
GOW(expf, fFf)
GOM(__expf_finite, fFf)
GOM(__exp_finite, dFd)
-// expl // Weak
+#ifdef HAVE_LD80BITS
+GOW(expl, DFD)
+#else
+GO2(expl, KFK, exp)
+#endif
GOW(expm1, dFd)
GOW(expm1f, fFf)
// expm1l // Weak
@@ -393,6 +397,9 @@ GOW(rintf, fFf)
// rintl // Weak
GOW(round, dFd)
GOW(roundf, fFf)
+GO(roundeven, dFd) //since C23
+GO(roundevenf, fFf)
+//GO(roundevenl, DFD)
// roundl // Weak
// scalb // Weak
// scalbf // Weak
diff --git a/src/wrapped/wrappedlibncurses.c b/src/wrapped/wrappedlibncurses.c
index bd20f90..bd20f90 100755..100644
--- a/src/wrapped/wrappedlibncurses.c
+++ b/src/wrapped/wrappedlibncurses.c
diff --git a/src/wrapped/wrappedlibncurses6.c b/src/wrapped/wrappedlibncurses6.c
index 4fe26c7..4fe26c7 100755..100644
--- a/src/wrapped/wrappedlibncurses6.c
+++ b/src/wrapped/wrappedlibncurses6.c
diff --git a/src/wrapped/wrappedlibncurses6_private.h b/src/wrapped/wrappedlibncurses6_private.h
index b7153d2..b7153d2 100755..100644
--- a/src/wrapped/wrappedlibncurses6_private.h
+++ b/src/wrapped/wrappedlibncurses6_private.h
diff --git a/src/wrapped/wrappedlibncurses_private.h b/src/wrapped/wrappedlibncurses_private.h
index ef182ab..ef182ab 100755..100644
--- a/src/wrapped/wrappedlibncurses_private.h
+++ b/src/wrapped/wrappedlibncurses_private.h
diff --git a/src/wrapped/wrappedlibncursesw.c b/src/wrapped/wrappedlibncursesw.c
index 2beb3e7..2beb3e7 100755..100644
--- a/src/wrapped/wrappedlibncursesw.c
+++ b/src/wrapped/wrappedlibncursesw.c
diff --git a/src/wrapped/wrappedlibncursesw6.c b/src/wrapped/wrappedlibncursesw6.c
index 4e440dc..4e440dc 100755..100644
--- a/src/wrapped/wrappedlibncursesw6.c
+++ b/src/wrapped/wrappedlibncursesw6.c
diff --git a/src/wrapped/wrappedlibncursesw6_private.h b/src/wrapped/wrappedlibncursesw6_private.h
index ef182ab..ef182ab 100755..100644
--- a/src/wrapped/wrappedlibncursesw6_private.h
+++ b/src/wrapped/wrappedlibncursesw6_private.h
diff --git a/src/wrapped/wrappedlibncursesw_private.h b/src/wrapped/wrappedlibncursesw_private.h
index b7153d2..b7153d2 100755..100644
--- a/src/wrapped/wrappedlibncursesw_private.h
+++ b/src/wrapped/wrappedlibncursesw_private.h
diff --git a/src/wrapped/wrappedlibnuma.c b/src/wrapped/wrappedlibnuma.c
new file mode 100644
index 0000000..86fcb9f
--- /dev/null
+++ b/src/wrapped/wrappedlibnuma.c
@@ -0,0 +1,25 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#define _GNU_SOURCE /* See feature_test_macros(7) */
+#include <dlfcn.h>
+
+#include "wrappedlibs.h"
+
+#include "debug.h"
+#include "wrapper.h"
+#include "bridge.h"
+#include "librarian/library_private.h"
+#include "x64emu.h"
+#include "emu/x64emu_private.h"
+#include "callback.h"
+#include "librarian.h"
+#include "box64context.h"
+#include "emu/x64emu_private.h"
+#include "myalign.h"
+
+const char* libnumaName = "libnuma.so.1";
+#define LIBNAME libnuma
+
+#include "wrappedlib_init.h"
+
diff --git a/src/wrapped/wrappedlibnuma_private.h b/src/wrapped/wrappedlibnuma_private.h
new file mode 100644
index 0000000..554cdcb
--- /dev/null
+++ b/src/wrapped/wrappedlibnuma_private.h
@@ -0,0 +1,107 @@
+#if !(defined(GO) && defined(GOM) && defined(GO2) && defined(DATA))
+#error meh!
+#endif
+
+GO(copy_bitmask_to_bitmask, vFpp)
+GO(copy_bitmask_to_nodemask, vFpp)
+GO(copy_nodemask_to_bitmask, vFpp)
+//GOW(get_mempolicy,
+GOW(mbind, iFpLipLu)
+//GOW(migrate_pages,
+//GOW(move_pages,
+DATAB(numa_all_cpus_ptr, sizeof(void*))
+//DATAB(numa_all_nodes,
+DATAB(numa_all_nodes_ptr, sizeof(void*))
+GO(numa_alloc, pFL)
+GO(numa_allocate_cpumask, pFv)
+GO(numa_allocate_nodemask, pFv)
+GO(numa_alloc_interleaved, pFL)
+GO(numa_alloc_interleaved_subset, pFLp)
+//GO2(numa_alloc_interleaved_subset@libnuma_1.1,
+GO(numa_alloc_local, pFL)
+GO(numa_alloc_onnode, pFLi)
+GO(numa_available, iFv)
+GO(numa_bind, vFp)
+//GO2(numa_bind@libnuma_1.1,
+GO(numa_bitmask_alloc, pFu)
+GO(numa_bitmask_clearall, pFp)
+GO(numa_bitmask_clearbit, pFpu)
+GO(numa_bitmask_equal, iFpp)
+GO(numa_bitmask_free, vFp)
+GO(numa_bitmask_isbitset, iFpu)
+GO(numa_bitmask_nbytes, uFp)
+GO(numa_bitmask_setall, pFp)
+GO(numa_bitmask_setbit, pFpu)
+GO(numa_bitmask_weight, uFp)
+GO(numa_distance, iFii)
+GOW(numa_error, vFp)
+DATAB(numa_exit_on_error, sizeof(int))
+DATAB(numa_exit_on_warn, sizeof(int))
+GO(numa_free, vFpL)
+//GO2(numa_get_interleave_mask@libnuma_1.1,
+GO(numa_get_interleave_mask, pFv)
+GO(numa_get_interleave_node, iFv)
+GO(numa_get_membind, pFv)
+//GO2(numa_get_membind@libnuma_1.1,
+GO(numa_get_mems_allowed, pFv)
+//GO2(numa_get_run_node_mask@libnuma_1.1,
+GO(numa_get_run_node_mask, pFv)
+//GO(numa_has_preferred_many,
+//GO2(numa_interleave_memory@libnuma_1.1,
+GO(numa_interleave_memory, vFpLp)
+GO(numa_max_node, iFv)
+GO(numa_max_possible_node, iFv)
+GO(numa_migrate_pages, iFipp)
+GO(numa_move_pages, iFiLpppi)
+GO(numa_node_of_cpu, iFi)
+GO(numa_node_size, lFip)
+GO(numa_node_size64, IFip)
+//DATAB(numa_nodes_ptr,
+//GO2(numa_node_to_cpus@libnuma_1.1,
+GO(numa_node_to_cpus, iFip)
+//GO(numa_node_to_cpu_update,
+//DATAB(numa_no_nodes,
+DATAB(numa_no_nodes_ptr, sizeof(void*))
+GO(numa_num_configured_cpus, iFv)
+GO(numa_num_configured_nodes, iFv)
+//GO(numa_num_possible_cpus,
+GO(numa_num_possible_nodes, iFv)
+GO(numa_num_task_cpus, iFv)
+GO(numa_num_task_nodes, iFv)
+//GO(numa_num_thread_cpus,
+//GO(numa_num_thread_nodes,
+//GO(numa_pagesize,
+GO(numa_parse_bitmap, iFpp)
+//GO2(numa_parse_bitmap@libnuma_1.1,
+GO(numa_parse_cpustring, pFp)
+//GO(numa_parse_cpustring_all,
+GO(numa_parse_nodestring, pFp)
+//GO(numa_parse_nodestring_all,
+GO(numa_police_memory, vFpL)
+GO(numa_preferred, iFv)
+//GO(numa_preferred_many,
+GO(numa_realloc, pFpLL)
+GO(numa_run_on_node, iFi)
+GO(numa_run_on_node_mask, iFp)
+//GO2(numa_run_on_node_mask@libnuma_1.1,
+//GO(numa_run_on_node_mask_all,
+GO(numa_sched_getaffinity, iFip)
+//GO2(numa_sched_getaffinity@libnuma_1.1,
+GO(numa_sched_setaffinity, iFip)
+//GO2(numa_sched_setaffinity@libnuma_1.1,
+GO(numa_set_bind_policy, vFi)
+GO(numa_set_interleave_mask, vFp)
+//GO2(numa_set_interleave_mask@libnuma_1.1,
+GO(numa_set_localalloc, vFv)
+GO(numa_setlocal_memory, vFpL)
+GO(numa_set_membind, vFp)
+//GO2(numa_set_membind@libnuma_1.1,
+//GO(numa_set_membind_balancing,
+GO(numa_set_preferred, vFi)
+//GO(numa_set_preferred_many,
+GO(numa_set_strict, vFi)
+GO(numa_tonodemask_memory, vFpLp)
+//GO2(numa_tonodemask_memory@libnuma_1.1,
+GO(numa_tonode_memory, vFpLi)
+GOW(numa_warn, vFippppppppppppp) //use VAARG with printf style, should wrap if used
+//GOW(set_mempolicy,
diff --git a/src/wrapped/wrappedlibogg.c b/src/wrapped/wrappedlibogg.c
index f922d8a..f922d8a 100755..100644
--- a/src/wrapped/wrappedlibogg.c
+++ b/src/wrapped/wrappedlibogg.c
diff --git a/src/wrapped/wrappedlibogg_private.h b/src/wrapped/wrappedlibogg_private.h
index 3440cc2..3440cc2 100755..100644
--- a/src/wrapped/wrappedlibogg_private.h
+++ b/src/wrapped/wrappedlibogg_private.h
diff --git a/src/wrapped/wrappedlibpanel.c b/src/wrapped/wrappedlibpanel.c
index 9d706b5..9d706b5 100755..100644
--- a/src/wrapped/wrappedlibpanel.c
+++ b/src/wrapped/wrappedlibpanel.c
diff --git a/src/wrapped/wrappedlibpanel_private.h b/src/wrapped/wrappedlibpanel_private.h
index 31a7431..31a7431 100755..100644
--- a/src/wrapped/wrappedlibpanel_private.h
+++ b/src/wrapped/wrappedlibpanel_private.h
diff --git a/src/wrapped/wrappedlibpcre.c b/src/wrapped/wrappedlibpcre.c
index 1175f7d..9d3b606 100755..100644
--- a/src/wrapped/wrappedlibpcre.c
+++ b/src/wrapped/wrappedlibpcre.c
@@ -20,7 +20,7 @@ typedef void (*pcre_free_t)(void *);
EXPORT uintptr_t my_pcre_free;
void wrapped_pcre_free(void* p) {
- RunFunction(my_context, my_pcre_free, 1, p);
+ RunFunctionFmt(my_pcre_free, "p", p);
}
EXPORT pcre_free_t pcre_free = wrapped_pcre_free;
diff --git a/src/wrapped/wrappedlibpcre_private.h b/src/wrapped/wrappedlibpcre_private.h
index b851fc3..b851fc3 100755..100644
--- a/src/wrapped/wrappedlibpcre_private.h
+++ b/src/wrapped/wrappedlibpcre_private.h
diff --git a/src/wrapped/wrappedlibpthread.c b/src/wrapped/wrappedlibpthread.c
index d29218e..d29218e 100755..100644
--- a/src/wrapped/wrappedlibpthread.c
+++ b/src/wrapped/wrappedlibpthread.c
diff --git a/src/wrapped/wrappedlibpthread_private.h b/src/wrapped/wrappedlibpthread_private.h
index 2c16c02..c0fd055 100755..100644
--- a/src/wrapped/wrappedlibpthread_private.h
+++ b/src/wrapped/wrappedlibpthread_private.h
@@ -5,20 +5,20 @@
// cpu_set_t is a struct with an array, default size is fixed for all architecture
// pthread_t is like unsigned long
-// __errno_location
-// fork
-// __fork
-// __h_errno_location
-// _IO_flockfile
-// _IO_ftrylockfile
-// _IO_funlockfile
-// __libc_allocate_rtsig
-// __libc_current_sigrtmax
-// __libc_current_sigrtmin
+//GO(__errno_location,
+//GO(fork,
+//GO(__fork,
+//GO(__h_errno_location,
+//GO(_IO_flockfile,
+//GO(_IO_ftrylockfile,
+//GO(_IO_funlockfile,
+//GO(__libc_allocate_rtsig,
+//GO(__libc_current_sigrtmax,
+//GO(__libc_current_sigrtmin,
GOM(pthread_atfork, iFEppp)
GOM(__pthread_atfork, iFEppp)
GOM(pthread_attr_destroy, iFEp)
-// pthread_attr_getaffinity_np
+//GO(pthread_attr_getaffinity_np,
#ifdef NOALIGN
GO(pthread_attr_getdetachstate, iFpp)
GO(pthread_attr_getguardsize, iFpp)
@@ -85,7 +85,7 @@ GOM(_pthread_cleanup_pop, vFEpi)
GOM(_pthread_cleanup_pop_restore, vFEpi)
GOM(_pthread_cleanup_push, vFEppp)
GOM(_pthread_cleanup_push_defer, vFEppp)
-// __pthread_cleanup_routine
+//GO(__pthread_cleanup_routine,
#ifdef NOALIGN
GO(pthread_condattr_destroy, iFp)
GO(pthread_condattr_getclock, iFpp)
@@ -93,6 +93,9 @@ GO(pthread_condattr_getpshared, iFpp)
GO(pthread_condattr_init, iFp)
GO(pthread_condattr_setclock, iFpi)
GO(pthread_condattr_setpshared, iFpi)
+GO(pthread_cond_broadcast, iFp)
+GO(pthread_cond_destroy, iFp)
+GO(pthread_cond_init, iFpp)
#else
GOM(pthread_condattr_destroy, iFEp)
GOM(pthread_condattr_getclock, iFEpp)
@@ -100,12 +103,6 @@ GOM(pthread_condattr_getpshared, iFEpp)
GOM(pthread_condattr_init, iFEp)
GOM(pthread_condattr_setclock, iFEpi)
GOM(pthread_condattr_setpshared, iFEpi)
-#endif
-#ifdef NOALIGN
-GO(pthread_cond_broadcast, iFp)
-GO(pthread_cond_destroy, iFp)
-GO(pthread_cond_init, iFpp)
-#else
GOM(pthread_cond_broadcast, iFEp)
GOM(pthread_cond_destroy, iFEp)
GOM(pthread_cond_init, iFEpp)
@@ -134,7 +131,7 @@ GO(pthread_getschedparam, iFLpp)
GO(__pthread_getspecific, pFL)
GO(pthread_getspecific, pFL)
GO(pthread_getname_np, iFppL)
-// __pthread_initialize_minimal
+//GO(__pthread_initialize_minimal,
GO(pthread_join, iFLp)
GOM(__pthread_key_create, iFEpp)
GOM(pthread_key_create, iFEpp)
@@ -146,91 +143,85 @@ GO(pthread_kill_other_threads_np, vFv)
GO(__pthread_mutexattr_destroy, iFp)
GO(pthread_mutexattr_destroy, iFp)
GO(pthread_mutexattr_getkind_np, iFpp)
-// pthread_mutexattr_getprioceiling
+//GO(pthread_mutexattr_getprioceiling,
GO(pthread_mutexattr_getprotocol, iFpp)
-// pthread_mutexattr_getpshared
-// pthread_mutexattr_getrobust_np
+//GO(pthread_mutexattr_getpshared,
+GO(pthread_mutexattr_getrobust, iFpp)
+//GO(pthread_mutexattr_getrobust_np,
GO(pthread_mutexattr_gettype, iFpp)
GO(__pthread_mutexattr_init, iFp)
GO(pthread_mutexattr_init, iFp)
GO(pthread_mutexattr_setkind_np, iFpi)
-// pthread_mutexattr_setprioceiling
+//GO(pthread_mutexattr_setprioceiling,
GO(pthread_mutexattr_setprotocol, iFpi)
GO(pthread_mutexattr_setpshared, iFpi)
-// pthread_mutexattr_setrobust_np
+GO(pthread_mutexattr_setrobust, iFpi)
+//GO(pthread_mutexattr_setrobust_np,
GO(__pthread_mutexattr_settype, iFpi)
GO(pthread_mutexattr_settype, iFpi)
#else
GOM(__pthread_mutexattr_destroy, iFEp)
GOM(pthread_mutexattr_destroy, iFEp)
GOM(pthread_mutexattr_getkind_np, iFEpp)
-// pthread_mutexattr_getprioceiling
+//GO(pthread_mutexattr_getprioceiling,
GOM(pthread_mutexattr_getprotocol, iFEpp)
-// pthread_mutexattr_getpshared
-// pthread_mutexattr_getrobust_np
+//GO(pthread_mutexattr_getpshared,
+GOM(pthread_mutexattr_getrobust, iFEpp)
+//GO(pthread_mutexattr_getrobust_np,
GOM(pthread_mutexattr_gettype, iFEpp)
GOM(__pthread_mutexattr_init, iFEp)
GOM(pthread_mutexattr_init, iFEp)
GOM(pthread_mutexattr_setkind_np, iFEpi)
-// pthread_mutexattr_setprioceiling
+//GO(pthread_mutexattr_setprioceiling,
GOM(pthread_mutexattr_setprotocol, iFEpi)
GOM(pthread_mutexattr_setpshared, iFEpi)
-// pthread_mutexattr_setrobust_np
+GOM(pthread_mutexattr_setrobust, iFEpi)
+//GO(pthread_mutexattr_setrobust_np,
GOM(__pthread_mutexattr_settype, iFEpi)
GOM(pthread_mutexattr_settype, iFEpi)
#endif
-// pthread_mutex_consistent_np
-#ifdef NOALIGN
+//GO(pthread_mutex_consistent_np,
+GO(pthread_mutex_consistent, iFp)
GO(__pthread_mutex_destroy, iFp)
GO(pthread_mutex_destroy, iFp)
-// pthread_mutex_getprioceiling
+//GO(pthread_mutex_getprioceiling,
+#ifdef NOALIGN
GO(__pthread_mutex_init, iFpp)
GO(pthread_mutex_init, iFpp)
+#else
+// phtread_mutex_t is 40 bytes on x86_64, but 48bytes on ARM64
+GOM(__pthread_mutex_init, iFpp)
+GOM(pthread_mutex_init, iFpp)
+#endif
GO(__pthread_mutex_lock, iFp)
GO(pthread_mutex_lock, iFp)
-// pthread_mutex_setprioceiling
+//GO(pthread_mutex_setprioceiling,
GO(pthread_mutex_timedlock, iFpp)
GO(__pthread_mutex_trylock, iFp)
GO(pthread_mutex_trylock, iFp)
GO(__pthread_mutex_unlock, iFp)
GO(pthread_mutex_unlock, iFp)
-#else
-// phtread_mutex_t is 40 bytes on x86_64, but 48bytes on ARM64
-GOM(__pthread_mutex_destroy, iFp)
-GOM(pthread_mutex_destroy, iFp)
-// pthread_mutex_getprioceiling
-GOM(__pthread_mutex_init, iFpp)
-GOM(pthread_mutex_init, iFpp)
-GOM(__pthread_mutex_lock, iFp)
-GOM(pthread_mutex_lock, iFp)
-// pthread_mutex_setprioceiling
-GOM(pthread_mutex_timedlock, iFpp)
-GOM(__pthread_mutex_trylock, iFp)
-GOM(pthread_mutex_trylock, iFp)
-GOM(__pthread_mutex_unlock, iFp)
-GOM(pthread_mutex_unlock, iFp)
-#endif
GOM(pthread_once, iFEpp)
GOM(__pthread_once, iFEpp)
GOM(__pthread_register_cancel, vFEp)
-// __pthread_register_cancel_defer
+//GO(__pthread_register_cancel_defer,
GO(pthread_rwlockattr_destroy, vFp)
GO(pthread_rwlockattr_getkind_np, iFpp)
-// pthread_rwlockattr_getpshared
+//GO(pthread_rwlockattr_getpshared,
GO(pthread_rwlockattr_init, iFp)
GO(pthread_rwlockattr_setkind_np, iFpi)
-// pthread_rwlockattr_setpshared
-// __pthread_rwlock_destroy
+//GO(pthread_rwlockattr_setpshared,
+//GO(__pthread_rwlock_destroy,
GO(pthread_rwlock_destroy, iFp)
GO(__pthread_rwlock_init, iFpp)
GO(pthread_rwlock_init, iFpp)
GO(__pthread_rwlock_rdlock, iFp)
GO(pthread_rwlock_rdlock, iFp)
-// pthread_rwlock_timedrdlock
-// pthread_rwlock_timedwrlock
-// __pthread_rwlock_tryrdlock
+//GO(pthread_rwlock_timedrdlock,
+//GO(pthread_rwlock_timedwrlock,
+//GO(__pthread_rwlock_tryrdlock,
GO(pthread_rwlock_tryrdlock, iFp)
-// __pthread_rwlock_trywrlock
+//GO(__pthread_rwlock_trywrlock,
GO(pthread_rwlock_trywrlock, iFp)
GO(__pthread_rwlock_unlock, iFp)
GO(pthread_rwlock_unlock, iFp)
@@ -256,12 +247,12 @@ GO(pthread_testcancel, vFv)
GO(pthread_timedjoin_np, iFppp)
GO(pthread_tryjoin_np, iFpp)
GOM(__pthread_unregister_cancel, vFEp)
-// __pthread_unregister_cancel_restore
-// __pthread_unwind
+//GO(__pthread_unregister_cancel_restore,
+//GO(__pthread_unwind,
GOM(__pthread_unwind_next, vFEp)
GO(pthread_yield, iFv)
-// raise
-// __res_state
+//GO(raise,
+//GO(__res_state,
GO(sem_close, iFp)
GO(sem_clockwait, iFppp)
GO(sem_destroy, iFp)
@@ -273,6 +264,6 @@ GO(sem_timedwait, iFpp)
GO(sem_trywait, iFp)
GO(sem_unlink, iFp)
GO(sem_wait, iFp)
-// __sigaction
-// system
-// __vfork
+//GO(__sigaction,
+//GO(system,
+//GO(__vfork,
diff --git a/src/wrapped/wrappedlibresolv_private.h b/src/wrapped/wrappedlibresolv_private.h
index 1d73f4f..1d73f4f 100755..100644
--- a/src/wrapped/wrappedlibresolv_private.h
+++ b/src/wrapped/wrappedlibresolv_private.h
diff --git a/src/wrapped/wrappedlibrt.c b/src/wrapped/wrappedlibrt.c
index 29fa375..f89d353 100755..100644
--- a/src/wrapped/wrappedlibrt.c
+++ b/src/wrapped/wrappedlibrt.c
@@ -40,7 +40,7 @@ GO(3)
static uintptr_t my_sigev_notify_fct_##A = 0; \
static void my_sigev_notify_##A(void* sigval) \
{ \
- RunFunction(my_context, my_sigev_notify_fct_##A, 1, sigval);\
+ RunFunctionFmt(my_sigev_notify_fct_##A, "p", sigval);\
}
SUPER()
#undef GO
diff --git a/src/wrapped/wrappedlibrt_private.h b/src/wrapped/wrappedlibrt_private.h
index 75eb3fa..75eb3fa 100755..100644
--- a/src/wrapped/wrappedlibrt_private.h
+++ b/src/wrapped/wrappedlibrt_private.h
diff --git a/src/wrapped/wrappedlibsm.c b/src/wrapped/wrappedlibsm.c
index daf095b..1ab0c30 100755..100644
--- a/src/wrapped/wrappedlibsm.c
+++ b/src/wrapped/wrappedlibsm.c
@@ -54,25 +54,25 @@ typedef struct my_SmcCallbacks_s {
static uintptr_t my_save_yourself_fct = 0;
static void my_save_yourself(void* smcConn, void* clientData, int saveType, int shutdown, int interactStyle, int fast)
{
- RunFunction(my_context, my_save_yourself_fct, 6, smcConn, clientData, saveType, shutdown, interactStyle, fast);
+ RunFunctionFmt(my_save_yourself_fct, "ppiiii", smcConn, clientData, saveType, shutdown, interactStyle, fast);
}
static uintptr_t my_die_fct = 0;
static void my_die(void* smcConn, void* clientData)
{
- RunFunction(my_context, my_die_fct, 2, smcConn, clientData);
+ RunFunctionFmt(my_die_fct, "pp", smcConn, clientData);
}
static uintptr_t my_shutdown_cancelled_fct = 0;
static void my_shutdown_cancelled(void* smcConn, void* clientData)
{
- RunFunction(my_context, my_shutdown_cancelled_fct, 2, smcConn, clientData);
+ RunFunctionFmt(my_shutdown_cancelled_fct, "pp", smcConn, clientData);
}
static uintptr_t my_save_complete_fct = 0;
static void my_save_complete(void* smcConn, void* clientData)
{
- RunFunction(my_context, my_save_complete_fct, 2, smcConn, clientData);
+ RunFunctionFmt(my_save_complete_fct, "pp", smcConn, clientData);
}
@@ -102,7 +102,7 @@ GO(4)
static uintptr_t my_Request_fct_##A = 0; \
static void my_Request_##A(void* a, void* b) \
{ \
- RunFunction(my_context, my_Request_fct_##A, 2, a, b);\
+ RunFunctionFmt(my_Request_fct_##A, "pp", a, b);\
}
SUPER()
#undef GO
diff --git a/src/wrapped/wrappedlibsm_private.h b/src/wrapped/wrappedlibsm_private.h
index bc00fca..bc00fca 100755..100644
--- a/src/wrapped/wrappedlibsm_private.h
+++ b/src/wrapped/wrappedlibsm_private.h
diff --git a/src/wrapped/wrappedlibsndfile.c b/src/wrapped/wrappedlibsndfile.c
index 3766066..bbb11b5 100755..100644
--- a/src/wrapped/wrappedlibsndfile.c
+++ b/src/wrapped/wrappedlibsndfile.c
@@ -38,7 +38,7 @@ GO(4)
static uintptr_t my_sf_vio_get_filelen_fct_##A = 0; \
static int64_t my_sf_vio_get_filelen_##A(void* a) \
{ \
- return (int64_t)RunFunction(my_context, my_sf_vio_get_filelen_fct_##A, 1, a); \
+ return (int64_t)RunFunctionFmt(my_sf_vio_get_filelen_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -60,7 +60,7 @@ static void* find_sf_vio_get_filelen_Fct(void* fct)
static uintptr_t my_sf_vio_seek_fct_##A = 0; \
static int64_t my_sf_vio_seek_##A(int64_t offset, int whence, void *user_data) \
{ \
- return (int64_t)RunFunction(my_context, my_sf_vio_seek_fct_##A, 3, offset, whence, user_data); \
+ return (int64_t)RunFunctionFmt(my_sf_vio_seek_fct_##A, "Iip", offset, whence, user_data); \
}
SUPER()
#undef GO
@@ -82,7 +82,7 @@ static void* find_sf_vio_seek_Fct(void* fct)
static uintptr_t my_sf_vio_read_fct_##A = 0; \
static int64_t my_sf_vio_read_##A(void* ptr, int64_t count, void *user_data) \
{ \
- return (int64_t)RunFunction(my_context, my_sf_vio_read_fct_##A, 3, ptr, count, user_data); \
+ return (int64_t)RunFunctionFmt(my_sf_vio_read_fct_##A, "pIp", ptr, count, user_data); \
}
SUPER()
#undef GO
@@ -104,7 +104,7 @@ static void* find_sf_vio_read_Fct(void* fct)
static uintptr_t my_sf_vio_write_fct_##A = 0; \
static int64_t my_sf_vio_write_##A(const void* ptr, int64_t count, void *user_data) \
{ \
- return (int64_t)RunFunction(my_context, my_sf_vio_write_fct_##A, 3, ptr, count, user_data); \
+ return (int64_t)RunFunctionFmt(my_sf_vio_write_fct_##A, "pIp", ptr, count, user_data); \
}
SUPER()
#undef GO
@@ -126,7 +126,7 @@ static void* find_sf_vio_write_Fct(void* fct)
static uintptr_t my_sf_vio_tell_fct_##A = 0; \
static int64_t my_sf_vio_tell_##A(void* a) \
{ \
- return (int64_t)RunFunction(my_context, my_sf_vio_tell_fct_##A, 1, a); \
+ return (int64_t)RunFunctionFmt(my_sf_vio_tell_fct_##A, "p", a); \
}
SUPER()
#undef GO
diff --git a/src/wrapped/wrappedlibsndfile_private.h b/src/wrapped/wrappedlibsndfile_private.h
index 7aef440..7aef440 100755..100644
--- a/src/wrapped/wrappedlibsndfile_private.h
+++ b/src/wrapped/wrappedlibsndfile_private.h
diff --git a/src/wrapped/wrappedlibssl.c b/src/wrapped/wrappedlibssl.c
index 48dae43..056c2ef 100755..100644
--- a/src/wrapped/wrappedlibssl.c
+++ b/src/wrapped/wrappedlibssl.c
@@ -22,6 +22,8 @@ const char* libsslName = "libssl.so.1.0.0";
#define ALTNAME "libssl.so.1.0.2"
#define ALTNAME2 "libssl.so.1.1"
+#define ADDED_FUNCTIONS() \
+
#include "generated/wrappedlibssltypes.h"
#include "wrappercallback.h"
@@ -39,7 +41,7 @@ GO(4)
static uintptr_t my_pem_passwd_cb_fct_##A = 0; \
static int my_pem_passwd_cb_##A(void* buf, int size, int rwflag, void* password) \
{ \
- return (int)RunFunction(my_context, my_pem_passwd_cb_fct_##A, 4, buf, size, rwflag, password); \
+ return (int)RunFunctionFmt(my_pem_passwd_cb_fct_##A, "piip", buf, size, rwflag, password); \
}
SUPER()
#undef GO
@@ -63,7 +65,7 @@ static void* find_pem_passwd_cb_Fct(void* fct)
static uintptr_t my_anonymous_fct_##A = 0; \
static void* my_anonymous_##A(void* a, void* b, void* c, void *d) \
{ \
- return (void*)RunFunction(my_context, my_anonymous_fct_##A, 4, a, b, c, d); \
+ return (void*)RunFunctionFmt(my_anonymous_fct_##A, "pppp", a, b, c, d); \
}
SUPER()
#undef GO
@@ -88,7 +90,7 @@ static void* find_anonymous_Fct(void* fct)
static uintptr_t my_verify_fct_##A = 0; \
static int my_verify_##A(int a, void* b) \
{ \
- return (int)RunFunction(my_context, my_verify_fct_##A, 2, a, b); \
+ return (int)RunFunctionFmt(my_verify_fct_##A, "ip", a, b); \
}
SUPER()
#undef GO
@@ -122,7 +124,7 @@ static void* reverse_verify_Fct(void* fct)
static uintptr_t my_ex_new_fct_##A = 0; \
static void my_ex_new_##A(void* parent, void* ptr, void* ad, int idx, long argl, void* argp) \
{ \
- RunFunction(my_context, my_ex_new_fct_##A, 6, parent, ptr, ad, idx, argl, argp); \
+ RunFunctionFmt(my_ex_new_fct_##A, "pppilp", parent, ptr, ad, idx, argl, argp); \
}
SUPER()
#undef GO
@@ -146,7 +148,7 @@ static void* find_ex_new_Fct(void* fct)
static uintptr_t my_ex_free_fct_##A = 0; \
static void my_ex_free_##A(void* parent, void* ptr, void* ad, int idx, long argl, void* argp) \
{ \
- RunFunction(my_context, my_ex_free_fct_##A, 6, parent, ptr, ad, idx, argl, argp); \
+ RunFunctionFmt(my_ex_free_fct_##A, "pppilp", parent, ptr, ad, idx, argl, argp); \
}
SUPER()
#undef GO
@@ -170,7 +172,7 @@ static void* find_ex_free_Fct(void* fct)
static uintptr_t my_ex_dup_fct_##A = 0; \
static int my_ex_dup_##A(void* to, void* from, void* from_d, int idx, long argl, void* argp) \
{ \
- return (int) RunFunction(my_context, my_ex_dup_fct_##A, 6, to, from, from_d, idx, argl, argp); \
+ return (int) RunFunctionFmt(my_ex_dup_fct_##A, "pppilp", to, from, from_d, idx, argl, argp); \
}
SUPER()
#undef GO
@@ -194,7 +196,7 @@ static void* find_ex_dup_Fct(void* fct)
static uintptr_t my_client_cb_fct_##A = 0; \
static uint32_t my_client_cb_##A(void* ssl, void* hint, void* identity, uint32_t id_len, void* psk, uint32_t psk_len) \
{ \
- return RunFunction(my_context, my_client_cb_fct_##A, 6, ssl, hint, identity, id_len, psk, psk_len); \
+ return RunFunctionFmt(my_client_cb_fct_##A, "pppupu", ssl, hint, identity, id_len, psk, psk_len); \
}
SUPER()
#undef GO
@@ -213,12 +215,86 @@ static void* find_client_cb_Fct(void* fct)
return NULL;
}
+
+// server_cb
+#define GO(A) \
+static uintptr_t my_server_cb_fct_##A = 0; \
+static uint32_t my_server_cb_##A(void* ssl, void* identity, void* psk, uint32_t psk_len) \
+{ \
+ return RunFunctionFmt(my_server_cb_fct_##A, "pppu", ssl, identity, psk, psk_len); \
+}
+SUPER()
+#undef GO
+static void* find_server_cb_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my_server_cb_fct_##A == (uintptr_t)fct) return my_server_cb_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_server_cb_fct_##A == 0) {my_server_cb_fct_##A = (uintptr_t)fct; return my_server_cb_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libSSL server_cb callback\n");
+ return NULL;
+}
+
+
+// use_session_cb
+#define GO(A) \
+static uintptr_t my_use_session_cb_fct_##A = 0; \
+static uint32_t my_use_session_cb_##A(void* ssl, void* md, void* id, void* id_len, void* sess) \
+{ \
+ return RunFunctionFmt(my_use_session_cb_fct_##A, "ppppp", ssl, md, id, id_len, sess); \
+}
+SUPER()
+#undef GO
+static void* find_use_session_cb_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my_use_session_cb_fct_##A == (uintptr_t)fct) return my_use_session_cb_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_use_session_cb_fct_##A == 0) {my_use_session_cb_fct_##A = (uintptr_t)fct; return my_use_session_cb_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libSSL use_session_cb callback\n");
+ return NULL;
+}
+
+// sess
+#define GO(A) \
+static uintptr_t my_sess_fct_##A = 0; \
+static uint32_t my_sess_##A(void* ssl, void* sess) \
+{ \
+ return RunFunctionFmt(my_sess_fct_##A, "pp", ssl, sess);\
+}
+SUPER()
+#undef GO
+static void* find_sess_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my_sess_fct_##A == (uintptr_t)fct) return my_sess_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_sess_fct_##A == 0) {my_sess_fct_##A = (uintptr_t)fct; return my_sess_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libSSL sess callback\n");
+ return NULL;
+}
+
// proto_select
#define GO(A) \
static uintptr_t my_proto_select_fct_##A = 0; \
static int my_proto_select_##A(void* s, void* out, void* outlen, void* in, uint32_t inlen, void* arg) \
{ \
- return (int)RunFunction(my_context, my_proto_select_fct_##A, 6, s, out, outlen, in, inlen, arg); \
+ return (int)RunFunctionFmt(my_proto_select_fct_##A, "ppppup", s, out, outlen, in, inlen, arg); \
}
SUPER()
#undef GO
@@ -242,7 +318,7 @@ static void* find_proto_select_Fct(void* fct)
static uintptr_t my_client_cert_fct_##A = 0; \
static int my_client_cert_##A(void* a, void* b, void* c) \
{ \
- return (int)RunFunction(my_context, my_client_cert_fct_##A, 3, a, b, c); \
+ return (int)RunFunctionFmt(my_client_cert_fct_##A, "ppp", a, b, c); \
}
SUPER()
#undef GO
@@ -261,6 +337,79 @@ static void* find_client_cert_Fct(void* fct)
return NULL;
}
+// cookie_generate
+#define GO(A) \
+static uintptr_t my_cookie_generate_fct_##A = 0; \
+static int my_cookie_generate_##A(void* a, void* b, void* c)\
+{ \
+ return (int)RunFunctionFmt(my_cookie_generate_fct_##A, "ppp", a, b, c); \
+}
+SUPER()
+#undef GO
+static void* find_cookie_generate_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my_cookie_generate_fct_##A == (uintptr_t)fct) return my_cookie_generate_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_cookie_generate_fct_##A == 0) {my_cookie_generate_fct_##A = (uintptr_t)fct; return my_cookie_generate_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libSSL cookie_generate callback\n");
+ return NULL;
+}
+
+
+// cookie_verify
+#define GO(A) \
+static uintptr_t my_cookie_verify_fct_##A = 0; \
+static int my_cookie_verify_##A(void* a, void* b, uint32_t c) \
+{ \
+ return (int)RunFunctionFmt(my_cookie_verify_fct_##A, "ppu", a, b, c); \
+}
+SUPER()
+#undef GO
+static void* find_cookie_verify_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my_cookie_verify_fct_##A == (uintptr_t)fct) return my_cookie_verify_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_cookie_verify_fct_##A == 0) {my_cookie_verify_fct_##A = (uintptr_t)fct; return my_cookie_verify_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libSSL cookie_verify callback\n");
+ return NULL;
+}
+
+// alpn_select
+#define GO(A) \
+static uintptr_t my_alpn_select_fct_##A = 0; \
+static int my_alpn_select_##A(void* a, void* b, void* c, void* d, uint32_t e, void* f) \
+{ \
+ return (int)RunFunctionFmt(my_alpn_select_fct_##A, "ppppup", a, b, c, d, e, f); \
+}
+SUPER()
+#undef GO
+static void* find_alpn_select_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my_alpn_select_fct_##A == (uintptr_t)fct) return my_alpn_select_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_alpn_select_fct_##A == 0) {my_alpn_select_fct_##A = (uintptr_t)fct; return my_alpn_select_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libSSL alpn_select callback\n");
+ return NULL;
+}
+
#undef SUPER
EXPORT void my_SSL_CTX_set_default_passwd_cb(x64emu_t* emu, void* ctx, void* cb)
@@ -305,6 +454,24 @@ EXPORT void my_SSL_set_psk_client_callback(x64emu_t* emu, void* ctx, void* cb)
my->SSL_set_psk_client_callback(ctx, find_client_cb_Fct(cb));
}
+EXPORT void my_SSL_set_psk_server_callback(x64emu_t* emu, void* ctx, void* cb)
+{
+ (void)emu;
+ my->SSL_set_psk_server_callback(ctx, find_client_cb_Fct(cb));
+}
+
+EXPORT void my_SSL_set_psk_use_session_callback(x64emu_t* emu, void* ctx, void* cb)
+{
+ (void)emu;
+ my->SSL_set_psk_use_session_callback(ctx, find_use_session_cb_Fct(cb));
+}
+
+EXPORT void my_SSL_CTX_sess_set_new_cb(x64emu_t* emu, void* ctx, void* cb)
+{
+ (void)emu;
+ my->SSL_CTX_sess_set_new_cb(ctx, find_sess_Fct(cb));
+}
+
EXPORT void my_SSL_CTX_set_next_proto_select_cb(x64emu_t* emu, void* ctx, void* cb, void* arg)
{
(void)emu;
@@ -329,6 +496,24 @@ EXPORT void my_SSL_CTX_set_client_cert_cb(x64emu_t* emu, void* ctx, void* cb)
my->SSL_CTX_set_client_cert_cb(ctx, find_client_cert_Fct(cb));
}
+EXPORT void my_SSL_CTX_set_cookie_generate_cb(x64emu_t* emu, void* ctx, void* cb)
+{
+ (void)emu;
+ my->SSL_CTX_set_cookie_generate_cb(ctx, find_cookie_generate_Fct(cb));
+}
+
+EXPORT void my_SSL_CTX_set_cookie_verify_cb(x64emu_t* emu, void* ctx, void* cb)
+{
+ (void)emu;
+ my->SSL_CTX_set_cookie_verify_cb(ctx, find_cookie_verify_Fct(cb));
+}
+
+EXPORT void my_SSL_CTX_set_alpn_select_cb(x64emu_t* emu, void* ctx, void* f ,void* arg)
+{
+ (void)emu;
+ my->SSL_CTX_set_alpn_select_cb(ctx, find_alpn_select_Fct(f), arg);
+}
+
#define CUSTOM_INIT \
getMy(lib); \
setNeededLibs(lib, 2, "libcrypto.so.1.1", "libpthread.so.0");
diff --git a/src/wrapped/wrappedlibssl3.c b/src/wrapped/wrappedlibssl3.c
new file mode 100644
index 0000000..23d2e3b
--- /dev/null
+++ b/src/wrapped/wrappedlibssl3.c
@@ -0,0 +1,367 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#define _GNU_SOURCE /* See feature_test_macros(7) */
+#include <dlfcn.h>
+
+#include "wrappedlibs.h"
+
+#include "debug.h"
+#include "wrapper.h"
+#include "bridge.h"
+#include "librarian/library_private.h"
+#include "x64emu.h"
+#include "emu/x64emu_private.h"
+#include "callback.h"
+#include "librarian.h"
+#include "box64context.h"
+#include "emu/x64emu_private.h"
+
+const char* libssl3Name = "libssl.so.3";
+#define LIBNAME libssl3
+
+#include "generated/wrappedlibssl3types.h"
+
+#include "wrappercallback.h"
+
+// utility functions
+#define SUPER() \
+GO(0) \
+GO(1) \
+GO(2) \
+GO(3) \
+GO(4)
+
+// pem_passwd_cb
+#define GO(A) \
+static uintptr_t my3_pem_passwd_cb_fct_##A = 0; \
+static int my3_pem_passwd_cb_##A(void* buf, int size, int rwflag, void* password) \
+{ \
+ return (int)RunFunctionFmt(my3_pem_passwd_cb_fct_##A, "piip", buf, size, rwflag, password); \
+}
+SUPER()
+#undef GO
+static void* find_pem_passwd_cb_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my3_pem_passwd_cb_fct_##A == (uintptr_t)fct) return my3_pem_passwd_cb_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my3_pem_passwd_cb_fct_##A == 0) {my3_pem_passwd_cb_fct_##A = (uintptr_t)fct; return my3_pem_passwd_cb_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libSSL pem_passwd_cb callback\n");
+ return NULL;
+}
+
+// anonymous
+#define GO(A) \
+static uintptr_t my3_anonymous_fct_##A = 0; \
+static void* my3_anonymous_##A(void* a, void* b, void* c, void *d) \
+{ \
+ return (void*)RunFunctionFmt(my3_anonymous_fct_##A, "pppp", a, b, c, d); \
+}
+SUPER()
+#undef GO
+static void* find_anonymous_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my3_anonymous_fct_##A == (uintptr_t)fct) return my3_anonymous_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my3_anonymous_fct_##A == 0) {my3_anonymous_fct_##A = (uintptr_t)fct; return my3_anonymous_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libSSL anonymous callback\n");
+ return NULL;
+}
+
+
+// verify
+#define GO(A) \
+static uintptr_t my3_verify_fct_##A = 0; \
+static int my3_verify_##A(int a, void* b) \
+{ \
+ return (int)RunFunctionFmt(my3_verify_fct_##A, "ip", a, b); \
+}
+SUPER()
+#undef GO
+static void* find_verify_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my3_verify_fct_##A == (uintptr_t)fct) return my3_verify_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my3_verify_fct_##A == 0) {my3_verify_fct_##A = (uintptr_t)fct; return my3_verify_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libSSL verify callback\n");
+ return NULL;
+}
+static void* reverse_verify_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(CheckBridged(my_lib->w.bridge, fct))
+ return (void*)CheckBridged(my_lib->w.bridge, fct);
+ #define GO(A) if(my3_verify_##A == fct) return (void*)my3_verify_fct_##A;
+ SUPER()
+ #undef GO
+ return (void*)AddBridge(my_lib->w.bridge, iFip, fct, 0, NULL);
+}
+
+// ex_new
+#define GO(A) \
+static uintptr_t my3_ex_new_fct_##A = 0; \
+static void my3_ex_new_##A(void* parent, void* ptr, void* ad, int idx, long argl, void* argp) \
+{ \
+ RunFunctionFmt(my3_ex_new_fct_##A, "pppilp", parent, ptr, ad, idx, argl, argp); \
+}
+SUPER()
+#undef GO
+static void* find_ex_new_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my3_ex_new_fct_##A == (uintptr_t)fct) return my3_ex_new_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my3_ex_new_fct_##A == 0) {my3_ex_new_fct_##A = (uintptr_t)fct; return my3_ex_new_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libSSL ex_new callback\n");
+ return NULL;
+}
+
+// ex_free
+#define GO(A) \
+static uintptr_t my3_ex_free_fct_##A = 0; \
+static void my3_ex_free_##A(void* parent, void* ptr, void* ad, int idx, long argl, void* argp) \
+{ \
+ RunFunctionFmt(my3_ex_free_fct_##A, "pppilp", parent, ptr, ad, idx, argl, argp); \
+}
+SUPER()
+#undef GO
+static void* find_ex_free_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my3_ex_free_fct_##A == (uintptr_t)fct) return my3_ex_free_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my3_ex_free_fct_##A == 0) {my3_ex_free_fct_##A = (uintptr_t)fct; return my3_ex_free_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libSSL ex_free callback\n");
+ return NULL;
+}
+
+// ex_dup
+#define GO(A) \
+static uintptr_t my3_ex_dup_fct_##A = 0; \
+static int my3_ex_dup_##A(void* to, void* from, void* from_d, int idx, long argl, void* argp) \
+{ \
+ return (int) RunFunctionFmt(my3_ex_dup_fct_##A, "pppilp", to, from, from_d, idx, argl, argp); \
+}
+SUPER()
+#undef GO
+static void* find_ex_dup_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my3_ex_dup_fct_##A == (uintptr_t)fct) return my3_ex_dup_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my3_ex_dup_fct_##A == 0) {my3_ex_dup_fct_##A = (uintptr_t)fct; return my3_ex_dup_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libSSL ex_dup callback\n");
+ return NULL;
+}
+
+// client_cb
+#define GO(A) \
+static uintptr_t my3_client_cb_fct_##A = 0; \
+static uint32_t my3_client_cb_##A(void* ssl, void* hint, void* identity, uint32_t id_len, void* psk, uint32_t psk_len) \
+{ \
+ return RunFunctionFmt(my3_client_cb_fct_##A, "pppupu", ssl, hint, identity, id_len, psk, psk_len); \
+}
+SUPER()
+#undef GO
+static void* find_client_cb_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my3_client_cb_fct_##A == (uintptr_t)fct) return my3_client_cb_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my3_client_cb_fct_##A == 0) {my3_client_cb_fct_##A = (uintptr_t)fct; return my3_client_cb_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libSSL client_cb callback\n");
+ return NULL;
+}
+
+// proto_select
+#define GO(A) \
+static uintptr_t my3_proto_select_fct_##A = 0; \
+static int my3_proto_select_##A(void* s, void* out, void* outlen, void* in, uint32_t inlen, void* arg) \
+{ \
+ return (int)RunFunctionFmt(my3_proto_select_fct_##A, "ppppup", s, out, outlen, in, inlen, arg); \
+}
+SUPER()
+#undef GO
+static void* find_proto_select_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my3_proto_select_fct_##A == (uintptr_t)fct) return my3_proto_select_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my3_proto_select_fct_##A == 0) {my3_proto_select_fct_##A = (uintptr_t)fct; return my3_proto_select_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libSSL proto_select callback\n");
+ return NULL;
+}
+
+// client_cert
+#define GO(A) \
+static uintptr_t my3_client_cert_fct_##A = 0; \
+static int my3_client_cert_##A(void* a, void* b, void* c) \
+{ \
+ return (int)RunFunctionFmt(my3_client_cert_fct_##A, "ppp", a, b, c); \
+}
+SUPER()
+#undef GO
+static void* find_client_cert_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my3_client_cert_fct_##A == (uintptr_t)fct) return my3_client_cert_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my3_client_cert_fct_##A == 0) {my3_client_cert_fct_##A = (uintptr_t)fct; return my3_client_cert_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libSSL client_cert callback\n");
+ return NULL;
+}
+
+// alpn_select_cb
+#define GO(A) \
+static uintptr_t my3_alpn_select_cb_fct_##A = 0; \
+static int my3_alpn_select_cb_##A(void* a, void* b, void* c, void* d, uint32_t e, void* f) \
+{ \
+ return (int)RunFunctionFmt(my3_alpn_select_cb_fct_##A, "ppppup", a, b, c, d, e, f); \
+}
+SUPER()
+#undef GO
+static void* find_alpn_select_cb_Fct(void* fct)
+{
+ if(!fct) return NULL;
+ void* p;
+ if((p = GetNativeFnc((uintptr_t)fct))) return p;
+ #define GO(A) if(my3_alpn_select_cb_fct_##A == (uintptr_t)fct) return my3_alpn_select_cb_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my3_alpn_select_cb_fct_##A == 0) {my3_alpn_select_cb_fct_##A = (uintptr_t)fct; return my3_alpn_select_cb_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libSSL alpn_select_cb callback\n");
+ return NULL;
+}
+
+#undef SUPER
+
+EXPORT void my3_SSL_CTX_set_default_passwd_cb(x64emu_t* emu, void* ctx, void* cb)
+{
+ (void)emu;
+ my->SSL_CTX_set_default_passwd_cb(ctx, find_pem_passwd_cb_Fct(cb));
+}
+
+EXPORT long my3_SSL_CTX_callback_ctrl(x64emu_t* emu, void* ctx, int cmd, void* f)
+{
+ (void)emu;
+ return my->SSL_CTX_callback_ctrl(ctx, cmd, find_anonymous_Fct(f));
+}
+
+EXPORT long my3_SSL_callback_ctrl(x64emu_t* emu, void* ctx, int cmd, void* f)
+{
+ (void)emu;
+ return my->SSL_callback_ctrl(ctx, cmd, find_anonymous_Fct(f));
+}
+
+EXPORT void my3_SSL_CTX_set_verify(x64emu_t* emu, void* ctx, int mode, void* f)
+{
+ (void)emu;
+ my->SSL_CTX_set_verify(ctx, mode, find_verify_Fct(f));
+}
+
+EXPORT void my3_SSL_set_verify(x64emu_t* emu, void* ctx, int mode, void* f)
+{
+ (void)emu;
+ my->SSL_set_verify(ctx, mode, find_verify_Fct(f));
+}
+
+EXPORT void my3_SSL_get_ex_new_index(x64emu_t* emu, long argl, void* argp, void* new_func, void* dup_func, void* free_func)
+{
+ (void)emu;
+ my->SSL_get_ex_new_index(argl, argp, find_ex_new_Fct(new_func), find_ex_dup_Fct(dup_func), find_ex_free_Fct(free_func));
+}
+
+EXPORT void my3_SSL_set_psk_client_callback(x64emu_t* emu, void* ctx, void* cb)
+{
+ (void)emu;
+ my->SSL_set_psk_client_callback(ctx, find_client_cb_Fct(cb));
+}
+
+EXPORT void my3_SSL_CTX_set_next_proto_select_cb(x64emu_t* emu, void* ctx, void* cb, void* arg)
+{
+ (void)emu;
+ my->SSL_CTX_set_next_proto_select_cb(ctx, find_proto_select_Fct(cb), arg);
+}
+
+EXPORT void* my3_SSL_get_verify_callback(x64emu_t* emu, void* ctx)
+{
+ (void)emu;
+ return reverse_verify_Fct(my->SSL_get_verify_callback(ctx));
+}
+
+EXPORT void my3_SSL_CTX_set_cert_verify_callback(x64emu_t* emu, void* ctx, void* cb, void* arg)
+{
+ (void)emu;
+ my->SSL_CTX_set_cert_verify_callback(ctx, find_verify_Fct(cb), arg);
+}
+
+EXPORT void my3_SSL_CTX_set_client_cert_cb(x64emu_t* emu, void* ctx, void* cb)
+{
+ (void)emu;
+ my->SSL_CTX_set_client_cert_cb(ctx, find_client_cert_Fct(cb));
+}
+
+EXPORT void my3_SSL_CTX_set_alpn_select_cb(x64emu_t* emu, void* ctx, void* f, void* arg)
+{
+ my->SSL_CTX_set_alpn_select_cb(ctx, find_alpn_select_cb_Fct(f), arg);
+}
+
+#define CUSTOM_INIT \
+ SETALT(my3_); \
+ getMy(lib); \
+ setNeededLibs(lib, 2, "libcrypto.so.3", "libpthread.so.0");
+
+#define CUSTOM_FINI \
+ freeMy();
+
+#include "wrappedlib_init.h"
diff --git a/src/wrapped/wrappedlibssl3_private.h b/src/wrapped/wrappedlibssl3_private.h
new file mode 100644
index 0000000..e9ff941
--- /dev/null
+++ b/src/wrapped/wrappedlibssl3_private.h
@@ -0,0 +1,605 @@
+#if !(defined(GO) && defined(GOM) && defined(GO2) && defined(DATA))
+#error meh!
+#endif
+
+//GO(BIO_f_ssl,
+//GO(BIO_new_buffer_ssl_connect,
+//GO(BIO_new_ssl,
+//GO(BIO_new_ssl_connect,
+//GO(BIO_ssl_copy_session_id,
+//GO(BIO_ssl_shutdown,
+//GO(custom_ext_add,
+//GO(custom_ext_init,
+//GO(custom_ext_parse,
+//GO(custom_exts_copy,
+//GO(custom_exts_free,
+GO(d2i_SSL_SESSION, pFppl)
+//GO(do_dtls1_write,
+//GO(dtls1_accept,
+//GO(dtls1_buffer_message,
+//GO(dtls1_check_timeout_num,
+//GO(dtls1_clear,
+//GO(dtls1_clear_received_buffer,
+//GO(dtls1_clear_sent_buffer,
+//GO(dtls1_connect,
+//GO(dtls1_ctrl,
+//GO(dtls1_default_timeout,
+//GO(dtls1_dispatch_alert,
+//GO(dtls1_double_timeout,
+//GO(dtls1_do_write,
+//GO(dtls1_free,
+//GO(dtls1_get_ccs_header,
+//GO(dtls1_get_cipher,
+//GO(dtls1_get_message,
+//GO(dtls1_get_message_header,
+//GO(dtls1_get_queue_priority,
+//GO(dtls1_get_record,
+//GO(dtls1_get_timeout,
+//GO(dtls1_handle_timeout,
+//GO(dtls1_heartbeat,
+//GO(dtls1_hm_fragment_free,
+//GO(dtls1_is_timer_expired,
+//GO(dtls1_link_min_mtu,
+//GO(dtls1_listen,
+//GO(dtls1_min_mtu,
+//GO(dtls1_new,
+//GO(dtls1_process_heartbeat,
+//GO(dtls1_read_bytes,
+//GO(dtls1_read_failed,
+//GO(dtls1_reset_seq_numbers,
+//GO(dtls1_retransmit_buffered_messages,
+//GO(dtls1_retransmit_message,
+//GO(dtls1_send_change_cipher_spec,
+//GO(dtls1_set_message_header,
+//GO(dtls1_shutdown,
+//GO(dtls1_start_timer,
+//GO(dtls1_stop_timer,
+//GO(dtls1_write_app_data_bytes,
+//GO(dtls1_write_bytes,
+//GO(DTLS_client_method,
+GO(DTLS_method, pFv)
+GO(DTLS_server_method, pFv)
+GO(DTLSv1_2_client_method, pFv)
+GO(DTLSv1_2_method, pFv)
+GO(DTLSv1_2_server_method, pFv)
+GO(DTLSv1_client_method, pFv)
+GO(DTLSv1_method, pFv)
+GO(DTLSv1_server_method, pFv)
+//GO(ERR_load_SSL_strings,
+//GO(_fini,
+GO(i2d_SSL_SESSION, iFpp)
+//GO(_init,
+//GO(n_ssl3_mac,
+//GO(OBJ_bsearch_ssl_cipher_id,
+GO(OPENSSL_init_ssl, iFUp)
+//GO(PEM_read_bio_SSL_SESSION,
+//GO(PEM_read_SSL_SESSION,
+//GO(PEM_write_bio_SSL_SESSION,
+//GO(PEM_write_SSL_SESSION,
+//GO(SRP_Calc_A_param,
+//GO(SRP_generate_client_master_secret,
+//GO(SRP_generate_server_master_secret,
+//GO(srp_verify_server_param,
+//GO(ssl23_accept,
+//GO(ssl23_connect,
+//GO(ssl23_default_timeout,
+//GO(ssl23_get_cipher,
+//GO(ssl23_get_cipher_by_char,
+//GO(ssl23_get_client_hello,
+//GO(ssl23_num_ciphers,
+//GO(ssl23_peek,
+//GO(ssl23_put_cipher_by_char,
+//GO(ssl23_read,
+//GO(ssl23_read_bytes,
+//GO(ssl23_write,
+//GO(ssl23_write_bytes,
+//GO(ssl3_accept,
+//GO(ssl3_alert_code,
+//GO(ssl3_callback_ctrl,
+//GO(ssl3_cbc_copy_mac,
+//GO(ssl3_cbc_digest_record,
+//GO(ssl3_cbc_record_digest_supported,
+//GO(ssl3_cbc_remove_padding,
+//GO(ssl3_cert_verify_mac,
+//GO(ssl3_change_cipher_state,
+//GO(ssl3_check_cert_and_algorithm,
+//GO(ssl3_choose_cipher,
+//GO(ssl3_cleanup_key_block,
+//GO(ssl3_clear,
+//GO(ssl3_client_hello,
+//GO(ssl3_comp_find,
+//GO(ssl3_connect,
+//GO(ssl3_ctrl,
+//GO(ssl3_ctx_callback_ctrl,
+//GO(ssl3_ctx_ctrl,
+//GO(ssl3_default_timeout,
+//GO(ssl3_digest_cached_records,
+//GO(ssl3_dispatch_alert,
+//GO(ssl3_do_change_cipher_spec,
+//GO(ssl3_do_compress,
+//GO(ssl3_do_uncompress,
+//GO(ssl3_do_write,
+//GO(ssl3_enc,
+//GO(ssl3_final_finish_mac,
+//GO(ssl3_finish_mac,
+//GO(ssl3_free,
+//GO(ssl3_free_digest_list,
+//GO(ssl3_generate_master_secret,
+//GO(ssl3_get_certificate_request,
+//GO(ssl3_get_cert_status,
+//GO(ssl3_get_cert_verify,
+//GO(ssl3_get_cipher,
+//GO(ssl3_get_cipher_by_char,
+//GO(ssl3_get_client_certificate,
+//GO(ssl3_get_client_hello,
+//GO(ssl3_get_client_key_exchange,
+//GO(ssl3_get_finished,
+//GO(ssl3_get_key_exchange,
+//GO(ssl3_get_message,
+//GO(ssl3_get_new_session_ticket,
+//GO(ssl3_get_next_proto,
+//GO(ssl3_get_req_cert_type,
+//GO(ssl3_get_server_certificate,
+//GO(ssl3_get_server_done,
+//GO(ssl3_get_server_hello,
+//GO(ssl3_handshake_write,
+//GO(ssl3_init_finished_mac,
+//GO(ssl3_new,
+//GO(ssl3_num_ciphers,
+//GO(ssl3_output_cert_chain,
+//GO(ssl3_peek,
+//GO(ssl3_pending,
+//GO(ssl3_put_cipher_by_char,
+//GO(ssl3_read,
+//GO(ssl3_read_bytes,
+//GO(ssl3_read_n,
+//GO(ssl3_record_sequence_update,
+//GO(ssl3_release_read_buffer,
+//GO(ssl3_release_write_buffer,
+//GO(ssl3_renegotiate,
+//GO(ssl3_renegotiate_check,
+//GO(ssl3_send_alert,
+//GO(ssl3_send_certificate_request,
+//GO(ssl3_send_cert_status,
+//GO(ssl3_send_change_cipher_spec,
+//GO(ssl3_send_client_certificate,
+//GO(ssl3_send_client_key_exchange,
+//GO(ssl3_send_client_verify,
+//GO(ssl3_send_finished,
+//GO(ssl3_send_hello_request,
+//GO(ssl3_send_newsession_ticket,
+//GO(ssl3_send_next_proto,
+//GO(ssl3_send_server_certificate,
+//GO(ssl3_send_server_done,
+//GO(ssl3_send_server_hello,
+//GO(ssl3_send_server_key_exchange,
+//GO(ssl3_set_handshake_header,
+//GO(ssl3_setup_buffers,
+//GO(ssl3_setup_key_block,
+//GO(ssl3_setup_read_buffer,
+//GO(ssl3_setup_write_buffer,
+//GO(ssl3_shutdown,
+//GO(ssl3_write,
+//GO(ssl3_write_bytes,
+//GO(ssl3_write_pending,
+GO(SSL_accept, iFp)
+//GO(ssl_add_cert_chain,
+GO(SSL_add_client_CA, iFpp)
+//GO(ssl_add_clienthello_renegotiate_ext,
+//GO(ssl_add_clienthello_tlsext,
+//GO(ssl_add_clienthello_use_srtp_ext,
+//GO(SSL_add_dir_cert_subjects_to_stack,
+//GO(SSL_add_file_cert_subjects_to_stack,
+//GO(ssl_add_serverhello_renegotiate_ext,
+//GO(ssl_add_serverhello_tlsext,
+//GO(ssl_add_serverhello_use_srtp_ext,
+//GO(SSL_alert_desc_string,
+//GO(SSL_alert_desc_string_long,
+//GO(SSL_alert_type_string,
+//GO(SSL_alert_type_string_long,
+//GO(ssl_bad_method,
+//GO(ssl_build_cert_chain,
+//GO(ssl_bytes_to_cipher_list,
+//GO(SSL_cache_hit,
+GOM(SSL_callback_ctrl, lFEpip)
+//GO(ssl_cert_add0_chain_cert,
+//GO(ssl_cert_add1_chain_cert,
+//GO(ssl_cert_clear_certs,
+//GO(ssl_cert_dup,
+//GO(ssl_cert_free,
+//GO(ssl_cert_inst,
+//GO(ssl_cert_new,
+//GO(SSL_certs_clear,
+//GO(ssl_cert_select_current,
+//GO(ssl_cert_set0_chain,
+//GO(ssl_cert_set1_chain,
+//GO(ssl_cert_set_cert_cb,
+//GO(ssl_cert_set_cert_store,
+//GO(ssl_cert_set_current,
+//GO(ssl_cert_set_default_md,
+//GO(ssl_cert_type,
+//GO(SSL_check_chain,
+//GO(ssl_check_clienthello_tlsext_late,
+GO(SSL_check_private_key, iFp)
+//GO(ssl_check_serverhello_tlsext,
+//GO(ssl_check_srvr_ecc_cert_and_alg,
+GO(SSL_CIPHER_description, pFppi)
+GO(SSL_CIPHER_find, pFpp)
+GO(SSL_CIPHER_get_bits, iFpp)
+//GO(ssl_cipher_get_cert_index,
+//GO(ssl_cipher_get_evp,
+GO(SSL_CIPHER_get_id, uFp)
+GO(SSL_CIPHER_get_name, pFp)
+GO(SSL_CIPHER_get_version, pFp)
+//GO(ssl_cipher_id_cmp,
+//GO(ssl_cipher_list_to_bytes,
+//GO(ssl_cipher_ptr_id_cmp,
+GO(SSL_clear, iFp)
+//GO(ssl_clear_bad_session,
+//GO(ssl_clear_cipher_ctx,
+//GO(ssl_clear_hash_ctx,
+//GO(SSL_COMP_add_compression_method,
+//GO(SSL_COMP_free_compression_methods,
+//GO(SSL_COMP_get_compression_methods,
+//GO(SSL_COMP_get_name,
+//GO(SSL_COMP_set0_compression_methods,
+//GO(SSL_CONF_cmd,
+//GO(SSL_CONF_cmd_argv,
+//GO(SSL_CONF_cmd_value_type,
+//GO(SSL_CONF_CTX_clear_flags,
+//GO(SSL_CONF_CTX_finish,
+//GO(SSL_CONF_CTX_free,
+//GO(SSL_CONF_CTX_new,
+//GO(SSL_CONF_CTX_set1_prefix,
+//GO(SSL_CONF_CTX_set_flags,
+//GO(SSL_CONF_CTX_set_ssl,
+//GO(SSL_CONF_CTX_set_ssl_ctx,
+GO(SSL_connect, iFp)
+//GO(SSL_copy_session_id,
+//GO(ssl_create_cipher_list,
+GO(SSL_ctrl, lFpilp)
+GO(SSL_CTX_add_client_CA, iFpp)
+//GO(SSL_CTX_add_client_custom_ext,
+//GO(SSL_CTX_add_server_custom_ext,
+//GO(SSL_CTX_add_session,
+GOM(SSL_CTX_callback_ctrl, lFEpip)
+GO(SSL_CTX_check_private_key, iFp)
+GO(SSL_CTX_config, iFpp)
+GO(SSL_CTX_ctrl, lFpilp)
+//GO(SSL_CTX_flush_sessions,
+GO(SSL_CTX_free, vFp)
+//GO(SSL_CTX_get0_certificate,
+//GO(SSL_CTX_get0_param,
+//GO(SSL_CTX_get0_privatekey,
+GO(SSL_CTX_get_cert_store, pFp)
+//GO(SSL_CTX_get_client_CA_list,
+//GO(SSL_CTX_get_client_cert_cb,
+GO(SSL_CTX_get_default_passwd_cb_userdata, pFp)
+GO(SSL_CTX_get_ex_data, pFpi)
+//GO(SSL_CTX_get_ex_new_index,
+//GO(SSL_CTX_get_info_callback,
+//GO(SSL_CTX_get_quiet_shutdown,
+//GO(SSL_CTX_get_ssl_method,
+//GO(SSL_CTX_get_timeout,
+//GO(SSL_CTX_get_verify_callback,
+//GO(SSL_CTX_get_verify_depth,
+//GO(SSL_CTX_get_verify_mode,
+GO(SSL_CTX_load_verify_locations, iFppp)
+GO(SSL_CTX_new, pFp)
+//GO(SSL_CTX_remove_session,
+//GO(SSL_CTX_sess_get_get_cb,
+//GO(SSL_CTX_sess_get_new_cb,
+//GO(SSL_CTX_sess_get_remove_cb,
+//GO(SSL_CTX_sessions,
+//GO(SSL_CTX_sess_set_get_cb,
+//GO(SSL_CTX_sess_set_new_cb,
+//GO(SSL_CTX_sess_set_remove_cb,
+//GO(SSL_CTX_set1_param,
+GO(SSL_CTX_set_alpn_protos, iFppu)
+GOM(SSL_CTX_set_alpn_select_cb, vFEppp)
+//GO(SSL_CTX_set_cert_cb,
+GO(SSL_CTX_set_cert_store, vFpp)
+GOM(SSL_CTX_set_cert_verify_callback, vFEppp)
+GO(SSL_CTX_set_ciphersuites, iFpp)
+GO(SSL_CTX_set_cipher_list, iFpp)
+GO(SSL_CTX_set_client_CA_list, vFpp)
+GOM(SSL_CTX_set_client_cert_cb, vFEpp)
+//GO(SSL_CTX_set_client_cert_engine,
+//GO(SSL_CTX_set_cookie_generate_cb,
+//GO(SSL_CTX_set_cookie_verify_cb,
+GOM(SSL_CTX_set_default_passwd_cb, vFEpp)
+GO(SSL_CTX_set_default_passwd_cb_userdata, vFpp)
+GO(SSL_CTX_set_default_verify_paths, iFp)
+//GO(SSL_CTX_set_ex_data,
+//GO(SSL_CTX_set_generate_session_id,
+//GO(SSL_CTX_set_info_callback,
+//GO(SSL_CTX_set_msg_callback,
+//GO(SSL_CTX_set_next_protos_advertised_cb,
+GOM(SSL_CTX_set_next_proto_select_cb, vFEppp)
+GO(SSL_CTX_set_options, lFpl)
+//GO(SSL_CTX_set_psk_client_callback,
+//GO(SSL_CTX_set_psk_server_callback,
+//GO(SSL_CTX_set_purpose,
+GO(SSL_CTX_set_quiet_shutdown, vFpi)
+GO(SSL_CTX_set_security_level, vFpi)
+//GO(SSL_CTX_set_session_id_context,
+//GO(SSL_CTX_set_srp_cb_arg,
+//GO(SSL_CTX_set_srp_client_pwd_callback,
+//GO(SSL_CTX_set_srp_password,
+//GO(SSL_CTX_set_srp_strength,
+//GO(SSL_CTX_set_srp_username,
+//GO(SSL_CTX_set_srp_username_callback,
+//GO(SSL_CTX_set_srp_verify_param_callback,
+//GO(SSL_CTX_set_ssl_version,
+//GO(SSL_CTX_set_timeout,
+//GO(SSL_CTX_set_tlsext_use_srtp,
+//GO(SSL_CTX_set_tmp_dh_callback,
+//GO(SSL_CTX_set_tmp_ecdh_callback,
+//GO(SSL_CTX_set_tmp_rsa_callback,
+//GO(SSL_CTX_set_trust,
+GOM(SSL_CTX_set_verify, vFEpip)
+GO(SSL_CTX_set_verify_depth, vFpi)
+//GO(SSL_CTX_SRP_CTX_free,
+//GO(SSL_CTX_SRP_CTX_init,
+GO(SSL_CTX_use_certificate, iFpp)
+GO(SSL_CTX_use_certificate_ASN1, iFpip)
+GO(SSL_CTX_use_certificate_chain_file, iFpp)
+GO(SSL_CTX_use_certificate_file, iFppi)
+GO(SSL_CTX_use_PrivateKey, iFpp)
+GO(SSL_CTX_use_PrivateKey_ASN1, iFuppi)
+GO(SSL_CTX_use_PrivateKey_file, iFppi)
+//GO(SSL_CTX_use_psk_identity_hint,
+GO(SSL_CTX_use_RSAPrivateKey, iFpp)
+GO(SSL_CTX_use_RSAPrivateKey_ASN1, iFppl)
+GO(SSL_CTX_use_RSAPrivateKey_file, iFppi)
+//GO(SSL_CTX_use_serverinfo,
+//GO(SSL_CTX_use_serverinfo_file,
+//GO(ssl_do_client_cert_cb,
+GO(SSL_do_handshake, iFp)
+//GO(SSL_dup,
+//GO(SSL_dup_CA_list,
+//GO(SSL_export_keying_material,
+//GO(SSL_extension_supported,
+//GO(ssl_fill_hello_random,
+GO(SSL_free, vFp)
+//GO(ssl_free_wbio_buffer,
+GO(SSL_get0_alpn_selected, iFppp)
+GO(SSL_get0_next_proto_negotiated, vFppp)
+//GO(SSL_get0_param,
+GO(SSL_get0_peer_certificate, pFp)
+GO(SSL_get0_session, pFp)
+GO(SSL_get1_peer_certificate, pFp)
+GO(SSL_get1_session, pFp)
+//GO(ssl_get_algorithm2,
+GO(SSL_get_certificate, pFp)
+//GO(ssl_get_cipher_by_char,
+//GO(SSL_get_cipher_list,
+GO(SSL_get_ciphers, pFp)
+//GO(ssl_get_ciphers_by_id,
+GO(SSL_get_client_CA_list, pFp)
+GO(SSL_get_current_cipher, pFp)
+//GO(SSL_get_current_compression,
+//GO(SSL_get_current_expansion,
+//GO(SSL_get_default_timeout,
+GO(SSL_get_error, iFpi)
+GO(SSL_get_ex_data, pFpi)
+GO(SSL_get_ex_data_X509_STORE_CTX_idx, iFv)
+GOM(SSL_get_ex_new_index, iFElpppp)
+//GO(SSL_get_fd,
+GO(SSL_get_finished, LFppL)
+//GO(ssl_get_handshake_digest,
+//GO(SSL_get_info_callback,
+//GO(ssl_get_new_session,
+GO(SSL_get_peer_cert_chain, pFp)
+GO(SSL_get_peer_finished, LFppL)
+//GO(ssl_get_prev_session,
+GO(SSL_get_privatekey, pFp)
+//GO(SSL_get_psk_identity,
+//GO(SSL_get_psk_identity_hint,
+//GO(SSL_get_quiet_shutdown,
+//GO(SSL_get_rbio,
+//GO(SSL_get_read_ahead,
+//GO(SSL_get_rfd,
+//GO(SSL_get_selected_srtp_profile,
+//GO(ssl_get_server_cert_serverinfo,
+//GO(SSL_get_servername,
+//GO(SSL_get_servername_type,
+//GO(ssl_get_server_send_pkey,
+GO(SSL_get_session, pFp)
+//GO(SSL_get_shared_ciphers,
+//GO(SSL_get_shared_sigalgs,
+GO(SSL_get_shutdown, iFp)
+//GO(SSL_get_sigalgs,
+//GO(ssl_get_sign_pkey,
+//GO(SSL_get_srp_g,
+//GO(SSL_get_srp_N,
+//GO(SSL_get_srp_userinfo,
+//GO(SSL_get_srp_username,
+//GO(SSL_get_srtp_profiles,
+GO(SSL_get_SSL_CTX, pFp)
+//GO(SSL_get_ssl_method,
+GOM(SSL_get_verify_callback, pFEp)
+GO(SSL_get_verify_depth, iFp)
+GO(SSL_get_verify_mode, iFp)
+GO(SSL_get_verify_result, iFp)
+GO(SSL_get_version, pFp)
+//GO(SSL_get_wbio,
+//GO(SSL_get_wfd,
+//GO(SSL_has_matching_session_id,
+//GO(ssl_init_wbio_buffer,
+GO(SSL_is_init_finished, iFp)
+GO(SSL_is_server, iFp)
+GO(SSL_library_init, iFv)
+//GO(ssl_load_ciphers,
+//GO(SSL_load_client_CA_file,
+GO(SSL_load_error_strings, vFv)
+GO(SSL_new, pFp)
+//GO(ssl_ok,
+//GO(ssl_parse_clienthello_renegotiate_ext,
+//GO(ssl_parse_clienthello_tlsext,
+//GO(ssl_parse_clienthello_use_srtp_ext,
+//GO(ssl_parse_serverhello_renegotiate_ext,
+//GO(ssl_parse_serverhello_tlsext,
+//GO(ssl_parse_serverhello_use_srtp_ext,
+GO(SSL_peek, iFppi)
+GO(SSL_pending, iFp)
+//GO(ssl_prepare_clienthello_tlsext,
+//GO(ssl_prepare_serverhello_tlsext,
+GO(SSL_read, iFppi)
+GO(SSL_renegotiate, iFp)
+GO(SSL_renegotiate_abbreviated, iFp)
+GO(SSL_renegotiate_pending, iFp)
+//GO(ssl_replace_hash,
+//GO(SSL_rstate_string,
+//GO(SSL_rstate_string_long,
+GO(SSL_select_next_proto, iFpppupu)
+//GO(ssl_sess_cert_free,
+//GO(ssl_sess_cert_new,
+GO(ssl_session_dup, pFp)
+GO(SSL_SESSION_dup, pFp)
+GO(SSL_SESSION_free, vFp)
+//GO(SSL_SESSION_get0_peer,
+//GO(SSL_SESSION_get_compress_id,
+//GO(SSL_SESSION_get_ex_data,
+//GO(SSL_SESSION_get_ex_new_index,
+//GO(SSL_SESSION_get_id,
+//GO(SSL_SESSION_get_time,
+//GO(SSL_SESSION_get_timeout,
+GO(SSL_SESSION_new, pFv)
+//GO(SSL_SESSION_print,
+//GO(SSL_SESSION_print_fp,
+GO(SSL_session_reused, iFp)
+//GO(SSL_SESSION_set1_id_context,
+//GO(SSL_SESSION_set_ex_data,
+//GO(SSL_SESSION_set_time,
+//GO(SSL_SESSION_set_timeout,
+GO(SSL_SESSION_up_ref, iFp)
+//GO(SSL_set1_param,
+GO(SSL_set_accept_state, vFp)
+//GO(SSL_set_alpn_protos,
+GO(SSL_set_bio, vFppp)
+//GO(SSL_set_cert_cb,
+//GO(ssl_set_cert_masks,
+GO(SSL_set_cipher_list, iFpp)
+GO(SSL_set_client_CA_list, vFpp)
+//GO(ssl_set_client_disabled,
+GO(SSL_set_connect_state, vFp)
+//GO(SSL_set_debug,
+GO(SSL_set_ex_data, iFpip)
+GO(SSL_set_fd, iFpi)
+//GO(SSL_set_generate_session_id,
+//GO(SSL_set_info_callback,
+//GO(SSL_set_msg_callback,
+GO(SSL_set_options, UFpU)
+//GO(ssl_set_peer_cert_type,
+GOM(SSL_set_psk_client_callback, vFEpp)
+//GO(SSL_set_psk_server_callback,
+//GO(SSL_set_purpose,
+GO(SSL_set_quiet_shutdown, vFpi)
+//GO(SSL_set_read_ahead,
+GO(SSL_set_rfd, iFpi)
+GO(SSL_set_session, iFpp)
+//GO(SSL_set_session_id_context,
+//GO(SSL_set_session_secret_cb,
+//GO(SSL_set_session_ticket_ext,
+//GO(SSL_set_session_ticket_ext_cb,
+GO(SSL_set_shutdown, iFp)
+//GO(SSL_set_srp_server_param,
+//GO(SSL_set_srp_server_param_pw,
+//GO(SSL_set_SSL_CTX,
+//GO(SSL_set_ssl_method,
+//GO(SSL_set_state,
+//GO(SSL_set_tlsext_use_srtp,
+//GO(SSL_set_tmp_dh_callback,
+//GO(SSL_set_tmp_ecdh_callback,
+//GO(SSL_set_tmp_rsa_callback,
+//GO(SSL_set_trust,
+GOM(SSL_set_verify, vFEpip)
+GO(SSL_set_verify_depth, vFpi)
+//GO(SSL_set_verify_result,
+GO(SSL_set_wfd, iFpi)
+GO(SSL_shutdown, iFp)
+//GO(SSL_SRP_CTX_free,
+//GO(SSL_SRP_CTX_init,
+//GO(SSL_srp_server_param_with_username,
+GO(SSL_state, iFp)
+//GO(SSL_state_string,
+//GO(SSL_state_string_long,
+//GO(ssl_undefined_const_function,
+//GO(ssl_undefined_function,
+//GO(ssl_undefined_void_function,
+//GO(ssl_update_cache,
+GO(SSL_use_certificate, iFpp)
+GO(SSL_use_certificate_ASN1, iFppi)
+GO(SSL_use_certificate_file, iFppi)
+GO(SSL_use_PrivateKey, iFpp)
+GO(SSL_use_PrivateKey_ASN1, iFppl)
+GO(SSL_use_PrivateKey_file, iFppi)
+//GO(SSL_use_psk_identity_hint,
+GO(SSL_use_RSAPrivateKey, iFpp)
+GO(SSL_use_RSAPrivateKey_ASN1, iFppl)
+GO(SSL_use_RSAPrivateKey_file, iFppi)
+GO(SSLv23_client_method, pFv)
+GO(SSLv23_method, pFv)
+GO(SSLv23_server_method, pFv)
+GO(SSLv2_client_method, pFv)
+GO(SSLv2_method, pFv)
+GO(SSLv2_server_method, pFv)
+GO(SSLv3_client_method, pFv)
+GO(SSLv3_method, pFv)
+GO(SSLv3_server_method, pFv)
+//GO(ssl_verify_alarm_type,
+//GO(ssl_verify_cert_chain,
+GO(SSL_version, iFp)
+//GO(SSL_want,
+GO(SSL_write, iFppi)
+//GO(tls12_check_peer_sigalg,
+//GO(tls12_get_hash,
+//GO(tls12_get_psigalgs,
+//GO(tls12_get_sigandhash,
+//GO(tls12_get_sigid,
+//GO(tls1_alert_code,
+//GO(tls1_cbc_remove_padding,
+//GO(tls1_cert_verify_mac,
+//GO(tls1_change_cipher_state,
+//GO(tls1_check_chain,
+//GO(tls1_check_curve,
+//GO(tls1_check_ec_tmp_key,
+//GO(tls1_clear,
+//GO(tls1_default_timeout,
+//GO(tls1_ec_curve_id2nid,
+//GO(tls1_ec_nid2curve_id,
+//GO(tls1_enc,
+//GO(tls1_export_keying_material,
+//GO(tls1_final_finish_mac,
+//GO(tls1_free,
+//GO(tls1_generate_master_secret,
+//GO(tls1_heartbeat,
+//GO(tls1_mac,
+//GO(tls1_new,
+//GO(tls1_process_heartbeat,
+//GO(tls1_process_sigalgs,
+//GO(tls1_process_ticket,
+//GO(tls1_save_sigalgs,
+//GO(tls1_set_cert_validity,
+//GO(tls1_set_curves,
+//GO(tls1_set_curves_list,
+//GO(tls1_set_server_sigalgs,
+//GO(tls1_set_sigalgs,
+//GO(tls1_set_sigalgs_list,
+//GO(tls1_setup_key_block,
+//GO(tls1_shared_curve,
+GO(TLS_method, pFv)
+GO(TLS_server_method, pFv)
+GO(TLS_client_method, pFv)
+GO(TLSv1_1_client_method, pFv)
+GO(TLSv1_1_method, pFv)
+GO(TLSv1_1_server_method, pFv)
+GO(TLSv1_2_client_method, pFv)
+GO(TLSv1_2_method, pFv)
+GO(TLSv1_2_server_method, pFv)
+GO(TLSv1_client_method, pFv)
+GO(TLSv1_method, pFv)
+GO(verify_callback, iFip)
+
+GO(TLSv1_server_method, pFv) // not always present in lib
diff --git a/src/wrapped/wrappedlibssl_private.h b/src/wrapped/wrappedlibssl_private.h
index 755854d..fa2a083 100755..100644
--- a/src/wrapped/wrappedlibssl_private.h
+++ b/src/wrapped/wrappedlibssl_private.h
@@ -56,13 +56,14 @@ GO(d2i_SSL_SESSION, pFppl)
//GO(dtls1_stop_timer,
//GO(dtls1_write_app_data_bytes,
//GO(dtls1_write_bytes,
-//GO(DTLS_client_method,
+GO(DTLS_client_method, pFv)
GO(DTLS_method, pFv)
GO(DTLS_server_method, pFv)
GO(DTLSv1_2_client_method, pFv)
GO(DTLSv1_2_method, pFv)
GO(DTLSv1_2_server_method, pFv)
GO(DTLSv1_client_method, pFv)
+GO(DTLSv1_listen, iFpp)
GO(DTLSv1_method, pFv)
GO(DTLSv1_server_method, pFv)
//GO(ERR_load_SSL_strings,
@@ -224,7 +225,7 @@ GO(SSL_check_private_key, iFp)
//GO(ssl_check_serverhello_tlsext,
//GO(ssl_check_srvr_ecc_cert_and_alg,
GO(SSL_CIPHER_description, pFppi)
-//GO(SSL_CIPHER_find,
+GO(SSL_CIPHER_find, pFpp)
GO(SSL_CIPHER_get_bits, iFpp)
//GO(ssl_cipher_get_cert_index,
//GO(ssl_cipher_get_evp,
@@ -243,17 +244,17 @@ GO(SSL_clear, iFp)
//GO(SSL_COMP_get_compression_methods,
//GO(SSL_COMP_get_name,
//GO(SSL_COMP_set0_compression_methods,
-//GO(SSL_CONF_cmd,
-//GO(SSL_CONF_cmd_argv,
-//GO(SSL_CONF_cmd_value_type,
+GO(SSL_CONF_cmd, iFppp)
+GO(SSL_CONF_cmd_argv, iFppp)
+GO(SSL_CONF_cmd_value_type, iFpp)
//GO(SSL_CONF_CTX_clear_flags,
-//GO(SSL_CONF_CTX_finish,
-//GO(SSL_CONF_CTX_free,
-//GO(SSL_CONF_CTX_new,
+GO(SSL_CONF_CTX_finish, iFp)
+GO(SSL_CONF_CTX_free, vFp)
+GO(SSL_CONF_CTX_new, pFv)
//GO(SSL_CONF_CTX_set1_prefix,
-//GO(SSL_CONF_CTX_set_flags,
+GO(SSL_CONF_CTX_set_flags, uFpu)
//GO(SSL_CONF_CTX_set_ssl,
-//GO(SSL_CONF_CTX_set_ssl_ctx,
+GO(SSL_CONF_CTX_set_ssl_ctx, vFpp)
GO(SSL_connect, iFp)
//GO(SSL_copy_session_id,
//GO(ssl_create_cipher_list,
@@ -264,6 +265,7 @@ GO(SSL_CTX_add_client_CA, iFpp)
//GO(SSL_CTX_add_session,
GOM(SSL_CTX_callback_ctrl, lFEpip)
GO(SSL_CTX_check_private_key, iFp)
+GO(SSL_CTX_config, iFpp)
GO(SSL_CTX_ctrl, lFpilp)
//GO(SSL_CTX_flush_sessions,
GO(SSL_CTX_free, vFp)
@@ -278,6 +280,7 @@ GO(SSL_CTX_get_ex_data, pFpi)
//GO(SSL_CTX_get_ex_new_index,
//GO(SSL_CTX_get_info_callback,
//GO(SSL_CTX_get_quiet_shutdown,
+GO(SSL_CTX_get_security_level, iFp)
//GO(SSL_CTX_get_ssl_method,
//GO(SSL_CTX_get_timeout,
//GO(SSL_CTX_get_verify_callback,
@@ -291,20 +294,21 @@ GO(SSL_CTX_new, pFp)
//GO(SSL_CTX_sess_get_remove_cb,
//GO(SSL_CTX_sessions,
//GO(SSL_CTX_sess_set_get_cb,
-//GO(SSL_CTX_sess_set_new_cb,
+GOM(SSL_CTX_sess_set_new_cb, vFEpp)
//GO(SSL_CTX_sess_set_remove_cb,
//GO(SSL_CTX_set1_param,
-//GO(SSL_CTX_set_alpn_protos,
-//GO(SSL_CTX_set_alpn_select_cb,
+GO(SSL_CTX_set_alpn_protos, iFppu)
+GOM(SSL_CTX_set_alpn_select_cb, vFEppp)
//GO(SSL_CTX_set_cert_cb,
GO(SSL_CTX_set_cert_store, vFpp)
GOM(SSL_CTX_set_cert_verify_callback, vFEppp)
GO(SSL_CTX_set_cipher_list, iFpp)
+GO(SSL_CTX_set_ciphersuites, iFpp)
GO(SSL_CTX_set_client_CA_list, vFpp)
GOM(SSL_CTX_set_client_cert_cb, vFEpp)
//GO(SSL_CTX_set_client_cert_engine,
-//GO(SSL_CTX_set_cookie_generate_cb,
-//GO(SSL_CTX_set_cookie_verify_cb,
+GOM(SSL_CTX_set_cookie_generate_cb, vFEpp)
+GOM(SSL_CTX_set_cookie_verify_cb, vFEpp)
GOM(SSL_CTX_set_default_passwd_cb, vFEpp)
GO(SSL_CTX_set_default_passwd_cb_userdata, vFpp)
GO(SSL_CTX_set_default_verify_paths, iFp)
@@ -319,6 +323,7 @@ GO(SSL_CTX_set_options, lFpl)
//GO(SSL_CTX_set_psk_server_callback,
//GO(SSL_CTX_set_purpose,
GO(SSL_CTX_set_quiet_shutdown, vFpi)
+GO(SSL_CTX_set_security_level, vFpi)
//GO(SSL_CTX_set_session_id_context,
//GO(SSL_CTX_set_srp_cb_arg,
//GO(SSL_CTX_set_srp_client_pwd_callback,
@@ -345,7 +350,7 @@ GO(SSL_CTX_use_certificate_file, iFppi)
GO(SSL_CTX_use_PrivateKey, iFpp)
GO(SSL_CTX_use_PrivateKey_ASN1, iFuppi)
GO(SSL_CTX_use_PrivateKey_file, iFppi)
-//GO(SSL_CTX_use_psk_identity_hint,
+GO(SSL_CTX_use_psk_identity_hint, iFpp)
GO(SSL_CTX_use_RSAPrivateKey, iFpp)
GO(SSL_CTX_use_RSAPrivateKey_ASN1, iFppl)
GO(SSL_CTX_use_RSAPrivateKey_file, iFppi)
@@ -360,7 +365,7 @@ GO(SSL_do_handshake, iFp)
//GO(ssl_fill_hello_random,
GO(SSL_free, vFp)
//GO(ssl_free_wbio_buffer,
-//GO(SSL_get0_alpn_selected,
+GO(SSL_get0_alpn_selected, vFppp)
GO(SSL_get0_next_proto_negotiated, vFppp)
//GO(SSL_get0_param,
GO(SSL_get0_session, pFp)
@@ -372,6 +377,7 @@ GO(SSL_get_certificate, pFp)
GO(SSL_get_ciphers, pFp)
//GO(ssl_get_ciphers_by_id,
GO(SSL_get_client_CA_list, pFp)
+GO(SSL_get_client_random, LFppL)
GO(SSL_get_current_cipher, pFp)
//GO(SSL_get_current_compression,
//GO(SSL_get_current_expansion,
@@ -393,7 +399,7 @@ GO(SSL_get_privatekey, pFp)
//GO(SSL_get_psk_identity,
//GO(SSL_get_psk_identity_hint,
//GO(SSL_get_quiet_shutdown,
-//GO(SSL_get_rbio,
+GO(SSL_get_rbio, pFp)
//GO(SSL_get_read_ahead,
//GO(SSL_get_rfd,
//GO(SSL_get_selected_srtp_profile,
@@ -405,6 +411,7 @@ GO(SSL_get_session, pFp)
//GO(SSL_get_shared_ciphers,
//GO(SSL_get_shared_sigalgs,
GO(SSL_get_shutdown, iFp)
+GO(SSL_get_state, iFp)
//GO(SSL_get_sigalgs,
//GO(ssl_get_sign_pkey,
//GO(SSL_get_srp_g,
@@ -423,6 +430,8 @@ GO(SSL_get_version, pFp)
//GO(SSL_get_wfd,
//GO(SSL_has_matching_session_id,
//GO(ssl_init_wbio_buffer,
+GO(SSL_in_init, iFP)
+GO(SSL_is_init_finished, iFp)
GO(SSL_is_server, iFp)
GO(SSL_library_init, iFv)
//GO(ssl_load_ciphers,
@@ -458,11 +467,15 @@ GO(SSL_SESSION_free, vFp)
//GO(SSL_SESSION_get_ex_data,
//GO(SSL_SESSION_get_ex_new_index,
//GO(SSL_SESSION_get_id,
+GO(SSL_SESSION_get_master_key, LFppL)
+GO(SSL_SESSION_get_ticket_lifetime_hint, LFp)
//GO(SSL_SESSION_get_time,
-//GO(SSL_SESSION_get_timeout,
+//GO(SSL_SESSION_get_timeout,
+GO(SSL_SESSION_is_resumable, iFp)
GO(SSL_SESSION_new, pFv)
//GO(SSL_SESSION_print,
//GO(SSL_SESSION_print_fp,
+GO(SSL_session_reused, iFp)
//GO(SSL_SESSION_set1_id_context,
//GO(SSL_SESSION_set_ex_data,
//GO(SSL_SESSION_set_time,
@@ -470,7 +483,7 @@ GO(SSL_SESSION_new, pFv)
GO(SSL_SESSION_up_ref, iFp)
//GO(SSL_set1_param,
GO(SSL_set_accept_state, vFp)
-//GO(SSL_set_alpn_protos,
+GO(SSL_set_alpn_protos, iFppu)
GO(SSL_set_bio, vFppp)
//GO(SSL_set_cert_cb,
//GO(ssl_set_cert_masks,
@@ -484,9 +497,11 @@ GO(SSL_set_fd, iFpi)
//GO(SSL_set_generate_session_id,
//GO(SSL_set_info_callback,
//GO(SSL_set_msg_callback,
+GO(SSL_set_options, LFpL)
//GO(ssl_set_peer_cert_type,
GOM(SSL_set_psk_client_callback, vFEpp)
-//GO(SSL_set_psk_server_callback,
+GOM(SSL_set_psk_server_callback, vFEpp)
+GOM(SSL_set_psk_use_session_callback, vFEpp)
//GO(SSL_set_purpose,
GO(SSL_set_quiet_shutdown, vFpi)
//GO(SSL_set_read_ahead,
diff --git a/src/wrapped/wrappedlibtinfo.c b/src/wrapped/wrappedlibtinfo.c
index 6e15e49..1827bb0 100755..100644
--- a/src/wrapped/wrappedlibtinfo.c
+++ b/src/wrapped/wrappedlibtinfo.c
@@ -38,7 +38,7 @@ GO(4)
static uintptr_t my_putc_fct_##A = 0; \
static int my_putc_##A(char c) \
{ \
- return (int)RunFunction(my_context, my_putc_fct_##A, 1, c); \
+ return (int)RunFunctionFmt(my_putc_fct_##A, "c", c); \
}
SUPER()
#undef GO
diff --git a/src/wrapped/wrappedlibtinfo6.c b/src/wrapped/wrappedlibtinfo6.c
index 9b1fc0a..c14c8ae 100755..100644
--- a/src/wrapped/wrappedlibtinfo6.c
+++ b/src/wrapped/wrappedlibtinfo6.c
@@ -38,7 +38,7 @@ GO(4)
static uintptr_t my_putc_fct_##A = 0; \
static int my_putc_##A(char c) \
{ \
- return (int)RunFunction(my_context, my_putc_fct_##A, 1, c); \
+ return (int)RunFunctionFmt(my_putc_fct_##A, "c", c); \
}
SUPER()
#undef GO
diff --git a/src/wrapped/wrappedlibtinfo6_private.h b/src/wrapped/wrappedlibtinfo6_private.h
index 41ec64f..41ec64f 100755..100644
--- a/src/wrapped/wrappedlibtinfo6_private.h
+++ b/src/wrapped/wrappedlibtinfo6_private.h
diff --git a/src/wrapped/wrappedlibtinfo_private.h b/src/wrapped/wrappedlibtinfo_private.h
index 41ec64f..41ec64f 100755..100644
--- a/src/wrapped/wrappedlibtinfo_private.h
+++ b/src/wrapped/wrappedlibtinfo_private.h
diff --git a/src/wrapped/wrappedlibusb1.c b/src/wrapped/wrappedlibusb1.c
index e34f440..c5fea90 100755..100644
--- a/src/wrapped/wrappedlibusb1.c
+++ b/src/wrapped/wrappedlibusb1.c
@@ -45,7 +45,7 @@ GO(9) \
static uintptr_t my_hotplug_fct_##A = 0; \
static int my_hotplug_##A(void* ctx, void* device, int event, void* data) \
{ \
- return (int)RunFunction(my_context, my_hotplug_fct_##A, 4, ctx, device, event, data); \
+ return (int)RunFunctionFmt(my_hotplug_fct_##A, "ppip", ctx, device, event, data); \
}
SUPER()
#undef GO
@@ -67,7 +67,7 @@ static void* findhotplugFct(void* fct)
static uintptr_t my_transfert_fct_##A = 0; \
static void my_transfert_##A(void* ctx) \
{ \
- RunFunction(my_context, my_transfert_fct_##A, 1, ctx); \
+ RunFunctionFmt(my_transfert_fct_##A, "p", ctx); \
}
SUPER()
#undef GO
@@ -139,7 +139,7 @@ EXPORT int my_libusb_submit_transfer(x64emu_t* emu, my_libusb_transfer_t* t)
{
t->callback = findtransfertFct(t->callback);
return my->libusb_submit_transfer(t); // don't put back callback, it's unknown if it's safe
-}
+}
EXPORT int my_libusb_cancel_transfer(x64emu_t* emu, my_libusb_transfer_t* t)
{
diff --git a/src/wrapped/wrappedlibusb1_private.h b/src/wrapped/wrappedlibusb1_private.h
index 6aa06db..6aa06db 100755..100644
--- a/src/wrapped/wrappedlibusb1_private.h
+++ b/src/wrapped/wrappedlibusb1_private.h
diff --git a/src/wrapped/wrappedlibuuid.c b/src/wrapped/wrappedlibuuid.c
index d80c991..d80c991 100755..100644
--- a/src/wrapped/wrappedlibuuid.c
+++ b/src/wrapped/wrappedlibuuid.c
diff --git a/src/wrapped/wrappedlibuuid_private.h b/src/wrapped/wrappedlibuuid_private.h
index 4402e96..4402e96 100755..100644
--- a/src/wrapped/wrappedlibuuid_private.h
+++ b/src/wrapped/wrappedlibuuid_private.h
diff --git a/src/wrapped/wrappedlibva.c b/src/wrapped/wrappedlibva.c
index 2900057..8c33132 100644
--- a/src/wrapped/wrappedlibva.c
+++ b/src/wrapped/wrappedlibva.c
@@ -6,13 +6,82 @@
#include "wrappedlibs.h"
+#include "debug.h"
#include "wrapper.h"
#include "bridge.h"
#include "librarian/library_private.h"
#include "x64emu.h"
+#include "callback.h"
+#include "librarian.h"
+#include "box64context.h"
+#include "emu/x64emu_private.h"
+#include "myalign.h"
const char* libvaName = "libva.so.2";
#define LIBNAME libva
+#define ADDED_FUNCTIONS() \
+
+#include "generated/wrappedlibvatypes.h"
+
+#include "wrappercallback.h"
+
+#define SUPER() \
+GO(0) \
+GO(1) \
+GO(2) \
+GO(3)
+
+// VAMessageCallback
+#define GO(A) \
+static uintptr_t my_VAMessageCallback_fct_##A = 0; \
+static void my_VAMessageCallback_##A(void* a, void* b) \
+{ \
+ RunFunctionFmt(my_VAMessageCallback_fct_##A, "pp", a, b); \
+}
+SUPER()
+#undef GO
+static void* findVAMessageCallbackFct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_VAMessageCallback_fct_##A == (uintptr_t)fct) return my_VAMessageCallback_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_VAMessageCallback_fct_##A == 0) {my_VAMessageCallback_fct_##A = (uintptr_t)fct; return my_VAMessageCallback_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libxa VAMessageCallback callback\n");
+ return NULL;
+}
+static void* reverse_VAMessageCallbackFct(void* fct)
+{
+ if(!fct) return fct;
+ if(CheckBridged(my_lib->w.bridge, fct))
+ return (void*)CheckBridged(my_lib->w.bridge, fct);
+ #define GO(A) if(my_VAMessageCallback_##A == fct) return (void*)my_VAMessageCallback_fct_##A;
+ SUPER()
+ #undef GO
+ return (void*)AddBridge(my_lib->w.bridge, vFpp, fct, 0, NULL);
+}
+
+#undef SUPER
+
+EXPORT void* my_vaSetErrorCallback(x64emu_t* emu, void* dpy, void* f, void* ctx)
+{
+ return reverse_VAMessageCallbackFct(my->vaSetErrorCallback(dpy, findVAMessageCallbackFct(f), ctx));
+}
+
+EXPORT void* my_vaSetInfoCallback(x64emu_t* emu, void* dpy, void* f, void* ctx)
+{
+ return reverse_VAMessageCallbackFct(my->vaSetInfoCallback(dpy, findVAMessageCallbackFct(f), ctx));
+}
+
+#define CUSTOM_INIT \
+ getMy(lib);
+
+#define CUSTOM_FINI \
+ freeMy();
+
#include "wrappedlib_init.h"
diff --git a/src/wrapped/wrappedlibva_private.h b/src/wrapped/wrappedlibva_private.h
index dd83be2..cba8dc0 100644
--- a/src/wrapped/wrappedlibva_private.h
+++ b/src/wrapped/wrappedlibva_private.h
@@ -78,9 +78,9 @@ GO(vaQueryVideoProcPipelineCaps, iFpupup)
GO(vaRenderPicture, iFpupi)
//GO(vaSetDisplayAttributes,
//GO(vaSetDriverName,
-//GO(vaSetErrorCallback,
+GOM(vaSetErrorCallback, pFEppp)
//GO(vaSetImagePalette,
-//GO(vaSetInfoCallback,
+GOM(vaSetInfoCallback, pFEppp)
//GO(vaSetSubpictureChromakey,
//GO(vaSetSubpictureGlobalAlpha,
//GO(vaSetSubpictureImage,
diff --git a/src/wrapped/wrappedlibvdpau.c b/src/wrapped/wrappedlibvdpau.c
index 146ef72..16eef5a 100644
--- a/src/wrapped/wrappedlibvdpau.c
+++ b/src/wrapped/wrappedlibvdpau.c
@@ -6,13 +6,37 @@
#include "wrappedlibs.h"
+#include "debug.h"
#include "wrapper.h"
#include "bridge.h"
#include "librarian/library_private.h"
#include "x64emu.h"
+#include "callback.h"
+#include "librarian.h"
+#include "box64context.h"
+#include "emu/x64emu_private.h"
+#include "myalign.h"
const char* libvdpauName = "libvdpau.so.1";
#define LIBNAME libvdpau
+
+#define ADDED_FUNCTIONS() \
+
+#include "generated/wrappedlibvdpautypes.h"
+
+#include "wrappercallback.h"
+
+EXPORT uint32_t my_vdp_device_create_x11(x64emu_t* emu, void* display, int screen, void* device, void** get_proc_address)
+{
+ return 1; // VDP_STATUS_NO_IMPLEMENTATION
+}
+
+#define CUSTOM_INIT \
+ getMy(lib);
+
+#define CUSTOM_FINI \
+ freeMy();
+
#include "wrappedlib_init.h"
diff --git a/src/wrapped/wrappedlibvdpau_private.h b/src/wrapped/wrappedlibvdpau_private.h
index 3a06a03..99a0b33 100644
--- a/src/wrapped/wrappedlibvdpau_private.h
+++ b/src/wrapped/wrappedlibvdpau_private.h
@@ -2,4 +2,4 @@
#error meh!
#endif
-//GO(vdp_device_create_x11, iFpipp) // last is a pointer to a VdpGetProcAddress function \ No newline at end of file
+GOM(vdp_device_create_x11, iFpipp) // last is a pointer to a VdpGetProcAddress function \ No newline at end of file
diff --git a/src/wrapped/wrappedlibvorbis.c b/src/wrapped/wrappedlibvorbis.c
index 7449582..7449582 100755..100644
--- a/src/wrapped/wrappedlibvorbis.c
+++ b/src/wrapped/wrappedlibvorbis.c
diff --git a/src/wrapped/wrappedlibvorbis_private.h b/src/wrapped/wrappedlibvorbis_private.h
index 427ef37..427ef37 100755..100644
--- a/src/wrapped/wrappedlibvorbis_private.h
+++ b/src/wrapped/wrappedlibvorbis_private.h
diff --git a/src/wrapped/wrappedlibx11.c b/src/wrapped/wrappedlibx11.c
index bf74a1c..0ee5d08 100755..100644
--- a/src/wrapped/wrappedlibx11.c
+++ b/src/wrapped/wrappedlibx11.c
@@ -43,15 +43,15 @@ typedef struct ximage_s {
void*(*create_image)(
void* /* display */,
void* /* visual */,
- uint64_t /* depth */, // Should be uint32_t instead
- int64_t /* format */, // Should be int32_t instead
- int64_t /* offset */, // Should be int32_t instead
+ uint32_t /* depth */,
+ int32_t /* format */,
+ int32_t /* offset */,
void* /* data */,
- uint64_t /* width */, // Should be uint32_t instead
- uint64_t /* height */, // Should be uint32_t instead
- int64_t /* bitmap_pad */, // Should be int32_t instead
- int64_t /* bytes_per_line */); // Should be int32_t instead
- int64_t (*destroy_image) (void*); // Should be int32_t instead
+ uint32_t /* width */,
+ uint32_t /* height */,
+ int32_t /* bitmap_pad */,
+ int32_t /* bytes_per_line */);
+ int32_t (*destroy_image) (void*);
uintptr_t (*get_pixel) (void*, int32_t, int32_t);
int32_t (*put_pixel) (void*, int32_t, int32_t, uintptr_t);
void*(*sub_image) (void*, int32_t, int32_t, uint32_t, uint32_t); //sub_image return a new XImage that need bridging => custom wrapper
@@ -109,14 +109,14 @@ GO(11) \
GO(12) \
GO(13) \
GO(14) \
-GO(15)
+GO(15)
// wire_to_event
#define GO(A) \
static uintptr_t my_wire_to_event_fct_##A = 0; \
static int my_wire_to_event_##A(void* dpy, void* re, void* event) \
{ \
- return (int)RunFunction(my_context, my_wire_to_event_fct_##A, 3, dpy, re, event);\
+ return (int)RunFunctionFmt(my_wire_to_event_fct_##A, "ppp", dpy, re, event);\
}
SUPER()
#undef GO
@@ -149,7 +149,7 @@ static void* reverse_wire_to_eventFct(library_t* lib, void* fct)
static uintptr_t my_event_to_wire_fct_##A = 0; \
static int my_event_to_wire_##A(void* dpy, void* re, void* event) \
{ \
- return (int)RunFunction(my_context, my_event_to_wire_fct_##A, 3, dpy, re, event);\
+ return (int)RunFunctionFmt(my_event_to_wire_fct_##A, "ppp", dpy, re, event);\
}
SUPER()
#undef GO
@@ -182,7 +182,7 @@ static void* reverse_event_to_wireFct(library_t* lib, void* fct)
static uintptr_t my_error_handler_fct_##A = 0; \
static int my_error_handler_##A(void* dpy, void* error) \
{ \
- return (int)RunFunction(my_context, my_error_handler_fct_##A, 2, dpy, error);\
+ return (int)RunFunctionFmt(my_error_handler_fct_##A, "pp", dpy, error);\
}
SUPER()
#undef GO
@@ -215,7 +215,7 @@ static void* reverse_error_handlerFct(library_t* lib, void* fct)
static uintptr_t my_ioerror_handler_fct_##A = 0; \
static int my_ioerror_handler_##A(void* dpy) \
{ \
- return (int)RunFunction(my_context, my_ioerror_handler_fct_##A, 1, dpy);\
+ return (int)RunFunctionFmt(my_ioerror_handler_fct_##A, "p", dpy);\
}
SUPER()
#undef GO
@@ -248,7 +248,7 @@ static void* reverse_ioerror_handlerFct(library_t* lib, void* fct)
static uintptr_t my_exterror_handler_fct_##A = 0; \
static int my_exterror_handler_##A(void* dpy, void* err, void* codes, int* ret_code) \
{ \
- return (int)RunFunction(my_context, my_exterror_handler_fct_##A, 4, dpy, err, codes, ret_code);\
+ return (int)RunFunctionFmt(my_exterror_handler_fct_##A, "pppp", dpy, err, codes, ret_code);\
}
SUPER()
#undef GO
@@ -281,7 +281,7 @@ static void* reverse_exterror_handlerFct(library_t* lib, void* fct)
static uintptr_t my_close_display_fct_##A = 0; \
static int my_close_display_##A(void* dpy, void* codes) \
{ \
- return (int)RunFunction(my_context, my_close_display_fct_##A, 2, dpy, codes);\
+ return (int)RunFunctionFmt(my_close_display_fct_##A, "pp", dpy, codes);\
}
SUPER()
#undef GO
@@ -314,7 +314,7 @@ static void* reverse_close_displayFct(library_t* lib, void* fct)
static uintptr_t my_register_im_fct_##A = 0; \
static void my_register_im_##A(void* dpy, void* u, void* d) \
{ \
- RunFunction(my_context, my_register_im_fct_##A, 3, dpy, u, d); \
+ RunFunctionFmt(my_register_im_fct_##A, "ppp", dpy, u, d); \
}
SUPER()
#undef GO
@@ -347,7 +347,7 @@ static void* reverse_register_imFct(library_t* lib, void* fct)
static uintptr_t my_XConnectionWatchProc_fct_##A = 0; \
static void my_XConnectionWatchProc_##A(void* dpy, void* data, int op, void* d) \
{ \
- RunFunction(my_context, my_XConnectionWatchProc_fct_##A, 4, dpy, data, op, d); \
+ RunFunctionFmt(my_XConnectionWatchProc_fct_##A, "ppip", dpy, data, op, d); \
}
SUPER()
#undef GO
@@ -369,7 +369,7 @@ static void* findXConnectionWatchProcFct(void* fct)
static uintptr_t my_xifevent_fct_##A = 0; \
static int my_xifevent_##A(void* dpy, void* event, void* d) \
{ \
- return RunFunction(my_context, my_xifevent_fct_##A, 3, dpy, event, d); \
+ return RunFunctionFmt(my_xifevent_fct_##A, "ppp", dpy, event, d); \
}
SUPER()
#undef GO
@@ -391,7 +391,7 @@ static void* findxifeventFct(void* fct)
static uintptr_t my_XInternalAsyncHandler_fct_##A = 0; \
static int my_XInternalAsyncHandler_##A(void* dpy, void* rep, void* buf, int len, void* data) \
{ \
- return RunFunction(my_context, my_XInternalAsyncHandler_fct_##A, 5, dpy, rep, buf, len, data); \
+ return RunFunctionFmt(my_XInternalAsyncHandler_fct_##A, "pppip", dpy, rep, buf, len, data); \
}
SUPER()
#undef GO
@@ -414,7 +414,7 @@ static void* findXInternalAsyncHandlerFct(void* fct)
static uintptr_t my_XSynchronizeProc_fct_##A = 0; \
static int my_XSynchronizeProc_##A() \
{ \
- return (int)RunFunction(my_context, my_XSynchronizeProc_fct_##A, 0);\
+ return (int)RunFunctionFmt(my_XSynchronizeProc_fct_##A, "");\
}
SUPER()
#undef GO
@@ -447,7 +447,7 @@ static void* reverse_XSynchronizeProcFct(library_t* lib, void* fct)
static uintptr_t my_XLockDisplay_fct_##A = 0; \
static void my_XLockDisplay_##A(void* dpy) \
{ \
- RunFunction(my_context, my_XLockDisplay_fct_##A, 1, dpy); \
+ RunFunctionFmt(my_XLockDisplay_fct_##A, "p", dpy); \
}
SUPER()
#undef GO
@@ -469,7 +469,7 @@ static void* findXLockDisplayFct(void* fct)
static uintptr_t my_XUnlockDisplay_fct_##A = 0; \
static void my_XUnlockDisplay_##A(void* dpy) \
{ \
- RunFunction(my_context, my_XUnlockDisplay_fct_##A, 1, dpy); \
+ RunFunctionFmt(my_XUnlockDisplay_fct_##A, "p", dpy); \
}
SUPER()
#undef GO
@@ -556,14 +556,14 @@ static int my_XICProc_##A(void* a, void* b, void* c) \
{ \
if (my_XICProc_fct_##A == 0) \
printf_log(LOG_NONE, "%s cannot find XICProc callback\n", __func__);\
- return (int)RunFunction(my_context, my_XICProc_fct_##A, 3, a, b, c); \
+ return (int)RunFunctionFmt(my_XICProc_fct_##A, "ppp", a, b, c); \
} \
static uintptr_t my_XIMProc_fct_##A = 0; \
static void my_XIMProc_##A(void* a, void* b, void* c) \
{ \
if (my_XIMProc_fct_##A == 0) \
printf_log(LOG_NONE, "%s cannot find XIMProc callback\n", __func__);\
- RunFunction(my_context, my_XIMProc_fct_##A, 3, a, b, c); \
+ RunFunctionFmt(my_XIMProc_fct_##A, "ppp", a, b, c); \
}
SUPER()
#undef GO
@@ -666,7 +666,7 @@ EXPORT void* my_XSetICValues(x64emu_t* emu, void* xic, uintptr_t* va) {
SUPER()
}
- void* res = NULL;
+ void* res = NULL;
VA_CALL(my->XSetICValues, xic, new_va, n, res);
box_free(new_va);
box_free(callbacks);
@@ -695,7 +695,7 @@ EXPORT void* my_XSetIMValues(x64emu_t* emu, void* xim, uintptr_t* va) {
SUPER()
}
#undef GO
-
+
void* res = NULL;
VA_CALL(my->XSetIMValues, xim, new_va, n, res)
box_free(new_va);
@@ -757,7 +757,7 @@ void BridgeImageFunc(x64emu_t *emu, XImage *img)
#define GO(A, W) \
fnc = CheckBridged(system, img->f.A); \
- if(!fnc) fnc = AddAutomaticBridge(emu, system, W, img->f.A, 0); \
+ if(!fnc) fnc = AddAutomaticBridge(emu, system, W, img->f.A, 0, #A); \
img->f.A = (W##_t)fnc;
uintptr_t fnc;
@@ -792,7 +792,7 @@ void UnbridgeImageFunc(x64emu_t *emu, XImage *img)
void sub_image_wrapper(x64emu_t *emu, uintptr_t fnc)
{
- pFpiiuu_t fn = (pFpiiuu_t)fnc;
+ pFpiiuu_t fn = (pFpiiuu_t)fnc;
void* img = fn(*(void**)(R_RDI), *(int32_t*)(R_RSI), *(int32_t*)(R_RDX), *(uint32_t*)(R_RCX), *(uint32_t*)(R_R8));
BridgeImageFunc(emu, (XImage*)img);
R_EAX=(uintptr_t)img;
@@ -903,7 +903,7 @@ EXPORT int my_XRegisterIMInstantiateCallback(x64emu_t* emu, void* d, void* db, v
{
return my->XRegisterIMInstantiateCallback(d, db, res_name, res_class, findregister_imFct(cb), data);
}
-
+
EXPORT int my_XUnregisterIMInstantiateCallback(x64emu_t* emu, void* d, void* db, void* res_name, void* res_class, void* cb, void* data)
{
return my->XUnregisterIMInstantiateCallback(d, db, res_name, res_class, reverse_register_imFct(my_lib, cb), data);
@@ -1108,12 +1108,12 @@ EXPORT void* my_XOpenDisplay(x64emu_t* emu, void* d)
#define GO(A, W)\
if(dpy->A) \
if(!CheckBridged(system, dpy->A)) \
- AddAutomaticBridge(emu, system, W, dpy->A, 0); \
+ AddAutomaticBridge(emu, system, W, dpy->A, 0, #A); \
#define GO2(A, B, W) \
if(dpy->A && dpy->A->B) \
if(!CheckBridged(system, dpy->A->B)) \
- AddAutomaticBridge(emu, system, W, dpy->A->B, 0); \
+ AddAutomaticBridge(emu, system, W, dpy->A->B, 0, #B "_" #A); \
GO2(free_funcs, atoms, vFp)
diff --git a/src/wrapped/wrappedlibx11_private.h b/src/wrapped/wrappedlibx11_private.h
index bd82eb6..9a98ef9 100755..100644
--- a/src/wrapped/wrappedlibx11_private.h
+++ b/src/wrapped/wrappedlibx11_private.h
@@ -17,7 +17,7 @@
// _init
// KeySymToUcs4
DATAB(_qfree, 4)
-// _Utf8GetConvByName
+//GO(_Utf8GetConvByName,
//GO(XActivateScreenSaver
GOM(XAddConnectionWatch, iFEppp)
GO(XAddExtension, pFp)
@@ -28,16 +28,16 @@ GO(XAddToExtensionList, vFpp)
//GO(XAddToSaveSet
GO(XAllocClassHint, pFv)
GO(XAllocColor, iFppp)
-GO(XAllocColorCells, iFppipipi)
-//GO(XAllocColorPlanes
-//GO(XAllocIconSize
+GO(XAllocColorCells, iFpLipupu)
+GO(XAllocColorPlanes, iFpLipiiiippp)
+GO(XAllocIconSize, pFv)
GO(_XAllocID, LFp)
GO(_XAllocIDs, vFppi)
GO(XAllocNamedColor, iFppppp)
-// _XAllocScratch
+//GO(_XAllocScratch,
GO(XAllocSizeHints, pFv)
-//GO(XAllocStandardColormap
-// _XAllocTemp
+GO(XAllocStandardColormap, pFv)
+//GO(_XAllocTemp,
GO(XAllocWMHints, pFv)
GO(XAllowEvents, iFpiL)
GO(XAllPlanes, LFv)
@@ -52,45 +52,45 @@ GO(XBitmapUnit, iFp)
GO(XBlackPixel, LFpi)
//GO(XBlackPixelOfScreen
//GO(XCellsOfScreen
-GO(XChangeActivePointerGrab, vFpupp)
+GO(XChangeActivePointerGrab, iFpuLL)
GO(XChangeGC, iFppLp)
GO(XChangeKeyboardControl, iFpLp)
GO(XChangeKeyboardMapping, iFpiipi)
GO(XChangePointerControl, iFpiiiii)
-GO(XChangeProperty, iFppppiipi)
+GO(XChangeProperty, iFpLLLiipi)
//GO(XChangeSaveSet
-GO(XChangeWindowAttributes, iFppLp)
+GO(XChangeWindowAttributes, iFpLLp)
GOM(XCheckIfEvent, iFEpppp)
GO(XCheckMaskEvent, iFplp)
GO(XCheckTypedEvent, iFpip)
-GO(XCheckTypedWindowEvent, iFppip)
+GO(XCheckTypedWindowEvent, iFpLip)
GO(XCheckWindowEvent, iFpplp)
-//GO(XCirculateSubwindows
+GO(XCirculateSubwindows, iFpLi)
//GO(XCirculateSubwindowsDown
//GO(XCirculateSubwindowsUp
-GO(XClearArea, iFppiiuui)
+GO(XClearArea, iFpLiiuui)
GO(XClearWindow, iFpp)
GO(XClipBox, iFpp)
GO(XCloseDisplay, iFp)
GO(XCloseIM, iFp)
-// _XCloseLC
+//GO(_XCloseLC,
GO(XCloseOM, iFp)
-// _XcmsAddCmapRec
+//GO(_XcmsAddCmapRec,
//GO(XcmsAddColorSpace
//GO(XcmsAddFunctionSet
//GO(XcmsAllocColor
//GO(XcmsAllocNamedColor
-// _XcmsArcTangent
+//GO(_XcmsArcTangent,
//GO(XcmsCCCOfColormap
//GO(XcmsCIELabClipab
//GO(XcmsCIELabClipL
//GO(XcmsCIELabClipLab
DATA(XcmsCIELabColorSpace, 6*sizeof(void*))
-// _XcmsCIELab_prefix // type r
+//GO(_XcmsCIELab_prefix // type r,
//GO(XcmsCIELabQueryMaxC
//GO(XcmsCIELabQueryMaxL
//GO(XcmsCIELabQueryMaxLC
-// _XcmsCIELabQueryMaxLCRGB
+//GO(_XcmsCIELabQueryMaxLCRGB,
//GO(XcmsCIELabQueryMinL
//GO(XcmsCIELabToCIEXYZ
//GO(XcmsCIELabWhiteShiftColors
@@ -98,167 +98,167 @@ DATA(XcmsCIELabColorSpace, 6*sizeof(void*))
//GO(XcmsCIELuvClipLuv
//GO(XcmsCIELuvClipuv
DATA(XcmsCIELuvColorSpace, 6*sizeof(void*))
-// _XcmsCIELuv_prefix // type r
+//GO(_XcmsCIELuv_prefix // type r,
//GO(XcmsCIELuvQueryMaxC
//GO(XcmsCIELuvQueryMaxL
//GO(XcmsCIELuvQueryMaxLC
-// _XcmsCIELuvQueryMaxLCRGB
+//GO(_XcmsCIELuvQueryMaxLCRGB,
//GO(XcmsCIELuvQueryMinL
//GO(XcmsCIELuvToCIEuvY
//GO(XcmsCIELuvWhiteShiftColors
DATA(XcmsCIEuvYColorSpace, 6*sizeof(void*))
-// _XcmsCIEuvY_prefix // type r
+//GO(_XcmsCIEuvY_prefix // type r,
//GO(XcmsCIEuvYToCIELuv
//GO(XcmsCIEuvYToCIEXYZ
//GO(XcmsCIEuvYToTekHVC
-// _XcmsCIEuvY_ValidSpec
+//GO(_XcmsCIEuvY_ValidSpec,
DATA(XcmsCIExyYColorSpace, 6*sizeof(void*)) // probably need some wrapping
-// _XcmsCIExyY_prefix // type r
+//GO(_XcmsCIExyY_prefix // type r,
//GO(XcmsCIExyYToCIEXYZ
DATA(XcmsCIEXYZColorSpace, 6*sizeof(void*))
-// _XcmsCIEXYZ_prefix // type r
+//GO(_XcmsCIEXYZ_prefix // type r,
//GO(XcmsCIEXYZToCIELab
//GO(XcmsCIEXYZToCIEuvY
//GO(XcmsCIEXYZToCIExyY
//GO(XcmsCIEXYZToRGBi
-// _XcmsCIEXYZ_ValidSpec
+//GO(_XcmsCIEXYZ_ValidSpec,
//GO(XcmsClientWhitePointOfCCC
//GO(XcmsConvertColors
-// _XcmsConvertColorsWithWhitePt
-// _XcmsCopyCmapRecAndFree
-// _XcmsCopyISOLatin1Lowered
-// _XcmsCopyPointerArray
-// _XcmsCosine
+//GO(_XcmsConvertColorsWithWhitePt,
+//GO(_XcmsCopyCmapRecAndFree,
+//GO(_XcmsCopyISOLatin1Lowered,
+//GO(_XcmsCopyPointerArray,
+//GO(_XcmsCosine,
//GO(XcmsCreateCCC
-// _XcmsCubeRoot
+//GO(_XcmsCubeRoot,
DATA(_XcmsDDColorSpaces, 6*sizeof(void*))
DATA(_XcmsDDColorSpacesInit, 6*sizeof(void*))
-// _XcmsDDConvertColors
+//GO(_XcmsDDConvertColors,
//GO(XcmsDefaultCCC
-// _XcmsDeleteCmapRec
+//GO(_XcmsDeleteCmapRec,
DATA(_XcmsDIColorSpaces, 6*sizeof(void*))
DATA(_XcmsDIColorSpacesInit, 6*sizeof(void*))
-// _XcmsDIConvertColors
+//GO(_XcmsDIConvertColors,
//GO(XcmsDisplayOfCCC
-// _XcmsEqualWhitePts
-//GO(XcmsFormatOfPrefix
+//GO(_XcmsEqualWhitePts,
+GO(XcmsFormatOfPrefix, LFp)
//GO(XcmsFreeCCC
-// _XcmsFreeIntensityMaps
-// _XcmsFreePointerArray
-// _XcmsGetElement
-// _XcmsGetIntensityMap
-// _XcmsGetProperty
-// _XcmsInitDefaultCCCs
-// _XcmsInitScrnInfo
+//GO(_XcmsFreeIntensityMaps,
+//GO(_XcmsFreePointerArray,
+//GO(_XcmsGetElement,
+//GO(_XcmsGetIntensityMap,
+//GO(_XcmsGetProperty,
+//GO(_XcmsInitDefaultCCCs,
+//GO(_XcmsInitScrnInfo,
DATA(XcmsLinearRGBFunctionSet, 3*sizeof(void*)) // probably needs some wrapping
-//GO(XcmsLookupColor
-// _XcmsLRGB_InitScrnDefault
-//GO(XcmsPrefixOfFormat
-// _XcmsPushPointerArray
+GO(XcmsLookupColor, iFpLpppL)
+//GO(_XcmsLRGB_InitScrnDefault,
+GO(XcmsPrefixOfFormat, pFL)
+//GO(_XcmsPushPointerArray,
//GO(XcmsQueryBlack
//GO(XcmsQueryBlue
-//GO(XcmsQueryColor
-//GO(XcmsQueryColors
+GO(XcmsQueryColor, iFpLpL)
+GO(XcmsQueryColors, iFpLpuL)
//GO(XcmsQueryGreen
//GO(XcmsQueryRed
//GO(XcmsQueryWhite
DATA(_XcmsRegColorSpaces, 6*sizeof(void*))
-// _XcmsRegFormatOfPrefix
-// _XcmsResolveColor
-// _XcmsResolveColorString
+//GO(_XcmsRegFormatOfPrefix,
+//GO(_XcmsResolveColor,
+//GO(_XcmsResolveColorString,
DATA(XcmsRGBColorSpace, 6*sizeof(void*))
DATA(XcmsRGBiColorSpace, 6*sizeof(void*))
-// _XcmsRGBi_prefix // type r
+//GO(_XcmsRGBi_prefix // type r,
//GO(XcmsRGBiToCIEXYZ
//GO(XcmsRGBiToRGB
-// _XcmsRGB_prefix // type r
+//GO(_XcmsRGB_prefix // type r,
//GO(XcmsRGBToRGBi
-// _XcmsRGB_to_XColor
+//GO(_XcmsRGB_to_XColor,
DATA(_XcmsSCCFuncSets, 3*sizeof(void*))
DATA(_XcmsSCCFuncSetsInit, 3*sizeof(void*))
//GO(XcmsScreenNumberOfCCC
//GO(XcmsScreenWhitePointOfCCC
//GO(XcmsSetCCCOfColormap
//GO(XcmsSetCompressionProc
-// _XcmsSetGetColor
-// _XcmsSetGetColors
+//GO(_XcmsSetGetColor,
+//GO(_XcmsSetGetColors,
//GO(XcmsSetWhiteAdjustProc
//GO(XcmsSetWhitePoint
-// _XcmsSine
-// _XcmsSquareRoot
-//GO(XcmsStoreColor
-//GO(XcmsStoreColors
-// _XcmsTekHVC_CheckModify
+//GO(_XcmsSine,
+//GO(_XcmsSquareRoot,
+GO(XcmsStoreColor, iFpLp)
+GO(XcmsStoreColors, iFpLpup)
+//GO(_XcmsTekHVC_CheckModify,
//GO(XcmsTekHVCClipC
//GO(XcmsTekHVCClipV
//GO(XcmsTekHVCClipVC
DATA(XcmsTekHVCColorSpace, 6*sizeof(void*))
-// _XcmsTekHVC_prefix // type r
+//GO(_XcmsTekHVC_prefix // type r,
//GO(XcmsTekHVCQueryMaxC
//GO(XcmsTekHVCQueryMaxV
//GO(XcmsTekHVCQueryMaxVC
-// _XcmsTekHVCQueryMaxVCRGB
+//GO(_XcmsTekHVCQueryMaxVCRGB,
//GO(XcmsTekHVCQueryMaxVSamples
//GO(XcmsTekHVCQueryMinV
//GO(XcmsTekHVCToCIEuvY
//GO(XcmsTekHVCWhiteShiftColors
DATA(XcmsUNDEFINEDColorSpace, 6*sizeof(void*))
-// _XcmsUnresolveColor
+//GO(_XcmsUnresolveColor,
//GO(XcmsVisualOfCCC
-// _XColor_to_XcmsRGB
-GO(XConfigureWindow, iFppup)
+//GO(_XColor_to_XcmsRGB,
+GO(XConfigureWindow, iFpLup)
GO(XConnectionNumber, iFp)
-// _XConnectXCB
+//GO(_XConnectXCB,
//GO(XContextDependentDrawing
-//GO(XContextualDrawing
+GO(XContextualDrawing, iFp)
GO(XConvertCase, vFLpp)
-GO(XConvertSelection, iFpppppL)
-GO(XCopyArea, iFppppiiuuii)
-GO(XCopyColormapAndFree, uFpp)
-// _XCopyEventCookie
-GO(XCopyGC, iFpppL)
-GO(XCopyPlane, iFppppiiuuiiL)
-// _XCopyToArg
-GO(XCreateBitmapFromData, pFpppuu)
+GO(XConvertSelection, iFpLLLLL)
+GO(XCopyArea, iFpLLpiiuuii)
+GO(XCopyColormapAndFree, LFpL)
+//GO(_XCopyEventCookie,
+GO(XCopyGC, iFppLp)
+GO(XCopyPlane, iFpLLpiiuuiiL)
+//GO(_XCopyToArg,
+GO(XCreateBitmapFromData, LFpLpuu)
GO(XCreateColormap, pFpppi)
-GO(XCreateFontCursor, pFpu)
+GO(XCreateFontCursor, LFpu)
GO(XCreateFontSet, pFppppp)
-GO(XCreateGC, pFppup)
-//GO(XCreateGlyphCursor
+GO(XCreateGC, pFpLLp)
+GO(XCreateGlyphCursor, LFpLLuupp)
GOM(XCreateIC, pFEpV) // use vararg
GOM(XCreateImage, pFEppuiipuuii)
GO(dummy_XCreateImage, pFppuiipuuii) // to have the wrapper
DATAB(_XCreateMutex_fn, sizeof(void*))
GO(XCreateOC, pFp)
-GO(XCreatePixmap, pFppuuu)
-GO(XCreatePixmapCursor, pFpppppuu)
-GO(XCreatePixmapFromBitmapData, pFpppuuLLu)
+GO(XCreatePixmap, LFpLuuu)
+GO(XCreatePixmapCursor, LFpLLppuu)
+GO(XCreatePixmapFromBitmapData, LFpLpuuLLu)
GO(XCreateRegion, pFv)
-GO(XCreateSimpleWindow, pFppiiuuuLL)
+GO(XCreateSimpleWindow, LFpLiiuuuLL)
GO(XCreateWindow, pFppiiuuuiupLp)
DATAB(_Xdebug, sizeof(void*))
-GO(XDefaultColormap, pFpi)
-GO(XDefaultColormapOfScreen, pFp)
+GO(XDefaultColormap, LFpi)
+GO(XDefaultColormapOfScreen, LFp)
GO(XDefaultDepth, iFpi)
GO(XDefaultDepthOfScreen, iFp)
-// _XDefaultError
+//GO(_XDefaultError,
GO(XDefaultGC, pFpi)
GO(XDefaultGCOfScreen, pFp)
GO(_XDefaultIOError, iFp)
-// _XDefaultOpenIM
-// _XDefaultOpenOM
-GO(XDefaultRootWindow, pFp)
+//GO(_XDefaultOpenIM,
+//GO(_XDefaultOpenOM,
+GO(XDefaultRootWindow, LFp)
GO(XDefaultScreen, iFp)
GO(XDefaultScreenOfDisplay, pFp)
GO(XDefaultString, pFv)
GO(XDefaultVisual, pFpi)
GO(XDefaultVisualOfScreen, pFp)
-// _XDefaultWireError
-GO(XDefineCursor, iFppp)
+//GO(_XDefaultWireError,
+GO(XDefineCursor, iFpLL)
GO(XDeleteContext, iFpLi)
//GO(XDeleteModifiermapEntry
-GO(XDeleteProperty, iFppp)
-// _XDeq
+GO(XDeleteProperty, iFpLL)
+//GO(_XDeq,
GOM(_XDeqAsyncHandler, vFEpp)
GO(XDestroyIC, vFp)
GOM(XDestroyImage, iFEp) //need to unbridge
@@ -276,7 +276,7 @@ GO(XDisplayKeycodes, iFppp)
GO(XDisplayName, pFp)
GO(XDisplayOfIM, pFp)
GO(XDisplayOfOM, pFp)
-//GO(XDisplayOfScreen
+GO(XDisplayOfScreen, pFp)
//GO(XDisplayPlanes
GO(XDisplayString, pFp)
GO(XDisplayWidth, iFpi)
@@ -287,17 +287,17 @@ GO(XDrawArc, iFpppiiuuii)
//GO(XDrawArcs
//GO(XDrawImageString
//GO(XDrawImageString16
-GO(XDrawLine, iFpppiiii)
+GO(XDrawLine, iFpLpiiii)
GO(XDrawLines, iFppppii)
-GO(XDrawPoint, iFpppii)
-GO(XDrawPoints, iFppppii)
+GO(XDrawPoint, iFpLpii)
+GO(XDrawPoints, iFpLppii)
GO(XDrawRectangle, iFpppiiuu)
GO(XDrawRectangles, iFppppi)
-GO(XDrawSegments, iFppppi)
-GO(XDrawString, iFpppiipi)
-GO(XDrawString16, iFpppiipi)
-//GO(XDrawText
-//GO(XDrawText16
+GO(XDrawSegments, iFpLppi)
+GO(XDrawString, iFpLpiipi)
+GO(XDrawString16, iFpLpiipi)
+GO(XDrawText, iFpLpiipi)
+GO(XDrawText16, iFpLpiipi)
GO(_XEatData, vFpL)
GO(_XEatDataWords, vFpL)
//GO(XEHeadOfExtensionList
@@ -305,7 +305,7 @@ GO(XEmptyRegion, iFp)
GO(XEnableAccessControl, vFp)
GO(_XEnq, vFpp)
GO(XEqualRegion, iFpp)
-// _XError
+//GO(_XError,
DATAB(_XErrorFunction, sizeof(void*))
//GO(XESetBeforeFlush
GOM(XESetCloseDisplay, pFEpip)
@@ -323,25 +323,25 @@ GOM(XESetEventToWire, pFEpip)
//GO(XESetWireToError
GOM(XESetWireToEvent, pFEpip)
//GO(XESetWireToEventCookie
-//GO(XEventMaskOfScreen
+GO(XEventMaskOfScreen, lFp)
GO(XEventsQueued, iFpi)
-// _XEventsQueued
-// _Xevent_to_mask // type r
-// _XEventToWire
+//GO(_XEventsQueued,
+//GO(_Xevent_to_mask // type r,
+//GO(_XEventToWire,
GO(XExtendedMaxRequestSize, lFp)
GO(XExtentsOfFontSet, pFp)
-// _XF86BigfontFreeFontMetrics
-// _XF86LoadQueryLocaleFont
-//GO(XFetchBuffer
-//GO(XFetchBytes
-// _XFetchEventCookie
+//GO(_XF86BigfontFreeFontMetrics,
+//GO(_XF86LoadQueryLocaleFont,
+GO(XFetchBuffer, pFppi)
+GO(XFetchBytes, pFpp)
+//GO(_XFetchEventCookie,
GO(XFetchName, iFppp)
-GO(XFillArc, iFpppiiuuii)
-//GO(XFillArcs
-GO(XFillPolygon, iFppppiii)
-GO(XFillRectangle, iFpppiiuu)
-GO(XFillRectangles, iFppppi)
-GO(XFilterEvent, iFpp)
+GO(XFillArc, iFpLpiiuuii)
+GO(XFillArcs, iFpLppi)
+GO(XFillPolygon, iFpLppiii)
+GO(XFillRectangle, iFpLpiiuu)
+GO(XFillRectangles, iFpLppi)
+GO(XFilterEvent, iFpL)
GO(XFindContext, iFpLip)
//GO(XFindOnExtensionList
GO(XFlush, iFp)
@@ -351,15 +351,15 @@ GO(_XFlushGCCache, vFpp)
GO(XFontsOfFontSet, iFppp)
GO(XForceScreenSaver, iFpi)
GO(XFree, iFp)
-// _XFreeAtomTable
+//GO(_XFreeAtomTable,
GO(XFreeColormap, iFpp)
-GO(XFreeColors, iFpppiL)
-GO(XFreeCursor, iFpp)
+GO(XFreeColors, iFpLpiL)
+GO(XFreeCursor, iFpL)
DATAB(_XFreeDisplayLock_fn, sizeof(void*))
-// _XFreeDisplayStructure
-// _XFreeEventCookies
+//GO(_XFreeDisplayStructure,
+//GO(_XFreeEventCookies,
GO(XFreeEventData, vFpp)
-// _XFreeExtData
+//GO(_XFreeExtData,
GO(XFreeExtensionList, iFp)
GO(XFreeFont, iFpp)
GO(XFreeFontInfo, iFppi)
@@ -369,39 +369,39 @@ GO(XFreeFontSet, vFpp)
GO(XFreeGC, iFpp)
GO(XFreeModifiermap, iFp)
DATAB(_XFreeMutex_fn, sizeof(void*))
-GO(XFreePixmap, iFpp)
+GO(XFreePixmap, iFpL)
GO(XFreeStringList, vFp)
-// _XFreeTemp
-// _XFreeX11XCBStructure
-GO(XGContextFromGC, pFp)
+//GO(_XFreeTemp,
+//GO(_XFreeX11XCBStructure,
+GO(XGContextFromGC, LFp)
GO(XGeometry, iFpippuuuiipppp)
GO(_XGetAsyncData, vFpppiiii)
-// _XGetAsyncReply
-GO(XGetAtomName, pFpp)
+GO(_XGetAsyncReply, pFppppiii)
+GO(XGetAtomName, pFpL)
GO(XGetAtomNames, iFppip)
-// _XGetBitsPerPixel
+//GO(_XGetBitsPerPixel,
GO(XGetClassHint, iFppp)
-GO(XGetCommand, iFpppp)
+GO(XGetCommand, iFpLpp)
GO(XGetDefault, pFppp)
GO(XGetErrorDatabaseText, iFpppppi)
GO(XGetErrorText, iFpipi)
GO(XGetEventData, iFpp)
GO(XGetFontPath, pFpp)
-GO(XGetFontProperty, iFppp)
+GO(XGetFontProperty, iFpLp)
GO(XGetGCValues, iFppLp)
-GO(XGetGeometry, iFppppppppp)
-// _XGetHostname
-GO(XGetIconName, iFppp)
-//GO(XGetIconSizes
+GO(XGetGeometry, iFpLppppppp)
+GO(_XGetHostname, iFpi)
+GO(XGetIconName, iFpLp)
+GO(XGetIconSizes, iFpLpp)
GO(XGetICValues, pFpppppppppp) // use varargs...
GOM(XGetImage, pFEppiiuuLi) // return an XImage with callbacks that needs wrapping
GO(XGetIMValues, pFppppppp) // use varargs
GO(XGetInputFocus, iFppp)
GO(XGetKeyboardControl, iFpp)
-GO(XGetKeyboardMapping, pFppip)
-// _XGetLCValues
+GO(XGetKeyboardMapping, pFpCip)
+//GO(_XGetLCValues,
GO(XGetModifierMapping, pFp)
-GO(XGetMotionEvents, pFppLLp)
+GO(XGetMotionEvents, pFpLLLp)
GO(XGetNormalHints, iFppp)
GO(XGetOCValues, pFpppppppppp) // use varargs
GO(XGetOMValues, pFp)
@@ -410,33 +410,33 @@ GO(dummy_XGetPixel, LFpii) // for the wrapper
GO(XGetPointerControl, iFpppp)
GO(XGetPointerMapping, iFppi)
GO(_XGetRequest, pFpuL)
-GO(XGetRGBColormaps, iFppppp)
-// _XGetScanlinePad
+GO(XGetRGBColormaps, iFpLppL)
+//GO(_XGetScanlinePad,
GO(XGetScreenSaver, iFppppp)
-GO(XGetSelectionOwner, pFpp)
+GO(XGetSelectionOwner, LFpL)
//GO(XGetSizeHints
-//GO(XGetStandardColormap
+GO(XGetStandardColormap, iFpLpL)
GOM(XGetSubImage, pFEppiiuuuipii)
-GO(XGetTextProperty, iFpppp)
-GO(XGetTransientForHint, iFppp)
+GO(XGetTextProperty, iFpLpL)
+GO(XGetTransientForHint, iFpLp)
GO(XGetVisualInfo, pFplpp)
GO(XGetWindowAttributes, iFppp)
-// _XGetWindowAttributes
-GO(XGetWindowProperty, iFpppllipppppp)
+//GO(_XGetWindowAttributes,
+GO(XGetWindowProperty, iFpLLlliLppppp)
//GO(XGetWMClientMachine
-GO(XGetWMColormapWindows, iFpppp)
-GO(XGetWMHints, pFpp)
+GO(XGetWMColormapWindows, iFpLpp)
+GO(XGetWMHints, pFpL)
GO(XGetWMIconName, iFppp)
-GO(XGetWMName, iFppp)
-GO(XGetWMNormalHints, iFpppp)
-//GO(XGetWMProtocols
-GO(XGetWMSizeHints, iFppppp)
+GO(XGetWMName, iFpLp)
+GO(XGetWMNormalHints, iFpLpp)
+GO(XGetWMProtocols, iFpLpp)
+GO(XGetWMSizeHints, iFpLppL)
//GO(XGetZoomHints
DATAB(_Xglobal_lock, sizeof(void*))
-GO(XGrabButton, iFpuupiuiipp)
-GO(XGrabKey, iFpiupiii)
-GO(XGrabKeyboard, iFppuiiL)
-GO(XGrabPointer, iFppiuiippL)
+GO(XGrabButton, iFpuuLiuiiLL)
+GO(XGrabKey, iFpiuLiii)
+GO(XGrabKeyboard, iFpLiiiL)
+GO(XGrabPointer, iFpLiuiiLLL)
GO(XGrabServer, iFp)
DATAB(_XHeadOfDisplayList, sizeof(void*))
GO(XHeightMMOfScreen, iFp)
@@ -445,56 +445,56 @@ DATAB(_Xi18n_lock, sizeof(void*))
GO(XIconifyWindow, iFppi)
GOM(XIfEvent, iFEpppp)
GO(XImageByteOrder, iFp)
-// _XIMCompileResourceList
-// _XimGetCharCode
-// _XimGetLocaleCode
-// _XimLookupMBText
-// _XimLookupUTF8Text
-// _XimLookupWCText
+//GO(_XIMCompileResourceList,
+//GO(_XimGetCharCode,
+//GO(_XimGetLocaleCode,
+//GO(_XimLookupMBText,
+//GO(_XimLookupUTF8Text,
+//GO(_XimLookupWCText,
GO(XIMOfIC, pFp)
-// _XimXTransBytesReadable
-// _XimXTransClose
-// _XimXTransCloseForCloning
-// _XimXTransConnect
-// _XimXTransDisconnect
-// _XimXTransFreeConnInfo
-// _XimXTransGetConnectionNumber
-// _XimXTransGetHostname
-// _XimXTransGetMyAddr
-// _XimXTransGetPeerAddr
-// _XimXTransIsLocal
-// _XimXTransOpenCLTSClient
-// _XimXTransOpenCOTSClient
-// _XimXTransRead
-// _XimXTransReadv
-// _XimXTransSetOption
+//GO(_XimXTransBytesReadable,
+//GO(_XimXTransClose,
+//GO(_XimXTransCloseForCloning,
+//GO(_XimXTransConnect,
+//GO(_XimXTransDisconnect,
+//GO(_XimXTransFreeConnInfo,
+//GO(_XimXTransGetConnectionNumber,
+//GO(_XimXTransGetHostname,
+//GO(_XimXTransGetMyAddr,
+//GO(_XimXTransGetPeerAddr,
+//GO(_XimXTransIsLocal,
+//GO(_XimXTransOpenCLTSClient,
+//GO(_XimXTransOpenCOTSClient,
+//GO(_XimXTransRead,
+//GO(_XimXTransReadv,
+//GO(_XimXTransSetOption,
DATA(_XimXTransSocketINET6Funcs, sizeof(void*))
DATA(_XimXTransSocketINETFuncs, sizeof(void*))
DATA(_XimXTransSocketLocalFuncs, sizeof(void*))
DATA(_XimXTransSocketTCPFuncs, sizeof(void*))
DATA(_XimXTransSocketUNIXFuncs, sizeof(void*))
-// _XimXTransWrite
-// _XimXTransWritev
-// _XInitDefaultIM
-// _XInitDefaultOM
+//GO(_XimXTransWrite,
+//GO(_XimXTransWritev,
+//GO(_XInitDefaultIM,
+//GO(_XInitDefaultOM,
DATAB(_XInitDisplayLock_fn, sizeof(void*))
-// _XInitDynamicIM
-// _XInitDynamicOM
+//GO(_XInitDynamicIM,
+//GO(_XInitDynamicOM,
GO(XInitExtension, pFpp)
GOM(XInitImage, iFEp)
-// _XInitImageFuncPtrs
-// _XInitKeysymDB
+//GO(_XInitImageFuncPtrs,
+//GO(_XInitKeysymDB,
GO(XInitThreads, iFv)
-//GO(XInsertModifiermapEntry
+GO(XInsertModifiermapEntry, pFpCi)
GO(XInstallColormap, iFpp)
GO(XInternalConnectionNumbers, iFppp)
-GO(XInternAtom, pFppi)
+GO(XInternAtom, LFppi)
GO(XInternAtoms, iFppiip)
GO(XIntersectRegion, iFppp)
GO(_XIOError, iFp)
DATAB(_XIOErrorFunction, sizeof(void*))
-// _XIsEventCookie
-//GO(XkbAddDeviceLedInfo
+//GO(_XIsEventCookie,
+GO(XkbAddDeviceLedInfo, pFpuu)
//GO(XkbAddGeomColor
//GO(XkbAddGeomDoodad
//GO(XkbAddGeomKey
@@ -507,11 +507,11 @@ DATAB(_XIOErrorFunction, sizeof(void*))
//GO(XkbAddGeomRow
//GO(XkbAddGeomSection
//GO(XkbAddGeomShape
-//GO(XkbAddKeyType
+GO(XkbAddKeyType, pFpLiii)
//GO(XkbAllocClientMap
-//GO(XkbAllocCompatMap
-//GO(XkbAllocControls
-//GO(XkbAllocDeviceInfo
+GO(XkbAllocCompatMap, iFpuu)
+GO(XkbAllocControls, iFpu)
+GO(XkbAllocDeviceInfo, pFuuu)
//GO(XkbAllocGeomColors
//GO(XkbAllocGeomDoodads
//GO(XkbAllocGeometry
@@ -527,38 +527,38 @@ DATAB(_XIOErrorFunction, sizeof(void*))
//GO(XkbAllocGeomSectionDoodads
//GO(XkbAllocGeomSections
//GO(XkbAllocGeomShapes
-//GO(XkbAllocIndicatorMaps
+GO(XkbAllocIndicatorMaps, iFp)
GO(XkbAllocKeyboard, pFv)
-//GO(XkbAllocNames
+GO(XkbAllocNames, iFpuii)
//GO(XkbAllocServerMap
-//GO(XkbApplyCompatMapToKey
-//GO(XkbApplyVirtualModChanges
-//GO(XkbBell
-//GO(XkbBellEvent
-//GO(XkbChangeDeviceInfo
+GO(XkbApplyCompatMapToKey, iFpCp)
+GO(XkbApplyVirtualModChanges, iFpup)
+GO(XkbBell, iFppip)
+GO(XkbBellEvent, iFpLiL)
+GO(XkbChangeDeviceInfo, iFppp)
//GO(XkbChangeEnabledControls
-//GO(XkbChangeKeycodeRange
-//GO(XkbChangeMap
-//GO(XkbChangeNames
-//GO(XkbChangeTypesOfKey
-//GO(XkbComputeEffectiveMap
+GO(XkbChangeKeycodeRange, iFpiip)
+GO(XkbChangeMap, iFppp)
+GO(XkbChangeNames, iFppp)
+GO(XkbChangeTypesOfKey, iFpiiupp)
+GO(XkbComputeEffectiveMap, iFppp)
//GO(XkbComputeRowBounds
//GO(XkbComputeSectionBounds
//GO(XkbComputeShapeBounds
//GO(XkbComputeShapeTop
-// _XkbCopyFromReadBuffer
-//GO(XkbCopyKeyType
-//GO(XkbCopyKeyTypes
+//GO(_XkbCopyFromReadBuffer,
+GO(XkbCopyKeyType, iFpp)
+GO(XkbCopyKeyTypes, iFppi)
//GO(XkbDeviceBell
-//GO(XkbDeviceBellEvent
+GO(XkbDeviceBellEvent, iFpLiiiiL)
//GO(XkbFindOverlayForKey
-//GO(XkbForceBell
-//GO(XkbForceDeviceBell
+GO(XkbForceBell, iFpi)
+GO(XkbForceDeviceBell, iFpiiii)
GO(XkbFreeClientMap, vFpui)
//GO(XkbFreeCompatMap
-//GO(XkbFreeComponentList
+GO(XkbFreeComponentList, vFp)
//GO(XkbFreeControls
-//GO(XkbFreeDeviceInfo
+GO(XkbFreeDeviceInfo, vFpui)
//GO(XkbFreeGeomColors
//GO(XkbFreeGeomDoodads
//GO(XkbFreeGeometry
@@ -573,21 +573,21 @@ GO(XkbFreeClientMap, vFpui)
//GO(XkbFreeGeomRows
//GO(XkbFreeGeomSections
//GO(XkbFreeGeomShapes
-//GO(XkbFreeIndicatorMaps
+GO(XkbFreeIndicatorMaps, vFp)
GO(XkbFreeKeyboard, vFpui)
GO(XkbFreeNames, vFpui)
-// _XkbFreeReadBuffer
+//GO(_XkbFreeReadBuffer,
//GO(XkbFreeServerMap
DATA(_XkbGetAtomNameFunc, sizeof(void*))
//GO(XkbGetAutoRepeatRate
-//GO(XkbGetAutoResetControls
-// _XkbGetCharset
+GO(XkbGetAutoResetControls, iFppp)
+//GO(_XkbGetCharset,
//GO(XkbGetCompatMap
-//GO(XkbGetControls
-// _XkbGetConverters
-//GO(XkbGetDetectableAutoRepeat
-//GO(XkbGetDeviceButtonActions
-//GO(XkbGetDeviceInfo
+GO(XkbGetControls, iFpLp)
+//GO(_XkbGetConverters,
+GO(XkbGetDetectableAutoRepeat, iFpp)
+GO(XkbGetDeviceButtonActions, iFppiuu)
+GO(XkbGetDeviceInfo, pFpuuuu)
//GO(XkbGetDeviceInfoChanges
//GO(XkbGetDeviceLedInfo
//GO(XkbGetGeometry
@@ -596,180 +596,180 @@ DATA(_XkbGetAtomNameFunc, sizeof(void*))
//GO(XkbGetKeyActions
//GO(XkbGetKeyBehaviors
GO(XkbGetKeyboard, pFpuu)
-//GO(XkbGetKeyboardByName
+GO(XkbGetKeyboardByName, pFpupuui)
//GO(XkbGetKeyExplicitComponents
//GO(XkbGetKeyModifierMap
//GO(XkbGetKeySyms
//GO(XkbGetKeyTypes
-//GO(XkbGetKeyVirtualModMap
+GO(XkbGetKeyVirtualModMap, iFpuup)
GO(XkbGetMap, pFpuu)
//GO(XkbGetMapChanges
-//GO(XkbGetNamedDeviceIndicator
+GO(XkbGetNamedDeviceIndicator, iFpuuuLpppp)
//GO(XkbGetNamedGeometry
-GO(XkbGetNamedIndicator, iFpuppppp)
+GO(XkbGetNamedIndicator, iFpLpppp)
GO(XkbGetNames, iFpup)
-//GO(XkbGetPerClientControls
-// _XkbGetReadBufferCountedString
-// _XkbGetReadBufferPtr
+GO(XkbGetPerClientControls, iFpp)
+//GO(_XkbGetReadBufferCountedString,
+//GO(_XkbGetReadBufferPtr,
GO(XkbGetState, iFpup)
GO(XkbGetUpdatedMap, iFpup)
//GO(XkbGetVirtualMods
-//GO(XkbGetXlibControls
-GO(XkbIgnoreExtension, iFp)
-//GO(XkbInitCanonicalKeyTypes
-// _XkbInitReadBuffer
+GO(XkbGetXlibControls, uFp)
+GO(XkbIgnoreExtension, iFi)
+GO(XkbInitCanonicalKeyTypes, iFpui)
+//GO(_XkbInitReadBuffer,
DATA(_XkbInternAtomFunc, sizeof(void*))
-GO(XkbKeycodeToKeysym, LFpuuu)
-GO(XkbKeysymToModifiers, uFpp)
-//GO(XkbKeyTypesForCoreSymbols
-//GO(XkbLatchGroup
-//GO(XkbLatchModifiers
+GO(XkbKeycodeToKeysym, LFpCii)
+GO(XkbKeysymToModifiers, uFpL)
+GO(XkbKeyTypesForCoreSymbols, iFpipupp)
+GO(XkbLatchGroup, iFpuu)
+GO(XkbLatchModifiers, iFpuuu)
GO(XkbLibraryVersion, iFpp)
-//GO(XkbListComponents
+GO(XkbListComponents, pFpupp)
//GO(XkbLockGroup
//GO(XkbLockModifiers
-//GO(XkbLookupKeyBinding
-GO(XkbLookupKeySym, iFpuupp)
-//GO(XkbNoteControlsChanges
-// _XkbNoteCoreMapChanges
-//GO(XkbNoteDeviceChanges
-//GO(XkbNoteMapChanges
-//GO(XkbNoteNameChanges
-//GO(XkbOpenDisplay
-// _XkbPeekAtReadBuffer
+GO(XkbLookupKeyBinding, iFpLupip)
+GO(XkbLookupKeySym, iFpCupp)
+GO(XkbNoteControlsChanges, vFppu)
+//GO(_XkbNoteCoreMapChanges,
+GO(XkbNoteDeviceChanges, vFppu)
+GO(XkbNoteMapChanges, vFppu)
+GO(XkbNoteNameChanges, vFppu)
+GO(XkbOpenDisplay, pFpppppp)
+//GO(_XkbPeekAtReadBuffer,
GO(XkbQueryExtension, iFpppppp)
-// _XkbReadBufferCopyKeySyms
-// _XkbReadCopyKeySyms
-// _XkbReadGetCompatMapReply
-// _XkbReadGetGeometryReply
-// _XkbReadGetIndicatorMapReply
-// _XkbReadGetMapReply
-// _XkbReadGetNamesReply
-//GO(XkbRefreshKeyboardMapping
-// _XkbReloadDpy
-//GO(XkbResizeDeviceButtonActions
-//GO(XkbResizeKeyActions
-//GO(XkbResizeKeySyms
-//GO(XkbResizeKeyType
+//GO(_XkbReadBufferCopyKeySyms,
+//GO(_XkbReadCopyKeySyms,
+//GO(_XkbReadGetCompatMapReply,
+//GO(_XkbReadGetGeometryReply,
+//GO(_XkbReadGetIndicatorMapReply,
+//GO(_XkbReadGetMapReply,
+//GO(_XkbReadGetNamesReply,
+GO(XkbRefreshKeyboardMapping, iFp)
+//GO(_XkbReloadDpy,
+GO(XkbResizeDeviceButtonActions, iFpu)
+GO(XkbResizeKeyActions, pFpii)
+GO(XkbResizeKeySyms, pFpii)
+GO(XkbResizeKeyType, iFpiiii)
GO(XkbSelectEventDetails, iFpuuLL)
GO(XkbSelectEvents, iFpuLL)
//GO(XkbSetAtomFuncs
//GO(XkbSetAutoRepeatRate
-//GO(XkbSetAutoResetControls
-//GO(XkbSetCompatMap
+GO(XkbSetAutoResetControls, iFpupp)
+GO(XkbSetCompatMap, iFpupi)
//GO(XkbSetControlslib
-//GO(XkbSetDebuggingFlags
+GO(XkbSetDebuggingFlags, iFpuupuupp)
GO(XkbSetDetectableAutoRepeat, iFpip)
-//GO(XkbSetDeviceButtonActions
-//GO(XkbSetDeviceInfo
-//GO(XkbSetDeviceLedInfo
+GO(XkbSetDeviceButtonActions, iFppuu)
+GO(XkbSetDeviceInfo, iFpup)
+GO(XkbSetDeviceLedInfo, iFppuuu)
//GO(XkbSetGeometry
-//GO(XkbSetIgnoreLockMods
+GO(XkbSetIgnoreLockMods, iFpuuuuu)
//GO(XkbSetIndicatorMap
-//GO(XkbSetMap
-//GO(XkbSetNamedDeviceIndicator
-//GO(XkbSetNamedIndicator
-//GO(XkbSetNames
+GO(XkbSetMap, iFpup)
+GO(XkbSetNamedDeviceIndicator, iFpuuuLiiip)
+GO(XkbSetNamedIndicator, iFpLiiip)
+GO(XkbSetNames, iFpuuup)
GO(XkbSetPerClientControls, iFpup)
//GO(XkbSetServerInternalMods
-//GO(XkbSetXlibControls
-// _XkbSkipReadBufferData
-//GO(XkbToControl
+GO(XkbSetXlibControls, uFpuu)
+//GO(_XkbSkipReadBufferData,
+GO(XkbToControl, CFC)
//GO(XkbTranslateKey
-GO(XkbTranslateKeyCode, iFpuupp)
+GO(XkbTranslateKeyCode, iFpCupp)
GO(XkbTranslateKeySym, iFppupip)
-//GO(XkbUpdateActionVirtualMods
-//GO(XkbUpdateKeyTypeVirtualMods
-//GO(XkbUpdateMapFromCore
+GO(XkbUpdateActionVirtualMods, iFppu)
+GO(XkbUpdateKeyTypeVirtualMods, vFppup)
+GO(XkbUpdateMapFromCore, iFpCiipp)
GO(XkbUseExtension, iFppp)
-//GO(XkbVirtualModsToReal
-// _XkbWriteCopyKeySyms
-//GO(XkbXlibControlsImplemented
-GO(XKeycodeToKeysym, pFppi)
-// _XKeycodeToKeysym
-// _XKeyInitialize
-GO(XKeysymToKeycode, uFpp)
-// _XKeysymToKeycode
-// _XKeysymToModifiers
-GO(XKeysymToString, pFp)
-// _XkeyTable // type r
+GO(XkbVirtualModsToReal, iFpup)
+//GO(_XkbWriteCopyKeySyms,
+GO(XkbXlibControlsImplemented, uFv)
+GO(XKeycodeToKeysym, LFpCi)
+//GO(_XKeycodeToKeysym,
+//GO(_XKeyInitialize,
+GO(XKeysymToKeycode, CFpL)
+//GO(_XKeysymToKeycode,
+//GO(_XKeysymToModifiers,
+GO(XKeysymToString, pFL)
+//GO(_XkeyTable // type r,
GO(XKillClient, iFpL)
GO(XLastKnownRequestProcessed, LFp)
-// _XlcAddCharSet
-// _XlcAddCT
-// _XlcAddGB18030LocaleConverters
-// _XlcAddLoader
-// _XlcAddUtf8Converters
-// _XlcAddUtf8LocaleConverters
-// _XlcCloseConverter
-// _XlcCompareISOLatin1
-// _XlcCompileResourceList
-// _XlcConvert
-// _XlcCopyFromArg
-// _XlcCopyToArg
-// _XlcCountVaList
-// _XlcCreateDefaultCharSet
-// _XlcCreateLC
-// _XlcCreateLocaleDataBase
-// _XlcCurrentLC
-// _XlcDbg_printValue
-// _XlcDefaultMapModifiers
-// _XlcDeInitLoader
-// _XlcDestroyLC
-// _XlcDestroyLocaleDataBase
-// _XlcDynamicLoad
-// _XlcFileName
+//GO(_XlcAddCharSet,
+//GO(_XlcAddCT,
+//GO(_XlcAddGB18030LocaleConverters,
+//GO(_XlcAddLoader,
+//GO(_XlcAddUtf8Converters,
+//GO(_XlcAddUtf8LocaleConverters,
+//GO(_XlcCloseConverter,
+//GO(_XlcCompareISOLatin1,
+//GO(_XlcCompileResourceList,
+//GO(_XlcConvert,
+//GO(_XlcCopyFromArg,
+//GO(_XlcCopyToArg,
+//GO(_XlcCountVaList,
+//GO(_XlcCreateDefaultCharSet,
+//GO(_XlcCreateLC,
+//GO(_XlcCreateLocaleDataBase,
+//GO(_XlcCurrentLC,
+//GO(_XlcDbg_printValue,
+//GO(_XlcDefaultMapModifiers,
+//GO(_XlcDeInitLoader,
+//GO(_XlcDestroyLC,
+//GO(_XlcDestroyLocaleDataBase,
+//GO(_XlcDynamicLoad,
+//GO(_XlcFileName,
DATA(_XlcGenericMethods, sizeof(void*))
-// _XlcGetCharSet
-// _XlcGetCharSetWithSide
-// _XlcGetCSValues
-// _XlcGetLocaleDataBase
-// _XlcGetResource
-// _XlcGetValues
-// _XlcInitCTInfo
-// _XlcInitLoader
-// _XlcLocaleDirName
-// _XlcLocaleLibDirName
-// _XlcMapOSLocaleName
-// _Xlcmbstoutf8
-// _Xlcmbstowcs
-// _Xlcmbtowc
-// _XlcNCompareISOLatin1
-// _XlcOpenConverter
-// _XlcParseCharSet
-// _XlcParse_scopemaps
+//GO(_XlcGetCharSet,
+//GO(_XlcGetCharSetWithSide,
+//GO(_XlcGetCSValues,
+//GO(_XlcGetLocaleDataBase,
+//GO(_XlcGetResource,
+//GO(_XlcGetValues,
+//GO(_XlcInitCTInfo,
+//GO(_XlcInitLoader,
+//GO(_XlcLocaleDirName,
+//GO(_XlcLocaleLibDirName,
+//GO(_XlcMapOSLocaleName,
+//GO(_Xlcmbstoutf8,
+//GO(_Xlcmbstowcs,
+//GO(_Xlcmbtowc,
+//GO(_XlcNCompareISOLatin1,
+//GO(_XlcOpenConverter,
+//GO(_XlcParseCharSet,
+//GO(_XlcParse_scopemaps,
DATA(_XlcPublicMethods, sizeof(void*))
-// _XlcRemoveLoader
-// _XlcResetConverter
-// _XlcResolveI18NPath
-// _XlcResolveLocaleName
-// _XlcSetConverter
-// _XlcSetValues
-// _XlcValidModSyntax
-// _XlcVaToArgList
-// _Xlcwcstombs
-// _Xlcwctomb
+//GO(_XlcRemoveLoader,
+//GO(_XlcResetConverter,
+//GO(_XlcResolveI18NPath,
+//GO(_XlcResolveLocaleName,
+//GO(_XlcSetConverter,
+//GO(_XlcSetValues,
+//GO(_XlcValidModSyntax,
+//GO(_XlcVaToArgList,
+//GO(_Xlcwcstombs,
+//GO(_Xlcwctomb,
GO(XListDepths, pFpip)
GO(XListExtensions, pFpp)
GO(XListFonts, pFppip)
GO(XListFontsWithInfo, pFppipp)
GO(XListHosts, pFppp)
-//GO(XListInstalledColormaps
+GO(XListInstalledColormaps, pFpLp)
GO(XListPixmapFormats, pFpp)
-GO(XListProperties, pFppp)
-GO(XLoadFont, pFpp)
+GO(XListProperties, pFpLp)
+GO(XLoadFont, LFpp)
GO(XLoadQueryFont, pFpp)
// xlocaledir
-//GO(XLocaleOfFontSet
+GO(XLocaleOfFontSet, pFp)
GO(XLocaleOfIM, pFp)
GO(XLocaleOfOM, pFp)
GO(XLockDisplay, vFp)
DATAB(_XLockMutex_fn, sizeof(void*))
-GO(XLookupColor, iFppppp)
-GO(XLookupKeysym, pFpi)
-// _XLookupKeysym
+GO(XLookupColor, iFpLppp)
+GO(XLookupKeysym, LFpi)
+//GO(_XLookupKeysym,
GO(XLookupString, iFppipp)
-// _XLookupString
+//GO(_XLookupString,
GO(XLowerWindow, iFpp)
GO(XMapRaised, iFpp)
GO(XMapSubwindows, iFpp)
@@ -781,37 +781,37 @@ GO(XMaxRequestSize, iFp)
//GO(XmbDrawImageString
GO(XmbDrawString, vFppppiipi)
//GO(XmbDrawText
-// _Xmblen
+GO(_Xmblen, iFpi)
GO(XmbLookupString, iFpppipp)
GO(XmbResetIC, pFp)
GO(XmbSetWMProperties, vFpppppippp)
-// _Xmbstoutf8
-// _Xmbstowcs
+//GO(_Xmbstoutf8,
+//GO(_Xmbstowcs,
GO(XmbTextEscapement, iFppi)
GO(XmbTextExtents, iFppipp)
GO(XmbTextListToTextProperty, iFppiip)
-// _XmbTextListToTextProperty
+//GO(_XmbTextListToTextProperty,
//GO(XmbTextPerCharExtents
GO(XmbTextPropertyToTextList, iFpppp)
-// _XmbTextPropertyToTextList
-// _Xmbtowc
+//GO(_XmbTextPropertyToTextList,
+GO(_Xmbtowc, iFppi)
//GO(XMinCmapsOfScreen
-GO(XMoveResizeWindow, iFppiiuu)
-GO(XMoveWindow, iFppii)
-//GO(XNewModifiermap
+GO(XMoveResizeWindow, iFpLiiuu)
+GO(XMoveWindow, iFpLii)
+GO(XNewModifiermap, pFi)
GO(XNextEvent, iFpp)
GO(XNextRequest, LFp)
GO(XNoOp, iFp)
-// _XNoticeCreateBitmap
-// _XNoticePutBitmap
+//GO(_XNoticeCreateBitmap,
+//GO(_XNoticePutBitmap,
GO(XOffsetRegion, iFpii)
GO(XOMOfOC, pFp)
GOM(XOpenDisplay, pFEp)
GO(XOpenIM, pFpppp)
-// _XOpenLC
+//GO(_XOpenLC,
GO(XOpenOM, pFpppp)
-// _XParseBaseFontNameList
-GO(XParseColor, iFpppp)
+//GO(_XParseBaseFontNameList,
+GO(XParseColor, iFpLpp)
GO(XParseGeometry, iFppppp)
GO(XPeekEvent, iFpp)
GOM(XPeekIfEvent, iFEpppp)
@@ -819,63 +819,63 @@ GO(XPending, iFp)
//GO(Xpermalloc
GO(XPlanesOfScreen, iFp)
GO(XPointInRegion, iFpp)
-// _XPollfdCacheAdd
-// _XPollfdCacheDel
-// _XPollfdCacheInit
+//GO(_XPollfdCacheAdd,
+//GO(_XPollfdCacheDel,
+//GO(_XPollfdCacheInit,
GO(XPolygonRegion, pFpii)
GO(XProcessInternalConnection, vFpi)
-// _XProcessInternalConnection
-// _XProcessWindowAttributes
+//GO(_XProcessInternalConnection,
+//GO(_XProcessWindowAttributes,
GO(XProtocolRevision, iFp)
GO(XProtocolVersion, iFp)
GO(XPutBackEvent, iFpp)
-// _XPutBackEvent
+//GO(_XPutBackEvent,
GOM(XPutImage, iFEppppiiiiuu)
//GO(XPutPixel
GO(XQLength, iFp)
GO(XQueryBestCursor, iFppuupp)
-//GO(XQueryBestSize
+GO(XQueryBestSize, iFpiLuupp)
//GO(XQueryBestStipple
-//GO(XQueryBestTile
+GO(XQueryBestTile, iFpLuupp)
GO(XQueryColor, iFppp)
GO(XQueryColors, iFpppi)
GOM(XQueryExtension, iFEppppp)
GO(XQueryFont, pFpL)
GO(XQueryKeymap, iFpp)
-GO(XQueryPointer, iFppppppppp)
+GO(XQueryPointer, iFpLppppppp)
GO(XQueryTextExtents, iFpLpipppp)
GO(XQueryTextExtents16, iFpLpipppp)
-GO(XQueryTree, pFpppppp)
+GO(XQueryTree, iFpLpppp)
GO(XRaiseWindow, iFpp)
GO(_XRead, iFppi)
-//GO(XReadBitmapFile
-//GO(XReadBitmapFileData
-// _XReadEvents
+GO(XReadBitmapFile, iFpLpppppp)
+GO(XReadBitmapFileData, iFpppppp)
+GO(_XReadEvents, vFp)
GO(_XReadPad, vFppi)
-GO(XRebindKeysym, iFpppipi)
-GO(XRecolorCursor, iFpppp)
-GO(XReconfigureWMWindow, iFppiup)
+GO(XRebindKeysym, iFpLpipi)
+GO(XRecolorCursor, iFpLpp)
+GO(XReconfigureWMWindow, iFpLiup)
GO(XRectInRegion, iFpiiuu)
GO(XRefreshKeyboardMapping, iFp)
-// _XRefreshKeyboardMapping
-// _XRegisterFilterByMask
-// _XRegisterFilterByType
+//GO(_XRefreshKeyboardMapping,
+//GO(_XRegisterFilterByMask,
+//GO(_XRegisterFilterByType,
GOM(XRegisterIMInstantiateCallback, iFEpppppp)
-// _XRegisterInternalConnection
+//GO(_XRegisterInternalConnection,
GOM(XRemoveConnectionWatch, iFEppp)
//GO(XRemoveFromSaveSet
-GO(XRemoveHost, vFpp)
-GO(XRemoveHosts, vFppi)
-GO(XReparentWindow, iFpppii)
+GO(XRemoveHost, iFpp)
+GO(XRemoveHosts, iFppi)
+GO(XReparentWindow, iFpLLii)
GO(_XReply, iFppii)
GO(XResetScreenSaver, iFp)
-GO(XResizeWindow, iFppuu)
+GO(XResizeWindow, iFpLuu)
GO(XResourceManagerString, pFp)
GO(XRestackWindows, iFppi)
-// _XReverse_Bytes
+//GO(_XReverse_Bytes,
GO(XrmCombineDatabase, vFppi)
GO(XrmCombineFileDatabase, iFppi)
-// _XrmDefaultInitParseInfo
+//GO(_XrmDefaultInitParseInfo,
GO(XrmDestroyDatabase, vFp)
//GOM(XrmEnumerateDatabase
GO(XrmGetDatabase, pFp)
@@ -883,8 +883,8 @@ GO(XrmGetFileDatabase, pFp)
GO(XrmGetResource, iFppppp)
GO(XrmGetStringDatabase, pFp)
GO(XrmInitialize, vFv)
-// _XrmInitParseInfo
-// _XrmInternalStringToQuark
+//GO(_XrmInitParseInfo,
+//GO(_XrmInternalStringToQuark,
//GO(XrmLocaleOfDatabase
//GO(XrmMergeDatabases
//GO(XrmParseCommand
@@ -904,189 +904,189 @@ GO(XrmInitialize, vFv)
//GO(XrmStringToQuark
//GO(XrmStringToQuarkList
GO(XrmUniqueQuark, iFv) //typedef int XrmQuark, *XrmQuarkList;
-GO(XRootWindow, pFpi)
-GO(XRootWindowOfScreen, pFp)
+GO(XRootWindow, LFpi)
+GO(XRootWindowOfScreen, LFp)
GO(XRotateBuffers, iFpi)
-GO(XRotateWindowProperties, iFpppii)
+GO(XRotateWindowProperties, iFpLpii)
GO(XSaveContext, iFpLip)
GO(XScreenCount, iFp)
GO(XScreenNumberOfScreen, iFp)
GO(XScreenOfDisplay, pFpi)
-// _XScreenOfWindow
-//GO(XScreenResourceString
-GO(XSelectInput, iFppi)
+//GO(_XScreenOfWindow,
+GO(XScreenResourceString, pFp)
+GO(XSelectInput, iFpLl)
GO(_XSend, vFppi)
-GO(XSendEvent, uFppiip)
+GO(XSendEvent, iFpLilp)
GO(XServerVendor, pFp)
GO(XSetAccessControl, vFpi)
GOM(XSetAfterFunction, pFEpp)
GO(XSetArcMode, iFppi)
-//GO(XSetAuthorization
+GO(XSetAuthorization, vFpipi)
GO(XSetBackground, iFppL)
-GO(XSetClassHint, iFppp)
+GO(XSetClassHint, iFpLp)
GO(XSetClipMask, iFppp)
GO(XSetClipOrigin, iFppii)
GO(XSetClipRectangles, iFppiipii)
-// _XSetClipRectangles
+//GO(_XSetClipRectangles,
GO(XSetCloseDownMode, iFpi)
-GO(XSetCommand, iFpppi)
+GO(XSetCommand, iFpLpi)
GO(XSetDashes, iFppipi)
GOM(XSetErrorHandler, pFEp)
GO(XSetFillRule, iFppi)
GO(XSetFillStyle, iFppp)
-GO(XSetFont, iFppp)
+GO(XSetFont, iFppL)
GO(XSetFontPath, iFppi)
GO(XSetForeground, iFppL)
GO(XSetFunction, iFppi)
GO(XSetGraphicsExposures, iFppi)
GO(XSetICFocus, vFp)
GO(XSetIconName, iFppp)
-//GO(XSetIconSizes
+GO(XSetIconSizes, iFpLpi)
GOM(XSetICValues, pFEpV) // use vaarg
-// _XSetImage
+//GO(_XSetImage,
GOM(XSetIMValues, pFEpV) // use vaarg
-GO(XSetInputFocus, iFppiL)
+GO(XSetInputFocus, iFpLiL)
GOM(XSetIOErrorHandler, pFEp)
GO(_XSetLastRequestRead, uFpp)
GO(XSetLineAttributes, iFppuiii)
GO(XSetLocaleModifiers, pFp)
-//GO(XSetModifierMapping
+GO(XSetModifierMapping, iFpp)
GO(XSetNormalHints, iFpppp)
GO(XSetOCValues, pFpppppppppppppppp) // use vaarg
GO(XSetOMValues, pFp)
-//GO(XSetPlaneMask
-//GO(XSetPointerMapping
+GO(XSetPlaneMask, iFppL)
+GO(XSetPointerMapping, iFppi)
GO(XSetRegion, iFppp)
-//GO(XSetRGBColormaps
+GO(XSetRGBColormaps, vFpLpiL)
GO(XSetScreenSaver, iFpiiii)
-GO(XSetSelectionOwner, iFpppL)
-//GO(XSetSizeHints
-//GO(XSetStandardColormap
-GO(XSetStandardProperties, iFpppppppp)
-//GO(XSetState
+GO(XSetSelectionOwner, iFpLLL)
+GO(XSetSizeHints, iFpLpL)
+GO(XSetStandardColormap, vFpLpL)
+GO(XSetStandardProperties, iFpLppLpip)
+GO(XSetState, iFppLLiL)
GO(XSetStipple, iFppp)
GO(XSetSubwindowMode, iFppi)
-GO(XSetTextProperty, vFpppp)
-GO(XSetTile, iFppp)
-GO(XSetTransientForHint, iFppp)
+GO(XSetTextProperty, vFpLpL)
+GO(XSetTile, iFppL)
+GO(XSetTransientForHint, iFpLL)
GO(XSetTSOrigin, iFppii)
GO(XSetWindowBackground, iFppu)
GO(XSetWindowBackgroundPixmap, iFppp)
-//GO(XSetWindowBorder
-//GO(XSetWindowBorderPixmap
-GO(XSetWindowBorderWidth, iFppu)
-GO(XSetWindowColormap, iFppp)
+GO(XSetWindowBorder, iFpLL)
+GO(XSetWindowBorderPixmap, iFpLL)
+GO(XSetWindowBorderWidth, iFpLu)
+GO(XSetWindowColormap, iFpLL)
GO(XSetWMClientMachine, vFppp)
-GO(XSetWMColormapWindows, iFpppi)
-GO(XSetWMHints, iFppp)
+GO(XSetWMColormapWindows, iFpLpi)
+GO(XSetWMHints, iFpLp)
GO(XSetWMIconName, vFppp)
-GO(XSetWMName, vFppp)
-GO(XSetWMNormalHints, iFppp)
-GO(XSetWMProperties, vFpppppippp)
-GO(XSetWMProtocols, iFpppi)
-GO(XSetWMSizeHints, vFpppu)
-//GO(XSetZoomHints
+GO(XSetWMName, vFpLp)
+GO(XSetWMNormalHints, vFpLp)
+GO(XSetWMProperties, vFpLpppippp)
+GO(XSetWMProtocols, iFpLpi)
+GO(XSetWMSizeHints, vFpLpL)
+GO(XSetZoomHints, iFpLp)
GO(XShrinkRegion, iFpii)
-//GO(XStoreBuffer
-//GO(XStoreBytes
-GO(XStoreColor, iFppp)
-GO(XStoreColors, iFpppi)
-// _XStoreEventCookie
-GO(XStoreName, iFppp)
-//GO(XStoreNamedColor
+GO(XStoreBuffer, iFppii)
+GO(XStoreBytes, iFppi)
+GO(XStoreColor, iFpLp)
+GO(XStoreColors, iFpLpi)
+//GO(_XStoreEventCookie,
+GO(XStoreName, iFpLp)
+GO(XStoreNamedColor, iFpLpLi)
GO(XStringListToTextProperty, iFpip)
-GO(XStringToKeysym, pFp)
+GO(XStringToKeysym, LFp)
//GOM(XSubImage, pFEpiiuu) // need unbridging
GO(dummy_XSubImage, pFpiiuu) // for the wrapper
GO(XSubtractRegion, iFppp)
GO(XSupportsLocale, iFv)
-GO(XSync, iFpu)
+GO(XSync, iFpi)
GOM(XSynchronize, pFEpi)
GO(XTextExtents, iFppipppp)
GO(XTextExtents16, iFppipppp)
-// _XTextHeight
-// _XTextHeight16
-//GO(XTextPropertyToStringList
+GO(_XTextHeight, iFppi)
+GO(_XTextHeight16, iFppi)
+GO(XTextPropertyToStringList, iFppp)
GO(XTextWidth, iFppi)
GO(XTextWidth16, iFppi)
DATAB(_Xthread_self_fn, sizeof(void*))
-GO(XTranslateCoordinates, iFpppiippp)
-// _XTranslateKey
-// _XTranslateKeySym
-// _XTryShapeBitmapCursor
+GO(XTranslateCoordinates, iFpLLiippp)
+//GO(_XTranslateKey,
+//GO(_XTranslateKeySym,
+//GO(_XTryShapeBitmapCursor,
GO(XUndefineCursor, iFpp)
-//GO(XUngrabButton
-GO(XUngrabKey, iFpiup)
+GO(XUngrabButton, iFpuuL)
+GO(XUngrabKey, iFpiuL)
GO(XUngrabKeyboard, iFpL)
GO(XUngrabPointer, iFpL)
GO(XUngrabServer, iFp)
-GO(XUninstallColormap, iFpp)
+GO(XUninstallColormap, iFpL)
GO(XUnionRectWithRegion, iFppp)
GO(XUnionRegion, iFppp)
-// _XUnknownCopyEventCookie
-// _XUnknownNativeEvent
-// _XUnknownWireEvent
-// _XUnknownWireEventCookie
-GO(XUnloadFont, iFpp)
+//GO(_XUnknownCopyEventCookie,
+//GO(_XUnknownNativeEvent,
+//GO(_XUnknownWireEvent,
+//GO(_XUnknownWireEventCookie,
+GO(XUnloadFont, iFpL)
GO(XUnlockDisplay, vFp)
DATAB(_XUnlockMutex_fn, sizeof(void*))
GO(XUnmapSubwindows, iFpp)
-GO(XUnmapWindow, iFpp)
-// _XUnregisterFilter
+GO(XUnmapWindow, iFpL)
+//GO(_XUnregisterFilter,
GOM(XUnregisterIMInstantiateCallback, iFEpppppp)
-// _XUnregisterInternalConnection
-// _XUnresolveColor
+//GO(_XUnregisterInternalConnection,
+//GO(_XUnresolveColor,
GO(XUnsetICFocus, vFp)
-// _XUpdateAtomCache
-// _XUpdateGCCache
-//GO(Xutf8DrawImageString
+//GO(_XUpdateAtomCache,
+//GO(_XUpdateGCCache,
+GO(Xutf8DrawImageString, vFpLppiipi)
GO(Xutf8DrawString, vFppppiipi)
-//GO(Xutf8DrawText
-GO(Xutf8LookupString, iFLppipp)
-GO(Xutf8ResetIC, pFL)
-GO(Xutf8SetWMProperties, vFpppppippp)
-//GO(Xutf8TextEscapement
+GO(Xutf8DrawText, vFpLpiipi)
+GO(Xutf8LookupString, iFpppipp)
+GO(Xutf8ResetIC, pFp)
+GO(Xutf8SetWMProperties, vFpLpppippp)
+GO(Xutf8TextEscapement, iFppi)
GO(Xutf8TextExtents, iFppipp)
GO(Xutf8TextListToTextProperty, iFppiup)
-// _Xutf8TextListToTextProperty
-//GO(Xutf8TextPerCharExtents
+//GO(_Xutf8TextListToTextProperty,
+GO(Xutf8TextPerCharExtents, iFppippippp)
GO(Xutf8TextPropertyToTextList, iFpppp)
-// _Xutf8TextPropertyToTextList
+//GO(_Xutf8TextPropertyToTextList,
GOM(XVaCreateNestedList, pFEiV)
GO(XVendorRelease, iFp)
-// _XVIDtoVisual
+//GO(_XVIDtoVisual,
GO(XVisualIDFromVisual, LFp)
-GO(XWarpPointer, iFpppiiuuii)
-//GO(XwcDrawImageString
+GO(XWarpPointer, iFpLLiiuuii)
+GO(XwcDrawImageString, vFpLppiipi)
GO(XwcDrawString, vFppppiipi)
-//GO(XwcDrawText
+GO(XwcDrawText, vFpLpiipi)
GO(XwcFreeStringList, vFp)
-// _XwcFreeStringList
+//GO(_XwcFreeStringList,
GO(XwcLookupString, iFpppipp)
-//GO(XwcResetIC
-// _Xwcscmp
-// _Xwcscpy
-// _Xwcslen
-// _Xwcsncmp
-// _Xwcsncpy
-// _Xwcstombs
+GO(XwcResetIC, pFp)
+//GO(_Xwcscmp,
+//GO(_Xwcscpy,
+//GO(_Xwcslen,
+//GO(_Xwcsncmp,
+//GO(_Xwcsncpy,
+//GO(_Xwcstombs,
GO(XwcTextEscapement, iFppi)
GO(XwcTextExtents, iFppipp)
-GO(XwcTextListToTextProperty, iFppiip)
-// _XwcTextListToTextProperty
-//GO(XwcTextPerCharExtents
+GO(XwcTextListToTextProperty, iFppiup)
+//GO(_XwcTextListToTextProperty,
+GO(XwcTextPerCharExtents, iFppippippp)
GO(XwcTextPropertyToTextList, iFpppp)
-// _XwcTextPropertyToTextList
-// _Xwctomb
-//GO(XWhitePixel
-//GO(XWhitePixelOfScreen
+//GO(_XwcTextPropertyToTextList,
+GO(_Xwctomb, iFpu)
+GO(XWhitePixel, LFpi)
+GO(XWhitePixelOfScreen, LFp)
//GO(XWidthMMOfScreen
GO(XWidthOfScreen, iFp)
-GO(XWindowEvent, iFpplp)
+GO(XWindowEvent, iFpLlp)
GO(_XWireToEvent, iFppp)
GO(XWithdrawWindow, iFppi)
-//GO(XWMGeometry
-//GO(XWriteBitmapFile
+GO(XWMGeometry, iFpippupppppp)
+GO(XWriteBitmapFile, iFppLuuii)
GO(XXorRegion, iFppp)
GO(_XData32, iFppu)
diff --git a/src/wrapped/wrappedlibxau.c b/src/wrapped/wrappedlibxau.c
index 7537eb0..7537eb0 100755..100644
--- a/src/wrapped/wrappedlibxau.c
+++ b/src/wrapped/wrappedlibxau.c
diff --git a/src/wrapped/wrappedlibxau_private.h b/src/wrapped/wrappedlibxau_private.h
index fae289d..fae289d 100755..100644
--- a/src/wrapped/wrappedlibxau_private.h
+++ b/src/wrapped/wrappedlibxau_private.h
diff --git a/src/wrapped/wrappedlibxcb.c b/src/wrapped/wrappedlibxcb.c
index d3798d4..d3798d4 100755..100644
--- a/src/wrapped/wrappedlibxcb.c
+++ b/src/wrapped/wrappedlibxcb.c
diff --git a/src/wrapped/wrappedlibxcb_private.h b/src/wrapped/wrappedlibxcb_private.h
index 470624e..10988e2 100755..100644
--- a/src/wrapped/wrappedlibxcb_private.h
+++ b/src/wrapped/wrappedlibxcb_private.h
@@ -148,7 +148,7 @@ GO(xcb_create_gc_checked, pFpuuup)
GO(xcb_create_glyph_cursor, pFpuuuWWWWWWWW)
//GO(xcb_create_glyph_cursor_checked,
GO(xcb_create_pixmap, pFpCuuWW)
-//GO(xcb_create_pixmap_checked,
+GO(xcb_create_pixmap_checked, pFpCuuWW)
GO(xcb_create_window, pFpCuuwwWWWWuup)
//GO(xcb_create_window_aux,
//GO(xcb_create_window_aux_checked,
@@ -460,7 +460,7 @@ GO(xcb_poly_segment, pFpuuup)
//GO(xcb_poly_text_8_sizeof,
GO(xcb_popcount, iFu)
GO(xcb_prefetch_extension_data, vFpp)
-//GO(xcb_prefetch_maximum_request_length,
+GO(xcb_prefetch_maximum_request_length, vFp)
GO(xcb_put_image, pFpCuuWWwwCCup)
//GO(xcb_put_image_checked,
//GO(xcb_put_image_data,
@@ -533,7 +533,7 @@ GO(xcb_screen_next, vFp)
//GO(xcb_segment_next,
GO(xcb_send_event, pFpCpup)
GO(xcb_send_event_checked, pFpCpup)
-//GO(xcb_send_fd,
+GO(xcb_send_fd, vFpi)
GO(xcb_send_request, uFpipp)
GO(xcb_send_request64, UFpipp)
GO(xcb_send_request_with_fds, uFpippup)
@@ -622,7 +622,7 @@ GO(xcb_setup_roots_length, iFp)
//GO(xcb_str_name_end,
//GO(xcb_str_name_length,
//GO(xcb_str_next,
-//GO(xcb_str_sizeof,
+GO(xcb_str_sizeof, iFp)
//GO(xcb_sumof,
//GO(xcb_take_socket,
//GO(xcb_timecoord_end,
diff --git a/src/wrapped/wrappedlibxcbdri2.c b/src/wrapped/wrappedlibxcbdri2.c
index 4745c51..4745c51 100755..100644
--- a/src/wrapped/wrappedlibxcbdri2.c
+++ b/src/wrapped/wrappedlibxcbdri2.c
diff --git a/src/wrapped/wrappedlibxcbdri2_private.h b/src/wrapped/wrappedlibxcbdri2_private.h
index d9efcec..313c209 100755..100644
--- a/src/wrapped/wrappedlibxcbdri2_private.h
+++ b/src/wrapped/wrappedlibxcbdri2_private.h
@@ -2,8 +2,6 @@
#error meh!
#endif
-//%S x my_xcb_cookie_t u
-
//GO(xcb_dri2_attach_format_end,
//GO(xcb_dri2_attach_format_next,
GO(xcb_dri2_authenticate, pFpuu)
diff --git a/src/wrapped/wrappedlibxcbdri3.c b/src/wrapped/wrappedlibxcbdri3.c
index a0a8542..a0a8542 100755..100644
--- a/src/wrapped/wrappedlibxcbdri3.c
+++ b/src/wrapped/wrappedlibxcbdri3.c
diff --git a/src/wrapped/wrappedlibxcbdri3_private.h b/src/wrapped/wrappedlibxcbdri3_private.h
index 2490657..b46a1be 100755..100644
--- a/src/wrapped/wrappedlibxcbdri3_private.h
+++ b/src/wrapped/wrappedlibxcbdri3_private.h
@@ -41,7 +41,7 @@ GO(xcb_dri3_open, pFpuu)
GO(xcb_dri3_open_reply, pFpup)
GO(xcb_dri3_open_reply_fds, pFpp)
//GO(xcb_dri3_open_unchecked,
-//GO(xcb_dri3_pixmap_from_buffer,
+GO(xcb_dri3_pixmap_from_buffer, pFpuuuWWWCCi)
GO(xcb_dri3_pixmap_from_buffer_checked, pFpuuuWWWCCi)
//GO(xcb_dri3_pixmap_from_buffers,
//GO(xcb_dri3_pixmap_from_buffers_checked,
diff --git a/src/wrapped/wrappedlibxcbimage.c b/src/wrapped/wrappedlibxcbimage.c
index 906e5eb..906e5eb 100755..100644
--- a/src/wrapped/wrappedlibxcbimage.c
+++ b/src/wrapped/wrappedlibxcbimage.c
diff --git a/src/wrapped/wrappedlibxcbimage_private.h b/src/wrapped/wrappedlibxcbimage_private.h
index 0127ba2..0127ba2 100755..100644
--- a/src/wrapped/wrappedlibxcbimage_private.h
+++ b/src/wrapped/wrappedlibxcbimage_private.h
diff --git a/src/wrapped/wrappedlibxcbkeysyms.c b/src/wrapped/wrappedlibxcbkeysyms.c
index 909c904..909c904 100755..100644
--- a/src/wrapped/wrappedlibxcbkeysyms.c
+++ b/src/wrapped/wrappedlibxcbkeysyms.c
diff --git a/src/wrapped/wrappedlibxcbkeysyms_private.h b/src/wrapped/wrappedlibxcbkeysyms_private.h
index 0a1b0a5..0a1b0a5 100755..100644
--- a/src/wrapped/wrappedlibxcbkeysyms_private.h
+++ b/src/wrapped/wrappedlibxcbkeysyms_private.h
diff --git a/src/wrapped/wrappedlibxcbrandr.c b/src/wrapped/wrappedlibxcbrandr.c
index 0b4387e..0b4387e 100755..100644
--- a/src/wrapped/wrappedlibxcbrandr.c
+++ b/src/wrapped/wrappedlibxcbrandr.c
diff --git a/src/wrapped/wrappedlibxcbrandr_private.h b/src/wrapped/wrappedlibxcbrandr_private.h
index 860da1b..47a9c4c 100755..100644
--- a/src/wrapped/wrappedlibxcbrandr_private.h
+++ b/src/wrapped/wrappedlibxcbrandr_private.h
@@ -88,12 +88,12 @@ GO(xcb_randr_get_crtc_info_unchecked, pFpppu)
//GO(xcb_randr_get_crtc_transform_reply,
//GO(xcb_randr_get_crtc_transform_sizeof,
//GO(xcb_randr_get_crtc_transform_unchecked,
-//GO(xcb_randr_get_monitors,
-//GO(xcb_randr_get_monitors_monitors_iterator,
-//GO(xcb_randr_get_monitors_monitors_length,
-//GO(xcb_randr_get_monitors_reply,
-//GO(xcb_randr_get_monitors_sizeof,
-//GO(xcb_randr_get_monitors_unchecked,
+GO(xcb_randr_get_monitors, pFppuC)
+GO(xcb_randr_get_monitors_monitors_iterator, pFpp)
+GO(xcb_randr_get_monitors_monitors_length, iFp)
+GO(xcb_randr_get_monitors_reply, pFpup)
+GO(xcb_randr_get_monitors_sizeof, iFp)
+GO(xcb_randr_get_monitors_unchecked, pFppuC)
GO(xcb_randr_get_output_info, pFpppu)
//GO(xcb_randr_get_output_info_clones,
//GO(xcb_randr_get_output_info_clones_end,
@@ -217,14 +217,14 @@ DATA(xcb_randr_id, 8)
//GO(xcb_randr_list_provider_properties_unchecked,
//GO(xcb_randr_mode_end,
//GO(xcb_randr_mode_info_end,
-//GO(xcb_randr_mode_info_next,
+GO(xcb_randr_mode_info_next, vFp)
//GO(xcb_randr_mode_next,
-//GO(xcb_randr_monitor_info_end,
-//GO(xcb_randr_monitor_info_next,
-//GO(xcb_randr_monitor_info_outputs,
-//GO(xcb_randr_monitor_info_outputs_end,
-//GO(xcb_randr_monitor_info_outputs_length,
-//GO(xcb_randr_monitor_info_sizeof,
+GO(xcb_randr_monitor_info_end, pFpp)
+GO(xcb_randr_monitor_info_next, vFp)
+GO(xcb_randr_monitor_info_outputs, pFp)
+GO(xcb_randr_monitor_info_outputs_end, pFpp)
+GO(xcb_randr_monitor_info_outputs_length, iFp)
+GO(xcb_randr_monitor_info_sizeof, iFp)
//GO(xcb_randr_notify_data_end,
//GO(xcb_randr_notify_data_next,
//GO(xcb_randr_output_change_end,
diff --git a/src/wrapped/wrappedlibxcbshape.c b/src/wrapped/wrappedlibxcbshape.c
index 3dc9c69..3dc9c69 100755..100644
--- a/src/wrapped/wrappedlibxcbshape.c
+++ b/src/wrapped/wrappedlibxcbshape.c
diff --git a/src/wrapped/wrappedlibxcbshape_private.h b/src/wrapped/wrappedlibxcbshape_private.h
index 61f405b..e46fada 100755..100644
--- a/src/wrapped/wrappedlibxcbshape_private.h
+++ b/src/wrapped/wrappedlibxcbshape_private.h
@@ -4,11 +4,11 @@
GO(xcb_shape_combine, pFpuuupwwp)
GO(xcb_shape_combine_checked, pFpuuupwwp)
-//GO(xcb_shape_get_rectangles,
-//GO(xcb_shape_get_rectangles_rectangles,
+GO(xcb_shape_get_rectangles, pFppi)
+GO(xcb_shape_get_rectangles_rectangles, pFp)
//GO(xcb_shape_get_rectangles_rectangles_iterator,
-//GO(xcb_shape_get_rectangles_rectangles_length,
-//GO(xcb_shape_get_rectangles_reply,
+GO(xcb_shape_get_rectangles_rectangles_length, iFp)
+GO(xcb_shape_get_rectangles_reply, pFpup)
//GO(xcb_shape_get_rectangles_sizeof,
//GO(xcb_shape_get_rectangles_unchecked,
DATA(xcb_shape_id, 8)
@@ -29,7 +29,7 @@ GO(xcb_shape_mask_checked, pFpuuuwwu)
GO(xcb_shape_query_version, pFp)
GO(xcb_shape_query_version_reply, pFppp)
GO(xcb_shape_query_version_unchecked, pFp)
-//GO(xcb_shape_rectangles,
+GO(xcb_shape_rectangles, pFpiiCpWWup)
//GO(xcb_shape_rectangles_checked,
//GO(xcb_shape_rectangles_rectangles,
//GO(xcb_shape_rectangles_rectangles_iterator,
diff --git a/src/wrapped/wrappedlibxcbshm.c b/src/wrapped/wrappedlibxcbshm.c
index 218304c..218304c 100755..100644
--- a/src/wrapped/wrappedlibxcbshm.c
+++ b/src/wrapped/wrappedlibxcbshm.c
diff --git a/src/wrapped/wrappedlibxcbshm_private.h b/src/wrapped/wrappedlibxcbshm_private.h
index cf6de17..cf6de17 100755..100644
--- a/src/wrapped/wrappedlibxcbshm_private.h
+++ b/src/wrapped/wrappedlibxcbshm_private.h
diff --git a/src/wrapped/wrappedlibxcbxfixes.c b/src/wrapped/wrappedlibxcbxfixes.c
index e41c3b8..e41c3b8 100755..100644
--- a/src/wrapped/wrappedlibxcbxfixes.c
+++ b/src/wrapped/wrappedlibxcbxfixes.c
diff --git a/src/wrapped/wrappedlibxcbxfixes_private.h b/src/wrapped/wrappedlibxcbxfixes_private.h
index f54d762..e17787d 100755..100644
--- a/src/wrapped/wrappedlibxcbxfixes_private.h
+++ b/src/wrapped/wrappedlibxcbxfixes_private.h
@@ -91,12 +91,12 @@ GO(xcb_xfixes_query_version_unchecked, pFpuu)
//GO(xcb_xfixes_select_cursor_input_checked,
GO(xcb_xfixes_select_selection_input, pFppppu)
GO(xcb_xfixes_select_selection_input_checked, pFppppu)
-//GO(xcb_xfixes_set_cursor_name,
-//GO(xcb_xfixes_set_cursor_name_checked,
-//GO(xcb_xfixes_set_cursor_name_name,
-//GO(xcb_xfixes_set_cursor_name_name_end,
-//GO(xcb_xfixes_set_cursor_name_name_length,
-//GO(xcb_xfixes_set_cursor_name_sizeof,
+GO(xcb_xfixes_set_cursor_name, pFppWp)
+GO(xcb_xfixes_set_cursor_name_checked, pFppWp)
+GO(xcb_xfixes_set_cursor_name_name, pFp)
+GO(xcb_xfixes_set_cursor_name_name_end, pFp)
+GO(xcb_xfixes_set_cursor_name_name_length, iFp)
+GO(xcb_xfixes_set_cursor_name_sizeof, iFp)
//GO(xcb_xfixes_set_gc_clip_region,
//GO(xcb_xfixes_set_gc_clip_region_checked,
//GO(xcb_xfixes_set_picture_clip_region,
diff --git a/src/wrapped/wrappedlibxcbxtest.c b/src/wrapped/wrappedlibxcbxtest.c
index b08fb35..b08fb35 100755..100644
--- a/src/wrapped/wrappedlibxcbxtest.c
+++ b/src/wrapped/wrappedlibxcbxtest.c
diff --git a/src/wrapped/wrappedlibxcbxtest_private.h b/src/wrapped/wrappedlibxcbxtest_private.h
index 2772570..2772570 100755..100644
--- a/src/wrapped/wrappedlibxcbxtest_private.h
+++ b/src/wrapped/wrappedlibxcbxtest_private.h
diff --git a/src/wrapped/wrappedlibxcomposite.c b/src/wrapped/wrappedlibxcomposite.c
index bb0394b..bb0394b 100755..100644
--- a/src/wrapped/wrappedlibxcomposite.c
+++ b/src/wrapped/wrappedlibxcomposite.c
diff --git a/src/wrapped/wrappedlibxcomposite_private.h b/src/wrapped/wrappedlibxcomposite_private.h
index 9c52d04..9c52d04 100755..100644
--- a/src/wrapped/wrappedlibxcomposite_private.h
+++ b/src/wrapped/wrappedlibxcomposite_private.h
diff --git a/src/wrapped/wrappedlibxcursor.c b/src/wrapped/wrappedlibxcursor.c
index 749d2a0..749d2a0 100755..100644
--- a/src/wrapped/wrappedlibxcursor.c
+++ b/src/wrapped/wrappedlibxcursor.c
diff --git a/src/wrapped/wrappedlibxcursor_private.h b/src/wrapped/wrappedlibxcursor_private.h
index 493b933..493b933 100755..100644
--- a/src/wrapped/wrappedlibxcursor_private.h
+++ b/src/wrapped/wrappedlibxcursor_private.h
diff --git a/src/wrapped/wrappedlibxdamage.c b/src/wrapped/wrappedlibxdamage.c
index 6f10e7f..6f10e7f 100755..100644
--- a/src/wrapped/wrappedlibxdamage.c
+++ b/src/wrapped/wrappedlibxdamage.c
diff --git a/src/wrapped/wrappedlibxdamage_private.h b/src/wrapped/wrappedlibxdamage_private.h
index 00fa99f..00fa99f 100755..100644
--- a/src/wrapped/wrappedlibxdamage_private.h
+++ b/src/wrapped/wrappedlibxdamage_private.h
diff --git a/src/wrapped/wrappedlibxdmcp.c b/src/wrapped/wrappedlibxdmcp.c
index c320caa..c320caa 100755..100644
--- a/src/wrapped/wrappedlibxdmcp.c
+++ b/src/wrapped/wrappedlibxdmcp.c
diff --git a/src/wrapped/wrappedlibxdmcp_private.h b/src/wrapped/wrappedlibxdmcp_private.h
index d583108..d583108 100755..100644
--- a/src/wrapped/wrappedlibxdmcp_private.h
+++ b/src/wrapped/wrappedlibxdmcp_private.h
diff --git a/src/wrapped/wrappedlibxext.c b/src/wrapped/wrappedlibxext.c
index efc2fba..245b65c 100755..100644
--- a/src/wrapped/wrappedlibxext.c
+++ b/src/wrapped/wrappedlibxext.c
@@ -56,7 +56,7 @@ GO(4)
static uintptr_t my_exterrorhandle_fct_##A = 0; \
static int my_exterrorhandle_##A(void* display, void* ext_name, void* reason) \
{ \
- return RunFunction(my_context, my_exterrorhandle_fct_##A, 3, display, ext_name, reason); \
+ return RunFunctionFmt(my_exterrorhandle_fct_##A, "ppp", display, ext_name, reason); \
}
SUPER()
#undef GO
@@ -83,6 +83,248 @@ static void* reverse_exterrorhandleFct(void* fct)
#undef GO
return (void*)AddBridge(my_lib->w.bridge, iFppp, fct, 0, NULL);
}
+// create_gc ...
+#define GO(A) \
+static uintptr_t my_create_gc_fct_##A = 0; \
+static int my_create_gc_##A(void* a, uint32_t b, void* c) \
+{ \
+ return RunFunctionFmt(my_create_gc_fct_##A, "pup", a, b, c); \
+}
+SUPER()
+#undef GO
+static void* find_create_gc_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_create_gc_fct_##A == (uintptr_t)fct) return my_create_gc_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_create_gc_fct_##A == 0) {my_create_gc_fct_##A = (uintptr_t)fct; return my_create_gc_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libXext create_gc callback\n");
+ return NULL;
+}
+// copy_gc ...
+#define GO(A) \
+static uintptr_t my_copy_gc_fct_##A = 0; \
+static int my_copy_gc_##A(void* a, uint32_t b, void* c) \
+{ \
+ return RunFunctionFmt(my_copy_gc_fct_##A, "pup", a, b, c); \
+}
+SUPER()
+#undef GO
+static void* find_copy_gc_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_copy_gc_fct_##A == (uintptr_t)fct) return my_copy_gc_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_copy_gc_fct_##A == 0) {my_copy_gc_fct_##A = (uintptr_t)fct; return my_copy_gc_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libXext copy_gc callback\n");
+ return NULL;
+}
+// flush_gc ...
+#define GO(A) \
+static uintptr_t my_flush_gc_fct_##A = 0; \
+static int my_flush_gc_##A(void* a, uint32_t b, void* c) \
+{ \
+ return RunFunctionFmt(my_flush_gc_fct_##A, "pup", a, b, c); \
+}
+SUPER()
+#undef GO
+static void* find_flush_gc_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_flush_gc_fct_##A == (uintptr_t)fct) return my_flush_gc_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_flush_gc_fct_##A == 0) {my_flush_gc_fct_##A = (uintptr_t)fct; return my_flush_gc_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libXext flush_gc callback\n");
+ return NULL;
+}
+// free_gc ...
+#define GO(A) \
+static uintptr_t my_free_gc_fct_##A = 0; \
+static int my_free_gc_##A(void* a, uint32_t b, void* c) \
+{ \
+ return RunFunctionFmt(my_free_gc_fct_##A, "pup", a, b, c); \
+}
+SUPER()
+#undef GO
+static void* find_free_gc_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_free_gc_fct_##A == (uintptr_t)fct) return my_free_gc_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_free_gc_fct_##A == 0) {my_free_gc_fct_##A = (uintptr_t)fct; return my_free_gc_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libXext free_gc callback\n");
+ return NULL;
+}
+// create_font ...
+#define GO(A) \
+static uintptr_t my_create_font_fct_##A = 0; \
+static int my_create_font_##A(void* a, void* b, void* c) \
+{ \
+ return RunFunctionFmt(my_create_font_fct_##A, "ppp", a, b, c); \
+}
+SUPER()
+#undef GO
+static void* find_create_font_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_create_font_fct_##A == (uintptr_t)fct) return my_create_font_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_create_font_fct_##A == 0) {my_create_font_fct_##A = (uintptr_t)fct; return my_create_font_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libXext create_font callback\n");
+ return NULL;
+}
+// free_font ...
+#define GO(A) \
+static uintptr_t my_free_font_fct_##A = 0; \
+static int my_free_font_##A(void* a, void* b, void* c) \
+{ \
+ return RunFunctionFmt(my_free_font_fct_##A, "ppp", a, b, c); \
+}
+SUPER()
+#undef GO
+static void* find_free_font_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_free_font_fct_##A == (uintptr_t)fct) return my_free_font_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_free_font_fct_##A == 0) {my_free_font_fct_##A = (uintptr_t)fct; return my_free_font_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libXext free_font callback\n");
+ return NULL;
+}
+// close_display ...
+#define GO(A) \
+static uintptr_t my_close_display_fct_##A = 0; \
+static int my_close_display_##A(void* a, void* b) \
+{ \
+ return RunFunctionFmt(my_close_display_fct_##A, "pp", a, b);\
+}
+SUPER()
+#undef GO
+static void* find_close_display_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_close_display_fct_##A == (uintptr_t)fct) return my_close_display_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_close_display_fct_##A == 0) {my_close_display_fct_##A = (uintptr_t)fct; return my_close_display_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libXext close_display callback\n");
+ return NULL;
+}
+// wire_to_event ...
+#define GO(A) \
+static uintptr_t my_wire_to_event_fct_##A = 0; \
+static int my_wire_to_event_##A(void* a, void* b, void* c) \
+{ \
+ return RunFunctionFmt(my_wire_to_event_fct_##A, "ppp", a, b, c); \
+}
+SUPER()
+#undef GO
+static void* find_wire_to_event_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_wire_to_event_fct_##A == (uintptr_t)fct) return my_wire_to_event_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_wire_to_event_fct_##A == 0) {my_wire_to_event_fct_##A = (uintptr_t)fct; return my_wire_to_event_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libXext wire_to_event callback\n");
+ return NULL;
+}
+// event_to_wire ...
+#define GO(A) \
+static uintptr_t my_event_to_wire_fct_##A = 0; \
+static int my_event_to_wire_##A(void* a, void* b, void* c) \
+{ \
+ return RunFunctionFmt(my_event_to_wire_fct_##A, "ppp", a, b, c); \
+}
+SUPER()
+#undef GO
+static void* find_event_to_wire_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_event_to_wire_fct_##A == (uintptr_t)fct) return my_event_to_wire_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_event_to_wire_fct_##A == 0) {my_event_to_wire_fct_##A = (uintptr_t)fct; return my_event_to_wire_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libXext event_to_wire callback\n");
+ return NULL;
+}
+// error ...
+#define GO(A) \
+static uintptr_t my_error_fct_##A = 0; \
+static int my_error_##A(void* a, void* b, void* c, int* d) \
+{ \
+ return RunFunctionFmt(my_error_fct_##A, "pppp", a, b, c, d); \
+}
+SUPER()
+#undef GO
+static void* find_error_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_error_fct_##A == (uintptr_t)fct) return my_error_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_error_fct_##A == 0) {my_error_fct_##A = (uintptr_t)fct; return my_error_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libXext error callback\n");
+ return NULL;
+}
+// error_string ...
+#define GO(A) \
+static uintptr_t my_error_string_fct_##A = 0; \
+static int my_error_string_##A(void* a, int b, void* c, void* d, int e) \
+{ \
+ return RunFunctionFmt(my_error_string_fct_##A, "pippi", a, b, c, d, e); \
+}
+SUPER()
+#undef GO
+static void* find_error_string_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_error_string_fct_##A == (uintptr_t)fct) return my_error_string_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_error_string_fct_##A == 0) {my_error_string_fct_##A = (uintptr_t)fct; return my_error_string_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libXext error_string callback\n");
+ return NULL;
+}
#undef SUPER
@@ -123,81 +365,10 @@ EXPORT void* my_XSetExtensionErrorHandler(x64emu_t* emu, void* handler)
return reverse_exterrorhandleFct(my->XSetExtensionErrorHandler(find_exterrorhandle_Fct(handler)));
}
-static box64context_t *context = NULL;
-static uintptr_t my_hook_create_gc_fnc = 0;
-static uintptr_t my_hook_copy_gc_fnc = 0;
-static uintptr_t my_hook_flush_gc_fnc = 0;
-static uintptr_t my_hook_free_gc_fnc = 0;
-static uintptr_t my_hook_create_font_fnc = 0;
-static uintptr_t my_hook_free_font_fnc = 0;
-static uintptr_t my_hook_close_display_fnc = 0;
-static uintptr_t my_hook_wire_to_event_fnc = 0;
-static uintptr_t my_hook_event_to_wire_fnc = 0;
-static uintptr_t my_hook_error_fnc = 0;
-static uintptr_t my_hook_error_string_fnc = 0;
-static int my_hook_create_gc(void* a, uint32_t b, void* c) {
- if(my_hook_create_gc_fnc)
- return (int)RunFunction(context, my_hook_create_gc_fnc, 3, a, b, c);
- return 0;
-}
-static int my_hook_copy_gc(void* a, uint32_t b, void* c) {
- if(my_hook_copy_gc_fnc)
- return (int)RunFunction(context, my_hook_copy_gc_fnc, 3, a, b, c);
- return 0;
-}
-static int my_hook_flush_gc(void* a, uint32_t b, void* c) {
- if(my_hook_flush_gc_fnc)
- return (int)RunFunction(context, my_hook_flush_gc_fnc, 3, a, b, c);
- return 0;
-}
-static int my_hook_free_gc(void* a, uint32_t b, void* c) {
- if(my_hook_free_gc_fnc)
- return (int)RunFunction(context, my_hook_free_gc_fnc, 3, a, b, c);
- return 0;
-}
-static int my_hook_create_font(void* a, void* b, void* c) {
- if(my_hook_create_font_fnc)
- return (int)RunFunction(context, my_hook_create_font_fnc, 3, a, b, c);
- return 0;
-}
-static int my_hook_free_font(void* a, void* b, void* c) {
- if(my_hook_free_font_fnc)
- return (int)RunFunction(context, my_hook_free_font_fnc, 3, a, b, c);
- return 0;
-}
-static int my_hook_close_display(void* a, void* b) {
- if(my_hook_close_display_fnc)
- return (int)RunFunction(context, my_hook_close_display_fnc, 2, a, b);
- return 0;
-}
-static int my_hook_wire_to_event(void* a, void* b, void* c) {
- if(my_hook_wire_to_event_fnc)
- return (int)RunFunction(context, my_hook_wire_to_event_fnc, 3, a, b, c);
- return 0;
-}
-static int my_hook_event_to_wire(void* a, void* b, void* c) {
- if(my_hook_event_to_wire_fnc)
- return (int)RunFunction(context, my_hook_event_to_wire_fnc, 3, a, b, c);
- return 0;
-}
-static int my_hook_error(void* a, void* b, void* c, int* d) {
- if(my_hook_error_fnc)
- return (int)RunFunction(context, my_hook_error_fnc, 4, a, b, c, d);
- return 0;
-}
-static char* my_hook_error_string(void* a, int b, void* c, void* d, int e) {
- if(my_hook_error_string_fnc)
- return (char*)RunFunction(context, my_hook_error_string_fnc, 5, a, b, c, d, e);
- return 0;
-}
-
EXPORT void* my_XextAddDisplay(x64emu_t* emu, void* extinfo, void* dpy, void* extname, my_XExtensionHooks* hooks, int nevents, void* data)
{
- if(!context)
- context = emu->context;
-
my_XExtensionHooks natives = {0};
- #define GO(A) if(hooks->A) {my_hook_##A##_fnc = (uintptr_t)hooks->A; natives.A = my_hook_##A;}
+ #define GO(A) natives.A = find_##A##_Fct(hooks->A);
GO(create_gc)
GO(copy_gc)
GO(flush_gc)
diff --git a/src/wrapped/wrappedlibxext_private.h b/src/wrapped/wrappedlibxext_private.h
index 2e2ac8e..2e2ac8e 100755..100644
--- a/src/wrapped/wrappedlibxext_private.h
+++ b/src/wrapped/wrappedlibxext_private.h
diff --git a/src/wrapped/wrappedlibxfixes.c b/src/wrapped/wrappedlibxfixes.c
index 6ee42f8..6ee42f8 100755..100644
--- a/src/wrapped/wrappedlibxfixes.c
+++ b/src/wrapped/wrappedlibxfixes.c
diff --git a/src/wrapped/wrappedlibxfixes_private.h b/src/wrapped/wrappedlibxfixes_private.h
index b388944..b388944 100755..100644
--- a/src/wrapped/wrappedlibxfixes_private.h
+++ b/src/wrapped/wrappedlibxfixes_private.h
diff --git a/src/wrapped/wrappedlibxft.c b/src/wrapped/wrappedlibxft.c
index b779f93..b779f93 100755..100644
--- a/src/wrapped/wrappedlibxft.c
+++ b/src/wrapped/wrappedlibxft.c
diff --git a/src/wrapped/wrappedlibxft_private.h b/src/wrapped/wrappedlibxft_private.h
index 0c00da9..843213b 100755..100644
--- a/src/wrapped/wrappedlibxft_private.h
+++ b/src/wrapped/wrappedlibxft_private.h
@@ -6,9 +6,9 @@
//GO(XftCharFontSpecRender,
//GO(XftCharIndex,
//GO(XftCharSpecRender,
-//GO(XftColorAllocName,
+GO(XftColorAllocName, iFppupp)
//GO(XftColorAllocValue,
-//GO(XftColorFree,
+GO(XftColorFree, vFppup)
//GO(XftDefaultHasRender,
//GO(XftDefaultSet,
//GO(XftDefaultSubstitute,
@@ -19,27 +19,27 @@ GO(XftDrawChange, vFpp)
GO(XftDrawCreate, pFpppp)
//GO(XftDrawCreateAlpha,
//GO(XftDrawCreateBitmap,
-//GO(XftDrawDestroy,
+GO(XftDrawDestroy, vFp)
//GO(XftDrawDisplay,
//GO(XftDrawDrawable,
//GO(XftDrawGlyphFontSpec,
//GO(XftDrawGlyphs,
//GO(XftDrawGlyphSpec,
//GO(XftDrawPicture,
-//GO(XftDrawRect,
+GO(XftDrawRect, vFppiiuu)
GO(XftDrawSetClip, iFpp)
//GO(XftDrawSetClipRectangles,
//GO(XftDrawSetSubwindowMode,
//GO(XftDrawSrcPicture,
-//GO(XftDrawString16,
+GO(XftDrawString16, vFpppiipi)
GO(XftDrawString32, vFpppiipi)
//GO(XftDrawString8,
//GO(XftDrawStringUtf16,
//GO(XftDrawStringUtf8,
//GO(XftDrawVisual,
//GO(XftFontCheckGlyph,
-//GO(XftFontClose,
-//GO(XftFontCopy,
+GO(XftFontClose, vFpp)
+GO(XftFontCopy, pFpp)
//GO(XftFontInfoCreate,
//GO(XftFontInfoDestroy,
//GO(XftFontInfoEqual,
@@ -63,7 +63,7 @@ GO(XftFontOpenXlfd, pFpip)
//GO(XftLockFace,
//GO(XftNameParse,
GO(XftNameUnparse, iFppi)
-//GO(XftTextExtents16,
+GO(XftTextExtents16, vFpppip)
GO(XftTextExtents32, vFpppip)
//GO(XftTextExtents8,
//GO(XftTextExtentsUtf16,
diff --git a/src/wrapped/wrappedlibxi.c b/src/wrapped/wrappedlibxi.c
index 0d2d065..0d2d065 100755..100644
--- a/src/wrapped/wrappedlibxi.c
+++ b/src/wrapped/wrappedlibxi.c
diff --git a/src/wrapped/wrappedlibxi_private.h b/src/wrapped/wrappedlibxi_private.h
index 4b81a2d..6e10da5 100755..100644
--- a/src/wrapped/wrappedlibxi_private.h
+++ b/src/wrapped/wrappedlibxi_private.h
@@ -38,7 +38,7 @@ GO(XIBarrierReleasePointer, vFpipp)
GO(XIBarrierReleasePointers, vFppi)
//GO(XIChangeHierarchy,
GO(XIChangeProperty, vFpippiipi)
-//GO(XIDefineCursor,
+GO(XIDefineCursor, iFpipp)
GO(XIDeleteProperty, vFpip)
GO(XIFreeDeviceInfo, vFp)
GO(XIGetClientPointer, iFppp)
@@ -58,7 +58,7 @@ GO(XIQueryVersion, iFppp)
GO(XISelectEvents, iFpppi)
GO(XISetClientPointer, iFppi)
//GO(XISetFocus,
-//GO(XIUndefineCursor,
+GO(XIUndefineCursor, iFpip)
GO(XIUngrabButton, iFpiipip)
GO(XIUngrabDevice, iFpiL)
//GO(XIUngrabEnter,
diff --git a/src/wrapped/wrappedlibxmu.c b/src/wrapped/wrappedlibxmu.c
index 225f682..225f682 100755..100644
--- a/src/wrapped/wrappedlibxmu.c
+++ b/src/wrapped/wrappedlibxmu.c
diff --git a/src/wrapped/wrappedlibxmu_private.h b/src/wrapped/wrappedlibxmu_private.h
index 931574d..931574d 100755..100644
--- a/src/wrapped/wrappedlibxmu_private.h
+++ b/src/wrapped/wrappedlibxmu_private.h
diff --git a/src/wrapped/wrappedlibxpm.c b/src/wrapped/wrappedlibxpm.c
index b978082..b978082 100755..100644
--- a/src/wrapped/wrappedlibxpm.c
+++ b/src/wrapped/wrappedlibxpm.c
diff --git a/src/wrapped/wrappedlibxpm_private.h b/src/wrapped/wrappedlibxpm_private.h
index fc71b02..fc71b02 100755..100644
--- a/src/wrapped/wrappedlibxpm_private.h
+++ b/src/wrapped/wrappedlibxpm_private.h
diff --git a/src/wrapped/wrappedlibxrandr.c b/src/wrapped/wrappedlibxrandr.c
index b74cca0..b74cca0 100755..100644
--- a/src/wrapped/wrappedlibxrandr.c
+++ b/src/wrapped/wrappedlibxrandr.c
diff --git a/src/wrapped/wrappedlibxrandr_private.h b/src/wrapped/wrappedlibxrandr_private.h
index c8f198b..c8f198b 100755..100644
--- a/src/wrapped/wrappedlibxrandr_private.h
+++ b/src/wrapped/wrappedlibxrandr_private.h
diff --git a/src/wrapped/wrappedlibxrender.c b/src/wrapped/wrappedlibxrender.c
index ff2c218..ff2c218 100755..100644
--- a/src/wrapped/wrappedlibxrender.c
+++ b/src/wrapped/wrappedlibxrender.c
diff --git a/src/wrapped/wrappedlibxrender_private.h b/src/wrapped/wrappedlibxrender_private.h
index 5c25670..5c25670 100755..100644
--- a/src/wrapped/wrappedlibxrender_private.h
+++ b/src/wrapped/wrappedlibxrender_private.h
diff --git a/src/wrapped/wrappedlibxss.c b/src/wrapped/wrappedlibxss.c
index 00c00b9..00c00b9 100755..100644
--- a/src/wrapped/wrappedlibxss.c
+++ b/src/wrapped/wrappedlibxss.c
diff --git a/src/wrapped/wrappedlibxss_private.h b/src/wrapped/wrappedlibxss_private.h
index d345f04..d345f04 100755..100644
--- a/src/wrapped/wrappedlibxss_private.h
+++ b/src/wrapped/wrappedlibxss_private.h
diff --git a/src/wrapped/wrappedlibxt.c b/src/wrapped/wrappedlibxt.c
index 6177ae8..6a7180f 100755..100644
--- a/src/wrapped/wrappedlibxt.c
+++ b/src/wrapped/wrappedlibxt.c
@@ -39,7 +39,7 @@ GO(7)
static uintptr_t my_Event_fct_##A = 0; \
static void my_Event_##A(void* w, void* data, void* event) \
{ \
- RunFunction(my_context, my_Event_fct_##A, 3, w, data, event);\
+ RunFunctionFmt(my_Event_fct_##A, "ppp", w, data, event);\
}
SUPER()
#undef GO
@@ -61,7 +61,7 @@ static void* findEventFct(void* fct)
static uintptr_t my_WorkProc_fct_##A = 0; \
static int my_WorkProc_##A(void* p) \
{ \
- return (int)RunFunction(my_context, my_WorkProc_fct_##A, 1, p);\
+ return (int)RunFunctionFmt(my_WorkProc_fct_##A, "p", p);\
}
SUPER()
#undef GO
@@ -83,7 +83,7 @@ static void* findWorkProcFct(void* fct)
static uintptr_t my_InputCallback_fct_##A = 0; \
static void my_InputCallback_##A(void* p, void* s, void* id) \
{ \
- RunFunction(my_context, my_InputCallback_fct_##A, 3, p, s, id); \
+ RunFunctionFmt(my_InputCallback_fct_##A, "ppp", p, s, id); \
}
SUPER()
#undef GO
diff --git a/src/wrapped/wrappedlibxt_private.h b/src/wrapped/wrappedlibxt_private.h
index 68139c5..68139c5 100755..100644
--- a/src/wrapped/wrappedlibxt_private.h
+++ b/src/wrapped/wrappedlibxt_private.h
diff --git a/src/wrapped/wrappedlibxtst.c b/src/wrapped/wrappedlibxtst.c
index eaec1de..4ae3a68 100755..100644
--- a/src/wrapped/wrappedlibxtst.c
+++ b/src/wrapped/wrappedlibxtst.c
@@ -36,7 +36,7 @@ GO(4)
static uintptr_t my_XRecordInterceptProc_fct_##A = 0; \
static void my_XRecordInterceptProc_##A(void* a, void* b) \
{ \
- RunFunction(my_context, my_XRecordInterceptProc_fct_##A, 2, a, b); \
+ RunFunctionFmt(my_XRecordInterceptProc_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
diff --git a/src/wrapped/wrappedlibxtst_private.h b/src/wrapped/wrappedlibxtst_private.h
index ce15425..ce15425 100755..100644
--- a/src/wrapped/wrappedlibxtst_private.h
+++ b/src/wrapped/wrappedlibxtst_private.h
diff --git a/src/wrapped/wrappedlibxxf86vm.c b/src/wrapped/wrappedlibxxf86vm.c
index 3f24e95..3f24e95 100755..100644
--- a/src/wrapped/wrappedlibxxf86vm.c
+++ b/src/wrapped/wrappedlibxxf86vm.c
diff --git a/src/wrapped/wrappedlibxxf86vm_private.h b/src/wrapped/wrappedlibxxf86vm_private.h
index b418072..b418072 100755..100644
--- a/src/wrapped/wrappedlibxxf86vm_private.h
+++ b/src/wrapped/wrappedlibxxf86vm_private.h
diff --git a/src/wrapped/wrappedlibz.c b/src/wrapped/wrappedlibz.c
index 8d3ebb7..4613c47 100755..100644
--- a/src/wrapped/wrappedlibz.c
+++ b/src/wrapped/wrappedlibz.c
@@ -34,7 +34,7 @@ GO(4)
static uintptr_t my_alloc_fct_##A = 0; \
static void* my_alloc_##A(void* opaque, uint32_t items, uint32_t size) \
{ \
- return (void*)RunFunction(my_context, my_alloc_fct_##A, 3, opaque, items, size); \
+ return (void*)RunFunctionFmt(my_alloc_fct_##A, "puu", opaque, items, size); \
}
SUPER()
#undef GO
@@ -51,12 +51,22 @@ static void* find_alloc_Fct(void* fct)
printf_log(LOG_NONE, "Warning, no more slot for zlib alloc callback\n");
return NULL;
}
+static void* reverse_alloc_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(CheckBridged(my_lib->w.bridge, fct))
+ return (void*)CheckBridged(my_lib->w.bridge, fct);
+ #define GO(A) if(my_alloc_##A == fct) return (void*)my_alloc_fct_##A;
+ SUPER()
+ #undef GO
+ return (void*)AddBridge(my_lib->w.bridge, pFpuu, fct, 0, NULL);
+}
// free ...
#define GO(A) \
static uintptr_t my_free_fct_##A = 0; \
static void my_free_##A(void* opaque, void* address) \
{ \
- RunFunction(my_context, my_free_fct_##A, 2, opaque, address); \
+ RunFunctionFmt(my_free_fct_##A, "pp", opaque, address); \
}
SUPER()
#undef GO
@@ -73,10 +83,20 @@ static void* find_free_Fct(void* fct)
printf_log(LOG_NONE, "Warning, no more slot for zlib free callback\n");
return NULL;
}
+static void* reverse_free_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(CheckBridged(my_lib->w.bridge, fct))
+ return (void*)CheckBridged(my_lib->w.bridge, fct);
+ #define GO(A) if(my_free_##A == fct) return (void*)my_free_fct_##A;
+ SUPER()
+ #undef GO
+ return (void*)AddBridge(my_lib->w.bridge, vFpp, fct, 0, NULL);
+}
#undef SUPER
typedef struct z_stream_s {
- void *next_in;
+ void *next_in;
uint32_t avail_in;
uintptr_t total_in;
void *next_out;
@@ -85,11 +105,11 @@ typedef struct z_stream_s {
char *msg;
void *state;
void* zalloc;
- void* zfree;
+ void* zfree;
void* opaque;
int32_t data_type;
- uintptr_t adler;
- uintptr_t reserved;
+ uintptr_t adler;
+ uintptr_t reserved;
} z_stream;
static void wrapper_stream_z(x64emu_t* emu, void* str)
@@ -99,28 +119,41 @@ static void wrapper_stream_z(x64emu_t* emu, void* str)
stream->zalloc = find_alloc_Fct(stream->zalloc);
stream->zfree = find_free_Fct(stream->zfree);
}
+static void unwrapper_stream_z(x64emu_t* emu, void* str)
+{
+ (void)emu;
+ z_stream *stream = (z_stream*)str;
+ stream->zalloc = reverse_alloc_Fct(stream->zalloc);
+ stream->zfree = reverse_free_Fct(stream->zfree);
+}
EXPORT int my_inflateInit_(x64emu_t* emu, void* str, void* version, int size)
{
wrapper_stream_z(emu, str);
- return my->inflateInit_(str, version, size);
+ int ret = my->inflateInit_(str, version, size);
+ unwrapper_stream_z(emu, str);
+ return ret;
}
EXPORT int my_inflateInit2_(x64emu_t* emu, void* str, int windowBits, void* version, int stream_size)
{
wrapper_stream_z(emu, str);
- return my->inflateInit2_(str, windowBits, version, stream_size);
+ int ret = my->inflateInit2_(str, windowBits, version, stream_size);
+ unwrapper_stream_z(emu, str);
+ return ret;
}
-EXPORT int my_inflateBackInit_(x64emu_t* emu, void* strm, int windowBits, void *window, void* version, int size)
+EXPORT int my_inflateBackInit_(x64emu_t* emu, void* str, int windowBits, void *window, void* version, int size)
{
- wrapper_stream_z(emu, strm);
- return my->inflateBackInit_(strm, windowBits, window, version, size);
+ wrapper_stream_z(emu, str);
+ int ret = my->inflateBackInit_(str, windowBits, window, version, size);
+ unwrapper_stream_z(emu, str);
+ return ret;
}
-// TODO: remove this?
EXPORT int my_inflateEnd(x64emu_t* emu, void* str)
{
+ wrapper_stream_z(emu, str);
int r = my->inflateEnd(str);
return r;
}
@@ -128,18 +161,23 @@ EXPORT int my_inflateEnd(x64emu_t* emu, void* str)
EXPORT int my_deflateInit_(x64emu_t* emu, void* str, int level, void* version, int stream_size)
{
wrapper_stream_z(emu, str);
- return my->deflateInit_(str, level, version, stream_size);
+ int ret = my->deflateInit_(str, level, version, stream_size);
+ unwrapper_stream_z(emu, str);
+ return ret;
}
EXPORT int my_deflateInit2_(x64emu_t* emu, void* str, int level, int method, int windowBits, int memLevel, int strategy, void* version, int stream_size)
{
wrapper_stream_z(emu, str);
- return my->deflateInit2_(str, level, method, windowBits, memLevel, strategy, version, stream_size);
+ int ret = my->deflateInit2_(str, level, method, windowBits, memLevel, strategy, version, stream_size);
+ unwrapper_stream_z(emu, str);
+ return ret;
}
// TODO: remove this?
EXPORT int my_deflateEnd(x64emu_t* emu, void* str)
{
+ wrapper_stream_z(emu, str);
int r = my->deflateEnd(str);
return r;
}
@@ -147,8 +185,9 @@ EXPORT int my_deflateEnd(x64emu_t* emu, void* str)
EXPORT int my_inflate(x64emu_t* emu, void* str, int flush)
{
wrapper_stream_z(emu, str);
- return my->inflate(str, flush);
- //TODO: should unwrap the stream
+ int ret = my->inflate(str, flush);
+ unwrapper_stream_z(emu, str);
+ return ret;
}
diff --git a/src/wrapped/wrappedlzma.c b/src/wrapped/wrappedlzma.c
index 638a38d..8592037 100755..100644
--- a/src/wrapped/wrappedlzma.c
+++ b/src/wrapped/wrappedlzma.c
@@ -64,7 +64,7 @@ GO(4)
static uintptr_t my_alloc_fct_##A = 0; \
static void* my_alloc_##A(void* opaque, size_t items, size_t size) \
{ \
- return (void*)RunFunction(my_context, my_alloc_fct_##A, 3, opaque, items, size);\
+ return (void*)RunFunctionFmt(my_alloc_fct_##A, "pLL", opaque, items, size);\
}
SUPER()
#undef GO
@@ -81,12 +81,22 @@ static void* find_alloc_Fct(void* fct)
printf_log(LOG_NONE, "Warning, no more slot for zlib alloc callback\n");
return NULL;
}
+static void* reverse_alloc_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(CheckBridged(my_lib->w.bridge, fct))
+ return (void*)CheckBridged(my_lib->w.bridge, fct);
+ #define GO(A) if(my_alloc_##A == fct) return (void*)my_alloc_fct_##A;
+ SUPER()
+ #undef GO
+ return (void*)AddBridge(my_lib->w.bridge, pFpuu, fct, 0, NULL);
+}
// free ...
#define GO(A) \
static uintptr_t my_free_fct_##A = 0; \
static void my_free_##A(void* opaque, void* address) \
{ \
- RunFunction(my_context, my_free_fct_##A, 2, opaque, address); \
+ RunFunctionFmt(my_free_fct_##A, "pp", opaque, address); \
}
SUPER()
#undef GO
@@ -103,101 +113,143 @@ static void* find_free_Fct(void* fct)
printf_log(LOG_NONE, "Warning, no more slot for zlib free callback\n");
return NULL;
}
+static void* reverse_free_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(CheckBridged(my_lib->w.bridge, fct))
+ return (void*)CheckBridged(my_lib->w.bridge, fct);
+ #define GO(A) if(my_free_##A == fct) return (void*)my_free_fct_##A;
+ SUPER()
+ #undef GO
+ return (void*)AddBridge(my_lib->w.bridge, vFpp, fct, 0, NULL);
+}
#undef SUPER
-static void wrap_alloc_struct(lzma_allocator_t* dst, lzma_allocator_t* src)
+static void wrap_alloc_struct(lzma_allocator_t* a)
+{
+ if(!a)
+ return;
+ a->alloc = find_alloc_Fct(a->alloc);
+ a->free = find_free_Fct(a->free);
+
+}
+static void unwrap_alloc_struct(lzma_allocator_t* a)
{
- if(!src)
+ if(!a)
return;
- dst->opaque = src->opaque;
- dst->alloc = find_alloc_Fct(src->alloc);
- dst->free = find_free_Fct(src->free);
-
+ a->alloc = reverse_alloc_Fct(a->alloc);
+ a->free = reverse_free_Fct(a->free);
+
}
EXPORT int my_lzma_index_buffer_decode(x64emu_t* emu, void* i, void* memlimit, lzma_allocator_t* alloc, void* in_, void* in_pos, size_t in_size)
{
- lzma_allocator_t allocator = {0};
- wrap_alloc_struct(&allocator, alloc);
- return my->lzma_index_buffer_decode(i, memlimit, alloc?&allocator:NULL, in_, in_pos, in_size);
+ wrap_alloc_struct(alloc);
+ int ret = my->lzma_index_buffer_decode(i, memlimit, alloc, in_, in_pos, in_size);
+ unwrap_alloc_struct(alloc);
+ return ret;
}
EXPORT void my_lzma_index_end(x64emu_t* emu, void* i, lzma_allocator_t* alloc)
{
- lzma_allocator_t allocator = {0};
- wrap_alloc_struct(&allocator, alloc);
- return my->lzma_index_end(i,alloc?&allocator:NULL);
+ wrap_alloc_struct(alloc);
+ my->lzma_index_end(i,alloc);
+ unwrap_alloc_struct(alloc);
}
EXPORT int my_lzma_stream_buffer_decode(x64emu_t* emu, void* memlimit, uint32_t flags, lzma_allocator_t* alloc, void* in_, void* in_pos, size_t in_size, void* out_, void* out_pos, size_t out_size)
{
- lzma_allocator_t allocator = {0};
- wrap_alloc_struct(&allocator, alloc);
- return my->lzma_stream_buffer_decode(memlimit, flags, alloc?&allocator:NULL, in_, in_pos, in_size, out_, out_pos, out_size);
+ wrap_alloc_struct(alloc);
+ int ret = my->lzma_stream_buffer_decode(memlimit, flags, alloc, in_, in_pos, in_size, out_, out_pos, out_size);
+ unwrap_alloc_struct(alloc);
+ return ret;
}
EXPORT int my_lzma_stream_decoder(x64emu_t* emu, lzma_stream_t* stream, uint64_t memlimit, uint32_t flags)
{
- // not restoring the allocator after, so lzma_code and lzma_end can be used without "GOM" wrapping
- if(stream->allocator)
- wrap_alloc_struct(stream->allocator, stream->allocator);
- return my->lzma_stream_decoder(stream, memlimit, flags);
+ wrap_alloc_struct(stream->allocator);
+ int ret = my->lzma_stream_decoder(stream, memlimit, flags);
+ unwrap_alloc_struct(stream->allocator);
+ return ret;
}
EXPORT int my_lzma_stream_encoder(x64emu_t* emu, lzma_stream_t* stream, void* filters, int check)
{
- // not restoring the allocator after, so lzma_code and lzma_end can be used without "GOM" wrapping
- if(stream->allocator)
- wrap_alloc_struct(stream->allocator, stream->allocator);
- return my->lzma_stream_encoder(stream, filters, check);
+ wrap_alloc_struct(stream->allocator);
+ int ret = my->lzma_stream_encoder(stream, filters, check);
+ unwrap_alloc_struct(stream->allocator);
+ return ret;
}
EXPORT int my_lzma_easy_encoder(x64emu_t* emu, lzma_stream_t* stream, uint32_t precheck, uint32_t check)
{
- // not restoring the allocator after, so lzma_code and lzma_end can be used without "GOM" wrapping
- if(stream->allocator)
- wrap_alloc_struct(stream->allocator, stream->allocator);
- return my->lzma_easy_encoder(stream, precheck, check);
+ wrap_alloc_struct(stream->allocator);
+ int ret = my->lzma_easy_encoder(stream, precheck, check);
+ unwrap_alloc_struct(stream->allocator);
+ return ret;
}
EXPORT int my_lzma_raw_encoder(x64emu_t* emu, lzma_stream_t* stream, void* filters)
{
- // not restoring the allocator after, so lzma_code and lzma_end can be used without "GOM" wrapping
- if(stream->allocator)
- wrap_alloc_struct(stream->allocator, stream->allocator);
- return my->lzma_raw_encoder(stream, filters);
+ wrap_alloc_struct(stream->allocator);
+ int ret = my->lzma_raw_encoder(stream, filters);
+ unwrap_alloc_struct(stream->allocator);
+ return ret;
}
EXPORT int my_lzma_raw_decoder(x64emu_t* emu, lzma_stream_t* stream, void* filters)
{
- // not restoring the allocator after, so lzma_code and lzma_end can be used without "GOM" wrapping
- if(stream->allocator)
- wrap_alloc_struct(stream->allocator, stream->allocator);
- return my->lzma_raw_decoder(stream, filters);
+ wrap_alloc_struct(stream->allocator);
+ int ret = my->lzma_raw_decoder(stream, filters);
+ unwrap_alloc_struct(stream->allocator);
+ return ret;
}
EXPORT int my_lzma_properties_decode(x64emu_t* emu, void* filters, lzma_allocator_t* allocator, void* props, size_t size)
{
- lzma_allocator_t alloc = {0};
- wrap_alloc_struct(&alloc, allocator);
- return my->lzma_properties_decode(filters, &alloc, props, size);
+ wrap_alloc_struct(allocator);
+ int ret = my->lzma_properties_decode(filters, allocator, props, size);
+ unwrap_alloc_struct(allocator);
+ return ret;
}
EXPORT int my_lzma_alone_decoder(x64emu_t* emu, lzma_stream_t* stream, uint64_t memlimit)
{
- // not restoring the allocator after, so lzma_code and lzma_end can be used without "GOM" wrapping
- if(stream->allocator)
- wrap_alloc_struct(stream->allocator, stream->allocator);
- return my->lzma_alone_decoder(stream, memlimit);
+ wrap_alloc_struct(stream->allocator);
+ int ret = my->lzma_alone_decoder(stream, memlimit);
+ unwrap_alloc_struct(stream->allocator);
+ return ret;
}
EXPORT int my_lzma_alone_encoder(x64emu_t* emu, lzma_stream_t* stream, void* options)
{
- // not restoring the allocator after, so lzma_code and lzma_end can be used without "GOM" wrapping
- if(stream->allocator)
- wrap_alloc_struct(stream->allocator, stream->allocator);
- return my->lzma_alone_encoder(stream, options);
+ wrap_alloc_struct(stream->allocator);
+ int ret = my->lzma_alone_encoder(stream, options);
+ unwrap_alloc_struct(stream->allocator);
+ return ret;
+}
+
+EXPORT int my_lzma_stream_encoder_mt(x64emu_t* emu, lzma_stream_t* stream, void* options)
+{
+ wrap_alloc_struct(stream->allocator);
+ int ret = my->lzma_stream_encoder_mt(stream, options);
+ unwrap_alloc_struct(stream->allocator);
+ return ret;
+}
+
+EXPORT int my_lzma_code(x64emu_t* emu, lzma_stream_t* stream, int a)
+{
+ wrap_alloc_struct(stream->allocator);
+ int ret = my->lzma_code(stream, a);
+ unwrap_alloc_struct(stream->allocator);
+ return ret;
+}
+
+EXPORT void my_lzma_end(x64emu_t* emu, lzma_stream_t* stream)
+{
+ wrap_alloc_struct(stream->allocator);
+ my->lzma_end(stream);
}
#define CUSTOM_INIT \
diff --git a/src/wrapped/wrappedlzma_private.h b/src/wrapped/wrappedlzma_private.h
index 3b82a07..6f8b476 100755..100644
--- a/src/wrapped/wrappedlzma_private.h
+++ b/src/wrapped/wrappedlzma_private.h
@@ -5,34 +5,34 @@
GOM(lzma_alone_decoder, iFEpU)
GOM(lzma_alone_encoder, iFEpp)
GO(lzma_auto_decoder, iFpUu)
-//GO(lzma_block_buffer_bound,
+GO(lzma_block_buffer_bound, LFL)
//GO(lzma_block_buffer_decode,
//GO(lzma_block_buffer_encode,
-//GO(lzma_block_compressed_size,
+GO(lzma_block_compressed_size, uFpL)
//GO(lzma_block_decoder,
//GO(lzma_block_encoder,
//GO(lzma_block_header_decode,
-//GO(lzma_block_header_encode,
-//GO(lzma_block_header_size,
-//GO(lzma_block_total_size,
-//GO(lzma_block_uncomp_encode,
+GO(lzma_block_header_encode, uFpp)
+GO(lzma_block_header_size, uFp)
+GO(lzma_block_total_size, LFp)
+GO(lzma_block_uncomp_encode, uFppLppL)
//GO(lzma_block_unpadded_size,
-GO(lzma_check_is_supported, iFi)
-//GO(lzma_check_size,
-GO(lzma_code, iFpi)
-//GO(lzma_cputhreads,
-//GO(lzma_crc32,
-//GO(lzma_crc64,
+GO(lzma_check_is_supported, CFu)
+GO(lzma_check_size, uFu)
+GOM(lzma_code, iFEpi)
+GO(lzma_cputhreads, uFv)
+GO(lzma_crc32, uFpLu)
+GO(lzma_crc64, LFpLL)
//GO(lzma_easy_buffer_encode,
-//GO(lzma_easy_decoder_memusage,
+GO(lzma_easy_decoder_memusage, LFu)
GOM(lzma_easy_encoder, iFEpui)
//GO(lzma_easy_encoder_memusage,
-GO(lzma_end, vFp)
-//GO(lzma_filter_decoder_is_supported,
+GOM(lzma_end, vFEp)
+GO(lzma_filter_decoder_is_supported, CFL)
//GO(lzma_filter_encoder_is_supported,
//GO(lzma_filter_flags_decode,
-//GO(lzma_filter_flags_encode,
-//GO(lzma_filter_flags_size,
+GO(lzma_filter_flags_encode, uFpppL)
+GO(lzma_filter_flags_size, uFpp)
//GO(lzma_filters_copy,
//GO(lzma_filters_update,
GO(lzma_get_check, iFp)
@@ -40,47 +40,47 @@ GO(lzma_get_check, iFp)
//GO(lzma_index_append,
//GO(lzma_index_block_count,
GOM(lzma_index_buffer_decode, iFEpppppL)
-//GO(lzma_index_buffer_encode,
+GO(lzma_index_buffer_encode, uFpppL)
//GO(lzma_index_cat,
-//GO(lzma_index_checks,
+GO(lzma_index_checks, uFp)
//GO(lzma_index_decoder,
//GO(lzma_index_dup,
//GO(lzma_index_encoder,
GOM(lzma_index_end, vFEpp)
//GO(lzma_index_file_size,
-//GO(lzma_index_hash_append,
-//GO(lzma_index_hash_decode,
+GO(lzma_index_hash_append, uFpLL)
+GO(lzma_index_hash_decode, uFpppL)
//GO(lzma_index_hash_end,
//GO(lzma_index_hash_init,
-//GO(lzma_index_hash_size,
+GO(lzma_index_hash_size, LFp)
//GO(lzma_index_init,
-//GO(lzma_index_iter_init,
-//GO(lzma_index_iter_locate,
-//GO(lzma_index_iter_next,
-//GO(lzma_index_iter_rewind,
-//GO(lzma_index_memusage,
-//GO(lzma_index_memused,
+GO(lzma_index_iter_init, vFpp)
+GO(lzma_index_iter_locate, CFpL)
+GO(lzma_index_iter_next, CFpu)
+GO(lzma_index_iter_rewind, vFp)
+GO(lzma_index_memusage, LFLL)
+GO(lzma_index_memused, LFp)
GO(lzma_index_size, UFp)
//GO(lzma_index_stream_count,
-//GO(lzma_index_stream_flags,
-//GO(lzma_index_stream_padding,
+GO(lzma_index_stream_flags, uFpp)
+GO(lzma_index_stream_padding, uFpL)
//GO(lzma_index_stream_size,
//GO(lzma_index_total_size,
-GO(lzma_index_uncompressed_size, UFp)
-GO(lzma_lzma_preset, iFpu)
+GO(lzma_index_uncompressed_size, LFp)
+GO(lzma_lzma_preset, CFpu)
//GO(lzma_memlimit_get,
//GO(lzma_memlimit_set,
-//GO(lzma_memusage,
-//GO(lzma_mf_is_supported,
-//GO(lzma_mode_is_supported,
-//GO(lzma_physmem,
+GO(lzma_memusage, UFp)
+GO(lzma_mf_is_supported, CFu)
+GO(lzma_mode_is_supported, CFu)
+GO(lzma_physmem, LFv)
GOM(lzma_properties_decode, iFEpppL)
-GO(lzma_properties_encode, iFpp)
+GO(lzma_properties_encode, uFpp)
GO(lzma_properties_size, iFpp)
//GO(lzma_raw_buffer_decode,
//GO(lzma_raw_buffer_encode,
GOM(lzma_raw_decoder, iFEpp)
-//GO(lzma_raw_decoder_memusage,
+GO(lzma_raw_decoder_memusage, LFp)
GOM(lzma_raw_encoder, iFEpp)
//GO(lzma_raw_encoder_memusage,
//GO(lzma_stream_buffer_bound,
@@ -88,15 +88,15 @@ GOM(lzma_stream_buffer_decode, iFEpupppLppL)
//GO(lzma_stream_buffer_encode,
GOM(lzma_stream_decoder, iFEpUi)
GOM(lzma_stream_encoder, iFEppi)
-//GO(lzma_stream_encoder_mt,
-//GO(lzma_stream_encoder_mt_memusage,
-//GO(lzma_stream_flags_compare,
-GO(lzma_stream_footer_decode, iFpp)
-//GO(lzma_stream_footer_encode,
+GOM(lzma_stream_encoder_mt, iFEpp)
+GO(lzma_stream_encoder_mt_memusage, LFp)
+GO(lzma_stream_flags_compare, uFpp)
+GO(lzma_stream_footer_decode, uFpp)
+GO(lzma_stream_footer_encode, uFpp)
//GO(lzma_stream_header_decode,
//GO(lzma_stream_header_encode,
//GO(lzma_version_number,
-//GO(lzma_version_string,
-//GO(lzma_vli_decode,
-//GO(lzma_vli_encode,
-//GO(lzma_vli_size,
+GO(lzma_version_string, pFv)
+GO(lzma_vli_decode, uFppppL)
+GO(lzma_vli_encode, uFLpppL)
+GO(lzma_vli_size, uFL)
diff --git a/src/wrapped/wrappedmpg123.c b/src/wrapped/wrappedmpg123.c
index 80d80cc..5b95749 100755..100644
--- a/src/wrapped/wrappedmpg123.c
+++ b/src/wrapped/wrappedmpg123.c
@@ -38,7 +38,7 @@ GO(4)
static uintptr_t my_r_read_fct_##A = 0; \
static ssize_t my_r_read_##A(void* a, void* b, size_t n) \
{ \
- return (ssize_t)RunFunction(my_context, my_r_read_fct_##A, 3, a, b, n); \
+ return (ssize_t)RunFunctionFmt(my_r_read_fct_##A, "ppL", a, b, n); \
}
SUPER()
#undef GO
@@ -60,7 +60,7 @@ static void* find_r_read_Fct(void* fct)
static uintptr_t my_r_lseek_fct_##A = 0; \
static int64_t my_r_lseek_##A(void* a, int64_t b, int n) \
{ \
- return (int64_t)RunFunction(my_context, my_r_lseek_fct_##A, 3, a, b, n); \
+ return (int64_t)RunFunctionFmt(my_r_lseek_fct_##A, "pIi", a, b, n); \
}
SUPER()
#undef GO
@@ -82,7 +82,7 @@ static void* find_r_lseek_Fct(void* fct)
static uintptr_t my_cleanup_fct_##A = 0; \
static void my_cleanup_##A(void* a) \
{ \
- RunFunction(my_context, my_cleanup_fct_##A, 1, a); \
+ RunFunctionFmt(my_cleanup_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -107,11 +107,6 @@ EXPORT int my_mpg123_replace_reader_handle(x64emu_t* emu, void* mh, void* r_read
return my->mpg123_replace_reader_handle(mh, find_r_read_Fct(r_read), find_r_lseek_Fct(r_lseek), find_cleanup_Fct(cleanup));
}
-EXPORT int my_mpg123_replace_reader_handle_32(x64emu_t* emu, void* mh, void* r_read, void* r_lseek, void* cleanup)
-{
- return my->mpg123_replace_reader_handle_32(mh, find_r_read_Fct(r_read), find_r_lseek_Fct(r_lseek), find_cleanup_Fct(cleanup));
-}
-
EXPORT int my_mpg123_replace_reader_handle_64(x64emu_t* emu, void* mh, void* r_read, void* r_lseek, void* cleanup)
{
return my->mpg123_replace_reader_handle_64(mh, find_r_read_Fct(r_read), find_r_lseek_Fct(r_lseek), find_cleanup_Fct(cleanup));
diff --git a/src/wrapped/wrappedmpg123_private.h b/src/wrapped/wrappedmpg123_private.h
index 9633cae..76d94aa 100755..100644
--- a/src/wrapped/wrappedmpg123_private.h
+++ b/src/wrapped/wrappedmpg123_private.h
@@ -4,136 +4,118 @@
//GO(mpg123_add_string,
//GO(mpg123_add_substring,
-//GO(mpg123_chomp_string,
-//GO(mpg123_clip,
+GO(mpg123_chomp_string, iFp)
+GO(mpg123_clip, lFp)
GO(mpg123_close, iFp)
//GO(mpg123_copy_string,
-//GO(mpg123_current_decoder,
-//GO(mpg123_decode,
+GO(mpg123_current_decoder, pFp)
+GO(mpg123_decode, iFppLpLp)
GO(mpg123_decode_frame, iFpppp)
-GO(mpg123_decode_frame_32, iFpppp)
GO(mpg123_decode_frame_64, iFpppp)
-GO(mpg123_decoder, iFppLpLp)
+GO(mpg123_decoder, iFpp)
//GO(mpg123_decoders,
GO(mpg123_delete, vFp)
-//GO(mpg123_delete_pars,
-//GO(mpg123_enc_from_id3,
+GO(mpg123_delete_pars, vFp)
+GO(mpg123_enc_from_id3, iFC)
GO(mpg123_encodings, vFpp)
GO(mpg123_encsize, iFi)
-//GO(mpg123_eq,
+GO(mpg123_eq, iFpiid)
GO(mpg123_errcode, iFp)
GO(mpg123_exit, vFv)
GO(mpg123_feature, iFi)
+GO(mpg123_feature2, iFi)
GO(mpg123_feed, iFppL)
-GO(mpg123_feedseek, IFpIip) // Warning, off_t is 64bits!
-GO(mpg123_feedseek_32, IFpIip)
+GO(mpg123_feedseek, lFplip)
GO(mpg123_feedseek_64, IFpIip)
-//GO(mpg123_fmt,
-//GO(mpg123_fmt_all,
-//GO(mpg123_fmt_none,
-//GO(mpg123_fmt_support,
+GO(mpg123_fmt, iFplii)
+GO(mpg123_fmt_all, iFp)
+GO(mpg123_fmt_none, iFp)
+GO(mpg123_fmt_support, iFpli)
GO(mpg123_format, iFplii)
GO(mpg123_format_all, iFp)
GO(mpg123_format_none, iFp)
GO(mpg123_format_support, iFpli)
GO(mpg123_framebyframe_decode, iFpppp)
-GO(mpg123_framebyframe_decode_32, iFpppp)
GO(mpg123_framebyframe_decode_64, iFpppp)
GO(mpg123_framebyframe_next, iFp)
GO(mpg123_framedata, iFpppp)
GO(mpg123_framelength, IFp)
-GO(mpg123_framelength_32, IFp)
GO(mpg123_framelength_64, IFp)
GO(mpg123_framepos, IFp)
-GO(mpg123_framepos_32, IFp)
GO(mpg123_framepos_64, IFp)
-//GO(mpg123_free_string,
-//GO(mpg123_geteq,
+GO(mpg123_free_string, vFp)
+GO(mpg123_geteq, dFpii)
GO(mpg123_getformat, iFpppp)
GO(mpg123_getformat2, iFppppi)
-//GO(mpg123_getpar,
+GO(mpg123_getpar, iFpipp)
GO(mpg123_getparam, iFpipp)
-//GO(mpg123_getstate,
-//GO(mpg123_getvolume,
-//GO(mpg123_grow_string,
-//GO(mpg123_icy,
-//GO(mpg123_icy2utf8,
-//GO(mpg123_id3,
+GO(mpg123_getparam2, iFpipp)
+GO(mpg123_getstate, iFpipp)
+GO(mpg123_getvolume, iFpppp)
+GO(mpg123_grow_string, iFpL)
+GO(mpg123_icy, iFpp)
+GO(mpg123_icy2utf8, pFp)
+GO(mpg123_id3, iFppp)
GO(mpg123_index, iFpppp)
-GO(mpg123_index_32, iFpppp)
GO(mpg123_index_64, iFpppp)
-//GO(mpg123_info,
+GO(mpg123_info, iFpp)
GO(mpg123_init, iFv)
//GO(mpg123_init_string,
-GO(mpg123_length, IFp)
-GO(mpg123_length_32, IFp)
+GO(mpg123_length, lFp)
GO(mpg123_length_64, IFp)
-//GO(mpg123_meta_check,
-//GO(mpg123_meta_free,
+GO(mpg123_meta_check, iFp)
+GO(mpg123_meta_free, vFp)
GO(mpg123_new, pFpp)
-//GO(mpg123_new_pars,
+GO(mpg123_new_pars, pFp)
GO(mpg123_open, iFpp)
-GO(mpg123_open_32, iFpp)
GO(mpg123_open_64, iFpp)
GO(mpg123_open_fd, iFpi)
-GO(mpg123_open_fd_32, iFpi)
GO(mpg123_open_fd_64, iFpi)
GO(mpg123_open_feed, iFp)
GO(mpg123_open_handle, iFpp)
-GO(mpg123_open_handle_32, iFpp)
GO(mpg123_open_handle_64, iFpp)
-//GO(mpg123_outblock,
-//GO(mpg123_par,
+GO(mpg123_outblock, LFp)
+GO(mpg123_par, iFpild)
GO(mpg123_param, iFpild)
-//GO(mpg123_parnew,
+GO(mpg123_param2, iFpild)
+GO(mpg123_parnew, pFppp)
GO(mpg123_plain_strerror, pFi)
-GO(mpg123_position, iFpIIpppp)
-GO(mpg123_position_32, iFpIIpppp)
+GO(mpg123_position, iFpllpppp)
GO(mpg123_position_64, iFpIIpppp)
GO(mpg123_rates, vFpp)
-GO(mpg123_read, iFppp)
-//GO(mpg123_replace_buffer,
+GO(mpg123_read, iFppLp)
+GO(mpg123_replace_buffer, iFppL)
//GO(mpg123_replace_reader,
-//GO(mpg123_replace_reader_32,
//GO(mpg123_replace_reader_64,
GOM(mpg123_replace_reader_handle, iFEpppp)
-GOM(mpg123_replace_reader_handle_32, iFEpppp)
GOM(mpg123_replace_reader_handle_64, iFEpppp)
//GO(mpg123_reset_eq,
//GO(mpg123_resize_string,
-//GO(mpg123_safe_buffer,
+GO(mpg123_safe_buffer, LFv)
//GO(mpg123_scan,
GO(mpg123_seek, IFpIi)
-GO(mpg123_seek_32, IFpIi)
GO(mpg123_seek_64, IFpIi)
-GO(mpg123_seek_frame, IFpIi)
-GO(mpg123_seek_frame_32, IFpIi)
+GO(mpg123_seek_frame, lFpli)
GO(mpg123_seek_frame_64, IFpIi)
-GO(mpg123_set_filesize, iFpI)
-GO(mpg123_set_filesize_32, iFpI)
+GO(mpg123_set_filesize, iFpl)
GO(mpg123_set_filesize_64, iFpI)
-GO(mpg123_set_index, iFppIL)
-GO(mpg123_set_index_32, iFppIL)
+GO(mpg123_set_index, iFpplL)
GO(mpg123_set_index_64, iFppIL)
-//GO(mpg123_set_string,
-//GO(mpg123_set_substring,
+GO(mpg123_set_string, iFpp)
+GO(mpg123_set_substring, iFppLL)
//GO(mpg123_spf,
-//GO(mpg123_store_utf8,
+GO(mpg123_store_utf8, iFpipL)
GO(mpg123_strerror, pFp)
-//GO(mpg123_strlen,
-//GO(mpg123_supported_decoders,
+GO(mpg123_strlen, LFpi)
+GO(mpg123_supported_decoders, pFv)
GO(mpg123_tell, IFp)
-GO(mpg123_tell_32, IFp)
GO(mpg123_tell_64, IFp)
GO(mpg123_tellframe, IFp)
-GO(mpg123_tellframe_32, IFp)
GO(mpg123_tellframe_64, IFp)
GO(mpg123_tell_stream, IFp)
-GO(mpg123_tell_stream_32, IFp)
GO(mpg123_tell_stream_64, IFp)
-GO(mpg123_timeframe, IFpd)
-GO(mpg123_timeframe_32, IFpd)
+GO(mpg123_timeframe, lFpd)
GO(mpg123_timeframe_64, IFpd)
-//GO(mpg123_tpf,
+GO(mpg123_tpf, dFp)
//GO(mpg123_volume,
-//GO(mpg123_volume_change,
+GO(mpg123_volume_change, iFpd)
diff --git a/src/wrapped/wrappednsl.c b/src/wrapped/wrappednsl.c
index fd2c287..fd2c287 100755..100644
--- a/src/wrapped/wrappednsl.c
+++ b/src/wrapped/wrappednsl.c
diff --git a/src/wrapped/wrappednsl_private.h b/src/wrapped/wrappednsl_private.h
index f0c538b..f0c538b 100755..100644
--- a/src/wrapped/wrappednsl_private.h
+++ b/src/wrapped/wrappednsl_private.h
diff --git a/src/wrapped/wrappednspr4.c b/src/wrapped/wrappednspr4.c
index 07240fc..07240fc 100755..100644
--- a/src/wrapped/wrappednspr4.c
+++ b/src/wrapped/wrappednspr4.c
diff --git a/src/wrapped/wrappednspr4_private.h b/src/wrapped/wrappednspr4_private.h
index 9a02d1c..47100da 100755..100644
--- a/src/wrapped/wrappednspr4_private.h
+++ b/src/wrapped/wrappednspr4_private.h
@@ -2,117 +2,119 @@
#error Meh....
#endif
+// typedef PRUint32 PRIntervalTime;
+
//GO(GetExecutionEnvironment,
//GO(libVersionPoint,
//GO(LL_MaxInt,
//GO(LL_MaxUint,
//GO(LL_MinInt,
-//GO(LL_Zero,
+GO(LL_Zero, lFv)
//GO(PR_Abort,
//GO(PR_Accept,
//GO(PR_AcceptRead,
-//GO(PR_Access,
+GO(PR_Access, iFpu)
//GO(PR_AddToCounter,
//GO(PR_AddWaitFileDesc,
//GO(PR_AllocFileDesc,
-//GO(PR_Assert,
-//GO(PR_AssertCurrentThreadInMonitor,
-//GO(PR_AssertCurrentThreadOwnsLock,
-//GO(PR_AtomicAdd,
-//GO(PR_AtomicDecrement,
+GO(PR_Assert, vFppi)
+GO(PR_AssertCurrentThreadInMonitor, vFp)
+GO(PR_AssertCurrentThreadOwnsLock, vFp)
+GO(PR_AtomicAdd, iFpi)
+GO(PR_AtomicDecrement, iFp)
//GO(PR_AtomicIncrement,
//GO(PR_AtomicSet,
-//GO(PR_AttachSharedMemory,
+GO(PR_AttachSharedMemory, pFpi)
//GO(PR_AttachThread,
//GO(PR_Available,
//GO(PR_Available64,
//GO(PR_Bind,
//GO(PR_BlockClockInterrupts,
//GO(PR_BlockInterrupt,
-//GO(PR_Calloc,
+GO(PR_Calloc, pFuu)
//GO(PR_CallOnce,
//GO(PR_CallOnceWithArg,
//GO(PR_CancelJob,
//GO(PR_CancelWaitFileDesc,
//GO(PR_CancelWaitGroup,
//GO(PR_CeilingLog2,
-//GO(PR_CEnterMonitor,
+GO(PR_CEnterMonitor, pFp)
//GO(PR_CExitMonitor,
//GO(PR_ChangeFileDescNativeHandle,
-//GO(PR_Cleanup,
+GO(PR_Cleanup, iFv)
//GO(PR_ClearInterrupt,
//GO(PR_ClearThreadGCAble,
GO(PR_Close, iFp)
-//GO(PR_CloseDir,
-//GO(PR_CloseFileMap,
-//GO(PR_CloseSemaphore,
-//GO(PR_CloseSharedMemory,
+GO(PR_CloseDir, iFp)
+GO(PR_CloseFileMap, iFp)
+GO(PR_CloseSemaphore, iFp)
+GO(PR_CloseSharedMemory, iFp)
//GO(PR_CNotify,
-//GO(PR_CNotifyAll,
-//GO(PR_cnvtf,
+GO(PR_CNotifyAll, iFp)
+GO(PR_cnvtf, vFpiid)
//GO(PR_Connect,
//GO(PR_ConnectContinue,
-//GO(PR_ConvertIPv4AddrToIPv6,
+GO(PR_ConvertIPv4AddrToIPv6, vFup)
//GO(PR_CreateAlarm,
//GO(PR_CreateCounter,
//GO(PR_CreateFileMap,
//GO(PR_CreateIOLayer,
//GO(PR_CreateIOLayerStub,
-//GO(PR_CreateMWaitEnumerator,
+GO(PR_CreateMWaitEnumerator, pFp)
//GO(PR_CreateOrderedLock,
-//GO(PR_CreatePipe,
-//GO(PR_CreateProcess,
-//GO(PR_CreateProcessDetached,
+GO(PR_CreatePipe, iFpp)
+GO(PR_CreateProcess, pFpppp)
+GO(PR_CreateProcessDetached, iFpppp)
//GO(PR_CreateSocketPollFd,
-//GO(PR_CreateStack,
+GO(PR_CreateStack, pFp)
//GO(PR_CreateThread,
//GO(PR_CreateThreadGCAble,
-//GO(PR_CreateThreadPool,
-//GO(PR_CreateTrace,
-//GO(PR_CreateWaitGroup,
+GO(PR_CreateThreadPool, pFiiu)
+GO(PR_CreateTrace, pFppp)
+GO(PR_CreateWaitGroup, pFi)
//GO(PR_CSetOnMonitorRecycle,
-//GO(PR_CWait,
+GO(PR_CWait, iFpu)
//GO(PR_DecrementCounter,
//GO(PR_Delete,
//GO(PR_DeleteSemaphore,
-//GO(PR_DeleteSharedMemory,
+GO(PR_DeleteSharedMemory, iFp)
//GO(PR_DestroyAlarm,
-//GO(PR_DestroyCondVar,
+GO(PR_DestroyCondVar, vFp)
//GO(PR_DestroyCounter,
//GO(PR_DestroyLock,
//GO(PR_DestroyMonitor,
-//GO(PR_DestroyMWaitEnumerator,
+GO(PR_DestroyMWaitEnumerator, iFp)
//GO(PR_DestroyOrderedLock,
//GO(PR_DestroyPollableEvent,
-//GO(PR_DestroyProcessAttr,
+GO(PR_DestroyProcessAttr, vFp)
//GO(PR_DestroyRWLock,
//GO(PR_DestroySem,
//GO(PR_DestroySocketPollFd,
-//GO(PR_DestroyStack,
-//GO(PR_DestroyTrace,
-//GO(PR_DestroyWaitGroup,
+GO(PR_DestroyStack, iFp)
+GO(PR_DestroyTrace, vFp)
+GO(PR_DestroyWaitGroup, iFp)
//GO(PR_DetachProcess,
-//GO(PR_DetachSharedMemory,
+GO(PR_DetachSharedMemory, iFpp)
GO(PR_DetachThread, vFv)
//GO(PR_DisableClockInterrupts,
-//GO(PR_dtoa,
-//GO(PR_DuplicateEnvironment,
+GO(PR_dtoa, iFdiippppL)
+GO(PR_DuplicateEnvironment, pFv)
GO(PR_EmulateAcceptRead, iFppppiu)
GO(PR_EmulateSendFile, iFppiu)
//GO(PR_EnableClockInterrupts,
//GO(PR_EnterMonitor,
-//GO(PR_EnumerateAddrInfo,
-//GO(PR_EnumerateHostEnt,
+GO(PR_EnumerateAddrInfo, pFppWp)
+GO(PR_EnumerateHostEnt, iFipWp)
//GO(PR_EnumerateThreads,
//GO(PR_EnumerateWaitGroup,
//GO(PR_ErrorInstallCallback,
-//GO(PR_ErrorInstallTable,
-//GO(PR_ErrorLanguages,
-//GO(PR_ErrorToName,
-//GO(PR_ErrorToString,
+GO(PR_ErrorInstallTable, iFp)
+GO(PR_ErrorLanguages, pFv)
+GO(PR_ErrorToName, pFi)
+GO(PR_ErrorToString, pFiu)
//GO(PR_ExitMonitor,
//GO(PR_ExplodeTime,
-//GO(PR_ExportFileMapAsString,
+GO(PR_ExportFileMapAsString, iFpLp)
//GO(PR_FD_CLR,
//GO(PR_FD_ISSET,
//GO(PR_FD_NCLR,
@@ -121,29 +123,29 @@ GO(PR_EmulateSendFile, iFppiu)
//GO(PR_FD_SET,
//GO(PR_FD_ZERO,
//GO(PR_FileDesc2NativeHandle,
-//GO(PR_FindFunctionSymbol,
-//GO(PR_FindFunctionSymbolAndLibrary,
+GO(PR_FindFunctionSymbol, pFpp)
+GO(PR_FindFunctionSymbolAndLibrary, pFpp)
//GO(PR_FindNextCounterQname,
//GO(PR_FindNextCounterRname,
-//GO(PR_FindNextTraceQname,
-//GO(PR_FindNextTraceRname,
-//GO(PR_FindSymbol,
-//GO(PR_FindSymbolAndLibrary,
-//GO(PR_FloorLog2,
-//GO(PR_FormatTime,
-//GO(PR_FormatTimeUSEnglish,
+GO(PR_FindNextTraceQname, pFp)
+GO(PR_FindNextTraceRname, pFpp)
+GO(PR_FindSymbol, pFpp)
+GO(PR_FindSymbolAndLibrary, pFpp)
+GO(PR_FloorLog2, iFu)
+GO(PR_FormatTime, uFpipp)
+GO(PR_FormatTimeUSEnglish, uFpupp)
//GO(PR_fprintf,
//GO(PR_FPrintZoneStats,
-//GO(PR_Free,
-//GO(PR_FreeAddrInfo,
+GO(PR_Free, vFp)
+GO(PR_FreeAddrInfo, vFp)
//GO(PR_FreeLibraryName,
-//GO(PR_GetAddrInfoByName,
-//GO(PR_GetCanonNameFromAddrInfo,
+GO(PR_GetAddrInfoByName, pFpWi)
+GO(PR_GetCanonNameFromAddrInfo, pFp)
//GO(PR_GetConnectStatus,
//GO(PR_GetCounter,
//GO(PR_GetCounterHandleFromName,
//GO(PR_GetCounterNameFromHandle,
-//GO(PR_GetCurrentThread,
+GO(PR_GetCurrentThread, pFv)
//GO(PR_GetDefaultIOMethods,
//GO(PR_GetDescType,
//GO(PR_GetDirectorySeparator,
@@ -151,88 +153,88 @@ GO(PR_EmulateSendFile, iFppiu)
//GO(PR_GetEnv,
//GO(PR_GetEnvSecure,
GO(PR_GetError, iFv)
-//GO(PR_GetErrorText,
-//GO(PR_GetErrorTextLength,
-//GO(PR_GetFileInfo,
-//GO(PR_GetFileInfo64,
+GO(PR_GetErrorText, iFp)
+GO(PR_GetErrorTextLength, iFv)
+GO(PR_GetFileInfo, iFpp)
+GO(PR_GetFileInfo64, iFpp)
//GO(PR_GetFileMethods,
//GO(PR_GetGCRegisters,
-//GO(PR_GetHostByAddr,
-//GO(PR_GetHostByName,
+GO(PR_GetHostByAddr, iFppip)
+GO(PR_GetHostByName, iFppip)
//GO(PR_GetIdentitiesLayer,
//GO(PR_GetInheritedFD,
//GO(PR_GetInheritedFileMap,
-//GO(PR_GetIPNodeByName,
+GO(PR_GetIPNodeByName, iFpWipip)
//GO(PR_GetLayersIdentity,
//GO(PR_GetLibraryFilePathname,
-//GO(PR_GetLibraryName,
-//GO(PR_GetLibraryPath,
+GO(PR_GetLibraryName, pFpp)
+GO(PR_GetLibraryPath, pFv)
//GO(PR_GetMemMapAlignment,
//GO(PR_GetMonitorEntryCount,
-//GO(PR_GetNameForIdentity,
-//GO(PR_GetNumberOfProcessors,
+GO(PR_GetNameForIdentity, pFi)
+GO(PR_GetNumberOfProcessors, iFv)
//GO(PR_GetOpenFileInfo,
//GO(PR_GetOpenFileInfo64,
-//GO(PR_GetOSError,
+GO(PR_GetOSError, iFv)
//GO(PR_GetPageShift,
//GO(PR_GetPageSize,
-//GO(PR_GetPathSeparator,
+GO(PR_GetPathSeparator, cFv)
//GO(PR_GetPeerName,
-//GO(PR_GetPhysicalMemorySize,
+GO(PR_GetPhysicalMemorySize, LFv)
//GO(PR_GetPipeMethods,
-//GO(PR_GetProtoByName,
-//GO(PR_GetProtoByNumber,
-//GO(PR_GetRandomNoise,
+GO(PR_GetProtoByName, iFppip)
+GO(PR_GetProtoByNumber, iFipip)
+GO(PR_GetRandomNoise, LFpL)
//GO(PR_GetSocketOption,
//GO(PR_GetSockName,
//GO(PR_GetSP,
//GO(PR_GetSpecialFD,
//GO(PR_GetStackSpaceLeft,
//GO(PR_GetSysfdTableMax,
-//GO(PR_GetSystemInfo,
+GO(PR_GetSystemInfo, iFupu)
//GO(PR_GetTCPMethods,
//GO(PR_GetThreadAffinityMask,
//GO(PR_GetThreadID,
-//GO(PR_GetThreadName,
-//GO(PR_GetThreadPriority,
-//GO(PR_GetThreadPrivate,
-//GO(PR_GetThreadScope,
-//GO(PR_GetThreadState,
-//GO(PR_GetThreadType,
-//GO(PR_GetTraceEntries,
-//GO(PR_GetTraceHandleFromName,
-//GO(PR_GetTraceNameFromHandle,
-//GO(PR_GetTraceOption,
+GO(PR_GetThreadName, pFp)
+GO(PR_GetThreadPriority, uFp)
+GO(PR_GetThreadPrivate, pFu)
+GO(PR_GetThreadScope, uFp)
+GO(PR_GetThreadState, uFp)
+GO(PR_GetThreadType, uFp)
+GO(PR_GetTraceEntries, iFpip)
+GO(PR_GetTraceHandleFromName, pFpp)
+GO(PR_GetTraceNameFromHandle, vFpppp)
+GO(PR_GetTraceOption, vFup)
//GO(PR_GetUDPMethods,
-//GO(PR_GetUniqueIdentity,
-//GO(PR_GetVersion,
+GO(PR_GetUniqueIdentity, iFp)
+GO(PR_GetVersion, pFv)
//GO(PR_GMTParameters,
-//GO(PR_htonl,
-//GO(PR_htonll,
-//GO(PR_htons,
-//GO(PR_ImplodeTime,
+GO(PR_htonl, uFu)
+GO(PR_htonll, LFL)
+GO(PR_htons, WFW)
+GO(PR_ImplodeTime, lFp)
//GO(PR_ImportFile,
-//GO(PR_ImportFileMapFromString,
+GO(PR_ImportFileMapFromString, pFp)
//GO(PR_ImportPipe,
GO(PR_ImportTCPSocket, pFi)
//GO(PR_ImportUDPSocket,
//GO(PR_IncrementCounter,
-GO(PR_Init, vFiii)
+GO(PR_Init, vFuuu)
//GO(PR_Initialize,
GO(PR_Initialized, iFv)
-//GO(PR_InitializeNetAddr,
-//GO(PR_Interrupt,
-//GO(PR_IntervalNow,
-//GO(PR_IntervalToMicroseconds,
-//GO(PR_IntervalToMilliseconds,
+GO(PR_InitializeNetAddr, iFuWp)
+GO(PR_Interrupt, iFp)
+GO(PR_IntervalNow, uFv)
+GO(PR_IntervalToMicroseconds, uFu)
+GO(PR_IntervalToMilliseconds, uFu)
//GO(PR_IntervalToSeconds,
-//GO(PR_IsNetAddrType,
-//GO(PR_JoinJob,
+GO(PR_IsNetAddrType, iFpu)
+GO(PR_JoinJob, iFp)
//GO(PR_JoinThread,
-//GO(PR_JoinThreadPool,
-//GO(PR_KillProcess,
+GO(PR_JoinThreadPool, iFp)
+GO(PR_KillProcess, iFp)
//GO(PR_Listen,
-//GO(PR_LoadLibrary,
+//GO(PR_LoadLibrary, pFp) // needs wrapping
//GO(PR_LoadLibraryWithFlags,
//GO(PR_LoadStaticLibrary,
//GO(PR_LocalTimeParameters,
@@ -241,46 +243,46 @@ GO(PR_Initialized, iFv)
//GO(PR_LockOrderedLock,
//GO(PR_LogFlush,
//GO(PR_LogPrint,
-//GO(PR_MakeDir,
-//GO(PR_Malloc,
-//GO(PR_MemMap,
-//GO(PR_MemUnmap,
-//GO(PR_MicrosecondsToInterval,
+GO(PR_MakeDir, iFpi)
+GO(PR_Malloc, pFu)
+//GO(PR_MemMap, pFplu) // needs wrapping
+//GO(PR_MemUnmap, iFpu) // needs wrapping
+GO(PR_MicrosecondsToInterval, uFu)
//GO(PR_MillisecondsToInterval,
//GO(PR_MkDir,
-//GO(PR_NetAddrToString,
-//GO(PR_NewCondVar,
-//GO(PR_NewLock,
-//GO(PR_NewLogModule,
-//GO(PR_NewMonitor,
+GO(PR_NetAddrToString, iFppu)
+GO(PR_NewCondVar, pFp)
+GO(PR_NewLock, pFv)
+GO(PR_NewLogModule, pFp)
+GO(PR_NewMonitor, pFv)
//GO(PR_NewNamedMonitor,
//GO(PR_NewPollableEvent,
-//GO(PR_NewProcessAttr,
-//GO(PR_NewRWLock,
+GO(PR_NewProcessAttr, pFv)
+GO(PR_NewRWLock, pFup)
//GO(PR_NewSem,
//GO(PR_NewTCPSocket,
-//GO(PR_NewTCPSocketPair,
+GO(PR_NewTCPSocketPair, iFp)
//GO(PR_NewThreadPrivateIndex,
//GO(PR_NewUDPSocket,
//GO(PR_NormalizeTime,
//GO(PR_Notify,
-//GO(PR_NotifyAll,
-//GO(PR_NotifyAllCondVar,
+GO(PR_NotifyAll, iFp)
+GO(PR_NotifyAllCondVar, iFp)
//GO(PR_NotifyCondVar,
-GO(PR_Now, pFv)
+GO(PR_Now, lFv)
//GO(PR_ntohl,
//GO(PR_ntohll,
//GO(PR_ntohs,
//GO(PR_Open,
-//GO(PR_OpenAnonFileMap,
-//GO(PR_OpenDir,
+GO(PR_OpenAnonFileMap, pFpLu)
+GO(PR_OpenDir, pFp)
//GO(PR_OpenFile,
-//GO(PR_OpenSemaphore,
-//GO(PR_OpenSharedMemory,
+GO(PR_OpenSemaphore, pFpiiu)
+GO(PR_OpenSharedMemory, pFpLii)
//GO(PR_OpenTCPSocket,
//GO(PR_OpenUDPSocket,
-//GO(PR_ParseTimeString,
-//GO(PR_ParseTimeStringToExplodedTime,
+GO(PR_ParseTimeString, iFpip)
+GO(PR_ParseTimeStringToExplodedTime, iFpip)
//GO(PRP_DestroyNakedCondVar,
//GO(PRP_NakedBroadcast,
//GO(PRP_NakedNotify,
@@ -290,9 +292,9 @@ GO(PR_Now, pFv)
//GO(PR_PopIOLayer,
//GO(PR_PostSem,
//GO(PR_PostSemaphore,
-//GO(PR_ProcessAttrSetCurrentDirectory,
+GO(PR_ProcessAttrSetCurrentDirectory, iFpp)
//GO(PR_ProcessAttrSetInheritableFD,
-//GO(PR_ProcessAttrSetInheritableFileMap,
+GO(PR_ProcessAttrSetInheritableFileMap, iFppp)
//GO(PR_ProcessAttrSetStdioRedirect,
//GO(PR_ProcessExit,
//GO(PRP_TryLock,
@@ -305,18 +307,18 @@ GO(PR_Now, pFv)
//GO(PR_QueueJob_Timer,
//GO(PR_QueueJob_Write,
GO(PR_Read, iFppi)
-//GO(PR_ReadDir,
-//GO(PR_Realloc,
-//GO(PR_RecordTraceEntries,
+GO(PR_ReadDir, pFpu)
+GO(PR_Realloc, pFpu)
+GO(PR_RecordTraceEntries, vFv)
//GO(PR_Recv,
//GO(PR_RecvFrom,
-//GO(PR_Rename,
+GO(PR_Rename, iFpp)
//GO(PR_ResetAlarm,
//GO(PR_ResetProcessAttr,
//GO(PR_ResumeAll,
//GO(PR_RmDir,
//GO(PR_RWLock_Rlock,
-//GO(PR_RWLock_Unlock,
+GO(PR_RWLock_Unlock, vFp)
//GO(PR_RWLock_Wlock,
//GO(PR_ScanStackPointers,
//GO(PR_SecondsToInterval,
@@ -327,18 +329,18 @@ GO(PR_Read, iFppi)
//GO(PR_SendFile,
//GO(PR_SendTo,
//GO(PR_SetAlarm,
-//GO(PR_SetConcurrency,
+GO(PR_SetConcurrency, vFu)
//GO(PR_SetCounter,
//GO(PR_SetCurrentThreadName,
//GO(PR_SetEnv,
-//GO(PR_SetError,
-//GO(PR_SetErrorText,
-//GO(PR_SetFDCacheSize,
+GO(PR_SetError, vFii)
+GO(PR_SetErrorText, vFip)
+GO(PR_SetFDCacheSize, iFii)
//GO(PR_SetFDInheritable,
//GO(PR_SetLibraryPath,
-//GO(PR_SetLogBuffering,
-//GO(PR_SetLogFile,
-//GO(PR_SetNetAddr,
+GO(PR_SetLogBuffering, vFi)
+GO(PR_SetLogFile, iFp)
+GO(PR_SetNetAddr, iFuWWp)
//GO(PR_SetPollableEvent,
GO(PR_SetSocketOption, iFpp)
//GO(PR_SetStdioRedirect,
@@ -346,24 +348,24 @@ GO(PR_SetSocketOption, iFpp)
//GO(PR_SetThreadAffinityMask,
//GO(PR_SetThreadDumpProc,
//GO(PR_SetThreadGCAble,
-//GO(PR_SetThreadPriority,
-//GO(PR_SetThreadPrivate,
+GO(PR_SetThreadPriority, vFpu)
+GO(PR_SetThreadPrivate, iFup)
//GO(PR_SetThreadRecycleMode,
//GO(PR_SetTraceOption,
//GO(PR_Shutdown,
//GO(PR_ShutdownThreadPool,
-//GO(PR_Sleep,
+GO(PR_Sleep, iFu)
//GO(PR_smprintf,
-//GO(PR_smprintf_free,
+GO(PR_smprintf_free, vFp)
//GO(PR_snprintf,
//GO(PR_Socket,
//GO(PR_sprintf_append,
//GO(PR_sscanf,
-//GO(PR_StackPop,
-//GO(PR_StackPush,
+GO(PR_StackPop, pFp)
+GO(PR_StackPush, vFpp)
//GO(PR_Stat,
-//GO(PR_StringToNetAddr,
-//GO(PR_strtod,
+GO(PR_StringToNetAddr, iFpp)
+GO(PR_strtod, dFpp)
//GO(PR_SubtractFromCounter,
//GO(PR_SuspendAll,
//GO(PR_sxprintf,
@@ -371,27 +373,27 @@ GO(PR_SetSocketOption, iFpp)
//GO(PR_SyncMemMap,
//GO(_pr_test_ipv6_socket,
//GO(PR_ThreadScanStackPointers,
-//GO(PR_TicksPerSecond,
+GO(PR_TicksPerSecond, uFv)
//GO(PR_TLockFile,
-//GO(PR_Trace,
+GO(PR_Trace, vFpuuuuuuuu)
//GO(PR_TransmitFile,
//GO(PR_UnblockClockInterrupts,
//GO(PR_UnblockInterrupt,
-//GO(PR_UnloadLibrary,
-//GO(PR_Unlock,
+GO(PR_UnloadLibrary, iFp)
+GO(PR_Unlock, iFp)
//GO(PR_UnlockFile,
//GO(PR_UnlockOrderedLock,
//GO(PR_USPacificTimeParameters,
//GO(PR_VersionCheck,
//GO(PR_vfprintf,
-//GO(PR_vsmprintf,
-//GO(PR_vsnprintf,
-//GO(PR_vsprintf_append,
+GO(PR_vsmprintf, pFpp)
+GO(PR_vsnprintf, uFpupp)
+GO(PR_vsprintf_append, pFppp)
//GO(PR_vsxprintf,
-//GO(PR_Wait,
-//GO(PR_WaitCondVar,
+GO(PR_Wait, iFpu)
+GO(PR_WaitCondVar, iFpu)
//GO(PR_WaitForPollableEvent,
-//GO(PR_WaitProcess,
+GO(PR_WaitProcess, iFpp)
//GO(PR_WaitRecvReady,
//GO(PR_WaitSem,
//GO(PR_WaitSemaphore,
diff --git a/src/wrapped/wrappednss3.c b/src/wrapped/wrappednss3.c
index 2b10bb4..e64ac39 100755..100644
--- a/src/wrapped/wrappednss3.c
+++ b/src/wrapped/wrappednss3.c
@@ -37,7 +37,7 @@ GO(4)
static uintptr_t my_PK11PasswordFunc_fct_##A = 0; \
static void* my_PK11PasswordFunc_##A(void* a, int b, void* c) \
{ \
- return (void*)RunFunction(my_context, my_PK11PasswordFunc_fct_##A, 3, a, b, c); \
+ return (void*)RunFunctionFmt(my_PK11PasswordFunc_fct_##A, "pip", a, b, c); \
}
SUPER()
#undef GO
@@ -60,7 +60,7 @@ static void* find_PK11PasswordFunc_Fct(void* fct)
static uintptr_t my_CERT_StringFromCertFcn_fct_##A = 0; \
static void* my_CERT_StringFromCertFcn_##A(void* a) \
{ \
- return (void*)RunFunction(my_context, my_CERT_StringFromCertFcn_fct_##A, 1, a); \
+ return (void*)RunFunctionFmt(my_CERT_StringFromCertFcn_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -92,7 +92,7 @@ static void* reverse_CERT_StringFromCertFcn_Fct(library_t* lib, void* fct)
static uintptr_t my_CERTChainVerifyCallbackFunc_fct_##A = 0; \
static int my_CERTChainVerifyCallbackFunc_##A(void* a, void* b, void* c) \
{ \
- return (int)RunFunction(my_context, my_CERTChainVerifyCallbackFunc_fct_##A, 3, a, b, c); \
+ return (int)RunFunctionFmt(my_CERTChainVerifyCallbackFunc_fct_##A, "ppp", a, b, c); \
}
SUPER()
#undef GO
@@ -119,6 +119,28 @@ static void* reverse_CERTChainVerifyCallbackFunc_Fct(library_t* lib, void* fct)
#undef GO
return (void*)AddBridge(lib->w.bridge, iFppp, fct, 0, NULL);
}
+// PORTCharConversionWSwapFunc ...
+#define GO(A) \
+static uintptr_t my_PORTCharConversionWSwapFunc_fct_##A = 0; \
+static int my_PORTCharConversionWSwapFunc_##A(int a, void* b, uint32_t c, void* d, uint32_t e, void* f, int g) \
+{ \
+ return (int)RunFunctionFmt(my_PORTCharConversionWSwapFunc_fct_##A, "ipupupi", a, b, c, d, e, f, g); \
+}
+SUPER()
+#undef GO
+static void* find_PORTCharConversionWSwapFunc_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_PORTCharConversionWSwapFunc_fct_##A == (uintptr_t)fct) return my_PORTCharConversionWSwapFunc_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_PORTCharConversionWSwapFunc_fct_##A == 0) {my_PORTCharConversionWSwapFunc_fct_##A = (uintptr_t)fct; return my_PORTCharConversionWSwapFunc_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for nss3 PORTCharConversionWSwapFunc callback\n");
+ return NULL;
+}
#undef SUPER
@@ -179,6 +201,11 @@ EXPORT int my_CERT_PKIXVerifyCert(x64emu_t* emu, void* cert, int64_t usages, my_
return ret;
}
+EXPORT void my_PORT_SetUCS2_ASCIIConversionFunction(x64emu_t* emu, void* f)
+{
+ my->PORT_SetUCS2_ASCIIConversionFunction(find_PORTCharConversionWSwapFunc_Fct(f));
+}
+
#define CUSTOM_INIT \
getMy(lib);
diff --git a/src/wrapped/wrappednss3_private.h b/src/wrapped/wrappednss3_private.h
index bbe3dba..4571086 100755..100644
--- a/src/wrapped/wrappednss3_private.h
+++ b/src/wrapped/wrappednss3_private.h
@@ -7,291 +7,291 @@
// CK_ATTRIBUTE_TYPE is type ULong
// SECOidTag is an enum
-//GO(ATOB_AsciiToData,
-//GO(ATOB_ConvertAsciiToItem,
+GO(ATOB_AsciiToData, pFpp)
+GO(ATOB_ConvertAsciiToItem, iFpp)
//GO(BTOA_ConvertItemToAscii,
-//GO(BTOA_DataToAscii,
-//GO(CERT_AddCertToListHead,
+GO(BTOA_DataToAscii, pFpu)
+GO(CERT_AddCertToListHead, iFpp)
//GO(CERT_AddCertToListSorted,
-//GO(CERT_AddCertToListTail,
-//GO(CERT_AddExtension,
-//GO(CERT_AddExtensionByOID,
+GO(CERT_AddCertToListTail, iFpp)
+GO(CERT_AddExtension, iFpipii)
+GO(CERT_AddExtensionByOID, iFpppii)
//GO(CERT_AddOCSPAcceptableResponses,
-//GO(CERT_AddOKDomainName,
-//GO(CERT_AddRDN,
+GO(CERT_AddOKDomainName, iFpp)
+GO(CERT_AddRDN, iFpp)
//GO(__CERT_AddTempCertToPerm,
-//GO(CERT_AllocCERTRevocationFlags,
-//GO(CERT_AsciiToName,
+GO(CERT_AllocCERTRevocationFlags, pFuuuu)
+GO(CERT_AsciiToName, pFp)
//GO(CERT_CacheCRL,
-//GO(CERT_CacheOCSPResponseFromSideChannel,
-//GO(CERT_CertChainFromCert,
+GO(CERT_CacheOCSPResponseFromSideChannel, iFpplpp)
+GO(CERT_CertChainFromCert, pFpui)
//DATA(CERT_CertificateRequestTemplate,
DATA(CERT_CertificateTemplate, 480)
-//GO(CERT_CertListFromCert,
+GO(CERT_CertListFromCert, pFp)
//GO(CERT_CertTimesValid,
-//GO(CERT_ChangeCertTrust,
-//GO(CERT_CheckCertUsage,
-GO(CERT_CheckCertValidTimes, iFpIi)
-//GO(CERT_CheckNameSpace,
-//GO(CERT_CheckOCSPStatus,
-//GO(CERT_ClearOCSPCache,
+GO(CERT_ChangeCertTrust, iFppp)
+GO(CERT_CheckCertUsage, iFpC)
+GO(CERT_CheckCertValidTimes, uFpli)
+GO(CERT_CheckNameSpace, iFppp)
+GO(CERT_CheckOCSPStatus, iFpplp)
+GO(CERT_ClearOCSPCache, iFv)
//GO(__CERT_ClosePermCertDB,
-//GO(CERT_CompareAVA,
-//GO(CERT_CompareCerts,
-//GO(CERT_CompareName,
+GO(CERT_CompareAVA, iFpp)
+GO(CERT_CompareCerts, iFpp)
+GO(CERT_CompareName, iFpp)
//GO(CERT_CompareValidityTimes,
-//GO(CERT_CompleteCRLDecodeEntries,
-//GO(CERT_CopyName,
-//GO(CERT_CopyRDN,
-//GO(CERT_CreateAVA,
-//GO(CERT_CreateCertificate,
-//GO(CERT_CreateCertificateRequest,
-//GO(CERT_CreateEncodedOCSPErrorResponse,
-//GO(CERT_CreateEncodedOCSPSuccessResponse,
+GO(CERT_CompleteCRLDecodeEntries, iFp)
+GO(CERT_CopyName, iFppp)
+GO(CERT_CopyRDN, iFppp)
+GO(CERT_CreateAVA, pFpuip)
+GO(CERT_CreateCertificate, pFLppp)
+GO(CERT_CreateCertificateRequest, pFppp)
+GO(CERT_CreateEncodedOCSPErrorResponse, pFpi)
+GO(CERT_CreateEncodedOCSPSuccessResponse, pFppilpp)
//GO(CERT_CreateName,
-//GO(CERT_CreateOCSPCertID,
-//GO(CERT_CreateOCSPRequest,
+GO(CERT_CreateOCSPCertID, pFpl)
+GO(CERT_CreateOCSPRequest, pFplip)
//GO(CERT_CreateOCSPSingleResponseGood,
-//GO(CERT_CreateOCSPSingleResponseRevoked,
-//GO(CERT_CreateOCSPSingleResponseUnknown,
+GO(CERT_CreateOCSPSingleResponseRevoked, pFpplplp)
+GO(CERT_CreateOCSPSingleResponseUnknown, pFpplp)
//GO(CERT_CreateRDN,
-GO(CERT_CreateSubjectCertList, pFpppIi)
-GO(CERT_CreateValidity, pFII)
-//GO(CERT_CRLCacheRefreshIssuer,
+GO(CERT_CreateSubjectCertList, pFpppli)
+GO(CERT_CreateValidity, pFll)
+GO(CERT_CRLCacheRefreshIssuer, vFpp)
//DATA(CERT_CrlTemplate,
GO(CERT_DecodeAltNameExtension, pFpp)
-//GO(CERT_DecodeAuthInfoAccessExtension,
-//GO(CERT_DecodeAuthKeyID,
+GO(CERT_DecodeAuthInfoAccessExtension, pFpp)
+GO(CERT_DecodeAuthKeyID, pFpp)
GO(CERT_DecodeAVAValue, pFp)
-//GO(CERT_DecodeBasicConstraintValue,
+GO(CERT_DecodeBasicConstraintValue, iFpp)
GO(CERT_DecodeCertificatePoliciesExtension, pFp)
-//GO(CERT_DecodeCRLDistributionPoints,
+GO(CERT_DecodeCRLDistributionPoints, pFpp)
//GO(__CERT_DecodeDERCertificate,
-//GO(CERT_DecodeDERCrl,
-//GO(CERT_DecodeDERCrlWithFlags,
-//GO(CERT_DecodeGeneralName,
-//GO(CERT_DecodeNameConstraintsExtension,
-//GO(CERT_DecodeOCSPRequest,
-//GO(CERT_DecodeOCSPResponse,
-//GO(CERT_DecodeOidSequence,
-//GO(CERT_DecodePrivKeyUsagePeriodExtension,
-//GO(CERT_DecodeTrustString,
-//GO(CERT_DecodeUserNotice,
-//GO(CERT_DerNameToAscii,
-//GO(CERT_DestroyCertArray,
+GO(CERT_DecodeDERCrl, pFppi)
+GO(CERT_DecodeDERCrlWithFlags, pFppii)
+GO(CERT_DecodeGeneralName, pFppp)
+GO(CERT_DecodeNameConstraintsExtension, pFpp)
+GO(CERT_DecodeOCSPRequest, pFp)
+GO(CERT_DecodeOCSPResponse, pFp)
+GO(CERT_DecodeOidSequence, pFp)
+GO(CERT_DecodePrivKeyUsagePeriodExtension, pFpp)
+GO(CERT_DecodeTrustString, iFpp)
+GO(CERT_DecodeUserNotice, pFp)
+GO(CERT_DerNameToAscii, pFp)
+GO(CERT_DestroyCertArray, vFpu)
GO(CERT_DestroyCertificate, vFp)
GO(CERT_DestroyCertificateList, vFp)
GO(CERT_DestroyCertificatePoliciesExtension, vFp)
GO(CERT_DestroyCertificateRequest, vFp)
GO(CERT_DestroyCertList, vFp)
-//GO(CERT_DestroyCERTRevocationFlags,
-//GO(CERT_DestroyName,
-//GO(CERT_DestroyOCSPCertID,
-//GO(CERT_DestroyOCSPRequest,
-//GO(CERT_DestroyOCSPResponse,
-//GO(CERT_DestroyOidSequence,
-//GO(CERT_DestroyUserNotice,
+GO(CERT_DestroyCERTRevocationFlags, vFp)
+GO(CERT_DestroyName, vFp)
+GO(CERT_DestroyOCSPCertID, iFp)
+GO(CERT_DestroyOCSPRequest, vFp)
+GO(CERT_DestroyOCSPResponse, vFp)
+GO(CERT_DestroyOidSequence, vFp)
+GO(CERT_DestroyUserNotice, vFp)
GO(CERT_DestroyValidity, vFp)
//GO(CERT_DisableOCSPChecking,
-//GO(CERT_DisableOCSPDefaultResponder,
-//GO(CERT_DistNamesFromCertList,
+GO(CERT_DisableOCSPDefaultResponder, iFp)
+GO(CERT_DistNamesFromCertList, pFp)
GO(CERT_DupCertificate, pFp)
-//GO(CERT_DupCertList,
-//GO(CERT_DupDistNames,
+GO(CERT_DupCertList, pFp)
+GO(CERT_DupDistNames, pFp)
//GO(CERT_EnableOCSPChecking,
//GO(CERT_EnableOCSPDefaultResponder,
-//GO(CERT_EncodeAltNameExtension,
-//GO(CERT_EncodeAndAddBitStrExtension,
-//GO(CERT_EncodeAuthKeyID,
-//GO(CERT_EncodeBasicConstraintValue,
-//GO(CERT_EncodeCertPoliciesExtension,
-//GO(CERT_EncodeCRLDistributionPoints,
-//GO(CERT_EncodeGeneralName,
-//GO(CERT_EncodeInfoAccessExtension,
-//GO(CERT_EncodeInhibitAnyExtension,
+GO(CERT_EncodeAltNameExtension, iFppp)
+GO(CERT_EncodeAndAddBitStrExtension, iFpipi)
+GO(CERT_EncodeAuthKeyID, iFppp)
+GO(CERT_EncodeBasicConstraintValue, iFppp)
+GO(CERT_EncodeCertPoliciesExtension, iFppp)
+GO(CERT_EncodeCRLDistributionPoints, iFppp)
+GO(CERT_EncodeGeneralName, pFppp)
+GO(CERT_EncodeInfoAccessExtension, iFppp)
+GO(CERT_EncodeInhibitAnyExtension, iFppp)
//GO(CERT_EncodeNameConstraintsExtension,
-//GO(CERT_EncodeNoticeReference,
-//GO(CERT_EncodeOCSPRequest,
-//GO(CERT_EncodePolicyConstraintsExtension,
-//GO(CERT_EncodePolicyMappingExtension,
-//GO(CERT_EncodeSubjectKeyID,
-//GO(CERT_EncodeUserNotice,
+GO(CERT_EncodeNoticeReference, iFppp)
+GO(CERT_EncodeOCSPRequest, pFppp)
+GO(CERT_EncodePolicyConstraintsExtension, iFppp)
+GO(CERT_EncodePolicyMappingExtension, iFppp)
+GO(CERT_EncodeSubjectKeyID, iFppp)
+GO(CERT_EncodeUserNotice, iFppp)
GO(CERT_ExtractPublicKey, pFp)
-//GO(CERT_FilterCertListByCANames,
-//GO(CERT_FilterCertListByUsage,
-//GO(CERT_FilterCertListForUserCerts,
-//GO(CERT_FindCertByDERCert,
-//GO(CERT_FindCertByIssuerAndSN,
-//GO(CERT_FindCertByIssuerAndSNCX,
-//GO(CERT_FindCertByName,
+GO(CERT_FilterCertListByCANames, iFpipu)
+GO(CERT_FilterCertListByUsage, iFpui)
+GO(CERT_FilterCertListForUserCerts, iFp)
+GO(CERT_FindCertByDERCert, pFpp)
+GO(CERT_FindCertByIssuerAndSN, pFpp)
+GO(CERT_FindCertByIssuerAndSNCX, pFppp)
+GO(CERT_FindCertByName, pFpp)
//GO(CERT_FindCertByNickname,
-//GO(CERT_FindCertByNicknameOrEmailAddr,
-//GO(CERT_FindCertByNicknameOrEmailAddrCX,
-//GO(CERT_FindCertByNicknameOrEmailAddrForUsage,
-//GO(CERT_FindCertByNicknameOrEmailAddrForUsageCX,
+GO(CERT_FindCertByNicknameOrEmailAddr, pFpp)
+GO(CERT_FindCertByNicknameOrEmailAddrCX, pFppp)
+GO(CERT_FindCertByNicknameOrEmailAddrForUsage, pFppu)
+GO(CERT_FindCertByNicknameOrEmailAddrForUsageCX, pFppup)
//GO(CERT_FindCertBySubjectKeyID,
-GO(CERT_FindCertExtension, iFppp)
-//GO(CERT_FindCertIssuer,
-//GO(CERT_FindCRLEntryReasonExten,
-//GO(CERT_FindCRLNumberExten,
+GO(CERT_FindCertExtension, iFpip)
+GO(CERT_FindCertIssuer, pFplu)
+GO(CERT_FindCRLEntryReasonExten, iFpp)
+GO(CERT_FindCRLNumberExten, iFppp)
//GO(CERT_FindKeyUsageExtension,
-//GO(CERT_FindNameConstraintsExten,
-//GO(CERT_FindSMimeProfile,
-//GO(CERT_FindSubjectKeyIDExtension,
-//GO(CERT_FindUserCertByUsage,
-//GO(CERT_FindUserCertsByUsage,
-//GO(CERT_FinishCertificateRequestAttributes,
-//GO(CERT_FinishExtensions,
-//GO(CERT_ForcePostMethodForOCSP,
-//GO(CERT_FormatName,
-//GO(CERT_FreeDistNames,
-//GO(CERT_FreeNicknames,
-//GO(CERT_GenTime2FormattedAscii,
-GO(CERT_GetAVATag, iFp)
-//GO(CERT_GetCertChainFromCert,
+GO(CERT_FindNameConstraintsExten, iFppp)
+GO(CERT_FindSMimeProfile, pFp)
+GO(CERT_FindSubjectKeyIDExtension, iFpp)
+GO(CERT_FindUserCertByUsage, pFppuip)
+GO(CERT_FindUserCertsByUsage, pFpuiip)
+GO(CERT_FinishCertificateRequestAttributes, iFp)
+GO(CERT_FinishExtensions, iFp)
+GO(CERT_ForcePostMethodForOCSP, iFi)
+GO(CERT_FormatName, pFp)
+GO(CERT_FreeDistNames, vFp)
+GO(CERT_FreeNicknames, vFp)
+GO(CERT_GenTime2FormattedAscii, pFlp)
+GO(CERT_GetAVATag, uFp)
+GO(CERT_GetCertChainFromCert, pFplu)
GO(CERT_GetCertEmailAddress, pFp)
-//GO(CERT_GetCertificateDer,
-//GO(CERT_GetCertificateNames,
-//GO(CERT_GetCertificateRequestExtensions,
-//GO(CERT_GetCertIsPerm,
-//GO(CERT_GetCertIssuerAndSN,
+GO(CERT_GetCertificateDer, iFpp)
+GO(CERT_GetCertificateNames, pFpp)
+GO(CERT_GetCertificateRequestExtensions, iFpp)
+GO(CERT_GetCertIsPerm, iFpp)
+GO(CERT_GetCertIssuerAndSN, pFpp)
//GO(CERT_GetCertIsTemp,
-//GO(CERT_GetCertKeyType,
-//GO(CERT_GetCertNicknames,
-//GO(CERT_GetCertTimes,
+GO(CERT_GetCertKeyType, uFp)
+GO(CERT_GetCertNicknames, pFpip)
+GO(CERT_GetCertTimes, iFppp)
GO(CERT_GetCertTrust, iFpp)
GO(CERT_GetCertUid, pFp)
-//GO(CERT_GetClassicOCSPDisabledPolicy,
+GO(CERT_GetClassicOCSPDisabledPolicy, pFv)
//GO(CERT_GetClassicOCSPEnabledHardFailurePolicy,
//GO(CERT_GetClassicOCSPEnabledSoftFailurePolicy,
GO(CERT_GetCommonName, pFp)
-//GO(CERT_GetConstrainedCertificateNames,
+GO(CERT_GetConstrainedCertificateNames, pFppi)
GO(CERT_GetCountryName, pFp)
-//GO(CERT_GetDBContentVersion,
+GO(CERT_GetDBContentVersion, iFp)
GO(CERT_GetDefaultCertDB, pFv)
GO(CERT_GetDomainComponentName, pFp)
-//GO(CERT_GetEncodedOCSPResponse,
-//GO(CERT_GetFirstEmailAddress,
-//GO(CERT_GetGeneralNameTypeFromString,
-//GO(CERT_GetImposedNameConstraints,
+GO(CERT_GetEncodedOCSPResponse, pFppplippp)
+GO(CERT_GetFirstEmailAddress, pFp)
+GO(CERT_GetGeneralNameTypeFromString, uFp)
+GO(CERT_GetImposedNameConstraints, iFpp)
GO(CERT_GetLocalityName, pFp)
-//GO(CERT_GetNextEmailAddress,
+GO(CERT_GetNextEmailAddress, pFpp)
GO(CERT_GetNextGeneralName, pFp)
//GO(CERT_GetNextNameConstraint,
-//GO(CERT_GetOCSPAuthorityInfoAccessLocation,
-//GO(CERT_GetOCSPResponseStatus,
-//GO(CERT_GetOCSPStatusForCertID,
-//GO(CERT_GetOidString,
+GO(CERT_GetOCSPAuthorityInfoAccessLocation, pFp)
+GO(CERT_GetOCSPResponseStatus, iFp)
+GO(CERT_GetOCSPStatusForCertID, iFppppl)
+GO(CERT_GetOidString, pFp)
GO(CERT_GetOrgName, pFp)
GO(CERT_GetOrgUnitName, pFp)
//GO(CERT_GetPKIXVerifyNistRevocationPolicy,
-//GO(CERT_GetPrevGeneralName,
-//GO(CERT_GetPrevNameConstraint,
+GO(CERT_GetPrevGeneralName, pFp)
+GO(CERT_GetPrevNameConstraint, pFp)
//GO(CERT_GetSlopTime,
-//GO(CERT_GetSSLCACerts,
+GO(CERT_GetSSLCACerts, pFp)
GO(CERT_GetStateName, pFp)
-//GO(CERT_GetSubjectNameDigest,
+GO(CERT_GetSubjectNameDigest, pFppup)
//GO(CERT_GetSubjectPublicKeyDigest,
//GO(CERT_GetUsePKIXForValidation,
-//GO(CERT_GetValidDNSPatternsFromCert,
-//GO(CERT_Hexify,
+GO(CERT_GetValidDNSPatternsFromCert, pFp)
+GO(CERT_Hexify, pFpi)
//GO(CERT_ImportCAChain,
-//GO(CERT_ImportCAChainTrusted,
-//GO(CERT_ImportCerts,
-//GO(CERT_ImportCRL,
-//GO(CERT_IsCACert,
-//GO(CERT_IsCADERCert,
-//GO(CERT_IsRootDERCert,
+GO(CERT_ImportCAChainTrusted, iFpiu)
+GO(CERT_ImportCerts, iFpuuppiip)
+GO(CERT_ImportCRL, pFpppip)
+GO(CERT_IsCACert, iFpp)
+GO(CERT_IsCADERCert, iFpp)
+GO(CERT_IsRootDERCert, iFp)
//DATA(CERT_IssuerAndSNTemplate,
//GO(CERT_IsUserCert,
//GO(CERT_KeyFromDERCrl,
-//GO(CERT_MakeCANickname,
-//GO(CERT_MergeExtensions,
+GO(CERT_MakeCANickname, pFp)
+GO(CERT_MergeExtensions, iFpp)
DATA(CERT_NameTemplate, 4*sizeof(void*))
//GO(CERT_NameToAscii,
-//GO(CERT_NameToAsciiInvertible,
-//GO(CERT_NewCertList,
+GO(CERT_NameToAsciiInvertible, pFpu)
+GO(CERT_NewCertList, pFv)
//GO(__CERT_NewTempCertificate,
GO(CERT_NewTempCertificate, pFpppii)
-//GO(CERT_NicknameStringsFromCertList,
-//GO(CERT_OCSPCacheSettings,
-//GO(CERT_OpenCertDBFilename,
+GO(CERT_NicknameStringsFromCertList, pFppp)
+GO(CERT_OCSPCacheSettings, iFiuu)
+GO(CERT_OpenCertDBFilename, iFppi)
GOM(CERT_PKIXVerifyCert, iFEpIppp)
-//GO(CERT_PostOCSPRequest,
+GO(CERT_PostOCSPRequest, pFppp)
GOM(CERT_RegisterAlternateOCSPAIAInfoCallBack, iFEpp)
-//GO(CERT_RemoveCertListNode,
-//GO(CERT_RFC1485_EscapeAndQuote,
-//GO(CERT_SaveSMimeProfile,
+GO(CERT_RemoveCertListNode, vFp)
+GO(CERT_RFC1485_EscapeAndQuote, iFpipi)
+GO(CERT_SaveSMimeProfile, iFppp)
//DATA(CERT_SequenceOfCertExtensionTemplate,
-//GO(CERT_SetOCSPDefaultResponder,
-//GO(CERT_SetOCSPFailureMode,
-//GO(CERT_SetOCSPTimeout,
+GO(CERT_SetOCSPDefaultResponder, iFppp)
+GO(CERT_SetOCSPFailureMode, iFu)
+GO(CERT_SetOCSPTimeout, iFu)
//DATA(CERT_SetOfSignedCrlTemplate,
-//GO(CERT_SetSlopTime,
-//GO(CERT_SetUsePKIXForValidation,
+GO(CERT_SetSlopTime, iFi)
+GO(CERT_SetUsePKIXForValidation, iFi)
//DATA(CERT_SignedCrlTemplate,
DATA(CERT_SignedDataTemplate, 160)
-//GO(CERT_StartCertExtensions,
-//GO(CERT_StartCertificateRequestAttributes,
-//GO(CERT_StartCRLEntryExtensions,
-//GO(CERT_StartCRLExtensions,
+GO(CERT_StartCertExtensions, pFp)
+GO(CERT_StartCertificateRequestAttributes, pFp)
+GO(CERT_StartCRLEntryExtensions, pFpp)
+GO(CERT_StartCRLExtensions, pFp)
//DATA(CERT_SubjectPublicKeyInfoTemplate,
//DATA(CERT_TimeChoiceTemplate, //R type
//GO(__CERT_TraversePermCertsForNickname,
//GO(__CERT_TraversePermCertsForSubject,
-//GO(CERT_UncacheCRL,
+GO(CERT_UncacheCRL, iFpp)
//GO(CERT_VerifyCACertForUsage,
-//GO(CERT_VerifyCert,
-//GO(CERT_VerifyCertificate,
-//GO(CERT_VerifyCertificateNow,
-//GO(CERT_VerifyCertName,
-//GO(CERT_VerifyCertNow,
-//GO(CERT_VerifyOCSPResponseSignature,
-//GO(CERT_VerifySignedData,
-//GO(CERT_VerifySignedDataWithPublicKey,
-//GO(CERT_VerifySignedDataWithPublicKeyInfo,
-//GO(DER_AsciiToTime,
+GO(CERT_VerifyCert, iFpp)
+GO(CERT_VerifyCertificate, iFppillppp)
+GO(CERT_VerifyCertificateNow, iFppilpp)
+GO(CERT_VerifyCertName, iFpp)
+GO(CERT_VerifyCertNow, iFppiup)
+GO(CERT_VerifyOCSPResponseSignature, iFppppp)
+GO(CERT_VerifySignedData, iFpplp)
+GO(CERT_VerifySignedDataWithPublicKey, iFppp)
+GO(CERT_VerifySignedDataWithPublicKeyInfo, iFppp)
+GO(DER_AsciiToTime, iFpp)
GO(DER_DecodeTimeChoice, iFpp)
-//GO(DER_Encode,
-//GO(DER_EncodeTimeChoice,
+GO(DER_Encode, iFpppp)
+GO(DER_EncodeTimeChoice, iFppl)
//GO(DER_GeneralizedDayToAscii,
//GO(DER_GeneralizedTimeToTime,
-//GO(DER_GetInteger,
-//GO(DER_Lengths,
-//GO(DER_TimeChoiceDayToAscii,
-//GO(DER_TimeToGeneralizedTime,
+GO(DER_GetInteger, lFp)
+GO(DER_Lengths, iFppp)
+GO(DER_TimeChoiceDayToAscii, pFp)
+GO(DER_TimeToGeneralizedTime, iFpl)
//GO(DER_TimeToGeneralizedTimeArena,
//GO(DER_TimeToUTCTime,
//GO(DER_UTCDayToAscii,
//GO(DER_UTCTimeToAscii,
//GO(DER_UTCTimeToTime,
-//GO(DSAU_DecodeDerSig,
-//GO(DSAU_DecodeDerSigToLen,
-//GO(DSAU_EncodeDerSig,
-//GO(DSAU_EncodeDerSigWithLen,
-//GO(HASH_Begin,
+GO(DSAU_DecodeDerSig, pFp)
+GO(DSAU_DecodeDerSigToLen, pFpu)
+GO(DSAU_EncodeDerSig, iFpp)
+GO(DSAU_EncodeDerSigWithLen, iFppu)
+GO(HASH_Begin, vFp)
//GO(HASH_Clone,
-//GO(HASH_Create,
-//GO(HASH_Destroy,
-//GO(HASH_End,
-//GO(HASH_GetHashObject,
-//GO(HASH_GetHashObjectByOidTag,
-//GO(HASH_GetHashOidTagByHashType,
-//GO(HASH_GetHashTypeByOidTag,
+GO(HASH_Create, pFi)
+GO(HASH_Destroy, vFp)
+GO(HASH_End, vFpppu)
+GO(HASH_GetHashObject, pFu)
+GO(HASH_GetHashObjectByOidTag, pFu)
+GO(HASH_GetHashOidTagByHashType, uFu)
+GO(HASH_GetHashTypeByOidTag, uFu)
//GO(HASH_GetType,
-GO(HASH_HashBuf, iFippu)
-//GO(HASH_ResultLen,
-//GO(HASH_ResultLenByOidTag,
-//GO(HASH_ResultLenContext,
-//GO(HASH_Update,
-//GO(NSSBase64_DecodeBuffer,
+GO(HASH_HashBuf, iFuppu)
+GO(HASH_ResultLen, uFu)
+GO(HASH_ResultLenByOidTag, uFu)
+GO(HASH_ResultLenContext, uFp)
+GO(HASH_Update, vFppu)
+GO(NSSBase64_DecodeBuffer, pFpppu)
//GO(NSSBase64Decoder_Create,
-//GO(NSSBase64Decoder_Destroy,
-//GO(NSSBase64Decoder_Update,
-//GO(NSSBase64_EncodeItem,
+GO(NSSBase64Decoder_Destroy, iFpi)
+GO(NSSBase64Decoder_Update, iFppu)
+GO(NSSBase64_EncodeItem, pFppup)
//GO(NSSBase64Encoder_Create,
-//GO(NSSBase64Encoder_Destroy,
-//GO(NSSBase64Encoder_Update,
+GO(NSSBase64Encoder_Destroy, iFpi)
+GO(NSSBase64Encoder_Update, iFppu)
//GO(nss_DumpCertificateCacheInfo,
//GO(NSS_Get_CERT_CertificateRequestTemplate,
//GO(NSS_Get_CERT_CertificateTemplate,
@@ -316,7 +316,7 @@ GO(HASH_HashBuf, iFippu)
//GO(NSS_Get_SECKEY_PointerToEncryptedPrivateKeyInfoTemplate,
//GO(NSS_Get_SECKEY_PointerToPrivateKeyInfoTemplate,
//GO(NSS_Get_SECKEY_PrivateKeyInfoTemplate,
-//GO(NSS_Get_SECKEY_RSAPSSParamsTemplate,
+GO(NSS_Get_SECKEY_RSAPSSParamsTemplate, pFpi)
//GO(NSS_Get_SECKEY_RSAPublicKeyTemplate,
//GO(NSS_Get_SEC_NullTemplate,
//GO(NSS_Get_SEC_ObjectIDTemplate,
@@ -328,14 +328,14 @@ GO(HASH_HashBuf, iFippu)
//GO(NSS_Get_SEC_SignedCertificateTemplate,
//GO(NSS_Get_SEC_UTCTimeTemplate,
//GO(NSS_Get_SEC_UTF8StringTemplate,
-//GO(NSS_Get_sgn_DigestInfoTemplate,
-//GO(NSS_GetVersion,
+GO(NSS_Get_sgn_DigestInfoTemplate, pFpi)
+GO(NSS_GetVersion, pFv)
//GO(NSS_Init,
-//GO(NSS_InitContext,
-//GO(NSS_Initialize,
+GO(NSS_InitContext, pFpppppu)
+GO(NSS_Initialize, iFppppu)
//GO(__nss_InitLock,
GO(NSS_InitReadWrite, iFp)
-//GO(NSS_InitWithMerge,
+GO(NSS_InitWithMerge, iFpppppppppu)
GO(NSS_IsInitialized, iFv)
GO(NSS_NoDB_Init, iFp)
//GO(NSS_OptionGet,
@@ -343,186 +343,186 @@ GO(NSS_NoDB_Init, iFp)
//GO(NSS_PutEnv,
//GO(NSS_RegisterShutdown,
//GO(NSSRWLock_Destroy,
-//GO(NSSRWLock_HaveWriteLock,
+GO(NSSRWLock_HaveWriteLock, iFp)
//GO(NSSRWLock_LockRead,
//GO(NSSRWLock_LockWrite,
-//GO(NSSRWLock_New,
+GO(NSSRWLock_New, pFup)
//GO(NSSRWLock_UnlockRead,
-//GO(NSSRWLock_UnlockWrite,
+GO(NSSRWLock_UnlockWrite, vFp)
//GO(NSS_Shutdown,
-//GO(NSS_ShutdownContext,
+GO(NSS_ShutdownContext, iFp)
//GO(NSS_UnregisterShutdown,
GO(NSS_VersionCheck, iFp)
//GO(__PBE_CreateContext,
-//GO(PBE_CreateContext,
+GO(PBE_CreateContext, pFuuppuu)
//GO(__PBE_DestroyContext,
-//GO(PBE_DestroyContext,
+GO(PBE_DestroyContext, vFp)
//GO(__PBE_GenerateBits,
-//GO(PBE_GenerateBits,
-//GO(PK11_AlgtagToMechanism,
+GO(PBE_GenerateBits, pFp)
+GO(PK11_AlgtagToMechanism, LFu)
GO(PK11_Authenticate, iFpip)
-//GO(PK11_BlockData,
-//GO(PK11_ChangePW,
+GO(PK11_BlockData, pFpL)
+GO(PK11_ChangePW, iFppp)
//GO(PK11_CheckSSOPassword,
GO(PK11_CheckUserPassword, iFpp)
GO(PK11_CipherOp, iFpppipi)
-//GO(PK11_CloneContext,
-//GO(PK11_ConfigurePKCS11,
-//GO(PK11_ConvertSessionPrivKeyToTokenPrivKey,
-//GO(PK11_ConvertSessionSymKeyToTokenSymKey,
-//GO(PK11_CopySymKeyForSigning,
-//GO(PK11_CopyTokenPrivKeyToSessionPrivKey,
+GO(PK11_CloneContext, pFp)
+GO(PK11_ConfigurePKCS11, vFppppppppii)
+GO(PK11_ConvertSessionPrivKeyToTokenPrivKey, pFpp)
+GO(PK11_ConvertSessionSymKeyToTokenSymKey, pFpp)
+GO(PK11_CopySymKeyForSigning, pFpL)
+GO(PK11_CopyTokenPrivKeyToSessionPrivKey, pFpp)
//GO(__PK11_CreateContextByRawKey,
-GO(PK11_CreateContextBySymKey, pFiipp)
-//GO(PK11_CreateDigestContext,
-//GO(PK11_CreateGenericObject,
+GO(PK11_CreateContextBySymKey, pFLLpp)
+GO(PK11_CreateDigestContext, pFu)
+GO(PK11_CreateGenericObject, pFppii)
//GO(PK11_CreateManagedGenericObject,
-//GO(PK11_CreateMergeLog,
-//GO(PK11_CreatePBEAlgorithmID,
-//GO(PK11_CreatePBEParams,
-//GO(PK11_CreatePBEV2AlgorithmID,
+GO(PK11_CreateMergeLog, pFv)
+GO(PK11_CreatePBEAlgorithmID, pFuip)
+GO(PK11_CreatePBEParams, pFppu)
+GO(PK11_CreatePBEV2AlgorithmID, pFuuuiip)
//GO(PK11_Decrypt,
GO(PK11_DeleteTokenCertAndKey, iFpp)
-//GO(PK11_DeleteTokenPrivateKey,
-//GO(PK11_DeleteTokenPublicKey,
+GO(PK11_DeleteTokenPrivateKey, iFpi)
+GO(PK11_DeleteTokenPublicKey, iFp)
//GO(PK11_DeleteTokenSymKey,
-//GO(PK11_DEREncodePublicKey,
-//GO(PK11_Derive,
-//GO(PK11_DeriveWithFlags,
-//GO(PK11_DeriveWithFlagsPerm,
-//GO(PK11_DeriveWithTemplate,
+GO(PK11_DEREncodePublicKey, pFp)
+GO(PK11_Derive, pFpLpLLi)
+GO(PK11_DeriveWithFlags, pFpLpLLiL)
+GO(PK11_DeriveWithFlagsPerm, pFpLpLLiLi)
+GO(PK11_DeriveWithTemplate, pFpLpLLipui)
GO(PK11_DestroyContext, vFpi)
-//GO(PK11_DestroyGenericObject,
-//GO(PK11_DestroyGenericObjects,
-//GO(PK11_DestroyMergeLog,
+GO(PK11_DestroyGenericObject, iFp)
+GO(PK11_DestroyGenericObjects, uFp)
+GO(PK11_DestroyMergeLog, vFp)
GO(PK11_DestroyObject, iFpL)
-//GO(PK11_DestroyPBEParams,
+GO(PK11_DestroyPBEParams, vFp)
GO(PK11_DestroyTokenObject, iFpL)
//GO(PK11_DigestBegin,
-//GO(PK11_DigestFinal,
-//GO(PK11_DigestKey,
-//GO(PK11_DigestOp,
-//GO(PK11_DoesMechanism,
-//GO(PK11_Encrypt,
-//GO(PK11_ExportDERPrivateKeyInfo,
-//GO(PK11_ExportEncryptedPrivateKeyInfo,
-//GO(PK11_ExportEncryptedPrivKeyInfo,
-//GO(PK11_ExportPrivateKeyInfo,
-//GO(PK11_ExportPrivKeyInfo,
-//GO(PK11_ExtractKeyValue,
+GO(PK11_DigestFinal, iFpppu)
+GO(PK11_DigestKey, iFpp)
+GO(PK11_DigestOp, iFppu)
+GO(PK11_DoesMechanism, iFpL)
+GO(PK11_Encrypt, iFpLpppupu)
+GO(PK11_ExportDERPrivateKeyInfo, pFpp)
+GO(PK11_ExportEncryptedPrivateKeyInfo, pFpuppip)
+GO(PK11_ExportEncryptedPrivKeyInfo, pFpuppip)
+GO(PK11_ExportPrivateKeyInfo, pFpp)
+GO(PK11_ExportPrivKeyInfo, pFpp)
+GO(PK11_ExtractKeyValue, iFp)
GO(PK11_Finalize, iFp)
-//GO(PK11_FindBestKEAMatch,
-//GO(PK11_FindCertAndKeyByRecipientList,
-//GO(PK11_FindCertAndKeyByRecipientListNew,
-//GO(PK11_FindCertByIssuerAndSN,
-//GO(PK11_FindCertFromDERCert,
+GO(PK11_FindBestKEAMatch, pFpp)
+GO(PK11_FindCertAndKeyByRecipientList, pFppppp)
+GO(PK11_FindCertAndKeyByRecipientListNew, iFpp)
+GO(PK11_FindCertByIssuerAndSN, pFppp)
+GO(PK11_FindCertFromDERCert, pFppp)
GO(PK11_FindCertFromDERCertItem, pFppp)
//GO(PK11_FindCertFromNickname,
-//GO(PK11_FindCertFromURI,
-//GO(PK11_FindCertInSlot,
+GO(PK11_FindCertFromURI, pFpp)
+GO(PK11_FindCertInSlot, LFppp)
//GO(PK11_FindCertsFromEmailAddress,
-//GO(PK11_FindCertsFromNickname,
+GO(PK11_FindCertsFromNickname, pFpp)
//GO(PK11_FindCertsFromURI,
-GO(PK11_FindFixedKey, pFpipp)
-//GO(PK11_FindGenericObjects,
+GO(PK11_FindFixedKey, pFpLpp)
+GO(PK11_FindGenericObjects, pFpL)
GO(PK11_FindKeyByAnyCert, pFpp)
GO(PK11_FindKeyByDERCert, pFppp)
GO(PK11_FindKeyByKeyID, pFppp)
GO(PK11_FindPrivateKeyFromCert, pFppp)
-//GO(PK11_FindRawCertsWithSubject,
+GO(PK11_FindRawCertsWithSubject, iFppp)
//GO(PK11_FindSlotByName,
-//GO(PK11_FindSlotsByNames,
-//GO(PK11_FortezzaHasKEA,
-//GO(PK11_FortezzaMapSig,
+GO(PK11_FindSlotsByNames, pFpppi)
+GO(PK11_FortezzaHasKEA, iFp)
+GO(PK11_FortezzaMapSig, uFu)
GO(PK11_FreeSlot, vFp)
GO(PK11_FreeSlotList, vFp)
-//GO(PK11_FreeSlotListElement,
+GO(PK11_FreeSlotListElement, iFpp)
GO(PK11_FreeSymKey, vFp)
-//GO(PK11_GenerateFortezzaIV,
+GO(PK11_GenerateFortezzaIV, iFppi)
GO(PK11_GenerateKeyPair, pFpLppiip)
-//GO(PK11_GenerateKeyPairWithFlags,
-//GO(PK11_GenerateKeyPairWithOpFlags,
-//GO(PK11_GenerateNewParam,
-//GO(PK11_GenerateRandom,
-//GO(PK11_GenerateRandomOnSlot,
-//GO(PK11_GetAllSlotsForCert,
+GO(PK11_GenerateKeyPairWithFlags, pFpLppup)
+GO(PK11_GenerateKeyPairWithOpFlags, pFpLppuLLp)
+GO(PK11_GenerateNewParam, pFLp)
+GO(PK11_GenerateRandom, iFpi)
+GO(PK11_GenerateRandomOnSlot, iFppi)
+GO(PK11_GetAllSlotsForCert, pFpp)
GO(PK11_GetAllTokens, pFLiip)
-//GO(PK11_GetBestKeyLength,
-//GO(PK11_GetBestSlot,
-//GO(PK11_GetBestSlotMultiple,
-//GO(PK11_GetBestSlotMultipleWithAttributes,
-//GO(PK11_GetBestSlotWithAttributes,
-//GO(PK11_GetBestWrapMechanism,
+GO(PK11_GetBestKeyLength, iFpL)
+GO(PK11_GetBestSlot, pFLp)
+GO(PK11_GetBestSlotMultiple, pFpup)
+GO(PK11_GetBestSlotMultipleWithAttributes, pFpppup)
+GO(PK11_GetBestSlotWithAttributes, pFLLup)
+GO(PK11_GetBestWrapMechanism, LFp)
GO(PK11_GetBlockSize, iFLp)
-//GO(PK11_GetCertFromPrivateKey,
-//GO(PK11_GetCertsMatchingPrivateKey,
-//GO(PK11_GetCurrentWrapIndex,
-//GO(PK11_GetDefaultArray,
-//GO(PK11_GetDefaultFlags,
-//GO(PK11_GetDisabledReason,
+GO(PK11_GetCertFromPrivateKey, pFp)
+GO(PK11_GetCertsMatchingPrivateKey, pFp)
+GO(PK11_GetCurrentWrapIndex, iFp)
+GO(PK11_GetDefaultArray, pFp)
+GO(PK11_GetDefaultFlags, LFp)
+GO(PK11_GetDisabledReason, uFp)
GO(PK11_GetFirstSafe, pFp)
GO(PK11_GetInternalKeySlot, pFv)
-//GO(PK11_GetInternalSlot,
+GO(PK11_GetInternalSlot, pFv)
//GO(PK11_GetIVLength,
//GO(__PK11_GetKeyData,
-//GO(PK11_GetKeyData,
+GO(PK11_GetKeyData, pFp)
//GO(PK11_GetKeyGen,
-//GO(PK11_GetKeyLength,
-//GO(PK11_GetKeyStrength,
-//GO(PK11_GetKeyType,
-//GO(PK11_GetLowLevelKeyIDForCert,
-//GO(PK11_GetLowLevelKeyIDForPrivateKey,
-//GO(PK11_GetMechanism,
+GO(PK11_GetKeyLength, uFp)
+GO(PK11_GetKeyStrength, uFpp)
+GO(PK11_GetKeyType, LFLL)
+GO(PK11_GetLowLevelKeyIDForCert, pFppp)
+GO(PK11_GetLowLevelKeyIDForPrivateKey, pFp)
+GO(PK11_GetMechanism, LFp)
//GO(PK11_GetMinimumPwdLength,
//GO(PK11_GetModInfo,
-//GO(PK11_GetModule,
-//GO(PK11_GetModuleID,
+GO(PK11_GetModule, pFp)
+GO(PK11_GetModuleID, LFp)
//GO(PK11_GetModuleURI,
-//GO(PK11_GetNextGenericObject,
+GO(PK11_GetNextGenericObject, pFp)
GO(PK11_GetNextSafe, pFppi)
GO(PK11_GetNextSymKey, pFp)
-//GO(PK11_GetPadMechanism,
-//GO(PK11_GetPBECryptoMechanism,
-//GO(PK11_GetPBEIV,
-//GO(PK11_GetPQGParamsFromPrivateKey,
-//GO(PK11_GetPrevGenericObject,
+GO(PK11_GetPadMechanism, LFL)
+GO(PK11_GetPBECryptoMechanism, LFppp)
+GO(PK11_GetPBEIV, pFpp)
+GO(PK11_GetPQGParamsFromPrivateKey, pFp)
+GO(PK11_GetPrevGenericObject, pFp)
GO(PK11_GetPrivateKeyNickname, pFp)
//GO(PK11_GetPrivateModulusLen,
-//GO(PK11_GetPublicKeyNickname,
-//GO(PK11_GetSlotFromKey,
-//GO(PK11_GetSlotFromPrivateKey,
-//GO(PK11_GetSlotID,
-//GO(PK11_GetSlotInfo,
+GO(PK11_GetPublicKeyNickname, pFp)
+GO(PK11_GetSlotFromKey, pFp)
+GO(PK11_GetSlotFromPrivateKey, pFp)
+GO(PK11_GetSlotID, LFp)
+GO(PK11_GetSlotInfo, iFpp)
GO(PK11_GetSlotName, pFp)
-//GO(PK11_GetSlotPWValues,
+GO(PK11_GetSlotPWValues, vFppp)
//GO(PK11_GetSlotSeries,
-//GO(PK11_GetSymKeyHandle,
-//GO(PK11_GetSymKeyNickname,
-//GO(PK11_GetSymKeyType,
+GO(PK11_GetSymKeyHandle, LFp)
+GO(PK11_GetSymKeyNickname, pFp)
+GO(PK11_GetSymKeyType, LFp)
//GO(PK11_GetSymKeyUserData,
-//GO(PK11_GetTokenInfo,
+GO(PK11_GetTokenInfo, iFpp)
GO(PK11_GetTokenName, pFp)
//GO(PK11_GetTokenURI,
-//GO(PK11_GetWindow,
-//GO(PK11_GetWrapKey,
-//GO(PK11_HasAttributeSet,
-//GO(PK11_HashBuf,
-//GO(PK11_HasRootCerts,
+GO(PK11_GetWindow, pFp)
+GO(PK11_GetWrapKey, pFpiLip)
+GO(PK11_HasAttributeSet, CFpLLi)
+GO(PK11_HashBuf, iFuppi)
+GO(PK11_HasRootCerts, iFp)
GO(PK11_ImportCert, iFppLpi)
-//GO(PK11_ImportCertForKey,
-//GO(PK11_ImportCertForKeyToSlot,
-//GO(PK11_ImportCRL,
-//GO(PK11_ImportDERCert,
-//GO(PK11_ImportDERCertForKey,
-//GO(PK11_ImportDERPrivateKeyInfo,
+GO(PK11_ImportCertForKey, pFppp)
+GO(PK11_ImportCertForKeyToSlot, iFpppip)
+GO(PK11_ImportCRL, pFpppipipi)
+GO(PK11_ImportDERCert, iFppLpi)
+GO(PK11_ImportDERCertForKey, pFppp)
+GO(PK11_ImportDERPrivateKeyInfo, iFppppiiup)
GO(PK11_ImportDERPrivateKeyInfoAndReturnKey, iFppppiiupp)
-//GO(PK11_ImportEncryptedPrivateKeyInfo,
-//GO(PK11_ImportEncryptedPrivateKeyInfoAndReturnKey,
-//GO(PK11_ImportPrivateKeyInfo,
-//GO(PK11_ImportPrivateKeyInfoAndReturnKey,
-//GO(PK11_ImportPublicKey,
-//GO(PK11_ImportSymKey,
-//GO(PK11_ImportSymKeyWithFlags,
+GO(PK11_ImportEncryptedPrivateKeyInfo, iFpppppiiuup)
+GO(PK11_ImportEncryptedPrivateKeyInfoAndReturnKey, iFpppppiiuupp)
+GO(PK11_ImportPrivateKeyInfo, iFppppiiup)
+GO(PK11_ImportPrivateKeyInfoAndReturnKey, iFppppiiupp)
+GO(PK11_ImportPublicKey, LFppi)
+GO(PK11_ImportSymKey, pFpLuLpp)
+GO(PK11_ImportSymKeyWithFlags, pFpLuLpLip)
GO(PK11_InitPin, iFppp)
//GO(PK11_IsDisabled,
GO(PK11_IsFIPS, iFv)
@@ -531,251 +531,251 @@ GO(PK11_IsHW, iFp)
GO(PK11_IsInternal, iFp)
GO(PK11_IsInternalKeySlot, iFp)
GO(PK11_IsLoggedIn, iFpp)
-//GO(PK11_IsPresent,
+GO(PK11_IsPresent, iFp)
GO(PK11_IsReadOnly, iFp)
GO(PK11_IsRemovable, iFp)
-//GO(PK11_IVFromParam,
+GO(PK11_IVFromParam, pFLpp)
GO(PK11_KeyForCertExists, pFppp)
-//GO(PK11_KeyForDERCertExists,
-//GO(PK11_KeyGen,
-//GO(PK11_KeyGenWithTemplate,
-//GO(PK11_LinkGenericObject,
-GO(PK11_ListCerts, pFip)
+GO(PK11_KeyForDERCertExists, pFppp)
+GO(PK11_KeyGen, pFpLpip)
+GO(PK11_KeyGenWithTemplate, pFpLLppup)
+GO(PK11_LinkGenericObject, iFpp)
+GO(PK11_ListCerts, pFup)
GO(PK11_ListCertsInSlot, pFp)
GO(PK11_ListFixedKeysInSlot, pFppp)
-//GO(PK11_ListPrivateKeysInSlot,
-//GO(PK11_ListPrivKeysInSlot,
-//GO(PK11_ListPublicKeysInSlot,
-//GO(PK11_LoadPrivKey,
+GO(PK11_ListPrivateKeysInSlot, pFp)
+GO(PK11_ListPrivKeysInSlot, pFppp)
+GO(PK11_ListPublicKeysInSlot, pFpp)
+GO(PK11_LoadPrivKey, pFpppii)
//GO(PK11_Logout,
//GO(PK11_LogoutAll,
GO(PK11_MakeIDFromPubKey, pFp)
-//GO(PK11_MakeKEAPubKey,
-//GO(PK11_MapPBEMechanismToCryptoMechanism,
-//GO(PK11_MapSignKeyType,
-//GO(PK11_MechanismToAlgtag,
-//GO(PK11_MergeTokens,
-//GO(PK11_MoveSymKey,
+GO(PK11_MakeKEAPubKey, pFpi)
+GO(PK11_MapPBEMechanismToCryptoMechanism, LFpppi)
+GO(PK11_MapSignKeyType, LFu)
+GO(PK11_MechanismToAlgtag, uFL)
+GO(PK11_MergeTokens, iFppppp)
+GO(PK11_MoveSymKey, pFpLLip)
GO(PK11_NeedLogin, iFp)
//GO(PK11_NeedPWInit,
GO(PK11_NeedUserInit, iFp)
GO(PK11_ParamFromAlgid, pFp)
-//GO(PK11_ParamFromIV,
-//GO(PK11_ParamToAlgid,
-//GO(PK11_PBEKeyGen,
-//GO(PK11_PQG_DestroyParams,
-//GO(PK11_PQG_DestroyVerify,
-//GO(PK11_PQG_GetBaseFromParams,
-//GO(PK11_PQG_GetCounterFromVerify,
-//GO(PK11_PQG_GetHFromVerify,
+GO(PK11_ParamFromIV, pFLp)
+GO(PK11_ParamToAlgid, iFuppp)
+GO(PK11_PBEKeyGen, pFpppip)
+GO(PK11_PQG_DestroyParams, vFp)
+GO(PK11_PQG_DestroyVerify, vFp)
+GO(PK11_PQG_GetBaseFromParams, iFpp)
+GO(PK11_PQG_GetCounterFromVerify, uFp)
+GO(PK11_PQG_GetHFromVerify, iFpp)
//GO(PK11_PQG_GetPrimeFromParams,
//GO(PK11_PQG_GetSeedFromVerify,
//GO(PK11_PQG_GetSubPrimeFromParams,
-//GO(PK11_PQG_NewParams,
-//GO(PK11_PQG_NewVerify,
-//GO(PK11_PQG_ParamGen,
-//GO(PK11_PQG_ParamGenSeedLen,
-//GO(PK11_PQG_ParamGenV2,
-//GO(PK11_PQG_VerifyParams,
-//GO(PK11_PrivDecrypt,
-//GO(PK11_PrivDecryptPKCS1,
+GO(PK11_PQG_NewParams, pFppp)
+GO(PK11_PQG_NewVerify, pFupp)
+GO(PK11_PQG_ParamGen, iFupp)
+GO(PK11_PQG_ParamGenSeedLen, iFuupp)
+GO(PK11_PQG_ParamGenV2, iFuuupp)
+GO(PK11_PQG_VerifyParams, iFppp)
+GO(PK11_PrivDecrypt, iFpLpppupu)
+GO(PK11_PrivDecryptPKCS1, iFpppupu)
//GO(PK11_ProtectedAuthenticationPath,
//GO(PK11_PubDecryptRaw,
-//GO(PK11_PubDerive,
-//GO(PK11_PubDeriveWithKDF,
-//GO(PK11_PubEncrypt,
-//GO(PK11_PubEncryptPKCS1,
+GO(PK11_PubDerive, pFppippLLLip)
+GO(PK11_PubDeriveWithKDF, pFppippLLLiLpp)
+GO(PK11_PubEncrypt, iFpLpppupup)
+GO(PK11_PubEncryptPKCS1, iFpppup)
//GO(PK11_PubEncryptRaw,
-//GO(PK11_PubUnwrapSymKey,
+GO(PK11_PubUnwrapSymKey, pFppLLi)
//GO(PK11_PubUnwrapSymKeyWithFlags,
-//GO(PK11_PubUnwrapSymKeyWithFlagsPerm,
-//GO(PK11_PubWrapSymKey,
-//GO(PK11_RandomUpdate,
-//GO(PK11_RawPBEKeyGen,
+GO(PK11_PubUnwrapSymKeyWithFlagsPerm, pFppLLiLi)
+GO(PK11_PubWrapSymKey, iFLppp)
+GO(PK11_RandomUpdate, iFpL)
+GO(PK11_RawPBEKeyGen, pFpLppip)
GO(PK11_ReadRawAttribute, iFipLp)
GO(PK11_ReferenceSlot, pFp)
//GO(PK11_ReferenceSymKey,
//GO(PK11_ResetToken,
-//GO(PK11_RestoreContext,
-//GO(PK11_SaveContext,
-//GO(PK11_SaveContextAlloc,
-//GO(PK11SDR_Decrypt,
-//GO(PK11SDR_Encrypt,
+GO(PK11_RestoreContext, iFppi)
+GO(PK11_SaveContext, iFpppi)
+GO(PK11_SaveContextAlloc, pFppup)
+GO(PK11SDR_Decrypt, iFppp)
+GO(PK11SDR_Encrypt, iFpppp)
//GO(PK11_SeedRandom,
-//GO(__PK11_SetCertificateNickname,
-//GO(PK11_SetFortezzaHack,
+GO(__PK11_SetCertificateNickname, iFpp)
+GO(PK11_SetFortezzaHack, vFp)
GOM(PK11_SetPasswordFunc, vFEp)
GO(PK11_SetPrivateKeyNickname, iFpp)
GO(PK11_SetPublicKeyNickname, iFpp)
-//GO(PK11_SetSlotPWValues,
-//GO(PK11_SetSymKeyNickname,
+GO(PK11_SetSlotPWValues, vFpii)
+GO(PK11_SetSymKeyNickname, iFpp)
//GO(PK11_SetSymKeyUserData,
-//GO(PK11_SetWrapKey,
+GO(PK11_SetWrapKey, vFpip)
GO(PK11_Sign, iFppp)
GO(PK11_SignatureLen, iFp)
-//GO(PK11_SignWithMechanism,
-//GO(PK11_SignWithSymKey,
-//GO(PK11_SymKeyFromHandle,
-GO(PK11_TokenExists, iFi)
-//GO(PK11_TokenKeyGen,
-//GO(PK11_TokenKeyGenWithFlags,
+GO(PK11_SignWithMechanism, iFpLppp)
+GO(PK11_SignWithSymKey, iFpLppp)
+GO(PK11_SymKeyFromHandle, pFppuLLip)
+GO(PK11_TokenExists, iFL)
+GO(PK11_TokenKeyGen, pFpLpipip)
+GO(PK11_TokenKeyGenWithFlags, pFpLpipLup)
//GO(PK11_TokenRefresh,
//GO(PK11_TraverseCertsForNicknameInSlot,
//GO(PK11_TraverseCertsForSubjectInSlot,
//GO(PK11_TraverseSlotCerts,
//GO(PK11_UnconfigurePKCS11,
//GO(PK11_UnlinkGenericObject,
-//GO(PK11_UnwrapPrivKey,
-//GO(PK11_UnwrapSymKey,
-//GO(PK11_UnwrapSymKeyWithFlags,
-//GO(PK11_UnwrapSymKeyWithFlagsPerm,
-//GO(PK11_UpdateSlotAttribute,
+GO(PK11_UnwrapPrivKey, pFppLppppiiLpip)
+GO(PK11_UnwrapSymKey, pFpLppLLi)
+GO(PK11_UnwrapSymKeyWithFlags, pFpLppLLiL)
+GO(PK11_UnwrapSymKeyWithFlagsPerm, pFpLppLLiLi)
+GO(PK11_UpdateSlotAttribute, iFppi)
//GO(PK11_UserDisableSlot,
//GO(PK11_UserEnableSlot,
-//GO(PK11_Verify,
-//GO(PK11_VerifyKeyOK,
-//GO(PK11_VerifyRecover,
-//GO(PK11_VerifyWithMechanism,
-//GO(PK11_WaitForTokenEvent,
-//GO(PK11_WrapPrivKey,
-//GO(PK11_WrapSymKey,
-GO(PK11_WriteRawAttribute, iFipLp)
-//GO(PORT_Alloc,
-//GO(PORT_ArenaAlloc,
-//GO(PORT_ArenaGrow,
-//GO(PORT_ArenaMark,
+GO(PK11_Verify, iFpppp)
+GO(PK11_VerifyKeyOK, iFp)
+GO(PK11_VerifyRecover, iFpppp)
+GO(PK11_VerifyWithMechanism, iFpLpppp)
+GO(PK11_WaitForTokenEvent, uFpuuui)
+GO(PK11_WrapPrivKey, iFpppLppp)
+GO(PK11_WrapSymKey, iFLpppp)
+GO(PK11_WriteRawAttribute, iFupLp)
+GO(PORT_Alloc, pFL)
+GO(PORT_ArenaAlloc, pFpL)
+GO(PORT_ArenaGrow, pFppLL)
+GO(PORT_ArenaMark, pFp)
//GO(PORT_ArenaRelease,
-//GO(PORT_ArenaStrdup,
-//GO(PORT_ArenaUnmark,
-//GO(PORT_ArenaZAlloc,
+GO(PORT_ArenaStrdup, pFpp)
+GO(PORT_ArenaUnmark, vFpp)
+GO(PORT_ArenaZAlloc, pFpL)
GO(PORT_Free, vFp)
GO(PORT_FreeArena, vFpi)
GO(PORT_GetError, iFv)
GO(PORT_NewArena, pFL)
-//GO(PORT_Realloc,
-//GO(PORT_SetError,
-//GO(PORT_SetUCS2_ASCIIConversionFunction,
-//GO(PORT_SetUCS2_UTF8ConversionFunction,
+GO(PORT_Realloc, pFpL)
+GO(PORT_SetError, vFi)
+GOM(PORT_SetUCS2_ASCIIConversionFunction, vFEp)
+GO(PORT_SetUCS2_UTF8ConversionFunction, vFi)
//GO(PORT_SetUCS4_UTF8ConversionFunction,
-//GO(PORT_Strdup,
-//GO(PORT_UCS2_ASCIIConversion,
-//GO(PORT_UCS2_UTF8Conversion,
-//GO(PORT_ZAlloc,
-//GO(PORT_ZFree,
+GO(PORT_Strdup, pFp)
+GO(PORT_UCS2_ASCIIConversion, iFipupupi)
+GO(PORT_UCS2_UTF8Conversion, iFipupup)
+GO(PORT_ZAlloc, pFL)
+GO(PORT_ZFree, vFpL)
//GO(RSA_FormatBlock,
DATA(SEC_AnyTemplate, 4*sizeof(void*)) //R type
-//GO(SEC_ASN1Decode,
+GO(SEC_ASN1Decode, iFppppl)
GO(SEC_ASN1DecodeInteger, iFpp)
GO(SEC_ASN1DecodeItem, iFpppp)
-//GO(SEC_ASN1DecoderAbort,
+GO(SEC_ASN1DecoderAbort, vFpi)
//GO(SEC_ASN1DecoderClearFilterProc,
-//GO(SEC_ASN1DecoderClearNotifyProc,
-//GO(SEC_ASN1DecoderFinish,
+GO(SEC_ASN1DecoderClearNotifyProc, vFp)
+GO(SEC_ASN1DecoderFinish, iFp)
//GO(SEC_ASN1DecoderSetFilterProc,
//GO(SEC_ASN1DecoderSetNotifyProc,
-//GO(SEC_ASN1DecoderStart,
-//GO(SEC_ASN1DecoderUpdate,
+GO(SEC_ASN1DecoderStart, pFppp)
+GO(SEC_ASN1DecoderUpdate, iFppL)
//GO(SEC_ASN1Encode,
-//GO(SEC_ASN1EncodeInteger,
-//GO(SEC_ASN1EncodeItem,
-//GO(SEC_ASN1EncoderAbort,
+GO(SEC_ASN1EncodeInteger, pFppl)
+GO(SEC_ASN1EncodeItem, pFpppp)
+GO(SEC_ASN1EncoderAbort, vFpi)
//GO(SEC_ASN1EncoderClearNotifyProc,
//GO(SEC_ASN1EncoderClearStreaming,
-//GO(SEC_ASN1EncoderClearTakeFromBuf,
+GO(SEC_ASN1EncoderClearTakeFromBuf, vFp)
//GO(SEC_ASN1EncoderFinish,
//GO(SEC_ASN1EncoderSetNotifyProc,
//GO(SEC_ASN1EncoderSetStreaming,
//GO(SEC_ASN1EncoderSetTakeFromBuf,
//GO(SEC_ASN1EncoderStart,
-//GO(SEC_ASN1EncoderUpdate,
-//GO(SEC_ASN1EncodeUnsignedInteger,
-//GO(SEC_ASN1LengthLength,
+GO(SEC_ASN1EncoderUpdate, iFppL)
+GO(SEC_ASN1EncodeUnsignedInteger, pFppL)
+GO(SEC_ASN1LengthLength, iFL)
DATA(SEC_BitStringTemplate, 4*sizeof(void*)) //R type
DATA(SEC_BMPStringTemplate, 4*sizeof(void*)) //R type
//DATA(SEC_BooleanTemplate, //R type
GO(SEC_CertNicknameConflict, iFppp)
-//GO(SEC_CheckCrlTimes,
-//GO(SEC_CreateSignatureAlgorithmParameters,
+GO(SEC_CheckCrlTimes, uFpl)
+GO(SEC_CreateSignatureAlgorithmParameters, pFppuupp)
GO(SEC_DeletePermCertificate, iFp)
//GO(SEC_DeletePermCRL,
-GO(SEC_DerSignData, iFpppipi)
-//GO(SEC_DerSignDataWithAlgorithmID,
-//GO(SEC_DestroyCrl,
-//GO(SEC_DupCrl,
-//GO(SEC_FindCrlByDERCert,
+GO(SEC_DerSignData, iFpppipu)
+GO(SEC_DerSignDataWithAlgorithmID, iFpppipp)
+GO(SEC_DestroyCrl, iFp)
+GO(SEC_DupCrl, pFp)
+GO(SEC_FindCrlByDERCert, pFppi)
//GO(SEC_FindCrlByName,
//DATA(SEC_GeneralizedTimeTemplate, //R type
-//GO(SEC_GetCrlTimes,
+GO(SEC_GetCrlTimes, iFppp)
//GO(SEC_GetRegisteredHttpClient,
-//GO(SEC_GetSignatureAlgorithmOidTag,
+GO(SEC_GetSignatureAlgorithmOidTag, uFuu)
DATA(SEC_IA5StringTemplate, 4*sizeof(void*)) //R type
//DATA(SEC_IntegerTemplate, //R type
-//GO(SECITEM_AllocItem,
-//GO(SECITEM_ArenaDupItem,
-//GO(SECITEM_CompareItem,
-//GO(SECITEM_CopyItem,
+GO(SECITEM_AllocItem, pFppu)
+GO(SECITEM_ArenaDupItem, pFpp)
+GO(SECITEM_CompareItem, iFpp)
+GO(SECITEM_CopyItem, iFppp)
//GO(SECITEM_DupItem,
GO(SECITEM_FreeItem, iFpi)
-//GO(SECITEM_ItemsAreEqual,
-//GO(SECITEM_ZfreeItem,
-//GO(SECKEY_AddPrivateKeyToListTail,
-//GO(SECKEY_BigIntegerBitLength,
-//GO(SECKEY_CacheStaticFlags,
-//GO(SECKEY_ConvertToPublicKey,
-//GO(SECKEY_CopyEncryptedPrivateKeyInfo,
-//GO(SECKEY_CopyPrivateKey,
-//GO(SECKEY_CopyPrivateKeyInfo,
-//GO(SECKEY_CopyPublicKey,
-//GO(SECKEY_CopySubjectPublicKeyInfo,
-//GO(SECKEY_CreateDHPrivateKey,
-//GO(SECKEY_CreateECPrivateKey,
-//GO(SECKEY_CreateRSAPrivateKey,
-//GO(SECKEY_CreateSubjectPublicKeyInfo,
-//GO(SECKEY_DecodeDERSubjectPublicKeyInfo,
-//GO(SECKEY_DestroyEncryptedPrivateKeyInfo,
-//GO(SECKEY_DestroyPrivateKey,
-//GO(SECKEY_DestroyPrivateKeyInfo,
-//GO(SECKEY_DestroyPrivateKeyList,
+GO(SECITEM_ItemsAreEqual, iFpp)
+GO(SECITEM_ZfreeItem, vFpi)
+GO(SECKEY_AddPrivateKeyToListTail, iFpp)
+GO(SECKEY_BigIntegerBitLength, uFp)
+GO(SECKEY_CacheStaticFlags, iFp)
+GO(SECKEY_ConvertToPublicKey, pFp)
+GO(SECKEY_CopyEncryptedPrivateKeyInfo, iFppp)
+GO(SECKEY_CopyPrivateKey, pFp)
+GO(SECKEY_CopyPrivateKeyInfo, iFppp)
+GO(SECKEY_CopyPublicKey, pFp)
+GO(SECKEY_CopySubjectPublicKeyInfo, iFppp)
+GO(SECKEY_CreateDHPrivateKey, pFppp)
+GO(SECKEY_CreateECPrivateKey, pFppp)
+GO(SECKEY_CreateRSAPrivateKey, pFipp)
+GO(SECKEY_CreateSubjectPublicKeyInfo, pFp)
+GO(SECKEY_DecodeDERSubjectPublicKeyInfo, pFp)
+GO(SECKEY_DestroyEncryptedPrivateKeyInfo, vFpi)
+GO(SECKEY_DestroyPrivateKey, vFp)
+GO(SECKEY_DestroyPrivateKeyInfo, vFpi)
+GO(SECKEY_DestroyPrivateKeyList, vFp)
GO(SECKEY_DestroyPublicKey, vFp)
-//GO(SECKEY_DestroyPublicKeyList,
-//GO(SECKEY_DestroySubjectPublicKeyInfo,
+GO(SECKEY_DestroyPublicKeyList, vFp)
+GO(SECKEY_DestroySubjectPublicKeyInfo, vFp)
//DATA(SECKEY_DSAPublicKeyTemplate, //R type
-//GO(SECKEY_ECParamsToBasePointOrderLen,
+GO(SECKEY_ECParamsToBasePointOrderLen, iFp)
//GO(SECKEY_ECParamsToKeySize,
-//GO(SECKEY_EncodeDERSubjectPublicKeyInfo,
+GO(SECKEY_EncodeDERSubjectPublicKeyInfo, pFp)
DATA(SECKEY_EncryptedPrivateKeyInfoTemplate, 128)
-//GO(SECKEY_ExtractPublicKey,
-//GO(SECKEY_GetPrivateKeyType,
-//GO(SECKEY_GetPublicKeyType,
+GO(SECKEY_ExtractPublicKey, pFp)
+GO(SECKEY_GetPrivateKeyType, uFp)
+GO(SECKEY_GetPublicKeyType, uFp)
//GO(SECKEY_HashPassword,
-//GO(SECKEY_ImportDERPublicKey,
-//GO(SECKEY_NewPrivateKeyList,
+GO(SECKEY_ImportDERPublicKey, pFpL)
+GO(SECKEY_NewPrivateKeyList, pFv)
//DATA(SECKEY_PointerToEncryptedPrivateKeyInfoTemplate,
//DATA(SECKEY_PointerToPrivateKeyInfoTemplate,
DATA(SECKEY_PrivateKeyInfoTemplate, 192)
//GO(SECKEY_PublicKeyStrength,
GO(SECKEY_PublicKeyStrengthInBits, uFp)
-//GO(SECKEY_RemovePrivateKeyListNode,
+GO(SECKEY_RemovePrivateKeyListNode, vFp)
//DATA(SECKEY_RSAPSSParamsTemplate,
//DATA(SECKEY_RSAPublicKeyTemplate, //R type
-//GO(SECKEY_SignatureLen,
-//GO(SECKEY_UpdateCertPQG,
-//GO(SEC_LookupCrls,
-//GO(SECMOD_AddNewModule,
-//GO(SECMOD_AddNewModuleEx,
+GO(SECKEY_SignatureLen, uFp)
+GO(SECKEY_UpdateCertPQG, iFp)
+GO(SEC_LookupCrls, iFppi)
+GO(SECMOD_AddNewModule, iFppLL)
+GO(SECMOD_AddNewModuleEx, iFppLLpp)
//GO(SECMOD_CancelWait,
-//GO(SECMOD_CanDeleteInternalModule,
+GO(SECMOD_CanDeleteInternalModule, iFv)
//GO(SECMOD_CloseUserDB,
//GO(SECMOD_CreateModule,
//GO(SECMOD_CreateModuleEx,
//GO(SECMOD_DeleteInternalModule,
-//GO(SECMOD_DeleteModule,
+GO(SECMOD_DeleteModule, iFpp)
//GO(SECMOD_DeleteModuleEx,
GO(SECMOD_DestroyModule, vFp)
//GO(SECMOD_FindModule,
//GO(SECMOD_FindSlot,
//GO(SECMOD_FreeModuleSpecList,
-//GO(SECMOD_GetDBModuleList,
+GO(SECMOD_GetDBModuleList, pFv)
//GO(SECMOD_GetDeadModuleList,
//GO(SECMOD_GetDefaultModDBFlag,
GO(SECMOD_GetDefaultModuleList, pFv)
@@ -787,13 +787,13 @@ GO(SECMOD_GetReadLock, vFp)
//GO(SECMOD_HasRemovableSlots,
//GO(SECMOD_HasRootCerts,
//GO(SECMOD_InternaltoPubMechFlags,
-//GO(SECMOD_IsModulePresent,
+GO(SECMOD_IsModulePresent, iFL)
//GO(SECMOD_LoadModule,
GO(SECMOD_LoadUserModule, pFppi)
-//GO(SECMOD_LookupSlot,
+GO(SECMOD_LookupSlot, pFLL)
//GO(SECMOD_OpenNewSlot,
GO(SECMOD_OpenUserDB, pFp)
-//GO(SECMOD_PubCipherFlagstoInternal,
+GO(SECMOD_PubCipherFlagstoInternal, LFL)
//GO(SECMOD_PubMechFlagstoInternal,
//GO(SECMOD_ReferenceModule,
GO(SECMOD_ReleaseReadLock, vFp)
@@ -802,60 +802,60 @@ GO(SECMOD_ReleaseReadLock, vFp)
//GO(SECMOD_UpdateModule,
//GO(SECMOD_UpdateSlotList,
//GO(SECMOD_WaitForAnyTokenEvent,
-//GO(SEC_NewCrl,
+GO(SEC_NewCrl, pFpppi)
//DATA(SEC_NullTemplate, //R type
//DATA(SEC_ObjectIDTemplate, //R type
DATA(SEC_OctetStringTemplate, 4*sizeof(void*)) //R type
-GO(SECOID_AddEntry, iFp)
+GO(SECOID_AddEntry, uFp)
DATA(SECOID_AlgorithmIDTemplate, 16*sizeof(void*)) //R type
-//GO(SECOID_CompareAlgorithmID,
-//GO(SECOID_CopyAlgorithmID,
-//GO(SECOID_DestroyAlgorithmID,
-//GO(SECOID_FindOID,
-//GO(SECOID_FindOIDByTag,
-GO(SECOID_FindOIDTag, iFp)
-//GO(SECOID_FindOIDTagDescription,
-//GO(SECOID_GetAlgorithmTag,
-//GO(SECOID_SetAlgorithmID,
-//GO(SEC_PKCS5GetCryptoAlgorithm,
-//GO(SEC_PKCS5GetIV,
-//GO(SEC_PKCS5GetKeyLength,
-//GO(SEC_PKCS5GetPBEAlgorithm,
-//GO(SEC_PKCS5IsAlgorithmPBEAlg,
-//GO(SEC_PKCS5IsAlgorithmPBEAlgTag,
+GO(SECOID_CompareAlgorithmID, iFpp)
+GO(SECOID_CopyAlgorithmID, iFppp)
+GO(SECOID_DestroyAlgorithmID, vFpi)
+GO(SECOID_FindOID, pFp)
+GO(SECOID_FindOIDByTag, pFu)
+GO(SECOID_FindOIDTag, uFp)
+GO(SECOID_FindOIDTagDescription, pFu)
+GO(SECOID_GetAlgorithmTag, uFp)
+GO(SECOID_SetAlgorithmID, iFppup)
+GO(SEC_PKCS5GetCryptoAlgorithm, uFp)
+GO(SEC_PKCS5GetIV, pFppi)
+GO(SEC_PKCS5GetKeyLength, iFp)
+GO(SEC_PKCS5GetPBEAlgorithm, uFui)
+GO(SEC_PKCS5IsAlgorithmPBEAlg, iFp)
+GO(SEC_PKCS5IsAlgorithmPBEAlgTag, iFu)
//DATA(SEC_PointerToAnyTemplate,
//DATA(SEC_PointerToOctetStringTemplate,
GO(SEC_QuickDERDecodeItem, iFpppp)
GO(SEC_RegisterDefaultHttpClient, iFp)
//DATA(SEC_SetOfAnyTemplate,
-//GO(SEC_SignData,
-//GO(SEC_SignDataWithAlgorithmID,
+GO(SEC_SignData, iFppipu)
+GO(SEC_SignDataWithAlgorithmID, iFppipp)
//DATA(SEC_SignedCertificateTemplate,
//DATA(SEC_UTCTimeTemplate, //R type
DATA(SEC_UTF8StringTemplate, 4*sizeof(void*)) //R type
-//GO(SGN_Begin,
-//GO(SGN_CompareDigestInfo,
-//GO(SGN_CopyDigestInfo,
-//GO(SGN_CreateDigestInfo,
-//GO(SGN_DestroyContext,
-//GO(SGN_DestroyDigestInfo,
-//GO(SGN_Digest,
+GO(SGN_Begin, iFp)
+GO(SGN_CompareDigestInfo, iFpp)
+GO(SGN_CopyDigestInfo, iFppp)
+GO(SGN_CreateDigestInfo, pFupu)
+GO(SGN_DestroyContext, vFpi)
+GO(SGN_DestroyDigestInfo, vFp)
+GO(SGN_Digest, iFpupp)
//DATA(sgn_DigestInfoTemplate,
-//GO(SGN_End,
-//GO(SGN_NewContext,
-//GO(SGN_NewContextWithAlgorithmID,
-//GO(SGN_Update,
+GO(SGN_End, iFpp)
+GO(SGN_NewContext, pFup)
+GO(SGN_NewContextWithAlgorithmID, pFpp)
+GO(SGN_Update, iFppu)
//GO(VFY_Begin,
-//GO(VFY_CreateContext,
-//GO(VFY_CreateContextDirect,
-//GO(VFY_CreateContextWithAlgorithmID,
-//GO(VFY_DestroyContext,
-//GO(VFY_End,
-//GO(VFY_EndWithSignature,
-//GO(VFY_Update,
-//GO(VFY_VerifyData,
-//GO(VFY_VerifyDataDirect,
-//GO(VFY_VerifyDataWithAlgorithmID,
-//GO(VFY_VerifyDigest,
-//GO(VFY_VerifyDigestDirect,
-//GO(VFY_VerifyDigestWithAlgorithmID,
+GO(VFY_CreateContext, pFppup)
+GO(VFY_CreateContextDirect, pFppuupp)
+GO(VFY_CreateContextWithAlgorithmID, pFppppp)
+GO(VFY_DestroyContext, vFpi)
+GO(VFY_End, iFp)
+GO(VFY_EndWithSignature, iFpp)
+GO(VFY_Update, iFppu)
+GO(VFY_VerifyData, iFpippup)
+GO(VFY_VerifyDataDirect, iFpippuupp)
+GO(VFY_VerifyDataWithAlgorithmID, iFpippppp)
+GO(VFY_VerifyDigest, iFpppup)
+GO(VFY_VerifyDigestDirect, iFpppuup)
+GO(VFY_VerifyDigestWithAlgorithmID, iFppppup)
diff --git a/src/wrapped/wrappednssutil3.c b/src/wrapped/wrappednssutil3.c
index 7a88495..7a88495 100755..100644
--- a/src/wrapped/wrappednssutil3.c
+++ b/src/wrapped/wrappednssutil3.c
diff --git a/src/wrapped/wrappednssutil3_private.h b/src/wrapped/wrappednssutil3_private.h
index aa81982..aa81982 100755..100644
--- a/src/wrapped/wrappednssutil3_private.h
+++ b/src/wrapped/wrappednssutil3_private.h
diff --git a/src/wrapped/wrappedopenal.c b/src/wrapped/wrappedopenal.c
index 96cc1bb..01b8c8e 100755..100644
--- a/src/wrapped/wrappedopenal.c
+++ b/src/wrapped/wrappedopenal.c
@@ -38,7 +38,7 @@ GO(4)
static uintptr_t my_Request_fct_##A = 0; \
static void my_Request_##A(int32_t a, int32_t b) \
{ \
- RunFunction(my_context, my_Request_fct_##A, 2, a, b); \
+ RunFunctionFmt(my_Request_fct_##A, "ii", a, b); \
}
SUPER()
#undef GO
@@ -113,7 +113,7 @@ void freeALProcWrapper(box64context_t* context)
context->almymap = NULL;
}
-EXPORT void* my_alGetProcAddress(x64emu_t* emu, void* name)
+EXPORT void* my_alGetProcAddress(x64emu_t* emu, void* name)
{
khint_t k;
const char* rname = (const char*)name;
@@ -130,7 +130,7 @@ EXPORT void* my_alGetProcAddress(x64emu_t* emu, void* name)
strcpy(tmp, "my_");
strcat(tmp, rname);
symbol = dlsym(emu->context->box64lib, tmp);
- } else
+ } else
symbol = my->alGetProcAddress(name);
if(!symbol)
return NULL; // easy
@@ -138,7 +138,7 @@ EXPORT void* my_alGetProcAddress(x64emu_t* emu, void* name)
uintptr_t ret = CheckBridged(emu->context->system, symbol);
if(ret)
return (void*)ret; // already bridged
- // get wrapper
+ // get wrapper
k = kh_get(symbolmap, emu->context->alwrappers, rname);
if(k==kh_end(emu->context->alwrappers)) {
printf_log(LOG_INFO, "Warning, no wrapper for %s\n", rname);
@@ -166,14 +166,14 @@ EXPORT void* my_alcGetProcAddress(x64emu_t* emu, void* device, void* name)
strcpy(tmp, "my_");
strcat(tmp, rname);
symbol = dlsym(emu->context->box64lib, tmp);
- } else
+ } else
symbol = my->alcGetProcAddress(device, name);
if(!symbol)
return NULL; // easy
uintptr_t ret = CheckBridged(emu->context->system, symbol);
if(ret)
return (void*)ret; // already bridged
- // get wrapper
+ // get wrapper
k = kh_get(symbolmap, emu->context->alwrappers, rname);
if(k==kh_end(emu->context->alwrappers)) {
printf_log(LOG_INFO, "Warning, no wrapper for %s\n", rname);
diff --git a/src/wrapped/wrappedopenal_private.h b/src/wrapped/wrappedopenal_private.h
index c138559..b0749c1 100755..100644
--- a/src/wrapped/wrappedopenal_private.h
+++ b/src/wrapped/wrappedopenal_private.h
@@ -14,12 +14,12 @@ GO(alGetBooleanv,vFip)
GO(alGetIntegerv,vFip)
GO(alGetFloatv,vFip)
GO(alGetDoublev,vFip)
-GO(alGetBoolean,iFi)
+GO(alGetBoolean, CFi)
GO(alGetInteger,iFi)
GO(alGetFloat,fFi)
GO(alGetDouble,dFi)
GO(alGetError,iFv)
-GO(alIsExtensionPresent,cFp)
+GO(alIsExtensionPresent, CFp)
GOM(alGetProcAddress,pFEp)
GO(alGetEnumValue,iFp)
GO(alListenerf,vFif)
@@ -61,7 +61,7 @@ GO(alSourceQueueBuffers,vFuip)
GO(alSourceUnqueueBuffers,vFuip)
GO(alGenBuffers,vFip)
GO(alDeleteBuffers,vFip)
-GO(alIsBuffer,cFu)
+GO(alIsBuffer, CFu)
GO(alBufferData,vFuipii)
GO(alBufferf,vFuif)
GO(alBuffer3f,vFuifff)
@@ -77,7 +77,7 @@ GO(alGetBuffer3i,vFuippp)
GO(alGetBufferiv,vFuip)
GO(alcCreateContext,pFpp)
-GO(alcMakeContextCurrent,iFp)
+GO(alcMakeContextCurrent, CFp)
GO(alcProcessContext,vFp)
GO(alcSuspendContext,vFp)
GO(alcDestroyContext,vFp)
@@ -86,26 +86,26 @@ GO(alcGetContextsDevice,pFp)
GO(alcOpenDevice,pFp)
GO(alcCloseDevice,iFp)
GO(alcGetError,iFp)
-GO(alcIsExtensionPresent,cFpp)
+GO(alcIsExtensionPresent, CFpp)
GOM(alcGetProcAddress,pFEpp)
GO(alcGetEnumValue,iFpp)
GO(alcGetString,pFpi)
GO(alcGetIntegerv,vFpiip)
GO(alcCaptureOpenDevice,pFpuii)
-GO(alcCaptureCloseDevice,iFp)
+GO(alcCaptureCloseDevice, CFp)
GO(alcCaptureStart,vFp)
GO(alcCaptureStop,vFp)
GO(alcCaptureSamples,vFppi)
GO(alcGetThreadContext, pFv)
-GO(alcSetThreadContext, iFp)
+GO(alcSetThreadContext, CFp)
GO(alcLoopbackOpenDeviceSOFT, pFp)
-GO(alcIsRenderFormatSupportedSOFT, cFpiii)
+GO(alcIsRenderFormatSupportedSOFT, CFpiii)
GO(alcRenderSamplesSOFT, vFppi)
GO(alcDevicePauseSOFT, vFp)
GO(alcDeviceResumeSOFT, vFp)
GO(alcGetStringiSOFT, pFpii)
-GO(alcResetDeviceSOFT, iFpp)
+GO(alcResetDeviceSOFT, CFpp)
GO(alcGetInteger64vSOFT, vFpiip)
GO(alBufferDataStatic,vFiipii)
@@ -115,15 +115,15 @@ GOM(alRequestFoldbackStop,vFEv)
GO(alBufferSamplesSOFT,vFuuiiiip)
GO(alBufferSubSamplesSOFT,vFuiiiip)
GO(alGetBufferSamplesSOFT,vFuiiiip)
-GO(alIsBufferFormatSupportedSOFT,cFi)
+GO(alIsBufferFormatSupportedSOFT, CFi)
GO(alSourcedSOFT,vFuid)
GO(alSource3dSOFT,vFuiddd)
GO(alSourcedvSOFT,vFuip)
GO(alGetSourcedSOFT,vFuip)
GO(alGetSource3dSOFT,vFuippp)
GO(alGetSourcedvSOFT,vFuip)
-GO(alSourcei64SOFT,vFuiI)
-GO(alSource3i64SOFT,vFuiIII)
+GO(alSourcei64SOFT, vFuil)
+GO(alSource3i64SOFT, vFuilll)
GO(alSourcei64vSOFT,vFuip)
GO(alGetSourcei64SOFT,vFuip)
GO(alGetSource3i64SOFT,vFuippp)
@@ -156,7 +156,7 @@ GO(alGetFilterf,vFuip)
GO(alGetFilterfv,vFuip)
GO(alGenAuxiliaryEffectSlots,vFip)
GO(alDeleteAuxiliaryEffectSlots,vFip)
-GO(alIsAuxiliaryEffectSlot,cFu)
+GO(alIsAuxiliaryEffectSlot, CFu)
GO(alAuxiliaryEffectSloti,vFuii)
GO(alAuxiliaryEffectSlotiv,vFuip)
GO(alAuxiliaryEffectSlotf,vFuif)
diff --git a/src/wrapped/wrappedpango.c b/src/wrapped/wrappedpango.c
index dc0ccf4..438ab7d 100755..100644
--- a/src/wrapped/wrappedpango.c
+++ b/src/wrapped/wrappedpango.c
@@ -46,17 +46,17 @@ static my_PangoAttrClass_t my_PangoAttrClass_struct_##A = {0}; \
static uintptr_t my_PangoAttrClass_copy_##A = 0; \
static void* my_PangoAttrClass_copyfct##A(void* attr) \
{ \
- return (void*)RunFunction(my_context, my_PangoAttrClass_copy_##A, 1, attr); \
+ return (void*)RunFunctionFmt(my_PangoAttrClass_copy_##A, "p", attr); \
} \
static uintptr_t my_PangoAttrClass_del_##A = 0; \
static void my_PangoAttrClass_delfct##A(void* attr) \
{ \
- RunFunction(my_context, my_PangoAttrClass_del_##A, 1, attr);\
+ RunFunctionFmt(my_PangoAttrClass_del_##A, "p", attr);\
} \
static uintptr_t my_PangoAttrClass_equal_##A = 0; \
static int my_PangoAttrClass_equalfct##A(void* a, void* b) \
{ \
- return (int)RunFunction(my_context, my_PangoAttrClass_equal_##A, 2, a, b);\
+ return (int)RunFunctionFmt(my_PangoAttrClass_equal_##A, "pp", a, b);\
}
SUPER()
#undef GO
diff --git a/src/wrapped/wrappedpango_private.h b/src/wrapped/wrappedpango_private.h
index b472a4a..db3b905 100755..100644
--- a/src/wrapped/wrappedpango_private.h
+++ b/src/wrapped/wrappedpango_private.h
@@ -45,30 +45,30 @@ GO(pango_attr_stretch_new, pFi)
GO(pango_attr_strikethrough_color_new, pFWWW)
GO(pango_attr_strikethrough_new, pFi)
GO(pango_attr_style_new, pFi)
-GO(pango_attr_type_get_name, pFp)
+GO(pango_attr_type_get_name, pFu)
GO(pango_attr_type_get_type, iFv)
-GO(pango_attr_type_register, iFp)
+GO(pango_attr_type_register, uFp)
GO(pango_attr_underline_color_new, pFWWW)
GO(pango_attr_underline_new, pFi)
GO(pango_attr_variant_new, pFi)
GO(pango_attr_weight_new, pFi)
-//GO(pango_bidi_type_for_unichar,
+GO(pango_bidi_type_for_unichar, uFu)
//GO(pango_bidi_type_get_type,
//GO(pango_break,
GO(pango_color_copy, pFp)
GO(pango_color_free, vFp)
GO(pango_color_get_type, iFv)
GO(pango_color_parse, iFpp)
-//GO(pango_color_to_string,
+GO(pango_color_to_string, pFp)
GO(pango_config_key_get, pFp)
//GO(pango_config_key_get_system,
GO(pango_context_changed, vFp)
-GO(pango_context_get_base_dir, iFp)
+GO(pango_context_get_base_dir, uFp)
GO(pango_context_get_base_gravity, iFp)
GO(pango_context_get_font_description, pFp)
GO(pango_context_get_font_map, pFp)
-GO(pango_context_get_gravity, iFp)
-GO(pango_context_get_gravity_hint, iFp)
+GO(pango_context_get_gravity, uFp)
+GO(pango_context_get_gravity_hint, uFp)
GO(pango_context_get_language, pFp)
GO(pango_context_get_matrix, pFp)
GO(pango_context_get_metrics, pFppp)
@@ -78,33 +78,33 @@ GO(pango_context_list_families, vFppp)
GO(pango_context_load_font, pFpp)
GO(pango_context_load_fontset, pFppp)
GO(pango_context_new, pFv)
-GO(pango_context_set_base_dir, vFpi)
-GO(pango_context_set_base_gravity, vFpi)
+GO(pango_context_set_base_dir, vFpu)
+GO(pango_context_set_base_gravity, vFpu)
GO(pango_context_set_font_description, vFpp)
GO(pango_context_set_font_map, vFpp)
-GO(pango_context_set_gravity_hint, vFpi)
+GO(pango_context_set_gravity_hint, vFpu)
GO(pango_context_set_language, vFpp)
GO(pango_context_set_matrix, vFpp)
-//GO(pango_coverage_copy,
-//GO(pango_coverage_from_bytes,
-//GO(pango_coverage_get,
+GO(pango_coverage_copy, pFp)
+GO(pango_coverage_from_bytes, pFpi)
+GO(pango_coverage_get, uFpi)
//GO(pango_coverage_level_get_type,
-//GO(pango_coverage_max,
-//GO(pango_coverage_new,
+GO(pango_coverage_max, vFpp)
+GO(pango_coverage_new, pFv)
//GO(pango_coverage_ref,
-//GO(pango_coverage_set,
-//GO(pango_coverage_to_bytes,
+GO(pango_coverage_set, vFpiu)
+GO(pango_coverage_to_bytes, vFppp)
//GO(pango_coverage_unref,
-//GO(pango_default_break,
+GO(pango_default_break, vFpippi)
//GO(pango_direction_get_type,
GO(pango_ellipsize_mode_get_type, lFv)
//GO(pango_engine_get_type,
//GO(pango_engine_lang_get_type,
//GO(pango_engine_shape_get_type,
GO(pango_extents_to_pixels, vFpp)
-//GO(pango_find_base_dir,
+GO(pango_find_base_dir, uFpi)
//GO(pango_find_map,
-//GO(pango_find_paragraph_boundary,
+GO(pango_find_paragraph_boundary, vFpipp)
GO(pango_font_describe, pFp)
GO(pango_font_describe_with_absolute_size, pFp)
GO(pango_font_description_better_match, iFppp)
@@ -114,15 +114,15 @@ GO(pango_font_description_equal, iFpp)
GO(pango_font_description_free, vFp)
GO(pango_font_description_from_string, pFp)
GO(pango_font_description_get_family, pFp)
-GO(pango_font_description_get_gravity, iFp)
-GO(pango_font_description_get_set_fields, iFp)
+GO(pango_font_description_get_gravity, uFp)
+GO(pango_font_description_get_set_fields, uFp)
GO(pango_font_description_get_size, iFp)
GO(pango_font_description_get_size_is_absolute, iFp)
-GO(pango_font_description_get_stretch, iFp)
-GO(pango_font_description_get_style, iFp)
+GO(pango_font_description_get_stretch, uFp)
+GO(pango_font_description_get_style, uFp)
GO(pango_font_description_get_type, iFv)
-GO(pango_font_description_get_variant, vFpi)
-GO(pango_font_description_get_weight, iFp)
+GO(pango_font_description_get_variant, uFp)
+GO(pango_font_description_get_weight, uFp)
GO(pango_font_description_hash, uFp)
GO(pango_font_description_merge, vFppi)
GO(pango_font_description_merge_static, vFppi)
@@ -130,16 +130,16 @@ GO(pango_font_description_new, pFv)
GO(pango_font_description_set_absolute_size, vFpd)
GO(pango_font_description_set_family, vFpp)
GO(pango_font_description_set_family_static, vFpp)
-GO(pango_font_description_set_gravity, vFpi)
+GO(pango_font_description_set_gravity, vFpu)
GO(pango_font_description_set_size, vFpi)
-GO(pango_font_description_set_stretch, vFpi)
-GO(pango_font_description_set_style, vFpi)
-GO(pango_font_description_set_variant, vFpi)
-GO(pango_font_description_set_weight, vFpi)
+GO(pango_font_description_set_stretch, vFpu)
+GO(pango_font_description_set_style, vFpu)
+GO(pango_font_description_set_variant, vFpu)
+GO(pango_font_description_set_weight, vFpu)
GO(pango_font_descriptions_free, vFpi)
GO(pango_font_description_to_filename, pFp)
GO(pango_font_description_to_string, pFp)
-GO(pango_font_description_unset_fields, vFpi)
+GO(pango_font_description_unset_fields, vFpu)
GO(pango_font_face_describe, pFp)
GO(pango_font_face_get_face_name, pFp)
GO(pango_font_face_get_type, iFv)
@@ -152,7 +152,7 @@ GO(pango_font_family_list_faces, vFppp)
GO(pango_font_find_shaper, pFppu)
GO(pango_font_get_coverage, pFpp)
GO(pango_font_get_font_map, pFp)
-GO(pango_font_get_glyph_extents, vFpppp)
+GO(pango_font_get_glyph_extents, vFpupp)
GO(pango_font_get_metrics, pFpp)
GO(pango_font_get_type, iFv)
GO(pango_font_map_create_context, pFp)
@@ -179,13 +179,13 @@ GO(pango_font_metrics_unref, vFp)
GO(pango_fontset_get_font, pFpu)
GO(pango_fontset_get_metrics, pFp)
//GO(pango_fontset_get_type,
-//GO(pango_fontset_simple_append,
+GO(pango_fontset_simple_append, vFpp)
//GO(pango_fontset_simple_get_type,
-//GO(pango_fontset_simple_new,
-//GO(pango_fontset_simple_size,
+GO(pango_fontset_simple_new, pFp)
+GO(pango_fontset_simple_size, iFp)
//GO(pango_get_lib_subdirectory,
-//GO(pango_get_log_attrs,
-//GO(pango_get_mirror_char,
+GO(pango_get_log_attrs, vFpiippi)
+GO(pango_get_mirror_char, iFup)
//GO(pango_get_sysconf_subdirectory,
GO(pango_glyph_item_apply_attrs, pFppp)
GO(pango_glyph_item_copy, pFp)
@@ -212,20 +212,20 @@ GO(pango_glyph_string_index_to_x, vFppipiip)
GO(pango_glyph_string_new, pFv)
GO(pango_glyph_string_set_size, vFpi)
GO(pango_glyph_string_x_to_index, vFppipipp)
-//GO(pango_gravity_get_for_matrix,
-//GO(pango_gravity_get_for_script,
-//GO(pango_gravity_get_for_script_and_width,
+GO(pango_gravity_get_for_matrix, uFp)
+GO(pango_gravity_get_for_script, uFiuu)
+GO(pango_gravity_get_for_script_and_width, uFiiuu)
GO(pango_gravity_get_type, iFv)
//GO(pango_gravity_hint_get_type,
-//GO(pango_gravity_to_rotation,
-//GO(pango_is_zero_width,
-//GO(pango_item_copy,
-//GO(pango_item_free,
+GO(pango_gravity_to_rotation, dFu)
+GO(pango_is_zero_width, iFu)
+GO(pango_item_copy, pFp)
+GO(pango_item_free, vFp)
//GO(pango_item_get_type,
-//GO(pango_itemize,
-//GO(pango_itemize_with_base_dir,
-//GO(pango_item_new,
-//GO(pango_item_split,
+GO(pango_itemize, pFppiipp)
+GO(pango_itemize_with_base_dir, pFpupiipp)
+GO(pango_item_new, pFv)
+GO(pango_item_split, pFpii)
GO(pango_language_from_string, pFp)
GO(pango_language_get_default, pFv)
GO(pango_language_get_sample_string, pFp)
@@ -236,14 +236,14 @@ GO(pango_language_matches, iFpp)
GO(pango_language_to_string, pFp)
GO(pango_layout_context_changed, vFp)
GO(pango_layout_copy, pFp)
-GO(pango_layout_get_alignment, iFp)
+GO(pango_layout_get_alignment, uFp)
GO(pango_layout_get_attributes, pFp)
GO(pango_layout_get_auto_dir, iFp)
GO(pango_layout_get_baseline, iFp)
GO(pango_layout_get_character_count, iFp)
GO(pango_layout_get_context, pFp)
GO(pango_layout_get_cursor_pos, vFpipp)
-GO(pango_layout_get_ellipsize, iFp)
+GO(pango_layout_get_ellipsize, uFp)
GO(pango_layout_get_extents, vFppp)
GO(pango_layout_get_font_description, pFp)
GO(pango_layout_get_height, iFp)
@@ -268,7 +268,7 @@ GO(pango_layout_get_text, pFp)
GO(pango_layout_get_type, iFv)
GO(pango_layout_get_unknown_glyphs_count, iFp)
GO(pango_layout_get_width, iFp)
-GO(pango_layout_get_wrap, iFp)
+GO(pango_layout_get_wrap, uFp)
GO(pango_layout_index_to_line_x, vFpiipp)
GO(pango_layout_index_to_pos, vFpip)
GO(pango_layout_is_ellipsized, iFp)
@@ -304,10 +304,10 @@ GO(pango_layout_line_unref, vFp)
GO(pango_layout_line_x_to_index, iFpipp)
GO(pango_layout_move_cursor_visually, vFpiiiipp)
GO(pango_layout_new, pFp)
-GO(pango_layout_set_alignment, vFpi)
+GO(pango_layout_set_alignment, vFpu)
GO(pango_layout_set_attributes, vFpp)
GO(pango_layout_set_auto_dir, vFpi)
-GO(pango_layout_set_ellipsize, vFpi)
+GO(pango_layout_set_ellipsize, vFpu)
GO(pango_layout_set_font_description, vFpp)
GO(pango_layout_set_height, vFpi)
GO(pango_layout_set_indent, vFpi)
@@ -319,13 +319,13 @@ GO(pango_layout_set_spacing, vFpi)
GO(pango_layout_set_tabs, vFpp)
GO(pango_layout_set_text, vFppi)
GO(pango_layout_set_width, vFpi)
-GO(pango_layout_set_wrap, vFpi)
+GO(pango_layout_set_wrap, vFpu)
GO(pango_layout_xy_to_index, iFpiipp)
-//GO(pango_log2vis_get_embedding_levels,
+GO(pango_log2vis_get_embedding_levels, pFpip)
//GO(pango_lookup_aliases,
//GO(pango_map_get_engine,
//GO(pango_map_get_engines,
-//GO(pango_markup_parser_finish,
+GO(pango_markup_parser_finish, iFppppp)
GO(pango_markup_parser_new, pFu)
GO(pango_matrix_concat, vFpp)
GO(pango_matrix_copy, pFp)
@@ -341,34 +341,34 @@ GO(pango_matrix_transform_point, vFppp)
GO(pango_matrix_transform_rectangle, vFpp)
GO(pango_matrix_translate, vFpdd)
//GO(pango_module_register,
-//GO(pango_parse_enum,
+GO(pango_parse_enum, iFLppip)
GO(pango_parse_markup, iFpiupppp)
-//GO(pango_parse_stretch,
-//GO(pango_parse_style,
-//GO(pango_parse_variant,
-//GO(pango_parse_weight,
-//GO(pango_quantize_line_geometry,
+GO(pango_parse_stretch, iFppi)
+GO(pango_parse_style, iFppi)
+GO(pango_parse_variant, iFppi)
+GO(pango_parse_weight, iFppi)
+GO(pango_quantize_line_geometry, vFpp)
GO(pango_read_line, iFpp)
//GO(pango_renderer_activate,
-//GO(pango_renderer_deactivate,
-//GO(pango_renderer_draw_error_underline,
-//GO(pango_renderer_draw_glyph,
-//GO(pango_renderer_draw_glyph_item,
-//GO(pango_renderer_draw_glyphs,
-//GO(pango_renderer_draw_layout,
-//GO(pango_renderer_draw_layout_line,
-//GO(pango_renderer_draw_rectangle,
-//GO(pango_renderer_draw_trapezoid,
-//GO(pango_renderer_get_color,
-//GO(pango_renderer_get_layout,
-//GO(pango_renderer_get_layout_line,
-//GO(pango_renderer_get_matrix,
-//GO(pango_renderer_get_type,
-//GO(pango_renderer_part_changed,
-//GO(pango_renderer_set_color,
-//GO(pango_renderer_set_matrix,
+GO(pango_renderer_deactivate, vFp)
+GO(pango_renderer_draw_error_underline, vFpiiii)
+GO(pango_renderer_draw_glyph, vFppudd)
+GO(pango_renderer_draw_glyph_item, vFpppii)
+GO(pango_renderer_draw_glyphs, vFpppii)
+GO(pango_renderer_draw_layout, vFppii)
+GO(pango_renderer_draw_layout_line, vFppii)
+GO(pango_renderer_draw_rectangle, vFpuiiii)
+GO(pango_renderer_draw_trapezoid, vFpudddddd)
+GO(pango_renderer_get_color, pFpu)
+GO(pango_renderer_get_layout, pFp)
+GO(pango_renderer_get_layout_line, pFp)
+GO(pango_renderer_get_matrix, pFp)
+GO(pango_renderer_get_type, LFv)
+GO(pango_renderer_part_changed, vFpu)
+GO(pango_renderer_set_color, vFpup)
+GO(pango_renderer_set_matrix, vFpp)
//GO(pango_render_part_get_type,
-//GO(pango_reorder_items,
+GO(pango_reorder_items, pFp)
GO(pango_scan_int, iFpp)
GO(pango_scan_string, iFpp)
GO(pango_scan_word, iFpp)
@@ -379,8 +379,8 @@ GO(pango_script_iter_free, vFp)
GO(pango_script_iter_get_range, vFpppp)
GO(pango_script_iter_new, pFpi)
GO(pango_script_iter_next, iFp)
-//GO(pango_shape,
-//GO(pango_shape_full,
+GO(pango_shape, vFpipp)
+GO(pango_shape_full, vFpipipp)
GO(pango_skip_space, iFp)
GO(pango_split_file_list, pFp)
GO(pango_stretch_get_type, iFv)
@@ -396,10 +396,10 @@ GO(pango_tab_array_get_type, iFv)
GO(pango_tab_array_new, pFii)
GO(pango_tab_array_new_with_positions, pFiiiippppppppppppppp) //vaarg
GO(pango_tab_array_resize, vFpi)
-GO(pango_tab_array_set_tab, vFpiii)
+GO(pango_tab_array_set_tab, vFpiui)
GO(pango_trim_string, pFp)
GO(pango_underline_get_type, iFv)
-GO(pango_unichar_direction, iFu)
+GO(pango_unichar_direction, uFu)
GO(pango_units_from_double, iFd)
GO(pango_units_to_double, dFi)
GO(pango_variant_get_type, pFv)
diff --git a/src/wrapped/wrappedpangocairo.c b/src/wrapped/wrappedpangocairo.c
index d1b2017..d1b2017 100755..100644
--- a/src/wrapped/wrappedpangocairo.c
+++ b/src/wrapped/wrappedpangocairo.c
diff --git a/src/wrapped/wrappedpangocairo_private.h b/src/wrapped/wrappedpangocairo_private.h
index 946e195..a39d0b9 100755..100644
--- a/src/wrapped/wrappedpangocairo_private.h
+++ b/src/wrapped/wrappedpangocairo_private.h
@@ -14,14 +14,14 @@ GO(pango_cairo_error_underline_path, vFpdddd)
GO(pango_cairo_fc_font_get_type, iFv)
GO(pango_cairo_fc_font_map_get_type, iFv)
GO(pango_cairo_font_get_scaled_font, pFp)
-GO(pango_cairo_font_get_type, iFv)
+GO(pango_cairo_font_get_type, LFv)
GO(pango_cairo_font_map_create_context, pFp)
GO(pango_cairo_font_map_get_default, pFv)
-GO(pango_cairo_font_map_get_font_type, iFp)
+GO(pango_cairo_font_map_get_font_type, uFp)
GO(pango_cairo_font_map_get_resolution, dFp)
GO(pango_cairo_font_map_get_type, iFv)
GO(pango_cairo_font_map_new, pFv)
-GO(pango_cairo_font_map_new_for_font_type, pFi)
+GO(pango_cairo_font_map_new_for_font_type, pFu)
GO(pango_cairo_font_map_set_default, vFp)
GO(pango_cairo_font_map_set_resolution, vFpd)
GO(pango_cairo_glyph_string_path, vFppp)
diff --git a/src/wrapped/wrappedpangoft2.c b/src/wrapped/wrappedpangoft2.c
index 3a9838b..3a9838b 100755..100644
--- a/src/wrapped/wrappedpangoft2.c
+++ b/src/wrapped/wrappedpangoft2.c
diff --git a/src/wrapped/wrappedpangoft2_private.h b/src/wrapped/wrappedpangoft2_private.h
index 03f7b30..0d12f7f 100755..100644
--- a/src/wrapped/wrappedpangoft2_private.h
+++ b/src/wrapped/wrappedpangoft2_private.h
@@ -39,7 +39,7 @@ GO(pango_ft2_font_get_kerning, iFpuu)
GO(pango_ft2_font_get_type, iFv)
GO(pango_ft2_font_map_create_context, pFp)
GO(pango_ft2_font_map_for_display, pFv)
-GO(pango_ft2_font_map_get_type, iFv)
+GO(pango_ft2_font_map_get_type, LFv)
GO(pango_ft2_font_map_new, pFv)
//GOM(pango_ft2_font_map_set_default_substitute, vFEpBpB)
GO(pango_ft2_font_map_set_resolution, vFpdd)
diff --git a/src/wrapped/wrappedplc4.c b/src/wrapped/wrappedplc4.c
index 1f6e779..1f6e779 100755..100644
--- a/src/wrapped/wrappedplc4.c
+++ b/src/wrapped/wrappedplc4.c
diff --git a/src/wrapped/wrappedplc4_private.h b/src/wrapped/wrappedplc4_private.h
index ae4adee..ae4adee 100755..100644
--- a/src/wrapped/wrappedplc4_private.h
+++ b/src/wrapped/wrappedplc4_private.h
diff --git a/src/wrapped/wrappedplds4.c b/src/wrapped/wrappedplds4.c
index f3a94af..f3a94af 100755..100644
--- a/src/wrapped/wrappedplds4.c
+++ b/src/wrapped/wrappedplds4.c
diff --git a/src/wrapped/wrappedplds4_private.h b/src/wrapped/wrappedplds4_private.h
index ccf0049..ccf0049 100755..100644
--- a/src/wrapped/wrappedplds4_private.h
+++ b/src/wrapped/wrappedplds4_private.h
diff --git a/src/wrapped/wrappedpng16.c b/src/wrapped/wrappedpng16.c
index 22bb9e5..290162b 100755..100644
--- a/src/wrapped/wrappedpng16.c
+++ b/src/wrapped/wrappedpng16.c
@@ -41,7 +41,7 @@ GO(3)
static uintptr_t my_user_write_fct_##A = 0; \
static void my_user_write_##A(void* png_ptr, void* data, int32_t length) \
{ \
- RunFunction(my_context, my_user_write_fct_##A, 3, png_ptr, data, length);\
+ RunFunctionFmt(my_user_write_fct_##A, "ppi", png_ptr, data, length);\
}
SUPER()
#undef GO
@@ -63,7 +63,7 @@ static void* finduser_writeFct(void* fct)
static uintptr_t my_user_flush_fct_##A = 0; \
static void my_user_flush_##A(void* png_ptr) \
{ \
- RunFunction(my_context, my_user_flush_fct_##A, 1, png_ptr);\
+ RunFunctionFmt(my_user_flush_fct_##A, "p", png_ptr);\
}
SUPER()
#undef GO
@@ -85,7 +85,7 @@ static void* finduser_flushFct(void* fct)
static uintptr_t my_user_read_fct_##A = 0; \
static void my_user_read_##A(void* png_ptr, void* data, int32_t length) \
{ \
- RunFunction(my_context, my_user_read_fct_##A, 3, png_ptr, data, length);\
+ RunFunctionFmt(my_user_read_fct_##A, "ppi", png_ptr, data, length);\
}
SUPER()
#undef GO
@@ -107,7 +107,7 @@ static void* finduser_readFct(void* fct)
static uintptr_t my_error_fct_##A = 0; \
static void my_error_##A(void* a, void* b) \
{ \
- RunFunction(my_context, my_error_fct_##A, 2, a, b);\
+ RunFunctionFmt(my_error_fct_##A, "pp", a, b);\
}
SUPER()
#undef GO
@@ -129,7 +129,7 @@ static void* finderrorFct(void* fct)
static uintptr_t my_warning_fct_##A = 0; \
static void my_warning_##A(void* a, void* b) \
{ \
- RunFunction(my_context, my_warning_fct_##A, 2, a, b);\
+ RunFunctionFmt(my_warning_fct_##A, "pp", a, b);\
}
SUPER()
#undef GO
@@ -151,7 +151,7 @@ static void* findwarningFct(void* fct)
static uintptr_t my_malloc_fct_##A = 0; \
static void my_malloc_##A(void* a, unsigned long b) \
{ \
- RunFunction(my_context, my_malloc_fct_##A, 2, a, b);\
+ RunFunctionFmt(my_malloc_fct_##A, "pL", a, b);\
}
SUPER()
#undef GO
@@ -173,7 +173,7 @@ static void* findmallocFct(void* fct)
static uintptr_t my_free_fct_##A = 0; \
static void my_free_##A(void* a, void* b) \
{ \
- RunFunction(my_context, my_free_fct_##A, 2, a, b);\
+ RunFunctionFmt(my_free_fct_##A, "pp", a, b);\
}
SUPER()
#undef GO
@@ -196,7 +196,7 @@ static void* findfreeFct(void* fct)
static uintptr_t my_progressive_info_fct_##A = 0; \
static void my_progressive_info_##A(void* a, void* b) \
{ \
- RunFunction(my_context, my_progressive_info_fct_##A, 2, a, b);\
+ RunFunctionFmt(my_progressive_info_fct_##A, "pp", a, b);\
}
SUPER()
#undef GO
@@ -219,7 +219,7 @@ static void* findprogressive_infoFct(void* fct)
static uintptr_t my_progressive_end_fct_##A = 0; \
static void my_progressive_end_##A(void* a, void* b) \
{ \
- RunFunction(my_context, my_progressive_end_fct_##A, 2, a, b);\
+ RunFunctionFmt(my_progressive_end_fct_##A, "pp", a, b);\
}
SUPER()
#undef GO
@@ -242,7 +242,7 @@ static void* findprogressive_endFct(void* fct)
static uintptr_t my_progressive_row_fct_##A = 0; \
static void my_progressive_row_##A(void* a, void* b, uint32_t c, int d) \
{ \
- RunFunction(my_context, my_progressive_row_fct_##A, 4, a, b, c, d);\
+ RunFunctionFmt(my_progressive_row_fct_##A, "ppui", a, b, c, d);\
}
SUPER()
#undef GO
@@ -266,7 +266,7 @@ static void* findprogressive_rowFct(void* fct)
static uintptr_t my_user_transform_fct_##A = 0; \
static void my_user_transform_##A(void* ptr, void* row, void* data) \
{ \
- RunFunction(my_context, my_user_transform_fct_##A, 3, ptr, row, data);\
+ RunFunctionFmt(my_user_transform_fct_##A, "ppp", ptr, row, data);\
}
SUPER()
#undef GO
diff --git a/src/wrapped/wrappedpng16_private.h b/src/wrapped/wrappedpng16_private.h
index 3a7e4d5..0891d45 100755..100644
--- a/src/wrapped/wrappedpng16_private.h
+++ b/src/wrapped/wrappedpng16_private.h
@@ -87,6 +87,7 @@ GO(png_set_cHRM, vFppdddddddd)
GO(png_permit_mng_features, uFpu)
GO(png_set_keep_unknown_chunks, vFpipi)
GO(png_set_oFFs, vFppiii)
+GO(png_set_option, iFpii)
GO(png_get_libpng_ver, pFp)
GO(png_get_text, uFpppp)
GO(png_set_sBIT, vFppp)
diff --git a/src/wrapped/wrappedpulse.c b/src/wrapped/wrappedpulse.c
index 02233aa..f5ec5d4 100755..100644
--- a/src/wrapped/wrappedpulse.c
+++ b/src/wrapped/wrappedpulse.c
@@ -49,7 +49,7 @@ typedef void (*vFipippV_t)(int, void*, int, void*, void*, va_list);
#else
typedef void (*vFipippV_t)(int, void*, int, void*, void*, void*);
#endif
- GO(pa_log_level_meta, vFipippV_t)
+ GO(pa_log_level_meta, vFipippV_t)
#endif
#define ADDED_FUNCTIONS() \
@@ -91,7 +91,7 @@ GO(15) \
static uintptr_t my_free_fct_##A = 0; \
static void my_free_##A(void* data) \
{ \
- RunFunction(my_context, my_free_fct_##A, 1, data);\
+ RunFunctionFmt(my_free_fct_##A, "p", data);\
}
SUPER()
#undef GO
@@ -113,7 +113,7 @@ static void* findFreeFct(void* fct)
static uintptr_t my_free_api_fct_##A = 0; \
static void my_free_api_##A(my_pa_mainloop_api_t* api, void* p, void* data) \
{ \
- RunFunction(my_context, my_free_api_fct_##A, 3, api, p, data);\
+ RunFunctionFmt(my_free_api_fct_##A, "ppp", api, p, data);\
}
SUPER()
#undef GO
@@ -136,7 +136,7 @@ static uintptr_t my_io_event_fct_##A = 0; \
static void my_io_event_##A(my_pa_mainloop_api_t* api, void* e, int fd, int events, void* data) \
{ \
if(api==my_mainloop_orig) api=my_mainloop_ref; \
- RunFunction(my_context, my_io_event_fct_##A, 5, api, e, fd, events, data); \
+ RunFunctionFmt(my_io_event_fct_##A, "ppiip", api, e, fd, events, data); \
}
SUPER()
#undef GO
@@ -159,7 +159,7 @@ static uintptr_t my_time_event_fct_##A = 0; \
static void my_time_event_##A(my_pa_mainloop_api_t* api, void* e, void* tv, void* data) \
{ \
if(api==my_mainloop_orig) api=my_mainloop_ref; \
- RunFunction(my_context, my_time_event_fct_##A, 4, api, e, tv, data); \
+ RunFunctionFmt(my_time_event_fct_##A, "pppp", api, e, tv, data); \
}
SUPER()
#undef GO
@@ -183,7 +183,7 @@ static uintptr_t my_defer_event_fct_##A = 0; \
static void my_defer_event_##A(my_pa_mainloop_api_t* api, void* e, void* data) \
{ \
if(api==my_mainloop_orig) api=my_mainloop_ref; \
- RunFunction(my_context, my_defer_event_fct_##A, 3, api, e, data); \
+ RunFunctionFmt(my_defer_event_fct_##A, "ppp", api, e, data); \
}
SUPER()
#undef GO
@@ -206,7 +206,7 @@ static void* findDeferEventFct(void* fct)
static uintptr_t my_poll_fct_##A = 0; \
static int my_poll_##A(void* ufds, unsigned long nfds, int timeout, void* data) \
{ \
- return (int)RunFunction(my_context, my_poll_fct_##A, 4, ufds, nfds, timeout, data); \
+ return (int)RunFunctionFmt(my_poll_fct_##A, "pLip", ufds, nfds, timeout, data); \
}
SUPER()
#undef GO
@@ -229,7 +229,7 @@ static uintptr_t my_signal_fct_##A = 0; \
static void my_signal_##A(my_pa_mainloop_api_t* api, void* e, int sig, void *data) \
{ \
if(api==my_mainloop_orig) api=my_mainloop_ref; \
- RunFunction(my_context, my_signal_fct_##A, 4, api, e, sig, data); \
+ RunFunctionFmt(my_signal_fct_##A, "ppip", api, e, sig, data); \
}
SUPER()
#undef GO
@@ -252,7 +252,7 @@ static uintptr_t my_signal_destroy_fct_##A = 0; \
static void my_signal_destroy_##A(my_pa_mainloop_api_t* api, void* e, void *data) \
{ \
if(api==my_mainloop_orig) api=my_mainloop_ref; \
- RunFunction(my_context, my_signal_destroy_fct_##A, 3, api, e, data); \
+ RunFunctionFmt(my_signal_destroy_fct_##A, "ppp", api, e, data); \
}
SUPER()
#undef GO
@@ -275,7 +275,7 @@ static void* find_signal_destroy_Fct(void* fct)
static uintptr_t my_prefork_fct_##A = 0; \
static void my_prefork_##A() \
{ \
- RunFunction(my_context, my_prefork_fct_##A, 0); \
+ RunFunctionFmt(my_prefork_fct_##A, ""); \
}
SUPER()
#undef GO
@@ -297,7 +297,7 @@ static void* find_prefork_Fct(void* fct)
static uintptr_t my_postfork_fct_##A = 0; \
static void my_postfork_##A() \
{ \
- RunFunction(my_context, my_postfork_fct_##A, 0);\
+ RunFunctionFmt(my_postfork_fct_##A, "");\
}
SUPER()
#undef GO
@@ -319,7 +319,7 @@ static void* find_postfork_Fct(void* fct)
static uintptr_t my_atfork_fct_##A = 0; \
static void my_atfork_##A() \
{ \
- RunFunction(my_context, my_atfork_fct_##A, 0); \
+ RunFunctionFmt(my_atfork_fct_##A, ""); \
}
SUPER()
#undef GO
@@ -342,7 +342,7 @@ static void* find_atfork_Fct(void* fct)
static uintptr_t my_state_context_fct_##A = 0; \
static void my_state_context_##A(void* context, void* data) \
{ \
- RunFunction(my_context, my_state_context_fct_##A, 2, context, data); \
+ RunFunctionFmt(my_state_context_fct_##A, "pp", context, data); \
}
SUPER()
#undef GO
@@ -364,7 +364,7 @@ static void* find_state_context_Fct(void* fct)
static uintptr_t my_notify_context_fct_##A = 0; \
static void my_notify_context_##A(void* context, void* data) \
{ \
- RunFunction(my_context, my_notify_context_fct_##A, 2, context, data); \
+ RunFunctionFmt(my_notify_context_fct_##A, "pp", context, data); \
}
SUPER()
#undef GO
@@ -386,7 +386,7 @@ static void* find_notify_context_Fct(void* fct)
static uintptr_t my_success_context_fct_##A = 0; \
static void my_success_context_##A(void* context, int success, void* data) \
{ \
- RunFunction(my_context, my_success_context_fct_##A, 3, context, success, data); \
+ RunFunctionFmt(my_success_context_fct_##A, "pip", context, success, data); \
}
SUPER()
#undef GO
@@ -408,7 +408,7 @@ static void* find_success_context_Fct(void* fct)
static uintptr_t my_event_context_fct_##A = 0; \
static void my_event_context_##A(void* context, void* name, void* p, void* data) \
{ \
- RunFunction(my_context, my_event_context_fct_##A, 4, context, name, p, data); \
+ RunFunctionFmt(my_event_context_fct_##A, "pppp", context, name, p, data); \
}
SUPER()
#undef GO
@@ -430,7 +430,7 @@ static void* find_event_context_Fct(void* fct)
static uintptr_t my_module_info_fct_##A = 0; \
static void my_module_info_##A(void* context, void* i, int eol, void* data) \
{ \
- RunFunction(my_context, my_module_info_fct_##A, 4, context, i, eol, data); \
+ RunFunctionFmt(my_module_info_fct_##A, "ppip", context, i, eol, data); \
}
SUPER()
#undef GO
@@ -452,7 +452,7 @@ static void* find_module_info_Fct(void* fct)
static uintptr_t my_server_info_fct_##A = 0; \
static void my_server_info_##A(void* context, void* i, void* data) \
{ \
- RunFunction(my_context, my_server_info_fct_##A, 3, context, i, data); \
+ RunFunctionFmt(my_server_info_fct_##A, "ppp", context, i, data); \
}
SUPER()
#undef GO
@@ -474,7 +474,7 @@ static void* find_server_info_Fct(void* fct)
static uintptr_t my_client_info_fct_##A = 0; \
static void my_client_info_##A(void* context, void* i, int eol, void* data) \
{ \
- RunFunction(my_context, my_client_info_fct_##A, 4, context, i, eol, data); \
+ RunFunctionFmt(my_client_info_fct_##A, "ppip", context, i, eol, data); \
}
SUPER()
#undef GO
@@ -496,7 +496,7 @@ static void* find_client_info_Fct(void* fct)
static uintptr_t my_context_index_fct_##A = 0; \
static void my_context_index_##A(void* context, uint32_t idx, void* data) \
{ \
- RunFunction(my_context, my_context_index_fct_##A, 3, context, idx, data); \
+ RunFunctionFmt(my_context_index_fct_##A, "pup", context, idx, data); \
}
SUPER()
#undef GO
@@ -518,7 +518,7 @@ static void* find_context_index_Fct(void* fct)
static uintptr_t my_subscribe_context_fct_##A = 0; \
static void my_subscribe_context_##A(void* context, int evt, uint32_t idx, void* data) \
{ \
- RunFunction(my_context, my_subscribe_context_fct_##A, 4, context, evt, idx, data); \
+ RunFunctionFmt(my_subscribe_context_fct_##A, "piup", context, evt, idx, data); \
}
SUPER()
#undef GO
@@ -541,7 +541,7 @@ static void* find_subscribe_context_Fct(void* fct)
static uintptr_t my_stream_state_fct_##A = 0; \
static void my_stream_state_##A(void* s, void* data) \
{ \
- RunFunction(my_context, my_stream_state_fct_##A, 2, s, data); \
+ RunFunctionFmt(my_stream_state_fct_##A, "pp", s, data); \
}
SUPER()
#undef GO
@@ -563,7 +563,7 @@ static void* find_stream_state_Fct(void* fct)
static uintptr_t my_stream_success_fct_##A = 0; \
static void my_stream_success_##A(void* s, int success, void* data) \
{ \
- RunFunction(my_context, my_stream_success_fct_##A, 3, s, success, data); \
+ RunFunctionFmt(my_stream_success_fct_##A, "pip", s, success, data); \
}
SUPER()
#undef GO
@@ -585,7 +585,7 @@ static void* find_stream_success_Fct(void* fct)
static uintptr_t my_stream_notify_fct_##A = 0; \
static void my_stream_notify_##A(void* s, void* data) \
{ \
- RunFunction(my_context, my_stream_notify_fct_##A, 2, s, data); \
+ RunFunctionFmt(my_stream_notify_fct_##A, "pp", s, data); \
}
SUPER()
#undef GO
@@ -607,7 +607,7 @@ static void* find_stream_notify_Fct(void* fct)
static uintptr_t my_stream_event_fct_##A = 0; \
static void my_stream_event_##A(void* s, void* name, void* pl, void* data) \
{ \
- RunFunction(my_context, my_stream_event_fct_##A, 4, s, name, pl, data); \
+ RunFunctionFmt(my_stream_event_fct_##A, "pppp", s, name, pl, data); \
}
SUPER()
#undef GO
@@ -629,7 +629,7 @@ static void* find_stream_event_Fct(void* fct)
static uintptr_t my_stream_request_fct_##A = 0; \
static void my_stream_request_##A(void* s, size_t nbytes, void* data) \
{ \
- RunFunction(my_context, my_stream_request_fct_##A, 3, s, nbytes, data); \
+ RunFunctionFmt(my_stream_request_fct_##A, "pLp", s, nbytes, data); \
}
SUPER()
#undef GO
@@ -651,7 +651,7 @@ static void* find_stream_request_Fct(void* fct)
static uintptr_t my_device_restore_read_device_formats_fct_##A = 0; \
static void my_device_restore_read_device_formats_##A(void* a, void* b, int c, void* d) \
{ \
- RunFunction(my_context, my_device_restore_read_device_formats_fct_##A, 4, a, b, c, d); \
+ RunFunctionFmt(my_device_restore_read_device_formats_fct_##A, "ppip", a, b, c, d); \
}
SUPER()
#undef GO
@@ -673,7 +673,7 @@ static void* find_device_restore_read_device_formats_Fct(void* fct)
static uintptr_t my_card_info_fct_##A = 0; \
static void my_card_info_##A(void* a, void* b, int c, void* d) \
{ \
- RunFunction(my_context, my_card_info_fct_##A, 4, a, b, c, d); \
+ RunFunctionFmt(my_card_info_fct_##A, "ppip", a, b, c, d); \
}
SUPER()
#undef GO
@@ -695,7 +695,7 @@ static void* find_card_info_Fct(void* fct)
static uintptr_t my_source_output_info_fct_##A = 0; \
static void my_source_output_info_##A(void* a, void* b, int c, void* d) \
{ \
- RunFunction(my_context, my_source_output_info_fct_##A, 4, a, b, c, d); \
+ RunFunctionFmt(my_source_output_info_fct_##A, "ppip", a, b, c, d); \
}
SUPER()
#undef GO
@@ -717,7 +717,7 @@ static void* find_source_output_info_Fct(void* fct)
static uintptr_t my_device_restore_subscribe_fct_##A = 0; \
static void my_device_restore_subscribe_##A(void* a, int b, uint32_t c, void* d) \
{ \
- RunFunction(my_context, my_device_restore_subscribe_fct_##A, 4, a, b, c, d); \
+ RunFunctionFmt(my_device_restore_subscribe_fct_##A, "piup", a, b, c, d); \
}
SUPER()
#undef GO
@@ -830,7 +830,7 @@ static void* my_io_new(void* api, int fd, int events, void* cb, void *userdata)
if(cb)
b = AddCheckBridge(bridge, vFppiip, cb, 0, NULL);
if(api==my_mainloop_orig) api=my_mainloop_ref; // need emulated version
- return (void*)RunFunction(my_context, (uintptr_t)my_mainloop_ref->io_new, 5, api, fd, events, b, userdata);
+ return (void*)RunFunctionFmt((uintptr_t)my_mainloop_ref->io_new, "piipp", api, fd, events, b, userdata);
}
static void my_io_enable(void* e, int events)
{
@@ -839,7 +839,7 @@ static void my_io_enable(void* e, int events)
if(fnc)
return ((vFpi_t)fnc)(e, events);
- RunFunction(my_context, (uintptr_t)my_mainloop_ref->io_enable, 2, e, events);
+ RunFunctionFmt((uintptr_t)my_mainloop_ref->io_enable, "pi", e, events);
}
static void my_io_free(void* e)
{
@@ -848,7 +848,7 @@ static void my_io_free(void* e)
if(fnc)
return ((vFp_t)fnc)(e);
- RunFunction(my_context, (uintptr_t)my_mainloop_ref->io_free, 1, e);
+ RunFunctionFmt((uintptr_t)my_mainloop_ref->io_free, "p", e);
}
static void my_io_set_destroy(void* e, void* cb)
{
@@ -864,7 +864,7 @@ static void my_io_set_destroy(void* e, void* cb)
if(!b)
b = AddBridge(bridge, vFppp, cb, 0, NULL);
}
- RunFunction(my_context, (uintptr_t)my_mainloop_ref->io_set_destroy, 2, e, b);
+ RunFunctionFmt((uintptr_t)my_mainloop_ref->io_set_destroy, "pp", e, b);
}
static void* my_time_new(void* api, void* tv, void* cb, void* data)
@@ -882,7 +882,7 @@ static void* my_time_new(void* api, void* tv, void* cb, void* data)
if(cb)
b = AddCheckBridge(bridge, vFpppp, cb, 0, NULL);
if(api==my_mainloop_orig) api=my_mainloop_ref; // need emulated version
- return (void*)RunFunction(my_context, (uintptr_t)my_mainloop_ref->time_new, 4, api, tv, b, data);
+ return (void*)RunFunctionFmt((uintptr_t)my_mainloop_ref->time_new, "pppp", api, tv, b, data);
}
static void my_time_restart(void* e, void* tv)
{
@@ -891,7 +891,7 @@ static void my_time_restart(void* e, void* tv)
if(fnc)
return ((vFpp_t)fnc)(e, tv);
- RunFunction(my_context, (uintptr_t)my_mainloop_ref->time_restart, 2, e, tv);
+ RunFunctionFmt((uintptr_t)my_mainloop_ref->time_restart, "pp", e, tv);
}
static void my_time_free(void* e)
{
@@ -900,7 +900,7 @@ static void my_time_free(void* e)
if(fnc)
return ((vFp_t)fnc)(e);
- RunFunction(my_context, (uintptr_t)my_mainloop_ref->time_free, 1, e);
+ RunFunctionFmt((uintptr_t)my_mainloop_ref->time_free, "p", e);
}
static void my_time_set_destroy(void* e, void* cb)
{
@@ -913,13 +913,21 @@ static void my_time_set_destroy(void* e, void* cb)
uintptr_t b = 0;
if(cb)
b = AddCheckBridge(bridge, vFppp, cb, 0, NULL);
- RunFunction(my_context, (uintptr_t)my_mainloop_ref->time_set_destroy, 2, e, b);
+ RunFunctionFmt((uintptr_t)my_mainloop_ref->time_set_destroy, "pp", e, b);
}
static void* my_defer_new(void* api, void* cb, void* data)
{
uintptr_t b = (uintptr_t)cb;
- void* fnc = GetNativeFnc((uintptr_t)my_mainloop_ref->defer_new);
+ static void* old_defer_new = NULL;
+ static void* old_fnc = NULL;
+ void* fnc = NULL;
+ if(old_defer_new == my_mainloop_ref->defer_new)
+ fnc = old_fnc;
+ else {
+ old_fnc = fnc = GetNativeFnc((uintptr_t)my_mainloop_ref->defer_new);
+ old_defer_new = my_mainloop_ref->defer_new;
+ }
if(fnc) {
if(api==my_mainloop_ref) api=my_mainloop_orig; // need native version
if(fnc==native_defer_new) fnc=my_mainloop_native.defer_new;
@@ -934,7 +942,7 @@ static void* my_defer_new(void* api, void* cb, void* data)
b = AddBridge(bridge, vFppp, cb, 0, NULL);
}
if(api==my_mainloop_orig) api=my_mainloop_ref; // need emulated version
- return (void*)RunFunction(my_context, (uintptr_t)my_mainloop_ref->defer_new, 3, api, b, data);
+ return (void*)RunFunctionFmt((uintptr_t)my_mainloop_ref->defer_new, "ppp", api, b, data);
}
static void my_defer_enable(void* e, int b)
{
@@ -943,7 +951,7 @@ static void my_defer_enable(void* e, int b)
if(fnc)
return ((vFpi_t)fnc)(e, b);
- RunFunction(my_context, (uintptr_t)my_mainloop_ref->defer_enable, 2, e, b);
+ RunFunctionFmt((uintptr_t)my_mainloop_ref->defer_enable, "pi", e, b);
}
static void my_defer_free(void* e)
{
@@ -952,7 +960,7 @@ static void my_defer_free(void* e)
if(fnc)
return ((vFp_t)fnc)(e);
- RunFunction(my_context, (uintptr_t)my_mainloop_ref->defer_free, 1, e);
+ RunFunctionFmt((uintptr_t)my_mainloop_ref->defer_free, "p", e);
}
static void my_defer_set_destroy(void* e, void* cb)
{
@@ -965,7 +973,7 @@ static void my_defer_set_destroy(void* e, void* cb)
uintptr_t b = 0;
if(cb)
b = AddCheckBridge(bridge, vFppp, cb, 0, NULL);
- RunFunction(my_context, (uintptr_t)my_mainloop_ref->defer_set_destroy, 2, e, b);
+ RunFunctionFmt((uintptr_t)my_mainloop_ref->defer_set_destroy, "pp", e, b);
}
static void my_quit(void* api, int retval)
@@ -978,7 +986,7 @@ static void my_quit(void* api, int retval)
}
if(api==my_mainloop_orig) api=my_mainloop_ref; // need emulated version
- RunFunction(my_context, (uintptr_t)my_mainloop_ref->quit, 2, api, retval);
+ RunFunctionFmt((uintptr_t)my_mainloop_ref->quit, "pi", api, retval);
}
static void bridgeMainloopAPI(bridge_t* bridge, my_pa_mainloop_api_t* api)
diff --git a/src/wrapped/wrappedpulse_private.h b/src/wrapped/wrappedpulse_private.h
index 9bc75bd..bceeaac 100755..100644
--- a/src/wrapped/wrappedpulse_private.h
+++ b/src/wrapped/wrappedpulse_private.h
@@ -6,18 +6,18 @@ GO(pa_ascii_filter, pFp)
GO(pa_ascii_valid, pFp)
GO(pa_bytes_per_second, LFp)
GO(pa_bytes_snprint, pFpLu)
-GO(pa_bytes_to_usec, UFUp)
+GO(pa_bytes_to_usec, LFLp)
GO(pa_channel_map_can_balance, iFp)
GO(pa_channel_map_can_fade, iFp)
GO(pa_channel_map_compatible, iFpp)
GO(pa_channel_map_equal, iFpp)
GO(pa_channel_map_init, pFp)
GO(pa_channel_map_init_auto, pFpui)
-GO(pa_channel_map_init_extend, pFpui)
+GO(pa_channel_map_init_extend, pFpuu)
GO(pa_channel_map_init_mono, pFp)
GO(pa_channel_map_init_stereo, pFp)
GO(pa_channel_map_parse, pFpp)
-GO(pa_channel_map_snprint, pFpup)
+GO(pa_channel_map_snprint, pFpLp)
GO(pa_channel_map_superset, iFpp)
GO(pa_channel_map_to_name, pFp)
GO(pa_channel_map_to_pretty_name, pFp)
@@ -58,7 +58,7 @@ GOM(pa_context_get_source_info_by_name, pFEpppp)
GOM(pa_context_get_source_info_list, pFEppp)
GOM(pa_context_get_source_output_info, pFEpupp)
GOM(pa_context_get_source_output_info_list, pFEppp)
-GO(pa_context_get_state, iFp)
+GO(pa_context_get_state, uFp)
GO(pa_context_is_local, iFp)
GO(pa_context_is_pending, iFp)
//GO(pa_context_kill_client,
@@ -158,22 +158,22 @@ GO(pa_mainloop_quit, vFpi)
GO(pa_mainloop_run, iFpp)
GOM(pa_mainloop_set_poll_func, vFEppp) //B is typedef int(*pa_poll_func) (struct pollfd *ufds, unsigned long nfds, int timeout, void *userdata)
GO(pa_mainloop_wakeup, vFp)
-//GO(pa_msleep,
+GO(pa_msleep, iFL)
GO(pa_operation_cancel, vFp)
-GO(pa_operation_get_state, iFp)
+GO(pa_operation_get_state, uFp)
GO(pa_operation_ref, pFp)
GO(pa_operation_unref, vFp)
GO(pa_parse_sample_format, iFp)
GO(pa_path_get_filename, pFp)
-//GO(pa_proplist_clear,
-//GO(pa_proplist_contains,
-//GO(pa_proplist_copy,
+GO(pa_proplist_clear, vFp)
+GO(pa_proplist_contains, iFpp)
+GO(pa_proplist_copy, pFp)
GO(pa_proplist_free, vFp)
-//GO(pa_proplist_from_string,
-//GO(pa_proplist_get,
+GO(pa_proplist_from_string, pFp)
+GO(pa_proplist_get, iFpppp)
GO(pa_proplist_gets, pFpp)
-//GO(pa_proplist_isempty,
-//GO(pa_proplist_iterate,
+GO(pa_proplist_isempty, iFp)
+GO(pa_proplist_iterate, pFpp)
GO(pa_proplist_new, pFv)
GO(pa_proplist_set, iFpppL)
GOM(pa_proplist_setf, iFEpppV)
@@ -183,10 +183,10 @@ GO(pa_proplist_to_string, pFp)
GO(pa_proplist_to_string_sep, pFpp)
GO(pa_proplist_unset, iFpp)
GO(pa_proplist_unset_many, iFpp)
-GO(pa_proplist_update, vFpip)
+GO(pa_proplist_update, vFpup)
GO(pa_sample_format_to_string, pFi)
GO(pa_sample_size, LFp)
-GO(pa_sample_size_of_format, LFp)
+GO(pa_sample_size_of_format, LFi)
GO(pa_sample_spec_equal, iFpp)
GO(pa_sample_spec_init, pFp)
GO(pa_sample_spec_snprint, pFpLp)
@@ -196,8 +196,8 @@ GO(pa_signal_free, vFp)
GOM(pa_signal_init, iFEp)
GOM(pa_signal_new, pFEipp)
GOM(pa_signal_set_destroy, vFEpp)
-GO(pa_stream_connect_playback, iFpppipp)
-GO(pa_stream_connect_record, iFpppi)
+GO(pa_stream_connect_playback, iFpppupp)
+GO(pa_stream_connect_record, iFpppu)
GO(pa_stream_connect_upload, iFpL)
GOM(pa_stream_cork, pFEpipp)
GO(pa_stream_disconnect, iFp)
@@ -214,7 +214,7 @@ GO(pa_stream_get_index, uFp)
GO(pa_stream_get_latency, iFppp)
GO(pa_stream_get_monitor_stream, uFp)
GO(pa_stream_get_sample_spec, pFp)
-GO(pa_stream_get_state, iFp)
+GO(pa_stream_get_state, uFp)
GO(pa_stream_get_time, iFpp)
GO(pa_stream_get_timing_info, pFp)
GO(pa_stream_is_corked, iFp)
@@ -255,7 +255,7 @@ GO(pa_sw_volume_divide, uFuu)
GO(pa_sw_volume_from_dB, uFd)
GO(pa_sw_volume_from_linear, uFd)
GO(pa_sw_volume_multiply, uFuu)
-GO(pa_sw_volume_snprint_dB, pFpuu)
+GO(pa_sw_volume_snprint_dB, pFpLu)
GO(pa_sw_volume_to_dB, dFu)
GO(pa_sw_volume_to_linear, dFu)
GO(pa_threaded_mainloop_accept, vFp)
@@ -273,11 +273,11 @@ GO(pa_threaded_mainloop_wait, vFp)
GO(pa_timeval_add, pFpU)
GO(pa_timeval_age, UFp)
GO(pa_timeval_cmp, iFpp)
-GO(pa_timeval_diff, UFpp)
-GO(pa_timeval_load, UFp)
-GO(pa_timeval_store, pFpU)
+GO(pa_timeval_diff, LFpp)
+GO(pa_timeval_load, LFp)
+GO(pa_timeval_store, pFpL)
GO(pa_timeval_sub, pFpU)
-GO(pa_usec_to_bytes, uFUp)
+GO(pa_usec_to_bytes, LFLp)
GO(pa_utf8_filter, pFp)
GO(pa_utf8_to_locale, pFp)
GO(pa_utf8_valid, pFp)
@@ -294,4 +294,4 @@ GO(pa_stream_begin_write, iFppp) // 0.9.16+
GO(pa_stream_cancel_write, iFp) // 0.9.16+
GO(dummy_io_new, pFpiipp) // dumy function to create Wrapper
-GO(dummy_io_new2, vFppiip) // and another one \ No newline at end of file
+GO(dummy_io_new2, vFppiip) // and another one
diff --git a/src/wrapped/wrappedpulsesimple.c b/src/wrapped/wrappedpulsesimple.c
index 1fd5681..1fd5681 100755..100644
--- a/src/wrapped/wrappedpulsesimple.c
+++ b/src/wrapped/wrappedpulsesimple.c
diff --git a/src/wrapped/wrappedpulsesimple_private.h b/src/wrapped/wrappedpulsesimple_private.h
index fb602d8..fb602d8 100755..100644
--- a/src/wrapped/wrappedpulsesimple_private.h
+++ b/src/wrapped/wrappedpulsesimple_private.h
diff --git a/src/wrapped/wrappedsdl1.c b/src/wrapped/wrappedsdl1.c
index 4ebfb31..50f3e1b 100755..100644
--- a/src/wrapped/wrappedsdl1.c
+++ b/src/wrapped/wrappedsdl1.c
@@ -73,7 +73,7 @@ GO(4)
static uintptr_t my_AudioCallback_fct_##A = 0; \
static void my_AudioCallback_##A(void *userdata, uint8_t *stream, int32_t len) \
{ \
- RunFunction(my_context, my_AudioCallback_fct_##A, 3, userdata, stream, len); \
+ RunFunctionFmt(my_AudioCallback_fct_##A, "pCi", userdata, stream, len); \
}
SUPER()
#undef GO
@@ -95,7 +95,7 @@ static void* find_AudioCallback_Fct(void* fct)
static uintptr_t my_TimerCallback_fct_##A = 0; \
static uint32_t my_TimerCallback_##A(uint32_t interval, void *userdata) \
{ \
- return (uint32_t)RunFunction(my_context, my_TimerCallback_fct_##A, 2, interval, userdata); \
+ return (uint32_t)RunFunctionFmt(my_TimerCallback_fct_##A, "up", interval, userdata); \
}
SUPER()
#undef GO
@@ -117,7 +117,7 @@ static void* find_TimerCallback_Fct(void* fct)
static uintptr_t my_EvtFilter_fct_##A = 0; \
static int my_EvtFilter_##A(void* p) \
{ \
- return RunFunction(my_context, my_EvtFilter_fct_##A, 1, p); \
+ return RunFunctionFmt(my_EvtFilter_fct_##A, "p", p); \
}
SUPER()
#undef GO
@@ -350,7 +350,7 @@ EXPORT void my_SDL_KillThread(x64emu_t* emu, void* p)
my->SDL_KillThread(p);
}
-EXPORT void* my_SDL_GL_GetProcAddress(x64emu_t* emu, void* name)
+EXPORT void* my_SDL_GL_GetProcAddress(x64emu_t* emu, void* name)
{
khint_t k;
const char* rname = (const char*)name;
diff --git a/src/wrapped/wrappedsdl1_private.h b/src/wrapped/wrappedsdl1_private.h
index 35e0e78..1130b4b 100755..100644
--- a/src/wrapped/wrappedsdl1_private.h
+++ b/src/wrapped/wrappedsdl1_private.h
@@ -1,4 +1,6 @@
-#if defined(GO) && defined(GOM) && defined(GO2) && defined(DATA)
+#if !(defined(GO) && defined(GOM) && defined(GO2) && defined(DATA))
+#error Meh...
+#endif
// _fini
// _init
@@ -38,8 +40,8 @@ GO(SDL_DisplayFormatAlpha, pFp)
GO(SDL_DisplayYUVOverlay, iFpp)
GO(SDL_EnableKeyRepeat, iFii)
GO(SDL_EnableUNICODE, iFi)
-GO(SDL_Error, vFi)
-GO(SDL_EventState, uFui)
+GO(SDL_Error, vFu)
+GO(SDL_EventState, CFCi)
GO(SDL_FillRect, iFppu)
GO(SDL_Flip, iFp)
GO(SDL_FreeCursor, vFp)
@@ -54,20 +56,20 @@ GO(SDL_GL_SetAttribute, iFui)
GO(SDL_GL_SwapBuffers, vFv)
GO(SDL_GL_Unlock, vFv)
GO(SDL_GL_UpdateRects, vFip)
-GO(SDL_GetAppState, uFv)
+GO(SDL_GetAppState, CFv)
GO(SDL_GetClipRect, vFpp)
GO(SDL_GetCursor, pFv)
GO(SDL_GetError, pFv)
GOM(SDL_GetEventFilter, pFEv)
GO(SDL_GetGammaRamp, iFppp)
-GO(SDL_GetKeyName, pFi)
+GO(SDL_GetKeyName, pFu)
GO(SDL_GetKeyRepeat, vFpp)
GO(SDL_GetKeyState, pFp)
-GO(SDL_GetModState, iFv)
+GO(SDL_GetModState, uFv)
GO(SDL_GetMouseState, uFpp)
GO(SDL_GetRGB, vFupppp)
GO(SDL_GetRGBA, vFuppppp)
-GO(SDL_GetRelativeMouseState, uFpp)
+GO(SDL_GetRelativeMouseState, CFpp)
GO(SDL_GetThreadID, uFp)
GO(SDL_GetTicks, uFv)
GO(SDL_GetVideoInfo, pFv)
@@ -86,9 +88,9 @@ GO(SDL_InitQuickDraw, vFp)
GO(SDL_InitSubSystem, iFu)
GO(SDL_JoystickClose, vFp)
GO(SDL_JoystickEventState, iFi)
-GO(SDL_JoystickGetAxis, iFpi)
+GO(SDL_JoystickGetAxis, wFpi)
GO(SDL_JoystickGetBall, iFpipp)
-GO(SDL_JoystickGetButton, uFpi)
+GO(SDL_JoystickGetButton, CFpi)
GO(SDL_JoystickGetHat, uFpi)
GO(SDL_JoystickIndex, iFp)
GO(SDL_JoystickName, pFi)
@@ -108,10 +110,10 @@ GOM(SDL_LoadObject, pFEp)
GO(SDL_LockSurface, iFp)
GO(SDL_LockYUVOverlay, iFp)
GO(SDL_LowerBlit, iFpppp)
-GO(SDL_MapRGB, uFpuuu)
-GO(SDL_MapRGBA, uFpuuuu)
+GO(SDL_MapRGB, uFpCCC)
+GO(SDL_MapRGBA, uFpCCCC)
GO(SDL_NumJoysticks, iFv)
-GO(SDL_PeepEvents, iFpiiu)
+GO(SDL_PeepEvents, iFpiuu)
GO(SDL_PollEvent, iFp)
GO(SDL_PumpEvents, vFv)
GO(SDL_PushEvent, iFp)
@@ -135,8 +137,8 @@ GO(SDL_SemTryWait, iFp)
GO(SDL_SemValue, uFp)
GO(SDL_SemWait, iFp)
GO(SDL_SemWaitTimeout, iFpu)
-GO(SDL_SetAlpha, iFpuu)
-GO(SDL_SetClipRect, iFpp)
+GO(SDL_SetAlpha, iFpuC)
+GO(SDL_SetClipRect, uFpp)
GO(SDL_SetColorKey, iFpuu)
GO(SDL_SetColors, iFppii)
GO(SDL_SetCursor, vFp)
@@ -144,7 +146,7 @@ GO(SDL_SetError, vFpppppp) // use ..., so putting arbitrary number of argum
GOM(SDL_SetEventFilter, vFEp)
GO(SDL_SetGamma, iFfff)
GO(SDL_SetGammaRamp, iFppp)
-GO(SDL_SetModState, vFi)
+GO(SDL_SetModState, vFu)
GO(SDL_SetModuleHandle, vFp)
GO(SDL_SetPalette, iFpipii)
GOM(SDL_SetTimer, iFEup)
@@ -156,7 +158,7 @@ GOM(SDL_UnloadObject, vFEp)
GO(SDL_UnlockSurface, vFp)
GO(SDL_UnlockYUVOverlay, vFp)
GO(SDL_UnregisterApp, vFv)
-GO(SDL_UpdateRect, vFpiiii)
+GO(SDL_UpdateRect, vFpiiuu)
GO(SDL_UpdateRects, vFpip)
GO(SDL_UpperBlit, iFpppp)
GO(SDL_VideoDriverName, pFpi)
@@ -182,18 +184,18 @@ GOM(SDL_WriteLE64, uFEpU)
GO(SDL_framerateDelay, uFp)
GO(SDL_getFramecount, iFp)
GO(SDL_getFramerate, iFp)
-GO(SDL_iconv, uFppppp)
+GO(SDL_iconv, LFppppp)
GO(SDL_iconv_close, iFp)
GO(SDL_iconv_open, pFpp)
-GO(SDL_iconv_string, pFpppu)
+GO(SDL_iconv_string, pFpppL)
GO(SDL_initFramerate, vFp)
-GO(SDL_lltoa, pFIpi)
-GO(SDL_ltoa, pFipi)
+GO(SDL_lltoa, pFlpi)
+GO(SDL_ltoa, pFlpi)
GO(SDL_main, iFip)
GO(SDL_memcmp, iFppu)
GO(SDL_mutexP, iFp)
GO(SDL_mutexV, iFp)
-GO(SDL_revcpy, pFppu)
+GO(SDL_revcpy, pFppL)
GO(SDL_setFramerate, iFpu)
GO(SDL_snprintf, iFpupppppp) // use ...
GO(SDL_sscanf, iFppppppp) // use ...
@@ -201,7 +203,7 @@ GO(SDL_strcasecmp, iFpp)
GO(SDL_strchr, pFpi)
GO(SDL_strcmp, iFpp)
GO(SDL_strdup, pFp)
-GO(SDL_strlcat, uFppu)
+GO(SDL_strlcat, LFppL)
GO(SDL_strlcpy, uFppu)
GO(SDL_strlen, uFp)
GO(SDL_strlwr, pFp)
@@ -216,23 +218,21 @@ GO(SDL_strtoll, IFppi)
GO(SDL_strtoul, uFppi)
GO(SDL_strtoull, UFppi)
GO(SDL_strupr, pFp)
-GO(SDL_ulltoa, pFUpi)
-GO(SDL_ultoa, pFupi)
+GO(SDL_ulltoa, pFLpi)
+GO(SDL_ultoa, pFLpi)
GO(SDL_vsnprintf, iFpupV)
GOM(SDL_OpenAudio, iFEpp)
GO(SDL_LockAudio, vFv)
GO(SDL_UnlockAudio, vFv)
GO(SDL_PauseAudio, vFi)
-GO(SDL_GetAudioStatus, iFv)
+GO(SDL_GetAudioStatus, uFv)
GO(SDL_LoadWAV, pFpppp)
GO(SDL_FreeWAV, vFp)
GOM(SDL_LoadWAV_RW, pFEpippp)
-GO(SDL_BuildAudioCVT, iFpuuiuui)
+GO(SDL_BuildAudioCVT, iFpWCiWCi)
GO(SDL_ConvertAudio, iFp)
GO(SDL_AudioInit, iFp)
GO(SDL_AudioQuit, vFv) // should free callback
GO(SDL_MixAudio, vFppui)
GO(SDL_CloseAudio, vFv) // should free callback
GO(SDL_AudioDriverName, pFpi)
-
-#endif \ No newline at end of file
diff --git a/src/wrapped/wrappedsdl1image.c b/src/wrapped/wrappedsdl1image.c
index 66eda2c..ad405d9 100755..100644
--- a/src/wrapped/wrappedsdl1image.c
+++ b/src/wrapped/wrappedsdl1image.c
@@ -24,7 +24,7 @@ const char* sdl1imageName = "libSDL_image-1.2.so.0";
#include "wrappercallback.h"
-#define GO(A) \
+#define GO(A) \
void EXPORT *my_##A(x64emu_t* emu, void* a) \
{ \
SDL1_RWops_t* rw = RWNativeStart(emu, (SDL1_RWops_t*)a); \
diff --git a/src/wrapped/wrappedsdl1image_private.h b/src/wrapped/wrappedsdl1image_private.h
index 8617d69..c336bc9 100755..100644
--- a/src/wrapped/wrappedsdl1image_private.h
+++ b/src/wrapped/wrappedsdl1image_private.h
@@ -1,4 +1,6 @@
-#if defined(GO) && defined(GOM) && defined(GO2) && defined(DATA)
+#if !(defined(GO) && defined(GOM) && defined(GO2) && defined(DATA))
+#error Meh...
+#endif
GO(IMG_Init,iFi)
GO(IMG_InvertAlpha,iFi)
@@ -37,5 +39,3 @@ GO(IMG_isWEBP,iFp)
GO(IMG_isXCF,iFp)
GO(IMG_isXPM,iFp)
GO(IMG_isXV,iFp)
-
-#endif \ No newline at end of file
diff --git a/src/wrapped/wrappedsdl1mixer.c b/src/wrapped/wrappedsdl1mixer.c
index 9538aac..d9287be 100755..100644
--- a/src/wrapped/wrappedsdl1mixer.c
+++ b/src/wrapped/wrappedsdl1mixer.c
@@ -37,7 +37,7 @@ GO(4)
static uintptr_t my_EffectFunc_fct_##A = 0; \
static void my_EffectFunc_##A(int chan, void *stream, int len, void *udata) \
{ \
- RunFunction(my_context, my_EffectFunc_fct_##A, 4, chan, stream, len, udata); \
+ RunFunctionFmt(my_EffectFunc_fct_##A, "ipip", chan, stream, len, udata); \
}
SUPER()
#undef GO
@@ -61,7 +61,7 @@ static void* find_EffectFunc_Fct(void* fct)
static uintptr_t my_EffectDone_fct_##A = 0; \
static void my_EffectDone_##A(int chan, void *udata) \
{ \
- RunFunction(my_context, my_EffectDone_fct_##A, 2, chan, udata); \
+ RunFunctionFmt(my_EffectDone_fct_##A, "ip", chan, udata); \
}
SUPER()
#undef GO
@@ -85,7 +85,7 @@ static void* find_EffectDone_Fct(void* fct)
static uintptr_t my_MixFunc_fct_##A = 0; \
static void my_MixFunc_##A(void *udata, uint8_t *stream, int len) \
{ \
- RunFunction(my_context, my_MixFunc_fct_##A, 3, udata, stream, len); \
+ RunFunctionFmt(my_MixFunc_fct_##A, "ppi", udata, stream, len); \
}
SUPER()
#undef GO
@@ -109,7 +109,7 @@ static void* find_MixFunc_Fct(void* fct)
static uintptr_t my_ChannelFinished_fct_##A = 0; \
static void my_ChannelFinished_##A(int channel) \
{ \
- RunFunction(my_context, my_ChannelFinished_fct_##A, 1, channel); \
+ RunFunctionFmt(my_ChannelFinished_fct_##A, "i", channel); \
}
SUPER()
#undef GO
@@ -133,7 +133,7 @@ static void* find_ChannelFinished_Fct(void* fct)
static uintptr_t my_MusicFinished_fct_##A = 0; \
static void my_MusicFinished_##A() \
{ \
- RunFunction(my_context, my_MusicFinished_fct_##A, 0); \
+ RunFunctionFmt(my_MusicFinished_fct_##A, ""); \
}
SUPER()
#undef GO
diff --git a/src/wrapped/wrappedsdl1mixer_private.h b/src/wrapped/wrappedsdl1mixer_private.h
index 3cca15a..730da35 100755..100644
--- a/src/wrapped/wrappedsdl1mixer_private.h
+++ b/src/wrapped/wrappedsdl1mixer_private.h
@@ -1,4 +1,6 @@
-#if defined(GO) && defined(GOM) && defined(GO2) && defined(DATA)
+#if !(defined(GO) && defined(GOM) && defined(GO2) && defined(DATA))
+#error Meh...
+#endif
GO(Mix_AllocateChannels,iFi)
GOM(Mix_ChannelFinished,vFEp)
@@ -11,15 +13,15 @@ GO(Mix_FadeInMusicPos,iFpiid)
GO(Mix_FadeOutChannel,iFii)
GO(Mix_FadeOutGroup,iFii)
GO(Mix_FadeOutMusic,iFi)
-GO(Mix_FadingChannel,iFi)
-GO(Mix_FadingMusic,iFv)
+GO(Mix_FadingChannel, uFi)
+GO(Mix_FadingMusic, uFv)
GO(Mix_FreeChunk,vFp)
GO(Mix_FreeMusic,vFp)
GO(Mix_GetChunk,pFi)
GO(Mix_GetChunkDecoder,pFi)
GO(Mix_GetMusicDecoder,pFi)
GO(Mix_GetMusicHookData,pFv)
-GO(Mix_GetMusicType,iFp)
+GO(Mix_GetMusicType, uFp)
GO(Mix_GetNumChunkDecoders,iFv)
GO(Mix_GetNumMusicDecoders,iFv)
GO(Mix_GetSoundFonts,pFv)
@@ -41,7 +43,7 @@ GO(Mix_LoadMUS,pFp)
GOM(Mix_LoadMUSType_RW,pFEpii)
GOM(Mix_LoadMUS_RW,pFEp)
GOM(Mix_LoadWAV_RW,pFEpi)
-GO(Mix_OpenAudio,iFiuii)
+GO(Mix_OpenAudio, iFiWii)
GO(Mix_Pause,vFi)
GO(Mix_PauseMusic,vFv)
GO(Mix_Paused,iFi)
@@ -59,11 +61,11 @@ GO(Mix_ReserveChannels,iFi)
GO(Mix_Resume,vFi)
GO(Mix_ResumeMusic,vFv)
GO(Mix_RewindMusic,vFv)
-GO(Mix_SetDistance,iFiu)
+GO(Mix_SetDistance, iFiC)
GO(Mix_SetMusicCMD,iFp)
GO(Mix_SetMusicPosition,iFd)
-GO(Mix_SetPanning,iFiuu)
-GO(Mix_SetPosition,iFiiu)
+GO(Mix_SetPanning, iFiCC)
+GO(Mix_SetPosition, iFiwC)
GOM(Mix_SetPostMix,vFEpp)
GO(Mix_SetReverseStereo,iFii)
GO(Mix_SetSoundFonts,iFp)
@@ -73,5 +75,3 @@ GOM(Mix_UnregisterEffect,iFEip)
GO(Mix_Volume,iFii)
GO(Mix_VolumeChunk,iFpi)
GO(Mix_VolumeMusic,iFi)
-
-#endif \ No newline at end of file
diff --git a/src/wrapped/wrappedsdl1net.c b/src/wrapped/wrappedsdl1net.c
index ee16dbe..ee16dbe 100755..100644
--- a/src/wrapped/wrappedsdl1net.c
+++ b/src/wrapped/wrappedsdl1net.c
diff --git a/src/wrapped/wrappedsdl1net_private.h b/src/wrapped/wrappedsdl1net_private.h
index 6986d4d..29bcd05 100755..100644
--- a/src/wrapped/wrappedsdl1net_private.h
+++ b/src/wrapped/wrappedsdl1net_private.h
@@ -42,4 +42,4 @@ GO(SDLNet_UDP_SetPacketLoss, vFpi)
GO(SDLNet_UDP_Unbind, vFpi)
GO(SDLNet_Write16, vFWp)
GO(SDLNet_Write32, vFup)
-GO(SDLNet_version, pFv) \ No newline at end of file
+GO(SDLNet_version, pFv)
diff --git a/src/wrapped/wrappedsdl1sound.c b/src/wrapped/wrappedsdl1sound.c
index e77d2a0..e77d2a0 100755..100644
--- a/src/wrapped/wrappedsdl1sound.c
+++ b/src/wrapped/wrappedsdl1sound.c
diff --git a/src/wrapped/wrappedsdl1sound_private.h b/src/wrapped/wrappedsdl1sound_private.h
index 1efad54..1efad54 100755..100644
--- a/src/wrapped/wrappedsdl1sound_private.h
+++ b/src/wrapped/wrappedsdl1sound_private.h
diff --git a/src/wrapped/wrappedsdl1ttf.c b/src/wrapped/wrappedsdl1ttf.c
index d0bb80c..d0bb80c 100755..100644
--- a/src/wrapped/wrappedsdl1ttf.c
+++ b/src/wrapped/wrappedsdl1ttf.c
diff --git a/src/wrapped/wrappedsdl1ttf_private.h b/src/wrapped/wrappedsdl1ttf_private.h
index a115d99..825e5d6 100755..100644
--- a/src/wrapped/wrappedsdl1ttf_private.h
+++ b/src/wrapped/wrappedsdl1ttf_private.h
@@ -8,21 +8,21 @@ GO(TTF_FontAscent, iFp)
GO(TTF_FontDescent, iFp)
GO(TTF_FontFaceFamilyName, pFp)
GO(TTF_FontFaceIsFixedWidth, iFp)
-GO(TTF_FontFaces, iFp)
+GO(TTF_FontFaces, lFp)
GO(TTF_FontFaceStyleName, pFp)
GO(TTF_FontHeight, iFp)
GO(TTF_FontLineSkip, iFp)
GO(TTF_GetFontHinting, iFp)
GO(TTF_GetFontKerning, iFp)
-GO(TTF_GetFontKerningSize, iFp)
+GO(TTF_GetFontKerningSize, iFpii)
GO(TTF_GetFontOutline, iFp)
GO(TTF_GetFontStyle, iFp)
-GO(TTF_GlyphIsProvided, iFpu)
-GO(TTF_GlyphMetrics, iFpuppppp)
+GO(TTF_GlyphIsProvided, iFpW)
+GO(TTF_GlyphMetrics, iFpWppppp)
GO(TTF_Init, iFv)
GO(TTF_Linked_Version, pFv)
GO(TTF_OpenFont, pFpi)
-GO(TTF_OpenFontIndex, pFpii)
+GO(TTF_OpenFontIndex, pFpil)
GOM(TTF_OpenFontIndexRW, pFEpiii)
GOM(TTF_OpenFontRW, pFEpii)
GO(TTF_Quit, vFv)
diff --git a/src/wrapped/wrappedsdl2.c b/src/wrapped/wrappedsdl2.c
index 2e665e9..8f0710f 100755..100644
--- a/src/wrapped/wrappedsdl2.c
+++ b/src/wrapped/wrappedsdl2.c
@@ -104,7 +104,7 @@ GO(4)
static uintptr_t my_Timer_fct_##A = 0; \
static uint64_t my_Timer_##A(uint64_t a, void* b) \
{ \
- return (uint64_t)RunFunction(my_context, my_Timer_fct_##A, 2, a, b); \
+ return (uint64_t)RunFunctionFmt(my_Timer_fct_##A, "Up", a, b); \
}
SUPER()
#undef GO
@@ -121,14 +121,14 @@ static void* find_Timer_Fct(void* fct)
#undef GO
printf_log(LOG_NONE, "Warning, no more slot for SDL2 Timer callback\n");
return NULL;
-
+
}
// AudioCallback
#define GO(A) \
static uintptr_t my_AudioCallback_fct_##A = 0; \
static void my_AudioCallback_##A(void* a, void* b, int c) \
{ \
- RunFunction(my_context, my_AudioCallback_fct_##A, 3, a, b, c); \
+ RunFunctionFmt(my_AudioCallback_fct_##A, "ppi", a, b, c); \
}
SUPER()
#undef GO
@@ -145,14 +145,14 @@ static void* find_AudioCallback_Fct(void* fct)
#undef GO
printf_log(LOG_NONE, "Warning, no more slot for SDL2 AudioCallback callback\n");
return NULL;
-
+
}
// eventfilter
#define GO(A) \
static uintptr_t my_eventfilter_fct_##A = 0; \
static int my_eventfilter_##A(void* userdata, void* event) \
{ \
- return (int)RunFunction(my_context, my_eventfilter_fct_##A, 2, userdata, event); \
+ return (int)RunFunctionFmt(my_eventfilter_fct_##A, "pp", userdata, event); \
}
SUPER()
#undef GO
@@ -169,7 +169,7 @@ static void* find_eventfilter_Fct(void* fct)
#undef GO
printf_log(LOG_NONE, "Warning, no more slot for SDL2 eventfilter callback\n");
return NULL;
-
+
}
static void* reverse_eventfilter_Fct(void* fct)
{
@@ -187,7 +187,7 @@ static void* reverse_eventfilter_Fct(void* fct)
static uintptr_t my_LogOutput_fct_##A = 0; \
static void my_LogOutput_##A(void* a, int b, int c, void* d) \
{ \
- RunFunction(my_context, my_LogOutput_fct_##A, 4, a, b, c, d); \
+ RunFunctionFmt(my_LogOutput_fct_##A, "piip", a, b, c, d); \
}
SUPER()
#undef GO
@@ -552,7 +552,7 @@ static int get_sdl_priv(x64emu_t* emu, const char *sym_str, void **w, void **f)
}
#define GOS(sym, _w) GOM(sym, _w)
#define DATA
-
+
if(0);
#include "wrappedsdl2_private.h"
@@ -570,7 +570,7 @@ int EXPORT my2_SDL_DYNAPI_entry(x64emu_t* emu, uint32_t version, uintptr_t *tabl
uintptr_t tab[tablesize];
int r = my->SDL_DYNAPI_entry(version, tab, tablesize);
(void)r;
-
+
#define SDL_DYNAPI_PROC(ret, sym, args, parms, ...) \
if (i < tablesize) { \
void *w = NULL; \
@@ -646,7 +646,7 @@ EXPORT void my2_SDL_Log(x64emu_t* emu, void* fmt, void *b) {
my->SDL_LogMessageV(0, 3, fmt, VARARGS);
}
-EXPORT void* my2_SDL_GL_GetProcAddress(x64emu_t* emu, void* name)
+EXPORT void* my2_SDL_GL_GetProcAddress(x64emu_t* emu, void* name)
{
khint_t k;
const char* rname = (const char*)name;
@@ -667,7 +667,7 @@ static uintptr_t dtor_emu[nb_once] = {0};
static void tls_dtor_callback(int n, void* a)
{
if(dtor_emu[n]) {
- RunFunction(my_context, dtor_emu[n], 1, a);
+ RunFunctionFmt(dtor_emu[n], "p", a);
}
}
#define GO(N) \
diff --git a/src/wrapped/wrappedsdl2_private.h b/src/wrapped/wrappedsdl2_private.h
index 7670c4a..6696fab 100755..100644
--- a/src/wrapped/wrappedsdl2_private.h
+++ b/src/wrapped/wrappedsdl2_private.h
@@ -24,14 +24,14 @@ GO(SDL_atanf, fFf)
GO(SDL_atof, dFp)
GO(SDL_atoi, iFp)
GO(SDL_AtomicAdd, iFpi)
-GO(SDL_AtomicCAS, iFpii)
-GO(SDL_AtomicCASPtr, iFppp)
+GO(SDL_AtomicCAS, uFpii)
+GO(SDL_AtomicCASPtr, uFppp)
GO(SDL_AtomicGet, iFp)
GO(SDL_AtomicGetPtr, pFp)
GO(SDL_AtomicLock, vFp)
GO(SDL_AtomicSet, iFpi)
GO(SDL_AtomicSetPtr, pFpp)
-GO(SDL_AtomicTryLock, iFp)
+GO(SDL_AtomicTryLock, uFp)
GO(SDL_AtomicUnlock, vFp)
GO(SDL_AudioInit, iFp)
GO(SDL_AudioQuit, vFv)
@@ -40,18 +40,18 @@ GO(SDL_AudioStreamClear, vFp)
GO(SDL_AudioStreamFlush, iFp)
GO(SDL_AudioStreamGet, iFppi)
GO(SDL_AudioStreamPut, iFppi)
-GO(SDL_BuildAudioCVT, iFpuuiuui)
+GO(SDL_BuildAudioCVT, iFpWCiWCi)
GO(SDL_CalculateGammaRamp, vFfp)
-GO(SDL_calloc, pFuu)
-GO(SDL_CaptureMouse, iFi)
+GO(SDL_calloc, pFLL)
+GO(SDL_CaptureMouse, iFu)
GO(SDL_ceil, dFd)
GO(SDL_ceilf, fFf)
GO(SDL_ClearError, vFv)
GO(SDL_ClearHints, vFv)
GO(SDL_ClearQueuedAudio, vFu)
GO(SDL_CloseAudio, vFv)
-GO(SDL_CloseAudioDevice, vFi)
-GO(SDL_ComposeCustomBlendMode, iFiiiiii)
+GO(SDL_CloseAudioDevice, vFu)
+GO(SDL_ComposeCustomBlendMode, uFuuuuuu)
GO(SDL_CondBroadcast, iFp)
GO(SDL_CondSignal, iFp)
GO(SDL_CondWait, iFpp)
@@ -99,8 +99,8 @@ GO(SDL_DisableScreenSaver, vFv)
GO(SDL_DuplicateSurface, pFp)
GOM(SDL_DYNAPI_entry, iFEupu)
GO(SDL_EnableScreenSaver, vFv)
-GO(SDL_EnclosePoints, iFpipp)
-GO(SDL_Error, iFi)
+GO(SDL_EnclosePoints, uFpipp)
+GO(SDL_Error, iFu)
GO(SDL_EventState, CFui)
GO(SDL_exp, dFd)
GO(SDL_expf, fFf)
@@ -130,12 +130,12 @@ GO(SDL_GameControllerEventState, iFi)
GO(SDL_GameControllerFromInstanceID, pFi)
GO(SDL_GameControllerFromPlayerIndex, pFi)
GO(SDL_GameControllerGetAttached, iFp)
-GO(SDL_GameControllerGetAxis, iFpi)
-GO(SDL_GameControllerGetAxisFromString, uFp)
+GO(SDL_GameControllerGetAxis, wFpi)
+GO(SDL_GameControllerGetAxisFromString, iFp)
GO(SDL_GameControllerGetBindForAxis, HFpi)
GO(SDL_GameControllerGetBindForButton, HFpi)
-GO(SDL_GameControllerGetButton, uFpi)
-GO(SDL_GameControllerGetButtonFromString, uFp)
+GO(SDL_GameControllerGetButton, CFpi)
+GO(SDL_GameControllerGetButtonFromString, iFp)
GO(SDL_GameControllerGetJoystick, pFp)
GO(SDL_GameControllerGetNumTouchpads, iFp)
GO(SDL_GameControllerGetNumTouchpadFingers, iFpi)
@@ -144,15 +144,15 @@ GO(SDL_GameControllerGetProduct, WFp)
GO(SDL_GameControllerGetProductVersion, WFp)
GO(SDL_GameControllerGetSensorData, iFpipi)
GO(SDL_GameControllerGetSerial, pFp)
-GO(SDL_GameControllerGetStringForAxis, pFp)
-GO(SDL_GameControllerGetStringForButton, pFu)
+GO(SDL_GameControllerGetStringForAxis, pFi)
+GO(SDL_GameControllerGetStringForButton, pFi)
GO(SDL_GameControllerGetTouchpadFinger, iFpiipppp)
-GO(SDL_GameControllerGetType, iFp)
+GO(SDL_GameControllerGetType, uFp)
GO(SDL_GameControllerGetVendor, WFp)
-GO(SDL_GameControllerHasButton, iFpi)
+GO(SDL_GameControllerHasButton, uFpi)
GO(SDL_GameControllerHasLED, iFp)
GO(SDL_GameControllerHasSensor, iFpi)
-GO(SDL_GameControllerIsSensorEnabled, iFpi)
+GO(SDL_GameControllerIsSensorEnabled, uFpi)
GO(SDL_GameControllerMapping, pFp)
GO(SDL_GameControllerMappingForDeviceIndex, pFi)
GO(SDL_GameControllerMappingForGUID, pFpp)
@@ -165,16 +165,16 @@ GO(SDL_GameControllerRumble, iFpWWu)
GO(SDL_GameControllerRumbleTriggers, iFpWWu)
GO(SDL_GameControllerSetLED, iFpCCC)
GO(SDL_GameControllerSetPlayerIndex, vFpi)
-GO(SDL_GameControllerSetSensorEnabled, iFpii)
-GO(SDL_GameControllerTypeForIndex, iFi)
+GO(SDL_GameControllerSetSensorEnabled, iFpiu)
+GO(SDL_GameControllerTypeForIndex, uFi)
GO(SDL_GameControllerUpdate, vFv)
// SDL_GetAssertionHandler
GO(SDL_GetAssertionReport, pFv)
GO(SDL_GetAudioDeviceName, pFii)
-GO(SDL_GetAudioDeviceStatus, iFi)
+GO(SDL_GetAudioDeviceStatus, uFu)
GO(SDL_GetAudioDriver, pFi)
GO(SDL_GetAudioDeviceSpec, iFiip)
-GO(SDL_GetAudioStatus, iFv)
+GO(SDL_GetAudioStatus, uFv)
GOM(SDL_GetBasePath, pFEv)
GO(SDL_GetClipboardText, pFv)
GO(SDL_GetClipRect, vFpp)
@@ -193,7 +193,7 @@ GO(SDL_GetDisplayBounds, iFip)
GO(SDL_GetDisplayDPI, iFippp)
GO(SDL_GetDisplayMode, iFiip)
GO(SDL_GetDisplayName, pFi)
-GO(SDL_GetDisplayOrientation, iFi)
+GO(SDL_GetDisplayOrientation, uFi)
GO(SDL_GetDisplayUsableBounds, iFip)
GO(SDL_getenv, pFp)
GO(SDL_GetError, pFv)
@@ -201,15 +201,15 @@ GOM(SDL_GetEventFilter, iFEpp)
GO(SDL_GetGlobalMouseState, uFpp)
GO(SDL_GetGrabbedWindow, pFv)
GO(SDL_GetHint, pFp)
-GO(SDL_GetHintBoolean, iFpi)
+GO(SDL_GetHintBoolean, uFpu)
GOM(SDL_GetJoystickGUIDInfo, vFGppp)
GO(SDL_GetKeyboardFocus, pFv)
GO(SDL_GetKeyboardState, pFp)
-GO(SDL_GetKeyFromName, pFp)
-GO(SDL_GetKeyFromScancode, uFu)
-GO(SDL_GetKeyName, pFu)
-GO(SDL_GetMemoryFunctions, iFpi)
-GO(SDL_GetModState, pFv)
+GO(SDL_GetKeyFromName, iFp)
+GO(SDL_GetKeyFromScancode, iFu)
+GO(SDL_GetKeyName, pFi)
+GO(SDL_GetMemoryFunctions, vFpppp)
+GO(SDL_GetModState, uFv)
GO(SDL_GetMouseFocus, pFv)
GO(SDL_GetMouseState, uFpp)
GO(SDL_GetNumAllocations, iFv)
@@ -222,13 +222,13 @@ GO(SDL_GetNumTouchFingers, iFu)
GO(SDL_GetNumVideoDisplays, iFv)
GO(SDL_GetNumVideoDrivers, iFv)
GO(SDL_GetPerformanceCounter, UFv)
-GO(SDL_GetPerformanceFrequency, UFv)
+GO(SDL_GetPerformanceFrequency, LFv)
GO(SDL_GetPixelFormatName, pFu)
GO(SDL_GetPlatform, pFv)
-GO(SDL_GetPowerInfo, iFpp)
+GO(SDL_GetPowerInfo, uFpp)
GO(SDL_GetPreferredLocales, pFv)
GO(SDL_GetPrefPath, pFpp)
-GO(SDL_GetQueuedAudioSize, uFi)
+GO(SDL_GetQueuedAudioSize, uFu)
GO(SDL_GetRelativeMouseMode, iFv)
GO(SDL_GetRelativeMouseState, uFpp)
GO(SDL_GetRenderDrawBlendMode, iFpp)
@@ -242,8 +242,8 @@ GO(SDL_GetRevision, pFv)
GO(SDL_GetRevisionNumber, iFv)
GO(SDL_GetRGB, vFupppp)
GO(SDL_GetRGBA, vFuppppp)
-GO(SDL_GetScancodeFromKey, uFu)
-GO(SDL_GetScancodeFromName, iFp)
+GO(SDL_GetScancodeFromKey, uFi)
+GO(SDL_GetScancodeFromName, uFp)
GO(SDL_GetScancodeName, pFu)
GO(SDL_GetShapedWindowMode, iFpp)
GO(SDL_GetSurfaceAlphaMod, iFpp)
@@ -256,9 +256,9 @@ GO(SDL_GetTextureColorMod, iFpppp)
GO(SDL_GetThreadID, LFp)
GO(SDL_GetThreadName, pFp)
GO(SDL_GetTicks, uFv)
-GO(SDL_GetTouchDevice, uFi)
-GO(SDL_GetTouchDeviceType, iFi)
-GO(SDL_GetTouchFinger, pFui)
+GO(SDL_GetTouchDevice, lFi)
+GO(SDL_GetTouchDeviceType, iFl)
+GO(SDL_GetTouchFinger, pFli)
GO(SDL_GetVersion, vFp)
GO(SDL_GetVideoDriver, pFi)
GO(SDL_GetWindowBordersSize, iFppppp)
@@ -280,8 +280,8 @@ GO(SDL_GetWindowSize, vFppp)
GO(SDL_GetWindowSurface, pFp)
GO(SDL_GetWindowTitle, pFp)
GO(SDL_GetWindowWMInfo, iFpp)
-GO(SDL_GetYUVConversionMode, iFv)
-GO(SDL_GetYUVConversionModeForResolution, iFii)
+GO(SDL_GetYUVConversionMode, uFv)
+GO(SDL_GetYUVConversionModeForResolution, uFii)
GO(SDL_GL_BindTexture, iFppp)
GO(SDL_GL_CreateContext, pFp)
GO(SDL_GL_DeleteContext, vFp)
@@ -333,10 +333,10 @@ GOM(SDL_HasAVX, iFv)
GOM(SDL_HasAVX2, iFv)
GOM(SDL_HasAVX512F, iFv)
GO(SDL_HasClipboardText, iFv)
-GO(SDL_HasColorKey, iFv)
-GO(SDL_HasEvent, iFv)
-GO(SDL_HasEvents, iFv)
-GO(SDL_HasIntersection, iFpp)
+GO(SDL_HasColorKey, uFp)
+GO(SDL_HasEvent, uFu)
+GO(SDL_HasEvents, uFuu)
+GO(SDL_HasIntersection, uFpp)
GOM(SDL_HasMMX, iFv)
GOM(SDL_HasNEON, iFv)
GOM(SDL_HasRDTSC, iFv)
@@ -353,15 +353,15 @@ GO(SDL_iconv_open, pFpp)
GO(SDL_iconv_string, pFpppL)
GO(SDL_Init, iFu)
GO(SDL_InitSubSystem, iFu)
-GO(SDL_IntersectRect, iFppp)
-GO(SDL_IntersectRectAndLine, iFppppp)
+GO(SDL_IntersectRect, uFppp)
+GO(SDL_IntersectRectAndLine, uFppppp)
GO(SDL_isdigit, iFi)
-GO(SDL_IsGameController, iFi)
-GO(SDL_IsScreenKeyboardShown, iFp)
+GO(SDL_IsGameController, uFi)
+GO(SDL_IsScreenKeyboardShown, uFp)
GO(SDL_IsScreenSaverEnabled, iFv)
-GO(SDL_IsShapedWindow, iFp)
+GO(SDL_IsShapedWindow, uFp)
GO(SDL_isspace, iFi)
-GO(SDL_IsTablet, iFv)
+GO(SDL_IsTablet, uFv)
GO(SDL_IsTextInputActive, iFv)
GO(SDL_itoa, pFipi)
GO(SDL_JoystickClose, vFp)
@@ -369,8 +369,8 @@ GO(SDL_JoystickCurrentPowerLevel, iFp)
GO(SDL_JoystickEventState, iFi)
GO(SDL_JoystickFromInstanceID, pFi)
GO(SDL_JoystickGetAttached, iFp)
-GO(SDL_JoystickGetAxis, iFpi)
-GO(SDL_JoystickGetAxisInitialState, iFpip)
+GO(SDL_JoystickGetAxis, wFpi)
+GO(SDL_JoystickGetAxisInitialState, uFpip)
GO(SDL_JoystickGetBall, iFpipp)
GO(SDL_JoystickGetButton, CFpi)
GO(SDL_JoystickGetDeviceGUID, HFi) // return a struct that is "uint8_t data[16]"
@@ -378,7 +378,7 @@ GO(SDL_JoystickGetDeviceInstanceID, iFi)
GO(SDL_JoystickGetDevicePlayerIndex, iFi)
GO(SDL_JoystickGetDeviceProduct, WFi)
GO(SDL_JoystickGetDeviceProductVersion, WFi)
-GO(SDL_JoystickGetDeviceType, iFi)
+GO(SDL_JoystickGetDeviceType, uFi)
GO(SDL_JoystickGetDeviceVendor, WFi)
GO(SDL_JoystickGetGUID, HFp)
GO(SDL_JoystickGetGUIDFromString, HFp)
@@ -387,7 +387,7 @@ GO(SDL_JoystickGetHat, CFpi)
GO(SDL_JoystickGetPlayerIndex, iFp)
GO(SDL_JoystickGetProduct, WFp)
GO(SDL_JoystickGetProductVersion, WFp)
-GO(SDL_JoystickGetType, iFp)
+GO(SDL_JoystickGetType, uFp)
GO(SDL_JoystickGetVendor, WFp)
GO(SDL_JoystickInstanceID, iFp)
GO(SDL_JoystickIsHaptic, iFp)
@@ -400,8 +400,8 @@ GO(SDL_JoystickNumHats, iFp)
GO(SDL_JoystickOpen, pFi)
GO(SDL_JoystickRumble, iFpWWu)
GO(SDL_JoystickUpdate, vFv)
-GO(SDL_LinuxSetThreadPriority, iFIi)
-GO(SDL_lltoa, pFIpi)
+GO(SDL_LinuxSetThreadPriority, iFli)
+GO(SDL_lltoa, pFlpi)
GOM(SDL_LoadBMP_RW, pFEpi)
GO(SDL_LoadDollarTemplates, iFip)
GO(SDL_LoadFile, pFpp)
@@ -424,7 +424,7 @@ GOM(SDL_LogDebug, vFEipV)
GOM(SDL_LogError, vFEipV)
GO(SDL_logf, fFf)
GOM(SDL_LogGetOutputFunction, vFEpp)
-GO(SDL_LogGetPriority, iFi)
+GO(SDL_LogGetPriority, uFi)
GOM(SDL_LogInfo, vFEipV)
GO2(SDL_LogMessage, vFiupV, SDL_LogMessageV)
GO(SDL_LogMessageV, vFiupV)
@@ -436,32 +436,32 @@ GOM(SDL_LogVerbose, vFEipV)
GOM(SDL_LogWarn, vFEipV)
GO(SDL_LowerBlit, iFpppp)
GO(SDL_LowerBlitScaled, iFpppp)
-GO(SDL_ltoa, pFlp)
-GO(SDL_malloc, pFu)
+GO(SDL_ltoa, pFlpi)
+GO(SDL_malloc, pFL)
GO(SDL_MapRGB, uFpCCC)
GO(SDL_MapRGBA, uFpCCCC)
GO(SDL_MasksToPixelFormatEnum, uFiuuuu)
GO(SDL_MaximizeWindow, vFp)
-GO(SDL_memcmp, iFppu)
+GO(SDL_memcmp, iFppL)
GO(SDL_memcpy, pFppu)
GO(SDL_memmove, pFppu)
GO(SDL_MemoryBarrierAcquireFunction, vFv)
GO(SDL_MemoryBarrierReleaseFunction, vFv)
-GO(SDL_memset, pFpiu)
+GO(SDL_memset, pFpiL)
GO(SDL_MinimizeWindow, vFp)
GO(SDL_MixAudio, vFppui)
GO(SDL_MixAudioFormat, vFppWui)
GO(SDL_MouseIsHaptic, iFv)
-GO(SDL_NewAudioStream, pFiCiiCi)
+GO(SDL_NewAudioStream, pFWCiWCi)
GO(SDL_NumHaptics, iFv)
GO(SDL_NumJoysticks, iFv)
GO(SDL_NumSensors, iFv)
GOM(SDL_OpenAudio, iFEpp)
GOM(SDL_OpenAudioDevice, iFEpippi)
GO(SDL_PauseAudio, vFi)
-GO(SDL_PauseAudioDevice, vFii)
-GO(SDL_PeepEvents, iFpiiuu)
-GO(SDL_PixelFormatEnumToMasks, iFuppppp)
+GO(SDL_PauseAudioDevice, vFui)
+GO(SDL_PeepEvents, iFpiuuu)
+GO(SDL_PixelFormatEnumToMasks, uFuppppp)
GO(SDL_PollEvent, iFp)
GO(SDL_pow, dFdd)
GO(SDL_powf, fFff)
@@ -469,7 +469,7 @@ GO(SDL_PumpEvents, vFv)
GO(SDL_PushEvent, iFp)
GO2(SDL_qsort, vFEpuup, my_qsort)
GO(SDL_QueryTexture, iFppppp)
-GO(SDL_QueueAudio, iFipu)
+GO(SDL_QueueAudio, iFupu)
GO(SDL_Quit, vFv)
GO(SDL_QuitSubSystem, vFu)
GO(SDL_RaiseWindow, vFp)
@@ -480,13 +480,13 @@ GOM(SDL_ReadLE16, uFEp)
GOM(SDL_ReadLE32, uFEp)
GOM(SDL_ReadLE64, UFEp)
GOM(SDL_ReadU8, uFEp)
-GO(SDL_realloc, pFpu)
-GO(SDL_RecordGesture, iFi)
+GO(SDL_realloc, pFpL)
+GO(SDL_RecordGesture, iFl)
GO(SDL_RegisterEvents, uFi)
GOM(SDL_RemoveTimer, iFEp)
GO(SDL_RenderClear, iFp)
GO(SDL_RenderCopy, iFpppp)
-GO(SDL_RenderCopyEx, iFppppdpi)
+GO(SDL_RenderCopyEx, iFppppdpu)
// SDL_RenderCopyExF
// SDL_RenderCopyF
GO(SDL_RenderDrawLine, iFpiiii)
@@ -513,11 +513,11 @@ GO(SDL_RenderGetLogicalSize, vFppp)
// SDL_RenderGetMetalLayer
GO(SDL_RenderGetScale, vFppp)
GO(SDL_RenderGetViewport, vFpp)
-GO(SDL_RenderIsClipEnabled, iFp)
+GO(SDL_RenderIsClipEnabled, uFp)
GO(SDL_RenderPresent, vFp)
GO(SDL_RenderReadPixels, iFppupi)
GO(SDL_RenderSetClipRect, iFpp)
-GO(SDL_RenderSetIntegerScale, iFpi)
+GO(SDL_RenderSetIntegerScale, iFpu)
GO(SDL_RenderSetLogicalSize, iFpii)
GO(SDL_RenderSetScale, iFpff)
GO(SDL_RenderSetViewport, iFpp)
@@ -533,8 +533,8 @@ GOM(SDL_RWFromMem, pFEpi)
GOM(SDL_SaveAllDollarTemplates, iFEp)
GOM(SDL_SaveBMP_RW, iFEppi)
GOM(SDL_SaveDollarTemplate, iFEip)
-GO(SDL_scalbn, dFdl)
-GO(SDL_scalbnf, fFfl)
+GO(SDL_scalbn, dFdi)
+GO(SDL_scalbnf, fFfi)
GO(SDL_SemPost, iFp)
GO(SDL_SemTryWait, iFp)
GO(SDL_SemValue, uFp)
@@ -555,17 +555,17 @@ GO(SDL_SemWaitTimeout, iFpu)
// SDL_SensorUpdate
// SDL_SetAssertionHandler
GO(SDL_SetClipboardText, iFp)
-GO(SDL_SetClipRect, iFpp)
+GO(SDL_SetClipRect, uFpp)
GO(SDL_SetColorKey, iFpiu)
GO(SDL_SetCursor, vFp)
GO(SDL_setenv, iFppi)
GO(SDL_SetError, iFppppp) // it use ..., so putarbitrary 4 args
GOM(SDL_SetEventFilter, vFEpp)
-GO(SDL_SetHint, iFpp)
-GO(SDL_SetHintWithPriority, iFppi)
+GO(SDL_SetHint, uFpp)
+GO(SDL_SetHintWithPriority, uFppu)
GO(SDL_SetMainReady, vFv)
// SDL_SetMemoryFunctions
-GO(SDL_SetModState, vFi)
+GO(SDL_SetModState, vFu)
GO(SDL_SetPaletteColors, iFppii)
// SDL_SetPixelFormatPalette
GO(SDL_SetRelativeMouseMode, iFi)
@@ -623,24 +623,24 @@ GO(SDL_strcasecmp, iFpp)
GO(SDL_strchr, pFpi)
GO(SDL_strcmp, iFpp)
GO(SDL_strdup, pFp)
-GO(SDL_strlcat, uFppu)
+GO(SDL_strlcat, LFppL)
GO(SDL_strlcpy, uFppu)
GO(SDL_strlen, uFp)
GO(SDL_strlwr, pFp)
-GO(SDL_strncasecmp, iFppu)
+GO(SDL_strncasecmp, iFppL)
GO(SDL_strncmp, iFppu)
GO(SDL_strrchr, pFpi)
GO(SDL_strrev, pFp)
GO(SDL_strstr, pFpp)
GO(SDL_strtod, dFpp)
-GO(SDL_strtol, iFppi)
-GO(SDL_strtoll, IFppi)
-GO(SDL_strtoul, uFppi)
-GO(SDL_strtoull, UFppi)
+GO(SDL_strtol, lFppi)
+GO(SDL_strtoll, lFppi)
+GO(SDL_strtoul, LFppi)
+GO(SDL_strtoull, LFppi)
GO(SDL_strupr, pFp)
GO(SDL_tan, dFd)
GO(SDL_tanf, fFf)
-GO(SDL_ThreadID, uFv)
+GO(SDL_ThreadID, LFv)
GO(SDL_TLSCreate, uFv)
GO(SDL_TLSGet, pFu)
GOM(SDL_TLSSet, iFEupp)
@@ -648,8 +648,8 @@ GO(SDL_tolower, iFi)
GO(SDL_toupper, iFi)
GO(SDL_TryLockMutex, iFp)
GO(SDL_uitoa, pFupi)
-GO(SDL_ulltoa, pFUpi)
-GO(SDL_ultoa, pFupi)
+GO(SDL_ulltoa, pFLpi)
+GO(SDL_ultoa, pFLpi)
GO(SDL_UnionRect, vFppp)
GOM(SDL_UnloadObject, vFEp)
GO(SDL_UnlockAudio, vFv)
@@ -686,7 +686,7 @@ GO(SDL_WasInit, uFu)
// SDL_wcsdup
// SDL_wcslcat
// SDL_wcslcpy
-GO(SDL_wcslen, uFp)
+GO(SDL_wcslen, LFp)
GOM(SDL_WriteBE16, uFEpW)
GOM(SDL_WriteBE32, uFEpu)
GOM(SDL_WriteBE64, uFEpU)
diff --git a/src/wrapped/wrappedsdl2image.c b/src/wrapped/wrappedsdl2image.c
index de520da..290d315 100755..100644
--- a/src/wrapped/wrappedsdl2image.c
+++ b/src/wrapped/wrappedsdl2image.c
@@ -24,7 +24,7 @@ const char* sdl2imageName = "libSDL2_image-2.0.so.0";
#include "wrappercallback.h"
-#define GO(A) \
+#define GO(A) \
EXPORT void *my2_##A(x64emu_t* emu, void* a) \
{ \
SDL2_RWops_t *rw = RWNativeStart2(emu, (SDL2_RWops_t*)a); \
diff --git a/src/wrapped/wrappedsdl2image_private.h b/src/wrapped/wrappedsdl2image_private.h
index 7c4af99..fac7878 100755..100644
--- a/src/wrapped/wrappedsdl2image_private.h
+++ b/src/wrapped/wrappedsdl2image_private.h
@@ -1,4 +1,6 @@
-#if defined(GO) && defined(GOM) && defined(GO2) && defined(DATA)
+#if !(defined(GO) && defined(GOM) && defined(GO2) && defined(DATA))
+#error Meh!
+#endif
DATA(__data_start, 4)
DATA(_edata, 4)
@@ -55,7 +57,7 @@ GOM(IMG_LoadTextureTyped_RW, pFEppip)
// IMG_QuitWEBP
// IMG_SaveJPG
// IMG_SaveJPG_RW
-GO(IMG_SavePNG, iFppi)
+GO(IMG_SavePNG, iFpp)
GOM(IMG_SavePNG_RW, iFEppi)
// _init
DATA(nsvg__colors, 4)
@@ -65,5 +67,3 @@ DATA(nsvg__colors, 4)
// nsvgParse
// nsvg__parseXML
// nsvgRasterize
-
-#endif \ No newline at end of file
diff --git a/src/wrapped/wrappedsdl2mixer.c b/src/wrapped/wrappedsdl2mixer.c
index 8bf9c4d..56a2a0e 100755..100644
--- a/src/wrapped/wrappedsdl2mixer.c
+++ b/src/wrapped/wrappedsdl2mixer.c
@@ -42,7 +42,7 @@ GO(4)
static uintptr_t my_EffectFunc_fct_##A = 0; \
static void my_EffectFunc_##A(int chan, void *stream, int len, void *udata) \
{ \
- RunFunction(my_context, my_EffectFunc_fct_##A, 4, chan, stream, len, udata); \
+ RunFunctionFmt(my_EffectFunc_fct_##A, "ipip", chan, stream, len, udata); \
}
SUPER()
#undef GO
@@ -66,7 +66,7 @@ static void* find_EffectFunc_Fct(void* fct)
static uintptr_t my_EffectDone_fct_##A = 0; \
static void my_EffectDone_##A(int chan, void *udata) \
{ \
- RunFunction(my_context, my_EffectDone_fct_##A, 2, chan, udata); \
+ RunFunctionFmt(my_EffectDone_fct_##A, "ip", chan, udata); \
}
SUPER()
#undef GO
@@ -90,7 +90,7 @@ static void* find_EffectDone_Fct(void* fct)
static uintptr_t my_MixFunc_fct_##A = 0; \
static void my_MixFunc_##A(void *udata, uint8_t *stream, int len) \
{ \
- RunFunction(my_context, my_MixFunc_fct_##A, 3, udata, stream, len); \
+ RunFunctionFmt(my_MixFunc_fct_##A, "ppi", udata, stream, len); \
}
SUPER()
#undef GO
@@ -114,7 +114,7 @@ static void* find_MixFunc_Fct(void* fct)
static uintptr_t my_ChannelFinished_fct_##A = 0; \
static void my_ChannelFinished_##A(int channel) \
{ \
- RunFunction(my_context, my_ChannelFinished_fct_##A, 1, channel); \
+ RunFunctionFmt(my_ChannelFinished_fct_##A, "i", channel); \
}
SUPER()
#undef GO
@@ -138,7 +138,7 @@ static void* find_ChannelFinished_Fct(void* fct)
static uintptr_t my_MusicFinished_fct_##A = 0; \
static void my_MusicFinished_##A() \
{ \
- RunFunction(my_context, my_MusicFinished_fct_##A, 0); \
+ RunFunctionFmt(my_MusicFinished_fct_##A, ""); \
}
SUPER()
#undef GO
diff --git a/src/wrapped/wrappedsdl2mixer_private.h b/src/wrapped/wrappedsdl2mixer_private.h
index db332fe..796e691 100755..100644
--- a/src/wrapped/wrappedsdl2mixer_private.h
+++ b/src/wrapped/wrappedsdl2mixer_private.h
@@ -17,15 +17,15 @@ GO(Mix_FadeInMusicPos,iFpiid)
GO(Mix_FadeOutChannel,iFii)
GO(Mix_FadeOutGroup,iFii)
GO(Mix_FadeOutMusic,iFi)
-GO(Mix_FadingChannel,iFi)
-GO(Mix_FadingMusic,iFv)
+GO(Mix_FadingChannel, uFi)
+GO(Mix_FadingMusic, uFv)
GO(Mix_FreeChunk,vFp)
GO(Mix_FreeMusic,vFp)
GO(Mix_GetChunk,pFi)
GO(Mix_GetChunkDecoder,pFi)
GO(Mix_GetMusicDecoder,pFi)
GO(Mix_GetMusicHookData,pFv)
-GO(Mix_GetMusicType,iFp)
+GO(Mix_GetMusicType, uFp)
GO(Mix_GetNumChunkDecoders,iFv)
GO(Mix_GetNumMusicDecoders,iFv)
GO(Mix_GetSoundFonts,pFv)
@@ -48,8 +48,8 @@ GO(Mix_LoadMUS,pFp)
GOM(Mix_LoadMUSType_RW,pFEpii)
GOM(Mix_LoadMUS_RW,pFEpi)
GOM(Mix_LoadWAV_RW,pFEpi)
-GO(Mix_OpenAudio,iFiuii)
-GO(Mix_OpenAudioDevice, iFiuiipi)
+GO(Mix_OpenAudio, iFiWii)
+GO(Mix_OpenAudioDevice, iFiWiipi)
GO(Mix_Pause,vFi)
GO(Mix_PauseMusic,vFv)
GO(Mix_Paused,iFi)
@@ -67,10 +67,10 @@ GO(Mix_ReserveChannels,iFi)
GO(Mix_Resume,vFi)
GO(Mix_ResumeMusic,vFv)
GO(Mix_RewindMusic,vFv)
-GO(Mix_SetDistance,iFiu)
+GO(Mix_SetDistance, iFiC)
GO(Mix_SetMusicCMD,iFp)
GO(Mix_SetMusicPosition,iFd)
-GO(Mix_SetPanning,iFiuu)
+GO(Mix_SetPanning, iFiCC)
GO(Mix_SetPosition,iFiwC)
GOM(MinorityMix_SetPosition, iFEiw)
GOM(Mix_SetPostMix,vFEpp)
diff --git a/src/wrapped/wrappedsdl2net.c b/src/wrapped/wrappedsdl2net.c
index 7009e4b..7009e4b 100755..100644
--- a/src/wrapped/wrappedsdl2net.c
+++ b/src/wrapped/wrappedsdl2net.c
diff --git a/src/wrapped/wrappedsdl2net_private.h b/src/wrapped/wrappedsdl2net_private.h
index 6986d4d..29bcd05 100755..100644
--- a/src/wrapped/wrappedsdl2net_private.h
+++ b/src/wrapped/wrappedsdl2net_private.h
@@ -42,4 +42,4 @@ GO(SDLNet_UDP_SetPacketLoss, vFpi)
GO(SDLNet_UDP_Unbind, vFpi)
GO(SDLNet_Write16, vFWp)
GO(SDLNet_Write32, vFup)
-GO(SDLNet_version, pFv) \ No newline at end of file
+GO(SDLNet_version, pFv)
diff --git a/src/wrapped/wrappedsdl2ttf.c b/src/wrapped/wrappedsdl2ttf.c
index b0075b3..b0075b3 100755..100644
--- a/src/wrapped/wrappedsdl2ttf.c
+++ b/src/wrapped/wrappedsdl2ttf.c
diff --git a/src/wrapped/wrappedsdl2ttf_private.h b/src/wrapped/wrappedsdl2ttf_private.h
index cb08016..0da9134 100755..100644
--- a/src/wrapped/wrappedsdl2ttf_private.h
+++ b/src/wrapped/wrappedsdl2ttf_private.h
@@ -2,27 +2,27 @@
#error Meh!
#endif
-GO(TTF_ByteSwappedUNICODE, vFi)
+GO(TTF_ByteSwappedUNICODE, vFu)
GO(TTF_CloseFont, vFp)
GO(TTF_FontAscent, iFp)
GO(TTF_FontDescent, iFp)
GO(TTF_FontFaceFamilyName, pFp)
GO(TTF_FontFaceIsFixedWidth, iFp)
-GO(TTF_FontFaces, iFp)
+GO(TTF_FontFaces, lFp)
GO(TTF_FontFaceStyleName, pFp)
GO(TTF_FontHeight, iFp)
GO(TTF_FontLineSkip, iFp)
GO(TTF_GetFontHinting, iFp)
GO(TTF_GetFontKerning, iFp)
-GO(TTF_GetFontKerningSize, iFp)
+GO(TTF_GetFontKerningSize, iFpii)
GO(TTF_GetFontOutline, iFp)
GO(TTF_GetFontStyle, iFp)
-GO(TTF_GlyphIsProvided, iFpu)
-GO(TTF_GlyphMetrics, iFpuppppp)
+GO(TTF_GlyphIsProvided, iFpW)
+GO(TTF_GlyphMetrics, iFpWppppp)
GO(TTF_Init, iFv)
GO(TTF_Linked_Version, pFv)
GO(TTF_OpenFont, pFpi)
-GO(TTF_OpenFontIndex, pFpii)
+GO(TTF_OpenFontIndex, pFpil)
GOM(TTF_OpenFontIndexRW, pFEpiii)
GOM(TTF_OpenFontRW, pFEpii)
GO(TTF_Quit, vFv)
diff --git a/src/wrapped/wrappedsecret1.c b/src/wrapped/wrappedsecret1.c
index d3597a1..d3597a1 100755..100644
--- a/src/wrapped/wrappedsecret1.c
+++ b/src/wrapped/wrappedsecret1.c
diff --git a/src/wrapped/wrappedsecret1_private.h b/src/wrapped/wrappedsecret1_private.h
index df7d74b..df7d74b 100755..100644
--- a/src/wrapped/wrappedsecret1_private.h
+++ b/src/wrapped/wrappedsecret1_private.h
diff --git a/src/wrapped/wrappedselinux.c b/src/wrapped/wrappedselinux.c
index 9e58f20..9e58f20 100755..100644
--- a/src/wrapped/wrappedselinux.c
+++ b/src/wrapped/wrappedselinux.c
diff --git a/src/wrapped/wrappedselinux_private.h b/src/wrapped/wrappedselinux_private.h
index 94a4f73..94a4f73 100755..100644
--- a/src/wrapped/wrappedselinux_private.h
+++ b/src/wrapped/wrappedselinux_private.h
diff --git a/src/wrapped/wrappedsmime3.c b/src/wrapped/wrappedsmime3.c
index a9eea34..858c16b 100755..100644
--- a/src/wrapped/wrappedsmime3.c
+++ b/src/wrapped/wrappedsmime3.c
@@ -39,7 +39,7 @@ GO(4)
static uintptr_t my_SECKEYGetPasswordKey_fct_##A = 0; \
static void* my_SECKEYGetPasswordKey_##A(void* a, void* b) \
{ \
- return (void*)RunFunction(my_context, my_SECKEYGetPasswordKey_fct_##A, 2, a, b);\
+ return (void*)RunFunctionFmt(my_SECKEYGetPasswordKey_fct_##A, "pp", a, b);\
}
SUPER()
#undef GO
@@ -62,7 +62,7 @@ static void* find_SECKEYGetPasswordKey_Fct(void* fct)
static uintptr_t my_digestOpenFn_fct_##A = 0; \
static int my_digestOpenFn_##A(void* a, int b) \
{ \
- return RunFunction(my_context, my_digestOpenFn_fct_##A, 2, a, b); \
+ return RunFunctionFmt(my_digestOpenFn_fct_##A, "pi", a, b); \
}
SUPER()
#undef GO
@@ -85,7 +85,7 @@ static void* find_digestOpenFn_Fct(void* fct)
static uintptr_t my_digestCloseFn_fct_##A = 0; \
static int my_digestCloseFn_##A(void* a, int b) \
{ \
- return RunFunction(my_context, my_digestCloseFn_fct_##A, 2, a, b); \
+ return RunFunctionFmt(my_digestCloseFn_fct_##A, "pi", a, b); \
}
SUPER()
#undef GO
@@ -108,7 +108,7 @@ static void* find_digestCloseFn_Fct(void* fct)
static uintptr_t my_digestIOFn_fct_##A = 0; \
static int my_digestIOFn_##A(void* a, void* b, unsigned long c) \
{ \
- return RunFunction(my_context, my_digestIOFn_fct_##A, 3, a, b, c); \
+ return RunFunctionFmt(my_digestIOFn_fct_##A, "ppL", a, b, c); \
}
SUPER()
#undef GO
@@ -131,7 +131,7 @@ static void* find_digestIOFn_Fct(void* fct)
static uintptr_t my_SEC_PKCS12NicknameCollisionCallback_fct_##A = 0; \
static void* my_SEC_PKCS12NicknameCollisionCallback_##A(void* a, void* b, void* c) \
{ \
- return (void*)RunFunction(my_context, my_SEC_PKCS12NicknameCollisionCallback_fct_##A, 3, a, b, c); \
+ return (void*)RunFunctionFmt(my_SEC_PKCS12NicknameCollisionCallback_fct_##A, "ppp", a, b, c); \
}
SUPER()
#undef GO
@@ -151,10 +151,10 @@ static void* find_SEC_PKCS12NicknameCollisionCallback_Fct(void* fct)
// SEC_PKCS12EncoderOutputCallback ...
#define GO(A) \
-static uintptr_t my_SEC_PKCS12EncoderOutputCallback_fct_##A = 0; \
-static void my_SEC_PKCS12EncoderOutputCallback_##A(void* a, void* b, unsigned long c) \
-{ \
- RunFunction(my_context, my_SEC_PKCS12EncoderOutputCallback_fct_##A, 3, a, b, c); \
+static uintptr_t my_SEC_PKCS12EncoderOutputCallback_fct_##A = 0; \
+static void my_SEC_PKCS12EncoderOutputCallback_##A(void* a, void* b, unsigned long c) \
+{ \
+ RunFunctionFmt(my_SEC_PKCS12EncoderOutputCallback_fct_##A, "ppL", a, b, c); \
}
SUPER()
#undef GO
@@ -177,7 +177,7 @@ static void* find_SEC_PKCS12EncoderOutputCallback_Fct(void* fct)
static uintptr_t my_NSSCMSContentCallback_fct_##A = 0; \
static void my_NSSCMSContentCallback_##A(void* a, void* b, unsigned long c) \
{ \
- RunFunction(my_context, my_NSSCMSContentCallback_fct_##A, 3, a, b, c); \
+ RunFunctionFmt(my_NSSCMSContentCallback_fct_##A, "ppL", a, b, c); \
}
SUPER()
#undef GO
@@ -200,7 +200,7 @@ static void* find_NSSCMSContentCallback_Fct(void* fct)
static uintptr_t my_PK11PasswordFunc_fct_##A = 0; \
static void* my_PK11PasswordFunc_##A(void* a, int b, void* c) \
{ \
- return (void*)RunFunction(my_context, my_PK11PasswordFunc_fct_##A, 3, a, b, c); \
+ return (void*)RunFunctionFmt(my_PK11PasswordFunc_fct_##A, "pip", a, b, c); \
}
SUPER()
#undef GO
@@ -223,7 +223,7 @@ static void* find_PK11PasswordFunc_Fct(void* fct)
static uintptr_t my_NSSCMSGetDecryptKeyCallback_fct_##A = 0; \
static void* my_NSSCMSGetDecryptKeyCallback_##A(void* a, void* b) \
{ \
- return (void*)RunFunction(my_context, my_NSSCMSGetDecryptKeyCallback_fct_##A, 2, a, b); \
+ return (void*)RunFunctionFmt(my_NSSCMSGetDecryptKeyCallback_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -241,6 +241,29 @@ static void* find_NSSCMSGetDecryptKeyCallback_Fct(void* fct)
return NULL;
}
+// CERTImportCertificateFunc ...
+#define GO(A) \
+static uintptr_t my_CERTImportCertificateFunc_fct_##A = 0; \
+static int my_CERTImportCertificateFunc_##A(void* a, void* b, int c) \
+{ \
+ return (int)RunFunctionFmt(my_CERTImportCertificateFunc_fct_##A, "ppi", a, b, c); \
+}
+SUPER()
+#undef GO
+static void* find_CERTImportCertificateFunc_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_CERTImportCertificateFunc_fct_##A == (uintptr_t)fct) return my_CERTImportCertificateFunc_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_CERTImportCertificateFunc_fct_##A == 0) {my_CERTImportCertificateFunc_fct_##A = (uintptr_t)fct; return my_CERTImportCertificateFunc_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for smime3 CERTImportCertificateFunc callback\n");
+ return NULL;
+}
+
#undef SUPER
EXPORT void my_SEC_PKCS12CreateExportContext(x64emu_t* emu, void* f, void* pwfnarg, void* slot, void* wincx)
@@ -248,7 +271,7 @@ EXPORT void my_SEC_PKCS12CreateExportContext(x64emu_t* emu, void* f, void* pwfna
my->SEC_PKCS12CreateExportContext(find_SECKEYGetPasswordKey_Fct(f), pwfnarg, slot, wincx);
}
-EXPORT void* my_SEC_PKCS12DecoderStart(x64emu_t* emu, void* item, void* slot, void* wincx, void* dOpen, void* dClose,
+EXPORT void* my_SEC_PKCS12DecoderStart(x64emu_t* emu, void* item, void* slot, void* wincx, void* dOpen, void* dClose,
void* dRead, void* dWrite, void* dArg)
{
return my->SEC_PKCS12DecoderStart(item, slot, wincx, find_digestOpenFn_Fct(dOpen), find_digestCloseFn_Fct(dClose),
@@ -274,6 +297,11 @@ EXPORT void* my_NSS_CMSEncoder_Start(x64emu_t* emu, void* cmsg, void* outputf, v
find_NSSCMSGetDecryptKeyCallback_Fct(decryptcb), decryptarg, detached, items);
}
+EXPORT int my_CERT_DecodeCertPackage(x64emu_t* emu, void* cert, int len, void* f, void* data)
+{
+ return my->CERT_DecodeCertPackage(cert, len, find_CERTImportCertificateFunc_Fct(f), data);
+}
+
#define CUSTOM_INIT \
getMy(lib);
diff --git a/src/wrapped/wrappedsmime3_private.h b/src/wrapped/wrappedsmime3_private.h
index 1bf39ae..f4e3bd8 100755..100644
--- a/src/wrapped/wrappedsmime3_private.h
+++ b/src/wrapped/wrappedsmime3_private.h
@@ -4,7 +4,7 @@
//GO(CERT_ConvertAndDecodeCertificate,
//GO(CERT_DecodeCertFromPackage,
-//GO(CERT_DecodeCertPackage,
+GOM(CERT_DecodeCertPackage, iFEpipp)
//GO(NSS_CMSContentInfo_GetBulkKey,
//GO(NSS_CMSContentInfo_GetBulkKeySize,
//GO(NSS_CMSContentInfo_GetContent,
diff --git a/src/wrapped/wrappedsmpeg.c b/src/wrapped/wrappedsmpeg.c
index cc552ba..c2bac56 100755..100644
--- a/src/wrapped/wrappedsmpeg.c
+++ b/src/wrapped/wrappedsmpeg.c
@@ -38,7 +38,7 @@ GO(4)
static uintptr_t my_dispcallback_fct_##A = 0; \
static void my_dispcallback_##A(void* dst, int32_t x, int32_t y, unsigned int w, unsigned int h)\
{ \
- RunFunction(my_context, my_dispcallback_fct_##A, 5, dst, x, y, w, h); \
+ RunFunctionFmt(my_dispcallback_fct_##A, "piiuu", dst, x, y, w, h); \
}
SUPER()
#undef GO
diff --git a/src/wrapped/wrappedsmpeg2.c b/src/wrapped/wrappedsmpeg2.c
index c95f0ba..e285c21 100755..100644
--- a/src/wrapped/wrappedsmpeg2.c
+++ b/src/wrapped/wrappedsmpeg2.c
@@ -38,7 +38,7 @@ GO(4)
static uintptr_t my_dispcallback_fct_##A = 0; \
static void my_dispcallback_##A(void* data, void* frame) \
{ \
- RunFunction(my_context, my_dispcallback_fct_##A, 2, data, frame); \
+ RunFunctionFmt(my_dispcallback_fct_##A, "pp", data, frame); \
}
SUPER()
#undef GO
diff --git a/src/wrapped/wrappedsmpeg2_private.h b/src/wrapped/wrappedsmpeg2_private.h
index e94bf48..e94bf48 100755..100644
--- a/src/wrapped/wrappedsmpeg2_private.h
+++ b/src/wrapped/wrappedsmpeg2_private.h
diff --git a/src/wrapped/wrappedsmpeg_private.h b/src/wrapped/wrappedsmpeg_private.h
index b06b958..b06b958 100755..100644
--- a/src/wrapped/wrappedsmpeg_private.h
+++ b/src/wrapped/wrappedsmpeg_private.h
diff --git a/src/wrapped/wrappedssl3.c b/src/wrapped/wrappedssl3.c
index 45bf1a0..45bf1a0 100755..100644
--- a/src/wrapped/wrappedssl3.c
+++ b/src/wrapped/wrappedssl3.c
diff --git a/src/wrapped/wrappedssl3_private.h b/src/wrapped/wrappedssl3_private.h
index 174b4c1..174b4c1 100755..100644
--- a/src/wrapped/wrappedssl3_private.h
+++ b/src/wrapped/wrappedssl3_private.h
diff --git a/src/wrapped/wrappedtbbbind.c b/src/wrapped/wrappedtbbbind.c
new file mode 100644
index 0000000..997438e
--- /dev/null
+++ b/src/wrapped/wrappedtbbbind.c
@@ -0,0 +1,54 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#define _GNU_SOURCE /* See feature_test_macros(7) */
+#include <dlfcn.h>
+
+#include "wrappedlibs.h"
+
+#include "wrapper.h"
+#include "bridge.h"
+#include "librarian/library_private.h"
+#include "x64emu.h"
+#include "debug.h"
+#include "myalign.h"
+#include "callback.h"
+#include "emu/x64emu_private.h"
+
+// Fake the lib for now, don't load it
+const char* tbbbindName = "libtbbbind_2_5.so";
+#define LIBNAME tbbbind
+
+EXPORT void my___TBB_internal_initialize_system_topology(size_t group, void* numa_code, void* numa_list, void* core_type, void* core_list)
+{ }
+
+EXPORT void* my___TBB_internal_allocate_binding_handler(int slot_num, int numa_id, int core_type_id, int max_threads_per_core)
+{
+ // dummy
+ return NULL;
+}
+
+EXPORT void my___TBB_internal_apply_affinity(void* handler, int slot)
+{ }
+
+EXPORT void my___TBB_internal_deallocate_binding_handler(void* handler)
+{ }
+
+EXPORT void my___TBB_internal_destroy_system_topology()
+{ }
+
+int getNCpu();
+EXPORT int my___TBB_internal_get_default_concurrency(int numa_id, int core_type, int max_threads_per_core)
+{
+ return getNCpu();
+}
+
+EXPORT void my___TBB_internal_restore_affinity(void* handler, int slot)
+{ }
+
+// this preinit basically open "box64" as dlopen
+#define PRE_INIT\
+ lib->w.lib = dlopen(NULL, RTLD_LAZY | RTLD_GLOBAL); \
+ if(0)
+
+#include "wrappedlib_init.h"
diff --git a/src/wrapped/wrappedtbbbind_private.h b/src/wrapped/wrappedtbbbind_private.h
new file mode 100644
index 0000000..9df20a3
--- /dev/null
+++ b/src/wrapped/wrappedtbbbind_private.h
@@ -0,0 +1,14 @@
+#if !(defined(GO) && defined(GOM) && defined(GO2) && defined(DATA))
+#error Meh...
+#endif
+
+GOM(__TBB_internal_allocate_binding_handler, pFiiii) //%%noE
+GOM(__TBB_internal_apply_affinity, vFpi) //%%noE
+GOM(__TBB_internal_deallocate_binding_handler, vFp) //%%noE
+GOM(__TBB_internal_destroy_system_topology, vFv) //%%noE
+GOM(__TBB_internal_get_default_concurrency, iFiii) //%%noE
+GOM(__TBB_internal_initialize_system_topology, vFLpppp) //%%noE
+GOM(__TBB_internal_restore_affinity, vFpi) //%%noE
+//GO(_ZN3tbb6detail2r115runtime_warningEPKcz,
+//DATA(_ZN3tbb6detail2r115system_topology12instance_ptrE,
+//GO(_ZN3tbb6detail2r117assertion_failureEPKciS3_S3_,
diff --git a/src/wrapped/wrappedtcmallocminimal.c b/src/wrapped/wrappedtcmallocminimal.c
index 4f179cf..4f179cf 100755..100644
--- a/src/wrapped/wrappedtcmallocminimal.c
+++ b/src/wrapped/wrappedtcmallocminimal.c
diff --git a/src/wrapped/wrappedtcmallocminimal_private.h b/src/wrapped/wrappedtcmallocminimal_private.h
index b1f6b1e..b1f6b1e 100755..100644
--- a/src/wrapped/wrappedtcmallocminimal_private.h
+++ b/src/wrapped/wrappedtcmallocminimal_private.h
diff --git a/src/wrapped/wrappedudev0.c b/src/wrapped/wrappedudev0.c
index 47d650f..4f2182a 100755..100644
--- a/src/wrapped/wrappedudev0.c
+++ b/src/wrapped/wrappedudev0.c
@@ -41,7 +41,7 @@ static uintptr_t my_log_fn_fct_##A = 0;
static void my_log_fn_##A(void* udev, int p, void *f, int l, void* fn, void* fmt, x64_va_list_t args) \
{ \
CONVERT_VALIST(args) \
- RunFunction(my_context, my_log_fn_fct_##A, 7, udev, p, f, l, fn, fmt, VARARGS); \
+ RunFunction(my_log_fn_fct_##A, 7, udev, p, f, l, fn, fmt, VARARGS); \
}
#else
#define GO(A) \
@@ -49,7 +49,7 @@ static uintptr_t my_log_fn_fct_##A = 0;
static void my_log_fn_##A(void* udev, int p, void *f, int l, void* fn, void* fmt, x64_va_list_t args) \
{ \
CREATE_VALIST_FROM_VALIST(args, thread_get_emu()->scratch); \
- RunFunction(my_context, my_log_fn_fct_##A, 7, udev, p, f, l, fn, fmt, VARARGS); \
+ RunFunction(my_log_fn_fct_##A, 7, udev, p, f, l, fn, fmt, VARARGS); \
}
#endif
SUPER()
diff --git a/src/wrapped/wrappedudev0_private.h b/src/wrapped/wrappedudev0_private.h
index 57c999e..57c999e 100755..100644
--- a/src/wrapped/wrappedudev0_private.h
+++ b/src/wrapped/wrappedudev0_private.h
diff --git a/src/wrapped/wrappedudev1.c b/src/wrapped/wrappedudev1.c
index 6c30a14..a82b61c 100755..100644
--- a/src/wrapped/wrappedudev1.c
+++ b/src/wrapped/wrappedudev1.c
@@ -41,7 +41,7 @@ static uintptr_t my_log_fn_fct_##A = 0;
static void my_log_fn_##A(void* udev, int p, void *f, int l, void* fn, void* fmt, x64_va_list_t args) \
{ \
CONVERT_VALIST(args) \
- RunFunction(my_context, my_log_fn_fct_##A, 7, udev, p, f, l, fn, fmt, VARARGS); \
+ RunFunction(my_log_fn_fct_##A, 7, udev, p, f, l, fn, fmt, VARARGS); \
}
#else
#define GO(A) \
@@ -49,7 +49,7 @@ static uintptr_t my_log_fn_fct_##A = 0;
static void my_log_fn_##A(void* udev, int p, void *f, int l, void* fn, void* fmt, x64_va_list_t args) \
{ \
CREATE_VALIST_FROM_VALIST(args, thread_get_emu()->scratch); \
- RunFunction(my_context, my_log_fn_fct_##A, 7, udev, p, f, l, fn, fmt, VARARGS); \
+ RunFunction(my_log_fn_fct_##A, 7, udev, p, f, l, fn, fmt, VARARGS); \
}
#endif
SUPER()
diff --git a/src/wrapped/wrappedudev1_private.h b/src/wrapped/wrappedudev1_private.h
index 3a6f1d9..3a6f1d9 100755..100644
--- a/src/wrapped/wrappedudev1_private.h
+++ b/src/wrapped/wrappedudev1_private.h
diff --git a/src/wrapped/wrappedutil.c b/src/wrapped/wrappedutil.c
index 3c2442a..3c2442a 100755..100644
--- a/src/wrapped/wrappedutil.c
+++ b/src/wrapped/wrappedutil.c
diff --git a/src/wrapped/wrappedvorbisfile.c b/src/wrapped/wrappedvorbisfile.c
index ad285fe..411a3ee 100755..100644
--- a/src/wrapped/wrappedvorbisfile.c
+++ b/src/wrapped/wrappedvorbisfile.c
@@ -49,9 +49,9 @@ GO(7)
// read
#define GO(A) \
static uintptr_t my_read_fct_##A = 0; \
-static unsigned long my_read_##A(void* ptr, unsigned long size, unsigned long nmemb, void* datasource) \
+static unsigned long my_read_##A(void* ptr, unsigned long size, unsigned long nmemb, void* datasource) \
{ \
- return RunFunction(my_context, my_read_fct_##A, 4, ptr, size, nmemb, datasource);\
+ return RunFunctionFmt(my_read_fct_##A, "pLLp", ptr, size, nmemb, datasource); \
}
SUPER()
#undef GO
@@ -73,7 +73,7 @@ static void* findreadFct(void* fct)
static uintptr_t my_seek_fct_##A = 0; \
static int my_seek_##A(void* ptr, int64_t offset, int whence) \
{ \
- return (int)RunFunction(my_context, my_seek_fct_##A, 3, ptr, offset, whence);\
+ return (int)RunFunctionFmt(my_seek_fct_##A, "pIi", ptr, offset, whence);\
}
SUPER()
#undef GO
@@ -95,7 +95,7 @@ static void* findseekFct(void* fct)
static uintptr_t my_close_fct_##A = 0; \
static int my_close_##A(void* ptr) \
{ \
- return (int)RunFunction(my_context, my_close_fct_##A, 1, ptr);\
+ return (int)RunFunctionFmt(my_close_fct_##A, "p", ptr);\
}
SUPER()
#undef GO
@@ -117,7 +117,7 @@ static void* findcloseFct(void* fct)
static uintptr_t my_tell_fct_##A = 0; \
static long my_tell_##A(void* ptr) \
{ \
- return (long)RunFunction(my_context, my_tell_fct_##A, 1, ptr);\
+ return (long)RunFunctionFmt(my_tell_fct_##A, "p", ptr);\
}
SUPER()
#undef GO
diff --git a/src/wrapped/wrappedvorbisfile_private.h b/src/wrapped/wrappedvorbisfile_private.h
index d721324..d721324 100755..100644
--- a/src/wrapped/wrappedvorbisfile_private.h
+++ b/src/wrapped/wrappedvorbisfile_private.h
diff --git a/src/wrapped/wrappedvulkan.c b/src/wrapped/wrappedvulkan.c
index b90747c..8cba577 100755..100644
--- a/src/wrapped/wrappedvulkan.c
+++ b/src/wrapped/wrappedvulkan.c
@@ -53,7 +53,7 @@ static void* resolveSymbol(x64emu_t* emu, void* symbol, const char* rname)
printf_dlsym(LOG_DEBUG, "%p\n", (void*)ret);
return (void*)ret; // already bridged
}
- // get wrapper
+ // get wrapper
khint_t k = kh_get(symbolmap, emu->context->vkwrappers, rname);
if(k==kh_end(emu->context->vkwrappers) && strstr(rname, "KHR")==NULL) {
// try again, adding KHR at the end if not present
@@ -74,7 +74,7 @@ static void* resolveSymbol(x64emu_t* emu, void* symbol, const char* rname)
return (void*)ret;
}
-EXPORT void* my_vkGetDeviceProcAddr(x64emu_t* emu, void* device, void* name)
+EXPORT void* my_vkGetDeviceProcAddr(x64emu_t* emu, void* device, void* name)
{
khint_t k;
const char* rname = (const char*)name;
@@ -84,8 +84,8 @@ EXPORT void* my_vkGetDeviceProcAddr(x64emu_t* emu, void* device, void* name)
fillVulkanProcWrapper(emu->context);
k = kh_get(symbolmap, emu->context->vkmymap, rname);
int is_my = (k==kh_end(emu->context->vkmymap))?0:1;
- void* symbol;
- if(is_my) {
+ void* symbol = my->vkGetDeviceProcAddr(device, name);
+ if(symbol && is_my) { // only wrap if symbol exist
// try again, by using custom "my_" now...
char tmp[200];
strcpy(tmp, "my_");
@@ -95,8 +95,7 @@ EXPORT void* my_vkGetDeviceProcAddr(x64emu_t* emu, void* device, void* name)
#define GO(A, W) if(!strcmp(rname, #A)) my->A = (W)my->vkGetDeviceProcAddr(device, name);
SUPER()
#undef GO
- } else
- symbol = my->vkGetDeviceProcAddr(device, name);
+ }
if(!symbol) {
printf_dlsym(LOG_DEBUG, "%p\n", NULL);
return NULL; // easy
@@ -104,7 +103,7 @@ EXPORT void* my_vkGetDeviceProcAddr(x64emu_t* emu, void* device, void* name)
return resolveSymbol(emu, symbol, rname);
}
-EXPORT void* my_vkGetInstanceProcAddr(x64emu_t* emu, void* instance, void* name)
+EXPORT void* my_vkGetInstanceProcAddr(x64emu_t* emu, void* instance, void* name)
{
khint_t k;
const char* rname = (const char*)name;
@@ -192,10 +191,10 @@ GO(4)
// Allocation ...
#define GO(A) \
-static uintptr_t my_Allocation_fct_##A = 0; \
-static void* my_Allocation_##A(void* a, size_t b, size_t c, int d) \
-{ \
- return (void*)RunFunction(my_context, my_Allocation_fct_##A, 4, a, b, c, d); \
+static uintptr_t my_Allocation_fct_##A = 0; \
+static void* my_Allocation_##A(void* a, size_t b, size_t c, int d) \
+{ \
+ return (void*)RunFunctionFmt(my_Allocation_fct_##A, "pLLi", a, b, c, d); \
}
SUPER()
#undef GO
@@ -214,10 +213,10 @@ static void* find_Allocation_Fct(void* fct)
}
// Reallocation ...
#define GO(A) \
-static uintptr_t my_Reallocation_fct_##A = 0; \
-static void* my_Reallocation_##A(void* a, void* b, size_t c, size_t d, int e) \
-{ \
- return (void*)RunFunction(my_context, my_Reallocation_fct_##A, 5, a, b, c, d, e); \
+static uintptr_t my_Reallocation_fct_##A = 0; \
+static void* my_Reallocation_##A(void* a, void* b, size_t c, size_t d, int e) \
+{ \
+ return (void*)RunFunctionFmt(my_Reallocation_fct_##A, "ppLLi", a, b, c, d, e); \
}
SUPER()
#undef GO
@@ -239,7 +238,7 @@ static void* find_Reallocation_Fct(void* fct)
static uintptr_t my_Free_fct_##A = 0; \
static void my_Free_##A(void* a, void* b) \
{ \
- RunFunction(my_context, my_Free_fct_##A, 2, a, b); \
+ RunFunctionFmt(my_Free_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -258,10 +257,10 @@ static void* find_Free_Fct(void* fct)
}
// InternalAllocNotification ...
#define GO(A) \
-static uintptr_t my_InternalAllocNotification_fct_##A = 0; \
-static void my_InternalAllocNotification_##A(void* a, size_t b, int c, int d) \
-{ \
- RunFunction(my_context, my_InternalAllocNotification_fct_##A, 4, a, b, c, d); \
+static uintptr_t my_InternalAllocNotification_fct_##A = 0; \
+static void my_InternalAllocNotification_##A(void* a, size_t b, int c, int d) \
+{ \
+ RunFunctionFmt(my_InternalAllocNotification_fct_##A, "pLii", a, b, c, d); \
}
SUPER()
#undef GO
@@ -280,10 +279,10 @@ static void* find_InternalAllocNotification_Fct(void* fct)
}
// InternalFreeNotification ...
#define GO(A) \
-static uintptr_t my_InternalFreeNotification_fct_##A = 0; \
-static void my_InternalFreeNotification_##A(void* a, size_t b, int c, int d) \
-{ \
- RunFunction(my_context, my_InternalFreeNotification_fct_##A, 4, a, b, c, d); \
+static uintptr_t my_InternalFreeNotification_fct_##A = 0; \
+static void my_InternalFreeNotification_##A(void* a, size_t b, int c, int d) \
+{ \
+ RunFunctionFmt(my_InternalFreeNotification_fct_##A, "pLii", a, b, c, d); \
}
SUPER()
#undef GO
@@ -302,10 +301,10 @@ static void* find_InternalFreeNotification_Fct(void* fct)
}
// DebugReportCallbackEXT ...
#define GO(A) \
-static uintptr_t my_DebugReportCallbackEXT_fct_##A = 0; \
-static int my_DebugReportCallbackEXT_##A(int a, int b, uint64_t c, size_t d, int e, void* f, void* g, void* h) \
-{ \
- return RunFunction(my_context, my_DebugReportCallbackEXT_fct_##A, 8, a, b, c, d, e, f, g, h); \
+static uintptr_t my_DebugReportCallbackEXT_fct_##A = 0; \
+static int my_DebugReportCallbackEXT_##A(int a, int b, uint64_t c, size_t d, int e, void* f, void* g, void* h) \
+{ \
+ return RunFunctionFmt(my_DebugReportCallbackEXT_fct_##A, "iiULippp", a, b, c, d, e, f, g, h); \
}
SUPER()
#undef GO
@@ -618,7 +617,7 @@ EXPORT void my_vkGetPhysicalDeviceMemoryProperties(x64emu_t* emu, void* device,
my->vkGetPhysicalDeviceMemoryProperties(device, pProps);
}
-EXPORT void my_vkCmdPipelineBarrier(x64emu_t* emu, void* device, int src, int dst, int dep,
+EXPORT void my_vkCmdPipelineBarrier(x64emu_t* emu, void* device, int src, int dst, int dep,
uint32_t barrierCount, void* pBarriers, uint32_t bufferCount, void* pBuffers, uint32_t imageCount, void* pImages)
{
my->vkCmdPipelineBarrier(device, src, dst, dep, barrierCount, pBarriers, bufferCount, pBuffers, imageCount, pImages);
@@ -632,12 +631,12 @@ typedef struct my_VkDebugReportCallbackCreateInfoEXT_s {
void* pUserData;
} my_VkDebugReportCallbackCreateInfoEXT_t;
-EXPORT int my_vkCreateDebugReportCallbackEXT(x64emu_t* emu, void* instance,
- my_VkDebugReportCallbackCreateInfoEXT_t* create,
+EXPORT int my_vkCreateDebugReportCallbackEXT(x64emu_t* emu, void* instance,
+ my_VkDebugReportCallbackCreateInfoEXT_t* create,
my_VkAllocationCallbacks_t* alloc, void* callback)
{
my_VkDebugReportCallbackCreateInfoEXT_t dbg = *create;
- my_VkAllocationCallbacks_t my_alloc;
+ my_VkAllocationCallbacks_t my_alloc;
dbg.pfnCallback = find_DebugReportCallbackEXT_Fct(dbg.pfnCallback);
return my->vkCreateDebugReportCallbackEXT(instance, &dbg, find_VkAllocationCallbacks(&my_alloc, alloc), callback);
}
@@ -648,4 +647,4 @@ EXPORT int my_vkDestroyDebugReportCallbackEXT(x64emu_t* emu, void* instance, voi
return my->vkDestroyDebugReportCallbackEXT(instance, callback, find_VkAllocationCallbacks(&my_alloc, alloc));
}
-CREATE(vkCreateHeadlessSurfaceEXT) \ No newline at end of file
+CREATE(vkCreateHeadlessSurfaceEXT)
diff --git a/src/wrapped/wrappedvulkan_private.h b/src/wrapped/wrappedvulkan_private.h
index 873f857..96ee093 100755..100644
--- a/src/wrapped/wrappedvulkan_private.h
+++ b/src/wrapped/wrappedvulkan_private.h
@@ -197,7 +197,7 @@ GO(vkGetPhysicalDeviceExternalFenceProperties, vFppp)
GO(vkGetPhysicalDeviceExternalSemaphoreProperties, vFppp)
GO(vkGetPhysicalDeviceFeatures2, vFpp)
GO(vkGetPhysicalDeviceFormatProperties2, vFpip)
-GO(vkGetPhysicalDeviceImageFormatProperties2, vFppp)
+GO(vkGetPhysicalDeviceImageFormatProperties2, iFppp)
GO(vkGetPhysicalDeviceMemoryProperties2, vFpp)
GO(vkGetPhysicalDeviceProperties2, vFpp)
GO(vkGetPhysicalDeviceQueueFamilyProperties2, vFppp) //VkQueueFamilyProperties2 seems OK
@@ -804,4 +804,28 @@ GO(vkCmdSetSampleMaskEXT, vFpip)
GO(vkCmdSetShadingRateImageEnableNV, vFpi)
GO(vkCmdSetTessellationDomainOriginEXT, vFpi)
GO(vkCmdSetViewportSwizzleNV, vFpuup)
-GO(vkCmdSetViewportWScalingEnableNV, vFpi) \ No newline at end of file
+GO(vkCmdSetViewportWScalingEnableNV, vFpi)
+
+// VK_KHR_external_memory_win32
+GO(vkGetMemoryWin32HandleKHR, iFppp)
+GO(vkGetMemoryWin32HandlePropertiesKHR, iFpipp)
+
+// VK_EXT_swapchain_maintenance1
+GO(vkReleaseSwapchainImagesEXT, iFpp)
+
+// VK_VALVE_descriptor_set_host_mapping
+GO(vkGetDescriptorSetHostMappingVALVE, vFppp)
+GO(vkGetDescriptorSetLayoutHostMappingInfoVALVE, vFppp)
+
+// VK_EXT_descriptor_buffer
+GO(vkCmdBindDescriptorBufferEmbeddedSamplersEXT, vFppUu)
+GO(vkCmdBindDescriptorBuffersEXT, vFpup)
+GO(vkCmdSetDescriptorBufferOffsetsEXT, vFppUuupp)
+GO(vkGetAccelerationStructureOpaqueCaptureDescriptorDataEXT, vFppp)
+GO(vkGetBufferOpaqueCaptureDescriptorDataEXT, vFppp)
+GO(vkGetDescriptorEXT, vFppLp)
+GO(vkGetDescriptorSetLayoutBindingOffsetEXT, vFpUup)
+GO(vkGetDescriptorSetLayoutSizeEXT, vFpUp)
+GO(vkGetImageOpaqueCaptureDescriptorDataEXT, vFppp)
+GO(vkGetImageViewOpaqueCaptureDescriptorDataEXT, vFppp)
+GO(vkGetSamplerOpaqueCaptureDescriptorDataEXT, vFppp)
diff --git a/src/wrapped/wrappedwaylandclient_private.h b/src/wrapped/wrappedwaylandclient_private.h
index fc2aeef..1d54f28 100644
--- a/src/wrapped/wrappedwaylandclient_private.h
+++ b/src/wrapped/wrappedwaylandclient_private.h
@@ -28,11 +28,11 @@ GO(wl_display_get_fd, iFp)
//GO(wl_display_get_protocol_error,
//DATA(wl_display_interface,
GO(wl_display_prepare_read, iFp)
-//GO(wl_display_prepare_read_queue,
+GO(wl_display_prepare_read_queue, iFpp)
GO(wl_display_read_events, iFp)
GO(wl_display_roundtrip, iFp)
//GO(wl_display_roundtrip_queue,
-//GO(wl_event_queue_destroy,
+GO(wl_event_queue_destroy, vFp)
//DATA(wl_keyboard_interface,
//GO(wl_list_empty,
//GO(wl_list_init,
@@ -44,28 +44,28 @@ GO(wl_display_roundtrip, iFp)
//DATA(wl_output_interface,
//DATA(wl_pointer_interface,
//GO(wl_proxy_add_dispatcher,
-//GO(wl_proxy_add_listener,
+GO(wl_proxy_add_listener, iFppp)
GO(wl_proxy_create, pFpp)
-//GO(wl_proxy_create_wrapper,
+GO(wl_proxy_create_wrapper, pFp)
GO(wl_proxy_destroy, vFp)
//GO(wl_proxy_get_class,
-//GO(wl_proxy_get_id,
-//GO(wl_proxy_get_listener,
+GO(wl_proxy_get_id, uFp)
+GO(wl_proxy_get_listener, pFp)
//GO(wl_proxy_get_tag,
-//GO(wl_proxy_get_user_data,
-//GO(wl_proxy_get_version,
+GO(wl_proxy_get_user_data, pFp)
+GO(wl_proxy_get_version, uFp)
//GO(wl_proxy_marshal,
//GO(wl_proxy_marshal_array,
-//GO(wl_proxy_marshal_array_constructor,
-//GO(wl_proxy_marshal_array_constructor_versioned,
+GO(wl_proxy_marshal_array_constructor, pFpupp)
+GO(wl_proxy_marshal_array_constructor_versioned, pFpuppu)
//GO(wl_proxy_marshal_array_flags,
//GO(wl_proxy_marshal_constructor,
//GO(wl_proxy_marshal_constructor_versioned,
//GO(wl_proxy_marshal_flags,
-//GO(wl_proxy_set_queue,
+GO(wl_proxy_set_queue, vFpp)
//GO(wl_proxy_set_tag,
-//GO(wl_proxy_set_user_data,
-//GO(wl_proxy_wrapper_destroy,
+GO(wl_proxy_set_user_data, vFpp)
+GO(wl_proxy_wrapper_destroy, vFp)
DATA(wl_region_interface, 40)
DATA(wl_registry_interface, 40)
DATA(wl_seat_interface, 40)
diff --git a/src/wrapped/wrappedxinerama.c b/src/wrapped/wrappedxinerama.c
index fed2403..fed2403 100755..100644
--- a/src/wrapped/wrappedxinerama.c
+++ b/src/wrapped/wrappedxinerama.c
diff --git a/src/wrapped/wrappedxinerama_private.h b/src/wrapped/wrappedxinerama_private.h
index ddc9c29..ddc9c29 100755..100644
--- a/src/wrapped/wrappedxinerama_private.h
+++ b/src/wrapped/wrappedxinerama_private.h
diff --git a/src/wrapped/wrappedxkbcommon_private.h b/src/wrapped/wrappedxkbcommon_private.h
index 1ab0c0c..6d4a3dc 100644
--- a/src/wrapped/wrappedxkbcommon_private.h
+++ b/src/wrapped/wrappedxkbcommon_private.h
@@ -20,7 +20,7 @@ GO(xkb_compose_table_unref, vFp)
//GO(xkb_context_get_log_level,
//GO(xkb_context_get_log_verbosity,
GO(xkb_context_get_user_data, pFp)
-//GO(xkb_context_include_path_append,
+GO(xkb_context_include_path_append, iFpp)
//GO(xkb_context_include_path_append_default,
//GO(xkb_context_include_path_clear,
//GO(xkb_context_include_path_get,
@@ -49,7 +49,7 @@ GO(xkb_keymap_mod_get_index, uFpp)
GO(xkb_keymap_mod_get_name, pFpu)
GO(xkb_keymap_new_from_buffer, pFppLii)
//GO(xkb_keymap_new_from_file,
-//GO(xkb_keymap_new_from_names,
+GO(xkb_keymap_new_from_names, pFppi)
GO(xkb_keymap_new_from_string, pFppii)
GO(xkb_keymap_num_layouts, uFp)
GO(xkb_keymap_num_layouts_for_key, uFpu)
diff --git a/src/wrapped/wrappedxkbcommonx11.c b/src/wrapped/wrappedxkbcommonx11.c
index 04f945e..04f945e 100755..100644
--- a/src/wrapped/wrappedxkbcommonx11.c
+++ b/src/wrapped/wrappedxkbcommonx11.c
diff --git a/src/wrapped/wrappedxkbcommonx11_private.h b/src/wrapped/wrappedxkbcommonx11_private.h
index 3971945..3971945 100755..100644
--- a/src/wrapped/wrappedxkbcommonx11_private.h
+++ b/src/wrapped/wrappedxkbcommonx11_private.h
diff --git a/src/wrapped/wrappedxml2.c b/src/wrapped/wrappedxml2.c
index 271edfd..cb7aef3 100755..100644
--- a/src/wrapped/wrappedxml2.c
+++ b/src/wrapped/wrappedxml2.c
@@ -3,6 +3,7 @@
#include <string.h>
#define _GNU_SOURCE /* See feature_test_macros(7) */
#include <dlfcn.h>
+#include <stdarg.h>
#include "wrappedlibs.h"
@@ -15,6 +16,7 @@
#include "box64context.h"
#include "librarian.h"
#include "callback.h"
+#include "myalign.h"
const char* xml2Name =
#ifdef ANDROID
@@ -34,7 +36,7 @@ EXPORT uintptr_t my_xmlMemStrdup = 0;
void my_wrap_xmlFree(void* p)
{
if(my_xmlFree){
- RunFunction(my_context, my_xmlFree, 1, p);
+ RunFunctionFmt(my_xmlFree, "p", p);
return;
}
free(p);
@@ -42,21 +44,21 @@ void my_wrap_xmlFree(void* p)
void* my_wrap_xmlMalloc(size_t s)
{
if(my_xmlMalloc)
- return (void*)RunFunction(my_context, my_xmlMalloc, 1, s);
+ return (void*)RunFunctionFmt(my_xmlMalloc, "L", s);
else
return malloc(s);
}
void* my_wrap_xmlRealloc(void* p, size_t s)
{
if(my_xmlRealloc)
- return (void*)RunFunction(my_context, my_xmlRealloc, 2, p, s);
+ return (void*)RunFunctionFmt(my_xmlRealloc, "pL", p, s);
else
return realloc(p, s);
}
void* my_wrap_xmlMemStrdup(void* p)
{
if(my_xmlMemStrdup)
- return (void*)RunFunction(my_context, my_xmlMemStrdup, 1, p);
+ return (void*)RunFunctionFmt(my_xmlMemStrdup, "p", p);
else
return strdup(p);
}
@@ -96,10 +98,10 @@ GO(9)
// xmlHashCopier ...
#define GO(A) \
-static uintptr_t my_xmlHashCopier_fct_##A = 0; \
-static void* my_xmlHashCopier_##A(void* a, void* b) \
-{ \
- return (void*)RunFunction(my_context, my_xmlHashCopier_fct_##A, 2, a, b); \
+static uintptr_t my_xmlHashCopier_fct_##A = 0; \
+static void* my_xmlHashCopier_##A(void* a, void* b) \
+{ \
+ return (void*)RunFunctionFmt(my_xmlHashCopier_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -118,10 +120,10 @@ static void* find_xmlHashCopier_Fct(void* fct)
}
// xmlHashDeallocator ...
#define GO(A) \
-static uintptr_t my_xmlHashDeallocator_fct_##A = 0; \
-static void my_xmlHashDeallocator_##A(void* a, void* b) \
-{ \
- RunFunction(my_context, my_xmlHashDeallocator_fct_##A, 2, a, b); \
+static uintptr_t my_xmlHashDeallocator_fct_##A = 0; \
+static void my_xmlHashDeallocator_##A(void* a, void* b) \
+{ \
+ RunFunctionFmt(my_xmlHashDeallocator_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -140,10 +142,10 @@ static void* find_xmlHashDeallocator_Fct(void* fct)
}
// xmlHashScanner ...
#define GO(A) \
-static uintptr_t my_xmlHashScanner_fct_##A = 0; \
-static void my_xmlHashScanner_##A(void* a, void* b, void* c) \
-{ \
- RunFunction(my_context, my_xmlHashScanner_fct_##A, 3, a, b, c); \
+static uintptr_t my_xmlHashScanner_fct_##A = 0; \
+static void my_xmlHashScanner_##A(void* a, void* b, void* c) \
+{ \
+ RunFunctionFmt(my_xmlHashScanner_fct_##A, "ppp", a, b, c); \
}
SUPER()
#undef GO
@@ -162,10 +164,10 @@ static void* find_xmlHashScanner_Fct(void* fct)
}
// xmlHashScannerFull ...
#define GO(A) \
-static uintptr_t my_xmlHashScannerFull_fct_##A = 0; \
-static void my_xmlHashScannerFull_##A(void* a, void* b, void* c, void* c2, void* c3)\
-{ \
- RunFunction(my_context, my_xmlHashScannerFull_fct_##A, 5, a, b, c, c2, c3); \
+static uintptr_t my_xmlHashScannerFull_fct_##A = 0; \
+static void my_xmlHashScannerFull_##A(void* a, void* b, void* c, void* c2, void* c3) \
+{ \
+ RunFunctionFmt(my_xmlHashScannerFull_fct_##A, "ppppp", a, b, c, c2, c3);\
}
SUPER()
#undef GO
@@ -184,10 +186,10 @@ static void* find_xmlHashScannerFull_Fct(void* fct)
}
// xmlCharEncodingInputFunc ...
#define GO(A) \
-static uintptr_t my_xmlCharEncodingInputFunc_fct_##A = 0; \
-static int my_xmlCharEncodingInputFunc_##A(void* a, void* b, void* c, void* d) \
-{ \
- return RunFunction(my_context, my_xmlCharEncodingInputFunc_fct_##A, 4, a, b, c, d); \
+static uintptr_t my_xmlCharEncodingInputFunc_fct_##A = 0; \
+static int my_xmlCharEncodingInputFunc_##A(void* a, void* b, void* c, void* d) \
+{ \
+ return RunFunctionFmt(my_xmlCharEncodingInputFunc_fct_##A, "pppp", a, b, c, d); \
}
SUPER()
#undef GO
@@ -206,10 +208,10 @@ static void* find_xmlCharEncodingInputFunc_Fct(void* fct)
}
// xmlCharEncodingOutputFunc ...
#define GO(A) \
-static uintptr_t my_xmlCharEncodingOutputFunc_fct_##A = 0; \
-static int my_xmlCharEncodingOutputFunc_##A(void* a, void* b, void* c, void* d) \
-{ \
- return RunFunction(my_context, my_xmlCharEncodingOutputFunc_fct_##A, 4, a, b, c, d);\
+static uintptr_t my_xmlCharEncodingOutputFunc_fct_##A = 0; \
+static int my_xmlCharEncodingOutputFunc_##A(void* a, void* b, void* c, void* d) \
+{ \
+ return RunFunctionFmt(my_xmlCharEncodingOutputFunc_fct_##A, "pppp", a, b, c, d);\
}
SUPER()
#undef GO
@@ -228,10 +230,10 @@ static void* find_xmlCharEncodingOutputFunc_Fct(void* fct)
}
// xmlOutputWriteCallback ...
#define GO(A) \
-static uintptr_t my_xmlOutputWriteCallback_fct_##A = 0; \
-static int my_xmlOutputWriteCallback_##A(void* a, void* b, int c) \
-{ \
- return RunFunction(my_context, my_xmlOutputWriteCallback_fct_##A, 3, a, b, c); \
+static uintptr_t my_xmlOutputWriteCallback_fct_##A = 0; \
+static int my_xmlOutputWriteCallback_##A(void* a, void* b, int c) \
+{ \
+ return RunFunctionFmt(my_xmlOutputWriteCallback_fct_##A, "ppi", a, b, c); \
}
SUPER()
#undef GO
@@ -250,10 +252,10 @@ static void* find_xmlOutputWriteCallback_Fct(void* fct)
}
// xmlOutputCloseCallback ...
#define GO(A) \
-static uintptr_t my_xmlOutputCloseCallback_fct_##A = 0; \
-static int my_xmlOutputCloseCallback_##A(void* a) \
-{ \
- return RunFunction(my_context, my_xmlOutputCloseCallback_fct_##A, 1, a); \
+static uintptr_t my_xmlOutputCloseCallback_fct_##A = 0; \
+static int my_xmlOutputCloseCallback_##A(void* a) \
+{ \
+ return RunFunctionFmt(my_xmlOutputCloseCallback_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -272,10 +274,10 @@ static void* find_xmlOutputCloseCallback_Fct(void* fct)
}
// xmlInputMatchCallback ...
#define GO(A) \
-static uintptr_t my_xmlInputMatchCallback_fct_##A = 0; \
-static int my_xmlInputMatchCallback_##A(void* a) \
-{ \
- return RunFunction(my_context, my_xmlInputMatchCallback_fct_##A, 1, a); \
+static uintptr_t my_xmlInputMatchCallback_fct_##A = 0; \
+static int my_xmlInputMatchCallback_##A(void* a) \
+{ \
+ return RunFunctionFmt(my_xmlInputMatchCallback_fct_##A, "p", a);\
}
SUPER()
#undef GO
@@ -294,10 +296,10 @@ static void* find_xmlInputMatchCallback_Fct(void* fct)
}
// xmlInputOpenCallback ...
#define GO(A) \
-static uintptr_t my_xmlInputOpenCallback_fct_##A = 0; \
-static void* my_xmlInputOpenCallback_##A(void* a) \
-{ \
- return (void*)RunFunction(my_context, my_xmlInputOpenCallback_fct_##A, 1, a); \
+static uintptr_t my_xmlInputOpenCallback_fct_##A = 0; \
+static void* my_xmlInputOpenCallback_##A(void* a) \
+{ \
+ return (void*)RunFunctionFmt(my_xmlInputOpenCallback_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -316,10 +318,10 @@ static void* find_xmlInputOpenCallback_Fct(void* fct)
}
// xmlInputReadCallback ...
#define GO(A) \
-static uintptr_t my_xmlInputReadCallback_fct_##A = 0; \
-static int my_xmlInputReadCallback_##A(void* a, void* b, int c) \
-{ \
- return RunFunction(my_context, my_xmlInputReadCallback_fct_##A, 3, a, b, c); \
+static uintptr_t my_xmlInputReadCallback_fct_##A = 0; \
+static int my_xmlInputReadCallback_##A(void* a, void* b, int c) \
+{ \
+ return RunFunctionFmt(my_xmlInputReadCallback_fct_##A, "ppi", a, b, c); \
}
SUPER()
#undef GO
@@ -338,10 +340,10 @@ static void* find_xmlInputReadCallback_Fct(void* fct)
}
// xmlInputCloseCallback ...
#define GO(A) \
-static uintptr_t my_xmlInputCloseCallback_fct_##A = 0; \
-static int my_xmlInputCloseCallback_##A(void* a) \
-{ \
- return RunFunction(my_context, my_xmlInputCloseCallback_fct_##A, 1, a); \
+static uintptr_t my_xmlInputCloseCallback_fct_##A = 0; \
+static int my_xmlInputCloseCallback_##A(void* a) \
+{ \
+ return RunFunctionFmt(my_xmlInputCloseCallback_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -363,7 +365,7 @@ static void* find_xmlInputCloseCallback_Fct(void* fct)
static uintptr_t my_xmlSchemaValidityErrorFunc_fct_##A = 0; \
static void my_xmlSchemaValidityErrorFunc_##A(void* a, void* b, void* c, void* d, void* e, void* f, void* g, void* h, void* i) \
{ \
- RunFunction(my_context, my_xmlSchemaValidityErrorFunc_fct_##A, 9, a, b, c, d, e, f, g, h, i); \
+ RunFunctionFmt(my_xmlSchemaValidityErrorFunc_fct_##A, "ppppppppp", a, b, c, d, e, f, g, h, i); \
}
SUPER()
#undef GO
@@ -385,7 +387,7 @@ static void* find_xmlSchemaValidityErrorFunc_Fct(void* fct)
static uintptr_t my_xmlSchemaValidityWarningFunc_fct_##A = 0; \
static void my_xmlSchemaValidityWarningFunc_##A(void* a, void* b, void* c, void* d, void* e, void* f, void* g, void* h, void* i) \
{ \
- RunFunction(my_context, my_xmlSchemaValidityWarningFunc_fct_##A, 9, a, b, c, d, e, f, g, h, i); \
+ RunFunctionFmt(my_xmlSchemaValidityWarningFunc_fct_##A, "ppppppppp", a, b, c, d, e, f, g, h, i); \
}
SUPER()
#undef GO
@@ -402,34 +404,12 @@ static void* find_xmlSchemaValidityWarningFunc_Fct(void* fct)
printf_log(LOG_NONE, "Warning, no more slot for libxml2 xmlSchemaValidityWarningFunc callback\n");
return NULL;
}
-// xmlStructuredErrorFunc ...
-#define GO(A) \
-static uintptr_t my_xmlStructuredErrorFunc_fct_##A = 0; \
-static void my_xmlStructuredErrorFunc_##A(void* a, void* b) \
-{ \
- RunFunction(my_context, my_xmlStructuredErrorFunc_fct_##A, 2, a, b); \
-}
-SUPER()
-#undef GO
-static void* find_xmlStructuredErrorFunc_Fct(void* fct)
-{
- if(!fct) return fct;
- if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
- #define GO(A) if(my_xmlStructuredErrorFunc_fct_##A == (uintptr_t)fct) return my_xmlStructuredErrorFunc_##A;
- SUPER()
- #undef GO
- #define GO(A) if(my_xmlStructuredErrorFunc_fct_##A == 0) {my_xmlStructuredErrorFunc_fct_##A = (uintptr_t)fct; return my_xmlStructuredErrorFunc_##A; }
- SUPER()
- #undef GO
- printf_log(LOG_NONE, "Warning, no more slot for libxml2 xmlStructuredErrorFunc callback\n");
- return NULL;
-}
// xmlXPathFunction ...
#define GO(A) \
-static uintptr_t my_xmlXPathFunction_fct_##A = 0; \
-static void my_xmlXPathFunction_##A(void* a, int b) \
-{ \
- RunFunction(my_context, my_xmlXPathFunction_fct_##A, 2, a, b); \
+static uintptr_t my_xmlXPathFunction_fct_##A = 0; \
+static void my_xmlXPathFunction_##A(void* a, int b) \
+{ \
+ RunFunctionFmt(my_xmlXPathFunction_fct_##A, "pi", a, b);\
}
SUPER()
#undef GO
@@ -448,10 +428,10 @@ static void* find_xmlXPathFunction_Fct(void* fct)
}
// internalSubsetSAXFunc ...
#define GO(A) \
-static uintptr_t my_internalSubsetSAXFunc_fct_##A = 0; \
-static void my_internalSubsetSAXFunc_##A(void* a, void* b, void* c, void* d) \
-{ \
- RunFunction(my_context, my_internalSubsetSAXFunc_fct_##A, 4, a, b, c, d); \
+static uintptr_t my_internalSubsetSAXFunc_fct_##A = 0; \
+static void my_internalSubsetSAXFunc_##A(void* a, void* b, void* c, void* d) \
+{ \
+ RunFunctionFmt(my_internalSubsetSAXFunc_fct_##A, "pppp", a, b, c, d); \
}
SUPER()
#undef GO
@@ -470,10 +450,10 @@ static void* find_internalSubsetSAXFunc_Fct(void* fct)
}
// isStandaloneSAXFunc ...
#define GO(A) \
-static uintptr_t my_isStandaloneSAXFunc_fct_##A = 0; \
-static int my_isStandaloneSAXFunc_##A(void* a) \
-{ \
- return RunFunction(my_context, my_isStandaloneSAXFunc_fct_##A, 1, a); \
+static uintptr_t my_isStandaloneSAXFunc_fct_##A = 0; \
+static int my_isStandaloneSAXFunc_##A(void* a) \
+{ \
+ return RunFunctionFmt(my_isStandaloneSAXFunc_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -492,10 +472,10 @@ static void* find_isStandaloneSAXFunc_Fct(void* fct)
}
// hasInternalSubsetSAXFunc ...
#define GO(A) \
-static uintptr_t my_hasInternalSubsetSAXFunc_fct_##A = 0; \
-static int my_hasInternalSubsetSAXFunc_##A(void* a) \
-{ \
- return RunFunction(my_context, my_hasInternalSubsetSAXFunc_fct_##A, 1, a); \
+static uintptr_t my_hasInternalSubsetSAXFunc_fct_##A = 0; \
+static int my_hasInternalSubsetSAXFunc_##A(void* a) \
+{ \
+ return RunFunctionFmt(my_hasInternalSubsetSAXFunc_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -514,10 +494,10 @@ static void* find_hasInternalSubsetSAXFunc_Fct(void* fct)
}
// hasExternalSubsetSAXFunc ...
#define GO(A) \
-static uintptr_t my_hasExternalSubsetSAXFunc_fct_##A = 0; \
-static int my_hasExternalSubsetSAXFunc_##A(void* a) \
-{ \
- return RunFunction(my_context, my_hasExternalSubsetSAXFunc_fct_##A, 1, a); \
+static uintptr_t my_hasExternalSubsetSAXFunc_fct_##A = 0; \
+static int my_hasExternalSubsetSAXFunc_##A(void* a) \
+{ \
+ return RunFunctionFmt(my_hasExternalSubsetSAXFunc_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -536,10 +516,10 @@ static void* find_hasExternalSubsetSAXFunc_Fct(void* fct)
}
// resolveEntitySAXFunc ...
#define GO(A) \
-static uintptr_t my_resolveEntitySAXFunc_fct_##A = 0; \
-static void* my_resolveEntitySAXFunc_##A(void* a, void* b, void* c) \
-{ \
- return (void*)RunFunction(my_context, my_resolveEntitySAXFunc_fct_##A, 3, a, b, c); \
+static uintptr_t my_resolveEntitySAXFunc_fct_##A = 0; \
+static void* my_resolveEntitySAXFunc_##A(void* a, void* b, void* c) \
+{ \
+ return (void*)RunFunctionFmt(my_resolveEntitySAXFunc_fct_##A, "ppp", a, b, c); \
}
SUPER()
#undef GO
@@ -558,10 +538,10 @@ static void* find_resolveEntitySAXFunc_Fct(void* fct)
}
// getEntitySAXFunc ...
#define GO(A) \
-static uintptr_t my_getEntitySAXFunc_fct_##A = 0; \
-static void* my_getEntitySAXFunc_##A(void* a, void* b) \
-{ \
- return (void*)RunFunction(my_context, my_getEntitySAXFunc_fct_##A, 2, a, b); \
+static uintptr_t my_getEntitySAXFunc_fct_##A = 0; \
+static void* my_getEntitySAXFunc_##A(void* a, void* b) \
+{ \
+ return (void*)RunFunctionFmt(my_getEntitySAXFunc_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -580,10 +560,10 @@ static void* find_getEntitySAXFunc_Fct(void* fct)
}
// entityDeclSAXFunc ...
#define GO(A) \
-static uintptr_t my_entityDeclSAXFunc_fct_##A = 0; \
-static void my_entityDeclSAXFunc_##A(void* a, void* b, int c, void* d, void* e, void* f)\
-{ \
- RunFunction(my_context, my_entityDeclSAXFunc_fct_##A, 6, a, b, c, d, e, f); \
+static uintptr_t my_entityDeclSAXFunc_fct_##A = 0; \
+static void my_entityDeclSAXFunc_##A(void* a, void* b, int c, void* d, void* e, void* f) \
+{ \
+ RunFunctionFmt(my_entityDeclSAXFunc_fct_##A, "ppippp", a, b, c, d, e, f); \
}
SUPER()
#undef GO
@@ -602,10 +582,10 @@ static void* find_entityDeclSAXFunc_Fct(void* fct)
}
// notationDeclSAXFunc ...
#define GO(A) \
-static uintptr_t my_notationDeclSAXFunc_fct_##A = 0; \
-static void my_notationDeclSAXFunc_##A(void* a, void* b, void* c, void* d) \
-{ \
- RunFunction(my_context, my_notationDeclSAXFunc_fct_##A, 4, a, b, c, d); \
+static uintptr_t my_notationDeclSAXFunc_fct_##A = 0; \
+static void my_notationDeclSAXFunc_##A(void* a, void* b, void* c, void* d) \
+{ \
+ RunFunctionFmt(my_notationDeclSAXFunc_fct_##A, "pppp", a, b, c, d); \
}
SUPER()
#undef GO
@@ -627,7 +607,7 @@ static void* find_notationDeclSAXFunc_Fct(void* fct)
static uintptr_t my_attributeDeclSAXFunc_fct_##A = 0; \
static void my_attributeDeclSAXFunc_##A(void* a, void* b, void* c, int d, int e, void* f, void* g) \
{ \
- RunFunction(my_context, my_attributeDeclSAXFunc_fct_##A, 7, a, b, c, d, e, f, g); \
+ RunFunctionFmt(my_attributeDeclSAXFunc_fct_##A, "pppiipp", a, b, c, d, e, f, g); \
}
SUPER()
#undef GO
@@ -646,10 +626,10 @@ static void* find_attributeDeclSAXFunc_Fct(void* fct)
}
// elementDeclSAXFunc ...
#define GO(A) \
-static uintptr_t my_elementDeclSAXFunc_fct_##A = 0; \
-static void my_elementDeclSAXFunc_##A(void* a, void* b, int c, void* d) \
-{ \
- RunFunction(my_context, my_elementDeclSAXFunc_fct_##A, 4, a, b, c, d); \
+static uintptr_t my_elementDeclSAXFunc_fct_##A = 0; \
+static void my_elementDeclSAXFunc_##A(void* a, void* b, int c, void* d) \
+{ \
+ RunFunctionFmt(my_elementDeclSAXFunc_fct_##A, "ppip", a, b, c, d); \
}
SUPER()
#undef GO
@@ -668,10 +648,10 @@ static void* find_elementDeclSAXFunc_Fct(void* fct)
}
// unparsedEntityDeclSAXFunc ...
#define GO(A) \
-static uintptr_t my_unparsedEntityDeclSAXFunc_fct_##A = 0; \
-static void my_unparsedEntityDeclSAXFunc_##A(void* a, void* b, void* c, void* d, void* e) \
-{ \
- RunFunction(my_context, my_unparsedEntityDeclSAXFunc_fct_##A, 5, a, b, c, d, e); \
+static uintptr_t my_unparsedEntityDeclSAXFunc_fct_##A = 0; \
+static void my_unparsedEntityDeclSAXFunc_##A(void* a, void* b, void* c, void* d, void* e) \
+{ \
+ RunFunctionFmt(my_unparsedEntityDeclSAXFunc_fct_##A, "ppppp", a, b, c, d, e); \
}
SUPER()
#undef GO
@@ -690,10 +670,10 @@ static void* find_unparsedEntityDeclSAXFunc_Fct(void* fct)
}
// setDocumentLocatorSAXFunc ...
#define GO(A) \
-static uintptr_t my_setDocumentLocatorSAXFunc_fct_##A = 0; \
-static void my_setDocumentLocatorSAXFunc_##A(void* a, void* b) \
-{ \
- RunFunction(my_context, my_setDocumentLocatorSAXFunc_fct_##A, 2, a, b); \
+static uintptr_t my_setDocumentLocatorSAXFunc_fct_##A = 0; \
+static void my_setDocumentLocatorSAXFunc_##A(void* a, void* b) \
+{ \
+ RunFunctionFmt(my_setDocumentLocatorSAXFunc_fct_##A, "pp", a, b);\
}
SUPER()
#undef GO
@@ -712,10 +692,10 @@ static void* find_setDocumentLocatorSAXFunc_Fct(void* fct)
}
// startDocumentSAXFunc ...
#define GO(A) \
-static uintptr_t my_startDocumentSAXFunc_fct_##A = 0; \
-static void my_startDocumentSAXFunc_##A(void* a) \
-{ \
- RunFunction(my_context, my_startDocumentSAXFunc_fct_##A, 1, a); \
+static uintptr_t my_startDocumentSAXFunc_fct_##A = 0; \
+static void my_startDocumentSAXFunc_##A(void* a) \
+{ \
+ RunFunctionFmt(my_startDocumentSAXFunc_fct_##A, "p", a);\
}
SUPER()
#undef GO
@@ -734,10 +714,10 @@ static void* find_startDocumentSAXFunc_Fct(void* fct)
}
// endDocumentSAXFunc ...
#define GO(A) \
-static uintptr_t my_endDocumentSAXFunc_fct_##A = 0; \
-static void my_endDocumentSAXFunc_##A(void* a) \
-{ \
- RunFunction(my_context, my_endDocumentSAXFunc_fct_##A, 1, a); \
+static uintptr_t my_endDocumentSAXFunc_fct_##A = 0; \
+static void my_endDocumentSAXFunc_##A(void* a) \
+{ \
+ RunFunctionFmt(my_endDocumentSAXFunc_fct_##A, "p", a); \
}
SUPER()
#undef GO
@@ -756,10 +736,10 @@ static void* find_endDocumentSAXFunc_Fct(void* fct)
}
// startElementSAXFunc ...
#define GO(A) \
-static uintptr_t my_startElementSAXFunc_fct_##A = 0; \
-static void my_startElementSAXFunc_##A(void* a, void* b, void* c) \
-{ \
- RunFunction(my_context, my_startElementSAXFunc_fct_##A, 3, a, b, c); \
+static uintptr_t my_startElementSAXFunc_fct_##A = 0; \
+static void my_startElementSAXFunc_##A(void* a, void* b, void* c) \
+{ \
+ RunFunctionFmt(my_startElementSAXFunc_fct_##A, "ppp", a, b, c); \
}
SUPER()
#undef GO
@@ -778,10 +758,10 @@ static void* find_startElementSAXFunc_Fct(void* fct)
}
// endElementSAXFunc ...
#define GO(A) \
-static uintptr_t my_endElementSAXFunc_fct_##A = 0; \
-static void my_endElementSAXFunc_##A(void* a, void* b) \
-{ \
- RunFunction(my_context, my_endElementSAXFunc_fct_##A, 2, a, b); \
+static uintptr_t my_endElementSAXFunc_fct_##A = 0; \
+static void my_endElementSAXFunc_##A(void* a, void* b) \
+{ \
+ RunFunctionFmt(my_endElementSAXFunc_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -800,10 +780,10 @@ static void* find_endElementSAXFunc_Fct(void* fct)
}
// referenceSAXFunc ...
#define GO(A) \
-static uintptr_t my_referenceSAXFunc_fct_##A = 0; \
-static void my_referenceSAXFunc_##A(void* a, void* b) \
-{ \
- RunFunction(my_context, my_referenceSAXFunc_fct_##A, 2, a, b); \
+static uintptr_t my_referenceSAXFunc_fct_##A = 0; \
+static void my_referenceSAXFunc_##A(void* a, void* b) \
+{ \
+ RunFunctionFmt(my_referenceSAXFunc_fct_##A, "pp", a, b);\
}
SUPER()
#undef GO
@@ -822,10 +802,10 @@ static void* find_referenceSAXFunc_Fct(void* fct)
}
// charactersSAXFunc ...
#define GO(A) \
-static uintptr_t my_charactersSAXFunc_fct_##A = 0; \
-static void my_charactersSAXFunc_##A(void* a, void* b, int c) \
-{ \
- RunFunction(my_context, my_charactersSAXFunc_fct_##A, 3, a, b, c); \
+static uintptr_t my_charactersSAXFunc_fct_##A = 0; \
+static void my_charactersSAXFunc_##A(void* a, void* b, int c) \
+{ \
+ RunFunctionFmt(my_charactersSAXFunc_fct_##A, "ppi", a, b, c); \
}
SUPER()
#undef GO
@@ -844,10 +824,10 @@ static void* find_charactersSAXFunc_Fct(void* fct)
}
// ignorableWhitespaceSAXFunc ...
#define GO(A) \
-static uintptr_t my_ignorableWhitespaceSAXFunc_fct_##A = 0; \
-static void my_ignorableWhitespaceSAXFunc_##A(void* a, void* b, int c) \
-{ \
- RunFunction(my_context, my_ignorableWhitespaceSAXFunc_fct_##A, 3, a, b, c); \
+static uintptr_t my_ignorableWhitespaceSAXFunc_fct_##A = 0; \
+static void my_ignorableWhitespaceSAXFunc_##A(void* a, void* b, int c) \
+{ \
+ RunFunctionFmt(my_ignorableWhitespaceSAXFunc_fct_##A, "ppi", a, b, c); \
}
SUPER()
#undef GO
@@ -866,10 +846,10 @@ static void* find_ignorableWhitespaceSAXFunc_Fct(void* fct)
}
// processingInstructionSAXFunc ...
#define GO(A) \
-static uintptr_t my_processingInstructionSAXFunc_fct_##A = 0; \
-static void my_processingInstructionSAXFunc_##A(void* a, void* b, void* c) \
-{ \
- RunFunction(my_context, my_processingInstructionSAXFunc_fct_##A, 3, a, b, c); \
+static uintptr_t my_processingInstructionSAXFunc_fct_##A = 0; \
+static void my_processingInstructionSAXFunc_##A(void* a, void* b, void* c) \
+{ \
+ RunFunctionFmt(my_processingInstructionSAXFunc_fct_##A, "ppp", a, b, c); \
}
SUPER()
#undef GO
@@ -888,10 +868,10 @@ static void* find_processingInstructionSAXFunc_Fct(void* fct)
}
// commentSAXFunc ...
#define GO(A) \
-static uintptr_t my_commentSAXFunc_fct_##A = 0; \
-static void my_commentSAXFunc_##A(void* a, void* b) \
-{ \
- RunFunction(my_context, my_commentSAXFunc_fct_##A, 2, a, b); \
+static uintptr_t my_commentSAXFunc_fct_##A = 0; \
+static void my_commentSAXFunc_##A(void* a, void* b) \
+{ \
+ RunFunctionFmt(my_commentSAXFunc_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -910,10 +890,10 @@ static void* find_commentSAXFunc_Fct(void* fct)
}
// warningSAXFunc ...
#define GO(A) \
-static uintptr_t my_warningSAXFunc_fct_##A = 0; \
-static void my_warningSAXFunc_##A(void* a, void* b, void* c, void* d, void* e, void* f, void* g, void* h, void* i, void* j)\
-{ \
- RunFunction(my_context, my_warningSAXFunc_fct_##A, 10, a, b, c, d, e, f, g, h, i, j); \
+static uintptr_t my_warningSAXFunc_fct_##A = 0; \
+static void my_warningSAXFunc_##A(void* a, void* b, void* c, void* d, void* e, void* f, void* g, void* h, void* i, void* j) \
+{ \
+ RunFunctionFmt(my_warningSAXFunc_fct_##A, "pppppppppp", a, b, c, d, e, f, g, h, i, j); \
}
SUPER()
#undef GO
@@ -932,10 +912,10 @@ static void* find_warningSAXFunc_Fct(void* fct) // this one have a VAArg
}
// errorSAXFunc ...
#define GO(A) \
-static uintptr_t my_errorSAXFunc_fct_##A = 0; \
-static void my_errorSAXFunc_##A(void* a, void* b, void* c, void* d, void* e, void* f, void* g, void* h, void* i, void* j)\
-{ \
- RunFunction(my_context, my_errorSAXFunc_fct_##A, 10, a, b, c, d, e, f, g, h, i, j); \
+static uintptr_t my_errorSAXFunc_fct_##A = 0; \
+static void my_errorSAXFunc_##A(void* a, void* b, void* c, void* d, void* e, void* f, void* g, void* h, void* i, void* j) \
+{ \
+ RunFunctionFmt(my_errorSAXFunc_fct_##A, "pppppppppp", a, b, c, d, e, f, g, h, i, j); \
}
SUPER()
#undef GO
@@ -954,10 +934,10 @@ static void* find_errorSAXFunc_Fct(void* fct) // this one have a VAArg
}
// fatalErrorSAXFunc ...
#define GO(A) \
-static uintptr_t my_fatalErrorSAXFunc_fct_##A = 0; \
-static void my_fatalErrorSAXFunc_##A(void* a, void* b, void* c, void* d, void* e, void* f, void* g, void* h, void* i, void* j)\
-{ \
- RunFunction(my_context, my_fatalErrorSAXFunc_fct_##A, 10, a, b, c, d, e, f, g, h, i, j); \
+static uintptr_t my_fatalErrorSAXFunc_fct_##A = 0; \
+static void my_fatalErrorSAXFunc_##A(void* a, void* b, void* c, void* d, void* e, void* f, void* g, void* h, void* i, void* j) \
+{ \
+ RunFunctionFmt(my_fatalErrorSAXFunc_fct_##A, "pppppppppp", a, b, c, d, e, f, g, h, i, j); \
}
SUPER()
#undef GO
@@ -976,10 +956,10 @@ static void* find_fatalErrorSAXFunc_Fct(void* fct) // this one have a VAArg
}
// getParameterEntitySAXFunc ...
#define GO(A) \
-static uintptr_t my_getParameterEntitySAXFunc_fct_##A = 0; \
-static void* my_getParameterEntitySAXFunc_##A(void* a, void* b) \
-{ \
- return (void*)RunFunction(my_context, my_getParameterEntitySAXFunc_fct_##A, 2, a, b); \
+static uintptr_t my_getParameterEntitySAXFunc_fct_##A = 0; \
+static void* my_getParameterEntitySAXFunc_##A(void* a, void* b) \
+{ \
+ return (void*)RunFunctionFmt(my_getParameterEntitySAXFunc_fct_##A, "pp", a, b); \
}
SUPER()
#undef GO
@@ -998,10 +978,10 @@ static void* find_getParameterEntitySAXFunc_Fct(void* fct) // this one have a VA
}
// cdataBlockSAXFunc ...
#define GO(A) \
-static uintptr_t my_cdataBlockSAXFunc_fct_##A = 0; \
-static void my_cdataBlockSAXFunc_##A(void* a, void* b, int c) \
-{ \
- RunFunction(my_context, my_cdataBlockSAXFunc_fct_##A, 3, a, b, c); \
+static uintptr_t my_cdataBlockSAXFunc_fct_##A = 0; \
+static void my_cdataBlockSAXFunc_##A(void* a, void* b, int c) \
+{ \
+ RunFunctionFmt(my_cdataBlockSAXFunc_fct_##A, "ppi", a, b, c); \
}
SUPER()
#undef GO
@@ -1020,10 +1000,10 @@ static void* find_cdataBlockSAXFunc_Fct(void* fct) // this one have a VAArg
}
// externalSubsetSAXFunc ...
#define GO(A) \
-static uintptr_t my_externalSubsetSAXFunc_fct_##A = 0; \
-static void my_externalSubsetSAXFunc_##A(void* a, void* b, void* c, void* d) \
-{ \
- RunFunction(my_context, my_externalSubsetSAXFunc_fct_##A, 4, a, b, c, d); \
+static uintptr_t my_externalSubsetSAXFunc_fct_##A = 0; \
+static void my_externalSubsetSAXFunc_##A(void* a, void* b, void* c, void* d) \
+{ \
+ RunFunctionFmt(my_externalSubsetSAXFunc_fct_##A, "pppp", a, b, c, d); \
}
SUPER()
#undef GO
@@ -1045,7 +1025,7 @@ static void* find_externalSubsetSAXFunc_Fct(void* fct) // this one have a VAArg
static uintptr_t my_xmlSAX2StartElementNs_fct_##A = 0; \
static void my_xmlSAX2StartElementNs_##A(void* a, void* b, void* c, void* d, int e, void* f, int g, int h, void* i) \
{ \
- RunFunction(my_context, my_xmlSAX2StartElementNs_fct_##A, 9, a, b, c, d, e, f, g, h, i); \
+ RunFunctionFmt(my_xmlSAX2StartElementNs_fct_##A, "ppppipiip", a, b, c, d, e, f, g, h, i); \
}
SUPER()
#undef GO
@@ -1064,10 +1044,10 @@ static void* find_xmlSAX2StartElementNs_Fct(void* fct) // this one have a VAArg
}
// xmlSAX2EndElementNs ...
#define GO(A) \
-static uintptr_t my_xmlSAX2EndElementNs_fct_##A = 0; \
-static void my_xmlSAX2EndElementNs_##A(void* a, void* b, void* c, void* d) \
-{ \
- RunFunction(my_context, my_xmlSAX2EndElementNs_fct_##A, 4, a, b, c, d); \
+static uintptr_t my_xmlSAX2EndElementNs_fct_##A = 0; \
+static void my_xmlSAX2EndElementNs_##A(void* a, void* b, void* c, void* d) \
+{ \
+ RunFunctionFmt(my_xmlSAX2EndElementNs_fct_##A, "pppp", a, b, c, d); \
}
SUPER()
#undef GO
@@ -1087,10 +1067,10 @@ static void* find_xmlSAX2EndElementNs_Fct(void* fct) // this one have a VAArg
// xmlExternalEntityLoader
#define GO(A) \
-static uintptr_t my_xmlExternalEntityLoader_fct_##A = 0; \
-static void* my_xmlExternalEntityLoader_##A(void* a, void* b, void* c) \
-{ \
- return (void*)RunFunction(my_context, my_xmlExternalEntityLoader_fct_##A, 3, a, b, c); \
+static uintptr_t my_xmlExternalEntityLoader_fct_##A = 0; \
+static void* my_xmlExternalEntityLoader_##A(void* a, void* b, void* c) \
+{ \
+ return (void*)RunFunctionFmt(my_xmlExternalEntityLoader_fct_##A, "ppp", a, b, c); \
}
SUPER()
#undef GO
@@ -1119,6 +1099,146 @@ static void* reverse_xmlExternalEntityLoaderFct(void* fct)
}
+// xmlGenericErrorFunc
+#define GO(A) \
+static uintptr_t my_xmlGenericErrorFunc_fct_##A = 0; \
+static void my_xmlGenericErrorFunc_##A(void* a, const char* fmt, ...) \
+{ \
+ char buf[4096]; \
+ va_list args; \
+ va_start(args, fmt); \
+ vsnprintf(buf, 4096, fmt, args); \
+ va_end(args); \
+ RunFunctionFmt(my_xmlGenericErrorFunc_fct_##A, "pp", a, buf); \
+}
+SUPER()
+#undef GO
+static void* find_xmlGenericErrorFunc_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_xmlGenericErrorFunc_fct_##A == (uintptr_t)fct) return my_xmlGenericErrorFunc_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_xmlGenericErrorFunc_fct_##A == 0) {my_xmlGenericErrorFunc_fct_##A = (uintptr_t)fct; return my_xmlGenericErrorFunc_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libxml2 xmlGenericErrorFunc callback\n");
+ return NULL;
+}
+static void* reverse_xmlGenericErrorFunc_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(CheckBridged(my_lib->w.bridge, fct))
+ return (void*)CheckBridged(my_lib->w.bridge, fct);
+ #define GO(A) if(my_xmlGenericErrorFunc_##A == fct) return (void*)my_xmlGenericErrorFunc_fct_##A;
+ SUPER()
+ #undef GO
+ return (void*)AddBridge(my_lib->w.bridge, vFpp, fct, 0, "xmlGenericErrorFunc_callback");
+}
+
+// xmlStructuredErrorFunc
+#define GO(A) \
+static uintptr_t my_xmlStructuredErrorFunc_fct_##A = 0; \
+static void my_xmlStructuredErrorFunc_##A(void* a, const char* b) \
+{ \
+ RunFunctionFmt(my_xmlStructuredErrorFunc_fct_##A, "pp", a, b); \
+}
+SUPER()
+#undef GO
+static void* find_xmlStructuredErrorFunc_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_xmlStructuredErrorFunc_fct_##A == (uintptr_t)fct) return my_xmlStructuredErrorFunc_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_xmlStructuredErrorFunc_fct_##A == 0) {my_xmlStructuredErrorFunc_fct_##A = (uintptr_t)fct; return my_xmlStructuredErrorFunc_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libxml2 xmlStructuredErrorFunc callback\n");
+ return NULL;
+}
+static void* reverse_xmlStructuredErrorFunc_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(CheckBridged(my_lib->w.bridge, fct))
+ return (void*)CheckBridged(my_lib->w.bridge, fct);
+ #define GO(A) if(my_xmlStructuredErrorFunc_##A == fct) return (void*)my_xmlStructuredErrorFunc_fct_##A;
+ SUPER()
+ #undef GO
+ return (void*)AddBridge(my_lib->w.bridge, vFpp, fct, 0, "xmlStructuredErrorFunc_callback");
+}
+
+// xmlOutputMatchCallback ...
+#define GO(A) \
+static uintptr_t my_xmlOutputMatchCallback_fct_##A = 0; \
+static int my_xmlOutputMatchCallback_##A(void* a) \
+{ \
+ return (int)RunFunctionFmt(my_xmlOutputMatchCallback_fct_##A, "p", a); \
+}
+SUPER()
+#undef GO
+static void* find_xmlOutputMatchCallback_Fct(void* fct) // this one have a VAArg
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_xmlOutputMatchCallback_fct_##A == (uintptr_t)fct) return my_xmlOutputMatchCallback_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_xmlOutputMatchCallback_fct_##A == 0) {my_xmlOutputMatchCallback_fct_##A = (uintptr_t)fct; return my_xmlOutputMatchCallback_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libxml2 xmlOutputMatchCallback callback\n");
+ return NULL;
+}
+
+// xmlOutputOpenCallback ...
+#define GO(A) \
+static uintptr_t my_xmlOutputOpenCallback_fct_##A = 0; \
+static void* my_xmlOutputOpenCallback_##A(void* a) \
+{ \
+ return (void*)RunFunctionFmt(my_xmlOutputOpenCallback_fct_##A, "p", a); \
+}
+SUPER()
+#undef GO
+static void* find_xmlOutputOpenCallback_Fct(void* fct) // this one have a VAArg
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_xmlOutputOpenCallback_fct_##A == (uintptr_t)fct) return my_xmlOutputOpenCallback_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_xmlOutputOpenCallback_fct_##A == 0) {my_xmlOutputOpenCallback_fct_##A = (uintptr_t)fct; return my_xmlOutputOpenCallback_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libxml2 xmlOutputOpenCallback callback\n");
+ return NULL;
+}
+
+// xmlTextReaderErrorFunc ...
+#define GO(A) \
+static uintptr_t my_xmlTextReaderErrorFunc_fct_##A = 0; \
+static void my_xmlTextReaderErrorFunc_##A(void* a, void* b, int c, void* d) \
+{ \
+ RunFunctionFmt(my_xmlTextReaderErrorFunc_fct_##A, "ppip", a, b, c, d); \
+}
+SUPER()
+#undef GO
+static void* find_xmlTextReaderErrorFunc_Fct(void* fct) // this one have a VAArg
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_xmlTextReaderErrorFunc_fct_##A == (uintptr_t)fct) return my_xmlTextReaderErrorFunc_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_xmlTextReaderErrorFunc_fct_##A == 0) {my_xmlTextReaderErrorFunc_fct_##A = (uintptr_t)fct; return my_xmlTextReaderErrorFunc_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libxml2 xmlTextReaderErrorFunc callback\n");
+ return NULL;
+}
+
#undef SUPER
EXPORT void* my_xmlHashCopy(x64emu_t* emu, void* table, void* f)
@@ -1317,6 +1437,59 @@ EXPORT void* my_xmlCreateIOParserCtxt(x64emu_t* emu, my_xmlSAXHandler_t** p, voi
return ret;
}
+EXPORT void* my___xmlGenericError(x64emu_t* emu)
+{
+ return reverse_xmlGenericErrorFunc_Fct(my->__xmlGenericError());
+}
+
+EXPORT void* my___xmlStructuredError(x64emu_t* emu)
+{
+ return reverse_xmlStructuredErrorFunc_Fct(my->__xmlStructuredError());
+}
+
+EXPORT void my_xmlSetGenericErrorFunc(x64emu_t* emu, void* ctx, void* f)
+{
+ my->xmlSetGenericErrorFunc(ctx, find_xmlGenericErrorFunc_Fct(f));
+}
+
+EXPORT void my_xmlSetStructuredErrorFunc(x64emu_t* emu, void* ctx, void* f)
+{
+ my->xmlSetStructuredErrorFunc(ctx, find_xmlStructuredErrorFunc_Fct(f));
+}
+
+EXPORT int my_xmlRegisterOutputCallbacks(x64emu_t* emu, void* match, void* open, void* write, void* close)
+{
+ return my->xmlRegisterOutputCallbacks(find_xmlOutputMatchCallback_Fct(match), find_xmlOutputOpenCallback_Fct(open), find_xmlOutputWriteCallback_Fct(write), find_xmlOutputCloseCallback_Fct(close));
+}
+
+EXPORT int my_xmlTextWriterWriteVFormatAttribute(x64emu_t* emu, void* writer, void* name, void* fmt, x64_va_list_t b)
+{
+ #ifdef CONVERT_VALIST
+ CONVERT_VALIST(b);
+ #else
+ myStackAlignValist(emu, (const char*)fmt, emu->scratch, b);
+ PREPARE_VALIST;
+ #endif
+ return my->xmlTextWriterWriteVFormatAttribute(writer, name, fmt, VARARGS);
+}
+
+EXPORT int my_xmlTextWriterWriteFormatAttribute(x64emu_t* emu, void* writer, void* name, void* fmt, void* b)
+{
+ myStackAlign(emu, (const char*)fmt, b, emu->scratch, R_EAX, 2);
+ PREPARE_VALIST;
+ return my->xmlTextWriterWriteVFormatAttribute(writer, name, fmt, VARARGS);
+}
+
+EXPORT void* my_xmlReaderForIO(void *emu, void * ioread, void * ioclose, void * ioctx, char * URL, char * encoding, int options)
+{
+ return my->xmlReaderForIO(find_xmlInputReadCallback_Fct(ioread), find_xmlInputCloseCallback_Fct(ioclose), ioctx, URL, encoding, options);
+}
+
+EXPORT void my_xmlTextReaderSetErrorHandler(x64emu_t* emu, void* reader, void* f, void* arg)
+{
+ my->xmlTextReaderSetErrorHandler(reader, find_xmlTextReaderErrorFunc_Fct(f), arg);
+}
+
#define CUSTOM_INIT \
getMy(lib);
diff --git a/src/wrapped/wrappedxml2_private.h b/src/wrapped/wrappedxml2_private.h
index bb0c185..4a43dac 100755..100644
--- a/src/wrapped/wrappedxml2_private.h
+++ b/src/wrapped/wrappedxml2_private.h
@@ -164,7 +164,7 @@ GO(xmlBufferWriteCHAR, vFpp)
GO(xmlBufferWriteQuotedString, vFpp)
GO(xmlBuildQName, pFpppi)
GO(xmlBuildRelativeURI, pFpp)
-//GO(xmlBuildURI,
+GO(xmlBuildURI, pFpp)
GO(xmlByteConsumed, lFp)
//GO(xmlC14NDocDumpMemory,
//GO(xmlC14NDocSave,
@@ -190,7 +190,7 @@ GO(xmlByteConsumed, lFp)
//GO(xmlCatalogResolveURI,
//GO(xmlCatalogSetDebug,
//GO(xmlCatalogSetDefaultPrefer,
-//GO(xmlCatalogSetDefaults,
+GO(xmlCatalogSetDefaults, vFi)
GO(xmlCharEncCloseFunc, iFp)
GO(xmlCharEncFirstLine, iFppp)
//GO(xmlCharEncFirstLineInt,
@@ -361,14 +361,14 @@ GO(xmlFreePropList, vFp)
GO(xmlFreeRefTable, vFp)
//GO(xmlFreeRMutex,
//GO(xmlFreeStreamCtxt,
-//GO(xmlFreeTextReader,
-//GO(xmlFreeTextWriter,
+GO(xmlFreeTextReader, vFp)
+GO(xmlFreeTextWriter, vFp)
//GO(xmlFreeURI,
GO(xmlFreeValidCtxt, vFp)
//GO(xmlGcMemGet,
//GO(xmlGcMemSetup,
-//GO(__xmlGenericError,
-//GO(__xmlGenericErrorContext,
+GOM(__xmlGenericError, pFEv)
+GO(__xmlGenericErrorContext, pFv)
//GO(xmlGenericErrorDefaultFunc,
GO(xmlGetBufferAllocationScheme, iFv)
GO(xmlGetCharEncodingHandler, pFp)
@@ -434,7 +434,7 @@ GOM(xmlHashUpdateEntry3, iFEpppppp)
GO(xmlHasFeature, iFi)
GO(xmlHasNsProp, pFppp)
GO(xmlHasProp, pFpp)
-//GO(__xmlIndentTreeOutput,
+GO(__xmlIndentTreeOutput, pFv)
GO(xmlInitCharEncodingHandlers, vFv)
GO(xmlInitializeDict, iFv)
GO(xmlInitGlobals, vFv)
@@ -622,7 +622,7 @@ GO(xmlNewTextLen, pFpi)
//GO(xmlNewTextWriter,
//GO(xmlNewTextWriterDoc,
//GO(xmlNewTextWriterFilename,
-//GO(xmlNewTextWriterMemory,
+GO(xmlNewTextWriterMemory, pFpi)
//GO(xmlNewTextWriterPushParser,
//GO(xmlNewTextWriterTree,
GO(xmlNewValidCtxt, pFv)
@@ -776,8 +776,8 @@ GO(xmlReadDoc, pFpppi)
//GO(xmlReaderForDoc,
//GO(xmlReaderForFd,
//GO(xmlReaderForFile,
-//GO(xmlReaderForIO,
-//GO(xmlReaderForMemory,
+GOM(xmlReaderForIO, pFEpppppi)
+GO(xmlReaderForMemory, pFpippi)
//GO(xmlReaderNewDoc,
//GO(xmlReaderNewFd,
//GO(xmlReaderNewFile,
@@ -811,7 +811,7 @@ GO(xmlRegisterHTTPPostCallbacks, vFv)
GOM(xmlRegisterInputCallbacks, iFEpppp)
//GOM(xmlRegisterNodeDefault, BFEB)
//GO(__xmlRegisterNodeDefaultValue,
-//GOM(xmlRegisterOutputCallbacks, iFEBBBB)
+GOM(xmlRegisterOutputCallbacks, iFEpppp)
//GO(xmlRegNewExecCtxt,
//GO(xmlRelaxNGCleanupTypes,
//GO(xmlRelaxNGDump,
@@ -851,8 +851,8 @@ GO(xmlSaveFile, iFpp)
GO(xmlSaveFileEnc, iFppp)
GO(xmlSaveFileTo, iFppp)
GO(xmlSaveFlush, iFp)
-//GO(xmlSaveFormatFile,
-//GO(xmlSaveFormatFileEnc,
+GO(xmlSaveFormatFile, iFppi)
+GO(xmlSaveFormatFileEnc, iFpppi)
//GO(xmlSaveFormatFileTo,
//GO(__xmlSaveNoEmptyTags,
//GOM(xmlSaveSetAttrEscape, iFEpB)
@@ -988,12 +988,12 @@ GO(xmlSetCompressMode, vFi)
GO(xmlSetDocCompressMode, vFpi)
GOM(xmlSetExternalEntityLoader, vFEp)
GO(xmlSetFeature, iFppp)
-//GO(xmlSetGenericErrorFunc,
+GOM(xmlSetGenericErrorFunc, vFEpp)
GO(xmlSetListDoc, vFpp)
GO(xmlSetNs, vFpp)
GO(xmlSetNsProp, pFpppp)
GO(xmlSetProp, pFppp)
-//GO(xmlSetStructuredErrorFunc,
+GOM(xmlSetStructuredErrorFunc, vFEpp)
GO(xmlSetTreeDoc, vFpp)
GO(xmlSetupParserForBuffer, vFppp)
//GO(__xmlSimpleError,
@@ -1031,7 +1031,7 @@ GO2(xmlStrPrintf, iFpipV, xmlStrVPrintf)
GO(xmlStrQEqual, iFppp)
GO(xmlStrstr, pFpp)
GO(xmlStrsub, pFpii)
-//GO(__xmlStructuredError,
+GOM(__xmlStructuredError, pFEv)
//GO(__xmlStructuredErrorContext,
GO(xmlStrVPrintf, iFpipp)
GO(xmlSubstituteEntitiesDefault, iFi)
@@ -1047,19 +1047,19 @@ GO(xmlTextMerge, pFpp)
//GO(xmlTextReaderClose,
//GO(xmlTextReaderConstBaseUri,
//GO(xmlTextReaderConstEncoding,
-//GO(xmlTextReaderConstLocalName,
-//GO(xmlTextReaderConstName,
+GO(xmlTextReaderConstLocalName, pFp)
+GO(xmlTextReaderConstName, pFp)
//GO(xmlTextReaderConstNamespaceUri,
//GO(xmlTextReaderConstPrefix,
//GO(xmlTextReaderConstString,
-//GO(xmlTextReaderConstValue,
+GO(xmlTextReaderConstValue, pFp)
//GO(xmlTextReaderConstXmlLang,
//GO(xmlTextReaderConstXmlVersion,
//GO(xmlTextReaderCurrentDoc,
//GO(xmlTextReaderCurrentNode,
//GO(xmlTextReaderDepth,
//GO(xmlTextReaderExpand,
-//GO(xmlTextReaderGetAttribute,
+GO(xmlTextReaderGetAttribute, pFpp)
//GO(xmlTextReaderGetAttributeNo,
//GO(xmlTextReaderGetAttributeNs,
//GO(xmlTextReaderGetErrorHandler,
@@ -1067,33 +1067,33 @@ GO(xmlTextMerge, pFpp)
//GO(xmlTextReaderGetParserLineNumber,
//GO(xmlTextReaderGetParserProp,
//GO(xmlTextReaderGetRemainder,
-//GO(xmlTextReaderHasAttributes,
+GO(xmlTextReaderHasAttributes, iFp)
//GO(xmlTextReaderHasValue,
//GO(xmlTextReaderIsDefault,
-//GO(xmlTextReaderIsEmptyElement,
-//GO(xmlTextReaderIsNamespaceDecl,
+GO(xmlTextReaderIsEmptyElement, iFp)
+GO(xmlTextReaderIsNamespaceDecl, iFp)
//GO(xmlTextReaderIsValid,
//GO(xmlTextReaderLocalName,
//GO(xmlTextReaderLocatorBaseURI,
//GO(xmlTextReaderLocatorLineNumber,
-//GO(xmlTextReaderLookupNamespace,
+GO(xmlTextReaderLookupNamespace, pFpp)
//GO(xmlTextReaderMoveToAttribute,
//GO(xmlTextReaderMoveToAttributeNo,
//GO(xmlTextReaderMoveToAttributeNs,
-//GO(xmlTextReaderMoveToElement,
-//GO(xmlTextReaderMoveToFirstAttribute,
-//GO(xmlTextReaderMoveToNextAttribute,
+GO(xmlTextReaderMoveToElement, iFp)
+GO(xmlTextReaderMoveToFirstAttribute, iFp)
+GO(xmlTextReaderMoveToNextAttribute, iFp)
//GO(xmlTextReaderName,
//GO(xmlTextReaderNamespaceUri,
//GO(xmlTextReaderNext,
//GO(xmlTextReaderNextSibling,
-//GO(xmlTextReaderNodeType,
+GO(xmlTextReaderNodeType, iFp)
//GO(xmlTextReaderNormalization,
//GO(xmlTextReaderPrefix,
//GO(xmlTextReaderPreserve,
//GO(xmlTextReaderPreservePattern,
//GO(xmlTextReaderQuoteChar,
-//GO(xmlTextReaderRead,
+GO(xmlTextReaderRead, iFp)
//GO(xmlTextReaderReadAttributeValue,
//GO(xmlTextReaderReadInnerXml,
//GO(xmlTextReaderReadOuterXml,
@@ -1103,7 +1103,7 @@ GO(xmlTextMerge, pFpp)
//GO(xmlTextReaderRelaxNGValidate,
//GO(xmlTextReaderSchemaValidate,
//GO(xmlTextReaderSchemaValidateCtxt,
-//GO(xmlTextReaderSetErrorHandler,
+GOM(xmlTextReaderSetErrorHandler, vFEppp)
//GO(xmlTextReaderSetParserProp,
//GO(xmlTextReaderSetSchema,
//GO(xmlTextReaderSetStructuredErrorHandler,
@@ -1114,32 +1114,32 @@ GO(xmlTextMerge, pFpp)
//GO(xmlTextWriterEndAttribute,
//GO(xmlTextWriterEndCDATA,
//GO(xmlTextWriterEndComment,
-//GO(xmlTextWriterEndDocument,
+GO(xmlTextWriterEndDocument, iFp)
//GO(xmlTextWriterEndDTD,
//GO(xmlTextWriterEndDTDAttlist,
//GO(xmlTextWriterEndDTDElement,
//GO(xmlTextWriterEndDTDEntity,
-//GO(xmlTextWriterEndElement,
+GO(xmlTextWriterEndElement, iFp)
//GO(xmlTextWriterEndPI,
//GO(xmlTextWriterFlush,
//GO(xmlTextWriterFullEndElement,
-//GO(xmlTextWriterSetIndent,
+GO(xmlTextWriterSetIndent, iFpi)
//GO(xmlTextWriterSetIndentString,
//GO(xmlTextWriterStartAttribute,
//GO(xmlTextWriterStartAttributeNS,
//GO(xmlTextWriterStartCDATA,
//GO(xmlTextWriterStartComment,
-//GO(xmlTextWriterStartDocument,
+GO(xmlTextWriterStartDocument, iFpppp)
//GO(xmlTextWriterStartDTD,
//GO(xmlTextWriterStartDTDAttlist,
//GO(xmlTextWriterStartDTDElement,
//GO(xmlTextWriterStartDTDEntity,
-//GO(xmlTextWriterStartElement,
+GO(xmlTextWriterStartElement, iFpp)
//GO(xmlTextWriterStartElementNS,
//GO(xmlTextWriterStartPI,
-//GO(xmlTextWriterWriteAttribute,
+GO(xmlTextWriterWriteAttribute, iFppp)
//GO(xmlTextWriterWriteAttributeNS,
-//GO(xmlTextWriterWriteBase64,
+GO(xmlTextWriterWriteBase64, iFppii)
//GO(xmlTextWriterWriteBinHex,
//GO(xmlTextWriterWriteCDATA,
//GO(xmlTextWriterWriteComment,
@@ -1153,7 +1153,7 @@ GO(xmlTextMerge, pFpp)
//GO(xmlTextWriterWriteDTDNotation,
//GO(xmlTextWriterWriteElement,
//GO(xmlTextWriterWriteElementNS,
-//GO(xmlTextWriterWriteFormatAttribute,
+GOM(xmlTextWriterWriteFormatAttribute, iFEpppV)
//GO(xmlTextWriterWriteFormatAttributeNS,
//GO(xmlTextWriterWriteFormatCDATA,
//GO(xmlTextWriterWriteFormatComment,
@@ -1169,8 +1169,8 @@ GO(xmlTextMerge, pFpp)
//GO(xmlTextWriterWritePI,
//GO(xmlTextWriterWriteRaw,
//GO(xmlTextWriterWriteRawLen,
-//GO(xmlTextWriterWriteString,
-//GO(xmlTextWriterWriteVFormatAttribute,
+GO(xmlTextWriterWriteString, iFpp)
+GOM(xmlTextWriterWriteVFormatAttribute, iFEpppA)
//GO(xmlTextWriterWriteVFormatAttributeNS,
//GO(xmlTextWriterWriteVFormatCDATA,
//GO(xmlTextWriterWriteVFormatComment,
diff --git a/src/wrapped/wrappedxslt.c b/src/wrapped/wrappedxslt.c
index 41e6863..ad145b2 100755..100644
--- a/src/wrapped/wrappedxslt.c
+++ b/src/wrapped/wrappedxslt.c
@@ -40,10 +40,10 @@ GO(4)
// xmlXPathFunction ...
#define GO(A) \
-static uintptr_t my_xmlXPathFunction_fct_##A = 0; \
-static void my_xmlXPathFunction_##A(void* a, int b) \
-{ \
- RunFunction(my_context, my_xmlXPathFunction_fct_##A, 2, a, b); \
+static uintptr_t my_xmlXPathFunction_fct_##A = 0; \
+static void my_xmlXPathFunction_##A(void* a, int b) \
+{ \
+ RunFunctionFmt(my_xmlXPathFunction_fct_##A, "pi", a, b); \
}
SUPER()
#undef GO
@@ -62,10 +62,10 @@ static void* find_xmlXPathFunction_Fct(void* fct)
}
// xsltDocLoaderFunc ...
#define GO(A) \
-static uintptr_t my_xsltDocLoaderFunc_fct_##A = 0; \
-static void* my_xsltDocLoaderFunc_##A(void* a, void* b, int c, void* d, int e) \
-{ \
- return (void*)RunFunction(my_context, my_xsltDocLoaderFunc_fct_##A, 5, a, b, c, d, e); \
+static uintptr_t my_xsltDocLoaderFunc_fct_##A = 0; \
+static void* my_xsltDocLoaderFunc_##A(void* a, void* b, int c, void* d, int e) \
+{ \
+ return (void*)RunFunctionFmt(my_xsltDocLoaderFunc_fct_##A, "ppipi", a, b, c, d, e); \
}
SUPER()
#undef GO
@@ -82,7 +82,50 @@ static void* find_xsltDocLoaderFunc_Fct(void* fct)
printf_log(LOG_NONE, "Warning, no more slot for libxslt xsltDocLoaderFunc callback\n");
return NULL;
}
-
+// xsltSecurityCheck ...
+#define GO(A) \
+static uintptr_t my_xsltSecurityCheck_fct_##A = 0; \
+static int my_xsltSecurityCheck_##A(void* a, void* b, void* c) \
+{ \
+ return (int)RunFunctionFmt(my_xsltSecurityCheck_fct_##A, "ppp", a, b, c); \
+}
+SUPER()
+#undef GO
+static void* find_xsltSecurityCheck_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_xsltSecurityCheck_fct_##A == (uintptr_t)fct) return my_xsltSecurityCheck_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_xsltSecurityCheck_fct_##A == 0) {my_xsltSecurityCheck_fct_##A = (uintptr_t)fct; return my_xsltSecurityCheck_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libxslt xsltSecurityCheck callback\n");
+ return NULL;
+}
+// xsltSortFunc ...
+#define GO(A) \
+static uintptr_t my_xsltSortFunc_fct_##A = 0; \
+static void my_xsltSortFunc_##A(void* a, void* b, int c) \
+{ \
+ RunFunctionFmt(my_xsltSortFunc_fct_##A, "ppi", a, b, c); \
+}
+SUPER()
+#undef GO
+static void* find_xsltSortFunc_Fct(void* fct)
+{
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_xsltSortFunc_fct_##A == (uintptr_t)fct) return my_xsltSortFunc_##A;
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_xsltSortFunc_fct_##A == 0) {my_xsltSortFunc_fct_##A = (uintptr_t)fct; return my_xsltSortFunc_##A; }
+ SUPER()
+ #undef GO
+ printf_log(LOG_NONE, "Warning, no more slot for libxslt xsltSortFunc callback\n");
+ return NULL;
+}
#undef SUPER
EXPORT int my_xsltRegisterExtModuleFunction(x64emu_t* emu, void* name, void* URI, void* f)
@@ -95,6 +138,21 @@ EXPORT void my_xsltSetLoaderFunc(x64emu_t* emu, void* f)
my->xsltSetLoaderFunc(find_xsltDocLoaderFunc_Fct(f));
}
+EXPORT int my_xsltRegisterExtFunction(x64emu_t* emu, void* ctx, void* name, void* uri, void* f)
+{
+ return my->xsltRegisterExtFunction(ctx, name, uri, find_xmlXPathFunction_Fct(f));
+}
+
+EXPORT int my_xsltSetSecurityPrefs(x64emu_t* emu, void* sec, void* option, void* f)
+{
+ return my->xsltSetSecurityPrefs(sec, option, find_xsltSecurityCheck_Fct(f));
+}
+
+EXPORT void my_xsltSetCtxtSortFunc(x64emu_t* emu, void* ctx, void* handler)
+{
+ return my->xsltSetCtxtSortFunc(ctx, find_xsltSortFunc_Fct(handler));
+}
+
#define CUSTOM_INIT \
getMy(lib);
diff --git a/src/wrapped/wrappedxslt_private.h b/src/wrapped/wrappedxslt_private.h
index f769d94..24c3db7 100755..100644
--- a/src/wrapped/wrappedxslt_private.h
+++ b/src/wrapped/wrappedxslt_private.h
@@ -56,7 +56,7 @@ GO(xsltDocumentSortFunction, vFp)
GO(xsltDoSortFunction, vFppi)
GO(xsltElement, vFpppp)
//GO(xsltElementAvailableFunction,
-//GO(xsltEvalAttrValueTemplate,
+GO(xsltEvalAttrValueTemplate, pFpppp)
GO(xsltEvalAVT, pFppp)
GO(xsltEvalGlobalVariables, iFp)
GO(xsltEvalOneUserParam, iFppp)
@@ -180,7 +180,7 @@ GO(xsltRegisterAllElement, vFp)
GO(xsltRegisterAllExtras, vFv)
//GO(xsltRegisterAllFunctions,
//GOM(xsltRegisterExtElement, iFEpppB)
-//GOM(xsltRegisterExtFunction, iFEpppB)
+GOM(xsltRegisterExtFunction, iFEpppp)
//GOM(xsltRegisterExtModule, iFEpBB)
//GOM(xsltRegisterExtModuleElement, iFEppBB)
//GOM(xsltRegisterExtModuleFull, iFEpBBBB)
@@ -207,14 +207,14 @@ GO(xsltSecurityAllow, iFppp)
GO(xsltSecurityForbid, iFppp)
GO(xsltSetCtxtParseOptions, iFpi)
GO(xsltSetCtxtSecurityPrefs, iFpp)
-//GOM(xsltSetCtxtSortFunc, vFEpB)
+GOM(xsltSetCtxtSortFunc, vFEpp)
//GOM(xsltSetDebuggerCallbacks, iFip)
GO(xsltSetDebuggerStatus, vFi)
GO(xsltSetDefaultSecurityPrefs, vFp)
//GOM(xsltSetGenericDebugFunc, vFEpB)
//GOM(xsltSetGenericErrorFunc, vFEpB)
GOM(xsltSetLoaderFunc, vFEp)
-//GOM(xsltSetSecurityPrefs, iFEppB)
+GOM(xsltSetSecurityPrefs, iFEppp)
//GOM(xsltSetSortFunc, vFEp)
//GO(MxsltSetTransformErrorFunc, vFEppB)
GO(xsltSetXIncludeDefault, vFi)
diff --git a/system/box64.box64rc b/system/box64.box64rc
index 746665f..ae2dfba 100644
--- a/system/box64.box64rc
+++ b/system/box64.box64rc
@@ -7,7 +7,6 @@
#
[3dSen.x86_64]
BOX64_DYNAREC_BLEEDING_EDGE=0 # avoid the use of STRONGMEM for much better performances
-BOX64_DYNAREC_HOTPAGE=0 # disabling hotpage seems to give better performances here
[7z]
# Those are safe to use on 7z and give a bit of a boost
@@ -26,12 +25,6 @@ BOX64_DYNAREC_CALLRET=1
[chrome]
BOX64_MALLOC_HACK=2
-[dav1d]
-# Speed hacks (those 3 gives ~10% speedup)
-BOX64_DYNAREC_SAFEFLAGS=0
-BOX64_DYNAREC_BIGBLOCK=2
-BOX64_DYNAREC_CALLRET=1
-
[deadcells]
BOX64_PREFER_EMULATED=1
@@ -51,6 +44,7 @@ BOX64_DYNAREC_SAFEFLAGS=0
BOX64_DYNAREC_BIGBLOCK=2
BOX64_DYNAREC_FORWARD=1024
BOX64_DYNAREC_CALLRET=1
+BOX64_DYNAREC_FASTROUND=0
[heroic]
BOX64_NOSANDBOX=1
@@ -58,6 +52,9 @@ BOX64_MALLOC_HACK=2
# this is to save some memory
BOX64_DYNAREC_BIGBLOCK=0
+[LotCG.x86_64]
+BOX64_DYNAREC_FASTROUND=0
+
[nacl_helper]
BOX64_MALLOC_HACK=1
@@ -66,11 +63,21 @@ BOX64_EMULATED_LIBS=libopenal.so.1
BOX64_DYNAREC_SAFEFLAGS=0
BOX64_DYNAREC_BIGBLOCK=3
BOX64_DYNAREC_FORWARD=1024
-BOX64_DYNAREC_CALLRET=1
+#BOX64_DYNAREC_CALLRET=1 #New jmpbuf handling tend to break this optim!
[pressure-vessel-wrap]
BOX64_NOGTK=1
+[ProjectZomboid64]
+# This one is still a bit unstable. This might help, but will also slowdown emulation
+BOX64_DYNAREC_STRONGMEM=2
+BOX64_DYNAREC_SAFEFLAGS=2
+BOX64_DYNAREC_JVM=0
+
+[Soma.bin.x86_64]
+# This is needed or the physics engine will not behave correctly
+BOX64_DYNAREC_FASTROUND=0
+
[steam]
BOX64_CRASHHANDLER=1
BOX64_EMULATED_LIBS=libudev.so.0
@@ -90,6 +97,9 @@ BOX64_DYNAREC_BIGBLOCK=0
[steam-runtime-check-requirements]
BOX64_EXIT=1
+[steam-runtime-launcher-service]
+BOX64_NOGTK=1
+
[Torchlight2.bin.x86_64]
# Those are safe to use on 7z and give a bit of a boost
BOX64_DYNAREC_SAFEFLAGS=0
@@ -97,6 +107,10 @@ BOX64_DYNAREC_BIGBLOCK=2
BOX64_DYNAREC_FORWARD=512
BOX64_DYNAREC_CALLRET=1
+[weixin]
+BOX64_MALLOC_HACK=2
+BOX64_NOSANDBOX=1
+
#
# Wine process
#
diff --git a/system/box64.conf.cmake b/system/box64.conf.cmake
index 7dbdc5d..7dbdc5d 100755..100644
--- a/system/box64.conf.cmake
+++ b/system/box64.conf.cmake
diff --git a/tests/benchfloat.c b/tests/benchfloat.c
index 93b8207..93b8207 100755..100644
--- a/tests/benchfloat.c
+++ b/tests/benchfloat.c
diff --git a/tests/ref17.txt b/tests/ref17.txt
index 97e5ea8..865dabc 100644
--- a/tests/ref17.txt
+++ b/tests/ref17.txt
@@ -489,9 +489,9 @@ mulsd(0 -2 , -0 0x7ff8000000000000 ) = -0 -2
subsd(1 2 , 1 2 ) = 0 2
subsd(1 2 , 0 -2 ) = 1 2
subsd(1 2 , inf -inf ) = -inf 2
-subsd(1 2 , 0x7ff8000000000000 -0 ) = 0xfff8000000000000 2
-subsd(0 -2 , 0x7ff8000000000000 -0 ) = 0xfff8000000000000 -2
-subsd(inf -inf , 0x7ff8000000000000 -0 ) = 0xfff8000000000000 -inf
+subsd(1 2 , 0x7ff8000000000000 -0 ) = 0x7ff8000000000000 2
+subsd(0 -2 , 0x7ff8000000000000 -0 ) = 0x7ff8000000000000 -2
+subsd(inf -inf , 0x7ff8000000000000 -0 ) = 0x7ff8000000000000 -inf
subsd(1 2 , 2 1 ) = -1 2
subsd(1 2 , -2 0 ) = 3 2
subsd(1 2 , -inf inf ) = inf 2
@@ -532,5 +532,9 @@ maxsd(1 2 , 2 1 ) = 2 2
maxsd(1 2 , -2 0 ) = 1 2
maxsd(1 2 , -inf inf ) = 1 2
maxsd(1 2 , -0 0x7ff8000000000000 ) = 1 2
-maxsd(0 -2 , -0 0x7ff8000000000000 ) = 0 -2
-maxsd(0 -2 , -0 0x7ff8000000000000 ) = 0 -2
+maxsd(0 -2 , -0 0x7ff8000000000000 ) = -0 -2
+maxsd(0 -2 , -0 0x7ff8000000000000 ) = -0 -2
+cvtps2pd(1 2 3 -4 ) = 0x1 0x2 0x3 0xfffffffc
+cvtps2pd(0 -2 -10 0.5 ) = 0x0 0xfffffffe 0xfffffff6 0x0
+cvtps2pd(inf -inf -inf 1 ) = 0x80000000 0x80000000 0x80000000 0x1
+cvtps2pd(nan -0 nan inf ) = 0x80000000 0x0 0x80000000 0x80000000
diff --git a/tests/ref22.txt b/tests/ref22.txt
index 0b90c20..9538e7a 100644
--- a/tests/ref22.txt
+++ b/tests/ref22.txt
@@ -1,222 +1,1224 @@
FUCOMI 0x0 0x4082c00000000000 --C
FUCOMPP 0x0 0x4082c00000000000 --C
-FRNDINT 0x0 => 0x0
-FRNDINT 0x4082c00000000000 => 0x4082c00000000000
-FISTP 0x0 => word: 0
-FISTP 0x4082c00000000000 => word: 258
-FISTP 0x0 => long: 0
-FISTP 0x4082c00000000000 => long: 258
-FISTP 0x0 => quad: 0
-FISTP 0x4082c00000000000 => quad: 258
+Rounding 0
+ FRNDINT 0x0 => 0x0
+ FRNDINT 0x4082c00000000000 => 0x4082c00000000000
+ FISTP 0x0 => word: 0
+ FISTP 0x4082c00000000000 => word: 258
+ FISTP 0x0 => long: 0
+ FISTP 0x4082c00000000000 => long: 258
+ FISTP 0x0 => quad: 0
+ FISTP 0x4082c00000000000 => quad: 258
+ FISTTP 0x0 => word: 0
+ FISTTP 0x4082c00000000000 => word: 258
+ FISTTP 0x0 => long: 0
+ FISTTP 0x4082c00000000000 => long: 258
+ FISTTP 0x0 => quad: 0
+ FISTTP 0x4082c00000000000 => quad: 258
+Rounding 1
+ FRNDINT 0x0 => 0x0
+ FRNDINT 0x4082c00000000000 => 0x4082c00000000000
+ FISTP 0x0 => word: 0
+ FISTP 0x4082c00000000000 => word: 258
+ FISTP 0x0 => long: 0
+ FISTP 0x4082c00000000000 => long: 258
+ FISTP 0x0 => quad: 0
+ FISTP 0x4082c00000000000 => quad: 258
+ FISTTP 0x0 => word: 0
+ FISTTP 0x4082c00000000000 => word: 258
+ FISTTP 0x0 => long: 0
+ FISTTP 0x4082c00000000000 => long: 258
+ FISTTP 0x0 => quad: 0
+ FISTTP 0x4082c00000000000 => quad: 258
+Rounding 2
+ FRNDINT 0x0 => 0x0
+ FRNDINT 0x4082c00000000000 => 0x4082c00000000000
+ FISTP 0x0 => word: 0
+ FISTP 0x4082c00000000000 => word: 258
+ FISTP 0x0 => long: 0
+ FISTP 0x4082c00000000000 => long: 258
+ FISTP 0x0 => quad: 0
+ FISTP 0x4082c00000000000 => quad: 258
+ FISTTP 0x0 => word: 0
+ FISTTP 0x4082c00000000000 => word: 258
+ FISTTP 0x0 => long: 0
+ FISTTP 0x4082c00000000000 => long: 258
+ FISTTP 0x0 => quad: 0
+ FISTTP 0x4082c00000000000 => quad: 258
FUCOMI 0x4082c00000000000 0x0 ---
FUCOMPP 0x4082c00000000000 0x0 ---
-FRNDINT 0x4082c00000000000 => 0x4082c00000000000
-FRNDINT 0x0 => 0x0
-FISTP 0x4082c00000000000 => word: 258
-FISTP 0x0 => word: 0
-FISTP 0x4082c00000000000 => long: 258
-FISTP 0x0 => long: 0
-FISTP 0x4082c00000000000 => quad: 258
-FISTP 0x0 => quad: 0
+Rounding 0
+ FRNDINT 0x4082c00000000000 => 0x4082c00000000000
+ FRNDINT 0x0 => 0x0
+ FISTP 0x4082c00000000000 => word: 258
+ FISTP 0x0 => word: 0
+ FISTP 0x4082c00000000000 => long: 258
+ FISTP 0x0 => long: 0
+ FISTP 0x4082c00000000000 => quad: 258
+ FISTP 0x0 => quad: 0
+ FISTTP 0x4082c00000000000 => word: 258
+ FISTTP 0x0 => word: 0
+ FISTTP 0x4082c00000000000 => long: 258
+ FISTTP 0x0 => long: 0
+ FISTTP 0x4082c00000000000 => quad: 258
+ FISTTP 0x0 => quad: 0
+Rounding 1
+ FRNDINT 0x4082c00000000000 => 0x4082c00000000000
+ FRNDINT 0x0 => 0x0
+ FISTP 0x4082c00000000000 => word: 258
+ FISTP 0x0 => word: 0
+ FISTP 0x4082c00000000000 => long: 258
+ FISTP 0x0 => long: 0
+ FISTP 0x4082c00000000000 => quad: 258
+ FISTP 0x0 => quad: 0
+ FISTTP 0x4082c00000000000 => word: 258
+ FISTTP 0x0 => word: 0
+ FISTTP 0x4082c00000000000 => long: 258
+ FISTTP 0x0 => long: 0
+ FISTTP 0x4082c00000000000 => quad: 258
+ FISTTP 0x0 => quad: 0
+Rounding 2
+ FRNDINT 0x4082c00000000000 => 0x4082c00000000000
+ FRNDINT 0x0 => 0x0
+ FISTP 0x4082c00000000000 => word: 258
+ FISTP 0x0 => word: 0
+ FISTP 0x4082c00000000000 => long: 258
+ FISTP 0x0 => long: 0
+ FISTP 0x4082c00000000000 => quad: 258
+ FISTP 0x0 => quad: 0
+ FISTTP 0x4082c00000000000 => word: 258
+ FISTTP 0x0 => word: 0
+ FISTTP 0x4082c00000000000 => long: 258
+ FISTTP 0x0 => long: 0
+ FISTTP 0x4082c00000000000 => quad: 258
+ FISTTP 0x0 => quad: 0
FUCOMI 0x8000000000000000 0x4082c00000000000 --C
FUCOMPP 0x8000000000000000 0x4082c00000000000 --C
-FRNDINT 0x8000000000000000 => 0x8000000000000000
-FRNDINT 0x4082c00000000000 => 0x4082c00000000000
-FISTP 0x8000000000000000 => word: 0
-FISTP 0x4082c00000000000 => word: 258
-FISTP 0x8000000000000000 => long: 0
-FISTP 0x4082c00000000000 => long: 258
-FISTP 0x8000000000000000 => quad: 0
-FISTP 0x4082c00000000000 => quad: 258
+Rounding 0
+ FRNDINT 0x8000000000000000 => 0x8000000000000000
+ FRNDINT 0x4082c00000000000 => 0x4082c00000000000
+ FISTP 0x8000000000000000 => word: 0
+ FISTP 0x4082c00000000000 => word: 258
+ FISTP 0x8000000000000000 => long: 0
+ FISTP 0x4082c00000000000 => long: 258
+ FISTP 0x8000000000000000 => quad: 0
+ FISTP 0x4082c00000000000 => quad: 258
+ FISTTP 0x8000000000000000 => word: 0
+ FISTTP 0x4082c00000000000 => word: 258
+ FISTTP 0x8000000000000000 => long: 0
+ FISTTP 0x4082c00000000000 => long: 258
+ FISTTP 0x8000000000000000 => quad: 0
+ FISTTP 0x4082c00000000000 => quad: 258
+Rounding 1
+ FRNDINT 0x8000000000000000 => 0x8000000000000000
+ FRNDINT 0x4082c00000000000 => 0x4082c00000000000
+ FISTP 0x8000000000000000 => word: 0
+ FISTP 0x4082c00000000000 => word: 258
+ FISTP 0x8000000000000000 => long: 0
+ FISTP 0x4082c00000000000 => long: 258
+ FISTP 0x8000000000000000 => quad: 0
+ FISTP 0x4082c00000000000 => quad: 258
+ FISTTP 0x8000000000000000 => word: 0
+ FISTTP 0x4082c00000000000 => word: 258
+ FISTTP 0x8000000000000000 => long: 0
+ FISTTP 0x4082c00000000000 => long: 258
+ FISTTP 0x8000000000000000 => quad: 0
+ FISTTP 0x4082c00000000000 => quad: 258
+Rounding 2
+ FRNDINT 0x8000000000000000 => 0x8000000000000000
+ FRNDINT 0x4082c00000000000 => 0x4082c00000000000
+ FISTP 0x8000000000000000 => word: 0
+ FISTP 0x4082c00000000000 => word: 258
+ FISTP 0x8000000000000000 => long: 0
+ FISTP 0x4082c00000000000 => long: 258
+ FISTP 0x8000000000000000 => quad: 0
+ FISTP 0x4082c00000000000 => quad: 258
+ FISTTP 0x8000000000000000 => word: 0
+ FISTTP 0x4082c00000000000 => word: 258
+ FISTTP 0x8000000000000000 => long: 0
+ FISTTP 0x4082c00000000000 => long: 258
+ FISTTP 0x8000000000000000 => quad: 0
+ FISTTP 0x4082c00000000000 => quad: 258
FUCOMI 0x4082c00000000000 0x8000000000000000 ---
FUCOMPP 0x4082c00000000000 0x8000000000000000 ---
-FRNDINT 0x4082c00000000000 => 0x4082c00000000000
-FRNDINT 0x8000000000000000 => 0x8000000000000000
-FISTP 0x4082c00000000000 => word: 258
-FISTP 0x8000000000000000 => word: 0
-FISTP 0x4082c00000000000 => long: 258
-FISTP 0x8000000000000000 => long: 0
-FISTP 0x4082c00000000000 => quad: 258
-FISTP 0x8000000000000000 => quad: 0
+Rounding 0
+ FRNDINT 0x4082c00000000000 => 0x4082c00000000000
+ FRNDINT 0x8000000000000000 => 0x8000000000000000
+ FISTP 0x4082c00000000000 => word: 258
+ FISTP 0x8000000000000000 => word: 0
+ FISTP 0x4082c00000000000 => long: 258
+ FISTP 0x8000000000000000 => long: 0
+ FISTP 0x4082c00000000000 => quad: 258
+ FISTP 0x8000000000000000 => quad: 0
+ FISTTP 0x4082c00000000000 => word: 258
+ FISTTP 0x8000000000000000 => word: 0
+ FISTTP 0x4082c00000000000 => long: 258
+ FISTTP 0x8000000000000000 => long: 0
+ FISTTP 0x4082c00000000000 => quad: 258
+ FISTTP 0x8000000000000000 => quad: 0
+Rounding 1
+ FRNDINT 0x4082c00000000000 => 0x4082c00000000000
+ FRNDINT 0x8000000000000000 => 0x8000000000000000
+ FISTP 0x4082c00000000000 => word: 258
+ FISTP 0x8000000000000000 => word: 0
+ FISTP 0x4082c00000000000 => long: 258
+ FISTP 0x8000000000000000 => long: 0
+ FISTP 0x4082c00000000000 => quad: 258
+ FISTP 0x8000000000000000 => quad: 0
+ FISTTP 0x4082c00000000000 => word: 258
+ FISTTP 0x8000000000000000 => word: 0
+ FISTTP 0x4082c00000000000 => long: 258
+ FISTTP 0x8000000000000000 => long: 0
+ FISTTP 0x4082c00000000000 => quad: 258
+ FISTTP 0x8000000000000000 => quad: 0
+Rounding 2
+ FRNDINT 0x4082c00000000000 => 0x4082c00000000000
+ FRNDINT 0x8000000000000000 => 0x8000000000000000
+ FISTP 0x4082c00000000000 => word: 258
+ FISTP 0x8000000000000000 => word: 0
+ FISTP 0x4082c00000000000 => long: 258
+ FISTP 0x8000000000000000 => long: 0
+ FISTP 0x4082c00000000000 => quad: 258
+ FISTP 0x8000000000000000 => quad: 0
+ FISTTP 0x4082c00000000000 => word: 258
+ FISTTP 0x8000000000000000 => word: 0
+ FISTTP 0x4082c00000000000 => long: 258
+ FISTTP 0x8000000000000000 => long: 0
+ FISTTP 0x4082c00000000000 => quad: 258
+ FISTTP 0x8000000000000000 => quad: 0
FUCOMI 0x8000000000000000 0x0 Z--
FUCOMPP 0x8000000000000000 0x0 Z--
-FRNDINT 0x8000000000000000 => 0x8000000000000000
-FRNDINT 0x0 => 0x0
-FISTP 0x8000000000000000 => word: 0
-FISTP 0x0 => word: 0
-FISTP 0x8000000000000000 => long: 0
-FISTP 0x0 => long: 0
-FISTP 0x8000000000000000 => quad: 0
-FISTP 0x0 => quad: 0
+Rounding 0
+ FRNDINT 0x8000000000000000 => 0x8000000000000000
+ FRNDINT 0x0 => 0x0
+ FISTP 0x8000000000000000 => word: 0
+ FISTP 0x0 => word: 0
+ FISTP 0x8000000000000000 => long: 0
+ FISTP 0x0 => long: 0
+ FISTP 0x8000000000000000 => quad: 0
+ FISTP 0x0 => quad: 0
+ FISTTP 0x8000000000000000 => word: 0
+ FISTTP 0x0 => word: 0
+ FISTTP 0x8000000000000000 => long: 0
+ FISTTP 0x0 => long: 0
+ FISTTP 0x8000000000000000 => quad: 0
+ FISTTP 0x0 => quad: 0
+Rounding 1
+ FRNDINT 0x8000000000000000 => 0x8000000000000000
+ FRNDINT 0x0 => 0x0
+ FISTP 0x8000000000000000 => word: 0
+ FISTP 0x0 => word: 0
+ FISTP 0x8000000000000000 => long: 0
+ FISTP 0x0 => long: 0
+ FISTP 0x8000000000000000 => quad: 0
+ FISTP 0x0 => quad: 0
+ FISTTP 0x8000000000000000 => word: 0
+ FISTTP 0x0 => word: 0
+ FISTTP 0x8000000000000000 => long: 0
+ FISTTP 0x0 => long: 0
+ FISTTP 0x8000000000000000 => quad: 0
+ FISTTP 0x0 => quad: 0
+Rounding 2
+ FRNDINT 0x8000000000000000 => 0x8000000000000000
+ FRNDINT 0x0 => 0x0
+ FISTP 0x8000000000000000 => word: 0
+ FISTP 0x0 => word: 0
+ FISTP 0x8000000000000000 => long: 0
+ FISTP 0x0 => long: 0
+ FISTP 0x8000000000000000 => quad: 0
+ FISTP 0x0 => quad: 0
+ FISTTP 0x8000000000000000 => word: 0
+ FISTTP 0x0 => word: 0
+ FISTTP 0x8000000000000000 => long: 0
+ FISTTP 0x0 => long: 0
+ FISTTP 0x8000000000000000 => quad: 0
+ FISTTP 0x0 => quad: 0
FUCOMI 0x0 0x8000000000000000 Z--
FUCOMPP 0x0 0x8000000000000000 Z--
-FRNDINT 0x0 => 0x0
-FRNDINT 0x8000000000000000 => 0x8000000000000000
-FISTP 0x0 => word: 0
-FISTP 0x8000000000000000 => word: 0
-FISTP 0x0 => long: 0
-FISTP 0x8000000000000000 => long: 0
-FISTP 0x0 => quad: 0
-FISTP 0x8000000000000000 => quad: 0
+Rounding 0
+ FRNDINT 0x0 => 0x0
+ FRNDINT 0x8000000000000000 => 0x8000000000000000
+ FISTP 0x0 => word: 0
+ FISTP 0x8000000000000000 => word: 0
+ FISTP 0x0 => long: 0
+ FISTP 0x8000000000000000 => long: 0
+ FISTP 0x0 => quad: 0
+ FISTP 0x8000000000000000 => quad: 0
+ FISTTP 0x0 => word: 0
+ FISTTP 0x8000000000000000 => word: 0
+ FISTTP 0x0 => long: 0
+ FISTTP 0x8000000000000000 => long: 0
+ FISTTP 0x0 => quad: 0
+ FISTTP 0x8000000000000000 => quad: 0
+Rounding 1
+ FRNDINT 0x0 => 0x0
+ FRNDINT 0x8000000000000000 => 0x8000000000000000
+ FISTP 0x0 => word: 0
+ FISTP 0x8000000000000000 => word: 0
+ FISTP 0x0 => long: 0
+ FISTP 0x8000000000000000 => long: 0
+ FISTP 0x0 => quad: 0
+ FISTP 0x8000000000000000 => quad: 0
+ FISTTP 0x0 => word: 0
+ FISTTP 0x8000000000000000 => word: 0
+ FISTTP 0x0 => long: 0
+ FISTTP 0x8000000000000000 => long: 0
+ FISTTP 0x0 => quad: 0
+ FISTTP 0x8000000000000000 => quad: 0
+Rounding 2
+ FRNDINT 0x0 => 0x0
+ FRNDINT 0x8000000000000000 => 0x8000000000000000
+ FISTP 0x0 => word: 0
+ FISTP 0x8000000000000000 => word: 0
+ FISTP 0x0 => long: 0
+ FISTP 0x8000000000000000 => long: 0
+ FISTP 0x0 => quad: 0
+ FISTP 0x8000000000000000 => quad: 0
+ FISTTP 0x0 => word: 0
+ FISTTP 0x8000000000000000 => word: 0
+ FISTTP 0x0 => long: 0
+ FISTTP 0x8000000000000000 => long: 0
+ FISTTP 0x0 => quad: 0
+ FISTTP 0x8000000000000000 => quad: 0
+FUCOMI 0x40dfffc000000000 0x40e0002000000000 --C
+FUCOMPP 0x40dfffc000000000 0x40e0002000000000 --C
+Rounding 0
+ FRNDINT 0x40dfffc000000000 => 0x40dfffc000000000
+ FRNDINT 0x40e0002000000000 => 0x40e0002000000000
+ FISTP 0x40dfffc000000000 => word: 7fff
+ FISTP 0x40e0002000000000 => word: 8000
+ FISTP 0x40dfffc000000000 => long: 7fff
+ FISTP 0x40e0002000000000 => long: 8001
+ FISTP 0x40dfffc000000000 => quad: 7fff
+ FISTP 0x40e0002000000000 => quad: 8001
+ FISTTP 0x40dfffc000000000 => word: 7fff
+ FISTTP 0x40e0002000000000 => word: 8000
+ FISTTP 0x40dfffc000000000 => long: 7fff
+ FISTTP 0x40e0002000000000 => long: 8001
+ FISTTP 0x40dfffc000000000 => quad: 7fff
+ FISTTP 0x40e0002000000000 => quad: 8001
+Rounding 1
+ FRNDINT 0x40dfffc000000000 => 0x40dfffc000000000
+ FRNDINT 0x40e0002000000000 => 0x40e0002000000000
+ FISTP 0x40dfffc000000000 => word: 7fff
+ FISTP 0x40e0002000000000 => word: 8000
+ FISTP 0x40dfffc000000000 => long: 7fff
+ FISTP 0x40e0002000000000 => long: 8001
+ FISTP 0x40dfffc000000000 => quad: 7fff
+ FISTP 0x40e0002000000000 => quad: 8001
+ FISTTP 0x40dfffc000000000 => word: 7fff
+ FISTTP 0x40e0002000000000 => word: 8000
+ FISTTP 0x40dfffc000000000 => long: 7fff
+ FISTTP 0x40e0002000000000 => long: 8001
+ FISTTP 0x40dfffc000000000 => quad: 7fff
+ FISTTP 0x40e0002000000000 => quad: 8001
+Rounding 2
+ FRNDINT 0x40dfffc000000000 => 0x40dfffc000000000
+ FRNDINT 0x40e0002000000000 => 0x40e0002000000000
+ FISTP 0x40dfffc000000000 => word: 7fff
+ FISTP 0x40e0002000000000 => word: 8000
+ FISTP 0x40dfffc000000000 => long: 7fff
+ FISTP 0x40e0002000000000 => long: 8001
+ FISTP 0x40dfffc000000000 => quad: 7fff
+ FISTP 0x40e0002000000000 => quad: 8001
+ FISTTP 0x40dfffc000000000 => word: 7fff
+ FISTTP 0x40e0002000000000 => word: 8000
+ FISTTP 0x40dfffc000000000 => long: 7fff
+ FISTTP 0x40e0002000000000 => long: 8001
+ FISTTP 0x40dfffc000000000 => quad: 7fff
+ FISTTP 0x40e0002000000000 => quad: 8001
+FUCOMI 0x40e0002000000000 0x40dfffc000000000 ---
+FUCOMPP 0x40e0002000000000 0x40dfffc000000000 ---
+Rounding 0
+ FRNDINT 0x40e0002000000000 => 0x40e0002000000000
+ FRNDINT 0x40dfffc000000000 => 0x40dfffc000000000
+ FISTP 0x40e0002000000000 => word: 8000
+ FISTP 0x40dfffc000000000 => word: 7fff
+ FISTP 0x40e0002000000000 => long: 8001
+ FISTP 0x40dfffc000000000 => long: 7fff
+ FISTP 0x40e0002000000000 => quad: 8001
+ FISTP 0x40dfffc000000000 => quad: 7fff
+ FISTTP 0x40e0002000000000 => word: 8000
+ FISTTP 0x40dfffc000000000 => word: 7fff
+ FISTTP 0x40e0002000000000 => long: 8001
+ FISTTP 0x40dfffc000000000 => long: 7fff
+ FISTTP 0x40e0002000000000 => quad: 8001
+ FISTTP 0x40dfffc000000000 => quad: 7fff
+Rounding 1
+ FRNDINT 0x40e0002000000000 => 0x40e0002000000000
+ FRNDINT 0x40dfffc000000000 => 0x40dfffc000000000
+ FISTP 0x40e0002000000000 => word: 8000
+ FISTP 0x40dfffc000000000 => word: 7fff
+ FISTP 0x40e0002000000000 => long: 8001
+ FISTP 0x40dfffc000000000 => long: 7fff
+ FISTP 0x40e0002000000000 => quad: 8001
+ FISTP 0x40dfffc000000000 => quad: 7fff
+ FISTTP 0x40e0002000000000 => word: 8000
+ FISTTP 0x40dfffc000000000 => word: 7fff
+ FISTTP 0x40e0002000000000 => long: 8001
+ FISTTP 0x40dfffc000000000 => long: 7fff
+ FISTTP 0x40e0002000000000 => quad: 8001
+ FISTTP 0x40dfffc000000000 => quad: 7fff
+Rounding 2
+ FRNDINT 0x40e0002000000000 => 0x40e0002000000000
+ FRNDINT 0x40dfffc000000000 => 0x40dfffc000000000
+ FISTP 0x40e0002000000000 => word: 8000
+ FISTP 0x40dfffc000000000 => word: 7fff
+ FISTP 0x40e0002000000000 => long: 8001
+ FISTP 0x40dfffc000000000 => long: 7fff
+ FISTP 0x40e0002000000000 => quad: 8001
+ FISTP 0x40dfffc000000000 => quad: 7fff
+ FISTTP 0x40e0002000000000 => word: 8000
+ FISTTP 0x40dfffc000000000 => word: 7fff
+ FISTTP 0x40e0002000000000 => long: 8001
+ FISTTP 0x40dfffc000000000 => long: 7fff
+ FISTTP 0x40e0002000000000 => quad: 8001
+ FISTTP 0x40dfffc000000000 => quad: 7fff
+FUCOMI 0xc0e0002000000000 0xc0dfffc000000000 --C
+FUCOMPP 0xc0e0002000000000 0xc0dfffc000000000 --C
+Rounding 0
+ FRNDINT 0xc0e0002000000000 => 0xc0e0002000000000
+ FRNDINT 0xc0dfffc000000000 => 0xc0dfffc000000000
+ FISTP 0xc0e0002000000000 => word: 8000
+ FISTP 0xc0dfffc000000000 => word: 8001
+ FISTP 0xc0e0002000000000 => long: ffff7fff
+ FISTP 0xc0dfffc000000000 => long: ffff8001
+ FISTP 0xc0e0002000000000 => quad: ffffffffffff7fff
+ FISTP 0xc0dfffc000000000 => quad: ffffffffffff8001
+ FISTTP 0xc0e0002000000000 => word: 8000
+ FISTTP 0xc0dfffc000000000 => word: 8001
+ FISTTP 0xc0e0002000000000 => long: ffff7fff
+ FISTTP 0xc0dfffc000000000 => long: ffff8001
+ FISTTP 0xc0e0002000000000 => quad: ffffffffffff7fff
+ FISTTP 0xc0dfffc000000000 => quad: ffffffffffff8001
+Rounding 1
+ FRNDINT 0xc0e0002000000000 => 0xc0e0002000000000
+ FRNDINT 0xc0dfffc000000000 => 0xc0dfffc000000000
+ FISTP 0xc0e0002000000000 => word: 8000
+ FISTP 0xc0dfffc000000000 => word: 8001
+ FISTP 0xc0e0002000000000 => long: ffff7fff
+ FISTP 0xc0dfffc000000000 => long: ffff8001
+ FISTP 0xc0e0002000000000 => quad: ffffffffffff7fff
+ FISTP 0xc0dfffc000000000 => quad: ffffffffffff8001
+ FISTTP 0xc0e0002000000000 => word: 8000
+ FISTTP 0xc0dfffc000000000 => word: 8001
+ FISTTP 0xc0e0002000000000 => long: ffff7fff
+ FISTTP 0xc0dfffc000000000 => long: ffff8001
+ FISTTP 0xc0e0002000000000 => quad: ffffffffffff7fff
+ FISTTP 0xc0dfffc000000000 => quad: ffffffffffff8001
+Rounding 2
+ FRNDINT 0xc0e0002000000000 => 0xc0e0002000000000
+ FRNDINT 0xc0dfffc000000000 => 0xc0dfffc000000000
+ FISTP 0xc0e0002000000000 => word: 8000
+ FISTP 0xc0dfffc000000000 => word: 8001
+ FISTP 0xc0e0002000000000 => long: ffff7fff
+ FISTP 0xc0dfffc000000000 => long: ffff8001
+ FISTP 0xc0e0002000000000 => quad: ffffffffffff7fff
+ FISTP 0xc0dfffc000000000 => quad: ffffffffffff8001
+ FISTTP 0xc0e0002000000000 => word: 8000
+ FISTTP 0xc0dfffc000000000 => word: 8001
+ FISTTP 0xc0e0002000000000 => long: ffff7fff
+ FISTTP 0xc0dfffc000000000 => long: ffff8001
+ FISTTP 0xc0e0002000000000 => quad: ffffffffffff7fff
+ FISTTP 0xc0dfffc000000000 => quad: ffffffffffff8001
+FUCOMI 0xc0dfffc000000000 0xc0e0002000000000 ---
+FUCOMPP 0xc0dfffc000000000 0xc0e0002000000000 ---
+Rounding 0
+ FRNDINT 0xc0dfffc000000000 => 0xc0dfffc000000000
+ FRNDINT 0xc0e0002000000000 => 0xc0e0002000000000
+ FISTP 0xc0dfffc000000000 => word: 8001
+ FISTP 0xc0e0002000000000 => word: 8000
+ FISTP 0xc0dfffc000000000 => long: ffff8001
+ FISTP 0xc0e0002000000000 => long: ffff7fff
+ FISTP 0xc0dfffc000000000 => quad: ffffffffffff8001
+ FISTP 0xc0e0002000000000 => quad: ffffffffffff7fff
+ FISTTP 0xc0dfffc000000000 => word: 8001
+ FISTTP 0xc0e0002000000000 => word: 8000
+ FISTTP 0xc0dfffc000000000 => long: ffff8001
+ FISTTP 0xc0e0002000000000 => long: ffff7fff
+ FISTTP 0xc0dfffc000000000 => quad: ffffffffffff8001
+ FISTTP 0xc0e0002000000000 => quad: ffffffffffff7fff
+Rounding 1
+ FRNDINT 0xc0dfffc000000000 => 0xc0dfffc000000000
+ FRNDINT 0xc0e0002000000000 => 0xc0e0002000000000
+ FISTP 0xc0dfffc000000000 => word: 8001
+ FISTP 0xc0e0002000000000 => word: 8000
+ FISTP 0xc0dfffc000000000 => long: ffff8001
+ FISTP 0xc0e0002000000000 => long: ffff7fff
+ FISTP 0xc0dfffc000000000 => quad: ffffffffffff8001
+ FISTP 0xc0e0002000000000 => quad: ffffffffffff7fff
+ FISTTP 0xc0dfffc000000000 => word: 8001
+ FISTTP 0xc0e0002000000000 => word: 8000
+ FISTTP 0xc0dfffc000000000 => long: ffff8001
+ FISTTP 0xc0e0002000000000 => long: ffff7fff
+ FISTTP 0xc0dfffc000000000 => quad: ffffffffffff8001
+ FISTTP 0xc0e0002000000000 => quad: ffffffffffff7fff
+Rounding 2
+ FRNDINT 0xc0dfffc000000000 => 0xc0dfffc000000000
+ FRNDINT 0xc0e0002000000000 => 0xc0e0002000000000
+ FISTP 0xc0dfffc000000000 => word: 8001
+ FISTP 0xc0e0002000000000 => word: 8000
+ FISTP 0xc0dfffc000000000 => long: ffff8001
+ FISTP 0xc0e0002000000000 => long: ffff7fff
+ FISTP 0xc0dfffc000000000 => quad: ffffffffffff8001
+ FISTP 0xc0e0002000000000 => quad: ffffffffffff7fff
+ FISTTP 0xc0dfffc000000000 => word: 8001
+ FISTTP 0xc0e0002000000000 => word: 8000
+ FISTTP 0xc0dfffc000000000 => long: ffff8001
+ FISTTP 0xc0e0002000000000 => long: ffff7fff
+ FISTTP 0xc0dfffc000000000 => quad: ffffffffffff8001
+ FISTTP 0xc0e0002000000000 => quad: ffffffffffff7fff
FUCOMI 0x8000000000000000 0x3ff0000000000000 --C
FUCOMPP 0x8000000000000000 0x3ff0000000000000 --C
-FRNDINT 0x8000000000000000 => 0x8000000000000000
-FRNDINT 0x3ff0000000000000 => 0x3ff0000000000000
-FISTP 0x8000000000000000 => word: 0
-FISTP 0x3ff0000000000000 => word: 1
-FISTP 0x8000000000000000 => long: 0
-FISTP 0x3ff0000000000000 => long: 1
-FISTP 0x8000000000000000 => quad: 0
-FISTP 0x3ff0000000000000 => quad: 1
+Rounding 0
+ FRNDINT 0x8000000000000000 => 0x8000000000000000
+ FRNDINT 0x3ff0000000000000 => 0x3ff0000000000000
+ FISTP 0x8000000000000000 => word: 0
+ FISTP 0x3ff0000000000000 => word: 1
+ FISTP 0x8000000000000000 => long: 0
+ FISTP 0x3ff0000000000000 => long: 1
+ FISTP 0x8000000000000000 => quad: 0
+ FISTP 0x3ff0000000000000 => quad: 1
+ FISTTP 0x8000000000000000 => word: 0
+ FISTTP 0x3ff0000000000000 => word: 1
+ FISTTP 0x8000000000000000 => long: 0
+ FISTTP 0x3ff0000000000000 => long: 1
+ FISTTP 0x8000000000000000 => quad: 0
+ FISTTP 0x3ff0000000000000 => quad: 1
+Rounding 1
+ FRNDINT 0x8000000000000000 => 0x8000000000000000
+ FRNDINT 0x3ff0000000000000 => 0x3ff0000000000000
+ FISTP 0x8000000000000000 => word: 0
+ FISTP 0x3ff0000000000000 => word: 1
+ FISTP 0x8000000000000000 => long: 0
+ FISTP 0x3ff0000000000000 => long: 1
+ FISTP 0x8000000000000000 => quad: 0
+ FISTP 0x3ff0000000000000 => quad: 1
+ FISTTP 0x8000000000000000 => word: 0
+ FISTTP 0x3ff0000000000000 => word: 1
+ FISTTP 0x8000000000000000 => long: 0
+ FISTTP 0x3ff0000000000000 => long: 1
+ FISTTP 0x8000000000000000 => quad: 0
+ FISTTP 0x3ff0000000000000 => quad: 1
+Rounding 2
+ FRNDINT 0x8000000000000000 => 0x8000000000000000
+ FRNDINT 0x3ff0000000000000 => 0x3ff0000000000000
+ FISTP 0x8000000000000000 => word: 0
+ FISTP 0x3ff0000000000000 => word: 1
+ FISTP 0x8000000000000000 => long: 0
+ FISTP 0x3ff0000000000000 => long: 1
+ FISTP 0x8000000000000000 => quad: 0
+ FISTP 0x3ff0000000000000 => quad: 1
+ FISTTP 0x8000000000000000 => word: 0
+ FISTTP 0x3ff0000000000000 => word: 1
+ FISTTP 0x8000000000000000 => long: 0
+ FISTTP 0x3ff0000000000000 => long: 1
+ FISTTP 0x8000000000000000 => quad: 0
+ FISTTP 0x3ff0000000000000 => quad: 1
FUCOMI 0x3ff0000000000000 0x8000000000000000 ---
FUCOMPP 0x3ff0000000000000 0x8000000000000000 ---
-FRNDINT 0x3ff0000000000000 => 0x3ff0000000000000
-FRNDINT 0x8000000000000000 => 0x8000000000000000
-FISTP 0x3ff0000000000000 => word: 1
-FISTP 0x8000000000000000 => word: 0
-FISTP 0x3ff0000000000000 => long: 1
-FISTP 0x8000000000000000 => long: 0
-FISTP 0x3ff0000000000000 => quad: 1
-FISTP 0x8000000000000000 => quad: 0
+Rounding 0
+ FRNDINT 0x3ff0000000000000 => 0x3ff0000000000000
+ FRNDINT 0x8000000000000000 => 0x8000000000000000
+ FISTP 0x3ff0000000000000 => word: 1
+ FISTP 0x8000000000000000 => word: 0
+ FISTP 0x3ff0000000000000 => long: 1
+ FISTP 0x8000000000000000 => long: 0
+ FISTP 0x3ff0000000000000 => quad: 1
+ FISTP 0x8000000000000000 => quad: 0
+ FISTTP 0x3ff0000000000000 => word: 1
+ FISTTP 0x8000000000000000 => word: 0
+ FISTTP 0x3ff0000000000000 => long: 1
+ FISTTP 0x8000000000000000 => long: 0
+ FISTTP 0x3ff0000000000000 => quad: 1
+ FISTTP 0x8000000000000000 => quad: 0
+Rounding 1
+ FRNDINT 0x3ff0000000000000 => 0x3ff0000000000000
+ FRNDINT 0x8000000000000000 => 0x8000000000000000
+ FISTP 0x3ff0000000000000 => word: 1
+ FISTP 0x8000000000000000 => word: 0
+ FISTP 0x3ff0000000000000 => long: 1
+ FISTP 0x8000000000000000 => long: 0
+ FISTP 0x3ff0000000000000 => quad: 1
+ FISTP 0x8000000000000000 => quad: 0
+ FISTTP 0x3ff0000000000000 => word: 1
+ FISTTP 0x8000000000000000 => word: 0
+ FISTTP 0x3ff0000000000000 => long: 1
+ FISTTP 0x8000000000000000 => long: 0
+ FISTTP 0x3ff0000000000000 => quad: 1
+ FISTTP 0x8000000000000000 => quad: 0
+Rounding 2
+ FRNDINT 0x3ff0000000000000 => 0x3ff0000000000000
+ FRNDINT 0x8000000000000000 => 0x8000000000000000
+ FISTP 0x3ff0000000000000 => word: 1
+ FISTP 0x8000000000000000 => word: 0
+ FISTP 0x3ff0000000000000 => long: 1
+ FISTP 0x8000000000000000 => long: 0
+ FISTP 0x3ff0000000000000 => quad: 1
+ FISTP 0x8000000000000000 => quad: 0
+ FISTTP 0x3ff0000000000000 => word: 1
+ FISTTP 0x8000000000000000 => word: 0
+ FISTTP 0x3ff0000000000000 => long: 1
+ FISTTP 0x8000000000000000 => long: 0
+ FISTTP 0x3ff0000000000000 => quad: 1
+ FISTTP 0x8000000000000000 => quad: 0
FUCOMI 0x3ff0000000000000 0x3fe89d9000000000 ---
FUCOMPP 0x3ff0000000000000 0x3fe89d9000000000 ---
-FRNDINT 0x3ff0000000000000 => 0x3ff0000000000000
-FRNDINT 0x3fe89d9000000000 => 0x0
-FISTP 0x3ff0000000000000 => word: 1
-FISTP 0x3fe89d9000000000 => word: 0
-FISTP 0x3ff0000000000000 => long: 1
-FISTP 0x3fe89d9000000000 => long: 0
-FISTP 0x3ff0000000000000 => quad: 1
-FISTP 0x3fe89d9000000000 => quad: 0
+Rounding 0
+ FRNDINT 0x3ff0000000000000 => 0x3ff0000000000000
+ FRNDINT 0x3fe89d9000000000 => 0x3ff0000000000000
+ FISTP 0x3ff0000000000000 => word: 1
+ FISTP 0x3fe89d9000000000 => word: 1
+ FISTP 0x3ff0000000000000 => long: 1
+ FISTP 0x3fe89d9000000000 => long: 1
+ FISTP 0x3ff0000000000000 => quad: 1
+ FISTP 0x3fe89d9000000000 => quad: 1
+ FISTTP 0x3ff0000000000000 => word: 1
+ FISTTP 0x3fe89d9000000000 => word: 0
+ FISTTP 0x3ff0000000000000 => long: 1
+ FISTTP 0x3fe89d9000000000 => long: 0
+ FISTTP 0x3ff0000000000000 => quad: 1
+ FISTTP 0x3fe89d9000000000 => quad: 0
+Rounding 1
+ FRNDINT 0x3ff0000000000000 => 0x3ff0000000000000
+ FRNDINT 0x3fe89d9000000000 => 0x0
+ FISTP 0x3ff0000000000000 => word: 1
+ FISTP 0x3fe89d9000000000 => word: 0
+ FISTP 0x3ff0000000000000 => long: 1
+ FISTP 0x3fe89d9000000000 => long: 0
+ FISTP 0x3ff0000000000000 => quad: 1
+ FISTP 0x3fe89d9000000000 => quad: 0
+ FISTTP 0x3ff0000000000000 => word: 1
+ FISTTP 0x3fe89d9000000000 => word: 0
+ FISTTP 0x3ff0000000000000 => long: 1
+ FISTTP 0x3fe89d9000000000 => long: 0
+ FISTTP 0x3ff0000000000000 => quad: 1
+ FISTTP 0x3fe89d9000000000 => quad: 0
+Rounding 2
+ FRNDINT 0x3ff0000000000000 => 0x3ff0000000000000
+ FRNDINT 0x3fe89d9000000000 => 0x3ff0000000000000
+ FISTP 0x3ff0000000000000 => word: 1
+ FISTP 0x3fe89d9000000000 => word: 1
+ FISTP 0x3ff0000000000000 => long: 1
+ FISTP 0x3fe89d9000000000 => long: 1
+ FISTP 0x3ff0000000000000 => quad: 1
+ FISTP 0x3fe89d9000000000 => quad: 1
+ FISTTP 0x3ff0000000000000 => word: 1
+ FISTTP 0x3fe89d9000000000 => word: 0
+ FISTTP 0x3ff0000000000000 => long: 1
+ FISTTP 0x3fe89d9000000000 => long: 0
+ FISTTP 0x3ff0000000000000 => quad: 1
+ FISTTP 0x3fe89d9000000000 => quad: 0
FUCOMI 0x3fe89d9000000000 0x3ff0000000000000 --C
FUCOMPP 0x3fe89d9000000000 0x3ff0000000000000 --C
-FRNDINT 0x3fe89d9000000000 => 0x0
-FRNDINT 0x3ff0000000000000 => 0x3ff0000000000000
-FISTP 0x3fe89d9000000000 => word: 0
-FISTP 0x3ff0000000000000 => word: 1
-FISTP 0x3fe89d9000000000 => long: 0
-FISTP 0x3ff0000000000000 => long: 1
-FISTP 0x3fe89d9000000000 => quad: 0
-FISTP 0x3ff0000000000000 => quad: 1
+Rounding 0
+ FRNDINT 0x3fe89d9000000000 => 0x3ff0000000000000
+ FRNDINT 0x3ff0000000000000 => 0x3ff0000000000000
+ FISTP 0x3fe89d9000000000 => word: 1
+ FISTP 0x3ff0000000000000 => word: 1
+ FISTP 0x3fe89d9000000000 => long: 1
+ FISTP 0x3ff0000000000000 => long: 1
+ FISTP 0x3fe89d9000000000 => quad: 1
+ FISTP 0x3ff0000000000000 => quad: 1
+ FISTTP 0x3fe89d9000000000 => word: 0
+ FISTTP 0x3ff0000000000000 => word: 1
+ FISTTP 0x3fe89d9000000000 => long: 0
+ FISTTP 0x3ff0000000000000 => long: 1
+ FISTTP 0x3fe89d9000000000 => quad: 0
+ FISTTP 0x3ff0000000000000 => quad: 1
+Rounding 1
+ FRNDINT 0x3fe89d9000000000 => 0x0
+ FRNDINT 0x3ff0000000000000 => 0x3ff0000000000000
+ FISTP 0x3fe89d9000000000 => word: 0
+ FISTP 0x3ff0000000000000 => word: 1
+ FISTP 0x3fe89d9000000000 => long: 0
+ FISTP 0x3ff0000000000000 => long: 1
+ FISTP 0x3fe89d9000000000 => quad: 0
+ FISTP 0x3ff0000000000000 => quad: 1
+ FISTTP 0x3fe89d9000000000 => word: 0
+ FISTTP 0x3ff0000000000000 => word: 1
+ FISTTP 0x3fe89d9000000000 => long: 0
+ FISTTP 0x3ff0000000000000 => long: 1
+ FISTTP 0x3fe89d9000000000 => quad: 0
+ FISTTP 0x3ff0000000000000 => quad: 1
+Rounding 2
+ FRNDINT 0x3fe89d9000000000 => 0x3ff0000000000000
+ FRNDINT 0x3ff0000000000000 => 0x3ff0000000000000
+ FISTP 0x3fe89d9000000000 => word: 1
+ FISTP 0x3ff0000000000000 => word: 1
+ FISTP 0x3fe89d9000000000 => long: 1
+ FISTP 0x3ff0000000000000 => long: 1
+ FISTP 0x3fe89d9000000000 => quad: 1
+ FISTP 0x3ff0000000000000 => quad: 1
+ FISTTP 0x3fe89d9000000000 => word: 0
+ FISTTP 0x3ff0000000000000 => word: 1
+ FISTTP 0x3fe89d9000000000 => long: 0
+ FISTTP 0x3ff0000000000000 => long: 1
+ FISTTP 0x3fe89d9000000000 => quad: 0
+ FISTTP 0x3ff0000000000000 => quad: 1
FUCOMI 0x3ff0000000000000 0x7ff0000000000000 --C
FUCOMPP 0x3ff0000000000000 0x7ff0000000000000 --C
-FRNDINT 0x3ff0000000000000 => 0x3ff0000000000000
-FRNDINT 0x7ff0000000000000 => 0x7ff0000000000000
-FISTP 0x3ff0000000000000 => word: 1
-FISTP 0x7ff0000000000000 => word: 8000
-FISTP 0x3ff0000000000000 => long: 1
-FISTP 0x7ff0000000000000 => long: 80000000
-FISTP 0x3ff0000000000000 => quad: 1
-FISTP 0x7ff0000000000000 => quad: 8000000000000000
+Rounding 0
+ FRNDINT 0x3ff0000000000000 => 0x3ff0000000000000
+ FRNDINT 0x7ff0000000000000 => 0x7ff0000000000000
+ FISTP 0x3ff0000000000000 => word: 1
+ FISTP 0x7ff0000000000000 => word: 8000
+ FISTP 0x3ff0000000000000 => long: 1
+ FISTP 0x7ff0000000000000 => long: 80000000
+ FISTP 0x3ff0000000000000 => quad: 1
+ FISTP 0x7ff0000000000000 => quad: 8000000000000000
+ FISTTP 0x3ff0000000000000 => word: 1
+ FISTTP 0x7ff0000000000000 => word: 8000
+ FISTTP 0x3ff0000000000000 => long: 1
+ FISTTP 0x7ff0000000000000 => long: 80000000
+ FISTTP 0x3ff0000000000000 => quad: 1
+ FISTTP 0x7ff0000000000000 => quad: 8000000000000000
+Rounding 1
+ FRNDINT 0x3ff0000000000000 => 0x3ff0000000000000
+ FRNDINT 0x7ff0000000000000 => 0x7ff0000000000000
+ FISTP 0x3ff0000000000000 => word: 1
+ FISTP 0x7ff0000000000000 => word: 8000
+ FISTP 0x3ff0000000000000 => long: 1
+ FISTP 0x7ff0000000000000 => long: 80000000
+ FISTP 0x3ff0000000000000 => quad: 1
+ FISTP 0x7ff0000000000000 => quad: 8000000000000000
+ FISTTP 0x3ff0000000000000 => word: 1
+ FISTTP 0x7ff0000000000000 => word: 8000
+ FISTTP 0x3ff0000000000000 => long: 1
+ FISTTP 0x7ff0000000000000 => long: 80000000
+ FISTTP 0x3ff0000000000000 => quad: 1
+ FISTTP 0x7ff0000000000000 => quad: 8000000000000000
+Rounding 2
+ FRNDINT 0x3ff0000000000000 => 0x3ff0000000000000
+ FRNDINT 0x7ff0000000000000 => 0x7ff0000000000000
+ FISTP 0x3ff0000000000000 => word: 1
+ FISTP 0x7ff0000000000000 => word: 8000
+ FISTP 0x3ff0000000000000 => long: 1
+ FISTP 0x7ff0000000000000 => long: 80000000
+ FISTP 0x3ff0000000000000 => quad: 1
+ FISTP 0x7ff0000000000000 => quad: 8000000000000000
+ FISTTP 0x3ff0000000000000 => word: 1
+ FISTTP 0x7ff0000000000000 => word: 8000
+ FISTTP 0x3ff0000000000000 => long: 1
+ FISTTP 0x7ff0000000000000 => long: 80000000
+ FISTTP 0x3ff0000000000000 => quad: 1
+ FISTTP 0x7ff0000000000000 => quad: 8000000000000000
FUCOMI 0x7ff0000000000000 0x3ff0000000000000 ---
FUCOMPP 0x7ff0000000000000 0x3ff0000000000000 ---
-FRNDINT 0x7ff0000000000000 => 0x7ff0000000000000
-FRNDINT 0x3ff0000000000000 => 0x3ff0000000000000
-FISTP 0x7ff0000000000000 => word: 8000
-FISTP 0x3ff0000000000000 => word: 1
-FISTP 0x7ff0000000000000 => long: 80000000
-FISTP 0x3ff0000000000000 => long: 1
-FISTP 0x7ff0000000000000 => quad: 8000000000000000
-FISTP 0x3ff0000000000000 => quad: 1
+Rounding 0
+ FRNDINT 0x7ff0000000000000 => 0x7ff0000000000000
+ FRNDINT 0x3ff0000000000000 => 0x3ff0000000000000
+ FISTP 0x7ff0000000000000 => word: 8000
+ FISTP 0x3ff0000000000000 => word: 1
+ FISTP 0x7ff0000000000000 => long: 80000000
+ FISTP 0x3ff0000000000000 => long: 1
+ FISTP 0x7ff0000000000000 => quad: 8000000000000000
+ FISTP 0x3ff0000000000000 => quad: 1
+ FISTTP 0x7ff0000000000000 => word: 8000
+ FISTTP 0x3ff0000000000000 => word: 1
+ FISTTP 0x7ff0000000000000 => long: 80000000
+ FISTTP 0x3ff0000000000000 => long: 1
+ FISTTP 0x7ff0000000000000 => quad: 8000000000000000
+ FISTTP 0x3ff0000000000000 => quad: 1
+Rounding 1
+ FRNDINT 0x7ff0000000000000 => 0x7ff0000000000000
+ FRNDINT 0x3ff0000000000000 => 0x3ff0000000000000
+ FISTP 0x7ff0000000000000 => word: 8000
+ FISTP 0x3ff0000000000000 => word: 1
+ FISTP 0x7ff0000000000000 => long: 80000000
+ FISTP 0x3ff0000000000000 => long: 1
+ FISTP 0x7ff0000000000000 => quad: 8000000000000000
+ FISTP 0x3ff0000000000000 => quad: 1
+ FISTTP 0x7ff0000000000000 => word: 8000
+ FISTTP 0x3ff0000000000000 => word: 1
+ FISTTP 0x7ff0000000000000 => long: 80000000
+ FISTTP 0x3ff0000000000000 => long: 1
+ FISTTP 0x7ff0000000000000 => quad: 8000000000000000
+ FISTTP 0x3ff0000000000000 => quad: 1
+Rounding 2
+ FRNDINT 0x7ff0000000000000 => 0x7ff0000000000000
+ FRNDINT 0x3ff0000000000000 => 0x3ff0000000000000
+ FISTP 0x7ff0000000000000 => word: 8000
+ FISTP 0x3ff0000000000000 => word: 1
+ FISTP 0x7ff0000000000000 => long: 80000000
+ FISTP 0x3ff0000000000000 => long: 1
+ FISTP 0x7ff0000000000000 => quad: 8000000000000000
+ FISTP 0x3ff0000000000000 => quad: 1
+ FISTTP 0x7ff0000000000000 => word: 8000
+ FISTTP 0x3ff0000000000000 => word: 1
+ FISTTP 0x7ff0000000000000 => long: 80000000
+ FISTTP 0x3ff0000000000000 => long: 1
+ FISTTP 0x7ff0000000000000 => quad: 8000000000000000
+ FISTTP 0x3ff0000000000000 => quad: 1
FUCOMI 0xfff0000000000000 0x7ff0000000000000 --C
FUCOMPP 0xfff0000000000000 0x7ff0000000000000 --C
-FRNDINT 0xfff0000000000000 => 0xfff0000000000000
-FRNDINT 0x7ff0000000000000 => 0x7ff0000000000000
-FISTP 0xfff0000000000000 => word: 8000
-FISTP 0x7ff0000000000000 => word: 8000
-FISTP 0xfff0000000000000 => long: 80000000
-FISTP 0x7ff0000000000000 => long: 80000000
-FISTP 0xfff0000000000000 => quad: 8000000000000000
-FISTP 0x7ff0000000000000 => quad: 8000000000000000
+Rounding 0
+ FRNDINT 0xfff0000000000000 => 0xfff0000000000000
+ FRNDINT 0x7ff0000000000000 => 0x7ff0000000000000
+ FISTP 0xfff0000000000000 => word: 8000
+ FISTP 0x7ff0000000000000 => word: 8000
+ FISTP 0xfff0000000000000 => long: 80000000
+ FISTP 0x7ff0000000000000 => long: 80000000
+ FISTP 0xfff0000000000000 => quad: 8000000000000000
+ FISTP 0x7ff0000000000000 => quad: 8000000000000000
+ FISTTP 0xfff0000000000000 => word: 8000
+ FISTTP 0x7ff0000000000000 => word: 8000
+ FISTTP 0xfff0000000000000 => long: 80000000
+ FISTTP 0x7ff0000000000000 => long: 80000000
+ FISTTP 0xfff0000000000000 => quad: 8000000000000000
+ FISTTP 0x7ff0000000000000 => quad: 8000000000000000
+Rounding 1
+ FRNDINT 0xfff0000000000000 => 0xfff0000000000000
+ FRNDINT 0x7ff0000000000000 => 0x7ff0000000000000
+ FISTP 0xfff0000000000000 => word: 8000
+ FISTP 0x7ff0000000000000 => word: 8000
+ FISTP 0xfff0000000000000 => long: 80000000
+ FISTP 0x7ff0000000000000 => long: 80000000
+ FISTP 0xfff0000000000000 => quad: 8000000000000000
+ FISTP 0x7ff0000000000000 => quad: 8000000000000000
+ FISTTP 0xfff0000000000000 => word: 8000
+ FISTTP 0x7ff0000000000000 => word: 8000
+ FISTTP 0xfff0000000000000 => long: 80000000
+ FISTTP 0x7ff0000000000000 => long: 80000000
+ FISTTP 0xfff0000000000000 => quad: 8000000000000000
+ FISTTP 0x7ff0000000000000 => quad: 8000000000000000
+Rounding 2
+ FRNDINT 0xfff0000000000000 => 0xfff0000000000000
+ FRNDINT 0x7ff0000000000000 => 0x7ff0000000000000
+ FISTP 0xfff0000000000000 => word: 8000
+ FISTP 0x7ff0000000000000 => word: 8000
+ FISTP 0xfff0000000000000 => long: 80000000
+ FISTP 0x7ff0000000000000 => long: 80000000
+ FISTP 0xfff0000000000000 => quad: 8000000000000000
+ FISTP 0x7ff0000000000000 => quad: 8000000000000000
+ FISTTP 0xfff0000000000000 => word: 8000
+ FISTTP 0x7ff0000000000000 => word: 8000
+ FISTTP 0xfff0000000000000 => long: 80000000
+ FISTTP 0x7ff0000000000000 => long: 80000000
+ FISTTP 0xfff0000000000000 => quad: 8000000000000000
+ FISTTP 0x7ff0000000000000 => quad: 8000000000000000
FUCOMI 0x7ff0000000000000 0xfff0000000000000 ---
FUCOMPP 0x7ff0000000000000 0xfff0000000000000 ---
-FRNDINT 0x7ff0000000000000 => 0x7ff0000000000000
-FRNDINT 0xfff0000000000000 => 0xfff0000000000000
-FISTP 0x7ff0000000000000 => word: 8000
-FISTP 0xfff0000000000000 => word: 8000
-FISTP 0x7ff0000000000000 => long: 80000000
-FISTP 0xfff0000000000000 => long: 80000000
-FISTP 0x7ff0000000000000 => quad: 8000000000000000
-FISTP 0xfff0000000000000 => quad: 8000000000000000
+Rounding 0
+ FRNDINT 0x7ff0000000000000 => 0x7ff0000000000000
+ FRNDINT 0xfff0000000000000 => 0xfff0000000000000
+ FISTP 0x7ff0000000000000 => word: 8000
+ FISTP 0xfff0000000000000 => word: 8000
+ FISTP 0x7ff0000000000000 => long: 80000000
+ FISTP 0xfff0000000000000 => long: 80000000
+ FISTP 0x7ff0000000000000 => quad: 8000000000000000
+ FISTP 0xfff0000000000000 => quad: 8000000000000000
+ FISTTP 0x7ff0000000000000 => word: 8000
+ FISTTP 0xfff0000000000000 => word: 8000
+ FISTTP 0x7ff0000000000000 => long: 80000000
+ FISTTP 0xfff0000000000000 => long: 80000000
+ FISTTP 0x7ff0000000000000 => quad: 8000000000000000
+ FISTTP 0xfff0000000000000 => quad: 8000000000000000
+Rounding 1
+ FRNDINT 0x7ff0000000000000 => 0x7ff0000000000000
+ FRNDINT 0xfff0000000000000 => 0xfff0000000000000
+ FISTP 0x7ff0000000000000 => word: 8000
+ FISTP 0xfff0000000000000 => word: 8000
+ FISTP 0x7ff0000000000000 => long: 80000000
+ FISTP 0xfff0000000000000 => long: 80000000
+ FISTP 0x7ff0000000000000 => quad: 8000000000000000
+ FISTP 0xfff0000000000000 => quad: 8000000000000000
+ FISTTP 0x7ff0000000000000 => word: 8000
+ FISTTP 0xfff0000000000000 => word: 8000
+ FISTTP 0x7ff0000000000000 => long: 80000000
+ FISTTP 0xfff0000000000000 => long: 80000000
+ FISTTP 0x7ff0000000000000 => quad: 8000000000000000
+ FISTTP 0xfff0000000000000 => quad: 8000000000000000
+Rounding 2
+ FRNDINT 0x7ff0000000000000 => 0x7ff0000000000000
+ FRNDINT 0xfff0000000000000 => 0xfff0000000000000
+ FISTP 0x7ff0000000000000 => word: 8000
+ FISTP 0xfff0000000000000 => word: 8000
+ FISTP 0x7ff0000000000000 => long: 80000000
+ FISTP 0xfff0000000000000 => long: 80000000
+ FISTP 0x7ff0000000000000 => quad: 8000000000000000
+ FISTP 0xfff0000000000000 => quad: 8000000000000000
+ FISTTP 0x7ff0000000000000 => word: 8000
+ FISTTP 0xfff0000000000000 => word: 8000
+ FISTTP 0x7ff0000000000000 => long: 80000000
+ FISTTP 0xfff0000000000000 => long: 80000000
+ FISTTP 0x7ff0000000000000 => quad: 8000000000000000
+ FISTTP 0xfff0000000000000 => quad: 8000000000000000
FUCOMI 0x3ff0002ca0000000 0xaeff000025000000 ---
FUCOMPP 0x3ff0002ca0000000 0xaeff000025000000 ---
-FRNDINT 0x3ff0002ca0000000 => 0x3ff0000000000000
-FRNDINT 0xaeff000025000000 => 0x8000000000000000
-FISTP 0x3ff0002ca0000000 => word: 1
-FISTP 0xaeff000025000000 => word: 0
-FISTP 0x3ff0002ca0000000 => long: 1
-FISTP 0xaeff000025000000 => long: 0
-FISTP 0x3ff0002ca0000000 => quad: 1
-FISTP 0xaeff000025000000 => quad: 0
+Rounding 0
+ FRNDINT 0x3ff0002ca0000000 => 0x3ff0000000000000
+ FRNDINT 0xaeff000025000000 => 0x8000000000000000
+ FISTP 0x3ff0002ca0000000 => word: 1
+ FISTP 0xaeff000025000000 => word: 0
+ FISTP 0x3ff0002ca0000000 => long: 1
+ FISTP 0xaeff000025000000 => long: 0
+ FISTP 0x3ff0002ca0000000 => quad: 1
+ FISTP 0xaeff000025000000 => quad: 0
+ FISTTP 0x3ff0002ca0000000 => word: 1
+ FISTTP 0xaeff000025000000 => word: 0
+ FISTTP 0x3ff0002ca0000000 => long: 1
+ FISTTP 0xaeff000025000000 => long: 0
+ FISTTP 0x3ff0002ca0000000 => quad: 1
+ FISTTP 0xaeff000025000000 => quad: 0
+Rounding 1
+ FRNDINT 0x3ff0002ca0000000 => 0x3ff0000000000000
+ FRNDINT 0xaeff000025000000 => 0xbff0000000000000
+ FISTP 0x3ff0002ca0000000 => word: 1
+ FISTP 0xaeff000025000000 => word: ffff
+ FISTP 0x3ff0002ca0000000 => long: 1
+ FISTP 0xaeff000025000000 => long: ffffffff
+ FISTP 0x3ff0002ca0000000 => quad: 1
+ FISTP 0xaeff000025000000 => quad: ffffffffffffffff
+ FISTTP 0x3ff0002ca0000000 => word: 1
+ FISTTP 0xaeff000025000000 => word: 0
+ FISTTP 0x3ff0002ca0000000 => long: 1
+ FISTTP 0xaeff000025000000 => long: 0
+ FISTTP 0x3ff0002ca0000000 => quad: 1
+ FISTTP 0xaeff000025000000 => quad: 0
+Rounding 2
+ FRNDINT 0x3ff0002ca0000000 => 0x4000000000000000
+ FRNDINT 0xaeff000025000000 => 0x8000000000000000
+ FISTP 0x3ff0002ca0000000 => word: 2
+ FISTP 0xaeff000025000000 => word: 0
+ FISTP 0x3ff0002ca0000000 => long: 2
+ FISTP 0xaeff000025000000 => long: 0
+ FISTP 0x3ff0002ca0000000 => quad: 2
+ FISTP 0xaeff000025000000 => quad: 0
+ FISTTP 0x3ff0002ca0000000 => word: 1
+ FISTTP 0xaeff000025000000 => word: 0
+ FISTTP 0x3ff0002ca0000000 => long: 1
+ FISTTP 0xaeff000025000000 => long: 0
+ FISTTP 0x3ff0002ca0000000 => quad: 1
+ FISTTP 0xaeff000025000000 => quad: 0
FUCOMI 0xaeff000025000000 0x3ff0002ca0000000 --C
FUCOMPP 0xaeff000025000000 0x3ff0002ca0000000 --C
-FRNDINT 0xaeff000025000000 => 0x8000000000000000
-FRNDINT 0x3ff0002ca0000000 => 0x3ff0000000000000
-FISTP 0xaeff000025000000 => word: 0
-FISTP 0x3ff0002ca0000000 => word: 1
-FISTP 0xaeff000025000000 => long: 0
-FISTP 0x3ff0002ca0000000 => long: 1
-FISTP 0xaeff000025000000 => quad: 0
-FISTP 0x3ff0002ca0000000 => quad: 1
+Rounding 0
+ FRNDINT 0xaeff000025000000 => 0x8000000000000000
+ FRNDINT 0x3ff0002ca0000000 => 0x3ff0000000000000
+ FISTP 0xaeff000025000000 => word: 0
+ FISTP 0x3ff0002ca0000000 => word: 1
+ FISTP 0xaeff000025000000 => long: 0
+ FISTP 0x3ff0002ca0000000 => long: 1
+ FISTP 0xaeff000025000000 => quad: 0
+ FISTP 0x3ff0002ca0000000 => quad: 1
+ FISTTP 0xaeff000025000000 => word: 0
+ FISTTP 0x3ff0002ca0000000 => word: 1
+ FISTTP 0xaeff000025000000 => long: 0
+ FISTTP 0x3ff0002ca0000000 => long: 1
+ FISTTP 0xaeff000025000000 => quad: 0
+ FISTTP 0x3ff0002ca0000000 => quad: 1
+Rounding 1
+ FRNDINT 0xaeff000025000000 => 0xbff0000000000000
+ FRNDINT 0x3ff0002ca0000000 => 0x3ff0000000000000
+ FISTP 0xaeff000025000000 => word: ffff
+ FISTP 0x3ff0002ca0000000 => word: 1
+ FISTP 0xaeff000025000000 => long: ffffffff
+ FISTP 0x3ff0002ca0000000 => long: 1
+ FISTP 0xaeff000025000000 => quad: ffffffffffffffff
+ FISTP 0x3ff0002ca0000000 => quad: 1
+ FISTTP 0xaeff000025000000 => word: 0
+ FISTTP 0x3ff0002ca0000000 => word: 1
+ FISTTP 0xaeff000025000000 => long: 0
+ FISTTP 0x3ff0002ca0000000 => long: 1
+ FISTTP 0xaeff000025000000 => quad: 0
+ FISTTP 0x3ff0002ca0000000 => quad: 1
+Rounding 2
+ FRNDINT 0xaeff000025000000 => 0x8000000000000000
+ FRNDINT 0x3ff0002ca0000000 => 0x4000000000000000
+ FISTP 0xaeff000025000000 => word: 0
+ FISTP 0x3ff0002ca0000000 => word: 2
+ FISTP 0xaeff000025000000 => long: 0
+ FISTP 0x3ff0002ca0000000 => long: 2
+ FISTP 0xaeff000025000000 => quad: 0
+ FISTP 0x3ff0002ca0000000 => quad: 2
+ FISTTP 0xaeff000025000000 => word: 0
+ FISTTP 0x3ff0002ca0000000 => word: 1
+ FISTTP 0xaeff000025000000 => long: 0
+ FISTTP 0x3ff0002ca0000000 => long: 1
+ FISTTP 0xaeff000025000000 => quad: 0
+ FISTTP 0x3ff0002ca0000000 => quad: 1
FUCOMI 0x3ff0000050000000 0xc082c00000000000 ---
FUCOMPP 0x3ff0000050000000 0xc082c00000000000 ---
-FRNDINT 0x3ff0000050000000 => 0x3ff0000000000000
-FRNDINT 0xc082c00000000000 => 0xc082c00000000000
-FISTP 0x3ff0000050000000 => word: 1
-FISTP 0xc082c00000000000 => word: fda8
-FISTP 0x3ff0000050000000 => long: 1
-FISTP 0xc082c00000000000 => long: fffffda8
-FISTP 0x3ff0000050000000 => quad: 1
-FISTP 0xc082c00000000000 => quad: fffffffffffffda8
+Rounding 0
+ FRNDINT 0x3ff0000050000000 => 0x3ff0000000000000
+ FRNDINT 0xc082c00000000000 => 0xc082c00000000000
+ FISTP 0x3ff0000050000000 => word: 1
+ FISTP 0xc082c00000000000 => word: fda8
+ FISTP 0x3ff0000050000000 => long: 1
+ FISTP 0xc082c00000000000 => long: fffffda8
+ FISTP 0x3ff0000050000000 => quad: 1
+ FISTP 0xc082c00000000000 => quad: fffffffffffffda8
+ FISTTP 0x3ff0000050000000 => word: 1
+ FISTTP 0xc082c00000000000 => word: fda8
+ FISTTP 0x3ff0000050000000 => long: 1
+ FISTTP 0xc082c00000000000 => long: fffffda8
+ FISTTP 0x3ff0000050000000 => quad: 1
+ FISTTP 0xc082c00000000000 => quad: fffffffffffffda8
+Rounding 1
+ FRNDINT 0x3ff0000050000000 => 0x3ff0000000000000
+ FRNDINT 0xc082c00000000000 => 0xc082c00000000000
+ FISTP 0x3ff0000050000000 => word: 1
+ FISTP 0xc082c00000000000 => word: fda8
+ FISTP 0x3ff0000050000000 => long: 1
+ FISTP 0xc082c00000000000 => long: fffffda8
+ FISTP 0x3ff0000050000000 => quad: 1
+ FISTP 0xc082c00000000000 => quad: fffffffffffffda8
+ FISTTP 0x3ff0000050000000 => word: 1
+ FISTTP 0xc082c00000000000 => word: fda8
+ FISTTP 0x3ff0000050000000 => long: 1
+ FISTTP 0xc082c00000000000 => long: fffffda8
+ FISTTP 0x3ff0000050000000 => quad: 1
+ FISTTP 0xc082c00000000000 => quad: fffffffffffffda8
+Rounding 2
+ FRNDINT 0x3ff0000050000000 => 0x4000000000000000
+ FRNDINT 0xc082c00000000000 => 0xc082c00000000000
+ FISTP 0x3ff0000050000000 => word: 2
+ FISTP 0xc082c00000000000 => word: fda8
+ FISTP 0x3ff0000050000000 => long: 2
+ FISTP 0xc082c00000000000 => long: fffffda8
+ FISTP 0x3ff0000050000000 => quad: 2
+ FISTP 0xc082c00000000000 => quad: fffffffffffffda8
+ FISTTP 0x3ff0000050000000 => word: 1
+ FISTTP 0xc082c00000000000 => word: fda8
+ FISTTP 0x3ff0000050000000 => long: 1
+ FISTTP 0xc082c00000000000 => long: fffffda8
+ FISTTP 0x3ff0000050000000 => quad: 1
+ FISTTP 0xc082c00000000000 => quad: fffffffffffffda8
FUCOMI 0xc082c00000000000 0x3ff0000050000000 --C
FUCOMPP 0xc082c00000000000 0x3ff0000050000000 --C
-FRNDINT 0xc082c00000000000 => 0xc082c00000000000
-FRNDINT 0x3ff0000050000000 => 0x3ff0000000000000
-FISTP 0xc082c00000000000 => word: fda8
-FISTP 0x3ff0000050000000 => word: 1
-FISTP 0xc082c00000000000 => long: fffffda8
-FISTP 0x3ff0000050000000 => long: 1
-FISTP 0xc082c00000000000 => quad: fffffffffffffda8
-FISTP 0x3ff0000050000000 => quad: 1
+Rounding 0
+ FRNDINT 0xc082c00000000000 => 0xc082c00000000000
+ FRNDINT 0x3ff0000050000000 => 0x3ff0000000000000
+ FISTP 0xc082c00000000000 => word: fda8
+ FISTP 0x3ff0000050000000 => word: 1
+ FISTP 0xc082c00000000000 => long: fffffda8
+ FISTP 0x3ff0000050000000 => long: 1
+ FISTP 0xc082c00000000000 => quad: fffffffffffffda8
+ FISTP 0x3ff0000050000000 => quad: 1
+ FISTTP 0xc082c00000000000 => word: fda8
+ FISTTP 0x3ff0000050000000 => word: 1
+ FISTTP 0xc082c00000000000 => long: fffffda8
+ FISTTP 0x3ff0000050000000 => long: 1
+ FISTTP 0xc082c00000000000 => quad: fffffffffffffda8
+ FISTTP 0x3ff0000050000000 => quad: 1
+Rounding 1
+ FRNDINT 0xc082c00000000000 => 0xc082c00000000000
+ FRNDINT 0x3ff0000050000000 => 0x3ff0000000000000
+ FISTP 0xc082c00000000000 => word: fda8
+ FISTP 0x3ff0000050000000 => word: 1
+ FISTP 0xc082c00000000000 => long: fffffda8
+ FISTP 0x3ff0000050000000 => long: 1
+ FISTP 0xc082c00000000000 => quad: fffffffffffffda8
+ FISTP 0x3ff0000050000000 => quad: 1
+ FISTTP 0xc082c00000000000 => word: fda8
+ FISTTP 0x3ff0000050000000 => word: 1
+ FISTTP 0xc082c00000000000 => long: fffffda8
+ FISTTP 0x3ff0000050000000 => long: 1
+ FISTTP 0xc082c00000000000 => quad: fffffffffffffda8
+ FISTTP 0x3ff0000050000000 => quad: 1
+Rounding 2
+ FRNDINT 0xc082c00000000000 => 0xc082c00000000000
+ FRNDINT 0x3ff0000050000000 => 0x4000000000000000
+ FISTP 0xc082c00000000000 => word: fda8
+ FISTP 0x3ff0000050000000 => word: 2
+ FISTP 0xc082c00000000000 => long: fffffda8
+ FISTP 0x3ff0000050000000 => long: 2
+ FISTP 0xc082c00000000000 => quad: fffffffffffffda8
+ FISTP 0x3ff0000050000000 => quad: 2
+ FISTTP 0xc082c00000000000 => word: fda8
+ FISTTP 0x3ff0000050000000 => word: 1
+ FISTTP 0xc082c00000000000 => long: fffffda8
+ FISTTP 0x3ff0000050000000 => long: 1
+ FISTTP 0xc082c00000000000 => quad: fffffffffffffda8
+ FISTTP 0x3ff0000050000000 => quad: 1
FUCOMI 0x0 0x7ff8000000000001 ZPC
FUCOMPP 0x0 0x7ff8000000000001 ZPC
-FRNDINT 0x0 => 0x0
-FRNDINT 0x7ff8000000000001 => 0x7ff8000000000001
-FISTP 0x0 => word: 0
-FISTP 0x7ff8000000000001 => word: 8000
-FISTP 0x0 => long: 0
-FISTP 0x7ff8000000000001 => long: 80000000
-FISTP 0x0 => quad: 0
-FISTP 0x7ff8000000000001 => quad: 8000000000000000
+Rounding 0
+ FRNDINT 0x0 => 0x0
+ FRNDINT 0x7ff8000000000001 => 0x7ff8000000000001
+ FISTP 0x0 => word: 0
+ FISTP 0x7ff8000000000001 => word: 8000
+ FISTP 0x0 => long: 0
+ FISTP 0x7ff8000000000001 => long: 80000000
+ FISTP 0x0 => quad: 0
+ FISTP 0x7ff8000000000001 => quad: 8000000000000000
+ FISTTP 0x0 => word: 0
+ FISTTP 0x7ff8000000000001 => word: 8000
+ FISTTP 0x0 => long: 0
+ FISTTP 0x7ff8000000000001 => long: 80000000
+ FISTTP 0x0 => quad: 0
+ FISTTP 0x7ff8000000000001 => quad: 8000000000000000
+Rounding 1
+ FRNDINT 0x0 => 0x0
+ FRNDINT 0x7ff8000000000001 => 0x7ff8000000000001
+ FISTP 0x0 => word: 0
+ FISTP 0x7ff8000000000001 => word: 8000
+ FISTP 0x0 => long: 0
+ FISTP 0x7ff8000000000001 => long: 80000000
+ FISTP 0x0 => quad: 0
+ FISTP 0x7ff8000000000001 => quad: 8000000000000000
+ FISTTP 0x0 => word: 0
+ FISTTP 0x7ff8000000000001 => word: 8000
+ FISTTP 0x0 => long: 0
+ FISTTP 0x7ff8000000000001 => long: 80000000
+ FISTTP 0x0 => quad: 0
+ FISTTP 0x7ff8000000000001 => quad: 8000000000000000
+Rounding 2
+ FRNDINT 0x0 => 0x0
+ FRNDINT 0x7ff8000000000001 => 0x7ff8000000000001
+ FISTP 0x0 => word: 0
+ FISTP 0x7ff8000000000001 => word: 8000
+ FISTP 0x0 => long: 0
+ FISTP 0x7ff8000000000001 => long: 80000000
+ FISTP 0x0 => quad: 0
+ FISTP 0x7ff8000000000001 => quad: 8000000000000000
+ FISTTP 0x0 => word: 0
+ FISTTP 0x7ff8000000000001 => word: 8000
+ FISTTP 0x0 => long: 0
+ FISTTP 0x7ff8000000000001 => long: 80000000
+ FISTTP 0x0 => quad: 0
+ FISTTP 0x7ff8000000000001 => quad: 8000000000000000
FUCOMI 0x7ff8000000000001 0x0 ZPC
FUCOMPP 0x7ff8000000000001 0x0 ZPC
-FRNDINT 0x7ff8000000000001 => 0x7ff8000000000001
-FRNDINT 0x0 => 0x0
-FISTP 0x7ff8000000000001 => word: 8000
-FISTP 0x0 => word: 0
-FISTP 0x7ff8000000000001 => long: 80000000
-FISTP 0x0 => long: 0
-FISTP 0x7ff8000000000001 => quad: 8000000000000000
-FISTP 0x0 => quad: 0
+Rounding 0
+ FRNDINT 0x7ff8000000000001 => 0x7ff8000000000001
+ FRNDINT 0x0 => 0x0
+ FISTP 0x7ff8000000000001 => word: 8000
+ FISTP 0x0 => word: 0
+ FISTP 0x7ff8000000000001 => long: 80000000
+ FISTP 0x0 => long: 0
+ FISTP 0x7ff8000000000001 => quad: 8000000000000000
+ FISTP 0x0 => quad: 0
+ FISTTP 0x7ff8000000000001 => word: 8000
+ FISTTP 0x0 => word: 0
+ FISTTP 0x7ff8000000000001 => long: 80000000
+ FISTTP 0x0 => long: 0
+ FISTTP 0x7ff8000000000001 => quad: 8000000000000000
+ FISTTP 0x0 => quad: 0
+Rounding 1
+ FRNDINT 0x7ff8000000000001 => 0x7ff8000000000001
+ FRNDINT 0x0 => 0x0
+ FISTP 0x7ff8000000000001 => word: 8000
+ FISTP 0x0 => word: 0
+ FISTP 0x7ff8000000000001 => long: 80000000
+ FISTP 0x0 => long: 0
+ FISTP 0x7ff8000000000001 => quad: 8000000000000000
+ FISTP 0x0 => quad: 0
+ FISTTP 0x7ff8000000000001 => word: 8000
+ FISTTP 0x0 => word: 0
+ FISTTP 0x7ff8000000000001 => long: 80000000
+ FISTTP 0x0 => long: 0
+ FISTTP 0x7ff8000000000001 => quad: 8000000000000000
+ FISTTP 0x0 => quad: 0
+Rounding 2
+ FRNDINT 0x7ff8000000000001 => 0x7ff8000000000001
+ FRNDINT 0x0 => 0x0
+ FISTP 0x7ff8000000000001 => word: 8000
+ FISTP 0x0 => word: 0
+ FISTP 0x7ff8000000000001 => long: 80000000
+ FISTP 0x0 => long: 0
+ FISTP 0x7ff8000000000001 => quad: 8000000000000000
+ FISTP 0x0 => quad: 0
+ FISTTP 0x7ff8000000000001 => word: 8000
+ FISTTP 0x0 => word: 0
+ FISTTP 0x7ff8000000000001 => long: 80000000
+ FISTTP 0x0 => long: 0
+ FISTTP 0x7ff8000000000001 => quad: 8000000000000000
+ FISTTP 0x0 => quad: 0
FUCOMI 0x7ff8000000000001 0x7ff8000000000001 ZPC
FUCOMPP 0x7ff8000000000001 0x7ff8000000000001 ZPC
-FRNDINT 0x7ff8000000000001 => 0x7ff8000000000001
-FRNDINT 0x7ff8000000000001 => 0x7ff8000000000001
-FISTP 0x7ff8000000000001 => word: 8000
-FISTP 0x7ff8000000000001 => word: 8000
-FISTP 0x7ff8000000000001 => long: 80000000
-FISTP 0x7ff8000000000001 => long: 80000000
-FISTP 0x7ff8000000000001 => quad: 8000000000000000
-FISTP 0x7ff8000000000001 => quad: 8000000000000000
+Rounding 0
+ FRNDINT 0x7ff8000000000001 => 0x7ff8000000000001
+ FRNDINT 0x7ff8000000000001 => 0x7ff8000000000001
+ FISTP 0x7ff8000000000001 => word: 8000
+ FISTP 0x7ff8000000000001 => word: 8000
+ FISTP 0x7ff8000000000001 => long: 80000000
+ FISTP 0x7ff8000000000001 => long: 80000000
+ FISTP 0x7ff8000000000001 => quad: 8000000000000000
+ FISTP 0x7ff8000000000001 => quad: 8000000000000000
+ FISTTP 0x7ff8000000000001 => word: 8000
+ FISTTP 0x7ff8000000000001 => word: 8000
+ FISTTP 0x7ff8000000000001 => long: 80000000
+ FISTTP 0x7ff8000000000001 => long: 80000000
+ FISTTP 0x7ff8000000000001 => quad: 8000000000000000
+ FISTTP 0x7ff8000000000001 => quad: 8000000000000000
+Rounding 1
+ FRNDINT 0x7ff8000000000001 => 0x7ff8000000000001
+ FRNDINT 0x7ff8000000000001 => 0x7ff8000000000001
+ FISTP 0x7ff8000000000001 => word: 8000
+ FISTP 0x7ff8000000000001 => word: 8000
+ FISTP 0x7ff8000000000001 => long: 80000000
+ FISTP 0x7ff8000000000001 => long: 80000000
+ FISTP 0x7ff8000000000001 => quad: 8000000000000000
+ FISTP 0x7ff8000000000001 => quad: 8000000000000000
+ FISTTP 0x7ff8000000000001 => word: 8000
+ FISTTP 0x7ff8000000000001 => word: 8000
+ FISTTP 0x7ff8000000000001 => long: 80000000
+ FISTTP 0x7ff8000000000001 => long: 80000000
+ FISTTP 0x7ff8000000000001 => quad: 8000000000000000
+ FISTTP 0x7ff8000000000001 => quad: 8000000000000000
+Rounding 2
+ FRNDINT 0x7ff8000000000001 => 0x7ff8000000000001
+ FRNDINT 0x7ff8000000000001 => 0x7ff8000000000001
+ FISTP 0x7ff8000000000001 => word: 8000
+ FISTP 0x7ff8000000000001 => word: 8000
+ FISTP 0x7ff8000000000001 => long: 80000000
+ FISTP 0x7ff8000000000001 => long: 80000000
+ FISTP 0x7ff8000000000001 => quad: 8000000000000000
+ FISTP 0x7ff8000000000001 => quad: 8000000000000000
+ FISTTP 0x7ff8000000000001 => word: 8000
+ FISTTP 0x7ff8000000000001 => word: 8000
+ FISTTP 0x7ff8000000000001 => long: 80000000
+ FISTTP 0x7ff8000000000001 => long: 80000000
+ FISTTP 0x7ff8000000000001 => quad: 8000000000000000
+ FISTTP 0x7ff8000000000001 => quad: 8000000000000000
FUCOMI 0x7ff8000000000001 0x7ff8000000000001 ZPC
FUCOMPP 0x7ff8000000000001 0x7ff8000000000001 ZPC
-FRNDINT 0x7ff8000000000001 => 0x7ff8000000000001
-FRNDINT 0x7ff8000000000001 => 0x7ff8000000000001
-FISTP 0x7ff8000000000001 => word: 8000
-FISTP 0x7ff8000000000001 => word: 8000
-FISTP 0x7ff8000000000001 => long: 80000000
-FISTP 0x7ff8000000000001 => long: 80000000
-FISTP 0x7ff8000000000001 => quad: 8000000000000000
-FISTP 0x7ff8000000000001 => quad: 8000000000000000
+Rounding 0
+ FRNDINT 0x7ff8000000000001 => 0x7ff8000000000001
+ FRNDINT 0x7ff8000000000001 => 0x7ff8000000000001
+ FISTP 0x7ff8000000000001 => word: 8000
+ FISTP 0x7ff8000000000001 => word: 8000
+ FISTP 0x7ff8000000000001 => long: 80000000
+ FISTP 0x7ff8000000000001 => long: 80000000
+ FISTP 0x7ff8000000000001 => quad: 8000000000000000
+ FISTP 0x7ff8000000000001 => quad: 8000000000000000
+ FISTTP 0x7ff8000000000001 => word: 8000
+ FISTTP 0x7ff8000000000001 => word: 8000
+ FISTTP 0x7ff8000000000001 => long: 80000000
+ FISTTP 0x7ff8000000000001 => long: 80000000
+ FISTTP 0x7ff8000000000001 => quad: 8000000000000000
+ FISTTP 0x7ff8000000000001 => quad: 8000000000000000
+Rounding 1
+ FRNDINT 0x7ff8000000000001 => 0x7ff8000000000001
+ FRNDINT 0x7ff8000000000001 => 0x7ff8000000000001
+ FISTP 0x7ff8000000000001 => word: 8000
+ FISTP 0x7ff8000000000001 => word: 8000
+ FISTP 0x7ff8000000000001 => long: 80000000
+ FISTP 0x7ff8000000000001 => long: 80000000
+ FISTP 0x7ff8000000000001 => quad: 8000000000000000
+ FISTP 0x7ff8000000000001 => quad: 8000000000000000
+ FISTTP 0x7ff8000000000001 => word: 8000
+ FISTTP 0x7ff8000000000001 => word: 8000
+ FISTTP 0x7ff8000000000001 => long: 80000000
+ FISTTP 0x7ff8000000000001 => long: 80000000
+ FISTTP 0x7ff8000000000001 => quad: 8000000000000000
+ FISTTP 0x7ff8000000000001 => quad: 8000000000000000
+Rounding 2
+ FRNDINT 0x7ff8000000000001 => 0x7ff8000000000001
+ FRNDINT 0x7ff8000000000001 => 0x7ff8000000000001
+ FISTP 0x7ff8000000000001 => word: 8000
+ FISTP 0x7ff8000000000001 => word: 8000
+ FISTP 0x7ff8000000000001 => long: 80000000
+ FISTP 0x7ff8000000000001 => long: 80000000
+ FISTP 0x7ff8000000000001 => quad: 8000000000000000
+ FISTP 0x7ff8000000000001 => quad: 8000000000000000
+ FISTTP 0x7ff8000000000001 => word: 8000
+ FISTTP 0x7ff8000000000001 => word: 8000
+ FISTTP 0x7ff8000000000001 => long: 80000000
+ FISTTP 0x7ff8000000000001 => long: 80000000
+ FISTTP 0x7ff8000000000001 => quad: 8000000000000000
+ FISTTP 0x7ff8000000000001 => quad: 8000000000000000
Done
diff --git a/tests/test05.c b/tests/test05.c
index c6a4e67..c6a4e67 100755..100644
--- a/tests/test05.c
+++ b/tests/test05.c
diff --git a/tests/test08.c b/tests/test08.c
index f5f5bce..f5f5bce 100755..100644
--- a/tests/test08.c
+++ b/tests/test08.c
diff --git a/tests/test09.c b/tests/test09.c
index e4a5605..dadff21 100755..100644
--- a/tests/test09.c
+++ b/tests/test09.c
@@ -1,5 +1,6 @@
#include <stdio.h>
-#include <sys/types.h>
+#include <sys/types.h>
+#include <sys/wait.h>
#include <unistd.h>
void forkexample()
@@ -9,7 +10,7 @@ void forkexample()
if (fork() == 0)
printf("Child has x = %d\n", ++x);
else {
- usleep(20000);
+ wait(NULL);
printf("Parent has x = %d\n", --x);
}
}
@@ -17,4 +18,4 @@ int main()
{
forkexample();
return 0;
-} \ No newline at end of file
+}
diff --git a/tests/test12.c b/tests/test12.c
index 4892a10..4892a10 100755..100644
--- a/tests/test12.c
+++ b/tests/test12.c
diff --git a/tests/test14.c b/tests/test14.c
index 65702be..65702be 100755..100644
--- a/tests/test14.c
+++ b/tests/test14.c
diff --git a/tests/test17.c b/tests/test17.c
index 385b624..632d13c 100644
--- a/tests/test17.c
+++ b/tests/test17.c
@@ -1,5 +1,6 @@
-// build with gcc -march=corei7 -O2 -g -msse -msse2 test17.c -o test17
+// build with gcc -O0 -g -msse -msse2 -mssse3 -msse4.1 test17.c -o test17
// and -m32 for 32bits version
+#include <inttypes.h>
#include <string.h>
#include <stdio.h>
#include <stddef.h>
@@ -141,7 +142,7 @@ void print_32(v128 v) {
}
void print_64(v128 v) {
for(int i=0; i<2; ++i)
- printf("0x%llx ", v.u64[i]);
+ printf("0x%"PRIx64" ", v.u64[i]);
}
#define print_128 print_64
void print_ps(v128 v) {
@@ -154,7 +155,7 @@ void print_ps(v128 v) {
void print_pd(v128 v) {
for(int i=0; i<2; ++i)
if(isnan(v.d64[i]))
- printf("0x%llx ", v.u64[i]);
+ printf("0x%"PRIx64" ", v.u64[i]);
else
printf("%g ", v.d64[i]);
}
@@ -163,7 +164,7 @@ void print_pd(v128 v) {
int main(int argc, const char** argv)
{
float a, b;
- uint64_t flags;
+ uint32_t flags;
uint32_t maxf = 0x7f7fffff;
uint32_t minf = 0xff7fffff;
uint32_t r;
@@ -171,40 +172,40 @@ int main(int argc, const char** argv)
#define GO1(A, N) \
a = 1.0f; b = 2.0f; \
flags = A(a, b); \
-printf(N " %f, %f => 0x%lx\n", a, b, flags); \
+printf(N " %f, %f => 0x%"PRIx32"\n", a, b, flags); \
flags = A(b, a); \
-printf(N " %f, %f => 0x%lx\n", b, a, flags); \
+printf(N " %f, %f => 0x%"PRIx32"\n", b, a, flags); \
b = INFINITY; \
flags = A(a, b); \
-printf(N " %f, %f => 0x%lx\n", a, b, flags); \
+printf(N " %f, %f => 0x%"PRIx32"\n", a, b, flags); \
flags = A(b, a); \
-printf(N " %f, %f => 0x%lx\n", b, a, flags); \
+printf(N " %f, %f => 0x%"PRIx32"\n", b, a, flags); \
b = -INFINITY; \
flags = A(a, b); \
-printf(N " %f, %f => 0x%lx\n", a, b, flags); \
+printf(N " %f, %f => 0x%"PRIx32"\n", a, b, flags); \
flags = A(b, a); \
-printf(N " %f, %f => 0x%lx\n", b, a, flags); \
+printf(N " %f, %f => 0x%"PRIx32"\n", b, a, flags); \
b = NAN; \
flags = A(a, b); \
-printf(N " %f, %f => 0x%lx\n", a, b, flags); \
+printf(N " %f, %f => 0x%"PRIx32"\n", a, b, flags); \
flags = A(b, a); \
-printf(N " %f, %f => 0x%lx\n", b, a, flags); \
+printf(N " %f, %f => 0x%"PRIx32"\n", b, a, flags); \
b = a; \
flags = A(a, b); \
-printf(N " %f, %f => 0x%lx\n", a, b, flags); \
+printf(N " %f, %f => 0x%"PRIx32"\n", a, b, flags); \
flags = A(b, a); \
-printf(N " %f, %f => 0x%lx\n", b, a, flags); \
+printf(N " %f, %f => 0x%"PRIx32"\n", b, a, flags); \
a = b = INFINITY; \
flags = A(a, b); \
-printf(N " %f, %f => 0x%lx\n", a, b, flags); \
+printf(N " %f, %f => 0x%"PRIx32"\n", a, b, flags); \
a = -INFINITY; \
flags = A(a, b); \
-printf(N " %f, %f => 0x%lx\n", a, b, flags); \
+printf(N " %f, %f => 0x%"PRIx32"\n", a, b, flags); \
flags = A(b, a); \
-printf(N " %f, %f => 0x%lx\n", b, a, flags); \
+printf(N " %f, %f => 0x%"PRIx32"\n", b, a, flags); \
a = b = NAN; \
flags = A(a, b); \
-printf(N " %f, %f => 0x%lx\n", a, b, flags);
+printf(N " %f, %f => 0x%"PRIx32"\n", a, b, flags);
#define GO2(A, N) \
a = 1.0f; b = 2.0f; \
@@ -353,6 +354,10 @@ printf(N " %g, %g => %g\n", b, a, *(float*)&r);
printf("%s(", #C); print_ps(A1); \
printf(", "); print_ps(A2); \
printf(", %d) = ", I); print_ps(a128); printf("\n");
+ #define GO1ps2dq(A, C, A1) \
+ a128.mm = _mm_##A##_epi32(A1.mf); \
+ printf("%s(", #C); print_ps(A1); \
+ printf(") = "); print_32(a128); printf("\n");
#define MULITGO2pd(A, B) \
GO2pd(A, B, a128_pd, b128_pd) \
@@ -378,6 +383,12 @@ printf(N " %g, %g => %g\n", b, a, *(float*)&r);
GO2ps(A, B, c128_ps, d128_ps) \
GO2ps(A, B, d128_ps, d128_ps)
+ #define MULTIGO1ps2dq(A, B) \
+ GO1ps2dq(A, B, a128_ps) \
+ GO1ps2dq(A, B, b128_ps) \
+ GO1ps2dq(A, B, c128_ps) \
+ GO1ps2dq(A, B, d128_ps)
+
#define MULITGO2Cps(A, B, I) \
GO2Cps(A, B, a128_ps, b128_ps, I) \
GO2Cps(A, B, b128_ps, c128_ps, I) \
@@ -577,7 +588,7 @@ printf(N " %g, %g => %g\n", b, a, *(float*)&r);
MULITGO2ps(min, minps)
MULITGO2ps(div, divps)
MULITGO2ps(max, maxps)
-// MULITGO2Cps(cmp, cmpps, 0) // use avx for some reason
+ //MULITGO2Cps(cmp, cmpps, 0) // use avx for some reason
MULITGO2Cps(shuffle, shufps, 0)
MULITGO2Cps(shuffle, shufps, 0x15)
MULITGO2Cps(shuffle, shufps, 0xff)
@@ -589,6 +600,7 @@ printf(N " %g, %g => %g\n", b, a, *(float*)&r);
MULTIGO2sd(min, minsd)
MULTIGO2sd(div, divsd)
MULTIGO2sd(max, maxsd)
+ MULTIGO1ps2dq(cvtps, cvtps2pd)
return 0;
}
diff --git a/tests/test18.c b/tests/test18.c
index 395c2ef..4ed5591 100644
--- a/tests/test18.c
+++ b/tests/test18.c
@@ -1,3 +1,4 @@
+// build with gcc -march=corei7 -O2 -g -maes -mpclmul test18.c -o test18
#include <stdio.h>
#include <stdint.h>
#include <wmmintrin.h>
diff --git a/tests/test22.c b/tests/test22.c
index 68bd41c..da0d05f 100644
--- a/tests/test22.c
+++ b/tests/test22.c
@@ -5,6 +5,8 @@
#include <stdint.h>
#include <math.h>
+// Build with `gcc -march=core2 -mfpmath=387 -O2 test22.c -o test22`
+
#if defined(__x86_64__)
uint64_t _fucomip_(double a, double b)
{
@@ -30,7 +32,7 @@ uint64_t _fucompp_(double a, double b)
:"=a" (ret):"m"(a), "m"(b):"cc");
return ret;
}
-uint64_t _fistpw_(double a)
+uint64_t _fistpw_(double a, uint8_t rd)
{
uint16_t ret;
uint16_t t1, t2;
@@ -38,15 +40,31 @@ uint64_t _fistpw_(double a)
"fldl %1\n"
"fstcw %2\n"
"mov %2, %%ax\n"
- "mov $0x0c, %%ah\n"
+ "mov %4, %%ah\n"
"mov %%ax, %3\n"
"fldcw %3\n"
"fistp %0\n"
"fldcw %2\n"
- :"=m" (ret):"m"(a), "m"(t1), "m"(t2):"cc");
+ :"=m" (ret):"m"(a), "m"(t1), "m"(t2), "m"(rd):"cc");
return ret;
}
-uint64_t _fistpl_(double a)
+uint64_t _fisttpw_(double a, uint8_t rd)
+{
+ uint16_t ret;
+ uint16_t t1, t2;
+ asm volatile (
+ "fldl %1\n"
+ "fstcw %2\n"
+ "mov %2, %%ax\n"
+ "mov %4, %%ah\n"
+ "mov %%ax, %3\n"
+ "fldcw %3\n"
+ "fisttp %0\n"
+ "fldcw %2\n"
+ :"=m" (ret):"m"(a), "m"(t1), "m"(t2), "m"(rd):"cc");
+ return ret;
+}
+uint64_t _fistpl_(double a, uint8_t rd)
{
uint32_t ret;
uint16_t t1, t2;
@@ -54,15 +72,31 @@ uint64_t _fistpl_(double a)
"fldl %1\n"
"fstcw %2\n"
"mov %2, %%ax\n"
- "mov $0x0c, %%ah\n"
+ "mov %4, %%ah\n"
"mov %%ax, %3\n"
"fldcw %3\n"
"fistpl %0\n"
"fldcw %2\n"
- :"=m" (ret):"m"(a), "m"(t1), "m"(t2):"cc");
+ :"=m" (ret):"m"(a), "m"(t1), "m"(t2), "m"(rd):"cc");
return ret;
}
-uint64_t _fistpq_(double a)
+uint64_t _fisttpl_(double a, uint8_t rd)
+{
+ uint32_t ret;
+ uint16_t t1, t2;
+ asm volatile (
+ "fldl %1\n"
+ "fstcw %2\n"
+ "mov %2, %%ax\n"
+ "mov %4, %%ah\n"
+ "mov %%ax, %3\n"
+ "fldcw %3\n"
+ "fisttpl %0\n"
+ "fldcw %2\n"
+ :"=m" (ret):"m"(a), "m"(t1), "m"(t2), "m"(rd):"cc");
+ return ret;
+}
+uint64_t _fistpq_(double a, uint8_t rd)
{
uint64_t ret;
uint16_t t1, t2;
@@ -70,15 +104,31 @@ uint64_t _fistpq_(double a)
"fldl %1\n"
"fstcw %2\n"
"mov %2, %%ax\n"
- "mov $0x0c, %%ah\n"
+ "mov %4, %%ah\n"
"mov %%ax, %3\n"
"fldcw %3\n"
"fistpq %0\n"
"fldcw %2\n"
- :"=m" (ret):"m"(a), "m"(t1), "m"(t2):"cc");
+ :"=m" (ret):"m"(a), "m"(t1), "m"(t2), "m"(rd):"cc");
+ return ret;
+}
+uint64_t _fisttpq_(double a, uint8_t rd)
+{
+ uint64_t ret;
+ uint16_t t1, t2;
+ asm volatile (
+ "fldl %1\n"
+ "fstcw %2\n"
+ "mov %2, %%ax\n"
+ "mov %4, %%ah\n"
+ "mov %%ax, %3\n"
+ "fldcw %3\n"
+ "fisttpq %0\n"
+ "fldcw %2\n"
+ :"=m" (ret):"m"(a), "m"(t1), "m"(t2), "m"(rd):"cc");
return ret;
}
-uint64_t _frndint_(double a)
+uint64_t _frndint_(double a, uint8_t rd)
{
uint64_t ret;
uint16_t t1, t2;
@@ -86,13 +136,13 @@ uint64_t _frndint_(double a)
"fldl %1\n"
"fstcw %2\n"
"mov %2, %%ax\n"
- "mov $0x0c, %%ah\n"
+ "mov %4, %%ah\n"
"mov %%ax, %3\n"
"fldcw %3\n"
"frndint\n"
"fstpl %0\n"
"fldcw %2\n"
- :"=m" (ret):"m"(a), "m"(t1), "m"(t2):"cc");
+ :"=m" (ret):"m"(a), "m"(t1), "m"(t2), "m"(rd):"cc");
return ret;
}
#endif
@@ -107,6 +157,8 @@ int main(int argc, const char** argv)
{0x0, 0x4082c00000000000LL},
{0x8000000000000000LL, 0x4082c00000000000LL},
{0x8000000000000000LL, 0x0},
+ {0x40dfffc000000000LL, 0x40e0002000000000LL}, // 0x7fff and 0x8001 as double
+ {0xc0e0002000000000LL, 0xc0dfffc000000000LL}, // -0x8001 and -0x7fff as double
{0x8000000000000000LL, 0x3ff0000000000000LL},
{0x3ff0000000000000LL, 0x3fe89d9000000000LL},
{0x3ff0000000000000LL, 0x7ff0000000000000LL},
@@ -133,14 +185,23 @@ int main(int argc, const char** argv)
za = (flags>>(8+6))&1?'Z':'-';
pa = (flags>>(8+2))&1?'P':'-';
printf("%c%c%c\n", za, pa, ca);
- printf("FRNDINT 0x%llx => 0x%llx\n", *(uint64_t*)&a, _frndint_(a));
- printf("FRNDINT 0x%llx => 0x%llx\n", *(uint64_t*)&b, _frndint_(b));
- printf("FISTP 0x%llx => word: %x\n", *(uint64_t*)&a, _fistpw_(a));
- printf("FISTP 0x%llx => word: %x\n", *(uint64_t*)&b, _fistpw_(b));
- printf("FISTP 0x%llx => long: %x\n", *(uint64_t*)&a, _fistpl_(a));
- printf("FISTP 0x%llx => long: %x\n", *(uint64_t*)&b, _fistpl_(b));
- printf("FISTP 0x%llx => quad: %llx\n", *(uint64_t*)&a, _fistpq_(a));
- printf("FISTP 0x%llx => quad: %llx\n", *(uint64_t*)&b, _fistpq_(b));
+ for(int rd=0; rd<3; ++rd) {
+ printf("Rounding %d\n", rd);
+ printf(" FRNDINT 0x%llx => 0x%llx\n", *(uint64_t*)&a, _frndint_(a, rd<<2));
+ printf(" FRNDINT 0x%llx => 0x%llx\n", *(uint64_t*)&b, _frndint_(b, rd<<2));
+ printf(" FISTP 0x%llx => word: %x\n", *(uint64_t*)&a, _fistpw_(a, rd<<2));
+ printf(" FISTP 0x%llx => word: %x\n", *(uint64_t*)&b, _fistpw_(b, rd<<2));
+ printf(" FISTP 0x%llx => long: %x\n", *(uint64_t*)&a, _fistpl_(a, rd<<2));
+ printf(" FISTP 0x%llx => long: %x\n", *(uint64_t*)&b, _fistpl_(b, rd<<2));
+ printf(" FISTP 0x%llx => quad: %llx\n", *(uint64_t*)&a, _fistpq_(a, rd<<2));
+ printf(" FISTP 0x%llx => quad: %llx\n", *(uint64_t*)&b, _fistpq_(b, rd<<2));
+ printf(" FISTTP 0x%llx => word: %x\n", *(uint64_t*)&a, _fisttpw_(a, rd<<2));
+ printf(" FISTTP 0x%llx => word: %x\n", *(uint64_t*)&b, _fisttpw_(b, rd<<2));
+ printf(" FISTTP 0x%llx => long: %x\n", *(uint64_t*)&a, _fisttpl_(a, rd<<2));
+ printf(" FISTTP 0x%llx => long: %x\n", *(uint64_t*)&b, _fisttpl_(b, rd<<2));
+ printf(" FISTTP 0x%llx => quad: %llx\n", *(uint64_t*)&a, _fisttpq_(a, rd<<2));
+ printf(" FISTTP 0x%llx => quad: %llx\n", *(uint64_t*)&b, _fisttpq_(b, rd<<2));
+ }
}
printf("\nDone\n");
}
diff --git a/wrapperhelper/CMakeLists.txt b/wrapperhelper/CMakeLists.txt
new file mode 100644
index 0000000..3ab9cf1
--- /dev/null
+++ b/wrapperhelper/CMakeLists.txt
@@ -0,0 +1,7 @@
+cmake_minimum_required(VERSION 3.10)
+project("helper")
+find_package(Clang REQUIRED CONFIG)
+
+add_executable(helper main.cpp gen.cpp)
+target_include_directories(helper SYSTEM PUBLIC ${CLANG_INCLUDE_DIRS})
+target_link_libraries(helper PUBLIC clang-cpp LLVM)
diff --git a/wrapperhelper/README.md b/wrapperhelper/README.md
new file mode 100644
index 0000000..1edd4db
--- /dev/null
+++ b/wrapperhelper/README.md
@@ -0,0 +1,99 @@
+# Wrapper helper
+
+**WARNING: There are still many problems with this tool. Please do NOT submit code generated directly by the tool, you should only use it as a preliminary reference.**
+
+
+This tool is based on libclangtooling.
+
+It parses the AST of the library header files, generating the required structures of the wrapping library, including:
+- structure definitions,
+- export function signatures,
+- callback function wrapping,
+etc. Of course, this cannot completely automate everything, it can only be used as a reference.
+
+At the same time, this tool is also quite rough, and may even have errors.
+
+## Build
+
+```
+sudo apt install libclang-14-dev
+cd wrapperhelper
+mkdir build; cd build; cmake ..
+make
+```
+
+## Usage:
+
+ helper <filename> <libname> [guest_triple] [host_triple] -- <clang_flags>
+ <filename> : set the header file to be parsed
+ <libname> : set libname required for wrapping func
+ [guest_triple]: set guest triple: can be arm32/arm64/x86/x64, default is x64
+ [host_triple] : set host triple: can be arm32/arm64/x86/x64, default is arm64
+ -- : mandatory
+ <clang_flags> : extra compiler flags
+
+### Usage example:
+
+`./helper /usr/include/jpeglib.h libjpeg x64 arm64 -- -I /usr/lib/gcc/x86_*/12.2.0/include --include /usr/lib/gcc/x86_*/12.2.0/include/stddef.h --include /usr/include/stdio.h`
+
+You would see an output similar to the files `src/wrapped/wrappedlibjpeg.c` and `src/wrapped/wrappedlibjpeg_private.h`, should they exist.
+
+If there are multiple header files to process, write them into a custom header file as input.
+
+### Output sample
+
+Using the command above, we get the following (trimmed) files:
+
+In `wrappedlibjpeg_private.h`:
+```c
+...
+GO(jpeg_quality_scaling, iFi)
+...
+GOM(jpeg_destroy, vFEp)
+...
+```
+
+In `wrappedlibjpeg.c`:
+```c
+...
+typedef struct jpeg_source_mgr {
+ void *next_input_byte;
+ unsigned long bytes_in_buffer;
+ vFp_t init_source;
+ iFp_t fill_input_buffer;
+ vFpI_t skip_input_data;
+ iFpi_t resync_to_restart;
+ vFp_t term_source;
+} jpeg_source_mgr, *jpeg_source_mgr_ptr;
+...
+#define GO(A) \
+static uintptr_t my_term_source_fct_##A = 0; \
+void my_term_source_##A(struct jpeg_decompress_struct * a0) { \
+ return RunFunction(my_context, my_term_source_fct_##A, 1, a0); \
+}
+SUPER()
+#undef GO
+static void* findterm_sourceFct(void* fct) {
+ if(!fct) return fct;
+ if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
+ #define GO(A) if(my_term_source_fct_##A == (uintptr_t)fct) return my_term_source_##A;}
+ SUPER()
+ #undef GO
+ #define GO(A) if(my_term_source_fct_##A == 0) {my_term_source_fct_##A = (uintptr_t)fct;return my_term_source_##A;}
+ SUPER()
+ #undef GO
+ return NULL;
+}
+...
+EXPORT int my_jpeg_quality_scaling(void *emu, int quality) {
+ libjpeg_my_t *my = (libjpeg_my_t*)my_lib->priv.w.p2;
+ my->jpeg_quality_scaling(quality);
+}
+...
+EXPORT void my_jpeg_destroy(void *emu, struct jpeg_common_struct * cinfo) {
+ // WARN: This function's arg has a structure ptr which is special, may need to wrap it for the host
+ libjpeg_my_t *my = (libjpeg_my_t*)my_lib->priv.w.p2;
+ my->jpeg_destroy(cinfo);
+}
+...
+```
diff --git a/wrapperhelper/ast.h b/wrapperhelper/ast.h
new file mode 100644
index 0000000..2746d98
--- /dev/null
+++ b/wrapperhelper/ast.h
@@ -0,0 +1,189 @@
+#pragma once
+#include <clang/AST/ASTConsumer.h>
+#include <clang/AST/Attr.h>
+#include <clang/AST/Decl.h>
+#include <clang/AST/Type.h>
+#include <clang/Tooling/Tooling.h>
+#include <clang/Tooling/CompilationDatabase.h>
+#include <clang/AST/RecursiveASTVisitor.h>
+#include <clang/Frontend/FrontendAction.h>
+#include <clang/Frontend/CompilerInstance.h>
+#include <clang/Tooling/CommonOptionsParser.h>
+
+#include <ios>
+#include <llvm/Support/Casting.h>
+
+#include <cstddef>
+#include <fstream>
+#include <memory>
+#include <string>
+#include <iostream>
+#include <vector>
+#include <cstring>
+#include <map>
+
+#include "gen.h"
+#include "utils.h"
+
+static void ParseParameter(clang::ASTContext* AST, WrapperGenerator* Gen, clang::QualType ParmType, FuncInfo* Func) {
+ using namespace clang;
+ (void)AST; (void)Func;
+ if (ParmType->isFunctionPointerType()) {
+ auto ProtoType = ParmType->getPointeeType()->getAs<FunctionProtoType>();
+ for (unsigned i = 0; i < ProtoType->getNumParams(); i++) {
+ ParseParameter(AST, Gen, ProtoType->getParamType(i), Func);
+ }
+ } else if (ParmType->isPointerType()) {
+ auto PointeeType = ParmType->getPointeeType();
+ if (PointeeType->isRecordType()) {
+ if (Gen->records.find(StripTypedef(PointeeType)) == Gen->records.end()) {
+ auto Record = &Gen->records[StripTypedef(PointeeType)];
+ if (PointeeType->isUnionType()) {
+ Record->is_union = true;
+ }
+ Record->type = StripTypedef(PointeeType);
+ Record->decl = PointeeType->getAs<RecordType>()->getDecl();
+ Record->type_name = Record->decl->getIdentifier() ? Record->decl->getIdentifier()->getName().str() : "<null identifier>";
+ }
+ } else if (PointeeType->isPointerType()) {
+ PointeeType = PointeeType->getPointeeType();
+ if (PointeeType->isRecordType()) {
+ if (Gen->records.find(StripTypedef(PointeeType)) == Gen->records.end()) {
+ auto Record = &Gen->records[StripTypedef(PointeeType)];
+ if (PointeeType->isUnionType()) {
+ Record->is_union = true;
+ }
+
+ Record->type = StripTypedef(PointeeType);
+ Record->decl = PointeeType->getAs<RecordType>()->getDecl();
+ Record->type_name = Record->decl->getIdentifier() ? Record->decl->getIdentifier()->getName().str() : "<null identifier>";
+ }
+ }
+ }
+ } else if (ParmType->isRecordType()) {
+ if (Gen->records.find(StripTypedef(ParmType)) == Gen->records.end()) {
+ auto Record = &Gen->records[StripTypedef(ParmType)];
+ if (ParmType->isUnionType()) {
+ Record->is_union = true;
+ }
+ Record->type = StripTypedef(ParmType);
+ Record->decl = ParmType->getAs<RecordType>()->getDecl();
+ Record->type_name = Record->decl->getIdentifier() ? Record->decl->getIdentifier()->getName().str() : "<null identifier>";
+ }
+ }
+}
+
+static void ParseFunction(clang::ASTContext* AST, WrapperGenerator* Gen, clang::FunctionDecl* Decl) {
+ using namespace clang;
+ auto Type = Decl->getType().getTypePtr();
+ auto FuncInfo = &Gen->funcs[Type];
+ FuncInfo->type = Type;
+ FuncInfo->func_name = Decl->getNameAsString();
+ FuncInfo->decl = Decl;
+ FuncInfo->callback_args.resize(Decl->getNumParams());
+ if (Decl->getAttr<WeakRefAttr>()) {
+ FuncInfo->is_weak = true;
+ }
+ if (Decl->isVariadic()) {
+ FuncInfo->is_variadaic = true;
+ }
+ for (unsigned i = 0; i < Decl->getNumParams(); i++) {
+ auto ParmDecl = Decl->getParamDecl(i);
+ if (ParmDecl->getType()->isFunctionPointerType()) {
+ FuncInfo->callback_args[i] = ParmDecl->getType().getTypePtr();
+ FuncInfo->has_callback_arg = true;
+ } else {
+ FuncInfo->callback_args[i] = nullptr;
+ }
+ ParseParameter(AST, Gen, ParmDecl->getType(), FuncInfo);
+ }
+}
+
+class MyASTVisitor : public clang::RecursiveASTVisitor<MyASTVisitor> {
+public:
+ MyASTVisitor(clang::ASTContext* ctx) : Ctx(ctx) {}
+ MyASTVisitor(clang::ASTContext* ctx, WrapperGenerator* gen) : Ctx(ctx), Gen(gen) {}
+
+ bool VisitFunctionDecl(clang::FunctionDecl* Decl) {
+ ParseFunction(Ctx, Gen, Decl);
+ return true;
+ }
+private:
+ clang::ASTContext* Ctx;
+ WrapperGenerator* Gen;
+};
+
+class MyASTConsumer : public clang::ASTConsumer {
+public:
+ MyASTConsumer(clang::ASTContext* Context, const std::string& libname, const std::string& host_triple, const std::string& guest_triple)
+ : Visitor(Context, &Generator) {
+ Generator.Init(libname, host_triple, guest_triple);
+ }
+ void HandleTranslationUnit(clang::ASTContext &Ctx) override {
+ Visitor.TraverseDecl(Ctx.getTranslationUnitDecl());
+ std::cout << "--------------- Libclangtooling parse complete -----------------\n";
+ Generator.Prepare(&Ctx);
+ std::cout << "--------------- Generator prepare complete -----------------\n";
+ std::ofstream FuncDeclFile("wrapped" + Generator.libname + "_private.h", std::ios::out);
+ FuncDeclFile << Generator.GenFuncDeclare(&Ctx);
+ FuncDeclFile.close();
+ std::ofstream FuncDefineFile("wrapped" + Generator.libname + ".c", std::ios::out);
+ FuncDefineFile << "#include <stdio.h>\n"
+ "#include <stdlib.h>\n"
+ "#include <string.h>\n"
+ "#define _GNU_SOURCE /* See feature_test_macros(7) */\n"
+ "#include <dlfcn.h>\n"
+ "\n"
+ "#include \"wrappedlibs.h\"\n"
+ "\n"
+ "#include \"debug.h\"\n"
+ "#include \"wrapper.h\"\n"
+ "#include \"bridge.h\"\n"
+ "#include \"x64emu.h\"\n"
+ "#include \"box64context.h\"\n"
+ "\n"
+ "const char* " + Generator.libname + "Name = \"" + Generator.libname + "\";\n"
+ "#define LIBNAME " + Generator.libname + "\n"
+ "\n"
+ "#define ADDED_FUNCTIONS() \\\n"
+ "\n"
+ "#include \"generated/wrapped" + Generator.libname + "types.h\"\n";
+ FuncDefineFile << Generator.GenRecordDeclare(&Ctx);
+ FuncDefineFile << Generator.GenRecordConvert(&Ctx);
+ FuncDefineFile << Generator.GenCallbackWrap(&Ctx);
+ FuncDefineFile << Generator.GenFuncDefine(&Ctx);
+ FuncDefineFile.close();
+ std::cout << "--------------- Generator gen complete -----------------\n";
+ }
+private:
+ MyASTVisitor Visitor;
+ WrapperGenerator Generator;
+};
+
+class MyGenAction : public clang::ASTFrontendAction {
+public:
+ MyGenAction(const std::string& libname, const std::string& host_triple, const std::string& guest_triple) :
+ libname(libname), host_triple(host_triple), guest_triple(guest_triple) {}
+ std::unique_ptr<clang::ASTConsumer> CreateASTConsumer(clang::CompilerInstance& Compiler, clang::StringRef file) override {
+ (void)file;
+ return std::make_unique<MyASTConsumer>(&Compiler.getASTContext(), libname, host_triple, guest_triple);
+ }
+private:
+ std::string libname;
+ std::string host_triple;
+ std::string guest_triple;
+};
+
+class MyFrontendActionFactory : public clang::tooling::FrontendActionFactory {
+public:
+ MyFrontendActionFactory(const std::string& libname, const std::string& host_triple, const std::string& guest_triple) :
+ libname(libname), host_triple(host_triple), guest_triple(guest_triple) {}
+private:
+ std::unique_ptr<clang::FrontendAction> create() override {
+ return std::make_unique<MyGenAction>(libname, host_triple, guest_triple);
+ }
+private:
+ std::string libname;
+ std::string host_triple;
+ std::string guest_triple;
+};
diff --git a/wrapperhelper/gen.cpp b/wrapperhelper/gen.cpp
new file mode 100644
index 0000000..743474c
--- /dev/null
+++ b/wrapperhelper/gen.cpp
@@ -0,0 +1,1059 @@
+#include "gen.h"
+#include "utils.h"
+#include <clang/AST/ASTContext.h>
+#include <clang/AST/Decl.h>
+#include <clang/AST/Type.h>
+#include <clang/Basic/LLVM.h>
+
+using namespace clang;
+using namespace clang::tooling;
+
+static std::vector<uint64_t> GetRecordFieldOff(const std::string& Code, const std::string& Triple) {
+ std::vector<uint64_t> FieldOff;
+ std::vector<std::string> Args = {"-target", Triple};
+ std::unique_ptr<clang::ASTUnit> AST = clang::tooling::buildASTFromCodeWithArgs(Code, Args);
+ auto& Ctx = AST->getASTContext();
+ auto TranslateDecl = Ctx.getTranslationUnitDecl();
+ for (const auto& Decl : TranslateDecl->decls()) {
+ if (const auto RecordDecl = clang::dyn_cast<clang::RecordDecl>(Decl)) {
+ auto& RecordLayout = Ctx.getASTRecordLayout(RecordDecl);
+ for (unsigned i = 0; i < RecordLayout.getFieldCount(); i++) {
+ FieldOff.push_back(RecordLayout.getFieldOffset(i) / 8);
+ }
+ break;
+ }
+ }
+ return FieldOff;
+}
+
+static uint64_t GetRecordSize(const std::string& Code, const std::string& Triple) {
+ std::vector<std::string> Args = {"-target", Triple};
+ std::unique_ptr<ASTUnit> AST = buildASTFromCodeWithArgs(Code, Args);
+ auto& Ctx = AST->getASTContext();
+ auto TranslateDecl = Ctx.getTranslationUnitDecl();
+ for (const auto& Decl : TranslateDecl->decls()) {
+ if (const auto recordDecl = dyn_cast<RecordDecl>(Decl)) {
+ return Ctx.getTypeSize(recordDecl->getTypeForDecl()) / 8;
+ }
+ }
+ return 0;
+}
+
+static CharUnits::QuantityType GetRecordAlign(const std::string& Code, const std::string& Triple) {
+ std::vector<std::string> Args = {"-target", Triple};
+ std::unique_ptr<ASTUnit> AST = buildASTFromCodeWithArgs(Code, Args);
+ auto& Ctx = AST->getASTContext();
+ auto TranslateDecl = Ctx.getTranslationUnitDecl();
+ for (const auto& Decl : TranslateDecl->decls()) {
+ if (const auto recordDecl = dyn_cast<RecordDecl>(Decl)) {
+ auto& RecordLayout = Ctx.getASTRecordLayout(recordDecl);
+ for (unsigned i = 0; i < RecordLayout.getFieldCount(); i++) {
+ return RecordLayout.getAlignment().getQuantity() / 8;
+ }
+ break;
+ }
+ }
+ return 0;
+}
+
+static uint64_t GetTypeSize(const Type* Type, const std::string& Triple) {
+ std::string Code = Type->getCanonicalTypeInternal().getAsString() + " dummy;";
+ std::vector<std::string> Args = {"-target", Triple};
+ std::unique_ptr<ASTUnit> AST = buildASTFromCodeWithArgs(Code, Args);
+ auto& Ctx = AST->getASTContext();
+ auto TranslateDecl = Ctx.getTranslationUnitDecl();
+ for (const auto& Decl : TranslateDecl->decls()) {
+ if (const auto varDecl = dyn_cast<VarDecl>(Decl)) {
+ return Ctx.getTypeSize(varDecl->getType()) / 8;
+ }
+ }
+ return 0;
+}
+
+static std::string TypeToSig(ASTContext* Ctx, const Type* Type) {
+ if (Type->isBuiltinType()) {
+ switch (Type->getAs<clang::BuiltinType>()->getKind()) {
+ case clang::BuiltinType::Kind::Void:
+ return "v";
+ case clang::BuiltinType::Kind::Bool:
+ return "i";
+ case clang::BuiltinType::Kind::Char_U:
+ return "C";
+ case clang::BuiltinType::Kind::Char_S:
+ return "c";
+ case clang::BuiltinType::Kind::Char8:
+ return "c";
+ case clang::BuiltinType::Kind::UChar:
+ return "C";
+ case clang::BuiltinType::Kind::SChar:
+ return "c";
+ case clang::BuiltinType::Kind::WChar_U:
+ return "W";
+ case clang::BuiltinType::Kind::UShort:
+ return "W";
+ case clang::BuiltinType::Kind::WChar_S:
+ return "w";
+ case clang::BuiltinType::Kind::Char16:
+ return "w";
+ case clang::BuiltinType::Kind::Short:
+ return "w";
+ case clang::BuiltinType::Kind::UInt:
+ return "u";
+ case clang::BuiltinType::Kind::Char32:
+ return "i";
+ case clang::BuiltinType::Kind::Int:
+ return "i";
+ case clang::BuiltinType::Kind::ULong:
+ return "L";
+ case clang::BuiltinType::Kind::Long:
+ return "l";
+ case clang::BuiltinType::Kind::ULongLong:
+ return "U";
+ case clang::BuiltinType::Kind::LongLong:
+ return "I";
+ case clang::BuiltinType::Kind::UInt128:
+ return "H";
+ case clang::BuiltinType::Kind::Int128:
+ return "H";
+ case clang::BuiltinType::Kind::Float:
+ return "f";
+ case clang::BuiltinType::Kind::Double:
+ return "d";
+ case clang::BuiltinType::Kind::LongDouble:
+ return "D";
+ case clang::BuiltinType::Kind::NullPtr:
+ return "p"; // nullptr_t
+ default:
+ std::cout << "Unsupported BuiltinType: " << Type->getCanonicalTypeInternal().getAsString() << std::endl;
+ }
+ } else {
+ if (Type->isPointerType()) {
+ return "p";
+ } else if (Type->isVoidType()) {
+ return "v";
+ } else if (Type->isUnsignedIntegerOrEnumerationType()) {
+ switch(Ctx->getTypeSizeInChars(Type).getQuantity()) {
+ case 1:
+ return "C";
+ case 2:
+ return "W";
+ case 4:
+ return "u";
+ case 8:
+ return "U";
+ default:
+ std::cout << "Unsupported UnsignedInteger Type: " << Type->getCanonicalTypeInternal().getAsString() << std::endl;
+ }
+ } else if (Type->isSignedIntegerOrEnumerationType()) {
+ switch(Ctx->getTypeSizeInChars(Type).getQuantity()) {
+ case 1:
+ return "c";
+ case 2:
+ return "w";
+ case 4:
+ return "i";
+ case 8:
+ return "I";
+ default:
+ std::cout << "Unsupported SignedInteger Type: " << Type->getCanonicalTypeInternal().getAsString() << std::endl;
+ }
+ } else if (Type->isCharType()) {
+ return "c";
+ } else if (Type->isFloatingType()) {
+ switch(Ctx->getTypeSizeInChars(Type).getQuantity()) {
+ case 4:
+ return "f";
+ case 8:
+ return "d";
+ case 16:
+ return "D";
+ default:
+ std::cout << "Unsupported Floating Type: " << Type->getCanonicalTypeInternal().getAsString()
+ << " (quantity = " << Ctx->getTypeSizeInChars(Type).getQuantity() << ")" << std::endl;
+ }
+ } else {
+ std::cout << "Unsupported Type: " << Type->getCanonicalTypeInternal().getAsString() << std::endl;
+ }
+ }
+ return "?";
+}
+
+// Prepare for generation, collect the structures and functions that need to be prcessed
+void WrapperGenerator::Prepare(ASTContext *Ctx) {
+ for (const auto &func_pair : funcs) {
+ for (auto Type : func_pair.second.callback_args) {
+ if (Type && Type->isTypedefNameType()) {
+ callbacks[StripTypedef(Type->getPointeeType())] =
+ Type->getAs<TypedefType>()->getDecl()->getNameAsString();
+ } else if (Type) {
+ callbacks[StripTypedef(Type->getPointeeType())] =
+ GetFuncSig(Ctx, Type->getPointeeType().getTypePtr()) + "_t";
+ }
+ }
+ }
+ std::vector<const Type *> Types;
+ for (const auto &record_pair : records) {
+ Types.push_back(record_pair.first);
+ }
+ for (auto type : Types) {
+ std::set<const Type*> Visited{type};
+ bool Special = false;
+ ParseRecordRecursive(Ctx, type, Special, Visited);
+ }
+ for (auto it = records.begin(); it != records.end();) {
+ if (!it->second.is_special) {
+ it = records.erase(it);
+ } else {
+ for (auto field : it->second.callback_fields) {
+ if (field->isTypedefNameType()) {
+ callbacks[StripTypedef(field->getPointeeType())] =
+ field->getAs<TypedefType>()->getDecl()->getNameAsString();
+ } else {
+ callbacks[StripTypedef(field->getPointeeType())] =
+ GetFuncSig(Ctx, field->getPointeeType().getTypePtr()) + "_t";
+ }
+ }
+ ++it;
+ }
+ }
+ for (auto &func_pair : funcs) {
+ for (unsigned i = 0; i < func_pair.second.decl->getNumParams(); i++) {
+ auto ParamDecl = func_pair.second.decl->getParamDecl(i);
+ auto ParamType = ParamDecl->getType();
+ if (ParamType->isPointerType() &&
+ ParamType->getPointeeType()->isRecordType()) {
+ if (records.find(StripTypedef(ParamType->getPointeeType())) !=
+ records.end()) {
+ func_pair.second.has_special_arg = true;
+ break;
+ }
+ } else if (ParamType->isRecordType()) {
+ if (records.find(StripTypedef(ParamType)) != records.end()) {
+ func_pair.second.has_special_arg = true;
+ break;
+ }
+ }
+ }
+ auto RetType = func_pair.second.decl->getReturnType();
+ if (RetType->isPointerType() && RetType->getPointeeType()->isRecordType()) {
+ if (records.find(StripTypedef(RetType->getPointeeType())) !=
+ records.end()) {
+ func_pair.second.has_special_ret = true;
+ }
+ } else if (RetType->isRecordType()) {
+ if (records.find(StripTypedef(RetType)) != records.end()) {
+ func_pair.second.has_special_ret = true;
+ }
+ }
+ }
+}
+
+// Gen callback typedef
+std::string WrapperGenerator::GenCallbackTypeDefs(ASTContext *Ctx) {
+ (void)Ctx;
+ std::string res;
+ for (auto callback : callbacks) {
+ auto Type = callback.first;
+ auto Definition = GetFuncDefinition(Type);
+ res += "typedef " + Definition.ret_str + "(*" + callback.second + ")(";
+ for (int i = 0; i < Definition.arg_size - 1; i++) {
+ res += Definition.arg_types_str[i] + Definition.arg_names[i] + ", ";
+ }
+ if (Definition.arg_size) {
+ res += Definition.arg_types_str[Definition.arg_size - 1] + Definition.arg_names[Definition.arg_size - 1];
+ }
+ res += ");\n";
+ }
+ return res;
+}
+
+// Gen function declare
+std::string WrapperGenerator::GenDeclare(ASTContext *Ctx,
+ const FuncInfo &Func) {
+ std::string res;
+ std::string sig = GetFuncSig(Ctx, Func);
+ res += "GO";
+ if (Func.is_weak) {
+ res += "W";
+ }
+ if (sig.find('E') != std::string::npos) {
+ res += "M";
+ }
+ res += "(" + Func.func_name + ", " + sig + ")\n";
+ ;
+ return res;
+}
+
+// Gen structure declare
+std::string WrapperGenerator::GenDeclare(ASTContext *Ctx,
+ const RecordInfo &Record) {
+ (void)Ctx;
+ std::string RecordStr;
+ std::string PreDecl;
+ RecordStr += "\ntypedef ";
+ RecordStr +=
+ (Record.is_union ? "union " : "struct ") + Record.type_name + " {\n";
+ for (const auto &Field : Record.decl->fields()) {
+ auto Type = Field->getType();
+ std::string Name = Field->getNameAsString();
+ RecordStr += " ";
+ if (Type->isFunctionPointerType()) {
+ auto FuncType = StripTypedef(Type->getPointeeType());
+ if (callbacks.count(FuncType)) {
+ std::string FieldStr = callbacks[FuncType];
+ FieldStr += " ";
+ FieldStr += Name;
+ RecordStr += FieldStr;
+ } else {
+ std::cout << "Err: FuncPtr(" << Record.type_name << "." << Name << ") is not supported\n";
+ }
+ } else if (Type->isPointerType()) {
+ auto PointeeType = Type->getPointeeType();
+ if (PointeeType->isRecordType()) {
+ if (records.count(PointeeType.getTypePtr())) {
+ std::string FieldStr = records[PointeeType.getTypePtr()].type_name;
+ FieldStr += "_ptr ";
+ FieldStr += Name;
+ RecordStr += FieldStr;
+ } else {
+ RecordStr += "void *" + Name;
+ }
+ } else {
+ RecordStr += "void *" + Name;
+ }
+ } else if (Type->isRecordType()) {
+ if (records.count(Type.getTypePtr())) {
+ std::string FieldStr = records[Type.getTypePtr()].type_name;
+ FieldStr += " ";
+ FieldStr += Name;
+ RecordStr += FieldStr;
+ } else {
+ RecordStr += TypeStringify(StripTypedef(Type), Field, nullptr, PreDecl);
+ }
+ } else {
+ RecordStr += TypeStringify(StripTypedef(Type), Field, nullptr, PreDecl);
+ }
+ RecordStr += ";\n";
+ }
+ RecordStr += "} ";
+ RecordStr += Record.type_name + ", *" + Record.type_name + "_ptr;\n";
+ return RecordStr;
+}
+
+std::string WrapperGenerator::GenCallbackWrap(ASTContext *Ctx,
+ const FuncInfo &Func) {
+ (void)Ctx;
+ std::string res;
+
+ for (unsigned i = 0; i < Func.decl->getNumParams(); i++) {
+ auto ParamType = Func.decl->getParamDecl(i)->getType();
+ if (ParamType->isFunctionPointerType()) {
+
+ auto PointeeType = ParamType->getPointeeType();
+ auto Definition = GetFuncDefinition(PointeeType.getTypePtr());
+ std::string my_funcname =
+ std::string("my_") + Func.decl->getParamDecl(i)->getNameAsString();
+ std::string funcname = Func.decl->getParamDecl(i)->getNameAsString();
+ res += "\n#define GO(A) \\\n"
+ "static uintptr_t " + my_funcname + "_fct_##A = 0; \\\n" +
+ Definition.ret_str + " " + my_funcname + "(";
+ int arg_size = Definition.arg_names.size();
+ if (arg_size) {
+ for (int i = 0; i < arg_size - 1; i++) {
+ res += Definition.arg_types_str[i] + " " + Definition.arg_names[i] + ", ";
+ }
+ res += Definition.arg_types_str[arg_size - 1] + " " + Definition.arg_names[arg_size - 1];
+ }
+ res += ") { \\\n"
+ " return RunFunction(my_context, " + my_funcname + "_fct_##A" + ", " + std::to_string(arg_size);
+ for (int i = 0; i < arg_size; i++) {
+ res += ", " + Definition.arg_names[i];
+ }
+ res += "); \\\n"
+ "}\n"
+ "SUPER()\n"
+ "#undef GO\n"
+ "static void* find" + funcname + "Fct(void* fct) {\n"
+ " if (!fct) return fct;\n"
+ " if (GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);\n"
+ " #define GO(A) if (" + my_funcname + "_fct_##A == (uintptr_t)fct) return " + my_funcname + "_##A;\n"
+ " SUPER()\n"
+ " #undef GO\n"
+ " #define GO(A) if (" + my_funcname + "_fct_##A == 0) { " + my_funcname + "_fct_##A = (uintptr_t)fct; return " + my_funcname + "_##A; }\n"
+ " SUPER()\n"
+ " #undef GO\n"
+ " return NULL;\n"
+ "}\n";
+ }
+ }
+ return res;
+}
+
+std::string WrapperGenerator::GenCallbackWrap(ASTContext *Ctx,
+ const RecordInfo &Struct) {
+ (void)Ctx;
+ std::string res;
+ for (const auto &field : Struct.decl->fields()) {
+ auto FieldType = field->getType();
+ if (FieldType->isFunctionPointerType()) {
+ auto PointeeType = FieldType->getPointeeType();
+ auto Definition = GetFuncDefinition(PointeeType.getTypePtr());
+ std::string my_funcname = std::string("my_") + field->getNameAsString();
+ std::string funcname = field->getNameAsString();
+ res += "\n#define GO(A) \\\n"
+ "static uintptr_t " + my_funcname + "_fct_##A = 0; \\\n" +
+ Definition.ret_str + " " + my_funcname + "_##A(";
+ int arg_size = Definition.arg_names.size();
+ if (arg_size) {
+ for (int i = 0; i < arg_size - 1; i++) {
+ res += Definition.arg_types_str[i] + " " + Definition.arg_names[i] + ", ";
+ }
+ res += Definition.arg_types_str[arg_size - 1] + " " + Definition.arg_names[arg_size - 1];
+ }
+ res += ") { \\\n"
+ " return RunFunction(my_context, " + my_funcname + "_fct_##A" + ", " + std::to_string(arg_size);
+ for (int i = 0; i < arg_size; i++) {
+ res += ", " + Definition.arg_names[i];
+ }
+ res += "); \\\n"
+ "}\n"
+ "SUPER()\n"
+ "#undef GO\n"
+ "static void* find" + funcname + "Fct(void* fct) {\n"
+ " if(!fct) return fct;\n"
+ " if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);\n"
+ " #define GO(A) if(" + my_funcname + "_fct_##A == (uintptr_t)fct) return " + my_funcname + "_##A;}\n"
+ " SUPER()\n"
+ " #undef GO\n"
+ " #define GO(A) if(" + my_funcname + "_fct_##A == 0) {" + my_funcname + "_fct_##A = (uintptr_t)fct;" + "return " + my_funcname + "_##A;}\n"
+ " SUPER()\n"
+ " #undef GO\n"
+ " return NULL;\n"
+ "}\n";
+ }
+ }
+ return res;
+}
+
+std::string WrapperGenerator::GenDefine(ASTContext *Ctx,
+ const FuncInfo &Func) {
+ std::string res;
+ auto Definition = GetFuncDefinition(Func.decl);
+ std::string Sig = GetFuncSig(Ctx, Func.type);
+ res += "\nEXPORT " + Definition.ret_str + "my_" + Func.func_name + "(";
+ if (Sig.find('E')) {
+ res += "void *emu, ";
+ }
+ int arg_size = Definition.arg_names.size();
+ if (arg_size) {
+ for (int i = 0; i < arg_size - 1; i++) {
+ if (Definition.arg_types[i]->isPointerType()) {
+ auto PointeeType = Definition.arg_types[i]->getPointeeType();
+ if (records.count(PointeeType.getTypePtr())) {
+ res +=
+ Definition.arg_types[i]->getCanonicalTypeInternal().getAsString();
+ } else {
+ res += Definition.arg_types_str[i];
+ }
+ } else {
+ res += Definition.arg_types_str[i];
+ }
+ res += " " + Definition.arg_names[i] + ", ";
+ }
+ if (Definition.arg_types[arg_size - 1]->isPointerType()) {
+ auto PointeeType = Definition.arg_types[arg_size - 1]->getPointeeType();
+ if (records.count(PointeeType.getTypePtr())) {
+ res += Definition.arg_types[arg_size - 1]
+ ->getCanonicalTypeInternal()
+ .getAsString();
+ } else {
+ res += Definition.arg_types_str[arg_size - 1];
+ }
+ } else {
+ res += Definition.arg_types_str[arg_size - 1];
+ }
+ res += " ";
+ res += Definition.arg_names[arg_size - 1];
+ }
+ res += ") {\n";
+ if (Func.has_special_arg) {
+ res += " // WARN: This function's arg has a structure ptr which is "
+ "special, may need to wrap it for the host\n";
+
+ } else if (Func.has_special_ret) {
+ res += " // WARN: This function's ret is a structure ptr which is "
+ "special, may need to wrap it for the guest\n";
+ }
+ if (Func.has_callback_arg) {
+ res += " " + my_lib_type + " *my = " + "(" + my_lib_type + "*)" +
+ my_lib + "->priv.w.p2;\n"
+ " my->" + Func.func_name + "(";
+ if (arg_size) {
+ for (int i = 0; i < arg_size - 1; i++) {
+ if (Func.callback_args[i]) {
+ if (!Func.callback_args[i]->isTypedefNameType()) {
+ res +=
+ "find" + Func.func_name + "_arg" + std::to_string(i) + "Fct";
+ } else {
+ res += "find" +
+ Func.callback_args[i]
+ ->getAs<TypedefType>()
+ ->getDecl()
+ ->getNameAsString() +
+ "Fct";
+ }
+ res += "(" + Definition.arg_names[i] + ")";
+ } else {
+ res += Definition.arg_names[i];
+ }
+ res += ", ";
+ }
+ if (Func.callback_args[arg_size - 1]) {
+ if (!Func.callback_args[arg_size - 1]->isTypedefNameType()) {
+ res += "find" + Func.func_name + "_arg" +
+ std::to_string(arg_size - 1) + "Fct";
+ } else {
+ res += "find" +
+ Func.callback_args[arg_size - 1]
+ ->getAs<TypedefType>()
+ ->getDecl()
+ ->getNameAsString() +
+ "Fct";
+ }
+ res += "(" + Definition.arg_names[arg_size - 1] + ")";
+ } else {
+ res += Definition.arg_names[arg_size - 1];
+ }
+ res += ")\n";
+ }
+ } else {
+ res += " " + my_lib_type + " *my = (" + my_lib_type + "*)" + my_lib + "->priv.w.p2;\n"
+ " my->" + Func.func_name + "(";
+ if (arg_size) {
+ for (int i = 0; i < arg_size - 1; i++) {
+ res += Definition.arg_names[i] + ", ";
+ }
+ res += Definition.arg_names[arg_size - 1];
+ }
+ res += ");\n";
+ }
+
+ res += "}\n";
+ return res;
+}
+
+std::string WrapperGenerator::GenDeclareDiffTriple(
+ ASTContext *Ctx, const RecordInfo &Record,
+ const std::string &GuestTriple, const std::string &HostTriple) {
+ (void)Ctx;
+ std::string GuestRecord;
+ std::string HostRecord;
+ std::string PreDecl;
+ std::vector<uint64_t> GuestFieldOff;
+ std::vector<uint64_t> HostFieldOff;
+ GuestRecord += "typedef ";
+ HostRecord += "typedef ";
+ GuestRecord +=
+ (Record.is_union ? "union " : "struct ") + Record.type_name + " {\n";
+ HostRecord += (Record.is_union ? "union " : "struct ") +
+ std::string("host_") + Record.type_name + " {\n";
+ auto OffDiff = GetRecordFieldOffDiff(Record.type, GuestTriple, HostTriple,
+ GuestFieldOff, HostFieldOff);
+ uint64_t GuestRecordSize = GetRecordSize(Record.type, GuestTriple);
+ uint64_t HostRecordSize = GetRecordSize(Record.type, HostTriple);
+ uint64_t SizeDiff = GuestRecordSize - HostRecordSize;
+ int FieldIndex = 0;
+ std::set<FieldDecl *> AlignDiffFields;
+ for (const auto &Field : Record.decl->fields()) {
+ if (OffDiff[FieldIndex] == 0) {
+ FieldIndex++;
+ continue;
+ }
+ std::string Name = Field->getNameAsString();
+ if (OffDiff[FieldIndex] != SizeDiff) {
+ auto Diff = OffDiff[FieldIndex];
+ AlignDiffFields.insert(Field);
+ for (size_t i = FieldIndex; i < OffDiff.size(); i++) {
+ if (OffDiff[i] == Diff) {
+ OffDiff[i] = 0;
+ } else {
+ break;
+ }
+ }
+ } else {
+ AlignDiffFields.insert(Field);
+ break;
+ }
+ FieldIndex++;
+ }
+ for (const auto &Field : Record.decl->fields()) {
+ auto Type = Field->getType();
+ std::string Name = Field->getNameAsString();
+ GuestRecord += " ";
+ HostRecord += " ";
+ if (AlignDiffFields.find(Field) != AlignDiffFields.end()) {
+ auto typeSize = GetTypeSize(StripTypedef(Field->getType()), guest_triple);
+ switch (typeSize) {
+ // FIXME: should test more case in different triple
+ case 4: GuestRecord += "int " + Name ; break;
+ case 8: GuestRecord += "int " + Name + "[2]"; break;
+ default:
+ std::cout << "Err: unknown type size " << typeSize << std::endl;
+ break;
+ }
+ HostRecord += TypeStringify(StripTypedef(Type), Field, nullptr, PreDecl);
+ } else if (Type->isFunctionPointerType()) {
+ auto FuncType = StripTypedef(Type->getPointeeType());
+ if (callbacks.count(FuncType)) {
+ std::string FieldStr = callbacks[FuncType];
+ FieldStr += " ";
+ FieldStr += Name;
+ GuestRecord += FieldStr;
+ HostRecord += FieldStr;
+ } else {
+ std::cout << "Err: FuncPtr(" << Record.type_name << "." << Name << ") is not supported" << std::endl;
+ }
+ } else if (Type->isPointerType()) {
+ auto PointeeType = Type->getPointeeType();
+ if (PointeeType->isRecordType()) {
+ if (records.count(PointeeType.getTypePtr())) {
+ std::string FieldStr = records[PointeeType.getTypePtr()].type_name;
+ FieldStr += "_ptr " + Name;
+ GuestRecord += FieldStr;
+ HostRecord += "host_" + FieldStr;
+ } else {
+ GuestRecord += "void *" + Name;
+ HostRecord += "void *" + Name;
+ }
+ } else {
+ GuestRecord += "void *" + Name;
+ HostRecord += "void *" + Name;
+ }
+ } else if (Type->isRecordType()) {
+ if (records.count(Type.getTypePtr())) {
+ std::string FieldStr = records[Type.getTypePtr()].type_name;
+ FieldStr += " " + Name;
+ GuestRecord += FieldStr;
+ HostRecord += "host_" + FieldStr;
+ } else {
+ GuestRecord += TypeStringify(StripTypedef(Type), Field, nullptr, PreDecl);
+ HostRecord += TypeStringify(StripTypedef(Type), Field, nullptr, PreDecl);
+ }
+ } else {
+ HostRecord += TypeStringify(StripTypedef(Type), Field, nullptr, PreDecl);
+ GuestRecord += TypeStringify(StripTypedef(Type), Field, nullptr, PreDecl);
+ }
+ GuestRecord += ";\n";
+ HostRecord += ";\n";
+ }
+ GuestRecord += "} " + Record.type_name + ", *" + Record.type_name + "_ptr;\n";
+ HostRecord += "} host_" + Record.type_name + ", *host_" + Record.type_name + "_ptr;\n";
+ return GuestRecord + HostRecord;
+}
+
+// Gen record convert function between host and guest
+std::string WrapperGenerator::GenRecordConvert(const RecordInfo &Record) {
+ std::string res;
+ if (Record.guest_size != Record.host_size) {
+ auto RecordDecl = Record.decl;
+ std::vector<uint64_t> GuestFieldOff;
+ std::vector<uint64_t> HostFieldOff;
+ auto OffDiff = GetRecordFieldOffDiff(Record.type, guest_triple, host_triple,
+ GuestFieldOff, HostFieldOff);
+ int FieldIndex = 0;
+ std::vector<FieldDecl *> AlignDiffFields;
+ uint64_t SizeDiff = Record.guest_size - Record.host_size;
+ for (const auto &Field : RecordDecl->fields()) {
+ if (OffDiff[FieldIndex] == 0) {
+ FieldIndex++;
+ continue;
+ }
+ if (OffDiff[FieldIndex] != SizeDiff) {
+ auto Diff = OffDiff[FieldIndex];
+ AlignDiffFields.push_back(Field);
+ for (size_t i = FieldIndex; i < OffDiff.size(); i++) {
+ if (OffDiff[i] == Diff) {
+ OffDiff[i] = 0;
+ } else {
+ break;
+ }
+ }
+ } else {
+ AlignDiffFields.push_back(Field);
+ break;
+ }
+ FieldIndex++;
+ }
+ if (!AlignDiffFields.size()) {
+ return res;
+ }
+ res += "void g2h_" + Record.type_name + "(" + "struct host_" + Record.type_name + " *d, struct " + Record.type_name + " *s) {\n";
+ std::string body = " memcpy(d, s, offsetof(struct " + Record.type_name +
+ ", " + AlignDiffFields[0]->getNameAsString() + "));\n";
+ std::string offstr = "offsetof(struct " + Record.type_name + ", " +
+ AlignDiffFields[0]->getNameAsString() + ")";
+ for (size_t i = 0; i < AlignDiffFields.size() - 1; i++) {
+ body += " memcpy(d->" + AlignDiffFields[i]->getNameAsString() + ", " +
+ "s->" + AlignDiffFields[i]->getNameAsString() + ", " +
+ "offsetof(struct " + Record.type_name + ", " +
+ AlignDiffFields[i + 1]->getNameAsString() + ") - " + offstr +
+ ");\n";
+ offstr = "offsetof(struct " + Record.type_name + ", " +
+ AlignDiffFields[i + 1]->getNameAsString() + ")";
+ }
+ body += " memcpy(d->" +
+ AlignDiffFields[AlignDiffFields.size() - 1]->getNameAsString() +
+ ", " + "s->" +
+ AlignDiffFields[AlignDiffFields.size() - 1]->getNameAsString() +
+ ", " + std::to_string(GetRecordSize(Record.type, guest_triple)) +
+ " - " + offstr + ");\n";
+ res += body + "}\n";
+
+ res += "void h2g_" + Record.type_name + "(struct " + Record.type_name + " *d, " + "struct host_" + Record.type_name + " *s) {\n";
+ res += body;
+ res += "}\n";
+ }
+ return res;
+}
+
+void WrapperGenerator::ParseRecordRecursive(
+ ASTContext *Ctx, const Type *type, bool &Special,
+ std::set<const Type *> &Visited) {
+ auto recordType = type->getAs<RecordType>();
+ auto RecordDecl = recordType->getDecl();
+ for (const auto &field : RecordDecl->fields()) {
+ auto FieldType = field->getType();
+ if (FieldType->isFunctionPointerType()) {
+ auto Record = &records[type];
+ Record->callback_fields.push_back(field->getType().getTypePtr());
+ // Record->type_name =
+ Special = true;
+ } else if (FieldType->isPointerType() &&
+ FieldType->getPointeeType()->isRecordType()) {
+ auto FieldRecordType = StripTypedef(FieldType->getPointeeType());
+ if (Visited.find(FieldRecordType) != Visited.end())
+ continue;
+ Visited.insert(FieldRecordType);
+ bool _Special = false;
+ ParseRecordRecursive(Ctx, FieldRecordType, _Special, Visited);
+ if (_Special)
+ Special = true;
+ } else if (FieldType->isRecordType()) {
+ auto FieldRecordType = StripTypedef(FieldType);
+ if (Visited.find(FieldRecordType) != Visited.end())
+ continue;
+ Visited.insert(FieldRecordType);
+ bool _Special = false;
+ ParseRecordRecursive(Ctx, FieldRecordType, _Special, Visited);
+ if (_Special)
+ Special = true;
+ }
+ }
+ uint64_t GuestSize = GetRecordSize(type, guest_triple);
+ uint64_t HostSize = GetRecordSize(type, host_triple);
+
+ auto Record = &records[type];
+ if (GuestSize != HostSize) {
+ Special = 1;
+ }
+ if (type->isUnionType()) {
+ Record->is_union = true;
+ }
+ if (!Record->decl) {
+ Record->type = type;
+ Record->decl = RecordDecl;
+ if (RecordDecl->getIdentifier())
+ Record->type_name = RecordDecl->getIdentifier()->getName().str();
+ }
+ Record->guest_size = GuestSize;
+ Record->host_size = HostSize;
+ if (Record->type_name.empty()) {
+ Record->is_special = false;
+ } else
+ Record->is_special = Special;
+}
+
+// Type to String
+std::string WrapperGenerator::TypeStringify(const Type *Type,
+ FieldDecl *FieldDecl,
+ ParmVarDecl *ParmDecl,
+ std::string& PreDecl,
+ std::string indent,
+ std::string Name) {
+ std::string res;
+ std::string name = FieldDecl
+ ? FieldDecl->getNameAsString()
+ : (ParmDecl ? ParmDecl->getNameAsString() : Name);
+ if (Type->isPointerType()) {
+ auto PointeeType = Type->getPointeeType();
+ if (PointeeType->isBuiltinType()) {
+ res +=
+ StripTypedef(PointeeType)->getCanonicalTypeInternal().getAsString();
+ } else if (PointeeType->isRecordType()) {
+ if (records.find(StripTypedef(PointeeType)) != records.end() &&
+ records[StripTypedef(PointeeType)].is_special) {
+ res += (PointeeType->isUnionType() ? "union " : "struct ") + records[StripTypedef(PointeeType)].type_name;
+ } else {
+ res += "void";
+ }
+ } else {
+ res += "void";
+ }
+ res += " *" + name;
+ } else if (Type->isEnumeralType()) {
+ res += "int " + name;
+ } else if (Type->isRecordType()) {
+ if (records.find(StripTypedef(Type->getCanonicalTypeInternal())) !=
+ records.end() &&
+ records[StripTypedef(Type->getCanonicalTypeInternal())].is_special) {
+ res += Type->isUnionType() ? "union " : "struct ";
+ res += records[StripTypedef(Type->getCanonicalTypeInternal())].type_name;
+ res += " ";
+ } else {
+ res += AnonRecordDecl(Type->getAs<RecordType>(), PreDecl, indent + " ");
+ }
+ res += name;
+ } else if (Type->isConstantArrayType()) {
+ auto ArrayType =
+ dyn_cast<ConstantArrayType>(Type->getAsArrayTypeUnsafe());
+ int EleSize = ArrayType->getSize().getZExtValue();
+ if (ArrayType->getElementType()->isPointerType()) {
+ res += "void *";
+ } else if (ArrayType->getElementType()->isEnumeralType()) {
+ res += "int ";
+ } else if (ArrayType->getElementType()->isRecordType()) {
+ auto RecordType = ArrayType->getElementType()->getAs<clang::RecordType>();
+ auto RecordDecl = RecordType->getDecl();
+ if (RecordDecl->isCompleteDefinition()) {
+ auto& Ctx = RecordDecl->getDeclContext()->getParentASTContext();
+ PreDecl += "#include \"";
+ PreDecl += GetDeclHeaderFile(Ctx, RecordDecl);
+ PreDecl += "\"";
+ PreDecl += "\n";
+ }
+ res += StripTypedef(ArrayType->getElementType())
+ ->getCanonicalTypeInternal()
+ .getAsString();
+ } else {
+ res += StripTypedef(ArrayType->getElementType())
+ ->getCanonicalTypeInternal()
+ .getAsString();
+ }
+ res += " ";
+ res += name;
+ res += "[";
+ res += std::to_string(EleSize);
+ res += "]";
+ } else {
+ res += StripTypedef(Type->getCanonicalTypeInternal())
+ ->getCanonicalTypeInternal()
+ .getAsString();
+ res += " ";
+ res += name;
+ }
+ return indent + res;
+}
+
+// Type to String, less detail
+std::string WrapperGenerator::SimpleTypeStringify(const Type *Type,
+ FieldDecl *FieldDecl,
+ ParmVarDecl *ParmDecl,
+ std::string indent,
+ std::string Name) {
+ std::string res;
+ std::string name = FieldDecl
+ ? FieldDecl->getNameAsString()
+ : (ParmDecl ? ParmDecl->getNameAsString() : Name);
+ if (Type->isPointerType()) {
+ res += "void *" + name;
+ } else if (Type->isEnumeralType()) {
+ res += "int ";
+ res += name;
+ } else if (Type->isRecordType()) {
+ if (records.find(StripTypedef(Type->getCanonicalTypeInternal())) !=
+ records.end()) {
+ res += Type->isUnionType() ? "union " : "struct ";
+ res += records[StripTypedef(Type->getCanonicalTypeInternal())].type_name;
+ res += " ";
+ } else {
+ res += SimpleAnonRecordDecl(Type->getAs<RecordType>(), indent);
+ }
+ res += name;
+ } else if (Type->isConstantArrayType()) {
+ auto ArrayType =
+ dyn_cast<ConstantArrayType>(Type->getAsArrayTypeUnsafe());
+ int EleSize = ArrayType->getSize().getZExtValue();
+ if (ArrayType->getElementType()->isPointerType()) {
+ res += "void *";
+ } else {
+ res += StripTypedef(ArrayType->getElementType())
+ ->getCanonicalTypeInternal()
+ .getAsString();
+ }
+ res += " ";
+ res += name;
+ res += "[";
+ res += std::to_string(EleSize);
+ res += "]";
+ } else {
+ res += StripTypedef(Type->getCanonicalTypeInternal())
+ ->getCanonicalTypeInternal()
+ .getAsString();
+ res += " ";
+ res += name;
+ }
+ return indent + res;
+}
+
+std::string WrapperGenerator::AnonRecordDecl(const RecordType *Type, std::string& PreDecl, std::string indent) {
+ auto RecordDecl = Type->getDecl();
+ std::string res;
+ res += Type->isUnionType() ? "union {\n" : "struct {\n";
+ for (const auto &field : RecordDecl->fields()) {
+ auto FieldType = field->getType();
+ res += TypeStringify(StripTypedef(FieldType), field, nullptr, PreDecl, indent + " ");
+ res += ";\n";
+ }
+ res += indent + "} ";
+ return res;
+}
+
+std::string
+WrapperGenerator::SimpleAnonRecordDecl(const RecordType *Type, std::string indent) {
+ auto RecordDecl = Type->getDecl();
+ std::string res;
+ res += Type->isUnionType() ? "union {\n" : "struct {\n";
+ for (const auto &field : RecordDecl->fields()) {
+ auto FieldType = field->getType();
+ res += SimpleTypeStringify(StripTypedef(FieldType), field, nullptr, indent + " ");
+ res += ";\n";
+ }
+ res += indent + "} ";
+ return res;
+}
+
+// Get func info from FunctionType
+FuncDefinition WrapperGenerator::GetFuncDefinition(const Type *Type) {
+ FuncDefinition res;
+ std::string PreDecl;
+ auto ProtoType = Type->getAs<FunctionProtoType>();
+ res.ret = StripTypedef(ProtoType->getReturnType());
+ res.ret_str =
+ TypeStringify(StripTypedef(ProtoType->getReturnType()), nullptr, nullptr, PreDecl);
+ for (unsigned i = 0; i < ProtoType->getNumParams(); i++) {
+ auto ParamType = ProtoType->getParamType(i);
+ res.arg_types.push_back(StripTypedef(ParamType));
+ res.arg_types_str.push_back(
+ TypeStringify(StripTypedef(ParamType), nullptr, nullptr, PreDecl));
+ res.arg_names.push_back(std::string("a") + std::to_string(i));
+ }
+ if (ProtoType->isVariadic()) {
+ res.is_variadaic = true;
+ }
+ res.arg_size = ProtoType->getNumParams();
+ return res;
+}
+
+// Get funcdecl info from FunctionDecl
+FuncDefinition WrapperGenerator::GetFuncDefinition(FunctionDecl *Decl) {
+ FuncDefinition res;
+ std::string PreDecl;
+ auto RetType = Decl->getReturnType();
+ res.ret = RetType.getTypePtr();
+ res.ret_str = TypeStringify(StripTypedef(RetType), nullptr, nullptr, PreDecl);
+ for (unsigned i = 0; i < Decl->getNumParams(); i++) {
+ auto ParamDecl = Decl->getParamDecl(i);
+ auto ParamType = ParamDecl->getType();
+ res.arg_types.push_back(ParamType.getTypePtr());
+ res.arg_types_str.push_back(
+ TypeStringify(StripTypedef(ParamType), nullptr, nullptr, PreDecl));
+ res.arg_names.push_back(ParamDecl->getNameAsString());
+ }
+ if (Decl->isVariadic()) {
+ res.is_variadaic = true;
+ }
+ return res;
+}
+
+// Get the offset diff between two different triple
+std::vector<uint64_t> WrapperGenerator::GetRecordFieldOffDiff(
+ const Type *Type, const std::string &GuestTriple,
+ const std::string &HostTriple, std::vector<uint64_t> &GuestFieldOff,
+ std::vector<uint64_t> &HostFieldOff) {
+ std::string PreDecl;
+ std::string Code = TypeStringify(Type, nullptr, nullptr, PreDecl, "", "dummy;");
+ std::vector<uint64_t> OffsetDiff;
+ GuestFieldOff = GetRecordFieldOff(Code, GuestTriple);
+ HostFieldOff = GetRecordFieldOff(Code, HostTriple);
+ if (GuestFieldOff.size() != HostFieldOff.size()) {
+ // Should not happen
+ std::cout << "Greater field offsets in guest than in host" << std::endl;
+ return OffsetDiff;
+ }
+ for (size_t i = 0; i < GuestFieldOff.size(); i++) {
+ OffsetDiff.push_back(GuestFieldOff[i] - HostFieldOff[i]);
+ }
+ return OffsetDiff;
+}
+
+// Get the size under a specific triple
+uint64_t WrapperGenerator::GetRecordSize(const Type *Type,
+ const std::string &Triple) {
+ std::string PreDecl;
+ std::string Code = TypeStringify(Type, nullptr, nullptr, PreDecl, "", "dummy;");
+ auto Size = ::GetRecordSize(PreDecl + Code, Triple);
+ return Size;
+}
+
+// Get the align under a specific triple
+CharUnits::QuantityType WrapperGenerator::GetRecordAlign(const Type *Type,
+ const std::string &Triple) {
+ std::string PreDecl{};
+ std::string Code = TypeStringify(Type, nullptr, nullptr, PreDecl, "", "dummy;");
+ return ::GetRecordAlign(PreDecl + Code, Triple);
+}
+
+// Generate the func sig by type, used for export func
+std::string WrapperGenerator::GetFuncSig(ASTContext *CTX,
+ const FuncInfo &Func) {
+ std::string sig;
+ auto Decl = Func.decl;
+ auto Type = Decl->getType().getTypePtr();
+ auto ProtoType = Type->getAs<FunctionProtoType>();
+ auto RetType = ProtoType->getReturnType();
+
+ sig += TypeToSig(CTX, RetType.getTypePtr());
+ sig += "F";
+ if (Func.has_special_arg || Func.has_special_ret || Func.has_callback_arg) {
+ sig += "E";
+ }
+ if (ProtoType->getNumParams()) {
+ for (unsigned i = 0; i < ProtoType->getNumParams(); i++) {
+ sig += TypeToSig(CTX, ProtoType->getParamType(i).getTypePtr());
+ }
+ } else {
+ sig += "v";
+ }
+ if (Decl->isVariadic()) {
+ sig += "VV";
+ }
+ return sig;
+}
+
+// Generate the func sig by type, used for callbacks
+std::string WrapperGenerator::GetFuncSig(ASTContext *CTX,
+ const Type *Type) {
+ std::string sig;
+ auto ProtoType = Type->getAs<FunctionProtoType>();
+ auto RetType = ProtoType->getReturnType();
+ sig += TypeToSig(CTX, RetType.getTypePtr());
+ sig += "F";
+ if (ProtoType->getNumParams()) {
+ for (unsigned i = 0; i < ProtoType->getNumParams(); i++) {
+ sig += TypeToSig(CTX, ProtoType->getParamType(i).getTypePtr());
+ }
+ } else {
+ sig += "v";
+ }
+ return sig;
+}
diff --git a/wrapperhelper/gen.h b/wrapperhelper/gen.h
new file mode 100644
index 0000000..55ecd20
--- /dev/null
+++ b/wrapperhelper/gen.h
@@ -0,0 +1,144 @@
+#pragma once
+#include <clang/AST/ASTContext.h>
+#include <clang/AST/Type.h>
+#include <cstdint>
+#include <string>
+#include <vector>
+#include <set>
+
+struct FuncDefinition {
+ std::vector<const clang::Type*> arg_types;
+ std::vector<std::string> arg_types_str;
+ std::vector<std::string> arg_names;
+ const clang::Type* ret;
+ std::string ret_str;
+ int arg_size;
+ bool is_variadaic;
+};
+
+struct FuncInfo {
+ const clang::Type* type;
+ clang::FunctionDecl* decl;
+ std::string func_name;
+ bool is_weak;
+ bool is_variadaic;
+ bool has_special_arg;
+ bool has_special_ret;
+ bool has_callback_arg;
+ std::vector<const clang::Type*> callback_args;
+};
+
+struct RecordInfo {
+ const clang::Type* type;
+ clang::RecordDecl* decl;
+ std::string type_name;
+ bool is_union;
+ bool is_special;
+
+ uint64_t guest_size;
+ uint64_t host_size;
+ std::vector<const clang::Type*> callback_fields;
+};
+
+struct ObjectInfo {
+ const clang::Type* type;
+ std::string object_name;
+};
+
+struct WrapperGenerator {
+
+ void Init(const std::string& libname, const std::string& host_triple, const std::string& guest_triple) {
+ this->host_triple = host_triple;
+ this->guest_triple = guest_triple;
+ this->libname = libname;
+ this->my_lib_type = libname + "_my_t";
+ this->my_lib = "my_lib";
+ }
+
+ void Prepare(clang::ASTContext* Ctx);
+
+ std::string GenCallbackTypeDefs(clang::ASTContext* Ctx);
+
+ std::string GenFuncDeclare(clang::ASTContext* Ctx) {
+ std::string res{};
+ for (const auto& func : funcs) {
+ res += GenDeclare(Ctx, func.second);
+ }
+ return res;
+ }
+ std::string GenRecordDeclare(clang::ASTContext* Ctx) {
+ std::string res{};
+ for (const auto& st : records) {
+ if (st.second.host_size == st.second.guest_size)
+ res += GenDeclare(Ctx, st.second);
+ else {
+ res += GenDeclareDiffTriple(Ctx, st.second, guest_triple, host_triple);
+ }
+ }
+ return res;
+ }
+
+ std::string GenFuncDefine(clang::ASTContext* Ctx) {
+ std::string res{};
+ for (const auto& func : funcs) {
+ res += GenDefine(Ctx, func.second);
+ }
+ return res;
+ }
+
+ std::string GenCallbackWrap(clang::ASTContext* Ctx) {
+ std::string res{};
+ for (const auto& func : funcs) {
+ res += GenCallbackWrap(Ctx, func.second);
+ }
+ for (const auto& st : records) {
+ res += GenCallbackWrap(Ctx, st.second);
+ }
+ return res;
+ }
+
+ std::string GenRecordConvert(clang::ASTContext* Ctx) {
+ (void)Ctx;
+ std::string res;
+ for (const auto& record : records) {
+ if (record.second.host_size != record.second.guest_size) {
+ res += GenRecordConvert(record.second);
+ }
+ }
+ return res;
+ }
+
+ std::map<const clang::Type*, FuncInfo> funcs;
+ std::map<const clang::Type*, RecordInfo> records;
+ std::map<const clang::Type*, ObjectInfo> objects;
+
+ std::map<const clang::Type*, std::string> callbacks;
+
+ std::string host_triple;
+ std::string guest_triple;
+ std::string libname;
+ std::string my_lib_type;
+ std::string my_lib;
+private:
+ std::string GenRecordConvert(const RecordInfo& Record);
+ std::string GenDeclare(clang::ASTContext* Ctx, const FuncInfo& Func);
+ std::string GenDefine(clang::ASTContext* Ctx, const FuncInfo& Func);
+ std::string GenCallbackWrap(clang::ASTContext* Ctx, const FuncInfo& Func);
+ std::string GenDeclareDiffTriple(clang::ASTContext* Ctx, const RecordInfo& Record, const std::string& GuestTriple, const std::string& HostTriple);
+ std::string GenDeclare(clang::ASTContext* Ctx, const RecordInfo& Struct);
+ std::string GenCallbackWrap(clang::ASTContext* Ctx, const RecordInfo& Struct);
+
+ void ParseRecordRecursive(clang::ASTContext* Ctx, const clang::Type* Type, bool& Special, std::set<const clang::Type*>& Visited);
+ std::string TypeStringify(const clang::Type* Type, clang::FieldDecl* FieldDecl, clang::ParmVarDecl* ParmDecl, std::string& PreDecl, std::string indent = "", std::string Name = "");
+ std::string SimpleTypeStringify(const clang::Type* Type, clang::FieldDecl* FieldDecl, clang::ParmVarDecl* ParmDecl, std::string indent = "", std::string Name = "");
+ std::string AnonRecordDecl(const clang::RecordType* Type, std::string& PreDecl, std::string indent);
+ std::string SimpleAnonRecordDecl(const clang::RecordType* Type, std::string indent);
+ FuncDefinition GetFuncDefinition(const clang::Type* Type);
+ FuncDefinition GetFuncDefinition(clang::FunctionDecl* Decl);
+ uint64_t GetRecordSize(const clang::Type* Type, const std::string& Triple);
+ std::vector<uint64_t> GetRecordFieldOffDiff(const clang::Type* Type, const std::string& GuestTriple, const std::string& HostTriple, std::vector<uint64_t>& GuestFieldOff, std::vector<uint64_t>& HostFieldOff);
+ clang::CharUnits::QuantityType GetRecordAlign(const clang::Type* Type, const std::string& Triple);
+
+ std::string GetFuncSig(clang::ASTContext* CTX, const FuncInfo& Decl);
+ std::string GetFuncSig(clang::ASTContext* CTX, const clang::Type* Type);
+};
diff --git a/wrapperhelper/main.cpp b/wrapperhelper/main.cpp
new file mode 100644
index 0000000..b5a18a1
--- /dev/null
+++ b/wrapperhelper/main.cpp
@@ -0,0 +1,69 @@
+#include "ast.h"
+#include "utils.h"
+
+static void dump_usage() {
+ std::string Usage = R"usage(
+ usage: command <filename> <libname> [guest_triple] [host_triple] -- <clang_flags>
+ <filename> : set the header file to be parsed
+ <libname> : set libname required for wrapping func
+ [guest_triple]: set guest triple: can be arm32/arm64/x86/x64, default is x64
+ [host_triple] : set host triple: can be arm32/arm64/x86/x64, default is arm64
+ -- : mandatory
+ <clang_flags> : extra compiler flags
+ )usage";
+ std::cerr << Usage << std::endl;
+}
+
+std::string parse_triple(const char* arg) {
+ if (strcmp(arg, "x86") == 0) {
+ return "i386-pc-linux-gnu";
+ } else if (strcmp(arg, "x64") == 0) {
+ return "x86_64-pc-linux-gnu";
+ } else if (strcmp(arg, "arm32") == 0) {
+ return "armv7-unknown-linux-gnueabihf";
+ } else if (strcmp(arg, "arm64") == 0) {
+ return "aarch64-unknown-linux-gnu";
+ } else {
+ std::cerr << "Invalid triple: '" << arg << "'\n";
+ dump_usage();
+ return "";
+ }
+}
+
+int main(int argc, const char* argv[]) {
+ if (argc < 4) {
+ dump_usage();
+ return 0;
+ }
+ std::string libname = argv[2];
+ std::string guest_triple = parse_triple("x64");
+ std::string host_triple = parse_triple("arm64");
+ if (argc >= 5) {
+ guest_triple = parse_triple(argv[3]);
+ }
+ if (argc >= 6) {
+ host_triple = parse_triple(argv[4]);
+ }
+ bool has_necessary_tag = false;
+ for (int i = 0; i < argc; i++) {
+ if (strcmp(argv[i], "--") == 0) {
+ has_necessary_tag = true;
+ break;
+ }
+ }
+ if (!has_necessary_tag) {
+ std::cerr << "Please add '--' after the triples" << std::endl;
+ dump_usage();
+ return 0;
+ }
+ std::string err;
+ auto compile_db = clang::tooling::FixedCompilationDatabase::loadFromCommandLine(argc, argv, err);
+ clang::tooling::ClangTool Tool(*compile_db, {argv[1]});
+ Tool.appendArgumentsAdjuster([&guest_triple](const clang::tooling::CommandLineArguments &args, clang::StringRef) {
+ clang::tooling::CommandLineArguments adjusted_args = args;
+ adjusted_args.push_back(std::string{"-target"});
+ adjusted_args.push_back(guest_triple);
+ return adjusted_args;
+ });
+ return Tool.run(std::make_unique<MyFrontendActionFactory>(libname, host_triple, guest_triple).get());
+}
diff --git a/wrapperhelper/utils.h b/wrapperhelper/utils.h
new file mode 100644
index 0000000..06acbb7
--- /dev/null
+++ b/wrapperhelper/utils.h
@@ -0,0 +1,33 @@
+#pragma once
+#include <clang/AST/ASTContext.h>
+#include <clang/AST/Decl.h>
+#include <clang/AST/Type.h>
+#include <clang/Tooling/Tooling.h>
+#include <clang/AST/RecordLayout.h>
+#include <clang/AST/Decl.h>
+
+#include <llvm/ADT/Triple.h>
+#include <llvm/Support/Casting.h>
+
+#include <cstddef>
+#include <cstring>
+#include <iostream>
+
+static const clang::Type* StripTypedef(clang::QualType type) {
+ if (type->isTypedefNameType()) {
+ return StripTypedef(type->getAs<clang::TypedefType>()->getDecl()->getUnderlyingType());
+ } else {
+ return type.getTypePtr();
+ }
+}
+
+// FIXME: Need to support other triple except default target triple
+static std::string GetDeclHeaderFile(clang::ASTContext& Ctx, clang::Decl* Decl) {
+ const auto& SourceManager = Ctx.getSourceManager();
+ const clang::FileID FileID = SourceManager.getFileID(Decl->getBeginLoc());
+ const clang::FileEntry *FileEntry = SourceManager.getFileEntryForID(FileID);
+ if (FileEntry) {
+ return FileEntry->getName().str();
+ }
+ return "";
+} \ No newline at end of file