<commit_before><!DOCTYPE html>
<html>
  <head>
    <title>Sugar Performance</title>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
    <script type="text/javascript" src="../unit_tests/javascripts/jquery-1.7.1.js"></script>
    <script type="text/javascript" src="javascripts/benchmark.js"></script>
    <script type="text/javascript" src="javascripts/vendor/moment.js"></script>
    <!-- sugar -->
    <script type="text/javascript" src="../lib/core.js"></script>
    <script type="text/javascript" src="../lib/es5.js"></script>
    <script type="text/javascript" src="../lib/object.js"></script>
    <script type="text/javascript" src="../lib/array.js"></script>
    <script type="text/javascript" src="../lib/string.js"></script>
    <script type="text/javascript" src="../lib/number.js"></script>
    <script type="text/javascript" src="../lib/function.js"></script>
    <script type="text/javascript" src="../lib/date.js"></script>
    <script type="text/javascript" src="../lib/range.js"></script>
    <script type="text/javascript" src="../lib/regexp.js"></script>
  </head>
  <body>
    <button id="sugar">Sugar</button>
    <button id="moment">Moment</button>
    <button id="sugar2">Sugar 2</button>
    <button id="moment2">Moment 2</button>
    <button id="repeat">Repeat</button>
    <div id="output"></div>
  </body>
  <script>

    var d = new Date();
    var m = moment();

    function runTest(obj, format) {
      console.info(obj);
      $('#output').html(obj.format(format));
      runPerformanceTest(function() {
        obj.format(format);
      });
    }

    $('#sugar').click(function() {
      runTest(d, '{yyyy}');
    });

    $('#moment').click(function() {
      runTest(m, 'YYYY');
    });

    $('#sugar2').click(function() {
      runTest(d, Date.ISO8601_DATETIME);
    });

    $('#moment2').click(function() {
      runTest(m, 'YYYY-MM-DDTHH:mm:ss.SSS');
    });

    $('#repeat').click(function() {
      runPerformanceTest(1, function() {
        repeatString(3000000, 'sss');
      });
    });

  </script>
</html><commit_msg>10 iterations with 300000 length<commit_after><!DOCTYPE html>
<html>
  <head>
    <title>Sugar Performance</title>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
    <script type="text/javascript" src="../unit_tests/javascripts/jquery-1.7.1.js"></script>
    <script type="text/javascript" src="javascripts/benchmark.js"></script>
    <script type="text/javascript" src="javascripts/vendor/moment.js"></script>
    <!-- sugar -->
    <script type="text/javascript" src="../lib/core.js"></script>
    <script type="text/javascript" src="../lib/es5.js"></script>
    <script type="text/javascript" src="../lib/object.js"></script>
    <script type="text/javascript" src="../lib/array.js"></script>
    <script type="text/javascript" src="../lib/string.js"></script>
    <script type="text/javascript" src="../lib/number.js"></script>
    <script type="text/javascript" src="../lib/function.js"></script>
    <script type="text/javascript" src="../lib/date.js"></script>
    <script type="text/javascript" src="../lib/range.js"></script>
    <script type="text/javascript" src="../lib/regexp.js"></script>
  </head>
  <body>
    <button id="sugar">Sugar</button>
    <button id="moment">Moment</button>
    <button id="sugar2">Sugar 2</button>
    <button id="moment2">Moment 2</button>
    <button id="repeat">Repeat</button>
    <div id="output"></div>
  </body>
  <script>

    var d = new Date();
    var m = moment();

    function runTest(obj, format) {
      console.info(obj);
      $('#output').html(obj.format(format));
      runPerformanceTest(function() {
        obj.format(format);
      });
    }

    $('#sugar').click(function() {
      runTest(d, '{yyyy}');
    });

    $('#moment').click(function() {
      runTest(m, 'YYYY');
    });

    $('#sugar2').click(function() {
      runTest(d, Date.ISO8601_DATETIME);
    });

    $('#moment2').click(function() {
      runTest(m, 'YYYY-MM-DDTHH:mm:ss.SSS');
    });

    $('#repeat').click(function() {
      runPerformanceTest(10, function() {
        repeatString(300000, 'sss');
      });
    });

  </script>
</html>
{'fraction_non_alphanumeric': 0.226612711259224, 'fraction_numerical': 0.012854082361342537, 'mean_word_length': 3.318602261048304, 'pattern_counts': {'":': 0, '<': 105, '<?xml version=': 0, '>': 105, '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': '4189892', 'n_tokens_mistral': 1414, 'n_tokens_neox': 1372, 'n_words': 205}