<commit_before>
#include "config.h"

#include <stdio.h>
#include <string.h>
#include <stdlib.h>

#include <sys/types.h>

#include <orc/orcprogram.h>
#include <orc/orcx86.h>
#include <orc/orcsse.h>
#include <orc/orcutils.h>
#include <orc/orcdebug.h>

#define SIZE 65536

#define ORC_SSE_ALIGNED_DEST_CUTOFF 64

void orc_sse_emit_loop (OrcCompiler *compiler, int offset, int update);

void orc_compiler_sse_init (OrcCompiler *compiler);
unsigned int orc_compiler_sse_get_default_flags (void);
void orc_compiler_sse_assemble (OrcCompiler *compiler);
void orc_compiler_sse_register_rules (OrcTarget *target);


void orc_compiler_rewrite_vars (OrcCompiler *compiler);
void orc_compiler_dump (OrcCompiler *compiler);
void sse_load_constant (OrcCompiler *compiler, int reg, int size, int value);

static OrcTarget sse_target = {
  "sse",
#if defined(HAVE_I386) || defined(HAVE_AMD64)
  TRUE,
#else
  FALSE,
#endif
  ORC_VEC_REG_BASE,
  orc_compiler_sse_get_default_flags,
  orc_compiler_sse_init,
  orc_compiler_sse_assemble,
  { { 0 } },
  0,
  NULL,
  sse_load_constant

};


void
orc_sse_init (void)
{
  orc_target_register (&sse_target);

  orc_compiler_sse_register_rules (&sse_target);
}

unsigned int
orc_compiler_sse_get_default_flags (void)<commit_msg>sse: set target as not executable if no SSE2<commit_after>
#include "config.h"

#include <stdio.h>
#include <string.h>
#include <stdlib.h>

#include <sys/types.h>

#include <orc/orcprogram.h>
#include <orc/orcx86.h>
#include <orc/orcsse.h>
#include <orc/orcutils.h>
#include <orc/orcdebug.h>

#define SIZE 65536

#define ORC_SSE_ALIGNED_DEST_CUTOFF 64

void orc_sse_emit_loop (OrcCompiler *compiler, int offset, int update);

void orc_compiler_sse_init (OrcCompiler *compiler);
unsigned int orc_compiler_sse_get_default_flags (void);
void orc_compiler_sse_assemble (OrcCompiler *compiler);
void orc_compiler_sse_register_rules (OrcTarget *target);


void orc_compiler_rewrite_vars (OrcCompiler *compiler);
void orc_compiler_dump (OrcCompiler *compiler);
void sse_load_constant (OrcCompiler *compiler, int reg, int size, int value);

static OrcTarget sse_target = {
  "sse",
#if defined(HAVE_I386) || defined(HAVE_AMD64)
  TRUE,
#else
  FALSE,
#endif
  ORC_VEC_REG_BASE,
  orc_compiler_sse_get_default_flags,
  orc_compiler_sse_init,
  orc_compiler_sse_assemble,
  { { 0 } },
  0,
  NULL,
  sse_load_constant

};


void
orc_sse_init (void)
{
#if defined(HAVE_I386)
  if (!(orc_sse_get_cpu_flags () & ORC_TARGET_SSE_SSE2)) {
    sse_target.executable = FALSE;
  }
#endif

  orc_target_register (&sse_target);

  orc_compiler_sse_register_rules (&sse_target);
}

unsigned int
orc_compiler_sse_get_default_flags (void)
{'fraction_non_alphanumeric': 0.10419790104947527, 'fraction_numerical': 0.013868065967016492, 'mean_word_length': 6.37292817679558, 'pattern_counts': {'":': 0, '<': 21, '<?xml version=': 0, '>': 21, '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': '878447', 'n_tokens_mistral': 1128, 'n_tokens_neox': 1052, 'n_words': 213}