1 /*BEGIN_LEGAL 2 3 Copyright (c) 2018 Intel Corporation 4 5 Licensed under the Apache License, Version 2.0 (the "License"); 6 you may not use this file except in compliance with the License. 7 You may obtain a copy of the License at 8 9 http://www.apache.org/licenses/LICENSE-2.0 10 11 Unless required by applicable law or agreed to in writing, software 12 distributed under the License is distributed on an "AS IS" BASIS, 13 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 See the License for the specific language governing permissions and 15 limitations under the License. 16 17 END_LEGAL */ 18 19 #if !defined(XED_ENCODE_TABLES_H) 20 # define XED_ENCODE_TABLES_H 21 22 // Some things are "extern const" because they are filled in where they are 23 // declared in some generated *.c file. 24 25 //Table of BIND function per each group 26 extern const 27 xed_encode_function_pointer_t xed_encode_groups[XED_ENC_GROUPS]; 28 29 //mapping from xed iclass to the encoding group 30 XED_GLOBAL_EXTERN 31 xed_uint16_t xed_enc_iclass2group[XED_ICLASS_LAST]; 32 33 //mapping from iclass to it's Id in the group 34 XED_GLOBAL_EXTERN 35 xed_uint8_t xed_enc_iclass2index_in_group[XED_ICLASS_LAST]; 36 37 // The entries of this array are xed_operand_enum_t, but stored as 38 // xed_uint8_t to save space. Subverting the type system. 39 XED_GLOBAL_EXTERN 40 xed_uint8_t xed_encode_order[XED_ENCODE_ORDER_MAX_ENTRIES][XED_ENCODE_ORDER_MAX_OPERANDS]; 41 XED_GLOBAL_EXTERN 42 xed_uint_t xed_encode_order_limit[XED_ENCODE_ORDER_MAX_ENTRIES]; 43 44 45 extern const 46 xed_ptrn_func_ptr_t xed_encode_fb_lu_table[XED_ENCODE_MAX_FB_PATTERNS]; 47 48 extern const 49 xed_ptrn_func_ptr_t xed_encode_emit_lu_table[XED_ENCODE_MAX_EMIT_PATTERNS]; 50 51 extern const 52 xed_uint8_t xed_encode_fb_values_table[XED_ENCODE_FB_VALUES_TABLE_SIZE]; 53 54 extern const 55 xed_encoder_iform_t xed_encode_iform_db[XED_ENCODE_MAX_IFORMS]; 56 57 #endif 58