Eine aufbereitete Darstellung der Quelle

 
     
 
 
Anforderungen  |   Konzepte  |   Entwurf  |   Entwicklung  |   Qualitätssicherung  |   Lebenszyklus  |   Steuerung
 
 
 
 

Benutzer

Quellcode-Bibliothek unaryarith-string.js

  Sprache: JAVA
 

setJitCompilerOption('ion.forceinlineCaches'1);

function warmup(fun, input_array, output_array) {
    assertEq(output_array.length, input_array.length);
    for (var index = 0; index < input_array.length; index++) {
        input = input_array[index];
        output = output_array[index];
        for (var i = 0; i < 30; i++) {
            var y = fun(input);
            assertEq(y, output)
        }
    }
}

// Unary - operator with transition between string representations of int32 and double.
var fun_neg_int32_double = (x) => { return -x; }
var fun_neg_double_int32 = (x) => { return -x; }

// Unary ~ operator using string representations of either int32 or double.
var fun_bitnot_int32 = (x) => { return ~x; }
var fun_bitnot_double = (x) => { return ~x; }

// Unary ++ operator using string representations of either int32 or double.
var fun_inc_int32 = (x) => { return ++x; }
var fun_inc_double = (x) => { return ++x; }

// Unary -- operator using string representations of either int32 or double.
var fun_dec_int32 = (x) => { return --x; }
var fun_dec_double = (x) => { return --x; }

// Unary + operator using string representations of either int32 or double.
var fun_pos_int32 = (x) => { return +x; }
var fun_pos_double = (x) => { return +x; }

// JSOp::ToNumeric using string representations of either int32 or double.
var fun_tonumeric_int32 = (x) => { return x++; }
var fun_tonumeric_double = (x) => { return x++; }

warmup(fun_neg_int32_double, ["1""2""-3"], [-1, -23]);
warmup(fun_neg_double_int32, ["0"], [-0]);

warmup(fun_neg_double_int32, ["3""4""-5"], [-3, -45]);
warmup(fun_neg_int32_double, ["1.2""1.4"], [-1.2, -1.4]);

warmup(fun_bitnot_int32, ["-1""0"], [0, -1]);
warmup(fun_bitnot_double, ["-1.0""0.0""1.2""3"], [0, -1, -2, -4]);

warmup(fun_inc_int32, ["-1""0"], [01]);
warmup(fun_inc_double, ["-1.0""0.0""1.2""3"], [012.24]);

warmup(fun_dec_int32, ["-1""0"], [-2, -1]);
warmup(fun_dec_double, ["-1.0""0.0""1.5""3"], [-2, -10.52]);

warmup(fun_pos_int32, ["-1""0"], [-10]);
warmup(fun_pos_double, ["-1.0""0.0""1.2""3"], [-1.00.01.23]);

warmup(fun_tonumeric_int32, ["-1""0"], [-10]);
warmup(fun_tonumeric_double, ["-1.0""0.0""1.2""3"], [-1.00.01.23]);

Messung V0.5 in Prozent
C=89 H=98 G=93

¤ Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.0.3Bemerkung:  ¤

*Bot Zugriff






Wurzel

Suchen

PVS Prover

Isabelle Prover

NIST Cobol Testsuite

Cephes Mathematical Library

Vienna Development Method

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.






                                                                                                                                                                                                                                                                                                                                                                                                     


Neuigkeiten

     Aktuelles
     Motto des Tages

Open Source Software

     Quellcodebibliothek
     Eigene Quellcodes
     Fremde Quellcodes
     Suchen

Jenseits des Üblichen ....
    

Besucherstatistik

Besucherstatistik

Statistik
#Sources=277311
#Domains=752002