| /external/swiftshader/third_party/llvm-10.0/llvm/lib/Target/WebAssembly/MCTargetDesc/ |
| D | WebAssemblyMCTargetDesc.h | 1 //==- WebAssemblyMCTargetDesc.h - WebAssembly Target Descriptions -*- C++ -*-=// 10 /// This file provides WebAssembly-specific target descriptions. 43 namespace WebAssembly { 82 } // end namespace WebAssembly 111 // Defines symbolic names for WebAssembly registers. This defines a mapping from 117 // Defines symbolic names for the WebAssembly instructions. 123 namespace WebAssembly { 152 case WebAssembly::LOAD8_S_I32: in GetDefaultP2AlignAny() 153 case WebAssembly::LOAD8_S_I32_S: in GetDefaultP2AlignAny() 154 case WebAssembly::LOAD8_U_I32: in GetDefaultP2AlignAny() [all …]
|
| D | WebAssemblyMCCodeEmitter.cpp | 1 //=- WebAssemblyMCCodeEmitter.cpp - Convert WebAssembly code to machine code -// 76 if (MI.getOpcode() == WebAssembly::BR_TABLE_I32_S || in encodeInstruction() 77 MI.getOpcode() == WebAssembly::BR_TABLE_I64_S) in encodeInstruction() 79 if (MI.getOpcode() == WebAssembly::BR_TABLE_I32 || in encodeInstruction() 80 MI.getOpcode() == WebAssembly::BR_TABLE_I64) in encodeInstruction() 95 case WebAssembly::OPERAND_I32IMM: in encodeInstruction() 98 case WebAssembly::OPERAND_OFFSET32: in encodeInstruction() 101 case WebAssembly::OPERAND_I64IMM: in encodeInstruction() 104 case WebAssembly::OPERAND_SIGNATURE: in encodeInstruction() 107 case WebAssembly::OPERAND_VEC_I8IMM: in encodeInstruction() [all …]
|
| D | WebAssemblyInstPrinter.cpp | 1 //=- WebAssemblyInstPrinter.cpp - WebAssembly assembly instruction printing -=// 16 #include "WebAssembly.h" 63 if (I != 0 && ((MI->getOpcode() != WebAssembly::CALL_INDIRECT_VOID && in printInst() 64 MI->getOpcode() != WebAssembly::CALL_INDIRECT_VOID_S) || in printInst() 82 case WebAssembly::LOOP: in printInst() 83 case WebAssembly::LOOP_S: in printInst() 88 case WebAssembly::BLOCK: in printInst() 89 case WebAssembly::BLOCK_S: in printInst() 93 case WebAssembly::TRY: in printInst() 94 case WebAssembly::TRY_S: in printInst() [all …]
|
| /external/swiftshader/third_party/llvm-16.0/llvm/lib/Target/WebAssembly/MCTargetDesc/ |
| D | WebAssemblyMCTargetDesc.h | 1 //==- WebAssemblyMCTargetDesc.h - WebAssembly Target Descriptions -*- C++ -*-=// 10 /// This file provides WebAssembly-specific target descriptions. 38 namespace WebAssembly { 81 } // end namespace WebAssembly 118 // Defines symbolic names for WebAssembly registers. This defines a mapping from 124 // Defines symbolic names for the WebAssembly instructions. 131 namespace WebAssembly { 141 case WebAssembly::NAME##_A32: \ in GetDefaultP2AlignAny() 142 case WebAssembly::NAME##_A64: \ in GetDefaultP2AlignAny() 143 case WebAssembly::NAME##_A32_S: \ in GetDefaultP2AlignAny() [all …]
|
| D | WebAssemblyMCCodeEmitter.cpp | 1 //=- WebAssemblyMCCodeEmitter.cpp - Convert WebAssembly code to machine code -// 80 if (MI.getOpcode() == WebAssembly::BR_TABLE_I32_S || in encodeInstruction() 81 MI.getOpcode() == WebAssembly::BR_TABLE_I64_S) in encodeInstruction() 83 if (MI.getOpcode() == WebAssembly::BR_TABLE_I32 || in encodeInstruction() 84 MI.getOpcode() == WebAssembly::BR_TABLE_I64) in encodeInstruction() 99 case WebAssembly::OPERAND_I32IMM: in encodeInstruction() 102 case WebAssembly::OPERAND_OFFSET32: in encodeInstruction() 105 case WebAssembly::OPERAND_I64IMM: in encodeInstruction() 108 case WebAssembly::OPERAND_SIGNATURE: in encodeInstruction() 109 case WebAssembly::OPERAND_VEC_I8IMM: in encodeInstruction() [all …]
|
| /external/swiftshader/third_party/llvm-16.0/llvm/lib/Target/WebAssembly/Utils/ |
| D | WebAssemblyUtilities.cpp | 1 //===-- WebAssemblyUtilities.cpp - WebAssembly Utility Functions ----------===// 10 /// This file implements several utility functions for WebAssembly. 22 // defined here to be shared between WebAssembly and its subdirectories. 25 cl::opt<bool> WebAssembly::WasmEnableEmEH( 27 cl::desc("WebAssembly Emscripten-style exception handling"), 30 cl::opt<bool> WebAssembly::WasmEnableEmSjLj( 32 cl::desc("WebAssembly Emscripten-style setjmp/longjmp handling"), 36 WebAssembly::WasmEnableEH("wasm-enable-eh", 37 cl::desc("WebAssembly exception handling"), 41 WebAssembly::WasmEnableSjLj("wasm-enable-sjlj", [all …]
|
| D | WebAssemblyTypeUtilities.cpp | 1 //===-- WebAssemblyTypeUtilities.cpp - WebAssembly Type Utility Functions -===// 10 /// This file implements several utility functions for WebAssembly type parsing. 24 std::optional<wasm::ValType> WebAssembly::parseType(StringRef Type) { in parseType() 45 WebAssembly::BlockType WebAssembly::parseBlockType(StringRef Type) { in parseBlockType() 47 return StringSwitch<WebAssembly::BlockType>(Type) in parseBlockType() 48 .Case("i32", WebAssembly::BlockType::I32) in parseBlockType() 49 .Case("i64", WebAssembly::BlockType::I64) in parseBlockType() 50 .Case("f32", WebAssembly::BlockType::F32) in parseBlockType() 51 .Case("f64", WebAssembly::BlockType::F64) in parseBlockType() 52 .Case("v128", WebAssembly::BlockType::V128) in parseBlockType() [all …]
|
| /external/llvm/lib/Target/WebAssembly/MCTargetDesc/ |
| D | WebAssemblyMCTargetDesc.h | 1 //==- WebAssemblyMCTargetDesc.h - WebAssembly Target Descriptions -*- C++ -*-=// 11 /// \brief This file provides WebAssembly-specific target descriptions. 43 namespace WebAssembly { 55 /// WebAssembly-specific directive identifiers. 64 } // end namespace WebAssembly 79 // Defines symbolic names for WebAssembly registers. This defines a mapping from 85 // Defines symbolic names for the WebAssembly instructions. 94 namespace WebAssembly { 99 case WebAssembly::LOAD8_S_I32: in GetDefaultP2Align() 100 case WebAssembly::LOAD8_U_I32: in GetDefaultP2Align() [all …]
|
| /external/swiftshader/third_party/llvm-10.0/llvm/lib/Target/WebAssembly/ |
| D | WebAssemblyFastISel.cpp | 1 //===-- WebAssemblyFastISel.cpp - WebAssembly FastISel implementation -----===// 10 /// This file defines the WebAssembly-specific support for the FastISel 19 #include "WebAssembly.h" 384 Reg = createResultReg(Subtarget->hasAddr64() ? &WebAssembly::I64RegClass in materializeLoadStoreOperands() 385 : &WebAssembly::I32RegClass); in materializeLoadStoreOperands() 386 unsigned Opc = Subtarget->hasAddr64() ? WebAssembly::CONST_I64 in materializeLoadStoreOperands() 387 : WebAssembly::CONST_I32; in materializeLoadStoreOperands() 462 unsigned Imm = createResultReg(&WebAssembly::I32RegClass); in zeroExtendToI32() 464 TII.get(WebAssembly::CONST_I32), Imm) in zeroExtendToI32() 467 unsigned Result = createResultReg(&WebAssembly::I32RegClass); in zeroExtendToI32() [all …]
|
| D | WebAssemblyExplicitLocals.cpp | 10 /// This file converts any remaining registers into WebAssembly locals. 19 #include "WebAssembly.h" 36 // This produces output which is not valid WebAssembly, and is not supported 40 cl::desc("WebAssembly: output implicit locals in" 47 return "WebAssembly Explicit Locals"; in getPassName() 66 "Convert registers to WebAssembly locals", false, false) 84 if (RC == &WebAssembly::I32RegClass) in getDropOpcode() 85 return WebAssembly::DROP_I32; in getDropOpcode() 86 if (RC == &WebAssembly::I64RegClass) in getDropOpcode() 87 return WebAssembly::DROP_I64; in getDropOpcode() [all …]
|
| D | WebAssemblyInstrInfo.cpp | 1 //===-- WebAssemblyInstrInfo.cpp - WebAssembly Instruction Information ----===// 10 /// This file contains the WebAssembly implementation of the 17 #include "WebAssembly.h" 31 // defines WebAssembly::getNamedOperandIdx 36 : WebAssemblyGenInstrInfo(WebAssembly::ADJCALLSTACKDOWN, in WebAssemblyInstrInfo() 37 WebAssembly::ADJCALLSTACKUP, in WebAssemblyInstrInfo() 38 WebAssembly::CATCHRET), in WebAssemblyInstrInfo() 44 case WebAssembly::CONST_I32: in isReallyTriviallyReMaterializable() 45 case WebAssembly::CONST_I64: in isReallyTriviallyReMaterializable() 46 case WebAssembly::CONST_F32: in isReallyTriviallyReMaterializable() [all …]
|
| D | WebAssemblyPeephole.cpp | 1 //===-- WebAssemblyPeephole.cpp - WebAssembly Peephole Optimiztions -------===// 10 /// Late peephole optimizations for WebAssembly. 15 #include "WebAssembly.h" 28 cl::desc("WebAssembly: Disable fallthrough-return optimizations."), 34 return "WebAssembly late peephole optimizer"; in getPassName() 53 "WebAssembly peephole optimizations", false, false) 86 assert(End->getOpcode() == WebAssembly::END_FUNCTION); in maybeRewriteToFallthrough() 99 case WebAssembly::I32RegClassID: in maybeRewriteToFallthrough() 100 CopyLocalOpc = WebAssembly::COPY_I32; in maybeRewriteToFallthrough() 102 case WebAssembly::I64RegClassID: in maybeRewriteToFallthrough() [all …]
|
| D | WebAssemblyRegisterInfo.cpp | 1 //===-- WebAssemblyRegisterInfo.cpp - WebAssembly Register Information ----===// 10 /// This file contains the WebAssembly implementation of the 47 for (auto Reg : {WebAssembly::SP32, WebAssembly::SP64, WebAssembly::FP32, in getReservedRegs() 48 WebAssembly::FP64}) in getReservedRegs() 73 unsigned AddrOperandNum = WebAssembly::getNamedOperandIdx( in eliminateFrameIndex() 74 MI.getOpcode(), WebAssembly::OpName::addr); in eliminateFrameIndex() 76 unsigned OffsetOperandNum = WebAssembly::getNamedOperandIdx( in eliminateFrameIndex() 77 MI.getOpcode(), WebAssembly::OpName::off); in eliminateFrameIndex() 91 if (MI.getOpcode() == WebAssembly::ADD_I32) { in eliminateFrameIndex() 100 if (Def && Def->getOpcode() == WebAssembly::CONST_I32 && in eliminateFrameIndex() [all …]
|
| D | WebAssemblyRegStackify.cpp | 22 #include "MCTargetDesc/WebAssemblyMCTargetDesc.h" // for WebAssembly::ARGUMENT_* 23 #include "WebAssembly.h" 46 return "WebAssembly Register Stackify"; in getPassName() 72 "Reorder instructions to use the WebAssembly value stack", 84 if (!MI->definesRegister(WebAssembly::VALUE_STACK)) in imposeStackOrdering() 85 MI->addOperand(MachineOperand::CreateReg(WebAssembly::VALUE_STACK, in imposeStackOrdering() 90 if (!MI->readsRegister(WebAssembly::VALUE_STACK)) in imposeStackOrdering() 91 MI->addOperand(MachineOperand::CreateReg(WebAssembly::VALUE_STACK, in imposeStackOrdering() 106 if (RegClass == &WebAssembly::I32RegClass) { in convertImplicitDefToConstZero() 107 MI->setDesc(TII->get(WebAssembly::CONST_I32)); in convertImplicitDefToConstZero() [all …]
|
| D | WebAssemblyFrameLowering.cpp | 1 //===-- WebAssemblyFrameLowering.cpp - WebAssembly Frame Lowering ----------==// 10 /// This file contains the WebAssembly implementation of 13 /// On WebAssembly, there aren't a lot of things to do here. There are no 132 BuildMI(MBB, InsertStore, DL, TII->get(WebAssembly::GLOBAL_SET_I32)) in writeSPToGlobal() 147 writeSPToGlobal(WebAssembly::SP32, MF, MBB, I, DL); in eliminateCallFramePseudoInstr() 157 "WebAssembly should not have callee-saved registers"); in emitPrologue() 168 WebAssembly::isArgument(InsertPt->getOpcode())) in emitPrologue() 174 unsigned SPReg = WebAssembly::SP32; in emitPrologue() 180 BuildMI(MBB, InsertPt, DL, TII->get(WebAssembly::GLOBAL_GET_I32), SPReg) in emitPrologue() 188 BuildMI(MBB, InsertPt, DL, TII->get(WebAssembly::COPY), BasePtr) in emitPrologue() [all …]
|
| /external/swiftshader/third_party/llvm-16.0/llvm/lib/Target/WebAssembly/ |
| D | WebAssemblyFastISel.cpp | 1 //===-- WebAssemblyFastISel.cpp - WebAssembly FastISel implementation -----===// 10 /// This file defines the WebAssembly-specific support for the FastISel 21 #include "WebAssembly.h" 387 Reg = createResultReg(Subtarget->hasAddr64() ? &WebAssembly::I64RegClass in materializeLoadStoreOperands() 388 : &WebAssembly::I32RegClass); in materializeLoadStoreOperands() 389 unsigned Opc = Subtarget->hasAddr64() ? WebAssembly::CONST_I64 in materializeLoadStoreOperands() 390 : WebAssembly::CONST_I32; in materializeLoadStoreOperands() 462 Register Imm = createResultReg(&WebAssembly::I32RegClass); in zeroExtendToI32() 464 TII.get(WebAssembly::CONST_I32), Imm) in zeroExtendToI32() 467 Register Result = createResultReg(&WebAssembly::I32RegClass); in zeroExtendToI32() [all …]
|
| D | WebAssemblyExplicitLocals.cpp | 10 /// This file converts any remaining registers into WebAssembly locals. 20 #include "WebAssembly.h" 37 return "WebAssembly Explicit Locals"; in getPassName() 56 "Convert registers to WebAssembly locals", false, false) 89 if (RC == &WebAssembly::I32RegClass) in getDropOpcode() 90 return WebAssembly::DROP_I32; in getDropOpcode() 91 if (RC == &WebAssembly::I64RegClass) in getDropOpcode() 92 return WebAssembly::DROP_I64; in getDropOpcode() 93 if (RC == &WebAssembly::F32RegClass) in getDropOpcode() 94 return WebAssembly::DROP_F32; in getDropOpcode() [all …]
|
| D | WebAssemblyInstrInfo.cpp | 1 //===-- WebAssemblyInstrInfo.cpp - WebAssembly Instruction Information ----===// 10 /// This file contains the WebAssembly implementation of the 18 #include "WebAssembly.h" 32 // defines WebAssembly::getNamedOperandIdx 37 : WebAssemblyGenInstrInfo(WebAssembly::ADJCALLSTACKDOWN, in WebAssemblyInstrInfo() 38 WebAssembly::ADJCALLSTACKUP, in WebAssemblyInstrInfo() 39 WebAssembly::CATCHRET), in WebAssemblyInstrInfo() 45 case WebAssembly::CONST_I32: in isReallyTriviallyReMaterializable() 46 case WebAssembly::CONST_I64: in isReallyTriviallyReMaterializable() 47 case WebAssembly::CONST_F32: in isReallyTriviallyReMaterializable() [all …]
|
| /external/llvm/lib/Target/WebAssembly/ |
| D | WebAssemblyFastISel.cpp | 1 //===-- WebAssemblyFastISel.cpp - WebAssembly FastISel implementation -----===// 11 /// \brief This file defines the WebAssembly-specific support for the FastISel 19 #include "WebAssembly.h" 329 &WebAssembly::I64RegClass : in materializeLoadStoreOperands() 330 &WebAssembly::I32RegClass); in materializeLoadStoreOperands() 332 WebAssembly::CONST_I64 : in materializeLoadStoreOperands() 333 WebAssembly::CONST_I32; in materializeLoadStoreOperands() 402 unsigned Imm = createResultReg(&WebAssembly::I32RegClass); in zeroExtendToI32() 404 TII.get(WebAssembly::CONST_I32), Imm) in zeroExtendToI32() 407 unsigned Result = createResultReg(&WebAssembly::I32RegClass); in zeroExtendToI32() [all …]
|
| D | WebAssemblySetP2AlignOperands.cpp | 15 #include "WebAssembly.h" 34 return "WebAssembly Set p2align Operands"; in getPassName() 64 case WebAssembly::LOAD_I32: in runOnMachineFunction() 65 case WebAssembly::LOAD_I64: in runOnMachineFunction() 66 case WebAssembly::LOAD_F32: in runOnMachineFunction() 67 case WebAssembly::LOAD_F64: in runOnMachineFunction() 68 case WebAssembly::LOAD8_S_I32: in runOnMachineFunction() 69 case WebAssembly::LOAD8_U_I32: in runOnMachineFunction() 70 case WebAssembly::LOAD16_S_I32: in runOnMachineFunction() 71 case WebAssembly::LOAD16_U_I32: in runOnMachineFunction() [all …]
|
| D | WebAssemblyPeephole.cpp | 1 //===-- WebAssemblyPeephole.cpp - WebAssembly Peephole Optimiztions -------===// 11 /// \brief Late peephole optimizations for WebAssembly. 16 #include "WebAssembly.h" 29 cl::desc("WebAssembly: Disable fallthrough-return optimizations."), 35 return "WebAssembly late peephole optimizer"; in getPassName() 122 case WebAssembly::STORE8_I32: in runOnMachineFunction() 123 case WebAssembly::STORE16_I32: in runOnMachineFunction() 124 case WebAssembly::STORE8_I64: in runOnMachineFunction() 125 case WebAssembly::STORE16_I64: in runOnMachineFunction() 126 case WebAssembly::STORE32_I64: in runOnMachineFunction() [all …]
|
| D | WebAssemblyRegisterInfo.cpp | 1 //===-- WebAssemblyRegisterInfo.cpp - WebAssembly Register Information ----===// 11 /// \brief This file contains the WebAssembly implementation of the 48 for (auto Reg : {WebAssembly::SP32, WebAssembly::SP64, WebAssembly::FP32, in getReservedRegs() 49 WebAssembly::FP64}) in getReservedRegs() 69 if (MI.mayLoadOrStore() && FIOperandNum == WebAssembly::MemOpAddressOperandNo) { in eliminateFrameIndex() 76 .ChangeToRegister(WebAssembly::SP32, /*IsDef=*/false); in eliminateFrameIndex() 83 if (MI.getOpcode() == WebAssembly::ADD_I32) { in eliminateFrameIndex() 92 if (Def && Def->getOpcode() == WebAssembly::CONST_I32 && in eliminateFrameIndex() 97 .ChangeToRegister(WebAssembly::SP32, /*IsDef=*/false); in eliminateFrameIndex() 107 unsigned FIRegOperand = WebAssembly::SP32; in eliminateFrameIndex() [all …]
|
| D | WebAssemblyInstrInfo.cpp | 1 //===-- WebAssemblyInstrInfo.cpp - WebAssembly Instruction Information ----===// 11 /// \brief This file contains the WebAssembly implementation of the 32 : WebAssemblyGenInstrInfo(WebAssembly::ADJCALLSTACKDOWN, in WebAssemblyInstrInfo() 33 WebAssembly::ADJCALLSTACKUP), in WebAssemblyInstrInfo() 39 case WebAssembly::CONST_I32: in isReallyTriviallyReMaterializable() 40 case WebAssembly::CONST_I64: in isReallyTriviallyReMaterializable() 41 case WebAssembly::CONST_F32: in isReallyTriviallyReMaterializable() 42 case WebAssembly::CONST_F64: in isReallyTriviallyReMaterializable() 64 if (RC == &WebAssembly::I32RegClass) in copyPhysReg() 65 CopyLocalOpcode = WebAssembly::COPY_LOCAL_I32; in copyPhysReg() [all …]
|
| D | WebAssemblyRegStackify.cpp | 23 #include "WebAssembly.h" 24 #include "MCTargetDesc/WebAssemblyMCTargetDesc.h" // for WebAssembly::ARGUMENT_* 43 return "WebAssembly Register Stackify"; in getPassName() 77 if (!MI->definesRegister(WebAssembly::EXPR_STACK)) in ImposeStackOrdering() 78 MI->addOperand(MachineOperand::CreateReg(WebAssembly::EXPR_STACK, in ImposeStackOrdering() 83 if (!MI->readsRegister(WebAssembly::EXPR_STACK)) in ImposeStackOrdering() 84 MI->addOperand(MachineOperand::CreateReg(WebAssembly::EXPR_STACK, in ImposeStackOrdering() 153 case WebAssembly::DIV_S_I32: case WebAssembly::DIV_S_I64: in Query() 154 case WebAssembly::REM_S_I32: case WebAssembly::REM_S_I64: in Query() 155 case WebAssembly::DIV_U_I32: case WebAssembly::DIV_U_I64: in Query() [all …]
|
| /external/clang/test/Driver/ |
| D | thread-model.c | 17 …arget wasm32-unknown-linux-gnu -c %s -v 2>&1 | FileCheck -check-prefix=CHECK-WEBASSEMBLY-DEFAULT %s 18 …linux-gnu -c %s -v -mthread-model single 2>&1 | FileCheck -check-prefix=CHECK-WEBASSEMBLY-SINGLE %s 19 …n-linux-gnu -c %s -v -mthread-model posix 2>&1 | FileCheck -check-prefix=CHECK-WEBASSEMBLY-POSIX %s 20 …linux-gnu -c %s -v -mthread-model silly 2>&1 | FileCheck -check-prefix=CHECK-WEBASSEMBLY-INVALID %s 21 …arget wasm64-unknown-linux-gnu -c %s -v 2>&1 | FileCheck -check-prefix=CHECK-WEBASSEMBLY-DEFAULT %s 22 …linux-gnu -c %s -v -mthread-model single 2>&1 | FileCheck -check-prefix=CHECK-WEBASSEMBLY-SINGLE %s 23 …n-linux-gnu -c %s -v -mthread-model posix 2>&1 | FileCheck -check-prefix=CHECK-WEBASSEMBLY-POSIX %s 24 …linux-gnu -c %s -v -mthread-model silly 2>&1 | FileCheck -check-prefix=CHECK-WEBASSEMBLY-INVALID %s 25 // CHECK-WEBASSEMBLY-DEFAULT: Thread model: posix 26 // CHECK-WEBASSEMBLY-DEFAULT: "-mthread-model" "posix" [all …]
|