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


Quelle  bug1684861.js   Sprache: JAVA

 
const oob = /index out of bounds/;
const unaligned = /unaligned memory access/;
const RuntimeError = WebAssembly.RuntimeError;

// Test memory.atomic.notify unaligned access.
const module = new WebAssembly.Module(wasmTextToBinary(`(module
  (type (;0;) (func))
  (func $main (type 0)
    i32.const -64
    i32.const -63
    memory.atomic.notify offset=1
    unreachable)
  (memory (;0;) 4 4)
  (export "main" (func $main)))`));

const instance = new WebAssembly.Instance(module);
assertErrorMessage(() => instance.exports.main(), RuntimeError, unaligned);

// Test memory.atomic.notify oob access.
const module2 = new WebAssembly.Module(wasmTextToBinary(`(module
  (type (;0;) (func))
  (func $main (type 0)
    i32.const -64
    i32.const -63
    memory.atomic.notify offset=65536
    unreachable)
  (memory (;0;) 4 4)
  (export "main" (func $main)))`));

const instance2 = new WebAssembly.Instance(module2);
assertErrorMessage(() => instance2.exports.main(), RuntimeError, oob);

// Test memory.atomic.wait32 and .wait64 unaligned access.
const module3 = new WebAssembly.Module(wasmTextToBinary(`(module
  (type (;0;) (func))
  (func $wait32 (type 0)
    i32.const -64
    i32.const 42
    i64.const 0
    memory.atomic.wait32 offset=1
    unreachable)
  (func $wait64 (type 0)
    i32.const -64
    i64.const 43
    i64.const 0
    memory.atomic.wait64 offset=3
    unreachable)
  (memory (;0;) 4 4 shared)
  (export "wait32" (func $wait32))
  (export "wait64" (func $wait64)))`));

const instance3 = new WebAssembly.Instance(module3);
assertErrorMessage(() => instance3.exports.wait32(), RuntimeError, unaligned);
assertErrorMessage(() => instance3.exports.wait64(), RuntimeError, unaligned);

Messung V0.5
C=92 H=96 G=93

¤ Dauer der Verarbeitung: 0.0 Sekunden  (vorverarbeitet)  ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

Beweissystem der NASA

Beweissystem Isabelle

NIST Cobol Testsuite

Cephes Mathematical Library

Wiener Entwicklungsmethode

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

Software

     Produkte
     Quellcodebibliothek

Aktivitäten

     Artikel über Sicherheit
     Anleitung zur Aktivierung von SSL

Muße

     Gedichte
     Musik
     Bilder

Jenseits des Üblichen ....
    

Besucherstatistik

Besucherstatistik

Monitoring

Montastic status badge