Dan Gohman | 10e730a | 2015-06-29 23:51:55 +0000 | [diff] [blame] | 1 | // WebAssemblyInstrSIMD.td - WebAssembly SIMD codegen support -*- tablegen -*-// |
| 2 | // |
| 3 | // The LLVM Compiler Infrastructure |
| 4 | // |
| 5 | // This file is distributed under the University of Illinois Open Source |
| 6 | // License. See LICENSE.TXT for details. |
| 7 | // |
| 8 | //===----------------------------------------------------------------------===// |
JF Bastien | 5ca0bac | 2015-07-10 18:23:10 +0000 | [diff] [blame] | 9 | /// |
| 10 | /// \file |
Adrian Prantl | 5f8f34e4 | 2018-05-01 15:54:18 +0000 | [diff] [blame] | 11 | /// WebAssembly SIMD operand code-gen constructs. |
JF Bastien | 5ca0bac | 2015-07-10 18:23:10 +0000 | [diff] [blame] | 12 | /// |
Dan Gohman | 10e730a | 2015-06-29 23:51:55 +0000 | [diff] [blame] | 13 | //===----------------------------------------------------------------------===// |
| 14 | |
Derek Schuff | 51ed131 | 2018-08-07 21:24:01 +0000 | [diff] [blame] | 15 | let Defs = [ARGUMENTS] in { |
| 16 | |
| 17 | let isCommutable = 1 in |
| 18 | defm ADD : SIMDBinaryInt<add, "add ", 24>; |
| 19 | defm SUB : SIMDBinaryInt<sub, "sub ", 28>; |
| 20 | let isCommutable = 1 in |
| 21 | defm MUL : SIMDBinaryInt<mul, "mul ", 32>; |
| 22 | |
| 23 | let isCommutable = 1 in |
| 24 | defm ADD : SIMDBinaryFP<fadd, "add ", 122>; |
| 25 | defm SUB : SIMDBinaryFP<fsub, "sub ", 124>; |
| 26 | defm DIV : SIMDBinaryFP<fdiv, "div ", 126>; |
| 27 | let isCommutable = 1 in |
| 28 | defm MUL : SIMDBinaryFP<fmul, "mul ", 128>; |
| 29 | |
| 30 | } // Defs = [ARGUMENTS] |