<commit_before>#include "libcpu.h"
#include "x86_isa.h"
#include "x86_decode.h"

static unsigned long decode_table[256] = {
	/* 0x00 - 0x07 */
	0, 0, 0, 0, 0, 0, 0, 0,
	/* 0x08 - 0x0F */
	0, 0, 0, 0, 0, 0, 0, 0,
	/* 0x10 - 0x17 */
	0, 0, 0, 0, 0, 0, 0, 0,
	/* 0x18 - 0x1F */
	0, 0, 0, 0, 0, 0, 0, 0,
	/* 0x20 - 0x27 */
	0, 0, 0, 0, 0, 0, 0, 0,
	/* 0x28 - 0x2F */
	0, 0, 0, 0, 0, 0, 0, 0,
	/* 0x30 - 0x37 */
	0, 0, 0, 0, 0, 0, 0, 0,
	/* 0x38 - 0x3F */
	0, 0, 0, 0, 0, 0, 0, 0,
	/* 0x40 - 0x47 */
	0, 0, 0, 0, 0, 0, 0, 0,
	/* 0x48 - 0x4F */
	0, 0, 0, 0, 0, 0, 0, 0,
	/* 0x50 - 0x57 */
	0, 0, 0, 0, 0, 0, 0, 0,
	/* 0x58 - 0x5F */
	0, 0, 0, 0, 0, 0, 0, 0,
	/* 0x60 - 0x67 */
	0, 0, 0, 0, 0, 0, 0, 0,
	/* 0x68 - 0x6F */
	0, 0, 0, 0, 0, 0, 0, 0,
	/* 0x70 - 0x77 */
	0, 0, 0, 0, 0, 0, 0, 0,
	/* 0x78 - 0x7F */
	0, 0, 0, 0, 0, 0, 0, 0,
	/* 0x80 - 0x87 */
	0, 0, 0, 0, 0, 0, 0, 0,
	/* 0x88 - 0x8F */
	0, INSTR_MOV|ModRM|SrcReg, 0, 0, 0, 0, 0, 0,
	/* 0x90 - 0x97 */
	0, 0, 0, 0, 0, 0, 0, 0,
	/* 0x98 - 0x9F */
	0, 0, 0, 0, 0, 0, 0, 0,
	/* 0xA0 - 0xA7 */
	0, 0, 0, 0, 0, 0, 0, 0,
	/* 0xA8 - 0xAF */
	0, 0, 0, 0, 0, 0, 0, 0,
	/* 0xB0 - 0xB7 */
	0, 0, 0, 0, 0, 0, 0, 0,
	/* 0xB8 - 0xBF */
	INSTR_MOV|SrcImm16|DstReg, INSTR_MOV|SrcImm16|DstReg, INSTR_MOV|SrcImm16|DstReg, INSTR_MOV|SrcImm16|DstReg,
	0, 0, 0, 0,
	/* 0xC0 - 0xC7 */
	0, 0, 0, INSTR_RET|SrcNone|DstNone, 0, 0, 0, 0,
	/* 0xC8 - 0xCF */
	0, 0, 0, 0, 0, 0, 0, 0,
	/* 0xD0 - 0xD7 */
	0, 0, 0, 0, 0, 0, 0, 0,
	/* 0xD8 - 0xDF */
	0, 0, 0, 0, 0, 0, 0, 0,
	/* 0xE0 - 0xE7 */
	0, 0, 0, 0, 0, 0, 0, 0,
	/* 0xE8 - 0xEF */
	0, 0, 0, 0, 0, 0, 0, 0,
	/* 0xF0 - 0xF7 */
	0, 0, 0, 0, 0, 0, 0, 0,
	/* 0xF8 - 0xFF */
	0, 0, 0, 0, 0, 0, 0, 0,
};

static void
decode_dst_operand(struct x86_instr *instr)
{
	struct x86_operand *operand = &instr->dst;

	switch (instr->flags & DstMask) {
	case DstNone:
		break;
	case DstReg:
		operand->type	= OP_REG;
<commit_msg>x86: Fix decode_table formatting<commit_after>#include "libcpu.h"
#include "x86_isa.h"
#include "x86_decode.h"

static unsigned long decode_table[256] = {
	/*[0x0]*/	0,
	/*[0x1]*/	0,
	/*[0x2]*/	0,
	/*[0x3]*/	0,
	/*[0x4]*/	0,
	/*[0x5]*/	0,
	/*[0x6]*/	0,
	/*[0x7]*/	0,
	/*[0x8]*/	0,
	/*[0x9]*/	0,
	/*[0xA]*/	0,
	/*[0xB]*/	0,
	/*[0xC]*/	0,
	/*[0xD]*/	0,
	/*[0xE]*/	0,
	/*[0xF]*/	0,
	/*[0x10]*/	0,
	/*[0x11]*/	0,
	/*[0x12]*/	0,
	/*[0x13]*/	0,
	/*[0x14]*/	0,
	/*[0x15]*/	0,
	/*[0x16]*/	0,
	/*[0x17]*/	0,
	/*[0x18]*/	0,
	/*[0x19]*/	0,
	/*[0x1A]*/	0,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/	0,
	/*[0xE6]*/	0,
	/*[0xE7]*/	0,
	/*[0xE8]*/	0,
	/*[0xE9]*/	0,
	/*[0xEA]*/	0,
	/*[0xEB]*/	0,
	/*[0xEC]*/	0,
	/*[0xED]*/	0,
	/*[0xEE]*/	0,
	/*[0xEF]*/	0,
	/*[0xF0]*/	0,
	/*[0xF1]*/	0,
	/*[0xF2]*/	0,
	/*[0xF3]*/	0,
	/*[0xF4]*/	0,
	/*[0xF5]*/	0,
	/*[0xF6]*/	0,
	/*[0xF7]*/	0,
	/*[0xF8]*/	0,
	/*[0xF9]*/	0,
	/*[0xFA]*/	0,
	/*[0xFB]*/	0,
	/*[0xFC]*/	0,
	/*[0xFD]*/	0,
	/*[0xFE]*/	0,
	/*[0xFF]*/	0,
};

static void
decode_dst_operand(struct x86_instr *instr)
{
	struct x86_operand *operand = &instr->dst;

	switch (instr->flags & DstMask) {
	case DstNone:
		break;
	case DstReg:
		operand->type	= OP_REG;

{'fraction_non_alphanumeric': 0.37327114827918945, 'fraction_numerical': 0.20135091669347058, 'mean_word_length': 2.1584560690705943, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6308099', 'n_tokens_mistral': 4910, 'n_tokens_neox': 4463, 'n_words': 893}