tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

MacroAssembler-wasm32.cpp (17011B)


      1 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*-
      2 * vim: set ts=8 sts=2 et sw=2 tw=80:
      3 * This Source Code Form is subject to the terms of the Mozilla Public
      4 * License, v. 2.0. If a copy of the MPL was not distributed with this
      5 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
      6 
      7 #include "jit/wasm32/MacroAssembler-wasm32.h"
      8 
      9 namespace js::jit {
     10 
     11 void MacroAssembler::subFromStackPtr(Imm32 imm32) { MOZ_CRASH(); }
     12 
     13 //{{{ check_macroassembler_style
     14 
     15 void MacroAssembler::PushBoxed(FloatRegister reg) { MOZ_CRASH(); }
     16 
     17 void MacroAssembler::branchPtrInNurseryChunk(Condition cond, Register ptr,
     18                                             Register temp, Label* label) {
     19  MOZ_CRASH();
     20 }
     21 
     22 void MacroAssembler::pushReturnAddress() { MOZ_CRASH(); }
     23 
     24 void MacroAssembler::popReturnAddress() { MOZ_CRASH(); }
     25 
     26 CodeOffset MacroAssembler::moveNearAddressWithPatch(Register dest) {
     27  MOZ_CRASH();
     28 }
     29 
     30 void MacroAssembler::patchNearAddressMove(CodeLocationLabel loc,
     31                                          CodeLocationLabel target) {
     32  MOZ_CRASH();
     33 }
     34 
     35 size_t MacroAssembler::PushRegsInMaskSizeInBytes(LiveRegisterSet set) {
     36  MOZ_CRASH();
     37  return 0;
     38 }
     39 
     40 void MacroAssembler::PushRegsInMask(LiveRegisterSet set) { MOZ_CRASH(); }
     41 
     42 void MacroAssembler::PopRegsInMaskIgnore(LiveRegisterSet set,
     43                                         LiveRegisterSet ignore) {
     44  MOZ_CRASH();
     45 }
     46 
     47 void MacroAssembler::PopStackPtr() { MOZ_CRASH(); }
     48 
     49 void MacroAssembler::freeStackTo(uint32_t framePushed) { MOZ_CRASH(); }
     50 
     51 void MacroAssembler::flexibleDivMod32(Register lhs, Register rhs,
     52                                      Register divOutput, Register remOutput,
     53                                      bool isUnsigned,
     54                                      const LiveRegisterSet& volatileLiveRegs) {
     55  MOZ_CRASH();
     56 }
     57 
     58 void MacroAssembler::flexibleQuotient32(
     59    Register lhs, Register rhs, Register dest, bool isUnsigned,
     60    const LiveRegisterSet& volatileLiveRegs) {
     61  MOZ_CRASH();
     62 }
     63 
     64 void MacroAssembler::flexibleQuotientPtr(
     65    Register lhs, Register rhs, Register dest, bool isUnsigned,
     66    const LiveRegisterSet& volatileLiveRegs) {
     67  MOZ_CRASH();
     68 }
     69 
     70 void MacroAssembler::flexibleRemainder32(
     71    Register lhs, Register rhs, Register dest, bool isUnsigned,
     72    const LiveRegisterSet& volatileLiveRegs) {
     73  MOZ_CRASH();
     74 }
     75 
     76 void MacroAssembler::flexibleRemainderPtr(
     77    Register lhs, Register rhs, Register dest, bool isUnsigned,
     78    const LiveRegisterSet& volatileLiveRegs) {
     79  MOZ_CRASH();
     80 }
     81 
     82 void MacroAssembler::storeRegsInMask(LiveRegisterSet set, Address dest,
     83                                     Register scratch) {
     84  MOZ_CRASH();
     85 }
     86 
     87 void MacroAssembler::wasmBoundsCheck32(Condition cond, Register index,
     88                                       Register boundsCheckLimit,
     89                                       Label* label) {
     90  MOZ_CRASH();
     91 }
     92 
     93 void MacroAssembler::wasmBoundsCheck32(Condition cond, Register index,
     94                                       Address boundsCheckLimit, Label* label) {
     95  MOZ_CRASH();
     96 }
     97 
     98 void MacroAssembler::wasmBoundsCheck64(Condition cond, Register64 index,
     99                                       Register64 boundsCheckLimit,
    100                                       Label* label) {
    101  MOZ_CRASH();
    102 }
    103 
    104 void MacroAssembler::wasmBoundsCheck64(Condition cond, Register64 index,
    105                                       Address boundsCheckLimit, Label* label) {
    106  MOZ_CRASH();
    107 }
    108 
    109 void MacroAssembler::oolWasmTruncateCheckF32ToI32(
    110    FloatRegister input, Register output, TruncFlags flags,
    111    const wasm::TrapSiteDesc& trapSiteDesc, Label* rejoin) {
    112  MOZ_CRASH();
    113 }
    114 
    115 void MacroAssembler::wasmTruncateDoubleToInt64(
    116    FloatRegister input, Register64 output, bool isSaturating, Label* oolEntry,
    117    Label* oolRejoin, FloatRegister tempDouble) {
    118  MOZ_CRASH();
    119 }
    120 
    121 void MacroAssembler::wasmTruncateDoubleToUInt64(
    122    FloatRegister input, Register64 output, bool isSaturating, Label* oolEntry,
    123    Label* oolRejoin, FloatRegister tempDouble) {
    124  MOZ_CRASH();
    125 }
    126 
    127 void MacroAssembler::oolWasmTruncateCheckF64ToI64(
    128    FloatRegister input, Register64 output, TruncFlags flags,
    129    const wasm::TrapSiteDesc& trapSiteDesc, Label* rejoin) {
    130  MOZ_CRASH();
    131 }
    132 
    133 void MacroAssembler::wasmTruncateFloat32ToInt64(
    134    FloatRegister input, Register64 output, bool isSaturating, Label* oolEntry,
    135    Label* oolRejoin, FloatRegister tempDouble) {
    136  MOZ_CRASH();
    137 }
    138 
    139 void MacroAssembler::wasmTruncateFloat32ToUInt64(
    140    FloatRegister input, Register64 output, bool isSaturating, Label* oolEntry,
    141    Label* oolRejoin, FloatRegister tempDouble) {
    142  MOZ_CRASH();
    143 }
    144 
    145 void MacroAssembler::oolWasmTruncateCheckF32ToI64(
    146    FloatRegister input, Register64 output, TruncFlags flags,
    147    const wasm::TrapSiteDesc& trapSiteDesc, Label* rejoin) {
    148  MOZ_CRASH();
    149 }
    150 
    151 void MacroAssembler::oolWasmTruncateCheckF64ToI32(
    152    FloatRegister input, Register output, TruncFlags flags,
    153    const wasm::TrapSiteDesc& trapSiteDesc, Label* rejoin) {
    154  MOZ_CRASH();
    155 }
    156 
    157 void MacroAssembler::convertUInt64ToFloat32(Register64 src, FloatRegister dest,
    158                                            Register temp) {
    159  MOZ_CRASH();
    160 }
    161 
    162 void MacroAssembler::convertInt64ToFloat32(Register64 src, FloatRegister dest) {
    163  MOZ_CRASH();
    164 }
    165 
    166 bool MacroAssembler::convertUInt64ToDoubleNeedsTemp() { MOZ_CRASH(); }
    167 
    168 void MacroAssembler::convertUInt64ToDouble(Register64 src, FloatRegister dest,
    169                                           Register temp) {
    170  MOZ_CRASH();
    171 }
    172 
    173 void MacroAssembler::convertInt64ToDouble(Register64 src, FloatRegister dest) {
    174  MOZ_CRASH();
    175 }
    176 
    177 void MacroAssembler::convertIntPtrToDouble(Register src, FloatRegister dest) {
    178  MOZ_CRASH();
    179 }
    180 
    181 void MacroAssembler::wasmAtomicLoad64(const wasm::MemoryAccessDesc& access,
    182                                      const Address& mem, Register64 temp,
    183                                      Register64 output) {
    184  MOZ_CRASH();
    185 }
    186 
    187 void MacroAssembler::wasmAtomicLoad64(const wasm::MemoryAccessDesc& access,
    188                                      const BaseIndex& mem, Register64 temp,
    189                                      Register64 output) {
    190  MOZ_CRASH();
    191 }
    192 
    193 void MacroAssembler::patchNopToCall(uint8_t* call, uint8_t* target) {
    194  MOZ_CRASH();
    195 }
    196 
    197 void MacroAssembler::patchCallToNop(uint8_t* call) { MOZ_CRASH(); }
    198 
    199 void MacroAssembler::patchCall(uint32_t callerOffset, uint32_t calleeOffset) {
    200  MOZ_CRASH();
    201 }
    202 
    203 CodeOffset MacroAssembler::farJumpWithPatch() {
    204  MOZ_CRASH();
    205  return CodeOffset(0);
    206 }
    207 
    208 void MacroAssembler::patchFarJump(CodeOffset farJump, uint32_t targetOffset) {
    209  MOZ_CRASH();
    210 }
    211 
    212 CodeOffset MacroAssembler::call(Register reg) {
    213  MOZ_CRASH();
    214  return CodeOffset(0);
    215 }
    216 
    217 CodeOffset MacroAssembler::call(Label* label) {
    218  MOZ_CRASH();
    219  return CodeOffset(0);
    220 }
    221 
    222 CodeOffset MacroAssembler::call(wasm::SymbolicAddress imm) {
    223  MOZ_CRASH();
    224  return CodeOffset(0);
    225 }
    226 
    227 CodeOffset MacroAssembler::callWithPatch() {
    228  MOZ_CRASH();
    229  return CodeOffset(0);
    230 }
    231 
    232 CodeOffset MacroAssembler::nopPatchableToCall() {
    233  MOZ_CRASH();
    234  return CodeOffset(0);
    235 }
    236 
    237 FaultingCodeOffset MacroAssembler::wasmTrapInstruction() {
    238  MOZ_CRASH();
    239  return FaultingCodeOffset();
    240 }
    241 
    242 template void MacroAssembler::storeUnboxedValue(const ConstantOrRegister& value,
    243                                                MIRType valueType,
    244                                                const Address& dest);
    245 
    246 template void MacroAssembler::storeUnboxedValue(
    247    const ConstantOrRegister& value, MIRType valueType,
    248    const BaseObjectElementIndex& dest);
    249 
    250 template <typename T>
    251 void MacroAssembler::storeUnboxedValue(const ConstantOrRegister& value,
    252                                       MIRType valueType, const T& dest) {
    253  MOZ_CRASH();
    254 }
    255 
    256 uint32_t MacroAssembler::pushFakeReturnAddress(Register scratch) {
    257  MOZ_CRASH();
    258 }
    259 
    260 void MacroAssembler::Pop(Register reg) { MOZ_CRASH(); }
    261 
    262 void MacroAssembler::Pop(FloatRegister t) { MOZ_CRASH(); }
    263 
    264 void MacroAssembler::Pop(const ValueOperand& val) { MOZ_CRASH(); }
    265 
    266 void MacroAssembler::Push(Register reg) { MOZ_CRASH(); }
    267 
    268 void MacroAssembler::Push(const Imm32 imm) { MOZ_CRASH(); }
    269 
    270 void MacroAssembler::Push(const ImmWord imm) { MOZ_CRASH(); }
    271 
    272 void MacroAssembler::Push(const ImmPtr imm) { MOZ_CRASH(); }
    273 
    274 void MacroAssembler::Push(const ImmGCPtr ptr) { MOZ_CRASH(); }
    275 
    276 void MacroAssembler::Push(FloatRegister reg) { MOZ_CRASH(); }
    277 
    278 void MacroAssembler::wasmTruncateFloat32ToInt32(FloatRegister input,
    279                                                Register output,
    280                                                bool isSaturating,
    281                                                Label* oolEntry) {
    282  MOZ_CRASH();
    283 }
    284 
    285 void MacroAssembler::wasmTruncateFloat32ToUInt32(FloatRegister input,
    286                                                 Register output,
    287                                                 bool isSaturating,
    288                                                 Label* oolEntry) {
    289  MOZ_CRASH();
    290 }
    291 
    292 void MacroAssembler::wasmTruncateDoubleToUInt32(FloatRegister input,
    293                                                Register output,
    294                                                bool isSaturating,
    295                                                Label* oolEntry) {
    296  MOZ_CRASH();
    297 }
    298 
    299 void MacroAssembler::wasmTruncateDoubleToInt32(FloatRegister input,
    300                                               Register output,
    301                                               bool isSaturating,
    302                                               Label* oolEntry) {
    303  MOZ_CRASH();
    304 }
    305 
    306 void MacroAssembler::wasmAtomicExchange64(const wasm::MemoryAccessDesc& access,
    307                                          const Address& mem, Register64 value,
    308                                          Register64 output) {
    309  MOZ_CRASH();
    310 }
    311 
    312 void MacroAssembler::wasmAtomicExchange64(const wasm::MemoryAccessDesc& access,
    313                                          const BaseIndex& mem,
    314                                          Register64 value, Register64 output) {
    315  MOZ_CRASH();
    316 }
    317 
    318 void MacroAssembler::atomicPause() { MOZ_CRASH(); }
    319 
    320 void MacroAssembler::speculationBarrier() { MOZ_CRASH(); }
    321 
    322 void MacroAssembler::shiftIndex32AndAdd(Register indexTemp32, int shift,
    323                                        Register pointer) {
    324  MOZ_CRASH();
    325 }
    326 
    327 void MacroAssembler::setupUnalignedABICall(Register scratch) { MOZ_CRASH(); }
    328 
    329 void MacroAssembler::enterFakeExitFrameForWasm(Register cxreg, Register scratch,
    330                                               ExitFrameType type) {
    331  MOZ_CRASH();
    332 }
    333 
    334 CodeOffset MacroAssembler::sub32FromMemAndBranchIfNegativeWithPatch(
    335    Address address, Label* label) {
    336  MOZ_CRASH();
    337 }
    338 
    339 void MacroAssembler::patchSub32FromMemAndBranchIfNegative(CodeOffset offset,
    340                                                          Imm32 imm) {
    341  MOZ_CRASH();
    342 }
    343 
    344 void MacroAssembler::floorFloat32ToInt32(FloatRegister src, Register dest,
    345                                         Label* fail) {
    346  MOZ_CRASH();
    347 }
    348 
    349 void MacroAssembler::floorDoubleToInt32(FloatRegister src, Register dest,
    350                                        Label* fail) {
    351  MOZ_CRASH();
    352 }
    353 
    354 void MacroAssembler::ceilFloat32ToInt32(FloatRegister src, Register dest,
    355                                        Label* fail) {
    356  MOZ_CRASH();
    357 }
    358 
    359 void MacroAssembler::ceilDoubleToInt32(FloatRegister src, Register dest,
    360                                       Label* fail) {
    361  MOZ_CRASH();
    362 }
    363 
    364 void MacroAssembler::roundFloat32ToInt32(FloatRegister src, Register dest,
    365                                         FloatRegister temp, Label* fail) {
    366  MOZ_CRASH();
    367 }
    368 
    369 void MacroAssembler::roundDoubleToInt32(FloatRegister src, Register dest,
    370                                        FloatRegister temp, Label* fail) {
    371  MOZ_CRASH();
    372 }
    373 
    374 void MacroAssembler::truncFloat32ToInt32(FloatRegister src, Register dest,
    375                                         Label* fail) {
    376  MOZ_CRASH();
    377 }
    378 
    379 void MacroAssembler::truncDoubleToInt32(FloatRegister src, Register dest,
    380                                        Label* fail) {
    381  MOZ_CRASH();
    382 }
    383 
    384 void MacroAssembler::nearbyIntDouble(RoundingMode mode, FloatRegister src,
    385                                     FloatRegister dest) {
    386  MOZ_CRASH();
    387 }
    388 
    389 void MacroAssembler::nearbyIntFloat32(RoundingMode mode, FloatRegister src,
    390                                      FloatRegister dest) {
    391  MOZ_CRASH();
    392 }
    393 
    394 void MacroAssembler::copySignDouble(FloatRegister lhs, FloatRegister rhs,
    395                                    FloatRegister output) {
    396  MOZ_CRASH();
    397 }
    398 
    399 void MacroAssembler::copySignFloat32(FloatRegister lhs, FloatRegister rhs,
    400                                     FloatRegister output) {
    401  MOZ_CRASH();
    402 }
    403 
    404 void MacroAssembler::branchTestValue(Condition cond, const ValueOperand& lhs,
    405                                     const Value& rhs, Label* label) {
    406  MOZ_CRASH();
    407 }
    408 
    409 void MacroAssembler::branchTestNaNValue(Condition cond, const ValueOperand& val,
    410                                        Register temp, Label* label) {
    411  MOZ_CRASH();
    412 }
    413 
    414 void MacroAssembler::branchValueIsNurseryCell(Condition cond,
    415                                              const Address& address,
    416                                              Register temp, Label* label) {
    417  MOZ_CRASH();
    418 }
    419 
    420 void MacroAssembler::branchValueIsNurseryCell(Condition cond,
    421                                              ValueOperand value, Register temp,
    422                                              Label* label) {
    423  MOZ_CRASH();
    424 }
    425 
    426 void MacroAssembler::callWithABINoProfiler(Register fun, ABIType result) {
    427  MOZ_CRASH();
    428 }
    429 
    430 void MacroAssembler::callWithABINoProfiler(const Address& fun, ABIType result) {
    431  MOZ_CRASH();
    432 }
    433 
    434 CodeOffset MacroAssembler::call(const Address& addr) { MOZ_CRASH(); }
    435 
    436 void MacroAssembler::call(ImmWord imm) { MOZ_CRASH(); }
    437 
    438 void MacroAssembler::call(ImmPtr imm) { MOZ_CRASH(); }
    439 
    440 void MacroAssembler::call(JitCode* c) { MOZ_CRASH(); }
    441 
    442 void MacroAssembler::callWithABIPost(uint32_t stackAdjust, ABIType result) {
    443  MOZ_CRASH();
    444 }
    445 
    446 void MacroAssembler::callWithABIPre(uint32_t* stackAdjust, bool callFromWasm) {
    447  MOZ_CRASH();
    448 }
    449 
    450 void MacroAssembler::comment(const char* msg) { MOZ_CRASH(); }
    451 
    452 void MacroAssembler::flush() { MOZ_CRASH(); }
    453 
    454 void MacroAssembler::loadStoreBuffer(Register ptr, Register buffer) {
    455  MOZ_CRASH();
    456 }
    457 
    458 void MacroAssembler::moveValue(const ValueOperand& src,
    459                               const ValueOperand& dest) {
    460  MOZ_CRASH();
    461 }
    462 
    463 void MacroAssembler::moveValue(const Value& src, const ValueOperand& dest) {
    464  MOZ_CRASH();
    465 }
    466 
    467 void MacroAssembler::wasmCompareExchange64(const wasm::MemoryAccessDesc& access,
    468                                           const Address& mem,
    469                                           Register64 expected,
    470                                           Register64 replacement,
    471                                           Register64 output) {
    472  MOZ_CRASH();
    473 }
    474 
    475 void MacroAssembler::wasmCompareExchange64(const wasm::MemoryAccessDesc& access,
    476                                           const BaseIndex& mem,
    477                                           Register64 expected,
    478                                           Register64 replacement,
    479                                           Register64 output) {
    480  MOZ_CRASH();
    481 }
    482 
    483 void MacroAssembler::wasmMarkCallAsSlow() { MOZ_CRASH(); }
    484 
    485 void MacroAssembler::wasmCheckSlowCallsite(Register ra, Label* notSlow,
    486                                           Register temp1, Register temp2) {
    487  MOZ_CRASH();
    488 }
    489 
    490 CodeOffset MacroAssembler::wasmMarkedSlowCall(const wasm::CallSiteDesc& desc,
    491                                              const Register reg) {
    492  MOZ_CRASH();
    493 }
    494 
    495 //}}} check_macroassembler_style
    496 
    497 void MacroAssemblerWasm32::executableCopy(void* buffer) { MOZ_CRASH(); }
    498 
    499 void MacroAssemblerWasm32::jump(Label* label) { MOZ_CRASH(); }
    500 
    501 void MacroAssemblerWasm32::writeCodePointer(CodeLabel* label) { MOZ_CRASH(); }
    502 
    503 void MacroAssemblerWasm32::haltingAlign(size_t) { MOZ_CRASH(); }
    504 
    505 void MacroAssemblerWasm32::nopAlign(size_t) { MOZ_CRASH(); }
    506 
    507 void MacroAssemblerWasm32::checkStackAlignment() { MOZ_CRASH(); }
    508 
    509 uint32_t MacroAssemblerWasm32::currentOffset() {
    510  MOZ_CRASH();
    511  return 0;
    512 }
    513 
    514 void MacroAssemblerWasm32::nop() { MOZ_CRASH(); }
    515 
    516 void MacroAssemblerWasm32::breakpoint() { MOZ_CRASH(); }
    517 
    518 void MacroAssemblerWasm32::abiret() { MOZ_CRASH(); }
    519 
    520 void MacroAssemblerWasm32::ret() { MOZ_CRASH(); }
    521 
    522 CodeOffset MacroAssemblerWasm32::toggledJump(Label*) { MOZ_CRASH(); }
    523 
    524 CodeOffset MacroAssemblerWasm32::toggledCall(JitCode*, bool) { MOZ_CRASH(); }
    525 
    526 size_t MacroAssemblerWasm32::ToggledCallSize(uint8_t*) { MOZ_CRASH(); }
    527 
    528 void MacroAssemblerWasm32::finish() { MOZ_CRASH(); }
    529 
    530 void MacroAssemblerWasm32::pushValue(ValueOperand val) { MOZ_CRASH(); }
    531 
    532 void MacroAssemblerWasm32::popValue(ValueOperand) { MOZ_CRASH(); }
    533 
    534 void MacroAssemblerWasm32::tagValue(JSValueType, Register, ValueOperand) {
    535  MOZ_CRASH();
    536 }
    537 
    538 void MacroAssemblerWasm32::retn(Imm32 n) { MOZ_CRASH(); }
    539 
    540 void MacroAssemblerWasm32::push(Register reg) { MOZ_CRASH(); }
    541 
    542 Address MacroAssemblerWasm32::ToType(const Address& address) { MOZ_CRASH(); }
    543 
    544 }  // namespace js::jit