removes C++17 dependency from asmjit backend
This commit is contained in:
parent
21f8eab432
commit
933f08494c
|
@ -104,7 +104,7 @@ protected:
|
||||||
void gen_instr_prologue(jit_holder& jh);
|
void gen_instr_prologue(jit_holder& jh);
|
||||||
void gen_instr_epilogue(jit_holder& jh);
|
void gen_instr_epilogue(jit_holder& jh);
|
||||||
inline void gen_raise(jit_holder& jh, uint16_t trap_id, uint16_t cause);
|
inline void gen_raise(jit_holder& jh, uint16_t trap_id, uint16_t cause);
|
||||||
template <typename T, typename = std::enable_if_t<std::is_integral_v<T>>> void gen_set_tval(jit_holder& jh, T new_tval) ;
|
template <typename T, typename = typename std::enable_if<std::is_integral<T>::value>::type> void gen_set_tval(jit_holder& jh, T new_tval) ;
|
||||||
void gen_set_tval(jit_holder& jh, x86_reg_t _new_tval) ;
|
void gen_set_tval(jit_holder& jh, x86_reg_t _new_tval) ;
|
||||||
|
|
||||||
template<unsigned W, typename U, typename S = typename std::make_signed<U>::type>
|
template<unsigned W, typename U, typename S = typename std::make_signed<U>::type>
|
||||||
|
@ -310,8 +310,8 @@ void vm_impl<ARCH>::gen_set_tval(jit_holder& jh, T new_tval) {
|
||||||
}
|
}
|
||||||
template <typename ARCH>
|
template <typename ARCH>
|
||||||
void vm_impl<ARCH>::gen_set_tval(jit_holder& jh, x86_reg_t _new_tval) {
|
void vm_impl<ARCH>::gen_set_tval(jit_holder& jh, x86_reg_t _new_tval) {
|
||||||
if(std::holds_alternative<x86::Gp>(_new_tval)) {
|
if(nonstd::holds_alternative<x86::Gp>(_new_tval)) {
|
||||||
x86::Gp new_tval = std::get<x86::Gp>(_new_tval);
|
x86::Gp new_tval = nonstd::get<x86::Gp>(_new_tval);
|
||||||
if(new_tval.size() < 8)
|
if(new_tval.size() < 8)
|
||||||
new_tval = gen_ext_Gp(jh.cc, new_tval, 64, false);
|
new_tval = gen_ext_Gp(jh.cc, new_tval, 64, false);
|
||||||
mov(jh.cc, jh.globals[TVAL], new_tval);
|
mov(jh.cc, jh.globals[TVAL], new_tval);
|
||||||
|
|
|
@ -104,7 +104,7 @@ protected:
|
||||||
void gen_instr_prologue(jit_holder& jh);
|
void gen_instr_prologue(jit_holder& jh);
|
||||||
void gen_instr_epilogue(jit_holder& jh);
|
void gen_instr_epilogue(jit_holder& jh);
|
||||||
inline void gen_raise(jit_holder& jh, uint16_t trap_id, uint16_t cause);
|
inline void gen_raise(jit_holder& jh, uint16_t trap_id, uint16_t cause);
|
||||||
template <typename T, typename = std::enable_if_t<std::is_integral_v<T>>> void gen_set_tval(jit_holder& jh, T new_tval) ;
|
template <typename T, typename = typename std::enable_if<std::is_integral<T>::value>::type> void gen_set_tval(jit_holder& jh, T new_tval) ;
|
||||||
void gen_set_tval(jit_holder& jh, x86_reg_t _new_tval) ;
|
void gen_set_tval(jit_holder& jh, x86_reg_t _new_tval) ;
|
||||||
|
|
||||||
template<unsigned W, typename U, typename S = typename std::make_signed<U>::type>
|
template<unsigned W, typename U, typename S = typename std::make_signed<U>::type>
|
||||||
|
@ -4850,8 +4850,8 @@ void vm_impl<ARCH>::gen_set_tval(jit_holder& jh, T new_tval) {
|
||||||
}
|
}
|
||||||
template <typename ARCH>
|
template <typename ARCH>
|
||||||
void vm_impl<ARCH>::gen_set_tval(jit_holder& jh, x86_reg_t _new_tval) {
|
void vm_impl<ARCH>::gen_set_tval(jit_holder& jh, x86_reg_t _new_tval) {
|
||||||
if(std::holds_alternative<x86::Gp>(_new_tval)) {
|
if(nonstd::holds_alternative<x86::Gp>(_new_tval)) {
|
||||||
x86::Gp new_tval = std::get<x86::Gp>(_new_tval);
|
x86::Gp new_tval = nonstd::get<x86::Gp>(_new_tval);
|
||||||
if(new_tval.size() < 8)
|
if(new_tval.size() < 8)
|
||||||
new_tval = gen_ext_Gp(jh.cc, new_tval, 64, false);
|
new_tval = gen_ext_Gp(jh.cc, new_tval, 64, false);
|
||||||
mov(jh.cc, jh.globals[TVAL], new_tval);
|
mov(jh.cc, jh.globals[TVAL], new_tval);
|
||||||
|
|
Loading…
Reference in New Issue